[Bug] Zoom Reset Count Incorrect After Multiple Grids Zoom
- Dominant language
- TypeScript
- Stars
- 67.3k
- Forks
- 19.8k
- Avg merge
- 11d 14h
- Merged PRs (30d)
- 8
Description
### Version
6.1.0
### Link to Minimal Reproduction
https://echarts.apache.org/examples/en/editor.html?c=grid-multiple
### Steps to Reproduce
1. Zoom in once on the upper trend chart.
2. Zoom in once on the lower trend chart.
3. You have now performed 2 zoom operations in total.
4. Click Zoom Reset. It can be triggered 3 times, which is incorrect.
### Current Behavior
Zoom Reset can be triggered 3 times, which indicates an error in how zoom history is tracked across multiple grids.
### Expected Behavior
Zoom Reset should only be available as many times as actual zoom operations were performed.
In this case, after 2 zooms, Zoom Reset should only be possible 2 times.
### Environment
```markdown
- OS:N/A
- Browser: N/A
- Framework: N/A
This issue can be reduced with Echarts Demo Examples. The issue is independent of my development environment or the browser used in testing.
```
### Any additional comments?
_No response_
Contributor guide
Research direction
Start with the linked grid-multiple ECharts reproduction and trace how zoom operations and Zoom Reset history are recorded across the upper and lower trend charts. Verify the two-zoom sequence and identify why reset is available three times; done means two zooms allow exactly two resets, with regression coverage for multiple grids.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- data-visualization
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 57/100