From f7f8ddcd7ca18ca4a1a6688c69766f275871a0a8 Mon Sep 17 00:00:00 2001 From: Jay Sitter Date: Fri, 16 Jun 2023 21:44:45 -0400 Subject: [PATCH] fix: Add total users in site sidebar --- src/shared/components/common/badges.tsx | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/src/shared/components/common/badges.tsx b/src/shared/components/common/badges.tsx index 56390342..858b9864 100644 --- a/src/shared/components/common/badges.tsx +++ b/src/shared/components/common/badges.tsx @@ -79,6 +79,22 @@ export const Badges = ({ counts, community_view }: BadgesProps) => { })}{" "} / {i18n.t("number_of_months", { count: 6, formattedCount: 6 })} + {isSiteAggregates(counts) && ( + <> +
  • + {i18n.t("number_of_users", { + count: Number(counts.users), + formattedCount: numToSI(counts.users), + })} +
  • +
  • + {i18n.t("number_of_communities", { + count: Number(counts.communities), + formattedCount: numToSI(counts.communities), + })} +
  • + + )} {isCommunityAggregates(counts) && (
  • {i18n.t("number_of_subscribers", { @@ -87,14 +103,6 @@ export const Badges = ({ counts, community_view }: BadgesProps) => { })}
  • )} - {isSiteAggregates(counts) && ( -
  • - {i18n.t("number_of_communities", { - count: Number(counts.communities), - formattedCount: numToSI(counts.communities), - })} -
  • - )}
  • {i18n.t("number_of_posts", { count: Number(counts.posts),