Skip to Content
zjkm-ui
Components

Water Ripples

Ripples that spread where the cursor moves.

ProPro, coming soon.

Move your pointer here

Props
140px/s
1.6s
<WaterRipples>
  <Hero />
</WaterRipples>

Get notified

Water Ripples is a Pro effect. Join the waitlist and we'll email you when it's available.

Usage

Rings spread out from the pointer as it moves, like ripples on water, and fade as they grow. It draws on a canvas, and the drawing stops while it's off-screen or the tab is hidden. Without canvas support, your content shows on its own.

import { WaterRipples } from "@zjkm/pro/water-ripples";

export function Hero() {
  return (
    <WaterRipples className="rounded-2xl bg-neutral-950 p-16">
      <h1 className="text-white">Make a splash</h1>
    </WaterRipples>
  );
}

Props

PropTypeDefaultDescription
childrenReactNodeContent shown over the ripples.
colorstring"#38bdf8"Ring colour.
speednumber140Pixels per second the rings spread.
lifetimenumber1.6Seconds a ring lasts.
classNamestringClasses for the wrapper.

With reduced motion, it draws one still frame and doesn't react to the pointer.

On this page