plotly.js icon indicating copy to clipboard operation
plotly.js copied to clipboard

fix wrong autosize for small size Cartesian bar chart

Open michelezanda opened this issue 4 years ago • 3 comments

This PR is meant to fix a chart render that in some scenario failed to span fully over the available area, and "too many auto-margin redraws" showed on console log.

The autosize logic is surely complex, so here I am mainly suggesting to set pad to 0 (rather than 12). And then apply two minor changes to restore some padding at the end of the computations. As a side effect, overall max iterations can be reduced, and the warning "too many auto-margin redraws" is no more reported in console log.

michelezanda avatar Jan 22 '21 16:01 michelezanda

Thanks for this PR! A small update on timing: our team is working hard on releasing v2.0 of Plotly.js, which we anticipate will happen in early April. This PR would be a good candidate to land in the library in v2.1 or later, so with apologies for the delay, we will likely not be able to give much feedback on this PR for the next few weeks :)

nicolaskruchten avatar Mar 10 '21 21:03 nicolaskruchten

This pull request has been sitting for a while, so I would like to close it as part of our effort to tidy up our public repositories. I've assigned it to myself to keep track of it; I'll wait until 2024-06-17 for someone to say it's still relevant and they'll to take it on, and otherwise I will close it then. Thanks - @gvwilson

gvwilson avatar Jun 10 '24 17:06 gvwilson

@michelezanda is there an open ticket related to this PR or a minimum example to reproduce? We're looking to assess the severity of the issue.

ndrezn avatar Aug 21 '24 15:08 ndrezn

@michelezanda Thank you for the contribution! This PR is promising (there are certainly lots of auto-margin bugs that crop up in specific cases) but without a minimum example which reproduces the issue, it's difficult for us to evaluate the changes. I'm going to close the PR for now; please feel free to reopen later with an example demonstrating the issue. If you prefer, you can also open a bug report issue and we or the community will get to it when we can.

emilykl avatar Oct 14 '25 21:10 emilykl