Skip to content
animorio
IT
Back to the library

Ellipse slide transition

TransitionsGSAP, CSS onlyMediumCompressed weight: Demo 7.3 KBGSAP + CustomEase 31 KBFreeDownload the zip

A presentation viewer by Lantern Decks, a made-up presentation studio in Lisbon: the slides change behind an indigo veil cut into an ellipse. Leaving, the ellipse rises from a flat line on the bottom edge and swells until it covers the screen; arriving, it widens from 70 to 100%, flattens into a line and slides down, uncovering the new slide from the top while its lines rise one after another and the title settles its width. Minimal style, inspired by the La boite à slides site.

Rebuilt from scratch studying laboiteaslides.fr by Sparkk, Evan Fasquelle: 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>
<!--
  "Ellipse slide 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>Pitch deck · Lantern Decks</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>
  <!-- A small presentation viewer by Lantern Decks, a made-up presentation studio in Lisbon. The slides change behind
       an indigo veil shaped like an ellipse: on the way out it rises from a flat line at the bottom and swells until
       it covers the slide; on the way in it gets wider, flattens into a line again and slides down, uncovering the
       next slide. The new slide's lines come up one after another. -->
  <main class="palco">
    <section class="visore" aria-label="Pitch deck viewer" aria-roledescription="carousel">
      <div class="schermo" data-schermo>
        <div class="slide" data-slide aria-live="polite"></div>
        <div class="velo" data-velo aria-hidden="true">
          <div class="velo-luce"></div>
          <p class="velo-nome" data-velo-nome></p>
        </div>
      </div>

      <div class="barra">
        <button class="tasto" type="button" data-indietro aria-label="Previous slide">
          <svg viewBox="0 0 20 20" aria-hidden="true"><path d="M12 4.5 6.5 10l5.5 5.5"/></svg>
        </button>
        <div class="centro">
          <p class="nome" data-nome></p>
          <div class="miniature" data-miniature role="tablist"></div>
        </div>
        <button class="tasto avanti" type="button" data-avanti data-autoclic aria-label="Next slide">
          <svg viewBox="0 0 20 20" aria-hidden="true"><path d="M8 4.5 13.5 10 8 15.5"/></svg>
        </button>
      </div>
    </section>
  </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.

13 values to change

Works with Claude, Claude Code, ChatGPT, Cursor, VS Code, Windsurf, Codex, Gemini CLI

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 “Ellipse slide 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

On a warm white ground, a 16:9 screen with a soft shadow and under it the viewer bar: the back button, the slide name with a grey line, four thumbnails with an indigo ring on the open one and the black next button. On the screen, the pitch deck of Halden Bikes, a made-up bike brand: the cover «Ride the city quieter.», the problem with 38-minute commutes and 71 decibels, traction with 12,400 riders and six bars, the ask of 4 million. Now and then the viewer moves on by itself, with an indigo hairline filling under the thumbnail. On a change the old title's words rise and vanish, an indigo ellipse with a veil of grain rises from the bottom edge and swells until it covers everything, the new slide's name shows in capitals in the middle; then the ellipse widens, flattens into a line and slides down, uncovering the new slide from the top: the title's words rise one by one from their mask, narrowing from wide to normal, then the figures and the chart's bars. The name in the bar rolls, the ring slides to the new thumbnail with a small bounce; the buttons sink when pressed and the arrow takes a step.

How it works

A veil cut by an ellipse

Over the slide sits an indigo veil masked by radial-gradient(rx ry at 50% py, black, transparent): three numbers, the width in percent, the height in pixels and the vertical position of the centre, kept in an object GSAP animates and written as CSS variables on every update.

Covering

It starts as a line on the bottom edge (100%, 0 pixels, centre at 100%) and ends as an ellipse 70% wide, as tall as the screen and centred: in 1 second with power2.in. With those sizes the corners are covered too: (0.5/0.7)² + 0.5² is below 1.

Swapping and uncovering

While the screen is covered the new slide is written, then the three numbers go back to 100%, 0 pixels and 100% in 1.5 seconds with power2.out: the ellipse widens, flattens and slides down, and the slide is uncovered from the top.

The lines that rise

Each word of the title sits in its own mask and rises from 105% with the studio's curve (a small overshoot to 1.016), 0.08 seconds apart; the title goes from wdth 118 to 100. The figures rise by 14 pixels and the bars grow from zero.

By itself, until you touch it

A hairline under the thumbnail fills in 1.9 seconds, then the viewer moves on. Arrows, keys and thumbnails stop it for four seconds; a click during a change waits its turn.

Values to change

NameFileDefaultWhat it changes
LEAVEscript.js1Seconds the veil takes to cover the slide.
ARRIVEscript.js1.5Seconds the veil takes to flatten and slide away.
WIDTH_STARTscript.js70The width of the ellipse when it covers, in percent of the screen.
HEIGHT_FULLscript.js1The height of the ellipse when it covers, in screens (never above 1500 pixels).
HOLDscript.js1.9Seconds each slide stays before the deck moves on by itself.
STAGGERscript.js0.08The delay between the lines of the incoming slide.
ACCENTscript.js#4b3bffThe colour of the veil and of the details.

Try them in the Playground

When to use it

For a presentation on the web, a pitch deck to send to investors, an agency portfolio showing work one piece at a time, or the change between two pages of a site: when you want a decisive change that covers everything and then uncovers the new page from the top.

On phones

The screen is sized on the smaller of 88vw and the height of the box minus the bar, so the whole viewer fits even when it is short; the buttons shrink to 34 pixels, the thumbnails to 22 and the grey line next to the name goes away.

With reduced motion

No moving ellipse and no rising lines: the indigo veil fades in and out and the new slide arrives already in place; the name fades and the ring jumps to the thumbnail.

Pitfalls

  • The ellipse is measured in pixels: its maximum is read again from the screen height on every change (a function in the tween), because the demo window can change height.
  • The new slide is written halfway through the timeline: its entrance is created with a call at that moment, not when the timeline is built, otherwise it would grab the old slide's words.
  • A click during a change does not start a second one: it waits and runs at the end.
  • With a hard mask edge the ellipse looks jagged: the black ends a pixel and a half before the transparent.

Libraries

GSAP 3.15.0, CustomEase 3.15.0, Mona Sans (font variabile) 5.3.0.

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

Testing

Tested on 2 December 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