[Feature] Be able to reverse legend order (stacked bar charts)
- Dominant language
- TypeScript
- Stars
- 67.3k
- Forks
- 19.8k
- Avg merge
- 15h 17m
- Merged PRs (30d)
- 5
Description
### What problem does this feature solve?
I am replacing dashboard paid for by companies in maintenance and oil/gas industries, who would have charts like below. See how the legend shows lowest to highest values (or increasing severity). The stacked bar shows the highest values at the bottom, as they tend to be more important and fluctuate less.
This is what I am aiming to achieve.
But I can't find a way to do this in echarts. See below for what I've managed to get done. You can see how bad it looks, having the legend ordered that way is counter intuitive.
### What does the proposed API look like?
I think a simple
`order: null | 'reversed'` property on the `legend` property would be enough.
Contributor guide
Research direction
Start by reviewing the legend configuration and stacked bar chart behavior described in the issue, using the provided examples to understand the desired ordering. Define the reversed-order behavior for the proposed legend property and verify that both the legend and stacked bars produce the intended result.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- data-visualization
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100