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-contain] it should be clearer that size containment inhibits effects of contents on intrinsic sizes #4741

Closed
dbaron opened this issue Feb 4, 2020 · 4 comments

Comments

@dbaron
Copy link
Member

dbaron commented Feb 4, 2020

The definition of size containment says:

  1. When calculating the size of the containing box, it must be treated as having no contents.

I think the implication here (given the text about replaced elements following this) is that "calculating the size of the containing box" includes both:

  • finding the resolved values of width and height
  • computing intrinsic sizes

However, I think a literal reading of the sentence implies that it means only the first and not the second. I think it should be clearer that the computation of the intrinsic sizes of the box must also be done as though the box has no contents. It's possible it might also be worth mentioning automatic sizes.

@frivoal
Copy link
Collaborator

frivoal commented Feb 5, 2020

This is indeed intended to cover both layout sizing and intrinsic sizing. Happy to clarify.

How's this?

When calculating the size of the containing box, including when computing its [=intrinsic size=], it must be treated as having no contents.

Also,

It's possible it might also be worth mentioning automatic sizes.

Not obvious to me that it would help. What would you do with that?

As this is a clarification rather than a contradiction or an addition, I think fixing it in level 2 is enough. I have no issue with including the fix in L1's ED, but I don't think it warrants going through the motions of republishing a REC just for this.

@frivoal frivoal self-assigned this Feb 5, 2020
@frivoal
Copy link
Collaborator

frivoal commented Feb 5, 2020

(also are you aware of any bug triggered by this ambiguity, either in browsers or in tests?)

@dbaron
Copy link
Member Author

dbaron commented Feb 5, 2020

That proposal seems reasonable. I ran into it while writing up a proposal about the size containment needed for container queries.

@css-meeting-bot
Copy link
Member

The CSS Working Group just discussed css-contain] it should be clearer that size containment inhibits effects of contents on intrinsic sizes, and agreed to the following:

  • RESOLVED: Accept propose as phrased in comment from florian
The full IRC log of that discussion <dael> Topic: css-contain] it should be clearer that size containment inhibits effects of contents on intrinsic sizes
<dael> github: https://github.com//issues/4741
<dael> dbaron: I don't think this is controversial but it seemed to me it should be implied by size containment it doesn't impact intrinsic size in addition to final computed size
<dael> dbaron: Ran into this while writing something that referenced size containment.
<dael> florian: Agree it was the intent. Prop rephrasing in the issue to clarify. dbaron said he was fine.
<dael> florian: [reads original sentence]
<dael> florian: Would insert including when computed as intrinsic size. Suggest we add to L2. Clarification so I'll prob edit into L1 too.
<dael> Rossen_: Proposed resolution?
<dael> florian: Accept propose as phrased in comment
<dael> Rossen_: Obj?
<dael> RESOLVED: Accept propose as phrased in comment from florian
<dael> fantasai: Republish a REC?
<dael> florian: Rather not, not worth process hassle
<dael> florian: Happy to update ED so if we do need to update REC it's folded in
<dael> Rossen_: fantasai do you feel strong to republish?
<dael> fantasai: Not super strong. Want to keep things in sync but this is minor
<dael> fantasai: I do want us...if something doesn't effect sizing it should mean any type of sizing. I don't think clarification is a problem but I think problem if "Size" doesn't mean "instrinsic size"

frivoal added a commit to frivoal/wpt that referenced this issue Apr 8, 2020
frivoal added a commit to web-platform-tests/wpt that referenced this issue Apr 8, 2020
@frivoal frivoal added Tested Memory aid - issue has WPT tests Closed Accepted as Editorial and removed Needs Edits labels Apr 8, 2020
@frivoal frivoal closed this as completed in 7806c20 Apr 8, 2020
xeonchen pushed a commit to xeonchen/gecko that referenced this issue Apr 13, 2020
Automatic update from web-platform-tests
Test for csswg issue 4741 (#22780)

w3c/csswg-drafts#4741
--

wpt-commits: 206c4928d65b3643eecb7d525aea43f7de1db8b6
wpt-pr: 22780
moz-v2v-gh pushed a commit to mozilla/gecko-dev that referenced this issue Apr 13, 2020
Automatic update from web-platform-tests
Test for csswg issue 4741 (#22780)

w3c/csswg-drafts#4741
--

wpt-commits: 206c4928d65b3643eecb7d525aea43f7de1db8b6
wpt-pr: 22780
JTensai pushed a commit to JTensai/csswg-drafts that referenced this issue May 13, 2020
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