Commit fa3702b9 authored by Christian Biesinger's avatar Christian Biesinger Committed by Commit Bot

[AspectRatio] Support size contained replaced elements

R=ikilpatrick@chromium.org, mstensho@chromium.org

Bug: 1083010, 1045668
Change-Id: Idaf6204ce7db45a91b657f27ea183f6600084c5b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2445449
Commit-Queue: Christian Biesinger <cbiesinger@chromium.org>
Commit-Queue: Morten Stenshorne <mstensho@chromium.org>
Auto-Submit: Christian Biesinger <cbiesinger@chromium.org>
Reviewed-by: default avatarMorten Stenshorne <mstensho@chromium.org>
Cr-Commit-Position: refs/heads/master@{#813179}
parent 2ca56c59
......@@ -178,6 +178,14 @@ void LayoutReplaced::ComputeIntrinsicSizingInfoForReplacedContent(
// Reset the size in case it was already populated.
intrinsic_sizing_info.size = FloatSize();
const StyleAspectRatio& aspect_ratio = StyleRef().AspectRatio();
if (!aspect_ratio.IsAuto()) {
intrinsic_sizing_info.aspect_ratio.SetWidth(
aspect_ratio.GetRatio().Width());
intrinsic_sizing_info.aspect_ratio.SetHeight(
aspect_ratio.GetRatio().Height());
}
// If any of the dimensions are overridden, set those sizes.
if (HasOverrideIntrinsicContentLogicalWidth()) {
intrinsic_sizing_info.size.SetWidth(
......
......@@ -273,11 +273,6 @@ crbug.com/1007134 external/wpt/intersection-observer/v2/delay-test.html [ Pass F
crbug.com/1004547 external/wpt/intersection-observer/cross-origin-iframe.sub.html [ Pass Failure ]
crbug.com/1007229 external/wpt/intersection-observer/same-origin-grand-child-iframe.sub.html [ Pass Failure ]
# Not supported yet
crbug.com/1133835 external/wpt/css/css-sizing/aspect-ratio/replaced-element-023.tentative.html [ Failure ]
crbug.com/1133835 external/wpt/css/css-sizing/aspect-ratio/replaced-element-025.tentative.html [ Failure ]
crbug.com/1133835 external/wpt/css/css-sizing/aspect-ratio/replaced-element-027.tentative.html [ Failure ]
crbug.com/936084 external/wpt/css/css-sizing/max-content-input-001.html [ Failure ]
crbug.com/849459 fragmentation/repeating-thead-under-repeating-thead.html [ Failure ]
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment