Repository navigation
Expand file tree
/
Copy pathindex.html
More file actions
185 lines (184 loc) · 6.02 KB
/
Copy pathindex.html
File metadata and controls
185 lines (184 loc) · 6.02 KB
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Debate Clock</title>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100..900;1,100..900&display=swap" rel="stylesheet">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/7.0.1/css/all.min.css" integrity="sha512-2SwdPD6INVrV/lHTZbO2nodKhrnDdJK9/kg2XD1r9uGqPo1cUbujc+IYdlYdEErWNu69gVcYgdxlmVmzTWnetw==" crossorigin="anonymous" referrerpolicy="no-referrer" />
<style>
@font-face {
font-family: '7Seg';
size-adjust: 80%;
unicode-range: U+002D, U+0030-003A;
src: url('segment-eglas.otf') format('opentype');
}
:root {
--barcolor: #ff8888;
--timercolor: black;
--percent: 0%;
--totalpercent: 0%;
}
html, body {
width: 100%;
height: 100%;
margin: 0;
padding: 0;
font-family: "Roboto", sans-serif;
font-optical-sizing: auto;
font-weight: 400;
font-style: normal;
font-variation-settings: "wdth" 100;
background: white;
color: black;
overflow: wrap;
}
.wrapper { /* Useless IMO */
height: 100%;
}
.main {
height: 100%;
font-size: 15em;
font-weight: 800;
text-align: center;
display: flex;
justify-content: center;
align-items: center;
cursor: pointer;
}
.main.style-7seg {
font-family: '7Seg', monospace;
}
.main.style-roboto { /* default atm */
font-family: 'Roboto', sans-serif;
}
.main.paused {
color: grey;
}
.main.negative {
color: #500000;
}
.header {
border-bottom: solid 10px;
border-image: linear-gradient(to left, var(--timercolor) var(--totalpercent), white var(--totalpercent), white 100%) 1;
text-align: center;
position: absolute;
top: 0;
width: 100%;
}
.header p {
font-size: 4vw;
font-weight: 800;
margin: 15px;
}
.header p:before {
content: attr(data-text);
position: absolute;
left: 3px;
top: 3px;
opacity: 1;
}
.footer {
display: flex;
flex-direction: row;
flex-wrap: wrap;
position: absolute;
bottom: 0;
width: 100%;
text-align: center;
justify-content: center;
}
.footer .button {
display: inline-block;
border: solid 4px black;
border-bottom-width: 10px;
padding: 5px;
font-size: 4vw;
line-height: 1em;
width: 10vw;
margin: 0 5px 10px;
cursor: pointer;
}
.footer .button.icon {
display: flex;
justify-content: center;
align-items: center;
}
@media (max-width: 55em) {
.main {
font-size: 25vw;
}
.header p {
font-size: 2em;
}
.footer .button {
font-size: 2em;
width: 70px;
}
}
.header.progress {
background: linear-gradient(to left, var(--barcolor) var(--percent), white var(--percent) /* middle thing is for gradient width*/, white 100%);
}
.footer .progress {
background: linear-gradient(to left, var(--barcolor) var(--totalpercent), white var(--totalpercent) /* middle thing is for gradient width*/, white 100%);
}
.footer .warning {
background: rgb(255, 255, 70);
}
.noselect {
-moz-user-select: -moz-none;
user-select: none;
}
.hidden {
display: none;
}
.modal {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
opacity: 90%;
width: 60vw;
max-height: 80vh;
overflow: auto;
animation: transform 0.3s ease-out, opacity 0.3s ease-out;
box-shadow: 0px 0px 5px black;
background: white;
padding: 20px;
z-index: 10;
}
.modal.hidden {
transform: translate(-50%, -50%-100vh);
opacity: 0%;
}
.modal * {
text-align: center;
}
</style>
</head>
<body>
<div class="wrapper hidden">
<div id="settings" class="modal hidden">
<h1>Timer Settings</h1>
<input type="checkbox" id="font"><label for="font">7-Segment Font</label>
</div>
<div id="hud" class="header progress">
<p>#<span id="number"></span> - <span id="status"></span></p>
</div>
<div id="clock" class="main paused">
<p id="time"></p>
</div>
<div id="menu" class="footer">
<span id="fullscreen" class="icon button"><i class="fa-solid fa-expand"></i></span>
<span id="menubookmark" class="hidden"></span><!--placeholder where the actual buttons go-->
<!--span id="settings" class="icon button"><i class="fa-solid fa-gear"></i></span-->
</div>
</div>
<script src="script.js"></script>
<!--script type="text/typescript" src="script.ts"></script-->
<script src="https://unpkg.com/typescript@5.9.3/lib/typescript.js"></script>
<!--script src="https://raw.githack.com/basarat/typescript-script/master/transpiler.js"></script-->
</body>
</html>