Skip to content

[css-flexbox][css-grid] Automatic minimum size on replaced element with overflow different than visible/clip #8502

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Loirooriol opened this issue Feb 27, 2023 · 1 comment
Labels
Closed as Question Answered Used when the issue is more of a question than a problem, and it's been answered. css-flexbox-1 Current Work css-grid-2 Subgrid; Current Work

Comments

@Loirooriol
Copy link
Contributor

https://software.hixie.ch/utilities/js/live-dom-viewer/saved/11339

<div style="display: flex; width: 50px;">
  <canvas width="1" height="1" style="background: blue; height: 100px; overflow: visible"></canvas>
</div>
<div style="display: flex; width: 50px;">
  <canvas width="1" height="1" style="background: cyan; height: 100px; overflow: scroll"></canvas>
</div>

There is interoperability that in the 1st case the automatic minimum size makes the flex item be 100px, and in the 2nd case the automatic minimum size is avoided due to overflow: scroll.

However, https://drafts.csswg.org/css-flexbox-1/#min-size-auto says "a flex item that is not a scroll container". And the <canvas> is replaced, so it's not really a scroll container?

Should the spec check the computed value of overflow-x/y instead of being a scroll container? Should browsers change?

@Loirooriol
Copy link
Contributor Author

From #7714 (comment)

RES0LVED: in the flex spec, for auto min sizing, instead of saying scroll container, we read the computed overflow property value

@Loirooriol Loirooriol added the Closed as Question Answered Used when the issue is more of a question than a problem, and it's been answered. label Nov 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Closed as Question Answered Used when the issue is more of a question than a problem, and it's been answered. css-flexbox-1 Current Work css-grid-2 Subgrid; Current Work
Projects
None yet
Development

No branches or pull requests

1 participant