-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
48 lines (41 loc) · 1.41 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
<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>Sunburst Home</title>
<link rel="stylesheet" href="styles/homepage.css">
</head>
<body>
<div id="overlay">
<div id="list-parent">
<div class="list-item" style="background:#27ae60;" data-chartid="1">
<p>Sunburst Basic</p>
</div>
<div class="list-item" style="background:tomato;" data-chartid="2">
<p>Sunburst Progress Arcs</p>
</div>
<div class="list-item" style="background:#2980b9" data-chartid="3">
<p>Sunburst with Slicing Animation</p>
</div>
</div>
</div>
<script>
var listItems = document.querySelectorAll('.list-item');
listItems.forEach(item => {
item.addEventListener('click', d => {
var listItem = d.currentTarget;
var chartID = listItem.getAttribute('data-chartid');
switch (chartID) {
case "1":
window.location.href = "sunburst-basic.html";
break;
default:
console.log('nothing found');
break;
}
});
})
</script>
</body>
</html>