From aaef9e0dbaa4c7d318bed48d26755d2f49262560 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E5=BF=A0=E6=9E=97?= <170083662@qq.com> Date: Thu, 29 Jan 2026 14:05:01 +0800 Subject: [PATCH] =?UTF-8?q?feat(home):=20=E6=9B=BF=E6=8D=A2=E9=A6=96?= =?UTF-8?q?=E9=A1=B5=E8=BD=AE=E6=92=AD=E5=9B=BE=E5=AE=9E=E7=8E=B0=E4=B8=BA?= =?UTF-8?q?=E5=B9=BF=E5=91=8A=E7=B3=BB=E7=BB=9F=E9=A9=B1=E5=8A=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 移除原有的硬编码轮播图组件和相关样式 - 新增 getAdByCode 方法用于获取广告数据 - 实现解析广告数据的工具函数 parseSlides 和 parsePx - 集成 useAsyncData 获取 flash 广告数据 - 添加备用图片以确保加载失败时的显示 - 更新页面样式适配新的轮播组件结构 --- app/components/Carousel.vue | 22 +++--- app/components/SiteHeader.vue | 2 +- app/pages/index.vue | 127 ++++++++++++++++++---------------- 3 files changed, 78 insertions(+), 73 deletions(-) diff --git a/app/components/Carousel.vue b/app/components/Carousel.vue index fef6073..631c4fe 100644 --- a/app/components/Carousel.vue +++ b/app/components/Carousel.vue @@ -8,15 +8,16 @@ :autoplay-speed="autoplaySpeed" :dots="dotsEnabled" :effect="effect" + :style="{ height: heightCss }" > -