1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-04-19 01:17:18 +02:00
unleash.unleash/frontend/src/component/project/Project/ProjectStatus/ProjectStatusModal.tsx
Jaanus Sellin 8a507b2eec
feat: connect project health frontend with backend (#8695)
1. Connected project health frontend with backend
2. Synced orval
2024-11-08 10:53:45 +02:00

51 lines
1.5 KiB
TypeScript

import { styled } from '@mui/material';
import { SidebarModal } from 'component/common/SidebarModal/SidebarModal';
import { ProjectResources } from './ProjectResources';
import { ProjectActivity } from './ProjectActivity';
import { ProjectHealth } from './ProjectHealth';
import { ProjectLifecycleSummary } from './ProjectLifecycleSummary';
const ModalContentContainer = styled('div')(({ theme }) => ({
minHeight: '100vh',
backgroundColor: theme.palette.background.default,
padding: theme.spacing(4),
display: 'flex',
flexFlow: 'column',
gap: theme.spacing(4),
}));
type Props = {
open: boolean;
close: () => void;
};
const HealthRow = styled('div')(({ theme }) => ({
display: 'flex',
flexFlow: 'row wrap',
padding: theme.spacing(2),
gap: theme.spacing(2),
'&>*': {
// todo: reconsider this value when the health widget is
// implemented. It may not be right, but it works for the
// placeholder
flex: '30%',
},
}));
export const ProjectStatusModal = ({ open, close }: Props) => {
return (
<SidebarModal open={open} onClose={close} label='Project status'>
<ModalContentContainer>
<HealthRow>
<ProjectHealth />
<ProjectResources />
</HealthRow>
<ProjectActivity />
<ProjectLifecycleSummary />
</ModalContentContainer>
</SidebarModal>
);
};