From c3c00eb764e2d3ad0d3fc57db319d8cfb19a49e2 Mon Sep 17 00:00:00 2001
From: zzh <1368735060@qq.com>
Date: Fri, 27 Nov 2026 15:46:24 +0800
Subject: [PATCH] =?UTF-8?q?refine:=20=E5=AE=98=E7=BD=91=20AI=20=E9=A6=96?=
=?UTF-8?q?=E9=A1=B5=E8=BE=93=E5=85=A5=E5=8F=B0=E5=B8=83=E5=B1=80=E3=80=81?=
=?UTF-8?q?=E7=B2=BE=E9=80=89=E5=B0=81=E9=9D=A2=E4=B8=8E=E4=BF=A1=E4=BB=BB?=
=?UTF-8?q?=E6=9D=A1=EF=BC=8C=E9=A1=B6=E6=A0=8F=20Logo=20=E5=9C=86?=
=?UTF-8?q?=E8=A7=92=E6=96=B9=E6=A0=87?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Co-authored-by: Cursor
---
src/components/top-nav/index.vue | 8 +-
src/views/site/SiteAdvisorShell.vue | 52 +-
src/views/site/SiteFeaturedRoutes.vue | 50 +-
src/views/site/SiteRunway.vue | 89 ++-
src/views/site/lib/portal-catalog.ts | 56 +-
src/views/site/lib/route-cover.ts | 76 ++-
src/views/site/styles/ai-advisor.css | 819 ++++++++++++++++----------
7 files changed, 728 insertions(+), 422 deletions(-)
diff --git a/src/components/top-nav/index.vue b/src/components/top-nav/index.vue
index 83cfb9d..6943f63 100644
--- a/src/components/top-nav/index.vue
+++ b/src/components/top-nav/index.vue
@@ -1408,7 +1408,7 @@ onUnmounted(() => {
align-items: center;
gap: 8px;
- /* 独立白底圆标:大图标 + 克制高级感(细描边 / 轻环境光) */
+ /* 独立白底圆角方标 */
.top-nav-logo {
position: relative;
z-index: 2;
@@ -1419,7 +1419,7 @@ onUnmounted(() => {
width: 44px;
height: 44px;
margin: 0;
- border-radius: 50%;
+ border-radius: 8px;
background: #fff;
border: 1px solid rgba(15, 23, 42, 0.08);
box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
@@ -1442,8 +1442,8 @@ onUnmounted(() => {
}
img {
- height: 30px;
- width: 30px;
+ height: 36px;
+ width: 36px;
box-sizing: border-box;
object-fit: contain;
display: block;
diff --git a/src/views/site/SiteAdvisorShell.vue b/src/views/site/SiteAdvisorShell.vue
index 9c2366e..9c8cdd2 100644
--- a/src/views/site/SiteAdvisorShell.vue
+++ b/src/views/site/SiteAdvisorShell.vue
@@ -31,7 +31,6 @@
{{ heroTitle }}
- {{ brandCopy.navFullName }}
@@ -167,24 +180,25 @@
@submit="$emit('submit', draft)"
/>
-
+
+
+ {{ copy.featuredRoutesAsk }}
@@ -184,9 +197,11 @@
type RouteItem,
} from './lib/portal-catalog';
import {
+ isRouteCoverReady,
preloadFeaturedRouteCovers,
resolveRouteCoverUrl,
routeHasRealCover,
+ subscribeRouteCoverReady,
} from './lib/route-cover';
const AUTOPLAY_MS = 4500;
@@ -213,6 +228,9 @@
const paused = ref(false);
const stageWidth = ref(1100);
const cardWidth = ref(280);
+ /** 驱动封面 is-ready 重绘;实际就绪态在 route-cover 模块里 */
+ const coverReadyTick = ref(0);
+ const coverReadyUnsubs: Array<() => void> = [];
const visible = computed(() => loading.value || featured.value.length > 0);
const canPrev = computed(() => featured.value.length > 1);
@@ -239,19 +257,33 @@
function cardBgStyle(item: RouteItem) {
const url = resolveRouteCoverUrl(item);
- // 3D rotateY 下 background-size:cover 比 img+object-fit 更稳,不会露底
+ // 封面走独立 media 层;cover + overflow 裁切,比 img 在 rotateY 下更稳
return url
? {
backgroundImage: `url("${url}")`,
- backgroundSize: 'cover',
- backgroundPosition: 'center',
- backgroundRepeat: 'no-repeat',
- backgroundOrigin: 'border-box',
- backgroundClip: 'border-box',
}
: undefined;
}
+ function isCoverReady(item: RouteItem) {
+ void coverReadyTick.value;
+ const url = resolveRouteCoverUrl(item);
+ return Boolean(url && isRouteCoverReady(url));
+ }
+
+ function bindCoverReady(items: RouteItem[]) {
+ while (coverReadyUnsubs.length) coverReadyUnsubs.pop()?.();
+ for (const item of items) {
+ const url = resolveRouteCoverUrl(item);
+ if (!url) continue;
+ coverReadyUnsubs.push(
+ subscribeRouteCoverReady(url, () => {
+ coverReadyTick.value += 1;
+ }),
+ );
+ }
+ }
+
function applyFeatured(items: RouteItem[], opts?: { keepIndex?: boolean }) {
featured.value = items;
const len = items.length;
@@ -261,6 +293,7 @@
activeIndex.value = Math.max(0, len - 1);
}
preloadFeaturedRouteCovers(items, activeIndex.value);
+ bindCoverReady(items);
}
/** 环形最短偏移:末张右侧接首张,首张左侧接末张 */
@@ -497,6 +530,7 @@
ro?.disconnect();
ro = null;
stopAutoplay();
+ while (coverReadyUnsubs.length) coverReadyUnsubs.pop()?.();
});
watch(stageRef, (el) => {
diff --git a/src/views/site/SiteRunway.vue b/src/views/site/SiteRunway.vue
index 0505bd9..8320657 100644
--- a/src/views/site/SiteRunway.vue
+++ b/src/views/site/SiteRunway.vue
@@ -6,7 +6,7 @@