Getting Started
AI-Assisted Development
Governance
Components
Search for a command to run or a page to navigate to.
Input OTP provides an accessible and user-friendly way to collect verification codes, PINs, or other numeric sequences. It automatically manages focus between input slots, supports paste functionality, and provides clear visual feedback for the current input position.
import { InputOtp } from "@strongtie/design-system/input-otp"This module exports the following components:
InputOTPInputOTPGroupInputOTPSlotInputOTPSeparator<InputOTP>| Prop | Type | Default | Description |
|---|---|---|---|
maxLength * | number | - | |
containerClassName | string | - | |
noScriptCSSFallback | string | null | - | |
onChange | ((newValue: string) => unknown) | - | |
onComplete | ((...args: any[]) => unknown) | - | |
pasteTransformer | ((pasted: string) => string) | - | |
pushPasswordManagerStrategy | none | increase-width | - | |
render | InputOTPRenderFn | - | |
textAlign | center | left | right | - | |
value | string | - |
<InputOTPSlot>| Prop | Type | Default | Description |
|---|---|---|---|
index * | number | - |
import { InputOtp } from "@strongtie/design-system/input-otp"
export default function Example() {
return <InputOtp>{/* Your content here */}</InputOtp>
}Components can be styled using the className prop. The design system uses Tailwind CSS for styling.
CSS classes used by this component:
input-otpinput-otp-groupinput-otp-separatorinput-otp-slotEnsure proper accessibility attributes are added when implementing this component.