diff --git a/apps/desktop/src/app/command-palette/index.tsx b/apps/desktop/src/app/command-palette/index.tsx index ce9f0149e5..f9a640000a 100644 --- a/apps/desktop/src/app/command-palette/index.tsx +++ b/apps/desktop/src/app/command-palette/index.tsx @@ -13,7 +13,6 @@ import { HUD_SURFACE, HUD_TEXT } from '@/app/floating-hud' -import { setTerminalTakeover } from '@/app/right-sidebar/store' import { codiconIcon } from '@/components/ui/codicon' import { Command, CommandGroup, CommandInput, CommandItem, CommandList } from '@/components/ui/command' import { HighlightMatches } from '@/components/ui/highlight-matches' @@ -52,7 +51,6 @@ import { SlidersHorizontal, Starmap, Sun, - Terminal, Users, Wrench, Zap @@ -771,14 +769,6 @@ function CommandPaletteBody({ onExited }: { onExited: () => void }) { } ] : []), - { - action: 'view.showTerminal', - icon: Terminal, - id: 'nav-terminal', - keywords: ['terminal', 'shell', 'console'], - label: t.keybinds.actions['view.showTerminal'], - run: () => setTerminalTakeover(true) - }, { action: 'nav.settings', icon: Settings, diff --git a/apps/desktop/src/app/contrib/controller.tsx b/apps/desktop/src/app/contrib/controller.tsx index 5ab0af5a78..3c4d1d3e98 100644 --- a/apps/desktop/src/app/contrib/controller.tsx +++ b/apps/desktop/src/app/contrib/controller.tsx @@ -37,7 +37,7 @@ import { useContributions } from '@/contrib/react/use-contributions' import { registry } from '@/contrib/registry' import { discoverRuntimePlugins } from '@/contrib/runtime-loader' import { sessionTitle as storedSessionTitle } from '@/lib/chat-runtime' -import { FileText, LayoutDashboard, PanelBottom, Zap } from '@/lib/icons' +import { FileText, LayoutDashboard, PanelBottom, Terminal, Zap } from '@/lib/icons' import { type KeybindContribution, KEYBINDS_AREA } from '@/lib/keybinds/actions' import { setYoloEnabled } from '@/lib/yolo-session' import { pruneComposerPopoutZones } from '@/store/composer-popout' @@ -568,6 +568,19 @@ bindPaneCollapse( () => setTerminalTakeover(false), () => setTerminalTakeover(true) ) +// ⌘K door onto the same store the keybind and statusbar pill flip — was a +// one-way "open" row under Go to, so it never showed on/off and couldn't hide. +registry.register( + paletteToggle({ + id: 'view.showTerminal', + label: 'Toggle terminal', + action: 'view.showTerminal', + icon: Terminal, + keywords: ['terminal', 'shell', 'console', 'pty'], + get: () => $terminalTakeover.get(), + set: setTerminalTakeover + }) +) // Preview EXISTS only while something is previewed (old-shell semantics: // closing the last preview tab closes the pane; a new target opens + fronts