mirror of
https://github.com/lWolvesl/antigravity-usage-monitor.git
synced 2026-11-26 17:09:28 +08:00
fix(panel): replace native width input, fix select menu open reflow, and gate context window settings behind risk consent
- Replace native <input type="number"> in popover width settings with CustomNumberInput stepper and hide native number spinbuttons globally - Eliminate single/multi-select option reflow on open by removing scale(0.985) GPU layer teardown in anim-popover-in, floating .scrollbar-rail without flex width squeeze, and reconciling options before unhiding .select-menu - Gate Model Context Settings behind a persistent risk consent mask (contextWindowRiskAccepted, default false and re-locked on factory reset)
This commit is contained in:
@@ -2233,10 +2233,12 @@ test('v1.5 feedback settings schema: custom token combo DSL, 3-way model display
|
||||
assert.equal(h.normalizeModelDisplayMode(undefined, true), 'upstream');
|
||||
assert.equal(h.normalizeModelDisplayMode(undefined, false), 'short');
|
||||
|
||||
assert.equal(h.loadSettings().contextWindowRiskAccepted, false);
|
||||
const compactRes = h.executeSettingsAction({
|
||||
modelDisplayMode: 'upstream_compact',
|
||||
popoverWidthMode: 'custom',
|
||||
popoverWidth: 1500,
|
||||
contextWindowRiskAccepted: true,
|
||||
stepTokenComboFormat: 'in:out:cache',
|
||||
stepTableColumns: ['step', 'model', 'tokens_io_cache', 'tokens_custom', 'cost'],
|
||||
});
|
||||
@@ -2245,6 +2247,7 @@ test('v1.5 feedback settings schema: custom token combo DSL, 3-way model display
|
||||
assert.equal(compactRes.updated.showUpstreamModel, true);
|
||||
assert.equal(compactRes.updated.popoverWidthMode, 'custom');
|
||||
assert.equal(compactRes.updated.popoverWidth, 1080, 'Clamped to MAX_POPOVER_WIDTH 1080');
|
||||
assert.equal(compactRes.updated.contextWindowRiskAccepted, true);
|
||||
assert.equal(compactRes.updated.stepTokenComboFormat, 'in:out:cache');
|
||||
assert.deepEqual([...compactRes.updated.stepTableColumns], [
|
||||
'step',
|
||||
|
||||
Reference in New Issue
Block a user