mirror of
https://github.com/outline/outline.git
synced 2026-12-01 09:22:14 +03:00
* fix: Headings at the end of a document never highlight in the contents The highlight was derived only from the scroll position, so a heading in the final viewport — which can never reach the top of the screen — stayed unhighlighted even when clicked directly in the contents. Keep the clicked heading highlighted until the reader scrolls again. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * Release the selected heading on window scroll only Listening for wheel, touch and key events dropped the highlight when the reader typed without scrolling or scrolled the contents panel, and missed scrollbar drags entirely. The document has already been scrolled to the heading by the time the effect runs, so anchor to that position and release once the window moves away from it. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>