Newer
Older
My-Portfolio / frontend / src / components / sections / projects / Container.jsx
import { motion } from "framer-motion";

const Container = ({
  children,
  className,
  shadow = true,
  whileHover,
  transition = { duration: 0.5 },
}) => {
  return (
    <motion.div
      className={`rounded-lg p-6 ${
        shadow ? "shadow-lg" : "shadow-none"
      } ${className}`}
      initial={{ opacity: 0, y: 50 }}
      animate={{ opacity: 1, y: 0 }}
      whileHover={whileHover}
      transition={transition}
    >
      {children}
    </motion.div>
  );
};

export default Container;