Terrace Dusk
Web (React)
Fifteen breathing terraces stepping down from left to right, cut from your theme's tones.
A full-bleed Three.js shader of fifteen grained bars that step down from left to right and breathe on a slow pulse. The bars are a lightness ramp on the theme's primary hue and the ground above them is the theme background, so it reads as ink terraces on paper in light mode and as dusk in dark mode, following the palette picker. It fills its positioned parent, pauses when off screen and renders a still frame when the user prefers reduced motion.
Installation
CLI
npx @modus-ui/cli add terrace-duskManual
- Install
three. - Copy the code from the component tab.
- Create a file at
components/ui/terrace-dusk.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). |
baseColor | string | theme primary, deep | Colour of the bars at the bottom. |
startColor | string | theme primary, light | Gradient colour on the left side. |
endColor | string | theme primary | Gradient colour on the right side. |
horizonColor | string | theme background | Colour above the stepped horizon. |
backgroundColor | string | "hsl(var(--background))" | Colour behind the canvas. |
Comments