diff options
author | RaindropsSys <contact@minteck.org> | 2023-07-21 23:00:41 +0200 |
---|---|---|
committer | RaindropsSys <contact@minteck.org> | 2023-07-21 23:00:41 +0200 |
commit | 05a4fcc9848ea1fb9feb5b5bfb7a2733dec3ce40 (patch) | |
tree | fb5dfa96e9f04c840e93ede2ee2042cad470378c /pages/alerts.inc | |
parent | 46251292b5c8b431de66aeff473594ccec60e04c (diff) | |
download | pluralconnect-05a4fcc9848ea1fb9feb5b5bfb7a2733dec3ce40.tar.gz pluralconnect-05a4fcc9848ea1fb9feb5b5bfb7a2733dec3ce40.tar.bz2 pluralconnect-05a4fcc9848ea1fb9feb5b5bfb7a2733dec3ce40.zip |
Updated 10 files and added 11 files (automated)
Diffstat (limited to 'pages/alerts.inc')
-rw-r--r-- | pages/alerts.inc | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/pages/alerts.inc b/pages/alerts.inc index b58a9ce..a0b47ff 100644 --- a/pages/alerts.inc +++ b/pages/alerts.inc @@ -9,6 +9,29 @@ require_once $_SERVER['DOCUMENT_ROOT'] . '/includes/components/header.inc'; ?> <div class="container"> <div id="page-content"> <h2>Alerts</h2> + <br> + + <div class="list-group"> + <a href="/-/emergency" class="list-group-item list-group-item-action" style="display: grid; grid-template-columns: max-content 1fr;"> + <img src="<?= icon('emergency', null, true) ?>" style="margin-right: 5px; height: 24px; width: 24px;"><div style="display: flex; align-items: center; color: var(--bs-body-color);">Emergency alert<?php if (isset($_GET["noCountdown"])): ?></div><?php else: ?> (<span id="emergency-countdown">10</span>)</div> + <script> + let eCountdownInterval = setInterval(() => { + document.getElementById("emergency-countdown").innerText = (parseInt(document.getElementById("emergency-countdown").innerText) - 1).toString(); + + if (parseInt(document.getElementById("emergency-countdown").innerText) <= 0) { + clearInterval(eCountdownInterval); + location.href = "/-/emergency"; + } + }, 1000); + </script><?php endif; ?> + </a> + <a href="/-/wakeup" class="list-group-item list-group-item-action" style="display: grid; grid-template-columns: max-content 1fr;"> + <img src="<?= icon('wakeup', null, true) ?>" style="margin-right: 5px; height: 24px; width: 24px;"><div style="display: flex; align-items: center; color: var(--bs-body-color);">Wake-up alert</div> + </a> + <a href="/-/pleasure" class="list-group-item list-group-item-action" style="display: grid; grid-template-columns: max-content 1fr;"> + <img src="<?= icon('pleasure', null, true) ?>" style="margin-right: 5px; height: 24px; width: 24px;"><div style="display: flex; align-items: center; color: var(--bs-body-color);">Pleasure alert</div> + </a> + </div> </div> </div> |