fix(assets): stop token rows overflowing the Assets card#295
Merged
Conversation
Long token names ($drep.collective) and raw quantities pushed the value/ticker past the card's right edge (the clipped "↗1 $S…"). Root cause: the flex row + left group had no min-w-0, so text couldn't shrink, and the name/quantity/ticker were never truncated. - min-w-0 on the row + flex-1 min-w-0 on the left group (lets text shrink). - 60px avatar wrappers flex-shrink-0 (so the image never compresses instead). - name h3 truncates (+ title tooltip) and is bounded via truncateTokenSymbol for the raw-unit hex fallback; remove ml-auto from the link. - value block flex-shrink-0; quantity via numberWithCommas (tabular-nums); ticker truncates with a max width + title. Full name stays reachable via tooltip + the Cardanoscan token link. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Assets card clipped token rows on the right (the cut-off "↗1 $S…" for
$drep.collective).Root cause (verified): the token row's flex row + left group lacked
min-w-0, so the name/quantity/ticker couldn't shrink below their intrinsic width, and none were truncated — long names/quantities pushed the value column past the card edge. (ADA renders fine because its name is the hardcoded "ADA".)Fix —
wallet-assets.tsxtoken rowmin-w-0on the row,flex-1 min-w-0on the left group (the actual fix — a flex child can't shrink below content width withoutmin-w-0).flex-shrink-0on both 60px avatar wrappers (so the image doesn't compress instead of the text).<h3>truncates with atitletooltip and is bounded viatruncateTokenSymbolfor the raw-hex fallback; removedml-auto.flex-shrink-0; quantity vianumberWithCommas+tabular-nums; ticker truncatesmax-w-[80px]with atitle.Full name still reachable via tooltip + the Cardanoscan token link (deep-link uses the policyId, unaffected).
Verify
tscclean.Part of the governance/assets UX pass (map→design→judge workflow). Sibling PRs: ballot voting controls + gov-card colored chips.
🤖 Generated with Claude Code