Skip to content

refactor(ui): move terminal, browser, and desktop panels to Solid - #168786

Merged
steipete merged 20 commits into
mainfrom
solid2/w-pg-5a
Oct 11, 2026
Merged

steipete merged 20 commits into
mainfrom
solid2/w-pg-5a

Conversation

@steipete

@steipete steipete commented Oct 11, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Ports the terminal, browser, and desktop panels from Lit to Solid while the remaining Lit shell callers continue using their registered tags.

User Impact

The existing routes, host tags, CSS classes, dock controls, and selectors remain. Terminal sessions retain their independent DOM islands and server-session lifetime. noVNC keeps ownership of its canvas and input subtree through connection and control handoffs.

Why This Change Was Made

Synchronous TypeScript controllers remain the state owners. The canonical Solid bridge and shared committed-DOM lifecycle publish their state to Solid. Each registered panel has one implementation. The remaining Lit tab-strip callers use a thin adapter to the same Solid renderer; their event and ref receivers are preserved.

Conditional terminal empty-state content uses the same registered primitive through its custom-element boundary so nested rendering cannot flush before the parent attaches. The migration now covers actual connection boundaries: detached bridge mounting, native browser geometry after nested rendering, reactive first browser refreshes, retained noVNC surfaces, and Web Awesome tab insertion/focus. There is no new dependency or domain store.

Release-note context: internal Control UI renderer migration, preserving terminal/server-session and desktop/viewer lifetimes.

Evidence

Check Result
Shared bridge / panel lifecycle 2 / 3 passed; final bridge run 3.71 s
Tab strip unit / browser layout 19 / 4 passed; final tab run 4.05 s / browser 3.03 s
Terminal cancellation / reconnect / hosted tabs 11 / 9 / 9 passed; 8.80 s / 32.24 s / 20.59 s
Draft native terminal start 14 passed; 126.81 s
Terminal panel / restore 29 / 19 passed; final panel run 24.04 s
Desktop panel / CSS 28 / 1 passed; final panel run 20.53 s
Browser panel / native / input / touch 19 / 41 / 24 / 5 passed; 61.54 s / 41.77 s / 45.45 s / 58.32 s
Terminal transport / controller lifecycle / queue / pending intents 49 / 11 / 1 / 3 passed
Browser route and wheel dispatch 16 passed; 4.86 s, wheel cancellation exercised on the rendered viewport
Browser controller / stale snapshots / viewport 21 / 8 / 7 passed; controller rerun after main integration: 19.33 s
Real-browser accessibility 4 passed; 10.82 s, including tab/action accessibility-tree separation
Mixed-panel layout regression Passed in Chromium; 2.72 s, reproduced fixed positioning before repair
Shared control ownership / chat tool cards 3 / 38 passed after integration; 8.77 s / 11.05 s
Focused lint, formatting, styles, i18n, whitespace and migration ratchets Passed
ClawSweeper Exact-head review: no findings; ready for maintainer landing
Independent autoreview Complete merged-candidate P0–P2 review clean after fixing inactive-tab activation
Full typechecks, UI build, unit shards and E2E Exact-head PR CI passed: 59 jobs passed or skipped by scope after conflict resolution and CSS repair
Synthetic visual parity 26 states × desktop/mobile × light/dark; 208 PNGs per revision including full-page and crop; 52 published comparison images

Local tests were single-file invocations with --maxWorkers=1; the supported direct UI runner was also used when wrapper startup stalled. Earlier panel/restore fixtures were compared with the base (29 and 19 passing tests). Final exact-head job durations: production types 235 s; UI unit shards 364 / 366 / 351 s; UI E2E 256 s; the formerly failing core test-type stripe 406 s. These are whole-job durations including setup.

One Testbox lease did not admit within about 15 minutes and was stopped without running tests. No alternate provider was used. Heavy suites/typechecks/builds are delegated to PR CI. The bounded synthetic captures used isolated Vite servers, mock Gateway data and a scripted real RFB exchange; no live Gateway or private data was used. Temporary CI capture tooling has been removed from the change.

Three candidate browser captures reported a recoverable Chromium ResizeObserver loop warning. All three settled and passed; the existing observer policy is retained.

Visual baseline: 53b8118647525c9e855a6d276ed3eef5dfef9464. Candidate: 0b3c295dbb29326a2cc6225c53256eeb71bcf7f5.

