Skip to content
caliper ui docs

Pro

Race bars

Ranked bars that reorder as values change over time.

Pro
pnpm dlx shadcn@latest add @caliper/race-bars

Open-source packages

Weekly downloads at the end of each quarter, Q4 2024 to Q3 2026.

Weekly downloadsQ4 2024
  1. react-kit92,000
  2. chart-core41,000
  3. form-lab38,000
  4. motion-kit22,000
  5. icon-set60,000
  6. tokens30,000
  7. data-table18,000

Q4 2024: react-kit, icon-set, chart-core lead

Weekly downloads
Timereact-kitchart-coreform-labmotion-kiticon-settokensdata-table
Q4 202492000410003800022000600003000018000
Q1 202598000520004400031000630003600027000
Q2 2025101000660004700045000640004400039000
Q3 2025104000810005200058000660004900055000
Q4 2025107000990005700074000670005800072000
Q1 20261090001180006100092000680006600091000
Q2 2026111000140000660001090006900071000118000
Q3 2026113000166000700001310007000079000149000
Installs components/ui/race-bars.tsxDepends on @radix-ui/react-slot, d3-shape, lucide-reactMotion none in component source

When to use

Use it for

  • Telling a story about rank changes across periods.
  • Playing back a leaderboard.

Skip it when

  • Readers need to inspect one moment closely.
  • The ranking rarely changes.

Installation

terminal
pnpm dlx shadcn@latest add @caliper/race-bars

Adds its 4 files to components/ui/, each with its own stylesheet, and installs their packages. Pro installs with your access token, set up once per project. See Pro access. The first part also adds Caliper UI’s tokens; import them once as in Installation.

Usage

Import it from your copy of the source. The example behind the preview comes with the source.

example.tsx
import { RaceBars } from "@/components/ui/race-bars"

The worked example comes with Pro

The 48-line example behind the preview opens here, ready to copy.

  • 626 Pro parts, blocks and page templates, all with source
  • $149 once, with lifetime updates. No renewal
  • A full refund within 14 days if it is not for you
Checking your licence…

API reference

RaceBars

component
PropTypeDefaultDescription
label *string—
items *readonly RaceItem[]—
frames *readonly RaceFrame[]—
topnumber8How many places to show.
intervalnumber900Milliseconds per frame while playing.
unitstring""
formatValue((value: number) => string)numberText
loadingboolean—
errorstring—
classNamestring—

Accessibility

It exposes status semantics, with aria-label, aria-busy, aria-hidden and aria-valuetext kept in step with state. Changes that matter are announced through a live region.

No custom key handling; Tab and the native activation keys do the work.

Motion

It declares no animation in its component source. Any transition comes from its stylesheet, which uses the duration tokens that collapse to instant under prefers-reduced-motion.

All Advanced charts examples