From 93bf65eb65fed40e16521ae53af58ef8b7757f7d Mon Sep 17 00:00:00 2001 From: duanshuwen Date: Tue, 14 Oct 2025 22:15:54 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E9=A6=96=E9=A1=B5=E6=AC=A2=E8=BF=8E?= =?UTF-8?q?=E8=AF=AD=E7=BB=84=E4=BB=B6=E5=B8=83=E5=B1=80=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/chat/ChatMainList/index.vue | 241 ++++++++---------- .../chat/ChatMainList/styles/index.scss | 108 +------- .../components/chat/ChatMoreTips/index.vue | 17 +- .../chat/ChatMoreTips/styles/index.scss | 35 +-- .../components/chat/ChatTopBgImg/index.vue | 9 - .../chat/ChatTopBgImg/styles/index.scss | 11 - .../components/chat/ChatTopWelcome/index.vue | 76 +++--- .../chat/ChatTopWelcome/styles/index.scss | 29 +-- src/pages/index/index.vue | 2 +- src/static/scss/flex.scss | 16 ++ src/static/scss/font-family.scss | 4 + src/static/scss/index.scss | 2 +- src/static/scss/padding.scss | 12 + .../{white-scape.scss => white-space.scss} | 2 +- 14 files changed, 212 insertions(+), 352 deletions(-) delete mode 100644 src/pages/index/components/chat/ChatTopBgImg/index.vue delete mode 100644 src/pages/index/components/chat/ChatTopBgImg/styles/index.scss rename src/static/scss/{white-scape.scss => white-space.scss} (53%) diff --git a/src/pages/index/components/chat/ChatMainList/index.vue b/src/pages/index/components/chat/ChatMainList/index.vue index 2309fab..afea69a 100644 --- a/src/pages/index/components/chat/ChatMainList/index.vue +++ b/src/pages/index/components/chat/ChatMainList/index.vue @@ -1,145 +1,122 @@ - - + + + + + + + @@ -157,13 +134,11 @@ import { import { WSS_URL } from "@/request/base/baseUrl"; import { MessageRole, MessageType, CompName } from "@/model/ChatModel"; import ChatTopWelcome from "../ChatTopWelcome/index.vue"; -import ChatTopBgImg from "../ChatTopBgImg/index.vue"; import ChatTopNavBar from "../ChatTopNavBar/index.vue"; import ChatCardAI from "../ChatCardAi/index.vue"; import ChatCardMine from "../ChatCardMine/index.vue"; import ChatCardOther from "../ChatCardOther/index.vue"; import ChatQuickAccess from "../ChatQuickAccess/index.vue"; -import ChatMoreTips from "../ChatMoreTips/index.vue"; import ChatInputArea from "../ChatInputArea/index.vue"; import QuickBookingComponent from "../../module/QuickBookingComponent/index.vue"; import DiscoveryCardComponent from "../../module/DiscoveryCardComponent/index.vue"; diff --git a/src/pages/index/components/chat/ChatMainList/styles/index.scss b/src/pages/index/components/chat/ChatMainList/styles/index.scss index fa0f759..79ea66d 100644 --- a/src/pages/index/components/chat/ChatMainList/styles/index.scss +++ b/src/pages/index/components/chat/ChatMainList/styles/index.scss @@ -1,106 +1,4 @@ -.chat-container { - width: 100vw; - height: 100vh; - background-color: #e9f3f7; - - display: flex; - flex-direction: column; - overflow: hidden !important; - position: relative; - /* 确保在键盘弹起时布局正确 */ - box-sizing: border-box; - - .chat-container-bg { - position: fixed; - top: 0; - left: 0; - right: 0; - z-index: 0; - height: 270px; - background: linear-gradient(180deg, #42adf9 0%, #6cd1ff 51%, #e9f3f7 99%); - } - - .chat-content { - width: 100vw; - display: flex; - flex-direction: column; - flex: 1; - min-height: 0; - z-index: 1; - overflow: hidden; - } - - .chat-container-top-bannar { - width: 100vw; - flex-shrink: 0; - touch-action: none; - } - - .area-msg-list { - width: 100vw; - flex: 1; - overflow-y: auto; - min-height: 0; - height: 0; - padding: 4px 0 0; - overscroll-behavior: contain; /* 阻止滚动穿透 */ - -webkit-overflow-scrolling: touch; - - display: flex; - flex-direction: column; - - .message-item-ai { - display: flex; - justify-content: flex-start; - } - - .message-item-mine { - display: flex; - justify-content: flex-end; - } - - .message-item-other { - display: flex; - justify-content: center; - } - } -} - -.footer-area { - width: 100vw; - flex-shrink: 0; - padding: 4px 0 20px 0; /* 直接设置20px底部安全距离 */ - background-color: #e9f3f7; - touch-action: pan-x; - overflow-x: auto; - overflow-y: hidden; - min-height: fit-content; - /* 安卓键盘适配 - 使用相对定位配合adjustPan */ - position: relative; - z-index: 1; - transition: padding-bottom 0.3s ease; - /* 确保输入区域始终可见 */ - // transform: translateZ(0); - // -webkit-transform: translateZ(0); -} - -// 打字机光标闪烁动画 -.typing-cursor { - display: inline-block; - color: #42adf9; - font-weight: bold; - font-size: 1.2em; - animation: blink 1s infinite; - margin-left: 2px; -} - -@keyframes blink { - 0%, - 50% { - opacity: 1; - } - 51%, - 100% { - opacity: 0; - } +.footer { + height: 118px; + // touch-action: pan-x; } diff --git a/src/pages/index/components/chat/ChatMoreTips/index.vue b/src/pages/index/components/chat/ChatMoreTips/index.vue index 825fd2b..4b2c3ee 100644 --- a/src/pages/index/components/chat/ChatMoreTips/index.vue +++ b/src/pages/index/components/chat/ChatMoreTips/index.vue @@ -1,17 +1,17 @@