Radial Chart
A radial chart recipe - Recharts drawn with Appica UI tokens, for progress toward a target as a dial or as rings.
A radial chart bends a bar into an arc, for progress toward a target. Like every chart here it is a recipe: Recharts draws it and the chart layer themes it. Each example below is a complete file to paste and adapt. For a plain quota in a row or a card, Meter does the job without Recharts.
Installation
Recharts is the only extra dependency, with react-is at the same version as react:
pnpm add recharts react-isThe examples import the chart layer from @/components/chart. If your project doesn't have it yet, copy it from the Charts page first.
Examples
Gauge
A half circle in a frame with aspect-2/1, with the value as HTML over it. The value is a fraction, so the angle axis runs from 0 to 1, and background draws the track behind the bar. Its accessible name carries the value, because a gauge has no tooltip.
Rings
1 ring per row of the data, each with its own fill. A category PolarRadiusAxis names the rings for the tooltip, and reversed puts the first row on the outside.
Accessibility
- Pass
aria-labelto the chart with what it shows. On a gauge include the value ("Storage used: 72%"), since nothing else announces it. - The value over a gauge is real text, not part of the SVG.
- Rings need a
Legend, and their tooltip names each ring, so color is never the only cue. - Nothing animates under reduced motion.