Backgrounds

Dot grid

A field of dots that behaves like a membrane: dots near the pointer swell, light up and lean away on springs, and a click sends a shockwave rolling across the grid. Canvas 2D — no WebGL.

Paste it into ChatGPT, Claude, Cursor or v0.
gap24
radius130

Usage

import { DotGrid } from '@vizzele/react';

<DotGrid gap={24} radius={130} style={{ minHeight: 480 }}>
  <h1>Your hero</h1>
</DotGrid>

Props

PropTypeDefaultDescription
gapnumber24Distance between dots (px).
sizenumber1.4Dot radius (px).
radiusnumber130Reach of the pointer (px).
shockbooleantrueA click sends a shockwave.

Accessibility

  • The canvas is aria-hidden; your content sits on top and stays fully interactive.
  • It only animates while on screen and while something is moving, then goes idle.
  • With reduced motion the dots still light up near the pointer but never move.