npx shadcn@latest add https://sdk-components.thesqd.com/r/spinner.jsonimport { Spinner, type SpinnerVariant, type SpinnerSize } from "@/components/ui/spinner";import { Spinner } from "@/components/ui/spinner";
export function Example() {
return <Spinner size="md" variant="brand" />;
}Spinner (single component — flat prop API)
├── size="sm | md | lg | xl" (default "md")
├── variant="brand | current | muted | destructive | pixels-1 | pixels-2" (default "brand")
├── color=… (named tint alias OR any CSS color string)
├── icon={LucideIcon} (override the default LoaderIcon)
└── ...props (forwarded to the underlying svg)| Prop | Type | Default | Description |
|---|---|---|---|
size | "sm" | "md" | "lg" | "xl" | "md" | Icon dimensions — maps to size-3 / size-4 / size-5 / size-6. |
variant | "brand" | "current" | "muted" | "destructive" | "pixels-1" | "pixels-2" | "brand" | Look. Named tints render a spinning icon (`current` inherits the parent's color); `pixels-1` (dither sphere) and `pixels-2` (dither swirl) render WebGL pixel loaders. |
color | SpinnerVariant | (string & {}) | — | A named tint (alias of `variant`) OR any CSS color string (`#0ea5e9`, `rgb(...)`) to tint the whole spinner, pixel variants included. |
icon | LucideIcon | LoaderIcon | Override the default lucide icon (e.g. `LoaderCircleIcon`). |
className | string | — | Override or extend the resolved variant classes. |
| Prop | Type | Default | Description |
|---|---|---|---|
message | string | — | Title text shown next to the spinner. |
label | string | — | Optional trailing text (e.g. `$100.00`). When undefined the trailing slot is not rendered. |
background | boolean | true | When `true`, tints the row with the sidebar-hover bg (`#341756/10` light, `white/10` dark). Set to `false` for a plain muted Item with no tint. |
icon | LucideIcon | — | Override the spinner's lucide icon. |
spinnerSize | "sm" | "md" | "lg" | "xl" | — | Forwarded to the inner Spinner's `size` prop. |
spinnerVariant | "brand" | "current" | "muted" | "destructive" | — | Forwarded to the inner Spinner's `variant` prop. |