Skip to content

feat(you): rebuild the You tab around the tip card - #1291

Open
bmc08gt wants to merge 4 commits into
code/cashfrom
feat/you-tab-redesign
Open

feat(you): rebuild the You tab around the tip card#1291
bmc08gt wants to merge 4 commits into
code/cashfrom
feat/you-tab-redesign

Conversation

@bmc08gt

@bmc08gtbmc08gt commented Aug 20, 2026

Copy link
Copy Markdown
Collaborator

Implements the "Tip Card You Page" design (node 9216:656).

You tab

The You tab — the Menu feature under the v2 tab bar — drops its app bar and money tiles and leads with the viewer's own tip card.

  • The card renders opaque at the design's flattened fill (rgb(16,16,17)) rather than the translucent frosted fill, since nothing is behind it here.
  • A link row shows the abbreviated tip link and copies the full URL to the clipboard. The trailing icon flips to a filled checkmark for 1.5s and fades back, matching iOS.
  • Share and Download tiles sit below. Download opens a "Download As" sheet offering PNG or SVG, renders the chosen format via TipCodeExporter, and hands the file to the Sharesheet — Android has no permissionless save-to-Photos, and the chooser already surfaces Files/Drive/Photos.
  • TipCardMaxWidth is raised from 270dp to 305dp so a phone-width canvas gets the full 0.82 width fraction the design specifies (302 on a 402 frame). This also enlarges scanned tip cards slightly.

Full Screen is an in-place expansion

Tapping the card or "Full Screen" no longer navigates anywhere — it expands the card that's already on screen, matching iOS.

  • The card keeps its slot in the LazyColumn; an inner layer translates it to the display centre while the slot grows to the 302dp expanded width (node 9277:121410). Effectively a shared-element morph without a shared-element API, mirroring iOS's clear-slot + offset approach.
  • Everything else on the page fades and slides down 60dp under it; the tab bar hides through a new counted TabBarVisibilityController so overlapping callers can't uncover it.
  • Close (bottom of screen) and system back collapse it.
  • The spring is iOS's .spring(response: 0.45, dampingFraction: 0.85) converted to Compose: dampingRatio = 0.85f, stiffness = 195f.

This replaces TipCardScreen (and its content/view model) and the session-presented own-tip-card path, both of which are removed.

MenuList gained an itemModifier that wraps each row together with its sibling divider — ListItem emits the divider outside the row, so fading the list out otherwise left hairlines floating over the expanded card.

Settings

Rows are restyled to match the design — 17sp Demi headline, 24dp icon, and the trailing chevron extracted to ListItemDefaults.Chevron() so callers driving their own endSlot can reuse it. The version footer sits 44dp below the last row, matching iOS's 69dp gap.

They are also rearranged:

ScreenRows
My AccountChange Display Name, Require Biometrics (switch), Blocked
AdvancedAccess Key, Beta Features, Application Logs, Switch Accounts, Log Out, Delete Account

Access Key, Log Out and Delete Account are recovery/destructive actions rather than account details, so they move to Advanced along with their confirmation prompts and auth wiring.

Switch Accounts lives in Advanced next to the other beta tool. It keeps both of its gates — staff/beta unlock andFeatureFlag.CredentialManager, which PassphraseCredentialManager.selectCredential() hard-refuses without — and the Advanced view model now applies the staff/flag filtering it had been missing, so flag-gated rows don't flash before their flag resolves.

App Settings screen removed

The standalone App Settings screen held two toggles. Require Biometrics folded into My Account (still gated on biometric hardware, still disabled when nothing is enrolled, still prompting before the flip). Auto Start Camera is dropped outright — the camera now always auto-starts — which also removes SessionState.autoStartCamera and the now-dead CameraDisabledView branch in ScannableContainer.

The :apps:flipcash:features:appsettings module, AppRoute.Menu.AppSettings, and AppSettingValue.CameraStartByDefault are gone.

