Skip to content
Snippets Groups Projects
Commit 158dff6b authored by Bjarke Madsen's avatar Bjarke Madsen
Browse files

Fix graph sizes according to NRENs in selected data instead of the number of selected NRENs

parent fe977806
Branches
Tags
No related merge requests found
......@@ -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
......
......@@ -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
......
......@@ -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
......
......@@ -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
......
......@@ -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
......
......@@ -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
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment