-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
88 lines (73 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
80
81
82
83
84
85
86
87
88
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-giJF6kkoqNQ00vy+HMDP7azOuL0xtbfIcaT9wjKHr8RbDVddVHyTfAAsrekwKmP1" crossorigin="anonymous">
<script src="/socket.io/socket.io.js"></script>
<script src="https://code.jquery.com/jquery-3.4.1.min.js"></script>
<style type="text/css">
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
-webkit-appearance: none;
margin: 0;
}
#center_div {
text-align: center;
margin: auto;
width: 50%;
}
@media screen and (max-width:540px) {
#center_div {
text-align: center;
margin: auto;
width: 80%;
}
}
img {
max-height: 100%;
display: block; /* remove extra space below image */
/* filter: invert(1%) sepia(1%) saturate(1%) hue-rotate(1deg) brightness(1000%) contrast(80%); */
}
.footer {
position: fixed;
left: 0;
bottom: 0;
width: 100%;
text-align: center;
color: white;
}
body {
background: rgb(0,101,255);
background: linear-gradient(0deg, rgba(0,101,255,1) 0%, rgba(0,212,255,1) 100%);
}
</style>
<script src="/client.js"></script>
</head>
<body>
<div id="center_div">
<h1 style="font-size: 50px; padding-top: 25px; color: white;">MathRacer</h1>
<h2 style="font-size: 25px; padding-bottom: 25px; color: white;">Matematik ræs online!</h2>
<h1 id="countdownLabel" hidden style="font-size: 50px; margin: 25px; color: white;">?</h1>
<div id="usernameBox" style="margin: auto; background-color: white; width: 100%; padding: 5px; border-radius: 25px;">
<ul id="messages"></ul>
<div id="usernameDiv" style="text-align: center; width: 100%; margin: auto;">
<label for="usernameInput" class="form-label">Username</label>
<input type="text" class="form-control" id="usernameInput" placeholder="Username">
<button id="setUsernameBtn" class="btn btn-primary" style="margin: 10px;">Join!</button>
</div>
</div>
<div id="equationBox" hidden style="margin: auto; margin-top: 25px; width: 100%;">
<h1 id="equationLabel" style="color: white;">Loading...</h1>
</div>
<div id="inputContainer" hidden style="margin: auto; margin-top: 25px; width: 100%;" class="input-group mb-3">
<input id="resultInput" type="number" class="form-control" placeholder="Regnestykke Resultat" aria-label="Resultat" aria-describedby="basic-addon2">
<div class="input-group-append">
<button id="checkButton" class="btn btn-success" type="button">Enter</button>
</div>
</div>
<div id="gameContainer" hidden style="margin: auto; margin-top: 25px; background-color: white; width: 100%; padding: 5px; border-radius: 25px;">
<div id="playerContainer"></div>
</div>
</div>
<footer class="footer">
Made by Hjalte, Malte & Mathilde | Open-source on <a target="_blank" style="color: black;" href="https://github.com/HLVM04/MathRacer">GitHub!</a>
</footer>
</body>