Closed tuzzo77 closed 2 years ago
Hello, @tuzzo77
Can you give a snippet with code that create this problem ?
I guess https://github.com/hosuaby/Leaflet.SmoothMarkerBouncing/commit/193d2982f1d1bfa789b7b0914512ced48be2b5c3 should have fixed it, but I'm not sure if it was published.
@FelipeACP Non, this commit was not published. It makes part of the next major release, fully based on CSS3 animations.
Current version 2.0.1
works well with clusters. If this is not a case, I invite you to share the code snippet that cause a problem.
This error happens occasionally: https://i.imgur.com/EteHTqS.png
This is how I've been using: https://gist.github.com/FelipeACP/a1cf58ebb2a6f2b72db6851c94d05daf
If it doesn't help, I'll try and create a minimal reproducible example
EDIT:
After spending quite a while debugging this issue, I found that this may be caused by some race condition where this library was called after the leaflet object context had been set. As a result, this._bouncingMotion
was undefined on the first render. After I had this lib imported into the project root, the error message seems to have stopped.
@FelipeACP I noticed that your code changes icon and z-index. It's not a good thing to do while using this plugin. If you need to change icon of the marker, I advise you to remove the marker first and create a new one with new icon; https://github.com/hosuaby/Leaflet.SmoothMarkerBouncing/issues/26
It is possible to change icon of bouncing marker starting from version 3.0.1
.
Hi, thanks for your implementation of marker.
I've an excpetion refreshing map markers with bouncing effect. Can you help me please?
Thanks
Uncaught TypeError: Cannot read property 'recalculateMotion' of undefined at i.setPos (bundle.js?=1611847560584:1300) at i._animateZoom (Marker.js:313) at i.fire (Events.js:190) at i._animateZoom (Map.js:1689) at i. (Map.js:1667)