Let Cmd+Shift+/ open Help menu search (#21230)
Fixes #21230.
Summary
With a terminal focused, cmux sends every Command chord straight to the main menu and, when no menu item matches, types it into Ghostty. The macOS "Show Help menu" shortcut (Cmd+Shift+/ by default) matches no menu item, so Ghostty consumed it and AppKit never opened Help menu search.
Cmd+` already skips the direct-to-menu path for the same reason. This adds the same exemption for the System Settings "Show Help menu" shortcut (symbolic hot key 98), read the way the window-cycling shortcut is: a missing entry means the Cmd+Shift+/ default, a disabled entry turns the exemption off, and a remapped chord is followed. The shared predicate also covers the browser web view path.
Testing
SystemHelpMenuShortcutTests(CmuxBrowser package): resolving the System Settings entry, exact chord matching, and the routing regression. The test commit comes before the fix;helpMenuChordStaysWithAppKitfails without the exemption.- Not run locally: the
nx-remotebuild host alias does not resolve on this machine, so the package tests run in hosted CI only. - Not dogfooded in a tagged build.
Changelog
- Fixed: Cmd+Shift+/ opens the Help menu with its search field focused when a terminal or browser pane has focus.
š¤ Generated with Claude Code
Need help on this PR? Tag @codesmith-bot with what you need.
Summary by cubic
Fixes #21230 so Cmd+Shift+/ (and any remapped "Show Help menu" shortcut) opens the macOS Help menu with search focused when a terminal or browser pane has focus.
Previously cmux sent every Command chord straight to the main menu and then typed it into the terminal, so AppKit never saw the chord. The new SystemHelpMenuShortcut class resolves the System Settings binding for "Show Help menu" (symbolic hot key 98) and exempts that chord from the direct-to-menu path, matching the existing window-cycling exemption. The shared predicate now covers both terminal and browser web view paths.
- A missing System Settings entry falls back to the default Cmd+Shift+/; a disabled entry turns the exemption off, and a remapped chord is honored.
- Tests cover resolution, exact chord matching, and the routing regression.