Files
Nexus/packages/db/src/system-role-config-defaults.ts
Hartmut b41c1d2501
CI / Architecture Guardrails (push) Successful in 2m38s
CI / Assistant Split Regression (push) Successful in 3m33s
CI / Typecheck (push) Successful in 3m51s
CI / Lint (push) Successful in 5m2s
CI / E2E Tests (push) Has been cancelled
CI / Fresh-Linux Docker Deploy (push) Has been cancelled
CI / Release Images (push) Has been cancelled
CI / Build (push) Has been cancelled
CI / Unit Tests (push) Has been cancelled
rename(phase 1): CapaKraken → Nexus across code, UI, docs, CI (#61)
rename(phase 1): CapaKraken → Nexus across code, UI, docs, CI (#61)

Co-authored-by: Hartmut Nörenberg <hn@hartmut-noerenberg.com>
Co-committed-by: Hartmut Nörenberg <hn@hartmut-noerenberg.com>
2026-05-21 16:28:40 +02:00

47 lines
1.2 KiB
TypeScript

import { ROLE_DEFAULT_PERMISSIONS, SystemRole } from "@nexus/shared";
export const SYSTEM_ROLE_CONFIG_DEFAULTS = [
{
role: SystemRole.ADMIN,
label: "Admin",
description: "Full platform administration and security management.",
color: "purple",
sortOrder: 1,
},
{
role: SystemRole.MANAGER,
label: "Manager",
description: "Operational delivery management across resources, projects, and staffing.",
color: "blue",
sortOrder: 2,
},
{
role: SystemRole.CONTROLLER,
label: "Controller",
description: "Read-heavy planning, resource, and financial oversight.",
color: "amber",
sortOrder: 3,
},
{
role: SystemRole.USER,
label: "User",
description: "Standard authenticated access with self-service capabilities only.",
color: "gray",
sortOrder: 4,
},
{
role: SystemRole.VIEWER,
label: "Viewer",
description: "Restricted read-only access for limited observation scenarios.",
color: "gray",
sortOrder: 5,
},
] as const;
export function buildSystemRoleConfigSeedData() {
return SYSTEM_ROLE_CONFIG_DEFAULTS.map((config) => ({
...config,
defaultPermissions: ROLE_DEFAULT_PERMISSIONS[config.role],
}));
}