essequiel
Content Type
Profiles
Forums
Store
Blog
Product
Showcase
FAQ
Downloads
Posts posted by essequiel
-
-
2 minutes ago, Rodrigo said:
Draggable does not have a snap-on-release functionality, just the live snap one (as you already discovered). In order to use an on release snap, you need to integrate the Inertia Plugin, which is a Club GreenSock benefit:
That's a shame, thanks for the response anyways!
-
For some reason, doing this with liveSnap works perfectly fine, but it's not the effect i'm looking for i, because want it to snap when the user releases their mouse.
Also i want to know how can i set different units for the snap? i want to use vh or svh instead of px. -
I have this code:
https://codesandbox.io/s/gsap-playground-forked-n1mcs5
The limegreen box is acting as the viewport of a page, what i want is for each section (red, green and blue boxes) to snap to the "viewport" of the page. Currently using "livesnap" isn't working as intended, what am i doing wrong?
How to snap to a section in a Draggable
in GSAP
Posted
For everyone that may come up to this post:
I came up with this solution: https://codesandbox.io/s/gsap-playground-forked-lrlnxh?file=/src/index.js
It may not be perfect, but it works.