-
Notifications
You must be signed in to change notification settings - Fork 0
/
account.html
219 lines (210 loc) · 12.5 KB
/
account.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
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
<!DOCTYPE html>
<html>
<head>
<title>Account Page</title>
<link rel="icon" type="image/png" sizes="32x32" href="images/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="images/favicon-16x16.png">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.1/css/all.min.css">
<script src="https://code.jquery.com/jquery-3.7.0.min.js"></script>
<link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/toastr.js/2.1.4/toastr.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/toastr.js/2.1.4/toastr.min.js"></script>
<meta name="viewport" content="width=device-width, initial-scale=1" />
<link rel="stylesheet" href="css/account.css">
</head>
<body>
<div class="header">
<a id="home-link" href="index.html">
<div class="left-section">
<img class="main-icon" src="icons/xylzicon.png">
<div class="main-title">xylz</div>
</div>
</a>
<div class="middle-section">
<a href="https://www.twitch.tv/xylzlol" target="_blank">
<img src="icons/logo--twitch.svg" alt="Twitch icon" class="twitch-icon">
</a>
<a href="https://www.youtube.com/xylzz" target="_blank">
<img src="icons/logo--youtube.svg" alt="Youtube icon" class="youtube-icon">
</a>
<a href="https://discord.com/invite/HMjWaGh" target="_blank">
<img src="icons/logo--discord.svg" alt="Discord icon" class="discord-icon">
</a>
<a href="https://twitter.com/Xylz97751031" target="_blank">
<img src="icons/logo--twitter.svg" alt="Twitter icon" class="twitter-icon">
</a>
</div>
<div class="right-section">
<button class="button-54" role="button" onclick="window.location.href='legacy.html'">legacy</button>
<button class="button-54" role="button" onclick="window.location.href='/leaderboard.html'">Leaderboard</button>
</div>
<div class="hamburger-menu">
<input type="checkbox" id="checkbox">
<label for="checkbox" class="toggle">
<div class="bar bar--top"></div>
<div class="bar bar--middle"></div>
<div class="bar bar--bottom"></div>
</label>
<ul class="menu">
<li role="button" onclick="window.location.href='/leaderboard.html'">Leaderboard</li>
<li role="button" onclick="window.location.href='/legacy.html'">Legacy</li>
<li role="button" class="loggedOutButtons" onclick="window.location.href='/signin.html'">Sign in</li>
<li role="button" class="loggedOutButtons" onclick="window.location.href='/signup.html'">Sign Up</li>
<li role="button" class="loggedInButton" onclick="window.location.href='/account.html'">Account</li>
</ul>
</div>
</div>
<div class="container mt-5">
<div class="row">
<div class="col-md-6 offset-md-3">
<div class="card">
<div class="admin-button-container">
<p class="h2 ml-4 mt-4">Account details</p>
<button class="admin-button" id="adminPanelBtn" onclick="window.location.href='/admin.html'">
<span>Admin Panel</span>
</button>
</div>
<hr class="my-1">
<div class="card-body">
<div class="d-flex justify-content-between mb-3">
<span><i class="bi bi-person mr-2" style="font-size: 25px;"></i>Username:</span>
<span>
<span id="usernameDisplay"></span>
<span id="adminTag" class="badge badge-primary ml-2" style="display: none;">Admin</span>
</span>
</div>
<div class="d-flex justify-content-between mb-3">
<span><i class="bi bi-calendar-check mr-2"style="font-size: 25px;"></i>Joined:</span>
<span id="joinDateDisplay"></span>
</div>
<!-- Geometry Dash account field -->
<div class="d-flex justify-content-between align-items-center mb-3">
<span><i class="bi bi-controller gd-icon mr-2"style="font-size: 25px;"></i>Geometry Dash Account:</span>
<div class="d-flex align-items-center">
<!-- Display GD Username if available -->
</i></i><span id="gdUsernameDisplay"></span>
<button class="btn btn-primary btn-sm" data-toggle="modal" data-target="#linkGdAccountModal" id="linkGdAccountBtn">Link</button>
<i class="fas bi-globe-europe-africa" id="flagIcon" style="display: none; font-size: 20px;"></i>
<button id="unlinkGdAccountBtn" class="Btn btn-danger btn-sm" style="display: none;">
<i class="bi bi-trash-fill ml-1 mr-3"></i>Unlink
</button>
</div>
</div>
<!-- Geometry Dash records field -->
<div id="gdRecordsField">
<span><i class="bi bi-award gd-icon mr-2"style="font-size: 15px;"></i>Your Records:</span>
<div id="recordLoader" class="loader"></div>
<div id="gdRecordsContainer"></div>
</div>
<!-- Geometry Dash created levels field -->
<div id="gdLevelsField" class="mt-3">
<span><i class="bi bi-card-list gd-icon mr-2"style="font-size: 15px;"></i>Your Levels:</span>
<div id="levelLoader" class="loader"></div>
<div id="gdCreatedLevelsContainer"></div>
</div>
<div class="button-container">
<button type="button" class="edit-button" data-toggle="modal" data-target="#changePasswordModal">
<svg class="edit-svgIcon" viewBox="0 0 512 512">
<path d="M410.3 231l11.3-11.3-33.9-33.9-62.1-62.1L291.7 89.8l-11.3 11.3-22.6 22.6L58.6 322.9c-10.4 10.4-18 23.3-22.2 37.4L1 480.7c-2.5 8.4-.2 17.5 6.1 23.7s15.3 8.5 23.7 6.1l120.3-35.4c14.1-4.2 27-11.8 37.4-22.2L387.7 253.7 410.3 231zM160 399.4l-9.1 22.7c-4 3.1-8.5 5.4-13.3 6.9L59.4 452l23-78.1c1.4-4.9 3.8-9.4 6.9-13.3l22.7-9.1v32c0 8.8 7.2 16 16 16h32zM362.7 18.7L348.3 33.2 325.7 55.8 314.3 67.1l33.9 33.9 62.1 62.1 33.9 33.9 11.3-11.3 22.6-22.6 14.5-14.5c25-25 25-65.5 0-90.5L453.3 18.7c-25-25-65.5-25-90.5 0zm-47.4 168l-144 144c-6.2 6.2-16.4 6.2-22.6 0s-6.2-16.4 0-22.6l144-144c6.2-6.2 16.4-6.2 22.6 0s6.2 16.4 0 22.6z"></path>
</svg>
</button>
<button class="Btn" id="logoutBtn">
<div class="sign"><svg viewBox="0 0 512 512"><path d="M377.9 105.9L500.7 228.7c7.2 7.2 11.3 17.1 11.3 27.3s-4.1 20.1-11.3 27.3L377.9 406.1c-6.4 6.4-15 9.9-24 9.9c-18.7 0-33.9-15.2-33.9-33.9l0-62.1-128 0c-17.7 0-32-14.3-32-32l0-64c0-17.7 14.3-32 32-32l128 0 0-62.1c0-18.7 15.2-33.9 33.9-33.9c9 0 17.6 3.6 24 9.9zM160 96L96 96c-17.7 0-32 14.3-32 32l0 256c0 17.7 14.3 32 32 32l64 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-64 0c-53 0-96-43-96-96L0 128C0 75 43 32 96 32l64 0c17.7 0 32 14.3 32 32s-14.3 32-32 32z"></path></svg></div>
<div class="text">Logout</div>
</button>
</button>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- Remove Record Modal -->
<div class="modal fade" id="removeRecordModal">
<div class="modal-dialog">
<div class="modal-content">
<!-- Modal Header -->
<div class="modal-header">
<h4 class="modal-title" id="removeRecordModalTitle">Remove Record</h4>
<button type="button" class="close" data-dismiss="modal">×</button>
</div>
<!-- Modal body -->
<div class="modal-body">
<p id="removeRecordModalMessage">Are you sure you want to remove this record?</p>
</div>
<!-- Modal footer -->
<div class="modal-footer">
<button type="button" class="btn btn-danger" id="removeRecordModalConfirmBtn">Remove</button>
<button type="button" class="btn btn-secondary" data-dismiss="modal">Cancel</button>
</div>
</div>
</div>
</div>
<!-- Link Geometry Dash Account Modal -->
<div class="modal fade" id="linkGdAccountModal">
<div class="modal-dialog modal-dialog-centered">
<div class="modal-content">
<div class="modal-header">
<h4 class="modal-title">Link Geometry Dash Account</h4>
<button type="button" class="close" data-dismiss="modal">×</button>
</div>
<div class="modal-body">
<form id="linkGdAccountForm">
<div class="form-group" id="gdUsernameSection">
<label for="gdUsername">Geometry Dash Username:</label>
<input type="text" id="gdUsername" class="form-control">
<button type="button" class="btn btn-primary mt-2" id="verifyGdUsernameBtn">Next</button>
</div>
<div class="form-group" style="display:none;" id="verificationInstructionsSection">
<p id="verificationInstructions"></p>
<button type="button" class="btn btn-primary mt-2" id="submitVerificationBtn">Verify</button>
</div>
</form>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-danger" data-dismiss="modal">Close</button>
</div>
</div>
</div>
</div>
<div class="modal fade" id="flagModal">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<h4 class="modal-title">Select a Flag</h4>
<button type="button" class="close" data-dismiss="modal">×</button>
</div>
<div class="modal-body">
<input type="text" id="flagSearch" placeholder="Search for a flag">
<div id="flagContainer">
<!-- List of flags will go here -->
</div>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-danger" data-dismiss="modal">Close</button>
<button type="button" class="btn btn-warning" id="removeFlagBtn">Remove Flag</button>
</div>
</div>
</div>
</div>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js"></script>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.11.2/font/bootstrap-icons.min.css">
<script src='https://unpkg.com/trianglify@^4/dist/trianglify.bundle.js'></script>
<script data-cfasync="false" type="module" src="js/account.js" ></script>
<link rel="stylesheet" href="css/main.css" defer>
<link rel="stylesheet" href="css/header.css" defer>
<script type="module" data-cfasync="false" src="js/authCheck.js" defer></script>
<script>
var pattern = trianglify({
width: window.innerWidth,
height: window.innerHeight,
cellSize: 200, // Adjust this value as needed
xColors: ['#ffb727', '#ff6347', '#75ca4e'], // More contrasting colors
colorFunction: trianglify.colorFunctions.interpolateLinear(0.5),
seed: Math.random().toString(36).substring(7)
});
document.body.style.backgroundImage = 'url(' + pattern.toCanvas().toDataURL() + ')';
document.body.style.backgroundColor = '#ffffff'; // Set a background color
</script>
</body>
</html>