Affected UI LOC Before After
Production 9,716 11,233
Tests and support 18,257 19,140

Counts compare the integrated candidate against main parent cb2a3ce3dda69bd6781411bb0b13ec7b9486b08f, include all affected UI files, and exclude temporary proof tooling. Production growth comes from explicit registrations, light-DOM style scoping, and rendering/lifecycle boundaries replacing Lit decorators. Consolidating the shared tab strip removes its duplicate implementation.

Validation repairs and integration

Migrated JSX now uses the pinned Solid attribute/property contracts, and retained Lit test callers await the public bridge completion. The shared tab renderer intercepts explicit activation before Web Awesome selection and binds wheel input through a non-passive native listener. The shared declarations also serve the landed chat leaf components; their new-tab controls may supply a DOM node.

The last conflict resolution preserves that DOM-node contract. Review then reproduced a mixed-panel CSS cascade bug: later shared styles could override embedded positioning. The shared default now uses lower specificity, with a Chromium regression that fails before the repair and passes after it. The one remaining review claim was rejected because the ownership helper deliberately normalizes .tsx to .ts; its three tests pass unchanged.

The inherited duplicate-scan coverage failure for worker-heap-flag.mjs was fixed upstream in cd6509510b12d and integrated. That main repair passes isolated coverage and full duplicate checks (0.418 s / 15.393 s).

Screenshots

Every image pairs the Lit baseline and Solid candidate in columns, with light/dark rows. All captures use synthetic fixtures and were inspected before upload. All 52 uploaded images were verified to load in the PR.

Work in progress for the page migration lane. Renderer and controller cutover is prepared; canonical Solid bridge registration and its dependent runtime proof follow once the primitive bridge lands on main.
Work-in-progress checkpoint while the primitive bridge lands. Preserve synchronous controller input ownership and imperative completion, migrate the test harnesses, and prepare temporary CI-only synthetic captures after Testbox did not admit a runner. The capture hooks will be removed after evidence is retained.
Keep tab, viewport, and picker ARIA associations unique across split panes. Preserve the bridge-owned test inputs and cover embedded plain-controller viewport reservations.
@clawsweeper

clawsweeper Bot commented Oct 11, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added app: web-ui App: web-ui scripts Repository scripts size: XL labels Oct 11, 2026
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Oct 11, 2026
@clawsweeper

clawsweeper Bot commented Oct 11, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

This PR moves Terminal, Browser, Desktop, and shared panel tabs from Lit to Solid while preserving their controllers and host tags.

Example: Open Browser and Desktop together in embedded panels, then load Terminal.

  • Before: The earlier migration candidate’s shared styles made the embedded sections fixed-position.
  • After: The repaired candidate keeps both sections positioned within their allocated layout.

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A coherent, maintainer-directed migration with inspected visual evidence, meaningful lifecycle coverage, and successful exact-head CI; runtime evidence is fixture-based.
Proof confidence 🐚 platinum hermit (4/6) ✨ media proof bonus Sufficient (screenshot): Inspected representative before/after production-renderer captures using synthetic Gateway and RFB fixtures, plus desktop/mobile CSS regression images; lifecycle tests and successful exact-head CI support the cutover, without claiming live Gateway or native-device verification.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Refactor · Worth it: Yes · Fix scope: Complete
User problem: These panels remain on the older renderer during the approved Control UI migration.
Reason: Maintainer direction is established, and the patch preserves the existing user contracts while consolidating rendering ownership.

Merge readiness

✅ Ready for maintainer review

Keep this maintainer-directed migration open for normal landing; no actionable defect remains in the reviewed head, and exact-head CI passed.

Priority: P2
Reviewed head: 58fda123cdf9afe45b476b45dd2b34e5314c00f6

Before merge

None.

Findings

None.

Agent review details

How this fits together

Control UI panel hosts receive Gateway clients and presentation inputs, retain synchronous controllers, and render controls around terminal and noVNC-owned DOM islands.

flowchart TD
  A[Control UI shell and routes] --> B[Registered panel bridges]
  B --> C[Synchronous panel controllers]
  C --> D[Solid panel renderers]
  D --> E[Shared tabs and dock controls]
  C --> F[Gateway and transport clients]
  D --> G[Terminal and noVNC DOM islands]
