Skip to content
animorio
IT
Back to the library

Vet service tags

Physics, HoverGSAP, CSS onlyAdvancedCompressed weight: Demo 10 KBGSAP 28 KBFreeDownload the zip

The services of Brindle Veterinary, a made-up veterinary clinic, in the premium style of Dribbble shots: four cream enamel tags with satin steel rims, hung by a split ring from hooks that slide on a gallery rail. Each one is a pendulum with real physics: gravity brings it back down, the air slows it, the pointer crossing them pushes them and neighbours knock softly; when a hook slides along the rail the tag lags behind, against the acceleration. A tap opens a tag on its spring, it turns to green enamel and shows the length of the visit, the price and a note, while the other hooks slide aside to make room and their tags swing.

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>
<!--
  "Vet service tags" 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>Brindle Veterinary, our services</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" data-stage>
    <!-- the services of a made-up veterinary clinic, Brindle Veterinary, as enamel tags on satin metal rims, each one
         hanging from a split ring and a sliding hook on a gallery rail. Every tag is a real pendulum: gravity brings it
         back, the air slows it down, the pointer pushes it and the hooks slide along the rail; when a hook moves the tag
         lags behind, against the acceleration. A tap opens a tag: it grows on a spring, turns to green enamel and shows
         the length of the visit and the price, while the other hooks slide aside to make room -->
    <div class="wall" data-wall>
      <header class="head">
        <div class="head__who">
          <span class="head__mark" aria-hidden="true">
            <svg viewBox="0 0 24 24"><ellipse cx="12" cy="15.6" rx="4.6" ry="3.7"></ellipse><ellipse cx="6.1" cy="10.4" rx="1.7" ry="2.2" transform="rotate(-18 6.1 10.4)"></ellipse><ellipse cx="9.7" cy="7.2" rx="1.8" ry="2.4" transform="rotate(-6 9.7 7.2)"></ellipse><ellipse cx="14.3" cy="7.2" rx="1.8" ry="2.4" transform="rotate(6 14.3 7.2)"></ellipse><ellipse cx="17.9" cy="10.4" rx="1.7" ry="2.2" transform="rotate(18 17.9 10.4)"></ellipse></svg>
          </span>
          <div>
            <p class="head__brand">Brindle Veterinary</p>
            <h1 class="head__title">Our services</h1>
          </div>
        </div>
        <p class="head__hours">Open today<br><b>08:00 to 22:00</b></p>
      </header>

      <div class="shades" data-shades aria-hidden="true"></div>
      <div class="rail" data-rail aria-hidden="true">
        <span class="rail__bracket rail__bracket--l"></span>
        <span class="rail__bracket rail__bracket--r"></span>
        <span class="rail__bar"></span>
      </div>
      <div class="hooks" data-hooks aria-hidden="true"></div>
      <ul class="tags" data-tags aria-label="Services"></ul>
    </div>
    <p class="sr" data-live aria-live="polite"></p>

    <svg class="ghost" data-ghost viewBox="0 0 24 24" aria-hidden="true"><path d="M5 3.2 19.2 11l-6.3 1.6-3.3 5.9Z"></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.

21 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 “Vet service tags” 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 light sand wall with the fine grain of plaster sits the mark of Brindle Veterinary, a made-up clinic (a paw print engraved in a round of green enamel), the title Our services and on the right today’s opening hours. Below runs a satin steel gallery rail held by two brackets with their screws, and four hooks slide along it. From each hook, by a split ring that goes through a hole with a metal grommet, hangs a cream enamel tag with a steel rim: Vaccinations, Dental care, Grooming and Night clinic, each with its icon engraved in green and a small paw print at the bottom. On arrival the hooks come in from the right one after the other and the tags swing behind them. Each tag is a real pendulum: the pointer crossing them pushes them the way it goes, the air calms them slowly, neighbours knock and pass the blow on; the light on the rim and the gleam on the enamel move with the swing and the shadow on the wall swings a little wider and fades as the tag moves away from it. Under the pointer a tag swells slightly, pressed it shrinks; a tap opens it on a spring: it widens and lengthens, turns to green enamel and shows the length of the visit with a clock, the starting price and a note, while the other hooks slide aside to make room and their tags lag behind and swing. Left alone, a drawn pointer sweeps across them all, opens Dental care, then Night clinic, closes it and passes back under the hooks.

How it works

A pendulum under a sliding hook

Each hook is a mass on a spring that brings it back to its place on the rail; each tag is a pendulum hanging from the hook, its angle following α = −(g/L)·sin θ − (a/L)·cos θ − friction·ω. The second term is the hook’s acceleration with the opposite sign: when the hook sets off to the right the tag lags to the left, when it brakes it swings ahead. Everything is in em, with four small steps per frame on the GSAP ticker, so the physics is the same at any window size.

The pointer pushes where it touches

The pointer is brought into the frame of the rotated tag (along and across the string): if it is inside, its speed is compared with the speed of the touched point (ω times the distance from the pivot plus the hook’s speed) and the difference becomes a push. Resting over a tag does not stop it; neighbours that get too close push apart on a stiff spring, and the blow is passed on.

Opening on its own spring

Opening a tag means moving the target of a damped spring from 0 to 1: width and height follow the spring (with its small overshoot), the pendulum gets longer and swings slower, the hook places are worked out again from the new widths and their springs move them. The green enamel is a layer over the cream one that fades in; the details arrive afterwards, staggered, with a back.out.

Values to change

NameFileDefaultWhat it changes
GRAVITYscript.js120How strong gravity is, in em per second squared: higher swings faster.
AIRscript.js0.7How quickly a swinging tag calms down (air friction).
PUSHscript.js0.6How much the pointer pushes a tag when it moves across it.
RAILscript.js60How stiff the spring that brings each hook back to its place on the rail.
SPRINGscript.js170How stiff the spring that opens and closes a tag.
BOUNCEscript.js0.42The damping of the opening: lower bounces more.
LOOPscript.jstrueLeft alone, a pointer sweeps the tags and opens two services.
--accentstyle.css#1f6b5cThe green of the open enamel, the icons and the mark.
--creamstyle.css#fbf8f1The cream enamel of the closed tags.
--bgstyle.css#ece7dfThe sand colour of the wall.

Try them in the Playground

When to use it

For the services section of a veterinary clinic, a pet groomer, a pet hotel or any business with a few services and a price list: the items look like real objects, you tap them to read the length and the price and they stay light on the page.

On phones

The same animation with adapted measures: the wall is sized on width and height together and fits the box even with a tag open; a finger sliding over the tags pushes them like the pointer and a tap opens them.

With reduced motion

No swinging or sliding: the tags stay still in their place, open at once and their green enamel and details arrive with a fade.

Pitfalls

  • In CSS a positive rotate turns clockwise, so the bottom of a hanging thing goes left: the physics uses θ with the bottom to the right and writes rotate(−θ). With the wrong sign the tag swung ahead instead of lagging when the hook set off.
  • The pointer’s push has to come from the difference between its speed and the speed of the touched point, not from its speed alone: otherwise a tag already swinging faster than the pointer still gets pushed and starts spinning.

Libraries

GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.

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

Testing

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