Skip to main content

Examples

Default

Without Icon

Stacked breakdown

Props

Demographics

One row of a breakdown: a leading glyph and label, its share at the far end, and a bar underneath. Stack these to show how a total splits across categories — the top-countries breakdown on the insights dashboard, and the same list expanded inside a dialog.
ReactNode
required
Formatted share shown at the end of the row, e.g. "52.6%".
string
required
Row label, e.g. a country name. Pass a translated string for i18n.A string rather than a node because it is also the bar’s accessible name: a node would leave the bar announcing “Progress” and a bare number, with nothing saying which row it belongs to.
number
required
Share of the total, 0–100. Drives the bar and is announced to assistive tech.
ReactNode
Leading 20px glyph — a flag for a country row.

Exported types

Also exported from @fanvue/ui: DemographicsProps.
Setup: Installation · Theming