Move personalization page from /operator/personalization to /settings/personalization (user-level) #70
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
Move the personalization page from the operator section to the user section:
http://192.168.31.41:5173/operator/personalization(added in #46)http://192.168.31.41:5173/settings/personalizationRationale: theme/accent preferences are a per-user setting, not an instance-operator one —
they belong under
/settings, not/operator.Scope hints
dashboard/src/routes/settings/personalization/; the pageitself keeps its behaviour (system/dark/light + accent tint picker).
destinations.ts,page-help.ts, breadcrumbs,any
operatornav list, and the e2e nav coverage (scripts/e2e/nav_selenium.pyif it liststhe route).
/operator/*must not be required for the newpath — a normal signed-in user must reach their own settings page. If some operator-only data
was being read there, report the conflict instead of guessing.
/operator/personalizationto the new path (preferred if anything links to it) or remove it cleanly — say which and why.
related:,_check.pygreen.Gates
python3 docs/use-cases/_check.py,scripts/check-ai-headers.py, dashboardbun run test+bun run check. One commit per logical step,Refs #<N>, no closing keywords.Claimed — branch
issue/70-personalization-move. Doing: move the accent-tint page to/settings/personalization(user-level), update nav/destinations/page-help/breadcrumb pointers + e2e walk, keep a 308 shim from the old/operator/personalization, update UC-FE-99/-08/-80.Plan — issue #70: move personalization from
/operator/personalizationto/settings/personalizationRestated goal
The accent-tint picker shipped in #46 (
dashboard/src/routes/operator/personalization/+page.svelte, UC-FE-99)sits behind the instance-operator gate (
operator/+layout.server.ts→ non-operators 303 to/settings),but the preference is per-browser/per-user, never an instance-operator concern. Move the page to
/settings/personalization, drop the operator gate (the ordinary session gate inhooks.server.tsis the only requirement), move every pointer that named the old URL (nav group item, destinations
icon prefix, page-help, app.css comment, selen-check/usecase test lists, e2e walk list), and keep a
thin 308 shim on the old path for bookmarks.
Done for the operator: a normal signed-in user (no
instanceOperator) opens/settings/personalizationfrom the Settings submenu, picks a tint, and it sticks across reloads;/operator/personalizationstill lands them on the new page; the old URL is no longer listed inthe Operator module; no operator-only data is read by the page (it is 100% browser-local, zero
middleware calls).
Scope
Will change (9 files + 1 dir move + 1 new file):
dashboard/src/routes/settings/personalization/+page.svelte— moved verbatim fromdashboard/src/routes/operator/personalization/+page.svelte, headerFile/Purpose/Lastupdated.dashboard/src/routes/operator/personalization/+page.ts— new 308 shim →/settings/personalization(same shape as
routes/config/kill/+page.ts).dashboard/src/lib/nav.ts— drop/operator/personalizationfrom theoperatorgroup, add/settings/personalizationto theconfiggroup (Settings submenu).dashboard/src/lib/dashboard/destinations.ts— icon prefix/operator/personalization→/settings/personalization.dashboard/src/lib/page-help.ts— page-help entry key moved;/settingsbody mentions the newsubmenu item.
dashboard/src/app.css— comment naming the page (line 103) updated.dashboard/src/lib/usecases-frontend.test.ts— operator href list, full NAV href list,accountSettingsNavname list, UC-FE-99 page path +pageHelpkey.scripts/e2e/nav_selenium.py—NAV_HREFSmoves the href;REDIRECTSgains the old→new entry.docs/use-cases/frontend/UC-FE-99-accent-personalization.md— story/preconditions/trigger/implementation now trust-level, version bump.
docs/use-cases/frontend/UC-FE-08-nav.md— Settings submenu list gains Personalization, Operatorlist loses it; Implementation path updated.
docs/use-cases/frontend/UC-FE-80-users-organizations.md— trigger line and Implementation citedrop personalization; version bump.
Will NOT touch:
middleware/**,agent/**,plans/**(no server-side or plan surface involved).dashboard/src/lib/theme.ts,app.html— accent plumbing is unchanged, only the route moves.routes/settings/+page.svelte) gets no new card: not requested; thesidebar Settings submenu is the discoverability pointer (see Open questions).
docs/use-cases/README.md— it links the UC file, not the route path.UC decision
No new UC. UC-FE-99 already owns this capability; the issue renames its route, so I update
UC-FE-99 (Story, Preconditions, Trigger, Implementation, version) plus its two consumers that
enumerate routes (UC-FE-08 nav groups, UC-FE-80 operator menu).
dashboard/src/routes/settings/personalization/+page.sveltedashboard/src/lib/theme.tssetAccentHuedashboard/src/lib/nav.tsNAV_GROUPSdashboard/src/app.htmldashboard/src/lib/usecases-frontend.test.ts(already mentions UC-FE-99).related: [UC-FE-08, UC-FE-80, UC-FE-85]— unchanged, still bidirectional.actor:staysOperator(repo-wide vocabulary for "console user" in every frontend UC, includinguser-level UC-FE-82/-83); the Story text now says signed-in user, not instance operator.
Ordered tasks (each with its verifying command)
git mvthe page dir toroutes/settings/personalization/, fix its five-field headerls dashboard/src/routes/settings/personalization/routes/operator/personalization/+page.ts308 shimrg -n 'settings/personalization' dashboard/src/routes/operator/personalization/+page.tsnav.ts+destinations.ts+page-help.ts+app.csscommentrg -n personalization dashboard/src --glob '!*.test.ts'usecases-frontend.test.tslists/pathscd dashboard && bunx vitest run src/lib/usecases-frontend.test.tsscripts/e2e/nav_selenium.pyNAV_HREFS + REDIRECTSpython3 -c "import ast,pathlib;ast.parse(pathlib.Path('scripts/e2e/nav_selenium.py').read_text())"python3 docs/use-cases/_check.pypython3 scripts/check-ai-headers.py;cd dashboard && bun run test && bun run check && bun run build;rg -n 'Showing lines' --glob '!node_modules' --glob '!.git'One commit per task;
Refs #70in each; no closing keyword anywhere.Open questions (assumption I proceed on)
already uses this exact pattern for
/config/*→/settings/*. Cost is one 6-line file. Note: theshim sits behind
operator/+layout.server.ts, so a non-operator hitting the old URL is 303'd to/settingsby the layout before the shim runs — they were never able to use the old URL anyway.Settings, <account/Profile>, Kill switch, Secrets, Organization, Personalization), so the existing account-name slot keepsindex 1 and nothing else shifts.
if the operator wants it: a card next to the Appearance card, same shape as the Secrets card.
actor:field: left asOperator(matches every frontend UC, incl. user-level ones); Storytext states signed-in user. Flagged in the report in case the operator wants a distinct actor.
localStorage(
gotoi-accent), browser-local, not server-side per-account. The issue asks for the route move,not for a middleware-backed user preference.
Risk
full NAV list test,
accountSettingsNavnames, seleniumNAV_HREFS). Miss one → red vitest or astale e2e walk. Fallback:
rg -n 'operator/personalization'must be empty except the shim.related:must stay bidirectional;fallback is to run
_check.pyafter each UC edit rather than at the end..sveltefile with a stale import path would fail; the page onlyimports
$lib/*, so the move is inert. Fallback: re-read the file tail if anything looks truncated.DONE — personalization moved to /settings/personalization (user-level).
Commits (branch
issue/70-personalization-move, base origin/develop):0ed997emove page + /operator 308 shimcd72fb1nav/destinations/page-help/app.css pointerse4b8c43tests + selenium walk0cce80aUC-FE-99 / UC-FE-08 / UC-FE-80Gates:
docs/use-cases/_check.pyexit 0 (358 files, all conform)scripts/check-ai-headers.pyexit 0 (574 ok)scripts/check-type-mirror.pyexit 0dashboard bun run testexit 0 (16 files, 251 tests)dashboard bun run checkexit 0 (0 errors, 7 pre-existing warnings)dashboard bun run buildexit 0check-test-tampering.pyexit 0;Showing linesscan emptyLive smoke (own middleware :3199 + scratch DB + Vite :5411, Chromium):
instanceOperator:false) GET /settings/personalization → 200, picker renders, tint persists across reload (260→15)Old URL kept as a 308 shim (matches /config/* pattern). No replacement operator gate needed: the page is localStorage-only and reads nothing from middleware. Nothing pushed; report at meta/issue-70.report.md.
REVIEW: FIXED 2 — findings: (1) usecases-frontend.test.ts dropped two passing profile-href assertions in the accountSettingsNav test with no need (test weakening) — restored in
62469c4; (2) UC-FE-08 Main flow step 4 still enumerated the Settings submenu without Personalization after the move — added ina616a19. Verified: route moved, 308 shim matches the /config pattern, all pointers (nav, destinations, page-help, app.css, selenium NAV_HREFS/REDIRECTS, UC-FE-99/-08/-80) updated, _check.py / check-ai-headers.py / check-type-mirror.py / check-test-tampering.py exit 0, touched vitest file 105/105 green; UNFIXED: noneDone. Branch
issue/70-personalization-move(6 commits: 4 implementer + 2 review), PR: #76 (targets agent-develop).Page moved to /settings/personalization (localStorage-only, no middleware reads), every pointer updated (nav, destinations.ts, page-help.ts, test lists, nav_selenium.py), old URL kept as 308 shim, UCs UC-FE-99/FE-08/FE-80 updated.
review: FIXED 2 — reviewer restored profile-href assertions the move dropped (
62469c4) and fixed UC-FE-08 Settings submenu (a616a19).Gates: _check.py green, ai-headers 574 ok, type-mirror green, dashboard vitest 251/251, svelte-check 0 errors / 7 pre-existing warnings, dashboard build green, hidden-tests exit 0. Live smoke: non-operator 200 on new path, old path 308s.