INNER CODE UNIT · JavaScript

colorGroupIndex

KeepSafe/dexcount-gradle-plugin · src/main/resources/com/getkeepsafe/dexcount/chart-builder.js:78

        var colorGroupIndex = level == 1 ? i % colors.length :
            level == 2 ? ++parentColorGroupIndex % colors.length : parentColorGroupIndex;
        var colorIndex = level == 1 ? 0 : Math.min(level, colors[colorGroupIndex].length - 1);
        children[i].color = colors[colorGroupIndex][colorIndex];
        decorate(children[i], level, colorGroupIndex)
    }
}

// Main function to draw and set up the visualization, once we have the data.
function createVisualization(data) {
    // Basic setup of page elements.
    initializeBreadcrumbTrail();

    // Bounding circle underneath the sunburst, to make it easier to detect when the mouse leaves the parent g.
    vis.append("svg:circle")
        .attr("r", radius)
        .style("opacity", 0);

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…