Line replay
ProA line chart that draws itself over time.
pnpm dlx shadcn@latest add @caliper/line-replayDec 2024: Public API released; growth speeds up.
| Period | Value |
|---|---|
| Jan 2023 | 1200 |
| Feb 2023 | 1362 |
| Mar 2023 | 1516 |
| Apr 2023 | 1655 |
| May 2023 | 1774 |
| Jun 2023 | 1869 |
| Jul 2023 | 1940 |
| Aug 2023 | 1989 |
| Sep 2023 | 2021 |
| Oct 2023 | 2041 |
| Nov 2023 | 2058 |
| Dec 2023 | 2080 |
| Jan 2024 | 2114 |
| Feb 2024 | 2166 |
| Mar 2024 | 2240 |
| Apr 2024 | 2339 |
| May 2024 | 2461 |
| Jun 2024 | 2603 |
| Jul 2024 | 2759 |
| Aug 2024 | 2921 |
| Sep 2024 | 3082 |
| Oct 2024 | 3235 |
| Nov 2024 | 3371 |
| Dec 2024 | 3646 |
| Jan 2025 | 3898 |
| Feb 2025 | 4125 |
| Mar 2025 | 4331 |
| Apr 2025 | 4521 |
| May 2025 | 4700 |
| Jun 2025 | 4877 |
| Jul 2025 | 5060 |
| Aug 2025 | 5257 |
| Sep 2025 | 5472 |
| Oct 2025 | 5710 |
| Nov 2025 | 5972 |
| Dec 2025 | 6258 |
When to use #
Use it for
- Telling a story step by step.
Skip it when
- Readers need the full chart at once.
Installation #
pnpm dlx shadcn@latest add @caliper/line-replay
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.
import { LineReplay } from "@/components/ui/line-replay"
The worked example comes with Pro
The 18-line example behind the preview opens here with a Pro or Team licence.
API reference #
LineReplay
component
Accessibility #
It exposes img and status semantics, with aria-label, aria-hidden and aria-valuetext kept in step with state. Changes that matter are announced through a live region.
Motion #
It checks prefers-reduced-motion itself and settles immediately instead of travelling. Every state is still reachable.