import { User, ChevronDown } from "lucide-react"; import type { Identity } from "../lib/api"; import { useHealth } from "../lib/health"; import { cn } from "../ui"; function Light({ on, label, unknown }: { on?: boolean; label: string; unknown?: boolean }) { const dot = unknown ? "bg-slate-600" : on ? "bg-success shadow-[0_0_8px_rgba(52,211,153,0.7)]" : "bg-danger"; return ( {label} ); } // 顶栏:品牌 · 垂直切换 · 健康灯 · 身份/会话(深色 + 毛玻璃)。 export function TopBar({ identity, setIdentity }: { identity: Identity; setIdentity: (id: Identity) => void }) { const h = useHealth(); return (
S
sundynix-agentix
setIdentity({ ...identity, userId: e.target.value })} title="用户" />
setIdentity({ ...identity, sessionId: e.target.value })} title="会话" />
); }