import { ReactNode } from "react"; import { useParams } from "react-router"; import BreadcrumbSimple from "../breadcrumbs/BreadcrumbSimple"; import Tabs, { TabItem } from "../tabs/Tabs"; import { cn } from "~/lib/utils"; import { adminPath } from "~/utils/app/CanonicalUrlUtils"; import UrlUtils from "~/utils/app/UrlUtils"; interface Props { title?: ReactNode; menu?: { title: string; routePath?: string; }[]; buttons?: ReactNode; children: ReactNode; withHome?: boolean; tabs?: TabItem[]; fullWidth?: boolean; className?: string; } export default function EditPageLayout({ title, menu, buttons, children, withHome = true, tabs, fullWidth, className }: Props) { const params = useParams(); const home = params.tenant ? UrlUtils.currentTenantUrl(params, "dashboard") : adminPath("dashboard", { mode: "host-aware" }); return (