Skip to content

No.45 · Buttons

Stack Button

An add-to-bag button where the quantity is physical: every press slides another sheet out from behind it, and removing one peels the top sheet away.

The prompt

Written for the variant you picked above: Warm

Design an add-to-bag button whose quantity is shown as a physical stack rather than a badge. The button is a 52px-tall, 14px-radius slab (tone-coloured, inset top highlight) holding the label in Hanken 15px/600 and a small tabular count chip in the accent colour. Behind it, draw one 'sheet' per item: the same rounded shape inset 6px on each side, a subtle top-lit gradient, a 1px highlight and a short shadow. Sheet i sits (i+1)×5px higher than the button, is scaled down by 1.2% per level, and leans by a fixed, deterministic angle from a table (−1.3°, 0.9°, −0.5°, 1.4°…) around its bottom centre — so the stack always looks the same and reads as hand-stacked. The wrapper's top padding grows with the count (480ms expo-out) so the stack never overlaps what's above. Draw at most six sheets; the count keeps going. Pressing the button slides a new sheet up out from behind it (from translateY 0 and 0.96 width to its slot, 520ms cubic-bezier(0.16,1,0.3,1)) and rolls the digit up. Once the count is above zero, a minus segment slides open on the left (width 0 → 44px). Removing an item peels the top sheet off: it rises 26px, drifts right, rotates a further 7° and fades on an ease-in curve. Selected variant — Warm: Warm tone (default): a warm near-black slab (#1b1714) with an amber count chip, "Add to bag" starting at 1, on #0c0b0a; caption "Stoneware cup · €24 each".

Notes

Interaction
Press to add one; the minus segment (appears once there's something to remove) peels the top sheet off.
Motion
520ms expo-out slide-up per sheet with a fixed lean table; 520ms ease-in peel; 380ms digit roll; minus segment width 420ms.
Accessibility
Two real buttons (add, 'Remove one'); the count is announced politely ('3 in bag'); the stack is aria-hidden. Visible focus rings; reduced motion shows the stack without the slide/peel.
Responsive
Intrinsic width; the stack grows upward inside its own padding so nothing overlaps.
On touch
Plain taps; press state nudges the label 1px. Tap highlight suppressed.

Featured

301 components