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/alignment/grid-self-baseline-not-applied-if-sizing-cyclic-dependency-003.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/alignment/grid-self-baseline-not-applied-if-sizing-cyclic-dependency-003.html')
-rw-r--r-- | testing/web-platform/tests/css/css-grid/alignment/grid-self-baseline-not-applied-if-sizing-cyclic-dependency-003.html | 93 |
1 files changed, 93 insertions, 0 deletions
diff --git a/testing/web-platform/tests/css/css-grid/alignment/grid-self-baseline-not-applied-if-sizing-cyclic-dependency-003.html b/testing/web-platform/tests/css/css-grid/alignment/grid-self-baseline-not-applied-if-sizing-cyclic-dependency-003.html new file mode 100644 index 0000000000..3d688ad15f --- /dev/null +++ b/testing/web-platform/tests/css/css-grid/alignment/grid-self-baseline-not-applied-if-sizing-cyclic-dependency-003.html @@ -0,0 +1,93 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: Self-Baseline alignment and sizing cyclic dependency</title> +<link rel="author" title="Javier Fernandez Garcia-Boente" href="mailto:jfernandez@igalia.com"> +<link rel="help" href="https://drafts.csswg.org/css-grid-1/#alignment"> +<link rel="help" href="https://drafts.csswg.org/css-grid-1/#column-align"> +<link rel="help" href="https://drafts.csswg.org/css-grid-1/#row-align"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#propdef-align-items"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#propdef-justify-items"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#baseline-alignment"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#valdef-justify-self-baseline"> +<link rel="stylesheet" href="/css/support/grid.css"> +<link rel="stylesheet" href="../../support/alignment.css"> +<!-- https://github.com/w3c/csswg-drafts/issues/3046 --> +<link rel="stylesheet" type="text/css" href="/fonts/ahem.css" /> +<style> +.grid { + position: relative; + display: inline-grid; + background: grey; + text-orientation: sideways; + font: 15px/1 Ahem; +} +.row { grid: minmax(0px, 1fr) / auto 50px 100px } +.column { grid: auto 50px 100px / minmax(0px, 1fr); } +.item1 { + font-size: 30px; + background: blue; +} +.item2 { + font-size: 20px; + background: red; +} +.item3 { + font-size: 80px; + background: green; +} +.height50 { height: 50px; } +.relativeHeight { height: 50%; } +.relativeWidth { width: 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'); })"> + +<!-- NOTE: previously this test was asserting some "cyclic" behaviour where an item would switch baseline alignment participation - this is no longer the case per spec. --> +<pre>flex row</pre> +<div class="grid row alignItemsBaseline"> + <div class="item1 verticalLR" data-offset-x="0" data-offset-y="34" data-expected-width="30" data-expected-height="30">É</div> + <div class="item2" data-offset-x="30" data-offset-y="48" data-expected-width="50" data-expected-height="20">É</div> + <div class="item3" data-offset-x="80" data-offset-y="0" data-expected-width="100" data-expected-height="80">É</div> +</div> + +<pre>flex row</pre> +<div class="grid row alignItemsBaseline"> + <div class="item1 relativeHeight" data-offset-x="0" data-offset-y="56" data-expected-width="30" data-expected-height="43">É</div> + <div class="item2" data-offset-x="30" data-offset-y="64" data-expected-width="50" data-expected-height="20">É</div> + <div class="item3 verticalLR" data-offset-x="80" data-offset-y="0" data-expected-width="100" data-expected-height="80">É</div> +</div> + +<pre>flex row</pre> +<div class="grid row alignItemsBaseline"> + <div class="item1 relativeHeight" data-offset-x="0" data-offset-y="40" data-expected-width="30" data-expected-height="40">É</div> + <div class="item2 verticalLR" data-offset-x="30" data-offset-y="44" data-expected-width="50" data-expected-height="20">É</div> + <div class="item3" data-offset-x="80" data-offset-y="0" data-expected-width="100" data-expected-height="80">É</div> +</div> + +<pre>flex column - all items share a baseline group</pre> +<div class="grid column justifyItemsBaseline"> + <div class="item1" data-offset-x="16" data-offset-y="0" data-expected-width="30" data-expected-height="30">É</div> + <div class="item2 verticalLR" data-offset-x="12" data-offset-y="30" data-expected-width="20" data-expected-height="50">É</div> + <div class="item3 verticalLR" data-offset-x="0" data-offset-y="80" data-expected-width="80" data-expected-height="100">É</div> +</div> + +<pre>flex column - all items share a baseline group</pre> +<div class="grid column justifyItemsBaseline"> + <div class="item1 relativeWidth height50" data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="50">É</div> + <div class="item2 verticalLR" data-offset-x="12" data-offset-y="50" data-expected-width="20" data-expected-height="50">É</div> + <div class="item3 verticalLR" data-offset-x="0" data-offset-y="100" data-expected-width="80" data-expected-height="100">É</div> +</div> + +<pre>flex column - all items share a baseline group</pre> +<div class="grid column justifyItemsBaseline"> + <div class="item1 relativeWidth height50" data-offset-x="0" data-offset-y="0" data-expected-width="40" data-expected-height="50">É</div> + <div class="item2" data-offset-x="16" data-offset-y="50" data-expected-width="20" data-expected-height="50">É</div> + <div class="item3 verticalLR" data-offset-x="0" data-offset-y="100" data-expected-width="80" data-expected-height="100">É</div> +</div> + +</body> |