|
@@ -20,6 +20,10 @@ const plugins: Array<MarkdownPlugin<any>> = [EChartsPlugin(), ToolsLoadingPlugin
|
|
|
// 消息列表
|
|
|
const messages = ref<Message[]>([])
|
|
|
|
|
|
+watch(messages,(newVal)=> {
|
|
|
+ console.log(newVal.map(it=>it.render_content))
|
|
|
+})
|
|
|
+
|
|
|
// 输入框内容
|
|
|
const inputMessage = ref('')
|
|
|
const messagesContainer = ref<HTMLElement>()
|
|
@@ -593,7 +597,7 @@ const maxPages = 100
|
|
|
<el-dropdown-menu>
|
|
|
<el-dropdown-item class="settings-item">
|
|
|
<div class="settings-row">
|
|
|
- <span class="settings-label">显示工具调用</span>
|
|
|
+ <span class="settings-label">新对话自动记录工具调用</span>
|
|
|
<el-switch v-model="showToolCalls" size="small"/>
|
|
|
</div>
|
|
|
</el-dropdown-item>
|
|
@@ -759,32 +763,57 @@ const maxPages = 100
|
|
|
</div>
|
|
|
|
|
|
<!-- 空状态页面 -->
|
|
|
-
|
|
|
<div v-else class="empty-content">
|
|
|
- <!-- 主图标 -->
|
|
|
- <div class="empty-icon">
|
|
|
- <el-icon :size="80" color="#d1d5db">
|
|
|
- <ChatDotRound/>
|
|
|
- </el-icon>
|
|
|
+ <!-- 收藏页面空状态 -->
|
|
|
+ <div v-if="activeConversationId === -1" class="bookmark-empty">
|
|
|
+ <div class="empty-icon">
|
|
|
+ <el-icon :size="80" color="#f59e0b">
|
|
|
+ <StarFilled/>
|
|
|
+ </el-icon>
|
|
|
+ </div>
|
|
|
+ <div class="empty-text">
|
|
|
+ <h2 class="empty-title">暂无收藏消息</h2>
|
|
|
+ <p class="empty-description">您还没有收藏任何对话消息</p>
|
|
|
+ </div>
|
|
|
+ <div class="empty-tips">
|
|
|
+ <div class="tip-item">
|
|
|
+ <el-icon color="#409eff"><InfoFilled/></el-icon>
|
|
|
+ <span>在对话中点击 ⭐ 按钮即可收藏消息</span>
|
|
|
+ </div>
|
|
|
+ <div class="tip-item">
|
|
|
+ <el-icon color="#67c23a"><Search/></el-icon>
|
|
|
+ <span>收藏的消息支持关键词搜索</span>
|
|
|
+ </div>
|
|
|
+ <div class="tip-item">
|
|
|
+ <el-icon color="#e6a23c"><Collection/></el-icon>
|
|
|
+ <span>收藏消息会保存在云端,永不丢失</span>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
|
|
|
- <!-- 标题和描述 -->
|
|
|
- <div class="empty-text">
|
|
|
- <h2 class="empty-title">开始新的对话</h2>
|
|
|
- </div>
|
|
|
- <!-- 示例问题 -->
|
|
|
- <div class="example-questions">
|
|
|
- <h4>试试这些问题:</h4>
|
|
|
- <div class="question-tags">
|
|
|
- <el-tag class="question-tag" @click="inputMessage = '帮我查看设备运行状态和告警信息'" type="info">
|
|
|
- 帮我查看设备运行状态和告警信息
|
|
|
- </el-tag>
|
|
|
- <el-tag class="question-tag" @click="inputMessage = '分析用户权限配置和角色分配情况'" type="success">
|
|
|
- 分析用户权限配置和角色分配情况
|
|
|
- </el-tag>
|
|
|
- <el-tag class="question-tag" @click="inputMessage = '检查系统性能和在线用户统计'" type="warning">
|
|
|
- 检查系统性能和在线用户统计
|
|
|
- </el-tag>
|
|
|
+ <!-- 普通对话空状态 -->
|
|
|
+ <div v-else class="chat-empty">
|
|
|
+ <div class="empty-icon">
|
|
|
+ <el-icon :size="80" color="#d1d5db">
|
|
|
+ <ChatDotRound/>
|
|
|
+ </el-icon>
|
|
|
+ </div>
|
|
|
+ <div class="empty-text">
|
|
|
+ <h2 class="empty-title">开始新的对话</h2>
|
|
|
+ </div>
|
|
|
+ <div class="example-questions">
|
|
|
+ <h4>试试这些问题:</h4>
|
|
|
+ <div class="question-tags">
|
|
|
+ <el-tag class="question-tag" @click="inputMessage = '帮我查看设备运行状态和告警信息'" type="info">
|
|
|
+ 帮我查看设备运行状态和告警信息
|
|
|
+ </el-tag>
|
|
|
+ <el-tag class="question-tag" @click="inputMessage = '分析用户权限配置和角色分配情况'" type="success">
|
|
|
+ 分析用户权限配置和角色分配情况
|
|
|
+ </el-tag>
|
|
|
+ <el-tag class="question-tag" @click="inputMessage = '检查系统性能和在线用户统计'" type="warning">
|
|
|
+ 检查系统性能和在线用户统计
|
|
|
+ </el-tag>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|