Sigil Weather
Web (React)
A WebGL2 background where lightning, water or flame plays around a sigil, toned in the active theme colours.
A full-bleed WebGL2 scene built around a signed distance field of a sigil. Lightning crawls fBm arcs along its contour by default; water refracts it beneath pointer-driven ripples, and flame licks noise-driven tongues and embers upward from its edge. The whole scene is mapped through a duotone of the theme tokens (background, primary, foreground), so it reads as ink on paper in light mode, glows in dark mode and follows the palette; set palette="original" to keep the source colours. It fills its positioned parent, pauses when off screen or when the tab is hidden, and renders a still frame when the user prefers reduced motion.
Installation
CLI
npx @modus-ui/cli add sigil-weatherManual
- Copy the code from the component tab.
- Create a file at
components/ui/sigil-weather.tsx. - Paste the code.
Usage
tsx
Props
| Prop | Type | Default | Description |
|---|---|---|---|
variant | "water" | "lightning" | "flame" | "lightning" | Which element plays around the sigil. |
palette | "theme" | "original" | "theme" | theme tones the scene with the theme tokens; original keeps the source colours. |
markPath | string | "M12 0C12.9 7 17 11.1 24 12C17 12.9 12.9 17 12 24C11.1 17 7 12.9 0 12C7 11.1 11.1 7 12 0Z" | SVG path data in a 24×24 viewBox used as the central mark. |
speed | number | 1 | Animation speed multiplier (0 to 3). |
size | number | 1 | Mark size multiplier (0.65 to 1.5). |
particleAmount | number | 1 | Particle count multiplier (0 to 2). |
opacity | number | 1 | Canvas opacity (0.05 to 1). |
hue | number | 0 | Hue rotation in degrees (-180 to 180). |
saturation | number | 1 | Saturation multiplier (0 to 2). |
brightness | number | 1 | Brightness multiplier (0.35 to 1.8). |
backgroundColor | string | --background | Darkest tone of the scene (theme token by default). |
Comments