CKTIS / CSS
scroll-snap-stop — stopping at snap positions
The scroll-snap-stop property controls whether relative scrolling may pass over an element’s snap position.
Version: CSS modules; structured CSSWG indexes reconciled with pinned MDN BCD; Chromium 152 scope gate, per-example verification still required
Syntax
scroll-snap-stop: normal | always;Set scroll-snap-stop on elements with snap positions, usually established by scroll-snap-align. The container needs snapping enabled through scroll-snap-type. The initial normal permits passing over a position; always prohibits passing over it and forces a stop at the first encountered snap position of that element.
The property is not inherited. It neither enables snapping nor replaces mandatory. It affects relative scrolling, such as a momentum gesture, but not absolute scrolling, such as scrollTo() or anchor navigation. Scrolling physics depend on the browser.
Examples
<!doctype html>
<html lang="en">
<meta charset="utf-8">
<title>scroll-snap-stop</title>
<style>
.scroller {
display: flex;
width: 240px;
overflow-x: auto;
scroll-snap-type: x mandatory;
}
.panel {
flex: 0 0 240px;
height: 120px;
display: grid;
place-items: center;
scroll-snap-align: start;
scroll-snap-stop: always;
background: #ddeeff;
}
.panel:nth-child(even) { background: #ffe4bb; }
</style>
<div class="scroller" tabindex="0" role="region" aria-label="Numbered panels">
<div class="panel">1</div>
<div class="panel">2</div>
<div class="panel">3</div>
</div>
</html>Result
Initially, panel 1 is visible. A relative scroll toward panel 3 must stop at panel 2 if it would otherwise pass over that snap position. No console output.
The displayed code and declared result were verified in an isolated environment using the method recorded in the verification evidence for this exact version.