Skip to content
animorio
IT
Back to the library

Coloured sheets transition

Transitions, HoverGSAP, CSS onlyMediumCompressed weight: Demo 9.2 KBGSAP + CustomEase 31 KBFreeDownload the zip

The page change of a made-up print studio, Folio Row, with four full-colour pages: every page is a sheet of its own colour and the sheets of the others peek out of the bottom edge like the tabs of a deck. Pick a page from the menu or a tab and the deck riffles up: the sheets rise one after another, slightly askew, and straighten as they cover the page; the last one, the sheet of the page you picked, lands with one pixel of overshoot and becomes the page, and the new headline rises letter by letter.

The code

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>
<!--
  "Coloured sheets 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 page transition with a deck of coloured sheets riffling up</title>
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fontsource-variable/fraunces@5.3.0/full.css">
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fontsource-variable/instrument-sans@5.3.0/wdth.css">
  <link rel="stylesheet" href="style.css">
</head>
<body>
  <main class="stage" data-stage>
    <!-- the four pages of a made-up print studio, Folio Row. Every page is a sheet of its own colour. At the bottom the
         next sheets peek out as index tabs. Pick a page and the deck riffles up: one sheet after the other slides over
         the page, slightly askew, until the sheet of the page you picked lands, settles and becomes the page -->

    <header class="top">
      <a href="#" class="brand" data-go="studio" aria-label="Folio Row, studio">
        <svg class="brand__mark" viewBox="0 0 24 24" aria-hidden="true">
          <rect x="4.5" y="6.5" width="12" height="13" rx="1.6"></rect>
          <path d="M7.5 6.5V4.8a.8.8 0 0 1 .8-.8h10.4a.8.8 0 0 1 .8.8v12.4a.8.8 0 0 1-.8.8h-2.2"></path>
        </svg>
        <span class="brand__name">Folio Row</span>
      </a>
      <nav class="nav" data-nav aria-label="Main">
        <span class="nav__pill" data-pill aria-hidden="true"></span>
        <a href="#" class="nav__item is-here" data-go="studio" aria-current="page">Studio</a>
        <a href="#" class="nav__item" data-go="papers">Papers</a>
        <a href="#" class="nav__item" data-go="print">Print</a>
        <a href="#" class="nav__item" data-go="visit">Visit</a>
      </nav>
    </header>

    <section class="page" data-page aria-live="polite">
      <p class="page__label" data-label>A small print studio</p>
      <h1 class="page__title" data-title>Studio</h1>
      <p class="page__line" data-line>Letterpress and risograph on paper we choose by hand, one short run at a time.</p>
      <aside class="card" data-card>
        <span class="card__k" data-card-k>Open</span>
        <span class="card__v" data-card-v>Tue to Sat, 10 to 18</span>
      </aside>
    </section>

    <!-- the studio's pile of paper samples, one per page: the one of the page you are on lies on top and changes on every
         page change, pulled out of the pile and laid back on top -->
    <div class="pile" data-pile aria-hidden="true">
      <div class="swatch" data-swatch="visit"><span class="swatch__n">Visit</span><span class="swatch__g">Laid, 120 gsm</span></div>
      <div class="swatch" data-swatch="print"><span class="swatch__n">Print</span><span class="swatch__g">Riso, 90 gsm</span></div>
      <div class="swatch" data-swatch="papers"><span class="swatch__n">Papers</span><span class="swatch__g">Cotton, 300 gsm</span></div>
      <div class="swatch" data-swatch="studio"><span class="swatch__n">Studio</span><span class="swatch__g">Kraft, 180 gsm</span></div>
    </div>

    <!-- the next sheets of the deck, peeking out of the bottom edge as index tabs -->
    <div class="deck" data-deck>
      <button class="tab" data-tab="studio" data-go="studio" type="button"><span>Studio</span></button>
      <button class="tab" data-tab="papers" data-go="papers" type="button"><span>Papers</span></button>
      <button class="tab" data-tab="print" data-go="print" type="button"><span>Print</span></button>
      <button class="tab" data-tab="visit" data-go="visit" type="button"><span>Visit</span></button>
    </div>

    <div class="sheets" data-sheets aria-hidden="true"></div>

    <!-- the drawn pointer that tours the pages until a real one arrives -->
    <svg class="pointer" data-pointer viewBox="0 0 24 24" aria-hidden="true"><path d="M5 3.5 18.5 12 12.4 13.6 9.4 19.6z"></path></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/CustomEase.min.js"></script>
  <script src="script.js"></script>
