网页特效栏目收集了最全最新的前端网页插件,包括最流行的jQuery,Bootstrap,Js,Css,Vue等主流特效插件。
Trading是功能丰富的Vue.js图表库,可为交易者生成高度可定制的K线图。
1.安装并导入库。
import TradingVue from 'trading-vue-js'
2.基本用法。
// in your template
<template>
<trading-vue :data="this.$data"></trading-vue>
</template>
export default {
name: 'app',
components: { TradingVue },
data() {
return {
ohlcv: [
// data here
]
}
}
}
3. 默认配置项。
titleTxt: {
type: String,
default: 'TradingVue.js'
},
id: {
type: String,
default: 'trading-vue-js'
},
width: {
type: Number,
default: 800
},
height: {
type: Number,
default: 421
},
colorTitle: {
type: String,
default: '#42b883'
},
colorBack: {
type: String,
default: '#121826'
},
colorGrid: {
type: String,
default: '#2f3240'
},
colorText: {
type: String,
default: '#dedddd'
},
colorTextHL: {
type: String,
default: '#fff'
},
colorScale: {
type: String,
default: '#838383'
},
colorCross: {
type: String,
default: '#8091a0'
},
colorCandleUp: {
type: String,
default: '#23a776'
},
colorCandleDw: {
type: String,
default: '#e54150'
},
colorWickUp: {
type: String,
default: '#23a77688'
},
colorWickDw: {
type: String,
default: '#e5415088'
},
colorWickSm: {
type: String,
default: '#bdbec0'
},
colorVolUp: {
type: String,
default: '#79999e42'
},
colorVolDw: {
type: String,
default: '#ef535042'
},
colorPanel: {
type: String,
default: '#565c68'
},
colorTbBack: {
type: String
},
colorTbBorder: {
type: String,
default: '#8282827d'
},
font: {
type: String,
default: Const.ChartConfig.FONT
},
toolbar: {
type: Boolean,
default: false
},
data: {
type: Object,
required: true
},
// Your overlay classes here
overlays: {
type: Array,
default: function () { return [] }
},
// Overwrites ChartConfig values,
// see constants.js
chartConfig: {
type: Object,
default: function () { return {} }
},
legendButtons: {
type: Array,
default: function () { return [] }
},
indexBased: {
type: Boolean,
default: false
}
转载请注明来源:Vue.js(trading-vue-js)K线图表库组件
本文永久链接地址:https://www.moyouyouw.cn/code/1073.html
郑重声明:本站所有主题/文章除标明原创外,均来自网络转载,版权归原作者所有,如果有侵犯到您的权益,请联系本站删除,谢谢!我们不承担任何技术及版权问题,且不对任何资源负法律责任。
已有 位小伙伴发表了看法
欢迎 你 发表评论