Skip to content
animorio
IT
Back to the library

Exhibition gallery

Transitions, Images, HoverGSAP, CSS onlyAdvancedCompressed weight: Demo 12 KBGSAP + CustomEase 31 KBFreeDownload the zip

The West Room of a made-up Los Angeles gallery, Arroyo Hall, showing the photography show Long Light: twelve real photographs of California (palms, bluffs, waves, desert roads, the seats and screen of a cinema, concrete, a prop camera) hung in a sparse eight-column grid on a warm white wall with grain. At the top a Grid / List pill switch, its dark thumb sliding on a spring and four small squares lining up. On the switch the photos in view leave blurring, one every 0.08 s, and in the row each one comes back turning like a page around its left edge, from behind, in 1.6 s, with the shadow of the page moving under it. Three sizes that rearrange in 1.2 s; drag or wheel to move through the room and, going fast, it shrinks to 0.96 and settles back.

Rebuilt from scratch studying hollywoodexhibit2026.com by OSMOS, HearstCC, Edoardo Lunardi, Daniel Velasquez, Marjoe Bacus: 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>
<!--
  "Exhibition gallery" 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>Arroyo Hall, Long Light: the West Room</title>
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fontsource-variable/instrument-sans@5.3.0/wdth.css">
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fontsource-variable/fraunces@5.3.0/full.css">
  <link rel="stylesheet" href="style.css">
</head>
<body>
  <main class="stage" data-stage>
    <!-- the West Room of a made-up Los Angeles gallery, Arroyo Hall, showing a photography show, Long Light.
         The works hang in a sparse grid on eight columns; the switch at the top turns it into one long row. The photos
         leave blurring, one after the other, and each one comes back into the row turning like a page around its left
         edge. Drag or wheel to move; moving fast, the room shrinks a little and settles back -->
    <div class="grain" aria-hidden="true"></div>

    <header class="head">
      <a class="brand" href="#top" aria-label="Arroyo Hall">
        <svg class="brand__mark" viewBox="0 0 28 28" aria-hidden="true">
          <path d="M5 24V12.5a9 9 0 0 1 18 0V24"/>
          <path d="M9.5 24v-10a4.5 4.5 0 0 1 9 0v10"/>
          <path d="M2.5 24h23"/>
        </svg>
        <span class="brand__words">
          <span class="brand__name">Arroyo Hall</span>
          <span class="brand__show">Long Light</span>
        </span>
      </a>

      <div class="switch" role="group" aria-label="View" data-switch>
        <span class="switch__glyph" aria-hidden="true" data-glyph><i></i><i></i><i></i><i></i></span>
        <span class="switch__track">
          <span class="switch__thumb" data-thumb aria-hidden="true"><span class="switch__shine"></span></span>
          <button class="switch__opt is-on" type="button" aria-pressed="true" data-view="grid"><span>Grid</span></button>
          <button class="switch__opt" type="button" aria-pressed="false" data-view="list"><span>List</span></button>
        </span>
      </div>
    </header>

    <section class="view" aria-label="The works in the West Room" data-view-box>
      <div class="lens" data-lens>
        <ul class="track" data-track>
          <!-- filled in by script.js from WORKS -->
        </ul>
      </div>
      <div class="edge edge--a" aria-hidden="true"></div>
      <div class="edge edge--b" aria-hidden="true"></div>
    </section>

    <footer class="foot">
      <p class="room">
        <span class="room__name">West Room</span>
        <span class="room__count">Long Light, 12 works</span>
      </p>
      <p class="now" aria-live="polite"><span class="now__in" data-now>California, 1958 to 2019</span></p>
      <div class="zoom" role="group" aria-label="Size of the works">
        <button class="zoom__btn" type="button" aria-label="Smaller" data-zoom="-1">
          <svg viewBox="0 0 16 16" aria-hidden="true"><path d="M4 8h8"/></svg>
        </button>
        <span class="zoom__steps" aria-hidden="true" data-steps><i></i><i></i><i></i></span>
        <button class="zoom__btn" type="button" aria-label="Larger" data-zoom="1">
          <svg viewBox="0 0 16 16" aria-hidden="true"><path d="M4 8h8M8 4v8"/></svg>
        </button>
      </div>
    </footer>
  </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.

29 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 “Exhibition gallery” 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

On a warm white wall with fine grain and slightly darker corners, the Arroyo Hall mark (an arch drawn in lines) with the name of the show, Long Light, at the top left, and at the right the frosted glass pill switch: four small squares, Grid and List, with a dark thumb under the chosen view. The twelve photographs hang in a sparse grid, eight columns on a wide screen, six on a tablet and four on a phone, some bigger than others, each with a small caption (title and year) at a different corner. On arrival they come in from a blur one after the other. Under the mouse a photo leans towards the pointer, lifts a little off the wall with a longer shadow and a soft light slides over the print, and its title and year appear at the bottom centre; pressed, it sinks and springs back. With the minus and plus at the bottom right (three ticks show the size) the photos all rearrange together in 1.2 s. Choosing List the thumb slides with a small bounce, the squares line up, the photos in view leave blurring and shrinking one after the other, and the row arrives: each photo turns like a page around its left edge, first showing its paper back with the gallery stamp, then the photo, with the page's shadow darkening the fold and the shadow on the ground stretching and shortening. The row moves with a drag or the wheel; going fast, the room shrinks to 0.96 and settles back. Left alone, it changes size, shows one photo, switches to the row, moves along it and comes back to the grid.

