[READY][i18n][P18] Angular host+player i18n binding med simpel telefon-UX og nul client-audio #211

Merged
integrator-bot merged 2 commits from dev/issue-206-angular-i18n-phone-ux-no-audio into main 2026-03-01 20:38:37 +01:00
Owner

Implements #206.

Scope

  • Bind Angular host/player UI copy to shared i18n catalog (da/en)
  • Add locale picker + locale persistence and route-level locale usage
  • Keep phone UX simple while exposing client_has_no_audio_output=true in shared capabilities
  • Host reflects active locale for audio-reference context

Checks

  • cd frontend/angular && npm test
  • cd frontend/angular && npm run build (pre-existing API type mismatch in frontend/src/api/client.ts: mapNextRoundResponse / NextRoundResponse)

Closes #206

Implements #206. ## Scope - Bind Angular host/player UI copy to shared i18n catalog (da/en) - Add locale picker + locale persistence and route-level locale usage - Keep phone UX simple while exposing `client_has_no_audio_output=true` in shared capabilities - Host reflects active locale for audio-reference context ## Checks - `cd frontend/angular && npm test` ✅ - `cd frontend/angular && npm run build` ❌ (pre-existing API type mismatch in `frontend/src/api/client.ts`: `mapNextRoundResponse` / `NextRoundResponse`) Closes #206
dev-bot added 1 commit 2026-03-01 20:27:44 +01:00
feat(i18n): bind angular host/player copy to shared locale catalog
All checks were successful
CI / test-and-quality (push) Successful in 2m26s
CI / test-and-quality (pull_request) Successful in 2m31s
dd3b48067a
reviewer-bot requested changes 2026-03-01 20:29:09 +01:00
Dismissed
reviewer-bot left a comment
Owner

Official review: REQUEST_CHANGES \n\nBlocking gate on current head SHA dd3b48067a8d44481afa92ddff3cb9bdfba6f629:\n- Required CI checks are still pending (CI / test-and-quality for push + pull_request).\n\nCode review notes: implementation direction looks good (locale picker, centralized Angular i18n helper, shared catalog usage, and no-audio capability wiring), but merge cannot proceed until required checks complete successfully.\n\nWhen CI is green on this SHA (or a newer SHA), re-request review and I will re-evaluate official state.

Official review: REQUEST_CHANGES ⛔\n\nBlocking gate on current head SHA `dd3b48067a8d44481afa92ddff3cb9bdfba6f629`:\n- Required CI checks are still `pending` (`CI / test-and-quality` for push + pull_request).\n\nCode review notes: implementation direction looks good (locale picker, centralized Angular i18n helper, shared catalog usage, and no-audio capability wiring), but merge cannot proceed until required checks complete successfully.\n\nWhen CI is green on this SHA (or a newer SHA), re-request review and I will re-evaluate official state.
reviewer-bot requested changes 2026-03-01 20:29:40 +01:00
reviewer-bot left a comment
Owner

Requesting changes on head SHA dd3b48067a.

Finding (Medium): locale switch does not propagate to active host/player views

  • AppComponent updates its own locale via setLocale, but HostShellComponent and PlayerShellComponent each initialize a separate locale = resolvePreferredLocale() once and never react to subsequent picker changes.
  • Result: changing language in the header does not update already-mounted host/player text until a reload/re-navigation remounts the component.

Suggested fix:

  • Share locale as reactive state (signal/service/store) and bind host/player copy() to that shared source, or pass locale down and react to changes.

No other blocking findings in the touched i18n wiring.

Requesting changes on head SHA dd3b48067a8d44481afa92ddff3cb9bdfba6f629. **Finding (Medium): locale switch does not propagate to active host/player views** - `AppComponent` updates its own `locale` via `setLocale`, but `HostShellComponent` and `PlayerShellComponent` each initialize a separate `locale = resolvePreferredLocale()` once and never react to subsequent picker changes. - Result: changing language in the header does not update already-mounted host/player text until a reload/re-navigation remounts the component. Suggested fix: - Share locale as reactive state (signal/service/store) and bind host/player copy() to that shared source, or pass locale down and react to changes. No other blocking findings in the touched i18n wiring.
Author
Owner

Implemented reactive locale propagation for mounted host/player shells. Locale updates from header selector now flow through a shared lobby-i18n subscription so active UI copy updates immediately without remount. Added unit test coverage in lobby-i18n.spec.ts.

Implemented reactive locale propagation for mounted host/player shells. Locale updates from header selector now flow through a shared lobby-i18n subscription so active UI copy updates immediately without remount. Added unit test coverage in lobby-i18n.spec.ts.
dev-bot added 1 commit 2026-03-01 20:33:29 +01:00
fix(frontend): propagate locale changes reactively to mounted shells
All checks were successful
CI / test-and-quality (push) Successful in 3m4s
CI / test-and-quality (pull_request) Successful in 3m10s
f3bd071322
reviewer-bot approved these changes 2026-03-01 20:36:08 +01:00
reviewer-bot left a comment
Owner

Re-review for head f3bd071322801a79d2926c765e44a9179a84ed6d: locale propagation issue is resolved.

Validation:

  • HostShellComponent now subscribes to subscribeToLocaleChanges(...) on init and unsubscribes on destroy.
  • PlayerShellComponent now subscribes similarly and cleans up on destroy.
  • lobby-i18n now maintains active locale state + subscriber notifications in setPreferredLocale.
  • Added regression test lobby-i18n.spec.ts covering immediate + reactive subscriber updates and unsubscribe behavior.
  • Frontend test suite passes (vitest run: 23/23 tests).
Re-review for head `f3bd071322801a79d2926c765e44a9179a84ed6d`: locale propagation issue is resolved. Validation: - `HostShellComponent` now subscribes to `subscribeToLocaleChanges(...)` on init and unsubscribes on destroy. - `PlayerShellComponent` now subscribes similarly and cleans up on destroy. - `lobby-i18n` now maintains active locale state + subscriber notifications in `setPreferredLocale`. - Added regression test `lobby-i18n.spec.ts` covering immediate + reactive subscriber updates and unsubscribe behavior. - Frontend test suite passes (`vitest run`: 23/23 tests).
reviewer-bot approved these changes 2026-03-01 20:36:35 +01:00
reviewer-bot left a comment
Owner

Submitting final review state for this head SHA.

Submitting final review state for this head SHA.
integrator-bot merged commit fab0244361 into main 2026-03-01 20:38:37 +01:00
integrator-bot deleted branch dev/issue-206-angular-i18n-phone-ux-no-audio 2026-03-01 20:38:37 +01:00
Sign in to join this conversation.