Flutter docs
Default skin

Sparkline · BarMini Widget

Shape of a series, sized to sit inside a Statistic. Lightweight Charts owns the plotted line, area or histogram and its hidden scales. No visible axis or tooltip: a mini chart shows direction, while the exact value belongs beside it. Import these client components from @ceebee/ui/client.

Usage

Revenue
35.2M

+9.4%

Signups
18

+3

The cases that break naive versions

  • A flat series stays flat, with the scale chosen by Lightweight Charts.
  • A single point stays visible through its marker even without a line segment.
  • A zero-height bar is absent, not a fabricated positive value.
  • Non-finite values are filtered out before anything is measured.

Do

Give it a label that names the series — 'Revenue trend', not 'Chart'.

Don't

Ask people to read values off it. It shows direction; the number belongs next to it.

Props

PropTypeDefaultNotes
valuesnumber[]—In order. Non-finite entries are ignored.
width / heightnumber | '100%' / number120 / 32The drawing box in px, or a responsive full-width chart with width='100%'.
tone / hueTone | DecorHuetone='brand'Line and fill colour.
filledbooleanfalseSparkline only: fills under the line.
showLastbooleantrueSparkline only: dot on the final point.
labelstring—Required accessible name.