Skip to content

Commit

Permalink
fix(18858): Remove special case for generating MCDA axis label (case …
Browse files Browse the repository at this point in the history
…where denominator === area_km2)
  • Loading branch information
albaranau committed Jun 25, 2024
1 parent a6c3995 commit 849910b
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions src/utils/bivariate/labelFormatters.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,6 @@ export const formatBivariateAxisLabel = (quotients: Axis['quotients']): string =
if (!hasUnits(denominator.unit.id)) {
return `${numerator.label} to ${denominator.label} (${numerator.unit.shortName})`;
}
// cases for both units
if (denominator.name === 'area_km2') {
return `${numerator.label} (${numerator.unit.shortName}/${denominator.unit.shortName})`;
}

return `${numerator.label} to ${denominator.label} (${numerator.unit.shortName}/${denominator.unit.shortName})`;
};
Expand All @@ -53,11 +49,6 @@ export const formatBivariateAxisUnit = (quotients: Axis['quotients']): string |
return numerator.unit.shortName;
}

// cases for both units
if (denominator.name === 'area_km2') {
return `${numerator.unit.shortName}/${denominator.unit.shortName}`;
}

return `${numerator.unit.shortName}/${denominator.unit.shortName}`;
};

Expand Down

0 comments on commit 849910b

Please sign in to comment.