Onboarding: multi-profile + group flows
Onboarding: multi-profile + group flows
Status: Delivered
CAS: CAS-713 (closes CAS-713, CAS-715, CAS-716, CAS-719)
Delivered: 2026-04-26
PRs: #234 (Steps 1b, 1c, deep-link)
What’s new
The onboarding flow now handles households with multiple people. A user can add housemates during sign-up, name the household, and the app creates a permanent group automatically. A deep-link handler is registered so invite codes can be accepted directly from a link.
How to use it
Step 1b — Add people in your home:
- After creating the first profile, the onboarding presents the “Add people” step.
- Tap the + row to add a housemate by name. Each row creates a real profile via
add_profile. - Rows can be removed before proceeding. At least one profile must exist to advance.
- If a housemate is not present, you can skip the step; they can be added later via an invite link.
Step 1c — Name your home (conditional on 2+ profiles):
- If two or more profiles were added in Step 1b, the app presents a “Name your home” step.
- Enter a household name and confirm. The app calls
create_groupand creates a permanent household group containing all profiles from Step 1b. - The group ID is persisted; all future shared invoice and receipt operations refer to it.
Deep-link invite acceptance:
- Opening a
casaconomy://invite/<code>URL on the device fires theinvite://deep-link-receivedevent on the frontend. - The onboarding (or invite screen, if already past onboarding) receives the event and pre-fills the code into the invite redemption flow.
- No manual copy-paste required.
What changed under the hood
AddPeopleStep.tsx— new onboarding component; dynamic profile-creation rows, callsadd_profileper row, surfaced errors via MantineAlert,ScrollArea mah={320}keeps footer visible at five-plus rows on 1280×800.NameHomeStep.tsx— new onboarding component; callscreate_groupwith all profile IDs collected in Step 1b; conditional render (only when ≥ 2 profiles exist).OnboardingPage.tsx— wired both new steps into the multi-step flow; manages collectedprofileId[]state passed forward from 1b into 1c.add_profilebackend — now returns the fullProfilestruct (including DB-assignedid), so the frontend can threadprofileIdthrough without a second lookup.tauri-plugin-deep-link— added toCargo.tomland registered inlib.rs; thecasaconomy://invite/<code>scheme is declared intauri.conf.json; the plugin firesinvite://deep-link-receivedon the main window’s event bus.- Capabilities —
capabilities/default.jsonupdated for the deep-link plugin.
Why we built it
The existing onboarding stopped at a single profile — the household-sharing features introduced in the CAS-468 groups epic (encryption, invite codes, shared invoices) are only reachable if multiple profiles exist and are linked to a group. Steps 1b and 1c bring that bootstrapping into the first-run experience so households are properly configured from day one rather than requiring a manual post-onboarding setup detour.