import { authOptions } from "@/config/authConfig" import { getServerSession, Session } from "next-auth" import DashboardPage from "./DashboardPage" import { Typography } from "@mui/material" import { I18nProvider, getServerI18n } from "@/i18n"; import DashboardLoading from "./DashboardLoading"; // export type SessionWithAbilities = { // abilities: string[] // } & Session | null interface SubComponents { Loading: typeof DashboardLoading; } type Props = { searchParams: { [key: string]: string | string[] | undefined }; } const DashboardWrapper: React.FC & SubComponents = async ({ searchParams }) => { const { t } = await getServerI18n("dashboard"); // const session: SessionWithAbilities = await getServerSession(authOptions) return ( <> {t("Dashboard")} ) } DashboardWrapper.Loading = DashboardLoading; export default DashboardWrapper