forked from mirrors/gecko-dev
Automatic update from web-platform-tests Consistently encompass fragmentainer overflow in the container. Monolithic content may cause a fragmentainer to be overflowed, and the container(s) of the monolithic node should then grow to hold the monolithic content (and thereby also overflow the fragmentainer), if allowed. Some of the tests included here were already passing, but not all. For block containers we were doing it wrong if the container of the overflowing (monolithic) fragment had more children after the monolithic node, whereas we got it right if it ended in the current fragmentainer. See monolithic-overflow-002.tentative.html vs. monolithic-overflow-003.tentative.html . For flex containers we were already doing it right. For grid containers and tables we were doing it wrong, because we didn't provide a correct intrinsic block-size (which is used by the fragmentation machinery to handle unbreakable content correctly). One additional complication for grid and tables was that we didn't handle the fact that cells or grid items might (now) be stretched by monolithic content, whereas sibling cells / items aren't. So we had to add support for that. Flex layout also already handles this part correctly, in GiveItemsFinalPositionAndSizeForFragmentation(), by compensating for the difference between space consumed by the flex line and the space consumed by the flex item. Do the same for grid and tables. Although this behavior isn't specified, we're now more compatible with Gecko. This behavior also makes more sense. With the previous behavior a child might overflow its container for no reason (the monolithic child would overflow one fragmentainer, whereas the container would fragment at the fragmentation line). This change also makes it much easier to fix crbug.com/1402540 , so that we can just very easily walk past monolithic content that bleeds into subsequent pages. Bug: 1425077, 1378607 Change-Id: I8ebe706b48fa18abb669041843baef74f021a340 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4370497 Reviewed-by: Alison Maher <almaher@microsoft.com> Commit-Queue: Morten Stenshorne <mstensho@chromium.org> Reviewed-by: Ian Kilpatrick <ikilpatrick@chromium.org> Cr-Commit-Position: refs/heads/main@{#1122895} -- wpt-commits: a2c3d90657a9d510fc80ded0b4c0317e86c3dfa8 wpt-pr: 39224
13 lines
665 B
HTML
13 lines
665 B
HTML
<!DOCTYPE html>
|
|
<link rel="author" title="Morten Stenshorne" href="mailto:mstensho@chromium.org">
|
|
<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=1425077">
|
|
<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="width:100px; height:100px; background:red;">
|
|
<div style="columns:2; gap:0; column-fill:auto; height:60px;">
|
|
<div style="height:100px; background:green;">
|
|
<div style="contain:size; height:300px;"></div>
|
|
<div style="contain:size; height:100px; background:green;"></div>
|
|
</div>
|
|
</div>
|
|
</div>
|