Charts
Value labeled line
Value labeled line: A monthly line chart that prints every value above its own point, so the numbers can be read without hovering anything.
Using Value labeled line
Value labeled line uses the wide 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.
| Control | Type | Default | Preview limits |
|---|---|---|---|
accent | color | #F5C542 | No additional limit in the metadata. |
showValues | boolean | true | No additional limit in the metadata. |
labelOffset | number | 12 | From 6 to 24; step 1 |
strokeWidth | number | 2 | From 1 to 4; step 0.5 |
showGrid | boolean | true | No additional limit in the metadata. |
Which frameworks are available for Value labeled line?
Value labeled line 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 Value labeled line depend on?
The React metadata lists these npm dependencies beyond React: motion.
What accessibility details are visible in Value labeled line?
The React source for Value labeled line includes: attributes and handlers (aria-hidden, aria-label, aria-live, onKeyDown, tabIndex); explicit roles (img); key comparisons (ArrowLeft, ArrowRight, End, Escape, Home). These are source observations. Verify accessible names, focus order and keyboard behavior in the composed page.
How does Value labeled line handle reduced motion?
Value labeled line reads the motion preference in its React source through useReducedMotion(). Preference-dependent expressions in index.tsx: delay: reduce ? 0 : 0.12 + (i / Math.max(n - 1, 1)) * DRAW_DURATION * 0.85; duration: reduce ? 0 : 0.32; duration: reduce ? 0 : DRAW_DURATION. Check the full implementation, shared styles and selected port with reduced motion enabled; these observations do not establish that every animation stops.