如何禁用拖动Highcharts注释?找不到任何选项。我试图将pointerEvents: none
添加到chart -> annotations -> labelOptions -> style
,但这没有帮助。
答案 0 :(得分:2)
您可以在注释属性中设置draggable = ""
,
annotations: [{
labels: [{
point: 'max',
text: 'Max'
}],
draggable: ""
}]
演示:
https://jsfiddle.net/BlackLabel/Lqxt3y6m/
或在图表初始化之前添加以下行:
Highcharts.Annotation.prototype.defaultOptions.draggable = '';