feat(preferences): user & organisation preferences UI (IFC-2720)
Merged
PA
4mo ago+0+0+0123456789-0-0-0123456789
Depends on #9871
What
The user & organisation preferences UI:
- Typed GraphQL API for the three read scopes (effective / user / global) and the user + global writes.
- An FSD domain layer — date-format and timezone models, rules, and use-cases.
- UI — a personal preferences card on the Profile tab, and a permission-gated Organisation defaults tab.
- The shared
DetailRowdisplay andComboboxFieldform control the preference forms build on.
Why / stack
This is the third of a 3-PR split of the original #9776, opened to make review easier. It builds on the reusable layout primitive and the global-permission plumbing extracted into the two PRs below:
- #9870 —
refactor(layout):DetailsColumnsprimitive - #9871 —
feat(permission): frontend global-permission checks - this PR — the preferences feature
Supersedes #9776 (the un-split PR), which is kept open for now for review-thread continuity and will be closed once this stack is approved.
Test
biome ciclean; 66 tests pass across preferences / permission / user-profile / display;tscintroduces no new errors.
🤖 Generated with Claude Code
Summary by cubic
Adds user date-format and timezone preferences, plus an admin Organisation defaults editor. Adds a Preferences card on Profile and a permission-gated tab at /profile/organisation-defaults, powered by typed GraphQL and React Query, per IFC-2720.
-
New Features
- Data: typed GraphQL for effective/global reads and user/global writes; React Query hooks with targeted invalidation.
- UI:
UserPreferencesCardon Profile;/profile/organisation-defaultsgated byMANAGE_GLOBAL_PREFERENCESviaRequireGlobalPermission. - Forms: reusable
PreferencesFormwithComboboxField,TimezoneField, andDetailRow; date-format uses semantic keys with live examples and re-select to clear; searchable IANA timezone list that always includesUTC; tooltips show value source (user/global/browser).
-
Refactors
- Account menu now uses shared
DropdownMenufor clearer, accessible navigation. - Failed saves keep the form dirty with errors via toasts; unknown
PreferenceSourcelogs instead of defaulting to browser.
- Account menu now uses shared