diff --git a/packages/workflow-dashboard/src/components/thread-list.tsx b/packages/workflow-dashboard/src/components/thread-list.tsx index f14ca57..01fdf5d 100644 --- a/packages/workflow-dashboard/src/components/thread-list.tsx +++ b/packages/workflow-dashboard/src/components/thread-list.tsx @@ -14,7 +14,9 @@ export function ThreadList({ agent, onSelect }: Props) { if (status === "error") return
Error: {error}
; const threads = [...data.threads].sort((a, b) => { - if (!a.startedAt || !b.startedAt) return 0; + if (!a.startedAt && !b.startedAt) return 0; + if (!a.startedAt) return 1; + if (!b.startedAt) return -1; return b.startedAt.localeCompare(a.startedAt); }); @@ -42,15 +44,12 @@ export function ThreadList({ agent, onSelect }: Props) { className="text-xs px-2 py-0.5 rounded" style={{ background: - t.status === "running" + t.status === "completed" ? "var(--color-success)" : t.status === "failed" ? "var(--color-error)" - : t.status === "completed" - ? "var(--color-success)" - : "var(--color-accent)", + : "var(--color-accent)", color: "#000", - opacity: t.status === "completed" ? 0.7 : 1, }} > {t.status}