Version
5.3.0
Link to Minimal Reproduction
https://codepen.io/tyn1998/pen/GRxpgQq
Steps to Reproduce
- visit my codepen url above
- click "Animals" bar (universalTransition animation works)
- click "Back" (not works)
- comment line 12
dataGroupId: "", and repeat 2 and 3 they both will work
Current Behavior
Hi, Echarts core team!
I have read the related source code so I know where the problem occurs.
|
const dataGroupId = data.hostModel && (data.hostModel as SeriesModel).get('dataGroupId') as string; |
When processing old data items, after executing this line, dataGroupId is wrongly assigned to a value that is belong to new data items, which is due to the factor of having notMerge default set to false when .setOption(newOption).
This bug will not be exposed when data item's groupId is specified.
Expected Behavior
Old data items should be given correct dataGroupId when item.groupId is not specified.
Environment
- OS: macOS Monterey
- Browser: Chrome 103
- Framework: None
Any additional comments?
N.A.
Version
5.3.0
Link to Minimal Reproduction
https://codepen.io/tyn1998/pen/GRxpgQq
Steps to Reproduce
dataGroupId: "",and repeat 2 and 3 they both will workCurrent Behavior
Hi, Echarts core team!
I have read the related source code so I know where the problem occurs.
echarts/src/animation/universalTransition.ts
Line 210 in 89d57f2
When processing old data items, after executing this line, dataGroupId is wrongly assigned to a value that is belong to new data items, which is due to the factor of having
notMergedefault set to false when.setOption(newOption).This bug will not be exposed when data item's
groupIdis specified.Expected Behavior
Old data items should be given correct dataGroupId when item.groupId is not specified.
Environment
Any additional comments?
N.A.