From 80afd673fd24c2ddddf5483911ca3b82d0df9367 Mon Sep 17 00:00:00 2001 From: joaocosta9 Date: Mon, 15 Dec 2025 16:42:25 +0000 Subject: [PATCH] otp fix --- components/form/index.tsx | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) 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 || (