{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "spinner",
  "type": "registry:ui",
  "title": "Spinner",
  "description": "Indeterminate loading spinner (Phosphor CircleNotch) for buttons and async regions.",
  "dependencies": [
    "@saasflare/ui"
  ],
  "files": [
    {
      "path": "components/ui/spinner.tsx",
      "type": "registry:ui",
      "content": "// @toreview\n/**\n * @fileoverview Spinner primitive — animated loading indicator built on the\n * Phosphor CircleNotch icon. Applies a continuous spin animation with accessible\n * status role.\n * Part of the Saasflare base component layer.\n * @module packages/ui/components/ui/spinner\n * @layer core\n *\n * @component\n * @example\n * import { Spinner } from '@saasflare/ui';\n * <Spinner className=\"size-6\" />\n */\n\"use client\"\n\nimport * as React from \"react\"\n\nimport { CircleNotchIcon } from \"@saasflare/ui\"\n\nimport { cn } from \"@saasflare/ui\"\nimport { useSaasflareProps, type SaasflareComponentProps } from \"@saasflare/ui\"\n\n/**\n * Props for {@link Spinner}.\n *\n * Extends the SVG element props with {@link SaasflareComponentProps}. The\n * spinner keeps the regular icon weight regardless of `iconWeight` — a\n * deliberate visual-identity exemption.\n */\ninterface SpinnerProps extends Omit<React.ComponentProps<\"svg\">, keyof SaasflareComponentProps>, SaasflareComponentProps {}\n\n/**\n * Loading indicator — a spinning Phosphor CircleNotch with `role=\"status\"` and\n * an accessible \"Loading\" label. The spin animation respects the resolved\n * `animated` axis. Size via `className` (defaults to `size-4`).\n *\n * @component\n * @layer core\n *\n * @example\n * <Spinner className=\"size-6\" />\n */\nfunction Spinner({ className, surface, radius, animated, iconWeight, ...props }: SpinnerProps) {\n  const sf = useSaasflareProps({ surface, radius, animated, iconWeight })\n\n  return (\n    <CircleNotchIcon\n      {...props}\n      role=\"status\"\n      aria-label=\"Loading\"\n      data-slot=\"spinner\"\n      data-surface={sf.surface}\n      data-radius={sf.radius}\n      data-animated={String(sf.animated)}\n      className={cn(\"size-4\", sf.animated && \"animate-spin\", className)}\n    />\n  )\n}\n\nexport { Spinner, type SpinnerProps }\n",
      "target": "components/ui/spinner.tsx"
    }
  ],
  "$meta": {
    "source": "https://ui.saasflare.io/r/spinner.json"
  }
}
