summaryrefslogtreecommitdiffstats
path: root/layout/reftests/css-scrollbars
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 /layout/reftests/css-scrollbars
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 'layout/reftests/css-scrollbars')
-rw-r--r--layout/reftests/css-scrollbars/reftest.list3
-rw-r--r--layout/reftests/css-scrollbars/scrollbar-thin-overflow-change-ref.html17
-rw-r--r--layout/reftests/css-scrollbars/scrollbar-thin-overflow-change.html22
-rw-r--r--layout/reftests/css-scrollbars/scrollbar-width-auto.html6
-rw-r--r--layout/reftests/css-scrollbars/scrollbar-width-thin.html7
-rw-r--r--layout/reftests/css-scrollbars/viewport-scrollbar-color-change-ref.html9
-rw-r--r--layout/reftests/css-scrollbars/viewport-scrollbar-color-change.html17
7 files changed, 81 insertions, 0 deletions
diff --git a/layout/reftests/css-scrollbars/reftest.list b/layout/reftests/css-scrollbars/reftest.list
new file mode 100644
index 0000000000..4720bad942
--- /dev/null
+++ b/layout/reftests/css-scrollbars/reftest.list
@@ -0,0 +1,3 @@
+== viewport-scrollbar-color-change.html viewport-scrollbar-color-change-ref.html
+== scrollbar-thin-overflow-change.html scrollbar-thin-overflow-change-ref.html
+test-pref(layout.css.scrollbar-width-thin.disabled,true) == scrollbar-width-thin.html scrollbar-width-auto.html
diff --git a/layout/reftests/css-scrollbars/scrollbar-thin-overflow-change-ref.html b/layout/reftests/css-scrollbars/scrollbar-thin-overflow-change-ref.html
new file mode 100644
index 0000000000..592690f7ca
--- /dev/null
+++ b/layout/reftests/css-scrollbars/scrollbar-thin-overflow-change-ref.html
@@ -0,0 +1,17 @@
+<!DOCTYPE html>
+<style>
+#outer {
+ scrollbar-width: thin;
+ overflow: auto;
+ border: 5px solid black;
+ background: black;
+ width: 200px;
+ height: 200px;
+}
+#inner {
+ height: 300px;
+}
+</style>
+<div id="outer">
+ <div id="inner"></div>
+</div>
diff --git a/layout/reftests/css-scrollbars/scrollbar-thin-overflow-change.html b/layout/reftests/css-scrollbars/scrollbar-thin-overflow-change.html
new file mode 100644
index 0000000000..a46d95d398
--- /dev/null
+++ b/layout/reftests/css-scrollbars/scrollbar-thin-overflow-change.html
@@ -0,0 +1,22 @@
+<!DOCTYPE html>
+<style>
+#outer {
+ scrollbar-width: thin;
+ overflow: auto;
+ border: 5px solid black;
+ background: black;
+ width: 200px;
+ height: 400px;
+}
+#inner {
+ height: 300px;
+}
+</style>
+<div id="outer">
+ <div id="inner"></div>
+</div>
+<script>
+// Force a reflow
+document.body.offsetHeight;
+document.getElementById('outer').style.height = '200px';
+</script>
diff --git a/layout/reftests/css-scrollbars/scrollbar-width-auto.html b/layout/reftests/css-scrollbars/scrollbar-width-auto.html
new file mode 100644
index 0000000000..9ea830144f
--- /dev/null
+++ b/layout/reftests/css-scrollbars/scrollbar-width-auto.html
@@ -0,0 +1,6 @@
+<!doctype html>
+<style>
+ :root {
+ overflow: scroll;
+ }
+</style>
diff --git a/layout/reftests/css-scrollbars/scrollbar-width-thin.html b/layout/reftests/css-scrollbars/scrollbar-width-thin.html
new file mode 100644
index 0000000000..79e9ed7a5f
--- /dev/null
+++ b/layout/reftests/css-scrollbars/scrollbar-width-thin.html
@@ -0,0 +1,7 @@
+<!doctype html>
+<style>
+ :root {
+ scrollbar-width: thin;
+ overflow: scroll;
+ }
+</style>
diff --git a/layout/reftests/css-scrollbars/viewport-scrollbar-color-change-ref.html b/layout/reftests/css-scrollbars/viewport-scrollbar-color-change-ref.html
new file mode 100644
index 0000000000..e9119fe7c6
--- /dev/null
+++ b/layout/reftests/css-scrollbars/viewport-scrollbar-color-change-ref.html
@@ -0,0 +1,9 @@
+<!DOCTYPE html>
+<html>
+<style>
+ html {
+ overflow: scroll;
+ scrollbar-color: green green;
+ }
+</style>
+<div style="width: 200vw; height: 200vh"></div>
diff --git a/layout/reftests/css-scrollbars/viewport-scrollbar-color-change.html b/layout/reftests/css-scrollbars/viewport-scrollbar-color-change.html
new file mode 100644
index 0000000000..f43e5afe50
--- /dev/null
+++ b/layout/reftests/css-scrollbars/viewport-scrollbar-color-change.html
@@ -0,0 +1,17 @@
+<!DOCTYPE html>
+<html class="reftest-wait">
+<style>
+ html {
+ overflow: scroll;
+ scrollbar-color: green green;
+ }
+ html.reftest-wait {
+ scrollbar-color: red red;
+ }
+</style>
+<div style="width: 200vw; height: 200vh"></div>
+<script>
+ window.addEventListener("MozAfterPaint", function() {
+ document.documentElement.classList.remove("reftest-wait");
+ });
+</script>