feat(desktop): remove close buttons from sidebar inline agent dropdown

Merged
KI
3mo ago
+9-168

Summary

  • Removes the per-agent stop (×) button and the "Stop all agents" footer from the running-agents hover card on the dashboard sidebar workspace row. The card is now open/navigate-only; each row always shows the agent's status instead of swapping it for a × on hover.
  • Deletes the now-orphaned useDashboardSidebarAgentKill hook and the chip's kill-pending spinner state.

How It Works

DashboardSidebarAgentHoverRow drops the grid overlay that swapped status text and the × in one cell; the status label is now a plain always-visible span. DashboardSidebarAgentsChip drops the separator + footer button, handleStopAll, and the isPending plumbing (spinner, disabled, aria-busy) that only existed for the kill flow.

Manual QA (CDP, end-to-end)

Verified in this workspace's dev desktop instance (Vite port 3765, CDP 9250, signed-in session with active org confirmed). Since the chip only renders with 2+ running agents, launched two Claude agents in a workspace via the real presets bar, then clicked the sidebar "✳ 2" chip with real mouse input.

Hover card open with an agent row hovered — no × on the row, no separator, no "Stop all agents" footer:

agents hover card after removal

Full window for context:

full window

DOM inspection of the open card confirms zero stop/close buttons. Chip open/close toggle and row click-through to the workspace still work (used them during capture).

  • Chip renders with 2 running agents and opens the card on click
  • Agent rows show label + status only; hovering a row reveals no ×
  • No separator/footer below the agent list
  • Clicking an agent row still navigates to that agent's terminal

Testing

  • bun run lint (clean)
  • tsc --noEmit for apps/desktop (clean)

Screenshots live on the evidence/remove-agent-close-button branch per the repo's evidence convention.


Summary by cubic

Removed per‑agent stop buttons and the “Stop all agents” footer from the desktop sidebar agents hover card. The card is now navigation‑only: rows always show status, and the chip shows avatar + count.

  • Refactors
    • Removed kill controls and deleted useDashboardSidebarAgentKill.
    • Simplified DashboardSidebarAgentsChip by dropping pending state, spinner, toasts, and disabled logic.
    • Simplified DashboardSidebarAgentHoverRow to show a plain, always-visible status label (no hover swap or kill button).

Summary by CodeRabbit

  • Changes
    • Simplified the dashboard sidebar’s agent display.
    • Agent counts now appear directly without loading indicators.
    • Agent rows consistently show status information.
    • Removed controls for stopping individual or all agents from the sidebar.