src/charts/donut.js
/**
         * Draws the slices of the donut
         * @private
         */
Draws the slices of the donut
@private
Draws the slices of the donut @private
function drawSlices() {
            if (!slices) {
                slices = svg.select('.chart-group')
                    .selectAll('g.arc')
                    .data(layout(data));
                slices.enter()
                  .append('g')
                    .each(storeAngle)
                    .each(reduceOuterRadius)
                    .classed('arc', true)
                    .on('mouseover', handleMouseOver)
                    .on('mouseout', handleMouseOut)
                .merge(slices)
                  .append('path')
                    .attr('fill', getSliceFill)
                    .on('mouseover', tweenGrowthFactory(externalRadius, 0))
                    .on('mouseout', tweenGrowthFactory(externalRadius - radiusHoverOffset, pieHoverTransitionDuration))
                    .transition()
                    .ease(ease)
                    .duration(pieDrawingTransitionDuration)
                    .attrTween('d', tweenLoading);
            } else {
                slices = svg.select('.chart-group')
                    .selectAll('path')
                    .data(layout(data));
                slices
                    .attr('d', shape);
                slices
                    .transition()
                    .duration(arcTransitionDuration)
                    .attrTween('d', tweenArc);
            }
        }
function drawSlices ( ) { if ( ! slices ) { slices = svg . select ( '.chart-group' ) . selectAll ( 'g.arc' ) . data ( layout ( data ) ) ; slices . enter ( ) . append ( 'g' ) . each ( storeAngle ) . each ( reduceOuterRadius ) . classed ( 'arc' , true ) . on ( 'mouseover' , handleMouseOver ) . on ( 'mouseout' , handleMouseOut ) . merge ( slices ) . append ( 'path' ) . attr ( 'fill' , getSliceFill ) . on ( 'mouseover' , tweenGrowthFactory ( externalRadius , 0 ) ) . on ( 'mouseout' , tweenGrowthFactory ( externalRadius - radiusHoverOffset , pieHoverTransitionDuration ) ) . transition ( ) . ease ( ease ) . duration ( pieDrawingTransitionDuration ) . attrTween ( 'd' , tweenLoading ) ; } else { slices = svg . select ( '.chart-group' ) . selectAll ( 'path' ) . data ( layout ( data ) ) ; slices . attr ( 'd' , shape ) ; slices . transition ( ) . duration ( arcTransitionDuration ) . attrTween ( 'd' , tweenArc ) ; } }
Draws the slices of the donut
 @private
Draws the slices of the donut @private
// Redraws the angles of the data