{
  "$schema": "https://uipkge.dev/schema/registry-item.json",
  "name": "progress",
  "title": "Progress",
  "type": "registry:ui",
  "files": [
    {
      "path": "packages/registry-svelte/components/progress/Progress.svelte",
      "content": "<script lang=\"ts\" module>\n  import type { HTMLAttributes } from 'svelte/elements'\n\n  export interface ProgressProps extends HTMLAttributes<HTMLDivElement> {\n    /** Current value. Clamped to 0..max so the indicator can't overshoot the track. */\n    value?: number | null\n    max?: number\n    ref?: HTMLDivElement | null\n  }\n</script>\n\n<script lang=\"ts\">\n  import { cn } from '$lib/utils'\n\n  let {\n    class: className,\n    value = 0,\n    max = 100,\n    ref = $bindable(null),\n    'aria-label': ariaLabel,\n    'aria-labelledby': ariaLabelledby,\n    ...restProps\n  }: ProgressProps = $props()\n\n  // Clamp so out-of-range value cannot push the indicator past the track.\n  const clampedValue = $derived(Math.min(max, Math.max(0, value ?? 0)))\n  const percentage = $derived(max > 0 ? (clampedValue / max) * 100 : 0)\n</script>\n\n<div\n  {...restProps}\n  bind:this={ref}\n  data-uipkge=\"\"\n  data-slot=\"progress\"\n  role=\"progressbar\"\n  aria-valuemin={0}\n  aria-valuemax={max}\n  aria-valuenow={clampedValue}\n  aria-label={ariaLabel ?? (ariaLabelledby === undefined ? 'Progress' : undefined)}\n  aria-labelledby={ariaLabelledby}\n  class={cn('bg-primary/20 relative h-2 w-full overflow-hidden rounded-full', className)}\n>\n  <div\n    data-uipkge=\"\"\n    data-slot=\"progress-indicator\"\n    class=\"bg-primary h-full w-full flex-1 transition-transform duration-500 ease-out motion-reduce:transition-none\"\n    style={`transform: translateX(-${100 - percentage}%);`}\n  ></div>\n</div>\n",
      "type": "registry:ui",
      "target": "~/src/lib/components/ui/progress/Progress.svelte"
    },
    {
      "path": "packages/registry-svelte/components/progress/index.ts",
      "content": "export { default as Progress, type ProgressProps } from './Progress.svelte'\n",
      "type": "registry:ui",
      "target": "~/src/lib/components/ui/progress/index.ts"
    }
  ],
  "dependencies": [],
  "devDependencies": [],
  "registryDependencies": [],
  "description": "Linear progress bar — determinate or indeterminate. Two visual densities (slim, default), four tones, and an optional inline percentage label.",
  "categories": [
    "feedback"
  ]
}