Metric Card with Sparkline

Pro

Hover the chart and a glowing dot snaps to your data.

Loading preview...

Props

PropTypeDefaultDescription
labelstring-Metric label shown above the value.
valuesnumber[]-Raw series values. Length should be at least 2.
formatValue(n: number) => string-Pretty-print the primary value. If omitted, the last data point is shown.
prefixstring-Optional value prefix such as $.
suffixstring-Optional value suffix such as users.
widthnumber320SVG width in pixels.
heightnumber84SVG height in pixels.
deltaPercentnumber-Optional explicit delta percentage. When omitted, derived from first vs last.
strokestring-Stroke color CSS variable or hex. Defaults to chili-500.
datesstring[]-Optional dates corresponding to the values.
statusLabelstring-Optional default footer label when not hovering.