import { FC, ReactNode } from "react"; // layouts import { observer } from "mobx-react-lite"; import { CommandPalette } from "@/components/command-palette"; import { UserAuthWrapper, WorkspaceAuthWrapper, ProjectAuthWrapper } from "@/layouts/auth-layout"; // components import { AppSidebar } from "./sidebar"; import { SidebarHamburgerToggle } from "@/components/core/sidebar/sidebar-menu-hamburger-toggle"; export interface IAppLayout { children: ReactNode; header: ReactNode; withProjectWrapper?: boolean; mobileHeader?: ReactNode; } export const AppLayout: FC = observer((props) => { const { children, header, withProjectWrapper = false, mobileHeader } = props; return ( <>
{header}
{mobileHeader && mobileHeader}
{withProjectWrapper ? {children} : <>{children}}
); });