shadcn.io is not affiliated with official shadcn/ui
Framework
UI library
Radix UI does not include this primitive, so this page uses the Ark UI component. The visuals match the Ark UI version.
Installation
bunx --bun shadcn@latest add https://kit.dev/r/radix/marquee.jsonAnatomy
Marquee
├── MarqueeContent
│ └── MarqueeViewport
├── MarqueeEdge
└── MarqueeItemUsage
import { AppleIcon } from "@/components/icons/apple";
import { ChatGptIcon } from "@/components/icons/chat-gpt";
import { ClaudeIcon } from "@/components/icons/claude";
import { GoogleIcon } from "@/components/icons/google";
import { NextIcon } from "@/components/icons/next";
import { ReactIcon } from "@/components/icons/react";
import { ViteIcon } from "@/components/icons/vite";
import { VueIcon } from "@/components/icons/vue";
import { Card, CardContent } from "@/components/ui/card";
import {
Marquee,
MarqueeContent,
MarqueeItem,
} from "@/components/ui/marquee";const MarqueeDemo = () => (
<Marquee>
<MarqueeContent>
{items.map((Icon, index) => (
<MarqueeItem key={index}>
<Card className="[--space:--spacing(8)]">
<CardContent>
<Icon className="size-10" />
</CardContent>
</Card>
</MarqueeItem>
))}
</MarqueeContent>
</Marquee>
);
const items = [
GoogleIcon,
AppleIcon,
NextIcon,
ChatGptIcon,
ClaudeIcon,
ViteIcon,
VueIcon,
ReactIcon,
];Accessibility
| Key | Description |
|---|---|
End | Go to the end. |
Demos
Autofill
Custom Speed
Fade
Orientation Horizontal
Orientation Vertical
Pause On Hover
Reverse
Spacing
API Reference
Marquee
div
PropType
AttributeType
CSS variableType
--marquee-delaystring--marquee-durationstring--marquee-loop-countstring--marquee-spacingstring--marquee-translatestringMarqueeViewport
div
PropType
AttributeType
CSS variableType
--marquee-delaystringMarqueeContent
div
PropType
childrenReactNodeAttributeType
CSS variableType
--marquee-delaystringMarqueeEdge
div
PropType
AttributeType
MarqueeItem
div
PropType
AttributeType