Loading

Technical review

Best possible solution:

Land the unified Solid renderers with the existing controller, transport, and retained-DOM ownership contracts.

Do we have a high-confidence way to reproduce the issue?

This is a renderer refactor; source inspection and supplied browser evidence establish the relevant behavior without running target code.

Is this the best way to solve the issue?

The change follows the approved bridge migration, preserves synchronous domain owners, and replaces the panel renderers without creating competing implementations.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 85018936a338.

Provenance checked

  • Shared tab rendering keeps the original intent (a864c64: One shared strip prevented Browser and Terminal tab behavior from drifting.)
  • Desktop connection handoff keeps the original intent (1b236df: Retain the predecessor viewer until the replacement authenticates, while immediately disabling predecessor input.)
  • Custom-element rendering ownership keeps the original intent (refactor(ui): share presentation primitives across Solid and Lit #168576: Provide one Solid implementation per tag while remaining Lit callers use the canonical bridge.)

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

Likely related people:

  • Peter Steinberger: Raw commit babf04c adds ui/src/components/terminal/terminal-panel-session-controller.ts:85 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: babf04ca0fcb; files: ui/src/components/terminal/terminal-panel-session-controller.ts)

PR surface

PR surface statistics unavailable: the file list is incomplete.

Review metrics

Metric Value Why it matters
Production versus test growth Production +6,132/-4,615; tests and support +1,831/-948. Net growth matches the body’s figures and is explained by explicit bridge registrations, scoped styles, and shared lifecycle boundaries.

Labels

Label changes:

No label changes.

Label justifications:

  • P2: An approved internal UI migration with integration value and no identified urgent user-facing defect.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.
  • proof: sufficient: Contributor real behavior proof is sufficient.
  • proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence.

Rating scale

6/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.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only; repair and merge need explicit maintainer commands such as @clawsweeper autofix or @clawsweeper automerge.

History

Review history (8 earlier review cycles)
  • reviewed 2026-10-11T01:21:49.570Z sha 6f9a2b1 :: needs changes before merge. :: [P2] Migrate the remaining Desktop E2E queries to light DOM | [P2] Update the New Session caller to inject its terminal mock
  • reviewed 2026-10-11T06:55:44.313Z sha 0b3c295 :: needs changes before merge. :: [P2] Inject the terminal mock in the remaining New Session fixture
  • reviewed 2026-10-11T11:09:55.326Z sha ae67b1f :: needs changes before merge. :: none
  • reviewed 2026-10-11T11:25:41.577Z sha fc1d8e6 :: needs changes before merge. :: [P2] [P2] Update the divider ownership inventory for the Solid renderer
  • reviewed 2026-10-11T11:42:48.964Z sha 395d30f :: needs changes before merge. :: none
  • reviewed 2026-10-11T12:19:29.435Z sha f05bbf5 :: needs changes before merge. :: none
  • reviewed 2026-10-11T13:00:16.101Z sha 6374847 :: needs maintainer review before merge. :: none
  • reviewed 2026-10-11T13:43:45.684Z sha 58fda12 :: needs maintainer review before merge. :: none

Reviewed October 11, 2026, 9:50 AM ET / 13:50 UTC (Revision 9).

@openclaw-barnacle openclaw-barnacle Bot removed the scripts Repository scripts label Oct 11, 2026
@steipete

Copy link
Copy Markdown
Contributor Author

Synthetic terminal parity

Before/after columns; light/dark rows. Desktop and mobile states were captured from the Lit baseline and Solid port, then inspected for incidental data.

terminal-connected — desktop, before/after and light/dark

terminal-connected — mobile, before/after and light/dark

terminal-error — desktop, before/after and light/dark

terminal-error — mobile, before/after and light/dark

terminal-loading — desktop, before/after and light/dark

terminal-loading — mobile, before/after and light/dark

terminal-page-connected — desktop, before/after and light/dark

terminal-page-connected — mobile, before/after and light/dark

terminal-page-unavailable — desktop, before/after and light/dark

terminal-page-unavailable — mobile, before/after and light/dark

terminal-restored — desktop, before/after and light/dark

terminal-restored — mobile, before/after and light/dark

terminal-session-picker — desktop, before/after and light/dark

terminal-session-picker — mobile, before/after and light/dark

@steipete

