Skip to content

Commit 5ae612b

Browse files
committed
fix: comment
1 parent 592057b commit 5ae612b

File tree

1 file changed

+3
-1
lines changed
  • packages/neuron-ui/src/components/DepositDialog

1 file changed

+3
-1
lines changed

packages/neuron-ui/src/components/DepositDialog/index.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,8 @@ const DepositDialog = ({
117117
setIsTyping(true)
118118
}, [setIsTyping])
119119

120+
const inputValue = useMemo(() => maxDepositValue ?? depositValue, [maxDepositValue, depositValue])
121+
120122
return (
121123
<Dialog
122124
show={show}
@@ -160,7 +162,7 @@ const DepositDialog = ({
160162
className={styles.depositValue}
161163
width="100%"
162164
field="depositValue"
163-
value={isTyping ? maxDepositValue ?? depositValue : localNumberFormatter(maxDepositValue ?? depositValue)}
165+
value={isTyping ? inputValue : localNumberFormatter(inputValue)}
164166
onChange={onChangeDepositValue}
165167
onBlur={handleBlur}
166168
onFocus={handleFocus}

0 commit comments

Comments
 (0)