Skip to content

Commit afcb022

Browse files
committed
Fix on empty input
1 parent 0965d7a commit afcb022

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Plot/CompareRegisterHandle.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ const CompareRegisterHandle = forwardRef<CompareRegisterHandleRef, Props>(
5656
}, [setDraggingTV])
5757

5858
const onChangedInput = (val: string) => {
59-
setCompareRegisterValue(constrain(parseFloat(val), ...yExtent))
59+
setCompareRegisterValue(constrain(parseFloat(val) || 0, ...yExtent))
6060
}
6161
return (
6262
<>

0 commit comments

Comments
 (0)