Skip to content

Commit

Permalink
Avoid fragmentainer overflow from children of monolithic content.
Browse files Browse the repository at this point in the history
Checking if the border box of a monolithic element can fit in the
current fragmentainer isn't enough. Children may overflow its border
box, and it's this size that we need to consider when determining
whether a monolithic element can fit in the current fragmentainer, or if
we have to push it to the next one.

Had to add a work-around to
fast/multicol/vertical-lr/balancing/balance-unbreakable.html to prevent
the (monolithic) IMG element (with alt text) in the test from messing
up. The broken image symbol got incorrectly aligned and therefore
incorrectly contributed to overflow. Reported crbug.com/1178743 for
this. Use a real image as a work-around. My first attempt was to switch
the IMG to writing-mode:horizontal-tb, but that messes up legacy column
balancing. Oh well...

Bug: 1178742
Change-Id: Iffbe55d53f32003ae58b574bb6a38745bb92d42e
  • Loading branch information
mstensho authored and chromium-wpt-export-bot committed Feb 23, 2021
1 parent d2ac09d commit fccdb77
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions css/css-break/monolithic-with-overflow.html
@@ -0,0 +1,11 @@
<!DOCTYPE html>
<link rel="author" title="Morten Stenshorne" href="mailto:mstensho@chromium.org">
<link rel="help" href="https://www.w3.org/TR/css-break-3/#monolithic">
<link rel="match" href="../reference/ref-filled-green-100px-square.xht">
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
<div style="columns:2; column-gap:0; column-fill:auto; width:100px; height:100px; background:red;">
<div style="height:100px; background:green;"></div>
<div style="contain:size; height:0;">
<div style="height:100px; background:green;"></div>
</div>
</div>

0 comments on commit fccdb77

Please sign in to comment.