Repository navigation
feat(console): support deployment-wide theme bundles - #3048
Conversation
Load and validate operator-mounted console branding at API startup. Apply product names, logos, icons, and semantic colors across public and authenticated UI surfaces, with API-only Compose and Helm mounts. Add HTTP and browser integration coverage, themed Storybook scenarios, QA workflow wiring, and operator documentation. Signed-off-by: Russell Bryant <rbryant@redhat.com>
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
Signed-off-by: Russell Bryant <rbryant@redhat.com>
|
Codex review: needs maintainer review before merge. What this changesThis PR adds startup-loaded theme bundles for the console’s name, images, and semantic colors, with Compose and Helm mounting support. Example: An operator mounts the example theme and restarts the API.
Review scores
ProductKind: Feature · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review Keep open: this PR delivers useful, maintainer-approved deployment branding that current main lacks; no actionable correctness or security defects were found. Priority: P2 Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherThe controller loads trusted deployment files before listening, then serves their validated presentation data through the existing public console asset handler. flowchart LR
A[Operator bundle] --> B[Startup validation]
B --> C[Theme snapshot]
C --> D[Console asset handler]
E[Bundled console assets] --> D
D --> F[Browser console]
Technical reviewBest possible solution: Land the optional startup snapshot through the existing console owner with its validated asset boundary and documented restart recovery. Do we have a high-confidence way to reproduce the issue? This is a new capability; current-main source confirms that deployment theme bundles are not already supported. Is this the best way to solve the issue? The implementation extends the existing console asset and composition owners without introducing platform resources, persistence, or arbitrary executable theme content. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 4f848ea4c8fc. Provenance checked
TestingProof path: shipped entry point. SecurityNone. EvidenceWhat I checked:
Likely related people:
LabelsLabel changes: No label changes. Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment HistoryReview history (1 earlier review cycle)
Reviewed October 21, 2026, 7:12 PM ET / 23:12 UTC (Revision 2). |
|
Free's clanker here (an AI agent working on Free's behalf). Heads-up about a conflict coming from main: #3111 moved the body of This PR edits the old body of |
|
(human here) I'm doing some UI cleanup work as well so gonna get this landed. Thanks @russellb 🙏 |
…theme-bundle-3048
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
freeqaz-openai
left a comment
There was a problem hiding this comment.
Maintainer review performed with Codex on 977d738. I reviewed the startup and public asset boundary, default and custom branding, QA selection, and typed test discovery. The final local controller/browser proof and Claw review show no actionable findings. The trusted-administrator filesystem requirement and the earlier model-runtime QA exception are documented; no live provider or cluster qualification is claimed for this revision.
A deployment can now set the Console’s product name, logo, and colors without rebuilding the controller. Mount a small theme bundle into the API and restart it. Installations without a bundle keep the standard Console, including its 20-pixel navigation and 40-pixel sign-in logos.
The bundle is public deployment configuration. The files and directories that can replace them must be writable only by trusted deployment administrators. A read-only container mount does not prevent host-side or ConfigMap replacement. The API reads a bounded snapshot at startup, accepts named semantic colors and raster images, and refuses invalid configuration before listening. Requests cannot select filesystem paths, upload themes, or provide CSS or JavaScript. The chart mounts the ConfigMap read-only in the API and can roll the API when the bundle changes.
Verification
The images compare the bundled Console with the example theme on the same revision. The recording starts after sign-in in an isolated browser session, opens and dismisses the Create Secret dialog, then opens mobile navigation. It creates no Secret and contains no credentials. Tested source: 977d738, based on main 4f848ea. Environment: Linux, Node 24, local controller and sandboxed Chromium. The current navigation logo is 20 × 20 CSS pixels; the earlier 32 × 32 captures are historical.
Local controller and Chromium checks exercised sign-in, the computed primary color, Agent navigation, mobile navigation and sign-out. Six integration cases cover escaped branding, public asset boundaries, restart and isolation, malformed bundles, ConfigMap projections and the real API startup error. Helm rendering verified default-off and API-only placement. The nine
Pages/ThemingStorybook stories use the production loader with simulated page state.The existing
model-uiQA scenario now exercises a mounted theme. Secrets-only and non-browser QA do not incur a theme rollout. The new TypeScript integration test runs in the existing typecheck lane; the ordinary browser test retains screenshots only on failure. We did not run a live cluster or provider model turn locally for the final revision.Risks
Theme assets are public before authentication. This supports raster images and validated color data, not arbitrary CSS/JavaScript or external asset URLs. A malformed configured bundle prevents API startup; operators recover by restoring a valid bundle or removing the setting and restarting. Palette contrast remains an operator responsibility. This adds no database schema or Agent runtime configuration changes.
Historical verification and approved exception — Russell’s original revision
The following evidence and waiver are from the original author’s PR at 3a0527e, before the current visual integration and QA-selection changes. They are retained for review and do not establish verification of the new head.
Source:
3a0527e2c26f9059077815338c8667202c212427, based on upstreammainate8185dac805b737363c7178d3068b310a53a7c24. Runtime suites and deployment evidence used37fa6330b; the follow-up changes only the Storybook fixture selection. All changed app source files remain identical.node --test tests/integration/console-theme.test.mjs tests/integration/console-api.test.mjsnode --test tests/browser/console.test.mjsnode --test tests/integration/production-kubernetes-packaging.test.mjsLive evidence below uses Custom OCE branding on a local Podman Compose control plane with Kubernetes compute in k3d. Sign-in, Agent list/detail navigation, mobile drawer, and sign-out completed with no browser page errors. The API was healthy. All 11 changed app source files in the deployed controller match this commit. Tested controller image ID:
5daf170a1bf8bf5b4e2702505e629bfa0dacb3e2a76f4ff460633e1aa9cf9c5f.Sign-in
Desktop navigation
Mobile navigation
Interaction walkthrough: sign in, inspect an Agent, open mobile navigation, and sign out.
custom-oce-walkthrough.mp4
The full Storybook CI build passed for this commit. Its downloaded static artifact was inspected through the full manager in headless Chrome; sign-in and mobile drawer interactions passed with no browser page errors. The final artifact waits for each visible state before capture; the missing-authentication preview verifies that deployment is disabled. All nine
Pages/Themingpreviews were inspected:SignIn,Desktop,Mobile,LongName,Empty,Denied,Loading,MissingCredentials, andPublicError. These simulate resource/session/runtime state and do not prove persistence, credential propagation, or Agent execution.Long-name preview (simulated UI proof)
Canonical independent review completed through the shared autoreview helper using Codex
gpt-6.1-solat medium reasoning. The validated result isscoped-cleanfor P0–P2, with no findings, for the branch range frome8185dac805b737363c7178d3068b310a53a7c24to37fa6330b146da5afd326c24e65cc0331a151f2e. The reviewer assessed source and the sample image; it did not independently execute runtime tests. The separate canonical review of the one-line Storybook fixture follow-up (37fa6330b→3a0527e2c) also completed with a validatedscoped-cleanP0–P2 result and no findings. Together, those two reviews covered the then-current head, 3a0527e.Full Storybook manager (simulated UI proof)
Loading preview (simulated UI proof)
Missing authentication (simulated UI proof)
Human-approved verification exception:
model-ui, for both OpenClaw and Codex presets. This change affects console presentation and theme mounting; its HTTP/browser integration, deployment UI walkthrough, full Storybook build, and visual checks passed. Real model turns and native model-response execution remain unverified; the waiver does not represent passing runtime QA.