[Feature] Show/hide Series
- Dominant language
- TypeScript
- Stars
- 67.3k
- Forks
- 19.8k
- Avg merge
- 11d 14h
- Merged PRs (30d)
- 8
Description
### What problem does this feature solve?
There are mutiple charts on the page, however, some of them have no data. We need to hide or disable those charts with no data.
### What does the proposed API look like?
Would be extremely useful to have in options.series to hide or show specific series `WITH series.visible = true/false`. For example, we have 5 series, but we don't want to show one of them.
```
option = {
xAxis: {
type: 'category',
data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun']
},
yAxis: {
type: 'value'
},
series: [{
data: [150, 230, 224, 218, 135, 147, 260],
visible: false,
type: 'line'
}]
};
```
Also, would be useful to have option to hide series if there is no data in the series.
`series.displayWhenNoData= true/false`
Waiting and ready to help!
Contributor guide
Assessment
This issue has not been assessed yet.