Flash target
HTMX Compatibility
Built-in support for HTMX lifecycle classes. No extra CSS needed.
Indicator (auto-spinner)
Empty
.htmx-indicator gets a CSS spinner
<div class="htmx-request">
<span class="htmx-indicator"></span>
<span>Loading…</span>
</div>
Form loading state
<form class="htmx-request">
<label for="name">Name</label>
<input type="text" id="name" value="Jane Smith">
<button type="submit">Submitting…</button>
</form>
Settle flash & Error shake
Shake target
<!-- Settle flash: fade-in + outline highlight -->
<div class="htmx-settling">…</div>
<!-- Error shake: red outline + shake animation -->
<div class="htmx-error">…</div>
HTMX classes reference
| Class | When | FAP CSS effect |
|---|---|---|
.htmx-indicator | During request | Show/hide with fade; auto-spinner when empty |
.htmx-request | On requesting element | Dim + wait cursor; forms disable inputs |
.htmx-swapping | Before swap | Fade out |
.htmx-settling | After swap | Fade in + outline flash |
.htmx-added | New elements | Fade-in animation |
.htmx-error | Failed request | Red outline + shake |
Usage
<!-- Skeleton loading -->
<div hx-get="/api/data" hx-trigger="load" aria-busy="true">
Loading…
</div>
<!-- Inline editing -->
<p contenteditable="true"
hx-post="/api/update"
hx-trigger="blur"
hx-swap="outerHTML">
Click to edit
</p>