Text Marquee

Animated text marquee component with vertical scrolling.

sv-animations/
Magic
Spell
Aceternity
Luxe
Indie
Motion

Installation

pnpm dlx shadcn-svelte@latest add https://sv-animations.vercel.app/s/text-marquee.json

Usage

<script lang="ts">	import { TextMarquee } from "#lib/components/spell/text-marquee/index.js";</script>
<TextMarquee items={["Magic", "Spell", "Motion"]}>	{#snippet children(item)}		<span>{item}</span>	{/snippet}</TextMarquee>

Props

NameTypeDefaultDescription
itemsT[]requiredThe ordered list of items to animate through vertically.
childrenSnippet<[T, number]>requiredSnippet used to render each animated row with the current item and index.
prefixSnippetOptional snippet rendered once before the animated viewport.
speednumber1Scales the total loop duration; larger values make the marquee cycle more slowly.
heightnumber200Sets the visible viewport height in pixels.
itemHeightnumber40Sets the height of each animated row in pixels.
classClassValueCustom classes applied to the root wrapper.
stylestringInline styles forwarded to the root wrapper.