diff --git a/ui/src/assets/iconfont.js b/ui/src/assets/iconfont.js index 6eb9b454743..d72c63cb6a8 100644 --- a/ui/src/assets/iconfont.js +++ b/ui/src/assets/iconfont.js @@ -1 +1 @@ -window._iconfont_svg_string_5200172='',(h=>{var a=(l=(l=document.getElementsByTagName("script"))[l.length-1]).getAttribute("data-injectcss"),l=l.getAttribute("data-disable-injectsvg");if(!l){var o,v,t,i,c,d=function(a,l){l.parentNode.insertBefore(a,l)};if(a&&!h.__iconfont__svg__cssinject__){h.__iconfont__svg__cssinject__=!0;try{document.write("")}catch(a){console&&console.log(a)}}o=function(){var a,l=document.createElement("div");l.innerHTML=h._iconfont_svg_string_5200172,(l=l.getElementsByTagName("svg")[0])&&(l.setAttribute("aria-hidden","true"),l.style.position="absolute",l.style.width=0,l.style.height=0,l.style.overflow="hidden",l=l,(a=document.body).firstChild?d(l,a.firstChild):a.appendChild(l))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(o,0):(v=function(){document.removeEventListener("DOMContentLoaded",v,!1),o()},document.addEventListener("DOMContentLoaded",v,!1)):document.attachEvent&&(t=o,i=h.document,c=!1,m(),i.onreadystatechange=function(){"complete"==i.readyState&&(i.onreadystatechange=null,e())})}function e(){c||(c=!0,t())}function m(){try{i.documentElement.doScroll("left")}catch(a){return void setTimeout(m,50)}e()}})(window); \ No newline at end of file +window._iconfont_svg_string_5200172='',(h=>{var a=(l=(l=document.getElementsByTagName("script"))[l.length-1]).getAttribute("data-injectcss"),l=l.getAttribute("data-disable-injectsvg");if(!l){var o,v,t,i,c,d=function(a,l){l.parentNode.insertBefore(a,l)};if(a&&!h.__iconfont__svg__cssinject__){h.__iconfont__svg__cssinject__=!0;try{document.write("")}catch(a){console&&console.log(a)}}o=function(){var a,l=document.createElement("div");l.innerHTML=h._iconfont_svg_string_5200172,(l=l.getElementsByTagName("svg")[0])&&(l.setAttribute("aria-hidden","true"),l.style.position="absolute",l.style.width=0,l.style.height=0,l.style.overflow="hidden",l=l,(a=document.body).firstChild?d(l,a.firstChild):a.appendChild(l))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(o,0):(v=function(){document.removeEventListener("DOMContentLoaded",v,!1),o()},document.addEventListener("DOMContentLoaded",v,!1)):document.attachEvent&&(t=o,i=h.document,c=!1,m(),i.onreadystatechange=function(){"complete"==i.readyState&&(i.onreadystatechange=null,e())})}function e(){c||(c=!0,t())}function m(){try{i.documentElement.doScroll("left")}catch(a){return void setTimeout(m,50)}e()}})(window); \ No newline at end of file diff --git a/ui/src/components/COMPONENT_README.md b/ui/src/components/COMPONENT_README.md index 863907d8a8e..786c11d7491 100644 --- a/ui/src/components/COMPONENT_README.md +++ b/ui/src/components/COMPONENT_README.md @@ -234,6 +234,9 @@ Element Plus 的 `v-infinite-scroll`。组件通过 `v-model` 管理已经加载 不属于全局组件。内部使用 `el-scrollbar`,父级需要提供受限高度或纵向 Flex 剩余空间, 外层不再额外包裹消息滚动容器。 +内容留白通过 `contentClass` 设置,例如 `content-class="p-4"`;该类作用于滚动区域内的内容层, +同时覆盖消息和空状态,使滚动条保持贴近容器边缘。`class` 仍用于组件外壳布局。 + 传入 `loading`、`hasMore`、`count` 和 `loadMore: () => Promise`。页码、请求和 历史数据前插由调用方维护;`loadMore` 在历史数据更新后返回 `true`,失败或没有新增数据返回 `false`。组件不请求首页;首页由调用方加载,首次出现数据时自动定位到底部,距顶部 60px 时 diff --git a/ui/src/conversation-panel/components/content/items/reasoning.vue b/ui/src/conversation-panel/components/content/items/reasoning.vue index 4ed985f1a1c..7a38d15a605 100644 --- a/ui/src/conversation-panel/components/content/items/reasoning.vue +++ b/ui/src/conversation-panel/components/content/items/reasoning.vue @@ -31,7 +31,9 @@ watch( - 思考中 + + {{ content.status === 'RUNNING' ? '思考中' : '思考完成' }} + {{ content.content }} diff --git a/ui/src/conversation-panel/components/header/chat/index.vue b/ui/src/conversation-panel/components/header/chat/index.vue index f2ee4561630..e63f5c4eefb 100644 --- a/ui/src/conversation-panel/components/header/chat/index.vue +++ b/ui/src/conversation-panel/components/header/chat/index.vue @@ -1,39 +1,5 @@ - - - - - - - - - - - - - - - - - - - - {{ list.appInfo.value.name }} - {{ list.currentConversation.value?.abstract || '新对话' }} - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + {{ list.currentConversation.value?.abstract || '新建对话' }} + + + + + + + + + + diff --git a/ui/src/conversation-panel/components/header/portal/index.vue b/ui/src/conversation-panel/components/header/portal/index.vue new file mode 100644 index 00000000000..93df87f6115 --- /dev/null +++ b/ui/src/conversation-panel/components/header/portal/index.vue @@ -0,0 +1,56 @@ + + + + + + + + + + + + + + + + + + + + {{ list.currentConversation.value?.abstract || '新建对话' }} + + + + {{ list.appInfo.value.name }} + + + + + + + + + + + + diff --git a/ui/src/conversation-panel/components/log-message-list/index.vue b/ui/src/conversation-panel/components/log-message-list/index.vue index 1156257b799..7eb9d6662f5 100644 --- a/ui/src/conversation-panel/components/log-message-list/index.vue +++ b/ui/src/conversation-panel/components/log-message-list/index.vue @@ -8,9 +8,10 @@ const { messages, loading, hasMore, loadMore } = useLogMessageListStore() - + - + + diff --git a/ui/src/conversation-panel/components/message-list/index.vue b/ui/src/conversation-panel/components/message-list/index.vue index 3a6da4c4226..7b50ceec046 100644 --- a/ui/src/conversation-panel/components/message-list/index.vue +++ b/ui/src/conversation-panel/components/message-list/index.vue @@ -16,16 +16,17 @@ onBeforeUnmount(offProgress) - + - + + - + @@ -41,24 +42,6 @@ onBeforeUnmount(offProgress) diff --git a/ui/src/conversation-panel/core/reverse-infinite-scroll/index.ts b/ui/src/conversation-panel/core/reverse-infinite-scroll/index.ts index f63486b0c26..4b6bb13bdc1 100644 --- a/ui/src/conversation-panel/core/reverse-infinite-scroll/index.ts +++ b/ui/src/conversation-panel/core/reverse-infinite-scroll/index.ts @@ -3,6 +3,7 @@ import type { ScrollbarInstance } from 'element-plus' import { Scroll } from '../scroll' export interface ReverseInfiniteScrollProps { + contentClass?: string loading: boolean hasMore: boolean count: number diff --git a/ui/src/conversation-panel/core/reverse-infinite-scroll/index.vue b/ui/src/conversation-panel/core/reverse-infinite-scroll/index.vue index d2998c5d6df..98eafdb2243 100644 --- a/ui/src/conversation-panel/core/reverse-infinite-scroll/index.vue +++ b/ui/src/conversation-panel/core/reverse-infinite-scroll/index.vue @@ -16,7 +16,7 @@ defineExpose({ scrollToBottom, followBottom }) - + diff --git a/ui/src/conversation-panel/main/portal-chat-panel/index.vue b/ui/src/conversation-panel/main/portal-chat-panel/index.vue index 14aaf31c4c4..5b2484191e3 100644 --- a/ui/src/conversation-panel/main/portal-chat-panel/index.vue +++ b/ui/src/conversation-panel/main/portal-chat-panel/index.vue @@ -1,5 +1,5 @@ + + + + + + + + + + + + + + + diff --git a/ui/src/views/home/components/ranking/RankingCard.vue b/ui/src/views/home/components/ranking/RankingCard.vue index 015c355260a..bcb408b3d9d 100644 --- a/ui/src/views/home/components/ranking/RankingCard.vue +++ b/ui/src/views/home/components/ranking/RankingCard.vue @@ -47,7 +47,7 @@ function getRecordPercentage(record: HomeRankingRecord) { - + {{ kind === 'questions' ? numberFormat(record.chat_record_count) : formatTokenNumber(record.total_tokens ?? 0) }}
+
{{ kind === 'questions' ? numberFormat(record.chat_record_count) : formatTokenNumber(record.total_tokens ?? 0) }}