diff --git a/app/src/components/ui/number-input.tsx b/app/src/components/ui/number-input.tsx index 748fd03..0367985 100644 --- a/app/src/components/ui/number-input.tsx +++ b/app/src/components/ui/number-input.tsx @@ -17,7 +17,8 @@ const NumberInput = React.forwardRef( ({ className, type, ...props }, ref) => { const [value, setValue] = useState(props.value.toString()); useEffect(() => { - if (getValue(props.value.toString()) !== props.value) { + // fix life cycle: update value when props.value changed + if (getValue(value.toString()) !== props.value) { setValue(props.value.toString()); } }, [props.value]);