feat(balance): starter accounts + opt-in modal + ADR 0012 (#179) #185
Closed
maximus
wants to merge 1 commit from
issue-179-starter-accounts into issue-178-onboarding-card
pull from: issue-179-starter-accounts
merge into: maximus:issue-178-onboarding-card
maximus:main
maximus:issue-187-balance-cleanup-post-184-185
maximus:issue-188-webkit-date-picker-7-inputs
maximus:issue-180-postcss-audit-fix
maximus:issue-190-restructure-settings-pages
maximus:issue-161-smoke-scaffold
maximus:issue-171-ci-drop-push-trigger
maximus:issue-169-asset-type-balance-categories
maximus:issue-67-feedback-widget
maximus:issue-97-cartes-page
maximus:issue-96-compare-refactor
maximus:issue-51-compte-maximus-oauth
maximus:issue-46-license-commands-entitlements
maximus:issue-48-gate-auto-updates
maximus:issue-47-license-ui-card
maximus:fix/simpl-resultat-54-argon2id-pin
maximus:fix/simpl-resultat-59-bump-vite
maximus:issue-43-update-picomatch
maximus:fix/simpl-resultat-41-category-time-report-filter
maximus:fix/simpl-resultat-31-dashboard-month-dropdown
maximus:fix/simpl-resultat-29-budget-visual-adjustments
maximus:fix/simpl-resultat-23-dashboard-category-ordering
maximus:fix/simpl-resultat-16-prev-year-budget
maximus:fix/simpl-resultat-19-tooltip-transparency
maximus:fix/simpl-resultat-17-remove-piechart-title
maximus:fix/simpl-resultat-16-budget-previous-year
1 commit
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
cd0a2b826f |
feat(balance): starter accounts + opt-in modal + ADR 0012
Part 1 — New profiles: seed 4 starter accounts in
consolidated_schema.sql (Compte chèque/CELI/REER/Compte
non-enregistré, currency CAD, is_active=1) right after the
balance_categories seeds. Categories resolved via SELECT subquery
on the seeded `key` values for robustness.
Part 2 — Existing profiles: StarterAccountsModal proposes the same
4 starters at first /balance visit. Default-checked checkboxes,
collision rule (case-insensitive trim name + matching category)
disables matches with a "Déjà présent" tooltip. The atomic helper
`proposeStarterAccounts` wraps the inserts in BEGIN/COMMIT (rolls
back on error). user_preferences.balance_starter_proposed records
{shown_at, accepted} so the modal never reappears, dismissed or
confirmed.
Part 3 — docs/adr/0012-balance-two-level-model.md (Proposed):
captures the future vehicles × compositions model for reflection,
no code change. Numbered 0012 because 0011 was already taken by
the providers-best-effort-yahoo ADR. Linked from architecture.md
ADR table and Bilan section.
Tests: StarterAccountsModal.test.tsx covers STARTER_ACCOUNTS shape,
getStarterCollisions (case-insensitive trim, category-scoped) and
proposeStarterAccounts (insert order, COMMIT, ROLLBACK on failure).
No render tests — mirrors the BalanceOnboardingCard pattern (no
jsdom configured).
Resolves #179
|