diff options
author | RaindropsSys <raindrops@equestria.dev> | 2023-11-18 11:34:36 +0100 |
---|---|---|
committer | RaindropsSys <raindrops@equestria.dev> | 2023-11-18 11:34:36 +0100 |
commit | 9337aae8b1c87fad34884dacd5cd79d9591c60db (patch) | |
tree | 5340f9fa67cd6236e4c879f0057d51d0b1e21361 /pages/schedules.inc | |
parent | 953ddd82e48dd206cef5ac94456549aed13b3ad5 (diff) | |
download | pluralconnect-9337aae8b1c87fad34884dacd5cd79d9591c60db.tar.gz pluralconnect-9337aae8b1c87fad34884dacd5cd79d9591c60db.tar.bz2 pluralconnect-9337aae8b1c87fad34884dacd5cd79d9591c60db.zip |
Updated 39 files, added 86 files, deleted 40 files and renamed 2 files (automated)
Diffstat (limited to 'pages/schedules.inc')
-rw-r--r-- | pages/schedules.inc | 134 |
1 files changed, 0 insertions, 134 deletions
diff --git a/pages/schedules.inc b/pages/schedules.inc deleted file mode 100644 index dde2981..0000000 --- a/pages/schedules.inc +++ /dev/null @@ -1,134 +0,0 @@ -<?php - -require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/util/evening.inc"; -require_once $_SERVER['DOCUMENT_ROOT'] . "/includes/init.inc"; global $title; global $isLoggedIn; global $lang; global $pages; global $app; -require_once $_SERVER['DOCUMENT_ROOT'] . '/includes/components/header.inc'; global $readOnly; global $isNormallyLoggedIn; - -global $use2023UI; - -?> - -<style> - .day-gradient { - background-image: linear-gradient(180deg, rgba(7,15,36,1) 0%, rgba(36,56,83,1) 14%, rgba(165,126,57,1) 28%, rgba(37,109,201,1) 42%, rgba(47,165,208,1) 57%, rgba(252,120,15,1) 71%, rgba(38,66,97,1) 85%, rgba(7,15,36,1) 100%); - background-size: 100% 1000%; - } - - .invert { - filter: invert(1) hue-rotate(180deg); - } - - @media (max-width: 800px) { - #schedules { - grid-template-columns: 1fr !important; - } - - .schedules-separator { - display: block !important; - } - } -</style> - -<br> -<div class="container"> - <h2>Schedules</h2> - - <div id="schedules" style="margin-top: 20px; display: grid; grid-template-columns: repeat(4, 1fr); grid-gap: 20px;"> - <div> - <div id="live-time-other-outer" class="day-gradient" style="text-align: center; background-color: rgba(255, 255, 255, .1); padding: 20px 0; border-radius: 10px; margin-bottom: 20px;"> - <b><?= $app["other"]["name"] ?></b><br> - <h3 id="live-time-other">--:--</h3> - </div> - - <hr style="display: none;" class="schedules-separator"> - </div> - - <div> - <div id="live-time-cloudburst-outer" class="day-gradient" style="text-align: center; background-color: rgba(255, 255, 255, .1); padding: 20px 0; border-radius: 10px; margin-bottom: 20px;"> - <b>Cloudburst System</b><br> - <h3 id="live-time-cloudburst">--:--</h3> - </div> - - <hr style="display: none;" class="schedules-separator"> - </div> - - <div> - <div id="live-time-raindrops-outer" class="day-gradient" style="text-align: center; background-color: rgba(255, 255, 255, .1); padding: 20px 0; border-radius: 10px; margin-bottom: 20px;"> - <b>Raindrops System</b><br> - <h3 id="live-time-raindrops">--:--</h3> - </div> - </div> - - <div> - <div id="live-time-moonwind-outer" class="day-gradient" style="text-align: center; background-color: rgba(255, 255, 255, .1); padding: 20px 0; border-radius: 10px; margin-bottom: 20px;"> - <b>Moonwind System</b><br> - <h3 id="live-time-moonwind">--:--</h3> - </div> - </div> - </div> -</div> - -<script> - function getDayPercentage(time) { - let hours = parseInt(time.split(":")[0]); - let minutes = parseInt(time.split(":")[1].split(" ")[0]); - - if (time.split(":")[1].split(" ")[1] === "PM") hours += 12; - if (hours === 12 && time.split(":")[1].split(" ")[1] === "AM") hours = 0; - if (hours === 24 && time.split(":")[1].split(" ")[1] === "PM") hours = 12; - - let timestamp = new Date("1970-01-01 " + hours + ":" + minutes + " UTC").getTime() / 1000; - - return (timestamp / 86400) * 100; - } - - function updateTime() { - let time1 = (new Intl.DateTimeFormat('en-US', { - timeZone: 'Europe/Paris', - hour: 'numeric', - minute: '2-digit', - hour12: false - })).format(new Date()); - - document.getElementById("live-time-raindrops").innerText = time1; - document.getElementById("live-time-raindrops-outer").style.backgroundPositionY = getDayPercentage(time1) + "%"; - - let time4 = (new Intl.DateTimeFormat('en-US', { - timeZone: 'Europe/Kyiv', - hour: 'numeric', - minute: '2-digit', - hour12: false - })).format(new Date()); - - document.getElementById("live-time-moonwind").innerText = time4; - document.getElementById("live-time-moonwind-outer").style.backgroundPositionY = getDayPercentage(time4) + "%"; - - let time2 = (new Intl.DateTimeFormat('en-US', { - timeZone: 'Europe/London', - hour: 'numeric', - minute: '2-digit', - hour12: false - })).format(new Date()); - - document.getElementById("live-time-cloudburst").innerText = time2; - document.getElementById("live-time-cloudburst-outer").style.backgroundPositionY = getDayPercentage(time2) + "%"; - - let time3 = (new Intl.DateTimeFormat('en-US', { - timeZone: 'America/Chicago', - hour: 'numeric', - minute: '2-digit', - hour12: false - })).format(new Date()); - - document.getElementById("live-time-other").innerText = time3; - document.getElementById("live-time-other-outer").style.backgroundPositionY = getDayPercentage(time3) + "%"; - } - - updateTime(); - - setInterval(() => { - updateTime(); - }, 10000); -</script> - -<?php require_once $_SERVER['DOCUMENT_ROOT'] . '/includes/components/footer.inc'; ?> |