ZeroGravity UI

Interfacestable

Dither

Pixel hover highlight

A pixel hover layer for any card, link or button: blocks sweep in from the pointer, or a quick block frame lights the edge.

The cards are a radio choice and never navigate. Pass as={Link} when a card should.

Customize

Pixelshover style, block size, glow and colour
variant
8 pxcell
0.50glow
color
Sweepfill, resting texture and timing; sweep variant only
0.300density
420 msduration
origin
Statestacking and a held-on state
layer
active

Usage

TSX
import { Dither } from "zerogravity/dither"

<Dither>
    <YourCard />
</Dither>

Generated from the controls above. Only props that differ from their defaults are shown.

Props

14 documented props on Dither
PropertyTypeDefaultDescription
variant"sweep" | "edge""sweep"Variant.
cellnumber8Cell. Range 4 to 24 px.
glownumber0.5Glow. Range 0 to 1.5.
colorstring"#4ee1f2"Colour.
densitynumber0.3Rest density. Range 0 to 1.
durationnumber420Duration. Range 120 to 1400 ms.
origin"pointer" | "center" | "left" | "right" | "top" | "bottom""pointer"Origin.
layer"under" | "over""under"Layer.
activebooleanfalseForce active.
asElementType"div"Element or component to render, such as "a", "button" or a router Link.
childrenReactNode—Content drawn above the pixel layer and left fully interactive.
colorsstring[]—Several block colours, assigned per cell. Overrides color.
disabledbooleanfalseRender the element without the pixel layer.
respectReducedMotionbooleantrueShow the settled state instantly instead of sweeping or stepping in.

Dependencies

0 external runtime dependencies

Ships with nothing but React.