优化: 前端DRY收敛与命名对齐

审批等待格式化与阈值沉 utils/time 正典
相对时间阶梯三套收敛 formatRelative 参数化
灵感状态表沉 constants,透传通道退役
aggText/clearOwn 等命名对齐,IPC 参数名统一 conversation_id
This commit is contained in:
lxy
2026-10-01 19:35:20 +08:00
parent 6ef15a0940
commit 0560137840
16 changed files with 111 additions and 97 deletions
+2 -2
View File
@@ -52,7 +52,7 @@ import { ref, computed, watch, nextTick, onMounted, onBeforeUnmount } from 'vue'
import { useI18n } from 'vue-i18n'
import ToolCard from './ToolCard.vue'
import { listen, type UnlistenFn } from '@tauri-apps/api/event'
import { aggregateCalls, aggText } from '@/composables/ai/useTurnTrace'
import { aggregateCalls, turnSummaryText } from '@/composables/ai/useTurnTrace'
import type { AiToolCallInfo } from '@/api/types'
// useI18n needed for $t() in template (collapseAll / expandAll) + groupDisplayName(i18n key)
@@ -230,7 +230,7 @@ function groupDisplayName(group: ToolCallGroup): string {
/** 分组聚合行文案:「N 次调用 · 成功 x 失败 y」(零值项省略;与单卡状态点同源 isToolFailure 判定) */
function groupAggText(group: ToolCallGroup): string {
return aggText(aggregateCalls(group.calls))
return turnSummaryText(aggregateCalls(group.calls))
}
/**