# Tracker

A row of status segments: uptime, heartbeats, runs.

Import from `@a31labs/rax/tracker`.

## Usage

```tsx
<Tracker
  label="api.example.com: last 40 checks, 2 down, 1 degraded"
  items={checks.map((c) => ({ key: c.id, tone: c.ok ? "ok" : "danger", label: `${c.time}: ${c.status}` }))}
  slots={50}
/>
```

## Rules

Props: `items` (`{ key, tone, label }`, oldest first; `tone` `ok` | `warn` | `danger` | `info` | `idle`), `label` (required: the row's text summary, e.g. "API: last 50 checks, 2 down, 1 degraded"), `slots` (keeps the newest N and pads on the left with faded empty segments, so rows line up), `height` (default 24), `onSelect` (each segment becomes a button named by its label). A row of equal segments with a 2px gap and 2px radius, one per check, run or day: uptime and heartbeat bars, CI runs, SLA days. Each segment shows its `label` as a tooltip. Without `onSelect` the row is `role="img"` with the summary; colour is never the only carrier, so the summary names the counts of the bad states.

Page: https://rax.a31.at/components/tracker
