Re: [csswg-drafts] [css-sizing-4] min/max size transfers across aspect-ratio (#6071)

Capturing some thoughts from discussing with @fantasai and @bfgeek today:

* auto preferred sizes defers to transferred constraints (min/max)
* transferred constraints defer to explicit (non-auto) in-axis preferred sizes and constraints
* in-axis automatic minimum defers to in-axis constraints only (ignores transferred constraints)

Some examples, all with `aspect-ratio: 1/1`:

* `max-height: 100px; width: auto;` clamps the width to 100px (transferred constraint)
* `max-height: 100px; max-width: 200px;` clamps the width to 100px (transferred constraint; you get two maxes, so the smaller one effectively applies)
* `max-height: 100px; width: 200px;` the width is 200px (explicit width wins over transferred constraint)
* `max-height: 100px; min-width: 200px;` the width is 200px (transferred max-height is floored by the explicit min-width, effectively becoming a `max-width:200px`)
* `max-height: 100px; min-width: auto;` uses the auto minimum; the 100px doesn't clamp it.

-- 
GitHub Notification of comment by tabatkins
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6071#issuecomment-2243986313 using your GitHub account


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

Received on Monday, 22 July 2024 23:37:21 UTC