OPUS/UI

Navigation

Beams

new

Glowing light pulses racing along the lines of a faded grid — the “background beams” look with deterministic placement and no JavaScript.

csszero-jsrsc2 files · 89 locdeps: clsx, tailwind-merge

Installation

With the shadcn CLI, pointing at this platform’s registry:

npx shadcn@latest add https://opusui.131199999.xyz/r/beams.json

Or offline, straight from your opus55 checkout (copies every file it needs):

node ../tailwind_component/opus55/scripts/add.mjs beams

Usage

import { Beams } from "@/components/opus/backgrounds/beams";

<Beams className="absolute inset-0" />

API

PropTypeDefaultDescription
colorsstring[]—Beam colours (cycled).
lineColor / backgroundstring—Grid and backdrop.
cell / count / durationnumber64 / 14 / 5Grid pitch, number of beams, average crossing time.
classNamestring—Wrapper classes — `absolute inset-0` to fill a relative parent.
childrenReactNode—Content rendered on top.

Notes

  • No canvas, no WebGL — only CSS gradients/masks and compositor-friendly transform animations.
  • Server-component safe unless marked otherwise; animations stop under prefers-reduced-motion.

Command palette