(animate?: boolean)
| 285 | } |
| 286 | |
| 287 | draw(animate?: boolean) { |
| 288 | this.set_ranges(); |
| 289 | this.positionCenter(animate); |
| 290 | |
| 291 | this.d3Pie = d3 |
| 292 | .pie<Slice>() |
| 293 | .startAngle((this.model.get('start_angle') * 2 * Math.PI) / 360) |
| 294 | .endAngle((this.model.get('end_angle') * 2 * Math.PI) / 360) |
| 295 | .value((d: Slice) => { |
| 296 | return d.size; |
| 297 | }); |
| 298 | |
| 299 | if (!this.model.get('sort')) { |
| 300 | this.d3Pie.sort(null); |
| 301 | } |
| 302 | |
| 303 | this.updateSlices(animate); |
| 304 | this.updateLabels(animate); |
| 305 | this.updatePolylines(animate); |
| 306 | } |
| 307 | |
| 308 | private updateSlices(animate?: boolean) { |
| 309 | const that = this; |
no test coverage detected