Marquee
betaScrolls its children in a seamless, endless loop — horizontal or vertical, at a set speed, pausing on hover and focus.
- Display
- 1 file
- 1 npm package
- Accessibility notes
pnpm dlx @dowel-ui/cli add marqueenpm packages installed: class-variance-authority.
import { Marquee } from "@/components/ui/marquee";Default
Gallery
Vertical
Repeat
With Pause Control
Right To Left
<Marquee>
| Prop | Type | Default |
|---|---|---|
gapSpace between items, and between the last item and the first again. Numbers are px. | number | string | 16 |
orientation | "horizontal" | "vertical" | "horizontal" |
pausedPauses it outright — wire this to a visible pause control. | boolean | false |
pauseOnHoverPauses while the pointer is over the marquee or focus is inside it. | boolean | true |
repeatHow many times to repeat the content inside each half, for content shorter than the viewport. Repeats are hidden from assistive technology. | number | 1 |
reverseRuns toward the inline end (or downward) instead of toward the start (or upward). | boolean | false |
speedPixels per second. Converted to a duration from the measured length of the content. | number | 50 |
children | ReactNode | — |
Plus every attribute of <div>.
7/8
checks passed
- Tested — passes
- axe assertion — passes
- Keyboard tested — fails
- Storybook examples — passes
- Accessibility documented — passes
- Semantic tokens only — passes
- Motion from tokens — does not apply
- className merged — passes
- Visible focus — does not apply
- No fixed widths — passes