summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/css/css-flexbox/flex-minimum-width-flex-items-014.html
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 00:47:55 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 00:47:55 +0000
commit26a029d407be480d791972afb5975cf62c9360a6 (patch)
treef435a8308119effd964b339f76abb83a57c29483 /testing/web-platform/tests/css/css-flexbox/flex-minimum-width-flex-items-014.html
parentInitial commit. (diff)
downloadfirefox-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-flexbox/flex-minimum-width-flex-items-014.html')
-rw-r--r--testing/web-platform/tests/css/css-flexbox/flex-minimum-width-flex-items-014.html69
1 files changed, 69 insertions, 0 deletions
diff --git a/testing/web-platform/tests/css/css-flexbox/flex-minimum-width-flex-items-014.html b/testing/web-platform/tests/css/css-flexbox/flex-minimum-width-flex-items-014.html
new file mode 100644
index 0000000000..04e447b05d
--- /dev/null
+++ b/testing/web-platform/tests/css/css-flexbox/flex-minimum-width-flex-items-014.html
@@ -0,0 +1,69 @@
+<!DOCTYPE html>
+<title>CSS Flexbox: Proper min-width intrinsic size with display: flex</title>
+<link rel="help" href="https://www.w3.org/TR/css-flexbox-1/#flex-containers">
+<link rel="help" href="https://www.w3.org/TR/CSS2/visudet.html#min-max-widths">
+<meta name="assert" content="This test checks that min-width intrinsic size still applies if a fixed width is set.">
+<style>
+.min-content {
+ width: 10px;
+ min-width: min-content;
+ outline: 2px solid;
+ display: flex;
+ flex-wrap: wrap;
+}
+.max-content {
+ width: 10px;
+ min-width: max-content;
+ outline: 2px solid;
+ display: flex;
+ flex-wrap: wrap;
+}
+.fit-content {
+ width: 10px;
+ min-width: fit-content;
+ outline: 2px solid;
+ display: flex;
+ flex-wrap: wrap;
+}
+.child {
+ width: 20px;
+ height: 20px;
+ background-color: pink;
+}
+div {
+ display: inline-block;
+ line-height: 0;
+}
+</style>
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<script src="/resources/check-layout-th.js"></script>
+
+<body onload="checkLayout('body > div')">
+<div id=log></div>
+
+<div class="min-content" data-expected-width=20>
+ <div class="child"></div><div class="child"></div>
+</div>
+
+<div class="max-content" data-expected-width=40>
+ <div class="child"></div><div class="child"></div>
+</div>
+
+<div class="fit-content" data-expected-width=40>
+ <div class="child"></div><div class="child"></div>
+</div>
+
+<div style="width: 30px">
+ <div class="fit-content" data-expected-width=30>
+ <div class="child"></div><div class="child"></div>
+ </div>
+</div>
+
+<div style="width: 10px">
+ <div class="fit-content" data-expected-width=20>
+ <div class="child"></div><div class="child"></div>
+ </div>
+</div>
+
+</body>