Copy link
Copy Markdown
Contributor Author

Synthetic browser parity

Before/after columns; light/dark rows. Desktop and mobile states were captured from the Lit baseline and Solid port, then inspected for incidental data.

browser-annotate — desktop, before/after and light/dark

browser-annotate — mobile, before/after and light/dark

browser-connected — desktop, before/after and light/dark

browser-connected — mobile, before/after and light/dark

browser-empty — desktop, before/after and light/dark

browser-empty — mobile, before/after and light/dark

browser-error — desktop, before/after and light/dark

browser-error — mobile, before/after and light/dark

browser-loading — desktop, before/after and light/dark

browser-loading — mobile, before/after and light/dark

browser-not-running — desktop, before/after and light/dark

browser-not-running — mobile, before/after and light/dark

browser-document-connected — desktop, before/after and light/dark

browser-document-connected — mobile, before/after and light/dark

browser-document-unavailable — desktop, before/after and light/dark

browser-document-unavailable — mobile, before/after and light/dark

@steipete

Copy link
Copy Markdown
Contributor Author

Synthetic desktop 1 parity

Before/after columns; light/dark rows. Desktop and mobile states were captured from the Lit baseline and Solid port, then inspected for incidental data.

desktop-connected — desktop, before/after and light/dark

desktop-connected — mobile, before/after and light/dark

desktop-connecting — desktop, before/after and light/dark

desktop-connecting — mobile, before/after and light/dark

desktop-control — desktop, before/after and light/dark

desktop-control — mobile, before/after and light/dark

desktop-credentials — desktop, before/after and light/dark

desktop-credentials — mobile, before/after and light/dark

desktop-disconnected — desktop, before/after and light/dark

desktop-disconnected — mobile, before/after and light/dark

desktop-dock-bottom — desktop, before/after and light/dark

desktop-dock-bottom — mobile, before/after and light/dark

@steipete

Copy link
Copy Markdown
Contributor Author

Synthetic desktop 2 parity

Before/after columns; light/dark rows. Desktop and mobile states were captured from the Lit baseline and Solid port, then inspected for incidental data.

desktop-dock-connected — desktop, before/after and light/dark

desktop-dock-connected — mobile, before/after and light/dark

desktop-inventory-error — desktop, before/after and light/dark

desktop-inventory-error — mobile, before/after and light/dark

desktop-sources-empty — desktop, before/after and light/dark

desktop-sources-empty — mobile, before/after and light/dark

desktop-sources-loading — desktop, before/after and light/dark

desktop-sources-loading — mobile, before/after and light/dark

desktop-sources-ready — desktop, before/after and light/dark

desktop-sources-ready — mobile, before/after and light/dark

@steipete

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

The repaired head is ae67b1f2c0f9f474643869a0bb3373b8b9c9ac34. The draft native-terminal fixture now uses its existing panel helper (14 passing tests), the Lit/assertion ratchets are repaired, and all 52 synthetic comparison images are uploaded and linked from the PR body. The merged candidate passed independent P0–P2 review after fixing inactive-tab activation ordering.

@clawsweeper

clawsweeper Bot commented Oct 11, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added proof: sufficient ClawSweeper judged the real behavior proof convincing. and removed rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. labels Oct 11, 2026
steipete added a commit that referenced this pull request Oct 12, 2026
The tab-strip assertion added in #168786 (89564fa) reads a root-relative
path while the CI command runs in ui/. Resolve the filesystem path from
import.meta.dirname so the same assertions run from either directory.
Keep the existing stylesheet assertion unchanged.

Linux proof: 29/29 focused tests, 5s command wall at maxWorkers=1.
The affected full UI shard passes in 148s; test types and typed/boundary
lint pass. Independent P2 review has no actionable findings.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 12, 2026
Hourly 38119289515 job 114410626720 stopped the real-Gateway desktop
resize proof at test-node/node-admission. The rejected RPC was
node.pair.approve: INVALID_REQUEST, unknown requestId. SSH validation and
cleanup succeeded.

