forked from comp426-2022-spring/a99-izar
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmainScreen.html
175 lines (158 loc) · 7.98 KB
/
mainScreen.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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<script src="https://cdn.anychart.com/releases/8.0.0/js/anychart-base.min.js"></script>
<script src="https://cdn.anychart.com/releases/8.0.0/themes/dark_earth.min.js" type="text/javascript"></script>
<title>Document</title>
</head>
<body>
<script>
document.addEventListener("DOMContentLoaded", function () {
var logoutButton = document.createElement('div');
logoutButton.innerHTML = 'Logout';
logoutButton.style.position = 'absolute';
logoutButton.style.top = '15px';
logoutButton.style.right = '15px';
logoutButton.style.padding = '10px';
logoutButton.style.Color = '#FFE08A';
logoutButton.style.backgroundColor = 'rgba(0,0,0,0.5)';
logoutButton.style.cursor = 'pointer';
logoutButton.onclick = function () {
alert('Logout clicked');
};
document.body.appendChild(logoutButton);
logoutButton.style.backgroundColor = 'rgba(0,0,0,0.5)';
logoutButton.style.backgroundColor = 'rgba(0,0,0,0.5)';
logoutButton.style.Color = '#FFE08A';
logoutButton.style.border = '1px solid #999';
logoutButton.style.borderRadius = '4px';
logoutButton.style.fontFamily = 'sans-serif';
logoutButton.style.fontSize = '14px';
logoutButton.style.padding = '8px';
logoutButton.style.textAlign = 'center';
logoutButton.style.width = '80px';
var left = document.createElement('div');
left.style.backgroundColor = '#CCC';
left.style.float = 'left';
left.style.width = '50%';
left.style.height = '100%';
document.body.appendChild(left);
var right = document.createElement('div');
right.style.backgroundColor = '#FFE08A';
right.style.float = 'left';
right.style.width = '50%';
right.style.height = '100%';
document.body.appendChild(right);
var statisticsLabel = document.createElement('div');
statisticsLabel.innerHTML = 'Statistics';
statisticsLabel.style.fontFamily = 'sans-serif';
statisticsLabel.style.fontSize = '24px';
statisticsLabel.style.padding = '20px';
left.appendChild(statisticsLabel);
var settingsLabel = document.createElement('div');
settingsLabel.innerHTML = 'Settings';
settingsLabel.style.fontFamily = 'sans-serif';
settingsLabel.style.fontSize = '24px';
settingsLabel.style.padding = '20px';
right.appendChild(settingsLabel);
var stateDropdown = document.createElement('select');
stateDropdown.style.fontFamily = 'sans-serif';
stateDropdown.style.fontSize = '14px';
stateDropdown.style.padding = '8px';
stateDropdown.style.margin = '8px';
var states = ['Alabama', 'Alaska', 'Arizona', 'Arkansas', 'California', 'Colorado', 'Connecticut', 'Delaware', 'Florida', 'Georgia', 'Hawaii', 'Idaho', 'Illinois', 'Indiana', 'Iowa', 'Kansas', 'Kentucky', 'Louisiana', 'Maine', 'Maryland', 'Massachusetts', 'Michigan', 'Minnesota', 'Mississippi', 'Missouri', 'Montana', 'Nebraska', 'Nevada', 'New Hampshire', 'New Jersey', 'New Mexico', 'New York', 'North Carolina', 'North Dakota', 'Ohio', 'Oklahoma', 'Oregon', 'Pennsylvania', 'Rhode Island', 'South Carolina', 'South Dakota', 'Tennessee', 'Texas', 'Utah', 'Vermont', 'Virginia', 'Washington', 'West Virginia', 'Wisconsin', 'Wyoming'];
for (var i = 0; i < states.length; i++) {
var option = document.createElement('option');
option.innerHTML = states[i];
stateDropdown.appendChild(option);
}
$("#statesdropdown").change(function(){
stateDropdown = $(this).val();
});
left.appendChild(stateDropdown);
var updateEmailLabel = document.createElement('div');
updateEmailLabel.innerHTML = 'Update Email';
updateEmailLabel.style.fontFamily = 'sans-serif';
updateEmailLabel.style.fontSize = '14px';
updateEmailLabel.style.padding = '8px';
updateEmailLabel.style.margin = '8px';
right.appendChild(updateEmailLabel);
var emailInput = document.createElement('input');
emailInput.type = 'text';
emailInput.style.fontFamily = 'sans-serif';
emailInput.style.fontSize = '14px';
emailInput.style.padding = '8px';
emailInput.style.margin = '8px';
right.appendChild(emailInput);
var updatePasswordLabel = document.createElement('div');
updatePasswordLabel.innerHTML = 'Update Password';
updatePasswordLabel.style.fontFamily = 'sans-serif';
updatePasswordLabel.style.fontSize = '14px';
updatePasswordLabel.style.padding = '8px';
updatePasswordLabel.style.margin = '0px';
right.appendChild(updatePasswordLabel);
var passwordInput = document.createElement('input');
passwordInput.type = 'password';
passwordInput.style.fontFamily = 'sans-serif';
passwordInput.style.fontSize = '14px';
passwordInput.style.padding = '8px';
passwordInput.style.margin = '8px';
right.appendChild(passwordInput);
var submitButton = document.createElement('div');
submitButton.innerHTML = 'Submit';
submitButton.style.fontFamily = 'sans-serif';
submitButton.style.fontSize = '14px';
submitButton.style.padding = '8px';
submitButton.style.margin = '8px';
submitButton.style.width='100px';
submitButton.style.backgroundColor = 'rgba(0,0,0,0.5)';
submitButton.style.border = '1px solid #999';
submitButton.style.borderRadius = '4px';
submitButton.style.cursor = 'pointer';
submitButton.onclick = function () {
alert('Submit clicked');
};
right.appendChild(submitButton);
var deleteAccountButton = document.createElement('div');
deleteAccountButton.innerHTML = 'Delete Account';
deleteAccountButton.style.fontFamily = 'sans-serif';
deleteAccountButton.style.fontSize = '14px';
deleteAccountButton.style.padding = '8px';
deleteAccountButton.style.margin = '8px';
deleteAccountButton.style.width='100px';
deleteAccountButton.style.backgroundColor = 'rgba(0,0,0,0.5)';
deleteAccountButton.style.border = '1px solid #999';
deleteAccountButton.style.borderRadius = '4px';
deleteAccountButton.style.cursor = 'pointer';
deleteAccountButton.onclick = function () {
alert('Delete Account clicked');
};
right.appendChild(deleteAccountButton);
});
</script>
<!-- <script>
anychart.onDocumentReady(function(){
anychart.theme(anychart.themes.darkEarth);
var data={
header: ["Name","Death toll"],
rows:[
["San-Francisco (1906)", 1500],
["Messina (1908)", 87000],
["Ashgabat (1948)", 175000],
["Chile (1960)", 10000],
["Tian Shan (1976)", 242000],
["Armenia (1988)", 25000],
["Iran (1990)", 50000]
]};
var chart=anychart.column();
chart.data(data);
chart.title("The deadliest earthquakes in the XXth century");
chart.container("container");
chart.draw();
});
</script> -->
</body>
</html>