Repository navigation
refactor(ui): retire chat pane Lit template interop - #174068
Conversation
Replace pane layout and sidebar template recipes with plain data consumed by retained Solid owners. Preserve sidebar roots, presentation gating, preview lifetime, and callback behavior. Dependency-owned header, composer, and hosted content adapters remain for the final integration cutover.
…a-layout # Conflicts: # ui/src/pages/chat/components/chat-transcript-geometry-updates.browser.test.tsx
…a-layout # Conflicts: # ui/src/pages/chat/chat-pane-embedded-panels.ts # ui/src/pages/chat/chat-pane-layout-render.ts # ui/src/pages/chat/components/chat-files-panel.tsx # ui/src/pages/chat/components/chat-sidebar-region-hosted-tabs.test.ts
…-end-content-a-layout
…a-layout # Conflicts: # ui/src/pages/chat/chat-pane-embedded-panels.test.ts # ui/src/pages/chat/chat-pane-embedded-view.tsx # ui/src/pages/chat/chat-pane-layout-render.ts # ui/src/pages/chat/chat-pane-layout-view.tsx # ui/src/pages/chat/components/chat-files-panel.tsx
|
🦞👀 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. |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex review: needs changes before merge. What this changesThis PR renders chat pane layouts and panels directly in Solid and deletes their unused Lit adapters. Example: Open preview.html in Files with its interactive counter showing Count: 1.
Review scores
ProductKind: Refactor · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Needs changes before merge - 1 item remains Keep this maintainer-directed cutover open: it removes the remaining chat template adapters, and review found no actionable introduced bug. Priority: P3 Before merge
FindingsNone. Agent review detailsHow this fits togetherThe Control UI pane runtime publishes session and layout snapshots to retained views, which render conversation controls, side panels, previews, and overlays. flowchart TD
A[Session and pane owners] --> B[Pane layout snapshot]
B --> C[Retained Solid layout]
C --> D[Conversation and header]
C --> E[Sidebar panel renderer]
E --> F[Lazy panel hosts]
C --> G[Presentation and cleanup]
Technical reviewBest possible solution: Complete the native Solid cutover while preserving current-main panel contracts and existing retained lifetimes. Do we have a high-confidence way to reproduce the issue? This is primarily a behavior-preserving refactor; source and supplied screenshots were inspected without executing target code. Is this the best way to solve the issue? Direct Solid rendering fits the established migration direction and removes the superseded shared boundary with its final callers. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against a08c6b39287b. Provenance checked
TestingProof path: shipped entry point. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource -293, Tests -419. Total -712 across 52 files. Added test files: 0. View PR surface stats
Review metrics
LabelsLabel 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 Reviewed October 16, 2026, 5:50 AM ET / 09:50 UTC. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e047b15d90
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
|
||
| export { retireSessionWorkspaceCheckout } from "./chat-session-workspace-state.ts"; | ||
| export { renderSessionWorkspaceRail } from "./chat-session-workspace-rail.ts"; | ||
| export { SessionWorkspaceRail } from "./chat-session-workspace-rail-solid.tsx"; |
There was a problem hiding this comment.
Regenerate the boot manifest after removing chat modules
This cutover deletes ui/src/lit/solid-content.tsx and chat-session-workspace-rail.ts, but ui/config/control-ui-boot-modules.json still lists both paths. Because chunk grouping and route preloads consume this generated capture, it no longer represents the reachable /chat module graph; run pnpm ui:boot-manifest:gen and commit the regenerated manifest before relying on the build result.
AGENTS.md reference: ui/AGENTS.md:L78-L81
Useful? React with 👍 / 👎.
| @@ -1,324 +0,0 @@ | |||
| import { insert, render as renderSolid, type JSX } from "@solidjs/web"; | |||
There was a problem hiding this comment.
Remove the retired interop owner from the Lit ratchet
After deleting this owner, scripts/check-control-ui-lit-ratchet.mts still exempts the exact ui/src/lit/solid-content.tsx path, and its test still asserts that Lit imports there are allowed. If a later change recreates that file, the ratchet will silently accept the regression; remove the exception, its allowance test, and the stale interop documentation as part of this cutover.
AGENTS.md reference: AGENTS.md:L48-L53
Useful? React with 👍 / 👎.
The native-video change cd486ed removed the final production call to readRuntimePromptImageOrder after runtime media facts began surviving message copies directly. Delete the reader and retain the same image-order and serialization assertions through readRuntimePromptMediaFacts. Test consolidation 7982ee6 also removed the external callers of resetCompactSessionStateMocks and createCompactHooksAuthStorage. Keep both helpers private to their existing owners. No runtime algorithm, test case, assertion, ignore, timeout, or dependency changes. Proof: 233 tests across 11 files, including every transitive importer of the changed compaction helpers, pass with pnpm test <files> --maxWorkers=1 (273.18s wall). Core, agents-other, and agents-sessions typechecks pass; scoped lint, boundary lint, formatting, and isolated P2 review pass. All three deadcode scripts were run before and after. Production and script export scans and both unused-file scans pass after the repair. The only remaining full-tree export is renderActivityGroup, already removed by active non-draft PR #174068; its exact diff and body were checked, so that peer-owned UI change is intentionally left alone.
…a-layout # Conflicts: # ui/src/pages/chat/chat-pane-render.ts # ui/src/pages/chat/chat-pane-runtime-view.tsx
|
Merged via explicitly authorized admin squash with attributed pre-existing CI failures.
|
…ge harness Main hourly 38902471699 failed check-dependencies on two exports that lost their last consumers: the SessionWorkspaceRail re-export (callers import the Solid module directly since #174068) and SynologyChatAccountRaw (only used inside types.ts since #173734). The package-openclaw-for-docker trusted-harness test copies a fixed file closure; #174133 made src/infra/npm-command.ts import ../../cli-invocation.mjs, so the harness failed with MODULE_NOT_FOUND. cli-invocation.mjs only imports node builtins. Negative control on current main fails on macOS too; with the file added the case passes.
The native-video change 85b1761 removed the final production call to readRuntimePromptImageOrder after runtime media facts began surviving message copies directly. Delete the reader and retain the same image-order and serialization assertions through readRuntimePromptMediaFacts. Test consolidation 0ed455a also removed the external callers of resetCompactSessionStateMocks and createCompactHooksAuthStorage. Keep both helpers private to their existing owners. No runtime algorithm, test case, assertion, ignore, timeout, or dependency changes. Proof: 233 tests across 11 files, including every transitive importer of the changed compaction helpers, pass with pnpm test <files> --maxWorkers=1 (273.18s wall). Core, agents-other, and agents-sessions typechecks pass; scoped lint, boundary lint, formatting, and isolated P2 review pass. All three deadcode scripts were run before and after. Production and script export scans and both unused-file scans pass after the repair. The only remaining full-tree export is renderActivityGroup, already removed by active non-draft PR openclaw#174068; its exact diff and body were checked, so that peer-owned UI change is intentionally left alone.
* refactor(ui): render chat pane layout and panels natively Replace pane layout and sidebar template recipes with plain data consumed by retained Solid owners. Preserve sidebar roots, presentation gating, preview lifetime, and callback behavior. Dependency-owned header, composer, and hosted content adapters remain for the final integration cutover. * test(ui): tighten native pane fixture callbacks * fix(ui): retain captured Review presentation during hide * refactor(ui): simplify native panel markup * test(ui): initialize attachment refresh before native mount * refactor(ui): retire orphaned Lit template adapters * test(ui): fix native chat pane fixtures * test(ui): explain isolated pane renderer mocks
…ge harness Main hourly 38902471699 failed check-dependencies on two exports that lost their last consumers: the SessionWorkspaceRail re-export (callers import the Solid module directly since openclaw#174068) and SynologyChatAccountRaw (only used inside types.ts since openclaw#173734). The package-openclaw-for-docker trusted-harness test copies a fixed file closure; openclaw#174133 made src/infra/npm-command.ts import ../../cli-invocation.mjs, so the harness failed with MODULE_NOT_FOUND. cli-invocation.mjs only imports node builtins. Negative control on current main fails on macOS too; with the file added the case passes.
What Problem This Solves
Retires the remaining Lit template interop in chat pane layouts, side panels, and their coupled fixtures. Against
1dbc6fb1f327fb861889c8abf8174fbf73052f24, scoped chat interop files fall 37 → 0, including production 18 → 0, completing the campaign's 132 total / 88 production → zero cutover.User Impact
Chat keeps its existing tags, controls, keyboard/focus behavior, lazy loading, and retained panel identity. Selected Review content also retires correctly when its pane is hidden while the selection is cleared.
Why This Change Was Made
The pane snapshot carries plain layout and panel data. Retained Solid components own the header, conversation, background, panels, and overlays directly. Native header, Details, outbox recovery, tool-icon, plugin-panel, and Files lifecycle owners remain authoritative. Review presentation is captured beside selected content, so hiding a pane cannot reread a newer selection and leave old content connected.
Sidebar definitions use the canonical
IconNamecontract, and conversation identity uses plainAgentIdentitydata. Native SVG placement, namespace, filled-shape and gradient assertions remain. The final consumers were also the last users ofsolid-content.tsx; this PR removes that renderer, its obsolete dedicated tests, and orphaned chat adapters together. Dependencies and migration-policy retirement remain with their owners.This is one complete renderer cutover: 46 files, 22 production, including coupled fixtures and shared owner deletion. Splitting the orphan removal would leave production Knip failing. Touched production LOC is 6,094 → 5,799 (−295; +376/−671); tests/support +453/−848 (−395). The integration preserves main's canonical icon and embedded-plugin owners.
Evidence
Final candidate:
80686b31abf24f4ad5eb8f308a9207400c5b1f5d; baseline:1dbc6fb1f327fb861889c8abf8174fbf73052f24.pnpm tsgo:uipassedpnpm deadcode:knippassed on final integrated head; no ignoresscoped-clean; no actionable findingsci:fullrun 38895268310, attempt 1, completed: all UI units/types/lint, browser-extension bootstrap, eight E2E shards, both real-Gateway shards, security and performance passed. Only the two inherited jobs below failedThe native inherited-failure exception covers two failed jobs in the exact final-head run. Its tested merge is
73e1c13624e03d07985bad796d21c80183424122, with ordered parents mainbc8b7ddb1b14cb1d4bcac3741316630f52b174bdand head80686b31abf24f4ad5eb8f308a9207400c5b1f5d:checks-ui-e2e (6/9): Models page keeps controls separate and publishes discovery into a passive picker, at 1440, 1100, 768, 640 and 390 px. Main already contains the unconditional seventh Utility Fallback Model row introduced by6861671cda97642a02854d085bd04ecc6fd9bb98, while its E2E expectation lists six rows. The test, complete Models settings directory, helper and English catalog are byte-identical between the tested main base and PR merge.checks-fast-baseline-ratchets: assertion-safety requires shrinkingsrc/media/media-facts.tsfrom baseline 16 → 14. Main's9b9933e290removes unused media-reader exports and two type assertions without pruning that entry. The media source, baseline and checker are byte-identical between tested main and PR merge; every other subratchet passed.Both failures also reproduce in completed scheduled main run 38894297213 at
1dbc6fb1: the same five Models names and extra row, and the same media 14 < 16 signature. They have both exact-signature and unchanged-source attribution independent of shard names. No affected main owner or baseline is changed here, and this CI run is not claimed green.Fresh paired build, strict startup, and four-state visual proof was captured on exact baseline
1dbc6fb1f327fb861889c8abf8174fbf73052f24and head80686b31abf24f4ad5eb8f308a9207400c5b1f5don the same machine. Chat boot improves 31 → 30 requests, 1,654,035 → 1,644,751 B (−9,284). All four refreshed full PNG pairs are byte-identical; all eight also match the already-published screenshots below, which were individually inspected again. Both sides had no page errors and preserved the same iframe and interactive Count 1 through Swap. Lazy registration/import boundaries remain in their existing owners; no startup entry import was added.The latest merge integrates
1dbc6fb1only because native landing found real conflicts in two renderer files. It preserves main’screateChatProviderReviewowner,readProviderReviewState,render(readProviderReview), andproviderReviewSourcewhile retaining directPaneLayoutJSX and its null empty layout. Current-head UI types, 53 focused pane/frame/geometry tests, scoped lint/format/diff checks pass; the complete current diff has a fresh validated P2scoped-cleanreview. Paired startup and four-state visual proof passed against that exact baseline; current screenshots match all eight published images.The two P2 inventory notes are assigned to final migration cleanup. Deleted boot-module paths occur only in grouping membership sets, never dynamic entry lists; grouping matches resolved modules and route preloads walk emitted chunks, so those stale entries are inert. Global capture refresh and the Lit ratchet, its allowance test, interop guidance, and dependency retirement stay with that final cleanup owner after the remaining lane PRs land. Existing lazy entry points remain unchanged.
createEffectcreateRenderEffectuntrackaddEventListenerquerySelector(All)flushrunWithOwner/getOwnerRetained host updates belong to synchronous pane/domain owners. Effects and listeners bind external presentation, hosted tabs, focus, and Files DOM settlement with existing cleanup. Queries cross retained panel/host islands. One
untrackcaptures the stable runtime identity; the other restores a deliberate hosted-header mount under its captured owner.