Loading indicator
ExpressiveAn Expressive shape that morphs while it rotates; replaces the spinning circle.
import { LoadingIndicator } from '@windmorph/react';Keyboard
None. It isn't focusable and has no keyboard interaction: it only shows that something is loading.
Screen reader
- Role
progressbar(React AriauseProgressBar).- Accessible name
- The required
aria-labeloraria-labelledby: the types reject an indicator with neither. - States announced
- Indeterminate by default, with no
aria-valuenow. Withvalueit is determinate:aria-valuemin0,aria-valuemax1,aria-valuenowthe value andaria-valuetexta percentage (40%).
The shape is drawn in an <svg> hidden from assistive tech (aria-hidden).
Focus
None. It never takes focus, so it has no focus order or focus ring.
Touch target
None. It isn't interactive, so it needs no touch target.
Motion
- Under reduced motion the indeterminate indicator only rotates, at a steady speed, holding its first shape: no morphs and no springy quarter turns.
- A determinate indicator draws whatever
valuegives it, so it moves only as the value changes.
What you need to do
- Name what is loading (
aria-label="Loading messages","Refreshing page"), not just "Loading". - Keep the indicator at 3:1 contrast against what it sits on. Recolour it only with roles that keep that contrast.
- Don't switch one indicator from indeterminate to determinate. For work whose progress becomes known, use a progress indicator (
LinearProgressIndicatororCircularProgressIndicator).