import { BrowserRouter, Routes, Route, Navigate } from 'react-router-dom' import { AuthProvider, useAuth } from './context/AuthContext' import { DeveloperModeProvider } from './context/DeveloperModeContext' import Login from './pages/Login' import Dashboard from './pages/Dashboard' import Search from './pages/Search' import Scan from './pages/Scan' import Process from './pages/Process' import Identify from './pages/Identify' import AutoMatch from './pages/AutoMatch' import Modify from './pages/Modify' import Tags from './pages/Tags' import FacesMaintenance from './pages/FacesMaintenance' import Settings from './pages/Settings' import Help from './pages/Help' import Layout from './components/Layout' function PrivateRoute({ children }: { children: React.ReactNode }) { const { isAuthenticated, isLoading } = useAuth() if (isLoading) { return
Loading...
} return isAuthenticated ? <>{children} : } function AppRoutes() { return ( } /> } > } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> ) } function App() { return ( ) } export default App