mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-19 14:33:52 +00:00
20 lines
330 B
TypeScript
20 lines
330 B
TypeScript
import { PermissionNode } from "../types";
|
|
|
|
export const createRoleNode = ({
|
|
subject,
|
|
environment
|
|
}: {
|
|
subject: string;
|
|
environment: string;
|
|
}) => ({
|
|
id: `role-${subject}-${environment}`,
|
|
position: { x: 0, y: 0 },
|
|
data: {
|
|
subject,
|
|
environment
|
|
},
|
|
type: PermissionNode.Role,
|
|
height: 48,
|
|
width: 264
|
|
});
|