Let's Talk
Let's Talk
This interaction adds a dynamic mouse trail animation to your Webflow site. When the user moves the cursor inside a section, an image smoothly appears at the cursor position, scales up, and fades away as it moves downward — creating a cinematic visual flow powered by GSAP.
🧩 Structure Overview:
To make this interaction work, your layout must include the following classes:
| Element | Class Name | Description |
| -------------- | ------------------ | ------------------------------------------------------------- |
| Main wrapper | `.gsap-component` | The container that holds the entire GSAP interaction |
| Visual wrapper | `.gsap-wrapper` | The container where the animated images will appear |
| Image element | `.gsap-image-wrap` | The element that contains the image being cloned and animated |
⚠️ Make sure the class names match exactly (all lowercase, separated by hyphens).
⚙️ How the Animation Works:
.gsap-component on the page..gsap-image-wrap element is cloned and positioned at the cursor location.This creates a floating image trail that follows the user’s cursor with an elegant, minimal animation.
🧠 Customization Guide:
1. Adjust the Trigger Distance
To control how often the animation activates, locate this line:
if (Math.abs(xPosition - e.pageX) > 100 || Math.abs(yPosition - e.pageY) > 100)
Change the 100 value to:
60) → animation triggers more frequently150) → animation triggers less frequently
2. Modify the Entry Animation
This part controls how the image appears:
tl.fromTo(imageWrap,
{ opacity: 0, scale: 0.5 },
{ opacity: 1, scale: 1, ease: "power3.out" }
);
You can adjust:opacity: how visible the image startsscale: the zoom amount when it appearsease: the smoothness of the motion (try "expo.out" or "back.out(1.7)")
3. Edit the Exit Animation
This line defines how the image disappears:
tl.to(imageWrap.find("img"), { opacity: 0, y: "8rem", duration: 0.5 });
opacity: controls fade-out strengthy: defines the vertical movement — use negative values (e.g., "-8rem") to make it move upwardduration: how long the animation lasts (increase for slower motion)
4. Change the Animation Direction
If you prefer a horizontal or diagonal motion, you can add or replace movement properties:
tl.to(imageWrap.find("img"), { opacity: 0, x: "6rem", y: "6rem", duration: 0.6 });
This will make the image move diagonally as it fades out.
5. Use Different Images
If you want to use different visuals, simply replace the image inside .gsap-image-wrap in your Webflow Designer.
You can duplicate this element or change the image source manually — no CMS setup is required.
💡 Pro Tips
.gsap-component section to use the effect in multiple parts of your site.<script> tag above the interaction script.