mirror of
https://github.com/ohwgiles/laminar.git
synced 2026-09-23 12:31:30 +00:00
Implements #220 - if the page is scrolled to the very bottom while a build log is streaming, the scroll position "sticks" there and follows new output as it is rendered, like tail -f. Any upward scroll disengages this behaviour, and scrolling back to the bottom re-engages it, so no toggle button is needed. The sticky state is tracked with wheel/scroll event listeners rather than sampled from window.scrollY at render time, because scrolling is handled outside the main thread: while the main thread is busy rendering a large log chunk, window.scrollY may still report the old (bottom) position, which would wrongly yank the page back down and swallow the user's upward scroll. AI-assisted implementation. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>