import { Box, Zap, ArrowLeftRight, Settings2 } from "lucide-react"; import { getRuntimeStateLabel, getRuntimeStatusTone } from "../../runtime/runtime-utils"; import type { RuntimeSnapshot } from "../../runtime/types"; export type Section = "model" | "runtime" | "connection" | "advanced"; const NAV: { id: Section; label: string; icon: typeof Box }[] = [ { id: "model", label: "Model", icon: Box }, { id: "runtime", label: "Runtime", icon: Zap }, { id: "connection", label: "Connection", icon: ArrowLeftRight }, { id: "advanced", label: "Advanced", icon: Settings2 }, ]; function statusColor(snapshot: RuntimeSnapshot): string { const tone = getRuntimeStatusTone(snapshot); if (tone === "success") return "bg-green-500 shadow-[0_0_6px_rgba(48,209,88,0.55)]"; if (tone === "warning") return "bg-yellow-500 animate-pulse"; if (tone === "danger") return "bg-red-500"; return "bg-neutral-500"; } interface Props { section: Section; setSection: (section: Section) => void; snapshot: RuntimeSnapshot; loading: boolean; onClose: () => void; } export function SettingsSidebar({ section, setSection, snapshot, loading, onClose }: Props) { const runtimeStatusLabel = loading ? "Loading..." : getRuntimeStateLabel(snapshot); return ( ); }