Skip to content

Add missing panels to View menu#60356

Open
dinocosta wants to merge 1 commit into
mainfrom
chore/view-menu-panels
Open

Add missing panels to View menu#60356
dinocosta wants to merge 1 commit into
mainfrom
chore/view-menu-panels

Conversation

@dinocosta

Copy link
Copy Markdown
Member

Objective

Ensure that all existing panels have corresponding menu items in the "View" menu. I was onboarding a friend to Zed yesterday that was having a hard time figuring out how to interact with the Agent. Although he did open the "View" menu, I noticed that the Agent panel item was missing from there, making it hard for new users to discover it exists.

Solution

  • Add both "Agent Panel" and "Git Panel" entries to the menu items for the "View" app menu.
  • Update the action used for the "Terminal Panel" menu item from terminal_panel::ToggleFocus to terminal_panel::Toggle to ensure we display a shortcut for this menu item.
    • Another valid option would be to update the default keymap to use terminal_panel::ToggleFocus instead but that would probably break existing user's expectations that the default shortcut toggles the terminal panel, instead of toggling its focus.
  • Introduce zed_actions::git_panel to be able to extract its ToggleFocus action, following the existing pattern.

Next Steps

It's worth noting that, even though there's now an "Agent Panel" item mapped to the assistant::ToggleFocus action, its default keybinding is not displayed (at least on macOS), because of the way it's defined as cmd-? . Using cmd-shift-/ instead doesn't work, so we'll likely have to update MacKeyboardMapper to allow mapping between shifted and unshifted keys equivalent, that is, when ? is detected, it is able to determine that, in the user's layout that is the result of shift-/.

Testing

Manually tested, screenshots can be seen in the "Showcase" section.

Self-Review Checklist:

  • I've reviewed my own diff for quality, security, and reliability
  • Unsafe blocks (if any) have justifying comments
  • The content adheres to Zed's UI standards (UX/UI and icon guidelines)
  • Tests cover the new/changed behavior
  • Performance impact has been considered and is acceptable

Showcase

Before CleanShot 2026-07-03 at 14 24 35@2x
After CleanShot 2026-07-03 at 14 24 59@2x

Release Notes:

  • Added "Agent Panel" and "Git Panel" items to the "View" menu

* Add both "Agent Panel" and "Git Panel" entries to the menu items for
  the "View" app menu.
* Update the action used for the "Terminal Panel" menu item from
  `terminal_panel::ToggleFocus` to `terminal_panel::Toggle` to ensure we
  display a shortcut for this menu item.
  * Another valid option would be to update the default keymap to use
    `terminal_panel::ToggleFocus` instead but that would probably break
    existing user's expectations that the default shortcut toggles the
    terminal panel, instead of toggling its focus.
* Introduce `zed_actions::git_panel` to be able to extract its
  `ToggleFocus` action, following the existing pattern.
@cla-bot cla-bot Bot added the cla-signed The user has signed the Contributor License Agreement label Jul 3, 2026
@zed-community-bot zed-community-bot Bot added the staff Pull requests authored by a current member of Zed staff label Jul 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla-signed The user has signed the Contributor License Agreement staff Pull requests authored by a current member of Zed staff

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant