Skip to content
animorio
IT
Back to the library

Letter into black transition

Transitions, HoverGSAP, CSS onlyMediumCompressed weight: Demo 9.9 KBGSAP 28 KBFreeDownload the zip

The page transition from the Creative Reference Library site, rebuilt in SVG with a made-up brand, Hold, an index of creative references: on the stone grey home the giant letters of the brand sit in black behind the type, and the Enter the library button follows the pointer. On click the H lifts off by one pixel and takes a shadow, comes in front of the type and dives towards the click point, faster and faster, until its full stem covers everything in black; from the black the dark library opens, with the rows of the list rising in their masks. Back makes the trip the other way round.

Rebuilt from scratch studying crl-2026.webflow.io by Josh Bendall, S•BJ: the idea is theirs; code, copy and images are ours. Read how it’s made

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>
<!--
  "Letter into black 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>Hold, a working reference index</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>
  <!-- the home of a made-up reference library, Hold: stone grey, with the giant black letters of the brand behind the
       type and an "Enter the library" button that follows the pointer. On click the H lifts off by one pixel, takes a
       shadow, comes in front of the type and dives towards the click point, faster and faster, until its stem fills the
       screen with black; from the black the dark library opens, its rows rising line by line in their masks. "Back"
       makes the same trip the other way round. -->
  <div class="sito" data-sito>
    <header class="testa">
      <a class="marchio" href="#" aria-label="Hold, home">
        <svg class="marchio__segno" viewBox="0 0 40 24" aria-hidden="true">
          <rect x="0" y="0" width="8" height="10.5"/><rect x="0" y="12" width="8" height="12"/>
          <rect x="10" y="8" width="6" height="7"/>
          <rect x="18" y="0" width="8" height="15.5"/><rect x="18" y="17" width="8" height="7"/>
          <rect x="29" y="0" width="11" height="24" rx="5.5"/>
        </svg>
        <span class="marchio__nome">Working<br>Reference Index</span>
      </a>
      <nav class="voci" aria-label="Main">
        <a href="#" class="voce" data-voce="home">Index</a>
        <a href="#" class="voce" data-voce="libreria">Library<sup>24</sup></a>
        <a href="#" class="voce voce--extra">About</a>
      </nav>
    </header>

    <!-- the home: stone grey, giant letters behind -->
    <main class="casa" data-casa>
      <svg class="giganti giganti--ferme" data-ferme viewBox="0 0 1300 800" preserveAspectRatio="xMinYMid slice" aria-hidden="true">
        <rect x="800" y="-200" width="210" height="1200"/>
        <path d="M1018 -200H1050C1300 -200 1420 140 1420 400C1420 660 1300 1000 1050 1000H1018V640H1040C1140 640 1190 530 1190 400C1190 270 1140 160 1040 160H1018Z"/>
      </svg>

      <div class="volo" data-volo aria-hidden="true">
        <div class="stacco" data-stacco>
          <svg class="giganti giganti--ombra" data-ombra viewBox="0 0 1300 800" preserveAspectRatio="xMinYMid slice">
            <use href="#lettera-h"/>
          </svg>
          <svg class="giganti giganti--h" data-h viewBox="0 0 1300 800" preserveAspectRatio="xMinYMid slice">
            <defs>
              <g id="lettera-h">
                <rect x="20" y="-200" width="270" height="310"/>
                <rect x="20" y="118" width="270" height="882"/>
                <rect x="298" y="300" width="144" height="220"/>
                <rect x="450" y="-200" width="270" height="830"/>
                <rect x="450" y="638" width="270" height="362"/>
              </g>
            </defs>
            <use href="#lettera-h"/>
            <!-- the entry point: the middle of the full stem, where the crossbar meets it -->
            <circle data-ingresso cx="155" cy="410" r="1" fill="none"/>
          </svg>
        </div>
      </div>

      <div class="testi" data-testi>
        <p class="nota"><span class="nota__n">(1)</span><span data-righe>Hold is a working index of creative references: the records, books, films and talks we keep going back to when the work has to be done properly.</span></p>
        <h1 class="titoli">
          <span class="titolo"><span class="maschera"><span data-car>Hold</span></span></span>
          <span class="titolo"><span class="maschera"><span data-car>/Index</span></span></span>
          <span class="titolo titolo--anno"><span class="maschera"><span data-car>(2026)</span></span></span>
        </h1>
        <ul class="generi">
          <li>(6) Records</li><li>(5) Books</li><li>(4) Films</li><li>(5) Talks</li><li>(4) Essays</li>
        </ul>
        <p class="firma">S/K</p>
      </div>

      <button class="entra" type="button" data-entra data-autoclic>
        <span class="entra__faccia">
          <span class="entra__scritta">Enter the library</span>
          <svg class="entra__freccia" viewBox="0 0 16 16" aria-hidden="true"><path d="M2.5 8h10M8.5 3.5 13 8l-4.5 4.5"/></svg>
        </span>
      </button>
    </main>

    <!-- the library: dark -->
    <section class="libreria" data-libreria aria-label="Library" hidden>
      <svg class="fantasma" viewBox="0 0 1300 800" preserveAspectRatio="xMinYMid slice" aria-hidden="true"><use href="#lettera-h"/></svg>
      <div class="libreria__cima">
        <button class="indietro" type="button" data-indietro data-autoclic>
          <span class="indietro__faccia">
            <svg viewBox="0 0 16 16" aria-hidden="true"><path d="M13.5 8h-10M7.5 3.5 3 8l4.5 4.5"/></svg>
            <span>Back</span>
          </span>
        </button>
        <p class="vista"><span class="vista__spenta">Wheel,</span> <span class="vista__accesa">List</span></p>
      </div>
      <div class="scelta" data-scelta>
        <p class="scelta__formato"><span class="maschera"><span data-sc="formato">Record</span></span></p>
        <h2 class="scelta__nomi">
          <span class="maschera"><span class="scelta__autore" data-sc="autore">Mira Okafen</span></span>
          <span class="maschera"><span data-sc="titolo">Rooms Without Clocks</span></span>
        </h2>
        <p class="scelta__anno"><span class="maschera"><span data-sc="anno">1998</span></span></p>
      </div>
      <div class="elenco" role="table" aria-label="References">
        <div class="riga riga--testa" role="row">
          <span class="cella" role="columnheader"><span class="maschera"><span>Format</span></span></span>
          <span class="cella" role="columnheader"><span class="maschera"><span>Author</span></span></span>
          <span class="cella" role="columnheader"><span class="maschera"><span>Title</span></span></span>
          <span class="cella cella--anno" role="columnheader"><span class="maschera"><span>Year</span></span></span>
        </div>
        <div data-righe-elenco></div>
      </div>
    </section>

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

  <script src="https://cdn.jsdelivr.net/npm/gsap@3.15.0/dist/gsap.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.

44 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 “Letter into black 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

A stone grey home with a light grain: behind the type, black and cut by the edges, the giant letters of the brand, an H with stencil cuts and the bowl of a D; in front, in warm white, a three-line note, the title Hold /Index (2026) in a large grotesque, the genres of the library at the bottom left and the signature on the right; at the top the mark and the Index, Library, About menu. The light Enter the library button, with its layered shadow, follows the pointer with a small lag, and on hover the label widens and the arrow steps forward. On press the button inflates. On click: the button inflates once more and goes, the H lifts one pixel up and takes a soft shadow, comes in front of the type and dives towards the click point, slowly and then faster and faster, sliding so that the click lands inside its full stem; the type disappears in a tenth of a second, the D goes out and a black cover closes on top. Under the black the theme turns dark and the menu underlines Library. Then the black opens while the letter moves back a little and fades, and the dark library comes in: the faint ghost H behind, the Back button, Wheel, List, the chosen reference in large (format, author in grey, title, year) and the list of eight rows (format, author, title, year) rising one after the other in their masks. Hovering a row (or tapping it) dims the others, lights its title in lime green and changes the large reference: the old lines slide up out of their masks and the new ones come from below. Back makes the trip the other way round: the rows slide up and away, the black closes, the huge H shrinks back to its place, lands one pixel too far and settles, the shadow goes out, the title rises again letter by letter and the button pops back from nothing.

