Skip to content

feat(group-send): pick the currency on the confirm sheet only - #1916

Merged
bmc08gt merged 7 commits into
code/cashfrom
feat/group-send-split-between
Oct 30, 2026
Merged

bmc08gt merged 7 commits into
code/cashfrom
feat/group-send-split-between

Conversation

@bmc08gt

@bmc08gt bmc08gt commented Oct 30, 2026 •

Copy link
Copy Markdown
Collaborator

Group send no longer asks for a currency or checks a balance before the user has picked people. The currency is chosen on the confirm sheet, which is now the only place the balance is checked. Spec: code-payments/flipcash-client-orchestrator#84 (docs/specs/group-send.md, Sender steps 1-3). There is no Figma frame for this change; it is removals and copy only.

  • Amount step: titled "Total Amount To Send" with no currency pill, no "Enter up to" hint and no balance ceiling. Next gates only on an amount above zero. ChatAmountEntryContent takes an optional title; DM send passes none and keeps its pill and hint. The ceiling is dropped for group sends in maxAmountFlow, and onConfirmRequested skips the balance check for them (the send-limit check stays).
  • Select People: the group send caller passes "Split Between" and "Next" through new title and buttonText arguments. The request-money flow keeps its current title and button. Disabled-at-zero, the 10-max sheet and the too-small alert are unchanged.
  • You in the split: Split Between starts with an unchecked "You" row, passed by the group send caller only. Checking You splits the total between everyone checked, You included, with You's part always the last share (so You never takes an extra cent), then drops You's part: only the other members are paid, in check order (one is a single payment, two or more a multi-payment). Next needs at least one member other than You. You counts toward the 10 cap: You plus 9 others is the most. The too-small check counts You. Confirm lists only the paid members, shows the entered total, and sendToMembers() checks the balance against the sum of the paid parts.
  • Confirm sheet with You in the split: the per-person line reads "$X Each, including You" ("~" unless every part, You's included, is equal, X the smallest paid part), and shows even for a single paid member. The confirm sheet's Each strings are capitalized; the group send chat bubble keeps its own lowercase "each" strings.
  • Confirm sheet: unchanged. It still opens on the globally selected token, and sendToMembers() still shows the insufficient balance alert with Add Money when the total exceeds the picked token's balance.

TokenCoordinator and TokenSelectionResolver are untouched.

Tests: ChatGroupCashLinkTest gains tests for the You row ($30.00 between You and 2 others pays $10.00 twice and charges $20.00; $1.00 with You checked at any position pays $0.34 and $0.33 and You keeps $0.33; only You blocks Next; You plus 9 others is the most; the too-small check counts You), one test where a total above the balance passes the amount step and is stopped at confirm by the insufficient-balance alert, and one for no hint and a confirmable amount on the group amount step.

The group send amount step drops the currency pill, the "Enter up to" hint and the balance ceiling, and is titled "Total Amount To Send". Select People is titled "Split Between" and ends on Next. The confirm sheet is unchanged and is now the only balance check.
@bmc08gt bmc08gt self-assigned this Oct 30, 2026
@github-actions github-actions Bot added the type: feature New functionality label Oct 30, 2026
Checking You counts the sender in the split without paying them: the total is split between everyone checked in check order, then You's part is dropped. Only the other members are paid, Next needs at least one of them, and You does not count toward the 10 cap. Confirm lists only the paid members, and the balance check is against the sum of the paid parts.
@github-actions github-actions Bot added the area: payments Payments, transfers, intents, billing label Oct 30, 2026
Adds the youVectors from the shared group-send-split.json fixture and a GroupSendSplit.splitWithViewer that GroupSendState.plan uses, so the test and the app share the drop-You path. Fixes the delegate doc comment: the balance check is against the paid parts.
When the sender is in the split, the per-person line reads "$X each, including You" ("~" unless every part, the sender's included, is equal), and shows even for a single paid member. The You vectors now carry that label.
You's part is always the last share, so You never takes an extra cent, and the 10 People Max cap counts You: nine others plus You is the most. The Each strings are capitalized.
The bubble gets its own lowercase strings; only the confirm sheet's Each is capitalized.
@bmc08gt
bmc08gt merged commit 5795604 into code/cash Oct 30, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: payments Payments, transfers, intents, billing type: feature New functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant