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-overflow-4] scrollbar-gutter should not be inherited #5231

Closed
felipeerias opened this issue Jun 17, 2020 · 3 comments
Closed

[css-overflow-4] scrollbar-gutter should not be inherited #5231

felipeerias opened this issue Jun 17, 2020 · 3 comments

Comments

@felipeerias
Copy link

The scrollbar-gutter spec states that the value of this property is inherited.

So, when a container uses e.g. scrollbar-gutter: always force; to reserve space for the scrollbar, then all of its children will also reserve the same amount of space inside their respective boxes.

This behaviour is likely to break the layout and doesn't seem to be what the author intended.

Proposal: update the scrollbar-gutter spec with Inherited: no.

@frivoal
Copy link
Collaborator

frivoal commented Jun 23, 2020

I agree. The main reason for inheriting would be to change the default from auto to stable by setting it on the root, but that can be achieved with a * selector as well, and other cases seem much more likely to be decided on a scroller per scroller basis. And as you said, the force value inherits particularly poorly.

@frivoal
Copy link
Collaborator

frivoal commented Jun 23, 2020

Btw, the original discussion on inheritance is minuted here: https://lists.w3.org/Archives/Public/www-style/2017Feb/0059.html We were on the fence about inherited vs not, with some people leaning one way and some leaning the other, but nobody feeling very strongly. But that discussion is prior to the introduction of the force value, so I think it makes sense to flip.

@css-meeting-bot
Copy link
Member

The CSS Working Group just discussed [css-overflow-4] scrollbar-gutter should not be inherited, and agreed to the following:

  • RESOLVED: Do not inherit by default
The full IRC log of that discussion <dael> Topic: [css-overflow-4] scrollbar-gutter should not be inherited
<dael> github: https://github.com//issues/5231
<dael> florian: Way back when initially drafted the propery, discussed if should inherit. people didn't seem to feel strongly. Arguement that won is set it on page was nicer than universal selection.
<dael> florian: Phillepe (?) noticed force value does not inherit nicely b/c creates gutter on non-scrollable. Setting on whole page in general is a bad idea. You should onlys et on elements where it matters.
<fantasai> +1 to non-inherited
<dael> florian: Suggestion is switch to non-inherited. Makes sense and I'd like to do that
<dael> florian: Effects layout so inheriting things that effect layout is good
<astearns> s/Phillepe/Felipe/
<dael> ??: Agree florian
<dael> Rossen_: Objections?
<dael> Rossen_: Prop: Do not inherit by default
<dael> RESOLVED: Do not inherit by default

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

3 participants