Repository navigation
fix: seat a margin row again when its card or options let it go - #6501
Conversation
A margin row its open card holds keeps no seating record and stands where it stood, so it can sit pushed below a row that has since gone, as in the early-send journey, where the drawing's row stays under the comment row that merged into it. Closing the card flips only `aria-expanded`, which changes no size, so the face observer ran no pass: the row kept its old seat until some later change, unprompted, put it beside its passage. The shift watch reported that move as 39px without input, whenever the later change landed outside an input's rendering (1 in 18 copies on main). The face observer now also asks whether any row the last pass held is held no longer, and runs the pass when one is, so the row returns in the rendering of the press that let it go. It asks only those rows, so the check costs the same however many rows the page holds. The journey now waits, after the Escape that closes the card, for the marker to stand level with its passage. Without the fix both variants fail every run with the issue's message; with it, 36 of 36 concurrent copies pass. Closes #6494
|
@leaf-agent
|
A change to one row's face no longer reseats another row that hover or focus held at the last pass and has since let go; only the row whose face changed is asked, while resizedFaces already visits it.
|
Done in e756a45. |
leaf-agent
left a comment
There was a problem hiding this comment.
margin-layout.js was reflowed to 80 columns, about 170 lines outside the fix. The repo formats at 88 (.oxfmtrc.jsonc, printWidth: 88), so the pre-commit oxfmt hook fails on this file. Running oxfmt doesn't fully undo the reflow either: it keeps the objects that were split across lines expanded. With main's layout restored, the file's diff comes to +20/−4, the actual fix. I'm pushing that restoration. The logic is unchanged.
The fix reflowed about 170 untouched lines to 80 columns, which the pre-commit oxfmt hook (printWidth 88) rejects. No behavior changes.
A margin row whose open thread card holds it gets no seating record and stays where it stood. So it can stay pushed below a row that has since gone. In the early-send journey, that is the drawing's row, left under the comment row that merged into it. Closing the card with Escape changes only
aria-expanded, which changes no size, so the face observer inmargin-layout.jsran no pass. The row stayed in its old seat until some later change put it beside its passage without any input. Under load that change landed outside an input's rendering, and the shift watch reported the 39px move in #6494.When a row's face changes, the face observer now also asks whether that row was held at the last pass and has been let go, and runs a pass if so. The row returns in the rendering of the press that let it go. Only the row whose face changed is asked, so a change to one row never reseats another, and the check costs the same however many rows the page holds.
Verification. In the journey, an instrumented run showed Escape setting
aria-expanded="false"with no margin pass for about 1.7 s, until the Close click. With the fix the pass lands 22 ms after Escape. After the Escape, the journey now waits for the marker to stand level with its passage. Without the fix, both variants fail on every run with the issue's message. With it,leaf-dev suite flakepasses 36 of 36 concurrent copies (main failed 1 of 18 before).pnpm run check,pnpm run test:runtimeand 54 focused margin browser tests (held rows, cards, clusters, opening threads) pass.Hover and focus holds still end without a mutation, so a row let go by them waits for the next change to its own face or the next pass, as before.
Closes #6494 — automated triage