Files
scadaproj/ZB.MOM.WW.Theme/CLAUDE.md
T

5.6 KiB
Raw Blame History

ZB.MOM.WW.Theme

Shared UI kit (Razor Class Library — Technical-Light tokens, IBM Plex, side-rail shell, widgets) for the ZB.MOM.WW SCADA family; five consumers. Build/test from this directory: dotnet test. Component spec + gaps: ../components/ui-theme/.

Index history (migrated from the scadaproj root CLAUDE.md)

Moved verbatim out of the scadaproj root CLAUDE.md on 2026-09-03 so it loads only when needed. This file is now the authoritative place for this history — append new entries here and keep the root index row short.

Component-table row as it read in the index

Component Status Goal Design Implementation
UI Theme (layout / tokens / components) Adopted (feed 0.2.0–0.4.1). 0.4.0 (2026-08-11) upstreamed the Bootstrap .btn/.btn-sm sizing block that all five consumers had independently written into their own stylesheets (Bootstrap hard-codes --bs-btn-font-size: 1rem, oversized against the kit's 0.9rem body) — sized by --bs-btn-* variable override only, never by redeclaring box properties, because .btn-group's seam/radius machinery reads those same variables and a literal font-size at equal specificity silently flattens .btn-sm into a padding-only difference (a real defect found in mxgw's local copy). Same release added the rail-btn-block full-width rail-foot modifier; 0.4.1 fixes it — 0.4.0 shipped width: auto, which fills for an <a> but shrink-wraps a <button> (measured 114px short in the same rail), now calc(100% - 1.2rem) to clear .rail-btn's side margins. Consumers are five, not four — the ignitionoee router joined. All five consumers are on 0.4.1 and all five are PUSHED (2026-08-11): ignitionoee main @ 38aa5c1, OtOpcUa master @ e82881c1, mxgw main @ 0a9715d. The two whose sweeps were not deploy-ready pushed to branches, deliberately leaving their default branch untouched: HistorianGateway dashboard-ui-sweep-theme-0.4.1 — MERGED to main (ff to e42ff31) + pushed 2026-08-13, carrying Theme 0.4.1 + Health 0.3.0 + Secrets 0.6.2 + Auth 0.2.1 and ScadaBridge ui/central-ui-cleanup-sweep @ 9e243493 (main was then b6f383a2). ScadaBridge's caveat is now CLOSED and its sweep is merged, deployed and live (2026-08-11): the branch landed on main, and the two follow-ups d14e0ee4 + 3eb7df74 fixed exactly the four detail-modal surfaces the caveat named — the modal is now gated on user intent (the held id), never on the row still resolving, so a background refresh that drops the row leaves it mounted and says why the summary is missing instead of unmounting the subtree and disposing Close's own handler mid-click. That disposal was the intermittent GetRequiredEventBindingEntry, and NotificationReportDetailModalTests.Modal_StaysOpen_WhenItsRowLeavesThePage now pins it. Deployed to wonder-app-vd03: OtOpcUa e82881c1, and ScadaBridge 3eb7df74 (2026-08-11 — theme.css/layout.css/nav-state.js served from _content/ZB.MOM.WW.Theme and referenced by the pages; all six changed routes 200). HistorianGateway on wonder still runs e9c31da = Theme 0.3.1 — its 0.4.1 is now on main (merged 2026-08-13) but not yet deployed to the box. On bump, TRIM the local .btn block, don't delete it — four of the five were pure sizing, but mxgw's also carried border-radius/font-weight/white-space that a blind delete would have dropped. Shared ZB.MOM.WW.Theme RCL components/ui-theme/ ZB.MOM.WW.Theme/

Narrative

The UI-theme component is fully populated: a normalized spec, a design-tokens reference, a shared-contract, three current-state docs, and an adoption GAPS backlog. Shared = Technical-Light tokens + IBM Plex fonts + side-rail shell + widgets; left per-project = each app's site.css page layout, route content, scoped .razor.css.

The shared RCL is built and lives in this repo at ZB.MOM.WW.Theme/ (.NET 10 Razor Class Library; single package; 48 bUnit tests (re-verified 2026-08-11 at 0.4.1); feed carries 0.2.0–0.4.1, published to the Gitea feed). The build plan is at docs/plans/2026-06-01-zb-mom-ww-theme-shared-library.md; the adoption plan at docs/plans/2026-06-03-ui-theme-adoption.md. Adopted across all three apps on 2026-06-03 (full canonical cutover, SPEC §7) on each repo's feat/adopt-zb-theme branch — committed + spec/code-reviewed, then fast-forward-merged into each repo's local default (master/main) and PUSHED to origin (gitea) (in sync; feat/* kept locally as history): OtOpcUa →lmxopcua master@11de14d, ScadaBridge main@58352a6, MxGateway→mxaccessgw main@73e54e2. The 0.1.0 → 0.2.0 bump first promoted nav-expand persistence into the kit (NavRailSection.Key/data-nav-key + a localStorage nav-state.js enhancer emitted by a new <ThemeScripts/>), so all three apps share one persistence mechanism (OtOpcUa's bespoke cookie/JS-interop nav island retired); MxGateway additionally gained a net-new Blazor <LoginCard> /login page over its existing hardened endpoint. Per-app result in components/ui-theme/GAPS.md. Build/test from ZB.MOM.WW.Theme/: dotnet test. Consumer matrix: all three apps consume the single ZB.MOM.WW.Theme package (OtOpcUa AdminUI, MxGateway Server, ScadaBridge Host + CentralUI).