Repository navigation
Unify initial widget drawings and thread controls - #4488
Merged
Merged
Conversation
Unify panel and composer rendering, retain one initial/live widget drawing, and remove parallel DOM caches. Narrow composer subscriptions and make motion playback observable so framework updates do not fan out across unrelated controls. Generate composer action controls and update the package-facing API at protocol 29.
leaf-agent
approved these changes
Oct 27, 2026
This was referenced Oct 27, 2026
leaf-agent
added a commit
that referenced
this pull request
Oct 27, 2026
The pointer adapter-failure cases assumed that opening reactions ended reply editing. #4488 intentionally keeps editing active for presses within the same thread, so all eight cases stopped before injecting their adapter failure. End the pointer case's composition explicitly with Escape before opening reactions. This preserves its saved-draft retirement scenario, the keyboard case's active-reply continuation scenario, and the existing checks for draft recovery, stale picker release and healthy sibling updates. No runtime behavior changes. An expanded experiment with active pointer compositions exposed a moved-outlet continuation defect, recorded with reproduction details in #4504. The saved-draft cases here and the existing keyboard continuation case remain distinct coverage. Validation: reproduced the old assertion on current main; the nine focused adapter-failure cases pass with this setup correction. Closes #4494 — automated triage Co-authored-by: leaf-agent <[email protected]>
This was referenced Oct 28, 2026
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.
Remove the separate
x-prepaintmarkup path and usex-initialas the single contract for a widget's first drawing. Tally retains one Lit template from initial paint through live updates; file tree, editor and trace adopt their initial pending nodes. This removes duplicate schema validation, Python placeholder insertion, browser insertion and placeholder CSS. Markdown retains its separate server-rendered content path.Thread headers and settlement controls now belong to their surrounding Lit templates, removing detached render roots and the Resolve/Reopen node cache. Reopening explicitly lands in the reply field while retaining the existing guards against stealing a later focus choice. Pointer presses on controls in the same thread retain the active reply until the action runs, preventing Reopen from retiring its own margin card; explicit Resolve and outside presses still dismiss it. Generic thread DOM relations move to their shared selectors owner so both rendering and composition use the same parts without a dependency cycle. The package-author contract is updated and the protocol advances to 33 because vendored declarations change.
The change removes 12 lines overall: source/docs shrink by 111 lines, while behavioral tests grow by 30 and generated assets by 69. Focused browser coverage exercises initial-node retention, lazy producers introduced by revisions and frozen replies, tally navigation and undo, and thread reopening/refusal/focus. The alert-page startup comparison against main retains 35 code requests through initial semantic presentation and removes 77 combined document/code bytes; neither arm reports browser errors.
Validation: Opus review and repair review, independent live-browser reviews, 128 focused model tests, 29 build tests, 682 runtime tests and 85 Worker tests. Focused Chromium journeys also cover keyboard/pointer Reopen, outside dismissal, panel transfer, shadow-input focus, and editing a message while retaining an unfinished reply.
Inherited diagnostic: the behavior assertions in
test_reply_editing_and_saved_words_have_separate_resolution_lifetimes[panel-user]pass, but teardown reports typed words leaving the screen. This also reproduces on an isolated snapshot of mainc4411611e. The resolution/words-visibility diagnostic family is tracked in #4401; this result does not establish that the two cases share a cause.