优化: i18n硬编码清扫(8文件20+处中文字符串替为i18n)
- ToolCard: 已等待 → aiTool.waitTime - ErrorBoundary: 堆栈详情 → error.stackDetails - TopBar: 10处硬编码(tooltip+section标签+单位) → aiChat.* keys - FileExplorer: 4处工程操作title → fileExplorer.* - Tasks: 快捷菜单4处 → tasks.* - EnrichmentPanel: 取消关联 → aiChat.enrichmentDismiss - PlanProgress: 复用已有 aiChat.conflictsPending - WorkflowDagDisplay: 删除中文fallback(已有i18n key) - vue-tsc + vite build 通过
This commit is contained in:
@@ -113,7 +113,7 @@
|
||||
<div class="ai-bottom-tools-right">
|
||||
<!-- 目标计数 -->
|
||||
<div v-if="goals.length" class="ai-goals-inline">
|
||||
<span class="ai-goals-inline-badge ai-tool-badge" @click="goalsExpanded = !goalsExpanded" title="查看目标">
|
||||
<span class="ai-goals-inline-badge ai-tool-badge" @click="goalsExpanded = !goalsExpanded" :title="$t('aiChat.viewGoals')">
|
||||
<svg width="9" height="9" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"/><circle cx="12" cy="12" r="6"/><circle cx="12" cy="12" r="2"/></svg>
|
||||
{{ goals.length }}
|
||||
</span>
|
||||
@@ -126,7 +126,7 @@
|
||||
</div>
|
||||
<!-- 历史消息 -->
|
||||
<div v-if="historyMsgs.length" class="ai-history-inline">
|
||||
<span class="ai-history-inline-badge ai-tool-badge" @click="historyExpanded = !historyExpanded" title="查看历史消息">
|
||||
<span class="ai-history-inline-badge ai-tool-badge" @click="historyExpanded = !historyExpanded" :title="$t('aiChat.viewHistory')">
|
||||
<svg width="9" height="9" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M12 8v4l3 3m6-3a9 9 0 11-18 0 9 9 0 0118 0z"/></svg>
|
||||
{{ historyMsgs.length }}
|
||||
</span>
|
||||
@@ -140,44 +140,44 @@
|
||||
</div>
|
||||
<!-- 上下文摘要 -->
|
||||
<div v-if="summaryMsgs.length" class="ai-summary-inline">
|
||||
<span class="ai-summary-inline-badge ai-tool-badge" @click="summaryExpanded = !summaryExpanded" title="查看上下文摘要">
|
||||
<span class="ai-summary-inline-badge ai-tool-badge" @click="summaryExpanded = !summaryExpanded" :title="$t('aiChat.viewSummary')">
|
||||
<svg width="9" height="9" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M4 6h16M4 12h16M4 18h12"/></svg>
|
||||
{{ summaryMsgs.length }}
|
||||
</span>
|
||||
<div v-if="summaryExpanded" class="ai-summary-inline-list">
|
||||
<div v-for="(s, i) in summaryMsgs" :key="i" class="ai-summary-inline-item" @click="scrollToMessage(s.id)">
|
||||
<span class="ai-summary-label">{{ $t('aiChat.compressedSummaryLabel') || '上下文摘要' }} #{{ summaryMsgs.length - i }}</span>
|
||||
<span class="ai-summary-label">{{ $t('aiChat.compressedSummaryLabel') }} #{{ summaryMsgs.length - i }}</span>
|
||||
<p class="ai-summary-preview">{{ s.text }}</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- L3 完整上下文 -->
|
||||
<div v-if="contextInfo.goals.length || contextInfo.summaryCount > 0" class="ai-context-inline">
|
||||
<span class="ai-context-inline-badge ai-tool-badge" @click="contextExpanded = !contextExpanded" title="查看 AI 上下文">
|
||||
<span class="ai-context-inline-badge ai-tool-badge" @click="contextExpanded = !contextExpanded" :title="$t('aiChat.viewContext')">
|
||||
<svg width="9" height="9" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"/><path d="M12 16v-4"/><circle cx="12" cy="8" r="1" fill="currentColor"/></svg>
|
||||
</span>
|
||||
<div v-if="contextExpanded" class="ai-context-inline-list">
|
||||
<!-- 系统提示 -->
|
||||
<div class="ai-context-section">
|
||||
<div class="ai-context-section-title">系统提示</div>
|
||||
<div class="ai-context-section-title">{{ $t('aiChat.contextSystemPrompt') }}</div>
|
||||
<div class="ai-context-section-body">
|
||||
<div class="ai-context-row">
|
||||
<span class="ai-context-label">目标({{ contextInfo.goals.length }})</span>
|
||||
<span class="ai-context-value">{{ contextInfo.goals.join('; ') || '无' }}</span>
|
||||
</div>
|
||||
<div class="ai-context-row">
|
||||
<span class="ai-context-label">环境</span>
|
||||
<span class="ai-context-label">{{ $t('aiChat.contextEnvironment') }}</span>
|
||||
<span class="ai-context-value">{{ contextInfo.osInfo }}</span>
|
||||
</div>
|
||||
<div class="ai-context-row">
|
||||
<span class="ai-context-label">压缩摘要</span>
|
||||
<span class="ai-context-value">{{ contextInfo.summaryCount }} 条</span>
|
||||
<span class="ai-context-label">{{ $t('aiChat.contextCompressedSummary') }}</span>
|
||||
<span class="ai-context-value">{{ contextInfo.summaryCount }} {{ $t('aiChat.contextCountUnit') }}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 增强上下文 -->
|
||||
<div class="ai-context-section">
|
||||
<div class="ai-context-section-title">增强上下文</div>
|
||||
<div class="ai-context-section-title">{{ $t('aiChat.contextEnrichment') }}</div>
|
||||
<div class="ai-context-section-body">
|
||||
<div class="ai-context-row">
|
||||
<span class="ai-context-label">@项目</span>
|
||||
|
||||
Reference in New Issue
Block a user