{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "plane-landing",
  "type": "registry:ui",
  "registryDependencies": [],
  "dependencies": ["motion"],
  "devDependencies": [],
  "files": [
    {
      "path": "plane-landing.tsx",
      "content": "\"use client\";\n\nimport { motion, useAnimation, type Variants } from \"motion/react\";\nimport type { HTMLAttributes } from \"react\";\nimport { forwardRef, useCallback, useImperativeHandle, useRef } from \"react\";\nimport { cn } from \"@/lib/utils\";\n\nexport interface PlaneLandingIconHandle {\n  startAnimation: () => void;\n  stopAnimation: () => void;\n}\n\ninterface PlaneLandingIconProps extends HTMLAttributes<HTMLDivElement> {\n  size?: number;\n}\n\nconst PLANE_LANDING_VARIANTS: Variants = {\n  normal: {\n    x: 0,\n    y: 0,\n    opacity: 1,\n    scale: 1,\n    rotate: 0,\n  },\n  animate: {\n    x: [-38, 1, 0],\n    y: [-20, 1, 0],\n    opacity: [0, 1, 1],\n    scale: [0.5, 1],\n    rotate: [16, -5, 0],\n    transition: {\n      duration: 1.1,\n      ease: [0.25, 1, 0.5, 1],\n      times: [0, 0.65, 1],\n    },\n  },\n};\n\nconst PlaneLandingIcon = forwardRef<\n  PlaneLandingIconHandle,\n  PlaneLandingIconProps\n>(({ onMouseEnter, onMouseLeave, className, size = 28, ...props }, ref) => {\n  const controls = useAnimation();\n  const isControlledRef = useRef(false);\n\n  useImperativeHandle(ref, () => {\n    isControlledRef.current = ref != null;\n    return {\n      startAnimation: () => controls.start(\"animate\"),\n      stopAnimation: () => controls.start(\"normal\"),\n    };\n  }, [controls, ref]);\n\n  const handleMouseEnter = useCallback(\n    (e: React.MouseEvent<HTMLDivElement>) => {\n      if (isControlledRef.current) {\n        onMouseEnter?.(e);\n      } else {\n        controls.start(\"animate\");\n      }\n    },\n    [controls, onMouseEnter]\n  );\n\n  const handleMouseLeave = useCallback(\n    (e: React.MouseEvent<HTMLDivElement>) => {\n      if (isControlledRef.current) {\n        onMouseLeave?.(e);\n      } else {\n        controls.start(\"normal\");\n      }\n    },\n    [controls, onMouseLeave]\n  );\n\n  return (\n    <div\n      className={cn(className)}\n      onMouseEnter={handleMouseEnter}\n      onMouseLeave={handleMouseLeave}\n      {...props}\n    >\n      <motion.svg\n        className=\"overflow-visible\"\n        fill=\"none\"\n        height={size}\n        stroke=\"currentColor\"\n        strokeLinecap=\"round\"\n        strokeLinejoin=\"round\"\n        strokeWidth=\"2\"\n        viewBox=\"0 0 24 24\"\n        width={size}\n        xmlns=\"http://www.w3.org/2000/svg\"\n      >\n        <path d=\"M2 22h20\" />\n        <motion.path\n          animate={controls}\n          d=\"M3.77 10.77 2 9l2-4.5 1.1.55c.55.28.9.84.9 1.45s.35 1.17.9 1.45L8 8.5l3-6 1.05.53a2 2 0 0 1 1.09 1.52l.72 5.4a2 2 0 0 0 1.09 1.52l4.4 2.2c.42.22.78.55 1.01.96l.6 1.03c.49.88-.06 1.98-1.06 2.1l-1.18.15c-.47.06-.95-.02-1.37-.24L4.29 11.15a2 2 0 0 1-.52-.38Z\"\n          initial=\"normal\"\n          style={{ originX: 0.5, originY: 0.5 }}\n          variants={PLANE_LANDING_VARIANTS}\n        />\n      </motion.svg>\n    </div>\n  );\n});\n\nPlaneLandingIcon.displayName = \"PlaneLandingIcon\";\n\nexport { PlaneLandingIcon };\n",
      "type": "registry:ui"
    }
  ]
}
