Dot Pattern
A customizable dot pattern background component that creates a repeating grid of dots. Supports optional glow animations and mask effects for beautiful background designs.Installation
Usage
Props
The width of the pattern tile in pixels.
The height of the pattern tile in pixels.
The x-offset of the entire pattern.
The y-offset of the entire pattern.
The x-offset of individual dots within the pattern tile.
The y-offset of individual dots within the pattern tile.
The radius of each dot in pixels.
Whether dots should have a glowing animation effect with pulsing opacity and scale.
Additional CSS classes to apply to the SVG element.
Examples
Basic Dot Pattern
With Glow Effect
With Linear Gradient Mask
Custom Dot Size and Spacing
Larger Dots with Glow
Notes
- The component uses motion-sv for glow animations
- Glow effect creates random pulsing animations for each dot
- Use CSS masks to create focused or gradient reveal effects
- The pattern automatically adapts to container size
- Each dot can have different animation timing when glow is enabled