
The elastic button
Buttons, Hover, Text
The poll for finding a meeting time, in a card on white: four times, each with the avatars of who already said yes, the count “3 of 5” and a band of colour as wide as the share of yeses. One tap on the row says “I can”: the box fills and the check draws itself, your avatar joins the line making room for itself, the band stretches with a bounce and the count rolls. The “Best” tag jumps to the time with most yeses, and at the bottom you read which one is leading.
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>
<!--
"Availability poll" 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>Availability poll</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">
<!-- the date poll of a meeting: four times with who can make it, one tap to say "I can", the row filling up,
your avatar joining the line and the Best tag moving to the time with most yeses -->
<section class="ap" data-ap aria-label="Availability poll">
<header class="ap__head">
<div class="ap__what"><strong>Offsite planning call</strong><span>Tap every time that works for you</span></div>
<span class="ap__mine"><b data-outmine>0</b> picked</span>
</header>
<ul class="ap__list">
<li><button type="button" class="ap__slot" data-slot data-day="Tue 9 Dec" data-time="10:00" data-yes="M,L" aria-pressed="false"><i class="ap__fill" data-fill></i><span class="ap__box"><svg viewBox="0 0 16 16" aria-hidden="true"><path data-tick d="M3.500 8.300 6.700 11.400 12.600 5" pathLength="1"></path></svg></span><span class="ap__when"><strong>Tue 9 Dec</strong><span>10:00 to 10:45</span></span><span class="ap__best" data-best>Best</span><span class="ap__who" data-who></span><span class="ap__n"><span class="ap__clip"><span data-outn>2 of 5</span></span></span></button></li>
<li><button type="button" class="ap__slot" data-slot data-day="Tue 9 Dec" data-time="15:30" data-yes="S" aria-pressed="false"><i class="ap__fill" data-fill></i><span class="ap__box"><svg viewBox="0 0 16 16" aria-hidden="true"><path data-tick d="M3.500 8.300 6.700 11.400 12.600 5" pathLength="1"></path></svg></span><span class="ap__when"><strong>Tue 9 Dec</strong><span>15:30 to 16:15</span></span><span class="ap__best" data-best>Best</span><span class="ap__who" data-who></span><span class="ap__n"><span class="ap__clip"><span data-outn>1 of 5</span></span></span></button></li>
<li><button type="button" class="ap__slot" data-slot data-day="Wed 10 Dec" data-time="14:00" data-yes="M,L,I" aria-pressed="false"><i class="ap__fill" data-fill></i><span class="ap__box"><svg viewBox="0 0 16 16" aria-hidden="true"><path data-tick d="M3.500 8.300 6.700 11.400 12.600 5" pathLength="1"></path></svg></span><span class="ap__when"><strong>Wed 10 Dec</strong><span>14:00 to 14:45</span></span><span class="ap__best" data-best>Best</span><span class="ap__who" data-who></span><span class="ap__n"><span class="ap__clip"><span data-outn>3 of 5</span></span></span></button></li>
<li><button type="button" class="ap__slot" data-slot data-day="Thu 11 Dec" data-time="09:00" data-yes="L,S,I" aria-pressed="false"><i class="ap__fill" data-fill></i><span class="ap__box"><svg viewBox="0 0 16 16" aria-hidden="true"><path data-tick d="M3.500 8.300 6.700 11.400 12.600 5" pathLength="1"></path></svg></span><span class="ap__when"><strong>Thu 11 Dec</strong><span>09:00 to 09:45</span></span><span class="ap__best" data-best>Best</span><span class="ap__who" data-who></span><span class="ap__n"><span class="ap__clip"><span data-outn>3 of 5</span></span></span></button></li>
</ul>
<p class="ap__foot"><span class="ap__clip ap__clip--foot"><span data-outbest>Leading: Wed 10 Dec at 14:00</span></span></p>
</section>
<span class="live" aria-live="polite" data-live></span>
<svg class="ghost" data-ghost viewBox="0 0 24 24" aria-hidden="true"><path d="M5 3.200 19.200 11l-6.300 1.600-3.300 5.900Z"></path></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
Works with Claude, Claude Code, ChatGPT, Cursor, VS Code, Windsurf, Codex, Gemini CLI
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 “Availability poll” from Animorio and fit it into my siteFor each time the list of who can make it and your yes kept apart: the count, the band’s width and the leader are worked out from them at every tap.
The new circle is born at scale zero with a negative margin as wide as itself: growing and putting the margin back, it pushes the line without a jump.
The most voted; between equals the earliest. “Best” only moves when the leader changes, not at every tap.
The whole row is a button with `aria-pressed`: the box is only the sign, the target is 50 pixels tall.
| Name | File | Default | What it changes |
|---|---|---|---|
ACCENT | script.js | #5a54d6 | The colour of your yeses: the check, your avatar, the row’s band and “Best”. |
TOTAL | script.js | 5 | How many people are invited, you included. |
LOOP | script.js | true | Left alone, the demo’s pointer picks a few times and removes one. |
In a calendar or teamwork app, in the invitation to a meeting, a dinner or a match, on an event page with several possible dates; the same poll carries the choice of a restaurant, the evening’s film, a shift to cover or a delivery date.
The card is at most 352 pixels wide and about 325 tall. Each row is 50 pixels tall and all of it can be tapped; under 350 pixels the gaps between the row’s parts narrow and the circles stay overlapped.
No bounces or jumps: the box fills with the check already drawn, the circle appears in its place, band, count and the “Best” tag change in one step. The demo’s pointer does not start.
GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.
Compressed with gzip, the three demo files weigh 5.4 KB; the libraries: GSAP 28 KB.
Tested on 2 December 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.
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.