cnippet/ui
  1. motion
  2. scroll animations
  3. scroll velocity text

scroll animations

Scroll Velocity Text

A continuous text marquee whose speed reacts to scroll velocity — the faster you scroll, the faster the marquee moves.

Installation

Usage

Anatomy

Good to know

  • Each row scrolls on its own at baseVelocity and speeds up while the page is scrolled. Set scrollReactivity={false} to ignore scrolling.
  • Use direction={-1} on alternate rows to scroll them the other way.
  • The row repeats its children as often as needed to fill the width.
  • It pauses while it's off screen or the browser tab is in the background.
  • When the user has turned on reduced motion, it keeps moving at baseVelocity but no longer speeds up with scrolling. To stop it completely, check useReducedMotion() from motion/react and render static content.

Props

ScrollVelocityContainer

ScrollVelocityRow

Examples

Word Marquee

A continuous horizontal scroll of tech-stack words that speeds up as you scroll the page.

Opposing Rows

Two rows scroll in opposite directions. Useful for decorative hero sections.

Pill Marquee

Badge-style items scroll at a constant speed with scrollReactivity disabled.

Logo Row

A customer logo strip that drifts slowly and speeds up as you scroll. Each logo is an icon plus a name, so swap in your own SVGs.