Repository navigation
fix: keep a tab set's open-panel stop from the reach pass, and select the editor's line instead of typing into the previewed table - #7604
Conversation
…g into the table The double-click test typed Z at the start of '| x | gamma |' to show the caret's column. That edit added a cell to the preview's table, which lf-text-document redraws after native awaits the input watch doesn't follow, so on a slow runner the reflow landed outside the keystroke's window and the shift watch reported it as a move without input. Shift+End selecting the whole line shows the same column and changes nothing the preview draws. Refs #7532
|
The red This PR's own claim, the shift report from the typed |
The reach pass gave back any `tabindex="0"` on a scroll candidate that stopped scrolling or fit, including one another owner wrote. Since lf-tabs moved to Effect UI (#7585), its arrival roves the open panel's stop after the reach pass has recorded the panel as a candidate, so the next reach paint removed it: the open panel of a tab set lost the Tab stop lf-tabs gives it, and the write watch reported `null -> 0 -> null` as an unchanged write of `tabindex` on the panel (test_a_double_click_on_the_rendered_copy_ types_at_its_line_in_the_editor, on every run after #7585). `returnStop` now acts only on a box wearing the pass's own mark, and `lendStop` leaves a `0` another owner wrote alone, as the header of `mayScroll` already said the pass does. A runtime test covers a surface that stops scrolling with another owner's stop on it.
|
The |
Two fixes for
test_a_double_click_on_the_rendered_copy_types_at_its_line_in_the_editor.A tab set's open panel kept losing its Tab stop to the reach pass (
browser/runtime/dom/reach.ts). Since #7585 ported lf-tabs to Effect UI, its arrival roves the open panel'stabindex="0"after the reach pass has already recorded the panel as a scroll candidate. On its next paint,returnStoptook that0back, as it did any0on a candidate. So the open panel lost the Tab stop lf-tabs gives it, and the write watch reportednull → 0 → nullasunchanged write: tabindex on lf-tab#…--preview. That failure reproduces on every run at main1026a7485and at #7585 (b9b4884d1), and never at its parent6e1977ac0. It turned this PR'stestjob red once main was merged in.returnStopnow gives back only a stop wearing the pass's owndata-lf-lent-reach-stopmark, andlendStopleaves alone a0that another owner wrote. The header ofmayScrollalready said the pass "takes back only that". A new runtime test intests/runtime/reach.test.mjsfails without the change and passes with it.The test's keystroke reflowed the previewed table (macOS teardown shift). To show where the double-click left the caret, the test typed
Zat the start of| x | gamma |. That gave the Markdown preview's table a new first cell, so its columns reflowed. lf-text-document draws that redraw after nativeawaits, whichinput_work_watch.jsdoesn't follow (tests/AGENTS.md, "Browser errors"). So on a slow runner the reflow landed outside the keystroke's window and was reported as#text in th … moved without input by (2, 0)px. The test now presses Shift+End and asserts the selection is the whole line, which shows the same caret position and changes nothing the preview draws. The underlying limit, that the input watch can't attribute a redraw drawn after a nativeawait, is left as easy to fix as before.Evidence
tabindexwrite.test_tab_reaches_the_open_panel_and_no_closed_one,test_a_scrolling_tab_panel_keeps_nested_headers_on_its_edgeand the two borrowed-stop tests intest_render_aim.pypass. The full runtime suite passes (1296 tests), and the browser type check is clean.leaf-dev suite flake --cpu-throttle 4): before the change, 3 of 4 copies fail with the same report on atdof that table; with this change, 6 of 6 pass.cidispatches withflake): at main6313a6f59, 4 of 12 copies error (46168668757); on this branch before the merge with main, 18 of 18 pass (46235315494).Refs #7532 — automated triage