fix(tui): align Ctrl+L and /model with classic CLI semantics

Make Ctrl+L non-destructive by redrawing the current screen state instead of starting a new session, and stop auto-appending --global for typed /model commands so session scope remains the default unless explicitly requested.
This commit is contained in:
Brooklyn Nicholson 2026-04-27 12:23:56 -05:00
parent d5a89283b7
commit 4909b94f99
5 changed files with 11 additions and 19 deletions

View file

@ -26,7 +26,7 @@ describe('createSlashHandler', () => {
expect(ctx.gateway.gw.request).not.toHaveBeenCalled()
})
it('persists typed /model switches by default', async () => {
it('keeps typed /model switches session-scoped by default', async () => {
patchUiState({ sid: 'sid-abc' })
const ctx = buildCtx({
@ -40,7 +40,7 @@ describe('createSlashHandler', () => {
expect(ctx.gateway.rpc).toHaveBeenCalledWith('config.set', {
key: 'model',
session_id: 'sid-abc',
value: 'x-model --global'
value: 'x-model'
})
})