// Status rail: brand, live signal rate, running totals, the lethal counter, // and how many signals are muted in the kernel. A live / paused badge is pinned // to the right edge. One row, tinted via its own bg. import { Box, Text } from "yeet:tui"; import { count } from "@/lib/format.js"; import { eintrOnly, mutedCount, paused } from "@/probes/sigwire.js"; const RAIL = "#101613"; const GREEN = "#3ddc84"; const BRIGHT = "#e6f0ea"; const DIM = "#6a7a72"; const AMBER = "#ffb020"; const RED = "#ff2d55"; const sep = () => {" │ "}; export default function TitleBar({ feed }) { return ( {() => { const s = feed.get(); const muted = mutedCount.get(); return [ {" ⌁ SIGWIRE "}, sep(), {Math.round(s.rate)}, {" sig/s"}, sep(), {"Σ "}, {count(s.total)}, sep(), {`☠ ${count(s.fatal)}`}, {" fatal"}, sep(), {`↯ ${count(s.eintr || 0)}`}, {" eintr"}, sep(), {`${muted}`}, {" muted"}, ]; }} {() => [ eintrOnly.get() ? {"↯ EINTR only "} : null, paused.get() ? {"⏸ PAUSED "} : {"● live "}, ]} ); }