Share Posted December 10, 2020 I've been trying to use this same principle as in this post, but with images inside an svg. but my first slide doesn't start for a smoe time... wel 15-20 seconds. any help would be lovely. See the Pen BaLLxpP by davicoo (@davicoo) on CodePen Link to comment Share on other sites More sharing options...
Share Posted December 10, 2020 That's because all your images are starting out at opacity: 1, so the top one on the stack is covering the ones that are correctly crossfading below. If you open Dev Tools you'll see that GSAP is doing what you're asking it to do - you just don't see it because the top image is obscuring the others. One fix would be to make all but the lowest one opacity: 0 to start: gsap.set(imgs.slice(1), {opacity: 0}); Happy tweening! 2 1 Link to comment Share on other sites More sharing options...
Author Share Posted December 10, 2020 Thank you! That’s got it ! Link to comment Share on other sites More sharing options...
Share Posted December 10, 2020 Additionally you're using a super old version of GSAP. We highly recommend upgrading the latest version of GSAP that has a smaller file size, a sleeker API, and a ton of new features! Upgrading it easy: 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