mirror of
https://github.com/stablyai/orca.git
synced 2026-10-20 16:03:20 +00:00
fix(dashboard): remove per-worktree status dot from agent cards
This commit is contained in:
@@ -144,7 +144,7 @@ describe('AgentKanbanCard', () => {
|
||||
expect(onOpenTerminal).toHaveBeenCalledTimes(1)
|
||||
})
|
||||
|
||||
it('labels one subagent and the workspace status accessibly', () => {
|
||||
it('labels one subagent accessibly and never renders a workspace-status dot', () => {
|
||||
renderCard({
|
||||
card: card({
|
||||
workspaceStatusId: 'in-review',
|
||||
@@ -156,7 +156,7 @@ describe('AgentKanbanCard', () => {
|
||||
})
|
||||
|
||||
expect(screen.getByRole('button', { name: '1 subagent' })).toBeInTheDocument()
|
||||
expect(screen.getByRole('img', { name: 'In review' })).toBeInTheDocument()
|
||||
expect(screen.queryByRole('img', { name: 'In review' })).not.toBeInTheDocument()
|
||||
})
|
||||
|
||||
it('tints attention amber and done green, leaving every other state neutral', () => {
|
||||
|
||||
@@ -17,7 +17,6 @@ import { cn } from '@/lib/utils'
|
||||
import type { DashboardCard } from '../../../../shared/dashboard-snapshot'
|
||||
import type { RepoIcon } from '../../../../shared/repo-icon'
|
||||
import { translate } from '@/i18n/i18n'
|
||||
import { getWorkspaceStatusVisualMeta } from '../sidebar/workspace-status'
|
||||
|
||||
/** Compact "started N ago" (the card is glanceable — coarse units are fine). */
|
||||
function formatStartedAgo(startedAt: number, now: number): string {
|
||||
@@ -93,9 +92,6 @@ function sameCard(a: DashboardCard, b: DashboardCard): boolean {
|
||||
a.leafId === b.leafId &&
|
||||
a.repoName === b.repoName &&
|
||||
a.worktreeName === b.worktreeName &&
|
||||
a.workspaceStatusId === b.workspaceStatusId &&
|
||||
a.workspaceStatusLabel === b.workspaceStatusLabel &&
|
||||
a.workspaceStatusColor === b.workspaceStatusColor &&
|
||||
a.hasReview === b.hasReview &&
|
||||
a.review?.number === b.review?.number &&
|
||||
a.review?.state === b.review?.state &&
|
||||
@@ -200,14 +196,6 @@ export const AgentKanbanCard = memo(
|
||||
}: AgentKanbanCardProps): React.JSX.Element {
|
||||
useTranslation()
|
||||
const [subagentsOpen, setSubagentsOpen] = useState(false)
|
||||
const workspaceStatusMeta =
|
||||
card.workspaceStatusId && card.workspaceStatusLabel
|
||||
? getWorkspaceStatusVisualMeta({
|
||||
id: card.workspaceStatusId,
|
||||
label: card.workspaceStatusLabel,
|
||||
color: card.workspaceStatusColor
|
||||
})
|
||||
: null
|
||||
// Why: the two outcomes worth scanning for get a tinted card — amber for
|
||||
// "answer me", green for "finished, look at it". Everything else stays
|
||||
// neutral so the tint keeps meaning something.
|
||||
@@ -322,14 +310,6 @@ export const AgentKanbanCard = memo(
|
||||
onClick={() => onOpenTerminal(card)}
|
||||
className="flex w-full items-center gap-2 rounded-md text-left text-[11px] text-muted-foreground focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none"
|
||||
>
|
||||
{workspaceStatusMeta ? (
|
||||
<span
|
||||
role="img"
|
||||
aria-label={card.workspaceStatusLabel}
|
||||
className={cn('size-2 shrink-0 rounded-full', workspaceStatusMeta.swatch)}
|
||||
title={card.workspaceStatusLabel}
|
||||
/>
|
||||
) : null}
|
||||
<Tooltip>
|
||||
<TooltipTrigger asChild>
|
||||
<span
|
||||
|
||||
Reference in New Issue
Block a user