Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: handle empty labelStyle values #3043

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

haneetsingh
Copy link
Contributor

Description

fix: Handle undefined labelStyle properties in VictoryCandlestick

  • Add null coalescing for labelStyle?. in calculatePlotValues
  • Prevents TypeError when accessing labelStyle properties

Fixes #3039

Type of Change

  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

I added the code that produces the bug to Storybook and tested it in Storybook. Without this change the code produces the bug as described, with this change the bug is no longer present.

Checklist:

  • I have included a changeset if this change will require a version change to one of the packages.
  • I have performed a self-review of my own code
  • I have run all builds, tests, and linting and all checks pass

Copy link

changeset-bot bot commented Jan 21, 2025

🦋 Changeset detected

Latest commit: 1c27648

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 30 packages
Name Type
victory-candlestick Minor
victory Minor
victory-area Minor
victory-axis Minor
victory-bar Minor
victory-box-plot Minor
victory-brush-container Minor
victory-brush-line Minor
victory-canvas Minor
victory-chart Minor
victory-core Minor
victory-create-container Minor
victory-cursor-container Minor
victory-errorbar Minor
victory-group Minor
victory-histogram Minor
victory-legend Minor
victory-line Minor
victory-native Minor
victory-pie Minor
victory-polar-axis Minor
victory-scatter Minor
victory-selection-container Minor
victory-shared-events Minor
victory-stack Minor
victory-tooltip Minor
victory-vendor Minor
victory-voronoi-container Minor
victory-voronoi Minor
victory-zoom-container Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link

vercel bot commented Jan 21, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
victory ✅ Ready (Inspect) Visit Preview Jan 21, 2025 4:38pm

Copy link
Contributor

Folder/File Previous size New size Difference
/packages/victory/dist/victory.min.js 386.05KB 386.05KB +0.01KB (+0.00%)
TOTAL +0.01KB

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.

Candlestick with empty theme bug
2 participants