-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support rendering pending transactions (#3839)
# Motivation When converting BTC to and from ckBTC, it takes a while before the transaction on one network results in a transaction on the other network. We want to render this as a "pending" transaction, which should look like this: <img width="750" alt="image" src="https://github.com/dfinity/nns-dapp/assets/122978264/e15b1f29-90b3-4333-a1fd-a9d45d7f3528"> # Changes 1. Add a field `isPending` to the type `UiTransaction`. 2. Make the field `timestamp` optional in `UiTransaction`. Since pending transaction haven't happened yet, they don't have a timestamp. 3. In `TransactionCard` make the icon orange, by adding class `pending`, when the transaction is pending. 4. In `TransactionCard` don't render a timestamp if it's absent, and render "Pending..." if it's pending. 5. Add `isPending: false` to existing instances. # Tests 1. Add a unit test for rendering a pending transaction. 2. Test that a non-pending transaction does not have a pending icon. 3. Add `hasPendingIcon` to page object. # Todos - [ ] Add entry to changelog (if necessary). will add when it's used
- Loading branch information
Showing
12 changed files
with
61 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters