Skip to content
animorio
IT
Back to the library

Audio cleanup scroll

Scroll, HoverGSAP, Canvas, CSS onlyMediumCompressed weight: Demo 7.3 KBGSAP + ScrollTrigger 45 KBLenis 5.3 KBFreeDownload the zip

Scroll inside the preview

The before and after of a made-up audio cleanup app, Quietline: the waveform of a badly recorded interview, with hum, hiss, clicks and room echo. As you scroll, a mint cleaning head sweeps across it and leaves the clean voice behind, section by section; the four steps tick, the noise floor drops from -38 to -71 dB and clarity rises. At the end the Before / After switch slides to After, a light sweeps the panel and Export lights up with its tick. Hovering the switch brings back the untouched recording.

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>
<!--
  "Audio cleanup scroll" 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 audio cleanup that clears the waveform section by section as you scroll</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 before / after of a made-up audio cleanup app, Quietline. A sticky stage: scrolling, a bright cleaning head
       sweeps across a noisy recording and leaves a clean waveform behind it, section by section (hum, hiss, clicks,
       room echo); each section chip ticks as the head passes it, the noise floor rolls down and the clarity meter
       fills. At the end the Before / After switch slides to After and Export lights up -->
  <section class="corsa" data-corsa>
    <div class="palco">
      <article class="pannello" data-pannello aria-label="Quietline, cleaning an interview recording">
        <span class="pannello__luce" data-luce aria-hidden="true"></span>

        <header class="testa">
          <span class="marchio">
            <svg viewBox="0 0 20 20" aria-hidden="true"><path d="M3 10h2.2M6.6 6.5v7M10 4v12M13.4 7v6M16.8 10H17"/></svg>
            <span>Quietline</span>
          </span>
          <span class="file">
            <svg viewBox="0 0 16 16" aria-hidden="true"><path d="M4 2.5h5l3 3v8H4z"/><path d="M9 2.5v3h3"/></svg>
            <span>interview_take3.wav</span>
            <span class="file__durata">02:48</span>
          </span>
        </header>

        <div class="ab" data-ab aria-hidden="true">
          <span class="ab__pillola" data-ab-pillola></span>
          <span class="ab__voce" data-ab-prima>Before</span>
          <span class="ab__voce" data-ab-dopo>After</span>
        </div>

        <div class="onda">
          <canvas class="onda__tela" data-tela aria-label="Waveform of the recording, cleaned from left to right"></canvas>
          <span class="testina" data-testina aria-hidden="true"><span class="testina__luce"></span></span>
        </div>

        <ul class="fasi" data-fasi aria-label="Cleanup steps"></ul>

        <div class="misure">
          <div class="misura">
            <span class="misura__nome">Noise floor</span>
            <span class="misura__valore"><span data-rumore>-38</span><small>dB</small></span>
          </div>
          <div class="misura misura--chiarezza">
            <span class="misura__nome">Clarity</span>
            <span class="misura__barra"><span class="misura__pieno" data-chiarezza-barra></span></span>
            <span class="misura__valore"><span data-chiarezza>42</span><small>%</small></span>
          </div>
          <span class="esporta" data-esporta>
            <svg viewBox="0 0 16 16" aria-hidden="true"><path class="esporta__spunta" data-spunta d="M3.5 8.4l3 3 6-6.6" pathLength="1"/></svg>
            <span data-esporta-testo>Cleaning</span>
          </span>
        </div>
      </article>
      <p class="invito" data-invito aria-hidden="true">Scroll to clean the recording</p>
    </div>
  </section>

  <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/ScrollTrigger.min.js"></script>
  <script src="https://cdn.jsdelivr.net/npm/lenis@1.3.26/dist/lenis.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.

31 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 “Audio cleanup scroll” 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 dark panel with the waveform of a recording: hum in the first quarter, hiss in the second, clicks in the third, echo in the last. As you scroll, a line of mint light crosses the waveform: behind it the bars become the clean voice, in mint, ahead of it they stay grey and dirty, with a soft edge right at the head. When the head passes the end of a section its step ticks with a small bounce; the noise floor rolls from -38 to -71 dB and the clarity bar fills from 42 to 96%. Once the cleanup is done, the switch pill slides from Before to After, a light crosses the panel and the button turns from Cleaning to Export, in mint, with its tick drawing in. Everything follows the scroll both ways; with the pointer on the switch the dirty waveform comes back.

How it works

A still stage, one number

The section is 320vh tall with a one-screen sticky stage inside. A single scrubbed ScrollTrigger takes a number from 0 to 1 and one function draws everything from it: the entrance, the cleanup and the ending each have their own stretch of the ride.

The waveform on a canvas

The voice is made of syllables as small bumps, with pauses between words, and the noise is different in each quarter; everything comes from a fixed random seed, so it is the same at every visit and every size. Each bar is drawn on a canvas: behind the head it takes the voice’s amplitude alone, ahead of it the one with the noise.

The head and the soft edge

The head is an element over the canvas moved in x; the change from dirty to clean is not sharp but runs over about fifteen pixels with a smoothstep, so the light seems to melt the noise.

The steps, the numbers, the ending

Each step ticks when the head passes its quarter, with a back.out bounce; the numbers come from the same ride. In the last stretch the switch pill slides, the light crosses the panel and Export’s tick draws in with pathLength 1.

Values to change

NameFileDefaultWhat it changes
NOISEscript.js1How loud the noise is before cleaning (0 none, 2 twice as loud).
BARscript.js3The width of each waveform bar, in pixels.
GAPscript.js1.5The gap between the bars, in pixels.
RIDEscript.js1How much scroll the whole section takes: 2 is twice as long.
SCRUBscript.js0.6How far the panel lags behind the scroll, in seconds.
GLOWscript.js1How bright the cleaning head is (0 none).
FLOOR_FROMscript.js-38The noise floor before, in dB.
FLOOR_TOscript.js-71The noise floor after, in dB.

Try them in the Playground

When to use it

For the page of an audio app or service (speech cleanup, podcasts, video calls, transcription): as you scroll you see the before and after without having to listen to anything.

On phones

The same animation with adapted sizes: the panel is sized on the height too, the four steps go on two rows and Export goes under the numbers; the canvas redraws at its own size.

With reduced motion

No movement: the panel does not rise and the steps do not bounce; the waveform, the numbers and the switch follow the scroll without jumps.

Pitfalls

  • One ScrollTrigger and one function drawing from a number: with one trigger per piece the steps and numbers overlap when you scroll back.
  • Measure the canvas again on resize, with devicePixelRatio, or the waveform gets blurry or stretched.
  • The noise must come from a fixed random seed: with Math.random the waveform would change every frame and tremble.

Libraries

GSAP 3.15.0, ScrollTrigger 3.15.0, Lenis 1.3.26, Mona Sans (font variabile) 5.3.0.

Compressed with gzip, the three demo files weigh 7.3 KB; the libraries: GSAP + ScrollTrigger 45 KB, Lenis 5.3 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