<!-- Faraday Penetration Test IDE -->
<!-- Copyright (C) 2013  Infobyte LLC (http://www.infobytesec.com/) -->
<!-- See the file 'doc/LICENSE' for the license information -->

<div ng-controller="vulnsPiechartCtrl">
    <article id='cake' class='panel m0' ng-class="{'height-auto': loaded === true && data.value.length === 0}">
        <header>
            <h2>Vulnerabilities
                <span class="glyphicon glyphicon-info-sign" uib-tooltip="Vulnerability distribution for current WS"></span>
            </h2>
        </header>
        <span id="cakeText"></span>
        <div ng-if="loaded && data.value.length === 0" class="no-info-overlay">
            <p class="no-info-text">No vulnerabilities found yet.</p>
        </div>
        <div id="doughnut" ng-if="loaded && data.value.length !== 0">
            <canvas id="doughnut" class="chart chart-doughnut" chart-data="data.value" chart-labels="data.key"
            chart-colours="data.colors" chart-options="data.options"></canvas>
        </div>
    </article>
</div>
