Skip to content

refactor(ui): register menu controls with rendering owners - #177136

Merged
steipete merged 1 commit into
mainfrom
solid2/w-zero-menu-controls-final-20261019
Oct 19, 2026
Merged

steipete merged 1 commit into
mainfrom
solid2/w-zero-menu-controls-final-20261019

Conversation

@steipete

@steipete steipete commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Menu currently discovers embedded controls by querying its rendered subtree, with local effects for positioning and prewarming. Register those controls with their rendering owners and use the shared anchored-overlay primitive. This removes all four Menu queries and both feature effects while preserving native keyboard navigation, nested dismissal, shortcuts, search, compound-row Tab order, and lazy prewarming.

Each menu tree has one control registry; refs register controls and release them with their rendering owner. Zag still owns ordinary row navigation. Prewarming keeps its existing double-animation-frame start, eight-item idle slices, timeout and cancellation. All production embedded-control callers are wired. The unused generic panel-header action field is removed; production already uses headerActionView. No dependencies, host tags, CSS classes, routes or startup imports change.

Evidence

Proof base: c8bed42299ccab89860d7318cd497a32b476faab. Landed PR head: 25ee1625631540df1c26d03dfef453ad9074e65a.

The landed Hovercard change added the same PersonName.ref prop using a callback wrapper. The sole conflict keeps this PR's direct ref={props.ref} binding. Only the Menu commit was rebased; every one of its 27 authored file blobs is byte-identical to the reviewed 51383a6c9b964a64f21f89c3a2bce739661e15f8. The 50 passing browser tests and isolated review are reused for those unchanged inputs. Frozen install, default tsrs, and paired strict builds were refreshed on the new base/head.

Check Result
Frozen install and default tsrs (pnpm tsgo:ui) Passed after rebase
Menu navigation / lifecycle / native contract 23 / 15 / 12 tests passed, pinned Bun, one run per file
Scoped lint, formatting, diff check Passed
Production Knip (pnpm deadcode:knip) Passed on final rebased head 25ee16256315; no findings
Isolated autoreview and simplification pass No actionable P0–P2 findings
Base/head builds and strict performance Passed, no violations or warnings
Synthetic built-app captures Three states passed; zero changed pixels in all three pairs; no page errors
Broad UI proof Exact-head full CI passed: all 3 UI unit, 9 UI E2E, and 2 real-Gateway shards; performance and enforced security gates passed
Shipped gzip Base Head Delta
Startup JS 337,563 B 337,576 B +13 B
Startup CSS 38,500 B, 1 request 38,500 B, 1 request 0
Chat boot JS 1,471,874 B 1,472,102 B +228 B
New Session boot JS 1,045,589 B 1,045,654 B +65 B

The small bundle growth is explicit ref wiring for embedded controls. Lazy boundaries are retained. Captures verify the built commit metadata on each side. They exercise owner-search arrows/Escape, custom-icon native Tab traversal and one scoped patch, nested Escape restoration, reopening prewarmed menus, and pinning a compound agent row without losing focus after reorder. Full suites stay in CI; no local E2E battery or parity run.

Scope and remaining patterns

27 files: 529 additions / 304 deletions. Production: 20 files, 5,928 → 6,075 LOC (+147). Test/helpers: 7 files, 2,295 → 2,373 LOC (+78). Growth is the explicit control-ref wiring across existing callers; no duplicate navigation owner is introduced.

Pattern, touched production Before After
createEffect 3 1
createRenderEffect 0 0
untrack 2 2
addEventListener 0 0
querySelector(All) 4 0

Survivors: the shared positioning effect at ui/src/lib/reactive/overlay-anchor.ts:32; intentional initial identity at ui/src/components/solid/menu.tsx:193; intentional keyed custom-renderer snapshot at ui/src/components/solid/menu.tsx:443. No Menu feature effect remains. Existing native-focus flush boundaries remain unchanged.

Screenshots

Retained inspected synthetic-only 1440×960 light captures compare base b6e0872bdb72 with reviewed head 51383a6c9b96: owner search, custom icon, agent pin. Every pair has zero changed pixels. All authored rendering files remain byte-identical after the conflict repair; these are retained visual proof, not a new capture of the rebased head.

Before: owner search

After: owner search

Before: custom icon

After: custom icon

Before: agent pin

After: agent pin

Merged as d08bb7657ff1f4286e7a90d5a462ae5b74597c60, verified on origin/main. The PR-context check rejected the original prose-only problem statement and Proof section name; this body now uses the required headings. No product test failed.

@steipete steipete added the ci:full Keep ordinary native-locale CI selection on the next PR run. label Oct 19, 2026
@clawsweeper

clawsweeper Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

ClawSweeper review in progress

ClawSweeper is reviewing this revision. This supersedes any previous blocked status.

View the workflow run.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 19, 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-19T08:49:35.745905Z 25ee162 New commits
ℹ️ 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.

@clawsweeper clawsweeper Bot added the clawsweeper:intake:feature Preliminary submission classification; full source review pending. label Oct 19, 2026
@steipete
steipete force-pushed the solid2/w-zero-menu-controls-final-20261019 branch from 51383a6 to 25ee162 Compare October 19, 2026 08:38
@steipete
steipete enabled auto-merge (squash) October 19, 2026 08:46
@steipete
steipete merged commit d08bb76 into main Oct 19, 2026
98 of 100 checks passed
@steipete
steipete deleted the solid2/w-zero-menu-controls-final-20261019 branch October 19, 2026 08:55
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash auto-merge.

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 ci:full Keep ordinary native-locale CI selection on the next PR run. clawsweeper:intake:feature Preliminary submission classification; full source review pending. size: L

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant