diff --git a/packages/cli/src/test-utils/render.tsx b/packages/cli/src/test-utils/render.tsx index db0d82750c..f6ab5efe16 100644 --- a/packages/cli/src/test-utils/render.tsx +++ b/packages/cli/src/test-utils/render.tsx @@ -107,7 +107,7 @@ function isInkRenderMetrics( class XtermStdout extends EventEmitter { private state: TerminalState; private pendingWrites = 0; - private renderCount = 0; + renderCount = 0; private queue: { promise: Promise }; isTTY = true; @@ -160,7 +160,8 @@ class XtermStdout extends EventEmitter { this.renderCount++; this.lastRenderStaticContent = staticContent; this.lastRenderOutput = output; - this.write(staticContent + output); + // Clear screen and move cursor to home before writing the new frame + this.write('\x1b[2J\x1b[H' + staticContent + output); this.emit('render'); }; @@ -188,7 +189,9 @@ class XtermStdout extends EventEmitter { lastFrame = (options: { allowEmpty?: boolean } = {}) => { const buffer = this.state.terminal.buffer.active; const allLines: string[] = []; - for (let i = 0; i < buffer.length; i++) { + const startLine = buffer.baseY; + const endLine = buffer.baseY + this.rows; + for (let i = startLine; i < endLine; i++) { allLines.push(buffer.getLine(i)?.translateToString(true) ?? ''); } @@ -400,6 +403,7 @@ const instances: InkInstance[] = []; export const render = async ( tree: React.ReactElement, terminalWidth?: number, + terminalHeight?: number, ): Promise< Omit > => { @@ -408,7 +412,7 @@ export const render = async ( // value was used (e.g. 40 rows). The alternatives to make things worse are // windows unfortunately with odd duplicate content in the backbuffer // which does not match actual behavior in xterm.js on windows. - const rows = 1000; + const rows = terminalHeight ?? 1000; const terminal = new Terminal({ cols, rows, @@ -455,7 +459,9 @@ export const render = async ( instances.push(instance); - await stdout.waitUntilReady(); + while (stdout.renderCount === 0 || stdout.lastFrame({ allowEmpty: true }) === '') { + await new Promise((resolve) => setTimeout(resolve, 10)); + } return { rerender: (newTree: React.ReactElement) => { @@ -518,7 +524,7 @@ const baseMockUiState = { isConfigInitialized: true, isAuthenticating: false, terminalWidth: 100, - terminalHeight: 40, + terminalHeight: 100, currentModel: 'gemini-pro', terminalBackgroundColor: 'black' as const, cleanUiDetailsVisible: false, @@ -634,6 +640,7 @@ export const renderWithProviders = async ( quotaState: providedQuotaState, inputState: providedInputState, width, + height, mouseEventsEnabled = false, config, uiActions, @@ -647,6 +654,7 @@ export const renderWithProviders = async ( quotaState?: Partial; inputState?: Partial; width?: number; + height?: number; mouseEventsEnabled?: boolean; config?: Config; uiActions?: Partial; @@ -712,6 +720,7 @@ export const renderWithProviders = async ( persistentStateMock.mockClear(); const terminalWidth = width ?? baseState.terminalWidth; + const terminalHeight = height ?? baseState.terminalHeight; if (!config) { config = makeFakeConfig({ @@ -820,6 +829,7 @@ export const renderWithProviders = async ( const renderResult = await render( wrapWithProviders(component), terminalWidth, + terminalHeight, ); return { diff --git a/packages/cli/src/ui/components/SettingsDialog.test.tsx b/packages/cli/src/ui/components/SettingsDialog.test.tsx index eff7e644df..9ac5f10316 100644 --- a/packages/cli/src/ui/components/SettingsDialog.test.tsx +++ b/packages/cli/src/ui/components/SettingsDialog.test.tsx @@ -247,6 +247,7 @@ const renderDialog = async ( settings, config: makeFakeConfig(), uiState: { terminalBackgroundColor: undefined }, + height: options?.availableTerminalHeight ?? 100, }, ); @@ -284,10 +285,11 @@ describe.sequential('SettingsDialog', () => { const settings = createMockSettings(); const onSelect = vi.fn(); - const { lastFrame, unmount } = await renderDialog(settings, onSelect, { - availableTerminalHeight: 20, + const { lastFrame, unmount, waitUntilReady } = await renderDialog(settings, onSelect, { + availableTerminalHeight: 25, }); + await waitUntilReady(); const output = lastFrame(); // Should still render properly with the height prop expect(output).toContain('Settings'); diff --git a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Initial-Rendering-should-render-settings-list-with-visual-indicators.snap.svg b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Initial-Rendering-should-render-settings-list-with-visual-indicators.snap.svg index 8d5b49c6b6..8679bf95d8 100644 --- a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Initial-Rendering-should-render-settings-list-with-visual-indicators.snap.svg +++ b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Initial-Rendering-should-render-settings-list-with-visual-indicators.snap.svg @@ -4,48 +4,48 @@ - ╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ - │ │ - │ > Settings │ - │ │ - │ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ - │ │ Search to filter │ │ - │ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ - │ │ - │ ▲ │ - │ ● Vim Mode false │ - │ Enable Vim keybindings │ - │ │ - │ Default Approval Mode Default │ - │ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ - │ │ - │ Enable Auto Update true │ - │ Enable automatic updates. │ - │ │ - │ Enable Notifications false │ - │ Enable run-event notifications for action-required prompts and session completion. │ - │ │ - │ Enable Plan Mode true │ - │ Enable Plan Mode for read-only safety during planning. │ - │ │ - │ Plan Directory undefined │ - │ The directory where planning artifacts are stored. If not specified, defaults t… │ - │ │ - │ Plan Model Routing true │ - │ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ - │ │ - │ Retry Fetch Errors true │ - │ Retry on "exception TypeError: fetch failed sending request" errors. │ - │ │ - │ ▼ │ - │ │ - │ Apply To │ - │ ● User Settings │ - │ Workspace Settings │ - │ System Settings │ - │ │ - │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ - │ │ - ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ + ╭─────────────────────────────────────────────────────────────────────────────── + + │ > Settings + + │ ╭───────────────────────────────────────────────────────────────────────────── + │ │ Search to filter + │ ╰───────────────────────────────────────────────────────────────────────────── + + │ ▲ + │ ● Vim Mode + │ Enable Vim keybindings + + │ Default Approval Mode + │ The default approval mode for tool execution. 'default' prompts for approva + + │ Enable Auto Update + │ Enable automatic updates. + + │ Enable Notifications + │ Enable run-event notifications for action-required prompts and session comp + + │ Enable Plan Mode + │ Enable Plan Mode for read-only safety during planning. + + │ Plan Directory + │ The directory where planning artifacts are stored. If not specified, defaul + + │ Plan Model Routing + │ Automatically switch between Pro and Flash models based on Plan Mode status + + │ Retry Fetch Errors + │ Retry on "exception TypeError: fetch failed sending request" errors. + + │ ▼ + + │ Apply To + │ ● User Settings + │ Workspace Settings + │ System Settings + + │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) + + ╰─────────────────────────────────────────────────────────────────────────────── \ No newline at end of file diff --git a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-accessibility-settings-enabled-correctly.snap.svg b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-accessibility-settings-enabled-correctly.snap.svg index e43de863f0..8679bf95d8 100644 --- a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-accessibility-settings-enabled-correctly.snap.svg +++ b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-accessibility-settings-enabled-correctly.snap.svg @@ -4,48 +4,48 @@ - ╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ - │ │ - │ > Settings │ - │ │ - │ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ - │ │ Search to filter │ │ - │ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ - │ │ - │ ▲ │ - │ ● Vim Mode true* │ - │ Enable Vim keybindings │ - │ │ - │ Default Approval Mode Default │ - │ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ - │ │ - │ Enable Auto Update true │ - │ Enable automatic updates. │ - │ │ - │ Enable Notifications false │ - │ Enable run-event notifications for action-required prompts and session completion. │ - │ │ - │ Enable Plan Mode true │ - │ Enable Plan Mode for read-only safety during planning. │ - │ │ - │ Plan Directory undefined │ - │ The directory where planning artifacts are stored. If not specified, defaults t… │ - │ │ - │ Plan Model Routing true │ - │ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ - │ │ - │ Retry Fetch Errors true │ - │ Retry on "exception TypeError: fetch failed sending request" errors. │ - │ │ - │ ▼ │ - │ │ - │ Apply To │ - │ ● User Settings │ - │ Workspace Settings │ - │ System Settings │ - │ │ - │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ - │ │ - ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ + ╭─────────────────────────────────────────────────────────────────────────────── + + │ > Settings + + │ ╭───────────────────────────────────────────────────────────────────────────── + │ │ Search to filter + │ ╰───────────────────────────────────────────────────────────────────────────── + + │ ▲ + │ ● Vim Mode + │ Enable Vim keybindings + + │ Default Approval Mode + │ The default approval mode for tool execution. 'default' prompts for approva + + │ Enable Auto Update + │ Enable automatic updates. + + │ Enable Notifications + │ Enable run-event notifications for action-required prompts and session comp + + │ Enable Plan Mode + │ Enable Plan Mode for read-only safety during planning. + + │ Plan Directory + │ The directory where planning artifacts are stored. If not specified, defaul + + │ Plan Model Routing + │ Automatically switch between Pro and Flash models based on Plan Mode status + + │ Retry Fetch Errors + │ Retry on "exception TypeError: fetch failed sending request" errors. + + │ ▼ + + │ Apply To + │ ● User Settings + │ Workspace Settings + │ System Settings + + │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) + + ╰─────────────────────────────────────────────────────────────────────────────── \ No newline at end of file diff --git a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-all-boolean-settings-disabled-correctly.snap.svg b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-all-boolean-settings-disabled-correctly.snap.svg index 9ab472e5f2..8679bf95d8 100644 --- a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-all-boolean-settings-disabled-correctly.snap.svg +++ b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-all-boolean-settings-disabled-correctly.snap.svg @@ -4,48 +4,48 @@ - ╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ - │ │ - │ > Settings │ - │ │ - │ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ - │ │ Search to filter │ │ - │ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ - │ │ - │ ▲ │ - │ ● Vim Mode false* │ - │ Enable Vim keybindings │ - │ │ - │ Default Approval Mode Default │ - │ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ - │ │ - │ Enable Auto Update true* │ - │ Enable automatic updates. │ - │ │ - │ Enable Notifications false │ - │ Enable run-event notifications for action-required prompts and session completion. │ - │ │ - │ Enable Plan Mode true │ - │ Enable Plan Mode for read-only safety during planning. │ - │ │ - │ Plan Directory undefined │ - │ The directory where planning artifacts are stored. If not specified, defaults t… │ - │ │ - │ Plan Model Routing true │ - │ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ - │ │ - │ Retry Fetch Errors true │ - │ Retry on "exception TypeError: fetch failed sending request" errors. │ - │ │ - │ ▼ │ - │ │ - │ Apply To │ - │ ● User Settings │ - │ Workspace Settings │ - │ System Settings │ - │ │ - │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ - │ │ - ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ + ╭─────────────────────────────────────────────────────────────────────────────── + + │ > Settings + + │ ╭───────────────────────────────────────────────────────────────────────────── + │ │ Search to filter + │ ╰───────────────────────────────────────────────────────────────────────────── + + │ ▲ + │ ● Vim Mode + │ Enable Vim keybindings + + │ Default Approval Mode + │ The default approval mode for tool execution. 'default' prompts for approva + + │ Enable Auto Update + │ Enable automatic updates. + + │ Enable Notifications + │ Enable run-event notifications for action-required prompts and session comp + + │ Enable Plan Mode + │ Enable Plan Mode for read-only safety during planning. + + │ Plan Directory + │ The directory where planning artifacts are stored. If not specified, defaul + + │ Plan Model Routing + │ Automatically switch between Pro and Flash models based on Plan Mode status + + │ Retry Fetch Errors + │ Retry on "exception TypeError: fetch failed sending request" errors. + + │ ▼ + + │ Apply To + │ ● User Settings + │ Workspace Settings + │ System Settings + + │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) + + ╰─────────────────────────────────────────────────────────────────────────────── \ No newline at end of file diff --git a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-default-state-correctly.snap.svg b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-default-state-correctly.snap.svg index 8d5b49c6b6..8679bf95d8 100644 --- a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-default-state-correctly.snap.svg +++ b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-default-state-correctly.snap.svg @@ -4,48 +4,48 @@ - ╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ - │ │ - │ > Settings │ - │ │ - │ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ - │ │ Search to filter │ │ - │ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ - │ │ - │ ▲ │ - │ ● Vim Mode false │ - │ Enable Vim keybindings │ - │ │ - │ Default Approval Mode Default │ - │ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ - │ │ - │ Enable Auto Update true │ - │ Enable automatic updates. │ - │ │ - │ Enable Notifications false │ - │ Enable run-event notifications for action-required prompts and session completion. │ - │ │ - │ Enable Plan Mode true │ - │ Enable Plan Mode for read-only safety during planning. │ - │ │ - │ Plan Directory undefined │ - │ The directory where planning artifacts are stored. If not specified, defaults t… │ - │ │ - │ Plan Model Routing true │ - │ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ - │ │ - │ Retry Fetch Errors true │ - │ Retry on "exception TypeError: fetch failed sending request" errors. │ - │ │ - │ ▼ │ - │ │ - │ Apply To │ - │ ● User Settings │ - │ Workspace Settings │ - │ System Settings │ - │ │ - │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ - │ │ - ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ + ╭─────────────────────────────────────────────────────────────────────────────── + + │ > Settings + + │ ╭───────────────────────────────────────────────────────────────────────────── + │ │ Search to filter + │ ╰───────────────────────────────────────────────────────────────────────────── + + │ ▲ + │ ● Vim Mode + │ Enable Vim keybindings + + │ Default Approval Mode + │ The default approval mode for tool execution. 'default' prompts for approva + + │ Enable Auto Update + │ Enable automatic updates. + + │ Enable Notifications + │ Enable run-event notifications for action-required prompts and session comp + + │ Enable Plan Mode + │ Enable Plan Mode for read-only safety during planning. + + │ Plan Directory + │ The directory where planning artifacts are stored. If not specified, defaul + + │ Plan Model Routing + │ Automatically switch between Pro and Flash models based on Plan Mode status + + │ Retry Fetch Errors + │ Retry on "exception TypeError: fetch failed sending request" errors. + + │ ▼ + + │ Apply To + │ ● User Settings + │ Workspace Settings + │ System Settings + + │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) + + ╰─────────────────────────────────────────────────────────────────────────────── \ No newline at end of file diff --git a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-file-filtering-settings-configured-correctly.snap.svg b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-file-filtering-settings-configured-correctly.snap.svg index 8d5b49c6b6..8679bf95d8 100644 --- a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-file-filtering-settings-configured-correctly.snap.svg +++ b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-file-filtering-settings-configured-correctly.snap.svg @@ -4,48 +4,48 @@ - ╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ - │ │ - │ > Settings │ - │ │ - │ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ - │ │ Search to filter │ │ - │ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ - │ │ - │ ▲ │ - │ ● Vim Mode false │ - │ Enable Vim keybindings │ - │ │ - │ Default Approval Mode Default │ - │ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ - │ │ - │ Enable Auto Update true │ - │ Enable automatic updates. │ - │ │ - │ Enable Notifications false │ - │ Enable run-event notifications for action-required prompts and session completion. │ - │ │ - │ Enable Plan Mode true │ - │ Enable Plan Mode for read-only safety during planning. │ - │ │ - │ Plan Directory undefined │ - │ The directory where planning artifacts are stored. If not specified, defaults t… │ - │ │ - │ Plan Model Routing true │ - │ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ - │ │ - │ Retry Fetch Errors true │ - │ Retry on "exception TypeError: fetch failed sending request" errors. │ - │ │ - │ ▼ │ - │ │ - │ Apply To │ - │ ● User Settings │ - │ Workspace Settings │ - │ System Settings │ - │ │ - │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ - │ │ - ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ + ╭─────────────────────────────────────────────────────────────────────────────── + + │ > Settings + + │ ╭───────────────────────────────────────────────────────────────────────────── + │ │ Search to filter + │ ╰───────────────────────────────────────────────────────────────────────────── + + │ ▲ + │ ● Vim Mode + │ Enable Vim keybindings + + │ Default Approval Mode + │ The default approval mode for tool execution. 'default' prompts for approva + + │ Enable Auto Update + │ Enable automatic updates. + + │ Enable Notifications + │ Enable run-event notifications for action-required prompts and session comp + + │ Enable Plan Mode + │ Enable Plan Mode for read-only safety during planning. + + │ Plan Directory + │ The directory where planning artifacts are stored. If not specified, defaul + + │ Plan Model Routing + │ Automatically switch between Pro and Flash models based on Plan Mode status + + │ Retry Fetch Errors + │ Retry on "exception TypeError: fetch failed sending request" errors. + + │ ▼ + + │ Apply To + │ ● User Settings + │ Workspace Settings + │ System Settings + + │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) + + ╰─────────────────────────────────────────────────────────────────────────────── \ No newline at end of file diff --git a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-focused-on-scope-selector-correctly.snap.svg b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-focused-on-scope-selector-correctly.snap.svg index 8d5b49c6b6..95e80c6aa2 100644 --- a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-focused-on-scope-selector-correctly.snap.svg +++ b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-focused-on-scope-selector-correctly.snap.svg @@ -4,48 +4,48 @@ - ╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ - │ │ - │ > Settings │ - │ │ - │ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ - │ │ Search to filter │ │ - │ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ - │ │ - │ ▲ │ - │ ● Vim Mode false │ - │ Enable Vim keybindings │ - │ │ - │ Default Approval Mode Default │ - │ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ - │ │ - │ Enable Auto Update true │ - │ Enable automatic updates. │ - │ │ - │ Enable Notifications false │ - │ Enable run-event notifications for action-required prompts and session completion. │ - │ │ - │ Enable Plan Mode true │ - │ Enable Plan Mode for read-only safety during planning. │ - │ │ - │ Plan Directory undefined │ - │ The directory where planning artifacts are stored. If not specified, defaults t… │ - │ │ - │ Plan Model Routing true │ - │ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ - │ │ - │ Retry Fetch Errors true │ - │ Retry on "exception TypeError: fetch failed sending request" errors. │ - │ │ - │ ▼ │ - │ │ - │ Apply To │ - │ ● User Settings │ - │ Workspace Settings │ - │ System Settings │ - │ │ - │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ - │ │ - ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ + ╭─────────────────────────────────────────────────────────────────────────────── + + │ Settings + + │ ╭───────────────────────────────────────────────────────────────────────────── + │ │ Search to filter + │ ╰───────────────────────────────────────────────────────────────────────────── + + │ ▲ + │ Vim Mode + │ Enable Vim keybindings + + │ Default Approval Mode + │ The default approval mode for tool execution. 'default' prompts for approva + + │ Enable Auto Update + │ Enable automatic updates. + + │ Enable Notifications + │ Enable run-event notifications for action-required prompts and session comp + + │ Enable Plan Mode + │ Enable Plan Mode for read-only safety during planning. + + │ Plan Directory + │ The directory where planning artifacts are stored. If not specified, defaul + + │ Plan Model Routing + │ Automatically switch between Pro and Flash models based on Plan Mode status + + │ Retry Fetch Errors + │ Retry on "exception TypeError: fetch failed sending request" errors. + + │ ▼ + + │ > Apply To + │ ● 1. User Settings + │ 2. Workspace Settings + │ 3. System Settings + + │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) + + ╰─────────────────────────────────────────────────────────────────────────────── \ No newline at end of file diff --git a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-mixed-boolean-and-number-settings-correctly.snap.svg b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-mixed-boolean-and-number-settings-correctly.snap.svg index 7e87cb8376..8679bf95d8 100644 --- a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-mixed-boolean-and-number-settings-correctly.snap.svg +++ b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-mixed-boolean-and-number-settings-correctly.snap.svg @@ -4,48 +4,48 @@ - ╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ - │ │ - │ > Settings │ - │ │ - │ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ - │ │ Search to filter │ │ - │ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ - │ │ - │ ▲ │ - │ ● Vim Mode false* │ - │ Enable Vim keybindings │ - │ │ - │ Default Approval Mode Default │ - │ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ - │ │ - │ Enable Auto Update false* │ - │ Enable automatic updates. │ - │ │ - │ Enable Notifications false │ - │ Enable run-event notifications for action-required prompts and session completion. │ - │ │ - │ Enable Plan Mode true │ - │ Enable Plan Mode for read-only safety during planning. │ - │ │ - │ Plan Directory undefined │ - │ The directory where planning artifacts are stored. If not specified, defaults t… │ - │ │ - │ Plan Model Routing true │ - │ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ - │ │ - │ Retry Fetch Errors true │ - │ Retry on "exception TypeError: fetch failed sending request" errors. │ - │ │ - │ ▼ │ - │ │ - │ Apply To │ - │ ● User Settings │ - │ Workspace Settings │ - │ System Settings │ - │ │ - │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ - │ │ - ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ + ╭─────────────────────────────────────────────────────────────────────────────── + + │ > Settings + + │ ╭───────────────────────────────────────────────────────────────────────────── + │ │ Search to filter + │ ╰───────────────────────────────────────────────────────────────────────────── + + │ ▲ + │ ● Vim Mode + │ Enable Vim keybindings + + │ Default Approval Mode + │ The default approval mode for tool execution. 'default' prompts for approva + + │ Enable Auto Update + │ Enable automatic updates. + + │ Enable Notifications + │ Enable run-event notifications for action-required prompts and session comp + + │ Enable Plan Mode + │ Enable Plan Mode for read-only safety during planning. + + │ Plan Directory + │ The directory where planning artifacts are stored. If not specified, defaul + + │ Plan Model Routing + │ Automatically switch between Pro and Flash models based on Plan Mode status + + │ Retry Fetch Errors + │ Retry on "exception TypeError: fetch failed sending request" errors. + + │ ▼ + + │ Apply To + │ ● User Settings + │ Workspace Settings + │ System Settings + + │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) + + ╰─────────────────────────────────────────────────────────────────────────────── \ No newline at end of file diff --git a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-tools-and-security-settings-correctly.snap.svg b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-tools-and-security-settings-correctly.snap.svg index 8d5b49c6b6..8679bf95d8 100644 --- a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-tools-and-security-settings-correctly.snap.svg +++ b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-tools-and-security-settings-correctly.snap.svg @@ -4,48 +4,48 @@ - ╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ - │ │ - │ > Settings │ - │ │ - │ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ - │ │ Search to filter │ │ - │ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ - │ │ - │ ▲ │ - │ ● Vim Mode false │ - │ Enable Vim keybindings │ - │ │ - │ Default Approval Mode Default │ - │ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ - │ │ - │ Enable Auto Update true │ - │ Enable automatic updates. │ - │ │ - │ Enable Notifications false │ - │ Enable run-event notifications for action-required prompts and session completion. │ - │ │ - │ Enable Plan Mode true │ - │ Enable Plan Mode for read-only safety during planning. │ - │ │ - │ Plan Directory undefined │ - │ The directory where planning artifacts are stored. If not specified, defaults t… │ - │ │ - │ Plan Model Routing true │ - │ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ - │ │ - │ Retry Fetch Errors true │ - │ Retry on "exception TypeError: fetch failed sending request" errors. │ - │ │ - │ ▼ │ - │ │ - │ Apply To │ - │ ● User Settings │ - │ Workspace Settings │ - │ System Settings │ - │ │ - │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ - │ │ - ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ + ╭─────────────────────────────────────────────────────────────────────────────── + + │ > Settings + + │ ╭───────────────────────────────────────────────────────────────────────────── + │ │ Search to filter + │ ╰───────────────────────────────────────────────────────────────────────────── + + │ ▲ + │ ● Vim Mode + │ Enable Vim keybindings + + │ Default Approval Mode + │ The default approval mode for tool execution. 'default' prompts for approva + + │ Enable Auto Update + │ Enable automatic updates. + + │ Enable Notifications + │ Enable run-event notifications for action-required prompts and session comp + + │ Enable Plan Mode + │ Enable Plan Mode for read-only safety during planning. + + │ Plan Directory + │ The directory where planning artifacts are stored. If not specified, defaul + + │ Plan Model Routing + │ Automatically switch between Pro and Flash models based on Plan Mode status + + │ Retry Fetch Errors + │ Retry on "exception TypeError: fetch failed sending request" errors. + + │ ▼ + + │ Apply To + │ ● User Settings + │ Workspace Settings + │ System Settings + + │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) + + ╰─────────────────────────────────────────────────────────────────────────────── \ No newline at end of file diff --git a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-various-boolean-settings-enabled-correctly.snap.svg b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-various-boolean-settings-enabled-correctly.snap.svg index dbfb7f515e..8679bf95d8 100644 --- a/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-various-boolean-settings-enabled-correctly.snap.svg +++ b/packages/cli/src/ui/components/__snapshots__/SettingsDialog-SettingsDialog-Snapshot-Tests-should-render-various-boolean-settings-enabled-correctly.snap.svg @@ -4,48 +4,48 @@ - ╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ - │ │ - │ > Settings │ - │ │ - │ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ - │ │ Search to filter │ │ - │ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ - │ │ - │ ▲ │ - │ ● Vim Mode true* │ - │ Enable Vim keybindings │ - │ │ - │ Default Approval Mode Default │ - │ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ - │ │ - │ Enable Auto Update false* │ - │ Enable automatic updates. │ - │ │ - │ Enable Notifications false │ - │ Enable run-event notifications for action-required prompts and session completion. │ - │ │ - │ Enable Plan Mode true │ - │ Enable Plan Mode for read-only safety during planning. │ - │ │ - │ Plan Directory undefined │ - │ The directory where planning artifacts are stored. If not specified, defaults t… │ - │ │ - │ Plan Model Routing true │ - │ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ - │ │ - │ Retry Fetch Errors true │ - │ Retry on "exception TypeError: fetch failed sending request" errors. │ - │ │ - │ ▼ │ - │ │ - │ Apply To │ - │ ● User Settings │ - │ Workspace Settings │ - │ System Settings │ - │ │ - │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ - │ │ - ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ + ╭─────────────────────────────────────────────────────────────────────────────── + + │ > Settings + + │ ╭───────────────────────────────────────────────────────────────────────────── + │ │ Search to filter + │ ╰───────────────────────────────────────────────────────────────────────────── + + │ ▲ + │ ● Vim Mode + │ Enable Vim keybindings + + │ Default Approval Mode + │ The default approval mode for tool execution. 'default' prompts for approva + + │ Enable Auto Update + │ Enable automatic updates. + + │ Enable Notifications + │ Enable run-event notifications for action-required prompts and session comp + + │ Enable Plan Mode + │ Enable Plan Mode for read-only safety during planning. + + │ Plan Directory + │ The directory where planning artifacts are stored. If not specified, defaul + + │ Plan Model Routing + │ Automatically switch between Pro and Flash models based on Plan Mode status + + │ Retry Fetch Errors + │ Retry on "exception TypeError: fetch failed sending request" errors. + + │ ▼ + + │ Apply To + │ ● User Settings + │ Workspace Settings + │ System Settings + + │ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) + + ╰─────────────────────────────────────────────────────────────────────────────── \ No newline at end of file diff --git a/packages/cli/src/ui/components/__snapshots__/SettingsDialog.test.tsx.snap b/packages/cli/src/ui/components/__snapshots__/SettingsDialog.test.tsx.snap index 55d099270a..c82b780cf2 100644 --- a/packages/cli/src/ui/components/__snapshots__/SettingsDialog.test.tsx.snap +++ b/packages/cli/src/ui/components/__snapshots__/SettingsDialog.test.tsx.snap @@ -1,415 +1,415 @@ // Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html exports[`SettingsDialog > Initial Rendering > should render settings list with visual indicators 1`] = ` -"╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ -│ │ -│ > Settings │ -│ │ -│ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ -│ │ Search to filter │ │ -│ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ -│ │ -│ ▲ │ -│ ● Vim Mode false │ -│ Enable Vim keybindings │ -│ │ -│ Default Approval Mode Default │ -│ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ -│ │ -│ Enable Auto Update true │ -│ Enable automatic updates. │ -│ │ -│ Enable Notifications false │ -│ Enable run-event notifications for action-required prompts and session completion. │ -│ │ -│ Enable Plan Mode true │ -│ Enable Plan Mode for read-only safety during planning. │ -│ │ -│ Plan Directory undefined │ -│ The directory where planning artifacts are stored. If not specified, defaults t… │ -│ │ -│ Plan Model Routing true │ -│ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ -│ │ -│ Retry Fetch Errors true │ -│ Retry on "exception TypeError: fetch failed sending request" errors. │ -│ │ -│ ▼ │ -│ │ -│ Apply To │ -│ ● User Settings │ -│ Workspace Settings │ -│ System Settings │ -│ │ -│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ -│ │ -╰──────────────────────────────────────────────────────────────────────────────────────────────────╯" +"╭─────────────────────────────────────────────────────────────────────────────── +│ +│ > Settings +│ +│ ╭───────────────────────────────────────────────────────────────────────────── +│ │ Search to filter +│ ╰───────────────────────────────────────────────────────────────────────────── +│ +│ ▲ +│ ● Vim Mode +│ Enable Vim keybindings +│ +│ Default Approval Mode +│ The default approval mode for tool execution. 'default' prompts for approva +│ +│ Enable Auto Update +│ Enable automatic updates. +│ +│ Enable Notifications +│ Enable run-event notifications for action-required prompts and session comp +│ +│ Enable Plan Mode +│ Enable Plan Mode for read-only safety during planning. +│ +│ Plan Directory +│ The directory where planning artifacts are stored. If not specified, defaul +│ +│ Plan Model Routing +│ Automatically switch between Pro and Flash models based on Plan Mode status +│ +│ Retry Fetch Errors +│ Retry on "exception TypeError: fetch failed sending request" errors. +│ +│ ▼ +│ +│ Apply To +│ ● User Settings +│ Workspace Settings +│ System Settings +│ +│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) +│ +╰───────────────────────────────────────────────────────────────────────────────" `; exports[`SettingsDialog > Snapshot Tests > should render 'accessibility settings enabled' correctly 1`] = ` -"╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ -│ │ -│ > Settings │ -│ │ -│ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ -│ │ Search to filter │ │ -│ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ -│ │ -│ ▲ │ -│ ● Vim Mode true* │ -│ Enable Vim keybindings │ -│ │ -│ Default Approval Mode Default │ -│ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ -│ │ -│ Enable Auto Update true │ -│ Enable automatic updates. │ -│ │ -│ Enable Notifications false │ -│ Enable run-event notifications for action-required prompts and session completion. │ -│ │ -│ Enable Plan Mode true │ -│ Enable Plan Mode for read-only safety during planning. │ -│ │ -│ Plan Directory undefined │ -│ The directory where planning artifacts are stored. If not specified, defaults t… │ -│ │ -│ Plan Model Routing true │ -│ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ -│ │ -│ Retry Fetch Errors true │ -│ Retry on "exception TypeError: fetch failed sending request" errors. │ -│ │ -│ ▼ │ -│ │ -│ Apply To │ -│ ● User Settings │ -│ Workspace Settings │ -│ System Settings │ -│ │ -│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ -│ │ -╰──────────────────────────────────────────────────────────────────────────────────────────────────╯" +"╭─────────────────────────────────────────────────────────────────────────────── +│ +│ > Settings +│ +│ ╭───────────────────────────────────────────────────────────────────────────── +│ │ Search to filter +│ ╰───────────────────────────────────────────────────────────────────────────── +│ +│ ▲ +│ ● Vim Mode +│ Enable Vim keybindings +│ +│ Default Approval Mode +│ The default approval mode for tool execution. 'default' prompts for approva +│ +│ Enable Auto Update +│ Enable automatic updates. +│ +│ Enable Notifications +│ Enable run-event notifications for action-required prompts and session comp +│ +│ Enable Plan Mode +│ Enable Plan Mode for read-only safety during planning. +│ +│ Plan Directory +│ The directory where planning artifacts are stored. If not specified, defaul +│ +│ Plan Model Routing +│ Automatically switch between Pro and Flash models based on Plan Mode status +│ +│ Retry Fetch Errors +│ Retry on "exception TypeError: fetch failed sending request" errors. +│ +│ ▼ +│ +│ Apply To +│ ● User Settings +│ Workspace Settings +│ System Settings +│ +│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) +│ +╰───────────────────────────────────────────────────────────────────────────────" `; exports[`SettingsDialog > Snapshot Tests > should render 'all boolean settings disabled' correctly 1`] = ` -"╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ -│ │ -│ > Settings │ -│ │ -│ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ -│ │ Search to filter │ │ -│ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ -│ │ -│ ▲ │ -│ ● Vim Mode false* │ -│ Enable Vim keybindings │ -│ │ -│ Default Approval Mode Default │ -│ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ -│ │ -│ Enable Auto Update true* │ -│ Enable automatic updates. │ -│ │ -│ Enable Notifications false │ -│ Enable run-event notifications for action-required prompts and session completion. │ -│ │ -│ Enable Plan Mode true │ -│ Enable Plan Mode for read-only safety during planning. │ -│ │ -│ Plan Directory undefined │ -│ The directory where planning artifacts are stored. If not specified, defaults t… │ -│ │ -│ Plan Model Routing true │ -│ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ -│ │ -│ Retry Fetch Errors true │ -│ Retry on "exception TypeError: fetch failed sending request" errors. │ -│ │ -│ ▼ │ -│ │ -│ Apply To │ -│ ● User Settings │ -│ Workspace Settings │ -│ System Settings │ -│ │ -│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ -│ │ -╰──────────────────────────────────────────────────────────────────────────────────────────────────╯" +"╭─────────────────────────────────────────────────────────────────────────────── +│ +│ > Settings +│ +│ ╭───────────────────────────────────────────────────────────────────────────── +│ │ Search to filter +│ ╰───────────────────────────────────────────────────────────────────────────── +│ +│ ▲ +│ ● Vim Mode +│ Enable Vim keybindings +│ +│ Default Approval Mode +│ The default approval mode for tool execution. 'default' prompts for approva +│ +│ Enable Auto Update +│ Enable automatic updates. +│ +│ Enable Notifications +│ Enable run-event notifications for action-required prompts and session comp +│ +│ Enable Plan Mode +│ Enable Plan Mode for read-only safety during planning. +│ +│ Plan Directory +│ The directory where planning artifacts are stored. If not specified, defaul +│ +│ Plan Model Routing +│ Automatically switch between Pro and Flash models based on Plan Mode status +│ +│ Retry Fetch Errors +│ Retry on "exception TypeError: fetch failed sending request" errors. +│ +│ ▼ +│ +│ Apply To +│ ● User Settings +│ Workspace Settings +│ System Settings +│ +│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) +│ +╰───────────────────────────────────────────────────────────────────────────────" `; exports[`SettingsDialog > Snapshot Tests > should render 'default state' correctly 1`] = ` -"╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ -│ │ -│ > Settings │ -│ │ -│ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ -│ │ Search to filter │ │ -│ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ -│ │ -│ ▲ │ -│ ● Vim Mode false │ -│ Enable Vim keybindings │ -│ │ -│ Default Approval Mode Default │ -│ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ -│ │ -│ Enable Auto Update true │ -│ Enable automatic updates. │ -│ │ -│ Enable Notifications false │ -│ Enable run-event notifications for action-required prompts and session completion. │ -│ │ -│ Enable Plan Mode true │ -│ Enable Plan Mode for read-only safety during planning. │ -│ │ -│ Plan Directory undefined │ -│ The directory where planning artifacts are stored. If not specified, defaults t… │ -│ │ -│ Plan Model Routing true │ -│ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ -│ │ -│ Retry Fetch Errors true │ -│ Retry on "exception TypeError: fetch failed sending request" errors. │ -│ │ -│ ▼ │ -│ │ -│ Apply To │ -│ ● User Settings │ -│ Workspace Settings │ -│ System Settings │ -│ │ -│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ -│ │ -╰──────────────────────────────────────────────────────────────────────────────────────────────────╯" +"╭─────────────────────────────────────────────────────────────────────────────── +│ +│ > Settings +│ +│ ╭───────────────────────────────────────────────────────────────────────────── +│ │ Search to filter +│ ╰───────────────────────────────────────────────────────────────────────────── +│ +│ ▲ +│ ● Vim Mode +│ Enable Vim keybindings +│ +│ Default Approval Mode +│ The default approval mode for tool execution. 'default' prompts for approva +│ +│ Enable Auto Update +│ Enable automatic updates. +│ +│ Enable Notifications +│ Enable run-event notifications for action-required prompts and session comp +│ +│ Enable Plan Mode +│ Enable Plan Mode for read-only safety during planning. +│ +│ Plan Directory +│ The directory where planning artifacts are stored. If not specified, defaul +│ +│ Plan Model Routing +│ Automatically switch between Pro and Flash models based on Plan Mode status +│ +│ Retry Fetch Errors +│ Retry on "exception TypeError: fetch failed sending request" errors. +│ +│ ▼ +│ +│ Apply To +│ ● User Settings +│ Workspace Settings +│ System Settings +│ +│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) +│ +╰───────────────────────────────────────────────────────────────────────────────" `; exports[`SettingsDialog > Snapshot Tests > should render 'file filtering settings configured' correctly 1`] = ` -"╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ -│ │ -│ > Settings │ -│ │ -│ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ -│ │ Search to filter │ │ -│ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ -│ │ -│ ▲ │ -│ ● Vim Mode false │ -│ Enable Vim keybindings │ -│ │ -│ Default Approval Mode Default │ -│ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ -│ │ -│ Enable Auto Update true │ -│ Enable automatic updates. │ -│ │ -│ Enable Notifications false │ -│ Enable run-event notifications for action-required prompts and session completion. │ -│ │ -│ Enable Plan Mode true │ -│ Enable Plan Mode for read-only safety during planning. │ -│ │ -│ Plan Directory undefined │ -│ The directory where planning artifacts are stored. If not specified, defaults t… │ -│ │ -│ Plan Model Routing true │ -│ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ -│ │ -│ Retry Fetch Errors true │ -│ Retry on "exception TypeError: fetch failed sending request" errors. │ -│ │ -│ ▼ │ -│ │ -│ Apply To │ -│ ● User Settings │ -│ Workspace Settings │ -│ System Settings │ -│ │ -│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ -│ │ -╰──────────────────────────────────────────────────────────────────────────────────────────────────╯" +"╭─────────────────────────────────────────────────────────────────────────────── +│ +│ > Settings +│ +│ ╭───────────────────────────────────────────────────────────────────────────── +│ │ Search to filter +│ ╰───────────────────────────────────────────────────────────────────────────── +│ +│ ▲ +│ ● Vim Mode +│ Enable Vim keybindings +│ +│ Default Approval Mode +│ The default approval mode for tool execution. 'default' prompts for approva +│ +│ Enable Auto Update +│ Enable automatic updates. +│ +│ Enable Notifications +│ Enable run-event notifications for action-required prompts and session comp +│ +│ Enable Plan Mode +│ Enable Plan Mode for read-only safety during planning. +│ +│ Plan Directory +│ The directory where planning artifacts are stored. If not specified, defaul +│ +│ Plan Model Routing +│ Automatically switch between Pro and Flash models based on Plan Mode status +│ +│ Retry Fetch Errors +│ Retry on "exception TypeError: fetch failed sending request" errors. +│ +│ ▼ +│ +│ Apply To +│ ● User Settings +│ Workspace Settings +│ System Settings +│ +│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) +│ +╰───────────────────────────────────────────────────────────────────────────────" `; exports[`SettingsDialog > Snapshot Tests > should render 'focused on scope selector' correctly 1`] = ` -"╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ -│ │ -│ > Settings │ -│ │ -│ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ -│ │ Search to filter │ │ -│ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ -│ │ -│ ▲ │ -│ ● Vim Mode false │ -│ Enable Vim keybindings │ -│ │ -│ Default Approval Mode Default │ -│ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ -│ │ -│ Enable Auto Update true │ -│ Enable automatic updates. │ -│ │ -│ Enable Notifications false │ -│ Enable run-event notifications for action-required prompts and session completion. │ -│ │ -│ Enable Plan Mode true │ -│ Enable Plan Mode for read-only safety during planning. │ -│ │ -│ Plan Directory undefined │ -│ The directory where planning artifacts are stored. If not specified, defaults t… │ -│ │ -│ Plan Model Routing true │ -│ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ -│ │ -│ Retry Fetch Errors true │ -│ Retry on "exception TypeError: fetch failed sending request" errors. │ -│ │ -│ ▼ │ -│ │ -│ Apply To │ -│ ● User Settings │ -│ Workspace Settings │ -│ System Settings │ -│ │ -│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ -│ │ -╰──────────────────────────────────────────────────────────────────────────────────────────────────╯" +"╭─────────────────────────────────────────────────────────────────────────────── +│ +│ Settings +│ +│ ╭───────────────────────────────────────────────────────────────────────────── +│ │ Search to filter +│ ╰───────────────────────────────────────────────────────────────────────────── +│ +│ ▲ +│ Vim Mode +│ Enable Vim keybindings +│ +│ Default Approval Mode +│ The default approval mode for tool execution. 'default' prompts for approva +│ +│ Enable Auto Update +│ Enable automatic updates. +│ +│ Enable Notifications +│ Enable run-event notifications for action-required prompts and session comp +│ +│ Enable Plan Mode +│ Enable Plan Mode for read-only safety during planning. +│ +│ Plan Directory +│ The directory where planning artifacts are stored. If not specified, defaul +│ +│ Plan Model Routing +│ Automatically switch between Pro and Flash models based on Plan Mode status +│ +│ Retry Fetch Errors +│ Retry on "exception TypeError: fetch failed sending request" errors. +│ +│ ▼ +│ +│ > Apply To +│ ● 1. User Settings +│ 2. Workspace Settings +│ 3. System Settings +│ +│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) +│ +╰───────────────────────────────────────────────────────────────────────────────" `; exports[`SettingsDialog > Snapshot Tests > should render 'mixed boolean and number settings' correctly 1`] = ` -"╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ -│ │ -│ > Settings │ -│ │ -│ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ -│ │ Search to filter │ │ -│ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ -│ │ -│ ▲ │ -│ ● Vim Mode false* │ -│ Enable Vim keybindings │ -│ │ -│ Default Approval Mode Default │ -│ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ -│ │ -│ Enable Auto Update false* │ -│ Enable automatic updates. │ -│ │ -│ Enable Notifications false │ -│ Enable run-event notifications for action-required prompts and session completion. │ -│ │ -│ Enable Plan Mode true │ -│ Enable Plan Mode for read-only safety during planning. │ -│ │ -│ Plan Directory undefined │ -│ The directory where planning artifacts are stored. If not specified, defaults t… │ -│ │ -│ Plan Model Routing true │ -│ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ -│ │ -│ Retry Fetch Errors true │ -│ Retry on "exception TypeError: fetch failed sending request" errors. │ -│ │ -│ ▼ │ -│ │ -│ Apply To │ -│ ● User Settings │ -│ Workspace Settings │ -│ System Settings │ -│ │ -│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ -│ │ -╰──────────────────────────────────────────────────────────────────────────────────────────────────╯" +"╭─────────────────────────────────────────────────────────────────────────────── +│ +│ > Settings +│ +│ ╭───────────────────────────────────────────────────────────────────────────── +│ │ Search to filter +│ ╰───────────────────────────────────────────────────────────────────────────── +│ +│ ▲ +│ ● Vim Mode +│ Enable Vim keybindings +│ +│ Default Approval Mode +│ The default approval mode for tool execution. 'default' prompts for approva +│ +│ Enable Auto Update +│ Enable automatic updates. +│ +│ Enable Notifications +│ Enable run-event notifications for action-required prompts and session comp +│ +│ Enable Plan Mode +│ Enable Plan Mode for read-only safety during planning. +│ +│ Plan Directory +│ The directory where planning artifacts are stored. If not specified, defaul +│ +│ Plan Model Routing +│ Automatically switch between Pro and Flash models based on Plan Mode status +│ +│ Retry Fetch Errors +│ Retry on "exception TypeError: fetch failed sending request" errors. +│ +│ ▼ +│ +│ Apply To +│ ● User Settings +│ Workspace Settings +│ System Settings +│ +│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) +│ +╰───────────────────────────────────────────────────────────────────────────────" `; exports[`SettingsDialog > Snapshot Tests > should render 'tools and security settings' correctly 1`] = ` -"╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ -│ │ -│ > Settings │ -│ │ -│ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ -│ │ Search to filter │ │ -│ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ -│ │ -│ ▲ │ -│ ● Vim Mode false │ -│ Enable Vim keybindings │ -│ │ -│ Default Approval Mode Default │ -│ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ -│ │ -│ Enable Auto Update true │ -│ Enable automatic updates. │ -│ │ -│ Enable Notifications false │ -│ Enable run-event notifications for action-required prompts and session completion. │ -│ │ -│ Enable Plan Mode true │ -│ Enable Plan Mode for read-only safety during planning. │ -│ │ -│ Plan Directory undefined │ -│ The directory where planning artifacts are stored. If not specified, defaults t… │ -│ │ -│ Plan Model Routing true │ -│ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ -│ │ -│ Retry Fetch Errors true │ -│ Retry on "exception TypeError: fetch failed sending request" errors. │ -│ │ -│ ▼ │ -│ │ -│ Apply To │ -│ ● User Settings │ -│ Workspace Settings │ -│ System Settings │ -│ │ -│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ -│ │ -╰──────────────────────────────────────────────────────────────────────────────────────────────────╯" +"╭─────────────────────────────────────────────────────────────────────────────── +│ +│ > Settings +│ +│ ╭───────────────────────────────────────────────────────────────────────────── +│ │ Search to filter +│ ╰───────────────────────────────────────────────────────────────────────────── +│ +│ ▲ +│ ● Vim Mode +│ Enable Vim keybindings +│ +│ Default Approval Mode +│ The default approval mode for tool execution. 'default' prompts for approva +│ +│ Enable Auto Update +│ Enable automatic updates. +│ +│ Enable Notifications +│ Enable run-event notifications for action-required prompts and session comp +│ +│ Enable Plan Mode +│ Enable Plan Mode for read-only safety during planning. +│ +│ Plan Directory +│ The directory where planning artifacts are stored. If not specified, defaul +│ +│ Plan Model Routing +│ Automatically switch between Pro and Flash models based on Plan Mode status +│ +│ Retry Fetch Errors +│ Retry on "exception TypeError: fetch failed sending request" errors. +│ +│ ▼ +│ +│ Apply To +│ ● User Settings +│ Workspace Settings +│ System Settings +│ +│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) +│ +╰───────────────────────────────────────────────────────────────────────────────" `; exports[`SettingsDialog > Snapshot Tests > should render 'various boolean settings enabled' correctly 1`] = ` -"╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ -│ │ -│ > Settings │ -│ │ -│ ╭──────────────────────────────────────────────────────────────────────────────────────────────╮ │ -│ │ Search to filter │ │ -│ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │ -│ │ -│ ▲ │ -│ ● Vim Mode true* │ -│ Enable Vim keybindings │ -│ │ -│ Default Approval Mode Default │ -│ The default approval mode for tool execution. 'default' prompts for approval, 'au… │ -│ │ -│ Enable Auto Update false* │ -│ Enable automatic updates. │ -│ │ -│ Enable Notifications false │ -│ Enable run-event notifications for action-required prompts and session completion. │ -│ │ -│ Enable Plan Mode true │ -│ Enable Plan Mode for read-only safety during planning. │ -│ │ -│ Plan Directory undefined │ -│ The directory where planning artifacts are stored. If not specified, defaults t… │ -│ │ -│ Plan Model Routing true │ -│ Automatically switch between Pro and Flash models based on Plan Mode status. Uses Pr… │ -│ │ -│ Retry Fetch Errors true │ -│ Retry on "exception TypeError: fetch failed sending request" errors. │ -│ │ -│ ▼ │ -│ │ -│ Apply To │ -│ ● User Settings │ -│ Workspace Settings │ -│ System Settings │ -│ │ -│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) │ -│ │ -╰──────────────────────────────────────────────────────────────────────────────────────────────────╯" +"╭─────────────────────────────────────────────────────────────────────────────── +│ +│ > Settings +│ +│ ╭───────────────────────────────────────────────────────────────────────────── +│ │ Search to filter +│ ╰───────────────────────────────────────────────────────────────────────────── +│ +│ ▲ +│ ● Vim Mode +│ Enable Vim keybindings +│ +│ Default Approval Mode +│ The default approval mode for tool execution. 'default' prompts for approva +│ +│ Enable Auto Update +│ Enable automatic updates. +│ +│ Enable Notifications +│ Enable run-event notifications for action-required prompts and session comp +│ +│ Enable Plan Mode +│ Enable Plan Mode for read-only safety during planning. +│ +│ Plan Directory +│ The directory where planning artifacts are stored. If not specified, defaul +│ +│ Plan Model Routing +│ Automatically switch between Pro and Flash models based on Plan Mode status +│ +│ Retry Fetch Errors +│ Retry on "exception TypeError: fetch failed sending request" errors. +│ +│ ▼ +│ +│ Apply To +│ ● User Settings +│ Workspace Settings +│ System Settings +│ +│ (Use Enter to select, Ctrl+L to reset, Tab to change focus, Esc to close) +│ +╰───────────────────────────────────────────────────────────────────────────────" `;