Skip to content
satin

Spinner

Says something is loading when there is no telling how long it takes.

Installation

Terminal
npm i @uisatin/ui
Import
import { Spinner } from '@uisatin/ui/spinner'

About 11.8 kB of JavaScript, minified and gzipped, with what it imports (React aside). The stylesheet is one file for every component.

First time with Satin? Set it up once, styles and fonts included, with the installation guide.

API Reference

The Spinner component is a span with role="status" around a turning arc in the current colour. With label={null} it is hidden from screen readers.

PropTypeDefault
size
"xs""sm""md""lg"
"md"
label
stringnull
"Loading"
className
string
—
ref
Ref<HTMLSpanElement>
—
...props
ComponentProps<'span'>

Other attributes go to <span>

—

Accessibility

On its own it is role="status" named "Loading" (or label). With label={null} it is hidden from screen readers, for a spinner inside something that already says it is busy, such as a loading Button.