UNPKG

@start-base/react-form-elements

Version:

Simplify form elements and form management. Selection of user friendly inputs and wide customization abilities to match your design and functionality.

32 lines (29 loc) 892 B
import React from 'react'; import { FieldError } from 'react-hook-form'; interface OTPInputProps { name: string; length: number; onChange: (event: { target: { name: string; value: string; }; }) => void; format?: number[] | null; separator?: string | React.ReactElement | null; timer?: number | null; onComplete?: () => void; onResend?: () => void; value?: string; error?: boolean | string | { message?: string; } | null | undefined | FieldError; label?: string | null; resendLabel?: string; inputClassName?: string; labelClassName?: string; errorClassName?: string; disabled?: boolean; } declare const OTPInputComponent: React.ForwardRefExoticComponent<OTPInputProps & React.RefAttributes<HTMLInputElement>>; export { type OTPInputProps, OTPInputComponent as default };