Glass button
controlsProA glass lens in a bevel that magnifies whatever sits behind it, with a pointer-following highlight and a one-pixel press.
Introductory price until 31 December 2026. €79 after that.
Preview
Live demo. The theme switches the demo itself.
Code
The code is locked
Glass button is part of Manniche UI Pro. A key unlocks the source of all 66 effects.
Buy · €49€49 · Introductory price until 31 December 2026. €79 after that.
- One-off payment
- One developer
- Sign in and create your key straight away
- No VAT (§ 19 UStG)
Have a key? Get the code with the CLI or MCP.
The key lives in MANNICHE_PRO_KEY, never in your code or a URL. How to set it up
npx shadcn@latest add @manniche-pro/glass-buttonclaude mcp add --transport http manniche-ui https://mikkelmanniche.dk/api/mcp --header "Authorization: Bearer $MANNICHE_PRO_KEY"Props
GlassButtonProps
| Prop | Type | Default | What it does |
|---|---|---|---|
backdrop | ReactNode | – | What sits behind the button, drawn in currentColor. It shows round the button in the muted colour and again, magnified, inside the lens. It is drawn twice, so keep it decorative: both copies are aria-hidden and inert. Leave it out for plain glass. |
backdropClassName | string | – | Classes for the backdrop layer, which is absolutely positioned in the wrapper. |
containerClassName | string | – | Classes for the wrapper round the backdrop and the button, e.g. flex w-full justify-center to give the backdrop room. |
magnify | number | 1.3 | How much the lens magnifies the backdrop. |
Also takes every prop from ButtonHTMLAttributes<HTMLButtonElement>.
A11y
Keyboard
Enter and Space show the pressed state and click the button.
Screen reader
The backdrop copies and the lens are inert and aria-hidden. Only the real label is read, once.
Reduced motion
Under reduced motion the moving highlight is hidden.