GitHub

Charts

Lightweight SVG chart primitives. Every sample below is exhaustive — each labeled row shows every severity, size, and state.

Sparkline

Tiny inline line or area chart. Every severity, both variants, and each feature flag.

severity
variant
feature
size
tsx
<Sparkline data={[10, 12, 11, 14, 18]} severity="primary" variant="area" showLast />

MiniBarChart

Inline micro bar chart. Every severity plus the last-bar highlight and sizes.

severity
highlightLast
size
tsx
<MiniBarChart data={[4, 8, 12, 6, 9, 15]} severity="primary" highlightLast />

ProgressRing

Circular progress. Every severity, a value progression, the indeterminate state, a custom center slot, and sizes.

severity
value
indeterminate
center slot
size
tsx
<ProgressRing value={72} severity="primary" showValue />

Gauge

Half-circle gauge. Every severity, with and without a label, min/max end labels, and multi-colour segments.

severity
646464646464
without label
824518
with label
82Health45Score18Errors
showLabels
010082Health
segments
010045Score
size
64Small64Medium64Large
tsx
<Gauge value={82} severity="success" showValue label="Health" showLabels />

TrendChart

Dashboard-sized trend. Every severity, plus axis labels, line-only, and straight segments.

severity
showAxis
4818
line only
straight
tsx
<TrendChart data={series} severity="primary" showAxis />

AreaChartMini

Area-only variant of TrendChart for KPI tiles. Every severity.

severity
tsx
<AreaChartMini data={series} severity="primary" />

LineChart

Full line chart on the visx engine — single or multi-series, axes, grid, legend, and hover tooltip. Series colours resolve to brand/severity tokens, so it re-skins per theme.

multi-series
  • Pemasukan
  • Pengeluaran
single
tsx
<LineChart data={data} xKey="month"
  series={[{ key: "pemasukan", label: "Pemasukan", severity: "primary" },
           { key: "pengeluaran", label: "Pengeluaran", severity: "warning" }]}
  showGrid showLegend showTooltip />

AreaChart

Area chart with token-coloured gradient fills. Overlay by default, or stacked.

overlay
  • Pemasukan
  • Pengeluaran
stacked
  • Pemasukan
  • Pengeluaran
tsx
<AreaChart data={data} xKey="month" series={series} stacked showLegend />

BarChart

Bar chart — grouped or stacked, each optionally horizontal. Same data/xKey/series API as Line and Area.

grouped
  • Pemasukan
  • Pengeluaran
stacked
  • Pemasukan
  • Pengeluaran
horizontal
  • Pemasukan
  • Pengeluaran
tsx
<BarChart data={data} xKey="team" series={series} variant="stacked" horizontal />