04.02 · Micro-Interactions
Click / Tap Ripple
A ripple spreads out from the spot you press. Best for buttons and list items.
Click it
Click or tap anywhere on a button (or Tab to one and press Enter), or press Show me.
Inside, one press is shown at three moments: a circle starts small, grows far past the edge, which cuts it off, and fades. Press a button, or press Show me.
No ripple: a press shows nothing, so you cannot tell it landed; Ripple: a circle spreads across the button and fades. Press a button, or press Show me.
Try it
Change a setting, then try it again or press Show me.
Starts from
Where you press shows exactly where it landed.
Speed
How long the ripple takes to spread and fade.
Ripple size
How far the circle grows before it fades.
Copy the prompt
Paste it into an AI assistant such as ChatGPT, Claude or Cursor to build this in your own project.
Add a ripple to [the buttons or list items you want to respond to presses]. When the visitor presses one, a soft circle appears where they pressed, or in the middle when the settings say so, then grows outward and fades away. Clip it to the button's shape so it never spills outside, start it as soon as the press begins so the feedback feels instant, and remove each ripple once it has faded so quick taps do not pile up. It should work the same for mouse, touch and pen. If the visitor has reduced motion turned on, fade a flat highlight over the button instead of a growing circle. Match the settings listed below.
Your settings
Replace the words in brackets with your own element. Your settings are added at the end.
Free and open source. If this helped, a star on GitHub helps other people find it.
Star on GitHubWhat it is
The full explanation is in README.md.