Skip to content

refactor(ui): AppBarWithTitle custom title + append close after end actions - #1223

Merged
bmc08gt merged 1 commit into
code/cashfrom
refactor/appbar-title-end-content
Aug 12, 2026
Merged

refactor(ui): AppBarWithTitle custom title + append close after end actions#1223
bmc08gt merged 1 commit into
code/cashfrom
refactor/appbar-title-end-content

Conversation

@bmc08gt

@bmc08gt bmc08gt commented Aug 12, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Add an optional titleContent slot to AppBarWithTitle so callers can render a composable title (e.g. a token icon + name) instead of only a plain string, and widen endContent to a RowScope receiver.
  • When the leading control resolves to a Close, append it after the caller's end actions (furthest toward the screen edge — the conventional dismiss position) instead of replacing them. TopAppBarBase already lays these out in an EndActionSlotHolder, so a back arrow never shares the leading slot with a close.
  • TokenInfoScreen adopts the new slots: titleContent for the token icon/name + an explicit onBackIconClicked, dropping its manual trailing Close.

Test Plan

  • Full :apps:flipcash:app:assembleDebug compiles (50+ AppBarWithTitle callers — signature change is source-compatible).
  • On device: token info screen shows the icon/name title, share action, and a close in the conventional edge position; spot-check a couple of other AppBar screens for correct close/end-action placement.

…ctions

Add an optional titleContent slot so callers can render a composable title
(e.g. a token icon + name) instead of a plain string, and widen endContent to
a RowScope receiver.

When the leading control resolves to a Close, append it *after* the caller's
end actions (furthest toward the screen edge, the conventional dismiss spot)
rather than replacing them — TopAppBarBase already lays these out in an
EndActionSlotHolder, so a back arrow never shares the leading slot with a close.

TokenInfoScreen adopts the new slots: titleContent for the token icon/name and
an explicit onBackIconClicked, dropping its manual trailing Close.
@github-actions github-actions Bot added area: ui Compose UI, theme, components, resources area: tokens Token accounts, balances, token info labels Aug 12, 2026
@bmc08gt
bmc08gt merged commit 8c3d545 into code/cash Aug 12, 2026
3 checks passed
@bmc08gt
bmc08gt deleted the refactor/appbar-title-end-content branch August 12, 2026 16:24
@github-actions github-actions Bot added the type: refactor Code restructuring, no behavior change label Aug 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: tokens Token accounts, balances, token info area: ui Compose UI, theme, components, resources type: refactor Code restructuring, no behavior change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant