Repository navigation
Read a hint map again once the page shows a script's scroll - #6055
Merged
Merged
Conversation
`t g Tab Enter` typed 60-80 ms apart in Chromium at 1440x900 ended in the card's Reply field, where typed slowly it opens the thread in the panel: the Go-to map `g` armed as the walk landed named the thread's margin entry, which the card the walk opened covers, and Tab walked to it. A box CSS anchors to page content takes a script's scroll only as the next rendering update lays the page out, so in the task where `g` landed the glide, the card still stood where the glide had carried it and the entry read as uncovered. The map's re-read at the scroll's end didn't correct it, since a script's scroll ends before that update; the entry kept its hint until something else re-read the map. arrivals.js now records each scroll write a script makes (`setScroll`, `stopWhereItStands`) and says when the page shows it (`scrollDrawn`), two frame callbacks later. The hint session reads its map only from a drawn scene: armed before then, it holds no members until it is, and its re-read at a scroll's end waits for it too. `stopBrowserScroll` waits on the same promise for its stop, in place of its own two frames. A reader waits only for the writes made before it asked, so a log kept at its end as it streams holds no reading back. At 60 ms between keys, 4 of 4 Chromium runs now end as typed slowly, against 0 of 4 before; Firefox ended right before and after. Keys pressed within the two frames of a landing still read the undrawn scene.
…ce it is Codex's review found that the first commit left an armed map empty until the landing was drawn, so a hint letter typed in those two frames was refused and Tab and Enter reached other commands, where on main they acted on the map read at once. The map is read at once again, as on main, and read again once the scene is drawn, keeping the target Tab had reached where it keeps its code, unless a letter typed meanwhile holds it. The re-read is the one a paint makes at rest (`readAgain`).
leaf-agent
approved these changes
Nov 15, 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.
t g Tab Entertyped 60–80 ms apart in Chromium ended in the thread card's Reply field, where typed slowly it opens the thread in the panel.glands the walk's glide and reads the Go-to map in the same task, but a box CSS anchors to page content, such as the thread card, takes a script's scroll only at the next rendering update. So the margin entry the card covers read as uncovered and got a hint, which Tab walked to. The map's re-read at the scroll's end also came before that update, so the stray hint stayed.scrollDrawn, two frame callbacks later).stopBrowserScrollwaits on it in place of its own two frames.Where to look: a key pressed within two frames of a landing still reads the undrawn scene. That covers the known Chromium
t-then-Tab case, and a let-go Codex found with keys ~10 ms apart, which fails on main too.Max asked for a review of a proposed redesign; this fixes the failure that redesign was meant to address. Tests: a Go-to browser test that fails on main; the probe ends as typed slowly in 6 of 6 runs at 60 ms gaps, against 0 of 6 on main; the glide matrix's
gandtcases;test:runtime;check:browser. Codex reviewed it.