Fix fieldset fixes

This commit is contained in:
Justin Edmund 2022-01-29 18:27:29 -08:00
parent f2085c8344
commit 9073f4262f

View file

@ -9,7 +9,7 @@ interface Props {
onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void
} }
const Fieldset = (props: Props) => { const Fieldset = React.forwardRef<HTMLInputElement, Props>(function fieldSet(props, ref) {
const fieldType = (['password', 'confirm_password'].includes(props.fieldName)) ? 'password' : 'text' const fieldType = (['password', 'confirm_password'].includes(props.fieldName)) ? 'password' : 'text'
return ( return (
@ -31,6 +31,6 @@ const Fieldset = (props: Props) => {
} }
</fieldset> </fieldset>
) )
} })
export default Fieldset export default Fieldset