Skip to content

Commit 83abea0

Browse files
authored
Update input value when click switch button swap page (#2403)
1 parent 9323de7 commit 83abea0

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/components/SwapForm/index.tsx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,12 @@ const SwapForm: React.FC<SwapFormProps> = props => {
245245
)}
246246
</PriceAlertButton>
247247
)}
248-
<ReverseTokenSelectionButton onClick={() => currencyIn && onChangeCurrencyOut(currencyIn)} />
248+
<ReverseTokenSelectionButton
249+
onClick={() => {
250+
currencyIn && onChangeCurrencyOut(currencyIn)
251+
routeSummary && onUserInput(routeSummary.parsedAmountOut.toExact())
252+
}}
253+
/>
249254
</Flex>
250255
</AutoRow>
251256

0 commit comments

Comments
 (0)