From ddf2bc98e033dcafeef10c272460247a349ecaec Mon Sep 17 00:00:00 2001 From: xiaji Date: Fri, 12 Jun 2026 23:37:48 +0800 Subject: [PATCH] =?UTF-8?q?style(ui):=20=E8=AF=84=E8=AE=BA=E4=B8=89?= =?UTF-8?q?=E6=80=81=E8=A7=86=E8=A7=89=E5=8C=96=20=E2=80=94=20=E7=AD=89?= =?UTF-8?q?=E5=BE=85/=E5=A4=B1=E8=B4=A5=E5=8D=A1=E7=89=87=E5=A2=9E?= =?UTF-8?q?=E5=BC=BA=E8=BE=A8=E8=AF=86=E5=BA=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 旧版问题:等待中卡片视觉太低调(灰小斜体一行),失败也不显眼, 用户截图反馈:看不出状态,无法判断是 bug 还是没跑。 新版: - 等待中: 浅蓝底 + 1.5px 虚线边框 + 旋转 spinner + '生成中' 徽章 - 失败: 浅红底 + 1.5px 实线红边框 + '失败' 徽章(详情页显示原因) - 成功: 保留原木色左边框样式 - 加 commentary-badge(带 spinner / 状态文字) 替代原 NTag,辨识度更高 - 列表/详情 min-height 60px,避免占位卡片太矮导致视觉跳 - 失败时详情页显示 commentary_meituan_error(给 owner 排查用) --- frontend/src/views/ArticleDetail.vue | 142 +++++++++++++---- frontend/src/views/Feed.vue | 220 +++++++++++++++++++-------- 2 files changed, 266 insertions(+), 96 deletions(-) diff --git a/frontend/src/views/ArticleDetail.vue b/frontend/src/views/ArticleDetail.vue index 7ac6235..6d9793a 100644 --- a/frontend/src/views/ArticleDetail.vue +++ b/frontend/src/views/ArticleDetail.vue @@ -282,30 +282,36 @@ onMounted(load) 💬 Angel 评论 -

{{ article.commentary }}

-

- ⚠️ 评论生成失败 + class="commentary-state-box commentary-state-ok" + >{{ article.commentary }} +

+ 评论生成失败 enrichment_loop 会自动重试;如持续失败,检查后端 worker 日志 -

-

- 🕒 等待评论中 +

+
+ 正在生成评论… enrichment_loop 会在翻译完成后跑(每篇约 15-20 秒) -

+
@@ -314,20 +320,23 @@ onMounted(load) 🐱 美团评论 -

{{ article.commentary_meituan }}

-

- ⚠️ 评论生成失败 + class="commentary-state-box commentary-state-ok" + >{{ article.commentary_meituan }} +

+ 评论生成失败 {{ article.commentary_meituan_error }} -

-

- 🕒 等待评论中 +

+
+ 正在生成评论… enrichment_loop 会在翻译完成后跑(每篇约 15-20 秒) -

+
{ -
+
- +
- +
@@ -323,51 +333,133 @@ onMounted(async () => {