Surfacesstable
Wash
Click colour bloom
A new colour that spreads outward from wherever the surface was touched.
Customize
Triggerclick, automatic, or both
mode6000 ms
intervalBloomshape and pace of the spreading colour
1400 ms
duration0.35
softnessburstpaletteNameUsage
import { Wash } from "zerogravity/wash"
<Wash>
<div>Hero copy</div>
</Wash>Generated from the controls above. Only props that differ from their defaults are shown.
Props
| Property | Type | Default | Description |
|---|---|---|---|
mode | "click" | "auto" | "both" | "both" | Mode. |
interval | number | 6000 | Interval. Range 600 to 15000 ms. |
duration | number | 1400 | Duration. Range 200 to 4000 ms. |
softness | number | 0.35 | Edge softness. Range 0 to 0.9. |
burst | boolean | true | Pixel burst on click. |
children | ReactNode | — | Content laid over the wash. Stays interactive. |
colors | string[] | five muted tones | The cycle of colours to bloom through. Any CSS colour, including var(). |
easing | string | "cubic-bezier(0.22, 1, 0.36, 1)" | Timing function for the spread. |
seed | number | 1 | Fixes the fragment pattern of the pixel burst. |
freezeAt | number | — | Holds the pour and burst at a 0 to 1 progress, for stories and screenshots. |
disabled | boolean | false | Holds the current colour and pours nothing. |
Dependencies
0 external runtime dependencies
Ships with nothing but React.