
The liquid grid
Hover, Transitions
The smart home app of Wenlo Home, a made-up brand: a grid of four rooms, each with its own line floor plan seen from above, the lights on and the temperature. Tap a room and its tile grows into the room page (Flip), the floor plan grows with it, the other tiles step aside and fade and the lights switch on one after the other as circles of warm light on the plan, each with a small flare that settles. The title, the brightness and the «Evening» and «Focus» scenes arrive; back does the gesture in reverse and the tile shows the lights now on. On a near black page, one amber accent.
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>
<!--
"Rooms grid transition" 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 rooms grid to room transition with the lights that switch on</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/geist-mono@5.3.0/index.css">
<link rel="stylesheet" href="style.css">
</head>
<body>
<main class="stage" data-stage>
<!-- the app of a made-up smart home brand, Wenlo Home. The rooms grid: tap a room and its tile grows into the
room page (Flip), the floor plan grows with it and the lights on the plan switch on one after the other as
circles of warm light. Back does the gesture in reverse and the tile shows the lights now on -->
<section class="app" data-app aria-label="Wenlo Home">
<span class="app__rim" aria-hidden="true"></span>
<div class="home" data-home>
<header class="home__head" data-head>
<span class="brand">
<svg class="brand__mark" viewBox="0 0 22 22" aria-hidden="true">
<path d="M3.5 10.2 11 4l7.5 6.2V18a.8.8 0 0 1-.8.8H4.3a.8.8 0 0 1-.8-.8Z"/>
<path d="M8.4 18.8v-4.6a2.6 2.6 0 0 1 5.2 0v4.6"/>
</svg>
<span class="brand__name">Wenlo Home</span>
</span>
<h1 class="home__title">Good evening</h1>
<p class="home__sum"><span class="roll" data-sum></span> lights on across 4 rooms</p>
</header>
<div class="grid" data-grid></div>
</div>
<section class="room" data-room aria-label="Room" hidden>
<header class="room__bar" data-fade>
<button class="back" type="button" data-back aria-label="Back to rooms">
<svg viewBox="0 0 20 20" aria-hidden="true"><path d="M12.2 4.6 6.8 10l5.4 5.4"/></svg>
</button>
<h2 class="room__title" data-room-title></h2>
<span class="room__temp" data-room-temp></span>
</header>
<p class="room__meta" data-fade><span class="roll" data-room-count></span><span data-room-of></span></p>
<div class="room__plan" data-room-plan-box></div>
<div class="dim" data-fade>
<div class="dim__top">
<span class="dim__label">Brightness</span>
<span class="dim__value" data-dim-value>0%</span>
</div>
<div class="dim__track" data-dim role="slider" tabindex="0" aria-label="Brightness" aria-valuemin="5" aria-valuemax="100">
<span class="dim__fill" data-dim-fill></span>
<span class="dim__thumb" data-dim-thumb></span>
</div>
</div>
<div class="scenes" data-fade>
<span class="scenes__pill" data-scene-pill aria-hidden="true"></span>
<button class="scene" type="button" data-scene="evening">
<svg viewBox="0 0 20 20" aria-hidden="true"><path d="M15.4 12.4A6.2 6.2 0 0 1 7.6 4.6a6.2 6.2 0 1 0 7.8 7.8Z"/></svg>
<span>Evening</span>
</button>
<button class="scene" type="button" data-scene="focus">
<svg viewBox="0 0 20 20" aria-hidden="true"><circle cx="10" cy="10" r="6.2"/><circle cx="10" cy="10" r="2.4"/></svg>
<span>Focus</span>
</button>
</div>
</section>
</section>
<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="https://cdn.jsdelivr.net/npm/gsap@3.15.0/dist/Flip.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 “Rooms grid transition” from Animorio and fit it into my siteEach room is an object with the SVG paths of its plan in a 160 by 120 viewBox: the walls with the gaps of the door and the window, the door arc, the furniture, the dashed rug, and the position and radius of each lamp. The same function draws the small plan of the tile and the big one of the page; each circle of light is a circle with a four stop radialGradient and mix-blend-mode: screen, under the furniture lines.
The tile and the page share the same data-flip-id, and so do the two plans. Flip.getState takes the tile and the small plan, the tile hides with visibility (its place in the grid stays), the page appears over the whole app and Flip.from(state, { targets: [page, plan], nested: true, absolute: true, props: "borderRadius" }) starts it from the tile in 0.85 s on power4.inOut. Each tile has its own grid-area, so when one turns absolute during the Flip the others do not move.
For each other tile the distance from the centre of the chosen one is measured and the tile moves away by 12% of it, to scale 0.92, while it fades; the further it is, the later it starts. On the way back they return on back.out(1.4), 0.04 s apart.
At the end of the Flip the lamps that are on switch on 0.16 s apart: the lamp turns amber and goes from scale 1.6 to 1 on elastic.out, the circle of light goes from scale 0.35 to a little past its size with an opacity 25% higher in 0.3 s, then settles in 0.8 s on power3.out. Opacity and size of the circle follow the brightness; the number of lights rolls up at every one.
The brightness slider is dragged with the pointer (setPointerCapture) or the arrow keys and changes the lit circles and the warm haze of the page at once. A scene tweens the brightness to its value, changes the stop-color of the gradient stops in 0.8 s, switches on in a row the lights it needs and switches off the others; the amber pill slides under it on back.out with an elastic squash. Tapping a lamp or moving the brightness deselects the scene.
Going back, the page fades its controls, takes its state and runs Flip.from towards the tile, which already has the plan with the lights as they are now; name and rows come back at the end and the number rolls. On its own, a GSAP timeline moves a fake pointer: it opens a room, drags the brightness, picks the scene that is not on, goes back and opens the next room; every round the two rooms change.
| Name | File | Default | What it changes |
|---|---|---|---|
OPEN | script.js | 0.85 | Seconds the tile takes to grow into the room page. |
CLOSE | script.js | 0.8 | Seconds the page takes to shrink back into its tile. |
IGNITE_GAP | script.js | 0.16 | Seconds between one light switching on and the next. |
FLARE | script.js | 1.25 | How much brighter the circle of light blooms before it settles (1 = none). |
PUSH | script.js | 0.12 | How far the other tiles step aside, as a share of their distance. |
SPRING | script.js | 1.4 | The spring of the tiles coming back and of the scenes pill (0 = none). |
IDLE | script.js | 1.6 | Seconds before the pointer walks the app by itself. |
LOOP | script.js | true | Left alone, it opens the rooms again and again. |
For the app or dashboard of a smart home, a home automation or a lighting system, and in general whenever a grid of tiles leads to the detail of one of them: hotel rooms, office areas, warehouse zones. The gesture of the tile becoming the page keeps the eye on the thing chosen.
The same animation with adapted sizes: the app is at most 66% of the height wide and everything inside is measured in container units (cqw, cqh), so the grid and the page fit the phone box. A finger taps a room, a scene, a lamp on the plan or drags the brightness.
No Flip and no moving tiles: the room page fades in and out, the lights fade on without growing, the tiles fade away and back. No pointer on its own.
GSAP 3.15.0, GSAP Flip 3.15.0, Mona Sans (font variabile) 5.3.0, Geist Mono (font variabile) 5.3.0.
Compressed with gzip, the three demo files weigh 12 KB; the libraries: GSAP + Flip 37 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.