Otp input

OTP input component for entering one-time passwords and verification codes. Renders a series of single-digit input boxes that automatically advance focus as the user types.

Contents

Enter any code to trigger error

Inputs
codeLength ?: number = 6

Code length is the number of digits in the code.

hasError ?: boolean = false
isDisabled ?: boolean = false
size ?: OtpInputSize = OtpInputSize.MID

Determines the size of the input.

spacing ?: OtpInputSpacing = OtpInputSpacing.AUTO

Determines the spacing between the input digits.

Outputs
codeComplete ?: any = new EventEmitter<string>()

Emits when the code is complete.

errorCleared ?: any = new EventEmitter<void>()

Emits when the error state is cleared.