- 已收到您的问题:"${msg}",我们会尽快回复!
+
+
🤖
+
+ 已收到您的问题:"${safeMsg}",我们会尽快回复!
`);
chatContent.scrollTop = chatContent.scrollHeight;
}, 800);
};
- sendBtn.onclick = sendMessage;
- chatInput.onkeydown = (e) => e.key === 'Enter' && sendMessage();
- console.log('纯前端聊天窗口创建完成');
+ sendBtn.onclick = sendMessage;
+ chatInput.onkeydown = (e) => {
+ if (e.key === 'Enter') {
+ e.preventDefault();
+ sendMessage();
+ }
+ };
+
+ console.log('响应式智能客服窗口创建完成');
},
- /**
- * 原逻辑(授权/登录/分享等)
- */
getAuthInfo() {
// #ifdef H5
if (this.$util.isWeiXin()) {
@@ -355,12 +431,15 @@
@import './common/css/iconfont.css';
@import './common/css/icondiy.css';
@import './common/css/icon/extend.css';
+
page {
background: #f4f6fa;
}
body {
padding-bottom: 80px !important;
}
+
+ /* 聊天窗口滚动条美化 */
#independent-chat-window div::-webkit-scrollbar {
width: 4px;
}
@@ -368,4 +447,17 @@
background: #ddd;
border-radius: 2px;
}
+
+ /* 彩虹动画 */
+ @keyframes rainbowPulse {
+ 0% { background-position: 0% 50%; }
+ 50% { background-position: 100% 50%; }
+ 100% { background-position: 0% 50%; }
+ }
+
+ /* 强制固定定位,防止被其他样式干扰 */
+ #independent-chat-btn,
+ #independent-chat-window {
+ position: fixed !important;
+ }
\ No newline at end of file
diff --git a/components/hover-nav/hover-nav.vue b/components/hover-nav/hover-nav.vue
index 64fbeac..7579292 100644
--- a/components/hover-nav/hover-nav.vue
+++ b/components/hover-nav/hover-nav.vue
@@ -1,213 +1,188 @@
-
-
-
-
-
-
-
- 🤖
-
-
- {{ unreadCount > 99 ? '99+' : unreadCount }}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/pages/index/index.vue b/pages/index/index.vue
index e0828e4..e863f2f 100644
--- a/pages/index/index.vue
+++ b/pages/index/index.vue
@@ -122,7 +122,7 @@
-
+
From 2416eab34fc318a92df6c2cb10784d90d6977aac Mon Sep 17 00:00:00 2001
From: jinhhanhan <1683105490@qq.com>
Date: Fri, 5 Dec 2025 17:12:14 +0800
Subject: [PATCH 3/3] =?UTF-8?q?chore:=E5=8A=A0=E4=BA=86dify?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
pages/dify-chat/dify-chat.vue | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
create mode 100644 pages/dify-chat/dify-chat.vue
diff --git a/pages/dify-chat/dify-chat.vue b/pages/dify-chat/dify-chat.vue
new file mode 100644
index 0000000..f00cf88
--- /dev/null
+++ b/pages/dify-chat/dify-chat.vue
@@ -0,0 +1,20 @@
+
+
+
+
+
+
+
+
+
\ No newline at end of file