Annotations can overflow out of the chart
Open
Nobody has claimed this yet.
bug
P3
- Dominant language
- JavaScript
- Stars
- 18.3k
- Forks
- 2k
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 28
Description
Minimal example of this:
<div id="graph" />
<script src="https://cdn.plot.ly/plotly-3.1.2.min.js"></script>
<script>
var layout = {
annotations: [{
"text": "No data is available to display. No data is available to display. No data is available to display. No data is available to display. No data is available to display. ",
"font": {"size": 20}
}]
};
Plotly.newPlot('graph', {
'config': {},
'data': [],
'layout': layout
})
</script>
Ideally this text would wrap so that it fits on the page
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the minimal example using Plotly.newPlot and an annotations array, then trace how annotation text is rendered when the chart has no data. Check the resulting chart dimensions and text layout against the attached screenshot. Done means long annotation text wraps or otherwise remains within the chart/page without overflowing.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- data-visualization
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100