Snippets Buttons

Bootstrap 5 Buttons with CSS Hover Effects

Six pill buttons, each with a different CSS-only hover effect: slide fill, lift, shine sweep, moving arrow, glow ring and a pressable key.

Bootstrap 5 No jQuery Aug 2019 2.1K views

<section class="wdw-stage">
<div class="container" style="max-width:720px">
<div class="text-center mb-4"><span class="wdw-eyebrow">Buttons</span><h2 class="wdw-heading h2 mb-1">Six hover effects, zero JavaScript</h2><p class="wdw-muted mb-0">Bootstrap buttons plus one modifier class each. Hover or focus to try them.</p></div>
<div class="wdw-card px-4 py-2">
<div class="fx-row d-flex align-items-center justify-content-between gap-3 py-3"><div class="wdw-min0"><div class="fw-semibold text-body-emphasis">Slide fill</div><div class="small wdw-muted">Colour wipes in from the left</div></div><button type="button" class="btn btn-outline-primary rounded-pill fx fx-fill">Slide fill</button></div>
<div class="fx-row d-flex align-items-center justify-content-between gap-3 py-3 border-top"><div class="wdw-min0"><div class="fw-semibold text-body-emphasis">Lift</div><div class="small wdw-muted">Rises with a coloured shadow</div></div><button type="button" class="btn rounded-pill fx fx-lift">Lift</button></div>
<div class="fx-row d-flex align-items-center justify-content-between gap-3 py-3 border-top"><div class="wdw-min0"><div class="fw-semibold text-body-emphasis">Shine</div><div class="small wdw-muted">A highlight sweeps across</div></div><button type="button" class="btn rounded-pill fx fx-shine">Shine</button></div>
<div class="fx-row d-flex align-items-center justify-content-between gap-3 py-3 border-top"><div class="wdw-min0"><div class="fw-semibold text-body-emphasis">Arrow</div><div class="small wdw-muted">Icon slides forward</div></div><button type="button" class="btn btn-outline-secondary rounded-pill fx fx-arrow">Continue <svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M5 12h14M13 6l6 6-6 6"/></svg></button></div>
<div class="fx-row d-flex align-items-center justify-content-between gap-3 py-3 border-top"><div class="wdw-min0"><div class="fw-semibold text-body-emphasis">Glow ring</div><div class="small wdw-muted">A soft halo blooms outward</div></div><button type="button" class="btn rounded-pill fx fx-ring is-hover">Glow ring</button></div>
<div class="fx-row d-flex align-items-center justify-content-between gap-3 py-3 border-top"><div class="wdw-min0"><div class="fw-semibold text-body-emphasis">Press</div><div class="small wdw-muted">3D key that sinks when clicked</div></div><button type="button" class="btn btn-primary rounded-pill fx fx-press">Press</button></div>
<div class="fx-row d-flex align-items-center justify-content-between gap-3 py-3 border-top"><div class="wdw-min0"><div class="fw-semibold text-body-emphasis">Disabled</div><div class="small wdw-muted">Effects switch off</div></div><button type="button" class="btn btn-primary rounded-pill fx fx-lift" disabled>Unavailable</button></div>
</div>
</div>
</section>

Built on Bootstrap 5.3.8 with plain JavaScript — no jQuery. Supports light and dark mode via data-bs-theme.

Free to use in personal and commercial projects under the MIT license.