You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug] Annotate: Contents highlight becomes stale after large scrolls and stays stale across files #2231
The Contents sidebar can stop following the visible section. Slow scrolling initially works. After large wheel movements the highlighted entry lags several sections behind; switching to another document with the same heading count and scrolling slowly does not recover it.
Run plannotator annotate a.md b.md, use a 1440×900 viewport, dismiss first-run announcements and open Contents.
Hover the document, wheel down about 140px × 20, waiting 330ms between movements and 500ms at the end. This is the working slow-scroll control.
Click A Section 01, wait 800ms, then wheel down about 1100px × 5 with the same waits.
Switch Files → b → Contents. Wheel down 140px × 45 with the same waits.
Actual vs expected
Observation
Current document section
Contents entry with aria-current="location"
Initial slow-scroll control
A Section 03
A Section 03
After large scrolling
A Section 05
A Section 02
Slow scrolling in second file
B Section 10
B Section 02
Expected: after scrolling settles, Contents follows the current section, including after switching files.
The two failure observations above are consecutive steps in one fresh 0.28.32 session. Both files have 15 headings; this alone does not establish equal heading count as the root cause. This is a Contents-active-state problem, not the Back-button restoration issue in #2128.
Environment
Official Plannotator 0.28.32, Darwin ARM64; macOS 27.0.1, Apple silicon.
Retested the original equal-heading-count a.md / b.md fixture on the official v0.28.36 stable binary (macOS Apple silicon, fresh in-memory Chromium 155.0.8059.12, 1440×900, isolated HOME/data directory). Native mouse-wheel input was used, not a synthetic DOM scroll event.
Both stale-highlight cases still reproduce:
Step
Actual document position
Contents aria-current="location"
Slow-scroll control, 20 × deltaY=140
scrollTop=2800; A Section 03
A Section 03 — correct
Return via Contents, then 5 × deltaY=1100
scrollTop=4474; A Section 05
A Section 02 — stale
Switch to b.md (same 15-heading count), then 45 × deltaY=140
scrollTop=10774; B Section 11 heading visible at y=147.546875
B Section 02 — stale
The actual scrollable main, heading geometry, and Contents state were measured after each gesture settled. The original reproduction and expected behavior still apply; this is not a claim about an untested development branch. No private documents were used.
Activity
zane668 commentedon Oct 29, 2026
Retested the original equal-heading-count
a.md/b.mdfixture on the official v0.28.36 stable binary (macOS Apple silicon, fresh in-memory Chromium 155.0.8059.12, 1440×900, isolated HOME/data directory). Native mouse-wheel input was used, not a synthetic DOMscrollevent.Both stale-highlight cases still reproduce:
aria-current="location"deltaY=140scrollTop=2800; A Section 03deltaY=1100scrollTop=4474; A Section 05b.md(same 15-heading count), then 45 ×deltaY=140scrollTop=10774; B Section 11 heading visible at y=147.546875The actual scrollable
main, heading geometry, and Contents state were measured after each gesture settled. The original reproduction and expected behavior still apply; this is not a claim about an untested development branch. No private documents were used.