Skip to content

fix(charts): fix edge cases, align tokens, and add chart DX features - #87

Merged
carllosnc merged 14 commits into
masterfrom
fix/charts-improvements
Nov 14, 2026
Merged

carllosnc merged 14 commits into
masterfrom
fix/charts-improvements

Conversation

@carllosnc

Copy link
Copy Markdown
Owner

Summary

  • Bug fixes:
    • Prevent division-by-zero (NaN) on single-point datasets (AreaChart, LineChart) and all-zero datasets (LineChart, BarChart).
    • Fix SVG arc collapse for 100% single-slice PieChart and handle total === 0 safely.
    • Use useId() in AreaChart linearGradient IDs to avoid DOM collisions across multiple charts.
    • Guard tooltip rendering against stale hoveredIndex when data updates dynamically.
  • Design & Token Consistency:
    • Align LineChart to semantic tokens (stroke-border, text-muted-foreground, text-foreground) and add optional height prop + aligned tooltip container.
    • Clean up PieChart tooltip stray border and legend typography, plus interactive legend hover.
  • New Features & Accessibility:
    • Add valueFormatter, labelKey, showYAxis, showLegend, ariaLabel (role="img"), and touch move/end support.
    • Add curve="smooth" and showDots={true | false | 'hover'} to AreaChart and LineChart.
    • Implement stacked mode in BarChart.

Verification

  • bun run check:all passed (all unit tests, ESLint, and TypeScript/Vite build).

@netlify

netlify Bot commented Nov 14, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for dashkit ready!

Name Link
🔨 Latest commit cbd668c
🔍 Latest deploy log https://app.netlify.com/projects/dashkit/deploys/6af8eb1b576519d1f0e24b6a
😎 Deploy Preview https://deploy-preview-87--dashkit.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@carllosnc
carllosnc merged commit d697b62 into master Nov 14, 2026
5 checks passed
@carllosnc
carllosnc deleted the fix/charts-improvements branch November 14, 2026 23:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant