Skip to content

Commit

Permalink
chore(bridge-ui-v2): clean amount warning when left bridge page (#14704)
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaodino authored and KorbinianK committed Sep 28, 2023
1 parent 674640d commit 4ed5cc6
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/bridge-ui-v2/src/components/Bridge/Amount.svelte
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<script lang="ts">
import { onDestroy } from 'svelte';
import { t } from 'svelte-i18n';
import { formatUnits, parseUnits } from 'viem';
Expand Down Expand Up @@ -36,6 +37,10 @@
let inputBox: InputBox;
let computingMaxAmount = false;
onDestroy(() => {
clearAmount();
});
// Public API
export function clearAmount() {
inputBox.clear();
Expand Down

0 comments on commit 4ed5cc6

Please sign in to comment.