feat: 全局接入 Dify 智能客服悬浮窗
This commit is contained in:
@ -9,5 +9,34 @@
|
||||
<body>
|
||||
<div id="app"></div>
|
||||
<script type="module" src="/src/main.ts"></script>
|
||||
<script>
|
||||
window.difyChatbotConfig = {
|
||||
token: 'Zp6B44AgCUPKprFG',
|
||||
baseUrl: 'http://172.16.0.198:8080',
|
||||
inputs: {},
|
||||
systemVariables: {},
|
||||
userVariables: {},
|
||||
};
|
||||
</script>
|
||||
<script
|
||||
src="http://172.16.0.198:8080/embed.min.js"
|
||||
id="Zp6B44AgCUPKprFG"
|
||||
defer>
|
||||
</script>
|
||||
<style>
|
||||
/* 修改悬浮按钮的颜色,使其与系统的主题蓝(如新增按钮)完全一致 */
|
||||
#dify-chatbot-bubble-button {
|
||||
background-color: #409EFF !important;
|
||||
box-shadow: 0 4px 12px rgba(64, 158, 255, 0.4) !important; /* 增加同色系发光投影,质感更好 */
|
||||
}
|
||||
|
||||
/* 调整聊天窗口的尺寸和阴影,使其更贴合现代 UI */
|
||||
#dify-chatbot-bubble-window {
|
||||
width: 28rem !important; /* 稍微加宽一点,文字展示更舒服 */
|
||||
height: 42rem !important; /* 稍微加高一点 */
|
||||
border-radius: 12px !important; /* 更圆润的边角 */
|
||||
box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12) !important; /* 更柔和的高级阴影 */
|
||||
}
|
||||
</style>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user