{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "provider-orbit",
  "title": "Provider Orbit",
  "author": "STARCK",
  "description": "A reduced-motion-aware orbit for integrations and providers.",
  "dependencies": [
    "framer-motion@^11.0.0"
  ],
  "files": [
    {
      "path": "registry/default/provider-orbit.tsx",
      "content": "\"use client\"\n\nimport * as React from \"react\"\nimport {\n  motion,\n  useAnimationFrame,\n  useMotionValue,\n  useReducedMotion,\n  useTransform,\n} from \"framer-motion\"\n\ntype OrbitItem = {\n  name: string\n  icon: React.ReactNode\n}\n\ntype ProviderOrbitProps = {\n  items: readonly OrbitItem[]\n  center: React.ReactNode\n  duration?: number\n  className?: string\n}\n\nfunction ProviderOrbit({\n  items,\n  center,\n  duration = 32,\n  className = \"\",\n}: ProviderOrbitProps) {\n  const reduced = useReducedMotion()\n  const [paused, setPaused] = React.useState(false)\n  const rotation = useMotionValue(0)\n  const counterRotation = useTransform(rotation, (value) => -value)\n  const safeDuration = Math.max(duration, 1)\n\n  useAnimationFrame((_time, delta) => {\n    if (reduced || paused) return\n    rotation.set((rotation.get() + (delta / (safeDuration * 1000)) * 360) % 360)\n  })\n\n  return (\n    <div\n      className={`relative mx-auto aspect-square w-full max-w-[420px] ${className}`}\n    >\n      <div\n        className=\"absolute inset-[8%] rounded-full border border-dashed border-zinc-300\"\n        aria-hidden\n      />\n      <motion.div\n        className=\"absolute inset-0\"\n        style={{ rotate: rotation }}\n        onPointerEnter={() => setPaused(true)}\n        onPointerLeave={() => setPaused(false)}\n      >\n        {items.map((item, index) => {\n          const angle = (360 / items.length) * index\n          return (\n            <div\n              key={item.name}\n              className=\"absolute top-1/2 left-1/2\"\n              style={\n                {\n                  \"--orbit-radius\": \"clamp(112px, 38vw, 170px)\",\n                  transform: `translate(-50%, -50%) rotate(${angle}deg) translateY(calc(-1 * var(--orbit-radius)))`,\n                } as React.CSSProperties\n              }\n            >\n              <motion.div style={{ rotate: counterRotation }}>\n                <div style={{ transform: `rotate(${-angle}deg)` }}>\n                  <div\n                    title={item.name}\n                    className=\"grid size-12 place-items-center rounded-2xl border border-black/8 bg-white text-sm font-semibold text-zinc-700 shadow-[0_12px_30px_-18px_rgba(0,0,0,0.45)]\"\n                  >\n                    {item.icon}\n                  </div>\n                </div>\n              </motion.div>\n            </div>\n          )\n        })}\n      </motion.div>\n      <div className=\"absolute top-1/2 left-1/2 grid size-24 -translate-x-1/2 -translate-y-1/2 place-items-center rounded-[28px] border border-black/8 bg-zinc-950 text-center text-sm font-semibold text-white shadow-[0_24px_60px_-28px_rgba(0,0,0,0.75)]\">\n        {center}\n      </div>\n      <ul className=\"sr-only\">\n        {items.map((item) => (\n          <li key={item.name}>{item.name}</li>\n        ))}\n      </ul>\n    </div>\n  )\n}\n\nexport { ProviderOrbit }\nexport type { OrbitItem, ProviderOrbitProps }\n",
      "type": "registry:component",
      "target": "components/provider-orbit.tsx"
    }
  ],
  "type": "registry:component"
}