[Webkit-unassigned] [Bug 219194] the nested grid container which has replaced item with 'max-height' has wrong width(0px).

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Feb 12 01:15:29 PST 2021


https://bugs.webkit.org/show_bug.cgi?id=219194

--- Comment #17 from Javier Fernandez <jfernandez at igalia.com> ---
Comment on attachment 419892
  --> https://bugs.webkit.org/attachment.cgi?id=419892
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=419892&action=review

>> Source/WebCore/rendering/RenderReplaced.cpp:798
>> +    return hasRelativeLogicalHeight() && style().logicalWidth().isAuto();
> 
> I know I'm already too late here but shouldn't we check that the replaced element does indeed have an aspect ratio? Being a replaced element does not imply that it has an aspect ratio.

I think this change affects to the second part of this statement of the Grid Spec, related to the natural-size:

https://drafts.csswg.org/css-grid-1/#grid-item-sizing
"If the grid item has no preferred aspect ratio, and no natural size in the relevant axis (if it is a replaced element), the grid item is sized as for align-self: stretch."

There is a CSS WG issue precisely about this: https://github.com/w3c/csswg-drafts/issues/5713

Maybe we could consider also the case when the replaced item has a preferred aspect-ratio, but I think grid still needs more work to properly support this properly.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20210212/7359ccbd/attachment.htm>


More information about the webkit-unassigned mailing list