@devries-cameron20 / t3code Mirror · read-only
Fork 0

The best way to control Claude Code, Codex and more from any computer or phone

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 21, 04:45 UTC

main
tsx 36 lines 968 Bytes
Raw
1 import { View } from "react-native";
2
3 import { cn } from "../../lib/cn";
4 import type { SubagentRowTone } from "./threadAgentsPresentation";
5
6 const TONE_CLASS = {
7 working: "bg-adaptive-sky-600-400",
8 completed: "bg-adaptive-emerald-600-400",
9 failed: "bg-adaptive-rose-600-400",
10 stopped: "bg-foreground-muted",
11 } as const satisfies Record<SubagentRowTone, string>;
12
13 export const SUBAGENT_TONE_TEXT_CLASS = {
14 working: "text-adaptive-sky-600-400",
15 completed: "text-adaptive-emerald-600-400",
16 failed: "text-adaptive-rose-600-400",
17 stopped: "text-foreground-muted",
18 } as const satisfies Record<SubagentRowTone, string>;
19
20 export function SubagentStatusDot({
21 tone,
22 placement = "inline",
23 }: {
24 readonly tone: SubagentRowTone;
25 readonly placement?: "inline" | "sheet";
26 }) {
27 return (
28 <View
29 className={cn(
30 "shrink-0 rounded-full",
31 placement === "sheet" ? "h-2 w-2" : "h-1.5 w-1.5",
32 TONE_CLASS[tone],
33 )}
34 />
35 );
36 }