diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 00:47:55 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 00:47:55 +0000 |
commit | 26a029d407be480d791972afb5975cf62c9360a6 (patch) | |
tree | f435a8308119effd964b339f76abb83a57c29483 /testing/web-platform/tests/css/css-grid/layout-algorithm/grid-container-percentage-002.html | |
parent | Initial commit. (diff) | |
download | firefox-26a029d407be480d791972afb5975cf62c9360a6.tar.xz firefox-26a029d407be480d791972afb5975cf62c9360a6.zip |
Adding upstream version 124.0.1.upstream/124.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'testing/web-platform/tests/css/css-grid/layout-algorithm/grid-container-percentage-002.html')
-rw-r--r-- | testing/web-platform/tests/css/css-grid/layout-algorithm/grid-container-percentage-002.html | 305 |
1 files changed, 305 insertions, 0 deletions
diff --git a/testing/web-platform/tests/css/css-grid/layout-algorithm/grid-container-percentage-002.html b/testing/web-platform/tests/css/css-grid/layout-algorithm/grid-container-percentage-002.html new file mode 100644 index 0000000000..34a52937a7 --- /dev/null +++ b/testing/web-platform/tests/css/css-grid/layout-algorithm/grid-container-percentage-002.html @@ -0,0 +1,305 @@ +<!DOCTYPE html> +<html> +<title>CSS Grid: indefinite grid container and percentage rows.</title> +<link rel="author" title="Manuel Rego Casasnovas" href="mailto:rego@igalia.com"/> +<link rel="help" href="https://drafts.csswg.org/css-grid-1/#track-sizing"/> +<link rel="help" href="https://drafts.csswg.org/css-grid/#valdef-grid-template-columns-length-percentage"/> +<meta name="assert" content="This test checks that percentage rows behave as 'auto' if the height of the grid container is indefinite to compute the grid container intrinsic height, but are afterwards resolved against that size."/> +<link rel="issue" href="https://crbug.com/616716"/> +<link rel="stylesheet" href="/css/support/grid.css"/> +<link rel="stylesheet" href="/css/support/height-keyword-classes.css"/> +<link rel="stylesheet" type="text/css" href="/fonts/ahem.css"/> +<style> +.wrapper { + position: relative; + clear: both; +} + +.grid { + font: 10px/1 Ahem; + width: fit-content; +} + +.abspos { + position: absolute; +} + +.fixedSize { + width: 200px; + height: 200px; +} + +.oneRow100 { + grid-template-rows: 100%; +} + +.oneRow50 { + grid-template-rows: 50%; +} + +.twoRows { + grid-template-rows: 100px 50%; +} +</style> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<script src="/resources/check-layout-th.js"></script> +<script type="text/javascript"> + setup({ explicit_done: true }); +</script> +<body onload="document.fonts.ready.then(() => { checkLayout('.grid'); })"> +<div id="log"></div> +<div class="wrapper"> + <div class="grid oneRow100" data-expected-width="40" data-expected-height="10"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="10"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid fixedSize oneRow100" data-expected-width="200" data-expected-height="200"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="200" data-expected-height="200"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid abspos oneRow100" data-expected-width="40" data-expected-height="10"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="10"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid max-content oneRow100" data-expected-width="40" data-expected-height="10"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="10"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid fit-content oneRow100" data-expected-width="40" data-expected-height="10"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="10"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid min-content oneRow100" data-expected-width="40" data-expected-height="10"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="10"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid oneRow50" data-expected-width="40" data-expected-height="10"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="5"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid fixedSize oneRow50" data-expected-width="200" data-expected-height="200"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="200" data-expected-height="100"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid abspos oneRow50" data-expected-width="40" data-expected-height="10"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="5"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid max-content oneRow50" data-expected-width="40" data-expected-height="10"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="5"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid fit-content oneRow50" data-expected-width="40" data-expected-height="10"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="5"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid min-content oneRow50" data-expected-width="40" data-expected-height="10"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="5"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid twoRows" data-expected-width="40" data-expected-height="110"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="100"> + </div> + <div class="secondRowFirstColumn" + data-offset-x="0" data-offset-y="100" data-expected-width="40" data-expected-height="55"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid fixedSize twoRows" data-expected-width="200" data-expected-height="200"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="200" data-expected-height="100"> + </div> + <div class="secondRowFirstColumn" + data-offset-x="0" data-offset-y="100" data-expected-width="200" data-expected-height="100"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid abspos twoRows" data-expected-width="40" data-expected-height="110"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="100"> + </div> + <div class="secondRowFirstColumn" + data-offset-x="0" data-offset-y="100" data-expected-width="40" data-expected-height="55"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid max-content twoRows" data-expected-width="40" data-expected-height="110"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="100"> + </div> + <div class="secondRowFirstColumn" + data-offset-x="0" data-offset-y="100" data-expected-width="40" data-expected-height="55"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid fit-content twoRows" data-expected-width="40" data-expected-height="110"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="100"> + </div> + <div class="secondRowFirstColumn" + data-offset-x="0" data-offset-y="100" data-expected-width="40" data-expected-height="55"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid min-content twoRows" data-expected-width="40" data-expected-height="110"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="100"> + </div> + <div class="secondRowFirstColumn" + data-offset-x="0" data-offset-y="100" data-expected-width="40" data-expected-height="55"> + XX X + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid twoRows" data-expected-width="40" data-expected-height="100"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="100"> + XX X + </div> + <div class="secondRowFirstColumn" + data-offset-x="0" data-offset-y="100" data-expected-width="40" data-expected-height="50"> + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid fixedSize twoRows" data-expected-width="200" data-expected-height="200"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="200" data-expected-height="100"> + XX X + </div> + <div class="secondRowFirstColumn" + data-offset-x="0" data-offset-y="100" data-expected-width="200" data-expected-height="100"> + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid abspos twoRows" data-expected-width="40" data-expected-height="100"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="100"> + XX X + </div> + <div class="secondRowFirstColumn" + data-offset-x="0" data-offset-y="100" data-expected-width="40" data-expected-height="50"> + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid max-content twoRows" data-expected-width="40" data-expected-height="100"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="100"> + XX X + </div> + <div class="secondRowFirstColumn" + data-offset-x="0" data-offset-y="100" data-expected-width="40" data-expected-height="50"> + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid fit-content twoRows" data-expected-width="40" data-expected-height="100"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="100"> + XX X + </div> + <div class="secondRowFirstColumn" + data-offset-x="0" data-offset-y="100" data-expected-width="40" data-expected-height="50"> + </div> + </div> +</div> + +<div class="wrapper"> + <div class="grid min-content twoRows" data-expected-width="40" data-expected-height="100"> + <div class="firstRowFirstColumn" + data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="100"> + XX X + </div> + <div class="secondRowFirstColumn" + data-offset-x="0" data-offset-y="100" data-expected-width="40" data-expected-height="50"> + </div> + </div> +</div> + +</body> +</html> |