
Melting words
Text, Scroll, SVG
Scroll inside the preview
A minimal SVG scroll animation: the easing curve of a motion tool, on a square graph. Scrolling down, its two handles slide out of the corners on a spring and bend the straight line into an S, while the cubic-bezier value follows them digit by digit; then a thin playhead crosses the graph with the scroll, a small orange diamond rides the curve and a little square on the rail beside it moves slow, fast, slow, stretching with its speed. At the end the curve takes the accent and the square lands a pixel too far. The handles can be grabbed and pulled: let go, they spring back.
A folder that runs on its own: index.html, style.css, script.js and the libraries from a CDN. The React and Vue tabs hold the same demo as a ready component, which switches its animations off when it leaves the page.
<!doctype html>
<!--
"Easing curve scroll" from Animorio · https://animorio.com
License: free on your own sites and your clients’ sites, paid work included.
Not for resale, redistribution, templates or code collections · https://animorio.com/en/license/
-->
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>The easing curve that bends as you scroll</title>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fontsource-variable/mona-sans@5.3.0/wdth.css">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fontsource-variable/jetbrains-mono@5.3.0/index.css">
<link rel="stylesheet" href="style.css">
</head>
<body>
<!-- an easing curve on a square graph, as in a motion tool. Scrolling down, its two handles slide out of the corners
on a spring and bend the straight line into an S; then a thin playhead walks across the graph with the scroll,
a small diamond rides the curve and a square on the rail beside it moves slow, fast, slow. When the playhead
reaches the end the curve takes the accent, the diamond knocks once and the square lands a pixel too far.
The handles can be grabbed and pulled: let go, they spring back -->
<main class="pagina">
<section class="corsa" data-corsa aria-label="Easing curve">
<div class="palco">
<div class="pezzo" data-pezzo>
<header class="testa">
<span class="testa__etichetta">Easing</span>
<span class="testa__nome"><span data-nome>linear</span></span>
</header>
<svg class="grafico" data-grafico aria-hidden="true">
<rect class="grafico__bordo" data-bordo></rect>
<g data-tacche></g>
<path class="grafico__lineare" data-lineare></path>
<line class="grafico__testina" data-testina></line>
<line class="grafico__guida" data-guida></line>
<line class="grafico__braccio" data-braccio="1"></line>
<line class="grafico__braccio" data-braccio="2"></line>
<path class="grafico__curva" data-curva pathLength="1"></path>
<rect class="grafico__capo" data-capo="0"></rect>
<rect class="grafico__capo" data-capo="3"></rect>
<line class="grafico__binario" data-binario></line>
<rect class="grafico__oggetto" data-oggetto></rect>
<rect class="grafico__rombo" data-rombo></rect>
<g class="grafico__maniglia" data-maniglia="1"><rect class="grafico__presa" data-presa></rect><rect class="grafico__pomo" data-pomo></rect></g>
<g class="grafico__maniglia" data-maniglia="2"><rect class="grafico__presa" data-presa></rect><rect class="grafico__pomo" data-pomo></rect></g>
</svg>
<p class="codice" aria-label="cubic-bezier value"><span class="codice__fn">cubic-bezier(</span><span class="codice__n" data-n>0.00</span><span class="codice__fn">, </span><span class="codice__n" data-n>0.00</span><span class="codice__fn">, </span><span class="codice__n" data-n>1.00</span><span class="codice__fn">, </span><span class="codice__n" data-n>1.00</span><span class="codice__fn">)</span></p>
</div>
<p class="scendi" data-scendi>Scroll</p>
</div>
</section>
</main>
<script src="https://cdn.jsdelivr.net/npm/gsap@3.15.0/dist/gsap.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/gsap@3.15.0/dist/ScrollTrigger.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/lenis@1.3.26/dist/lenis.min.js"></script>
<script src="script.js"></script>
</body>
</html>Change values, colours and text with the controls and watch the animation respond live. Or write in the code yourself. Then download the folder with your changes.
27 values to change
With the Animorio connector, Claude Code, ChatGPT, Cursor or VS Code take it from here, guide included, and fit it into your project. Paste this request:
Take “Easing curve scroll” from Animorio and fit it into my siteScroll, handles, colour and knocks are numbers in an object; ScrollTrigger with scrub only carries the scroll, and one draw per frame, in GSAP’s ticker, writes the SVG attributes: the C path of the curve, the arms, the handles, the diamond and the square.
The scroll says where each handle should be; the handle chases it on a spring (stiffness 230, damping from the bounce), integrated in steps of 1/120 of a second. So it arrives late and a pixel too far, and when it is dragged it follows the finger on the same spring.
To place the diamond, the Bézier t that gives the playhead’s x is found by bisection (22 steps), and the y is read from that t. The handles’ x stays between 0 and 1, so every moment has only one value.
The square’s speed is the smoothed difference between one frame and the next; the faster it runs, the taller and narrower it gets, keeping the same area.
When the playhead reaches the end a short timeline takes the curve’s colour to orange and gives two elastic knocks: to the diamond, which swells and comes back, and to the square, which rises a pixel and a half too far and settles. Scrolling back under 90% turns it black again.
| Name | File | Default | What it changes |
|---|---|---|---|
X1 | script.js | 0.65 | The first handle of the final curve, across (0 to 1). |
Y1 | script.js | 0 | The first handle, up: below 0 or above 1 the curve overshoots. |
X2 | script.js | 0.35 | The second handle, across. |
Y2 | script.js | 1 | The second handle, up. |
NAME | script.js | ease-in-out | The name the curve gets once it is bent. |
BOUNCE | script.js | 0.35 | How much the handles bounce on their spring. |
SQUASH | script.js | 1 | How much the square stretches with its speed (0 = never). |
LAG | script.js | 0.6 | How many seconds everything takes to catch up with the scroll. |
SMOOTH | script.js | 1.1 | Seconds of the smooth scroll; 0 for the browser’s own. |
For the page of a motion or design tool, a motion design course, the docs of a library or the portfolio of an interface designer: it explains what easing is without one more word.
The same animation with adapted sizes: the graph is as big as the screen allows, in width and height, and the handles can be grabbed with a finger on an area wider than they are.
No movement: the curve is already bent and orange, with the diamond and the square at the top, and it appears in a fade.
GSAP 3.15.0, ScrollTrigger 3.15.0, Lenis 1.3.26, Mona Sans (font variabile) 5.3.0, JetBrains Mono (font variabile) 5.3.0.
Compressed with gzip, the three demo files weigh 7.7 KB; the libraries: GSAP + ScrollTrigger 45 KB, Lenis 5.3 KB.
Tested on 31 October 2026
Use it in your own projects and in your clients’ projects. Do not resell it or redistribute it as is. GSAP stays under its own Standard license. Full license.
Support Animorio
Animorio stays free thanks to the people who support it. If you like, buy us a coffee: it helps us make the next animations.
You asked for
We made it for you: it’s in the library, with the preview, the Playground and the code to copy.
An animation you can’t find, or a site to take apart in the journal: tell us which. We pick the next ones from here.
With your account’s email and password.
or with your email
You’re signed in as .
With your account, you can download the zip of every animation and every pack, for free.