Skip to content

Marquee ​

A CSS-driven ticker for short, repeated announcements. It preserves the former Carousel marquee layout: a rounded canvas viewport with full-height scrolling cards. Direct child elements scroll continuously and are duplicated internally to create a seamless loop.

Use it for supplementary status or promotional content, not information users must read carefully. The duplicate items are hidden from assistive technology and inert; put interactive content only in the original children.

Basic Usage ​

Full width

Direction and Pause ​

The ticker moves left by default. Set direction="right" for the reverse motion. The persistent Pause marquee control can stop and resume the ticker. Hover and keyboard focus also pause automatically by default; pause-on-hover="false" disables only those automatic pauses, not the persistent control. Set a height on the marquee and a width on each child card so the loop is predictable.

The pause control remains available when show-controls="false" hides the previous/next buttons.

Full width

API Reference ​

Attributes / Properties ​

NameTypeDefaultDescription
colorThemeColorN/ATheme color for navigation controls
durationnumber20Seconds for one complete ticker cycle
direction'left' | 'right''left'Horizontal scroll direction
pause-on-hoverbooleantrueAutomatically pauses while hovered or keyboard-focused
show-controlsbooleantrueShows previous and next controls

CSS Custom Properties ​

PropertyDefaultDescription
--marquee-gapvar(--size-4)Gap between ticker items

CSS Parts ​

PartDescription
trackThe animated ticker track
controlsPrevious/next controls and the persistent pause toggle
pause-toggleThe persistent pause/resume button

Accessibility ​

The animation stops automatically for prefers-reduced-motion: reduce, and for data-motion="reduced" regardless of the OS setting; data-motion="full" keeps it scrolling despite the OS preference (see Motion Mode). A persistent Pause/Resume button is available when the marquee has content; hover and keyboard focus also pause automatically by default. Set pause-on-hover="false" to disable only the automatic pauses. Because a ticker repeats continuously, do not use it for essential instructions, time-sensitive actions, or content that needs keyboard interaction.