No.11 · Buttons
Machined Bevel Button
A button turned from metal whose bevelled rim catches the light from your pointer: the bright edge turns to face it, and pressing flips the bevel as the face sinks.
The prompt
Written for the variant you picked above: Aluminium
Build a hardware-style button: a brushed-metal face (a vertical gradient plus a 1px repeating line texture) inside a 3px bevel drawn as a border-box conic gradient — white, mid grey, dark, mid grey, white — starting from a registered --angle. At rest the light comes from the top-left (−45°). On pointer move anywhere within 360px, compute the angle from the button's centre to the pointer (atan2, +90° to match conic-gradient's zero), so the bright edge of the bevel turns to face the cursor, transitioning 260ms. On press, the angle jumps to 135° (light on the far side, as if the bevel were pressed in), the face drops 1px and gains an inset shadow. The label is engraved with a 1px highlight text-shadow. A small status LED sits before the label; the button is a toggle (aria-pressed): pressing reads 'Connected · 38 ms' and lights the LED green. Selected variant — Aluminium: theme="paper" (aluminium): a light brushed face #e9ebee → #c9cdd3 with dark engraved label #2b2f36; label "Connect device".
Notes
- Interaction
- Move the pointer around the button to see the bevel catch the light; press to connect (toggle).
- Motion
- Bevel angle follows the pointer over 260ms; press is 140ms; LED fades 200ms.
- Accessibility
- A real toggle button with aria-pressed and a label that changes with state; the LED is decorative. Keyboard press works like a click. Reduced motion removes the transitions.
- Responsive
- Intrinsic width from its label.