Skip to content
animorio
IT
All components

Hire me button

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

The Hire me button at the end of the portfolio of Iris Okafor, a made-up product designer. Above the black pill a line says when she is free, «Available from Jan 12», with a small drawn calendar. On hover the pill lifts by a pixel, on click it presses on a spring and the request opens below: the start date to pick from three, with the white puck sliding over, the email and «Send request», which works with a running line and turns into «Request sent · I’ll reply within a day» with a tick. Closed again, the button says «Requested» and the line above shows the chosen date.

The code

A folder that runs on its own: index.html, style.css, script.js and the libraries from a CDN.

<!doctype html>
<!--
  "Hire me button" 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>Hire me button</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 Hire me button at the end of the portfolio of Iris Okafor, a made-up product designer.
         It says when she is free, opens into a small request: pick a start, leave an email, send -->
    <div class="frame" data-frame>
      <div class="mover" data-mover>
        <p class="stato" data-stato aria-live="polite">
          <svg class="cal" viewBox="0 0 16 16" aria-hidden="true">
            <rect x="2.2" y="3.2" width="11.6" height="10.4" rx="2.2"/>
            <path d="M2.2 6.6h11.6M5.4 1.8v2.6M10.6 1.8v2.6"/>
            <path class="cal__tick" data-caltick pathLength="1" d="M5.6 10.2l1.7 1.6 3.2-3.4"/>
          </svg>
          <span class="stato__box">
            <span class="stato__l" data-st="0">Available from <b data-from>Jan 12</b></span>
            <span class="stato__l" data-st="1" aria-hidden="true">Request sent · starting <b data-from2>Jan 12</b></span>
          </span>
        </p>

        <button class="pill" type="button" data-pill aria-haspopup="dialog" aria-expanded="false">
          <span class="pill__fondo" aria-hidden="true"></span>
          <span class="pill__vista">
            <span class="pill__l" data-pl="0">
              <span>Hire me</span>
              <svg class="arrow" viewBox="0 0 16 16" aria-hidden="true"><path d="M3.5 8h8.6M8.6 4.4 12.2 8l-3.6 3.6"/></svg>
            </span>
            <span class="pill__l" data-pl="1" aria-hidden="true">
              <svg class="ok" viewBox="0 0 16 16" aria-hidden="true"><path data-oktick pathLength="1" d="M3.6 8.3l2.8 2.7 6-6.2"/></svg>
              <span>Requested</span>
            </span>
          </span>
        </button>

        <div class="panel" data-panel role="dialog" aria-label="Request a project start" aria-hidden="true">
          <div class="panel__in" data-in>
            <header class="head">
              <span class="ava" aria-hidden="true">IO</span>
              <span class="head__t">
                <span class="head__name">Iris Okafor</span>
                <span class="head__sub">Product designer · Lisbon</span>
              </span>
              <button class="x" type="button" data-close aria-label="Close" tabindex="-1">
                <svg viewBox="0 0 16 16" aria-hidden="true"><path d="M4.5 4.5l7 7M11.5 4.5l-7 7"/></svg>
              </button>
            </header>

            <p class="lab" id="lab-start">Earliest start</p>
            <div class="chips" role="radiogroup" aria-labelledby="lab-start" data-chips>
              <span class="chips__sel" data-sel aria-hidden="true"></span>
              <button class="chip" type="button" role="radio" aria-checked="true" data-chip="Jan 12" tabindex="-1">Jan 12</button>
              <button class="chip" type="button" role="radio" aria-checked="false" data-chip="Feb 2" tabindex="-1">Feb 2</button>
              <button class="chip" type="button" role="radio" aria-checked="false" data-chip="Mar 1" tabindex="-1">Mar 1</button>
            </div>

            <label class="lab" for="mail">Your email</label>
            <div class="field" data-field>
              <svg class="field__ico" viewBox="0 0 16 16" aria-hidden="true"><rect x="2" y="3.6" width="12" height="8.8" rx="1.8"/><path d="M2.6 4.6 8 8.6l5.4-4"/></svg>
              <input id="mail" type="email" inputmode="email" autocomplete="email" placeholder="you@studio.com" data-mail tabindex="-1">
            </div>
            <p class="hint" data-hint aria-live="polite"></p>

            <div class="slot">
              <button class="send" type="button" data-send tabindex="-1">
                <span class="send__l" data-sl="0">Send request</span>
                <span class="send__l" data-sl="1" aria-hidden="true">Sending</span>
                <span class="send__run" data-run aria-hidden="true"></span>
              </button>
              <p class="done" data-done aria-hidden="true">
                <span class="done__ok" aria-hidden="true"><svg viewBox="0 0 16 16"><path data-donetick pathLength="1" d="M3.8 8.3l2.7 2.6 5.7-6"/></svg></span>
                <span>Request sent · I’ll reply within a day</span>
              </p>
            </div>
          </div>
        </div>
      </div>
    </div>
  </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.

