feat: unified loader

This commit is contained in:
TrèsAbhi committed 2024-01-05 15:01:45 -06:00
1 parent 884531700b
commit cb6ce4f183
7 files changed
+63 -37

No files matched your search

+3 -2
View File
@@ -1,9 +1,10 @@
'use client';
import { usePathname } from 'next/navigation';
import { ReactNode } from 'react';
import { ReactNode, Suspense } from 'react';
import { TOOLS } from '../../constants/tools';
import { theme } from '../../stitches.config';
import { Loader } from './components/Loader';
interface ToolsLayoutProps {
children: ReactNode;
@@ -63,7 +64,7 @@ export default function ToolsLayout({ children }: ToolsLayoutProps) {
</span>
</div>
{children}
<Suspense fallback={<Loader />}>{children}</Suspense>
</>
);
}