当我在样条图表上更改'visible:false'属性时,Highcharts似乎会崩溃Chrome。如果我将所有可见标志设置为相同的东西,Chrome似乎没问题。
Firefox中不会出现此问题
这是highcharts中的错误吗?
演示在这里:
$(function () {
$('#weeklyRevenue').highcharts({
chart: {
type: 'spline'
},
xAxis: {
type: 'datetime'
},
series: [{name: 'George Street', data: [[Date.UTC(2013, 5, 3), 5.4]], visible:true}, {name: 'Marrickville', data: [[Date.UTC(2013, 4, 20), 4.5],[Date.UTC(2013, 5, 10), 23.7],[Date.UTC(2013, 5, 17), 33.6]], visible:false}, {name: 'Liverpool Street', data: [[Date.UTC(2013, 4, 27), 7.3],[Date.UTC(2013, 5, 3), 10.7],[Date.UTC(2013, 5, 10), 6.8]], visible:false}, {name: 'Moving Average', dashStyle: 'ShortDash', marker:{enabled:false}, data: [[Date.UTC(2013, 5, 3), 5.4]], visible:true}]
});
});
答案 0 :(得分:0)
你应该替换它:
[Date.UTC(2013, 5, 3), 5.4]], visible:true}
与
{x:Date.UTC(2013, 5, 3), y: 5.4, visible:true}