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-row-axis-alignment-sticky-positioned-items-001.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-row-axis-alignment-sticky-positioned-items-001.html')
-rw-r--r-- | testing/web-platform/tests/css/css-grid/alignment/grid-row-axis-alignment-sticky-positioned-items-001.html | 75 |
1 files changed, 75 insertions, 0 deletions
diff --git a/testing/web-platform/tests/css/css-grid/alignment/grid-row-axis-alignment-sticky-positioned-items-001.html b/testing/web-platform/tests/css/css-grid/alignment/grid-row-axis-alignment-sticky-positioned-items-001.html new file mode 100644 index 0000000000..31d06b8062 --- /dev/null +++ b/testing/web-platform/tests/css/css-grid/alignment/grid-row-axis-alignment-sticky-positioned-items-001.html @@ -0,0 +1,75 @@ +<!DOCTYPE html> +<meta charset="utf-8"> +<title>CSS Grid Layout Test: Self-Alignment along row axis of stcky positioned items</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/#row-align"> +<link rel="help" href="https://www.w3.org/TR/css-position-3/#sticky-pos"> +<link rel="help" href="https://drafts.csswg.org/css-align-3/#propdef-justify-self"> +<link rel="stylesheet" href="../../support/alignment.css"> +<meta name="assert" content="Sticky positioned grid items are aligned correcly."> +<style> +.container { + border: solid 1px; + overflow: auto; + width: 500px; +} +.grid { + position: relative; + display: grid; + grid-template-columns: 100px 100px 100px 300px; + grid-template-rows: 75px 75px 75px 75px; + background: grey; + width: 400px; + margin-bottom: 20px; +} +.sticky { + position: -webkit-sticky; + position: sticky; + width: 20px; + height: 20px; + background-color: #cae8ca; +} +.item1 { + left: 0px; + grid-column: 1; + grid-row: 1; +} +.item2 { + left: 0px; + grid-column: 2; + grid-row: 2; +} +.item3 { + left: 0px; + grid-column: 3; + grid-row: 3; +} +.item4 { + grid-column: 4; + grid-row: 4; + background: lightgrey; +} +.scroll { overflow: auto; } +</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')"> +<div class="container"> + <div style="width: 30px; float:left; height: 10px;"></div> + <div class="grid"> + <div class="item1 sticky justifySelfStart" data-offset-x="0" data-offset-y="0"></div> + <div class="item2 sticky justifySelfCenter" data-offset-x="140" data-offset-y="75"></div> + <div class="item3 sticky justifySelfEnd" data-offset-x="280" data-offset-y="150"></div> + <div class="item4"></div> + </div> + <div style="width: 30px; float:left; height: 10px;"></div> + <div class="grid scroll"> + <div class="item1 sticky justifySelfStart" data-offset-x="0" data-offset-y="0"></div> + <div class="item2 sticky justifySelfCenter" data-offset-x="140" data-offset-y="75"></div> + <div class="item3 sticky justifySelfEnd" data-offset-x="280" data-offset-y="150"></div> + <div class="item4"></div> + </div> + <div style="width: 2000px; height: 10px;"></div> +</div> +</body> |