mirror of
https://github.com/pheralb/svgl.git
synced 2025-02-06 06:58:04 +08:00
25 lines
413 B
JavaScript
25 lines
413 B
JavaScript
import React from "react";
|
|
import { motion } from "framer-motion";
|
|
|
|
const Transitions = ({ key, children }) => {
|
|
return (
|
|
<motion.div
|
|
key={key}
|
|
initial="initial"
|
|
animate="animate"
|
|
variants={{
|
|
initial: {
|
|
opacity: 0,
|
|
},
|
|
animate: {
|
|
opacity: 1,
|
|
},
|
|
}}
|
|
>
|
|
{children}
|
|
</motion.div>
|
|
);
|
|
};
|
|
|
|
export default Transitions;
|