import { Suspense } from "react";
import { Center, Loader } from "@mantine/core";
import PageBody from "@/app/modules/components/PageBody";
import { ModulesContextProvider } from "@/app/modules/contexts/ModulesContext";
import PageContainer from "@/components/layout/PageContainer/PageContainer";

export default async function ModulesPage() {
    return (
        <Suspense
            fallback={
                <Center h="50vh">
                    <Loader size="lg" />
                </Center>
            }>
            <PageContainer>
                <ModulesContextProvider>
                    <PageBody />
                </ModulesContextProvider>
            </PageContainer>
        </Suspense>
    );
}
