[css-scroll-snap] Is scroll-snap-type: [ mandatory | proximity ] valid CSS? · Issue #827 · w3c/csswg-drafts · GitHub
Skip to content
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] Is scroll-snap-type: [ mandatory | proximity ] valid CSS? #827

Closed
whsieh opened this issue Dec 22, 2016 · 2 comments
Closed

Comments

@whsieh
Copy link

whsieh commented Dec 22, 2016

Link: https://drafts.csswg.org/css-scroll-snap/

According to the spec, values of scroll-snap-type follow the format none | [ x | y | block | inline | both ] [ mandatory | proximity ]?, which I understand to mean that values like x mandatory or block are valid, but mandatory alone is not. However, in Section 2 (Motivating Examples) I noticed that scroll-snap-type: mandatory; and scroll-snap-type: proximity; are utilized. Is the intention to make those valid values for scroll-snap-type?

If they are, would it make sense to make the default axis type both when only proximity or mandatory are specified?

@whsieh whsieh changed the title [css-scroll-snap] Is scroll-snap-type: [ mandatory | proximity ] valid CSS? [css-scroll-snap] Is scroll-snap-type: [ mandatory | proximity ] valid CSS? Dec 23, 2016
@fantasai
Copy link
Collaborator

Good catch. The CSSWG resolved on requiring the axis arguments (usually you want just one axis or the other, not both--both results in weird scrolling behavior on a normal document). The examples didn't get updated, though.

@fantasai
Copy link
Collaborator

(Tab and I had originally proposed to use whichever axis is scrollable, defaulting to the block axis if both are, but we couldn't get agreement on that so now it's a required argument.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants