Closed dubzzz closed 3 years ago
Just in case it can help, I think that the issue is not limited to bar chart and also happens with others π€
@dubzzz thank you very much for the examples and detailed report, it comes from an issue with react-spring
which is now used for the axes/grids, it has an issue, and the fix hasn't been released yet, but there are ways to fix it, please have a look at this issue: https://github.com/plouc/nivo/issues/1290
Whaou thanks a lot for the linked issue, I'll have a look to it
First of all, thanks a lot for this amazing project π
Describe/explain the bug
It seems that the legend on charts rendered using the component
<ResponsiveBar />
is not resized properly when updating the size of the parent.The issue only happens with production build (I was not able to reproduce it with dev mode). It seems that it was introduced between 0.62.x and 0.66.x.
To Reproduce
The detailed scenario with dev and production bundles is available at: https://github.com/dubzzz/nivo-legend-resize-bug/blob/main/README.md
Steps to reproduce the behavior:
Expected behavior
Production and dev should behave the same way. Resize of the window should resize the legend and the chart together.
Screenshots
Here is what I have with the production bundle: