diff --git a/components/form/index.tsx b/components/form/index.tsx index fbfc9e7..64e53af 100644 --- a/components/form/index.tsx +++ b/components/form/index.tsx @@ -315,7 +315,11 @@ function Switch({ Form.Switch = Switch; interface OTPProps - extends Omit, "type"> { + extends Omit, "type" | "onChange" | "value">, + Omit< + React.ComponentProps, + "value" | "onChange" | "maxLength" | "name" | "render" + > { maxLength?: number; children?: React.ReactNode; slotClassName?: string; @@ -343,10 +347,10 @@ function OTP({ {label && {label}} field.onChange(value)} - {...(rest as any)} > {children || (