81 lines
1.8 KiB
HTML
81 lines
1.8 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
|
<title>Area Spline</title>
|
|
|
|
<link href="../../assets/styles.css" rel="stylesheet" />
|
|
|
|
<style>
|
|
#chart {
|
|
max-width: 650px;
|
|
margin: 35px auto;
|
|
}
|
|
</style>
|
|
</head>
|
|
|
|
<body>
|
|
<div id="chart">
|
|
<apexchart type=area height=350 :options="chartOptions" :series="series" />
|
|
</div>
|
|
|
|
<!-- Below element is just for displaying source code. it is not required. DO NOT USE -->
|
|
<div id="html">
|
|
<div id="chart">
|
|
<apexchart type=area height=350 :options="chartOptions" :series="series" />
|
|
</div>
|
|
</div>
|
|
|
|
<script src="https://unpkg.com/vue/dist/vue.js"></script>
|
|
<script src="https://cdn.jsdelivr.net/npm/apexcharts@latest"></script>
|
|
<script src="https://cdn.jsdelivr.net/npm/vue-apexcharts"></script>
|
|
|
|
<script>
|
|
new Vue({
|
|
el: '#chart',
|
|
components: {
|
|
apexchart: VueApexCharts,
|
|
},
|
|
data: {
|
|
series: [{
|
|
name: 'series1',
|
|
data: [31, 40, 28, 51, 42, 109, 100]
|
|
}, {
|
|
name: 'series2',
|
|
data: [11, 32, 45, 32, 34, 52, 41]
|
|
}],
|
|
chartOptions: {
|
|
dataLabels: {
|
|
enabled: false
|
|
},
|
|
stroke: {
|
|
curve: 'smooth'
|
|
},
|
|
|
|
|
|
xaxis: {
|
|
type: 'datetime',
|
|
categories: ["2018-09-19T00:00:00", "2018-09-19T01:30:00", "2018-09-19T02:30:00",
|
|
"2018-09-19T03:30:00", "2018-09-19T04:30:00", "2018-09-19T05:30:00",
|
|
"2018-09-19T06:30:00"
|
|
],
|
|
},
|
|
tooltip: {
|
|
x: {
|
|
format: 'dd/MM/yy HH:mm'
|
|
},
|
|
|
|
}
|
|
}
|
|
|
|
}
|
|
|
|
})
|
|
</script>
|
|
|
|
</body>
|
|
|
|
</html> |