Open ValkA opened 5 years ago
Looks like animationDuration becomes negative or results in divide/0 as zoomLevel decreases.
I don't have time for a PR now, but if you wrap zoomLevel like this it should fix:
const zoomLevel = Math.max(4, _map.getZoom());
It works for me to simply add the attribution of animation-duration
to the polyline elements
let temp = document.getElementsByClassName("leaflet-interactive");
for (let i = 0; i < temp.length; i++) {
temp[i].style["animation-duration"] = '1s';
}
Type:
Environment:
I'm going to open a PR:
Description: When zooming out to <= 0 the animation freezes. Zooming back to >0 the animation unfreezes.
Zoom <= 0 is useful especially when using an ImageOverlay map together with CRS.Simple coordinates.