Velora UI

Border Beam

A beam of light traveling around any border.

  • 0.9 KB gzipped
  • Deps: motion/react
  • Reduced-motion safe
  • Base UI & Radix compatible
Open in v0

Preview

<BorderBeam />

Installation

pnpm dlx shadcn@latest add https://velora.colorlib.com/r/border-beam.json

Adds components/velora/border-beam.tsx, installs motion and merges the keyframes and tokens into your CSS.

Props

PropTypeDefault
classNamestring—
size

Size of the beam in px

number64
duration

Seconds for one full loop

number6
delay

Seconds of delay before starting

number0
reversebooleanfalse
colorFromstring"var(--brand-from)"
colorTostring"var(--brand-to)"

Accessibility

Reduced motion
The beam is hidden entirely; only the parent's normal border remains.
Keyboard
Decorative — nothing to operate.
Screen readers
Decorative; aria-hidden.