
Melting words
Text, Scroll, SVG
A contract to sign online, in the clean style of today’s apps: a blue flag leads from field to field, the pen writes the initials and the cursive signature stroke by stroke, with its pauses and the ink pooling at the end of each stroke, the date types itself, the count goes up and Finish closes the agreement with a check.
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>
<!--
"Contract signature" 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 signature that writes itself on the contract</title>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fontsource-variable/mona-sans@5.3.0/wdth.css">
<link rel="stylesheet" href="style.css">
</head>
<body>
<main class="stage" data-stage>
<!-- a contract to sign online: a Sign flag leads from field to field (initials, signature, date), each field fills
itself in, the counter rolls, and Finish closes the agreement -->
<div class="fit" data-fit>
<header class="top">
<span class="brand"><span class="brand__mark" aria-hidden="true">F</span><span data-brand>Fenmoor Studio</span></span>
<span class="count" aria-live="polite"><span class="count__win"><span class="count__num" data-count>0</span></span> of 3 signed</span>
</header>
<article class="paper" data-paper aria-label="Design services agreement">
<h1 class="paper__title">Design Services Agreement</h1>
<p class="paper__meta">Between Fenmoor Studio and <span data-client>Ada Harrowby</span></p>
<div class="lines" aria-hidden="true">
<span style="width:96%"></span><span style="width:88%"></span><span style="width:92%"></span><span style="width:54%"></span>
</div>
<div class="clause">
<div class="lines lines--short" aria-hidden="true">
<span style="width:94%"></span><span style="width:80%"></span><span style="width:62%"></span>
</div>
<button class="field field--initials" type="button" data-field="initials" aria-label="Initial here">
<span class="field__label">Initials</span>
<svg class="ink ink--initials" viewBox="0 0 48 36" aria-hidden="true" data-ink="initials">
<path d="M5 31 C9 20, 13 9, 16 5 C18 14, 20 23, 22 31"/>
<path d="M9 21 C15 18, 22 18, 27 19"/>
<path d="M29 5 C28 14, 27 23, 26 31"/>
<path d="M27 19 C32 17, 37 16, 41 15 C40 21, 39 26, 38 31"/>
</svg>
</button>
</div>
<div class="lines" aria-hidden="true">
<span style="width:90%"></span><span style="width:70%"></span>
</div>
<div class="signrow">
<button class="field field--sign" type="button" data-field="sign" aria-label="Sign here">
<svg class="ink ink--sign" viewBox="0 0 300 80" aria-hidden="true" data-ink="sign">
<path d="M16 63 C25 41, 34 19, 42 11 C46 30, 50 48, 56 63"/>
<path d="M30 44 C44 40, 58 42, 66 46 C60 40, 54 50, 62 54 C70 56, 72 44, 76 30 C74 46, 74 56, 82 54 C86 52, 88 46, 92 44 C86 44, 84 54, 92 55 C98 56, 100 48, 104 46"/>
<path d="M122 16 C120 34, 118 50, 116 64"/>
<path d="M136 14 C134 34, 132 50, 130 64"/>
<path d="M110 42 C124 39, 140 40, 150 42 C156 44, 152 54, 158 54 C164 54, 166 44, 168 42 C168 50, 170 56, 174 50 C178 44, 182 42, 186 44 C184 50, 186 56, 192 50 C196 44, 200 42, 204 44 C198 46, 198 56, 206 55 C214 54, 214 44, 208 44 C216 44, 220 50, 222 54 C226 46, 228 42, 232 44 C234 50, 236 54, 240 50 C244 30, 248 16, 252 12 C250 30, 248 46, 250 56 C254 60, 262 52, 258 46 C262 50, 266 56, 272 52 C274 46, 276 42, 278 44 C276 54, 272 66, 266 74 C262 78, 258 74, 264 66 C272 58, 282 52, 292 50"/>
<path d="M58 71 C120 65, 200 63, 288 67"/>
<path class="dot" d="M286 30 L286.4 30.3"/>
</svg>
<span class="field__rule" aria-hidden="true"><span class="field__glow" data-glow="sign"></span></span>
<span class="field__label">Signature</span>
</button>
<button class="field field--date" type="button" data-field="date" aria-label="Add the date">
<span class="date" data-date></span><span class="caret" data-caret aria-hidden="true"></span>
<span class="field__rule" aria-hidden="true"><span class="field__glow" data-glow="date"></span></span>
<span class="field__label">Date</span>
</button>
</div>
<svg class="pen" viewBox="0 0 40 40" aria-hidden="true" data-pen>
<path class="pen__body" d="M6 34 L9 25 L29 5 C31 3 34 3 36 5 C38 7 38 10 36 12 L16 32 Z"/>
<path class="pen__nib" d="M6 34 L9 25 L16 32 Z"/>
<path class="pen__shine" d="M13 23 L30 6"/>
</svg>
</article>
<div class="flag" data-flag aria-hidden="true">
<span class="flag__word" data-flag-word>Sign</span>
<svg viewBox="0 0 16 16"><path d="M5 3l5 5-5 5"/></svg>
</div>
<footer class="foot">
<button class="finish" type="button" data-finish disabled>
<span class="finish__fill" data-finish-fill></span>
<span class="finish__a" data-finish-a>Finish</span>
<span class="finish__b" data-finish-b>
<svg viewBox="0 0 16 16" aria-hidden="true"><path data-check d="M3.5 8.4l3 3 6-6.6"/></svg>
<span>Signed · 18:04</span>
</span>
</button>
<button class="replay" type="button" data-replay>
<svg viewBox="0 0 16 16" aria-hidden="true"><path d="M3.2 8a4.8 4.8 0 1 0 1.5-3.5M3 2.8v2.6h2.6"/></svg>
Replay
</button>
</footer>
</div>
<svg class="cursor" data-cursor viewBox="0 0 24 24" aria-hidden="true"><path d="M5 2.8v16.4l4.2-4 2.8 6.2 2.9-1.3-2.8-6.1h5.9Z"/></svg>
</main>
<script src="https://cdn.jsdelivr.net/npm/gsap@3.15.0/dist/gsap.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.
28 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 “Contract signature” from Animorio and fit it into my siteEvery stroke of the signature and the initials is an SVG path whose stroke-dasharray is as long as the path and whose stroke-dashoffset equals its length, read with getTotalLength: so it starts invisible. A tween on a number from 0 to the length lowers the offset and reveals the stroke.
On every update getPointAtLength gives the point reached, getScreenCTM turns it into screen pixels and the container’s scale brings it back into the sheet’s pixels: the tip of the drawn pen goes there. Between strokes the pen lifts four pixels, flies to the start of the next one and comes down again.
Each stroke lasts its length divided by SPEED, with power1.inOut: long strokes run, short ones are brief, and each slows down at the start and at the end. Between strokes there is a pause of PAUSE seconds, and at the end of each stroke a small dark circle grows with back.out: the ink pooling where the pen slows down.
The flag is a single element: GSAP carries it to the height of the next field, read with getBoundingClientRect and divided by the scale, with back.out; meanwhile it tucks in eight pixels, changes word and comes back out with an elastic. The active field lights up: the initials box with a blue border, the signature line with a line growing with scaleX.
Once the three fields are filled Finish wakes up. Pressed, it sinks and comes back with an elastic, a blue fill grows from the left with scaleX, Finish rises away, «Signed · 18:04» comes in from below with back.out and the check draws itself with the same trick as the strokes.
| Name | File | Default | What it changes |
|---|---|---|---|
CLIENT | script.js | 'Ada Harrowby' | The made-up client’s name, written under the contract’s title. |
ACCENT | script.js | '#2f55e4' | The colour of the flag, the active field and the signed button. |
SPEED | script.js | 230 | How fast the pen runs, in drawing points per second. |
PAUSE | script.js | 0.16 | The seconds the pen rests between one stroke and the next. |
TYPE | script.js | 0.07 | The seconds per letter as the date types itself. |
HOLD | script.js | 2.6 | The seconds the contract stays signed before it starts again. |
For an e-signature app, for a quote page to accept or for the last step of a subscription: the flag says where to sign, and the signature writing itself makes a digital gesture feel human.
The same animation: the contract is drawn in its own pixels and the wrapper scales it to the box’s width and height, so the sheet, the flag and the button stay whole; the fields are tapped with a finger.
No pen, no flight of the flag and no rolling: the contract appears already signed with a fade, with the initials, the signature, the date and the «Signed · 18:04» button.
GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.
Compressed with gzip, the three demo files weigh 8.1 KB; the libraries: GSAP 28 KB.
Tested on 27 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.