Backgrounds

Lightfall

Thin streaks of light falling in columns, each with a bright head and a fading tail.
import { Lightfall } from "pleate/effects/lightfall";

Behind a headline

Light, falling softly

Props

density

Share of columns with streaks, 0 to 1.

numberdefault 0.5

columns

Columns across the height of the canvas.

numberdefault 36

colors

CSS colors or tokens: two colors the streaks mix between. Defaults follow the palette.

string[]

speed

Playback speed.

numberdefault 1

scale

Pattern size; above 1 is bigger.

numberdefault 1

interactive

React to the pointer over the parent.

booleandefault true

Accessibility

  • Decorative: the canvas is aria-hidden and ignores pointer events, so content on top stays usable.
  • Pauses off screen and in hidden tabs; with reduced motion it shows a still frame.
  • Fills its parent: give the parent position relative and the background absolute inset-0.