[csswg-drafts] [css-align] justify/align have double effect in fieldsets? (#8690)

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

== [css-align] justify/align have double effect in fieldsets? ==
HTML [specifies](https://html.spec.whatwg.org/multipage/rendering.html#the-fieldset-and-legend-elements) that fieldset elements generate a principal box that establishes a box formatting context. Then, the anonymous fieldset content box [inherits](https://html.spec.whatwg.org/multipage/rendering.html#anonymous-fieldset-content-box) the justify/align properties from the fieldset element.

So, the justify/align properties take effect in the anonymous content box AND the principal box.

Things get hairy with column flexboxes:
```html
<fieldset style="display: flex; flex-flow: column; align-content: end; width: 200px; min-height: 200px;">
  <div style="width: 100px; height: 100px;"></div>
</fieldset>
```

If `align-content: end` applies in both principal and anonymous boxes, then the 100x100 square will be on the bottom right of the fieldset: the principal box moves the anonymous box to the bottom because that's what `align-content: end` does in block flow, and the anonymous box moves the flex item to the right, because that's what `align-content: end` does in column flexboxes.

For simplicity, can we change css-align to require that justify/align properties don't take effect in fieldset-generated principal boxes?

This is a bit intertwined with the proposal to change how the anonymous content box's height is derived at https://github.com/whatwg/html/issues/9123.

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


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

Received on Thursday, 6 April 2023 00:03:01 UTC