diff --git a/frontend/src/App.tsx b/frontend/src/App.tsx index 8f31bc4..54eebb9 100644 --- a/frontend/src/App.tsx +++ b/frontend/src/App.tsx @@ -33,19 +33,14 @@ function ProtectedLayout() { ); } -// Wrapper for routes with providers +// Wrapper for routes with providers (outside Router) function AppProviders({ children }: { children: React.ReactNode }) { return ( - - - {children} - - - + {children} @@ -53,33 +48,47 @@ function AppProviders({ children }: { children: React.ReactNode }) { ); } +// Wrapper for providers that need Router context +function RouterProviders({ children }: { children: React.ReactNode }) { + return ( + + + {children} + + + + ); +} + function App() { return ( - }> - - {/* Public routes */} - } /> - } /> - - {/* Protected routes with layout */} - }> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - - - {/* 404 */} - } /> - - + + }> + + {/* Public routes */} + } /> + } /> + + {/* Protected routes with layout */} + }> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + + + {/* 404 */} + } /> + + + + - ); }