Marquee

An infinitely scrolling strip for logos and highlights — CSS-driven, pausable, gradient-masked.

React
TypeScript
Vitest
Vite
Next.js
CVA
pnpm

Import#

import { Marquee } from "astralis-ui";
// Marquee.Item

Usage#

Children are duplicated once (the clone is aria-hidden) for a seamless loop; the animation is pure CSS keyframes, so it costs nothing at runtime. gradient masks the edges into the background.

Opposing rows#

Semantic tokens
Runtime theming
Dark mode
Responsive props
Compound components
Accent channel
Zero build step
Typed styles

Props#

PropTypeDefaultDescription
direction"left" | "right" | "up" | "down""left"Scroll axis and direction.
speednumber50Pixels per second.
gapCSS length"1rem"Space between items (and the loop seam).
pauseOnHover / pauseOnFocusbooleanfalsePause for pointer or keyboard users.
reversebooleanfalseFlip the direction.
gradient / gradientColor / gradientWidthboolean / color / lengthfalse / surface / "10%"Edge fade mask.
loopCountnumber0Loops before stopping (0 = infinite).

Accessibility#

The duplicated track is aria-hidden, and pauseOnFocus lets keyboard users freeze the motion — turn it on when items are interactive.