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

[cssom-view] "Elements and viewports have an associated scrol..." #1526

Open
zcorpan opened this issue Jun 13, 2017 · 6 comments
Open

[cssom-view] "Elements and viewports have an associated scrol..." #1526

zcorpan opened this issue Jun 13, 2017 · 6 comments

Comments

@zcorpan
Copy link
Member

zcorpan commented Jun 13, 2017

https://drafts.csswg.org/cssom-view/#terminology

Elements and viewports have an associated scrolling box if has a scrolling mechanism or it overflows its content area and the used value of the overflow-x or overflow-y property is hidden. [CSS3-BOX]

An element is potentially scrollable if all of the following conditions are true:​

The element has an associated CSS layout box.
The element is not the HTML body element, or it is and the root element’s used value of the overflow-x or overflow-y properties is not visible.
The element’s used value of the overflow-x or overflow-y properties is not visible.
Note:​ An element that is potentially scrollable might not have a scrolling box. For instance, it could have overflow set to auto but not have its content overflowing its content area.

The definition of scrolling box looks wrong. Certainly scroll and auto should also cause a scrolling box.

The definition of potentially scrollable also looks wrong w.r.t. overflow: clip.

@zcorpan
Copy link
Member Author

zcorpan commented Jun 19, 2017

Ah, now I see. overflow: scroll causes a "scrolling mechanism". I think this needs clearer grouping, with a list.

@zcorpan
Copy link
Member Author

zcorpan commented Jun 19, 2017

The scrolling box definition here should be removed in favor of css-overflow's "scroll container"... or maybe the "scrollport"

@zcorpan
Copy link
Member Author

zcorpan commented Jun 19, 2017

cc @dbaron @frivoal

@zcorpan
Copy link
Member Author

zcorpan commented Jun 19, 2017

The definition of potentially scrollable also looks wrong w.r.t. overflow: clip.

Actually I think it's not wrong. https://drafts.csswg.org/css-overflow-3/#overflow-propagation only checks 'visible', and potentially scrollable should match up with that.

@zcorpan
Copy link
Member Author

zcorpan commented Jun 19, 2017

Scrolling box I think should be defined as there being a scroll container and scrollable overflow.

@mrobinson
Copy link
Contributor

I think this causes a problem when this definition is combined with step 10 of When setting the scrollTop attribute these steps must be run: of section 6 which reads:

  1. If the element does not have any associated CSS layout box, the element has no associated scrolling box, or the element has no overflow, terminate these steps.

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