-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
63 lines (63 loc) · 1.56 KB
/
index.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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
<!DOCTYPE html>
<html lang="en">
<head>
<title>Interactive Slider - Basic</title>
<meta charset="utf-8" />
<meta
name="viewport"
content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"
/>
<style type="text/css">
body {
background-color: #f0f0f0;
margin: 0px;
overflow: hidden;
height: 100vh;
}
.slider {
width: 500px;
position: relative;
display: inline-block;
}
</style>
<script
type="text/javascript"
src="https://unpkg.com/interactive-slider"
></script>
<!--<script
type="text/javascript"
src="../../dist/interactive-slider.js"
></script>-->
</head>
<body>
<div id="slider" class="slider"></div>
<div id="slider2" class="slider"></div>
<script>
function onChange(event) {
console.log(event);
}
options = {
availability: [
[-0.5, 0.5],
[0.75, 2],
],
min: 0,
max: 1,
onChange: onChange,
};
options2 = {
max: new Date("1998-12-17T03:24:00"),
min: new Date("1995-12-17T03:24:00"),
lower: new Date("1998-12-01T03:24:00"),
availability: [
[new Date("1995-12-17T03:24:00"), new Date("1996-12-17T03:24:00")],
[new Date("1997-12-17T03:24:00"), new Date("1998-12-17T03:24:00")],
],
type: "double",
onChange: onChange,
};
slider("slider", options);
slider("slider2", options2);
</script>
</body>
</html>