f92efac (openclaw#163862) intentionally made the Gateway approve initial
local node capabilities. The fixture retained a competing manual approval
and could consume a request that the Gateway had already resolved. This
predates the supplied regression window: hourly 38101298609 at 3193cda
has the same failure. Linux parent/child proof: 8339d09 passed 50
admissions; f92efac failed admission 3. The original failing head
9561277 reproduced the RPC rejection on admission 17.

Remove the fixture's node.pair.list/approve path and retain its existing
approved, paired, connected, sessionHost and device-identity checks. Update
the two caller comments to name the Gateway's ownership. No production
behavior, assertions, retries, deadlines, or skips change.

Linux proof (historical refs for attribution and negative control):
- Fixed helper: 50 admissions passed in 156.75s. Reverting only the helper
  reproduced the rejection on admission 4 in 18.89s.
- Ten complete desktop proofs passed, including 20 node/SSH carrier runs;
  65.46-83.24s per bootstrap. Original CI test-node wall was 39.49s.
- Desktop proof-helper suite: 50 tests passed in 32.91s using
  pnpm test test/scripts/desktop-resize-proof.test.ts --maxWorkers=1.
- Changed checks passed in 414.09s; changed-file oxlint, boundary oxlint,
  oxfmt and independent P0-P2 review passed.
- Full general E2E: 239 passed, 28 failed, 12 skipped files across all four
  shards; 38 of 39 failed tests reproduce on the unchanged base. The
  Telegram menu timeout did not reproduce in its targeted baseline.
- Full UI and prebuilt real-Gateway inventories were exercised. The
  worker-initial-setup failure reproduces on the unchanged base. A
  delegation approval-card timeout did not reproduce alone or in the full
  baseline file order. Missing WebKit in the fallback environment was
  corrected; its two native bundle parity cases passed afterward.

The full-suite and changed-check candidate tree matches the final staged
tree: 789591f5c143c86c3376de0d84f7782bb3f8ec2b.

openclaw#168786: in-flight overlap, unrelated. This change avoids its rendering
hunks. Broader baseline failures and the two unreproduced timeouts are
retained in the lane evidence, not hidden or treated as passing proof.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 12, 2026
…enclaw#168786)

* refactor(ui): checkpoint Solid terminal browser and desktop port

Work in progress for the page migration lane. Renderer and controller cutover is prepared; canonical Solid bridge registration and its dependent runtime proof follow once the primitive bridge lands on main.

* Merge remote-tracking branch 'origin/main' into solid2/w-pg-5a

* refactor(ui): wire panel controllers to the Solid bridge

Work-in-progress checkpoint while the primitive bridge lands. Preserve synchronous controller input ownership and imperative completion, migrate the test harnesses, and prepare temporary CI-only synthetic captures after Testbox did not admit a runner. The capture hooks will be removed after evidence is retained.

* fix(ui): scope Solid panel references to each mounted view

Keep tab, viewport, and picker ARIA associations unique across split panes. Preserve the bridge-owned test inputs and cover embedded plain-controller viewport reservations.

* Merge remote-tracking branch 'refs/remotes/wpg5a/main' into solid2/w-pg-5a

* refactor(ui): share the Solid panel commit lifecycle

* test(ui): prepare panel runtime and parity proof

* test(ui): retain terminal runtime proof through the Solid bridge

* Merge remote-tracking branch 'origin/main' into solid2/w-pg-5a

* refactor(ui): integrate panel views with Solid bridge ownership

* fix(ui): preserve Solid panel lifecycle and rendering contracts

* fix(ui): retain legacy rendering at migration boundaries

* fix(ui): preserve panel contracts across main integration

* fix(ui): correct panel JSX element types

* fix(ui): share tab element contracts with migrated chat

* fix(ui): bind browser wheel input through native events

* test(ui): await panel bridge before accessibility queries

* test(ui): declare panel fixture lifecycle overrides

* chore(ui): integrate repaired main validation

* fix(ui): preserve shared panel contracts across main

Co-authored-by: Peter Steinberger <[email protected]>
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 12, 2026
The tab-strip assertion added in openclaw#168786 (6d48380) reads a root-relative
path while the CI command runs in ui/. Resolve the filesystem path from
import.meta.dirname so the same assertions run from either directory.
Keep the existing stylesheet assertion unchanged.

Linux proof: 29/29 focused tests, 5s command wall at maxWorkers=1.
The affected full UI shard passes in 148s; test types and typed/boundary
lint pass. Independent P2 review has no actionable findings.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: web-ui App: web-ui P2 Normal backlog priority with limited blast radius. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: XL status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant