2026-03-23 22:17:33 +01:00
|
|
|
import { Outlet, useNavigate, useLocation } from 'react-router';
|
|
|
|
|
import { Tabs } from '@cameleer/design-system';
|
|
|
|
|
|
|
|
|
|
const ADMIN_TABS = [
|
|
|
|
|
{ label: 'User Management', value: '/admin/rbac' },
|
|
|
|
|
{ label: 'Audit Log', value: '/admin/audit' },
|
|
|
|
|
{ label: 'OIDC', value: '/admin/oidc' },
|
2026-03-26 12:51:07 +01:00
|
|
|
{ label: 'App Config', value: '/admin/appconfig' },
|
2026-03-23 22:17:33 +01:00
|
|
|
{ label: 'Database', value: '/admin/database' },
|
|
|
|
|
{ label: 'OpenSearch', value: '/admin/opensearch' },
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
export default function AdminLayout() {
|
|
|
|
|
const navigate = useNavigate();
|
|
|
|
|
const location = useLocation();
|
|
|
|
|
|
|
|
|
|
return (
|
|
|
|
|
<div>
|
|
|
|
|
<Tabs
|
|
|
|
|
tabs={ADMIN_TABS}
|
|
|
|
|
active={location.pathname}
|
|
|
|
|
onChange={(path) => navigate(path)}
|
|
|
|
|
/>
|
feat: replace UI with design system example pages wired to real API
Migrate all page components from the @cameleer/design-system v0.0.3
example UI, replacing mock data with real backend API hooks. This brings
richer visuals (KpiStrip, GroupCard, RouteFlow, ProcessorTimeline,
DateRangePicker, expandable rows) while preserving all existing API
integration, auth, and routing infrastructure.
Pages migrated: Dashboard, RoutesMetrics, RouteDetail, ExchangeDetail,
AgentHealth, AgentInstance, OidcConfig, AuditLog, RBAC (Users/Groups/Roles).
Also enhanced LayoutShell CommandPalette with real search data from catalog.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 16:42:16 +01:00
|
|
|
<div style={{ padding: '20px 24px 40px' }}>
|
|
|
|
|
<Outlet />
|
|
|
|
|
</div>
|
2026-03-23 22:17:33 +01:00
|
|
|
</div>
|
|
|
|
|
);
|
|
|
|
|
}
|