Component packs › Odo › Slot Roll

Slot Roll

The reels spin to a blur, then stop one by one from the left, each landing a touch past its digit and rocking back.

Slot Roll is a reveal from Odo, a component pack with 6 number counters: Number counters on physical wheels: they carry like gears, spin through big jumps and settle. Price: $2 for the whole pack.

Built with: staggered stops, decelerate into the digit, announced when settled.

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.

Slot Roll props

PropTypeDefaultDescription
codestring"4827"Starting code, digits only. Default "4827".
labelstring"Locker code"Caption over the reels. Default "Locker code".
buttonstring"New code"Button text. Default "New code".
onDone(code: string) => void

Methods on the ref

Use it in React

import SlotRoll from './SlotRoll';

<SlotRoll />

The Vue, HTML, Next.js, Tailwind and Motion versions take the same options.

More in Odo

Good for: Number counters.