Add split terminal File menu; drop tab-bar hover popover#318
Merged
Conversation
…minal commands
Restructures the File menu to mirror Ghostty's: "New Terminal Tab", four
"Split Terminal {Right,Left,Down,Up}" entries with SF Symbol icons, and
moves "Close Terminal" / "Close Terminal Tab" next to "Close Window" in the
.saveItem group. Adds a `splitTerminal(direction)` reducer action, gates the
File-menu split items on a focused surface via `.focusedValue`, and shows
hotkey hints on the tab-bar long-press menu items.
Tab-bar trailing accessories shed the 350ms hover popover that duplicated
the inline split buttons; the two split buttons become `Menu` + primaryAction
so click splits in the primary direction and long-press reveals both
directions. New `SecondaryToolbarMenuStyle` consolidates the borderless
menu chrome shared with the sidebar repo ellipsis menu.
Drops the local `KeyboardShortcutModifier` wrapper now that SwiftUI's
nilable `keyboardShortcut(_:)` overload exists, and introduces a
`ghosttyKeyboardShortcut(_:in:)` helper that funnels through the same
nilable overload so menu-bar `CommandGroup`s keep a stable view identity
when Ghostty shortcuts hydrate from disk (avoids stripping Tahoe menu
arrangement items).
Also fixes a pre-existing bug where the in-surface search overlay looked
up `search:next` / `search:previous` instead of Ghostty's actual action
names `navigate_search:next` / `navigate_search:previous`, leaving the
Next/Previous buttons without their shortcut hints.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
New Terminal Tab, divider, fourSplit Terminal {Right,Left,Down,Up}entries with SF Symbol icons. MovesClose Terminal/Close Terminal Tabinto the.saveItemgroup next toClose Window.+hover popover (350 ms debounce, pointer guards, click-suppression — duplicated the inline split buttons next to it) with twoMenu+primaryAction:controls: click splits in the primary direction, long-press / right-click shows both directions.KeyboardShortcutModifierViewModifier; introducesghosttyKeyboardShortcut(_:in:)that funnels through SwiftUI's nilablekeyboardShortcut(_:)overload so menu-barCommandGroups keep a stable view identity when Ghostty shortcuts hydrate from disk (sidesteps stripped Tahoe menu arrangement items, mirroringappKeyboardShortcutinSupacodeSettingsShared).SecondaryToolbarMenuStyle(customMenuStyle) shared between the tab-bar split menus and the sidebar repo-section ellipsis menu — replaces the 4-modifier chain that was duplicated across both call sites.GhosttySurfaceSearchOverlay: the Next/Previous buttons were looking up"search:next"/"search:previous"instead of Ghostty's actual action names"navigate_search:next"/"navigate_search:previous", so their shortcut hints never rendered. Same correction inTerminalCommandsandGhosttyShortcutManager.terminalActions.Test plan
make build-appsucceeds.make check(format + lint) clean.AppFeatureSplitTerminalTests(9 cases: 4 reducer + 4 binding-pin + 1 no-op) passes.