Skip to content

refactor(ui): port sibling session pages to Solid - #169300

Merged
steipete merged 11 commits into
mainfrom
solid2/w-chat-8a
Oct 12, 2026
Merged

steipete merged 11 commits into
mainfrom
solid2/w-chat-8a

Conversation

@steipete

@steipete steipete commented Oct 11, 2026 •

Copy link
Copy Markdown
Contributor

Problem and change

Ports Custodian, Apps, question, approval, and Skill Workshop from Lit to Solid 2, keeping their registered tags, routes, CSS classes, selectors, and lazy entry points. Each ported tag has one Solid bridge implementation; the old Lit classes are removed. Remaining shared wizard controls and the Workshop agent picker stay behind their existing Lit boundary.

Request admission, generation checks, cancellation, and domain state remain with the existing synchronous owners. Solid consumes their projections. Custodian alert visibility also follows session-authority changes, so stale diagnostics retire when the administrator, profile, or Gateway changes. Custodian uses the current shared MessageGroup, OptionCard, and Markdown owners.

The build omits redundant transitive static JavaScript from dynamic preload hints while preserving lazy targets, other dependencies, CSS hints, and execution order. This keeps the initial module set unchanged and prevents startup growth. No dependency, backend contract, or new domain owner is introduced.

Touched page production source: 4,147 → 4,625 lines (+478). The increase is explicit Solid lifecycle/projection code and JSX replacing Lit decorators and templates.

Validation

Check Result
Focused page tests Initial 193 cases / 18 files passed (10.44 s); affected cases rerun after shared-main integration
Custodian and update-triage 122 passed (8.16 s); later focus/triage integration subset: 36 passed (5.26 s)
MCP views 27 passed after latest fixture integration (8.41 s)
Build configuration/chunking 39 passed (4.29 s)
Page E2E 44 targeted outcomes pass after fixture correction; all 7 event-nudge cases passed (22.80 s)
Additional Custodian regressions from CI Eight locale, activation-review, first-run, and reconnect cases passed unchanged (74.44 s)
UI types, scoped lint, i18n, Lit/assertion-safety/line-cap ratchets Passed; current-head CI UI test shards and type/lint checks passed
Visual parity All 10 captured scenes pixel-identical: five pages × desktop-light/mobile-dark
Same-host production build and startup measurement 412,876 → 412,803 B gzip (−73 B); 8 startup JavaScript requests unchanged
Independent review No actionable findings after port and follow-up fixes

The strict performance checker reports the same inherited chat-boot request excess on both sides: 36 requests versus a limit of 35. Startup itself does not grow. The paired comparison uses main baa363f7e9bf4aca1f810aaef35e2442cf76fcb5 and the same toolchain/build identity.

Page E2E coverage includes approval-page, question-flow, custodian-channel-onboarding, custodian-event-nudge, and plugins-help. Apps also uses the MCP conversation boundary tests. Skill Workshop has no dedicated E2E file; page behavior tests and routed screenshots cover its port. The shared mock Gateway now returns the canonical typed empty channels status; the event-nudge fixture explicitly supplies an active configured channel to isolate its zero-event-nudge expectation.

Testbox was attempted once. Its lease completed before E2E reuse, so bounded local proof used one worker; no full repository suite or local Docker was run. Lease tbx_01m4p03v9z8ez1bav3m7bw57sv is completed with no active runner.

Screenshots

All captures use inspected synthetic mock-Gateway data. The full-resolution before/after pairs are pixel-identical.

Before: five pages in desktop-light and mobile-dark

After: five pages rendered with Solid

The additional Chinese onboarding capture and regression proof are in the linked review comment: #169300 (comment)

Inherited CI disposition

Current-head run 38195673218 completed with exactly three failed jobs and no cancellations. All UI unit-test shards, UI types/lint, and security-fast passed. The remaining failures are independently inherited:

  • Five pasted-text assertions and the Add MCP server dialog assertion in the unchanged /chat composer also fail in scheduled main run 38197887998, which does not contain this PR. Local exact-baseline and tested-merge replays pass all seven pasted-text cases plus the MCP case; those passes do not replace the independent main CI evidence.
  • The wrapper dependency-closure test rejects three duplicate entries already present in the identical baseline scripts/pr-lib/wrapper-components.txt; this PR changes neither the inventory nor its assertion.