Implements the "Tip Card You Page" design (node 9216:656).
The You tab (the Menu feature under the v2 tab bar) drops its app bar and
money tiles and leads with the viewer's own tip card:
- the card renders opaque at the design's flattened fill, sits under a
"Full Screen" affordance that presents it over the camera, and the
status-bar clearance moves to the list's content padding so the card's
own inset isn't paid twice
- a copy row shows the abbreviated tip link and copies the full URL
- Share and Download tiles sit below it. Download opens a "Download As"
sheet (PNG / SVG) and hands the rendered file to the Sharesheet —
Android has no permissionless save-to-Photos, and the chooser already
offers Files/Drive/Photos
- the full-screen presentation of your own card gets a Close affordance
instead of the Send-a-Tip modal, via a new SelfTipCardDecorator
- TipCardMaxWidth is raised so a phone-width canvas gets the full 0.82
fraction the design specifies
Settings rows are restyled (17sp headline, 24dp icon, chevron extracted to
ListItemDefaults) and rearranged:
- My Account keeps the account-shaped rows — Change Display Name, Require
Biometrics, Blocked
- Access Key, Log Out and Delete Account move to Advanced, alongside Beta
Features and Application Logs
- the standalone App Settings screen is removed; its only surviving toggle
moved into My Account, and Auto Start Camera is dropped (the camera now
always auto-starts)
@github-actionsgithub-actionsBot added type: feature New functionality area: payments Payments, transfers, intents, billing area: ui Compose UI, theme, components, resources area: scanner QR/Kikcode scanning, camera area: build-system Gradle, convention plugins, build-logic area: session and removed type: feature New functionality labels Aug 20, 2026
Three fixes found on device:
* The Share / Download tiles paid 20dp of vertical padding inside a tile
whose height is already fixed at 88dp, leaving the label a 14dp box for a
16dp line and clipping its descenders. The centred arrangement was already
doing the spacing, so the padding just goes.
* "Require Biometrics" sat ~24dp taller than its neighbours: Material applies
its 48dp minimum touch target to a Switch only when onCheckedChange is
non-null, and 48dp beats the 24dp icon that sets every other row's height.
Adds ListItemDefaults.Toggle — a display-only switch pinned to the icon size
— and uses it there; the row's own onClick already ran the toggle, and it
still does when you tap the switch itself.
* The full-screen tip card is now a route (AppRoute.Menu.TipCard) instead of a
bill presented into the session's overlay. The card is a static thing to
hold up to a camera, so it gets the whole screen: the page drops away
downward on push (and the tab bar leaves with it, since this isn't a tab
route), the card sits centred at the design's 302/402 of the screen width,
and Close sits just above the navigation bar. Node 9277:121410.
That last one retires the whole own-card-as-bill path:
presentOwnTipCard, Scannable.TipCard.isSelf, and SelfTipCardDecorator.
@github-actionsgithub-actionsBot added the type: feature New functionality label Aug 21, 2026
Full Screen now morphs the card that's already on the You tab rather than
navigating to a dedicated TipCardScreen. The card keeps its slot in the list
while an inner layer translates it to the display centre and grows it to the
302dp expanded width (node 9277:121410); the rest of the page fades and slides
out under it, the tab bar hides via a counted TabBarVisibilityController, and
Close/back collapse it. Spring matches iOS's
.spring(response: 0.45, dampingFraction: 0.85) — dampingRatio 0.85, stiffness 195.
Also:
- Copy link now flips to a filled checkmark.circle.fill-style glyph for 1.5s
before fading back to the copy icon, matching iOS.
- Version footer sits 44dp below the last row to match iOS's 69dp gap.
- Switch Accounts moves into Advanced Features next to Beta Features, and the
Advanced view model gained the staff/feature-flag filtering it was missing.
- MenuList takes an itemModifier that wraps the row *and* its sibling divider,
so fading the list out no longer leaves divider hairlines behind.
- Clamp the animated tab-bar inset: the underdamped spring undershoots below
zero, PaddingValues throws on a negative, and the exception was killing the
Recomposer and freezing the whole UI mid-expansion.
Removes TipCardScreen, its content and view model, and the session-presented
tip card path.
The empty state was a Box wrapping its content, so `align(Center)` centered it
against itself and it rendered flush at the top-left of the list. It now fills
the viewport and centers there when it's the only thing in the list, and centers
within padding when the override sections are present so it can't push them off
screen. Text is centered and inset for narrow screens.
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: build-systemGradle, convention plugins, build-logicarea: paymentsPayments, transfers, intents, billingarea: scannerQR/Kikcode scanning, cameraarea: sessionarea: uiCompose UI, theme, components, resourcestype: featureNew functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

@bmc08gt