From 3407fa80a4b70d313c13da4a87dbc84b0197c2d5 Mon Sep 17 00:00:00 2001 From: Kyle Carberry Date: Thu, 12 Mar 2026 11:40:47 -0700 Subject: [PATCH] fix: only show subagent chevron on icon hover, not full row hover (#23010) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Summary When hovering on an agent row that is **not running**, the expand/collapse chevron (`>`) for subagents was appearing by replacing the status icon. This was visually distracting when scanning the sidebar. ## Change The chevron now only appears when hovering directly over the **icon area** (`group-hover/icon`), not the entire row (`group-hover`). This was already the behavior for running agents — this PR makes it consistent for all states. - Unified both the status-icon-hide and chevron-show hover triggers to use `group-hover/icon` - Removed the now-unused `isExecuting` variable (net -15 lines) --- site/src/pages/AgentsPage/AgentsSidebar.tsx | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) diff --git a/site/src/pages/AgentsPage/AgentsSidebar.tsx b/site/src/pages/AgentsPage/AgentsSidebar.tsx index b1628dd780..99d4856107 100644 --- a/site/src/pages/AgentsPage/AgentsSidebar.tsx +++ b/site/src/pages/AgentsPage/AgentsSidebar.tsx @@ -375,14 +375,6 @@ const ChatTreeNode = memo(({ chat, isChildNode }) => { const workspaceId = chat.workspace_id; const isArchivingThisChat = isArchiving && archivingChatId === chat.id; const isExpanded = normalizedSearch ? true : (expandedById[chatID] ?? false); - const isExecuting = - chat.status === "pending" || - chat.status === "running" || - (hasChildren && - childIDs.some((id) => { - const c = chatById.get(id); - return c?.status === "pending" || c?.status === "running"; - })); return (
@@ -405,12 +397,7 @@ const ChatTreeNode = memo(({ chat, isChildNode }) => {
(({ chat, isChildNode }) => { onClick={() => toggleExpanded(chatID)} className={cn( "absolute inset-0 invisible flex h-5 w-5 min-w-0 items-center justify-center rounded-md p-0 text-content-secondary/60 hover:text-content-primary [&>svg]:size-3.5", - isExecuting - ? "[@media(hover:hover)]:group-hover/icon:visible" - : "[@media(hover:hover)]:group-hover:visible", + "[@media(hover:hover)]:group-hover/icon:visible", )} data-testid={`agents-tree-toggle-${chat.id}`} aria-label={isExpanded ? "Collapse" : "Expand"}