Skip to content

Meteors

Motion

React meteors background that sends accent colored streaks with fading tails falling diagonally behind your content, with count, angle and speed props.

src/registry/premium/meteors.tsx/r/meteors.json

Installation

bash
npx shadcn@latest add @minidev/meteors

MiniDev UI is in the shadcn registry directory, so the short form works with no setup. Older CLI versions can use the full URL: npx shadcn@latest add https://ui.minidev.pro/r/meteors.json

Usage

tsx
import { Meteors } from "@/components/ui/meteors"

export function Example() {
  return (
    <Meteors />
  )
}

API reference

Meteors props
PropTypeDefault
countHow many meteors are in flight at once.number16
angleDirection of travel in degrees. 0 points right, 90 falls straight down.number140
speedSpeed multiplier. 2 is twice as fast, 0.5 half as fast.number1
tailTail length in pixels.number110
classNamestring-
childrenReact.ReactNode-

When to use

Use it behind a dark, quiet hero or release announcement. Reach for Particles when the backdrop should react to the pointer, and RetroGrid or Ripple for a steadier geometric backdrop.

Accessibility

  • The meteor layer is aria-hidden and pointer-events-none.
  • Under reduced motion each meteor is drawn once, still and at half strength, along its path.
  • Animations pause when the panel is more than 80px outside the viewport.

Frequently asked questions

Why are there no meteors in the server HTML?

Paths depend on the panel size, so they are measured with a ResizeObserver after mount. The server renders the panel and your content only, and hydration matches.

How do I change direction, density or speed?

angle sets the direction in degrees (0 points right, 90 falls straight down; default 140). count is how many are in flight (16), speed multiplies the pace and tail sets the streak length in pixels.

Dependencies

npm

lucide-reactmotion

Built from

Examples

Custom content

Children sit above the streaks and keep the pointer; the panel fills its container width.

Angle and speed

angle is degrees of travel, 90 is straight down; speed multiplies the pace and count adds streaks.

Sparse and slow

A handful of long, slow meteors reads as weather behind a quiet section.

All Animated React components