34 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 “Hire me button” 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

The Hire me button of the portfolio of Iris Okafor, a product designer in Lisbon: a black pill with an arrow and above it the availability line with a calendar. The pill sits in the middle; when the request opens everything rises as much as needed for pill and panel to be centred together. The panel is born from a slit as wide as the pill and widens with a clip; inside, the header with the initials, three start dates with the white puck springing onto the chosen one, the email field lighting up and «Send request». If the email is missing or wrong the field turns red, shakes by four pixels and a line says what is missing. Once sent, a line runs inside the button, then in its place comes «Request sent · I’ll reply within a day» with the tick drawing itself; closing, the pill says «Requested» with a tick and the line above «Request sent · starting» with the chosen date. It plays by itself and starts again after six seconds without touches.

How it works

Two labels out of the flow

Hire me and Requested, like Send request and Sending, sit on top of each other with position absolute, inset 0 and their own centring: the hidden label cannot widen the pill, and the visible one stays centred in every state.

A frame as big as the request

The frame already has the height of the open request; closed, the whole group moves down by half the panel, so the pill sits in the middle; opening, it goes back to zero with expo.out while the panel widens.

The sliding puck

The white puck is a single element behind the three dates: it slides to the chosen date’s offsetLeft with an elastic, and the chosen date squeezes to 0.94 and back.

The confirmation

Send request presses, its label makes way for Sending and a line runs along the bottom with a pause halfway; then the button disappears and the confirmation arrives in the same cell, with the tick drawn by stroke-dashoffset.

Values to change

NameFileDefaultWhat it changes
OPEN_TIMEscript.js0.55Seconds the request takes to unfold under the pill.
SPRINGscript.js0.65How springy the pill, the dates and the buttons are (lower means more bounce).
SEND_TIMEscript.js1.1Seconds Send request works before the confirmation.
TYPE_SPEEDscript.js16Letters per second of the email writing itself in the tour.
LIFTscript.js1Pixels the pill rises on hover.
AUTO_PAUSEscript.js6Seconds without touches before the tour starts again by itself.

Try them in the Playground

When to use it

At the end of a freelancer’s portfolio, on a small studio’s contact page, anywhere the call to action is «let’s work together» and people need to know from when.

On phones

Sizes are in em and depend on both the width and the height of the window, so the open request fits the short box; positions are measured again when the window changes. A tap works like a click; the hover lift only exists with a mouse.

With reduced motion

No springs, clips or movement: the request fades in and out, the email arrives whole, the confirmation and the ticks are already drawn.

Pitfalls

  • Each button’s two labels go out of the flow: in the same cell the longer hidden label would widen the button and the visible one would no longer be centred.
  • The clip the panel grows from has to be measured on every opening: with a changing window, an old measure would grow the panel off to the side.
  • Move the puck with the date’s offsetLeft, not with percentages: GSAP does not read percentages back from the CSS.

Libraries

GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.

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

Testing

Tested on 29 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 components