How it works

A calculated sparse grid

Every photo is an absolute element given x, y, width and height by GSAP. There are eight columns (six, four); for each photo a fixed pattern says where across it would like to be and how far it drops, and the script picks the column that costs least between the wanted one and an emptier one nearby, keeping for every column the lowest point already taken. It looks scattered at random but never heaps up.

Three sizes in 1.2 s

Plus and minus recompute the pattern with wider columns and every photo goes from its old box to the new one with a fromTo on x, y, width and height, 1.2 s on the site's quart curve (CustomEase 0.77,0,0.18,1). The scroll moves in proportion over the same time, so you stay at the same point of the room.

Leaving in a blur

On a view change only the photos in view are taken, in reading order, and each goes to opacity 0, a 6 px blur and scale 0.97 in 0.6 s, 0.08 s after the one before; the ones out of view vanish at once. Once they are gone everything is recomputed for the new view and the scroll goes back to the start.

The turning page

Inside every card a page in preserve-3d has its origin on the left edge and two faces with backface-visibility hidden: the photo in front, paper behind. A number from 0 to 1 over 1.6 s on sine.out takes rotationY from 150 degrees to 0 and z from −40 to 0; at each step a dark veil on the fold follows the sine of the angle, the ground shadow takes a scaleX equal to the cosine (negative while the page is still on the other side) and the card appears with the progress, as on the site.

A scroll that shrinks the room

The wheel and the drag move a target; every frame the position follows it by a factor of 0.1. The difference between one frame and the next is the speed: the room goes to a scale of 1 − 0.04 × min(speed / 40, 1), smoothed at 0.15, so 0.96 when going fast and 1 at rest.

Values to change

NameFileDefaultWhat it changes
COLUMNSscript.js8Columns of the grid on a wide screen (two less on a tablet, four on a phone).
START_SIZEscript.js0Size of the photos at the start: 0 small, 1 medium, 2 large.
LAYOUT_TIMEscript.js1.2Seconds the photos take to rearrange when the size changes (the site uses 1.2).
EXIT_TIMEscript.js0.6Seconds each photo takes to blur away (the site uses 0.6).
EXIT_STAGGERscript.js0.08Seconds between one photo leaving and the next (the site uses 0.08).
EXIT_BLURscript.js6Pixels of blur leaving and coming back into the grid (the site uses 6).
FLIP_TIMEscript.js1.6Seconds of each photo's page turn into the row (the site uses 1.6).
FLIP_ANGLEscript.js150Degrees the page starts from, folded behind its left edge.
FLIP_STAGGERscript.js0.08Seconds between one page and the next.
SCROLL_SHRINKscript.js0.96How small the room gets when moving fast (the site uses 0.96).
SCROLL_EASEscript.js0.1How closely the room follows the wheel and the drag (the site uses 0.1).
TILTscript.js6Degrees a photo leans under the pointer.
LOOPscript.jstrueLeft alone, the room changes size and view again and again.

Try them in the Playground

When to use it

For the page of an exhibition, a photo archive, a photography or architecture portfolio, a catalogue of works or a product collection: when both readings matter, the grid to see the whole and the row to see one thing at a time, and moving between them should feel physical, like leafing through real prints.

On phones

The same animation with adapted sizes: four columns and sizes measured on the room's height too, captions hidden on photos that are too small, the row tall in proportion. It moves with a finger (vertical in the grid, horizontal in the row) with a little inertia on release; no leaning on hover, but the press with its spring back stays.

With reduced motion

No movement: changing view the photos fade out and the new view fades in, changing size the room fades and comes back already rearranged, no page turn, no blur, no leaning and the room does not shrink while scrolling.

Pitfalls

  • A filter or an opacity below 1 on an element in preserve-3d flattens it and the page turn loses its perspective: here blur and opacity sit on the card, which only gives the perspective, and the 3D lives in the page inside.
  • The page turn shows the back of the photo for half the time: without the second face with backface-visibility hidden the photo would be seen mirrored. The site solves it by flipping the coordinates in the shader; here there is a paper back.
  • The speed that shrinks the room must be measured only when the person moves it: when the scroll moves by itself to follow a size change, the room would shake at every zoom.
  • Three transforms on one element cancel each other out: the card takes position and size, the page the turn, the leaf inside the lean under the pointer.

Libraries

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

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

Testing

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