diff --git a/.vscode/launch.json b/.vscode/launch.json new file mode 100644 index 0000000..39a8bad --- /dev/null +++ b/.vscode/launch.json @@ -0,0 +1,15 @@ +{ + // 使用 IntelliSense 了解相关属性。 + // 悬停以查看现有属性的描述。 + // 欲了解更多信息,请访问: https://go.microsoft.com/fwlink/?linkid=830387 + "version": "0.2.0", + "configurations": [ + { + "type": "chrome", + "request": "launch", + "name": "针对 localhost 启动 Chrome", + "url": "http://localhost:8080", + "webRoot": "${workspaceFolder}" + } + ] +} \ No newline at end of file diff --git a/web/ai-assistant.css b/web/ai-assistant.css new file mode 100644 index 0000000..0f8f2c4 --- /dev/null +++ b/web/ai-assistant.css @@ -0,0 +1,108 @@ + /* 全局样式 */ + body { + font-family: Arial, sans-serif; + background-color: #f5f5f5; /* 浅灰色背景 */ + margin: 0; + padding: 0; + display: flex; + justify-content: center; + align-items: center; + height: 100vh; + } + + /* 容器样式 */ + .chat-container { + background-color: #ffffff; /* 白色背景 */ + border-radius: 15px; + box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); + width: 90%; + max-width: 500px; + height: 80vh; + display: flex; + flex-direction: column; + overflow: hidden; + } + + /* 标题栏样式 */ + .header { + background-color: #000000; /* 蓝色标题栏 */ + color: #ffffff; + text-align: center; + padding: 15px; + font-size: 20px; + font-weight: bold; + border-top-left-radius: 15px; + border-top-right-radius: 15px; + } + + /* 对话内容区域样式 */ + .chat-box { + flex: 1; + padding: 15px; + overflow-y: auto; + border-bottom: 1px solid #ddd; + } + + /* 用户消息样式 */ + .user-message { + text-align: right; + margin-bottom: 10px; + } + + .user-message .message { + display: inline-block; + background-color: #cad4ff; /* 绿色背景 */ + color: #000; + padding: 10px 15px; + border-radius: 15px; + max-width: 70%; + } + + /* AI消息样式 */ + .ai-message { + text-align: left; + margin-bottom: 10px; + } + + .ai-message .message { + display: inline-block; + background-color: #ececec; /* 灰色背景 */ + color: #000; + padding: 10px 15px; + border-radius: 15px; + max-width: 70%; + } + + /* 输入区域样式 */ + .input-area { + display: flex; + padding: 10px; + background-color: #f9f9f9; + border-bottom-left-radius: 15px; + border-bottom-right-radius: 15px; + } + + .input-area input { + flex: 1; + padding: 10px; + border: 1px solid #ddd; + border-radius: 25px; + font-size: 16px; + outline: none; + } + + .input-area button { + background-color: #000000; /* 蓝色按钮 */ + color: #ffffff; + border: none; + padding: 10px 15px; + margin-left: 10px; + border-radius: 25px; + cursor: pointer; + font-size: 16px; + transition: background-color 0.3s ease; + } + + .input-area button:hover { + background-color: #0d47a1; /* 深蓝色按钮 */ + } \ No newline at end of file diff --git a/web/ai-assistant.html b/web/ai-assistant.html new file mode 100644 index 0000000..7fec89b --- /dev/null +++ b/web/ai-assistant.html @@ -0,0 +1,30 @@ + + +
+ + +