From f8115f47fd899547888a31af66426654a519cead Mon Sep 17 00:00:00 2001 From: jing <1683105490@qq.com> Date: Wed, 23 Sep 2026 14:13:54 +0800 Subject: [PATCH] =?UTF-8?q?chore=EF=BC=9AAI=E4=BF=AE=E6=94=B9=E6=96=B0?= =?UTF-8?q?=E5=AF=B9=E8=AF=9D=E6=8C=89=E9=92=AE=E5=9B=BE=E6=A0=87=EF=BC=8C?= =?UTF-8?q?=E6=90=9C=E7=B4=A2=E8=AE=B0=E5=BD=95=E6=8C=89=E9=92=AE=E5=90=91?= =?UTF-8?q?=E4=B8=8A=E7=A7=BB=E5=8A=A8=EF=BC=8C=E5=88=A0=E9=99=A4AI?= =?UTF-8?q?=E5=9B=9E=E7=AD=94=E5=90=8E=E7=9A=84AI=E5=90=8D=E7=A7=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages_tool/ai-chat/ai-chat-message.vue | 45 ++++++++----------- .../ai-chat/components/ai-chat-search.vue | 5 ++- 2 files changed, 22 insertions(+), 28 deletions(-) diff --git a/pages_tool/ai-chat/ai-chat-message.vue b/pages_tool/ai-chat/ai-chat-message.vue index 9a4ed29..f40c5de 100644 --- a/pages_tool/ai-chat/ai-chat-message.vue +++ b/pages_tool/ai-chat/ai-chat-message.vue @@ -15,7 +15,8 @@ {{ $lang('ai-chat.index.aiNickname') }} - 🔄 + + 新对话 @@ -160,9 +161,8 @@ - + - {{ $lang('ai-chat.index.aiNickname') }} {{ formatTime(message.timestamp) }} @@ -4105,13 +4105,8 @@ _handleStreamError(msg) { position: relative; gap: 12rpx; - .ai-nickname-text { - position: relative; - z-index: 1; - } - .message-time { - /* 时间显示在 AI 智能昵称的右面 */ + /* AI 回答上方只保留时间, 左对齐显示 */ position: static; margin-top: 0; margin-left: 0; @@ -4211,13 +4206,6 @@ _handleStreamError(msg) { gap: 12rpx; margin-bottom: 4rpx; - .ai-nickname-text { - font-size: 24rpx; - font-weight: 500; - color: #666; - line-height: 1; - } - .message-time { margin-top: 0; font-size: 22rpx; @@ -5197,15 +5185,6 @@ _handleStreamError(msg) { /* ========== AI 回答: 无气泡 ========== AI 回答不做任何卡片/气泡, 背景透明、无边框、无阴影、无内边距, 文字直接渲染在白色页面底上 */ -/* 昵称更精致 */ -.ai-chat-container .chat-messages .message-item .ai-message .message-content .message-nickname .ai-nickname-text { - color: #3a4353 !important; - font-weight: 600; - letter-spacing: 0.4rpx; -} - - - /* ========== 思考流 / 工具调用 / 选项卡片 / 附件 样式 ========== */ /* 顶部栏: 标题 + 新对话 */ @@ -5213,7 +5192,9 @@ _handleStreamError(msg) { display: flex; align-items: center; justify-content: space-between; - padding: 16rpx 24rpx; + /* 右侧预留搜索入口(56rpx 圆形按钮, right:16rpx)的宽度, + 把"新对话"按钮左移, 避免被搜索按钮遮挡 */ + padding: 16rpx 88rpx 16rpx 24rpx; border-bottom: 1rpx solid rgba(17, 24, 39, 0.06); background: #ffffff; .chat-title { @@ -5230,7 +5211,17 @@ _handleStreamError(msg) { background: #f4f5f7; color: #1f6cff; font-size: 24rpx; - .new-chat-icon { font-size: 26rpx; } + /* 新对话图标: 圆角气泡 + 中间加号 + 左下角小尾巴的线性图标 + 微信小程序不支持内联 SVG, 沿用 base64 背景图方案 (与 svg-icon / voice-icon-bg 一致) */ + .new-chat-icon { + width: 32rpx; + height: 32rpx; + flex-shrink: 0; + background-image: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0ibm9uZSIgc3Ryb2tlPSIjMWY2Y2ZmIiBzdHJva2Utd2lkdGg9IjEuNyIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIj48cGF0aCBkPSJNOC41IDIuNUgxNkE1LjUgNS41IDAgMCAxIDIxLjUgOFYxMi41QTUuNSA1LjUgMCAwIDEgMTYgMThIOC42TDMgMjJWOEE1LjUgNS41IDAgMCAxIDguNSAyLjVaIi8+PHBhdGggZD0iTTEyIDcuNVYxMy41TTkuMiAxMC41SDE0LjgiLz48L3N2Zz4="); + background-repeat: no-repeat; + background-position: center; + background-size: contain; + } } } diff --git a/pages_tool/ai-chat/components/ai-chat-search.vue b/pages_tool/ai-chat/components/ai-chat-search.vue index 3af0a9c..87d7e75 100644 --- a/pages_tool/ai-chat/components/ai-chat-search.vue +++ b/pages_tool/ai-chat/components/ai-chat-search.vue @@ -263,7 +263,10 @@ export default { // 搜索入口按钮 .search-entrance { position: absolute; - top: 44rpx; + /* 与新对话按钮垂直居中对齐: + .chat-topbar padding-top 16rpx + 按钮高 52rpx => 按钮中心 42rpx, + 本按钮 icon-only 高 56rpx, 故 top = 42 - 56/2 = 14rpx */ + top: 14rpx; right: 16rpx; z-index: 10; display: flex;