"use client"; import { motion, useInView } from "framer-motion"; import { useRef } from "react"; interface FadeInProps { children: React.ReactNode; className?: string; delay?: number; direction?: "up" | "down" | "left" | "right"; } export function FadeIn({ children, className = "", delay = 0, direction = "up" }: FadeInProps) { const ref = useRef(null); const isInView = useInView(ref, { once: true, margin: "-100px" }); const directionOffset = { up: { y: 40, x: 0 }, down: { y: -40, x: 0 }, left: { x: 40, y: 0 }, right: { x: -40, y: 0 }, }; return ( {children} ); }