Components (172)
Decision Loop
Reusable Clean-style UI component built on Base UI and Tailwind CSS v4.
Loading Decision Loop…
Usage
import { DecisionLoop } from "ui-kit/components/decision-loop";Props
| Prop | Type | Default | Description |
|---|---|---|---|
events* | LoopEvent[] | — | — |
actions* | LoopAction[] | — | — |
rules | LoopRule[] | [] | The rules after the model – the threshold comes first by itself |
model* | { id: string; name: string; subtitle?: string; details?: LoopDetail[]; } | — | The model: its name, a line under it, and its card's details |
review | { label: string; via?: string; count?: number; } | — | Who looks when a rule fails |
threshold | number | — | — |
defaultThreshold | number | 0.85 | — |
onThresholdChange | (t: number) => void | — | — |
autoPlay | boolean | true | Takes the next event by itself – on by default; reduced motion keeps it still |
onRoute | (event: LoopEvent, to: string) => void | — | Called once a decision has gone somewhere – an action id or "review" |
className | string | — | — |