2022-09-29 12:02:09 -06:00
|
|
|
import React from 'react';
|
2025-12-11 18:32:55 -07:00
|
|
|
import {PageContainer, TabLinks} from "../Common";
|
2025-12-07 11:54:20 -07:00
|
|
|
import {Route, Routes} from "react-router";
|
2023-07-21 15:14:09 -06:00
|
|
|
import {DownloadsPage} from "./Downloads";
|
2023-08-17 20:07:02 -06:00
|
|
|
import {SettingsPage} from "./Settings";
|
2023-08-23 19:08:13 -06:00
|
|
|
import {StatusPage} from "./Status";
|
2025-12-11 18:32:55 -07:00
|
|
|
import {ControllerPage} from "./ControllerPage";
|
2022-09-29 12:02:09 -06:00
|
|
|
|
2023-07-21 15:14:09 -06:00
|
|
|
export default function AdminRoute() {
|
2022-09-29 12:02:09 -06:00
|
|
|
|
|
|
|
|
const links = [
|
|
|
|
|
{text: 'Downloads', to: '/admin', key: 'admin', end: true},
|
|
|
|
|
{text: 'Settings', to: '/admin/settings', key: 'settings'},
|
|
|
|
|
{text: 'Status', to: '/admin/status', key: 'status'},
|
2025-12-11 18:32:55 -07:00
|
|
|
{text: 'Controller', to: '/admin/controller', key: 'controller'},
|
2022-09-29 12:02:09 -06:00
|
|
|
];
|
|
|
|
|
|
2023-02-17 16:09:24 -07:00
|
|
|
return <PageContainer>
|
|
|
|
|
<TabLinks links={links}/>
|
|
|
|
|
<Routes>
|
2023-07-21 15:14:09 -06:00
|
|
|
<Route path='/' exact element={<DownloadsPage/>}/>
|
2023-08-17 20:07:02 -06:00
|
|
|
<Route path='settings' exact element={<SettingsPage/>}/>
|
2023-08-23 19:08:13 -06:00
|
|
|
<Route path='status' exact element={<StatusPage/>}/>
|
2025-12-11 18:32:55 -07:00
|
|
|
<Route path='controller' exact element={<ControllerPage/>}/>
|
2023-02-17 16:09:24 -07:00
|
|
|
</Routes>
|
|
|
|
|
</PageContainer>
|
2022-09-29 12:02:09 -06:00
|
|
|
}
|