fast mode and other stuff idk

This commit is contained in:
sky
2025-09-07 16:30:15 -04:00
parent aa700bfb2e
commit 9395403389
15 changed files with 104 additions and 201 deletions

View File

@ -56,8 +56,23 @@
<link rel="icon" href="/favicon.ico" id="favicon" />
<!-- <script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3415518411898563" crossorigin="anonymous"></script> -->
<script>
let currentPanic = {key: "", url: ""};
let currentPanic = {key: "", url: ""};
document.addEventListener("DOMContentLoaded", ()=>{
let socket = new WebSocket("/socket");
socket.addEventListener("open", () => {
let cookies = document.cookie.split("; ");
for (let i = 0; i < cookies.length; i++) {
if (cookies[i].trim().startsWith("token=")) {
socket.send(cookies[i].trim());
}
}
});
socket.addEventListener("message", (e)=>{
socket.send("1");
if(e.data.split("=")[0] == "online") {
document.getElementById("online").innerText = `currently online: ${e.data.split("=")[1]}`;
}
})
let currentCloak = {name: "", icon: ""};
setInterval(()=>{
if(localStorage.getItem("selenite.tab-cloak")) {
@ -115,6 +130,14 @@
}
})
document.getElementById("open-bottom-menu").addEventListener("click", ()=>{
document.getElementById("bottom-menu").setAttribute("enabled", !(document.getElementById("bottom-menu").getAttribute("enabled") === "true"));
document.getElementById("open-bottom-menu").setAttribute("enabled", !(document.getElementById("open-bottom-menu").getAttribute("enabled") === "true"));
});
document.getElementById("bottom-menu").addEventListener("click", ()=>{
document.getElementById("bottom-menu").setAttribute("enabled", !(document.getElementById("bottom-menu").getAttribute("enabled") === "true"));
document.getElementById("open-bottom-menu").setAttribute("enabled", !(document.getElementById("open-bottom-menu").getAttribute("enabled") === "true"));
});
})
</script>
</head>
@ -134,5 +157,9 @@
<div class="sidebar-item"><a href="#" target="/settings"><img src="/img/settings.svg" /></a><div class="sidebar-item-descriptor">settings</div></div> <!-- settings -->
<div class="sidebar-item"><a href="#" target="/info"><img src="/img/info.svg" /></a><div class="sidebar-item-descriptor">information</div></div> <!-- info -->
</sidebar>
<div id="open-bottom-menu"></div>
<div id="bottom-menu">
<div class="bottom-item"><p id="online">yap yap yap</p></div>
</div>
</body>
</html>