Reflection Text
Text EffectsCrisp typography meets a soft, fading reflection beneath the baseline.
Letters break formation on hover, then settle back into line.
Copy the component and its CSS module into your project.
Matches your current playground settings.
import DisperseText from "./DisperseText";export default function Example() {return (<DisperseTexttext={"BREAK FORM"}distance={22}rotation={18}duration={650}color={"#ebdcca"}style={{"fontSize": 56}}/>);}
Use a short word or phrase with room around it for the letters to separate. distance and rotation control the amount of movement.
Use active to coordinate the effect with another interaction. Reducing distance is a useful way to fit the effect into a tighter layout.
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
| text | string | No | "" | Text to scatter. Accessible text is announced once. |
| distance | number | No | 25 | Maximum displacement in pixels. |
| rotation | number | No | 18 | Maximum rotation in degrees. |
| duration | number | No | 650 | Scatter and return transition duration in milliseconds. |
| color | string | No | "inherit" | Text colour. |
| active | boolean | No | undefined | Optional controlled scatter state; otherwise pointer hover or keyboard focus activates it. |
| className | string | No | "" | Additional classes merged with component styles. |
| style | CSSProperties | No | undefined | Inline styles for caller-defined sizing, typography, and appearance. |