
The send button
Buttons, Transitions, SVG
The card for booking a visit at a made-up clinic, on white: the doctor on top with her initials in a circle, below the seven days of the week as pills with availability ticks. The chosen day widens on a spring and the time grid opens underneath like an accordion, the times coming in staggered; the chosen time lights up, a copy of it flies into the “Tue 17 Nov · 15:00 · 30 min” summary and the Confirm visit button wakes up. Changing day closes the grid and opens it again with the new one.
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>
<!--
"Clinic booking calendar" 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 clinic appointment calendar with the time slots that open</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 booking card of a made-up clinic: the doctor on top, the seven days of the week as pills with their
availability ticks, the time grid that opens like an accordion under the chosen day, and the chosen time
that lifts off the grid and lands in the summary, waking the Confirm visit button -->
<section class="card" data-card aria-label="Book a visit">
<span class="card__sheen" aria-hidden="true"></span>
<header class="doc">
<span class="doc__face" aria-hidden="true"><span class="doc__ring"></span><span class="doc__ini" data-ini>EM</span></span>
<span class="doc__txt">
<span class="doc__name" data-docname>Dr. Elena Marsh</span>
<span class="doc__role"><span data-docrole>Dermatologist</span> · <span data-clinic>Wrenfield Clinic</span></span>
</span>
<span class="doc__mark" aria-hidden="true">
<svg viewBox="0 0 24 24"><path d="M9.6 4.2h4.8v5.4h5.4v4.8h-5.4v5.4H9.6v-5.4H4.2V9.6h5.4Z"></path></svg>
</span>
</header>
<div class="week" data-week role="radiogroup" aria-label="Day"></div>
<div class="slots" data-slots>
<div class="slots__in" data-slotsin>
<p class="slots__head"><span class="slots__day" data-slotday>Choose a day</span><span class="slots__free" data-slotfree></span></p>
<div class="grid" data-grid role="radiogroup" aria-label="Time"></div>
</div>
</div>
<footer class="foot">
<span class="sum" data-sum>
<span class="sum__label">Your visit</span>
<span class="sum__line" data-sumline><span class="sum__empty" data-sumempty>Pick a day and a time</span><span class="sum__full" data-sumfull><span data-sumday></span><i> · </i><span class="sum__time" data-sumtime></span><i> · </i><span data-sumlen></span></span></span>
</span>
<button class="confirm" type="button" data-confirm disabled>
<span class="confirm__fill" data-confirmfill aria-hidden="true"></span>
<span class="confirm__glint" data-confirmglint aria-hidden="true"></span>
<span class="confirm__word" data-confirmword>Confirm visit</span>
<svg class="confirm__ic" data-confirmic viewBox="0 0 24 24" aria-hidden="true"><path data-arrow d="M5 12h12.4M12.8 6.6 18.2 12l-5.4 5.4"></path><path data-tick d="M5.6 12.6 9.8 16.6 18.4 7.6"></path></svg>
</button>
</footer>
<p class="sr" data-live aria-live="polite"></p>
</section>
<div class="flyer" data-flyer aria-hidden="true"></div>
<svg class="ghost" data-ghost viewBox="0 0 24 24" aria-hidden="true"><path d="M5 3.2 19.2 11l-6.3 1.6-3.3 5.9Z"></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
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 “Clinic booking calendar” from Animorio and fit it into my siteEach day is a flex column with flex-grow 1: GSAP takes the chosen one to WIDEN with elastic.out and brings the others back to 1, so the row redistributes itself with no measuring. The teal fill is a layer over the pill switched on through opacity; the number goes from font-stretch 92% to 122%.
The container has overflow hidden and height 0. To open it a timeline fills the grid with the new day, measures the content height (a function, read when it starts) and reaches it with back.out, then leaves it on auto. Changing day the same timeline first sends the times out in reverse and closes to 0.
The summary takes its new words at once, so the target of the time can be measured. A fixed element as big as the cell starts from its rectangle and goes to the word’s one in the summary: x with power3.inOut and y with back.in, so it draws an arc; at the end its fill fades, the text turns green and the real word lights up in its place.
Confirm visit is disabled until a time is chosen. Waking it means switching on the black layer, brightening the label, a swell in scale keyframes, a running shine and a spring on the arrow. Once confirmed the check draws itself with stroke-dashoffset.
A repeating timeline moves an SVG arrow to the centre of each element, read with getBoundingClientRect when it gets there, and calls the same functions as real clicks. The first real touch or key stops it for good.
| Name | File | Default | What it changes |
|---|---|---|---|
DOCTOR | script.js | Dr. Elena Marsh | The doctor’s name on top; the initials in the circle are made from it. |
SPECIALTY | script.js | Dermatologist | The specialty under the name. |
CLINIC | script.js | Wrenfield Clinic | The name of the clinic. |
VISIT_MIN | script.js | 30 | How many minutes the visit lasts, written in the summary. |
ACCENT | script.js | #0e7a70 | The colour of the chosen day and time. |
WIDEN | script.js | 1.75 | How much the chosen day’s pill widens compared with the others. |
SPRING | script.js | 0.8 | How long the spring of the widening pill lasts, in seconds. |
STAGGER | script.js | 0.04 | How many seconds between one time and the next as the grid opens. |
On the booking page of a medical practice, a dentist, a physiotherapist or a beauty studio, in a clinic’s app, in any service with fixed length appointments: wherever the day comes first and then the time, and you want to see at once what you are confirming.
The card narrows to the screen width minus twenty-eight pixels and its paddings also follow the height; the pills narrow to about thirty pixels and the chosen one stays wider. Below 380 pixels the button and the summary get a little smaller to share one row. A finger taps like the mouse; without hover the press and the states remain.
No springs, flights or hops: the chosen pill takes its width at once, the grid opens and closes with a fade, the time appears in the summary with a fade and the button lights up without swelling. The fake pointer is hidden: the states change on their own.
GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.
Compressed with gzip, the three demo files weigh 9.0 KB; the libraries: GSAP 28 KB.
Tested on 13 November 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.