Flock
Teams move faster in formation
Plan, build and ship on one shared rhythm, with every update in plain sight.
More cursor effects in Pro
Cursor trails and pointer effects that give a site its own feel.
children | ReactNode | Content the swarm flows behind, such as a hero with buttons. | |
count | 800 | Number of particles in the swarm, up to 2000. | |
size | 2.6 | Size of each particle, in px. | |
shape | 'dot' | 'streak' | 'square' | 'dot' | Shape of each particle. |
color | '#ffffff' | Color of the particles. Defaults to near black in light mode. | |
accentColor | color | Color particles take on when they rush and when you click. | |
spread | 90 | Radius of the swarm around the cursor, in px. | |
speed | How lively the swarm churns and turns while the cursor rests. | ||
swirl | 0.6 | How much the swarm curls into eddies and how long they keep turning, from 0 (calm) to 1 (stormy). | |
tail | 0.5 | How far the swarm streams behind a fast cursor, from 0 (tight) to 1 (a long trailing tail). | |
trail | 0.6 | Motion blur on fast particles. | |
wander | 0.5 | How restlessly the swarm folds and drifts on its own. | |
depth | 0.7 | How much near particles grow and blur and far ones shrink and fade, from 0 (flat) to 1 (deep). | |
targets | 'a, button, [data-swarm-target]' | Elements inside the swarm that it pours around while hovered. Pass an empty string to turn this off. | |
idle | 'roam' | 'gather' | 'hide' | 'roam' | What the swarm does while the cursor is away: drift around the area, wait in the middle, or fade out. |
clickEffect | 'burst' | 'pulse' | 'none' | 'burst' | What a click does. Burst splashes the swarm outward in a curl, pulse sends a wave of light through it. |
hideCursor | Hides the system cursor over the component and marks the pointer with a dot, so the swarm becomes the cursor. | ||
| Swirls the swarm in from across the area on mount. | |||
enabled | Shows and animates the swarm. | ||
lightMode | Uses near black particles by default and keeps them crisp, for light backgrounds. | ||
dpr | auto | Maximum device pixel ratio, capped at 2. | |
| Extra class names for the container. | |||
| Inline styles for the container. |
childrenReactNodeContent the swarm flows behind, such as a hero with buttons.
countnumberNumber of particles in the swarm, up to 2000.
800sizenumberSize of each particle, in px.
2.6shape'dot' | 'streak' | 'square'Shape of each particle.
'dot'colorstringColor of the particles. Defaults to near black in light mode.
'#ffffff'accentColorstringColor particles take on when they rush and when you click.
colorspreadnumberRadius of the swarm around the cursor, in px.
90speednumberHow lively the swarm churns and turns while the cursor rests.
swirlnumberHow much the swarm curls into eddies and how long they keep turning, from 0 (calm) to 1 (stormy).
0.6tailnumberHow far the swarm streams behind a fast cursor, from 0 (tight) to 1 (a long trailing tail).
0.5trailnumberMotion blur on fast particles.
0.6wandernumberHow restlessly the swarm folds and drifts on its own.
0.5depthnumberHow much near particles grow and blur and far ones shrink and fade, from 0 (flat) to 1 (deep).
0.7targetsstringElements inside the swarm that it pours around while hovered. Pass an empty string to turn this off.
'a, button, [data-swarm-target]'idle'roam' | 'gather' | 'hide'What the swarm does while the cursor is away: drift around the area, wait in the middle, or fade out.
'roam'clickEffect'burst' | 'pulse' | 'none'What a click does. Burst splashes the swarm outward in a curl, pulse sends a wave of light through it.
'burst'hideCursorbooleanHides the system cursor over the component and marks the pointer with a dot, so the swarm becomes the cursor.
introbooleanSwirls the swarm in from across the area on mount.
enabledbooleanShows and animates the swarm.
lightModebooleanUses near black particles by default and keeps them crisp, for light backgrounds.
dprnumberMaximum device pixel ratio, capped at 2.
autoExtra class names for the container.
Inline styles for the container.



