From 3734cbd3a4bee7c1b2c2bbe49295ffc2f810ca71 Mon Sep 17 00:00:00 2001 From: gillespi314 <73313222+gillespi314@users.noreply.github.com> Date: Thu, 17 Feb 2022 17:27:29 -0600 Subject: [PATCH] Remove new hosts count from homepage (#4283) --- changes/issue-3285-remove-new-host-count | 1 + frontend/pages/Homepage/Homepage.tsx | 3 --- .../pages/Homepage/cards/HostsStatus/HostsStatus.tsx | 12 ------------ .../pages/Homepage/cards/HostsStatus/_styles.scss | 7 ------- 4 files changed, 1 insertion(+), 22 deletions(-) create mode 100644 changes/issue-3285-remove-new-host-count diff --git a/changes/issue-3285-remove-new-host-count b/changes/issue-3285-remove-new-host-count new file mode 100644 index 0000000000..9de16e8e49 --- /dev/null +++ b/changes/issue-3285-remove-new-host-count @@ -0,0 +1 @@ +* Remove new hosts count from homepage \ No newline at end of file diff --git a/frontend/pages/Homepage/Homepage.tsx b/frontend/pages/Homepage/Homepage.tsx index 89a14e18ea..d29e7c9a9c 100644 --- a/frontend/pages/Homepage/Homepage.tsx +++ b/frontend/pages/Homepage/Homepage.tsx @@ -48,7 +48,6 @@ const Homepage = (): JSX.Element => { const [windowsCount, setWindowsCount] = useState("0"); const [onlineCount, setOnlineCount] = useState(); const [offlineCount, setOfflineCount] = useState(); - const [newCount, setNewCount] = useState(); const [showActivityFeedTitle, setShowActivityFeedTitle] = useState( false ); @@ -88,7 +87,6 @@ const Homepage = (): JSX.Element => { onSuccess: (data: IHostSummary) => { setOnlineCount(data.online_count.toLocaleString("en-US")); setOfflineCount(data.offline_count.toLocaleString("en-US")); - setNewCount(data.new_count.toLocaleString("en-US")); const macHosts = data.platforms?.find( (platform: IHostSummaryPlatforms) => platform.platform === "darwin" ) || { platform: "darwin", hosts_count: 0 }; @@ -147,7 +145,6 @@ const Homepage = (): JSX.Element => { diff --git a/frontend/pages/Homepage/cards/HostsStatus/HostsStatus.tsx b/frontend/pages/Homepage/cards/HostsStatus/HostsStatus.tsx index f933c1c2fa..8c58bfa78b 100644 --- a/frontend/pages/Homepage/cards/HostsStatus/HostsStatus.tsx +++ b/frontend/pages/Homepage/cards/HostsStatus/HostsStatus.tsx @@ -5,7 +5,6 @@ const baseClass = "hosts-status"; interface IHostSummaryProps { onlineCount: string | undefined; offlineCount: string | undefined; - newCount: string | undefined; isLoadingHosts: boolean; showHostsUI: boolean; } @@ -13,7 +12,6 @@ interface IHostSummaryProps { const HostsStatus = ({ onlineCount, offlineCount, - newCount, isLoadingHosts, showHostsUI, }: IHostSummaryProps): JSX.Element => { @@ -45,16 +43,6 @@ const HostsStatus = ({
Offline hosts
-
-
-
- {newCount} -
-
New hosts
-
-
); }; diff --git a/frontend/pages/Homepage/cards/HostsStatus/_styles.scss b/frontend/pages/Homepage/cards/HostsStatus/_styles.scss index 77a64de98d..65480081fd 100644 --- a/frontend/pages/Homepage/cards/HostsStatus/_styles.scss +++ b/frontend/pages/Homepage/cards/HostsStatus/_styles.scss @@ -9,13 +9,6 @@ display: flex; justify-content: center; align-items: center; - - &:first-of-type { - justify-content: flex-end; - } - &:last-of-type { - justify-content: flex-start; - } } &__tile-count {