Repository navigation
Description
Workflow
I move between threads, plugin pages, and settings many times an hour. The sidebar has back and forward history buttons (SidebarHistoryNavigationControls), but they are mouse-only. Every browser and editor I use binds history navigation to Cmd+[ / Cmd+] on macOS (Ctrl+[ / Ctrl+] elsewhere), and my hands keep reaching for it in bb.
Current behavior
useRouteStateHistoryNavigation and the sidebar buttons exist:
| const handleBack = useCallback(() => { | |
| if (!canGoBack) { | |
| return; | |
| } | |
| goBack(); | |
| onNavigate?.(); | |
| }, [canGoBack, goBack, onNavigate]); | |
| const handleForward = useCallback(() => { | |
| if (!canGoForward) { | |
| return; | |
| } | |
| goForward(); | |
| onNavigate?.(); | |
| }, [canGoForward, goForward, onNavigate]); | |
No history.* command id exists in the rebindable registry, so there is nothing to bind in Settings → Keyboard and nothing to run from the palette:
bb/packages/domain/src/app-keybindings.ts
Line 38 in 33c1564
| export const APP_COMMAND_IDS = [ |
The desktop menu has no accelerator for it either.
Expected
Two core app commands, history.back and history.forward, with default shortcuts Mod+[ and Mod+], that:
- appear in Settings → Keyboard, the quick palette, and
bb settings keyboard, and are rebindable like every other core command; - are excluded while a modal is open or while an editable field, the terminal, or the embedded browser has focus, so typing
[in the composer, a terminal, or a web page is never intercepted; - decline when there is no history entry in that direction, so the key keeps its native behavior instead of swallowing the press;
- are registered in the app command registry rather than as an Electron accelerator, so the editable-focus guard actually holds (a menu accelerator fires before the renderer sees the key);
- expose the resolved chord on the sidebar buttons through
aria-keyshortcuts.
Prototype
I have this working on my fork on branch bi/back-forward-shortcuts (head 5784d066c, 10 files, about 250 lines including a 180-line handler test). The change touches packages/domain/src/app-keybindings.ts, apps/server/src/services/system/app-keybindings.ts, apps/app/src/lib/app-command-metadata.ts, a new HistoryNavigationCommandHandler mounted from AppLayout, the sidebar controls, and the docs and CLI skill references for the two new command ids. I can push it and open a PR if the design above is acceptable, or adjust the defaults first if Mod+[ conflicts with something planned.
Versions
upstream/mainat33c1564e5e49499f3baef7da5dbf112b876d153f- macOS 26.6, desktop app 0.43.1
AGENT GENERATED
Activity
bb-slop-cop commentedon Sep 15, 2026
🚨 SLOP COP 🚨 ·
new-issue-autopilotApplied Type Feature, Priority Low, Effort Medium, and label ui. All were previously unset; final values verified.
This adds keyboard navigation behavior, with existing sidebar buttons providing a workaround. Implementation spans command registration, focus handling, and shortcut presentation. No report or pull request: the rule skips reproduction and fixes for non-bugs.
benwaffle commentedon Sep 15, 2026
Permalinks for the fork implementation described above:
Add ⌘[ / ⌘] shortcuts to the sidebar's back and forward (#4897)
ymichael commentedon Oct 8, 2026
Fixed by #4897: ⌘[ / ⌘] now go back and forward, and both are rebindable.