gpt4 book ai didi

jquery - highstock 中 RangeSelectors 的自定义

转载 作者:行者123 更新时间:2023-11-28 04:22:56 24 4
gpt4 key购买 nike

我想自定义 highstock 图表库中的范围和日期选择器,如提议的设计所示。我想将范围选择器移到左下角,将日期选择器移到右下角,我们可以按照设计中的建议自定义它的外观吗?

enter image description here

最佳答案

您可以根据 margin 和位置的各种组合自定义范围选择器的位置

Fiddle Link用于演示

Highcharts.stockChart('container', {
chart: {
marginBottom: 70 /*marign between chart area and bottom*/
},

title: {
text: 'AAPL stock price by minute'
},

rangeSelector: {
buttons: [{
type: 'hour',
count: 1,
text: '1h'
}, {
type: 'day',
count: 1,
text: '1D'
}, {
type: 'all',
count: 1,
text: 'All'
}],
selected: 1,
padding: 50,
buttonPosition: {
y: 360, /*Position of button from top*/
},

},
navigator: {
top:300, /*Postion of navigator from top*/
},
series: [{
name: 'AAPL',
type: 'candlestick',
data: data,
tooltip: {
valueDecimals: 2
}
}]
});

关于jquery - highstock 中 RangeSelectors 的自定义,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42112194/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com