Landing uses the explicitly authorized native inherited-failure/admin route with retained, hashed checkout/failure evidence. It does not claim the CI gate passed or waive review/security requirements.

Preserve Custodian, Apps, question, approval, and Skill Workshop behavior through lazy Solid bridges. Keep shared wizard and route templates as stateless Lit adapters until their owners migrate. Consolidate already-eager foundation chunks to reduce startup transfer without expanding the initial module set.
@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 P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. 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 changes before merge.

What this changes

This PR ports five Control UI pages from Lit to Solid while preserving their routes and existing state owners.

Example: Open /apps on a phone using the dark theme.

  • Before: Lit renders the companion-app cards and installation links.
  • After: Solid renders the same cards and links through the existing route.

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) Useful migration with inspected browser proof and preserved owner boundaries; one actionable P3 locale dependency remains.
Proof confidence 🦞 diamond lobster (5/6) ✨ media proof bonus Sufficient (screenshot): Inspected before/after browser captures exercise all five page routes in desktop-light and mobile-dark against a synthetic mock Gateway; the additional Chinese onboarding capture exercises the native Solid message and option-card presentation.
Patch quality 🐚 platinum hermit (4/6) 1 actionable review finding remain.

Product

Kind: Refactor · Worth it: Yes · Fix scope: Complete
User problem: These pages remain on the retiring Lit renderer during the Control UI's Solid migration.
Reason: The maintainer-authored change follows the repository's explicit Solid migration direction, removes the replaced Lit implementations, and preserves existing routes, controllers, and shared capabilities.

Merge readiness

⛔ Needs changes before merge - 1 item remains

Keep this PR open: the maintainer-directed Solid migration remains necessary, but the previously reported P3 timestamp-localization defect is unresolved.

Priority: P3
Reviewed head: 61b4b72317b38c13289469337647bc253692fdbe

Before merge

  • Use the reactive formatter for mounted history timestamps (P3) - The previously reported defect remains at this head. Open Recent changes in English, retain its rows, then switch to German: labels update, but the timestamp can remain in English because lib/format.ts reads the locale without establishing a Solid dependency. WorkshopChangeText at view-shared.tsx:25 and the saved-version timestamp at detail.tsx:400 have the same bare expression. Import formatRelativeTimestamp from lib/reactive/format.ts in all three consumers so existing mounted rows observe locale changes.

Findings

  • [P3] Use the reactive formatter for mounted history timestamps — ui/src/pages/custodian/custodian-history.tsx:4
Agent review details

How this fits together

The Control UI receives Gateway snapshots and events through existing controllers, projects their state into page components, and sends user actions through the same Gateway operations.

flowchart LR
  A[Browser routes] --> B[Solid bridges]
  B --> C[Page components]
  D[Existing state owners] --> E[Reactive projections]
  E --> C
  C --> D
  D --> F[Gateway operations]
Loading

Technical review

Best possible solution:

Complete the Solid cutover using the existing reactive formatting owner for locale-sensitive timestamps.

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

Source establishes the timestamp defect: retained JSX timestamp expressions observe row data but no locale signal, whereas the former Lit base refreshed the whole view on locale changes; no target code was executed during this review.

Is this the best way to solve the issue?

The migration follows the existing Solid bridge and projection architecture; changing three formatter imports is the smallest repair and avoids another formatting owner.

Full review comments:

  • [P3] Use the reactive formatter for mounted history timestamps — ui/src/pages/custodian/custodian-history.tsx:4
    The previously reported defect remains at this head. Open Recent changes in English, retain its rows, then switch to German: labels update, but the timestamp can remain in English because lib/format.ts reads the locale without establishing a Solid dependency. WorkshopChangeText at view-shared.tsx:25 and the saved-version timestamp at detail.tsx:400 have the same bare expression. Import formatRelativeTimestamp from lib/reactive/format.ts in all three consumers so existing mounted rows observe locale changes.
    Confidence: 0.99

