The following WPT tests are failing in WebKit: css/css-grid/alignment/grid-item-no-aspect-ratio-stretch-5.html css/css-grid/alignment/grid-item-no-aspect-ratio-stretch-6.html css/css-grid/alignment/grid-item-no-aspect-ratio-stretch-7.html css/css-grid/alignment/grid-item-no-aspect-ratio-stretch-8.html css/css-grid/alignment/grid-item-no-aspect-ratio-stretch-9.html css/css-grid/alignment/grid-item-no-aspect-ratio-stretch-10.html https://wpt.fyi/results/css/css-grid/alignment?label=master&label=experimental&aligned&q=grid-item-no-aspect-ratio-stretch Most of them (except 6 and 7) also fail in Chromium: https://crbug.com/1114013
<rdar://problem/68666896>
Created attachment 423644 [details] Patch
Comment on attachment 423644 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=423644&action=review The patch looks good, but it doesn't fix all the tests that has been identified as failing due to this bug. We should either fix all of them or create a different bug, which this will depend on, and provide this patch as fix for that. > Source/WebCore/ChangeLog:8 > + When SVG element has fixed width or height as 0, it should also be reflected as true for has s/for has/for > Source/WebCore/ChangeLog:10 > + RenderReplaced::computeReplacedLogicalHeight. This change is to differentiate the case when Could you explain a bit more the case we want to differentiate from ? > Source/WebCore/platform/graphics/FloatSize.h:75 > + bool hasWidth = false; Give than we set it to true if the Length value assigned to FloatSize attributes is Fixed or not, wouldn't be better to define these attributes as isFixed ? > Source/WebCore/rendering/svg/RenderSVGRoot.cpp:83 > + intrinsicSize.hasWidth = svgSVGElement().intrinsicWidth().isFixed(); The function computeIntrinsicRatioInformation is overridden by RenderImage as well; shouldn't this class set values to the hasWidth and hasHeight as well ? Otherwise, we'll use the default values for these FloatSize's fields in the RenderReplaced logic. Additionally, are you sure that isFixed is enough ? Wouldn't be better to check use Length::isSpeficied() instead ? (it includes percent or calculated as well).
Fixes on css/css-grid/alignment/grid-item-no-aspect-ratio-stretch-6.html css/css-grid/alignment/grid-item-no-aspect-ratio-stretch-7.html are now at https://bugs.webkit.org/show_bug.cgi?id=223504
Created attachment 452396 [details] expectations
*** Bug 236792 has been marked as a duplicate of this bug. ***
Comment on attachment 452396 [details] expectations Clearing flags on attachment: 452396 Committed r290038 (247416@trunk): <https://commits.webkit.org/247416@trunk>
(In reply to Robert Jenner from comment #7) > Comment on attachment 452396 [details] > expectations > > Clearing flags on attachment: 452396 > > Committed r290038 (247416@trunk): <https://commits.webkit.org/247416@trunk> I authored this commit, and Robert landed it for me, the purpose of the commit was to change the expectations on the two tests that did not receive changes, to relieve the EWS queue backlog.
My intention was only to fix css/css-grid/alignment/grid-item-no-aspect-ratio-stretch-6.html css/css-grid/alignment/grid-item-no-aspect-ratio-stretch-7.html and they are being addressed at bug 223504.