mirror of
https://github.com/lWolvesl/antigravity-usage-monitor.git
synced 2026-11-26 17:09:28 +08:00
fix(panel): make font-scale visibly resize all tables/charts and raise readable base sizes
- Raise base typography tokens (data tables to 12.5px, body/titles to 13px) above CJK 12px floor and widen lg (1.14x) / xl (1.28x) scale steps - Replace 19 hardcoded px font-size rules across tables, charts, tooltips, heatmaps, and monthly bars with scalable --fs-* tokens - Bind [data-font-scale] directly in CSS and mirror onto Shadow DOM overlay panels without colliding with :host defaults - Convert rigid control/row pixel heights to scalable min-heights and scale floating panel base widths on lg/xl
This commit is contained in:
+43
-15
@@ -1558,8 +1558,15 @@ const THEME_ACCENT_PRESETS = Object.freeze([
|
|||||||
const FONT_SCALE_FACTORS = Object.freeze({
|
const FONT_SCALE_FACTORS = Object.freeze({
|
||||||
sm: 0.92,
|
sm: 0.92,
|
||||||
md: 1,
|
md: 1,
|
||||||
lg: 1.08,
|
lg: 1.14,
|
||||||
xl: 1.15,
|
xl: 1.28,
|
||||||
|
});
|
||||||
|
|
||||||
|
const PANEL_SCALE_FACTORS = Object.freeze({
|
||||||
|
sm: 1,
|
||||||
|
md: 1,
|
||||||
|
lg: 1.09,
|
||||||
|
xl: 1.18,
|
||||||
});
|
});
|
||||||
|
|
||||||
function normalizeClientThemeAccent(raw) {
|
function normalizeClientThemeAccent(raw) {
|
||||||
@@ -1611,10 +1618,13 @@ function applyAppearanceToRoot(targetEl, settings, { includeFontScale = true } =
|
|||||||
if (includeFontScale) {
|
if (includeFontScale) {
|
||||||
const scaleKey = normalizeClientFontScale(settings?.fontScale);
|
const scaleKey = normalizeClientFontScale(settings?.fontScale);
|
||||||
const factor = FONT_SCALE_FACTORS[scaleKey] ?? 1;
|
const factor = FONT_SCALE_FACTORS[scaleKey] ?? 1;
|
||||||
|
const panelFactor = PANEL_SCALE_FACTORS[scaleKey] ?? 1;
|
||||||
setOrClearStyleVar(targetEl, '--ui-font-scale', factor === 1 ? '' : String(factor));
|
setOrClearStyleVar(targetEl, '--ui-font-scale', factor === 1 ? '' : String(factor));
|
||||||
|
setOrClearStyleVar(targetEl, '--ui-panel-scale', panelFactor === 1 ? '' : String(panelFactor));
|
||||||
targetEl.setAttribute?.('data-font-scale', scaleKey);
|
targetEl.setAttribute?.('data-font-scale', scaleKey);
|
||||||
} else {
|
} else {
|
||||||
setOrClearStyleVar(targetEl, '--ui-font-scale', '');
|
setOrClearStyleVar(targetEl, '--ui-font-scale', '');
|
||||||
|
setOrClearStyleVar(targetEl, '--ui-panel-scale', '');
|
||||||
if (typeof targetEl.removeAttribute === 'function') {
|
if (typeof targetEl.removeAttribute === 'function') {
|
||||||
targetEl.removeAttribute('data-font-scale');
|
targetEl.removeAttribute('data-font-scale');
|
||||||
}
|
}
|
||||||
@@ -10882,7 +10892,7 @@ const STEP_COLUMN_REGISTRY = Object.freeze({
|
|||||||
if (reason && !refs.speedReason) {
|
if (reason && !refs.speedReason) {
|
||||||
refs.speedReason = h('div', {
|
refs.speedReason = h('div', {
|
||||||
className: 'text-muted',
|
className: 'text-muted',
|
||||||
style: 'font-size: var(--fs-2xs);',
|
style: 'font-size: var(--fs-xs);',
|
||||||
});
|
});
|
||||||
refs.wrapEl.appendChild(refs.speedReason);
|
refs.wrapEl.appendChild(refs.speedReason);
|
||||||
}
|
}
|
||||||
@@ -19384,8 +19394,6 @@ function mountWindowOverlay() {
|
|||||||
portalShadow.appendChild(portalStyleEl);
|
portalShadow.appendChild(portalStyleEl);
|
||||||
|
|
||||||
const initialSettings = telemetryStore.getState().telemetry?.settings;
|
const initialSettings = telemetryStore.getState().telemetry?.settings;
|
||||||
applyAppearanceToRoot(capsuleHost, initialSettings, { includeFontScale: false });
|
|
||||||
applyAppearanceToRoot(portalHost, initialSettings, { includeFontScale: true });
|
|
||||||
|
|
||||||
// 悬停全景概览浮层(完全解耦至 widgetRegistry,由 hoverModules 动态驱动 0..4 个独立组件,零硬编码)
|
// 悬停全景概览浮层(完全解耦至 widgetRegistry,由 hoverModules 动态驱动 0..4 个独立组件,零硬编码)
|
||||||
const hoverUpdateVerText = h('span', { text: t('capsule.hoverNewVerGeneric') });
|
const hoverUpdateVerText = h('span', { text: t('capsule.hoverNewVerGeneric') });
|
||||||
@@ -19594,9 +19602,19 @@ function mountWindowOverlay() {
|
|||||||
[appInstance.el]
|
[appInstance.el]
|
||||||
);
|
);
|
||||||
|
|
||||||
|
function syncPortalAppearance(settings) {
|
||||||
|
applyAppearanceToRoot(capsuleHost, settings, { includeFontScale: false });
|
||||||
|
applyAppearanceToRoot(portalHost, settings, { includeFontScale: true });
|
||||||
|
const scaleKey = normalizeClientFontScale(settings?.fontScale);
|
||||||
|
popoverEl.setAttribute?.('data-font-scale', scaleKey);
|
||||||
|
hoverTipEl.setAttribute?.('data-font-scale', scaleKey);
|
||||||
|
multiPanelEl.setAttribute?.('data-font-scale', scaleKey);
|
||||||
|
}
|
||||||
|
|
||||||
portalShadow.appendChild(multiPanelEl);
|
portalShadow.appendChild(multiPanelEl);
|
||||||
portalShadow.appendChild(hoverTipEl);
|
portalShadow.appendChild(hoverTipEl);
|
||||||
portalShadow.appendChild(popoverEl);
|
portalShadow.appendChild(popoverEl);
|
||||||
|
syncPortalAppearance(initialSettings);
|
||||||
(document.body || document.documentElement).appendChild(portalHost);
|
(document.body || document.documentElement).appendChild(portalHost);
|
||||||
|
|
||||||
// --- 3. 几何测量、IDE 主题桥接、顶栏停靠与防溢出定位 ---
|
// --- 3. 几何测量、IDE 主题桥接、顶栏停靠与防溢出定位 ---
|
||||||
@@ -19935,8 +19953,17 @@ function mountWindowOverlay() {
|
|||||||
const vh = Number(window.innerHeight || 800);
|
const vh = Number(window.innerHeight || 800);
|
||||||
const navRight = getLeftSidebarRightEdge(vw);
|
const navRight = getLeftSidebarRightEdge(vw);
|
||||||
const minLeft = navRight > 0 ? Math.max(12, navRight + 12) : 12;
|
const minLeft = navRight > 0 ? Math.max(12, navRight + 12) : 12;
|
||||||
const defaultCardW = Math.min(FLOATING_CARD_WIDTH, Math.max(280, vw - 24));
|
const curSettings = telemetryStore.getState().telemetry?.settings;
|
||||||
const defaultMultiW = Math.min(MULTI_PANEL_WIDTH, Math.max(280, vw - 24));
|
const panelScale =
|
||||||
|
PANEL_SCALE_FACTORS[normalizeClientFontScale(curSettings?.fontScale)] ?? 1;
|
||||||
|
const defaultCardW = Math.min(
|
||||||
|
Math.round(FLOATING_CARD_WIDTH * panelScale),
|
||||||
|
Math.max(280, vw - 24)
|
||||||
|
);
|
||||||
|
const defaultMultiW = Math.min(
|
||||||
|
Math.round(MULTI_PANEL_WIDTH * panelScale),
|
||||||
|
Math.max(280, vw - 24)
|
||||||
|
);
|
||||||
const isDockComposer = capsuleHost.getAttribute('data-dock') === 'composer';
|
const isDockComposer = capsuleHost.getAttribute('data-dock') === 'composer';
|
||||||
|
|
||||||
if (multiOpen) {
|
if (multiOpen) {
|
||||||
@@ -19984,9 +20011,8 @@ function mountWindowOverlay() {
|
|||||||
|
|
||||||
if (popoverOpen) {
|
if (popoverOpen) {
|
||||||
const maxPopCardW = Math.max(280, vw - minLeft - 12);
|
const maxPopCardW = Math.max(280, vw - minLeft - 12);
|
||||||
const curSettings = telemetryStore.getState().telemetry?.settings;
|
|
||||||
const popWidthMode = normalizeClientPopoverWidthMode(curSettings?.popoverWidthMode);
|
const popWidthMode = normalizeClientPopoverWidthMode(curSettings?.popoverWidthMode);
|
||||||
let desiredPopW = Math.min(POPOVER_BASE_WIDTH, maxPopCardW);
|
let desiredPopW = Math.min(Math.round(POPOVER_BASE_WIDTH * panelScale), maxPopCardW);
|
||||||
if (popWidthMode === 'custom') {
|
if (popWidthMode === 'custom') {
|
||||||
desiredPopW = Math.min(
|
desiredPopW = Math.min(
|
||||||
normalizeClientPopoverWidth(curSettings?.popoverWidth),
|
normalizeClientPopoverWidth(curSettings?.popoverWidth),
|
||||||
@@ -20634,8 +20660,7 @@ function mountWindowOverlay() {
|
|||||||
const telemetry = telSt.telemetry;
|
const telemetry = telSt.telemetry;
|
||||||
|
|
||||||
setI18nLanguage(telemetry?.settings?.language);
|
setI18nLanguage(telemetry?.settings?.language);
|
||||||
applyAppearanceToRoot(capsuleHost, telemetry?.settings, { includeFontScale: false });
|
syncPortalAppearance(telemetry?.settings);
|
||||||
applyAppearanceToRoot(portalHost, telemetry?.settings, { includeFontScale: true });
|
|
||||||
|
|
||||||
const showMulti = telemetry?.settings?.showTopbarMultiSession !== false;
|
const showMulti = telemetry?.settings?.showTopbarMultiSession !== false;
|
||||||
patchAttr(multiBtn, 'hidden', !showMulti);
|
patchAttr(multiBtn, 'hidden', !showMulti);
|
||||||
@@ -21235,14 +21260,17 @@ async function bootstrapApp(mountTarget = document.getElementById('app-root')) {
|
|||||||
const appInstance = App();
|
const appInstance = App();
|
||||||
mountTarget.appendChild(appInstance.el);
|
mountTarget.appendChild(appInstance.el);
|
||||||
|
|
||||||
const unsubAppearance = telemetryStore.subscribe(
|
const syncDocAppearance = (settings) => {
|
||||||
(st) => st.telemetry?.settings,
|
|
||||||
(settings) => {
|
|
||||||
setI18nLanguage(settings?.language);
|
setI18nLanguage(settings?.language);
|
||||||
if (typeof document !== 'undefined' && document.documentElement) {
|
if (typeof document !== 'undefined' && document.documentElement) {
|
||||||
applyAppearanceToRoot(document.documentElement, settings, { includeFontScale: true });
|
applyAppearanceToRoot(document.documentElement, settings, { includeFontScale: true });
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
|
syncDocAppearance(telemetryStore.getState().telemetry?.settings);
|
||||||
|
|
||||||
|
const unsubAppearance = telemetryStore.subscribe(
|
||||||
|
(st) => st.telemetry?.settings,
|
||||||
|
syncDocAppearance
|
||||||
);
|
);
|
||||||
|
|
||||||
const stopPolling = startAsyncTelemetryLoop(2000);
|
const stopPolling = startAsyncTelemetryLoop(2000);
|
||||||
|
|||||||
@@ -4,11 +4,11 @@
|
|||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||||
<title>用量监控</title>
|
<title>用量监控</title>
|
||||||
<link rel="stylesheet" href="/styles.css?v=1794913323467">
|
<link rel="stylesheet" href="/styles.css?v=1794916257143">
|
||||||
<script src="/preload.js"></script>
|
<script src="/preload.js"></script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div id="app-root"></div>
|
<div id="app-root"></div>
|
||||||
<script src="/app.js?v=1794913323467"></script>
|
<script src="/app.js?v=1794916257143"></script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@@ -15,7 +15,11 @@ import {
|
|||||||
readInjectedWindowBridge,
|
readInjectedWindowBridge,
|
||||||
} from '../../../shared/window-bridge-protocol.mjs';
|
} from '../../../shared/window-bridge-protocol.mjs';
|
||||||
import { App } from '../../App.js';
|
import { App } from '../../App.js';
|
||||||
import { applyAppearanceToRoot } from '../../core/appearance.js';
|
import {
|
||||||
|
PANEL_SCALE_FACTORS,
|
||||||
|
applyAppearanceToRoot,
|
||||||
|
normalizeClientFontScale,
|
||||||
|
} from '../../core/appearance.js';
|
||||||
import {
|
import {
|
||||||
h,
|
h,
|
||||||
isEventInside,
|
isEventInside,
|
||||||
@@ -1380,8 +1384,6 @@ export function mountWindowOverlay() {
|
|||||||
portalShadow.appendChild(portalStyleEl);
|
portalShadow.appendChild(portalStyleEl);
|
||||||
|
|
||||||
const initialSettings = telemetryStore.getState().telemetry?.settings;
|
const initialSettings = telemetryStore.getState().telemetry?.settings;
|
||||||
applyAppearanceToRoot(capsuleHost, initialSettings, { includeFontScale: false });
|
|
||||||
applyAppearanceToRoot(portalHost, initialSettings, { includeFontScale: true });
|
|
||||||
|
|
||||||
// 悬停全景概览浮层(完全解耦至 widgetRegistry,由 hoverModules 动态驱动 0..4 个独立组件,零硬编码)
|
// 悬停全景概览浮层(完全解耦至 widgetRegistry,由 hoverModules 动态驱动 0..4 个独立组件,零硬编码)
|
||||||
const hoverUpdateVerText = h('span', { text: t('capsule.hoverNewVerGeneric') });
|
const hoverUpdateVerText = h('span', { text: t('capsule.hoverNewVerGeneric') });
|
||||||
@@ -1590,9 +1592,19 @@ export function mountWindowOverlay() {
|
|||||||
[appInstance.el]
|
[appInstance.el]
|
||||||
);
|
);
|
||||||
|
|
||||||
|
function syncPortalAppearance(settings) {
|
||||||
|
applyAppearanceToRoot(capsuleHost, settings, { includeFontScale: false });
|
||||||
|
applyAppearanceToRoot(portalHost, settings, { includeFontScale: true });
|
||||||
|
const scaleKey = normalizeClientFontScale(settings?.fontScale);
|
||||||
|
popoverEl.setAttribute?.('data-font-scale', scaleKey);
|
||||||
|
hoverTipEl.setAttribute?.('data-font-scale', scaleKey);
|
||||||
|
multiPanelEl.setAttribute?.('data-font-scale', scaleKey);
|
||||||
|
}
|
||||||
|
|
||||||
portalShadow.appendChild(multiPanelEl);
|
portalShadow.appendChild(multiPanelEl);
|
||||||
portalShadow.appendChild(hoverTipEl);
|
portalShadow.appendChild(hoverTipEl);
|
||||||
portalShadow.appendChild(popoverEl);
|
portalShadow.appendChild(popoverEl);
|
||||||
|
syncPortalAppearance(initialSettings);
|
||||||
(document.body || document.documentElement).appendChild(portalHost);
|
(document.body || document.documentElement).appendChild(portalHost);
|
||||||
|
|
||||||
// --- 3. 几何测量、IDE 主题桥接、顶栏停靠与防溢出定位 ---
|
// --- 3. 几何测量、IDE 主题桥接、顶栏停靠与防溢出定位 ---
|
||||||
@@ -1931,8 +1943,17 @@ export function mountWindowOverlay() {
|
|||||||
const vh = Number(window.innerHeight || 800);
|
const vh = Number(window.innerHeight || 800);
|
||||||
const navRight = getLeftSidebarRightEdge(vw);
|
const navRight = getLeftSidebarRightEdge(vw);
|
||||||
const minLeft = navRight > 0 ? Math.max(12, navRight + 12) : 12;
|
const minLeft = navRight > 0 ? Math.max(12, navRight + 12) : 12;
|
||||||
const defaultCardW = Math.min(FLOATING_CARD_WIDTH, Math.max(280, vw - 24));
|
const curSettings = telemetryStore.getState().telemetry?.settings;
|
||||||
const defaultMultiW = Math.min(MULTI_PANEL_WIDTH, Math.max(280, vw - 24));
|
const panelScale =
|
||||||
|
PANEL_SCALE_FACTORS[normalizeClientFontScale(curSettings?.fontScale)] ?? 1;
|
||||||
|
const defaultCardW = Math.min(
|
||||||
|
Math.round(FLOATING_CARD_WIDTH * panelScale),
|
||||||
|
Math.max(280, vw - 24)
|
||||||
|
);
|
||||||
|
const defaultMultiW = Math.min(
|
||||||
|
Math.round(MULTI_PANEL_WIDTH * panelScale),
|
||||||
|
Math.max(280, vw - 24)
|
||||||
|
);
|
||||||
const isDockComposer = capsuleHost.getAttribute('data-dock') === 'composer';
|
const isDockComposer = capsuleHost.getAttribute('data-dock') === 'composer';
|
||||||
|
|
||||||
if (multiOpen) {
|
if (multiOpen) {
|
||||||
@@ -1980,9 +2001,8 @@ export function mountWindowOverlay() {
|
|||||||
|
|
||||||
if (popoverOpen) {
|
if (popoverOpen) {
|
||||||
const maxPopCardW = Math.max(280, vw - minLeft - 12);
|
const maxPopCardW = Math.max(280, vw - minLeft - 12);
|
||||||
const curSettings = telemetryStore.getState().telemetry?.settings;
|
|
||||||
const popWidthMode = normalizeClientPopoverWidthMode(curSettings?.popoverWidthMode);
|
const popWidthMode = normalizeClientPopoverWidthMode(curSettings?.popoverWidthMode);
|
||||||
let desiredPopW = Math.min(POPOVER_BASE_WIDTH, maxPopCardW);
|
let desiredPopW = Math.min(Math.round(POPOVER_BASE_WIDTH * panelScale), maxPopCardW);
|
||||||
if (popWidthMode === 'custom') {
|
if (popWidthMode === 'custom') {
|
||||||
desiredPopW = Math.min(
|
desiredPopW = Math.min(
|
||||||
normalizeClientPopoverWidth(curSettings?.popoverWidth),
|
normalizeClientPopoverWidth(curSettings?.popoverWidth),
|
||||||
@@ -2630,8 +2650,7 @@ export function mountWindowOverlay() {
|
|||||||
const telemetry = telSt.telemetry;
|
const telemetry = telSt.telemetry;
|
||||||
|
|
||||||
setI18nLanguage(telemetry?.settings?.language);
|
setI18nLanguage(telemetry?.settings?.language);
|
||||||
applyAppearanceToRoot(capsuleHost, telemetry?.settings, { includeFontScale: false });
|
syncPortalAppearance(telemetry?.settings);
|
||||||
applyAppearanceToRoot(portalHost, telemetry?.settings, { includeFontScale: true });
|
|
||||||
|
|
||||||
const showMulti = telemetry?.settings?.showTopbarMultiSession !== false;
|
const showMulti = telemetry?.settings?.showTopbarMultiSession !== false;
|
||||||
patchAttr(multiBtn, 'hidden', !showMulti);
|
patchAttr(multiBtn, 'hidden', !showMulti);
|
||||||
|
|||||||
@@ -17,8 +17,15 @@ export const THEME_ACCENT_PRESETS = Object.freeze([
|
|||||||
export const FONT_SCALE_FACTORS = Object.freeze({
|
export const FONT_SCALE_FACTORS = Object.freeze({
|
||||||
sm: 0.92,
|
sm: 0.92,
|
||||||
md: 1,
|
md: 1,
|
||||||
lg: 1.08,
|
lg: 1.14,
|
||||||
xl: 1.15,
|
xl: 1.28,
|
||||||
|
});
|
||||||
|
|
||||||
|
export const PANEL_SCALE_FACTORS = Object.freeze({
|
||||||
|
sm: 1,
|
||||||
|
md: 1,
|
||||||
|
lg: 1.09,
|
||||||
|
xl: 1.18,
|
||||||
});
|
});
|
||||||
|
|
||||||
export function normalizeClientThemeAccent(raw) {
|
export function normalizeClientThemeAccent(raw) {
|
||||||
@@ -70,10 +77,13 @@ export function applyAppearanceToRoot(targetEl, settings, { includeFontScale = t
|
|||||||
if (includeFontScale) {
|
if (includeFontScale) {
|
||||||
const scaleKey = normalizeClientFontScale(settings?.fontScale);
|
const scaleKey = normalizeClientFontScale(settings?.fontScale);
|
||||||
const factor = FONT_SCALE_FACTORS[scaleKey] ?? 1;
|
const factor = FONT_SCALE_FACTORS[scaleKey] ?? 1;
|
||||||
|
const panelFactor = PANEL_SCALE_FACTORS[scaleKey] ?? 1;
|
||||||
setOrClearStyleVar(targetEl, '--ui-font-scale', factor === 1 ? '' : String(factor));
|
setOrClearStyleVar(targetEl, '--ui-font-scale', factor === 1 ? '' : String(factor));
|
||||||
|
setOrClearStyleVar(targetEl, '--ui-panel-scale', panelFactor === 1 ? '' : String(panelFactor));
|
||||||
targetEl.setAttribute?.('data-font-scale', scaleKey);
|
targetEl.setAttribute?.('data-font-scale', scaleKey);
|
||||||
} else {
|
} else {
|
||||||
setOrClearStyleVar(targetEl, '--ui-font-scale', '');
|
setOrClearStyleVar(targetEl, '--ui-font-scale', '');
|
||||||
|
setOrClearStyleVar(targetEl, '--ui-panel-scale', '');
|
||||||
if (typeof targetEl.removeAttribute === 'function') {
|
if (typeof targetEl.removeAttribute === 'function') {
|
||||||
targetEl.removeAttribute('data-font-scale');
|
targetEl.removeAttribute('data-font-scale');
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,14 +16,17 @@ async function bootstrapApp(mountTarget = document.getElementById('app-root')) {
|
|||||||
const appInstance = App();
|
const appInstance = App();
|
||||||
mountTarget.appendChild(appInstance.el);
|
mountTarget.appendChild(appInstance.el);
|
||||||
|
|
||||||
const unsubAppearance = telemetryStore.subscribe(
|
const syncDocAppearance = (settings) => {
|
||||||
(st) => st.telemetry?.settings,
|
|
||||||
(settings) => {
|
|
||||||
setI18nLanguage(settings?.language);
|
setI18nLanguage(settings?.language);
|
||||||
if (typeof document !== 'undefined' && document.documentElement) {
|
if (typeof document !== 'undefined' && document.documentElement) {
|
||||||
applyAppearanceToRoot(document.documentElement, settings, { includeFontScale: true });
|
applyAppearanceToRoot(document.documentElement, settings, { includeFontScale: true });
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
|
syncDocAppearance(telemetryStore.getState().telemetry?.settings);
|
||||||
|
|
||||||
|
const unsubAppearance = telemetryStore.subscribe(
|
||||||
|
(st) => st.telemetry?.settings,
|
||||||
|
syncDocAppearance
|
||||||
);
|
);
|
||||||
|
|
||||||
const stopPolling = startAsyncTelemetryLoop(2000);
|
const stopPolling = startAsyncTelemetryLoop(2000);
|
||||||
|
|||||||
@@ -224,7 +224,7 @@ export const STEP_COLUMN_REGISTRY = Object.freeze({
|
|||||||
if (reason && !refs.speedReason) {
|
if (reason && !refs.speedReason) {
|
||||||
refs.speedReason = h('div', {
|
refs.speedReason = h('div', {
|
||||||
className: 'text-muted',
|
className: 'text-muted',
|
||||||
style: 'font-size: var(--fs-2xs);',
|
style: 'font-size: var(--fs-xs);',
|
||||||
});
|
});
|
||||||
refs.wrapEl.appendChild(refs.speedReason);
|
refs.wrapEl.appendChild(refs.speedReason);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -37,7 +37,12 @@ body {
|
|||||||
}
|
}
|
||||||
|
|
||||||
button,
|
button,
|
||||||
input {
|
input,
|
||||||
|
select,
|
||||||
|
textarea,
|
||||||
|
table,
|
||||||
|
th,
|
||||||
|
td {
|
||||||
font-family: inherit;
|
font-family: inherit;
|
||||||
font-size: inherit;
|
font-size: inherit;
|
||||||
font-stretch: inherit;
|
font-stretch: inherit;
|
||||||
|
|||||||
@@ -149,14 +149,14 @@
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 5px;
|
gap: 5px;
|
||||||
height: 26px;
|
min-height: calc(26px * var(--ui-font-scale, 1));
|
||||||
padding: 0 var(--space-2);
|
padding: 2px var(--space-2);
|
||||||
border: none;
|
border: none;
|
||||||
background: transparent;
|
background: transparent;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
font-size: var(--fs-base);
|
font-size: var(--fs-base);
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
line-height: 1;
|
line-height: 1.15;
|
||||||
border-radius: var(--radius-pill);
|
border-radius: var(--radius-pill);
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
@@ -175,8 +175,8 @@
|
|||||||
.pill-tab-badge {
|
.pill-tab-badge {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
height: 14px;
|
min-height: 14px;
|
||||||
line-height: 1;
|
line-height: 1.15;
|
||||||
}
|
}
|
||||||
|
|
||||||
.pill-tab-badge {
|
.pill-tab-badge {
|
||||||
@@ -223,8 +223,8 @@
|
|||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
gap: var(--space-2);
|
gap: var(--space-2);
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 24px;
|
min-height: calc(24px * var(--ui-font-scale, 1));
|
||||||
padding: 0 6px;
|
padding: 2px 6px;
|
||||||
background: transparent;
|
background: transparent;
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
border: none;
|
border: none;
|
||||||
@@ -350,7 +350,7 @@
|
|||||||
.number-input {
|
.number-input {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: stretch;
|
align-items: stretch;
|
||||||
height: 28px;
|
min-height: calc(28px * var(--ui-font-scale, 1));
|
||||||
background: var(--surface-panel);
|
background: var(--surface-panel);
|
||||||
border: 1px solid var(--border-hairline);
|
border: 1px solid var(--border-hairline);
|
||||||
border-radius: var(--radius-xs);
|
border-radius: var(--radius-xs);
|
||||||
@@ -410,8 +410,8 @@
|
|||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
gap: var(--space-2);
|
gap: var(--space-2);
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 26px;
|
min-height: calc(26px * var(--ui-font-scale, 1));
|
||||||
padding: 0 var(--space-2);
|
padding: 2px var(--space-2);
|
||||||
background: var(--surface-panel);
|
background: var(--surface-panel);
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
border: 1px solid var(--border-hairline);
|
border: 1px solid var(--border-hairline);
|
||||||
@@ -464,7 +464,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.dt-day {
|
.dt-day {
|
||||||
height: 22px;
|
min-height: calc(22px * var(--ui-font-scale, 1));
|
||||||
border: none;
|
border: none;
|
||||||
background: transparent;
|
background: transparent;
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
@@ -540,8 +540,8 @@
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
height: 22px;
|
min-height: calc(22px * var(--ui-font-scale, 1));
|
||||||
padding: 0 7px;
|
padding: 2px 7px;
|
||||||
border: none;
|
border: none;
|
||||||
background: transparent;
|
background: transparent;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
@@ -650,8 +650,8 @@
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 6px;
|
gap: 6px;
|
||||||
height: 28px;
|
min-height: calc(28px * var(--ui-font-scale, 1));
|
||||||
padding: 0 var(--space-5);
|
padding: 3px var(--space-5);
|
||||||
background: var(--accent-primary);
|
background: var(--accent-primary);
|
||||||
color: var(--text-inverse);
|
color: var(--text-inverse);
|
||||||
border: 1px solid var(--accent-primary);
|
border: 1px solid var(--accent-primary);
|
||||||
@@ -675,8 +675,8 @@
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 6px;
|
gap: 6px;
|
||||||
height: 28px;
|
min-height: calc(28px * var(--ui-font-scale, 1));
|
||||||
padding: 0 var(--space-4);
|
padding: 3px var(--space-4);
|
||||||
background: var(--surface-panel);
|
background: var(--surface-panel);
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
border: 1px solid var(--border-strong);
|
border: 1px solid var(--border-strong);
|
||||||
@@ -714,8 +714,8 @@
|
|||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
height: 22px;
|
min-height: calc(22px * var(--ui-font-scale, 1));
|
||||||
padding: 0 7px;
|
padding: 2px 7px;
|
||||||
font-size: var(--fs-md);
|
font-size: var(--fs-md);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
border-radius: var(--radius-xs);
|
border-radius: var(--radius-xs);
|
||||||
@@ -748,8 +748,8 @@
|
|||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
height: 20px;
|
min-height: calc(20px * var(--ui-font-scale, 1));
|
||||||
padding: 0 6px;
|
padding: 1px 6px;
|
||||||
font-size: var(--fs-md);
|
font-size: var(--fs-md);
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
@@ -779,8 +779,9 @@
|
|||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
width: 16px;
|
min-width: calc(16px * var(--ui-font-scale, 1));
|
||||||
height: 16px;
|
min-height: calc(16px * var(--ui-font-scale, 1));
|
||||||
|
padding: 0 3px;
|
||||||
font-size: var(--fs-sm);
|
font-size: var(--fs-sm);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
font-variant-numeric: tabular-nums;
|
font-variant-numeric: tabular-nums;
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
/* --- 1. 顶栏胶囊宿主容器 (Titlebar Capsule Host) --- */
|
/* --- 1. 顶栏胶囊宿主容器 (Titlebar Capsule Host) --- */
|
||||||
:host(.wm-capsule-host) {
|
:host(.wm-capsule-host) {
|
||||||
--ui-font-scale: 1;
|
--ui-font-scale: 1 !important;
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 6px;
|
gap: 6px;
|
||||||
@@ -581,7 +581,7 @@
|
|||||||
position: fixed;
|
position: fixed;
|
||||||
top: 42px;
|
top: 42px;
|
||||||
left: 12px;
|
left: 12px;
|
||||||
width: min(522px, calc(100vw - 24px));
|
width: min(calc(522px * var(--ui-panel-scale, 1)), calc(100vw - 24px));
|
||||||
max-height: calc(100vh - 54px);
|
max-height: calc(100vh - 54px);
|
||||||
padding: var(--space-3) var(--space-4);
|
padding: var(--space-3) var(--space-4);
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -605,7 +605,7 @@
|
|||||||
position: fixed;
|
position: fixed;
|
||||||
top: 42px;
|
top: 42px;
|
||||||
left: 12px;
|
left: 12px;
|
||||||
width: min(464px, calc(100vw - 24px));
|
width: min(calc(464px * var(--ui-panel-scale, 1)), calc(100vw - 24px));
|
||||||
max-height: calc(100vh - 54px);
|
max-height: calc(100vh - 54px);
|
||||||
padding: 14px 16px;
|
padding: 14px 16px;
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -711,8 +711,8 @@
|
|||||||
.wm-pin-badge {
|
.wm-pin-badge {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
height: 16px;
|
min-height: calc(16px * var(--ui-font-scale, 1));
|
||||||
padding: 0 5px;
|
padding: 1px 5px;
|
||||||
font-size: var(--fs-xs);
|
font-size: var(--fs-xs);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: var(--accent-primary);
|
color: var(--accent-primary);
|
||||||
@@ -724,8 +724,8 @@
|
|||||||
.wm-session-tag {
|
.wm-session-tag {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
height: 16px;
|
min-height: calc(16px * var(--ui-font-scale, 1));
|
||||||
padding: 0 4px;
|
padding: 1px 4px;
|
||||||
font-size: var(--fs-xs);
|
font-size: var(--fs-xs);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
|
|||||||
@@ -43,16 +43,15 @@
|
|||||||
--border-strong: color-mix(in srgb, var(--border-hairline) 72%, var(--text-primary) 28%);
|
--border-strong: color-mix(in srgb, var(--border-hairline) 72%, var(--text-primary) 28%);
|
||||||
|
|
||||||
/* Typography Hierarchy & Scalable Font Tokens */
|
/* Typography Hierarchy & Scalable Font Tokens */
|
||||||
--ui-font-scale: 1;
|
--fs-2xs: calc(10.5px * var(--ui-font-scale, 1));
|
||||||
--fs-2xs: calc(9.5px * var(--ui-font-scale, 1));
|
--fs-xs: calc(11px * var(--ui-font-scale, 1));
|
||||||
--fs-xs: calc(10px * var(--ui-font-scale, 1));
|
--fs-sm: calc(11.5px * var(--ui-font-scale, 1));
|
||||||
--fs-sm: calc(10.5px * var(--ui-font-scale, 1));
|
--fs-md: calc(12px * var(--ui-font-scale, 1));
|
||||||
--fs-md: calc(11px * var(--ui-font-scale, 1));
|
--fs-base-sm: calc(12.5px * var(--ui-font-scale, 1));
|
||||||
--fs-base-sm: calc(11.5px * var(--ui-font-scale, 1));
|
--fs-base: calc(13px * var(--ui-font-scale, 1));
|
||||||
--fs-base: calc(12px * var(--ui-font-scale, 1));
|
--fs-body: calc(13px * var(--ui-font-scale, 1));
|
||||||
--fs-body: calc(12.5px * var(--ui-font-scale, 1));
|
--fs-lg: calc(15px * var(--ui-font-scale, 1));
|
||||||
--fs-lg: calc(14.5px * var(--ui-font-scale, 1));
|
--fs-hero: calc(18px * 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-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-secondary: var(--muted-foreground, var(--vscode-descriptionForeground, hsl(215 12% 44%)));
|
||||||
@@ -120,6 +119,46 @@
|
|||||||
--space-5: 12px;
|
--space-5: 12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
:root[data-font-scale="sm"],
|
||||||
|
:host([data-font-scale="sm"]),
|
||||||
|
[data-font-scale="sm"] {
|
||||||
|
--ui-font-scale: 0.92;
|
||||||
|
--ui-panel-scale: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
:root[data-font-scale="md"],
|
||||||
|
:host([data-font-scale="md"]),
|
||||||
|
[data-font-scale="md"] {
|
||||||
|
--ui-font-scale: 1;
|
||||||
|
--ui-panel-scale: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
:root[data-font-scale="lg"],
|
||||||
|
:host([data-font-scale="lg"]),
|
||||||
|
[data-font-scale="lg"] {
|
||||||
|
--ui-font-scale: 1.14;
|
||||||
|
--ui-panel-scale: 1.09;
|
||||||
|
}
|
||||||
|
|
||||||
|
:root[data-font-scale="xl"],
|
||||||
|
:host([data-font-scale="xl"]),
|
||||||
|
[data-font-scale="xl"] {
|
||||||
|
--ui-font-scale: 1.28;
|
||||||
|
--ui-panel-scale: 1.18;
|
||||||
|
}
|
||||||
|
|
||||||
|
[data-font-scale] {
|
||||||
|
--fs-2xs: calc(10.5px * var(--ui-font-scale, 1));
|
||||||
|
--fs-xs: calc(11px * var(--ui-font-scale, 1));
|
||||||
|
--fs-sm: calc(11.5px * var(--ui-font-scale, 1));
|
||||||
|
--fs-md: calc(12px * var(--ui-font-scale, 1));
|
||||||
|
--fs-base-sm: calc(12.5px * var(--ui-font-scale, 1));
|
||||||
|
--fs-base: calc(13px * var(--ui-font-scale, 1));
|
||||||
|
--fs-body: calc(13px * var(--ui-font-scale, 1));
|
||||||
|
--fs-lg: calc(15px * var(--ui-font-scale, 1));
|
||||||
|
--fs-hero: calc(18px * var(--ui-font-scale, 1));
|
||||||
|
}
|
||||||
|
|
||||||
@media (prefers-color-scheme: dark) {
|
@media (prefers-color-scheme: dark) {
|
||||||
html[data-standalone="true"] {
|
html[data-standalone="true"] {
|
||||||
color-scheme: dark;
|
color-scheme: dark;
|
||||||
|
|||||||
@@ -166,8 +166,8 @@
|
|||||||
.cons-row-title {
|
.cons-row-title {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
height: 20px;
|
min-height: calc(20px * var(--ui-font-scale, 1));
|
||||||
line-height: 20px;
|
line-height: 1.3;
|
||||||
font-size: var(--fs-base);
|
font-size: var(--fs-base);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
@@ -177,16 +177,16 @@
|
|||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 8px;
|
gap: 8px;
|
||||||
height: 20px;
|
min-height: calc(20px * var(--ui-font-scale, 1));
|
||||||
}
|
}
|
||||||
|
|
||||||
.cons-share-pill {
|
.cons-share-pill {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
height: 20px;
|
min-height: calc(20px * var(--ui-font-scale, 1));
|
||||||
line-height: 1;
|
line-height: 1.2;
|
||||||
padding: 0 6px;
|
padding: 1px 6px;
|
||||||
font-size: var(--fs-base);
|
font-size: var(--fs-base);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: var(--metric-ok);
|
color: var(--metric-ok);
|
||||||
@@ -199,8 +199,8 @@
|
|||||||
.cons-row-tok {
|
.cons-row-tok {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
height: 20px;
|
min-height: calc(20px * var(--ui-font-scale, 1));
|
||||||
line-height: 1;
|
line-height: 1.25;
|
||||||
font-size: var(--fs-base);
|
font-size: var(--fs-base);
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
@@ -209,8 +209,8 @@
|
|||||||
.cons-row-cost {
|
.cons-row-cost {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
height: 20px;
|
min-height: calc(20px * var(--ui-font-scale, 1));
|
||||||
line-height: 1;
|
line-height: 1.25;
|
||||||
font-size: var(--fs-base);
|
font-size: var(--fs-base);
|
||||||
font-weight: 700;
|
font-weight: 700;
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
@@ -287,7 +287,7 @@
|
|||||||
top: 2px;
|
top: 2px;
|
||||||
left: var(--peak-x, 50%);
|
left: var(--peak-x, 50%);
|
||||||
transform: translateX(-50%);
|
transform: translateX(-50%);
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
padding: 1px 6px;
|
padding: 1px 6px;
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
@@ -306,7 +306,7 @@
|
|||||||
transform: translateX(var(--tip-shift, -50%));
|
transform: translateX(var(--tip-shift, -50%));
|
||||||
width: max-content;
|
width: max-content;
|
||||||
min-width: 152px;
|
min-width: 152px;
|
||||||
max-width: min(300px, calc(100% - 8px));
|
max-width: min(320px, calc(100% - 8px));
|
||||||
padding: 5px 9px;
|
padding: 5px 9px;
|
||||||
background: var(--surface-panel);
|
background: var(--surface-panel);
|
||||||
border: 1px solid var(--border-strong);
|
border: 1px solid var(--border-strong);
|
||||||
@@ -324,7 +324,7 @@
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
gap: 10px;
|
gap: 10px;
|
||||||
font-size: 10.5px;
|
font-size: var(--fs-sm);
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -336,7 +336,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.trend-tip-calls {
|
.trend-tip-calls {
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
max-width: 190px;
|
max-width: 190px;
|
||||||
@@ -352,7 +352,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.trend-tip-tokens {
|
.trend-tip-tokens {
|
||||||
font-size: 12px;
|
font-size: var(--fs-base);
|
||||||
font-weight: 700;
|
font-weight: 700;
|
||||||
color: var(--accent-primary);
|
color: var(--accent-primary);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
@@ -360,7 +360,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.trend-tip-cost {
|
.trend-tip-cost {
|
||||||
font-size: 11px;
|
font-size: var(--fs-md);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
@@ -368,7 +368,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.trend-tip-sub {
|
.trend-tip-sub {
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
@@ -391,7 +391,7 @@
|
|||||||
.trend-x-axis {
|
.trend-x-axis {
|
||||||
position: relative;
|
position: relative;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 18px;
|
min-height: calc(18px * var(--ui-font-scale, 1));
|
||||||
user-select: none;
|
user-select: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -400,10 +400,10 @@
|
|||||||
top: 0;
|
top: 0;
|
||||||
left: var(--tick-x, 0%);
|
left: var(--tick-x, 0%);
|
||||||
transform: translateX(-50%);
|
transform: translateX(-50%);
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
line-height: 16px;
|
line-height: 1.35;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
transition: color var(--dur-instant) var(--ease-fast);
|
transition: color var(--dur-instant) var(--ease-fast);
|
||||||
}
|
}
|
||||||
@@ -455,21 +455,21 @@
|
|||||||
|
|
||||||
.trend-hm-weekdays {
|
.trend-hm-weekdays {
|
||||||
display: grid;
|
display: grid;
|
||||||
grid-template-rows: 15px repeat(7, var(--hm-cell));
|
grid-template-rows: calc(15px * var(--ui-font-scale, 1)) repeat(7, var(--hm-cell));
|
||||||
row-gap: var(--hm-gap);
|
row-gap: var(--hm-gap);
|
||||||
width: 14px;
|
width: calc(15px * var(--ui-font-scale, 1));
|
||||||
flex-shrink: 0;
|
flex-shrink: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.trend-hm-month-spacer {
|
.trend-hm-month-spacer {
|
||||||
height: 15px;
|
height: calc(15px * var(--ui-font-scale, 1));
|
||||||
}
|
}
|
||||||
|
|
||||||
.trend-hm-wday {
|
.trend-hm-wday {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: flex-start;
|
justify-content: flex-start;
|
||||||
font-size: 9px;
|
font-size: var(--fs-2xs);
|
||||||
line-height: 1;
|
line-height: 1;
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
}
|
}
|
||||||
@@ -490,7 +490,7 @@
|
|||||||
|
|
||||||
.trend-hm-months {
|
.trend-hm-months {
|
||||||
position: relative;
|
position: relative;
|
||||||
height: 15px;
|
height: calc(15px * var(--ui-font-scale, 1));
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -498,8 +498,8 @@
|
|||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
left: calc(var(--hm-col, 0) * (var(--hm-cell) + var(--hm-gap)));
|
left: calc(var(--hm-col, 0) * (var(--hm-cell) + var(--hm-gap)));
|
||||||
font-size: 9.5px;
|
font-size: var(--fs-2xs);
|
||||||
line-height: 14px;
|
line-height: 1.25;
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
@@ -564,7 +564,7 @@
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
gap: 8px;
|
gap: 8px;
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
min-height: 16px;
|
min-height: 16px;
|
||||||
}
|
}
|
||||||
@@ -581,7 +581,7 @@
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 3px;
|
gap: 3px;
|
||||||
flex-shrink: 0;
|
flex-shrink: 0;
|
||||||
font-size: 9.5px;
|
font-size: var(--fs-2xs);
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -642,7 +642,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.month-cost {
|
.month-cost {
|
||||||
font-size: 9.5px;
|
font-size: var(--fs-2xs);
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
min-height: 14px;
|
min-height: 14px;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
@@ -686,7 +686,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.month-label {
|
.month-label {
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
padding: 1px 3px;
|
padding: 1px 3px;
|
||||||
border-radius: var(--radius-xs);
|
border-radius: var(--radius-xs);
|
||||||
@@ -700,7 +700,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.month-tok {
|
.month-tok {
|
||||||
font-size: 9px;
|
font-size: var(--fs-2xs);
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
min-height: 12px;
|
min-height: 12px;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
|
|||||||
@@ -156,8 +156,8 @@
|
|||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 3px;
|
gap: 3px;
|
||||||
height: 18px;
|
min-height: calc(18px * var(--ui-font-scale, 1));
|
||||||
padding: 0 6px;
|
padding: 1px 6px;
|
||||||
font-size: var(--fs-sm);
|
font-size: var(--fs-sm);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
@@ -547,8 +547,8 @@
|
|||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
height: 20px;
|
min-height: calc(20px * var(--ui-font-scale, 1));
|
||||||
padding: 0 6px;
|
padding: 1px 6px;
|
||||||
border: 1px solid var(--border-hairline);
|
border: 1px solid var(--border-hairline);
|
||||||
background: var(--surface-panel);
|
background: var(--surface-panel);
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
|
|||||||
@@ -37,7 +37,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.settings-subnav-bar .seg-btn {
|
.settings-subnav-bar .seg-btn {
|
||||||
height: 24px;
|
min-height: calc(24px * var(--ui-font-scale, 1));
|
||||||
font-size: var(--fs-base-sm);
|
font-size: var(--fs-base-sm);
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
}
|
}
|
||||||
@@ -55,9 +55,9 @@
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
height: 25px;
|
min-height: calc(25px * var(--ui-font-scale, 1));
|
||||||
min-width: 0;
|
min-width: 0;
|
||||||
padding: 0 6px;
|
padding: 2px 6px;
|
||||||
border: 1px solid var(--border-hairline);
|
border: 1px solid var(--border-hairline);
|
||||||
border-radius: var(--radius-xs);
|
border-radius: var(--radius-xs);
|
||||||
background: var(--surface-subtle);
|
background: var(--surface-subtle);
|
||||||
@@ -116,8 +116,8 @@
|
|||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 5px;
|
gap: 5px;
|
||||||
height: 24px;
|
min-height: calc(24px * var(--ui-font-scale, 1));
|
||||||
padding: 0 9px;
|
padding: 2px 9px;
|
||||||
font-size: var(--fs-md);
|
font-size: var(--fs-md);
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
@@ -240,7 +240,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.structure-preview-canvas.is-scaled {
|
.structure-preview-canvas.is-scaled {
|
||||||
zoom: 0.86;
|
zoom: 0.9;
|
||||||
}
|
}
|
||||||
|
|
||||||
.wm-hover-tip.is-preview {
|
.wm-hover-tip.is-preview {
|
||||||
@@ -286,6 +286,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.preview-capsule-bar {
|
.preview-capsule-bar {
|
||||||
|
--ui-font-scale: 1;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
@@ -431,8 +432,8 @@
|
|||||||
.collapsible-badge {
|
.collapsible-badge {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
height: 18px;
|
min-height: calc(18px * var(--ui-font-scale, 1));
|
||||||
padding: 0 6px;
|
padding: 1px 6px;
|
||||||
font-size: var(--fs-sm);
|
font-size: var(--fs-sm);
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
@@ -577,8 +578,8 @@
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 5px;
|
gap: 5px;
|
||||||
height: 24px;
|
min-height: calc(24px * var(--ui-font-scale, 1));
|
||||||
padding: 0 9px;
|
padding: 2px 9px;
|
||||||
font-size: var(--fs-md);
|
font-size: var(--fs-md);
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
color: var(--accent-primary);
|
color: var(--accent-primary);
|
||||||
@@ -711,8 +712,8 @@
|
|||||||
.settings-text-input {
|
.settings-text-input {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
min-width: 0;
|
min-width: 0;
|
||||||
height: 28px;
|
min-height: calc(28px * var(--ui-font-scale, 1));
|
||||||
padding: 0 8px;
|
padding: 2px 8px;
|
||||||
background: var(--surface-subtle);
|
background: var(--surface-subtle);
|
||||||
border: 1px solid var(--border-hairline);
|
border: 1px solid var(--border-hairline);
|
||||||
border-radius: var(--radius-xs);
|
border-radius: var(--radius-xs);
|
||||||
@@ -738,7 +739,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.settings-number-wrap .number-input {
|
.settings-number-wrap .number-input {
|
||||||
height: 24px;
|
min-height: calc(24px * var(--ui-font-scale, 1));
|
||||||
background: var(--surface-subtle);
|
background: var(--surface-subtle);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -831,7 +832,7 @@
|
|||||||
|
|
||||||
.ctx-risk-accept-btn {
|
.ctx-risk-accept-btn {
|
||||||
margin-top: 2px;
|
margin-top: 2px;
|
||||||
height: 26px;
|
min-height: calc(26px * var(--ui-font-scale, 1));
|
||||||
padding: 0 var(--space-3);
|
padding: 2px var(--space-3);
|
||||||
font-size: var(--fs-md);
|
font-size: var(--fs-md);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -35,13 +35,14 @@
|
|||||||
.data-table {
|
.data-table {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
border-collapse: collapse;
|
border-collapse: collapse;
|
||||||
font-size: var(--fs-md);
|
font-size: var(--fs-base-sm);
|
||||||
}
|
}
|
||||||
|
|
||||||
.data-table th,
|
.data-table th,
|
||||||
.data-table td {
|
.data-table td {
|
||||||
padding: 5px 4px;
|
padding: calc(5px * var(--ui-font-scale, 1)) calc(4px * var(--ui-font-scale, 1));
|
||||||
text-align: left;
|
text-align: left;
|
||||||
|
font-size: var(--fs-base-sm);
|
||||||
border-bottom: 1px solid var(--border-hairline);
|
border-bottom: 1px solid var(--border-hairline);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
@@ -78,7 +79,7 @@
|
|||||||
.step-model-cell {
|
.step-model-cell {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: baseline;
|
align-items: baseline;
|
||||||
max-width: var(--step-model-max-w, 176px);
|
max-width: calc(var(--step-model-max-w, 176px) * var(--ui-font-scale, 1));
|
||||||
min-width: 0;
|
min-width: 0;
|
||||||
vertical-align: bottom;
|
vertical-align: bottom;
|
||||||
}
|
}
|
||||||
@@ -133,8 +134,9 @@
|
|||||||
|
|
||||||
.steps-inline-scope-select .select-trigger,
|
.steps-inline-scope-select .select-trigger,
|
||||||
.steps-inline-model-select .select-trigger {
|
.steps-inline-model-select .select-trigger {
|
||||||
height: 22px;
|
min-height: calc(22px * var(--ui-font-scale, 1));
|
||||||
padding: 0 6px;
|
height: auto;
|
||||||
|
padding: 2px 6px;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
min-width: 0;
|
min-width: 0;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
@@ -320,8 +322,9 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.sstep-fit-model-select .select-trigger {
|
.sstep-fit-model-select .select-trigger {
|
||||||
height: 22px;
|
min-height: calc(22px * var(--ui-font-scale, 1));
|
||||||
padding: 0 6px;
|
height: auto;
|
||||||
|
padding: 2px 6px;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
min-width: 0;
|
min-width: 0;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
@@ -377,7 +380,7 @@
|
|||||||
.sstep-axis-label {
|
.sstep-axis-label {
|
||||||
fill: var(--text-muted);
|
fill: var(--text-muted);
|
||||||
font-family: var(--font-mono, ui-monospace, SFMono-Regular, Menlo, Consolas, monospace);
|
font-family: var(--font-mono, ui-monospace, SFMono-Regular, Menlo, Consolas, monospace);
|
||||||
font-size: 9.5px;
|
font-size: var(--fs-2xs);
|
||||||
user-select: none;
|
user-select: none;
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
}
|
}
|
||||||
@@ -485,7 +488,7 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
font-size: 11px;
|
font-size: var(--fs-md);
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
z-index: 2;
|
z-index: 2;
|
||||||
}
|
}
|
||||||
@@ -496,7 +499,7 @@
|
|||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
gap: 4px 10px;
|
gap: 4px 10px;
|
||||||
padding-top: 2px;
|
padding-top: 2px;
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -535,7 +538,7 @@
|
|||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
gap: 4px 8px;
|
gap: 4px 8px;
|
||||||
padding-top: 2px;
|
padding-top: 2px;
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -595,7 +598,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.sstep-fit-delta {
|
.sstep-fit-delta {
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* --- 4. 极简高密度模型总览列表 (Minimalist Session Model Summary Cards) --- */
|
/* --- 4. 极简高密度模型总览列表 (Minimalist Session Model Summary Cards) --- */
|
||||||
|
|||||||
+153
-104
@@ -44,16 +44,15 @@
|
|||||||
--border-strong: color-mix(in srgb, var(--border-hairline) 72%, var(--text-primary) 28%);
|
--border-strong: color-mix(in srgb, var(--border-hairline) 72%, var(--text-primary) 28%);
|
||||||
|
|
||||||
/* Typography Hierarchy & Scalable Font Tokens */
|
/* Typography Hierarchy & Scalable Font Tokens */
|
||||||
--ui-font-scale: 1;
|
--fs-2xs: calc(10.5px * var(--ui-font-scale, 1));
|
||||||
--fs-2xs: calc(9.5px * var(--ui-font-scale, 1));
|
--fs-xs: calc(11px * var(--ui-font-scale, 1));
|
||||||
--fs-xs: calc(10px * var(--ui-font-scale, 1));
|
--fs-sm: calc(11.5px * var(--ui-font-scale, 1));
|
||||||
--fs-sm: calc(10.5px * var(--ui-font-scale, 1));
|
--fs-md: calc(12px * var(--ui-font-scale, 1));
|
||||||
--fs-md: calc(11px * var(--ui-font-scale, 1));
|
--fs-base-sm: calc(12.5px * var(--ui-font-scale, 1));
|
||||||
--fs-base-sm: calc(11.5px * var(--ui-font-scale, 1));
|
--fs-base: calc(13px * var(--ui-font-scale, 1));
|
||||||
--fs-base: calc(12px * var(--ui-font-scale, 1));
|
--fs-body: calc(13px * var(--ui-font-scale, 1));
|
||||||
--fs-body: calc(12.5px * var(--ui-font-scale, 1));
|
--fs-lg: calc(15px * var(--ui-font-scale, 1));
|
||||||
--fs-lg: calc(14.5px * var(--ui-font-scale, 1));
|
--fs-hero: calc(18px * 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-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-secondary: var(--muted-foreground, var(--vscode-descriptionForeground, hsl(215 12% 44%)));
|
||||||
@@ -121,6 +120,46 @@
|
|||||||
--space-5: 12px;
|
--space-5: 12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
:root[data-font-scale="sm"],
|
||||||
|
:host([data-font-scale="sm"]),
|
||||||
|
[data-font-scale="sm"] {
|
||||||
|
--ui-font-scale: 0.92;
|
||||||
|
--ui-panel-scale: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
:root[data-font-scale="md"],
|
||||||
|
:host([data-font-scale="md"]),
|
||||||
|
[data-font-scale="md"] {
|
||||||
|
--ui-font-scale: 1;
|
||||||
|
--ui-panel-scale: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
:root[data-font-scale="lg"],
|
||||||
|
:host([data-font-scale="lg"]),
|
||||||
|
[data-font-scale="lg"] {
|
||||||
|
--ui-font-scale: 1.14;
|
||||||
|
--ui-panel-scale: 1.09;
|
||||||
|
}
|
||||||
|
|
||||||
|
:root[data-font-scale="xl"],
|
||||||
|
:host([data-font-scale="xl"]),
|
||||||
|
[data-font-scale="xl"] {
|
||||||
|
--ui-font-scale: 1.28;
|
||||||
|
--ui-panel-scale: 1.18;
|
||||||
|
}
|
||||||
|
|
||||||
|
[data-font-scale] {
|
||||||
|
--fs-2xs: calc(10.5px * var(--ui-font-scale, 1));
|
||||||
|
--fs-xs: calc(11px * var(--ui-font-scale, 1));
|
||||||
|
--fs-sm: calc(11.5px * var(--ui-font-scale, 1));
|
||||||
|
--fs-md: calc(12px * var(--ui-font-scale, 1));
|
||||||
|
--fs-base-sm: calc(12.5px * var(--ui-font-scale, 1));
|
||||||
|
--fs-base: calc(13px * var(--ui-font-scale, 1));
|
||||||
|
--fs-body: calc(13px * var(--ui-font-scale, 1));
|
||||||
|
--fs-lg: calc(15px * var(--ui-font-scale, 1));
|
||||||
|
--fs-hero: calc(18px * var(--ui-font-scale, 1));
|
||||||
|
}
|
||||||
|
|
||||||
@media (prefers-color-scheme: dark) {
|
@media (prefers-color-scheme: dark) {
|
||||||
html[data-standalone="true"] {
|
html[data-standalone="true"] {
|
||||||
color-scheme: dark;
|
color-scheme: dark;
|
||||||
@@ -173,7 +212,12 @@ body {
|
|||||||
}
|
}
|
||||||
|
|
||||||
button,
|
button,
|
||||||
input {
|
input,
|
||||||
|
select,
|
||||||
|
textarea,
|
||||||
|
table,
|
||||||
|
th,
|
||||||
|
td {
|
||||||
font-family: inherit;
|
font-family: inherit;
|
||||||
font-size: inherit;
|
font-size: inherit;
|
||||||
font-stretch: inherit;
|
font-stretch: inherit;
|
||||||
@@ -471,14 +515,14 @@ html[data-standalone="true"] .app-shell {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 5px;
|
gap: 5px;
|
||||||
height: 26px;
|
min-height: calc(26px * var(--ui-font-scale, 1));
|
||||||
padding: 0 var(--space-2);
|
padding: 2px var(--space-2);
|
||||||
border: none;
|
border: none;
|
||||||
background: transparent;
|
background: transparent;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
font-size: var(--fs-base);
|
font-size: var(--fs-base);
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
line-height: 1;
|
line-height: 1.15;
|
||||||
border-radius: var(--radius-pill);
|
border-radius: var(--radius-pill);
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
@@ -497,8 +541,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
.pill-tab-badge {
|
.pill-tab-badge {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
height: 14px;
|
min-height: 14px;
|
||||||
line-height: 1;
|
line-height: 1.15;
|
||||||
}
|
}
|
||||||
|
|
||||||
.pill-tab-badge {
|
.pill-tab-badge {
|
||||||
@@ -545,8 +589,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
gap: var(--space-2);
|
gap: var(--space-2);
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 24px;
|
min-height: calc(24px * var(--ui-font-scale, 1));
|
||||||
padding: 0 6px;
|
padding: 2px 6px;
|
||||||
background: transparent;
|
background: transparent;
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
border: none;
|
border: none;
|
||||||
@@ -672,7 +716,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
.number-input {
|
.number-input {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: stretch;
|
align-items: stretch;
|
||||||
height: 28px;
|
min-height: calc(28px * var(--ui-font-scale, 1));
|
||||||
background: var(--surface-panel);
|
background: var(--surface-panel);
|
||||||
border: 1px solid var(--border-hairline);
|
border: 1px solid var(--border-hairline);
|
||||||
border-radius: var(--radius-xs);
|
border-radius: var(--radius-xs);
|
||||||
@@ -732,8 +776,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
gap: var(--space-2);
|
gap: var(--space-2);
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 26px;
|
min-height: calc(26px * var(--ui-font-scale, 1));
|
||||||
padding: 0 var(--space-2);
|
padding: 2px var(--space-2);
|
||||||
background: var(--surface-panel);
|
background: var(--surface-panel);
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
border: 1px solid var(--border-hairline);
|
border: 1px solid var(--border-hairline);
|
||||||
@@ -786,7 +830,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.dt-day {
|
.dt-day {
|
||||||
height: 22px;
|
min-height: calc(22px * var(--ui-font-scale, 1));
|
||||||
border: none;
|
border: none;
|
||||||
background: transparent;
|
background: transparent;
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
@@ -862,8 +906,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
height: 22px;
|
min-height: calc(22px * var(--ui-font-scale, 1));
|
||||||
padding: 0 7px;
|
padding: 2px 7px;
|
||||||
border: none;
|
border: none;
|
||||||
background: transparent;
|
background: transparent;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
@@ -972,8 +1016,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 6px;
|
gap: 6px;
|
||||||
height: 28px;
|
min-height: calc(28px * var(--ui-font-scale, 1));
|
||||||
padding: 0 var(--space-5);
|
padding: 3px var(--space-5);
|
||||||
background: var(--accent-primary);
|
background: var(--accent-primary);
|
||||||
color: var(--text-inverse);
|
color: var(--text-inverse);
|
||||||
border: 1px solid var(--accent-primary);
|
border: 1px solid var(--accent-primary);
|
||||||
@@ -997,8 +1041,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 6px;
|
gap: 6px;
|
||||||
height: 28px;
|
min-height: calc(28px * var(--ui-font-scale, 1));
|
||||||
padding: 0 var(--space-4);
|
padding: 3px var(--space-4);
|
||||||
background: var(--surface-panel);
|
background: var(--surface-panel);
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
border: 1px solid var(--border-strong);
|
border: 1px solid var(--border-strong);
|
||||||
@@ -1036,8 +1080,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
height: 22px;
|
min-height: calc(22px * var(--ui-font-scale, 1));
|
||||||
padding: 0 7px;
|
padding: 2px 7px;
|
||||||
font-size: var(--fs-md);
|
font-size: var(--fs-md);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
border-radius: var(--radius-xs);
|
border-radius: var(--radius-xs);
|
||||||
@@ -1070,8 +1114,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
height: 20px;
|
min-height: calc(20px * var(--ui-font-scale, 1));
|
||||||
padding: 0 6px;
|
padding: 1px 6px;
|
||||||
font-size: var(--fs-md);
|
font-size: var(--fs-md);
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
@@ -1101,8 +1145,9 @@ html[data-standalone="true"] .app-shell {
|
|||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
width: 16px;
|
min-width: calc(16px * var(--ui-font-scale, 1));
|
||||||
height: 16px;
|
min-height: calc(16px * var(--ui-font-scale, 1));
|
||||||
|
padding: 0 3px;
|
||||||
font-size: var(--fs-sm);
|
font-size: var(--fs-sm);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
font-variant-numeric: tabular-nums;
|
font-variant-numeric: tabular-nums;
|
||||||
@@ -1309,8 +1354,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 3px;
|
gap: 3px;
|
||||||
height: 18px;
|
min-height: calc(18px * var(--ui-font-scale, 1));
|
||||||
padding: 0 6px;
|
padding: 1px 6px;
|
||||||
font-size: var(--fs-sm);
|
font-size: var(--fs-sm);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
@@ -1700,8 +1745,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
height: 20px;
|
min-height: calc(20px * var(--ui-font-scale, 1));
|
||||||
padding: 0 6px;
|
padding: 1px 6px;
|
||||||
border: 1px solid var(--border-hairline);
|
border: 1px solid var(--border-hairline);
|
||||||
background: var(--surface-panel);
|
background: var(--surface-panel);
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
@@ -1971,8 +2016,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
.cons-row-title {
|
.cons-row-title {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
height: 20px;
|
min-height: calc(20px * var(--ui-font-scale, 1));
|
||||||
line-height: 20px;
|
line-height: 1.3;
|
||||||
font-size: var(--fs-base);
|
font-size: var(--fs-base);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
@@ -1982,16 +2027,16 @@ html[data-standalone="true"] .app-shell {
|
|||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 8px;
|
gap: 8px;
|
||||||
height: 20px;
|
min-height: calc(20px * var(--ui-font-scale, 1));
|
||||||
}
|
}
|
||||||
|
|
||||||
.cons-share-pill {
|
.cons-share-pill {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
height: 20px;
|
min-height: calc(20px * var(--ui-font-scale, 1));
|
||||||
line-height: 1;
|
line-height: 1.2;
|
||||||
padding: 0 6px;
|
padding: 1px 6px;
|
||||||
font-size: var(--fs-base);
|
font-size: var(--fs-base);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: var(--metric-ok);
|
color: var(--metric-ok);
|
||||||
@@ -2004,8 +2049,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
.cons-row-tok {
|
.cons-row-tok {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
height: 20px;
|
min-height: calc(20px * var(--ui-font-scale, 1));
|
||||||
line-height: 1;
|
line-height: 1.25;
|
||||||
font-size: var(--fs-base);
|
font-size: var(--fs-base);
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
@@ -2014,8 +2059,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
.cons-row-cost {
|
.cons-row-cost {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
height: 20px;
|
min-height: calc(20px * var(--ui-font-scale, 1));
|
||||||
line-height: 1;
|
line-height: 1.25;
|
||||||
font-size: var(--fs-base);
|
font-size: var(--fs-base);
|
||||||
font-weight: 700;
|
font-weight: 700;
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
@@ -2092,7 +2137,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
top: 2px;
|
top: 2px;
|
||||||
left: var(--peak-x, 50%);
|
left: var(--peak-x, 50%);
|
||||||
transform: translateX(-50%);
|
transform: translateX(-50%);
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
padding: 1px 6px;
|
padding: 1px 6px;
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
@@ -2111,7 +2156,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
transform: translateX(var(--tip-shift, -50%));
|
transform: translateX(var(--tip-shift, -50%));
|
||||||
width: max-content;
|
width: max-content;
|
||||||
min-width: 152px;
|
min-width: 152px;
|
||||||
max-width: min(300px, calc(100% - 8px));
|
max-width: min(320px, calc(100% - 8px));
|
||||||
padding: 5px 9px;
|
padding: 5px 9px;
|
||||||
background: var(--surface-panel);
|
background: var(--surface-panel);
|
||||||
border: 1px solid var(--border-strong);
|
border: 1px solid var(--border-strong);
|
||||||
@@ -2129,7 +2174,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
gap: 10px;
|
gap: 10px;
|
||||||
font-size: 10.5px;
|
font-size: var(--fs-sm);
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2141,7 +2186,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.trend-tip-calls {
|
.trend-tip-calls {
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
max-width: 190px;
|
max-width: 190px;
|
||||||
@@ -2157,7 +2202,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.trend-tip-tokens {
|
.trend-tip-tokens {
|
||||||
font-size: 12px;
|
font-size: var(--fs-base);
|
||||||
font-weight: 700;
|
font-weight: 700;
|
||||||
color: var(--accent-primary);
|
color: var(--accent-primary);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
@@ -2165,7 +2210,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.trend-tip-cost {
|
.trend-tip-cost {
|
||||||
font-size: 11px;
|
font-size: var(--fs-md);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
@@ -2173,7 +2218,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.trend-tip-sub {
|
.trend-tip-sub {
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
@@ -2196,7 +2241,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
.trend-x-axis {
|
.trend-x-axis {
|
||||||
position: relative;
|
position: relative;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 18px;
|
min-height: calc(18px * var(--ui-font-scale, 1));
|
||||||
user-select: none;
|
user-select: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2205,10 +2250,10 @@ html[data-standalone="true"] .app-shell {
|
|||||||
top: 0;
|
top: 0;
|
||||||
left: var(--tick-x, 0%);
|
left: var(--tick-x, 0%);
|
||||||
transform: translateX(-50%);
|
transform: translateX(-50%);
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
line-height: 16px;
|
line-height: 1.35;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
transition: color var(--dur-instant) var(--ease-fast);
|
transition: color var(--dur-instant) var(--ease-fast);
|
||||||
}
|
}
|
||||||
@@ -2260,21 +2305,21 @@ html[data-standalone="true"] .app-shell {
|
|||||||
|
|
||||||
.trend-hm-weekdays {
|
.trend-hm-weekdays {
|
||||||
display: grid;
|
display: grid;
|
||||||
grid-template-rows: 15px repeat(7, var(--hm-cell));
|
grid-template-rows: calc(15px * var(--ui-font-scale, 1)) repeat(7, var(--hm-cell));
|
||||||
row-gap: var(--hm-gap);
|
row-gap: var(--hm-gap);
|
||||||
width: 14px;
|
width: calc(15px * var(--ui-font-scale, 1));
|
||||||
flex-shrink: 0;
|
flex-shrink: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.trend-hm-month-spacer {
|
.trend-hm-month-spacer {
|
||||||
height: 15px;
|
height: calc(15px * var(--ui-font-scale, 1));
|
||||||
}
|
}
|
||||||
|
|
||||||
.trend-hm-wday {
|
.trend-hm-wday {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: flex-start;
|
justify-content: flex-start;
|
||||||
font-size: 9px;
|
font-size: var(--fs-2xs);
|
||||||
line-height: 1;
|
line-height: 1;
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
}
|
}
|
||||||
@@ -2295,7 +2340,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
|
|
||||||
.trend-hm-months {
|
.trend-hm-months {
|
||||||
position: relative;
|
position: relative;
|
||||||
height: 15px;
|
height: calc(15px * var(--ui-font-scale, 1));
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2303,8 +2348,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
left: calc(var(--hm-col, 0) * (var(--hm-cell) + var(--hm-gap)));
|
left: calc(var(--hm-col, 0) * (var(--hm-cell) + var(--hm-gap)));
|
||||||
font-size: 9.5px;
|
font-size: var(--fs-2xs);
|
||||||
line-height: 14px;
|
line-height: 1.25;
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
@@ -2369,7 +2414,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
gap: 8px;
|
gap: 8px;
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
min-height: 16px;
|
min-height: 16px;
|
||||||
}
|
}
|
||||||
@@ -2386,7 +2431,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 3px;
|
gap: 3px;
|
||||||
flex-shrink: 0;
|
flex-shrink: 0;
|
||||||
font-size: 9.5px;
|
font-size: var(--fs-2xs);
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2447,7 +2492,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.month-cost {
|
.month-cost {
|
||||||
font-size: 9.5px;
|
font-size: var(--fs-2xs);
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
min-height: 14px;
|
min-height: 14px;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
@@ -2491,7 +2536,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.month-label {
|
.month-label {
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
padding: 1px 3px;
|
padding: 1px 3px;
|
||||||
border-radius: var(--radius-xs);
|
border-radius: var(--radius-xs);
|
||||||
@@ -2505,7 +2550,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.month-tok {
|
.month-tok {
|
||||||
font-size: 9px;
|
font-size: var(--fs-2xs);
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
min-height: 12px;
|
min-height: 12px;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
@@ -2559,13 +2604,14 @@ html[data-standalone="true"] .app-shell {
|
|||||||
.data-table {
|
.data-table {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
border-collapse: collapse;
|
border-collapse: collapse;
|
||||||
font-size: var(--fs-md);
|
font-size: var(--fs-base-sm);
|
||||||
}
|
}
|
||||||
|
|
||||||
.data-table th,
|
.data-table th,
|
||||||
.data-table td {
|
.data-table td {
|
||||||
padding: 5px 4px;
|
padding: calc(5px * var(--ui-font-scale, 1)) calc(4px * var(--ui-font-scale, 1));
|
||||||
text-align: left;
|
text-align: left;
|
||||||
|
font-size: var(--fs-base-sm);
|
||||||
border-bottom: 1px solid var(--border-hairline);
|
border-bottom: 1px solid var(--border-hairline);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
@@ -2602,7 +2648,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
.step-model-cell {
|
.step-model-cell {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: baseline;
|
align-items: baseline;
|
||||||
max-width: var(--step-model-max-w, 176px);
|
max-width: calc(var(--step-model-max-w, 176px) * var(--ui-font-scale, 1));
|
||||||
min-width: 0;
|
min-width: 0;
|
||||||
vertical-align: bottom;
|
vertical-align: bottom;
|
||||||
}
|
}
|
||||||
@@ -2657,8 +2703,9 @@ html[data-standalone="true"] .app-shell {
|
|||||||
|
|
||||||
.steps-inline-scope-select .select-trigger,
|
.steps-inline-scope-select .select-trigger,
|
||||||
.steps-inline-model-select .select-trigger {
|
.steps-inline-model-select .select-trigger {
|
||||||
height: 22px;
|
min-height: calc(22px * var(--ui-font-scale, 1));
|
||||||
padding: 0 6px;
|
height: auto;
|
||||||
|
padding: 2px 6px;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
min-width: 0;
|
min-width: 0;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
@@ -2844,8 +2891,9 @@ html[data-standalone="true"] .app-shell {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.sstep-fit-model-select .select-trigger {
|
.sstep-fit-model-select .select-trigger {
|
||||||
height: 22px;
|
min-height: calc(22px * var(--ui-font-scale, 1));
|
||||||
padding: 0 6px;
|
height: auto;
|
||||||
|
padding: 2px 6px;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
min-width: 0;
|
min-width: 0;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
@@ -2901,7 +2949,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
.sstep-axis-label {
|
.sstep-axis-label {
|
||||||
fill: var(--text-muted);
|
fill: var(--text-muted);
|
||||||
font-family: var(--font-mono, ui-monospace, SFMono-Regular, Menlo, Consolas, monospace);
|
font-family: var(--font-mono, ui-monospace, SFMono-Regular, Menlo, Consolas, monospace);
|
||||||
font-size: 9.5px;
|
font-size: var(--fs-2xs);
|
||||||
user-select: none;
|
user-select: none;
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
}
|
}
|
||||||
@@ -3009,7 +3057,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
font-size: 11px;
|
font-size: var(--fs-md);
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
z-index: 2;
|
z-index: 2;
|
||||||
}
|
}
|
||||||
@@ -3020,7 +3068,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
gap: 4px 10px;
|
gap: 4px 10px;
|
||||||
padding-top: 2px;
|
padding-top: 2px;
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3059,7 +3107,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
gap: 4px 8px;
|
gap: 4px 8px;
|
||||||
padding-top: 2px;
|
padding-top: 2px;
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
color: var(--text-muted);
|
color: var(--text-muted);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3119,7 +3167,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.sstep-fit-delta {
|
.sstep-fit-delta {
|
||||||
font-size: 10px;
|
font-size: var(--fs-xs);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* --- 4. 极简高密度模型总览列表 (Minimalist Session Model Summary Cards) --- */
|
/* --- 4. 极简高密度模型总览列表 (Minimalist Session Model Summary Cards) --- */
|
||||||
@@ -3292,7 +3340,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.settings-subnav-bar .seg-btn {
|
.settings-subnav-bar .seg-btn {
|
||||||
height: 24px;
|
min-height: calc(24px * var(--ui-font-scale, 1));
|
||||||
font-size: var(--fs-base-sm);
|
font-size: var(--fs-base-sm);
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
}
|
}
|
||||||
@@ -3310,9 +3358,9 @@ html[data-standalone="true"] .app-shell {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 4px;
|
gap: 4px;
|
||||||
height: 25px;
|
min-height: calc(25px * var(--ui-font-scale, 1));
|
||||||
min-width: 0;
|
min-width: 0;
|
||||||
padding: 0 6px;
|
padding: 2px 6px;
|
||||||
border: 1px solid var(--border-hairline);
|
border: 1px solid var(--border-hairline);
|
||||||
border-radius: var(--radius-xs);
|
border-radius: var(--radius-xs);
|
||||||
background: var(--surface-subtle);
|
background: var(--surface-subtle);
|
||||||
@@ -3371,8 +3419,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 5px;
|
gap: 5px;
|
||||||
height: 24px;
|
min-height: calc(24px * var(--ui-font-scale, 1));
|
||||||
padding: 0 9px;
|
padding: 2px 9px;
|
||||||
font-size: var(--fs-md);
|
font-size: var(--fs-md);
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
@@ -3495,7 +3543,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.structure-preview-canvas.is-scaled {
|
.structure-preview-canvas.is-scaled {
|
||||||
zoom: 0.86;
|
zoom: 0.9;
|
||||||
}
|
}
|
||||||
|
|
||||||
.wm-hover-tip.is-preview {
|
.wm-hover-tip.is-preview {
|
||||||
@@ -3541,6 +3589,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.preview-capsule-bar {
|
.preview-capsule-bar {
|
||||||
|
--ui-font-scale: 1;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
@@ -3686,8 +3735,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
.collapsible-badge {
|
.collapsible-badge {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
height: 18px;
|
min-height: calc(18px * var(--ui-font-scale, 1));
|
||||||
padding: 0 6px;
|
padding: 1px 6px;
|
||||||
font-size: var(--fs-sm);
|
font-size: var(--fs-sm);
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
@@ -3832,8 +3881,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
gap: 5px;
|
gap: 5px;
|
||||||
height: 24px;
|
min-height: calc(24px * var(--ui-font-scale, 1));
|
||||||
padding: 0 9px;
|
padding: 2px 9px;
|
||||||
font-size: var(--fs-md);
|
font-size: var(--fs-md);
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
color: var(--accent-primary);
|
color: var(--accent-primary);
|
||||||
@@ -3966,8 +4015,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
.settings-text-input {
|
.settings-text-input {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
min-width: 0;
|
min-width: 0;
|
||||||
height: 28px;
|
min-height: calc(28px * var(--ui-font-scale, 1));
|
||||||
padding: 0 8px;
|
padding: 2px 8px;
|
||||||
background: var(--surface-subtle);
|
background: var(--surface-subtle);
|
||||||
border: 1px solid var(--border-hairline);
|
border: 1px solid var(--border-hairline);
|
||||||
border-radius: var(--radius-xs);
|
border-radius: var(--radius-xs);
|
||||||
@@ -3993,7 +4042,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.settings-number-wrap .number-input {
|
.settings-number-wrap .number-input {
|
||||||
height: 24px;
|
min-height: calc(24px * var(--ui-font-scale, 1));
|
||||||
background: var(--surface-subtle);
|
background: var(--surface-subtle);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -4086,8 +4135,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
|
|
||||||
.ctx-risk-accept-btn {
|
.ctx-risk-accept-btn {
|
||||||
margin-top: 2px;
|
margin-top: 2px;
|
||||||
height: 26px;
|
min-height: calc(26px * var(--ui-font-scale, 1));
|
||||||
padding: 0 var(--space-3);
|
padding: 2px var(--space-3);
|
||||||
font-size: var(--fs-md);
|
font-size: var(--fs-md);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -4099,7 +4148,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
|
|
||||||
/* --- 1. 顶栏胶囊宿主容器 (Titlebar Capsule Host) --- */
|
/* --- 1. 顶栏胶囊宿主容器 (Titlebar Capsule Host) --- */
|
||||||
:host(.wm-capsule-host) {
|
:host(.wm-capsule-host) {
|
||||||
--ui-font-scale: 1;
|
--ui-font-scale: 1 !important;
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 6px;
|
gap: 6px;
|
||||||
@@ -4675,7 +4724,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
position: fixed;
|
position: fixed;
|
||||||
top: 42px;
|
top: 42px;
|
||||||
left: 12px;
|
left: 12px;
|
||||||
width: min(522px, calc(100vw - 24px));
|
width: min(calc(522px * var(--ui-panel-scale, 1)), calc(100vw - 24px));
|
||||||
max-height: calc(100vh - 54px);
|
max-height: calc(100vh - 54px);
|
||||||
padding: var(--space-3) var(--space-4);
|
padding: var(--space-3) var(--space-4);
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -4699,7 +4748,7 @@ html[data-standalone="true"] .app-shell {
|
|||||||
position: fixed;
|
position: fixed;
|
||||||
top: 42px;
|
top: 42px;
|
||||||
left: 12px;
|
left: 12px;
|
||||||
width: min(464px, calc(100vw - 24px));
|
width: min(calc(464px * var(--ui-panel-scale, 1)), calc(100vw - 24px));
|
||||||
max-height: calc(100vh - 54px);
|
max-height: calc(100vh - 54px);
|
||||||
padding: 14px 16px;
|
padding: 14px 16px;
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -4805,8 +4854,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
.wm-pin-badge {
|
.wm-pin-badge {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
height: 16px;
|
min-height: calc(16px * var(--ui-font-scale, 1));
|
||||||
padding: 0 5px;
|
padding: 1px 5px;
|
||||||
font-size: var(--fs-xs);
|
font-size: var(--fs-xs);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: var(--accent-primary);
|
color: var(--accent-primary);
|
||||||
@@ -4818,8 +4867,8 @@ html[data-standalone="true"] .app-shell {
|
|||||||
.wm-session-tag {
|
.wm-session-tag {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
height: 16px;
|
min-height: calc(16px * var(--ui-font-scale, 1));
|
||||||
padding: 0 4px;
|
padding: 1px 4px;
|
||||||
font-size: var(--fs-xs);
|
font-size: var(--fs-xs);
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
|
|||||||
@@ -616,3 +616,29 @@ test('Compaction liveActivity: detects in-progress & completed CHECKPOINT over p
|
|||||||
assert.equal(pTranscriptOnly.activeConversation.liveActivity.phase, 'compacting');
|
assert.equal(pTranscriptOnly.activeConversation.liveActivity.phase, 'compacting');
|
||||||
assert.equal(pTranscriptOnly.activeConversation.liveActivity.label, '上下文压缩');
|
assert.equal(pTranscriptOnly.activeConversation.liveActivity.label, '上下文压缩');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
test('panel typography scales all view/table/chart CSS rules via --fs-* tokens without hardcoded px sizes', () => {
|
||||||
|
const stylesDir = fileURLToPath(new URL('../src/styles', import.meta.url));
|
||||||
|
const viewCssFiles = [
|
||||||
|
'controls.css',
|
||||||
|
'views-overview.css',
|
||||||
|
'views-tables.css',
|
||||||
|
'views-consumption.css',
|
||||||
|
'views-settings.css',
|
||||||
|
];
|
||||||
|
for (const file of viewCssFiles) {
|
||||||
|
const css = fs.readFileSync(join(stylesDir, file), 'utf8');
|
||||||
|
const rawFontLines = css
|
||||||
|
.split(/\r?\n/)
|
||||||
|
.filter((line) => /font-size\s*:/.test(line) && !/var\(--fs-/.test(line));
|
||||||
|
assert.deepEqual(
|
||||||
|
rawFontLines,
|
||||||
|
[],
|
||||||
|
`${file} must route every font-size declaration through scalable --fs-* tokens`
|
||||||
|
);
|
||||||
|
}
|
||||||
|
const tokensCss = fs.readFileSync(join(stylesDir, 'tokens.css'), 'utf8');
|
||||||
|
assert.match(tokensCss, /:host\(\[data-font-scale="xl"\]\)/);
|
||||||
|
assert.match(tokensCss, /\[data-font-scale\]\s*\{[\s\S]*?--fs-base-sm:/);
|
||||||
|
assert.doesNotMatch(tokensCss, /:root,\s*:host\s*\{[^}]*--ui-font-scale\s*:\s*1\s*;/);
|
||||||
|
});
|
||||||
|
|||||||
@@ -1422,7 +1422,11 @@ test('Compiled app.js mounts dual Shadow DOM hosts, tracks /c/<uuid> routes, pro
|
|||||||
assert.equal(liveDotSvg.attributes.get('width'), '11', 'Enlarged live activity SVG dot size is 11');
|
assert.equal(liveDotSvg.attributes.get('width'), '11', 'Enlarged live activity SVG dot size is 11');
|
||||||
assert.equal(liveDotSvg.children[0].attributes.get('r'), '5', 'Enlarged dot circle radius is 5');
|
assert.equal(liveDotSvg.children[0].attributes.get('r'), '5', 'Enlarged dot circle radius is 5');
|
||||||
assert.match(stylesCss, /\.wm-multi-dot\s*\{\s*width:\s*8px;\s*height:\s*8px;/, 'Topbar multi-session dot enlarged to 8px');
|
assert.match(stylesCss, /\.wm-multi-dot\s*\{\s*width:\s*8px;\s*height:\s*8px;/, 'Topbar multi-session dot enlarged to 8px');
|
||||||
assert.match(stylesCss, /\.wm-hover-tip\s*\{[^}]*width:\s*min\(522px,\s*calc\(100vw - 24px\)\);/, 'Hover floating card width is 522px');
|
assert.match(
|
||||||
|
stylesCss,
|
||||||
|
/\.wm-hover-tip\s*\{[^}]*width:\s*min\(calc\(522px \* var\(--ui-panel-scale, 1\)\),\s*calc\(100vw - 24px\)\);/,
|
||||||
|
'Hover floating card base width is 522px and scales with --ui-panel-scale'
|
||||||
|
);
|
||||||
assert.equal(multiPanelEl.querySelector('.wm-recent-list'), null, 'Recent sessions list removed so panel shows online sessions only');
|
assert.equal(multiPanelEl.querySelector('.wm-recent-list'), null, 'Recent sessions list removed so panel shows online sessions only');
|
||||||
assert.equal(multiPanelEl.querySelector('.panel'), null, 'Single-layer multi-session panel without nested .panel box');
|
assert.equal(multiPanelEl.querySelector('.panel'), null, 'Single-layer multi-session panel without nested .panel box');
|
||||||
|
|
||||||
@@ -1563,19 +1567,25 @@ test('Compiled app.js mounts dual Shadow DOM hosts, tracks /c/<uuid> routes, pro
|
|||||||
assert.equal(mockSettings.themeAccent, 'host');
|
assert.equal(mockSettings.themeAccent, 'host');
|
||||||
assert.equal(portalHost.style.getPropertyValue('--user-accent-primary'), '', 'Host accent clears override');
|
assert.equal(portalHost.style.getPropertyValue('--user-accent-primary'), '', 'Host accent clears override');
|
||||||
|
|
||||||
// Font scale: switch to xl (1.15), verify portalHost scales while capsuleHost NEVER scales
|
// Font scale: switch to xl (1.28), verify portalHost and inner panels scale while capsuleHost NEVER scales
|
||||||
assert.equal(fontScaleBtns.length, 4, 'Font scale segmented control has sm / md / lg / xl');
|
assert.equal(fontScaleBtns.length, 4, 'Font scale segmented control has sm / md / lg / xl');
|
||||||
fontScaleBtns[3].dispatchEvent({ type: 'click', stopPropagation() {} });
|
fontScaleBtns[3].dispatchEvent({ type: 'click', stopPropagation() {} });
|
||||||
await new Promise((r) => setTimeout(r, 30));
|
await new Promise((r) => setTimeout(r, 30));
|
||||||
assert.equal(mockSettings.fontScale, 'xl');
|
assert.equal(mockSettings.fontScale, 'xl');
|
||||||
assert.equal(portalHost.style.getPropertyValue('--ui-font-scale'), '1.15', 'Portal host scales to 1.15');
|
assert.equal(portalHost.style.getPropertyValue('--ui-font-scale'), '1.28', 'Portal host scales to 1.28');
|
||||||
|
assert.equal(portalHost.style.getPropertyValue('--ui-panel-scale'), '1.18', 'Portal host panel width scales to 1.18');
|
||||||
|
assert.equal(popoverEl.getAttribute('data-font-scale'), 'xl', 'Popover panel receives data-font-scale');
|
||||||
|
assert.equal(hoverTipEl.getAttribute('data-font-scale'), 'xl', 'Hover card receives data-font-scale');
|
||||||
|
assert.equal(multiPanelEl.getAttribute('data-font-scale'), 'xl', 'Multi-session panel receives data-font-scale');
|
||||||
assert.equal(capsuleHost.style.getPropertyValue('--ui-font-scale'), '', 'Capsule host strictly excludes font scale');
|
assert.equal(capsuleHost.style.getPropertyValue('--ui-font-scale'), '', 'Capsule host strictly excludes font scale');
|
||||||
assert.equal(capsuleHost.hasAttribute('data-font-scale'), false);
|
assert.equal(capsuleHost.hasAttribute('data-font-scale'), false);
|
||||||
fontScaleBtns[1].dispatchEvent({ type: 'click', stopPropagation() {} });
|
fontScaleBtns[1].dispatchEvent({ type: 'click', stopPropagation() {} });
|
||||||
await new Promise((r) => setTimeout(r, 30));
|
await new Promise((r) => setTimeout(r, 30));
|
||||||
assert.equal(mockSettings.fontScale, 'md');
|
assert.equal(mockSettings.fontScale, 'md');
|
||||||
assert.equal(portalHost.style.getPropertyValue('--ui-font-scale'), '');
|
assert.equal(portalHost.style.getPropertyValue('--ui-font-scale'), '');
|
||||||
|
assert.equal(portalHost.style.getPropertyValue('--ui-panel-scale'), '');
|
||||||
assert.equal(portalHost.getAttribute('data-font-scale'), 'md');
|
assert.equal(portalHost.getAttribute('data-font-scale'), 'md');
|
||||||
|
assert.equal(popoverEl.getAttribute('data-font-scale'), 'md');
|
||||||
|
|
||||||
// Live i18n switch: zh-CN -> en-US -> zh-CN without page reload
|
// Live i18n switch: zh-CN -> en-US -> zh-CN without page reload
|
||||||
langBtns[1].dispatchEvent({ type: 'click', stopPropagation() {} });
|
langBtns[1].dispatchEvent({ type: 'click', stopPropagation() {} });
|
||||||
|
|||||||
Reference in New Issue
Block a user