Overall correctness: patch is correct
Overall confidence: 0.94

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 80d82cacade5.

Provenance checked

  • Standalone approval page keeps the original intent (4eb1f52: Provide authenticated, durable approval links without altering the full application's saved Gateway selection.)
  • Standalone question page keeps the original intent (ef95d8f: Let users supply credentials through masked questions without exposing them in conversation content.)
  • Custodian shared surface keeps the original intent (699315e: Share the existing conversation between the settings page and dockable panel.)
  • Apps discovery page keeps the original intent (654560f: Expose companion apps, installation links, and pairing from inside the Control UI.)
  • Skill Workshop list and detail keeps the original intent (a42afa5: Keep each skill's instructions, files, history, comparison, and undo actions together.)
  • JavaScript preload filtering keeps the original intent (bb2d479: Exclude already imported static JavaScript from lazy preload tables while preserving other JavaScript and CSS hints.)

Testing

Proof path: shipped entry point.

Security

None.

Evidence

Acceptance criteria:

  • pnpm test ui/src/pages/skill-workshop/skill-workshop-page.test.tsx --maxWorkers=1
  • pnpm test ui/src/pages/custodian/custodian-page.nudges.test.ts --maxWorkers=1
  • pnpm tsgo:ui
  • git diff --check
  • Browser: retain populated Custodian and Workshop history rows, switch English to German, and verify timestamps update without refetching or replacing the rows.

What I checked:

PR surface

Source +486, Tests +27, Other -1. Total +512 across 55 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 35 3711 3225 +486
Tests 18 118 91 +27
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 2 1 2 -1
Total 55 3830 3318 +512

Labels

Label changes:

No label changes.

Label justifications:

  • P3: This is an internal renderer migration with one low-impact localization defect and no established urgent workflow regression.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster and patch quality is 🐚 platinum hermit.
  • status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action.
  • 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 execution lanes are retired.

History

Review history (11 earlier review cycles; latest 8 shown)
  • reviewed 2026-10-11T21:06:12.653Z sha 6ab3c70 :: needs maintainer review before merge. :: none
  • reviewed 2026-10-11T21:53:52.131Z sha 2f90334 :: needs changes before merge. :: [P2] Import MarkdownBlocks from its moved owner on main
  • reviewed 2026-10-11T22:12:27.719Z sha 2f90334 :: needs changes before merge. :: [P2] Import MarkdownBlocks from the current owner module
  • reviewed 2026-10-11T23:04:30.449Z sha b1514a6 :: needs changes before merge. :: none
  • reviewed 2026-10-12T00:28:50.519Z sha 1a93382 :: needs changes before merge. :: none
  • reviewed 2026-10-12T01:01:11.816Z sha 0642ab4 :: needs changes before merge. :: [P3] Use the reactive formatter for mounted history timestamps
  • reviewed 2026-10-12T02:32:20.282Z sha 61b4b72 :: needs changes before merge. :: [P3] Use the reactive formatter for mounted history timestamps
  • reviewed 2026-10-12T04:00:00.774Z sha 61b4b72 :: needs changes before merge. :: [P3] Use the reactive formatter for mounted history timestamps

Reviewed October 12, 2026, 12:22 AM ET / 04:22 UTC (Revision 12).

# Conflicts:
#	ui/config/control-ui-chunking.ts
#	ui/src/app/control-ui-chunking.test.ts
@steipete

Copy link
Copy Markdown
Contributor Author

After migration: the five page routes remain visually identical in desktop-light and mobile-dark. All captures use synthetic mock-Gateway data.

After: the five pages rendered with Solid

@clawsweeper clawsweeper Bot added proof: sufficient ClawSweeper judged the real behavior proof convincing. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed 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
Preserve lazy targets and CSS hints while dropping redundant JS preloads. Remove the retired Custodian Lit assertion allowance. Verified paired build startup does not grow, 39 build configuration tests and 44 focused E2E cases pass, and fresh P2 review is clean.
@clawsweeper clawsweeper Bot added status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed proof: sufficient ClawSweeper judged the real behavior proof convincing. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Oct 11, 2026
# Conflicts:
#	ui/src/pages/chat/chat-pane.ts
#	ui/src/pages/custodian/custodian-surface.ts
@clawsweeper clawsweeper Bot added status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Oct 11, 2026
@clawsweeper clawsweeper Bot added rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. and removed rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Oct 11, 2026
@clawsweeper clawsweeper Bot added rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. labels Oct 12, 2026
# Conflicts:
#	ui/src/components/mcp-app-view.test.ts
@clawsweeper clawsweeper Bot added the proof: sufficient ClawSweeper judged the real behavior proof convincing. label Oct 12, 2026
@steipete

Copy link
Copy Markdown
Contributor Author

Current integration proof: Chinese onboarding renders its translated welcome, typed options, and channel prompt through the native Solid message view. The shared mock Gateway supplies a valid channel snapshot. All eight previously failing setup/locale/reconnect cases now pass without weakening their assertions. Synthetic fixture data only.

Verified Solid onboarding in Chinese

@steipete
steipete merged commit 6fcd048 into main Oct 12, 2026
128 of 135 checks passed
@steipete
steipete deleted the solid2/w-chat-8a branch October 12, 2026 04:31
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via explicitly authorized admin squash with attributed pre-existing CI failures.

steipete added a commit that referenced this pull request Oct 12, 2026
The Control UI build fails on main with MISSING_EXPORT: custodian-surface.tsx
(ported to Solid in #169300) imports OptionCard, but 3e8757d had removed
that export while it had no consumer. The two changes landed independently,
so every bundled UI e2e lane fails in global setup.

Export the bridge component again now that it has a consumer.

Proof: pnpm tsgo:ui and pnpm ui:build pass; custodian-event-nudge e2e passes
against the rebuilt bundle.
steipete added a commit that referenced this pull request Oct 12, 2026
6fcd048 (#169300) passes PanelRefreshStatus its shared className prop, matching the existing logs view entry.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 13, 2026
* refactor(ui): port sibling session pages to Solid

Preserve Custodian, Apps, question, approval, and Skill Workshop behavior through lazy Solid bridges. Keep shared wizard and route templates as stateless Lit adapters until their owners migrate. Consolidate already-eager foundation chunks to reduce startup transfer without expanding the initial module set.

* fix(ui): omit preloads for already loaded transitive modules

Preserve lazy targets and CSS hints while dropping redundant JS preloads. Remove the retired Custodian Lit assertion allowance. Verified paired build startup does not grow, 39 build configuration tests and 44 focused E2E cases pass, and fresh P2 review is clean.

* test(ui): await the custodian welcome request

* fix(ui): retire custodian alerts when session authority changes

* fix(ui): consume the landed markdown presentation owner

* fix(ui): render custodian messages with the native Solid view

Consume the landed message group directly and provide a typed empty channel status in the shared mock Gateway. Preserve MCP context-strip assertions through Solid settlement. All eight previously failing Custodian E2E cases, 27 MCP cases, UI types and scoped lint pass; P2 review is clean.

* test(ui): isolate onboarding event nudges from channel setup
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 13, 2026
The Control UI build fails on main with MISSING_EXPORT: custodian-surface.tsx
(ported to Solid in openclaw#169300) imports OptionCard, but 1230fac had removed
that export while it had no consumer. The two changes landed independently,
so every bundled UI e2e lane fails in global setup.

Export the bridge component again now that it has a consumer.

Proof: pnpm tsgo:ui and pnpm ui:build pass; custodian-event-nudge e2e passes
against the rebuilt bundle.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 13, 2026
beabbc0 (openclaw#169300) passes PanelRefreshStatus its shared className prop, matching the existing logs view entry.
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 P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. 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. scripts Repository scripts size: XL status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant