Skip to content

Spinner

In review
Live · web

Sizes: stroke scales with the diameter

xssmmdlgmd · track

With a label, baseline-aligned beside the arc

Loading sessions…Transcribing…

Inline within a line of running text

Connecting to the gatewayand resuming nockerl-design · docs site. This can take a moment.

Centered in a region · NockerlOverlay over dimmed content

Loading file…
Refreshing…

In a button: label swap, on-accent arc, blocks re-click

On a dark vs a light surface: same cyan arc

on canvas on a lifted card

Saved 0 times · overlay on. The island is live.

// Web: React, consuming @dizyx/nockerl-tokens. (Web is the laggard platform;
// this is the canonical API the published @dizyx/nockerl-react package exposes.)
// The spinner is the INDETERMINATE CIRCULAR loader: no value, no %, no track
// number. For a determinate ring use the NockerlGauge (shape="ring").
import { NockerlSpinner, NockerlButton } from '@dizyx/nockerl-react';
// Sizes. Stroke scales with the diameter. role="status" + aria-label baked in.
<NockerlSpinner size="md" label="Loading" />
// Beside a label (the most common form).
<span style={{ display: 'inline-flex', alignItems: 'center', gap: 8 }}>
<NockerlSpinner size="sm" /> Loading sessions…
</span>
// Centered in a content region while it loads.
<div className="file-preview" aria-busy>
<NockerlSpinner size="lg" label="Loading file" />
</div>
// In a button, the NockerlButton primitive owns its OWN loading spinner (on-accent tinted)
// and holds its width. Pass `loading` + an optional `loadingText`; do NOT nest a
// NockerlSpinner inside it (NockerlButton takes `text`, not children).
<NockerlButton text="Save" loading loadingText="Saving…" />
PropTypeDefaultDescription
sizeNockerlSpinnerSize'md'Diameter step. Stroke width scales with the size (thinner when small).
toneNockerlSpinnerTone'accent'Arc color: the cyan accent (default), the on-accent label (in a primary button), or inherit.
trackbooleanfalseRender the faint recessed track ring behind the arc.
labelstring'Loading'Accessible name announced by assistive tech.

Also accepts the native <span> attributes (e.g. onClick, disabled, id, aria-*, data-*), forwarded straight through, plus a forwarded ref.

The spinner is presentational (not focusable). It honors prefers-reduced-motion: the continuous spin stops and degrades to a static partial arc with a gentle opacity pulse, never an infinite fast spin.