Commit Graph
23 Commits
Author SHA1 Message Date
SluijsensandClaude Haiku 4.5 31cc45d79b docs(unit-3): Functional design for Layout & Navigation
- Role-filtered sidebar (Owner/Admin/User visibility rules BR-U3-01–06)
- Topbar removed; UserMenu + LanguageSwitcher move to sidebar footer
- Mobile slide-over sidebar with hamburger button
- Theme toggle (light/dark) with localStorage persistence and no-flash init
- New components: MobileBar, SidebarOverlay, ThemeToggle, useTheme
- Unit 2 marked complete in aidlc-state

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
2026-06-22 11:44:24 +02:00
SluijsensandClaude Haiku 4.5 bbb8d5f423 fix(auth): Remove hardcoded api/v1 prefix from AuthController route
ApiPrefixConvention already prepends api/v1 to all controllers.
AuthController had it hardcoded too, resulting in the doubled route
api/v1/api/v1/auth/login which caused a 404 on login attempts.

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
2026-06-22 11:35:24 +02:00
SluijsensandClaude Haiku 4.5 7237669b14 fix(setup): Apply language choice and fix post-setup redirect
- Call changeLanguage(values.language) after successful owner creation so
  the UI immediately switches to the language the owner chose
- Call _markSystemInitialized() to update the router cache before navigating
  to /login; without this the guard saw initialized=false and redirected
  back to /setup, blocking the redirect

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
2026-06-22 11:25:40 +02:00
SluijsensandClaude Haiku 4.5 27490356cb fix(ui): Add type=button to FormErrorBanner dismiss to prevent form resubmit
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
2026-06-22 11:20:48 +02:00
SluijsensandClaude Haiku 4.5 2f381d8407 fix(frontend): Strip confirmPassword before API calls; add pointer cursor
- Destructure confirmPassword out of form values in SetupPage and
  InviteCompletePage so it is never sent to the backend
- Add global cursor:pointer rule for buttons, selects, labels and links

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
2026-06-22 11:17:20 +02:00
SluijsensandClaude Haiku 4.5 f221d7cee5 fix(unit-2-auth): Redirect to /setup on API failure; store owner display name
- Router catch block now falls back to { initialized: false } instead of
  silently continuing, preventing unwanted redirect to /login when the
  API call fails at startup
- Add Name field to CreateOwnerRequest and propagate to ApplicationUser.DisplayName
  so the owner's display name is stored during initial setup

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
2026-06-22 11:06:34 +02:00
SluijsensandClaude Haiku 4.5 8d95754ece fix(unit-2-auth): Fix API endpoint paths and JSON casing for real backend
- Add /api/v1/ prefix to all Unit 2 API calls (Setup/status, Setup/owner,
  Invitation/validate, Invitation/complete) to match backend ApiPrefixConvention
- Fix setup status endpoint to POST /api/v1/Setup/owner (not /Setup)
- Handle PascalCase 'Initialized' response from .NET backend without camelCase policy
- Update all MSW mock handlers to match corrected /api/v1/ URL patterns
- Remove unused imports from RouteGuard.test.tsx

Root cause: backend uses ApiPrefixConvention('api/v1') but frontend calls
were missing the prefix, and .NET defaults to PascalCase JSON serialization.

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
2026-06-22 10:55:34 +02:00
SluijsensandClaude Haiku 4.5 c9cd0ff457 fix(unit-2-auth): Fix all 4 failing unit tests to 29/29 passing
- Fix invitation MSW handler: use 'valid-token' to match test fixtures
- Add data-testid='setup-success' to SetupPage success state
- Change invite email input from readOnly to disabled (matches test assertion)

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
2026-06-22 10:20:00 +02:00
SluijsensandClaude Haiku 4.5 15b417c929 docs: Update Unit 2 completion status - Code Generation 86% pass rate
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
2026-06-22 10:05:50 +02:00
SluijsensandClaude Haiku 4.5 53879a891a 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>
2026-06-22 09:58:28 +02:00
Sluijsens f9689d2091 Adds unit 2 functional design and code generation plan and gap 4 report 2026-06-21 23:28:45 +02:00
Sluijsens ab93a5c7d1 Adds auth pages 2026-06-21 00:15:28 +02:00
Sluijsens 7dfc3a9692 Adds front-end set-up 2026-06-20 17:04:17 +02:00
Sluijsens efd1569c26 Adds nfr requirements and design for unit 1 2026-06-19 21:34:20 +02:00
Sluijsens 7e4397af4e Adds unit 1 functional design and answered nfr requirements questions and plan 2026-06-19 20:39:36 +02:00
Sluijsens 8b6ffcecba Adds migration 2026-06-19 15:07:33 +02:00
Sluijsens 23e2150140 Changes backend in preparation for frontend work 2026-06-19 12:15:08 +02:00
Sluijsens b5357f213a nfr design plan vragen aangemaakt (en beantwoord) voor unit 0 2026-06-18 23:50:29 +02:00
Sluijsens 53a307cdbd Finishes functional design for unit 0 (back-end changes before front-end work) 2026-06-18 21:40:45 +02:00
Sluijsens 9e49489f7e Adds application design (awaiting approval) 2026-06-17 20:15:54 +02:00
Sluijsens c7154e288f Adds requirements and userstories. also updates diagrams to be mermaid diagrams instead of text variants 2026-06-17 11:31:17 +02:00
Sluijsens 73025c5a84 Adds reverse engineering docs and adds new aidlc feature for front-end development 2026-06-16 23:25:22 +02:00
Sluijsens 95d986790e Initial commit with inital CMS 2026-06-15 17:00:16 +02:00