Component packs › Dials › Combo Lock
Three number wheels roll past with a click per digit; the right code springs the shackle open, a wrong try shakes the lock.
Combo Lock is a combination input from Dials, a component pack with 8 components: Physical controls that click: dials, wheels, rings and switches with real detents. Price: $2 for the whole pack.
Built with: rolling wheels, spring shackle, spin buttons.
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 |
|---|---|---|---|
code | string | The code that opens it (three digits). | |
value | string | ||
theme | 'dark' | 'light' | ||
sound | boolean | ||
haptics | boolean | ||
autoplay | boolean | ||
onOpen | () => void |
readonly open: booleandestroy(): voidimport ComboLock from './ComboLock';
<ComboLock />The Vue, HTML, Next.js, Tailwind and Motion versions take the same options.
Good for: Knobs and dials.