Closed nstolpe closed 4 days ago
The latest updates on your projects. Learn more about Vercel for Git ↗︎
Name | Status | Preview | Updated (UTC) |
---|---|---|---|
victory | ✅ Ready (Inspect) | Visit Preview | Nov 18, 2024 9:14pm |
Latest commit: 210b9b00a4cf20555b0e1c1b32c24fa665e3fd9b
The changes in this PR will be included in the next version bump.
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
@carbonrobot this fixes the issue in 2905, in a way that I don't think is going to conflict with anything else. There's a lot of jumping around in logic, from the actual component class, to its helper methods, into data, and into domain as well. I don't think this the best way to fix it in terms of code maintainability and understandability, but I think to have a better fix would require a larger refactor, which seems like something coming in the future. There might also be a slightly cleaner check than component.type.displayName
, I'll take a look into that refactor once I get your thoughts and see if you'd definitely like to go this route.
Folder/File | Previous size | New size | Difference |
---|---|---|---|
/packages/victory/dist/victory.min.js | 385.59KB | 385.76KB | +0.17KB (+0.04%) |
TOTAL | +0.17KB |
After seeing @nlkluth's solution here, I gave a try at subclassing VictoryBar
and overriding renderData
, getBaseProps
and getCalculatedValues
from the EventsMixin
in the derived class to see if this could be accomplished without modifying internal packages (aside from exposing an export or 2). Unfortunately, the overrides got out of control, each additional one triggering an error that required another. I think what's here might be the best way to go at this point.
Description
Addresses the issue where bar chart items more than 50% out of their chart area when zoomed disappear completely, as the bar middle point was being used to determine whether they should be culled from view.
Fixes # 2905
Type of Change
How Has This Been Tested?
Checklist: (Feel free to delete this section upon completion)
Original video from issue:
https://github.com/user-attachments/assets/311b9725-00b7-4867-a539-90f9dc8e125e
Video after fix:
https://github.com/user-attachments/assets/965e120c-73ee-43bc-9923-33a666e56e85