Skip to content
Source
Sign inSign up
pingdotgg/t3code
Open History to see the last commit

ThreadSyncStatusPill.tsx

18 lines679 Bytes

1import { LoaderCircleIcon } from "lucide-react";
2​
3import { threadSyncLabel, type ThreadSyncPhase } from "../../threadSync";
4​
5export function ThreadSyncStatusPill({ phase }: { readonly phase: ThreadSyncPhase }) {
6 const label = threadSyncLabel(phase);
7​
8 return (
9 <div
10 aria-label={label}
11 className="pointer-events-none mx-auto mb-2 flex w-fit max-w-full items-center gap-2 rounded-full border border-border/60 bg-card/95 px-3 py-1.5 text-foreground text-xs font-medium shadow-sm"
12 role="status"
13 >
14 <LoaderCircleIcon aria-hidden className="size-3.5 shrink-0 text-muted-foreground" />
15 <span className="truncate">{label}</span>
16 </div>
17 );