-
Notifications
You must be signed in to change notification settings - Fork 677
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[css-scroll-snap-1] Alignment when scrolling to an element with scroll-snap-align #9576
Comments
Small correction - the interop 2022 failures are The tests |
Chrome prioritizes ScrollIntoViewOptions over scroll-snap-align, but the specs need clarification on this point: w3c/csswg-drafts#9576 In the meantime, have the tests use scroll-snap-align: start instead of center, so that it matches the default ScrollIntoViewOptions. Bug: 1325845 Change-Id: Ibd40a187cc86b9286ff9e2c7a67ed59d7233185b
Chrome prioritizes ScrollIntoViewOptions over scroll-snap-align, but the specs need clarification on this point: w3c/csswg-drafts#9576 In the meantime, have the tests use scroll-snap-align: start instead of center, so that it matches the default ScrollIntoViewOptions. Bug: 1325845 Change-Id: Ibd40a187cc86b9286ff9e2c7a67ed59d7233185b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5025233 Reviewed-by: Robert Flack <[email protected]> Commit-Queue: Steve Kobes <[email protected]> Cr-Commit-Position: refs/heads/main@{#1223689}
Chrome prioritizes ScrollIntoViewOptions over scroll-snap-align, but the specs need clarification on this point: w3c/csswg-drafts#9576 In the meantime, have the tests use scroll-snap-align: start instead of center, so that it matches the default ScrollIntoViewOptions. Bug: 1325845 Change-Id: Ibd40a187cc86b9286ff9e2c7a67ed59d7233185b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5025233 Reviewed-by: Robert Flack <[email protected]> Commit-Queue: Steve Kobes <[email protected]> Cr-Commit-Position: refs/heads/main@{#1223689}
Chrome prioritizes ScrollIntoViewOptions over scroll-snap-align, but the specs need clarification on this point: w3c/csswg-drafts#9576 In the meantime, have the tests use scroll-snap-align: start instead of center, so that it matches the default ScrollIntoViewOptions. Bug: 1325845 Change-Id: Ibd40a187cc86b9286ff9e2c7a67ed59d7233185b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5025233 Reviewed-by: Robert Flack <[email protected]> Commit-Queue: Steve Kobes <[email protected]> Cr-Commit-Position: refs/heads/main@{#1223689}
…ap-* tests., a=testonly Automatic update from web-platform-tests Avoid spec ambiguity in scroll-target-snap-* tests. Chrome prioritizes ScrollIntoViewOptions over scroll-snap-align, but the specs need clarification on this point: w3c/csswg-drafts#9576 In the meantime, have the tests use scroll-snap-align: start instead of center, so that it matches the default ScrollIntoViewOptions. Bug: 1325845 Change-Id: Ibd40a187cc86b9286ff9e2c7a67ed59d7233185b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5025233 Reviewed-by: Robert Flack <[email protected]> Commit-Queue: Steve Kobes <[email protected]> Cr-Commit-Position: refs/heads/main@{#1223689} -- wpt-commits: ff3d3e29464e87581edc6eea7037485e424097d7 wpt-pr: 43117
…ap-* tests., a=testonly Automatic update from web-platform-tests Avoid spec ambiguity in scroll-target-snap-* tests. Chrome prioritizes ScrollIntoViewOptions over scroll-snap-align, but the specs need clarification on this point: w3c/csswg-drafts#9576 In the meantime, have the tests use scroll-snap-align: start instead of center, so that it matches the default ScrollIntoViewOptions. Bug: 1325845 Change-Id: Ibd40a187cc86b9286ff9e2c7a67ed59d7233185b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5025233 Reviewed-by: Robert Flack <[email protected]> Commit-Queue: Steve Kobes <[email protected]> Cr-Commit-Position: refs/heads/main@{#1223689} -- wpt-commits: ff3d3e29464e87581edc6eea7037485e424097d7 wpt-pr: 43117
…ap-* tests., a=testonly Automatic update from web-platform-tests Avoid spec ambiguity in scroll-target-snap-* tests. Chrome prioritizes ScrollIntoViewOptions over scroll-snap-align, but the specs need clarification on this point: w3c/csswg-drafts#9576 In the meantime, have the tests use scroll-snap-align: start instead of center, so that it matches the default ScrollIntoViewOptions. Bug: 1325845 Change-Id: Ibd40a187cc86b9286ff9e2c7a67ed59d7233185b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5025233 Reviewed-by: Robert Flack <[email protected]> Commit-Queue: Steve Kobes <[email protected]> Cr-Commit-Position: refs/heads/main@{#1223689} -- wpt-commits: ff3d3e29464e87581edc6eea7037485e424097d7 wpt-pr: 43117
…ap-* tests., a=testonly Automatic update from web-platform-tests Avoid spec ambiguity in scroll-target-snap-* tests. Chrome prioritizes ScrollIntoViewOptions over scroll-snap-align, but the specs need clarification on this point: w3c/csswg-drafts#9576 In the meantime, have the tests use scroll-snap-align: start instead of center, so that it matches the default ScrollIntoViewOptions. Bug: 1325845 Change-Id: Ibd40a187cc86b9286ff9e2c7a67ed59d7233185b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5025233 Reviewed-by: Robert Flack <[email protected]> Commit-Queue: Steve Kobes <[email protected]> Cr-Commit-Position: refs/heads/main@{#1223689} -- wpt-commits: ff3d3e29464e87581edc6eea7037485e424097d7 wpt-pr: 43117
…ap-* tests., a=testonly Automatic update from web-platform-tests Avoid spec ambiguity in scroll-target-snap-* tests. Chrome prioritizes ScrollIntoViewOptions over scroll-snap-align, but the specs need clarification on this point: w3c/csswg-drafts#9576 In the meantime, have the tests use scroll-snap-align: start instead of center, so that it matches the default ScrollIntoViewOptions. Bug: 1325845 Change-Id: Ibd40a187cc86b9286ff9e2c7a67ed59d7233185b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5025233 Reviewed-by: Robert Flack <flackrchromium.org> Commit-Queue: Steve Kobes <skobeschromium.org> Cr-Commit-Position: refs/heads/main{#1223689} -- wpt-commits: ff3d3e29464e87581edc6eea7037485e424097d7 wpt-pr: 43117 UltraBlame original commit: e0272cfd4f73823e45cff178a76e6e89e379c848
…ap-* tests., a=testonly Automatic update from web-platform-tests Avoid spec ambiguity in scroll-target-snap-* tests. Chrome prioritizes ScrollIntoViewOptions over scroll-snap-align, but the specs need clarification on this point: w3c/csswg-drafts#9576 In the meantime, have the tests use scroll-snap-align: start instead of center, so that it matches the default ScrollIntoViewOptions. Bug: 1325845 Change-Id: Ibd40a187cc86b9286ff9e2c7a67ed59d7233185b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5025233 Reviewed-by: Robert Flack <flackrchromium.org> Commit-Queue: Steve Kobes <skobeschromium.org> Cr-Commit-Position: refs/heads/main{#1223689} -- wpt-commits: ff3d3e29464e87581edc6eea7037485e424097d7 wpt-pr: 43117 UltraBlame original commit: e0272cfd4f73823e45cff178a76e6e89e379c848
…ap-* tests., a=testonly Automatic update from web-platform-tests Avoid spec ambiguity in scroll-target-snap-* tests. Chrome prioritizes ScrollIntoViewOptions over scroll-snap-align, but the specs need clarification on this point: w3c/csswg-drafts#9576 In the meantime, have the tests use scroll-snap-align: start instead of center, so that it matches the default ScrollIntoViewOptions. Bug: 1325845 Change-Id: Ibd40a187cc86b9286ff9e2c7a67ed59d7233185b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5025233 Reviewed-by: Robert Flack <flackrchromium.org> Commit-Queue: Steve Kobes <skobeschromium.org> Cr-Commit-Position: refs/heads/main{#1223689} -- wpt-commits: ff3d3e29464e87581edc6eea7037485e424097d7 wpt-pr: 43117 UltraBlame original commit: e0272cfd4f73823e45cff178a76e6e89e379c848
css-scroll-snap-1 6.2 Choosing Snap Positions says the following:
While working on this, the question came up of how to respect the alignment if the developer provided one. E.g. if the developer specifies a block alignment:
What should we do if the target element has a non-none
scroll-snap-align
:scroll-snap-align
value. This seems reasonable as not doing so could result in the element not being visible. E.g. see degenerate case mentioned in [css-scroll-snap-2] Should scroll-start-target specify alignment? #9012 (comment)scroll-snap-align
alignment it seems like it would have to always override the javascript provided alignment.Having a CSS value override the JS one, especially when it's optional, seems like it runs counter to developer expectations - e.g. confusion around why the provided alignment wasn't used.
Another concern is that currently scrolling to a fragment also specifically invokes Scroll target into view, with behavior set to "auto", block set to "start", and inline set to "nearest" so it currently has a specified alignment, even though the developer did not provide it.
TLDR; There are a few questions around this space:
scroll-snap-align
value if specified, and otherwise fall back to defaults.The text was updated successfully, but these errors were encountered: