-
Couldn't load subscription status.
- Fork 19.8k
Description
Version
5.4.1
Link to Minimal Reproduction
https://echarts.apache.org/examples/en/editor.html?c=map-usa
Steps to Reproduce
Open https://echarts.apache.org/examples/en/editor.html?c=map-usa on a smartphone. Use your fingers to pinch into the map.
Current Behavior
The zooming does not feel natural, because the scale factor is too high. E.g., when the fingers move by 1 cm, the map below the fingers moves by 3 cm.
Expected Behavior
When moving the fingers, the location of the map below each finger should stay fixed while the fingers move.
Environment
- OS: Android 12
- Browser: Chromium, BraveAny additional comments?
- the pinch recognizer of zrender calculates a pinchScale - this looks good
- the RoamController._pinchHandler of echarts ignores this value, only using its sign, and hard-codes the scale to 1.1
- if I comment out this hard-coded value of 1.1 and use the provided pinchScale, the issue is resolved and pinching feels natural again.
I couldn't find the initial commit that started providing this hard-coded value, but maybe @100pah, who did a lot of work on the RoamController, can comment on why the calculated pinchScale is ignored and hard-coded to 1.1...