Jump to content
GreenSock

Victor Work

ScrollTrigger resizing issue:

Go to solution Solved by ZachSaucier,

Recommended Posts

Hey All,

I've experiecing a weird issue with resizing.
Once I've resized the window the scrub effect completely disappears with the element.
Why does it happens and how could I fix that?

Thanks in Advance.

Regards
 

See the Pen PozRPWx by victorwork (@victorwork) on CodePen

Link to comment
Share on other sites

@ZachSaucier
Thanks for helping me out... I appreciate it.

Seizing the opportunity... a quick question. 
Is there a way to fire a animation on ScrollTirgger before the elements enters on the viewport?
Something like this:
 

ScrollTrigger.batch(this.unwrapTexts, {
    onEnter: (elements) => {
        gsap.fromTo($(elements).find('.wrapped-p'), { yPercent: 140 }, { duration: 4, yPercent: 0, ease: 'expo.out', stagger: .06 })
    },
    start: 'top 110%',
    once: true
})

Thanks in advance.

Link to comment
Share on other sites

1 hour ago, Victor Work said:

Is there a way to fire a animation on ScrollTirgger before the elements enters on the viewport?

Sure. Is the code you provided not working for you? It'd be helpful if you provided a minimal demo if you'd like our help debugging.

  • Like 1
Link to comment
Share on other sites

Hey @ZachSaucier Thanks, that works ... was a miss configuration on my end.

Seize the same topic to dont flood the forum... 
Is there a way do get scrolling direction? For example.. detecting scrollup or scrolldown inside of a Scrub animation?

Link to comment
Share on other sites

Let me check it out and see how I can play and get back with a feedback.

Thanks for now @GreenSock Jack

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.
×