Bedform UILoading & Progress

Spinner

Show an indeterminate loading state.

Spinner

*
boolean
*
string
*
number

Usage

import { Spinner } from "@bedform/ui/spinner";

export function LoadingWorlds() {
  return <Spinner aria-label="Loading worlds" />;
}

Size and color

Spinner uses the current font size and text color.

<span style={{ fontSize: "2rem", color: "#52A535" }}>
  <Spinner aria-label="Loading worlds" />
</span>

Decorative

Hide the Spinner from assistive technology when nearby text already describes the loading state.

<Spinner aria-hidden="true" /> <span>Loading worlds</span>

Accessibility

Spinner has role="status" and the label Loading unless you pass an aria-label that describes the loading state. With aria-hidden, it drops both the role and the label. Animation stops when reduced motion is enabled.

On this page