1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-10-04 11:17:02 +02:00
unleash.unleash/frontend/src/interfaces/project.ts
Fredrik Strand Oseberg 1c4ba4cc97
Feat/project stats types (#3012)
Update type for project stats
2023-01-27 17:19:27 +01:00

51 lines
1.1 KiB
TypeScript

import { ProjectStatsSchema } from 'openapi';
import { IFeatureToggleListItem } from './featureToggle';
export interface IProjectCard {
name: string;
id: string;
createdAt: string;
health: number;
description: string;
featureCount: number;
memberCount?: number;
favorite?: boolean;
}
export interface IProject {
id?: string;
members: number;
version: string;
name: string;
description?: string;
environments: string[];
health: number;
stats: ProjectStatsSchema;
favorite: boolean;
features: IFeatureToggleListItem[];
}
export interface IProjectHealthReport extends IProject {
staleCount: number;
potentiallyStaleCount: number;
activeCount: number;
updatedAt: string;
}
export interface IPermission {
id: number;
name: string;
displayName: string;
environment?: string;
}
export interface IProjectRolePermissions {
project: IPermission[];
environments: IProjectEnvironmentPermissions[];
}
export interface IProjectEnvironmentPermissions {
name: string;
permissions: IPermission[];
}