[csswg-drafts] [css-sizing] Last remembered size relies on unclear `contain-intrinsic-size: auto` (#7516)

Loirooriol has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-sizing] Last remembered size relies on unclear `contain-intrinsic-size: auto` ==
https://drafts.csswg.org/css-sizing-4/#last-remembered

> The [last remembered size](https://drafts.csswg.org/css-sizing-4/#last-remembered) of an element is determined by:
>  -  At the time that [ResizeObserver](https://drafts.csswg.org/resize-observer-1/#resizeobserver) events are determined and delivered, if an element has [`contain-intrinsic-size: auto`](https://drafts.csswg.org/css-sizing-4/#propdef-contain-intrinsic-size), is capable of being a [ResizeObserver](https://drafts.csswg.org/resize-observer-1/#resizeobserver) target, but does not have [size containment](https://drafts.csswg.org/css-contain-2/#size-containment), record the current inner dimensions of its [principal box](https://drafts.csswg.org/css-display-3/#principal-box) as its [last remembered size](https://drafts.csswg.org/css-sizing-4/#last-remembered).
>  -  At the time that [ResizeObserver](https://drafts.csswg.org/resize-observer-1/#resizeobserver) events are determined and delivered, if an element has a [last remembered size](https://drafts.csswg.org/css-sizing-4/#last-remembered) but does not have [`contain-intrinsic-size: auto`](https://drafts.csswg.org/css-sizing-4/#propdef-contain-intrinsic-size), remove its last remembered size.

The checks for `contain-intrinsic-size: auto` are unclear because:

 - `auto` alone is invalid, it must be followed by a length.
 - `contain-intrinsic-size` is a shorthand. What happens if only one of `contain-intrinsic-width` and `contain-intrinsic-height` contains `auto`?

I guess the check should be whether both `contain-intrinsic-width` and `contain-intrinsic-height` have `auto`? Or should the last remembered width and height be set or removed independently?

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/7516 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 20 July 2022 00:35:12 UTC