Ripple Touch Feedback
A copy-paste mobile patterns component in pure HTML & CSS. Zero dependencies, framework-agnostic, MIT-licensed.
Mobile PatternsHTMLCSSany framework
Copy into your project
HTML
<button type="button" class="nuda-ripple">
<span class="nuda-ripple__label">Tap me</span>
<span class="nuda-ripple__wave" aria-hidden="true"></span>
</button>CSS
/* Ripple Touch Feedback
Material-style expanding ripple on tap.
Customize: --ripple-color */
.nuda-ripple {
--ripple-color: rgba(228, 255, 84, 0.35);
position: relative;
appearance: none;
overflow: hidden;
min-width: 180px;
min-height: 48px;
padding: 0 20px;
border-radius: 12px;
border: 1px solid rgba(255, 255, 255, 0.1);
background: #111114;
color: #fafafa;
font: 600 13px/1 system-ui;
cursor: pointer;
transition: background 0.2s;
}
.nuda-ripple:hover { background: #1a1a20; }
.nuda-ripple__label {
position: relative;
z-index: 1;
}
.nuda-ripple__wave {
position: absolute;
top: 50%;
left: 50%;
width: 10px;
height: 10px;
border-radius: 50%;
background: var(--ripple-color);
transform: translate(-50%, -50%) scale(0);
animation: nuda-ripple-out 1.8s ease-out infinite;
}
@keyframes nuda-ripple-out {
0% { transform: translate(-50%, -50%) scale(0); opacity: 0.8; }
80% { opacity: 0.1; }
100% { transform: translate(-50%, -50%) scale(20); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
.nuda-ripple__wave { animation: none; opacity: 0; }
}How to use Ripple Touch Feedback
Paste the HTML where you need it and the CSS into a global stylesheet (or a <style> tag). Every class is prefixed nuda- so it never collides with Tailwind or your own styles. Tweak the CSS custom properties to match your design system.
Works in React, Vue, Svelte, Astro, Next.js, Nuxt, Laravel Blade, Django, Rails — or a single .html file. No npm install, no build step.