MIF_E31230680/public/assetdashboard/vendor/apex/examples/column/basic-column-graph.js

62 lines
1.0 KiB
JavaScript

var options = {
chart: {
height: 350,
type: 'bar',
},
plotOptions: {
bar: {
horizontal: false,
endingShape: 'rounded',
columnWidth: '35%',
},
},
dataLabels: {
enabled: false
},
stroke: {
show: true,
width: 2,
colors: ['transparent']
},
series: [{
name: 'Net Profit',
data: [44, 55, 57, 56, 61, 58, 63, 60, 66]
}, {
name: 'Revenue',
data: [76, 85, 101, 98, 87, 105, 91, 114, 94]
}, {
name: 'Free Cash Flow',
data: [35, 41, 36, 26, 45, 48, 52, 53, 41]
}],
xaxis: {
categories: ['Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct'],
},
yaxis: {
title: {
text: '$ (thousands)'
}
},
fill: {
opacity: 1
},
tooltip: {
y: {
formatter: function(val) {
return "$ " + val + " thousands"
}
}
},
grid: {
row: {
colors: ['#f5f9fe', '#ffffff'], // takes an array which will be repeated on columns
opacity: 0.5
},
},
colors: ['#01902d', '#00bb3a', '#5bca7d'],
}
var chart = new ApexCharts(
document.querySelector("#basic-column-graph"),
options
);
chart.render();