How it works

The letter is an SVG that dives towards the click

The H is an SVG as large as the home, with preserveAspectRatio xMinYMid slice, inside two elements: the outer one flies, the inner one lifts off by a pixel. A small invisible circle marks the entry point, in the middle of the full stem where the crossbar meets it: getScreenCTM gives its position in pixels and half the stem width, at every trip. The transformOrigin goes on that point, x and y bring that point under the click (power2.inOut) and the scale grows with power2.in.

How much it has to grow

The site zooms 14 times. Here the scale is at least ZOOM, but if the screen is large or the click is in a corner it grows more: the distance from the click to the farthest corner, times 1.12, divided by half the stem width. This way the stem always covers everything, on the phone too and at any size.

The curtain: cover, dark, opening

As on the site: the type disappears in 0.1 s, the scale flies in 0.6 s power2.in and from 0.2 s a black cover rises in 0.35 s. The theme changes under the black, with two CSS variables (--bg, --ink) that GSAP blends in 0.6 s with the site's curve, cubic-bezier(.4, 0, 0, 1), written by hand in a function (no CustomEase). Then the black opens in 0.6 s power2.out while the letter goes back to 70% of its scale and fades.

The rows in their masks

Every cell of the list and every line of the large reference sits in a span with overflow hidden: they come in from yPercent 110 to 0 (0.87 s power2.out, staggered, like the site's list) and leave to -110. The large reference changes the same way when a row is hovered: the old lines leave, the new text is written, the lines come in from below.

The button that follows the pointer

Two gsap.quickTo on x and y, 0.6 s power3.out like the site, centred with xPercent and yPercent -50. Outside the home it goes back to its place; on touch it jumps straight under the finger. A click inside the home starts from the point clicked; a click without a point (keyboard or preview) starts from the centre of the button.

Values to change

NameFileDefaultWhat it changes
ZOOMscript.js14How many times the letter grows at least (more if the screen needs it; the site uses 14).
FLIGHTscript.js0.6Seconds of the dive into the letter.
COVER_ATscript.js0.2How many seconds into the dive the black cover starts.
COVERscript.js0.35Seconds the black cover takes to close.
REVEALscript.js0.6Seconds the black takes to open on the new page.
LIFTscript.js1How many pixels the letter lifts off before the flight.
FOLLOWscript.js0.6Seconds the button takes to catch the pointer.
THEMEscript.js0.6Seconds of the colour fade between the two themes.
GRAINscript.js0.08How much grain on the colours.

Try them in the Playground

When to use it

For the most important step of a site with a strong brand: from the home to the archive of a portfolio, to the catalogue of a publisher or a label, to the collection of a studio. The giant brand is not only decoration, it is the door: you step into it.

On phones

The same trip: the H is sized by the SVG slice and on the phone almost fills the home, the scale is worked out from the real screen size, the title wraps and the list narrows its columns. The button does not follow the finger but jumps where you tap, and the dive starts from there.

With reduced motion

No dive and no moving letters: the home fades away, the colours turn dark and the library appears in place with the list already still; Back does the same the other way round. The button stays still in its place.

Pitfalls

  • The entry point is measured with getScreenCTM, which includes the ancestors' transforms: it has to be read with the letter at rest, so before every trip the leftover transforms are cleared and it is measured again.
  • With the letter growing on a ground already turning dark the dive could not be seen any more: the theme changes only halfway through the cover, under the black.
  • gsap.killTweensOf on the button also killed the quickTo tweens, and the button stopped following: to put it on a point at once, the quickTo function is called with the start value equal to the end.
  • The first row of the list is the header: counting it among the entries moved the lit row by one.
  • The preview's click came while the home was still arriving and the trip started halfway: the letter does not leave until the arrival is over. Back, instead, already answers while the rows are rising (the trip under way stops and the new one starts from there).

Libraries

GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.

Compressed with gzip, the three demo files weigh 9.9 KB; the libraries: GSAP 28 KB.

Testing

Tested on 16 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