uibrik

OTP Input

Preview

Customize

Scramble tick45ms
Lock stagger90ms
Hold1300ms

Usage

import { OTPInput } from "@/components/uibrik/otp-input/otp-input";

<OTPInput />

Installation

npx shadcn@latest add https://uibrik.com/r/otp-input.json
Adds the files to components/uibrik/otp-input and installs figma-squircle and motion. With the @uibrik namespace set up: npx shadcn@latest add @uibrik/otp-input.

Props

OTPInput
label
Type string
"Verification Code"
Heading above the boxes.
correctCode
Type string
"123456"
The six-digit code that passes.
scrambleSpeed
Type number
45
Milliseconds between scramble frames.
lockStagger
Type number
90
Milliseconds between letters locking in.
holdDuration
Type number
1300
How long the result shows before resetting.