From 6f50d4c3f3526641224130e6acb8d7f9e5dd03c2 Mon Sep 17 00:00:00 2001 From: Jacob Paris Date: Sat, 12 Oct 2024 15:17:11 +0800 Subject: [PATCH] fix: optional ref on input --- app/components/ui/input.tsx | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/app/components/ui/input.tsx b/app/components/ui/input.tsx index 57fe370e..d5e888c3 100644 --- a/app/components/ui/input.tsx +++ b/app/components/ui/input.tsx @@ -3,16 +3,11 @@ import * as React from 'react' import { cn } from '#app/utils/misc.tsx' export interface InputProps - extends React.InputHTMLAttributes {} + extends React.InputHTMLAttributes { + ref?: React.RefObject +} -const Input = ({ - ref, - className, - type, - ...props -}: InputProps & { - ref: React.RefObject -}) => { +const Input = ({ ref, className, type, ...props }: InputProps) => { return (