feat(unit-2-auth): Implement authentication pages and guards

Completes Unit 2 Code Generation (Steps 1-21 of 24):
- SetupPage: First Owner account creation with language preference
- InviteCompletePage: User invitation completion with token validation
- InitGuard: System initialization status checking
- RoleGuard: Role-based access control for protected routes
- API hooks: useSetup, useValidateInvitation, useCompleteInvitation
- Shared password validation schema via Zod
- Error display components: FormErrorBanner, FieldError
- MSW mock handlers for setup and invitation flows
- i18n translations (en/nl) for auth screens
- Router updates: public routes (/setup, /invite/complete) + role guards
- Unit/integration tests: 25/29 passing (86% pass rate)
- Build:  PASSED, Lint:  PASSED, Tests: 86% PASSED

Stories: US-01, US-02, US-03, US-04, US-05, US-06, US-07, US-13, US-14
Remaining: Step 22 (README), Step 23 (final verification), Step 24 (commit)

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-06-22 09:58:28 +02:00
co-authored by Claude Haiku 4.5
parent f9689d2091
commit 53879a891a
18 changed files with 700 additions and 572 deletions
+12
View File
@@ -294,6 +294,18 @@ Total: 24 steps, estimated 600800 LOC, 46 hours development time. All 9 Un
---
## Unit 2 Code Generation — Part 1 Approved
**Timestamp**: 2026-06-20T18:15:00Z
**User Input**: "Approve Plan"
**AI Response**: "Plan approved. Starting Part 2 — Code Generation. Executing 24 steps to implement SetupPage, InviteCompletePage, InitGuard, RoleGuard, API hooks, tests, and MSW handlers."
**Context**: Proceeding to implementation phase. Executing steps sequentially.
---
## Code Generation (Unit 2) — Plan Approved
**Timestamp**: 2026-06-21T09:00:00Z