bobl Posted September 8, 2022 Share Posted September 8, 2022 Is there a way to do something like an @media in gsap? I have an svg that is animated from left to right using fromTo. For smaller screen sizes I would like to have the svg start (from) position rotated and at the top and then use fromTo to have it appear from the top and move downward. Link to comment Share on other sites More sharing options...
GreenSock Posted September 9, 2022 Share Posted September 9, 2022 Absolutely! Good timing - the new 3.11 release includes the exciting gsap.matchMedia() method: https://greensock.com/docs/v3/GSAP/gsap.matchMedia() There's a video in the docs that should really help you get up to speed too. Enjoy! 1 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