MCPcopy Create free account
hub / github.com/freecodexyz/free-code / TaskStatusText

Function TaskStatusText

src/components/tasks/ShellProgress.tsx:13–33  ·  view source on GitHub ↗
(t0)

Source from the content-addressed store, hash-verified

11 suffix?: string;
12};
13export function TaskStatusText(t0) {
14 const $ = _c(4);
15 const {
16 status,
17 label,
18 suffix
19 } = t0;
20 const displayLabel = label ?? status;
21 const color = status === "completed" ? "success" : status === "failed" ? "error" : status === "killed" ? "warning" : undefined;
22 let t1;
23 if ($[0] !== color || $[1] !== displayLabel || $[2] !== suffix) {
24 t1 = <Text color={color} dimColor={true}>({displayLabel}{suffix})</Text>;
25 $[0] = color;
26 $[1] = displayLabel;
27 $[2] = suffix;
28 $[3] = t1;
29 } else {
30 t1 = $[3];
31 }
32 return t1;
33}
34export function ShellProgress(t0) {
35 const $ = _c(4);
36 const {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected