Build single scales in core

This commit is contained in:
Tanner Linsley 2015-06-15 23:54:25 -06:00
parent 5759f419c0
commit ef1acfa0e8

View File

@ -121,6 +121,20 @@
this.scales[scale.id] = scale;
}, this);
}
if (this.options.scale) {
// Build radial axes
var ScaleClass = Chart.scaleService.getScaleConstructor(axisOptions.type);
var scale = new ScaleClass({
ctx: this.chart.ctx,
options: axisOptions,
data: this.data,
id: axisOptions.id,
chart: this.chart,
});
this.scale = scale;
}
}
Chart.scaleService.fitScalesForChart(this, this.chart.width, this.chart.height);