Skip to content

Commit

Permalink
fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
gguio committed Sep 11, 2024
1 parent 7ee8d8e commit 5de334a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/react/Input.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ interface Props extends React.ComponentProps<'input'> {
export default ({ autoFocus, rootStyles, inputRef, validateInput, defaultValue, ...inputProps }: Props) => {
const ref = useRef<HTMLInputElement>(null!)
const [validationStyle, setValidationStyle] = useState<CSSProperties>({})
const [value, setValue] = useState(defaultValue ?? inputProps.value ?? '')
const [value, setValue] = useState(defaultValue ?? '')

useEffect(() => {
setValue(inputProps.value === '' || inputProps.value ? inputProps.value : value)
Expand Down

0 comments on commit 5de334a

Please sign in to comment.