Skip to content

Commit 7e886a3

Browse files
committed
[css-scroll-snap] Step-by-step de-duping of re-snapping requirements. Step 3: Split off conditional so we don't have to repeat that either.
1 parent 7e93d06 commit 7e886a3

File tree

1 file changed

+3
-8
lines changed

1 file changed

+3
-8
lines changed

css-scroll-snap/Overview.bs

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -338,19 +338,14 @@ Scroll Snapping Rules: the 'scroll-snap-type' property {#scroll-snap-type}
338338
If the content changes
339339
such that the scroll container would no longer be <a>snapped</a>
340340
(e.g. content is added, moved, deleted, resized)
341-
to the same snap position it was snapped to before the content change
341+
the UA must re-evaluate the resulting <a>scroll position</a>,
342+
and re-snap if required.
343+
If the <a>scroll container</a> was <a>snapped</a> before the content change
342344
and that same snap position still exists
343345
(e.g. its associated element was not deleted) and is reachable,
344346
the scroll container must be re-snapped to that same snap position
345347
after the content change.
346348

347-
<!-- proximity -->
348-
If the content changes
349-
such that the scroll container would no longer be <a>snapped</a>
350-
(e.g. content is added, moved, deleted, resized)
351-
to the same snap position it was snapped to before the content change,
352-
the scroll container must be re-snapped.
353-
354349
<!--
355350
████████ ███ ████████ ████████ ████ ██ ██ ██████
356351
██ ██ ██ ██ ██ ██ ██ ██ ██ ███ ██ ██ ██

0 commit comments

Comments
 (0)