fix(dashboard): stop the agent icon shrinking on long card titles (#11001)

A bare <svg> flex item shrinks with its row, so kanban cards and the
terminal dialog rendered a squashed ~9px agent icon whenever the worktree
name overflowed. Wrap both in the shrink-0 span every other surface
already uses.
This commit is contained in:
Brennan Benson 2026-07-27 16:19:22 -07:00 committed by GitHub
parent 3716a7bb49
commit 1fcbf8e5fe
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 7 additions and 2 deletions

View File

@ -86,7 +86,10 @@ export const AgentKanbanCard = memo(
)}
>
<div className="flex items-center gap-1.5">
<AgentIcon agent={agentTypeToIconAgent(card.agentType)} size={14} />
{/* Why: a bare <svg> flex item shrinks with the row — long worktree names squashed the icon. */}
<span className="inline-flex shrink-0">
<AgentIcon agent={agentTypeToIconAgent(card.agentType)} size={14} />
</span>
<span
// Why: same unvisited treatment as the sidebar's DashboardAgentRow —
// bold+bright until acked, normal+muted after — so both surfaces

View File

@ -79,7 +79,9 @@ export function AgentTerminalDialog({
}}
>
<div className="flex items-center gap-1.5 px-2.5 py-2">
<AgentIcon agent={agentTypeToIconAgent(card.agentType)} size={13} />
<span className="inline-flex shrink-0">
<AgentIcon agent={agentTypeToIconAgent(card.agentType)} size={13} />
</span>
<DialogTitle className="text-[12px] leading-normal font-semibold">
{card.worktreeName}
</DialogTitle>