Component packs › Minted › Coin Flip Toggle
The coin is tossed across the track, turns three half turns to land on its other face and wobbles flat.
Coin Flip Toggle is a toggle from Minted, a component pack with 6 savings components: Savings and payment controls with metal coins that flip, stack, drop and pile up. Price: $2 for the whole pack.
Built with: toss arc, face from the flip, settling wobble.
Code: React and Next.js (TypeScript), Vue 3, plain HTML/CSS/JS, Tailwind CSS v4 and Motion (motion.dev). No npm packages needed. Keyboard accessible, with a reduced-motion version, in dark and light.
| Prop | Type | Default | Description |
|---|---|---|---|
checked | boolean | ||
disabled | boolean | ||
label | string | Accessible name, e.g. "Round up purchases". | |
metal | MtMetal | gold | Coin metal. Default gold. |
onChange | (checked: boolean) => void | ||
autoplay | number | false | Showcase mode: toggles itself every N ms while visible. |
readonly checked: booleansetChecked(checked: boolean, silent?: boolean): voiddestroy(): voidimport CoinFlip from './CoinFlip';
<CoinFlip />The Vue, HTML, Next.js, Tailwind and Motion versions take the same options.
Good for: Pricing and payment.