diff --git a/docs/plans/2026-06-03-ui-theme-adoption-design.md b/docs/plans/2026-06-03-ui-theme-adoption-design.md new file mode 100644 index 0000000..4ad3c82 --- /dev/null +++ b/docs/plans/2026-06-03-ui-theme-adoption-design.md @@ -0,0 +1,171 @@ +# UI-Theme Adoption — Design + +**Date:** 2026-06-03 +**Status:** Approved (brainstorming complete) — ready for `writing-plans`. +**Component:** UI Theme (`ZB.MOM.WW.Theme` shared RCL). +**Goal:** Adopt the shared `ZB.MOM.WW.Theme` Razor Class Library across all three sister +apps (OtOpcUa AdminUI, MxAccessGateway Dashboard, ScadaBridge CentralUI + Host) via a +**full canonical cutover** (SPEC §7), after first **promoting nav-expand persistence into +the kit** so every app gets it from one shared mechanism. + +> This is the UI-theme analogue of the completed Auth+Audit normalization +> (`docs/plans/2026-06-02-auth-audit-normalization*.md`). It is **UI-only**: no data +> contracts, no DB migrations, no wire protocols. The dominant risk is **visual +> regression**, not data corruption. + +--- + +## 0. Verified starting state (2026-06-03) + +Independently verified (the component docs were optimistic — cf. memory +`component-status-claims-are-optimistic`): + +- **Library is real but unpublished and unadopted.** `ZB.MOM.WW.Theme/` holds all 10 + components + a Release `0.1.0` nupkg, but the Gitea feed returns **HTTP 404** for the + package and **no app references it**. The shared-contract's "Published to the Gitea NuGet + feed" is aspirational. → This is a clean **publish + adopt**. +- **Library is plain files tracked by `scadaproj`** (not a nested git repo) — library + changes commit in `scadaproj` (cf. memory `shared-libs-are-plain-files-not-nested-repos`). +- **Per-app surface** matches `components/ui-theme/GAPS.md`: + - **OtOpcUa AdminUI** — already side-rail (`.app-shell`/`.side-rail`/`.rail-link`); + interactive `NavSidebar` island (`@rendermode InteractiveServer`) holding `_expanded`, + persisted via JS interop (`window.navState.get/.set`) to the `otopcua_nav` cookie + (comma-separated section ids, 1-yr, `SameSite=Lax`); bespoke `StatusBadge`; static-POST + `Login.razor`; own `theme.css` + vendored fonts. *Lowest risk.* + - **ScadaBridge CentralUI** — `.sidebar`/`.nav-link`/`