03
Mesh Gradient
Each palette colour is a soft gaussian point on its own slow orbit. The points are blended by weight into a continuous mesh gradient, and the cursor gently swirls it. The default palette is monochrome graphite. Swap in your brand colours and it becomes a quiet hero backdrop.
Adapted from Paper Shaders · Apache-2.0
mesh gradientOKLabswirl cursor
Live· swirl
Installation
Add it to your project
$
Installs 5 files into components/shaders. The engine is shared, so a second shader only adds its own three files.
Usage
Mount it behind your content
app/hero.tsx
The shader fills its nearest positioned ancestor. Give the parent relative isolate and the shader -z-10 to put it behind everything else. The cursor is tracked on the window, so content on top doesn’t block it.
API reference