Skip to content

Commit

Permalink
feat: Improve ExpirationTimePicker component (#7782)
Browse files Browse the repository at this point in the history
* refactor: improve expirationTimePicker componente

* fix:revert changes to expiration time picker

* fix: persist expiration time picker value when toggling gift storage deposit

---------

Co-authored-by: Branko Bosnic <[email protected]>
Co-authored-by: Begoña Álvarez de la Cruz <[email protected]>
  • Loading branch information
3 people authored Jan 25, 2024
1 parent 6016c99 commit ca652cd
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@
let visibleSurplus: number | undefined = undefined
let isPreparingOutput = false
$: expirationTimePicker?.setNull(giftStorageDeposit)
$: isBaseTokenTransfer =
Expand Down
3 changes: 3 additions & 0 deletions packages/shared/components/ExpirationTimePicker.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,11 @@
if (bool && value) {
storedValue = value
value = null
previouslySelectedPeriod = selectedTimePeriod
selectedTimePeriod = TimePeriod.None
} else {
value = storedValue ?? value
selectedTimePeriod = previouslySelectedPeriod
}
}
Expand Down

0 comments on commit ca652cd

Please sign in to comment.