
The star rating
Ratings, SVG, Hover
The ‘Download portfolio’ button of a design studio, in graphite on black with a warm light, like a Dribbble shot: on the left a small fan of the portfolio’s pages, each with its picture and two lines of text, on the right a bone knob with the arrow. On hover the fan opens on a spring and the top page leans toward the pointer; pressed, the button downloads the PDF: the pages fall one after the other onto the pile, which gives by a pixel under each one, the ring around the knob fills and the line below counts the pages. At the end the pile squares up into a booklet, the arrow becomes a check and a reflection crosses the graphite.
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>
<!--
"Download portfolio 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 download portfolio button with the pages that stack up</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 Download portfolio button of a design studio, graphite with a warm light. On the left a small fan of the
portfolio's pages; on hover the fan opens and the arrow in the knob dips. Pressed, the button downloads: the
pages of the PDF fall one after the other onto the stack, which settles a pixel under each one, the ring
around the knob fills and the line under the label counts the pages. At the end the stack squares up into a
booklet, the arrow becomes a check and a reflection crosses the graphite -->
<div class="dp" data-wrap>
<span class="dp__spill" data-spill aria-hidden="true"></span>
<button class="dp__btn" type="button" data-btn aria-label="Download portfolio, PDF, 48 pages, 24 MB">
<span class="dp__body" data-body>
<span class="dp__skin" aria-hidden="true"></span>
<span class="dp__shine" data-shine aria-hidden="true"></span>
<span class="dp__sweep" aria-hidden="true"><span class="dp__sweep-band" data-sweep></span></span>
<span class="dp__row">
<span class="dp__stack" aria-hidden="true">
<span class="dp__pile" data-pile>
<span class="dp__page dp__page--c" data-page><span class="dp__ink"></span></span>
<span class="dp__page dp__page--b" data-page><span class="dp__ink"></span></span>
<span class="dp__page dp__page--a" data-page><span class="dp__ink"></span></span>
<span class="dp__drops" data-drops></span>
</span>
</span>
<span class="dp__text" aria-hidden="true">
<span class="dp__labels">
<span class="dp__label" data-label>Download portfolio</span>
<span class="dp__label" data-label>Downloading</span>
<span class="dp__label" data-label>Saved to Downloads</span>
</span>
<span class="dp__subs">
<span class="dp__sub" data-sub>PDF · 48 pages · 24 MB</span>
<span class="dp__sub" data-sub>Page <span class="dp__num" data-num>1</span> of <span data-total>48</span></span>
<span class="dp__sub" data-sub>halden-portfolio.pdf</span>
</span>
</span>
<span class="dp__knob" data-knob aria-hidden="true">
<svg class="dp__ring" viewBox="0 0 44 44">
<circle class="dp__ring-track" cx="22" cy="22" r="20.5"/>
<circle class="dp__ring-fill" data-ring cx="22" cy="22" r="20.5" pathLength="1"/>
</svg>
<span class="dp__well">
<svg class="dp__icon" viewBox="0 0 20 20">
<g data-arrow>
<path class="dp__arrow" d="M10 3.6v11.2M5.4 10.4L10 15l4.6-4.6"/>
</g>
<path class="dp__tray" data-tray d="M4.2 16.6h11.6"/>
<path class="dp__check" data-check pathLength="1" d="M5 10.4l3.3 3.3 6.7-7.2"/>
</svg>
</span>
</span>
</span>
</span>
</button>
</div>
<p class="sr" aria-live="polite" data-live></p>
</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.
35 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 “Download portfolio button” from Animorio and fit it into my siteThe button’s body is a single box with overflow hidden, moved only by GSAP (scale and y for the press); inside, a layer with three backgrounds (a feTurbulence grain in an SVG used as image, a warm radial-gradient in the corner, a vertical gradient) and four inner shadows for the one pixel edges; above it a radial-gradient that follows the pointer through two CSS variables moved by gsap.quickTo.
Each page is a span with the cover colour in a CSS variable, the picture box in a child and the two lines of text drawn with two linear-gradients on an ::after; another ::after makes the reflection on the paper. GSAP moves only the pages’ x, y and rotation between three poses (rest, open fan, squared booklet), with the origin at the bottom and a small delay between one and the next.
A timeline in four stretches (fast to 0.3, calmer to 0.66, almost still to 0.72, power3.in to 1) moves a single value: from it come the ring (pathLength 1 and strokeDashoffset), the page number and the moment each page falls, when the value passes its threshold.
Each new page is made in JS with a cover taken from six CSS variables, falls from 40 pixels above with power2.in landing tilted, then straightens on an elastic spring; at the same instant the pile sinks 1.2 pixels in 0.07 seconds and springs back, the glow on the floor lights up, and the next page stops half a pixel higher.
The knob has overflow hidden: while downloading a repeating timeline takes the arrow 15 pixels down, puts it back 15 above and brings it down into place, while the line under the arrow dips a little and springs back. At the end the arrow drops out, the line shrinks with scaleX and the check draws itself with pathLength 1.
| Name | File | Default | What it changes |
|---|---|---|---|
LABEL_REST | script.js | Download portfolio | The label at rest. |
LABEL_BUSY | script.js | Downloading | The label while the file comes down. |
LABEL_DONE | script.js | Saved to Downloads | The label at the end. |
FILE_INFO | script.js | PDF · 48 pages · 24 MB | The line under the label at rest. |
FILE_NAME | script.js | halden-portfolio.pdf | The line under the label at the end. |
PAGES | script.js | 48 | How many pages the counter reaches. |
DROPS | script.js | 7 | How many pages fall onto the pile during the download. |
DURATION | script.js | 3.2 | How many seconds the download takes. |
FAN | script.js | 1 | How wide the fan of pages opens on hover. |
SPRING | script.js | 1 | How springy the press and the pages are: 0.4 calm, 2 very bouncy. |
HOLD | script.js | 1.7 | How many seconds the saved state stays before going back. |
AUTO | script.js | true | The button goes round by itself until someone touches it. |
For the portfolio of a design studio, an agency, a photographer or an illustrator offering the PDF of their work as a download; it also fits a press kit, a catalogue or a lookbook. The falling pages show what is arriving, the counter how far it has gone.
On the phone the button is at most 84% of the screen wide and the label shortens with an ellipsis if needed; there is no hover, so the light under the finger turns on at the touch and the download, with the falling pages, is the same.
Nothing moves: the fan stays still, the new pages fade in on the pile, the ring fills, the labels swap in place and the check fades in where the arrow was.
GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.
Compressed with gzip, the three demo files weigh 8.2 KB; the libraries: GSAP 28 KB.
Tested on 2 November 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.