Repository navigation
Let sticking blocks flow in a window shorter than 480px - #3330
Merged
Merged
Conversation
Since #3274 a playground's rail sticks beside its stage, bounded to the window and scrolling what it holds. In a short window that bound left a few lines of the rail: at 844x390, `data-explorer`'s workspace flows (below 480px tall), so its rail stuck at 252px, scrolled its 467px inside, and at the page's end stopped where the stage ends, cut mid-text with "Build query" reachable only by scrolling inside the rail. Before #3274 the page scrolled down to it. The shared "Sticking blocks" rule now applies only in a window at least 480px tall, the height below which a workspace already flows. Below it every sticking block (a column's margin sidebar, a sidebar page's track block, a widget's track) flows with its holder, and the page scrolls to all it holds. `module-scroll-and-motion.md` states the threshold for package authors. Measured with `leaf-dev probe`, rail box / content height, submit position at the page's end: - data-explorer 844x390: base sticky, 252 of 467, submit 395-423 below the 390px window; now static, 467 of 467, submit at 181-209. - data-explorer 1024x479: base sticky, 341 of 413; now static, submit at 270-298. - alert-thresholds 844x390 and 1024x479: base sticky and scrolling inside; now static, as before #3274. - 1024x500, 1280x600, 1440x900 on both pages: unchanged. On alert-thresholds at 1024x500 the rail still scrolls its 581px within 380px, as #3274 measured. - Firefox at 844x390 and 1024x768 matches Chrome. - pr-walkthrough's track block flows at 1024x470 and still sticks at 1024x500. Behavior changes in tests: the notification playground's flowing workspace at 1100x300 scrolls the rail's controls and instruction in the page again, as before #3274. The alert playground's tall-stage test now also checks that at 844x390 the page scrolls to the submit button without scrolling inside the rail. Both fail without the change. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
leaf-agent
approved these changes
Oct 20, 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.
Since #3274 a playground's rail sticks beside its stage, bounded to the window's height and scrolling what it holds. In a short window that bound leaves a few lines of the rail. At 844×390
data-explorer's workspace flows (below 480px tall), so its rail stuck at 252px, scrolled its 467px inside, and at the page's end stopped where the stage ends, cut mid-text, with "Build query" reachable only by scrolling inside the rail. Before #3274 the page scrolled down to it.The shared "Sticking blocks" rule in
layouts.cssnow applies only in a window at least 480px tall, the height below which a workspace already flows. Below it every sticking block (a column's margin sidebar, a sidebar page's track block, a widget's track) flows with its holder and the page scrolls to everything it holds.module-scroll-and-motion.mdstates the threshold for package authors, and a newleaf-dev stillsstate,playground-short-window, showsdata-explorerat 844×390 scrolled to the page's end: the rail whole with its actions, where base cuts it.Measured with
leaf-dev probe(rail box / content height; submit at the page's end):data-explorer844×390: base sticky, 252 of 467, submit at 395–423, below the 390px window; now static, 467 of 467, submit at 181–209. The same under--touchand in Firefox.data-explorer1024×479: base sticky, 341 of 413; now static, submit at 270–298.alert-thresholds844×390 and 1024×479: base sticky and scrolling inside; now static, as before Keep a playground's rail in view beside a tall stage #3274.alert-thresholdsfrom 1024×520 to 1024×460 and back mid-stage keeps the alert being read at the same place. At 460, focusing the submit button scrolls the page to it (at 179–209), not the rail.The gate costs a short block its sticking in a short window.
pr-walkthrough's 59px track block and a 40px margin sidebar fit a 470px window, yet they now flow there. Keeping them would need a reading of whether each block fits its bound, which no CSS query gives. The same reading would decidealert-thresholdsat 1024×500, where the rail still scrolls 581px within 380px, as #3274 accepted.Behavior changes in tests: the notification playground's flowing workspace at 1100×300 scrolls the rail's controls and instruction in the page again, as before #3274. The alert playground's tall-stage test also checks that at 844×390 the page scrolls to the submit button without scrolling inside the rail. Both fail without the change.