我有一個(gè)餅圖,其功能現(xiàn)在可以正常工作。問(wèn)題在于它的顯示。當(dāng)我將鼠標(biāo)懸停在餅圖的一個(gè)部分上時(shí),餅圖的其他部分的不透明度變低。如下所示我的腳本在這里:<script type="text/javascript">var data = <?php echo json_encode($json_data) ?>data.forEach(function(el) {el.name = el.label;el.y = Number(el.value);});Highcharts.chart('userpie', {chart: { plotBackgroundColor: null, plotBorderWidth: null, plotShadow: false, type: 'pie'},title: { text: undefined},credits: { enabled: false},exporting: { enabled: false } ,tooltip: { pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>'},plotOptions: { pie: { allowPointSelect: true, cursor: 'pointer', showInLegend: true, dataLabels: { enabled: true, format: '<b>{point.name}</b>: {point.percentage:.1f} %', style: { color: (Highcharts.theme && Highcharts.theme.contrastTextColor) || 'black' } } }},series: [{ name: 'Users', colorByPoint: true, data: data}]});</script>我在想什么嗎?請(qǐng)幫忙。提前致謝
添加回答
舉報(bào)
0/150
提交
取消