feat(automation): own automation page with tree sidebar, separate from agents
This commit is contained in:
@@ -80,6 +80,9 @@ const HelpPlaceholderPage = React.lazy(() => import('@/pages/help/HelpPlaceholde
|
||||
const AgentsPage = React.lazy(() => import('@/pages/Agents').then(m => ({ default: m.AgentsPage })));
|
||||
const AgentsOverviewPage = React.lazy(() => import('@/pages/agents/AgentsOverview').then(m => ({ default: m.AgentsOverviewPage })));
|
||||
const AgentsPlaceholderPage = React.lazy(() => import('@/pages/agents/AgentsPlaceholder').then(m => ({ default: m.AgentsPlaceholderPage })));
|
||||
const AutomationPage = React.lazy(() => import('@/pages/Automation').then(m => ({ default: m.AutomationPage })));
|
||||
const AutomationOverviewPage = React.lazy(() => import('@/pages/automation/AutomationOverview').then(m => ({ default: m.AutomationOverviewPage })));
|
||||
const AutomationPlaceholderPage = React.lazy(() => import('@/pages/automation/AutomationPlaceholder').then(m => ({ default: m.AutomationPlaceholderPage })));
|
||||
const ApiDocsPage = React.lazy(() => import('@/pages/ApiDocs').then(m => ({ default: m.ApiDocsPage })));
|
||||
|
||||
/** Centered spinner fallback for lazy-loaded routes */
|
||||
@@ -174,6 +177,19 @@ const router = createBrowserRouter([
|
||||
{ path: '*', element: withSuspense(<AgentsPlaceholderPage />) },
|
||||
],
|
||||
},
|
||||
{
|
||||
path: '/automation',
|
||||
element: withSuspense(<AutomationPage />),
|
||||
children: [
|
||||
{ path: 'overview', element: withSuspense(<AutomationOverviewPage />) },
|
||||
{ path: 'runs', element: withSuspense(<AutomationDashboardPage />) },
|
||||
{ path: 'versions', element: withSuspense(<AgentsPlaceholderPage />) },
|
||||
{ path: 'triggers', element: withSuspense(<AgentsPlaceholderPage />) },
|
||||
{ path: 'actions', element: withSuspense(<AgentsPlaceholderPage />) },
|
||||
{ path: 'conditions', element: withSuspense(<AgentsPlaceholderPage />) },
|
||||
{ path: '*', element: withSuspense(<AutomationPlaceholderPage />) },
|
||||
],
|
||||
},
|
||||
{
|
||||
path: '/settings',
|
||||
element: <PermissionRoute permission="settings:read">{withSuspense(<SettingsPage />)}</PermissionRoute>,
|
||||
|
||||
Reference in New Issue
Block a user