mirror of
https://github.com/lWolvesl/antigravity-usage-monitor.git
synced 2026-11-26 17:09:28 +08:00
refactor(panel): extract sqlite/wire primitives, localize charts & structured status, and unify overlay/mock-dom (P2)
This commit is contained in:
@@ -309,14 +309,16 @@ export const ContextWindowWidget = defineComponent({
|
||||
if (interactiveInspector) {
|
||||
patchAttr(ctxInspectorBar, 'hidden', !hasSubagents);
|
||||
if (hasSubagents && ctxAgent) {
|
||||
const rawActiveBadge = aggregated?.activeAgentBadge || '主';
|
||||
const activeBadgeText = isEnglishLocale()
|
||||
? rawActiveBadge === '主'
|
||||
? t('fmt.mainBadge')
|
||||
: rawActiveBadge
|
||||
.replace(/^子(\d+)$/, (_, n) => t('fmt.subBadge', { index: n }))
|
||||
.replace(/^旁(\d+)$/, (_, n) => t('fmt.sideBadge', { index: n }))
|
||||
: rawActiveBadge;
|
||||
const activeBadgeText = formatAgentBadgeText({
|
||||
agentKind:
|
||||
aggregated?.activeAgentKind ||
|
||||
(!aggregated?.activeAgentId || aggregated.activeAgentId === 'main'
|
||||
? 'main'
|
||||
: 'subagent'),
|
||||
agentOrdinal: Number(aggregated?.activeAgentOrdinal || 0),
|
||||
isMain: !aggregated?.activeAgentId || aggregated.activeAgentId === 'main',
|
||||
badgeText: aggregated?.activeAgentBadge,
|
||||
});
|
||||
|
||||
const pillItems = [
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user