feat(ui): ship unified audit surfaces

This commit is contained in:
master
2026-03-08 02:16:20 +02:00
parent 6e00a48e00
commit 484abe0039
27 changed files with 673 additions and 55 deletions

View File

@@ -44,6 +44,30 @@ function redirectToDecisioning(path: string) {
};
}
function redirectToEvidence(path: string) {
return ({
params,
queryParams,
fragment,
}: {
params: Record<string, string>;
queryParams: Record<string, string>;
fragment?: string | null;
}) => {
const router = inject(Router);
let targetPath = path;
for (const [name, value] of Object.entries(params ?? {})) {
targetPath = targetPath.replaceAll(`:${name}`, encodeURIComponent(value));
}
const target = router.parseUrl(targetPath);
target.queryParams = { ...queryParams };
target.fragment = fragment ?? null;
return target;
};
}
export const ADMINISTRATION_ROUTES: Routes = [
// A0 — Administration overview
{
@@ -245,6 +269,27 @@ export const ADMINISTRATION_ROUTES: Routes = [
},
// A6 — Trust & Signing
{
path: 'audit',
title: 'Unified Audit Log',
data: { breadcrumb: 'Unified Audit Log' },
redirectTo: redirectToEvidence('/evidence/audit-log'),
pathMatch: 'full',
},
{
path: 'audit/:page',
title: 'Unified Audit Log',
data: { breadcrumb: 'Unified Audit Log' },
redirectTo: redirectToEvidence('/evidence/audit-log/:page'),
pathMatch: 'full',
},
{
path: 'audit/:page/:child',
title: 'Unified Audit Log',
data: { breadcrumb: 'Unified Audit Log' },
redirectTo: redirectToEvidence('/evidence/audit-log/:page/:child'),
pathMatch: 'full',
},
{
path: 'trust-signing',
title: 'Trust & Signing',