Update 'covid-speedrun/index.html'
continuous-integration/drone/push Build is passing Details

This commit is contained in:
Han Dai 2022-08-21 22:21:41 +00:00
parent 23f9c2e2e7
commit ca5e93ed2c
1 changed files with 127 additions and 118 deletions

View File

@ -1,7 +1,7 @@
<html> <html>
<head> <head>
<title>Han's Covid Speedrun Record</title> <title>Han's Covid Speedrun Record</title>
<meta charset="UTF-8"> <meta charset="UTF-8">
<style> <style>
@ -30,9 +30,9 @@
background-color: #333; background-color: #333;
} }
</style> </style>
</head> </head>
<body> <body>
<table width="100%" height="100%"> <table width="100%" height="100%">
<tbody> <tbody>
<tr> <tr>
@ -41,13 +41,15 @@
<h1>Han's Covid Speedrun Record</h1> <h1>Han's Covid Speedrun Record</h1>
<h2>Any% - Omicron Variant</h2> <h2>Any% - Omicron Variant</h2>
<h4>(Started at 5:51pm EDT on Aug 17 2022)</h4> <h4>(Started at 5:51pm EDT on Aug 17 2022)</h4>
<table id="speedrun"> <table>
<tbody id="speedrun">
<tr> <tr>
<th>Checkpoint</th> <th>Checkpoint</th>
<th>Time</th> <th>Time</th>
</tr> </tr>
</tbody>
<tbody id="final"></tbody>
</table> </table>
<table><tbody><tr><td style="color: rgb(0, 255, 0);font-size: 30px;text-align: right;">🏆 3d 23:59:47.180</td></tr></tbody></table>
</center> </center>
</td> </td>
</tr> </tr>
@ -55,6 +57,7 @@
</table> </table>
<script> <script>
var table = document.getElementById("speedrun"); var table = document.getElementById("speedrun");
var final = document.getElementById("final");
var timeline = { // I actually can't recall that much detail so this is just a rough estimate var timeline = { // I actually can't recall that much detail so this is just a rough estimate
"Possible Exposure": new Date("Aug 14, 2022 22:00:00"), "Possible Exposure": new Date("Aug 14, 2022 22:00:00"),
@ -99,7 +102,13 @@
// Win // Win
cell1.innerHTML = "Tested Negative!"; cell1.innerHTML = "Tested Negative!";
cell2.innerHTML = timeSince(new Date("Aug 21, 2022 17:50:57.303") - timeline["First Positive"]); cell2.innerHTML = timeSince(new Date("Aug 21, 2022 17:50:57.303") - timeline["First Positive"]);
var row = final.insertRow();
var cell = row.insertCell(0);
cell.colSpan = 2;
cell.innerHTML = "🏆 3d 23:59:47.180";
cell.style.color = "#00ff00";
cell.style.fontSize = "30px";
cell.style.textAlign = "right";
function timeSince(timestamp) { function timeSince(timestamp) {
var sign = "+"; var sign = "+";
@ -120,6 +129,6 @@
return sign + String(d).padStart(2, '0') + "d " + String(h).padStart(2, '0') + ":" + String(m).padStart(2, '0') + ":" + String(s).padStart(2, '0') + "." + String(ms).padStart(3, '0'); return sign + String(d).padStart(2, '0') + "d " + String(h).padStart(2, '0') + ":" + String(m).padStart(2, '0') + ":" + String(s).padStart(2, '0') + "." + String(ms).padStart(3, '0');
} }
</script> </script>
</body> </body>
</html> </html>