import { cn } from "cn" import type { Lampe as LampenDaten, Start } from "@/lib/typen" import { hauptleuchte } from "@/lib/anzeige" import { Lampe } from "./Lampe" type Zustand = Start["zustand"] const LEUCHTE: Record["art"], string> = { ok: "border-gruen-rand bg-gruen-grund text-gruen", info: "border-cyan-rand bg-cyan-grund text-cyan", stumm: "border-aus-rand bg-aus-grund text-aus-text", gelb: "border-2 border-bernstein bg-bernstein-grund text-bernstein-hell lampe-atmet", rot: "border-2 border-rot bg-rot-grund text-rot shadow-[0_0_32px_rgba(255,90,79,0.3)]", } export function Warnpanel({ zustand, lampen, onAnsehen }: { zustand: Zustand lampen: LampenDaten[] onAnsehen: () => void }) { const h = hauptleuchte(zustand) const aktiv = h.art === "gelb" || h.art === "rot" return (
) }