wpt / css / css-grid / grid-lanes / track-sizing / auto-repeat / intrinsic-auto-repeat / column-auto-repeat-auto-012.html

Status: FAIL | Duration: 16ms | Subtests: 0/1 | Open test on wpt.live | Open ref on wpt.live | wpt.fyi

/css/css-grid/grid-lanes/track-sizing/auto-repeat/intrinsic-auto-repeat/column-auto-repeat-auto-012.html

<!DOCTYPE html>
<html>
<title>Auto-fit repeat tracks with auto size</title>
<link rel="help" href="https://drafts.csswg.org/css-grid-3">
<link rel="match" href="column-auto-repeat-auto-012-ref.html">
<link rel="author" title="Alison Maher" href="mailto:almaher@microsoft.com">
<style>
.grid-lanes {
    display: grid-lanes;
    background: gray;
    flow-tolerance: 0;
    grid-template-columns: repeat(auto-fit, auto);
    height: 300px;
    width: 300px;
}

.grid-lanes > div {
    width: 100px;
    height: 100px;
}
</style>
<body>
  <div class="grid-lanes">
    <!-- The second track should still be collapsed, even though this
    item is placed in every possible track. -->
    <div style="background: lightskyblue;">
      Number 1
    </div>
    <div style="background: lightcoral; grid-column: 3;">
      Number 2
    </div>
    <div style="background: lightgreen; grid-column: 1;">
      Number 3
    </div>
    <div style="background: lightpink; grid-column: 3;">
      Number 4
    </div>
    <div style="background: orange; grid-column:1;">
      Number 5
    </div>
  </div>
</body>
</html>

/css/css-grid/grid-lanes/track-sizing/auto-repeat/intrinsic-auto-repeat/column-auto-repeat-auto-012-ref.html

<!DOCTYPE html>
<html>
<style>
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, 150px);
    grid-template-rows: 100px 100px;
    background: gray;
    height: 300px;
    width: 300px;
}

.grid > div {
    width: 100px;
    height: 100px;
}
</style>
<body>
  <div class="grid">
    <div style="background: lightskyblue;">
      Number 1
    </div>
    <div style="background: lightcoral;">
      Number 2
    </div>
    <div style="background: lightgreen;">
      Number 3
    </div>
    <div style="background: lightpink;">
      Number 4
    </div>
    <div style="background: orange;">
      Number 5
    </div>
  </div>
</body>
</html>