@reactloom/charts
v1.3.0
Published
Accessible React charts for ReactLoom: line, area, bar, pie, scatter, heatmap, histogram, box plot, waterfall, funnel, gauge, radar, treemap, sankey, combo, candlestick and sparkline, with keyboard exploration and data tables.
Maintainers
Readme
@reactloom/charts
Accessible React charts for ReactLoom: LineChart, AreaChart, BarChart, PieChart and
Sparkline, drawn with visx primitives (ADR-0010).
pnpm add @reactloom/charts @reactloom/ui @reactloom/themeimport '@reactloom/charts/styles.css';
import { LineChart } from '@reactloom/charts';
<LineChart
title="Revenue and costs, 2026"
data={monthly}
x="month"
series={[
{ key: 'revenue', label: 'Revenue' },
{ key: 'costs', label: 'Costs' },
]}
valueFormat={{ style: 'currency', currency: 'USD' }}
/>;- A figure with words: named by
title, described by yourdescriptionor a summary generated from the data (range, extremes, change), plus a "Show data table" alternative. - Keyboard: one tab stop; arrow keys move between points with a tooltip and a polite live
readout. Not
role="application". - Theme colours: series use
--pl-color-chart-1…6from@reactloom/theme(3:1 against the background in every built-in theme); dash patterns in Windows high-contrast mode. - Locale and direction: numbers and dates use the active
LocaleProviderlocale; charts mirror in right-to-left layouts. - Size: about 21 kB brotli for a cartesian chart (visx/d3 included, shared between charts), 7 kB for PieChart, 1.5 kB for Sparkline.
Limits: SVG, so very dense series (tens of thousands of separate marks) get slow — line and area series stay one path. Charts read the layout direction when they mount.
Documentation and live examples: https://www.reactloom.dev/components/line-chart
MIT licensed.
