feat(ui): wire seamColor from bootstrap config to CSS custom properties (fixes #56068)#92949
feat(ui): wire seamColor from bootstrap config to CSS custom properties (fixes #56068)#92949liuhao1024 wants to merge 1 commit into
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed June 14, 2026, 7:29 AM ET / 11:29 UTC. Summary PR surface: Source +28. Total +28 across 3 files. Reproducibility: yes. at source level. Current main accepts Review metrics: 1 noteworthy metric.
Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Proof guidance:
Mantis proof suggestion Risk before merge
Maintainer options:
Next step before merge
Security Review findings
Review detailsBest possible solution: Keep the bootstrap wiring approach, but apply and clear the full Control UI accent/focus token set with focused regression tests and real browser proof. Do we have a high-confidence way to reproduce the issue? Yes, at source level. Current main accepts Is this the best way to solve the issue? No, not as submitted. The bootstrap path is the right layer, but the patch should cover focus/ring tokens and reset absent values instead of only setting a subset of accent variables. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 0716ebc1e55b. Label changesLabel changes:
Label justifications:
Evidence reviewedPR surface: Source +28. Total +28 across 3 files. View PR surface stats
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
|
|
Closing to manage open PR capacity. The fix is still valid on current main — will resubmit when capacity allows. |
Summary
Wire the
ui.seamColorconfig setting fromopenclaw.jsonthrough the gateway bootstrap endpoint to the frontend CSS custom properties. Previously, the setting was validated and stored but never included in the/control-ui-config.jsonresponse, so the frontend had no way to read it.Changes
src/gateway/control-ui-contract.ts: AddseamColor?: stringtoControlUiBootstrapConfigtypesrc/gateway/control-ui.ts: IncludeseamColor: config?.ui?.seamColorin the bootstrap config JSON responseui/src/ui/controllers/control-ui-bootstrap.ts: ReadseamColorfrom bootstrap config and apply it as CSS custom properties (--accent,--accent-muted,--accent-subtle,--accent-glow,--accent-hover,--primary) viaapplySeamColor()helperReal behavior proof
Behavior addressed:
ui.seamColorconfig setting is ignored by the web UI frontendEnvironment tested: macOS 26.4.1, Node.js v24, pnpm build
Steps run after the patch:
pnpm build— full project build including UI bundlenode scripts/run-vitest.mjs run src/gateway/control-ui.http.test.ts— gateway bootstrap endpoint testsnode scripts/run-vitest.mjs run ui/src/ui/controllers/control-ui-bootstrap.test.ts— frontend bootstrap loader testsgrep -n seamColoracross all 3 changed files to verify wiringEvidence after fix:
seamColornow flows fromopenclaw.json→ gateway bootstrap JSON → frontend CSS custom properties. TheapplySeamColor()function sets--accent,--accent-muted,--primary,--accent-subtle,--accent-glow, and--accent-hoverondocument.documentElement. All existing tests pass.seamColorvalue (requires running gateway + browser). The CSScolor-mix()andoklch()functions are used for derived colors — browser compatibility foroklch(from ...)is wrapped in try/catch as a graceful fallback.