import { lazy, Suspense } from 'react'; import { BrowserRouter, Routes, Route, Navigate } from 'react-router-dom'; import { AuthProvider } from './context/AuthContext'; import ProtectedRoute from './components/ProtectedRoute'; import PageLoader from './components/PageLoader'; import Login from './pages/Login'; import PayInvoice from './pages/PayInvoice'; const Settings = lazy(() => import('./pages/Settings')); const Dashboard = lazy(() => import('./pages/team/Dashboard')); const Companies = lazy(() => import('./pages/team/Companies')); const CompanyDetail = lazy(() => import('./pages/team/CompanyDetail')); const ProjectDetail = lazy(() => import('./pages/team/ProjectDetail')); const TeamProjects = lazy(() => import('./pages/team/TeamProjects')); const Requests = lazy(() => import('./pages/team/Requests')); const Invoices = lazy(() => import('./pages/team/Invoices')); const MeetingNotes = lazy(() => import('./pages/team/MeetingNotes')); const TaskDetail = lazy(() => import('./pages/team/TaskDetail')); const CreateInvoice = lazy(() => import('./pages/team/CreateInvoice')); const CreateSubcontractorPO = lazy(() => import('./pages/team/CreateSubcontractorPO')); const InvoiceDetail = lazy(() => import('./pages/team/InvoiceDetail')); const SubcontractorPODetail = lazy(() => import('./pages/team/SubcontractorPODetail')); const SurveyMaker = lazy(() => import('./pages/team/SurveyMaker')); const BrandBook = lazy(() => import('./pages/team/BrandBook')); const Converters = lazy(() => import('./pages/team/Converters')); const ServerStatus = lazy(() => import('./pages/team/ServerStatus')); const FileSharing = lazy(() => import('./pages/team/FileSharing')); const FourgePasswords = lazy(() => import('./pages/team/FourgePasswords')); const ExternalMyRequests = lazy(() => import('./pages/external/MyRequests')); const MyPurchaseOrders = lazy(() => import('./pages/external/MyPurchaseOrders')); const ExternalMyInvoices = lazy(() => import('./pages/external/MyInvoices')); const ExternalProjects = lazy(() => import('./pages/external/ExternalProjects')); const ExternalMyInvoiceDetail = lazy(() => import('./pages/external/MyInvoiceDetail')); const ExternalMyInvoiceCreate = lazy(() => import('./pages/external/MyInvoiceCreate')); const ClientDashboard = lazy(() => import('./pages/client/ClientDashboard')); const MyCompany = lazy(() => import('./pages/client/MyCompany')); const MyRequests = lazy(() => import('./pages/client/MyRequests')); const MyProjects = lazy(() => import('./pages/client/MyProjects')); const MyProjectDetail = lazy(() => import('./pages/client/MyProjectDetail')); const MyInvoices = lazy(() => import('./pages/client/MyInvoices')); const RequestDetail = lazy(() => import('./pages/client/RequestDetail')); const NewRequest = lazy(() => import('./pages/client/NewRequest')); const NewProject = lazy(() => import('./pages/client/NewProject')); export default function App() { return ( }> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> } /> ); }