Skip to content
animorio
IT
Back to the library

Bulk actions bar

Hover, TransitionsGSAP, CSS onlyMediumCompressed weight: Demo 6.9 KBGSAP 28 KBFreeDownload the zip

The file list of a workspace: picking rows fills the checkbox on a spring and the dark actions bar rises from below, with the number of picked files rolling. Archive closes the rows one after the other and the bar turns into the notice with Undo and a draining thread of time; the checkbox at the top picks them all in a cascade.

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>
<!--
  "Bulk actions bar" 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>Bulk actions bar</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>
  <main class="stage">
    <!-- the files of a workspace: pick some rows and the bar of the bulk actions rises with the count,
         Archive closes the picked rows and the bar turns into the notice with Undo -->
    <section class="ba" data-ba aria-label="Documents">
      <header class="ba__head">
        <button class="ba__pick ba__pick--all" type="button" role="checkbox" aria-checked="false" aria-label="Select all files" data-all><span class="ba__fill" data-fill></span><svg viewBox="0 0 16 16" aria-hidden="true"><path data-tick pathLength="1" d="M3.900 8.400l2.700 2.700 5.600-6"></path><path data-dash pathLength="1" d="M4.300 8h7.400"></path></svg></button>
        <h1>Documents</h1>
        <p class="ba__count"><span data-files>5 files</span></p>
      </header>
      <ul class="ba__list" data-list>
        <li class="ba__row" data-row>
          <button class="ba__pick" type="button" role="checkbox" aria-checked="false" aria-label="Select Q4 roadmap.pdf" data-pick><span class="ba__fill" data-fill></span><svg viewBox="0 0 16 16" aria-hidden="true"><path data-tick pathLength="1" d="M3.900 8.400l2.700 2.700 5.600-6"></path></svg></button>
          <svg class="ba__doc" viewBox="0 0 20 20" aria-hidden="true"><path d="M5.500 2.800h6l3 3v10.200a1.200 1.200 0 0 1-1.200 1.200H5.500a1.200 1.200 0 0 1-1.200-1.200V4a1.200 1.200 0 0 1 1.200-1.200Z"></path><path d="M11.500 2.800v3h3"></path></svg>
          <span class="ba__name">Q4 roadmap.pdf</span>
          <span class="ba__size">2.4 MB</span>
        </li>
        <li class="ba__row" data-row>
          <button class="ba__pick" type="button" role="checkbox" aria-checked="false" aria-label="Select Brand kit.zip" data-pick><span class="ba__fill" data-fill></span><svg viewBox="0 0 16 16" aria-hidden="true"><path data-tick pathLength="1" d="M3.900 8.400l2.700 2.700 5.600-6"></path></svg></button>
          <svg class="ba__doc" viewBox="0 0 20 20" aria-hidden="true"><path d="M5.500 2.800h6l3 3v10.200a1.200 1.200 0 0 1-1.200 1.200H5.500a1.200 1.200 0 0 1-1.200-1.200V4a1.200 1.200 0 0 1 1.200-1.200Z"></path><path d="M11.500 2.800v3h3"></path></svg>
          <span class="ba__name">Brand kit.zip</span>
          <span class="ba__size">48 MB</span>
        </li>
        <li class="ba__row" data-row>
          <button class="ba__pick" type="button" role="checkbox" aria-checked="false" aria-label="Select Invoice 0192.pdf" data-pick><span class="ba__fill" data-fill></span><svg viewBox="0 0 16 16" aria-hidden="true"><path data-tick pathLength="1" d="M3.900 8.400l2.700 2.700 5.600-6"></path></svg></button>
          <svg class="ba__doc" viewBox="0 0 20 20" aria-hidden="true"><path d="M5.500 2.800h6l3 3v10.200a1.200 1.200 0 0 1-1.200 1.200H5.500a1.200 1.200 0 0 1-1.200-1.200V4a1.200 1.200 0 0 1 1.200-1.200Z"></path><path d="M11.500 2.800v3h3"></path></svg>
          <span class="ba__name">Invoice 0192.pdf</span>
          <span class="ba__size">180 KB</span>
        </li>
        <li class="ba__row" data-row>
          <button class="ba__pick" type="button" role="checkbox" aria-checked="false" aria-label="Select Homepage v3.fig" data-pick><span class="ba__fill" data-fill></span><svg viewBox="0 0 16 16" aria-hidden="true"><path data-tick pathLength="1" d="M3.900 8.400l2.700 2.700 5.600-6"></path></svg></button>
          <svg class="ba__doc" viewBox="0 0 20 20" aria-hidden="true"><path d="M5.500 2.800h6l3 3v10.200a1.200 1.200 0 0 1-1.200 1.200H5.500a1.200 1.200 0 0 1-1.200-1.200V4a1.200 1.200 0 0 1 1.200-1.200Z"></path><path d="M11.500 2.800v3h3"></path></svg>
          <span class="ba__name">Homepage v3.fig</span>
          <span class="ba__size">12 MB</span>
        </li>
        <li class="ba__row" data-row>
          <button class="ba__pick" type="button" role="checkbox" aria-checked="false" aria-label="Select Launch notes.md" data-pick><span class="ba__fill" data-fill></span><svg viewBox="0 0 16 16" aria-hidden="true"><path data-tick pathLength="1" d="M3.900 8.400l2.700 2.700 5.600-6"></path></svg></button>
          <svg class="ba__doc" viewBox="0 0 20 20" aria-hidden="true"><path d="M5.500 2.800h6l3 3v10.200a1.200 1.200 0 0 1-1.200 1.200H5.500a1.200 1.200 0 0 1-1.200-1.200V4a1.200 1.200 0 0 1 1.200-1.200Z"></path><path d="M11.500 2.800v3h3"></path></svg>
          <span class="ba__name">Launch notes.md</span>
          <span class="ba__size">6 KB</span>
        </li>
      </ul>
      <div class="ba__slot">
        <p class="ba__hint" data-hint>Select files to archive them together</p>
        <div class="ba__bar" data-bar>
          <div class="ba__layer" data-sel>
            <p class="ba__n"><span class="ba__num"><span data-num>0</span></span> selected</p>
            <button class="ba__act" type="button" data-archive>Archive</button>
            <button class="ba__x" type="button" aria-label="Clear selection" data-clear><svg viewBox="0 0 16 16" aria-hidden="true"><path d="M4.500 4.500l7 7M11.500 4.500l-7 7"></path></svg></button>
          </div>
          <div class="ba__layer ba__layer--toast" data-toast>
            <p class="ba__n"><span data-done>0 archived</span></p>
            <button class="ba__act ba__act--undo" type="button" data-undo>Undo</button>
          </div>
          <span class="ba__drain" data-drain aria-hidden="true"></span>
        </div>
      </div>
      <span class="ba__say" data-say aria-live="polite"></span>
    </section>

    <svg class="ghost" data-ghost viewBox="0 0 24 24" aria-hidden="true"><path d="M5 3.200 19.200 11l-6.300 1.600-3.300 5.900Z"></path></svg>
  </main>

  <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.

