
The inchworm menu
Menus, Hover, Transitions
The booking calendar of a vacation rental, Casa Alvear, in a frosted glass card on a warm night, like a Dribbble shot. Under every day the price of that night, higher on Friday and Saturday; the nights already taken are dim and struck through by a thin line. Pick the arrival and a champagne brushstroke of light follows the pointer from day to day on a spring, the nights roll like an odometer and the total climbs with scrolling digits; once the departure is picked, a light runs along the stroke. The arrows slide the months in on a spring.
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>
<!--
"Glass stay 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 stay booking calendar in the glass card with the brushstroke of light</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>
<!-- two warm lights behind the glass, so the frosted card has something to blur -->
<span class="glow glow--a" data-glow-a aria-hidden="true"></span>
<span class="glow glow--b" data-glow-b aria-hidden="true"></span>
<!-- the date picker of a vacation rental: one month at a time, the price of each night under its day, the nights
already booked struck through. Between arrival and departure a brushstroke of light runs through the days;
nights and total roll like odometers. -->
<section class="cal" data-card aria-label="Choose the dates of your stay">
<span class="cal__shine" aria-hidden="true"></span>
<header class="cal__head">
<div class="cal__brand">
<span class="cal__name">Casa Alvear</span>
<span class="cal__where">Sea-view loft, Menorca</span>
</div>
<span class="cal__rate">
<svg viewBox="0 0 16 16" aria-hidden="true"><path d="M8 1.6l1.9 4.1 4.5.5-3.4 3 1 4.4L8 11.3l-4 2.3 1-4.4-3.4-3 4.5-.5z"/></svg>
4.96
</span>
</header>
<div class="cal__bar">
<button class="cal__nav" type="button" data-prev aria-label="Previous month">
<svg viewBox="0 0 16 16" aria-hidden="true"><path d="M10 3.5L5.5 8l4.5 4.5"/></svg>
</button>
<div class="cal__month" aria-live="polite" data-month></div>
<button class="cal__nav" type="button" data-next aria-label="Next month">
<svg viewBox="0 0 16 16" aria-hidden="true"><path d="M6 3.5L10.5 8 6 12.5"/></svg>
</button>
</div>
<div class="cal__week" aria-hidden="true">
<span>Mo</span><span>Tu</span><span>We</span><span>Th</span><span class="we">Fr</span><span class="we">Sa</span><span>Su</span>
</div>
<div class="cal__view" data-view></div>
<footer class="cal__foot">
<div class="sum" data-sum>
<p class="sum__nights"><span class="odo" data-nights></span><span class="sum__word" data-word>nights</span></p>
<p class="sum__dates">
<span data-dates>Pick your arrival</span>
<button class="sum__clear" type="button" data-clear>Clear</button>
</p>
</div>
<div class="tot">
<span class="tot__label">Total</span>
<span class="tot__value"><span class="tot__cur">€</span><span class="odo" data-total></span></span>
</div>
<button class="book" type="button" data-book disabled>
<span class="book__face">
<span class="book__words" data-book-words>Reserve</span>
<svg class="book__icon" viewBox="0 0 16 16" aria-hidden="true">
<path class="book__check" data-check pathLength="1" d="M3.4 8.4l3 3 6.2-6.6"/>
</svg>
</span>
</button>
</footer>
</section>
<!-- the drawn pointer of the autopilot -->
<svg class="hand" data-hand viewBox="0 0 24 24" aria-hidden="true">
<path d="M5 2.8l13.4 9.6-6.1.9 3.6 7-2.6 1.3-3.6-7-4.7 4.2z"/>
</svg>
<p class="sr" aria-live="polite" data-live></p>
</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.
37 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 “Glass stay calendar” from Animorio and fit it into my siteEvery date is a number of days since 1970 (Date.UTC divided by 86400000): so arrival, departure and the brushstroke live in the same space even across two months. Every month is a grid of 42 cells starting on the Monday before the first of the month; the price of each night and the booked nights come from fixed rules (season, Friday and Saturday, a small seeded wobble), so they are the same on every loop.
Under the day buttons there is a layer with six strips, one per week. The end of the stroke is a fractional number moved by GSAP towards the day under the pointer: on every frame each row takes its part between the arrival and the end, and where the stroke wraps the two cut edges fade with a mask. The bristles are one pixel lines in a repeating gradient, the running light is a pseudo-element moved with a CSS variable.
Each digit is a window one line tall over a column 0-9 and 0 again. GSAP moves the value and each column is computed like a real odometer: the units roll continuously, tens and hundreds move only while the digits below go from 9 to 0, and the leading zeros shrink to zero width.
The new month is built next to the old one in the same window, masked at the sides: it comes in from the arrow’s side with a back.out (the spring), the old one leaves quickly on the other and is removed, the days arrive with an 8 ms stagger and the month’s name rolls vertically. While sliding, the stroke is drawn in both months.
The autopilot is an async function awaiting GSAP tweens: the drawn pointer goes to the arrow, presses, picks the arrival, glides to the departure (on every frame elementFromPoint tells which day is under it, and the stroke follows), rests on Reserve, clears and goes back. It starts from the load event and stops at the first real touch.
| Name | File | Default | What it changes |
|---|---|---|---|
START_YEAR | script.js | 2027 | The year of the first month shown. |
START_MONTH | script.js | 4 | The first month shown (1 = January); the pointer books in the next one. |
NIGHT | script.js | 148 | The price of a weekday night, in euro. |
WEEKEND | script.js | 52 | How much more a Friday or Saturday night costs. |
ARRIVE | script.js | 13 | The day the pointer arrives. |
LEAVE | script.js | 17 | The day the pointer leaves. |
ROLL | script.js | 0.9 | How many seconds the nights and the total take to roll. |
SPRING | script.js | 1 | How springy the moves are: 0.4 calm, 2 very bouncy. |
SPEED | script.js | 1 | The speed of the autopilot: 2 twice as fast, 0.5 half. |
AUTO | script.js | true | The drawn pointer goes round by itself until someone touches the card. |
For the page of a vacation rental, a hotel, a B&B, a farm stay or a campsite, and for any booking by nights or days (rentals, rooms, studios): it shows at once what each night costs, what is already taken and how much the whole stay comes to while the dates are being picked.
On the phone the card takes the full width minus the margins and the days get shorter with the screen’s height (clamp in vh), so the whole month fits in the frame; there is no hover, so the stroke jumps to the day between the first and the second tap.
Nothing slides or bounces: the months swap with a fade, the stroke appears already whole, nights and total change in place without rolling, the drawn pointer is gone and the autopilot only changes the states.
GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.
Compressed with gzip, the three demo files weigh 12 KB; the libraries: GSAP 28 KB.
Tested on 4 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.