summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/scroll-animations/css/view-timeline-attachment-computed-tentative.html
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 19:33:14 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 19:33:14 +0000
commit36d22d82aa202bb199967e9512281e9a53db42c9 (patch)
tree105e8c98ddea1c1e4784a60a5a6410fa416be2de /testing/web-platform/tests/scroll-animations/css/view-timeline-attachment-computed-tentative.html
parentInitial commit. (diff)
downloadfirefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.tar.xz
firefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.zip
Adding upstream version 115.7.0esr.upstream/115.7.0esr
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'testing/web-platform/tests/scroll-animations/css/view-timeline-attachment-computed-tentative.html')
-rw-r--r--testing/web-platform/tests/scroll-animations/css/view-timeline-attachment-computed-tentative.html35
1 files changed, 35 insertions, 0 deletions
diff --git a/testing/web-platform/tests/scroll-animations/css/view-timeline-attachment-computed-tentative.html b/testing/web-platform/tests/scroll-animations/css/view-timeline-attachment-computed-tentative.html
new file mode 100644
index 0000000000..dd244e137b
--- /dev/null
+++ b/testing/web-platform/tests/scroll-animations/css/view-timeline-attachment-computed-tentative.html
@@ -0,0 +1,35 @@
+<!DOCTYPE html>
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<script src="/css/support/computed-testcommon.js"></script>
+<style>
+ #outer { view-timeline-attachment: defer; }
+ #target { view-timeline-attachment: ancestor; }
+</style>
+<div id="outer">
+ <div id="target"></div>
+</div>
+<script>
+test_computed_value('view-timeline-attachment', 'initial', 'local');
+test_computed_value('view-timeline-attachment', 'inherit', 'defer');
+test_computed_value('view-timeline-attachment', 'unset', 'local');
+test_computed_value('view-timeline-attachment', 'revert', 'local');
+test_computed_value('view-timeline-attachment', 'local');
+test_computed_value('view-timeline-attachment', 'defer');
+test_computed_value('view-timeline-attachment', 'ancestor');
+test_computed_value('view-timeline-attachment', 'local, defer');
+test_computed_value('view-timeline-attachment', 'defer, ancestor');
+test_computed_value('view-timeline-attachment', 'local, defer, ancestor');
+test_computed_value('view-timeline-attachment', 'local, local, local, local');
+
+test(() => {
+ let style = getComputedStyle(document.getElementById('target'));
+ assert_not_equals(Array.from(style).indexOf('view-timeline-attachment'), -1);
+}, 'The view-timeline-attachment property shows up in CSSStyleDeclaration enumeration');
+
+test(() => {
+ let style = document.getElementById('target').style;
+ assert_not_equals(style.cssText.indexOf('view-timeline-attachment'), -1);
+}, 'The view-timeline-attachment property shows up in CSSStyleDeclaration.cssText');
+
+</script>