-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathweekends.html
41 lines (41 loc) · 1.29 KB
/
weekends.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<html>
<head>
<title>Yagr</title>
<script src="../../dist/yagr.iife.js"></script>
<script src="../../dist/plugins/weekends/weekends.iife.js"></script>
<link rel="stylesheet" href="../../dist/index.css" />
<style>
.container {
margin-bottom: 26px;
height: 350px;
width: 100%;
}
.grid {
height: 350px;
display: flex;
width: 100%;
flex-direction: row;
justify-content: space-between;
}
</style>
</head>
<body>
<h1>Weekends plugin</h1>
<div class="grid">
<div id="chart1" class="container"></div>
</div>
<script>
const y1 = new Yagr(chart1, {
timeline: new Array(500).fill().map((_, i) => i * 5000000),
series: [{data: new Array(500).fill().map((_, i) => Math.random() * 6), color: 'red'}],
scales: {y: {min: 0, max: 6}},
chart: {
appearance: {
drawOrder: ['plotLines', 'series', 'axes'],
},
},
plugins: [WeekendsPlugin()],
});
</script>
</body>
</html>