A simulated clock: runs at 1x, 60x or 600x, pauses, seeks, optionally bounded (a replay stops at its end). Feed it to the time components.
60x: one real second is one minute of simulated time.
$ npx shadcn@latest add @highcommand/replay-clockCopies the source into your project and pulls in what it needs. First time? Add the registry to components.json.
useReplayClock({ start, speed: speed0, paused: paused0, tickMs, min, max }: { start: number; speed?: number | undefined; paused?: boolean | undefined; tickMs?: number | undefined; min?: number | undefined; max?: number | undefined; }…A simulated clock for the time components: it runs at `speed` simulated seconds per real second (1x, 60x, 600x), pauses, and seeks. Feed `nowMs` to the activity bar, the trip timetable and the impact line, and the controls to TimeControl. Optional `min` and `max` bound it (a replay of a recorded window): it stops at `max`. Ticks every `tickMs` of wall time while it runs; nothing runs in render.
Install this free piece now; the Pro pieces drop in on top of it, in the same app. Pro is $79 once.