Skip to content
↑↓ to navigate↵ to openesc to close

Menu

Scroll Animation

Scroll Reveal

ScrollReveal.vue
Scroll ↓
Spring slide
Blur in
Staggered by delay
Reveal once
End

Install

Run it in a project set up with shadcn-vue. The source is copied to components/beui and its dependencies are added to your package.json. Read the shadcn-vue guide

bunx --bun shadcn-vue@latest add @beui-vue/scroll-reveal

Import the shared styles once in your application.

TSUsage
import ScrollReveal from '@/components/beui/effects/ScrollReveal.vue'
import '@/components/beui/styles.css'

API Reference

y?
number

Slide distance in px before reveal.

Default16
blur?
number

Enter blur in px (kept ≤ 10 per motion conventions).

Default8
duration?
number

Reveal duration in seconds.

Default.6
delay?
number
Default0
once?
boolean

Reveal only once (default) or every time it enters view.

Defaulttrue
amount?
"some" | "all" | number

Portion of the element that must be visible to trigger.

Default.3
root?
Element | null

Scroll root element for contained scroll areas. Defaults to the viewport.

Default—
class?
string
Default—
#default?
slot
Default—

Updated