Hello!
I'm beginner in Javascript/GSAP world. Pardon me because of some elementary questions. :)
I'm trying to animate a button to expand on hover. I did that. But, I would love to completely remove the animation in the certain screen sizes/media queries.
Here is my code:
toggleHeroBtn.to(herobutton, .7, {paddingRight:"15.3rem", paddingLeft:"15.3rem", ease: Power1. easeOut});
herobuttonImg.addEventListener('mouseenter', _ => {
toggleHeroBtn.play();
});
herobuttonImg.addEventListener('mouseleave', _ => {
toggleHeroBtn.reverse();
});
Thank you in advance!!