From 9c9bc0d76137708cf067026b10131b8ed9f69898 Mon Sep 17 00:00:00 2001 From: e-for-eshaan Date: Thu, 16 May 2024 17:36:18 +0530 Subject: [PATCH 1/5] fixes spacing for team-cards for a single team --- web-server/src/components/TeamsList.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web-server/src/components/TeamsList.tsx b/web-server/src/components/TeamsList.tsx index 12014dc7c..a3e3868a3 100644 --- a/web-server/src/components/TeamsList.tsx +++ b/web-server/src/components/TeamsList.tsx @@ -76,7 +76,7 @@ export const TeamsList = () => { gap={4} grid gridTemplateColumns={'1fr 1fr'} - maxWidth={'900px'} + width={'900px'} relative sx={{ filter: isLoadingTeams ? 'blur(2px)' : 'none', From 3c3a18e0896fbd732b399b34195aee40b30bedf9 Mon Sep 17 00:00:00 2001 From: e-for-eshaan Date: Thu, 16 May 2024 17:47:16 +0530 Subject: [PATCH 2/5] fixes spacings, and dims the integration heading on DORA-CTA --- web-server/pages/integrations.tsx | 22 +++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/web-server/pages/integrations.tsx b/web-server/pages/integrations.tsx index 26cbad1b4..d449e5b45 100644 --- a/web-server/pages/integrations.tsx +++ b/web-server/pages/integrations.tsx @@ -1,6 +1,6 @@ import { Add } from '@mui/icons-material'; import { Button, Divider } from '@mui/material'; -import { useEffect } from 'react'; +import { useEffect, useMemo } from 'react'; import { Authenticated } from 'src/components/Authenticated'; import { FlexBox } from '@/components/FlexBox'; @@ -80,13 +80,25 @@ const Content = () => { } }, [dispatch, isGithubIntegrated, loadedTeams.true, orgId, teamCount]); + const showDoraCTA = useMemo( + () => Boolean(teamCount) && Boolean(hasCodeProviderLinked), + [hasCodeProviderLinked, teamCount] + ); + return ( - - + + Integrate your Github to fetch DORA for your team - {Boolean(teamCount) && Boolean(hasCodeProviderLinked) && ( + {showDoraCTA && ( @@ -144,7 +150,7 @@ const SearchFilter: FC<{ sx={{ width: '100%' }} variant="contained" > - + Continue to Dora {'->'} @@ -161,6 +167,11 @@ const SearchFilter: FC<{ ); }; +type TeamCardProps = { + team: Team; + onEdit: () => void; +}; + const TeamCard: React.FC = ({ team, onEdit }) => { const { name: teamName, id: teamId } = team; const teamReposMap = useSelector((state) => state.team.teamReposMaps);