★ GitHub

ScrollBlur

Animate elements from blurred to sharp as they enter the viewport.

Usage

Wrap any component in ScrollBlur to trigger a beautiful un-blur animation along with a slight slide up.

I was blurry!

I was blurry later!

tsx
import { ScrollBlur, Card } from "starkit-ui"; <ScrollBlur delay={200}> <Card>Unblurred Content</Card> </ScrollBlur>

Props

PropTypeDefaultDescription
delaynumber0Delay in ms before the un-blur starts.
thresholdnumber0.1How much of the element needs to be visible to trigger.
repeatbooleanfalseAnimate out when scrolled past, to animate in again.