Description
Visual state is zoom level, orientation, position, etc...
Checking for saving state: simply click on one of this control buttons: or call
Plotly.restyle
. None of these actions should change the visual state.
Bugs briefly:
- Mouse wheel zooming not saving last zoom lvl (always reverted to previous zoom lvl).
- Touch pad zooming/rotating/moving not saved at all.
Сonditions under which the visual state is not preserved:
Zoom without mouse click - by mouse wheel.
Each odd iteration of zoom level with mouse wheel - will not be remembered. Why odd? Because plotly will save previous zoomlvl after next zoom. In other words - mouse wheel zoomlvl will be reverted 1 step back after restyle or other refresh actions.
PL.mp4
This make mouse wheel zooming not usable with updating by time interval (Plotly.restyle
) plots. Side note - if your click any where in the plot after mouse wheel zoom - zoomlvl will be stored.
Any plot manipulation with touch pad.
Here same behavior - touch any where in the plot after manipulating - will store visual state. See video below.
PL2.mp4
Repro: https://codepen.io/k_sze/pen/WXgNoJ (from #2181). You can click buttons or call restyle()
function in console.