{ "$schema": "https://ui.shadcn.com/schema/registry-item.json", "name": "marquee", "type": "registry:ui", "title": "Marquee", "description": "An infinite scrolling component that can be used to display text, images, or videos.", "files": [ { "path": "registry/magicui/marquee.tsx", "content": "import { type ComponentPropsWithoutRef } from \"react\"\n\nimport { cn } from \"@/lib/utils\"\n\ninterface MarqueeProps extends ComponentPropsWithoutRef<\"div\"> {\n /**\n * Optional CSS class name to apply custom styles\n */\n className?: string\n /**\n * Whether to reverse the animation direction\n * @default false\n */\n reverse?: boolean\n /**\n * Whether to pause the animation on hover\n * @default false\n */\n pauseOnHover?: boolean\n /**\n * Content to be displayed in the marquee\n */\n children: React.ReactNode\n /**\n * Whether to animate vertically instead of horizontally\n * @default false\n */\n vertical?: boolean\n /**\n * Number of times to repeat the content\n * @default 4\n */\n repeat?: number\n}\n\nexport function Marquee({\n className,\n reverse = false,\n pauseOnHover = false,\n children,\n vertical = false,\n repeat = 4,\n ...props\n}: MarqueeProps) {\n return (\n \n {Array(repeat)\n .fill(0)\n .map((_, i) => (\n \n {children}\n \n ))}\n \n )\n}\n", "type": "registry:ui" } ], "cssVars": { "theme": { "animate-marquee": "marquee var(--duration) infinite linear", "animate-marquee-vertical": "marquee-vertical var(--duration) linear infinite" } }, "css": { "@keyframes marquee": { "from": { "transform": "translateX(0)" }, "to": { "transform": "translateX(calc(-100% - var(--gap)))" } }, "@keyframes marquee-vertical": { "from": { "transform": "translateY(0)" }, "to": { "transform": "translateY(calc(-100% - var(--gap)))" } } } }