# Spinner

The busy glyph: a 270° arc on a faint track, turning on its own 1s period.

Live variants: https://design.arcadia.is/components/spinner

```tsx
import { Spinner, SpinnerGlyph } from "@arcadia/ui";
```

```tsx
import { Button, ListRow, Spinner } from "@arcadia/ui";

<Button variant="secondary" icon="upload" loading>Uploading</Button>
<div {...sx("cmp-rows", cmp.rows, cmp.rowsNarrow)} data-width="narrow">
  <ListRow
    leading={<Spinner size="sm" />}
    label="Indexing files"
    meta="12%"
    interactive={false}
  />
</div>
```

## Accessibility

Decorative unless given a `label`, which makes it an `img` with that name; omit it when nearby text already says what is happening. A loading Button or IconButton sets `aria-busy` itself. With reduced motion the arc holds still.

## API reference

### Spinner

- `size` (`"xs" | "sm" | "md" | "lg" | "text"`, default `"md"`): 10 / 12 / 14 / 16 px, or `text`: in an icon's slot, the size and stroke of the icon of the text style it stands in.
- `label` (`string`): Accessible name ("Loading"). Omit when adjacent text already says what is happening.
- `arc` (`"long" | "half"`, default `"long"`): The arc: `long` (about 270 degrees) or `half` (about 180, a thinking step's live node).
- `rootStyle` (`RootStyle<SpinnerKnobs>`): Typed StyleX override: layout and the `--spinner-*` knobs.

Rest props go to `<span>` props and `render`.
