Platform
VaultVault
  • Free15
  • Navigation19
  • Buttons9
  • Scroll55
  • Text27
  • Sliders & marquees19
  • Gallery & images67
  • Cursor24
  • Page transitions10
  • Loaders2
  • Backgrounds10
  • UI components33
ButtonsPart of ProButtons
IconsPart of ProIcons
  • Interface Essentials144
  • Social Icons69
  • Payment Badges41
SavedPart of ProSaved
Support
DocumentationDocumentation
MCP serverMCP server
SettingsSettings
VaultScrollDiagonal Tile Gallery
Rising Arch on ScrollBrowse all 182Folding Burger Nav
  • Free15
  • Navigation19
  • Buttons9
  • Scroll55
  • Text27
  • Sliders & marquees19
  • Gallery & images67
  • Cursor24
  • Page transitions10
  • Loaders2
  • Backgrounds10
  • UI components33
  • Interface Essentials144
  • Social Icons69
  • Payment Badges41
Sign inSign in

Start free. The code for 15 components, no card needed.

Get 15 free

Diagonal Tile Gallery

This one is locked. Become a member to open the code for it and the rest of the Vault.

See plansTry the 15 free ones

What you'll need.

Install

  • gsap
  • ScrollTrigger

Setup

npm i gsapregisterPlugin(ScrollTrigger)

More like this

  • Card
  • Horizontal scroll
  • Pinned
  • Line drawing
  • ScrollTrigger
  • Sticky
  • SVG

Features.

  • Square tiles on one diagonal sheet that pans up and left at 45° as the page scrolls
  • The next tile slides in from the bottom right while the last one leaves top left
  • The first tile opens from a smaller window as the section arrives
  • A large heading at the foot of every tile, sized from the tile (a short sentence under it is optional: .dgp_text)
  • Three line drawings that draw themselves with the scroll: a dot spiral, a dial with a hand, a rosette
  • Small colour blocks pop one by one along an S-curve as the sheet passes
  • Any number of tiles: the script measures the sheet and sets the scroll length itself
  • Phones get the tiles stacked, each drawing on its own tile's scroll
  • Respects prefers-reduced-motion: stacked tiles, drawings finished

How to get it right.

Give it something to follow

The pan needs more scroll than the space the section takes, so the next section rides up over the pinned screen while the last tile leaves. Follow it with about a screen and a half of content. If it is the last thing on the page, wrap the page in an element with overflow: clip so the page ends with that content.

Lift the next section above the stage

Give whatever follows position: relative; z-index: 1, or it slides under the tiles.

Use square pictures

Tiles are square on desktop and 2:3 on phones, cropped with object-fit: cover. Keep the subject near the middle.

Number the tiles

Each tile needs style="--dgp-i: n", counting from 0. That is what puts it lower than the one before.

Variations.

  • Locked to scroll — data-au-scrub="0"
  • Smaller or larger tiles — --dgp-width: 30vw; they never grow past 70vh
  • Tighter diagonal — --dgp-gap: 1em
  • No opening on the first tile — data-au-open="0"
  • No blocks — data-au-blocks="false", or delete .dgp_trail
  • No drawing on a tile — delete its [data-dgp-drawing]
  • Picture-only tiles — delete .dgp_copy from a tile; the drawing takes the room
  • Different page colour — --dgp-bg; heading and accent strokes follow --dgp-accent
  • Different block colours — --dgp-block-brand, --dgp-block-soft, --dgp-block-ink, --dgp-block-muted
  • Lighter tint on the pictures — --dgp-scrim-top and --dgp-scrim-bottom

Where it fits.

  • Case studies — three or four key pictures or numbers
  • Landing pages — a feature run between two plain sections
  • Reports and editorial — a short sequence of facts, one per tile

Frequently asked.

No. It runs on native scroll, and with Lenis once Lenis updates ScrollTrigger.

As many as you like. Three to five reads best: every extra tile adds about one tile and a gap of scrolling.

The script sets the section's height from the sheet's size. Load it before the page is shown, or keep the section below the first screen.

Yes. Each block's --dgp-x and --dgp-y place it in % of the sheet, and it lands on the nearest point of the curve. To change the curve, edit the path in [data-dgp-path].

Not with an option. The diagonal runs down to the right and the sheet pans up and left.

Related components.

NewPro

Arc Collage Hero

Scroll

Pro

Rising Card on Scroll

Scroll

Pro

Outline Paint Reveal

Scroll