Skip to content

Commit

Permalink
[FlexNG] Item offsets when fragmenting
Browse files Browse the repository at this point in the history
In order to support an item that doesn't start in the first
fragmentainer, the item offset must be adjusted to take the previously
consumed block size into account.

Test added for single-line column flex. Tests for the other container
types will follow once fragmentation support is added.

Bug: 660611
Change-Id: I60739077144ec729a81eb024c17dcfcd398c5ce2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3230383
Commit-Queue: Alison Maher <[email protected]>
Reviewed-by: Morten Stenshorne <[email protected]>
Cr-Commit-Position: refs/heads/main@{#934221}
  • Loading branch information
alisonmaher authored and chromium-wpt-export-bot committed Oct 22, 2021
1 parent 2afde04 commit 04499b8
Showing 1 changed file with 33 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
<!DOCTYPE html>
<title>
Single-line column flex fragmentation.
</title>
<link rel="help" href="https://drafts.csswg.org/css-flexbox-1/#pagination">
<link rel="match" href="../../reference/ref-filled-green-100px-square.xht">
<style>
.multicol {
background: red;
column-count: 4;
column-fill: auto;
column-gap: 0px;
height: 100px;
width: 100px;
}
.flex {
display: flex;
flex-direction: column;
width: 25px;
}
.flex > div {
background: green;
width: 25px;
}
</style>
<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
<div class="multicol">
<div class="flex">
<div style="height: 150px;"></div>
<div style="height: 150px;"></div>
<div style="height: 100px;"></div>
</div>
</div>

0 comments on commit 04499b8

Please sign in to comment.