</body>
</html>

Playground

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.

39 values to change

Or ask your AI assistant for it

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 “Coloured sheets transition” from Animorio and fit it into my site
Platform licenseFree on your sites and your clients’ sites. Want it inside a website builder, a template platform or a client dashboard? There’s a license for agencies and platforms.

What it does

Every page has its own full colour and the sheets of the other pages peek out of the bottom edge as tabs. Pick a page and the old page leaves (the headline letters lift out of their word, the rest drifts up and the page darkens under the deck) while the sheets of the pages in between rise one after another from the bottom, starting a few degrees askew and straightening as they cover the screen, each with its name at the top and the headline as a watermark. At least three go past even between two neighbouring pages. The last is the sheet of the page you picked: it lands with one pixel of overshoot, the page underneath already has its colour, and the new headline rises letter by letter while the label, the line and the card arrive in a cascade. The menu pill stretches to the new item and settles on a spring, and the tabs rearrange: the one of the page you are on disappears.

How it works

The sheets of the deck

deckTo() picks the sheets that go past: the pages between the current one and the chosen one in deck order, at least MIN_SHEETS, always ending with the chosen page. Every sheet is a full-screen div 112 % tall (so the upward overshoot never shows its lower edge), with its colour, the grain, the light on the top edge and its name.

The askew rise

Every sheet starts below the edge (y measured with a function, so it holds if the window changes size), rotated TILT degrees, alternating, around its bottom edge, and rises to 0 straightening in SHEET_TIME on power3.inOut, STAGGER seconds after the previous one.

The last one lands

The last sheet uses a CustomEase with one pixel of overshoot and a soft settle in LAST_TIME. When it has almost landed, the --bg and --ink variables and the content change underneath: the sheet has the same colour as the page and goes without being seen.

Headline out and in

The headline is split by hand into letters inside words with hidden overflow: on the way out the letters lift out (yPercent −112) on power3.in, on the way in they rise from below on expo.out, LETTER_STAGGER seconds apart; the label, the line and the card follow in a cascade, the card on back.out.

Pill, tabs and pointer

The menu pill stretches to cover both items and then settles on the new one with elastic.out. The tabs are moved only by GSAP (yPercent 42 in view, 110 hidden) and lift TAB_LIFT pixels on hover; a menu item lifts its tab too. A drawn pointer tours the pages, once through the menu and once through the tabs, until the real one arrives. The menu sits above the sheets: it stays put while the deck goes under it.

Values to change

NameFileDefaultWhat it changes
SHEET_TIMEscript.js0.62The seconds of every sheet rising over the page.
STAGGERscript.js0.11The seconds between one sheet of the deck and the next.
LAST_TIMEscript.js0.8The seconds of the last sheet, the chosen page, landing.
MIN_SHEETSscript.js3How many sheets at least go past on every change, even between neighbouring pages.
TILTscript.js2.6How many degrees askew the sheets start from the bottom.
SHADEscript.js0.28How much the old page darkens under the deck.
LETTER_STAGGERscript.js0.045The seconds between one letter and the next of the rising headline.
TAB_LIFTscript.js9How many pixels a tab lifts on hover.
AUTO_EVERYscript.js2.6Left alone, the seconds of rest between two changes of the drawn pointer.

Try them in the Playground

When to use it

For the site of a studio, a print shop, a stationery brand or a small label with a few pages, each with its own colour.

On phones

The same on the phone: headline and tabs are sized on the height too (min of vw and vh, clamp), the menu tightens, the sheets always cover the whole screen.

With reduced motion

With reduced motion no rising sheets: the new page colour fades in and the content changes underneath; the drawn pointer does not start.

Pitfalls

  • The tabs have a vertical offset that keeps them half out of the edge: GSAP sets it (yPercent), not the CSS, because GSAP's inline transform would erase the class one.
  • The sheets are 112 % tall: with the upward overshoot a 100 % sheet would show the page under its lower edge for a moment.
  • The sheets' starting position is a function of the stage height: a fixed number goes wrong if the window changes size halfway.

Libraries

GSAP 3.15.0, CustomEase 3.15.0, Fraunces (font variabile) 5.3.0, Instrument Sans (font variabile) 5.3.0.

Compressed with gzip, the three demo files weigh 9.2 KB; the libraries: GSAP + CustomEase 31 KB.

Testing

Tested on 8 November 2026

  • Desktop: Done
  • Phone: Done
  • Reduced motion: Done
  • Safari on iPhone: To do

License

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.

All animations