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: handle long asset names in send input #7751

Merged
merged 7 commits into from
Sep 17, 2024

Conversation

woodenfurniture
Copy link
Member

@woodenfurniture woodenfurniture commented Sep 16, 2024

Description

Fixes text overflow of asset label in send input.

Adds a ellipsis for overflow with tooltip.'

Opted to use trimWithEndEllipsis intead of CSS ellipsis so we can predictably and simly detect an overflow render the tooltip accordingly.

Issue (if applicable)

closes #7720

Risk

High Risk PRs Require 2 approvals

Low risk - display concern only.

What protocols, transaction types, wallets or contract interactions might be affected by this PR?

Testing

Check normal length asset names are rendered correctly without a tooltip.
Check very long asset names are truncated with an ellipsis and have a tooltip with the full asset name.

Engineering

Operations

  • 🏁 My feature is behind a flag and doesn't require operations testing (yet)

Screenshots (if applicable)

Screen.Recording.2024-09-16.at.2.50.27.PM.mov

@woodenfurniture woodenfurniture marked this pull request as ready for review September 16, 2024 04:54
@woodenfurniture woodenfurniture requested a review from a team as a code owner September 16, 2024 04:54
Copy link
Contributor

@gomesalexandre gomesalexandre left a comment

Choose a reason for hiding this comment

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

Tested locally, and while name does ellipse now, there are still issues re: overflowing array as well as symbol still rugging the send display:

https://jam.dev/c/3723bfe2-5d04-472d-9fbe-1d7ff71e024c

See arrow placement/symbol rugging "Enter Amount" with long symbols vs. smolish ones:

image image

@woodenfurniture woodenfurniture force-pushed the send-input-long-ass-names branch from c2ef72b to bfc5377 Compare September 16, 2024 22:14
@woodenfurniture
Copy link
Member Author

Tested locally, and while name does ellipse now, there are still issues re: overflowing array as well as symbol still rugging the send display:

https://jam.dev/c/3723bfe2-5d04-472d-9fbe-1d7ff71e024c

See arrow placement/symbol rugging "Enter Amount" with long symbols vs. smolish ones:

image image

Well spotted, changed approach to use css variables and looking much better:

image

image

@woodenfurniture
Copy link
Member Author

Also added some overflow for amounts

image

Copy link
Contributor

@gomesalexandre gomesalexandre left a comment

Choose a reason for hiding this comment

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

Retested locally, second time's a charm!

image

Still noticing the same issue re: symbol being weird but should be much more simple to tackle separately in a follow-up :fridaydoge:

image

@gomesalexandre gomesalexandre enabled auto-merge (squash) September 17, 2024 10:38
@gomesalexandre gomesalexandre merged commit a16fcd5 into develop Sep 17, 2024
3 checks passed
@gomesalexandre gomesalexandre deleted the send-input-long-ass-names branch September 17, 2024 10:46
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.

Send input styling is borked for long asset names
2 participants