{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "progress",
  "type": "registry:ui",
  "title": "Progress",
  "description": "Linear determinate progress bar for uploads, completion meters, and loading states.",
  "dependencies": [
    "@radix-ui/react-progress",
    "@saasflare/ui",
    "motion"
  ],
  "files": [
    {
      "path": "components/ui/progress.tsx",
      "type": "registry:ui",
      "content": "// @toreview\n\"use client\"\n\n/**\n * @fileoverview Saasflare Progress — animated progress bar.\n * @module packages/ui/components/ui/progress\n * @layer core\n *\n * Self-contained implementation using Radix Progress primitive directly.\n * Width animation respects reduced-motion preference.\n *\n * @example\n * import { Progress } from \"@saasflare/ui\";\n * <Progress value={65} />\n */\n\nimport * as React from \"react\"\nimport { m } from \"motion/react\"\nimport * as ProgressPrimitive from \"@radix-ui/react-progress\"\nimport { cn } from \"@saasflare/ui\"\nimport { useSaasflareProps, type SaasflareComponentProps } from \"@saasflare/ui\"\nimport { useSaasflareMotion, spring } from \"@saasflare/ui\"\n\n/**\n * Props for {@link Progress}.\n *\n * Extends the Radix Progress Root props with {@link SaasflareComponentProps},\n * so `surface`, `radius`, `animated`, and `iconWeight` can be supplied\n * per-instance or inherited from <SaasflareProvider>.\n */\ninterface ProgressProps\n  extends Omit<React.ComponentProps<typeof ProgressPrimitive.Root>, keyof SaasflareComponentProps>,\n    SaasflareComponentProps {}\n\n/**\n * Progress bar with smooth spring animation.\n *\n * @component\n * @layer core\n *\n * @param {number} value - Progress value (0-100)\n *\n * @example\n * <Progress value={42} className=\"w-full\" />\n */\nfunction Progress({\n  className,\n  value,\n  surface,\n  radius,\n  animated,\n  iconWeight,\n  ...props\n}: ProgressProps) {\n  const sf = useSaasflareProps({ surface, radius, animated, iconWeight })\n  const motion = useSaasflareMotion(sf.animated, spring)\n\n  return (\n    <ProgressPrimitive.Root\n      {...props}\n      data-slot=\"progress\"\n      data-surface={sf.surface}\n      data-radius={sf.radius}\n      data-animated={String(sf.animated)}\n      className={cn(\n        \"relative h-2 w-full overflow-hidden rounded-full bg-primary/20\",\n        className\n      )}\n    >\n      <ProgressPrimitive.Indicator data-slot=\"progress-indicator\" asChild>\n        <m.div\n          className=\"h-full bg-primary\"\n          initial={motion.disabled ? false : { width: \"0%\" }}\n          animate={{ width: `${value ?? 0}%` }}\n          transition={motion.transition}\n        />\n      </ProgressPrimitive.Indicator>\n    </ProgressPrimitive.Root>\n  )\n}\n\nexport { Progress, type ProgressProps }\n",
      "target": "components/ui/progress.tsx"
    }
  ],
  "$meta": {
    "source": "https://ui.saasflare.io/r/progress.json"
  }
}
