Refactor Accordion motion properties

Updated Accordion motion properties for better animation effects.
This commit is contained in:
Jeff
2026-05-12 10:36:55 +05:30
committed by GitHub
parent d7db8c8c83
commit 6ba453aa1a

View File

@@ -314,11 +314,10 @@ export function ExpandingCard({ title, body }: { title: string; body: string })
```tsx
<motion.div
animate={{
height: open ? "auto" : 0,
overflow: "hidden",
}}
transition={{
initial={false}
animate={{ opacity: open ? 1 : 0, scaleY: open ? 1 : 0 }}
style={{ transformOrigin: "top", overflow: "hidden" }}
transition={{
duration: motionTokens.duration.normal,
ease: motionTokens.easing.smooth,
}}