.mdl Posted October 10, 2021 Share Posted October 10, 2021 Hello to all animation lovers! Please tell me how I can improve the animation in the mobile version (<576px). My expectation was that when the scrolling reaches a certain column of text, the function of showing the animation is triggered, but in fact the animation either fires earlier than I need and the animation is performed for all columns, and not those in the visibility zone. I would also like to play the appearance of the speakers depending on the direction. I found out that the direction is responsible for this when the onUpdate method is called, but I could not think of how this can be implemented. See the Pen QWMWQRv by mdl95r (@mdl95r) on CodePen Link to comment Share on other sites More sharing options...
GreenSock Posted October 12, 2021 Share Posted October 12, 2021 You were trying to use a position parameter with a regular .fromTo() that's not even in a timeline. That won't work. I don't really understand what you meant about the direction changing things, but here's a simplified version that uses toggleActions to reverse the animation when scrolling back up past the element: See the Pen QWMwQxy?editors=0010 by GreenSock (@GreenSock) on CodePen Does that help? Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now