W3C home > Mailing lists > Public > public-css-archive@w3.org > November 2019

Re: [csswg-drafts] [css-grid] Do all percentages behave as auto when computing minimum contribution? (#3612)

From: Mats Palmgren via GitHub <sysbot+gh@w3.org>
Date: Mon, 04 Nov 2019 13:39:40 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-549357033-1572874779-sysbot+gh@w3.org>
> note it was undefined behavior in CSS2

But the [behave as auto](https://drafts.csswg.org/css-sizing-3/#behave-auto) is in css-sizing, not CSS2. I always understood css-sizing as applying to all of CSS.

> I think in CSS2 there was no case in which a percentage behaved as auto at some points and not at others?

Well, floats are in CSS2, so the float example I gave demonstrates there is, right?

> For example, block-size: 200% in block layout, when the container has an auto size.

True, but note that an auto-sized block's block-size is still indefinite when resolving the child's used value of `block-size`, so the old definition works there too. (Also worth mentioning perhaps is that `block-size: 200%` does not behave as auto in block layout **in quirks mode**.)

> We can't have 100% of 100px because we don't know the size of the grid area, so it will be 100% of undefined.

What about the block layout example I gave above? We need a general definition that works for that case too.

It's also worth noting that in [resolving intrinsic _row_ sizes](https://drafts.csswg.org/css-grid/#algo-content), the grid area sizes are definite in the _column_ axis so some transferred sizes (e.g. images with a ratio) involving percentages are resolved.

> Anyways, for discussing the exact definition of "to behave as auto" it may be better to file a new issue against css-sizing.

Fair enough, I just don't see a reason to change what is already a working definition. Especially since it's a long-standing and widely used term and thus changing it invalidates all prior discussion and comments involving this term (as I described above).

GitHub Notification of comment by MatsPalmgren
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/3612#issuecomment-549357033 using your GitHub account
Received on Monday, 4 November 2019 13:39:42 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:41:56 UTC