forked from mirrors/gecko-dev
Automatic update from web-platform-tests fixup! [css-grid] Migrate flex-sizing-columns-min-max-width.html to WPT This CL updates the title and assert slightly to be aligned with flex-sizing-rows-min-max-height-001.html. Bug: 1063749 Change-Id: Ie16502fa396475e402a7649a74f1cfced215f478 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2153177 Reviewed-by: Manuel Rego <rego@igalia.com> Commit-Queue: Gyuyoung Kim <gyuyoung@igalia.com> Cr-Commit-Position: refs/heads/master@{#759990} -- wpt-commits: 8d11959e5d2917a3e01471d2ee058a4b8c127297 wpt-pr: 23039
94 lines
4.5 KiB
HTML
94 lines
4.5 KiB
HTML
<!DOCTYPE HTML>
|
|
<title>CSS Grid Layout Test: min and max width when computing the flex column</title>
|
|
<link rel="author" title="Sergio Villar" href="mailto:svillar@igalia.com"/>
|
|
<link rel="help" href="https://drafts.csswg.org/css-grid/#algo-flex-tracks"/>
|
|
<link rel="issue" href="https://bugs.chromium.org/p/chromium/issues/detail?id=660690"/>
|
|
<link href="/css/support/grid.css" rel="stylesheet"/>
|
|
<link href="/css/support/width-keyword-classes.css" rel="stylesheet">
|
|
<meta name="assert" content="This test ensures that minimum and maximum widths are used to compute the flex fraction for grid columns."/>
|
|
<style>
|
|
.grid {
|
|
margin: 3px;
|
|
grid: 50px / minmax(10px, 1fr) minmax(10px, 4fr);
|
|
grid-column-gap: 33px;
|
|
border: 5px dashed;
|
|
padding: 2px;
|
|
}
|
|
|
|
.float { float: left; }
|
|
|
|
.item:nth-child(1) { background-color: purple; }
|
|
.item:nth-child(2) { background-color: blue; }
|
|
</style>
|
|
<script src="/resources/testharness.js"></script>
|
|
<script src="/resources/testharnessreport.js"></script>
|
|
<script src="/resources/check-layout-th.js"></script>
|
|
<body onload="checkLayout('.grid')">
|
|
|
|
<p>This test PASS if all the grids in the same row look the same.</p>
|
|
|
|
<div class="grid float" style="max-width: 70px" data-expected-height="64" data-expected-width="84">
|
|
<div class="item" data-expected-height="50" data-expected-width="10"></div>
|
|
<div class="item" data-expected-height="50" data-expected-width="27"></div>
|
|
</div>
|
|
<div class="grid float" style="min-width: 70px; max-width: 60px" data-expected-height="64" data-expected-width="84">
|
|
<div class="item" data-expected-height="50" data-expected-width="10"></div>
|
|
<div class="item" data-expected-height="50" data-expected-width="27"></div>
|
|
</div>
|
|
<div class="grid float" style="width: 70px" data-expected-height="64" data-expected-width="84">
|
|
<div class="item" data-expected-height="50" data-expected-width="10"></div>
|
|
<div class="item" data-expected-height="50" data-expected-width="27"></div>
|
|
</div>
|
|
|
|
<br clear="all">
|
|
|
|
<div class="grid float" style="min-width: 108px" data-expected-height="64" data-expected-width="122">
|
|
<div class="item" data-expected-height="50" data-expected-width="15"></div>
|
|
<div class="item" data-expected-height="50" data-expected-width="60"></div>
|
|
</div>
|
|
<div class="grid float" style="min-width: 108px; max-width: 60px" data-expected-height="64" data-expected-width="122">
|
|
<div class="item" data-expected-height="50" data-expected-width="15"></div>
|
|
<div class="item" data-expected-height="50" data-expected-width="60"></div>
|
|
</div>
|
|
<div class="grid float" style="width: 108px" data-expected-height="64" data-expected-width="122">
|
|
<div class="item" data-expected-height="50" data-expected-width="15"></div>
|
|
<div class="item" data-expected-height="50" data-expected-width="60"></div>
|
|
</div>
|
|
|
|
<br clear="all">
|
|
|
|
<div class="grid float min-width-max-content" data-expected-height="64" data-expected-width="97">
|
|
<div class="item" data-expected-height="50" data-expected-width="10"></div>
|
|
<div class="item" data-expected-height="50" data-expected-width="40"></div>
|
|
</div>
|
|
<div class="grid float min-width-max-content max-width-min-content" data-expected-height="64" data-expected-width="97">
|
|
<div class="item" data-expected-height="50" data-expected-width="10"></div>
|
|
<div class="item" data-expected-height="50" data-expected-width="40"></div>
|
|
</div>
|
|
<div class="grid float max-content" data-expected-height="64" data-expected-width="97">
|
|
<div class="item" data-expected-height="50" data-expected-width="10"></div>
|
|
<div class="item" data-expected-height="50" data-expected-width="40"></div>
|
|
</div>
|
|
|
|
<br clear="all">
|
|
|
|
<div class="float min-content">
|
|
<div class="grid min-width-max-content" data-expected-height="64" data-expected-width="97">
|
|
<div class="item" data-expected-height="50" data-expected-width="10"></div>
|
|
<div class="item" data-expected-height="50" data-expected-width="40"></div>
|
|
</div>
|
|
</div>
|
|
<div class="float max-content">
|
|
<div class="grid min-width-max-content max-width-min-content" data-expected-height="64" data-expected-width="97">
|
|
<div class="item" data-expected-height="50" data-expected-width="10"></div>
|
|
<div class="item" data-expected-height="50" data-expected-width="40"></div>
|
|
</div>
|
|
</div>
|
|
<div class="float fit-content">
|
|
<div class="grid max-content" data-expected-height="64" data-expected-width="97">
|
|
<div class="item" data-expected-height="50" data-expected-width="10"></div>
|
|
<div class="item" data-expected-height="50" data-expected-width="40"></div>
|
|
</div>
|
|
</div>
|
|
|
|
</body>
|