From 35a01a3354ee9e9850512e240e55f46f832c03d7 Mon Sep 17 00:00:00 2001
From: Andreas Ellewsen <ae@uio.no>
Date: Thu, 3 Feb 2022 15:40:04 +0100
Subject: [PATCH] Show number of guests in categories

Resolves: GREG-193
---
 frontend/src/routes/sponsor/frontpage/index.tsx | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/frontend/src/routes/sponsor/frontpage/index.tsx b/frontend/src/routes/sponsor/frontpage/index.tsx
index 4e987e59..68850f8c 100644
--- a/frontend/src/routes/sponsor/frontpage/index.tsx
+++ b/frontend/src/routes/sponsor/frontpage/index.tsx
@@ -217,7 +217,9 @@ const InvitedGuests = ({ persons }: GuestProps) => {
       <StyledAccordionSummary
         expandIcon={<ArrowUpwardIcon sx={{ fill: 'black' }} />}
       >
-        <Typography variant="h2">{t('common:sentInvitations')}</Typography>
+        <Typography variant="h2">
+          {`${t('common:sentInvitations')} (${guests.length})`}
+        </Typography>
       </StyledAccordionSummary>
       <AccordionDetails>
         <Typography variant="body1">
@@ -248,7 +250,9 @@ const ActiveGuests = ({ persons }: GuestProps) => {
       <StyledAccordionSummary
         expandIcon={<ArrowUpwardIcon sx={{ fill: 'black' }} />}
       >
-        <Typography variant="h2">{t('common:activeGuests')}</Typography>
+        <Typography variant="h2">
+          {`${t('common:activeGuests')} (${guests.length})`}
+        </Typography>
       </StyledAccordionSummary>
       <AccordionDetails>
         <Typography variant="body1">
@@ -281,7 +285,7 @@ const WaitingGuests = ({ persons }: GuestProps) => {
         expandIcon={<ArrowUpwardIcon sx={{ fill: 'black' }} />}
       >
         <Typography variant="h2">
-          {t('common:waitingGuests')}{' '}
+          {`${t('common:waitingGuests')} (${guests.length})`}{' '}
           {guests.length > 0 && (
             <NotificationsActiveIcon
               sx={{ color: 'error.main', fontSize: '1.625rem' }}
-- 
GitLab