0%

pay attention when using gsap scrollTrigger

I run into a problem during I use gsap scrollTrigger library. When I scroll the screen, the target element is work and horizontal scroll to right. But the thing is the following element is also scroll up during the target element is scrolling to right. I fall in to meditation. The following element is suppose to scroll up after the crosswise scroll is finish.

Over some hours, I find the reason. The father box of the target element is flex and set a align-items or justify-content. And the target element’s display cannot be flex. In sum up, both target’s father and target cannot be a flex box. After I erase these codes, the process is work.

請打賞支待一下.