The page now lives at /instruction; /brain and /perintah redirect there. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
32 lines
1.4 KiB
TypeScript
32 lines
1.4 KiB
TypeScript
import { Navigate, Route, Routes } from 'react-router-dom'
|
|
import { AuthGate } from './auth/AuthGate'
|
|
import { AppLayout } from './components/AppLayout'
|
|
import { BrainPage } from './pages/Brain'
|
|
import { ProductionPage } from './pages/Production'
|
|
import { InstructionPage } from './pages/Instruction'
|
|
import { SchedulePage } from './pages/Schedule'
|
|
import { ResultsPage } from './pages/Results'
|
|
|
|
export default function App() {
|
|
return (
|
|
<AuthGate>
|
|
<Routes>
|
|
<Route element={<AppLayout />}>
|
|
<Route path="/production" element={<ProductionPage />} />
|
|
<Route path="/upload" element={<BrainPage />} />
|
|
<Route path="/instruction" element={<InstructionPage />} />
|
|
<Route path="/schedule" element={<SchedulePage />} />
|
|
<Route path="/results" element={<ResultsPage />} />
|
|
</Route>
|
|
{/* Paths from before the routes were renamed, so old links keep working. */}
|
|
<Route path="/brain" element={<Navigate replace to="/instruction" />} />
|
|
<Route path="/otak" element={<Navigate replace to="/upload" />} />
|
|
<Route path="/perintah" element={<Navigate replace to="/instruction" />} />
|
|
<Route path="/jadwal" element={<Navigate replace to="/schedule" />} />
|
|
<Route path="/hasil" element={<Navigate replace to="/results" />} />
|
|
<Route path="*" element={<Navigate replace to="/production" />} />
|
|
</Routes>
|
|
</AuthGate>
|
|
)
|
|
}
|