feat: expand admin and instructor tools
This commit is contained in:
3
App.tsx
3
App.tsx
@@ -10,6 +10,7 @@ import { AuthProvider, useAuth } from './context/AuthContext';
|
||||
import { ToastProvider } from './context/ToastContext';
|
||||
import { Course, UserRole } from './types';
|
||||
import { SuperAdmin } from './pages/SuperAdmin';
|
||||
import { AccessTokenPage } from './pages/AccessTokenPage';
|
||||
|
||||
// Protected Route Component
|
||||
const ProtectedRoute: React.FC<{ children: React.ReactNode; allowedRoles?: UserRole[] }> = ({ children, allowedRoles }) => {
|
||||
@@ -90,6 +91,8 @@ function AppContent() {
|
||||
</ProtectedRoute>
|
||||
}
|
||||
/>
|
||||
<Route path="/invite" element={<AccessTokenPage mode="invite" />} />
|
||||
<Route path="/reset-password" element={<AccessTokenPage mode="reset" />} />
|
||||
|
||||
{/* Catch all redirect */}
|
||||
<Route path="*" element={<Navigate to="/" replace />} />
|
||||
|
||||
Reference in New Issue
Block a user