A trip album that pages with depth, captions on color blocks, and a pinch to peek at the centred photo.
A paged gallery where off-center pages recede in scale, blur and tone with parallax, rubber-banded ends, a continuously tracking scrubbable dot strip and pinch peek-zoom on the centered page.
$199 once, every piece included. See how installing works · Sign in
SwiftUI source you own, built on Apple frameworks only.
How it behaves, what it handles, and the decisions behind it.
A horizontal, view-aligned pager with generous margins so the neighbours peek in. The centered page sits at full size with a deep shadow; pages either side scale down, blur and darken by how far off-center they are, and shift slightly against the scroll for a parallax feel, all from scrollTransition. The ends rubber-band with scrollBounceBehavior(.always). A dot strip below tracks progress continuously as the scroll moves and can be scrubbed to jump pages. Pinch the centered page to peek-zoom with a soft limit; it springs back on release.
scrollPosition(id:) binding, so the centered page is always addressable and the strip can move it programmatically.onScrollGeometryChange on iOS 18; on iOS 17 the indicator still snaps to the selected page, it just does not track mid-scroll.VisualEffect function called from the scrollTransition closure, which keeps the closure nonisolated and cheap..selection.pageWidth (fraction of the gallery width, default 0.78) and spacing (default 16) size the pages; the album uses 0.82 and 14 so the pages fill the screen with the neighbours just peeking.safeAreaInset, so the pager can scroll under it at large text sizes.DepthGalleryExample at the end of DepthGallery.swift is the Gallery screen from the preview; copy it as a starting point.Pieces that work well next to this one.