Framer Motion » Automatic Layout Animations » Scale Correction for Child Elements

Scale Correction for Child Elements

Child elements might visually distort when their parent resizes, but it’s easily solved.Look at this example. The white motion.div (with layout property) grows or shrinks when you tap it and has a red dot (standard div) as a child.export default function App() { const [big, setBig] = useState(false); return ( // Parent <motion.div layout style={{ […]
To access this page, you must purchase The Framer book.