-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
style(frontend): activity incomplete transaction list #3700
base: main
Are you sure you want to change the base?
style(frontend): activity incomplete transaction list #3700
Conversation
…ity-incomplete-transaction-list # Conflicts: # src/frontend/src/lib/components/transactions/AllTransactions.svelte
…ity-incomplete-transaction-list
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we add a test as well?
</script> | ||
|
||
<div class="flex flex-col gap-5"> | ||
<PageTitle>{$i18n.activity.text.title}</PageTitle> | ||
|
||
{#if tokenList} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tokenList
is never undefined, what's the goal of this check?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This check will return false if the tokenList
is undefined
, null
or empty
. If no token were found than the tokenList
will be empty and the MessageBox will not be displayed. It works as expected.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@peterpeterparker
But your test is wrong. The tokenList
is not an array but the list of the tokens as string
. It is an empty string.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ahhh my bad! Sorry!
Nitpick then: can you use notEmptyString(tokensList)
/** | ||
* All user-enabled tokens matching the selected network or chain fusion that do not have an index canister. | ||
*/ | ||
export const enabledNetworkTokensWithoutIndexCanister: Readable<Token[]> = derived( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
-
Is there plan to reuse this information anywhere else? If not, I would scope the information to the component. I think a lean approach about adding new stores is for the best given our performance issues.
-
Why considering ETH and BTC? Should you just iterate on
enabledIcrcTokens
orenabledIcrcTokensNoCk
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@peterpeterparker
No, at the moment it is not planed to reuse it anywhere else. I guess you are right, i should move the implementation into the component.
Why not? Isn't it possible that an ETH or BTC does not have an Index canister?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, at the moment it is not planed to reuse it anywhere else. I guess you are right, i should move the implementation into the component.
I would say let's do that if that works for you?
Isn't it possible that an ETH or BTC
Canisters only existing on the Internet Computer that's why I'm wondering why we are considering Ethereum and Bitcoin, unless e.g. ckBTC or ckETH are listed explicitely within this derived stores but, I don't think it's the case?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@peterpeterparker
That's ok for me, i just moved the implementation into the component.
Hmm, i guess you are right.
…ity-incomplete-transaction-list # Conflicts: # src/frontend/src/lib/components/transactions/AllTransactions.svelte
Motivation
On the activity page we want to show a disclaimer to the user if he has active tokens that do not have an index canister yet. The disclaimer should list all affected tokens.
Changes
Tests
before:
after:
oisy-wallet-incomplete-transaction-list-new.mp4