in src/radarChart.ts [1250:1278]
private updateViewport(): void {
let legendMargins: IViewport = this.legend.getMargins(),
legendPosition: LegendPosition;
legendPosition = LegendPosition[this.legendObjectProperties[legendProps.position] as string];
switch (legendPosition) {
case LegendPosition.Top:
case LegendPosition.TopCenter:
case LegendPosition.Bottom:
case LegendPosition.BottomCenter: {
this.viewport.height = Math.max(
this.viewport.height - legendMargins.height,
RadarChart.MinViewport.height);
break;
}
case LegendPosition.Left:
case LegendPosition.LeftCenter:
case LegendPosition.Right:
case LegendPosition.RightCenter: {
this.viewport.width = Math.max(
this.viewport.width - legendMargins.width,
RadarChart.MinViewport.width);
break;
}
}
}