// Layout/container used for the main mostly empty landing page, can be used for related pages (credits, about, etc.) import { AnimatePresence, domAnimation, LazyMotion, m, Variants, } from "framer-motion"; import Head from "next/head"; import { useRouter } from "next/router"; import NavBar from "../components/common/NavBar"; import { NavTemplate } from "./NavTemplates"; interface HomeLayoutProps { navOptions: NavTemplate[]; children: React.ReactNode; metaTags: { title?: string; ogTitle?: string; description?: string; ogDescription?: string; content?: string; imageUrl?: string; themeColor?: string; misc?: { [key: string]: string; }; }; } function HomeLayout(props: HomeLayoutProps) { // get the nav options const navOptions = props.navOptions; // get the current route for animation purposes const router = useRouter(); const title = props.metaTags.title ?? "Dashboard - toffee"; return ( {title} {props.metaTags.misc && Object.keys(props.metaTags.misc).map((key) => { return ( ); })} {props.children} ); } const containerVariants: Variants = { initial: { opacity: 0 }, animate: { opacity: 1 }, exit: { opacity: 0 }, }; export default HomeLayout;