fix(panel): remove 0.9x zoom distortion on structure previews and align capsule font/mock schema

This commit is contained in:
fish
2026-11-18 13:13:00 +09:00
parent c948126c96
commit 1602897178
10 changed files with 71 additions and 32 deletions
@@ -220,10 +220,12 @@ export function buildStructurePreviewTelemetry(baseSettings = {}, draftOverrides
isRunning: true,
stepCount: 16,
speedSampleCount: 15,
speedSummary: { sampleCount: 15, excludedCount: 1 },
latestTokPerSec: 68.4,
avgTokPerSec: 54.8,
latestTtftSec: 1.15,
avgTtftSec: 1.62,
ttftSummary: { avgSec: 1.62, sampleCount: 15 },
latestStepCostUsd: 0.042,
sessionCostUsd: 1.16,
latestCacheHitPct: 94.5,
@@ -254,10 +256,12 @@ export function buildStructurePreviewTelemetry(baseSettings = {}, draftOverrides
isRunning: false,
stepCount: 8,
speedSampleCount: 8,
speedSummary: { sampleCount: 8, excludedCount: 0 },
latestTokPerSec: 96.2,
avgTokPerSec: 88.5,
latestTtftSec: 0.68,
avgTtftSec: 0.82,
ttftSummary: { avgSec: 0.82, sampleCount: 8 },
latestStepCostUsd: 0.009,
sessionCostUsd: 0.12,
latestCacheHitPct: 88.1,
@@ -281,8 +285,10 @@ export function buildStructurePreviewTelemetry(baseSettings = {}, draftOverrides
...mainAgent,
stepCount: 24,
speedSampleCount: 23,
speedSummary: { sampleCount: 23, excludedCount: 1 },
avgTokPerSec: 59.6,
avgTtftSec: 1.38,
ttftSummary: { avgSec: 1.38, sampleCount: 23 },
sessionCostUsd: 1.28,
sessionCacheHitPct: 88.9,
inputTokens: 186400,
@@ -296,8 +302,9 @@ export function buildStructurePreviewTelemetry(baseSettings = {}, draftOverrides
return {
settings: mergedSettings,
account: {
planName: 'Google AI Pro',
aiCredits: 1200,
tierName: 'Google AI Ultra',
planName: 'Pro',
aiCredits: 0,
},
quotas: {
activePool: {
@@ -94,6 +94,14 @@
}
/* --- 2. 多任务实时运行卡片列表与 4 格测速指标矩阵 (Live Running Tasks List & 4-Cell Telemetry Matrix) --- */
.overview-modules-host {
display: flex;
flex-direction: column;
gap: var(--space-3);
min-width: 0;
padding-bottom: 2px;
}
.live-activity-list {
display: flex;
flex-direction: column;
+7 -10
View File
@@ -230,19 +230,15 @@
font-weight: 600;
}
/* --- 结构页真实 UI 实时预览画布(无套娃外框,直接呈现真实组件) --- */
/* --- 结构页真实 UI 实时预览画布(1:1 零缩放、零套娃外框,直接呈现真实组件) --- */
.structure-preview-canvas {
position: relative;
display: flex;
flex-direction: column;
gap: var(--space-2);
gap: var(--space-3);
min-width: 0;
}
.structure-preview-canvas.is-scaled {
zoom: 0.9;
}
.wm-hover-tip.is-preview {
position: relative;
top: auto;
@@ -260,10 +256,7 @@
}
.overview-modules-host.is-preview {
display: flex;
flex-direction: column;
gap: var(--space-2);
min-width: 0;
padding-bottom: 0;
}
.structure-preview-empty,
@@ -296,6 +289,10 @@
background: var(--surface-bg);
border: 1px solid var(--border-hairline);
border-radius: var(--radius-xs);
font-family: "Google Sans Flex", "Google Sans", system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
font-variant-numeric: tabular-nums;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
overflow-x: auto;
user-select: none;
}
@@ -31,7 +31,6 @@ export const LiveOverviewView = defineComponent({
setup({ onCleanup }) {
const overviewInner = h('div', {
className: 'overview-modules-host',
style: 'display: flex; flex-direction: column; gap: var(--space-3); padding-bottom: 2px;',
});
const widgetHost = createDynamicWidgetHost({
@@ -449,7 +449,7 @@ export const SettingsStructureTab = defineComponent({
isVisibleFn: () => isStructureVisible() && activeThirdTab === 'hover',
initialModuleKeys: [],
});
const hoverPreviewCanvas = h('div', { className: 'structure-preview-canvas is-scaled' }, [
const hoverPreviewCanvas = h('div', { className: 'structure-preview-canvas' }, [
hoverPreviewTipEl,
hoverPreviewEmptyEl,
]);
@@ -541,7 +541,7 @@ export const SettingsStructureTab = defineComponent({
isVisibleFn: () => isStructureVisible() && activeThirdTab === 'overview',
initialModuleKeys: [],
});
const overviewPreviewCanvas = h('div', { className: 'structure-preview-canvas is-scaled' }, [
const overviewPreviewCanvas = h('div', { className: 'structure-preview-canvas' }, [
overviewPreviewContainerEl,
]);