feat(FN-005): implement frontend foundation with auth and routing
- Add OIDC authentication with PKCE flow - Create dashboard shell with sidebar and header - Implement project management UI (list, create, detail) - Add tool spawn page with tool/project selection - Create tool instance detail page with status and controls - Set up React Router with route guards - Add Zustand auth store and API client with types
This commit is contained in:
@@ -0,0 +1,45 @@
|
||||
import { createBrowserRouter } from 'react-router-dom'
|
||||
import App from './App'
|
||||
import RouteGuard from './components/RouteGuard'
|
||||
import DashboardLayout from './components/DashboardLayout'
|
||||
import LoginPage from './pages/LoginPage'
|
||||
import CallbackPage from './pages/CallbackPage'
|
||||
import DashboardPage from './pages/DashboardPage'
|
||||
import ProjectListPage from './pages/ProjectListPage'
|
||||
import ProjectDetailPage from './pages/ProjectDetailPage'
|
||||
import ProjectFormPage from './pages/ProjectFormPage'
|
||||
import ToolsPage from './pages/ToolsPage'
|
||||
import ToolSpawnPage from './pages/ToolSpawnPage'
|
||||
import ToolInstanceDetailPage from './pages/ToolInstanceDetailPage'
|
||||
import SettingsPage from './pages/SettingsPage'
|
||||
import RepositoriesPage from './pages/RepositoriesPage'
|
||||
|
||||
export const router = createBrowserRouter([
|
||||
{
|
||||
path: '/',
|
||||
element: <App />,
|
||||
children: [
|
||||
{
|
||||
element: (
|
||||
<RouteGuard>
|
||||
<DashboardLayout />
|
||||
</RouteGuard>
|
||||
),
|
||||
children: [
|
||||
{ path: '/', element: <DashboardPage /> },
|
||||
{ path: '/projects', element: <ProjectListPage /> },
|
||||
{ path: '/projects/new', element: <ProjectFormPage /> },
|
||||
{ path: '/projects/:id', element: <ProjectDetailPage /> },
|
||||
{ path: '/projects/:id/edit', element: <ProjectFormPage /> },
|
||||
{ path: '/tools', element: <ToolsPage /> },
|
||||
{ path: '/tools/spawn', element: <ToolSpawnPage /> },
|
||||
{ path: '/projects/:projectId/instances/:instanceId', element: <ToolInstanceDetailPage /> },
|
||||
{ path: '/settings', element: <SettingsPage /> },
|
||||
{ path: '/repositories', element: <RepositoriesPage /> },
|
||||
],
|
||||
},
|
||||
{ path: '/login', element: <LoginPage /> },
|
||||
{ path: '/callback', element: <CallbackPage /> },
|
||||
],
|
||||
},
|
||||
])
|
||||
Reference in New Issue
Block a user