{ "$schema": "https://ui.shadcn.com/schema/registry-item.json", "name": "floating-phone", "title": "Floating Phone", "description": "A floating phone component", "files": [ { "path": "registry/pioneerui/floating-phone.tsx", "content": "\"use client\"\n\nimport type React from \"react\"\nimport { useState } from \"react\"\nimport { motion, useMotionValue, useTransform, useSpring } from \"framer-motion\"\nimport { FiBatteryCharging, FiWifi } from \"react-icons/fi\"\nimport Link from \"next/link\"\nimport { cn } from \"@/lib/utils\"\n\ninterface FloatingPhoneProps {\n gradientStart?: string\n gradientEnd?: string\n textColor?: string\n content?: React.ReactNode\n actionText?: string\n actionLink?: string\n showStatusBar?: boolean\n logo?: React.ReactNode\n title?: string\n}\n\nexport type IconProps = React.SVGProps;\n\n\nconst DefaultLogo = ({ className, ...props }: IconProps) => (\n \n {/* Background with purple and gold gradient */}\n \n \n {/* Overlay texture */}\n \n \n {/* Main Logo Elements */}\n \n {/* Compass Star */}\n \n \n {/* Direction Lines */}\n \n \n {/* Small Stars */}\n \n \n \n \n {/* Decorative Arc */}\n \n \n \n {/* Gradients and Effects */}\n \n \n {/* Deep Purple */}\n {/* Rich Purple */}\n {/* Warm Gold */}\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n)\n\nexport const FloatingPhone: React.FC = ({\n gradientStart = \"#4F46E5\",\n gradientEnd = \"#9333EA\",\n textColor = \"#ffffff\",\n content,\n actionText = \"Explore Now\",\n actionLink = \"#\",\n showStatusBar = true,\n logo,\n title = \"PioneerUI\",\n}) => {\n const [isHovered, setIsHovered] = useState(false)\n const mouseX = useMotionValue(0)\n const mouseY = useMotionValue(0)\n\n const rotateX = useTransform(mouseY, [-300, 300], [15, -15])\n const rotateY = useTransform(mouseX, [-300, 300], [-15, 15])\n\n const springConfig = { damping: 20, stiffness: 300 }\n const rotateXSpring = useSpring(rotateX, springConfig)\n const rotateYSpring = useSpring(rotateY, springConfig)\n\n const handleMouseMove = (event: React.MouseEvent) => {\n const rect = event.currentTarget.getBoundingClientRect()\n mouseX.set(event.clientX - rect.left - rect.width / 2)\n mouseY.set(event.clientY - rect.top - rect.height / 2)\n }\n\n return (\n setIsHovered(true)}\n onMouseLeave={() => {\n setIsHovered(false)\n mouseX.set(0)\n mouseY.set(0)\n }}\n >\n \n {/* Phone Body */}\n \n {/* Glass Effect */}\n \n\n {/* Status Bar */}\n {showStatusBar && (\n <>\n
\n
\n \n \n
\n \n )}\n\n {/* Screen Content */}\n
\n {content ? (\n
{content}
\n ) : (\n
\n {logo || }\n
\n {title}\n
\n
\n )}\n\n {/* Action Button */}\n \n \n {actionText}\n \n \n\n {/* Gradient Effects */}\n \n \n
\n\n {/* Bottom Line */}\n
\n \n \n
\n )\n}\n\n", "type": "registry:ui", "target": "components/pioneerui/floating-phone.tsx" } ], "type": "registry:ui" }