Skip to content

fix(wallet): short-stack overlap, and a token icon for rows with no counterparty - #1368

Merged
bmc08gt merged 2 commits into
code/cashfrom
fix/wallet-stack-overlap-and-activity-avatars
Aug 28, 2026
Merged

fix(wallet): short-stack overlap, and a token icon for rows with no counterparty#1368
bmc08gt merged 2 commits into
code/cashfrom
fix/wallet-stack-overlap-and-activity-avatars

Conversation

@bmc08gt

@bmc08gt bmc08gt commented Aug 28, 2026

Copy link
Copy Markdown
Collaborator

Two wallet-screen fixes from the same session.

"Recent" drew over a short card stack

TokenCardStack reports its fanned height and only re-places cards as the list
scrolls, so nothing may be placed below that height. collapseComplete — the cap
on how far the deck pins — is what enforces it: at the cap, the last card lands
exactly on its fanned slot. Clamping the cap at 0 broke that whenever the fanned
slack is smaller than pinInset. A single card has no slack at all, so the cap
became 0 rather than -88dp and the front card was placed 88dp (status bar plus
8dp) below the item's own top, under the "Recent" header that follows it.

The clamp is gone. A negative cap simply means no card pins, which is right when
there is nothing to collapse.

TokenCardStackPlacementTest renders 1, 2 and 5 cards scrolled well past full
collapse and asserts every card stays inside the stack's bounds; the 1- and
2-card cases fail without the fix.

Rows with no counterparty showed a grey silhouette

A give or grab hands a bill between two devices that never exchange identities:
RequestToGrabBill carries a destination token account and nothing else. When
the server leaves destination_identifier unset too, there is no profile coming
and the row keeps the placeholder avatar forever. Those rows now draw the token's
icon, as do cash links, which carry a gift-card vault rather than a recipient.

The fallback is deliberately narrow: a payment that does name a counterparty
keeps the silhouette until the profile resolves, so a slow profile fetch never
settles on a token icon.

`collapseComplete` caps how far the deck pins as the list scrolls. At that cap
the last card lands exactly on its fanned slot, which is what keeps every card
inside the stack's measured (fanned) height. Clamping the cap at 0 broke this
whenever the fanned slack is smaller than `pinInset`: a single card has no slack
at all, so the cap became 0 rather than -88dp and the front card was placed 88dp
(status bar plus 8dp) below the item's own top, drawing over the "Recent" section
that follows it in the list.

Drop the clamp. A negative cap means no card ever pins, which is correct when
there is nothing to collapse.

The test renders 1, 2 and 5 cards scrolled well past full collapse and asserts no
card leaves the stack's bounds. The 1- and 2-card cases fail without this change.
A give or grab hands a bill between two devices that never exchange identities:
`RequestToGrabBill` carries a destination token account and nothing else. When
the server also leaves the notification's `destination_identifier` unset, no
profile is ever coming and the row keeps the generic silhouette permanently. Seen
on a USDF give-bill, which arrived as `directly_sent_crypto` with the identifier
oneof unset, while a token give-bill 22 seconds earlier carried the grabber's
user id.

Fall back to the token's icon for those rows, and for cash links, which carry a
gift-card vault rather than a recipient.

The fallback stays narrow. A payment that does name a counterparty keeps the
silhouette until the profile lands, so a slow profile fetch never settles on a
token icon.
@bmc08gt bmc08gt self-assigned this Aug 28, 2026
@github-actions github-actions Bot added the type: fix Bug fix label Aug 28, 2026
@bmc08gt
bmc08gt merged commit 908f0f6 into code/cash Aug 28, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type: fix Bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant