Repository navigation
perf(ui): narrow sibling spacing invalidation - #180964
Merged
Merged
Conversation
Contributor
|
🦞👀 Pull request received. I will update this pull request when review starts. |
Contributor
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. |
Contributor
Author
Contributor
Author
|
Merged via squash auto-merge.
|
github-actions Bot
pushed a commit
to Desicool/openclaw
that referenced
this pull request
Oct 23, 2026
* perf(ui): limit sibling spacing style invalidation * perf(ui): narrow key and sharing span invalidation * test(ui): correct warm interaction session fixtures
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.




What Problem This Solves
Opening a Cron row menu in a 500-job inventory inserts/removes body-level tooltip and menu nodes. Chromium's invalidation trace names the universal adjacent-sibling spacing rules as the reason the whole body subtree is restyled twice.
Candidate: preserve the same element-child spacing and specificity using
:where(:not(:first-child)). Keep rendering, overlay ownership, and all class names unchanged.Before accepting: production renderer, synthetic Gateway with the existing session-list owner, 500 loaded jobs, desktop 1440×1000 and mobile 390×844. At least 10 serial interleaved baseline/candidate pairs for
cron-menu-open; review script/task/layout/style/automation-to-assertion median, p95, min, max. Any >20% regression rejects the candidate. Record zero interval RPCs, source-mapped diagnostic traces, and inspected before/after screenshots. Compare exact-source builds on this host; no boot-surface increase beyond 64 B build variance. Follow with a report-only probe in the existing Cron E2E file if accepted.The benchmark correction removes bogus dashboard pages, honors session filters and pagination, and loads the sidebar's 1,000-row inventory through its existing Load more control. Earlier route-opening census figures are superseded, not performance wins.
Results
Ten serial interleaved pairs per viewport (40/40 visible outcomes pass), Chromium 156, macOS arm64. Zero interval RPCs. Values are median / p95 / min–max, milliseconds; all 40 time-statistic comparisons satisfy the 20% rule. No trace/profiler overhead in these pairs.
The universal adjacent-sibling rules produced body-wide invalidations; two span-sibling rules retained broad span invalidations. Child-position selectors keep spacing while eliminating those false dependencies. The two span rules rely on current span-only renderer children; their type specificity drops by one and has no competing declaration. No host, class, rendering, or overlay-ownership change.
Strict immutable-bundle comparison: startup JS 316,237 → 316,246 B (+9 B), CSS 41,124 → 41,128 B (+4 B). Startup remains 7 JS requests and 1 CSS request. All boot-surface deltas remain within 64 B; the final merged-base build check is recorded below.
Four inspected synthetic-only screenshots show unchanged desktop/mobile spacing and menu placement. Existing Cron E2E gains a report-only menu-open probe with visible open/close assertions. The harness reuses the paginated session-list owner rather than returning ordinary chats as dashboard pages, and makes detailed invalidation tracing opt-in. Production code adds only two explanatory CSS comments; no new runtime state or abstraction.
Corrected ranked census
28/28 production-renderer outcomes passed. One diagnostic sample per cell after the first three spacing-selector changes, before the final two span-selector changes; CDP trace plus 1 ms CPU profiling overhead included. Nested intervals overlap. The 10-pair untraced distributions above decide acceptance, not this ranking. Desktop 1440×1000; mobile 390×844. Session list owner now honors dashboard and pagination queries. Route opening uses its default window, while sort/search uses the explicitly expanded 1,000-row result.
Sessions/Cron opening has no remaining long task with the corrected fixture. Desktop sidebar layout work comes from 59 layouts during its existing grid-width animation; the trace reports no forced synchronous layout. Session switching has no long task in either viewport in this census. Cron typing remains the next rendering owner to investigate, separately from variable request coalescing.
Evidence
Integrated #180889 and current main (
fdf6d47e645) with Git merge. Source changes remain eight focused files; no baseline, dependency, route, tag, or class-name changes.ci:full; no local E2E suiteProduction LOC across the five CSS files: 8,805 → 8,807 (+2 explanatory comments). All changed files: 9,962 → 10,009 (+47); +91/−44 diff lines. Existing renderers supply the spacing contract; no new owner or runtime state.
Reproduction: build both revisions with
pnpm ui:build; runscripts/bench-control-ui-interactions.ts --bundle-dir <base> --compare-bundle-dir <head> --steps cron-menu-open --pairs 10. Diagnostic attribution additionally uses--trace --invalidation-tracking; those overhead-bearing intervals do not decide acceptance. Both strict reports usescripts/check-control-ui-performance.mts --dist <bundle>, adding--base-dist <base>for the head.Inspected synthetic before/after screenshots are embedded in the linked proof comment.
Production Knip reports 13 unused-export groups and 11 exported-type groups. The exact same command on merge base
fdf6d47e645produces byte-identical output, includingresolveConfiguredCronModelSuggestionsand the approval presentation exports. No ignores or out-of-scope removals were added. This is retained as an investigated local failure.