diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/parsing/scroll-start-target-computed.html b/testing/web-platform/tests/css/css-scroll-snap-2/parsing/scroll-start-target-computed.html index 1ebb5e786541d..50dbcff2397dd 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/parsing/scroll-start-target-computed.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/parsing/scroll-start-target-computed.html @@ -3,8 +3,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target-* computed values - + CSS Scroll Snap 2 Test: scroll-initial-target-* computed values + @@ -13,8 +13,8 @@
diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/parsing/scroll-start-target-invalid.html b/testing/web-platform/tests/css/css-scroll-snap-2/parsing/scroll-start-target-invalid.html index f2a60836d1d92..dfcaaabdeeddc 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/parsing/scroll-start-target-invalid.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/parsing/scroll-start-target-invalid.html @@ -2,19 +2,19 @@ - CSS Scroll Snap 2 Test: scroll-start-target-* with invalid values - + CSS Scroll Snap 2 Test: scroll-initial-target-* with invalid values + diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/parsing/scroll-start-target-valid.html b/testing/web-platform/tests/css/css-scroll-snap-2/parsing/scroll-start-target-valid.html index 9ff7055a81cc9..3397f19e50c9e 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/parsing/scroll-start-target-valid.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/parsing/scroll-start-target-valid.html @@ -3,8 +3,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target-* with valid values - + CSS Scroll Snap 2 Test: scroll-initial-target-* with valid values + @@ -12,8 +12,8 @@ diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-aligns-with-snap-align.tentative.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-aligns-with-snap-align.tentative.html index 3203e1e1a6159..8dc76a657d7a1 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-aligns-with-snap-align.tentative.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-aligns-with-snap-align.tentative.html @@ -2,8 +2,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target* - + CSS Scroll Snap 2 Test: scroll-initial-target* + @@ -26,7 +26,7 @@ width: 100px; height: 100px; background-color: pink; - scroll-start-target: auto; + scroll-initial-target: nearest; position: absolute; top: 400px; left: 400px; @@ -68,7 +68,7 @@ "scroller is vertically aligned to target's top"); assert_equals(scroller.scrollLeft, 400, "scroller is horizontally aligned to target's left"); - }, "scroll-start-target aligns with scroll-snap-align"); + }, "scroll-initial-target aligns with scroll-snap-align"); diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-display-toggled.tentative.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-display-toggled.tentative.html index a0224a568e565..2f58e2393c75d 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-display-toggled.tentative.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-display-toggled.tentative.html @@ -2,8 +2,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target* - + CSS Scroll Snap 2 Test: scroll-initial-target* + @@ -33,7 +33,7 @@ width: 100px; height: 100px; background-color: pink; - scroll-start-target: auto; + scroll-initial-target: nearest; }
@@ -89,7 +89,7 @@ let initial_expected_scroll_top = total_content_height - inner_scroller.clientHeight; assert_equals(inner_scroller.scrollTop, initial_expected_scroll_top, - "inner-scroller is scrolled to scroll-start-target"); + "inner-scroller is scrolled to scroll-initial-target"); let display_promise = waitForDisplay(target, "none"); target.style.display = "none"; @@ -98,14 +98,14 @@ let final_expected_scroll_top = initial_expected_scroll_top - target_height; assert_equals(inner_scroller.scrollTop, final_expected_scroll_top, "inner scroller is clamped to updated scroll range"); - }, "display:block scroll-start-target becomes display: none"); + }, "display:block scroll-initial-target becomes display: none"); promise_test(async (t) => { await resetDisplay(); let initial_expected_scroll_top = total_content_height - inner_scroller.clientHeight; assert_equals(inner_scroller.scrollTop, initial_expected_scroll_top, - "inner-scroller is scrolled to scroll-start-target"); + "inner-scroller is scrolled to scroll-initial-target"); let display_promise = waitForDisplay(target, "none"); target.style.display = "none"; @@ -118,8 +118,8 @@ target.style.display = "block"; await display_promise; assert_equals(inner_scroller.scrollTop, initial_expected_scroll_top, - "inner scroller is updated as scroll-start-target reappears"); - }, "display:none scroll-start-target becomes display: block"); + "inner scroller is updated as scroll-initial-target reappears"); + }, "display:none scroll-initial-target becomes display: block"); diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-nested-container.tentative.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-nested-container.tentative.html index e3a1df6e6a1b6..cd2717ed88cc9 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-nested-container.tentative.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-nested-container.tentative.html @@ -2,8 +2,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target* - + CSS Scroll Snap 2 Test: scroll-initial-target* + @@ -49,7 +49,7 @@ width: 100px; height: 100px; background-color: pink; - scroll-start-target: auto; + scroll-initial-target: nearest; }
@@ -96,7 +96,7 @@ promise_test(async (t) => { await resetDisplay(); assert_equals(outer_container.scrollTop, outer_to_target_scrolltop, - "outer-container is scrolled to scroll-start-target"); + "outer-container is scrolled to scroll-initial-target"); // Remove large_space_outer so we can observe outer-container adjust to // its new content height. @@ -113,14 +113,14 @@ await waitForAnimationFrames(2); assert_equals(outer_container.scrollTop, outer_to_target_scrolltop, - "outer-scroller is updated as scroll-start-target reappears"); - }, "display:none scroll-start-target becomes display:block"); + "outer-scroller is updated as scroll-initial-target reappears"); + }, "display:none scroll-initial-target becomes display:block"); promise_test(async (t) => { await waitForCompositorCommit(); await resetDisplay(); assert_equals(outer_container.scrollTop, outer_to_target_scrolltop, - "outer-container is scrolled to scroll-start-target"); + "outer-container is scrolled to scroll-initial-target"); // Remove large_space_outer so we can observe outer-container adjust to // its new content height. @@ -129,7 +129,7 @@ await waitForAnimationFrames(2); // inner-container has become a scroller and should be scrolled to - // scroll-start-target. + // scroll-initial-target. assert_equals(inner_container.scrollTop, inner_to_target_scrolltop, "inner-container is fully scrolled to target"); @@ -152,21 +152,21 @@ promise_test(async (t) => { // This test verifies that: - // 1. when both the child and grandchild are scroll-start-targets, the + // 1. when both the child and grandchild are scroll-initial-targets, the // first-in-tree-order (i.e. the child) wins/is scrolled to. - // 2. if/when the grandchild stops being a scroll-start-target, the + // 2. if/when the grandchild stops being a scroll-initial-target, the // child (inner container) is scrolled to. await waitForCompositorCommit(); await resetDisplay(); t.add_cleanup(async () => { - inner_container.style.scrollStartTarget = "none"; + inner_container.style.scrollInitialTarget = "none"; await waitForAnimationFrames(2); }); assert_equals(outer_container.scrollTop, outer_to_target_scrolltop, - "outer-container is scrolled to scroll-start-target"); - // Make the inner container a scroll-start-target. - inner_container.style.scrollStartTarget = "auto"; + "outer-container is scrolled to scroll-initial-target"); + // Make the inner container a scroll-initial-target. + inner_container.style.scrollInitialTarget = "nearest"; await waitForAnimationFrames(2); // The inner container has overflow: visible, so it's not the scroll @@ -174,33 +174,33 @@ assert_equals(outer_container.scrollTop, outer_to_inner_scrolltop, "outer-container is scrolled to inner-container (which is before the" + - "inner scroll-start-target in tree order)"); - }, "outer scroll-start-target takes precedence over inner"); + "inner scroll-initial-target in tree order)"); + }, "outer scroll-initial-target takes precedence over inner"); promise_test(async (t) => { // This test verifies that a child which is a scroller, is a - // scroll-start-target, and has a scroll-start-target is scrolled to by - // its scrolling container, and also scrolls to its own - // scroll-start-target. + // scroll-initial-target, and has a scroll-initial-target is scrolled to + // by its scrolling container, and also scrolls to its own + // scroll-initial-target. await waitForCompositorCommit(); await resetDisplay(); t.add_cleanup(async () => { inner_container.style.overflow = "visible"; - inner_container.style.scrollStartTarget = "none"; + inner_container.style.scrollInitialTarget = "none"; await waitForAnimationFrames(2); }); assert_equals(outer_container.scrollTop, outer_to_target_scrolltop, - "outer-container is scrolled to scroll-start-target"); + "outer-container is scrolled to scroll-initial-target"); - // Make the inner container a scroll-start-target. - inner_container.style.scrollStartTarget = "auto"; + // Make the inner container a scroll-initial-target. + inner_container.style.scrollInitialTarget = "nearest"; await waitForAnimationFrames(2); assert_equals(outer_container.scrollTop, outer_to_inner_scrolltop, "outer-container is still scrolled to inner scroll-container" + - "as it is a scroll-start-target and comes before #target in " + + "as it is a scroll-initial-target and comes before #target in " + "tree-order"); // Make the inner container a scroller. @@ -213,7 +213,7 @@ assert_equals(inner_container.scrollTop, inner_to_target_scrolltop, "inner-container is scrolled to target"); - }, "scroll containers can also be scroll-start-targets"); + }, "scroll containers can also be scroll-initial-targets"); diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-root.tentative.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-root.tentative.html index 860a592bb106a..5cb9e7447333e 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-root.tentative.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-root.tentative.html @@ -3,8 +3,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target* - + CSS Scroll Snap 2 Test: scroll-initial-target* + @@ -32,7 +32,7 @@ top: 60vh; left: 60vw; background-color: purple; - scroll-start-target: auto; + scroll-initial-target: nearest; } .bottom_right { @@ -54,9 +54,9 @@ const expected_scroll_left = top_left_box.getBoundingClientRect().width; assert_approx_equals(scroller.scrollTop, expected_scroll_top, 1, - "scroll-start-target sets initial vertical scroll position"); + "scroll-initial-target sets initial vertical scroll position"); assert_approx_equals(scroller.scrollLeft, expected_scroll_left, 1, - "scroll-start-target sets initial horizontal scroll position"); + "scroll-initial-target sets initial horizontal scroll position"); }); diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-rtl.tentative.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-rtl.tentative.html index e7766cc07a2c8..7cb0f93c49582 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-rtl.tentative.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-rtl.tentative.html @@ -3,8 +3,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target* - + CSS Scroll Snap 2 Test: scroll-initial-target* + @@ -34,7 +34,7 @@ .center { top: 60%; background-color: purple; - scroll-start-target: auto; + scroll-initial-target: nearest; } .bottom_left { @@ -53,10 +53,10 @@ test((t) => { assert_equals(scroller.scrollTop, initial_expected_scroll_top, - "scroller is vertically scrolled to scroll-start-target"); + "scroller is vertically scrolled to scroll-initial-target"); assert_equals(scroller.scrollLeft, initial_expected_scroll_left, - "scroller is horizontally scrolled to scroll-start-target"); - }, "scroll-start-target reflects vertical rtl writing mode."); + "scroller is horizontally scrolled to scroll-initial-target"); + }, "scroll-initial-target reflects vertical rtl writing mode."); diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-span.tentative.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-span.tentative.html index 0985dcc2ee91f..e7fe0479089ce 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-span.tentative.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-span.tentative.html @@ -2,8 +2,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target with a <span> element - + CSS Scroll Snap 2 Test: scroll-initial-target with a <span> element + @@ -24,7 +24,7 @@ background-color: turquoise; } .target { - scroll-start-target: auto; + scroll-initial-target: nearest; } .scroller { overflow: scroll; @@ -46,8 +46,8 @@ const target = document.getElementById("target"); assert_equals(scroller.scrollTop, target.offsetTop, - "scroller is initially scrolled to it scroll-start-target"); - }, " scroll-start-target is honored"); + "scroller is initially scrolled to it scroll-initial-target"); + }, " scroll-initial-target is honored"); diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-anchor-navigation-inner-frame.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-anchor-navigation-inner-frame.html index de02dcf00f68e..c363961add7aa 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-anchor-navigation-inner-frame.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-anchor-navigation-inner-frame.html @@ -23,7 +23,7 @@ #middle_box { width: 100px; height: 60vh; - scroll-start-target: auto; + scroll-initial-target: nearest; background-color: purple; } #bottom_box { diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-anchor-navigation.tentative.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-anchor-navigation.tentative.html index bc5b75f75f1c3..bb3380e3ab651 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-anchor-navigation.tentative.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-anchor-navigation.tentative.html @@ -3,8 +3,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target interaction with anchor navigation - + CSS Scroll Snap 2 Test: scroll-initial-target interaction with anchor navigation + @@ -29,12 +29,12 @@ // Expect scroll offset of 100px per scroll-start. const scroll_start_target_top = 0.6 * frame.contentWindow.innerHeight; assert_equals(scroller.scrollTop, scroll_start_target_top, - "scroll-start-target sets initial scroll offset"); + "scroll-initial-target sets initial scroll offset"); // Scroll away from start position. scroller.scrollTop = 200; assert_equals(scroller.scrollTop, 200, - "scrolled away from scroll-start-target"); + "scrolled away from scroll-initial-target"); anchor_target_link.click(); await waitForHashchange(frame.contentWindow); @@ -52,8 +52,8 @@ assert_equals(scroller.scrollTop, 200, "scroller returns to previous scroll position, not " + - "scroll-start-target"); - }, "scroll-start-target does not override anchor navigation."); + "scroll-initial-target"); + }, "scroll-initial-target does not override anchor navigation."); } diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-hash-fragment-navigation-inner-frame.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-hash-fragment-navigation-inner-frame.html index 90629c4990f67..1c81212e216a8 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-hash-fragment-navigation-inner-frame.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-hash-fragment-navigation-inner-frame.html @@ -23,7 +23,7 @@ #middle_box { width: 100px; height: 60vh; - scroll-start-target: auto; + scroll-initial-target: nearest; background-color: purple; } #bottom_box { diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-hash-fragment-navigation.tentative.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-hash-fragment-navigation.tentative.html index 2d291c2ef9ff9..6eb1737b39f55 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-hash-fragment-navigation.tentative.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-hash-fragment-navigation.tentative.html @@ -3,8 +3,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target interaction with fragment-navigation - + CSS Scroll Snap 2 Test: scroll-initial-target interaction with fragment-navigation + @@ -18,9 +18,9 @@ let scroller = frame.contentDocument.scrollingElement; // fragment_target is at the bottom of the frame so the frame should be // fully scrolled down to bring it into view (despite middle_box being - // the scroll-start-target). + // the scroll-initial-target). let expected_scroll_top = scroller.scrollHeight - scroller.clientHeight; - // The scroll-start-target is just below top_box which has a height of + // The scroll-initial-target is just below top_box which has a height of // 60vh. const scroll_start_target_top = 0.6 * frame.contentWindow.innerHeight; @@ -28,7 +28,7 @@ assert_not_equals(scroll_start_target_top, expected_scroll_top); assert_equals(frame.contentDocument.scrollingElement.scrollTop, expected_scroll_top); - }, "scroll-start-target does not override hash fragment navigation"); + }, "scroll-initial-target does not override hash fragment navigation"); } \ No newline at end of file diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-scroll-snap.tentative.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-scroll-snap.tentative.html index 28bea40d7a044..dfdb8b0277249 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-scroll-snap.tentative.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-scroll-snap.tentative.html @@ -3,8 +3,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target* - + CSS Scroll Snap 2 Test: scroll-initial-target* + @@ -42,7 +42,7 @@ top: 200px; left: 200px; background-color: purple; - scroll-start-target: auto; + scroll-initial-target: nearest; } .bottom_right { @@ -71,9 +71,9 @@ centerbox.getBoundingClientRect().width; assert_approx_equals(scroller.scrollTop, expected_scroll_top, 1, - "scroll-start-target sets initial vertical scroll position"); + "scroll-initial-target sets initial vertical scroll position"); assert_approx_equals(scroller.scrollLeft, expected_scroll_left, 1, - "scroll-start-target sets initial horizontal scroll position"); + "scroll-initial-target sets initial horizontal scroll position"); }); \ No newline at end of file diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-scroll-start-root.tentative.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-scroll-start-root.tentative.html index daf664aa7fbdf..2405334540faa 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-scroll-start-root.tentative.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-scroll-start-root.tentative.html @@ -3,8 +3,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target* - + CSS Scroll Snap 2 Test: scroll-initial-target* + @@ -36,7 +36,7 @@ top: 60vh; left: 60vw; background-color: purple; - scroll-start-target: auto; + scroll-initial-target: nearest; } .bottom_right { @@ -58,9 +58,9 @@ const expected_scroll_left = top_left_box.getBoundingClientRect().width; assert_approx_equals(scroller.scrollTop, expected_scroll_top, 1, - "scroll-start-target sets initial vertical scroll position"); + "scroll-initial-target sets initial vertical scroll position"); assert_approx_equals(scroller.scrollLeft, expected_scroll_left, 1, - "scroll-start-target sets initial horizontal scroll position"); + "scroll-initial-target sets initial horizontal scroll position"); }); \ No newline at end of file diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-scroll-start.tentative.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-scroll-start.tentative.html index a08daad76db6d..9c0f58ddbfbfb 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-scroll-start.tentative.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-scroll-start.tentative.html @@ -3,8 +3,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target* - + CSS Scroll Snap 2 Test: scroll-initial-target* + @@ -24,7 +24,7 @@ margin: 0px; position: absolute; scroll-start: end end; - /* This should be overriden by scroll-start-target. */ + /* This should be overriden by scroll-initial-target. */ } .box { @@ -43,7 +43,7 @@ top: 200px; left: 200px; background-color: purple; - scroll-start-target: auto; + scroll-initial-target: nearest; } .bottom_right { @@ -67,9 +67,9 @@ const expected_scroll_left = top_left_box.getBoundingClientRect().width; assert_approx_equals(scroller.scrollTop, expected_scroll_top, 1, - "scroll-start-target sets initial vertical scroll position"); + "scroll-initial-target sets initial vertical scroll position"); assert_approx_equals(scroller.scrollLeft, expected_scroll_left, 1, - "scroll-start-target sets initial horizontal scroll position"); + "scroll-initial-target sets initial horizontal scroll position"); }); \ No newline at end of file diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-text-fragment-navigation-target.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-text-fragment-navigation-target.html index 80cbb55fb2730..bbedb01132803 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-text-fragment-navigation-target.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-text-fragment-navigation-target.html @@ -20,7 +20,7 @@ #middle_box { width: 100px; height: 60vh; - scroll-start-target: auto; + scroll-initial-target: nearest; background-color: purple; } #bottom_box { diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-text-fragment-navigation.tentative.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-text-fragment-navigation.tentative.html index f83ea1a036aee..dc8c332270c84 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-text-fragment-navigation.tentative.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-text-fragment-navigation.tentative.html @@ -3,8 +3,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target interaction with text-fragment navigation - + CSS Scroll Snap 2 Test: scroll-initial-target interaction with text-fragment navigation + diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-user-programmatic-scroll.tentative.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-user-programmatic-scroll.tentative.html index 6bcf103253d6c..20d6763034f6d 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-user-programmatic-scroll.tentative.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target-with-user-programmatic-scroll.tentative.html @@ -3,8 +3,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target* - + CSS Scroll Snap 2 Test: scroll-initial-target* + @@ -45,7 +45,7 @@ top: 200px; left: 200px; background-color: purple; - scroll-start-target: auto; + scroll-initial-target: nearest; } .bottom_right { @@ -78,7 +78,7 @@ scroller.scrollTo(target_offset.x, target_offset.y); } - async function test_scroll_start_target(test, scroller, msg, scrolling_function) { + async function test_scroll_initial_target(test, scroller, msg, scrolling_function) { await waitForCompositorCommit(); let top_left_box = document.getElementById("user_top_left_box"); @@ -86,9 +86,9 @@ let expected_scroll_left = top_left_box.getBoundingClientRect().width; assert_approx_equals(scroller.scrollTop, expected_scroll_top, 1, - "scroll-start-target sets initial vertical scroll position"); + "scroll-initial-target sets initial vertical scroll position"); assert_approx_equals(scroller.scrollLeft, expected_scroll_left, 1, - "scroll-start-target sets initial horizontal scroll position"); + "scroll-initial-target sets initial horizontal scroll position"); let scrollend_promise = new Promise((resolve) => { scroller.addEventListener("scrollend", resolve); @@ -112,14 +112,15 @@ promise_test(async (t) => { let scroller = document.getElementById("user_scroller"); - const msg = "user scroll is not overriden in by scroll-start-target"; - await test_scroll_start_target(t, scroller, msg, user_scroll); - }, "scroll-start-target does not override user scroll"); + const msg = "user scroll is not overriden in by scroll-initial-target"; + await test_scroll_initial_target(t, scroller, msg, user_scroll); + }, "scroll-initial-target does not override user scroll"); promise_test(async (t) => { let scroller = document.getElementById("programmatic_scroller"); - const msg = "programmatic scroll is not overriden in by scroll-start-target"; - await test_scroll_start_target(t, scroller, msg, programmatic_scroll); - }, "scroll-start-target does not override programmatic scroll"); + const msg = + "programmatic scroll is not overriden in by scroll-initial-target"; + await test_scroll_initial_target(t, scroller, msg, programmatic_scroll); + }, "scroll-initial-target does not override programmatic scroll"); \ No newline at end of file diff --git a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target.tentative.html b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target.tentative.html index 1fcb3cbbe40ae..13e9e20e3e2ba 100644 --- a/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target.tentative.html +++ b/testing/web-platform/tests/css/css-scroll-snap-2/scroll-start-target/scroll-start-target.tentative.html @@ -3,8 +3,8 @@ - CSS Scroll Snap 2 Test: scroll-start-target* - + CSS Scroll Snap 2 Test: scroll-initial-target* + @@ -38,7 +38,7 @@ } .target { - scroll-start-target: auto; + scroll-initial-target: nearest; } .center { @@ -68,9 +68,9 @@ const expected_scroll_left = top_left_box.getBoundingClientRect().width; assert_approx_equals(scroller.scrollTop, expected_scroll_top, 1, - "scroll-start-target sets initial vertical scroll position"); + "scroll-initial-target sets initial vertical scroll position"); assert_approx_equals(scroller.scrollLeft, expected_scroll_left, 1, - "scroll-start-target sets initial horizontal scroll position"); + "scroll-initial-target sets initial horizontal scroll position"); }); \ No newline at end of file