Skip to content

Commit

Permalink
[LayoutNG] Fix what replaced descendants resolve %-block-sizes...
Browse files Browse the repository at this point in the history
resolve against during the OOF-positioned min/max phase.

Previously we resolved against the wrong %-block-size during the
OOF-positioned min/max phase. The resulted in an incorrect size for the
OOF-positioned node.

This corrects what we resolve against.

Change-Id: I24be784cfce1ec8cc416cdb286034e71f9c20358
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2105753
Commit-Queue: Ian Kilpatrick <ikilpatrick@chromium.org>
Reviewed-by: Christian Biesinger <cbiesinger@chromium.org>
Reviewed-by: Aleks Totic <atotic@chromium.org>
Cr-Commit-Position: refs/heads/master@{#750741}
  • Loading branch information
bfgeek authored and chromium-wpt-export-bot committed Mar 16, 2020
1 parent 3555a98 commit 9b0f58e
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions css/css-writing-modes/abs-pos-with-replaced-child.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<!DOCTYPE html>
<link rel="match" href="../reference/ref-filled-green-100px-square-only.html">
<link rel="help" href="https://drafts.csswg.org/css-sizing-3/#intrinsic-sizes">
<link rel="help" href="https://drafts.csswg.org/css-writing-modes-3/">
<meta name="assert" content="This test checks that the intrinsic size of an absolute positioned element is calculated correctly, with a replaced child that has a percentage block-size." />
<p>Test passes if there is a filled green square.</p>
<div style="position: relative; width: 200px; height: 100px;">
<div style="position: absolute; background: green; writing-mode: vertical-rl; width: 50%;">
<canvas style="width: 100%;" width=1 height=1></canvas>
</div>
</div>

0 comments on commit 9b0f58e

Please sign in to comment.