-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
79 lines (79 loc) · 3.34 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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="description" content="Visualization tool for college degree planning">
<meta name="keywords" content="university, college, degree, planner, courses">
<meta name="author" content="Brandon Reponte, Ryan Chen">
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
<link rel="stylesheet" href="index.css">
<title>
Degree Dependencies Visualizer
</title>
</head>
<body>
<!-- User Inputs -->
<div id="topbar">
<div id="user_info">
<label style="font-size:20pt; -webkit-text-fill-color:white">To get started, enter the following information:</label>
<br />
<!-- University Input -->
<div class="input">
<span class="dropdown_label">University:</span>
<select class="dropdown">
<option value="UC San Diego">UC San Diego</option>
<!-- Create more options using JS -->
</select>
</div>
<!-- Major/Minor Input -->
<form class="input">
<span class="dropdown_label">Department:</span>
<input list="depts" id="dptdropdown" name="department">
<datalist id="depts">
<script src="dropdown.js"></script>
</datalist>
<button class="button" id="submit" style="width:100px;margin-left:10px">Generate</button>
<script src="webscrape.js"></script>
</form>
</div>
<div id="altprereqs" class="hidden">
<label style="font-size:14pt; -webkit-text-fill-color:white; margin-top:10px">Alternative Prereqs to the Class:</label>
<div id="altptext">
<!-- Write text using JS -->
</div>
</div>
</div>
<div class="buttons">
<button class="button" id="main_button" style="width:100px">Main</button>
<button class="button" id="upperdiv_button">No Prereq UDs</button>
</div>
<div id="tree_display">
<script src="main.js"></script>
</div>
<script>
document.getElementById("main_button").addEventListener('click', loadMain);
document.getElementById("upperdiv_button").addEventListener('click', loadUpperDiv);
function loadMain() {
removeChildNodes(document.getElementById("tree_display"));
document.getElementById("tree_display").innerHTML = '';
var script = document.createElement('script');
script.src = "main.js";
document.getElementById("tree_display").appendChild(script);
}
function loadUpperDiv() {
removeChildNodes(document.getElementById("tree_display"));
document.getElementById("tree_display").innerHTML = '';
var script = document.createElement('script');
script.src = "upperdiv.js";
document.getElementById("tree_display").appendChild(script);
}
function removeChildNodes(parent) {
while (parent.firstChild) {
parent.removeChild(parent.firstChild);
}
}
</script>
<script src="mouseover.js"></script>
</body>
</html>