Chart

Charts built on Recharts. Series colors come from the --chart-1 to --chart-5 tokens.

components/ui/chart.tsx

Installation

npx betterone-ds add chart

Props

ComponentPropTypeDefault
ChartContainerconfigChartConfigrequired
ChartTooltipContentindicator

Accessibility

  • Do not rely on color alone. Add labels or a legend.
  • Provide the underlying numbers in a table for screen reader users.