
The star rating
Ratings, SVG, Hover
One button, one sign, in the simple style of product interface pieces: the black «Stop generating» pill of an AI chat, with the stop square inside a thin ring that spins while the answer is being written. On tap the ring brakes, closes into a full circle, goes a hair past the top and settles; the square tips into the play triangle and «Continue» arrives. On a second tap the ring opens again from nothing and spins up.
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>
<!--
"Stop generating 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>The Stop generating button with the ring that brakes</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>
<!-- one button, one sign: the ring that spins while the AI writes brakes, closes and the square turns into a play sign -->
<button class="stop" type="button" data-stop aria-pressed="false" aria-label="Stop generating">
<span class="stop__body" data-body>
<svg class="stop__icon" viewBox="0 0 32 32" aria-hidden="true">
<circle class="stop__track" cx="16" cy="16" r="12"/>
<g data-spin>
<circle class="stop__ring" data-ring cx="16" cy="16" r="12" transform="rotate(-90 16 16)"/>
</g>
<path class="stop__glyph" data-glyph d="M12.2 12.2 L19.8 12.2 L19.8 19.8 L12.2 19.8 Z"/>
</svg>
<span class="stop__label" aria-hidden="true">
<span class="stop__word" data-word="on">Stop generating</span>
<span class="stop__word" data-word="off">Continue</span>
</span>
</span>
</button>
</main>
<script src="https://cdn.jsdelivr.net/npm/gsap@3.15.0/dist/gsap.min.js"></script>
<script src="script.js"></script>
</body>
</html>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.
14 values to change
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 “Stop generating button” from Animorio and fit it into my siteThe arc is an SVG circle with stroke-dasharray: its length and the group’s rotation live in one object, and a single function redraws them. That way the same ring can spin, breathe, brake and close without the tweens stepping on each other.
On tap the two endless tweens (the turn and the breath) stop and the rotation goes to the first multiple of 360 degrees at least 200 degrees away, plus six, with power3.out: it slows down like a wheel. Then it comes back six degrees with power2.inOut, the hair past and the settle; meanwhile the arc stretches into the full circle.
The sign is a four-point path: the triangle repeats its tip point, so GSAP interpolates the d attribute number by number. With back.out the triangle goes a pixel too far and comes back; a rounded stroke in the same colour softens the corners of both.
On the second tap the arc starts again from zero length at the top, and the turn’s timeScale goes from 0 to 1 with power2.in: the ring speeds up instead of starting at full speed.
The old word rises and leaves before the new one arrives, which comes up from below with the wdth axis at 75 and the weight at 420 and lands at 100 and 560 with back.out. The pill’s width follows the new word, measured in its final shape.
| Name | File | Default | What it changes |
|---|---|---|---|
ACCENT | script.js | #7b6cff | The colour of the spinning ring. |
LABEL_ON | script.js | Stop generating | The word while the answer is being written. |
LABEL_OFF | script.js | Continue | The word once it has stopped. |
TURN | script.js | 1.1 | How many seconds one turn of the ring takes. |
SPRING | script.js | 1 | How springy the press and the sign are: 0.4 calm, 2 very bouncy. |
SPEED | script.js | 1 | The speed of everything: 2 twice as fast, 0.5 half. |
HOLD | script.js | 2.2 | How many seconds each state stays when the button plays by itself. |
AUTO | script.js | true | The button plays the gesture by itself until someone touches it. |
For the button that stops an AI assistant’s answer, or any long job that can be interrupted and resumed: the braking ring says it has really stopped, the play sign says it can start again.
On the phone the pill and the icon take their size from the screen (clamp on the shorter side); there is no hover, everything else is the same.
The ring stays still and fades out, the square and the triangle swap with a fade, and so do the words; the pill takes its new width at once.
GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.
Compressed with gzip, the three demo files weigh 4.5 KB; the libraries: GSAP 28 KB.
Tested on 31 October 2026
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.
Support Animorio
Animorio stays free thanks to the people who support it. If you like, buy us a coffee: it helps us make the next animations.
You asked for
We made it for you: it’s in the library, with the preview, the Playground and the code to copy.
An animation you can’t find, or a site to take apart in the journal: tell us which. We pick the next ones from here.
With your account’s email and password.
or with your email
You’re signed in as .
With your account, you can download the zip of every animation and every pack, for free.