Micro Data-Viz
Mechanical Lap Split Stopwatch
A brass stopwatch dial with a red hand sweeping a sixty-mark ring and a plunger button on top that starts and stops it.
canvasmedium complexitymoderate motionclickaccessible
Open on the canvas to copy the code → Free account · 3 copies a day · membership goes unlimited
1
When to use it
Timing, pace or session-length widgets that want a mechanical chronograph look with one big start-stop control.
When not to
Accurate timing. The hand advances a fixed step per frame, and the lap split text is a sample value.
Working with an AI agent
Every component ships agent-ready metadata. An example instruction for this one:
Change the starting time with seconds in the script, retune the brass and ink colours through --sw-dust, --sw-red and --sw-asphalt on :root (the light set lives in [data-theme="light"]), and edit the lap text in #sw09-split-metric. The plunger is .sw09-plunger-button and toggles isRunning; keep its aria-pressed in step.
Safe to edit
- start time (let seconds = 14.4)
- hand speed per frame (seconds += 0.04)
- brass, dust and red tokens (--sw-* on :root and [data-theme=light])
- head and lap split copy (.sw09-card-head, #sw09-split-metric)
Keep intact
- First control stops idle demo; user-started stopwatch keeps timing until stopped.
- demo-v1 preview lifecycle: initialize demoEnabled from window.__foreverPreview and stop attract work on the window forever:interactive event; retain manual feedback, settling, cleanup and explicit sessions
Known limitations
- State remains local to each mounted instance; format/theme remount preserves takeover, not component values.
More Micro Data-Viz components
- Live Line SweepA soft verdigris area line scrolls a live sine-plus-noise time-series across a faint grid, with a white head dot marking the latest value.
- Donut Ring ProgressOlive-to-terracotta gradient donut ring eases its fill to random targets with a leading dot and large centered percentage readout. Tap to jump to a new value.
- Sparkline Moving DotA sage-green sparkline traces itself across a faint ghost path, led by a haloed white dot; on completion it regenerates a new random 28-point series.
- Radial Gauge NeedleSemicircular gauge on dark amber background with green-yellow-red arc segments; a glowing white needle sweeps smoothly via sine wave with a live 0–100…
- Heatmap Ripple12x6 grid of rounded cells colored via a magma ramp, with a sine-wave ripple emanating from a point that orbits and follows the cursor.
- Odometer Count-UpSix-digit mechanical odometer with rolling digit reels easing toward a random REQUESTS/SEC target; tap/click to randomize a new target value.