UI図鑑
Scrolling Behaviors · 06 · アクション

Snap Scrolling

スナップ(要素に吸着するスクロール)

snap_scrolling デモ
Snap Scrolling のデモ

ほかの呼び名

Paging ScrollSnap to ItemScroll SnappingMagnetic Scroll
Material 3
Carousel(snap)
Material 2
該当なし(M2 に無い)
Android (Compose)
LazyRow + rememberSnapFlingBehavior / HorizontalPager
iOS (HIG)
Scroll views(paging)
SwiftUI
.scrollTargetBehavior(.viewAligned / .paging)
Web
CSS scroll-snap-type
Flutter
PageView(viewportFraction:) / SnapScrollPhysics(自作)

概要

自由なスクロールではなく、要素の境界で必ず止まる。カルーセル、時間選択、カード送りで使う。PageView は 1 画面ずつ、ListWheelScrollView は行ごとに吸着。

使いどころ

カルーセル、横並びカード、ドラム式ピッカー、ストーリー UI。

関連

シーン