Skip to content

fix(ui): let scroll events advance offscreen message reveals - #170789

Merged
steipete merged 1 commit into
mainfrom
dbasync/redmain-ui-renderer-stall
Oct 13, 2026
Merged

steipete merged 1 commit into
mainfrom
dbasync/redmain-ui-renderer-stall

Conversation

@steipete

@steipete steipete commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Offscreen reply navigation and position-rail jumps can freeze the Control UI renderer. When the target bubble is not mounted, completeMessageReveal() scrolls toward its virtual row and unconditionally requests another render. Commit 010435d1635247f39a6a14a05dbe5a8b342da101 (#170662) moved layout completion from a browser frame to a microtask, allowing this loop to starve the native scroll notification needed to advance the virtual range.

Remove that redundant render request. The initial reveal still requests an update for folded-work expansion; native scroll notifications, mounted rows, and deferred projection settlement own subsequent progress. Target highlighting, cancellation, and reader-scroll behavior are unchanged. The fast initial-display path remains intact.

Accepted edge case: an absent target waits for an actual scroll, row mount, or projection event instead of polling unchanged DOM. No security or data-authority check is removed.

Evidence

  • Scheduled baseline: run 38359584345, source 0348a2526c561d8ccce61bfd23931024a6b8f13e. UI2/job 115170476315 fails the deep standalone-work reply reveal; UI8/job 115170476361 fails both dark/light position-rail navigation cases and reply-source navigation after reconnect. Diagnostics show a connected, uncrashed browser whose renderer does not respond.
  • Candidate 5ed8e6c21f2dba67cb0f33d2562b08e099e5e059: all four original cases pass in focused hosted run 38364929226/job 115187670047: dark/light position rail 22.973/22.448 seconds, deep earlier reveal 2.985 seconds, reconnect source navigation 3.574 seconds. Three files, four passed, seven unrelated cases filtered; total Vitest time 83.06 seconds. Source verification confirms the owner and all three test files are unchanged. No assertions, timeouts, retries, or screenshot behavior are weakened.
  • Changed-file oxfmt, oxlint, and git diff --check: passed. No local suite, build, or dependency installation was run.
  • Codex autoreview: scoped-clean; no actionable P0–P2 findings. Normal commit hooks passed.

Focused candidate command (ordinary PR CI omitted these four original cases):

OPENCLAW_UI_E2E_SKIP_REAL_GATEWAY=1 node scripts/run-vitest.mjs run \
  --config test/vitest/vitest.ui-e2e.config.ts --configLoader runner --maxWorkers=1 \
  ui/src/e2e/chat-collapsed-reply-reveal.e2e.test.ts \
  ui/src/e2e/chat-position-rail.e2e.test.ts \
  ui/src/e2e/chat-reply-preview-recovery.e2e.test.ts \
  -t 'reveals the deep earlier message in standalone work|tracks reader position and keyboard jumps|refreshes the page-carried original after reconnect and keeps source navigation working' \
  --reporter=verbose

Scope: one file, +2/-1 lines. No SQL or database-worker/T1 call paths change; no SQL harness measurement applies.

Ordinary candidate CI 38363444022 passed all 28 selected jobs; 26 were skipped. Required, security, types, lint, architecture and static gates passed. Ratchets remain T1 454 to 454, compatibility calls 9 to 9, all dialect groups 0 to 0. The initial PR-context check required these body headings and was corrected; replacement run 38363572076 passed.

After transcript layout completion moved to a microtask, retrying an unmounted message with another unconditional render could starve the native scroll event needed to update the virtual range.

Let native scroll notifications and row mounts continue the reveal. Keep the initial expansion update, target highlight, and scroll cancellation behavior.
@clawsweeper

clawsweeper Bot commented Oct 13, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-13T07:36:16.042855Z 5ed8e6c PR opened
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@steipete
steipete merged commit 2a2c616 into main Oct 13, 2026
95 of 97 checks passed
@steipete
steipete deleted the dbasync/redmain-ui-renderer-stall branch October 13, 2026 07:54
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 14, 2026
…w#170789)

## What Problem This Solves

Offscreen reply navigation and position-rail jumps can freeze the Control UI renderer. When the target bubble is not mounted, `completeMessageReveal()` scrolls toward its virtual row and unconditionally requests another render. Commit `f17d27e18ccba603bab078885201bd7cf3162fb3` (openclaw#170662) moved layout completion from a browser frame to a microtask, allowing this loop to starve the native scroll notification needed to advance the virtual range.

Remove that redundant render request. The initial reveal still requests an update for folded-work expansion; native scroll notifications, mounted rows, and deferred projection settlement own subsequent progress. Target highlighting, cancellation, and reader-scroll behavior are unchanged. The fast initial-display path remains intact.

Accepted edge case: an absent target waits for an actual scroll, row mount, or projection event instead of polling unchanged DOM. No security or data-authority check is removed.

## Evidence

- Scheduled baseline: [run 38359584345](https://github.com/openclaw/openclaw/actions/runs/38359584345), source `116f0502239e7f1cd4a85f57331f986f616e8939`. UI2/job 115170476315 fails the deep standalone-work reply reveal; UI8/job 115170476361 fails both dark/light position-rail navigation cases and reply-source navigation after reconnect. Diagnostics show a connected, uncrashed browser whose renderer does not respond.
- Candidate `5ed8e6c21f2dba67cb0f33d2562b08e099e5e059`: all four original cases pass in [focused hosted run 38364929226/job 115187670047](https://github.com/openclaw/openclaw/actions/runs/38364929226/job/115187670047): dark/light position rail 22.973/22.448 seconds, deep earlier reveal 2.985 seconds, reconnect source navigation 3.574 seconds. Three files, four passed, seven unrelated cases filtered; total Vitest time 83.06 seconds. Source verification confirms the owner and all three test files are unchanged. No assertions, timeouts, retries, or screenshot behavior are weakened.
- Changed-file oxfmt, oxlint, and `git diff --check`: passed. No local suite, build, or dependency installation was run.
- Codex autoreview: scoped-clean; no actionable P0–P2 findings. Normal commit hooks passed.

Focused candidate command (ordinary PR CI omitted these four original cases):

```sh
OPENCLAW_UI_E2E_SKIP_REAL_GATEWAY=1 node scripts/run-vitest.mjs run \
  --config test/vitest/vitest.ui-e2e.config.ts --configLoader runner --maxWorkers=1 \
  ui/src/e2e/chat-collapsed-reply-reveal.e2e.test.ts \
  ui/src/e2e/chat-position-rail.e2e.test.ts \
  ui/src/e2e/chat-reply-preview-recovery.e2e.test.ts \
  -t 'reveals the deep earlier message in standalone work|tracks reader position and keyboard jumps|refreshes the page-carried original after reconnect and keeps source navigation working' \
  --reporter=verbose
```

Scope: one file, +2/-1 lines. No SQL or database-worker/T1 call paths change; no SQL harness measurement applies.

Ordinary candidate CI [38363444022](https://github.com/openclaw/openclaw/actions/runs/38363444022) passed all 28 selected jobs; 26 were skipped. Required, security, types, lint, architecture and static gates passed. Ratchets remain T1 454 to 454, compatibility calls 9 to 9, all dialect groups 0 to 0. The initial PR-context check required these body headings and was corrected; replacement run 38363572076 passed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant