Documentation

Component: Marquee Infinite running line animation

The Marquee component creates a continuously animated line of elements that scroll infinitely. It supports custom speed, spacing, direction, hover pause and vertical animations.

What the marquee component does

When the attribute data-anim-marquee is added to a container, the script automatically converts its children into an infinite scrolling animation.

  • Automatically duplicates elements to create infinite scrolling
  • Supports horizontal and vertical directions
  • Allows speed and spacing control
  • Can pause animation on hover
Files location
HTML / SCSS / JS files live in: src/components/effects/marquee/

Basic usage

Add the attribute data-anim-marquee to any container.

Basic marquee markup
<div data-anim-marquee>
	<span>element one</span>
	<span>element two</span>
	<span>element three</span>
</div>

Animation speed

You can control the animation speed using data-anim-marquee-speed.

  • Default value: 100
Custom speed
<div data-anim-marquee data-anim-marquee-speed="80">
   ...
</div>

Space between items

Control spacing between elements using data-anim-marquee-space.

Custom spacing
<div data-anim-marquee data-anim-marquee-space="50">
   ...
</div>

Animation direction

The marquee supports horizontal and vertical directions.

  • left
  • right
  • top
  • bottom
Direction example
<div data-anim-marquee data-anim-marquee-direction="right">
   ...
</div>

Pause on hover

Add the attribute data-anim-marquee-pause to pause animation on hover.

Pause on hover
<div data-anim-marquee data-anim-marquee-pause>
   ...
</div>

Start position offset

You can offset the starting animation position using data-anim-marquee-start.

Start offset
<div data-anim-marquee data-anim-marquee-start="30">
   ...
</div>

Download

Add smooth, infinite marquee animations to your UI with zero setup.