-
Notifications
You must be signed in to change notification settings - Fork 1
/
view.html
77 lines (61 loc) · 2.3 KB
/
view.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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="Downloader count manager for geode mods">
<link rel="icon" type="image/png" href="assets/geode-circle.webp">
<title>View Mod</title>
<link rel="stylesheet" href="view.css">
</head>
<script>
var headername = localStorage.getItem('realname');
document.title = headername + " Stats";
</script>
<script>
function saveUserInfo() {
var username = document.querySelector('.avatar img').alt.slice(1);
var avatarUrl = document.querySelector('.avatar img').src;
localStorage.setItem('username', username);
localStorage.setItem('avatarUrl', avatarUrl);
}
</script>
<body>
<div id="background-animation"></div>
<div id="space"></div>
<div id="stats-header"></div>
<p id="downloads1"></p>
<p id="downloads"></p>
<div id="generic-container"></div>
<div id="release-container">
</div>
<div id="comments-container">
<script src="https://utteranc.es/client.js"
repo="BitZGD/BitZGD.github.io"
issue-term="url"
theme="github-dark"
crossorigin="anonymous"
async>
</script>
</div>
<button id="comments-button" onclick="toggleComments()">Comments</button>
<script>
function toggleComments() {
var commentsContainer = document.getElementById("comments-container");
if (commentsContainer.style.display === "none" || commentsContainer.style.display === "") {
commentsContainer.style.display = "block";
saveUserInfo();
} else {
commentsContainer.style.display = "none";
}
}
function saveUserInfo() {
var username = document.querySelector('.avatar img').alt.slice(1);
var avatarUrl = document.querySelector('.avatar img').src;
localStorage.setItem('username', username);
localStorage.setItem('avatarUrl', avatarUrl);
}
</script>
<script src="view.js"></script>
</body>
</html>