{ "$schema": "https://ui.shadcn.com/schema/registry-item.json", "name": "animated-accordion-shadcnui", "type": "registry:component", "title": "Animated Accordion", "description": "Accordion with smooth expand/collapse and rotate arrow", "registryDependencies": [ "button" ], "dependencies": [ "framer-motion", "react" ], "files": [ { "path": "@uitripled/react-shadcn/src/components/disclosure/animated-accordion.tsx", "content": "\"use client\";\n\nimport { AnimatePresence, motion } from \"framer-motion\";\nimport { ChevronDown } from \"lucide-react\";\nimport { useState } from \"react\";\n\nconst items = [\n {\n title: \"What is your return policy?\",\n content:\n \"We offer a 30-day money-back guarantee on all our products. If you're not satisfied, contact our support team for a full refund.\",\n },\n {\n title: \"How long does shipping take?\",\n content:\n \"Standard shipping takes 5-7 business days. Express shipping is available for 2-3 day delivery.\",\n },\n {\n title: \"Do you ship internationally?\",\n content:\n \"Yes, we ship to over 50 countries worldwide. International shipping times vary by location.\",\n },\n];\n\nexport function AnimatedAccordion() {\n const [openIndex, setOpenIndex] = useState(null);\n\n return (\n
\n {items.map((item, index) => (\n \n setOpenIndex(openIndex === index ? null : index)}\n className=\"flex w-full items-center justify-between p-4 text-left text-sm font-medium\"\n whileHover={{ backgroundColor: \"rgba(var(--accent-rgb), 0.05)\" }}\n >\n {item.title}\n \n \n \n \n\n \n {openIndex === index && (\n \n
\n {item.content}\n
\n \n )}\n
\n
\n ))}\n \n );\n}\n", "type": "registry:component", "target": "components/uitripled/animated-accordion-shadcnui.tsx" } ] }