diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 09:22:09 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 09:22:09 +0000 |
commit | 43a97878ce14b72f0981164f87f2e35e14151312 (patch) | |
tree | 620249daf56c0258faa40cbdcf9cfba06de2a846 /testing/web-platform/tests/css/css-flexbox/overflow-auto-003.html | |
parent | Initial commit. (diff) | |
download | firefox-43a97878ce14b72f0981164f87f2e35e14151312.tar.xz firefox-43a97878ce14b72f0981164f87f2e35e14151312.zip |
Adding upstream version 110.0.1.upstream/110.0.1upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'testing/web-platform/tests/css/css-flexbox/overflow-auto-003.html')
-rw-r--r-- | testing/web-platform/tests/css/css-flexbox/overflow-auto-003.html | 62 |
1 files changed, 62 insertions, 0 deletions
diff --git a/testing/web-platform/tests/css/css-flexbox/overflow-auto-003.html b/testing/web-platform/tests/css/css-flexbox/overflow-auto-003.html new file mode 100644 index 0000000000..29063b79d5 --- /dev/null +++ b/testing/web-platform/tests/css/css-flexbox/overflow-auto-003.html @@ -0,0 +1,62 @@ +<!DOCTYPE html> +<html> +<title>CSS Flexbox: margin: auto and overflow: auto with nested flexboxes.</title> +<link rel="help" href="https://drafts.csswg.org/css-flexbox/#auto-margins"> +<link rel="help" href="https://drafts.csswg.org/css-overflow-3/#overflow-properties"> +<link rel="help" href="https://drafts.csswg.org/css-box-3/#margins"> +<link rel="help" href="https://crbug.com/605682"> +<meta name="assert" content="This test checks that 'margin: auto' set on the outer box gets properly handled when the inner box uses 'overflow: auto', in a layout with two nested flexboxes." /> + +<style> +html, body { + margin: 0; + padding: 0; +} + +.flexbox { + display: flex; + background: papayawhip; + width: 800px; +} + +.flexbox > div { + width: 300px; + height: 300px; + margin: 0 auto; + background: olive; +} + +.flexbox > div > div { + overflow-y: auto; + height: 50px; + visibility: hidden; +} + +.elm { + height: 10px; +} +</style> + +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<script src="/resources/check-layout-th.js"></script> + +<body> + +<div id=log></div> +<p>Below there should be a olive square <em>centered</em> inside a papayawhip box.</p> +<div class="flexbox"> + <div data-offset-x="250"> + <div> + <div id="elm"></div> + </div> + </div> +</div> + +<script> +document.body.offsetTop; +document.getElementById("elm").style.height = "800px"; +checkLayout('.flexbox'); +</script> +</body> +</html> |