Quarterly goals
import { RadialChart } from "@senvenli/react/charts";
const GOALS = [
{ name: "Revenue", value: 82 },
{ name: "New customers", value: 64 },
{ name: "Retention", value: 91 },
];
export default function Example() {
return <RadialChart title="Quarterly goals" period="Q1 2026" data={GOALS} />;
}import { RadialChart } from "@senvenli/react/charts";Examples
With a formatter
Two rings whose values say what they count.import { RadialChart } from "@senvenli/react/charts";
const FULFILLMENT = [
{ name: "Shipped on time", value: 94.5 },
{ name: "Delivered on time", value: 88.2 },
];
const percent = new Intl.NumberFormat("en", { style: "percent", minimumFractionDigits: 1 });
export default function Example() {
return <RadialChart title="Fulfillment" period="March 2026" data={FULFILLMENT} valueFormatter={(value) => percent.format(value / 100)} />;
}Guidelines
When to use it
- Two to four progress figures side by side.
Use something else when
- There is only one figure. Gauge chart
Accessibility
Built in
- A "Show as table" button shows the same data as a table, which screen readers get by default.
You provide
- A title that says what the figure is.
API reference
RadialChart
| Prop | Type | Default | Description |
|---|---|---|---|
title | string | – | What the chart shows, over it; leave it out when a card or a heading already says so. |
aria-label | string | – | Names the chart when it has no visible |
period | string | – | |
isLoading | boolean | – | |
emptyState | React.ReactNode | – | Shown instead of the plot when there is no data: an |
height | number | 200 | |
dataRequired | readonly DonutDatum[] | – | Two or three values on one 0–100 scale. |
valueFormatter | ChartValueFormatter | (value) => `${value}%` |
titlestringWhat the chart shows, over it; leave it out when a card or a heading already says so.
aria-labelstringNames the chart when it has no visible
title(a card's heading already says what it shows).periodstringisLoadingbooleanemptyStateReact.ReactNodeShown instead of the plot when there is no data: an
EmptyState size="small"or text; "No data" by default.heightnumberDefault200dataRequiredreadonly DonutDatum[]Two or three values on one 0–100 scale.
valueFormatterChartValueFormatterDefault(value) => `${value}%`