From 4d1105d1db2f78bead7a9a29245eecab6f4cc6d8 Mon Sep 17 00:00:00 2001 From: qiuchenfan <2035024011@qq.com> Date: Thu, 20 Nov 2025 09:57:11 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B3=9B=E5=8C=96=E8=BD=AE=E6=92=AD=E5=9B=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../news/body/FireNews/ImportantNews.tsx | 29 ++++++++++++++++++- app/components/untils/CarouselPreset.tsx | 16 +++++----- 2 files changed, 36 insertions(+), 9 deletions(-) diff --git a/app/components/news/body/FireNews/ImportantNews.tsx b/app/components/news/body/FireNews/ImportantNews.tsx index 9feff88..5aace90 100644 --- a/app/components/news/body/FireNews/ImportantNews.tsx +++ b/app/components/news/body/FireNews/ImportantNews.tsx @@ -3,11 +3,38 @@ import {FireNewsList} from "./FireNewsList"; import { CarouselPreset } from "@/components/untils/CarouselPreset"; export function ImportantNews() { + // 定义所有轮播图片路径 + const carouselImages = [ + "/images/carousel-1.jpg", + "/images/carousel-2.jpg", + "/images/carousel-3.jpg", + "/images/carousel-4.jpg", + "/images/carousel-5.jpg", + "/images/carousel-6.jpg", + "/images/carousel-7.jpg", + "/images/carousel-8.jpg", + "/images/carousel-9.jpg", + ]; + + // 转换为 slides 格式 + const slides = carouselImages.map((imageUrl, index) => ({ + key: `carousel-${index + 1}`, + content: ( +
+ ), + })); + return(