diff --git a/compendium-frontend/src/pages/Network/CapacityCoreIP.tsx b/compendium-frontend/src/pages/Network/CapacityCoreIP.tsx index faa850cb55297f284f559d7d1b537d39b70d8bd8..4c49cbe6047420208eb80ff77f517a04e282cfe0 100644 --- a/compendium-frontend/src/pages/Network/CapacityCoreIP.tsx +++ b/compendium-frontend/src/pages/Network/CapacityCoreIP.tsx @@ -40,7 +40,7 @@ function CapacityCoreIPPage() { setFilterSelection={setFilterSelection} /> - const numNrens = filterSelection.selectedNrens.length; + const numNrens = Array.from(new Set(selectedData.map(c => c.nren))).length; const heightPerBar = 1.5; // every added bar should give this much additional height // set a minimum height of 50rem diff --git a/compendium-frontend/src/pages/Network/CapacityLargestLink.tsx b/compendium-frontend/src/pages/Network/CapacityLargestLink.tsx index 09de1c9907b75c366f72b5f23b450aa9bfe34668..d3d7a50d41657007dbeca18e397dc3e07a9e53e4 100644 --- a/compendium-frontend/src/pages/Network/CapacityLargestLink.tsx +++ b/compendium-frontend/src/pages/Network/CapacityLargestLink.tsx @@ -40,7 +40,7 @@ function CapacityLargestLinkPage() { setFilterSelection={setFilterSelection} /> - const numNrens = filterSelection.selectedNrens.length; + const numNrens = Array.from(new Set(selectedData.map(c => c.nren))).length; const heightPerBar = 1.5; // every added bar should give this much additional height // set a minimum height of 50rem diff --git a/compendium-frontend/src/pages/Network/NonRAndEPeer.tsx b/compendium-frontend/src/pages/Network/NonRAndEPeer.tsx index df143fbe76cbd6af4556326304160d2dc37a7f7d..d83768e5baa7c67b5c0b1ece58d79d7bc7bc41bc 100644 --- a/compendium-frontend/src/pages/Network/NonRAndEPeer.tsx +++ b/compendium-frontend/src/pages/Network/NonRAndEPeer.tsx @@ -37,7 +37,7 @@ function NonRAndEPeerPage() { setFilterSelection={setFilterSelection} /> - const numNrens = filterSelection.selectedNrens.length; + const numNrens = Array.from(new Set(selectedData.map(c => c.nren))).length; const heightPerBar = 1.5; // every added bar should give this much additional height // set a minimum height of 50rem diff --git a/compendium-frontend/src/pages/Organization/FundingSource.tsx b/compendium-frontend/src/pages/Organization/FundingSource.tsx index d9c1248c8be7105de3c3044eef0af6242cd5dba4..9d6befe9cfcbe6700a740ede27018d2bcda0ee5b 100644 --- a/compendium-frontend/src/pages/Organization/FundingSource.tsx +++ b/compendium-frontend/src/pages/Organization/FundingSource.tsx @@ -148,7 +148,7 @@ function FundingSourcePage() { setFilterSelection={setFilterSelection} /> - const numNrens = filterSelection.selectedNrens.length; + const numNrens = Array.from(new Set(selectedData.map(c => c.nren))).length; const numYears = filterSelection.selectedYears.length; const heightPerBar = 2; // every added bar should give this much additional height diff --git a/compendium-frontend/src/pages/Organization/StaffGraphAbsolute.tsx b/compendium-frontend/src/pages/Organization/StaffGraphAbsolute.tsx index dec574fb345fa4779841cbd4fb674aaf9aac6922..8e218480d4140d47d5960c99b1e42a95ae79031d 100644 --- a/compendium-frontend/src/pages/Organization/StaffGraphAbsolute.tsx +++ b/compendium-frontend/src/pages/Organization/StaffGraphAbsolute.tsx @@ -38,7 +38,7 @@ function StaffGraphAbsolutePage() { setFilterSelection={setFilterSelection} /> - const numNrens = filterSelection.selectedNrens.length; + const numNrens = Array.from(new Set(selectedData.map(c => c.nren))).length; const heightPerBar = 1.5; // every added bar should give this much additional height // set a minimum height of 50rem diff --git a/compendium-frontend/src/pages/Standards&Policies/CentralProcurement.tsx b/compendium-frontend/src/pages/Standards&Policies/CentralProcurement.tsx index ea02b82afe985b452367587ef0c2b8b66b167170..10093a7e76453019897808cdf7361f98ca827219 100644 --- a/compendium-frontend/src/pages/Standards&Policies/CentralProcurement.tsx +++ b/compendium-frontend/src/pages/Standards&Policies/CentralProcurement.tsx @@ -48,7 +48,7 @@ function CentralProcurementPage() { setFilterSelection={setFilterSelection} /> - const numNrens = filterSelection.selectedNrens.length; + const numNrens = Array.from(new Set(selectedData.map(c => c.nren))).length; const heightPerBar = 1.5; // every added bar should give this much additional height // set a minimum height of 50rem