mirror of
https://github.com/lWolvesl/antigravity-usage-monitor.git
synced 2026-11-27 01:19:25 +08:00
feat(panel): modularize 3-tab preferences, add model context windows, and optimize telemetry
- Refactor Preferences into decoupled General, Structure, and Other tabs with unified settings schema, factory reset, and trajectory cache rebuild endpoints - Extract standalone widget, metric, and step-table column registries to customize topbar/composer slots, hover popup modules, live overview layout, and step detail columns - Add bilingual zh-CN/en-US i18n dictionaries, theme accent presets, and font scale controls across Shadow DOM overlay and sidebar views - Support per-model host-advertised context window rules across App and IDE transports - Preserve CLEARED step generation timings, memoize per-poll model resolution, optimize LOESS sorted-x fitting, and update bilingual READMEs and test suites
This commit is contained in:
@@ -30,7 +30,7 @@ body {
|
||||
background: var(--surface-bg);
|
||||
color: var(--text-primary);
|
||||
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Roboto, sans-serif;
|
||||
font-size: 12.5px;
|
||||
font-size: var(--fs-body);
|
||||
line-height: 1.4;
|
||||
font-variant-numeric: tabular-nums;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
|
||||
@@ -57,7 +57,7 @@
|
||||
align-items: center;
|
||||
gap: 4px;
|
||||
padding: 2px 6px;
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
font-weight: 600;
|
||||
border-radius: var(--radius-xs);
|
||||
border: 1px solid color-mix(in srgb, var(--metric-ok) 32%, var(--border-hairline));
|
||||
@@ -154,7 +154,7 @@
|
||||
border: none;
|
||||
background: transparent;
|
||||
color: var(--text-secondary);
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
font-weight: 500;
|
||||
line-height: 1;
|
||||
border-radius: var(--radius-pill);
|
||||
@@ -181,7 +181,7 @@
|
||||
|
||||
.pill-tab-badge {
|
||||
margin-left: -2px;
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
opacity: 0.85;
|
||||
}
|
||||
|
||||
@@ -229,7 +229,7 @@
|
||||
color: var(--text-primary);
|
||||
border: none;
|
||||
border-radius: var(--radius-xs);
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
cursor: pointer;
|
||||
text-align: left;
|
||||
transition: background-color var(--dur-instant) var(--ease-fast);
|
||||
@@ -276,7 +276,7 @@
|
||||
border: none;
|
||||
background: transparent;
|
||||
color: var(--text-primary);
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
text-align: left;
|
||||
border-radius: var(--radius-xs);
|
||||
cursor: pointer;
|
||||
@@ -293,6 +293,15 @@
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.select-option.is-disabled {
|
||||
opacity: 0.42;
|
||||
cursor: not-allowed;
|
||||
}
|
||||
|
||||
.select-option.is-disabled:hover {
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
.select-option-text {
|
||||
flex: 1;
|
||||
min-width: 0;
|
||||
@@ -302,7 +311,7 @@
|
||||
}
|
||||
|
||||
.select-option-meta {
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
flex-shrink: 0;
|
||||
font-family: var(--font-mono);
|
||||
}
|
||||
@@ -406,7 +415,7 @@
|
||||
color: var(--text-primary);
|
||||
border: 1px solid var(--border-hairline);
|
||||
border-radius: var(--radius-xs);
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
@@ -436,7 +445,7 @@
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
font-weight: 600;
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
}
|
||||
|
||||
.dt-weekdays,
|
||||
@@ -448,7 +457,7 @@
|
||||
}
|
||||
|
||||
.dt-weekday {
|
||||
font-size: 10.5px;
|
||||
font-size: var(--fs-sm);
|
||||
color: var(--text-secondary);
|
||||
padding: 2px 0;
|
||||
}
|
||||
@@ -458,7 +467,7 @@
|
||||
border: none;
|
||||
background: transparent;
|
||||
color: var(--text-primary);
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
border-radius: var(--radius-xs);
|
||||
cursor: pointer;
|
||||
}
|
||||
@@ -484,7 +493,7 @@
|
||||
gap: var(--space-2);
|
||||
padding-top: var(--space-2);
|
||||
border-top: 1px solid var(--border-hairline);
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
}
|
||||
|
||||
.dt-time-controls {
|
||||
@@ -535,7 +544,7 @@
|
||||
border: none;
|
||||
background: transparent;
|
||||
color: var(--text-secondary);
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
border-radius: var(--radius-xs);
|
||||
cursor: pointer;
|
||||
transition:
|
||||
@@ -629,7 +638,7 @@
|
||||
}
|
||||
|
||||
.form-label {
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
font-weight: 500;
|
||||
color: var(--text-secondary);
|
||||
}
|
||||
@@ -646,7 +655,7 @@
|
||||
border: 1px solid var(--accent-primary);
|
||||
border-radius: var(--radius-xs);
|
||||
font-weight: 600;
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
cursor: pointer;
|
||||
transition: opacity var(--dur-instant) var(--ease-fast), transform var(--dur-instant) var(--ease-fast);
|
||||
}
|
||||
@@ -671,7 +680,7 @@
|
||||
border: 1px solid var(--border-strong);
|
||||
border-radius: var(--radius-xs);
|
||||
font-weight: 500;
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
cursor: pointer;
|
||||
transition: background-color var(--dur-instant) var(--ease-fast), border-color var(--dur-instant) var(--ease-fast), transform var(--dur-instant) var(--ease-fast);
|
||||
}
|
||||
@@ -705,7 +714,7 @@
|
||||
gap: 4px;
|
||||
height: 22px;
|
||||
padding: 0 7px;
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
font-weight: 600;
|
||||
border-radius: var(--radius-xs);
|
||||
border: 1px solid var(--accent-primary-border);
|
||||
@@ -745,7 +754,7 @@
|
||||
justify-content: center;
|
||||
height: 20px;
|
||||
padding: 0 6px;
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
font-weight: 500;
|
||||
color: var(--text-secondary);
|
||||
background: transparent;
|
||||
@@ -804,7 +813,7 @@
|
||||
justify-content: center;
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
font-size: 10.5px;
|
||||
font-size: var(--fs-sm);
|
||||
font-weight: 600;
|
||||
font-variant-numeric: tabular-nums;
|
||||
color: var(--text-secondary);
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
/* --- 1. 顶栏胶囊宿主容器 (Titlebar Capsule Host) --- */
|
||||
:host(.wm-capsule-host) {
|
||||
--ui-font-scale: 1;
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
@@ -326,6 +327,26 @@
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
/* 缓存命中率槽位(固定预占宽度 44px 居中对齐) */
|
||||
.wm-seg-cache {
|
||||
width: 44px;
|
||||
}
|
||||
|
||||
.wm-cache-text {
|
||||
width: 44px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
/* 会话总 Token 槽位(固定预占宽度 52px 居中对齐) */
|
||||
.wm-seg-tokens {
|
||||
width: 52px;
|
||||
}
|
||||
|
||||
.wm-tokens-text {
|
||||
width: 52px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.wm-cap-slot.tone-warn,
|
||||
.wm-cap-slot.tone-warn .wm-slot-text {
|
||||
color: var(--metric-warn);
|
||||
@@ -423,16 +444,24 @@
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
/* 四级响应式迟滞折叠(基于可见槽位次序 data-vis-rank 与分隔线次序 data-sep-for-rank 动态折叠) */
|
||||
/* 四级响应式迟滞折叠(基于可见槽位次序 data-vis-rank 1..5 与分隔线次序 data-sep-for-rank 动态折叠) */
|
||||
:host(.wm-capsule-host[data-layout="compact"]) .wm-cap-slot[data-vis-rank="3"],
|
||||
:host(.wm-capsule-host[data-layout="compact"]) .wm-sep[data-sep-for-rank="3"] {
|
||||
:host(.wm-capsule-host[data-layout="compact"]) .wm-cap-slot[data-vis-rank="4"],
|
||||
:host(.wm-capsule-host[data-layout="compact"]) .wm-cap-slot[data-vis-rank="5"],
|
||||
:host(.wm-capsule-host[data-layout="compact"]) .wm-sep[data-sep-for-rank="3"],
|
||||
:host(.wm-capsule-host[data-layout="compact"]) .wm-sep[data-sep-for-rank="4"],
|
||||
:host(.wm-capsule-host[data-layout="compact"]) .wm-sep[data-sep-for-rank="5"] {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
:host(.wm-capsule-host[data-layout="minimal"]) .wm-cap-slot[data-vis-rank="2"],
|
||||
:host(.wm-capsule-host[data-layout="minimal"]) .wm-cap-slot[data-vis-rank="3"],
|
||||
:host(.wm-capsule-host[data-layout="minimal"]) .wm-cap-slot[data-vis-rank="4"],
|
||||
:host(.wm-capsule-host[data-layout="minimal"]) .wm-cap-slot[data-vis-rank="5"],
|
||||
:host(.wm-capsule-host[data-layout="minimal"]) .wm-sep[data-sep-for-rank="2"],
|
||||
:host(.wm-capsule-host[data-layout="minimal"]) .wm-sep[data-sep-for-rank="3"],
|
||||
:host(.wm-capsule-host[data-layout="minimal"]) .wm-sep[data-sep-for-rank="4"],
|
||||
:host(.wm-capsule-host[data-layout="minimal"]) .wm-sep[data-sep-for-rank="5"],
|
||||
:host(.wm-capsule-host[data-layout="minimal"]) .wm-multi-label {
|
||||
display: none !important;
|
||||
}
|
||||
@@ -444,8 +473,12 @@
|
||||
|
||||
:host(.wm-capsule-host[data-layout="ring-only"]) .wm-cap-slot[data-vis-rank="2"],
|
||||
:host(.wm-capsule-host[data-layout="ring-only"]) .wm-cap-slot[data-vis-rank="3"],
|
||||
:host(.wm-capsule-host[data-layout="ring-only"]) .wm-cap-slot[data-vis-rank="4"],
|
||||
:host(.wm-capsule-host[data-layout="ring-only"]) .wm-cap-slot[data-vis-rank="5"],
|
||||
:host(.wm-capsule-host[data-layout="ring-only"]) .wm-sep[data-sep-for-rank="2"],
|
||||
:host(.wm-capsule-host[data-layout="ring-only"]) .wm-sep[data-sep-for-rank="3"],
|
||||
:host(.wm-capsule-host[data-layout="ring-only"]) .wm-sep[data-sep-for-rank="4"],
|
||||
:host(.wm-capsule-host[data-layout="ring-only"]) .wm-sep[data-sep-for-rank="5"],
|
||||
:host(.wm-capsule-host[data-layout="ring-only"]) .wm-cap-slot[data-vis-rank="1"] .wm-ctx-pct,
|
||||
:host(.wm-capsule-host[data-layout="ring-only"]) .wm-multi-label {
|
||||
display: none !important;
|
||||
@@ -469,7 +502,7 @@
|
||||
pointer-events: none;
|
||||
z-index: 2147483000;
|
||||
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Roboto, sans-serif;
|
||||
font-size: 12.5px;
|
||||
font-size: var(--fs-body);
|
||||
line-height: 1.4;
|
||||
font-variant-numeric: tabular-nums;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
@@ -609,6 +642,13 @@
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.wm-hover-widgets {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: var(--space-3);
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.wm-hover-update-bar {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@@ -618,7 +658,7 @@
|
||||
border-radius: var(--radius-xs);
|
||||
background: var(--accent-primary-soft);
|
||||
border: 1px solid var(--accent-primary-border);
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
line-height: 1.3;
|
||||
}
|
||||
|
||||
@@ -633,7 +673,7 @@
|
||||
|
||||
.wm-hover-update-hint {
|
||||
color: var(--text-secondary);
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
@@ -646,7 +686,7 @@
|
||||
}
|
||||
|
||||
.wm-hover-quota-foot {
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
padding-top: 2px;
|
||||
}
|
||||
|
||||
@@ -655,7 +695,7 @@
|
||||
align-items: center;
|
||||
height: 16px;
|
||||
padding: 0 5px;
|
||||
font-size: 10px;
|
||||
font-size: var(--fs-xs);
|
||||
font-weight: 600;
|
||||
color: var(--accent-primary);
|
||||
background: var(--accent-primary-soft);
|
||||
@@ -668,7 +708,7 @@
|
||||
align-items: center;
|
||||
height: 16px;
|
||||
padding: 0 4px;
|
||||
font-size: 10px;
|
||||
font-size: var(--fs-xs);
|
||||
font-weight: 600;
|
||||
color: var(--text-secondary);
|
||||
background: color-mix(in srgb, var(--text-primary) 7%, transparent);
|
||||
@@ -683,7 +723,7 @@
|
||||
}
|
||||
|
||||
.wm-task-metrics {
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
color: var(--text-secondary);
|
||||
white-space: nowrap;
|
||||
flex-shrink: 0;
|
||||
@@ -720,7 +760,7 @@
|
||||
}
|
||||
|
||||
.wm-multi-panel .live-task-title {
|
||||
font-size: 12.5px;
|
||||
font-size: var(--fs-body);
|
||||
}
|
||||
|
||||
.wm-multi-empty {
|
||||
@@ -730,7 +770,7 @@
|
||||
gap: var(--space-3);
|
||||
min-height: 36px;
|
||||
padding: 12px 2px 4px;
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
color: var(--text-secondary);
|
||||
}
|
||||
|
||||
|
||||
@@ -42,16 +42,30 @@
|
||||
);
|
||||
--border-strong: color-mix(in srgb, var(--border-hairline) 72%, var(--text-primary) 28%);
|
||||
|
||||
/* Typography Hierarchy */
|
||||
/* Typography Hierarchy & Scalable Font Tokens */
|
||||
--ui-font-scale: 1;
|
||||
--fs-2xs: calc(9.5px * var(--ui-font-scale, 1));
|
||||
--fs-xs: calc(10px * var(--ui-font-scale, 1));
|
||||
--fs-sm: calc(10.5px * var(--ui-font-scale, 1));
|
||||
--fs-md: calc(11px * var(--ui-font-scale, 1));
|
||||
--fs-base-sm: calc(11.5px * var(--ui-font-scale, 1));
|
||||
--fs-base: calc(12px * var(--ui-font-scale, 1));
|
||||
--fs-body: calc(12.5px * var(--ui-font-scale, 1));
|
||||
--fs-lg: calc(14.5px * var(--ui-font-scale, 1));
|
||||
--fs-hero: calc(17px * var(--ui-font-scale, 1));
|
||||
|
||||
--text-primary: var(--foreground, var(--vscode-foreground, var(--vscode-editor-foreground, hsl(215 22% 15%))));
|
||||
--text-secondary: var(--muted-foreground, var(--vscode-descriptionForeground, hsl(215 12% 44%)));
|
||||
--text-muted: color-mix(in srgb, var(--text-secondary) 74%, var(--surface-panel) 26%);
|
||||
--text-inverse: var(--surface-panel);
|
||||
--text-inverse: var(--user-accent-contrast, var(--surface-panel));
|
||||
|
||||
/* Semantic Telemetry Accents */
|
||||
--accent-primary: var(
|
||||
--primary,
|
||||
var(--vscode-textLink-foreground, var(--vscode-button-background, hsl(217 82% 51%)))
|
||||
--user-accent-primary,
|
||||
var(
|
||||
--primary,
|
||||
var(--vscode-textLink-foreground, var(--vscode-button-background, hsl(217 82% 51%)))
|
||||
)
|
||||
);
|
||||
--accent-primary-soft: color-mix(in srgb, var(--accent-primary) 13%, transparent);
|
||||
--accent-primary-border: color-mix(in srgb, var(--accent-primary) 38%, var(--border-hairline));
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
}
|
||||
|
||||
.cons-badge {
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
font-weight: 500;
|
||||
padding: 0;
|
||||
background: transparent;
|
||||
@@ -98,21 +98,21 @@
|
||||
}
|
||||
|
||||
.cons-hero-num {
|
||||
font-size: 17px;
|
||||
font-size: var(--fs-hero);
|
||||
font-weight: 700;
|
||||
color: var(--text-primary);
|
||||
letter-spacing: -0.02em;
|
||||
}
|
||||
|
||||
.cons-hero-cost {
|
||||
font-size: 17px;
|
||||
font-size: var(--fs-hero);
|
||||
font-weight: 700;
|
||||
color: var(--accent-primary);
|
||||
letter-spacing: -0.02em;
|
||||
}
|
||||
|
||||
.cons-hero-cache {
|
||||
font-size: 17px;
|
||||
font-size: var(--fs-hero);
|
||||
font-weight: 700;
|
||||
color: var(--ctx-cached);
|
||||
letter-spacing: -0.02em;
|
||||
@@ -132,7 +132,7 @@
|
||||
}
|
||||
|
||||
.cons-sub-label {
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
font-weight: 600;
|
||||
color: var(--text-primary);
|
||||
white-space: nowrap;
|
||||
@@ -140,7 +140,7 @@
|
||||
}
|
||||
|
||||
.cons-mid-num {
|
||||
font-size: 14.5px;
|
||||
font-size: var(--fs-lg);
|
||||
font-weight: 700;
|
||||
line-height: 1.25;
|
||||
color: var(--text-primary);
|
||||
@@ -168,7 +168,7 @@
|
||||
align-items: center;
|
||||
height: 20px;
|
||||
line-height: 20px;
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
font-weight: 600;
|
||||
color: var(--text-primary);
|
||||
}
|
||||
@@ -187,7 +187,7 @@
|
||||
height: 20px;
|
||||
line-height: 1;
|
||||
padding: 0 6px;
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
font-weight: 600;
|
||||
color: var(--metric-ok);
|
||||
background: color-mix(in srgb, var(--metric-ok) 11%, transparent);
|
||||
@@ -201,7 +201,7 @@
|
||||
align-items: center;
|
||||
height: 20px;
|
||||
line-height: 1;
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
font-weight: 500;
|
||||
color: var(--text-secondary);
|
||||
}
|
||||
@@ -211,7 +211,7 @@
|
||||
align-items: center;
|
||||
height: 20px;
|
||||
line-height: 1;
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
font-weight: 700;
|
||||
color: var(--text-primary);
|
||||
}
|
||||
@@ -611,7 +611,7 @@
|
||||
align-items: center;
|
||||
flex-wrap: wrap;
|
||||
gap: 4px 10px;
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
color: var(--text-secondary);
|
||||
}
|
||||
|
||||
@@ -712,6 +712,6 @@
|
||||
justify-content: center;
|
||||
gap: var(--space-4);
|
||||
padding-top: var(--space-2);
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
color: var(--text-secondary);
|
||||
}
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
font-weight: 600;
|
||||
color: var(--text-primary);
|
||||
flex: 1;
|
||||
@@ -47,7 +47,7 @@
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
color: var(--text-secondary);
|
||||
flex-shrink: 0;
|
||||
white-space: nowrap;
|
||||
@@ -69,7 +69,7 @@
|
||||
}
|
||||
|
||||
.quota-win-title {
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
font-weight: 500;
|
||||
color: var(--text-primary);
|
||||
white-space: nowrap;
|
||||
@@ -79,7 +79,7 @@
|
||||
.quota-win-usage {
|
||||
font-family: var(--font-mono);
|
||||
font-variant-numeric: tabular-nums;
|
||||
font-size: 10.5px;
|
||||
font-size: var(--fs-sm);
|
||||
font-weight: 400;
|
||||
color: var(--text-muted);
|
||||
white-space: nowrap;
|
||||
@@ -89,7 +89,7 @@
|
||||
}
|
||||
|
||||
.quota-win-meta {
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
@@ -130,7 +130,7 @@
|
||||
}
|
||||
|
||||
.live-task-title {
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
font-weight: 600;
|
||||
line-height: 1.45;
|
||||
color: var(--text-primary);
|
||||
@@ -158,7 +158,7 @@
|
||||
gap: 3px;
|
||||
height: 18px;
|
||||
padding: 0 6px;
|
||||
font-size: 10.5px;
|
||||
font-size: var(--fs-sm);
|
||||
font-weight: 600;
|
||||
color: var(--text-secondary);
|
||||
background: var(--surface-panel);
|
||||
@@ -208,7 +208,7 @@
|
||||
}
|
||||
|
||||
.live-activity-phase {
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
font-weight: 600;
|
||||
color: var(--text-primary);
|
||||
white-space: nowrap;
|
||||
@@ -216,7 +216,7 @@
|
||||
}
|
||||
|
||||
.live-activity-progress {
|
||||
font-size: 10.5px;
|
||||
font-size: var(--fs-sm);
|
||||
font-weight: 600;
|
||||
color: var(--accent-primary);
|
||||
background: var(--accent-primary-soft);
|
||||
@@ -227,13 +227,13 @@
|
||||
}
|
||||
|
||||
.live-activity-sep {
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
color: var(--text-muted);
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.live-activity-detail {
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
color: var(--text-secondary);
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
@@ -243,7 +243,7 @@
|
||||
}
|
||||
|
||||
.live-activity-elapsed {
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
font-weight: 500;
|
||||
color: var(--text-secondary);
|
||||
white-space: nowrap;
|
||||
@@ -270,7 +270,7 @@
|
||||
gap: 10px;
|
||||
min-height: 22px;
|
||||
min-width: 0;
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
line-height: 1.45;
|
||||
}
|
||||
|
||||
@@ -306,7 +306,7 @@
|
||||
}
|
||||
|
||||
.live-sub-elapsed {
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
color: var(--text-secondary);
|
||||
white-space: nowrap;
|
||||
min-width: 28px;
|
||||
@@ -316,7 +316,7 @@
|
||||
|
||||
.telemetry-matrix {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(4, 1fr);
|
||||
grid-template-columns: repeat(var(--matrix-cols, 4), minmax(0, 1fr));
|
||||
flex-shrink: 0;
|
||||
border: 1px solid var(--border-hairline);
|
||||
border-radius: var(--radius-xs);
|
||||
@@ -338,12 +338,12 @@
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
color: var(--text-secondary);
|
||||
}
|
||||
|
||||
.cell-value {
|
||||
font-size: 14.5px;
|
||||
font-size: var(--fs-lg);
|
||||
font-weight: 700;
|
||||
color: var(--text-primary);
|
||||
white-space: nowrap;
|
||||
@@ -360,7 +360,7 @@
|
||||
}
|
||||
|
||||
.cell-sub {
|
||||
font-size: 10.5px;
|
||||
font-size: var(--fs-sm);
|
||||
color: var(--text-secondary);
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
@@ -457,7 +457,7 @@
|
||||
padding: 2px 0 0 0;
|
||||
background: transparent;
|
||||
border: none;
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
}
|
||||
|
||||
.legend-item {
|
||||
@@ -527,7 +527,7 @@
|
||||
border: 1px solid var(--border-hairline);
|
||||
background: var(--surface-panel);
|
||||
color: var(--text-secondary);
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
border-radius: var(--radius-xs);
|
||||
cursor: pointer;
|
||||
white-space: nowrap;
|
||||
@@ -573,7 +573,7 @@
|
||||
align-items: center;
|
||||
gap: 3px;
|
||||
padding: 1px 5px;
|
||||
font-size: 10.5px;
|
||||
font-size: var(--fs-sm);
|
||||
font-weight: 600;
|
||||
line-height: 1.25;
|
||||
border-radius: var(--radius-xs);
|
||||
@@ -616,8 +616,8 @@
|
||||
}
|
||||
|
||||
@media (max-width: 390px) {
|
||||
.telemetry-matrix {
|
||||
grid-template-columns: repeat(2, 1fr);
|
||||
.telemetry-matrix:not([data-cols="1"]):not([data-cols="2"]) {
|
||||
grid-template-columns: repeat(2, minmax(0, 1fr));
|
||||
}
|
||||
.dual-grid {
|
||||
grid-template-columns: 1fr;
|
||||
|
||||
@@ -0,0 +1,363 @@
|
||||
/*
|
||||
* 模块化偏好设置三栏样式表 (views-settings.css).
|
||||
* 包含:
|
||||
* 1. 顶部常规 / 结构 / 其他三栏切换导航条 (.settings-view-root, .settings-subnav-bar)
|
||||
* 2. 主题强调色色卡选择器 (.theme-color-picker, .theme-host-chip, .theme-swatch-btn)
|
||||
* 3. 结构页手风琴折叠面板 (.collapsible-section, .collapsible-trigger, .collapsible-body)
|
||||
* 4. 通用 + / - / ↑ / ↓ 自添加排序列表 (.editable-slot-list, .editable-slot-row, .slot-add-btn)
|
||||
* 5. 其他页维护操作行与二次确认危险态按钮 (.settings-action-row, .btn-danger-confirm)
|
||||
*/
|
||||
|
||||
.settings-view-root {
|
||||
flex: 1;
|
||||
min-height: 0;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: var(--space-2);
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.settings-subnav-bar {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding: 3px 4px;
|
||||
background: var(--surface-panel);
|
||||
border: 1px solid var(--border-hairline);
|
||||
border-radius: var(--radius-sm);
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.settings-subnav-bar .segmented {
|
||||
width: 100%;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
gap: 3px;
|
||||
}
|
||||
|
||||
.settings-subnav-bar .seg-btn {
|
||||
height: 24px;
|
||||
font-size: var(--fs-base-sm);
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.settings-tab-stack {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: var(--space-3);
|
||||
padding-bottom: 2px;
|
||||
}
|
||||
|
||||
.settings-hint-text {
|
||||
font-size: var(--fs-sm);
|
||||
line-height: 1.4;
|
||||
color: var(--text-muted);
|
||||
}
|
||||
|
||||
/* --- 主题色色卡选择器 (ThemeColorPicker) --- */
|
||||
.theme-color-picker {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
flex-wrap: wrap;
|
||||
gap: 6px;
|
||||
}
|
||||
|
||||
.theme-host-chip {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 5px;
|
||||
height: 24px;
|
||||
padding: 0 9px;
|
||||
font-size: var(--fs-md);
|
||||
font-weight: 500;
|
||||
color: var(--text-secondary);
|
||||
background: var(--surface-subtle);
|
||||
border: 1px solid var(--border-hairline);
|
||||
border-radius: var(--radius-pill);
|
||||
cursor: pointer;
|
||||
white-space: nowrap;
|
||||
transition:
|
||||
background-color var(--dur-instant) var(--ease-fast),
|
||||
color var(--dur-instant) var(--ease-fast),
|
||||
border-color var(--dur-instant) var(--ease-fast);
|
||||
}
|
||||
|
||||
.theme-host-chip:hover {
|
||||
color: var(--text-primary);
|
||||
border-color: var(--border-strong);
|
||||
}
|
||||
|
||||
.theme-host-chip.is-active {
|
||||
color: var(--accent-primary);
|
||||
background: var(--accent-primary-soft);
|
||||
border-color: var(--accent-primary-border);
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.theme-swatch-group {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.theme-swatch-btn {
|
||||
position: relative;
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
padding: 0;
|
||||
border-radius: var(--radius-pill);
|
||||
border: 1.5px solid color-mix(in srgb, var(--text-primary) 18%, transparent);
|
||||
background: var(--swatch-color, var(--accent-primary));
|
||||
color: #ffffff;
|
||||
cursor: pointer;
|
||||
transition:
|
||||
transform var(--dur-instant) var(--ease-fast),
|
||||
box-shadow var(--dur-instant) var(--ease-fast),
|
||||
border-color var(--dur-instant) var(--ease-fast);
|
||||
}
|
||||
|
||||
.theme-swatch-btn:hover {
|
||||
transform: scale(1.08);
|
||||
}
|
||||
|
||||
.theme-swatch-btn.is-active {
|
||||
border-color: var(--text-primary);
|
||||
box-shadow: 0 0 0 2px color-mix(in srgb, var(--swatch-color, var(--accent-primary)) 32%, transparent);
|
||||
}
|
||||
|
||||
.theme-swatch-btn .svg-icon {
|
||||
stroke-width: 2.5;
|
||||
}
|
||||
|
||||
/* --- 手风琴折叠面板 (CollapsibleSection) --- */
|
||||
.collapsible-section {
|
||||
gap: 0;
|
||||
padding: 0;
|
||||
overflow: visible;
|
||||
}
|
||||
|
||||
.collapsible-header-row {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
gap: var(--space-2);
|
||||
padding: var(--space-3) var(--space-4);
|
||||
min-height: 36px;
|
||||
}
|
||||
|
||||
.collapsible-trigger {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
flex: 1;
|
||||
min-width: 0;
|
||||
padding: 0;
|
||||
border: none;
|
||||
background: transparent;
|
||||
color: var(--text-primary);
|
||||
font-size: var(--fs-base);
|
||||
font-weight: 600;
|
||||
text-align: left;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.collapsible-trigger:hover {
|
||||
color: var(--accent-primary);
|
||||
}
|
||||
|
||||
.collapsible-chevron {
|
||||
color: var(--text-secondary);
|
||||
transition: transform var(--dur-fast) var(--ease-fast);
|
||||
}
|
||||
|
||||
.collapsible-section.is-expanded .collapsible-chevron {
|
||||
transform: rotate(90deg);
|
||||
}
|
||||
|
||||
.collapsible-title-text {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.collapsible-right {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.collapsible-badge {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
height: 18px;
|
||||
padding: 0 6px;
|
||||
font-size: var(--fs-sm);
|
||||
font-weight: 500;
|
||||
color: var(--text-secondary);
|
||||
background: var(--surface-subtle);
|
||||
border: 1px solid var(--border-hairline);
|
||||
border-radius: var(--radius-xs);
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.collapsible-status {
|
||||
font-size: var(--fs-sm);
|
||||
color: var(--text-secondary);
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.collapsible-body {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: var(--space-3);
|
||||
padding: var(--space-3) var(--space-4) var(--space-4);
|
||||
border-top: 1px solid var(--border-hairline);
|
||||
}
|
||||
|
||||
.settings-divider {
|
||||
height: 1px;
|
||||
width: 100%;
|
||||
background: var(--border-hairline);
|
||||
margin: 2px 0;
|
||||
}
|
||||
|
||||
/* --- 通用可增删排序槽位列表 (EditableSlotList) --- */
|
||||
.editable-slot-wrap {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 6px;
|
||||
}
|
||||
|
||||
.editable-slot-list {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 5px;
|
||||
}
|
||||
|
||||
.editable-slot-empty {
|
||||
padding: 8px 10px;
|
||||
font-size: var(--fs-md);
|
||||
color: var(--text-secondary);
|
||||
background: var(--surface-subtle);
|
||||
border: 1px dashed var(--border-hairline);
|
||||
border-radius: var(--radius-xs);
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.editable-slot-row {
|
||||
position: relative;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
padding: 2px 4px 2px 6px;
|
||||
border: 1px solid var(--border-hairline);
|
||||
border-radius: var(--radius-xs);
|
||||
background: var(--surface-panel);
|
||||
transition: border-color var(--dur-instant) var(--ease-fast);
|
||||
}
|
||||
|
||||
.editable-slot-row:focus-within,
|
||||
.editable-slot-row:has(.is-open) {
|
||||
z-index: 35;
|
||||
border-color: var(--border-strong);
|
||||
}
|
||||
|
||||
.editable-slot-row .select-menu {
|
||||
max-height: 216px;
|
||||
}
|
||||
|
||||
.slot-remove-btn {
|
||||
color: var(--text-secondary);
|
||||
}
|
||||
|
||||
.slot-remove-btn:hover:not(:disabled) {
|
||||
color: var(--metric-danger);
|
||||
background: color-mix(in srgb, var(--metric-danger) 10%, transparent);
|
||||
}
|
||||
|
||||
.editable-slot-footer {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
padding-top: 1px;
|
||||
}
|
||||
|
||||
.slot-add-btn {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
gap: 5px;
|
||||
height: 24px;
|
||||
padding: 0 9px;
|
||||
font-size: var(--fs-md);
|
||||
font-weight: 500;
|
||||
color: var(--accent-primary);
|
||||
background: var(--accent-primary-soft);
|
||||
border: 1px dashed var(--accent-primary-border);
|
||||
border-radius: var(--radius-xs);
|
||||
cursor: pointer;
|
||||
transition:
|
||||
background-color var(--dur-instant) var(--ease-fast),
|
||||
opacity var(--dur-instant) var(--ease-fast);
|
||||
}
|
||||
|
||||
.slot-add-btn:hover:not(:disabled) {
|
||||
background: color-mix(in srgb, var(--accent-primary) 18%, transparent);
|
||||
}
|
||||
|
||||
.slot-add-btn:disabled {
|
||||
opacity: 0.45;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
/* --- 其他页:维护操作行 --- */
|
||||
.settings-action-block {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
gap: var(--space-3);
|
||||
padding-top: 2px;
|
||||
}
|
||||
|
||||
.settings-action-block + .settings-action-block {
|
||||
padding-top: var(--space-3);
|
||||
border-top: 1px solid var(--border-hairline);
|
||||
}
|
||||
|
||||
.settings-action-info {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 2px;
|
||||
min-width: 0;
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.settings-action-title {
|
||||
font-size: var(--fs-base-sm);
|
||||
font-weight: 600;
|
||||
color: var(--text-primary);
|
||||
}
|
||||
|
||||
.settings-action-desc {
|
||||
font-size: var(--fs-sm);
|
||||
color: var(--text-secondary);
|
||||
line-height: 1.35;
|
||||
}
|
||||
|
||||
.settings-context-model .select-option-meta {
|
||||
max-width: 62%;
|
||||
text-align: right;
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
.btn-danger-confirm {
|
||||
color: var(--metric-danger) !important;
|
||||
border-color: color-mix(in srgb, var(--metric-danger) 55%, var(--border-hairline)) !important;
|
||||
background: color-mix(in srgb, var(--metric-danger) 11%, var(--surface-panel)) !important;
|
||||
font-weight: 600;
|
||||
}
|
||||
@@ -27,11 +27,15 @@
|
||||
background: var(--surface-panel);
|
||||
}
|
||||
|
||||
.table-viewport.is-step-table {
|
||||
overflow-x: auto;
|
||||
}
|
||||
|
||||
/* --- 2. 粘性表头数据表 (Sticky-Header Data Table) --- */
|
||||
.data-table {
|
||||
width: 100%;
|
||||
border-collapse: collapse;
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
}
|
||||
|
||||
.data-table th,
|
||||
@@ -42,6 +46,11 @@
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.data-table th.is-right,
|
||||
.data-table td.is-right {
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.data-table th:first-child,
|
||||
.data-table td:first-child {
|
||||
padding-left: 2px;
|
||||
@@ -102,7 +111,7 @@
|
||||
gap: 4px;
|
||||
min-width: 0;
|
||||
overflow: hidden;
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
border: 1px solid var(--border-hairline);
|
||||
background: var(--surface-subtle);
|
||||
}
|
||||
@@ -143,7 +152,7 @@
|
||||
}
|
||||
|
||||
.sstep-card-title {
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
font-weight: 600;
|
||||
color: var(--text-primary);
|
||||
white-space: nowrap;
|
||||
@@ -151,7 +160,7 @@
|
||||
|
||||
.sstep-card .seg-btn {
|
||||
padding: 2px 6px;
|
||||
font-size: 10.5px;
|
||||
font-size: var(--fs-sm);
|
||||
}
|
||||
|
||||
.sstep-fit-controls {
|
||||
@@ -174,7 +183,7 @@
|
||||
gap: 4px;
|
||||
min-width: 0;
|
||||
overflow: hidden;
|
||||
font-size: 10.5px;
|
||||
font-size: var(--fs-sm);
|
||||
border: 1px solid var(--border-hairline);
|
||||
background: var(--surface-subtle);
|
||||
}
|
||||
@@ -465,7 +474,7 @@
|
||||
.smodel-empty {
|
||||
padding: var(--space-5) var(--space-3);
|
||||
text-align: center;
|
||||
font-size: 11px;
|
||||
font-size: var(--fs-md);
|
||||
border: 1px dashed var(--border-hairline);
|
||||
border-radius: var(--radius-xs);
|
||||
}
|
||||
@@ -516,7 +525,7 @@
|
||||
}
|
||||
|
||||
.smodel-name {
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
font-weight: 600;
|
||||
color: var(--text-primary);
|
||||
overflow: hidden;
|
||||
@@ -526,7 +535,7 @@
|
||||
|
||||
.smodel-calls-pill {
|
||||
flex-shrink: 0;
|
||||
font-size: 10px;
|
||||
font-size: var(--fs-xs);
|
||||
font-weight: 500;
|
||||
padding: 1px 5px;
|
||||
color: var(--text-secondary);
|
||||
@@ -542,13 +551,13 @@
|
||||
}
|
||||
|
||||
.smodel-tok {
|
||||
font-size: 11.5px;
|
||||
font-size: var(--fs-base-sm);
|
||||
font-weight: 500;
|
||||
color: var(--text-secondary);
|
||||
}
|
||||
|
||||
.smodel-cost {
|
||||
font-size: 12px;
|
||||
font-size: var(--fs-base);
|
||||
font-weight: 700;
|
||||
color: var(--text-primary);
|
||||
}
|
||||
@@ -563,7 +572,7 @@
|
||||
justify-content: space-between;
|
||||
flex-wrap: wrap;
|
||||
gap: 2px 10px;
|
||||
font-size: 10.5px;
|
||||
font-size: var(--fs-sm);
|
||||
color: var(--text-secondary);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user