[Feature] How to get the axis range when datazoom scales it?
See original GitHub issueWhat problem does this feature solve?
Hopefully the axis range could be known when it’s changed.
I have y-axis scale
set to true
, and enabled datazoom
. When I zoom or pan the chart, clearly the y-axis’s range changes too. Now I need to know the new range.
I tried to listen to datazoom
event but it doesn’t look like any properties in the option could give me the values.
chart.on("datazoom", params => console.log(chart.getOption().yAxis[0]))
From the output I cannot see any information showing the y-axis range. Is there a way I can get it?
What does the proposed API look like?
Add a range property in the yAxis option:
yAxis: {
range: [currentMin: number, currentMax: number]
}
Issue Analytics
- State:
- Created 10 months ago
- Comments:7 (4 by maintainers)
Top Results From Across the Web
DataZoom Slider Does Not Respect Y Axis min if positive value
If y axis has a min and/or max set, the data zoom should adhere and have the same range as the chart's y...
Read more >Range and scale on visual types in QuickSight
By default, the axis range starts at 0 and ends with the highest value for the measure being displayed. For the group-by axis,...
Read more >Apache Echarts: dataZoom's miniature misrepresents data in ...
By default, dataZoom doesn't take into account the chart scale limits ticks or/and the minimum and maximum allowable values (range of a function...
Read more >Axis - Concepts - Handbook - Apache ECharts
Both x-axis and y-axis included axis line, tick, label and title. Some chart will use the grid to assist the data viewing and...
Read more >Charts configure - pyecharts
The display interval of the x-axis scale labels is valid in the category axis. By default, labels are displayed with intervals that do...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@bbcfive This API is not exposed, so you have to use
as any
or// @ts-ignore
to disable the TS check.hi @plainheart, but how can I solve the ts error?