Open rod203 opened 10 months ago
I'm creating a pointer click animation using mouseDown and mouseUp event and when the animation has duration (any value except 0) the animation doesn't work. When I put the duration on 0 the element scale but with out animation.
Here is the code
const toggleDown = () => { anime.remove(cursorInner); anime({ targets: cursorInner, duration: 1000, scale: 2, easing: "easeInOutSine", }); }; const toggleUp = () => { anime.remove(cursorInner); anime({ targets: cursorInner, duration: 1000, scale: 1, easing: "easeInOutSine", }); }; document.addEventListener("mousedown", toggleDown); document.addEventListener("mouseup", toggleUp);
I'm creating a pointer click animation using mouseDown and mouseUp event and when the animation has duration (any value except 0) the animation doesn't work. When I put the duration on 0 the element scale but with out animation.
Here is the code