Skip to content
Menu

Charts

Leader line pie

Leader line pie: A solid pie chart whose values sit outside the circle, each tied back to its slice by a two-segment leader line.

Using Leader line pie

Leader line pie uses the card preview frame with a light/dark theme setting.

Customize the preview

These controls are passed to the demo. Defaults and limits describe the preview; consult the implementation for its full prop API.

ControlTypeDefaultPreview limits
accentcolor#FF4D8DNo additional limit in the metadata.
hueRangenumber90From 20 to 180; step 5
labelDistancenumber20From 8 to 40; step 2
showLeadersbooleantrueNo additional limit in the metadata.
gapnumber1From 0 to 6; step 0.5
Which frameworks are available for Leader line pie?

Leader line pie is available for React, Vue, Svelte, Astro, HTML. The live preview uses React; the source observations below apply to index.tsx. Check the selected port before relying on the same interactions.

What does Leader line pie depend on?

The React metadata lists these npm dependencies beyond React: motion.

What accessibility details are visible in Leader line pie?

The React source for Leader line pie includes: attributes and handlers (aria-hidden, aria-label, aria-live, aria-pressed, onKeyDown, tabIndex); explicit roles (button); key comparisons (ArrowDown, ArrowLeft, ArrowRight, ArrowUp, Enter, Escape, Space). These are source observations. Verify accessible names, focus order and keyboard behavior in the composed page.

How does Leader line pie handle reduced motion?

Leader line pie reads the motion preference in its React source through useReducedMotion(). Preference-dependent expressions in index.tsx: reduce ? 360 : 0; reduce ? 360 : sweepDeg; reduce || revealed[i] ? { opacity: 1, x: 0 } : { opacity: 0, x: s.side === "right" ? -4 : 4 }. Check the full implementation, shared styles and selected port with reduced motion enabled; these observations do not establish that every animation stops.

Connect your agent

Related open components