3.7 KiB
phase, plan, subsystem, tags, dependency_graph, tech_stack, key_files, decisions, metrics
| phase | plan | subsystem | tags | dependency_graph | tech_stack | key_files | decisions | metrics | |||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 07-setup-wizard | 01 | frontend/setup-wizard |
|
|
|
|
|
|
Phase 07 Plan 01: Setup Wizard UI Shell Summary
LocalStorage-synced 3-step wizard with income input, grouped preset checklist (19 items), live allocation bar, and horizontal stepper navigation.
Commits
| Task | Commit | Description |
|---|---|---|
| 1 | bbcb07f |
useWizardState hook, i18n keys (EN+DE), shadcn checkbox |
| 2 | e141197 |
All 7 wizard UI components and SetupPage orchestrator |
What Was Built
-
useWizardState hook - Manages wizard step, income, and item selections in localStorage keyed by userId. Validates JSON shape on load (T-07-01 mitigation). Bills and variable_expense items pre-checked by default.
-
WizardStepper - Horizontal 1-2-3 stepper with circles, connector lines, and step labels. Completed steps are clickable; future steps are disabled.
-
IncomeStep - Number input pre-filled with 3000, currency suffix from profile, helper text, and inline validation error display.
-
AllocationBar - Sticky bar showing remaining = income - sum(checked amounts). Green when positive, red (destructive) when negative. aria-live="polite" for screen readers.
-
CategoryGroupHeader - Colored dot + label + item count for each of the 6 category types.
-
PresetItemRow - Checkbox + preset name (i18n) + category badge with colored border + editable amount input (disabled when unchecked).
-
RecurringItemsStep - Groups all 19 PRESETS into 6 category sections with AllocationBar at top.
-
SetupPage - Page orchestrator: centered card layout (max-w-2xl), loads profile for currency, renders stepper + active step, handles Next/Back/Skip navigation with income validation.
i18n
All wizard copy added under setup.* namespace in both en.json and de.json (35 keys each). German translations use proper umlauts and natural phrasing.
Deviations from Plan
None - plan executed exactly as written.
Known Stubs
| File | Line | Stub | Reason |
|---|---|---|---|
| src/pages/SetupPage.tsx | Step 3 content | "Review step coming in next plan" placeholder | Plan 02 will implement ReviewStep and completion logic |
| src/pages/SetupPage.tsx | Skip setup button | No-op onClick | Plan 02 will wire skip to mark setup_completed and redirect |
| src/pages/SetupPage.tsx | Complete button | Disabled, no handler | Plan 02 will implement completion sequence |
These stubs are intentional -- Plan 02 explicitly owns the ReviewStep, completion logic, routing, and redirect.