Relief Mesh
Web (React)
A slowly turning mesh globe of pulsing nodes joined by fine links, inked in theme tokens and fading into the page background.
A slowly turning mesh globe of pulsing nodes joined by fine links, inked in theme tokens and fading into the page background. It fills its positioned parent, follows the active theme and palette in light and dark mode, pauses when off screen and renders a still frame when the user prefers reduced motion.
Installation
CLI
npx @modus-ui/cli add relief-meshManual
- Copy the code from the component tab.
- Create a file at
components/ui/relief-mesh.tsx. - Paste the code.
Usage
tsx
Props
| Prop | Type | Default | Description |
|---|---|---|---|
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.65). |
nodeColor | string | theme primary | Colour of the pulsing nodes. |
lineColor | string | theme foreground | Colour of the links between nodes. |
fogColor | string | theme background | Colour the far side of the globe fades into. |
backgroundColor | string | theme background | Colour behind the effect. |
Comments