summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/css/css-anchor-position/anchor-scroll-fallback-position-002.html
diff options
context:
space:
mode:
Diffstat (limited to 'testing/web-platform/tests/css/css-anchor-position/anchor-scroll-fallback-position-002.html')
-rw-r--r--testing/web-platform/tests/css/css-anchor-position/anchor-scroll-fallback-position-002.html62
1 files changed, 0 insertions, 62 deletions
diff --git a/testing/web-platform/tests/css/css-anchor-position/anchor-scroll-fallback-position-002.html b/testing/web-platform/tests/css/css-anchor-position/anchor-scroll-fallback-position-002.html
deleted file mode 100644
index f30c35d390..0000000000
--- a/testing/web-platform/tests/css/css-anchor-position/anchor-scroll-fallback-position-002.html
+++ /dev/null
@@ -1,62 +0,0 @@
-<!DOCTYPE html>
-<html dir="rtl">
-<title>Tests position fallback with rtl scroller</title>
-<link rel="author" href="mailto:xiaochengh@chromium.org">
-<link rel="help" href="https://drafts.csswg.org/css-anchor-1/#scroll">
-<link rel="help" href="https://drafts.csswg.org/css-anchor-1/#fallback-apply">
-<script src="/resources/testharness.js"></script>
-<script src="/resources/testharnessreport.js"></script>
-<script src="support/test-common.js"></script>
-
-<style>
-body {
- margin: 0;
-}
-
-#anchor {
- anchor-name: --a;
- width: 100px;
- height: 100px;
- margin-right: 200px;
- background: orange;
-}
-
-#spacer {
- width: 1000vw;
- height: 1px;
-}
-
-#anchored {
- position: fixed;
- width: 100px;
- height: 100px;
- background: green;
- anchor-default: --a;
- top: anchor(--a top);
- position-fallback: --pf;
-}
-
-@position-fallback --pf {
- @try { left: anchor(--a right); }
- @try { right: anchor(--a left); }
-}
-</style>
-
-<div id="anchor"></div>
-<div id="spacer"></div>
-<div id="anchored"></div>
-
-<script>
-promise_test(async () => {
- await waitUntilNextAnimationFrame();
- assert_fallback_position(anchored, anchor, 'right');
-}, 'Should use the first fallback position at the initial scroll offset');
-
-promise_test(async () => {
- document.documentElement.scrollLeft = -101;
- await waitUntilNextAnimationFrame();
- assert_fallback_position(anchored, anchor, 'left');
-}, 'Should use the second fallback position after scrolling left');
-</script>
-
-</html>