Skip to content

Commit

Permalink
reset selectedNFTs when back is clicked
Browse files Browse the repository at this point in the history
  • Loading branch information
leppaludi committed Feb 25, 2024
1 parent 5f8ea2c commit 7d89ecb
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,10 @@
};
const handlePreviousStep = () => {
if (activeStep === BridgeSteps.REVIEW) {
if (activeStep === BridgeSteps.IMPORT) {
$selectedNFTs = [];
$selectedImportMethod = ImportMethod.NONE;
} else if (activeStep === BridgeSteps.REVIEW) {
activeStep = BridgeSteps.IMPORT;
} else if (activeStep === BridgeSteps.CONFIRM) {
activeStep = BridgeSteps.REVIEW;
Expand All @@ -65,7 +68,9 @@
<span class="body-bold">{nextStepButtonText}</span>
</ActionButton>

<StepBack on:click={() => ($selectedImportMethod = ImportMethod.NONE)}>{$t('common.back')}</StepBack>
<StepBack on:click={() => handlePreviousStep()}>
{$t('common.back')}
</StepBack>
{/if}
{/if}
{#if activeStep === BridgeSteps.REVIEW}
Expand Down

0 comments on commit 7d89ecb

Please sign in to comment.