From 02ca8bbef5fff8a9459f787dd0c13dfc78a93707 Mon Sep 17 00:00:00 2001 From: Ben Brandt Date: Mon, 11 May 2026 18:13:31 +0200 Subject: [PATCH] agent_ui: Fix double hint for keybinding (#56442) Release Notes: - N/A --- crates/agent_ui/src/agent_panel.rs | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/crates/agent_ui/src/agent_panel.rs b/crates/agent_ui/src/agent_panel.rs index e7e2f62782..2a2a42b395 100644 --- a/crates/agent_ui/src/agent_panel.rs +++ b/crates/agent_ui/src/agent_panel.rs @@ -3767,9 +3767,10 @@ impl AgentPanel { }) .item( ContextMenuEntry::new("Zed Agent") - .when(is_agent_selected(Agent::NativeAgent), |this| { - this.action(Box::new(NewThread)) - }) + .when( + !showing_terminal && is_agent_selected(Agent::NativeAgent), + |this| this.action(Box::new(NewThread)), + ) .icon(IconName::ZedAgent) .icon_color(Color::Muted) .handler({ @@ -3873,9 +3874,10 @@ impl AgentPanel { entry = entry .when( - is_agent_selected(Agent::Custom { - id: item.id.clone(), - }), + !showing_terminal + && is_agent_selected(Agent::Custom { + id: item.id.clone(), + }), |this| this.action(Box::new(NewThread)), ) .icon_color(Color::Muted)