Skip to content
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

fix(frontend): do not show token logo in token transaction page #3579

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

AntonioVentilii
Copy link
Collaborator

@AntonioVentilii AntonioVentilii commented Nov 15, 2024

Motivation

I don't have a better idea: the token logo was being showed in token-specific transaction page, because it is given as input and it is required in components like BtcTransaction or EthTransaction.

However, that same component is needed for the unified transactions (example PR #3570) with the token logo.

So, the only idea I had was to make it so by default the component show the token logo, but not under request (for example in the token-specific transaction page).

@AntonioVentilii AntonioVentilii marked this pull request as ready for review November 15, 2024 10:34
@AntonioVentilii AntonioVentilii requested a review from a team as a code owner November 15, 2024 10:34
@AntonioVentilii AntonioVentilii marked this pull request as draft November 15, 2024 10:36
@AntonioVentilii AntonioVentilii marked this pull request as ready for review November 15, 2024 15:41
Copy link
Member

@peterpeterparker peterpeterparker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thx

@@ -31,7 +32,7 @@
<span class="inline-block first-letter:capitalize"><slot /></span>

<div slot="icon">
{#if nonNullish(token)}
{#if nonNullish(token) && !hideTokenLogo}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The token is mandatory now, I guess we can remove nonNullish(token)?

@@ -18,6 +18,7 @@
export let timestamp: number | undefined;
export let styleClass: string | undefined = undefined;
export let token: Token;
export let hideTokenLogo = false;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another option is something like as following

export let badge: "token" | "logo" = "logo";

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants