animated

Rain

A looping character-art rain animation with adjustable trails and dimensions.

Install

pnpm add @fractaldesign/machines-ui
import '@fractaldesign/machines-ui/style.css';
import { GraphRain } from '@fractaldesign/machines-ui';

Preview

[ RAIN ]

glyph rain

<GraphRain title="RAIN" cols={48} rows={12} />

Props

PropTypeDefaultDescription
title* string —Caption drawn on the top edge as `[ TITLE ]`. Uppercase, 1–2 words.
animated boolean trueAnimate the rain. Default true. Reduced motion freezes a single frame.
cols number 56Width in character columns. Default 56.
rows number 16Height in rows. Default 16.
speedMs number 110Milliseconds per tick. Default 110.
trail number 8Trail length behind each head. Default 8.
seedNum number 5Seed for the reproducible rain. Default 5.
label string 'glyph rain'Short caption under the art; the art itself is decorative.
class string ''

API

  • class forwarded to the outer element
  • motion runs live; set animated={false} to freeze
  • a11y honours prefers-reduced-motion

Types

NameKindDescription
Dropinterface
Seginterface

Theming

CSS custom properties this component reads.

  • --graph-accent
  • --text-muted
  • --text-primary
  • --text-secondary

Related

Built from

src/lib/components/animated/GraphRain.svelte

machines-ui