Skip to content

terminal_view: Show terminal inline assist keybinding in tooltip - #55903

Merged
smitbarmase merged 3 commits into
zed-industries:mainfrom
di404:codex/fix-terminal-inline-assist-tooltip
Jul 3, 2026
Merged

terminal_view: Show terminal inline assist keybinding in tooltip#55903
smitbarmase merged 3 commits into
zed-industries:mainfrom
di404:codex/fix-terminal-inline-assist-tooltip

Conversation

@di404

@di404 di404 commented May 6, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Fixed the terminal inline assist tab bar tooltip so it resolves the keybinding from the active terminal view.
  • The bug happened when the initial terminal was closed and a new terminal was opened: the tab bar button kept a cached focus handle for the old terminal, so tooltip keybinding lookup could no longer find the terminal key context.
  • The button is now created while rendering the tab bar with the current terminal view's focus handle, avoiding stale focus handles as terminals are closed and recreated.

Validation

  • cargo fmt --package terminal_view --check
  • cargo check -p terminal_view --message-format short

Release Notes:

  • Fixed the terminal inline assist toolbar tooltip not showing its keybinding after reopening terminals.

@cla-bot cla-bot Bot added the cla-signed The user has signed the Contributor License Agreement label May 6, 2026
@zed-community-bot zed-community-bot Bot added the first contribution the author's first pull request to Zed. NOTE: the label application is automated via github actions label May 6, 2026
@di404
di404 marked this pull request as ready for review May 6, 2026 16:49
@ChristopherBiscardi ChristopherBiscardi added the area:integrations/terminal Feedback for terminal integration, shell commands, etc label May 6, 2026

@smitbarmase smitbarmase left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I made two changes on top. Clicking the inline assist button did nothing since we were recreating the button entity on every render, so turned that to RenderOnce component. Also added a test.

@smitbarmase
smitbarmase enabled auto-merge July 3, 2026 13:44
@smitbarmase
smitbarmase added this pull request to the merge queue Jul 3, 2026
Merged via the queue into zed-industries:main with commit be7e5b0 Jul 3, 2026
34 checks passed
@di404
di404 deleted the codex/fix-terminal-inline-assist-tooltip branch July 3, 2026 14:09
@smitbarmase smitbarmase self-assigned this Jul 3, 2026
TakuroBreath pushed a commit to TakuroBreath/zed that referenced this pull request Jul 7, 2026
…-industries#55903)

## Summary

- Fixed the terminal inline assist tab bar tooltip so it resolves the
keybinding from the active terminal view.
- The bug happened when the initial terminal was closed and a new
terminal was opened: the tab bar button kept a cached focus handle for
the old terminal, so tooltip keybinding lookup could no longer find the
terminal key context.
- The button is now created while rendering the tab bar with the current
terminal view's focus handle, avoiding stale focus handles as terminals
are closed and recreated.

## Validation

- `cargo fmt --package terminal_view --check`
- `cargo check -p terminal_view --message-format short`

Release Notes:

- Fixed the terminal inline assist toolbar tooltip not showing its
keybinding after reopening terminals.

---------

Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
jolutz pushed a commit to jolutz/zed that referenced this pull request Aug 8, 2026
…-industries#55903)

## Summary

- Fixed the terminal inline assist tab bar tooltip so it resolves the
keybinding from the active terminal view.
- The bug happened when the initial terminal was closed and a new
terminal was opened: the tab bar button kept a cached focus handle for
the old terminal, so tooltip keybinding lookup could no longer find the
terminal key context.
- The button is now created while rendering the tab bar with the current
terminal view's focus handle, avoiding stale focus handles as terminals
are closed and recreated.

## Validation

- `cargo fmt --package terminal_view --check`
- `cargo check -p terminal_view --message-format short`

Release Notes:

- Fixed the terminal inline assist toolbar tooltip not showing its
keybinding after reopening terminals.

---------

Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:integrations/terminal Feedback for terminal integration, shell commands, etc cla-signed The user has signed the Contributor License Agreement first contribution the author's first pull request to Zed. NOTE: the label application is automated via github actions

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants