Jump to content
Search Community

Mouseover event

Pandy test
Moderator Tag

Go to solution Solved by GreenSock,

Recommended Posts

  • Solution

Welcome to the forums, @Pandy

 

The problem is that you animate to an opacity of 1 and y of -10...and that's it. You never return to the other values when the user rolls their mouse out. So the next time they mouseover, the elements are ALREADY at the destination values (opacity: 1, y: -10) so you don't see any motion. Also, it's pointless to have a stagger in your animation because you're creating it inside a .forEach() loop so there's only ONE element in each of those animations (hence nothing to stagger). 

 

I assume you wanted to do something more like this?: 

See the Pen QWvXjJx?editors=0010 by GreenSock (@GreenSock) on CodePen

 

Does that help? 

  • Like 3
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...