31 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 “Bulk actions bar” 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 pale grey, a white card: at the top the checkbox that picks them all, “Documents” and “5 files”; below, five files, each with its checkbox, the sheet icon, the name and the size; at the bottom, faintly, “Select files to archive them together”. On the first click on a row the checkbox fills with indigo on a spring, the tick draws itself, the row takes a wash of colour and a dark pill-shaped bar rises from below: “1 selected”, Archive and the cross. With every extra row the number rolls up, taking one away rolls it down; the top checkbox shows the dash until they are all picked. With Archive the picked rows close one after the other sliding right, the others move up, “5 files” becomes “2 files” and inside the bar the words change to “3 archived” and Undo, with a thread draining along the edge. Undo reopens the rows on a spring and the bar drops. The top checkbox picks them all in a cascade; the cross, or Esc, lets the selection go.

How it works

The state lives in the rows

Every row knows whether it is picked and whether it is archived; a single function counts the picks and from there decides the top checkbox, the number and the bar.

The bar

It rises on a spring (y, scale and autoAlpha) when the count goes from zero to one and drops when it returns to zero; while it is down it is inert, so Tab does not enter it.

Archive

The picked rows animate height, opacity and x towards zero with a stagger; inside the bar two layers swap places and a thread scales from 1 to 0 in UNDO seconds.

Undo

It stops the thread, brings the rows back to their height on a spring and clears the ticks; without Undo, in the demo, they come back by themselves a little later.

Values to change

NameFileDefaultWhat it changes
ACCENTscript.js#5b5bf0The colour of the checkboxes, of the picked rows and of the Archive button.
UNDOscript.js4For how many seconds the notice with Undo stays after Archive.
STAGGERscript.js0.05The delay between one row and the next when they close, come back or are all picked together.
SPRINGscript.js1How much the bar, the checkboxes and the rows bounce: 0.3 = a little, 2 = a lot.
LOOPscript.jstrueLeft alone, the demo’s pointer picks three files, archives them, undoes, picks them all and lets go.

Try them in the Playground

When to use it

In the tables and lists of a dashboard or an app: files, emails, orders, users, invoices, tasks. Anywhere the same actions apply to several rows together: archiving, moving, deleting, exporting.

On phones

The same card, 316 pixels wide at most: the rows are 38 pixels tall and the whole row is the target, long names are cut with an ellipsis, and the bar sits in its place at the bottom of the card without covering the rows.

With reduced motion

No springs and no sliding rows: the checkboxes fill at once, the bar fades in and out, the archived rows vanish and come back in place in one step. The demo does not move by itself.

Pitfalls

  • The files are made up and nothing is archived: in a real app Archive fires at once and Undo reverts it, or the request only leaves when the notice ends.
  • With Shift held the click picks every row between the last one touched and this one, as mail programs do.
  • The checkboxes are buttons with role=checkbox and aria-checked; the top one is “mixed” when only some rows are picked.
  • The lowered bar and the hidden layer inside it are inert: without that, Tab would land on buttons nobody can see.
  • The rows’ height is animated with GSAP: fine for a few rows; in a long table animate only what is on screen.

Libraries

GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.

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

Testing

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