Components

Grid Background (Radix UI)

A responsive grid background with animated moving beams.

Installation

pnpm dlx shadcn@latest add @toui/grid-background

Examples

Hero

API Reference

This component is built using Motion primitives and includes the following custom props:

GridBackground

PropTypeDefault
children ReactNode
gridSize enum "8:8"
className string
colors.background string"bg-slate-900"
colors.borderColor string"border-slate-700/50"
colors.borderSize string"1px"
colors.borderStyle enum "solid"
beams.count number12
beams.colors string[]["bg-cyan-400", "bg-purple-400", "bg-fuchsia-400", "bg-violet-400", "bg-blue-400", "bg-indigo-400", "bg-green-400", "bg-yellow-400", "bg-orange-400", "bg-red-400", "bg-pink-400", "bg-rose-400"]
beams.shadow string"shadow-lg shadow-cyan-400/50 rounded-full"
beams.speed number4

Credits

We use cookies

We use cookies to ensure you get the best experience on our website. For more information on how we use cookies, please see our cookie policy.

By clicking Accept, you agree to our use of cookies.
Learn more.