Slosh Button
buttonProEn knap af frostet glas med ægte vandfysik for lavt vand indeni: træk med markøren, hover og klik får vandet til at skvulpe og sprøjte, brydende bølgetoppe sender dråber afsted, og simuleringen sover, når alt er roligt.
Introduktionspris til og med 31. december 2026. Derefter 79 €.
Preview
Live demo. Temaet skifter selve demoen.
Kode
Koden er låst
Slosh Button er en del af Manniche UI Pro. En nøgle åbner kildekoden til alle 66 effekter.
Køb · 49 €49 € · Introduktionspris til og med 31. december 2026. Derefter 79 €.
- Engangsbetaling
- Én udvikler
- Log ind og opret din nøgle med det samme
- Ingen moms (§ 19 UStG)
Har du en nøgle? Hent koden med CLI eller MCP.
Nøglen ligger i MANNICHE_PRO_KEY, aldrig i koden eller i adressen. Sådan sætter du den op
npx shadcn@latest add @manniche-pro/slosh-buttonclaude mcp add --transport http manniche-ui https://mikkelmanniche.dk/api/mcp --header "Authorization: Bearer $MANNICHE_PRO_KEY"Props
SloshButtonProps
| Prop | Type | Standard | Hvad den gør |
|---|---|---|---|
waterColor | string | 'var(--primary)' | Water colour. Any CSS colour, including var(--x). Defaults to the theme's --primary; re-read when the theme changes. |
fill | number | 0.3 | How full the glass is at rest, from 0.05 (a puddle) to 0.9 (nearly full). |
waterOpacity | number | 0.85 | Water opacity, from 0.2 to 1. |
tint | string | 'color-mix(in oklab, currentColor 6%, transparent)' | Glass tint: the fill behind the water. Any CSS colour or var(). Defaults to a faint wash of the text colour. |
frost | number | 0.5 | How frosted the glass looks, from 0 (clear) to 1 (milky). It adds a soft white sheen over the water. |
blur | number | 10 | Background blur behind the glass, in CSS pixels. 0 turns it off. |
borderColor | string | 'color-mix(in oklab, currentColor 18%, transparent)' | Border colour. Any CSS colour or var(). Defaults to a hairline of the text colour. |
borderWidth | number | 1 | Border width in CSS pixels. |
shadow | string | '0 10px 30px -12px color-mix(in oklab, currentColor 35%, transparent)' | Box shadow of the glass. Any CSS box-shadow value. |
pressScale | number | 0.97 | Scale while pressed, from 0.9 to 1. 1 turns the press feedback off. |
splash | number | 1 | How strongly the pointer and clicks disturb the water. 1 is natural, 0 makes it inert. |
spray | number | 1 | How readily crests tear off droplets. 0 turns the spray off, 1 is natural, 2 is stormy. |
viscosity | number | 0.4 | How quickly waves die down, from 0 (water that keeps sloshing) to 1 (syrup). |
meniscus | number | 3 | Height in px of the little climb the water makes against the glass walls. 0 gives a flat edge. |
ref | Ref<HTMLButtonElement> | – | Ref to the real <button>. |
Tager også alle props fra Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'color'>.
A11y
Tastatur
Enter and Space click the button and splash the liquid.
Skærmlæser
The liquid canvas is aria-hidden. The label is plain text in the button.
Mindre bevægelse
Under reduced motion the surface is calm. Otherwise the simulation sleeps while the button is off screen.