Skip to content

Commit 841eea7

Browse files
committed
[css-position-3] Revert stickypos targeting back to using its offsetted position. #7930
1 parent 7e7ead7 commit 841eea7

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

css-position-3/Overview.bs

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -685,15 +685,17 @@ Scroll Position of Sticky-Positioned Boxes
685685

686686
For the purposes of any operation targeting the scroll position
687687
of a sticky positioned element (or one of its descendants),
688-
the sticky positioned element must be considered to be positioned
689-
at its initial (non-offsetted) position.
688+
the sticky positioned element must be considered to be
689+
at its offsetted position.
690690

691691
692692
For example, if a user clicks a link targeting a [=sticky-positioned=] element,
693-
even if the element's [=nearest scrollport=] is currently scrolled
693+
if the element's [=nearest scrollport=] is currently scrolled
694694
such that the [=sticky positioned=] element is offset from its initial position,
695-
the [=scrollport=] will be scrolled back
696-
so that the element's initial position is visible.
695+
the [=scroll container=] will be scrolled back
696+
only the minimum necessary to bring it into its desired position in the [=scrollport=]
697+
(rather than scrolling all the way back
698+
to target its original, non-offsetted position).
697699
698700

699701

0 commit comments

Comments
 (0)