Frontend-Rundumschlag: Health-Logik + Statuszeile an neue LLM-Landschaft angepasst
(1) useLucyHealth: ruhende Augen sind seit der Warm-Set-Diaet 07.07. der
NORMALZUSTAND (vision on-demand, Lucy waermt selbst) -> kein Dauer-warn
mehr im Cockpit ('Kleinigkeit an der Box' ohne Grund). Geladen = 'sieht
gerade zu', ruhend = ok mit ehrlicher Erklaerung + Weck-Knopf.
(2) Cockpit-Statuszeile SAGT jetzt, was der Hinweis ist (erster warn-Check
mit Label+Detail statt generischem 'Nichts Schlimmes — nur ein Hinweis';
User-Feedback 08.07.). useLucyHealth exportiert dafuer die warns-Liste.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -81,7 +81,7 @@ export function CockpitView({ onNavigate }: { onNavigate: (v: string) => void })
|
||||
</div>
|
||||
|
||||
{/* Ehrliche Status-Zeile */}
|
||||
<StatusLine verdict={health.verdict} memory={health.memory} />
|
||||
<StatusLine verdict={health.verdict} memory={health.memory} warns={health.warns} />
|
||||
|
||||
{/* „Braucht dich" — offene Aktionen, sonst Ruhe */}
|
||||
<NeedsYou
|
||||
@@ -175,11 +175,20 @@ function ZoneLabel({ children }: { children: React.ReactNode }) {
|
||||
}
|
||||
|
||||
// Ehrliche Status-Zeile: großes Verdikt + Speicher-Pille. Erzählrahmen = Box.
|
||||
function StatusLine({ verdict, memory }: { verdict: ReturnType<typeof useLucyHealth>["verdict"]; memory: ReturnType<typeof useLucyHealth>["memory"] }) {
|
||||
// Bei „warn" wird der ECHTE Hinweis gezeigt (vorher stand hier nur „nur ein Hinweis" —
|
||||
// ohne zu sagen, welcher; User-Feedback 08.07.).
|
||||
function StatusLine({ verdict, memory, warns }: {
|
||||
verdict: ReturnType<typeof useLucyHealth>["verdict"]
|
||||
memory: ReturnType<typeof useLucyHealth>["memory"]
|
||||
warns: ReturnType<typeof useLucyHealth>["warns"]
|
||||
}) {
|
||||
const warnText = warns.length
|
||||
? `${warns[0].label}: ${warns[0].detail}${warns.length > 1 ? ` (+${warns.length - 1} weitere)` : ""}`
|
||||
: memory.status === "full" ? memory.text : "Nichts Schlimmes — nur ein Hinweis."
|
||||
const b = {
|
||||
loading: { ring: "border-border/60 bg-card/45", icon: Loader2, iconCls: "text-muted-foreground animate-spin", title: "Box wird geprüft …", sub: "Einen Moment." },
|
||||
gut: { ring: "border-emerald-500/40 bg-emerald-500/5", icon: HeartPulse, iconCls: "text-emerald-400", title: "Box gesund", sub: "Alle wichtigen Dienste laufen." },
|
||||
warn: { ring: "border-amber-500/40 bg-amber-500/5", icon: AlertTriangle, iconCls: "text-amber-400", title: "Kleinigkeit an der Box", sub: "Nichts Schlimmes — nur ein Hinweis." },
|
||||
warn: { ring: "border-amber-500/40 bg-amber-500/5", icon: AlertTriangle, iconCls: "text-amber-400", title: "Kleinigkeit an der Box", sub: warnText },
|
||||
problem: { ring: "border-red-500/50 bg-red-500/5", icon: AlertTriangle, iconCls: "text-red-400", title: "Box braucht Hilfe", sub: "Ein wichtiger Dienst hakt." },
|
||||
}[verdict]
|
||||
const Icon = b.icon
|
||||
|
||||
Reference in New Issue
Block a user