[csswg-drafts] [css-position-3] A bug about "weaker-inset" of inset-modified containing block (#9468)

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

== [css-position-3] A bug about "weaker-inset" of inset-modified containing block ==
The spec defines "[weaker inset](https://drafts.csswg.org/css-position/#weaker-inset)" as:

> In the case that only one inset is [`auto`](https://drafts.csswg.org/css-position/#valdef-top-auto), that is the weaker inset; otherwise the weaker inset is the inset of the [end](https://drafts.csswg.org/css-writing-modes-4/#css-end) edge (where end is interpreted relative to the [writing mode](https://drafts.csswg.org/css-writing-modes-4/#writing-mode) of the containing block).

And if the previous steps of IMCB gives a negative size in any axis, the weaker inset is reduced to bring the size back up to zero.

This seems incorrect when both insets are `auto`, in which case the IMCB is produced by extending from the static position. So the weaker-inset-reduction process should be a reversal of that extension. So instead of looking at the writing modes and directions, it should be:
- For `self-start` alignment or its equivalent, the weaker inset is the end inset (in the element's own writing direction, ditto below)
- For `self-end` alignment or its equivalent, the weaker inset is the start inset
- For `center` alignment, both insets are equally weak, and should both be reduced by the same amount until they meet at the static position

@tabatkins 

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


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

Received on Friday, 13 October 2023 22:35:49 UTC