fix(web): color custom terminal failure outcomes accurately

This commit is contained in:
2026-10-20 18:33:20 +01:00
parent 34939edd0e
commit b3bcfa3826
2 changed files with 14 additions and 1 deletions
+4 -1
View File
@@ -32,7 +32,10 @@ export function miniatureModel(graph, run = null) {
// A recorded current stage is evidence even in a compact list summary.
const current = run?.executing && run.current_stage === node.key;
const status = step?.status ?? (current ? run.status : null);
const color = status === "completed" ? edgeStrokeColor(step.outcome) : status ? miniatureColor(status) : null;
// Custom outcome names do not override a recorded terminal verdict.
const color = step?.target === "#failure" ? "var(--bad)"
: step?.target === "#success" ? "var(--ok)"
: status === "completed" ? edgeStrokeColor(step.outcome) : status ? miniatureColor(status) : null;
return { ...node, color,
untaken: Boolean(run) && !step && !current };
}),