UPDATEEEE
This commit is contained in:
parent
c2a6cb8639
commit
265de4f542
|
@ -140,7 +140,7 @@ if (cluster.isPrimary) {
|
||||||
|
|
||||||
app.get("/", sendHtml("$.html"));
|
app.get("/", sendHtml("$.html"));
|
||||||
app.get("/g", sendHtml("!.html"));
|
app.get("/g", sendHtml("!.html"));
|
||||||
app.get("/a", sendHtml("!!.html"));
|
app.get("/s", sendHtml("!!.html"));
|
||||||
app.get("/resent", (_req, res) => res.sendFile(path.join(publicPath, "resent", "index.html")));
|
app.get("/resent", (_req, res) => res.sendFile(path.join(publicPath, "resent", "index.html")));
|
||||||
|
|
||||||
app.get("/api/info", (_req, res) => {
|
app.get("/api/info", (_req, res) => {
|
||||||
|
|
259
public/!!.html
259
public/!!.html
|
@ -1,122 +1,155 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||||
<meta property="og:title" content="Waves. - Apps"/>
|
<meta property="og:title" content="Waves." />
|
||||||
<meta property="og:description" content="A sleek and minimalist web proxy."/>
|
<meta property="og:description" content="A sleek and minimalist web proxy." />
|
||||||
<meta property="og:image" content="/assets/images/icons/favicon.ico"/>
|
<meta property="og:image" content="/assets/images/icons/favicon.ico" />
|
||||||
<meta name="theme-color" content="#ffffff"/>
|
<meta name="theme-color" content="#ffffff" />
|
||||||
<meta name="msapplication-TileColor" content="#ffffff"/>
|
<meta name="msapplication-TileColor" content="#ffffff" />
|
||||||
<title>Waves.</title>
|
<title>Waves.</title>
|
||||||
<link rel="icon" type="image/x-icon" href="/assets/images/icons/favicon.ico">
|
|
||||||
<link rel="stylesheet" href="/assets/css/$.css">
|
|
||||||
<link rel="stylesheet" href="/assets/css/settings.css">
|
|
||||||
<link rel="stylesheet" href="/assets/css/toast.css">
|
|
||||||
<link rel="stylesheet" href="/assets/css/a.css">
|
|
||||||
<link rel="stylesheet" href="/assets/css/nprogress.css">
|
|
||||||
<link href="https://cdn.jsdelivr.net/gh/aquawolf04/font-awesome-pro@5cd1511/css/all.css" rel="stylesheet">
|
|
||||||
<script async src="https://www.googletagmanager.com/gtag/js?id=G-WGJ2192JZY"></script><script>window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'G-WGJ2192JZY');</script>
|
|
||||||
<!-- Cool little title animation :D-->
|
|
||||||
<script>
|
|
||||||
document.addEventListener('DOMContentLoaded', function () {
|
|
||||||
|
|
||||||
NProgress.configure({ showSpinner: false });
|
<link rel="preconnect" href="https://cdn.jsdelivr.net" crossorigin />
|
||||||
NProgress.start();
|
|
||||||
|
|
||||||
const titleElement = document.querySelector('.search-title');
|
<link rel="icon" type="image/x-icon" href="/assets/images/icons/favicon.ico" />
|
||||||
if (titleElement) {
|
|
||||||
const text = titleElement.textContent.trim();
|
|
||||||
titleElement.textContent = '';
|
|
||||||
text.split('').forEach((letter, i) => {
|
|
||||||
const span = document.createElement('span');
|
|
||||||
span.textContent = letter;
|
|
||||||
span.style.animationDelay = `${i * 0.05}s`;
|
|
||||||
titleElement.appendChild(span);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
window.addEventListener('load', function () {
|
<link rel="stylesheet" href="/assets/css/$.css" />
|
||||||
NProgress.done();
|
|
||||||
});
|
<link rel="preload" href="/assets/css/settings.css" as="style" onload="this.onload=null;this.rel='stylesheet'" />
|
||||||
});
|
<link rel="preload" href="/assets/css/toast.css" as="style" onload="this.onload=null;this.rel='stylesheet'" />
|
||||||
</script>
|
<link rel="preload" href="/assets/css/nprogress.css" as="style" onload="this.onload=null;this.rel='stylesheet'" />
|
||||||
</head>
|
<link rel="preload" href="/assets/css/s.css" as="style" onload="this.onload=null;this.rel='stylesheet'" />
|
||||||
<body>
|
<noscript>
|
||||||
<script src="/baremux/index.js"></script>
|
<link rel="stylesheet" href="/assets/css/settings.css" />
|
||||||
<script src="/assets/js/nprogress.js?v=0.2.0"></script>
|
<link rel="stylesheet" href="/assets/css/toast.css" />
|
||||||
<script src="/wah/uv.bundle.js" defer></script>
|
<link rel="stylesheet" href="/assets/css/nprogress.css" />
|
||||||
<script src="/wah/cute1.js" defer></script>
|
<link rel="stylesheet" href="/assets/css/s.css" />
|
||||||
<script src="/assets/js/eruda.js?v=2.8.4" defer></script>
|
</noscript>
|
||||||
<script src="/assets/js/register.js?v=2.8.5" defer></script>
|
|
||||||
<script src="/assets/js/settings.js?v=2.8.7" defer></script>
|
<link rel="preload" as="style" href="https://cdn.jsdelivr.net/gh/aquawolf04/font-awesome-pro@5cd1511/css/all.css" onload="this.onload=null;this.rel='stylesheet'" />
|
||||||
<script src="/assets/js/greetings.js?v=2.8.5" defer></script>
|
<noscript>
|
||||||
<script src="/assets/js/shortcuts.js?v=2.8.4" defer></script>
|
<link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/aquawolf04/font-awesome-pro@5cd1511/css/all.css" />
|
||||||
<script src="/assets/js/$.js?v=2.8.4" defer></script>
|
</noscript>
|
||||||
<script src="/assets/js/a.js?v=2.8.4" defer></script>
|
|
||||||
<script src="/assets/js/wv.js?v=1.4.1" defer></script>
|
<script async src="https://www.googletagmanager.com/gtag/js?id=G-WGJ2192JZY"></script>
|
||||||
<div class="relative flex flex-col h-[100vh] items-center justify-center bg-black transition-bg">
|
<script>
|
||||||
<div class="absolute inset-0 overflow-hidden">
|
window.dataLayer = window.dataLayer || [];
|
||||||
<div class="god-rays absolute -inset-[10px] opacity-50"></div>
|
function gtag() {
|
||||||
</div>
|
dataLayer.push(arguments);
|
||||||
|
}
|
||||||
|
gtag("js", new Date());
|
||||||
|
gtag("config", "G-WGJ2192JZY");
|
||||||
|
</script>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<script src="/baremux/index.js" defer></script>
|
||||||
|
<script src="/assets/js/nprogress.js?v=0.2.0" defer></script>
|
||||||
|
<script src="/wah/uv.bundle.js" defer></script>
|
||||||
|
<script src="/wah/cute1.js" defer></script>
|
||||||
|
<script src="/assets/js/eruda.js?v=2.8.4" defer></script>
|
||||||
|
<script src="/assets/js/register.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/settings.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/greetings.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/shortcuts.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/$.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/s.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/wv.js?v=1.4.1" defer></script>
|
||||||
|
|
||||||
|
<div class="relative flex flex-col h-[100vh] items-center justify-center bg-black transition-bg">
|
||||||
|
<div class="absolute inset-0 overflow-hidden">
|
||||||
|
<div class="god-rays absolute -inset-[10px] opacity-50"></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="home-navbar">
|
</div>
|
||||||
<img src="/assets/images/icons/favicon.ico" class="favicon">
|
|
||||||
<span id="waves">Waves.</span>
|
<div class="home-navbar">
|
||||||
<a href="/" id="home">Home</a>
|
<img src="/assets/images/icons/favicon.ico" class="favicon" alt="favicon" />
|
||||||
<a href="/g" id="games">Games</a>
|
<span id="waves">Waves.</span>
|
||||||
<a href="/a" id="apps" style="color: #ffffff;">Apps</a>
|
<a href="/" id="home">Home</a>
|
||||||
<a href="#" id="movies">Movies</a>
|
<a href="/g" id="games">Games</a>
|
||||||
<a href="#" id="ai">AI</a>
|
<a href="/s" id="shortcuts" style="color: #ffffff;">Shortcuts</a>
|
||||||
<a href="#" id="settings-icon">
|
<a href="#" id="movies">Movies</a>
|
||||||
<i class="settings-icon fa-regular fa-gear"></i>
|
<a href="#" id="ai">AI</a>
|
||||||
</a>
|
<a href="#" id="settings-icon">
|
||||||
|
<i class="settings-icon fa-regular fa-gear"></i>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="settings-menu" class="settings-menu"></div>
|
||||||
|
|
||||||
|
<div class="navbar">
|
||||||
|
<ul class="nav-buttons">
|
||||||
|
<li><a id="backIcon" href="#"><i class="fa-regular fa-arrow-left"></i></a></li>
|
||||||
|
<li><a id="refreshIcon" href="#"><i class="fa-regular fa-rotate-right"></i></a></li>
|
||||||
|
<li><a id="forwardIcon" href="#"><i class="fa-regular fa-arrow-right"></i></a></li>
|
||||||
|
<li><a id="fullscreenIcon" href="#"><i class="fa-regular fa-expand"></i></a></li>
|
||||||
|
<li>
|
||||||
|
<div class="small-searchbar" style="position: relative;">
|
||||||
|
<i id="lockIcon" class="fa-solid fa-lock"></i>
|
||||||
|
<input class="waves" type="text" id="searchInputt" placeholder="Search for a query or enter a URL..." autocomplete="off" style="padding-left: 40px;" />
|
||||||
|
</div>
|
||||||
|
</li>
|
||||||
|
<li><a href="/"><i class="fa-regular fa-home"></i></a></li>
|
||||||
|
<li><a href="/g"><i class="fa-regular fa-gamepad"></i></a></li>
|
||||||
|
<li><a href="/s"><i class="fa-regular fa-rocket"></i></a></li>
|
||||||
|
<li><a id="erudaIcon" href="#"><i class="fa-regular fa-code"></i></a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="content shortcuts-page">
|
||||||
|
<h1>Shortcuts</h1>
|
||||||
|
<div class="shortcuts-search-bar">
|
||||||
|
<input type="text" id="shortcutSearchInput" placeholder="Search shortcuts..." autocomplete="off" />
|
||||||
|
<span class="shortcut-indicator-4">Ctrl + S</span>
|
||||||
</div>
|
</div>
|
||||||
<div id="settings-menu" class="settings-menu"></div>
|
<div class="shortcuts-grid"></div>
|
||||||
<div class="navbar">
|
</div>
|
||||||
<ul class="nav-buttons">
|
|
||||||
<li><a id="backIcon" href="#"><i class="fa-regular fa-arrow-left"></i></a></li>
|
<div id="erudaLoadingScreen" style="display: none;">Eruda is loading...</div>
|
||||||
<li><a id="refreshIcon" href="#"><i class="fa-regular fa-rotate-right"></i></a></li>
|
<div id="overlay" class="overlay"></div>
|
||||||
<li><a id="forwardIcon" href="#"><i class="fa-regular fa-arrow-right"></i></a></li>
|
|
||||||
<li><a id="fullscreenIcon" href="#"><i class="fa-regular fa-expand"></i></a></li>
|
<div id="namePrompt" class="popup">
|
||||||
<li>
|
<div class="input-container">
|
||||||
<div class="small-searchbar" style="position: relative;">
|
<label for="userName">Please enter a name so we know what to call you:</label>
|
||||||
<i id="lockIcon" class="fa-solid fa-lock"></i>
|
<div class="input-wrapper">
|
||||||
<input class="waves" type="text" id="searchInputt"
|
<input type="text" id="userName" placeholder="Your name" autocomplete="off" />
|
||||||
placeholder="Search for a query or enter a URL..." autocomplete="off"
|
</div>
|
||||||
style="padding-left: 40px;">
|
<button id="doneButton" onclick="submitName()" disabled><i class="fa-regular fa-check"></i> Done</button>
|
||||||
<span class="shortcut-indicator-2">Ctrl + S</span>
|
|
||||||
</div>
|
|
||||||
</li>
|
|
||||||
<li><a href="/"><i class="fa-regular fa-home"></i></a></li>
|
|
||||||
<li><a href="/g"><i class="fa-regular fa-gamepad"></i></a></li>
|
|
||||||
<li><a href="/a"><i class="fa-regular fa-grid-2"></i></a></li>
|
|
||||||
<li><a id="erudaIcon" href="#"><i class="fa-regular fa-code"></i></a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="content apps-page">
|
</div>
|
||||||
<h1>Apps</h1>
|
|
||||||
<div class="apps-search-bar">
|
<iframe id="cool-iframe" class="iframe"></iframe>
|
||||||
<input type="text" id="appSearchInput" placeholder="Search apps..." autocomplete="off" />
|
|
||||||
<span class="shortcut-indicator-4">Ctrl + S</span>
|
<script defer>
|
||||||
</div>
|
document.addEventListener("DOMContentLoaded", function () {
|
||||||
<div class="apps-grid">
|
NProgress.configure({ showSpinner: false });
|
||||||
</div>
|
NProgress.start();
|
||||||
</div>
|
|
||||||
<div id="overlay" class="overlay"></div>
|
const titleElement = document.querySelector(".search-title");
|
||||||
<div id="namePrompt" class="popup">
|
if (titleElement) {
|
||||||
<div class="input-container">
|
const text = titleElement.textContent.trim();
|
||||||
<label for="userName">Please enter a name so we know what to call you:</label>
|
titleElement.textContent = "";
|
||||||
<div class="input-wrapper">
|
text.split("").forEach((letter, i) => {
|
||||||
<input type="text" id="userName" placeholder="Your name" oninput="checkInput()" autocomplete="off" />
|
const span = document.createElement("span");
|
||||||
</div>
|
span.textContent = letter;
|
||||||
<button id="doneButton" onclick="submitName()" disabled>
|
span.style.animationDelay = `${i * 0.05}s`;
|
||||||
<i class="fas fa-check"></i> Done
|
titleElement.appendChild(span);
|
||||||
</button>
|
});
|
||||||
</div>
|
}
|
||||||
</div>
|
|
||||||
<div id="erudaLoadingScreen" style="display: none;">Eruda is loading...</div>
|
window.addEventListener("load", function () {
|
||||||
<iframe id="cool-iframe" class="iframe"></iframe>
|
NProgress.done();
|
||||||
<script type='text/javascript' src='//pl26200346.effectiveratecpm.com/08/db/84/08db842da9b43ad3d13c14634f9fd1c8.js'></script>
|
});
|
||||||
</body>
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
requestIdleCallback(() => {
|
||||||
|
const ad = document.createElement("script");
|
||||||
|
ad.src = "//pl26200346.effectiveratecpm.com/08/db/84/08db842da9b43ad3d13c14634f9fd1c8.js";
|
||||||
|
ad.async = true;
|
||||||
|
document.body.appendChild(ad);
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
</html>
|
</html>
|
259
public/!.html
259
public/!.html
|
@ -1,122 +1,155 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||||
<meta property="og:title" content="Waves. - Games"/>
|
<meta property="og:title" content="Waves." />
|
||||||
<meta property="og:description" content="A sleek and minimalist web proxy."/>
|
<meta property="og:description" content="A sleek and minimalist web proxy." />
|
||||||
<meta property="og:image" content="/assets/images/icons/favicon.ico"/>
|
<meta property="og:image" content="/assets/images/icons/favicon.ico" />
|
||||||
<meta name="theme-color" content="#ffffff"/>
|
<meta name="theme-color" content="#ffffff" />
|
||||||
<meta name="msapplication-TileColor" content="#ffffff"/>
|
<meta name="msapplication-TileColor" content="#ffffff" />
|
||||||
<title>Waves.</title>
|
<title>Waves.</title>
|
||||||
<link rel="icon" type="image/x-icon" href="/assets/images/icons/favicon.ico">
|
|
||||||
<link rel="stylesheet" href="/assets/css/$.css">
|
|
||||||
<link rel="stylesheet" href="/assets/css/settings.css">
|
|
||||||
<link rel="stylesheet" href="/assets/css/toast.css">
|
|
||||||
<link rel="stylesheet" href="/assets/css/g.css">
|
|
||||||
<link href="https://cdn.jsdelivr.net/gh/aquawolf04/font-awesome-pro@5cd1511/css/all.css" rel="stylesheet" />
|
|
||||||
<script async src="https://www.googletagmanager.com/gtag/js?id=G-WGJ2192JZY"></script><script>window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'G-WGJ2192JZY');</script>
|
|
||||||
<script type='text/javascript' src='//pl26200262.effectiveratecpm.com/f0/e8/15/f0e81559842363ebf19aa99900ff2d02.js'></script>
|
|
||||||
<!-- Cool little title animation :D-->
|
|
||||||
<script>
|
|
||||||
document.addEventListener('DOMContentLoaded', function () {
|
|
||||||
|
|
||||||
NProgress.configure({ showSpinner: false });
|
<link rel="preconnect" href="https://cdn.jsdelivr.net" crossorigin />
|
||||||
NProgress.start();
|
|
||||||
|
|
||||||
const titleElement = document.querySelector('.search-title');
|
<link rel="icon" type="image/x-icon" href="/assets/images/icons/favicon.ico" />
|
||||||
if (titleElement) {
|
|
||||||
const text = titleElement.textContent.trim();
|
|
||||||
titleElement.textContent = '';
|
|
||||||
text.split('').forEach((letter, i) => {
|
|
||||||
const span = document.createElement('span');
|
|
||||||
span.textContent = letter;
|
|
||||||
span.style.animationDelay = `${i * 0.05}s`;
|
|
||||||
titleElement.appendChild(span);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
window.addEventListener('load', function () {
|
<link rel="stylesheet" href="/assets/css/$.css" />
|
||||||
NProgress.done();
|
|
||||||
});
|
<link rel="preload" href="/assets/css/settings.css" as="style" onload="this.onload=null;this.rel='stylesheet'" />
|
||||||
});
|
<link rel="preload" href="/assets/css/toast.css" as="style" onload="this.onload=null;this.rel='stylesheet'" />
|
||||||
</script>
|
<link rel="preload" href="/assets/css/nprogress.css" as="style" onload="this.onload=null;this.rel='stylesheet'" />
|
||||||
</head>
|
<link rel="preload" href="/assets/css/g.css" as="style" onload="this.onload=null;this.rel='stylesheet'" />
|
||||||
<body>
|
<noscript>
|
||||||
<script src="/baremux/index.js"></script>
|
<link rel="stylesheet" href="/assets/css/settings.css" />
|
||||||
<script src="/assets/js/nprogress.js?v=0.2.0"></script>
|
<link rel="stylesheet" href="/assets/css/toast.css" />
|
||||||
<script src="/wah/uv.bundle.js" defer></script>
|
<link rel="stylesheet" href="/assets/css/nprogress.css" />
|
||||||
<script src="/wah/cute1.js" defer></script>
|
<link rel="stylesheet" href="/assets/css/g.css" />
|
||||||
<script src="/assets/js/eruda.js?v=2.8.4" defer></script>
|
</noscript>
|
||||||
<script src="/assets/js/register.js?v=2.8.5" defer></script>
|
|
||||||
<script src="/assets/js/settings.js?v=2.8.7" defer></script>
|
<link rel="preload" as="style" href="https://cdn.jsdelivr.net/gh/aquawolf04/font-awesome-pro@5cd1511/css/all.css" onload="this.onload=null;this.rel='stylesheet'" />
|
||||||
<script src="/assets/js/greetings.js?v=2.8.5" defer></script>
|
<noscript>
|
||||||
<script src="/assets/js/shortcuts.js?v=2.8.4" defer></script>
|
<link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/aquawolf04/font-awesome-pro@5cd1511/css/all.css" />
|
||||||
<script src="/assets/js/$.js?v=2.8.4" defer></script>
|
</noscript>
|
||||||
<script src="/assets/js/g.js?v=2.8.4" defer></script>
|
|
||||||
<script src="/assets/js/wv.js?v=1.4.1" defer></script>
|
<script async src="https://www.googletagmanager.com/gtag/js?id=G-WGJ2192JZY"></script>
|
||||||
<div class="relative flex flex-col h-[100vh] items-center justify-center bg-black transition-bg">
|
<script>
|
||||||
<div class="absolute inset-0 overflow-hidden">
|
window.dataLayer = window.dataLayer || [];
|
||||||
<div class="god-rays absolute -inset-[10px] opacity-50"></div>
|
function gtag() {
|
||||||
</div>
|
dataLayer.push(arguments);
|
||||||
|
}
|
||||||
|
gtag("js", new Date());
|
||||||
|
gtag("config", "G-WGJ2192JZY");
|
||||||
|
</script>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<script src="/baremux/index.js" defer></script>
|
||||||
|
<script src="/assets/js/nprogress.js?v=0.2.0" defer></script>
|
||||||
|
<script src="/wah/uv.bundle.js" defer></script>
|
||||||
|
<script src="/wah/cute1.js" defer></script>
|
||||||
|
<script src="/assets/js/eruda.js?v=2.8.4" defer></script>
|
||||||
|
<script src="/assets/js/register.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/settings.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/greetings.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/shortcuts.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/$.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/g.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/wv.js?v=1.4.1" defer></script>
|
||||||
|
|
||||||
|
<div class="relative flex flex-col h-[100vh] items-center justify-center bg-black transition-bg">
|
||||||
|
<div class="absolute inset-0 overflow-hidden">
|
||||||
|
<div class="god-rays absolute -inset-[10px] opacity-50"></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="home-navbar">
|
</div>
|
||||||
<img src="/assets/images/icons/favicon.ico" class="favicon">
|
|
||||||
<span id="waves">Waves.</span>
|
<div class="home-navbar">
|
||||||
<a href="/" id="home">Home</a>
|
<img src="/assets/images/icons/favicon.ico" class="favicon" alt="favicon" />
|
||||||
<a href="/g" id="games" style="color: #ffffff;">Games</a>
|
<span id="waves">Waves.</span>
|
||||||
<a href="/a" id="apps">Apps</a>
|
<a href="/" id="home">Home</a>
|
||||||
<a href="#" id="movies">Movies</a>
|
<a href="/g" id="games" style="color: #ffffff;">Games</a>
|
||||||
<a href="#" id="ai">AI</a>
|
<a href="/s" id="apps">Shortcuts</a>
|
||||||
<a href="#" id="settings-icon">
|
<a href="#" id="movies">Movies</a>
|
||||||
<i class="settings-icon fa-regular fa-gear"></i>
|
<a href="#" id="ai">AI</a>
|
||||||
</a>
|
<a href="#" id="settings-icon">
|
||||||
|
<i class="settings-icon fa-regular fa-gear"></i>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="settings-menu" class="settings-menu"></div>
|
||||||
|
|
||||||
|
<div class="navbar">
|
||||||
|
<ul class="nav-buttons">
|
||||||
|
<li><a id="backIcon" href="#"><i class="fa-regular fa-arrow-left"></i></a></li>
|
||||||
|
<li><a id="refreshIcon" href="#"><i class="fa-regular fa-rotate-right"></i></a></li>
|
||||||
|
<li><a id="forwardIcon" href="#"><i class="fa-regular fa-arrow-right"></i></a></li>
|
||||||
|
<li><a id="fullscreenIcon" href="#"><i class="fa-regular fa-expand"></i></a></li>
|
||||||
|
<li>
|
||||||
|
<div class="small-searchbar" style="position: relative;">
|
||||||
|
<i id="lockIcon" class="fa-solid fa-lock"></i>
|
||||||
|
<input class="waves" type="text" id="searchInputt" placeholder="Search for a query or enter a URL..." autocomplete="off" style="padding-left: 40px;" />
|
||||||
|
</div>
|
||||||
|
</li>
|
||||||
|
<li><a href="/"><i class="fa-regular fa-home"></i></a></li>
|
||||||
|
<li><a href="/g"><i class="fa-regular fa-gamepad"></i></a></li>
|
||||||
|
<li><a href="/s"><i class="fa-regular fa-rocket"></i></a></li>
|
||||||
|
<li><a id="erudaIcon" href="#"><i class="fa-regular fa-code"></i></a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="content games-page">
|
||||||
|
<h1>Games</h1>
|
||||||
|
<div class="games-search-bar">
|
||||||
|
<input type="text" id="gameSearchInput" placeholder="Search games..." autocomplete="off" />
|
||||||
|
<span class="shortcut-indicator-3">Ctrl + S</span>
|
||||||
</div>
|
</div>
|
||||||
<div id="settings-menu" class="settings-menu"></div>
|
<div class="games-grid"></div>
|
||||||
<div class="navbar">
|
</div>
|
||||||
<ul class="nav-buttons">
|
|
||||||
<li><a id="backIcon" href="#"><i class="fa-regular fa-arrow-left"></i></a></li>
|
<div id="erudaLoadingScreen" style="display: none;">Eruda is loading...</div>
|
||||||
<li><a id="refreshIcon" href="#"><i class="fa-regular fa-rotate-right"></i></a></li>
|
<div id="overlay" class="overlay"></div>
|
||||||
<li><a id="forwardIcon" href="#"><i class="fa-regular fa-arrow-right"></i></a></li>
|
|
||||||
<li><a id="fullscreenIcon" href="#"><i class="fa-regular fa-expand"></i></a></li>
|
<div id="namePrompt" class="popup">
|
||||||
<li>
|
<div class="input-container">
|
||||||
<div class="small-searchbar" style="position: relative;">
|
<label for="userName">Please enter a name so we know what to call you:</label>
|
||||||
<i id="lockIcon" class="fa-solid fa-lock"></i>
|
<div class="input-wrapper">
|
||||||
<input class="waves" type="text" id="searchInputt"
|
<input type="text" id="userName" placeholder="Your name" autocomplete="off" />
|
||||||
placeholder="Search for a query or enter a URL..." autocomplete="off"
|
</div>
|
||||||
style="padding-left: 40px;">
|
<button id="doneButton" onclick="submitName()" disabled><i class="fa-regular fa-check"></i> Done</button>
|
||||||
<span class="shortcut-indicator-2">Ctrl + S</span>
|
|
||||||
</div>
|
|
||||||
</li>
|
|
||||||
<li><a href="/"><i class="fa-regular fa-home"></i></a></li>
|
|
||||||
<li><a href="/g"><i class="fa-regular fa-gamepad"></i></a></li>
|
|
||||||
<li><a href="/a"><i class="fa-regular fa-grid-2"></i></a></li>
|
|
||||||
<li><a id="erudaIcon" href="#"><i class="fa-regular fa-code"></i></a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="content games-page">
|
</div>
|
||||||
<h1>Games</h1>
|
|
||||||
<div class="games-search-bar">
|
<iframe id="cool-iframe" class="iframe"></iframe>
|
||||||
<input type="text" id="gameSearchInput" placeholder="Search games..." autocomplete="off" />
|
|
||||||
<span class="shortcut-indicator-3">Ctrl + S</span>
|
<script defer>
|
||||||
</div>
|
document.addEventListener("DOMContentLoaded", function () {
|
||||||
<div class="games-grid">
|
NProgress.configure({ showSpinner: false });
|
||||||
</div>
|
NProgress.start();
|
||||||
</div>
|
|
||||||
<div id="overlay" class="overlay"></div>
|
const titleElement = document.querySelector(".search-title");
|
||||||
<div id="namePrompt" class="popup">
|
if (titleElement) {
|
||||||
<div class="input-container">
|
const text = titleElement.textContent.trim();
|
||||||
<label for="userName">Please enter a name so we know what to call you:</label>
|
titleElement.textContent = "";
|
||||||
<div class="input-wrapper">
|
text.split("").forEach((letter, i) => {
|
||||||
<input type="text" id="userName" placeholder="Your name" oninput="checkInput()" autocomplete="off" />
|
const span = document.createElement("span");
|
||||||
</div>
|
span.textContent = letter;
|
||||||
<button id="doneButton" onclick="submitName()" disabled>
|
span.style.animationDelay = `${i * 0.05}s`;
|
||||||
<i class="fas fa-check"></i> Done
|
titleElement.appendChild(span);
|
||||||
</button>
|
});
|
||||||
</div>
|
}
|
||||||
</div>
|
|
||||||
<div id="erudaLoadingScreen" style="display: none;">Eruda is loading...</div>
|
window.addEventListener("load", function () {
|
||||||
<iframe id="cool-iframe" class="iframe"></iframe>
|
NProgress.done();
|
||||||
<script type='text/javascript' src='//pl26200346.effectiveratecpm.com/08/db/84/08db842da9b43ad3d13c14634f9fd1c8.js'></script>
|
});
|
||||||
</body>
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
requestIdleCallback(() => {
|
||||||
|
const ad = document.createElement("script");
|
||||||
|
ad.src = "//pl26200346.effectiveratecpm.com/08/db/84/08db842da9b43ad3d13c14634f9fd1c8.js";
|
||||||
|
ad.async = true;
|
||||||
|
document.body.appendChild(ad);
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
</html>
|
</html>
|
291
public/$.html
291
public/$.html
|
@ -1,137 +1,172 @@
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||||
<meta property="og:title" content="Waves."/>
|
<meta property="og:title" content="Waves." />
|
||||||
<meta property="og:description" content="A sleek and minimalist web proxy."/>
|
<meta property="og:description" content="A sleek and minimalist web proxy." />
|
||||||
<meta property="og:image" content="/assets/images/icons/favicon.ico"/>
|
<meta property="og:image" content="/assets/images/icons/favicon.ico" />
|
||||||
<meta name="theme-color" content="#ffffff"/>
|
<meta name="theme-color" content="#ffffff" />
|
||||||
<meta name="msapplication-TileColor" content="#ffffff"/>
|
<meta name="msapplication-TileColor" content="#ffffff" />
|
||||||
<title>Waves.</title>
|
<title>Waves.</title>
|
||||||
<link rel="icon" type="image/x-icon" href="/assets/images/icons/favicon.ico">
|
|
||||||
<link rel="stylesheet" href="/assets/css/$.css">
|
|
||||||
<link rel="stylesheet" href="/assets/css/settings.css">
|
|
||||||
<link rel="stylesheet" href="/assets/css/toast.css">
|
|
||||||
<link rel="stylesheet" href="/assets/css/nprogress.css">
|
|
||||||
<link href="https://cdn.jsdelivr.net/gh/aquawolf04/font-awesome-pro@5cd1511/css/all.css" rel="stylesheet">
|
|
||||||
<script async src="https://www.googletagmanager.com/gtag/js?id=G-WGJ2192JZY"></script><script>window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'G-WGJ2192JZY');</script>
|
|
||||||
<!-- Cool little title animation :D-->
|
|
||||||
<script>
|
|
||||||
document.addEventListener('DOMContentLoaded', function () {
|
|
||||||
|
|
||||||
NProgress.configure({ showSpinner: false });
|
<link rel="preconnect" href="https://cdn.jsdelivr.net" crossorigin />
|
||||||
NProgress.start();
|
|
||||||
|
|
||||||
const titleElement = document.querySelector('.search-title');
|
<link rel="icon" type="image/x-icon" href="/assets/images/icons/favicon.ico" />
|
||||||
if (titleElement) {
|
|
||||||
const text = titleElement.textContent.trim();
|
|
||||||
titleElement.textContent = '';
|
|
||||||
text.split('').forEach((letter, i) => {
|
|
||||||
const span = document.createElement('span');
|
|
||||||
span.textContent = letter;
|
|
||||||
span.style.animationDelay = `${i * 0.05}s`;
|
|
||||||
titleElement.appendChild(span);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
window.addEventListener('load', function () {
|
<link rel="stylesheet" href="/assets/css/$.css" />
|
||||||
NProgress.done();
|
|
||||||
});
|
<link rel="preload" href="/assets/css/settings.css" as="style" onload="this.onload=null;this.rel='stylesheet'" />
|
||||||
});
|
<link rel="preload" href="/assets/css/toast.css" as="style" onload="this.onload=null;this.rel='stylesheet'" />
|
||||||
</script>
|
<link rel="preload" href="/assets/css/nprogress.css" as="style" onload="this.onload=null;this.rel='stylesheet'" />
|
||||||
</head>
|
<noscript>
|
||||||
<body>
|
<link rel="stylesheet" href="/assets/css/settings.css" />
|
||||||
<script src="/baremux/index.js"></script>
|
<link rel="stylesheet" href="/assets/css/toast.css" />
|
||||||
<script src="/assets/js/nprogress.js?v=0.2.0"></script>
|
<link rel="stylesheet" href="/assets/css/nprogress.css" />
|
||||||
<script src="/wah/uv.bundle.js" defer></script>
|
</noscript>
|
||||||
<script src="/wah/cute1.js" defer></script>
|
|
||||||
<script src="/assets/js/eruda.js?v=2.8.4" defer></script>
|
<link rel="preload" as="style" href="https://cdn.jsdelivr.net/gh/aquawolf04/font-awesome-pro@5cd1511/css/all.css" onload="this.onload=null;this.rel='stylesheet'" />
|
||||||
<script src="/assets/js/register.js?v=2.8.4" defer></script>
|
<noscript>
|
||||||
<script src="/assets/js/settings.js?v=2.8.8" defer></script>
|
<link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/aquawolf04/font-awesome-pro@5cd1511/css/all.css" />
|
||||||
<script src="/assets/js/ping.js?v=2.8.4" defer></script>
|
</noscript>
|
||||||
<script src="/assets/js/greetings.js?v=2.8.4" defer></script>
|
|
||||||
<script src="/assets/js/shortcuts.js?v=2.8.4" defer></script>
|
<script async src="https://www.googletagmanager.com/gtag/js?id=G-WGJ2192JZY"></script>
|
||||||
<script src="/assets/js/$.js?v=2.8.4" defer></script>
|
<script>
|
||||||
<script src="/assets/js/wv.js?v=1.4.1" defer></script>
|
window.dataLayer = window.dataLayer || [];
|
||||||
<div class="relative flex flex-col h-[100vh] items-center justify-center bg-black transition-bg">
|
function gtag() {
|
||||||
<div class="absolute inset-0 overflow-hidden">
|
dataLayer.push(arguments);
|
||||||
<div class="god-rays absolute -inset-[10px] opacity-50"></div>
|
}
|
||||||
</div>
|
gtag("js", new Date());
|
||||||
|
gtag("config", "G-WGJ2192JZY");
|
||||||
|
</script>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<script src="/baremux/index.js"></script>
|
||||||
|
<script src="/assets/js/nprogress.js?v=0.2.0" defer></script>
|
||||||
|
<script src="/wah/uv.bundle.js" defer></script>
|
||||||
|
<script src="/wah/cute1.js" defer></script>
|
||||||
|
<script src="/assets/js/eruda.js?v=2.8.4" defer></script>
|
||||||
|
<script src="/assets/js/register.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/settings.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/ping.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/greetings.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/shortcuts.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/$.js?v=2.8.9" defer></script>
|
||||||
|
<script src="/assets/js/wv.js?v=1.4.1" defer></script>
|
||||||
|
|
||||||
|
<div class="relative flex flex-col h-[100vh] items-center justify-center bg-black transition-bg">
|
||||||
|
<div class="absolute inset-0 overflow-hidden">
|
||||||
|
<div class="god-rays absolute -inset-[10px] opacity-50"></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="home-navbar">
|
</div>
|
||||||
<img src="/assets/images/icons/favicon.ico" class="favicon">
|
|
||||||
<span id="waves">Waves</span>
|
<div class="home-navbar">
|
||||||
<a href="/" id="home" style="color: #ffffff;">Home</a>
|
<img src="/assets/images/icons/favicon.ico" class="favicon" />
|
||||||
<a href="/g" id="games">Games</a>
|
<span id="waves">Waves</span>
|
||||||
<a href="/a" id="apps">Apps</a>
|
<a href="/" id="home" style="color: #ffffff;">Home</a>
|
||||||
<a href="#" id="movies">Movies</a>
|
<a href="/g" id="games">Games</a>
|
||||||
<a href="#" id="ai">AI</a>
|
<a href="/s" id="apps">Shortcuts</a>
|
||||||
<a href="#" id="settings-icon">
|
<a href="#" id="movies">Movies</a>
|
||||||
<i class="settings-icon fa-regular fa-gear"></i>
|
<a href="#" id="ai">AI</a>
|
||||||
</a>
|
<a href="#" id="settings-icon"><i class="settings-icon fa-regular fa-gear"></i></a>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="settings-menu" class="settings-menu"></div>
|
||||||
|
|
||||||
|
<div class="navbar">
|
||||||
|
<ul class="nav-buttons">
|
||||||
|
<li><a id="backIcon" href="#"><i class="fa-regular fa-arrow-left"></i></a></li>
|
||||||
|
<li><a id="refreshIcon" href="#"><i class="fa-regular fa-rotate-right"></i></a></li>
|
||||||
|
<li><a id="forwardIcon" href="#"><i class="fa-regular fa-arrow-right"></i></a></li>
|
||||||
|
<li><a id="fullscreenIcon" href="#"><i class="fa-regular fa-expand"></i></a></li>
|
||||||
|
<li>
|
||||||
|
<div class="small-searchbar" style="position: relative;">
|
||||||
|
<i id="lockIcon" class="fa-solid fa-lock"></i>
|
||||||
|
<input class="waves" type="text" id="searchInputt" placeholder="Search for a query or enter a URL..." autocomplete="off" style="padding-left: 40px;" />
|
||||||
|
<span class="shortcut-indicator-2">Ctrl + S</span>
|
||||||
|
</div>
|
||||||
|
</li>
|
||||||
|
<li><a href="/"><i class="fa-regular fa-home"></i></a></li>
|
||||||
|
<li><a href="/g"><i class="fa-regular fa-gamepad"></i></a></li>
|
||||||
|
<li><a href="/s"><i class="fa-regular fa-rocket"></i></a></li>
|
||||||
|
<li><a id="erudaIcon" href="#"><i class="fa-regular fa-code"></i></a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="search-container">
|
||||||
|
<div class="search-title">Waves.</div>
|
||||||
|
<div class="search-bar">
|
||||||
|
<input class="waves" type="text" id="searchInput" placeholder="What's been on your mind lately?" autocomplete="off" />
|
||||||
|
<span class="shortcut-indicator">Ctrl + S</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="glow-blob"></div>
|
</div>
|
||||||
<div id="settings-menu" class="settings-menu"></div>
|
|
||||||
<div class="navbar">
|
<div id="erudaLoadingScreen" style="display: none;">Eruda is loading...</div>
|
||||||
<ul class="nav-buttons">
|
<div id="overlay" class="overlay"></div>
|
||||||
<li><a id="backIcon" href="#"><i class="fa-regular fa-arrow-left"></i></a></li>
|
|
||||||
<li><a id="refreshIcon" href="#"><i class="fa-regular fa-rotate-right"></i></a></li>
|
<div id="namePrompt" class="popup">
|
||||||
<li><a id="forwardIcon" href="#"><i class="fa-regular fa-arrow-right"></i></a></li>
|
<div class="input-container">
|
||||||
<li><a id="fullscreenIcon" href="#"><i class="fa-regular fa-expand"></i></a></li>
|
<label for="userName">Please enter a name so we know what to call you:</label>
|
||||||
<li>
|
<div class="input-wrapper">
|
||||||
<div class="small-searchbar" style="position: relative;">
|
<input type="text" id="userName" placeholder="Your name" autocomplete="off" />
|
||||||
<i id="lockIcon" class="fa-solid fa-lock"></i>
|
</div>
|
||||||
<input class="waves" type="text" id="searchInputt" placeholder="Search for a query or enter a URL..." autocomplete="off" style="padding-left: 40px;">
|
<button id="doneButton" onclick="submitName()" disabled><i class="fa-regular fa-check"></i> Done</button>
|
||||||
<span class="shortcut-indicator-2">Ctrl + S</span>
|
|
||||||
</div>
|
|
||||||
</li>
|
|
||||||
<li><a href="/"><i class="fa-regular fa-home"></i></a></li>
|
|
||||||
<li><a href="/g"><i class="fa-regular fa-gamepad"></i></a></li>
|
|
||||||
<li><a href="/a"><i class="fa-regular fa-grid-2"></i></a></li>
|
|
||||||
<li><a id="erudaIcon" href="#"><i class="fa-regular fa-code"></i></a></li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="search-container">
|
</div>
|
||||||
<div class="search-title">Waves.</div>
|
|
||||||
<div class="search-bar">
|
<div id="pingDisplay"><i class="fa-regular fa-wifi"></i> Ping: Connecting...</div>
|
||||||
<input class="waves" type="text" id="searchInput" placeholder="What's been on your mind lately?" autocomplete="off">
|
<div id="greeting"></div>
|
||||||
<span class="shortcut-indicator">Ctrl + S</span>
|
<iframe id="cool-iframe" class="iframe"></iframe>
|
||||||
</div>
|
<div id="lastest-commit">Loading latest commit</div>
|
||||||
</div>
|
|
||||||
<div id="erudaLoadingScreen" style="display: none;">Eruda is loading...</div>
|
<div id="copyright">
|
||||||
<div id="overlay" class="overlay"></div>
|
<i class="fa-regular fa-copyright"></i> 2025
|
||||||
<div id="namePrompt" class="popup">
|
<a class="hover-link" href="https://discord.gg/ire" target="_blank" rel="noopener noreferrer"><span class="copyrightname">Waves Services</span></a>.
|
||||||
<div class="input-container">
|
All Rights Reserved.
|
||||||
<label for="userName">Please enter a name so we know what to call you:</label>
|
</div>
|
||||||
<div class="input-wrapper">
|
|
||||||
<input type="text" id="userName" placeholder="Your name" autocomplete="off">
|
<div id="discord">
|
||||||
</div>
|
<a class="hover-link" href="https://discord.gg/ire" target="_blank" rel="noopener noreferrer">
|
||||||
<button id="doneButton" onclick="submitName()" disabled>
|
<i class="fa-brands fa-discord"></i> Discord
|
||||||
<i class="fa-regular fa-check"></i> Done
|
</a>
|
||||||
</button>
|
</div>
|
||||||
</div>
|
|
||||||
</div>
|
<div id="github">
|
||||||
<div id="pingDisplay"><i class="fa-regular fa-wifi"></i> Ping: Connecting...</div>
|
<a class="hover-link" href="https://github.com/xojw/waves" target="_blank" rel="noopener noreferrer">
|
||||||
<div id="greeting"></div>
|
<i class="fa-brands fa-github"></i> Github
|
||||||
<iframe id="cool-iframe" class="iframe"></iframe>
|
</a>
|
||||||
<div id="lastest-commit">Loading latest commit</div>
|
</div>
|
||||||
<div id="copyright">
|
|
||||||
<i class="fa-regular fa-copyright"></i> 2025
|
<script defer>
|
||||||
<a class="hover-link" href="https://discord.gg/ire" target="_blank" rel="noopener noreferrer">
|
document.addEventListener("DOMContentLoaded", function () {
|
||||||
<span class="copyrightname">Waves Services</span>
|
NProgress.configure({ showSpinner: false });
|
||||||
</a>. All Rights Reserved.
|
NProgress.start();
|
||||||
</div>
|
|
||||||
<div id="discord">
|
const titleElement = document.querySelector(".search-title");
|
||||||
<a class="hover-link" href="https://discord.gg/ire" target="_blank" rel="noopener noreferrer">
|
if (titleElement) {
|
||||||
<i class="fa-brands fa-discord"></i> Discord
|
const text = titleElement.textContent.trim();
|
||||||
</a>
|
titleElement.textContent = "";
|
||||||
</div>
|
text.split("").forEach((letter, i) => {
|
||||||
<div id="github">
|
const span = document.createElement("span");
|
||||||
<a class="hover-link" href="https://github.com/xojw/waves" target="_blank" rel="noopener noreferrer">
|
span.textContent = letter;
|
||||||
<i class="fa-brands fa-github"></i> Github
|
span.style.animationDelay = `${i * 0.05}s`;
|
||||||
</a>
|
titleElement.appendChild(span);
|
||||||
</div>
|
});
|
||||||
<script type="text/javascript" src="//pl26200346.effectiveratecpm.com/08/db/84/08db842da9b43ad3d13c14634f9fd1c8.js"></script>
|
}
|
||||||
</body>
|
|
||||||
|
window.addEventListener("load", function () {
|
||||||
|
NProgress.done();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
requestIdleCallback(() => {
|
||||||
|
const ad = document.createElement("script");
|
||||||
|
ad.src = "//pl26200346.effectiveratecpm.com/08/db/84/08db842da9b43ad3d13c14634f9fd1c8.js";
|
||||||
|
ad.async = true;
|
||||||
|
document.body.appendChild(ad);
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -63,7 +63,7 @@ body {
|
||||||
|
|
||||||
.home-navbar {
|
.home-navbar {
|
||||||
transform: translateX(-50%);
|
transform: translateX(-50%);
|
||||||
width: 670px;
|
width: 690px;
|
||||||
top: 1%;
|
top: 1%;
|
||||||
margin-bottom: -10px;
|
margin-bottom: -10px;
|
||||||
margin-left: 50%;
|
margin-left: 50%;
|
||||||
|
@ -86,7 +86,7 @@ body {
|
||||||
}
|
}
|
||||||
|
|
||||||
.home-navbar .favicon {
|
.home-navbar .favicon {
|
||||||
width: 24px;
|
width: 28px;
|
||||||
height: 24px;
|
height: 24px;
|
||||||
margin-right: -10px;
|
margin-right: -10px;
|
||||||
vertical-align: middle;
|
vertical-align: middle;
|
||||||
|
@ -105,7 +105,7 @@ body {
|
||||||
|
|
||||||
.home-navbar a:hover {
|
.home-navbar a:hover {
|
||||||
color: #bbbbbb;
|
color: #bbbbbb;
|
||||||
font-size: 16px;
|
font-size: 18px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.home-navbar a:active {
|
.home-navbar a:active {
|
||||||
|
@ -223,6 +223,26 @@ body {
|
||||||
color: #818181;
|
color: #818181;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.shortcut-indicator {
|
||||||
|
position: absolute;
|
||||||
|
top: 50%;
|
||||||
|
left: 50%;
|
||||||
|
transform: translate(calc(-50% + 235px), -50%);
|
||||||
|
font-size: 12px;
|
||||||
|
font-weight: 500;
|
||||||
|
color: #000000;
|
||||||
|
background-color: #c4c4c4;
|
||||||
|
padding: 2px 6px;
|
||||||
|
border-radius: 7px;
|
||||||
|
cursor: pointer;
|
||||||
|
transition: all 0.3s ease;
|
||||||
|
animation: fadeIn 0.3s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.shortcut-indicator:hover {
|
||||||
|
background-color: #ffffff;
|
||||||
|
}
|
||||||
|
|
||||||
.shortcut-indicator-2 {
|
.shortcut-indicator-2 {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 50%;
|
top: 50%;
|
||||||
|
@ -236,12 +256,20 @@ body {
|
||||||
border-radius: 7px;
|
border-radius: 7px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
transition: all 0.3s ease;
|
transition: all 0.3s ease;
|
||||||
|
animation: fadeUp 0.3s ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
.shortcut-indicator-2:hover {
|
.shortcut-indicator-2:hover {
|
||||||
background-color: #ffffff;
|
background-color: #ffffff;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.arrow-mode {
|
||||||
|
display: inline-block;
|
||||||
|
margin-left: 17px;
|
||||||
|
transition: all 0.3s ease;
|
||||||
|
animation: fadeIn 0.3s ease;
|
||||||
|
}
|
||||||
|
|
||||||
#lockIcon {
|
#lockIcon {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
left: 25px;
|
left: 25px;
|
||||||
|
@ -320,25 +348,6 @@ body {
|
||||||
color: #ffffff69;
|
color: #ffffff69;
|
||||||
}
|
}
|
||||||
|
|
||||||
.shortcut-indicator {
|
|
||||||
position: absolute;
|
|
||||||
top: 50%;
|
|
||||||
left: 50%;
|
|
||||||
transform: translate(calc(-50% + 235px), -50%);
|
|
||||||
font-size: 12px;
|
|
||||||
font-weight: 500;
|
|
||||||
color: #000000;
|
|
||||||
background-color: #c4c4c4;
|
|
||||||
padding: 2px 6px;
|
|
||||||
border-radius: 7px;
|
|
||||||
cursor: pointer;
|
|
||||||
transition: all 0.3s ease;
|
|
||||||
}
|
|
||||||
|
|
||||||
.shortcut-indicator:hover {
|
|
||||||
background-color: #ffffff;
|
|
||||||
}
|
|
||||||
|
|
||||||
#erudaLoadingScreen {
|
#erudaLoadingScreen {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
top: 50%;
|
top: 50%;
|
||||||
|
@ -451,7 +460,7 @@ body {
|
||||||
display: none;
|
display: none;
|
||||||
opacity: 0;
|
opacity: 0;
|
||||||
transition: opacity 0.3s ease-in-out;
|
transition: opacity 0.3s ease-in-out;
|
||||||
animation: fadeInOverlay 0.3s ease-in-out forwards;
|
animation: fadeIn 0.3s ease-in-out forwards;
|
||||||
}
|
}
|
||||||
|
|
||||||
#namePrompt {
|
#namePrompt {
|
||||||
|
@ -578,7 +587,7 @@ body {
|
||||||
}
|
}
|
||||||
|
|
||||||
#namePrompt.fade-out {
|
#namePrompt.fade-out {
|
||||||
animation: fadeOutPrompt 0.3s ease-in-out forwards;
|
animation: fadeOut 0.3s ease-in-out forwards;
|
||||||
}
|
}
|
||||||
|
|
||||||
#lastest-commit {
|
#lastest-commit {
|
||||||
|
@ -650,6 +659,14 @@ body {
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.fadeIn {
|
||||||
|
animation: fadeIn 0.3s ease-in-out forwards;
|
||||||
|
}
|
||||||
|
|
||||||
|
.fadeOut {
|
||||||
|
animation: fadeOut 0.3s ease-in-out forwards;
|
||||||
|
}
|
||||||
|
|
||||||
@keyframes fadeSlideIn {
|
@keyframes fadeSlideIn {
|
||||||
to {
|
to {
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
|
@ -657,26 +674,6 @@ body {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@keyframes fadeIn {
|
|
||||||
from {
|
|
||||||
opacity: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
to {
|
|
||||||
opacity: 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes fadeInOverlay {
|
|
||||||
0% {
|
|
||||||
opacity: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
100% {
|
|
||||||
opacity: 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes fadeInPrompt {
|
@keyframes fadeInPrompt {
|
||||||
0% {
|
0% {
|
||||||
opacity: 0;
|
opacity: 0;
|
||||||
|
@ -689,7 +686,17 @@ body {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@keyframes fadeOutPrompt {
|
@keyframes fadeIn {
|
||||||
|
from {
|
||||||
|
opacity: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
to {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fadeOut {
|
||||||
0% {
|
0% {
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
|
@ -709,47 +716,6 @@ body {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@keyframes swing {
|
|
||||||
|
|
||||||
0%,
|
|
||||||
100% {
|
|
||||||
transform: rotate(3deg);
|
|
||||||
}
|
|
||||||
|
|
||||||
50% {
|
|
||||||
transform: rotate(-3deg);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes steamLarge {
|
|
||||||
0% {
|
|
||||||
stroke-dashoffset: 13;
|
|
||||||
opacity: 0.6;
|
|
||||||
}
|
|
||||||
|
|
||||||
100% {
|
|
||||||
stroke-dashoffset: 39;
|
|
||||||
opacity: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes steamSmall {
|
|
||||||
10% {
|
|
||||||
stroke-dashoffset: 9;
|
|
||||||
opacity: 0.6;
|
|
||||||
}
|
|
||||||
|
|
||||||
80% {
|
|
||||||
stroke-dashoffset: 27;
|
|
||||||
opacity: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
100% {
|
|
||||||
stroke-dashoffset: 27;
|
|
||||||
opacity: 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes spin {
|
@keyframes spin {
|
||||||
0% {
|
0% {
|
||||||
transform: rotate(0deg);
|
transform: rotate(0deg);
|
||||||
|
|
|
@ -1,16 +1,16 @@
|
||||||
.apps-page {
|
.shortcuts-page {
|
||||||
padding: 100px 20px 40px;
|
padding: 100px 20px 40px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
.apps-page h1 {
|
.shortcuts-page h1 {
|
||||||
font-size: 2.5rem;
|
font-size: 2.5rem;
|
||||||
margin-bottom: 20px;
|
margin-bottom: 20px;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.apps-grid {
|
.shortcuts-grid {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
|
@ -21,14 +21,14 @@
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.content.apps-page {
|
.content.shortcuts-page {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.app-card {
|
.shortcut-card {
|
||||||
background-color: #08080894;
|
background-color: #08080894;
|
||||||
border-radius: 25px;
|
border-radius: 25px;
|
||||||
padding: 15px 20px;
|
padding: 15px 20px;
|
||||||
|
@ -48,7 +48,7 @@
|
||||||
animation: fadeIn 2s ease;
|
animation: fadeIn 2s ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
.app-card img {
|
.shortcut-card img {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 200px;
|
height: 200px;
|
||||||
object-fit: cover;
|
object-fit: cover;
|
||||||
|
@ -57,26 +57,26 @@
|
||||||
transition: all 0.3s ease;
|
transition: all 0.3s ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
.app-card:hover img {
|
.shortcut-card:hover img {
|
||||||
filter: brightness(1);
|
filter: brightness(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
.app-card:hover {
|
.shortcut-card:hover {
|
||||||
background-color: #333333;
|
background-color: #333333;
|
||||||
}
|
}
|
||||||
|
|
||||||
.app-card h2 {
|
.shortcut-card h2 {
|
||||||
font-size: 1rem;
|
font-size: 1rem;
|
||||||
margin: 10px 0;
|
margin: 10px 0;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.app-card p {
|
.shortcut-card p {
|
||||||
font-size: 1rem;
|
font-size: 1rem;
|
||||||
color: #ccc;
|
color: #ccc;
|
||||||
}
|
}
|
||||||
|
|
||||||
.apps-search-bar {
|
.shortcuts-search-bar {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
margin-bottom: 20px;
|
margin-bottom: 20px;
|
||||||
|
@ -84,12 +84,12 @@
|
||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
#appSearchInput {
|
#shortcutSearchInput {
|
||||||
padding: 14px 30px;
|
padding: 14px 30px;
|
||||||
border: 1px solid #ffffff1a;
|
border: 1px solid #ffffff1a;
|
||||||
background-image: url('/assets/images/icons/search.png');
|
background-image: url('/assets/images/icons/search.png');
|
||||||
background-size: 35px 35px;
|
background-size: 35px 35px;
|
||||||
background-position: 10px center;
|
background-position: 5px center;
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
padding-left: 45px;
|
padding-left: 45px;
|
||||||
border-radius: 20px;
|
border-radius: 20px;
|
||||||
|
@ -102,12 +102,12 @@
|
||||||
transition: all 0.3s ease;
|
transition: all 0.3s ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
#appSearchInput:focus,
|
#shortcutSearchInput:focus,
|
||||||
#appSearchInput:hover {
|
#shortcutSearchInput:hover {
|
||||||
border: 1px solid #ffffff69;
|
border: 1px solid #ffffff69;
|
||||||
}
|
}
|
||||||
|
|
||||||
#appSearchInput::placeholder {
|
#shortcutSearchInput::placeholder {
|
||||||
color: #a8a8a8;
|
color: #a8a8a8;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
{
|
{
|
||||||
"apps": [
|
"shortcuts": [
|
||||||
{
|
{
|
||||||
"icon": "/assets/images/a/crazygames.jpg",
|
"icon": "/assets/images/a/crazygames.jpg",
|
||||||
"title": "Crazy Games",
|
"title": "Crazy Games",
|
|
@ -145,8 +145,8 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||||
const subjects = ['math', 'science', 'history', 'art', 'programming', 'philosophy'];
|
const subjects = ['math', 'science', 'history', 'art', 'programming', 'philosophy'];
|
||||||
const randomSubject = subjects[Math.floor(Math.random() * subjects.length)];
|
const randomSubject = subjects[Math.floor(Math.random() * subjects.length)];
|
||||||
try {
|
try {
|
||||||
history.replaceState({}, '', `/learning?subject=${randomSubject}`);
|
history.replaceState({}, '', `/learning?subject=${randomSubject}`);
|
||||||
} catch(e) {}
|
} catch (e) {}
|
||||||
}
|
}
|
||||||
|
|
||||||
function setupIframeNavigationListeners() {
|
function setupIframeNavigationListeners() {
|
||||||
|
@ -203,14 +203,14 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||||
try {
|
try {
|
||||||
const newUrl = iframe.contentWindow ? iframe.contentWindow.location.href : iframe.src;
|
const newUrl = iframe.contentWindow ? iframe.contentWindow.location.href : iframe.src;
|
||||||
if (newUrl && newUrl !== 'about:blank') {
|
if (newUrl && newUrl !== 'about:blank') {
|
||||||
if (currentIndex === -1 || normalizeUrl(historyStack[currentIndex]) !== normalizeUrl(newUrl) || historyStack[currentIndex] !== newUrl ) {
|
if (currentIndex === -1 || normalizeUrl(historyStack[currentIndex]) !== normalizeUrl(newUrl) || historyStack[currentIndex] !== newUrl) {
|
||||||
addToHistory(newUrl);
|
addToHistory(newUrl);
|
||||||
} else if (historyStack[currentIndex] !== newUrl) {
|
} else if (historyStack[currentIndex] !== newUrl) {
|
||||||
addToHistory(newUrl, true);
|
addToHistory(newUrl, true);
|
||||||
}
|
}
|
||||||
} else if (newUrl === 'about:blank' && historyStack.length > 0 && historyStack[currentIndex] !== 'about:blank') {
|
} else if (newUrl === 'about:blank' && historyStack.length > 0 && historyStack[currentIndex] !== 'about:blank') {
|
||||||
if (currentIndex > 0) {
|
if (currentIndex > 0) {
|
||||||
const previousUrl = historyStack[currentIndex -1];
|
const previousUrl = historyStack[currentIndex - 1];
|
||||||
currentIndex--;
|
currentIndex--;
|
||||||
iframe.src = previousUrl;
|
iframe.src = previousUrl;
|
||||||
return;
|
return;
|
||||||
|
@ -218,11 +218,10 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||||
}
|
}
|
||||||
setupIframeNavigationListeners();
|
setupIframeNavigationListeners();
|
||||||
generateSubject();
|
generateSubject();
|
||||||
if (navbarToggle && navbarToggle.checked && navBar) {
|
if (navbarToggle && navbarToggle.checked && navBar) {
|
||||||
navBar.style.display = 'block';
|
navBar.style.display = 'block';
|
||||||
}
|
}
|
||||||
} catch (error) {
|
} catch (error) {} finally {
|
||||||
} finally {
|
|
||||||
updateNavButtons();
|
updateNavButtons();
|
||||||
updateDecodedSearchInput();
|
updateDecodedSearchInput();
|
||||||
}
|
}
|
||||||
|
@ -270,7 +269,7 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||||
showLoadingScreen(false);
|
showLoadingScreen(false);
|
||||||
const currentIframeUrl = iframe.contentWindow.location.href;
|
const currentIframeUrl = iframe.contentWindow.location.href;
|
||||||
if (normalizeUrl(currentIframeUrl) !== normalizeUrl(historyStack[currentIndex] || '')) {
|
if (normalizeUrl(currentIframeUrl) !== normalizeUrl(historyStack[currentIndex] || '')) {
|
||||||
addToHistory(currentIframeUrl);
|
addToHistory(currentIframeUrl);
|
||||||
}
|
}
|
||||||
iframe.contentWindow.location.reload(true);
|
iframe.contentWindow.location.reload(true);
|
||||||
}
|
}
|
||||||
|
@ -296,10 +295,10 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (/^(localhost|(\d{1,3}\.){3}\d{1,3})(:\d+)?(\/.*)?$/.test(query) || query.toLowerCase() === "localhost") {
|
if (/^(localhost|(\d{1,3}\.){3}\d{1,3})(:\d+)?(\/.*)?$/.test(query) || query.toLowerCase() === "localhost") {
|
||||||
if (!query.toLowerCase().startsWith("http:") && !query.toLowerCase().startsWith("https:")) {
|
if (!query.toLowerCase().startsWith("http:") && !query.toLowerCase().startsWith("https:")) {
|
||||||
return `http://${query}`;
|
return `http://${query}`;
|
||||||
}
|
}
|
||||||
return query;
|
return query;
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -310,7 +309,7 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||||
urlWithHttps.hostname !== '.' &&
|
urlWithHttps.hostname !== '.' &&
|
||||||
urlWithHttps.hostname.split('.').pop().length >= 2 &&
|
urlWithHttps.hostname.split('.').pop().length >= 2 &&
|
||||||
!/^\d+$/.test(urlWithHttps.hostname.split('.').pop())
|
!/^\d+$/.test(urlWithHttps.hostname.split('.').pop())
|
||||||
) {
|
) {
|
||||||
return urlWithHttps.toString();
|
return urlWithHttps.toString();
|
||||||
}
|
}
|
||||||
} catch (e) {}
|
} catch (e) {}
|
||||||
|
@ -357,15 +356,18 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||||
if (searchURL.startsWith(window.location.origin + '/assets/g/')) {
|
if (searchURL.startsWith(window.location.origin + '/assets/g/')) {
|
||||||
finalUrlToLoad = searchURL;
|
finalUrlToLoad = searchURL;
|
||||||
} else if (searchURL.startsWith('/assets/g/')) {
|
} else if (searchURL.startsWith('/assets/g/')) {
|
||||||
finalUrlToLoad = new URL(searchURL, window.location.origin).href;
|
finalUrlToLoad = new URL(searchURL, window.location.origin).href;
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
try {
|
try {
|
||||||
const tempUrl = new URL(searchURL);
|
const tempUrl = new URL(searchURL);
|
||||||
if (tempUrl.origin === window.location.origin && tempUrl.pathname.startsWith('/assets/g/')) {
|
if (tempUrl.origin === window.location.origin && tempUrl.pathname.startsWith('/assets/g/')) {
|
||||||
finalUrlToLoad = tempUrl.href;
|
finalUrlToLoad = tempUrl.href;
|
||||||
} else { finalUrlToLoad = await getUrl(searchURL); }
|
} else {
|
||||||
} catch (e) { finalUrlToLoad = await getUrl(searchURL); }
|
finalUrlToLoad = await getUrl(searchURL);
|
||||||
|
}
|
||||||
|
} catch (e) {
|
||||||
|
finalUrlToLoad = await getUrl(searchURL);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (searchInput2) searchInput2.value = decodeUrl(finalUrlToLoad);
|
if (searchInput2) searchInput2.value = decodeUrl(finalUrlToLoad);
|
||||||
|
@ -392,27 +394,47 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
if (movies) movies.addEventListener('click', e => { e.preventDefault(); APP.handleSearch('https://movies.usewaves.site/'); });
|
if (movies) movies.addEventListener('click', e => {
|
||||||
if (ai) ai.addEventListener('click', e => { e.preventDefault(); APP.handleSearch('https://ai.usewaves.site/'); });
|
e.preventDefault();
|
||||||
|
APP.handleSearch('https://movies.usewaves.site/');
|
||||||
|
});
|
||||||
|
if (ai) ai.addEventListener('click', e => {
|
||||||
|
e.preventDefault();
|
||||||
|
APP.handleSearch('https://ai.usewaves.site/');
|
||||||
|
});
|
||||||
|
|
||||||
function showToast(message, type = 'success', iconType = 'check') {
|
function showToast(message, type = 'success', iconType = 'check') {
|
||||||
const toast = document.createElement('div');
|
const toast = document.createElement('div');
|
||||||
toast.className = `toast show ${type}`;
|
toast.className = `toast show ${type}`;
|
||||||
const icons = { 'check': 'fa-regular fa-check-circle', 'times-circle': 'fa-regular fa-times-circle', 'info': 'fa-regular fa-info-circle', 'warning': 'fa-regular fa-exclamation-triangle', 'heart': 'fa-solid fa-heart' };
|
const icons = {
|
||||||
|
'check': 'fa-regular fa-check-circle',
|
||||||
|
'times-circle': 'fa-regular fa-times-circle',
|
||||||
|
'info': 'fa-regular fa-info-circle',
|
||||||
|
'warning': 'fa-regular fa-exclamation-triangle',
|
||||||
|
'heart': 'fa-solid fa-heart'
|
||||||
|
};
|
||||||
toast.innerHTML = `<i class="${icons[iconType] || icons.heart}" style="margin-right: 8px;"></i>${message}`;
|
toast.innerHTML = `<i class="${icons[iconType] || icons.heart}" style="margin-right: 8px;"></i>${message}`;
|
||||||
const progressBar = document.createElement('div'); progressBar.className = 'progress-bar'; toast.appendChild(progressBar);
|
const progressBar = document.createElement('div');
|
||||||
const closeBtn = document.createElement('button'); closeBtn.className = 'toast-close';
|
progressBar.className = 'progress-bar';
|
||||||
|
toast.appendChild(progressBar);
|
||||||
|
const closeBtn = document.createElement('button');
|
||||||
|
closeBtn.className = 'toast-close';
|
||||||
closeBtn.innerHTML = '<i class="fa-solid fa-xmark" style="margin-left: 8px; font-size: 0.8em;"></i>';
|
closeBtn.innerHTML = '<i class="fa-solid fa-xmark" style="margin-left: 8px; font-size: 0.8em;"></i>';
|
||||||
closeBtn.onclick = () => { toast.classList.add('hide'); setTimeout(() => toast.remove(), 500); };
|
closeBtn.onclick = () => {
|
||||||
|
toast.classList.add('hide');
|
||||||
|
setTimeout(() => toast.remove(), 500);
|
||||||
|
};
|
||||||
toast.appendChild(closeBtn);
|
toast.appendChild(closeBtn);
|
||||||
document.body.appendChild(toast);
|
document.body.appendChild(toast);
|
||||||
setTimeout(() => { toast.classList.add('hide'); setTimeout(() => toast.remove(), 500); }, 3000);
|
setTimeout(() => {
|
||||||
|
toast.classList.add('hide');
|
||||||
|
setTimeout(() => toast.remove(), 500);
|
||||||
|
}, 3000);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (navbarToggle && navBar && iframe) {
|
if (navbarToggle && navBar && iframe) {
|
||||||
const savedNavbarState = localStorage.getItem('navbarToggled');
|
const savedNavbarState = localStorage.getItem('navbarToggled');
|
||||||
const defaultChecked = iframe.style.display !== 'block' ? true : (savedNavbarState === null ? false : savedNavbarState === 'true');
|
navbarToggle.checked = savedNavbarState !== 'false';
|
||||||
navbarToggle.checked = defaultChecked;
|
|
||||||
|
|
||||||
const updateNavbarDisplayBasedOnToggle = () => {
|
const updateNavbarDisplayBasedOnToggle = () => {
|
||||||
if (iframe.style.display === 'block') {
|
if (iframe.style.display === 'block') {
|
||||||
|
@ -446,7 +468,7 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||||
iframe.style.display = 'block';
|
iframe.style.display = 'block';
|
||||||
}
|
}
|
||||||
|
|
||||||
if(window.APP.updateNavbarDisplay) window.APP.updateNavbarDisplay();
|
if (window.APP.updateNavbarDisplay) window.APP.updateNavbarDisplay();
|
||||||
updateNavButtons();
|
updateNavButtons();
|
||||||
updateDecodedSearchInput();
|
updateDecodedSearchInput();
|
||||||
});
|
});
|
||||||
|
@ -456,44 +478,17 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||||
});
|
});
|
||||||
|
|
||||||
(async () => {
|
(async () => {
|
||||||
const commitElement = document.getElementById('lastest-commit');
|
try {
|
||||||
|
const res = await fetch('/api/latest-commit');
|
||||||
try {
|
const {
|
||||||
const res = await fetch('/api/latest-commit');
|
updates
|
||||||
|
} = await res.json();
|
||||||
console.log('Fetching latest commit from API:', res);
|
const u = updates[0];
|
||||||
|
const commitUrl = `https://github.com/xojw/waves/commit/${u.sha}`;
|
||||||
if (!res.ok) {
|
document.getElementById('lastest-commit').innerHTML =
|
||||||
const remaining = res.headers.get('X-RateLimit-Remaining');
|
`<a href="${commitUrl}" class="hover-link" target="_blank" rel="noopener noreferrer"><i class="fa-solid fa-code-commit"></i> ${u.sha}</a>`;
|
||||||
const reset = res.headers.get('X-RateLimit-Reset');
|
} catch {
|
||||||
|
document.getElementById('lastest-commit').textContent =
|
||||||
console.warn(`Status: ${res.status}`);
|
'Failed to load lastest commit';
|
||||||
if (remaining !== null) {
|
|
||||||
console.warn(`Rate limit remaining: ${remaining}`);
|
|
||||||
if (Number(remaining) === 0) {
|
|
||||||
const resetDate = reset ? new Date(Number(reset) * 1000) : 'unknown';
|
|
||||||
throw new Error(`Rate limit exceeded. Try again at ${resetDate}`);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (res.status === 403) {
|
|
||||||
throw new Error('403 Forbidden — possibly rate limited or blocked.');
|
|
||||||
}
|
|
||||||
|
|
||||||
throw new Error(`HTTP error! status: ${res.status}`);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const { updates } = await res.json();
|
|
||||||
const u = updates[0];
|
|
||||||
const commitUrl = `https://github.com/xojw/waves/commit/${u.sha}`;
|
|
||||||
|
|
||||||
commitElement.innerHTML = `
|
|
||||||
<a href="${commitUrl}" class="hover-link" target="_blank" rel="noopener noreferrer">
|
|
||||||
<i class="fa-solid fa-code-commit"></i> ${u.sha}
|
|
||||||
</a>`;
|
|
||||||
} catch (err) {
|
|
||||||
console.error('Failed to fetch latest commit:', err.message || err);
|
|
||||||
|
|
||||||
commitElement.textContent = 'Failed to load latest commit';
|
|
||||||
}
|
|
||||||
})();
|
})();
|
|
@ -1,45 +0,0 @@
|
||||||
document.addEventListener('DOMContentLoaded', function() {
|
|
||||||
const searchInput = document.getElementById('appSearchInput');
|
|
||||||
const grid = document.querySelector('.apps-grid');
|
|
||||||
let appsData = [];
|
|
||||||
|
|
||||||
fetch('/assets/data/a.json')
|
|
||||||
.then(response => response.json())
|
|
||||||
.then(data => {
|
|
||||||
appsData = data.apps;
|
|
||||||
|
|
||||||
searchInput.placeholder = `Search through ${appsData.length} Apps…`;
|
|
||||||
|
|
||||||
displayApps(appsData);
|
|
||||||
|
|
||||||
searchInput.addEventListener('input', function() {
|
|
||||||
const query = searchInput.value.toLowerCase();
|
|
||||||
const filteredApps = appsData.filter(app => {
|
|
||||||
const title = app.title ? app.title.toLowerCase() : '';
|
|
||||||
const description = app.description ? app.description.toLowerCase() : '';
|
|
||||||
return title.includes(query) || description.includes(query);
|
|
||||||
});
|
|
||||||
displayApps(filteredApps);
|
|
||||||
});
|
|
||||||
})
|
|
||||||
.catch(err => console.error('Error loading apps data:', err));
|
|
||||||
|
|
||||||
function displayApps(apps) {
|
|
||||||
grid.innerHTML = '';
|
|
||||||
if (apps.length === 0) {
|
|
||||||
grid.innerHTML = '<p>Zero apps were found matching your search :(</p>';
|
|
||||||
}
|
|
||||||
apps.forEach(app => {
|
|
||||||
const card = document.createElement('div');
|
|
||||||
card.classList.add('app-card');
|
|
||||||
card.innerHTML = `
|
|
||||||
<img src="${app.icon}" alt="${app.title} Icon" />
|
|
||||||
<h2>${app.title}</h2>
|
|
||||||
`;
|
|
||||||
card.addEventListener('click', function() {
|
|
||||||
window.handleSearch(app.link);
|
|
||||||
});
|
|
||||||
grid.appendChild(card);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
|
@ -1,98 +1,69 @@
|
||||||
document.addEventListener('DOMContentLoaded', () => {
|
document.addEventListener('DOMContentLoaded', function() {
|
||||||
const searchInput = document.getElementById('gameSearchInput');
|
const searchInput = document.getElementById('gameSearchInput');
|
||||||
const grid = document.querySelector('.games-grid');
|
const grid = document.querySelector('.games-grid');
|
||||||
let gamesData = [];
|
|
||||||
let filteredData = [];
|
|
||||||
const BATCH_SIZE = 50;
|
|
||||||
let renderedCount = 0;
|
|
||||||
|
|
||||||
const sentinel = document.createElement('div');
|
const sentinel = document.createElement('div');
|
||||||
sentinel.className = 'sentinel';
|
let allGames = [];
|
||||||
grid.after(sentinel);
|
let filteredGames = [];
|
||||||
|
let renderedCount = 0;
|
||||||
|
const BATCH_SIZE = 20;
|
||||||
|
|
||||||
const observer = new IntersectionObserver(entries => {
|
const observer = new IntersectionObserver(entries => {
|
||||||
entries.forEach(entry => {
|
if (entries[0].isIntersecting) loadNextBatch();
|
||||||
if (entry.isIntersecting) {
|
}, { rootMargin: '500px' });
|
||||||
renderNextBatch();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}, { rootMargin: '200px', threshold: 0.1 });
|
|
||||||
|
|
||||||
function debounce(fn, wait = 200) {
|
|
||||||
let t;
|
|
||||||
return (...args) => {
|
|
||||||
clearTimeout(t);
|
|
||||||
t = setTimeout(() => fn.apply(this, args), wait);
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
fetch('/assets/data/g.json')
|
fetch('/assets/data/g.json')
|
||||||
.then(r => r.json())
|
.then(res => res.json())
|
||||||
.then(data => {
|
.then(data => {
|
||||||
gamesData = data;
|
allGames = data;
|
||||||
filteredData = data;
|
filteredGames = data;
|
||||||
searchInput.placeholder = `Search through ${data.length} Games…`;
|
searchInput.placeholder = `Search through ${allGames.length} Games…`;
|
||||||
|
grid.parentNode.appendChild(sentinel);
|
||||||
observer.observe(sentinel);
|
observer.observe(sentinel);
|
||||||
renderNextBatch();
|
resetAndRender();
|
||||||
|
|
||||||
searchInput.addEventListener('input', debounce(() => {
|
|
||||||
const q = searchInput.value.trim().toLowerCase();
|
|
||||||
filteredData = gamesData.filter(g =>
|
|
||||||
(g.name || '').toLowerCase().includes(q)
|
|
||||||
);
|
|
||||||
resetRendering();
|
|
||||||
}, 250));
|
|
||||||
})
|
})
|
||||||
.catch(console.error);
|
.catch(err => console.error(err));
|
||||||
|
|
||||||
function resetRendering() {
|
searchInput.addEventListener('input', function() {
|
||||||
|
const q = this.value.toLowerCase();
|
||||||
|
filteredGames = allGames.filter(game =>
|
||||||
|
(game.name || '').toLowerCase().includes(q)
|
||||||
|
);
|
||||||
|
resetAndRender();
|
||||||
|
});
|
||||||
|
|
||||||
|
function resetAndRender() {
|
||||||
grid.innerHTML = '';
|
grid.innerHTML = '';
|
||||||
renderedCount = 0;
|
renderedCount = 0;
|
||||||
observer.observe(sentinel);
|
if (filteredGames.length === 0) {
|
||||||
renderNextBatch();
|
grid.innerHTML = '<p>Zero games were found matching your search :(</p>';
|
||||||
}
|
|
||||||
|
|
||||||
function renderNextBatch() {
|
|
||||||
const batch = filteredData.slice(renderedCount, renderedCount + BATCH_SIZE);
|
|
||||||
if (!batch.length) {
|
|
||||||
observer.unobserve(sentinel);
|
observer.unobserve(sentinel);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
observer.observe(sentinel);
|
||||||
|
loadNextBatch();
|
||||||
|
}
|
||||||
|
|
||||||
const frag = document.createDocumentFragment();
|
function loadNextBatch() {
|
||||||
batch.forEach(game => {
|
const nextCount = Math.min(renderedCount + BATCH_SIZE, filteredGames.length);
|
||||||
|
for (let i = renderedCount; i < nextCount; i++) {
|
||||||
|
const game = filteredGames[i];
|
||||||
const card = document.createElement('div');
|
const card = document.createElement('div');
|
||||||
card.className = 'game-card';
|
card.classList.add('game-card');
|
||||||
card.innerHTML = `
|
card.innerHTML = `
|
||||||
<img
|
<img src="/assets/g/${game.directory}/${game.image}" alt="${game.name} Icon" />
|
||||||
loading="lazy"
|
|
||||||
src="/assets/g/${game.directory}/${game.image}"
|
|
||||||
alt="${game.name} Icon"
|
|
||||||
/>
|
|
||||||
<h2>${game.name}</h2>
|
<h2>${game.name}</h2>
|
||||||
`;
|
`;
|
||||||
card.addEventListener('click', () => {
|
card.addEventListener('click', () => {
|
||||||
window.handleSearch(`/assets/g/${game.directory}`);
|
const gameUrl = window.location.origin + `/assets/g/${game.directory}`;
|
||||||
|
APP.handleSearch(gameUrl);
|
||||||
});
|
});
|
||||||
frag.appendChild(card);
|
grid.appendChild(card);
|
||||||
});
|
}
|
||||||
|
renderedCount = nextCount;
|
||||||
grid.appendChild(frag);
|
if (renderedCount >= filteredGames.length) {
|
||||||
renderedCount += batch.length;
|
|
||||||
|
|
||||||
preloadNextImages(5);
|
|
||||||
|
|
||||||
if (renderedCount >= filteredData.length) {
|
|
||||||
observer.unobserve(sentinel);
|
observer.unobserve(sentinel);
|
||||||
|
} else {
|
||||||
|
grid.parentNode.appendChild(sentinel);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function preloadNextImages(limit = 3) {
|
|
||||||
const next = filteredData.slice(renderedCount, renderedCount + limit);
|
|
||||||
next.forEach(({ directory, image }) => {
|
|
||||||
const img = new Image();
|
|
||||||
img.src = `/assets/g/${directory}/${image}`;
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
});
|
|
@ -38,8 +38,8 @@ function getWelcomeMessage(name) {
|
||||||
const path = window.location.pathname;
|
const path = window.location.pathname;
|
||||||
if (path === '/g') {
|
if (path === '/g') {
|
||||||
return `Have fun playing games, ${name}!`;
|
return `Have fun playing games, ${name}!`;
|
||||||
} else if (path === '/a') {
|
} else if (path === '/s') {
|
||||||
return `Enjoy our collection of apps, ${name}!`;
|
return `Enjoy our collection of, ${name}!`;
|
||||||
} else {
|
} else {
|
||||||
return `Welcome back, ${name}!`;
|
return `Welcome back, ${name}!`;
|
||||||
}
|
}
|
||||||
|
@ -47,7 +47,7 @@ function getWelcomeMessage(name) {
|
||||||
|
|
||||||
function getIconType(path) {
|
function getIconType(path) {
|
||||||
if (path === '/g') return 'game';
|
if (path === '/g') return 'game';
|
||||||
if (path === '/a') return 'apps';
|
if (path === '/s') return 'shortcuts';
|
||||||
return 'wave';
|
return 'wave';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -65,7 +65,7 @@ timeGreetings.push(
|
||||||
{ text: 'Good morning, sunshine', icon: '<i class="fa-regular fa-sun"></i>', suffix: ' :D' },
|
{ text: 'Good morning, sunshine', icon: '<i class="fa-regular fa-sun"></i>', suffix: ' :D' },
|
||||||
{ text: 'Here’s to a bright morning', icon: '<i class="fa-regular fa-cloud-sun"></i>', suffix: '.' },
|
{ text: 'Here’s to a bright morning', icon: '<i class="fa-regular fa-cloud-sun"></i>', suffix: '.' },
|
||||||
{ text: 'Enjoy your morning', icon: '<i class="fa-regular fa-mug-hot"></i>', suffix: '!' },
|
{ text: 'Enjoy your morning', icon: '<i class="fa-regular fa-mug-hot"></i>', suffix: '!' },
|
||||||
{ text: 'Your day starts here', icon: '<i class="fa-regular fa-star"></i>', suffix: ' !' }
|
{ text: 'Your day starts here', icon: '<i class="fa-regular fa-star"></i>', suffix: '!' }
|
||||||
);
|
);
|
||||||
|
|
||||||
timeGreetings.push(
|
timeGreetings.push(
|
||||||
|
|
|
@ -1,89 +1,80 @@
|
||||||
document.addEventListener('DOMContentLoaded', function() {
|
;(function(){
|
||||||
|
const origLog = console.log.bind(console);
|
||||||
|
document.addEventListener("DOMContentLoaded", () => {
|
||||||
|
origLog(
|
||||||
|
"%c\n" +
|
||||||
|
" ᶻ 𝗓 𐰁 .ᐟ\n" +
|
||||||
|
" |\\ _,,,---,,_\n" +
|
||||||
|
" /, `.-'`' -. ;-;;,_\n" +
|
||||||
|
" |,4- ) )-,_..;\\ ( `'-'\n" +
|
||||||
|
" '---''(_/--' `-`\\_)\n discord.gg/dJvdkPRheV",
|
||||||
|
"color: hotpink; font-size: 16px; display: block; white-space: pre; text-align: center; padding-left: 28%;"
|
||||||
|
);
|
||||||
|
});
|
||||||
|
|
||||||
const defaultWispUrl = `${window.location.protocol === "https:" ? "wss" : "ws"}://${window.location.host}/w/`;
|
const labelStyle = "background: white; color: black; font-weight: bold; padding: 2px 4px; border-radius: 2px";
|
||||||
let currentWispUrl = localStorage.getItem('customWispUrl') || defaultWispUrl;
|
const messageStyle = "background: black; color: white; padding: 2px 4px; border-radius: 2px";
|
||||||
const wispUrl = currentWispUrl;
|
["log","info","warn","error","debug"].forEach(method => {
|
||||||
const connection = new BareMux.BareMuxConnection("/baremux/worker.js");
|
const orig = console[method].bind(console);
|
||||||
|
console[method] = (...args) => {
|
||||||
|
const text = args.map(a => typeof a === 'string' ? a : JSON.stringify(a)).join(' ');
|
||||||
|
orig(`%cWaves:%c ${text}`, labelStyle, messageStyle);
|
||||||
|
};
|
||||||
|
});
|
||||||
|
|
||||||
async function registerSW() {
|
document.addEventListener("DOMContentLoaded", function(){
|
||||||
try {
|
const defaultWispUrl = `${window.location.protocol==="https:"?"wss":"ws"}://${window.location.host}/w/`;
|
||||||
if (!navigator.serviceWorker) {
|
let currentWispUrl = localStorage.getItem("customWispUrl") || defaultWispUrl;
|
||||||
console.log("%c[!]%c Service Workers are not supported by this browser.", "background-color: black; color: white; font-weight: bold;", "background-color: black; color: white;");
|
const wispUrl = currentWispUrl;
|
||||||
return;
|
const connection = new BareMux.BareMuxConnection("/baremux/worker.js");
|
||||||
}
|
|
||||||
await ensureWebSocketConnection(wispUrl);
|
|
||||||
console.log("%c[+]%c Registering Service Worker...", "background-color: black; color: white; font-weight: bold;", "background-color: black; color: white;");
|
|
||||||
await navigator.serviceWorker.register("/wah/sw.js", { scope: '/wah/a/' });
|
|
||||||
console.log("%c[*]%c Service Worker registered successfully.", "background-color: black; color: white; font-weight: bold;", "background-color: black; color: white;");
|
|
||||||
const savedTransport = localStorage.getItem('transport') || "epoxy";
|
|
||||||
switchTransport(savedTransport);
|
|
||||||
updateTransportUI(savedTransport);
|
|
||||||
console.log(`%c[#]%c Using ${capitalizeTransport(savedTransport)} transport.`, "background-color: black; color: white; font-weight: bold;", "background-color: black; color: white;");
|
|
||||||
} catch (error) {
|
|
||||||
logError(error, 'An error occurred during Service Worker registration or WebSocket connection');
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
async function ensureWebSocketConnection(url) {
|
registerSW();
|
||||||
return new Promise((resolve, reject) => {
|
|
||||||
console.log("%c[+]%c Establishing WebSocket connection...", "background-color: black; color: white; font-weight: bold;", "background-color: black; color: white;");
|
|
||||||
const ws = new WebSocket(url);
|
|
||||||
ws.onopen = () => {
|
|
||||||
console.log("%c[*]%c WebSocket connection established.", "background-color: black; color: white; font-weight: bold;", "background-color: black; color: white;");
|
|
||||||
resolve(ws);
|
|
||||||
};
|
|
||||||
ws.onerror = (error) => {
|
|
||||||
logError(error, 'Failed to establish WebSocket connection');
|
|
||||||
reject(error);
|
|
||||||
};
|
|
||||||
ws.onclose = (event) => {
|
|
||||||
if (event.code !== 1000) {
|
|
||||||
console.warn(`%c[-]%c WebSocket connection closed. Reason: ${event.reason || "No reason provided"}`, "background-color: black; color: white; font-weight: bold;", "background-color: black; color: white;");
|
|
||||||
} else {
|
|
||||||
console.warn("%c[-]%c WebSocket connection closed normally.", "background-color: black; color: white; font-weight: bold;", "background-color: black; color: white;");
|
|
||||||
}
|
|
||||||
};
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
function logError(error, message) {
|
async function registerSW(){
|
||||||
console.error(`%c[!]%c ${message}: ${error.message || error}`, "background-color: black; color: white; font-weight: bold;", "background-color: black; color: white;");
|
try {
|
||||||
}
|
if (!navigator.serviceWorker) return console.error("Service Workers are not supported by this browser.");
|
||||||
|
await ensureWebSocketConnection(wispUrl);
|
||||||
|
console.log("Registering Service Worker...");
|
||||||
|
await navigator.serviceWorker.register("/wah/sw.js", { scope: "/wah/a/" });
|
||||||
|
console.log("Service Worker registered successfully.");
|
||||||
|
const savedTransport = localStorage.getItem("transport") || "epoxy";
|
||||||
|
switchTransport(savedTransport);
|
||||||
|
updateTransportUI(savedTransport);
|
||||||
|
console.log(`Using ${capitalizeTransport(savedTransport)} transport.`);
|
||||||
|
} catch (e) {
|
||||||
|
console.error(`An error occurred during Service Worker registration or WebSocket connection: ${e.message||e}`);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function switchTransport(transport) {
|
async function ensureWebSocketConnection(url){
|
||||||
const transportMap = {
|
return new Promise((resolve, reject) => {
|
||||||
"epoxy": "/epoxy/index.mjs",
|
console.log("Establishing WebSocket connection...");
|
||||||
"libcurl": "/libcurl/index.mjs"
|
const ws = new WebSocket(url);
|
||||||
};
|
ws.onopen = () => { console.log("WebSocket connection established."); resolve(ws); };
|
||||||
const transportFile = transportMap[transport];
|
ws.onerror = e => { console.error(`Failed to establish WebSocket connection: ${e.message||e}`); reject(e); };
|
||||||
if (transportFile) {
|
ws.onclose = ev => {
|
||||||
connection.setTransport(transportFile, [{ wisp: wispUrl }]);
|
if (ev.code !== 1000) console.warn(`WebSocket connection closed. Reason: ${ev.reason||"No reason provided"}`);
|
||||||
}
|
else console.warn("WebSocket connection closed normally.");
|
||||||
}
|
};
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
async function changeTransport(newTransport) {
|
function switchTransport(t){
|
||||||
try {
|
const m = { epoxy: "/epoxy/index.mjs", libcurl: "/libcurl/index.mjs" }[t];
|
||||||
localStorage.setItem('transport', newTransport);
|
if (m) connection.setTransport(m, [{ wisp: wispUrl }]);
|
||||||
switchTransport(newTransport);
|
}
|
||||||
updateTransportUI(newTransport);
|
|
||||||
} catch (error) {
|
|
||||||
logError(error, 'An error occurred while storing transport preference');
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function updateTransportUI(transport) {
|
function updateTransportUI(t){
|
||||||
const transportSelected = document.querySelector(".transport-selected");
|
document.querySelector(".transport-selected").textContent = capitalizeTransport(t);
|
||||||
transportSelected.textContent = capitalizeTransport(transport);
|
}
|
||||||
}
|
|
||||||
|
|
||||||
function capitalizeTransport(transport) {
|
function capitalizeTransport(t){
|
||||||
return transport.charAt(0).toUpperCase() + transport.slice(1).toLowerCase();
|
return t.charAt(0).toUpperCase() + t.slice(1).toLowerCase();
|
||||||
}
|
}
|
||||||
|
|
||||||
document.addEventListener('wispUrlChanged', function(e) {
|
document.addEventListener("wispUrlChanged", function(e){
|
||||||
currentWispUrl = e.detail;
|
currentWispUrl = e.detail;
|
||||||
switchTransport(localStorage.getItem('transport') || "epoxy");
|
switchTransport(localStorage.getItem("transport") || "epoxy");
|
||||||
});
|
});
|
||||||
|
});
|
||||||
registerSW();
|
})();
|
||||||
});
|
|
45
public/assets/js/s.js
Normal file
45
public/assets/js/s.js
Normal file
|
@ -0,0 +1,45 @@
|
||||||
|
document.addEventListener('DOMContentLoaded', function() {
|
||||||
|
const searchInput = document.getElementById('shortcutSearchInput');
|
||||||
|
const grid = document.querySelector('.shortcuts-grid');
|
||||||
|
let shortcutsData = [];
|
||||||
|
|
||||||
|
fetch('/assets/data/s.json')
|
||||||
|
.then(response => response.json())
|
||||||
|
.then(data => {
|
||||||
|
shortcutsData = data.shortcuts;
|
||||||
|
|
||||||
|
searchInput.placeholder = `Search through ${shortcutsData.length} Shortcuts...`;
|
||||||
|
|
||||||
|
displayShortcuts(shortcutsData);
|
||||||
|
|
||||||
|
searchInput.addEventListener('input', function() {
|
||||||
|
const query = searchInput.value.toLowerCase();
|
||||||
|
const filteredShortcuts = shortcutsData.filter(shortcut => {
|
||||||
|
const title = shortcut.title ? shortcut.title.toLowerCase() : '';
|
||||||
|
const description = shortcut.description ? shortcut.description.toLowerCase() : '';
|
||||||
|
return title.includes(query) || description.includes(query);
|
||||||
|
});
|
||||||
|
displayShortcuts(filteredShortcuts);
|
||||||
|
});
|
||||||
|
})
|
||||||
|
.catch(err => console.error('Error loading shortcuts data:', err));
|
||||||
|
|
||||||
|
function displayShortcuts(shortcuts) {
|
||||||
|
grid.innerHTML = '';
|
||||||
|
if (shortcuts.length === 0) {
|
||||||
|
grid.innerHTML = '<p>Zero shortcuts were found matching your search :(</p>';
|
||||||
|
}
|
||||||
|
shortcuts.forEach(shortcut => {
|
||||||
|
const card = document.createElement('div');
|
||||||
|
card.classList.add('shortcut-card');
|
||||||
|
card.innerHTML = `
|
||||||
|
<img src="${shortcut.icon}" alt="${shortcut.title} Icon" />
|
||||||
|
<h2>${shortcut.title}</h2>
|
||||||
|
`;
|
||||||
|
card.addEventListener('click', function() {
|
||||||
|
APP.handleSearch(shortcut.link);
|
||||||
|
});
|
||||||
|
grid.appendChild(card);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
|
@ -1,6 +1,6 @@
|
||||||
document.addEventListener('DOMContentLoaded', function () {
|
document.addEventListener('DOMContentLoaded', function() {
|
||||||
const settingsMenu = document.getElementById('settings-menu');
|
const settingsMenu = document.getElementById('settings-menu');
|
||||||
settingsMenu.innerHTML = `
|
settingsMenu.innerHTML = `
|
||||||
<h2>Settings</h2>
|
<h2>Settings</h2>
|
||||||
<div class="settings-tabs">
|
<div class="settings-tabs">
|
||||||
<button class="tab-button active" id="proxy-tab">
|
<button class="tab-button active" id="proxy-tab">
|
||||||
|
@ -92,241 +92,259 @@ document.addEventListener('DOMContentLoaded', function () {
|
||||||
</button>
|
</button>
|
||||||
`;
|
`;
|
||||||
|
|
||||||
const settingsIcon = document.getElementById('settings-icon');
|
const settingsIcon = document.getElementById('settings-icon');
|
||||||
const closeSettingsBtn = document.getElementById('close-settings');
|
const closeSettingsBtn = document.getElementById('close-settings');
|
||||||
const saveWispBtn = document.getElementById('save-wisp-url');
|
const saveWispBtn = document.getElementById('save-wisp-url');
|
||||||
const transportSelector = document.querySelector('.transport-selector');
|
const transportSelector = document.querySelector('.transport-selector');
|
||||||
const transportSelected = transportSelector.querySelector('.transport-selected');
|
const transportSelected = transportSelector.querySelector('.transport-selected');
|
||||||
const transportOptions = transportSelector.querySelector('.transport-options');
|
const transportOptions = transportSelector.querySelector('.transport-options');
|
||||||
const navbarToggle = document.getElementById('navbar-toggle');
|
const navbarToggle = document.getElementById('navbar-toggle');
|
||||||
const defaultWispUrl = `${window.location.protocol === "https:" ? "wss" : "ws"}://${window.location.host}/w/`;
|
const defaultWispUrl = `${window.location.protocol === "https:" ? "wss" : "ws"}://${window.location.host}/w/`;
|
||||||
let currentWispUrl = localStorage.getItem('customWispUrl') || defaultWispUrl;
|
let currentWispUrl = localStorage.getItem('customWispUrl') || defaultWispUrl;
|
||||||
const wispInput = document.querySelector("#wisp-server");
|
const wispInput = document.querySelector("#wisp-server");
|
||||||
wispInput.value = currentWispUrl;
|
wispInput.value = currentWispUrl;
|
||||||
let isToggling = false;
|
let isToggling = false;
|
||||||
|
|
||||||
function isValidUrl(url) {
|
navbarToggle.checked = localStorage.getItem('navbarToggled') !== 'false';
|
||||||
try {
|
|
||||||
const p = new URL(url);
|
function isValidUrl(url) {
|
||||||
return (p.protocol === "wss:" || p.protocol === "ws:") && url.endsWith('/');
|
try {
|
||||||
} catch (_) {
|
const p = new URL(url);
|
||||||
return false;
|
return (p.protocol === "wss:" || p.protocol === "ws:") && url.endsWith('/');
|
||||||
|
} catch (_) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
function runScriptIfChecked() {
|
function runScriptIfChecked() {
|
||||||
let inFrame;
|
let inFrame;
|
||||||
try {
|
try {
|
||||||
inFrame = window !== top;
|
inFrame = window !== top;
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
inFrame = true;
|
inFrame = true;
|
||||||
}
|
}
|
||||||
const aboutBlankChecked = JSON.parse(localStorage.getItem("aboutBlankChecked")) || false;
|
const aboutBlankChecked = JSON.parse(localStorage.getItem("aboutBlankChecked")) || false;
|
||||||
if (!aboutBlankChecked || inFrame) {
|
if (!aboutBlankChecked || inFrame) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const defaultTitle = "Google.";
|
const defaultTitle = "Google.";
|
||||||
const defaultIcon = "https://www.google.com/favicon.ico";
|
const defaultIcon = "https://www.google.com/favicon.ico";
|
||||||
const title = localStorage.getItem("siteTitle") || defaultTitle;
|
const title = localStorage.getItem("siteTitle") || defaultTitle;
|
||||||
const icon = localStorage.getItem("faviconURL") || defaultIcon;
|
const icon = localStorage.getItem("faviconURL") || defaultIcon;
|
||||||
const iframeSrc = "/";
|
const iframeSrc = "/";
|
||||||
const popup = window.open("", "_blank");
|
const popup = window.open("", "_blank");
|
||||||
if (!popup || popup.closed) {
|
if (!popup || popup.closed) {
|
||||||
alert("Failed to load automask. Please allow popups and try again.");
|
alert("Failed to load automask. Please allow popups and try again.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
popup.document.head.innerHTML = `
|
popup.document.head.innerHTML = `
|
||||||
<title>${title}</title>
|
<title>${title}</title>
|
||||||
<link rel="icon" href="${icon}">
|
<link rel="icon" href="${icon}">
|
||||||
`;
|
`;
|
||||||
popup.document.body.innerHTML = `
|
popup.document.body.innerHTML = `
|
||||||
<iframe style="height: 100%; width: 100%; border: none; position: fixed; top: 0; right: 0; left: 0; bottom: 0;" src="${iframeSrc}"></iframe>
|
<iframe style="height: 100%; width: 100%; border: none; position: fixed; top: 0; right: 0; left: 0; bottom: 0;" src="${iframeSrc}"></iframe>
|
||||||
`;
|
`;
|
||||||
window.location.replace("https://bisd.schoology.com/home");
|
window.location.replace("https://bisd.schoology.com/home");
|
||||||
}
|
|
||||||
document.getElementById("aboutblank-toggle").addEventListener("change", function() {
|
|
||||||
localStorage.setItem("aboutBlankChecked", JSON.stringify(this.checked));
|
|
||||||
if (this.checked) {
|
|
||||||
showToast('success', 'Auto About:Blank is now enabled.');
|
|
||||||
} else {
|
|
||||||
showToast('error', 'Auto About:Blank is now disabled.');
|
|
||||||
}
|
|
||||||
runScriptIfChecked();
|
|
||||||
});
|
|
||||||
window.addEventListener("load", function() {
|
|
||||||
const aboutBlankChecked = JSON.parse(localStorage.getItem("aboutBlankChecked")) || false;
|
|
||||||
document.getElementById("aboutblank-toggle").checked = aboutBlankChecked;
|
|
||||||
runScriptIfChecked();
|
|
||||||
});
|
|
||||||
|
|
||||||
function updateWispServerUrl(url) {
|
|
||||||
if (isValidUrl(url)) {
|
|
||||||
currentWispUrl = url;
|
|
||||||
localStorage.setItem('customWispUrl', url);
|
|
||||||
document.dispatchEvent(new CustomEvent('wispUrlChanged', { detail: currentWispUrl }));
|
|
||||||
showToast('success', `Wisp Server URL changed to: ${currentWispUrl}`);
|
|
||||||
} else {
|
|
||||||
currentWispUrl = defaultWispUrl;
|
|
||||||
localStorage.setItem('customWispUrl', defaultWispUrl);
|
|
||||||
document.dispatchEvent(new CustomEvent('wispUrlChanged', { detail: currentWispUrl }));
|
|
||||||
showToast('error', "Invalid URL. Reverting to default...");
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
function updateServerInfo() {
|
document.getElementById("aboutblank-toggle").addEventListener("change", function() {
|
||||||
const speedSpan = document.getElementById('server-speed');
|
localStorage.setItem("aboutBlankChecked", JSON.stringify(this.checked));
|
||||||
const uptimeSpan = document.getElementById('server-uptime');
|
if (this.checked) {
|
||||||
const specsSpan = document.getElementById('server-specs');
|
showToast('success', 'Auto About:Blank is now enabled.');
|
||||||
let uptimeInterval;
|
} else {
|
||||||
|
showToast('error', 'Auto About:Blank is now disabled.');
|
||||||
fetch('/api/info')
|
|
||||||
.then(response => {
|
|
||||||
if (!response.ok) throw new Error();
|
|
||||||
return response.json();
|
|
||||||
})
|
|
||||||
.then(data => {
|
|
||||||
if (data?.speed) {
|
|
||||||
const updateUptimeDisplay = () => {
|
|
||||||
const uptime = Date.now() - data.startTime;
|
|
||||||
const days = Math.floor(uptime / 86400000);
|
|
||||||
const hours = Math.floor((uptime % 86400000) / 3600000);
|
|
||||||
const minutes = Math.floor((uptime % 3600000) / 60000);
|
|
||||||
const seconds = Math.floor((uptime % 60000) / 1000);
|
|
||||||
uptimeSpan.textContent = `${days}d ${hours}h ${minutes}m ${seconds}s`;
|
|
||||||
};
|
|
||||||
|
|
||||||
updateUptimeDisplay();
|
|
||||||
clearInterval(uptimeInterval);
|
|
||||||
uptimeInterval = setInterval(updateUptimeDisplay, 1000);
|
|
||||||
|
|
||||||
speedSpan.textContent = `${data.speed} (${data.averageLatency}ms)`;
|
|
||||||
specsSpan.textContent = data.specs;
|
|
||||||
}
|
}
|
||||||
setTimeout(updateServerInfo, 10000);
|
runScriptIfChecked();
|
||||||
})
|
});
|
||||||
.catch(() => {
|
|
||||||
speedSpan.textContent = 'Connection error';
|
|
||||||
setTimeout(updateServerInfo, 30000);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
function initializeInfo() {
|
window.addEventListener("load", function() {
|
||||||
const infoTab = document.getElementById('info-tab');
|
const aboutBlankChecked = JSON.parse(localStorage.getItem("aboutBlankChecked")) || false;
|
||||||
const infoContent = document.getElementById('info-content');
|
document.getElementById("aboutblank-toggle").checked = aboutBlankChecked;
|
||||||
|
runScriptIfChecked();
|
||||||
|
});
|
||||||
|
|
||||||
const startMonitoring = () => {
|
function updateWispServerUrl(url) {
|
||||||
updateServerInfo();
|
if (isValidUrl(url)) {
|
||||||
infoTab.removeEventListener('click', startMonitoring);
|
currentWispUrl = url;
|
||||||
};
|
localStorage.setItem('customWispUrl', url);
|
||||||
|
document.dispatchEvent(new CustomEvent('wispUrlChanged', {
|
||||||
if (infoContent.classList.contains('active')) {
|
detail: currentWispUrl
|
||||||
updateServerInfo();
|
}));
|
||||||
} else {
|
showToast('success', `Wisp Server URL changed to: ${currentWispUrl}`);
|
||||||
infoTab.addEventListener('click', startMonitoring, { once: true });
|
} else {
|
||||||
|
currentWispUrl = defaultWispUrl;
|
||||||
|
localStorage.setItem('customWispUrl', defaultWispUrl);
|
||||||
|
document.dispatchEvent(new CustomEvent('wispUrlChanged', {
|
||||||
|
detail: currentWispUrl
|
||||||
|
}));
|
||||||
|
showToast('error', "Invalid URL. Reverting to default...");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
function showToast(type, message) {
|
|
||||||
const toast = document.createElement('div');
|
|
||||||
toast.className = `toast ${type} show`;
|
|
||||||
const icons = {
|
|
||||||
success: '<i class="fa-regular fa-check-circle"></i>',
|
|
||||||
error: '<i class="fa-regular fa-times-circle"></i>',
|
|
||||||
info: '<i class="fa-regular fa-info-circle"></i>',
|
|
||||||
warning: '<i class="fa-regular fa-exclamation-triangle"></i>'
|
|
||||||
};
|
|
||||||
toast.innerHTML = `${icons[type]||''}${message}`;
|
|
||||||
const progressBar = document.createElement('div');
|
|
||||||
progressBar.className = 'progress-bar';
|
|
||||||
toast.appendChild(progressBar);
|
|
||||||
const closeBtn = document.createElement('button');
|
|
||||||
closeBtn.className = 'toast-close';
|
|
||||||
closeBtn.innerHTML = '<i class="fa-regular fa-xmark"></i>';
|
|
||||||
closeBtn.addEventListener('click', () => {
|
|
||||||
toast.classList.replace('show', 'hide');
|
|
||||||
setTimeout(() => toast.remove(), 500);
|
|
||||||
});
|
|
||||||
toast.appendChild(closeBtn);
|
|
||||||
document.body.appendChild(toast);
|
|
||||||
setTimeout(() => {
|
|
||||||
toast.classList.replace('show', 'hide');
|
|
||||||
setTimeout(() => toast.remove(), 500);
|
|
||||||
}, 3000);
|
|
||||||
}
|
|
||||||
|
|
||||||
saveWispBtn.addEventListener('click', () => updateWispServerUrl(wispInput.value.trim()));
|
|
||||||
settingsIcon.addEventListener('click', e => {
|
|
||||||
e.preventDefault();
|
|
||||||
toggleSettingsMenu();
|
|
||||||
});
|
|
||||||
closeSettingsBtn.addEventListener('click', toggleSettingsMenu);
|
|
||||||
|
|
||||||
function toggleSettingsMenu() {
|
function updateServerInfo() {
|
||||||
if (isToggling) return;
|
const speedSpan = document.getElementById('server-speed');
|
||||||
isToggling = true;
|
const uptimeSpan = document.getElementById('server-uptime');
|
||||||
const icon = document.querySelector('#settings-icon i.settings-icon');
|
const specsSpan = document.getElementById('server-specs');
|
||||||
if (settingsMenu.classList.contains('open')) {
|
let uptimeInterval;
|
||||||
settingsMenu.classList.add('close');
|
|
||||||
icon.classList.replace('fa-solid', 'fa-regular');
|
fetch('/api/info')
|
||||||
setTimeout(() => {
|
.then(response => {
|
||||||
settingsMenu.classList.remove('open', 'close');
|
if (!response.ok) throw new Error();
|
||||||
isToggling = false;
|
return response.json();
|
||||||
}, 300);
|
})
|
||||||
} else {
|
.then(data => {
|
||||||
settingsMenu.classList.add('open');
|
if (data?.speed) {
|
||||||
icon.classList.replace('fa-regular', 'fa-solid');
|
const updateUptimeDisplay = () => {
|
||||||
setTimeout(() => {
|
const uptime = Date.now() - data.startTime;
|
||||||
settingsMenu.classList.remove('close');
|
const days = Math.floor(uptime / 86400000);
|
||||||
isToggling = false;
|
const hours = Math.floor((uptime % 86400000) / 3600000);
|
||||||
}, 300);
|
const minutes = Math.floor((uptime % 3600000) / 60000);
|
||||||
|
const seconds = Math.floor((uptime % 60000) / 1000);
|
||||||
|
uptimeSpan.textContent = `${days}d ${hours}h ${minutes}m ${seconds}s`;
|
||||||
|
};
|
||||||
|
|
||||||
|
updateUptimeDisplay();
|
||||||
|
clearInterval(uptimeInterval);
|
||||||
|
uptimeInterval = setInterval(updateUptimeDisplay, 1000);
|
||||||
|
|
||||||
|
speedSpan.textContent = `${data.speed} (${data.averageLatency}ms)`;
|
||||||
|
specsSpan.textContent = data.specs;
|
||||||
|
}
|
||||||
|
setTimeout(updateServerInfo, 10000);
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
speedSpan.textContent = 'Connection error';
|
||||||
|
setTimeout(updateServerInfo, 30000);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
transportSelected.addEventListener('click', e => {
|
function initializeInfo() {
|
||||||
e.stopPropagation();
|
const infoTab = document.getElementById('info-tab');
|
||||||
transportOptions.classList.toggle('transport-show');
|
const infoContent = document.getElementById('info-content');
|
||||||
transportSelected.classList.toggle('transport-arrow-active');
|
|
||||||
});
|
|
||||||
|
|
||||||
Array.from(transportOptions.getElementsByTagName('div')).forEach(option => {
|
const startMonitoring = () => {
|
||||||
option.addEventListener('click', function (e) {
|
updateServerInfo();
|
||||||
e.stopPropagation();
|
infoTab.removeEventListener('click', startMonitoring);
|
||||||
const val = this.textContent;
|
};
|
||||||
transportSelected.textContent = val;
|
|
||||||
localStorage.setItem('transport', val.toLowerCase());
|
if (infoContent.classList.contains('active')) {
|
||||||
transportOptions.classList.remove('transport-show');
|
updateServerInfo();
|
||||||
transportSelected.classList.remove('transport-arrow-active');
|
} else {
|
||||||
document.dispatchEvent(new CustomEvent('newTransport', { detail: val.toLowerCase() }));
|
infoTab.addEventListener('click', startMonitoring, {
|
||||||
showToast('success', `Transport changed to ${val}`);
|
once: true
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function showToast(type, message) {
|
||||||
|
const toast = document.createElement('div');
|
||||||
|
toast.className = `toast ${type} show`;
|
||||||
|
const icons = {
|
||||||
|
success: '<i class="fa-regular fa-check-circle"></i>',
|
||||||
|
error: '<i class="fa-regular fa-times-circle"></i>',
|
||||||
|
info: '<i class="fa-regular fa-info-circle"></i>',
|
||||||
|
warning: '<i class="fa-regular fa-exclamation-triangle"></i>'
|
||||||
|
};
|
||||||
|
toast.innerHTML = `${icons[type]||''}${message}`;
|
||||||
|
const progressBar = document.createElement('div');
|
||||||
|
progressBar.className = 'progress-bar';
|
||||||
|
toast.appendChild(progressBar);
|
||||||
|
const closeBtn = document.createElement('button');
|
||||||
|
closeBtn.className = 'toast-close';
|
||||||
|
closeBtn.innerHTML = '<i class="fa-regular fa-xmark"></i>';
|
||||||
|
closeBtn.addEventListener('click', () => {
|
||||||
|
toast.classList.replace('show', 'hide');
|
||||||
|
setTimeout(() => toast.remove(), 500);
|
||||||
|
});
|
||||||
|
toast.appendChild(closeBtn);
|
||||||
|
document.body.appendChild(toast);
|
||||||
|
setTimeout(() => {
|
||||||
|
toast.classList.replace('show', 'hide');
|
||||||
|
setTimeout(() => toast.remove(), 500);
|
||||||
|
}, 3000);
|
||||||
|
}
|
||||||
|
|
||||||
|
saveWispBtn.addEventListener('click', () => updateWispServerUrl(wispInput.value.trim()));
|
||||||
|
settingsIcon.addEventListener('click', e => {
|
||||||
|
e.preventDefault();
|
||||||
|
toggleSettingsMenu();
|
||||||
});
|
});
|
||||||
});
|
closeSettingsBtn.addEventListener('click', toggleSettingsMenu);
|
||||||
|
|
||||||
document.getElementById('proxy-content').classList.add('active');
|
function toggleSettingsMenu() {
|
||||||
|
if (isToggling) return;
|
||||||
|
isToggling = true;
|
||||||
|
const icon = document.querySelector('#settings-icon i.settings-icon');
|
||||||
|
if (settingsMenu.classList.contains('open')) {
|
||||||
|
settingsMenu.classList.add('close');
|
||||||
|
icon.classList.replace('fa-solid', 'fa-regular');
|
||||||
|
setTimeout(() => {
|
||||||
|
settingsMenu.classList.remove('open', 'close');
|
||||||
|
isToggling = false;
|
||||||
|
}, 300);
|
||||||
|
} else {
|
||||||
|
settingsMenu.classList.add('open');
|
||||||
|
icon.classList.replace('fa-regular', 'fa-solid');
|
||||||
|
setTimeout(() => {
|
||||||
|
settingsMenu.classList.remove('close');
|
||||||
|
isToggling = false;
|
||||||
|
}, 300);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function switchTab(activeTab, activeContent, ...others) {
|
transportSelected.addEventListener('click', e => {
|
||||||
others.forEach(id => document.getElementById(id).classList.remove('active'));
|
e.stopPropagation();
|
||||||
document.getElementById(activeTab).classList.add('active');
|
transportOptions.classList.toggle('transport-show');
|
||||||
document.getElementById(activeContent).classList.add('active');
|
transportSelected.classList.toggle('transport-arrow-active');
|
||||||
}
|
|
||||||
|
|
||||||
document.getElementById('proxy-tab').addEventListener('click', () => switchTab('proxy-tab', 'proxy-content', 'cloak-tab', 'cloak-content', 'appearance-tab', 'appearance-content', 'info-tab', 'info-content'));
|
|
||||||
document.getElementById('cloak-tab').addEventListener('click', () => switchTab('cloak-tab', 'cloak-content', 'proxy-tab', 'proxy-content', 'appearance-tab', 'appearance-content', 'info-tab', 'info-content'));
|
|
||||||
document.getElementById('appearance-tab').addEventListener('click', () => switchTab('appearance-tab', 'appearance-content', 'proxy-tab', 'proxy-content', 'cloak-tab', 'cloak-content', 'info-tab', 'info-content'));
|
|
||||||
document.getElementById('info-tab').addEventListener('click', () => switchTab('info-tab', 'info-content', 'proxy-tab', 'proxy-content', 'cloak-tab', 'cloak-content', 'appearance-tab', 'appearance-content'));
|
|
||||||
|
|
||||||
document.querySelectorAll('.tab-button').forEach(btn => {
|
|
||||||
btn.addEventListener('click', function () {
|
|
||||||
const icon = this.querySelector('i');
|
|
||||||
if (!icon.classList.contains('fa-bounce')) {
|
|
||||||
icon.classList.add('fa-bounce');
|
|
||||||
setTimeout(() => icon.classList.remove('fa-bounce'), 750);
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
});
|
|
||||||
|
|
||||||
navbarToggle.addEventListener('change', function () {
|
Array.from(transportOptions.getElementsByTagName('div')).forEach(option => {
|
||||||
showToast(this.checked ? 'success' : 'error', `Navigation Bar ${this.checked ? 'enabled' : 'disabled'}`);
|
option.addEventListener('click', function(e) {
|
||||||
});
|
e.stopPropagation();
|
||||||
|
const val = this.textContent;
|
||||||
|
transportSelected.textContent = val;
|
||||||
|
localStorage.setItem('transport', val.toLowerCase());
|
||||||
|
transportOptions.classList.remove('transport-show');
|
||||||
|
transportSelected.classList.remove('transport-arrow-active');
|
||||||
|
document.dispatchEvent(new CustomEvent('newTransport', {
|
||||||
|
detail: val.toLowerCase()
|
||||||
|
}));
|
||||||
|
showToast('success', `Transport changed to ${val}`);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
initializeInfo();
|
document.getElementById('proxy-content').classList.add('active');
|
||||||
|
|
||||||
|
function switchTab(activeTab, activeContent, ...others) {
|
||||||
|
others.forEach(id => document.getElementById(id).classList.remove('active'));
|
||||||
|
document.getElementById(activeTab).classList.add('active');
|
||||||
|
document.getElementById(activeContent).classList.add('active');
|
||||||
|
}
|
||||||
|
|
||||||
|
document.getElementById('proxy-tab').addEventListener('click', () => switchTab('proxy-tab', 'proxy-content', 'cloak-tab', 'cloak-content', 'appearance-tab', 'appearance-content', 'info-tab', 'info-content'));
|
||||||
|
document.getElementById('cloak-tab').addEventListener('click', () => switchTab('cloak-tab', 'cloak-content', 'proxy-tab', 'proxy-content', 'appearance-tab', 'appearance-content', 'info-tab', 'info-content'));
|
||||||
|
document.getElementById('appearance-tab').addEventListener('click', () => switchTab('appearance-tab', 'appearance-content', 'proxy-tab', 'proxy-content', 'cloak-tab', 'cloak-content', 'info-tab', 'info-content'));
|
||||||
|
document.getElementById('info-tab').addEventListener('click', () => switchTab('info-tab', 'info-content', 'proxy-tab', 'proxy-content', 'cloak-tab', 'cloak-content', 'appearance-tab', 'appearance-content'));
|
||||||
|
|
||||||
|
document.querySelectorAll('.tab-button').forEach(btn => {
|
||||||
|
btn.addEventListener('click', function() {
|
||||||
|
const icon = this.querySelector('i');
|
||||||
|
if (!icon.classList.contains('fa-bounce')) {
|
||||||
|
icon.classList.add('fa-bounce');
|
||||||
|
setTimeout(() => icon.classList.remove('fa-bounce'), 750);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
navbarToggle.addEventListener('change', function() {
|
||||||
|
localStorage.setItem('navbarToggled', this.checked.toString());
|
||||||
|
showToast(this.checked ? 'success' : 'error', `Navigation Bar ${this.checked ? 'enabled' : 'disabled'}`);
|
||||||
|
if (window.APP && typeof window.APP.updateNavbarDisplay === 'function') {
|
||||||
|
window.APP.updateNavbarDisplay();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
initializeInfo();
|
||||||
});
|
});
|
|
@ -1,109 +1,147 @@
|
||||||
(function () {
|
(function(){
|
||||||
document.addEventListener('DOMContentLoaded', function () {
|
document.addEventListener('DOMContentLoaded', function(){
|
||||||
function getSearchInputs() {
|
const indicators = document.querySelectorAll('.shortcut-indicator, .shortcut-indicator-2, .shortcut-indicator-3, .shortcut-indicator-4');
|
||||||
return [
|
const arrowIndicators = document.querySelectorAll('.shortcut-indicator, .shortcut-indicator-2');
|
||||||
document.getElementById('searchInput'),
|
indicators.forEach(el => {
|
||||||
document.getElementById('searchInputt'),
|
if (!el.dataset.original) el.dataset.original = el.innerHTML;
|
||||||
document.getElementById('gameSearchInput'),
|
});
|
||||||
document.getElementById('appSearchInput')
|
|
||||||
].filter(Boolean);
|
function getSearchInputs(){
|
||||||
|
return [
|
||||||
|
document.getElementById('searchInput'),
|
||||||
|
document.getElementById('searchInputt'),
|
||||||
|
document.getElementById('gameSearchInput'),
|
||||||
|
document.getElementById('shortcutSearchInput')
|
||||||
|
].filter(Boolean);
|
||||||
|
}
|
||||||
|
|
||||||
|
function isVisible(el){
|
||||||
|
return !!(el.offsetWidth || el.offsetHeight || el.getClientRects().length);
|
||||||
|
}
|
||||||
|
|
||||||
|
function focusFirstVisibleInput(){
|
||||||
|
const inputs = getSearchInputs();
|
||||||
|
for (let inp of inputs) {
|
||||||
|
if (isVisible(inp)) {
|
||||||
|
inp.focus();
|
||||||
|
return inp;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
if (inputs[0]) {
|
||||||
function isVisible(el) {
|
inputs[0].focus();
|
||||||
return !!(el.offsetWidth || el.offsetHeight || el.getClientRects().length);
|
return inputs[0];
|
||||||
}
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
function focusFirstVisibleInput() {
|
let arrowMode = false;
|
||||||
const inputs = getSearchInputs();
|
|
||||||
for (const input of inputs) {
|
function updateIndicatorState(){
|
||||||
if (isVisible(input)) {
|
const hasText = getSearchInputs().some(i => i.value.trim() !== '');
|
||||||
input.focus();
|
if (hasText === arrowMode) return;
|
||||||
return;
|
arrowMode = hasText;
|
||||||
}
|
arrowIndicators.forEach(ind => {
|
||||||
}
|
ind.classList.remove('fadeIn');
|
||||||
if (inputs.length) {
|
ind.classList.add('fadeOut');
|
||||||
inputs[0].focus();
|
setTimeout(() => {
|
||||||
}
|
if (hasText) {
|
||||||
|
ind.innerHTML = '<i class="fa-solid fa-arrow-right"></i>';
|
||||||
|
ind.classList.add('arrow-mode');
|
||||||
|
} else {
|
||||||
|
ind.innerHTML = ind.dataset.original;
|
||||||
|
ind.classList.remove('arrow-mode');
|
||||||
|
}
|
||||||
|
ind.classList.remove('fadeOut');
|
||||||
|
ind.classList.add('fadeIn');
|
||||||
|
}, 100);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function triggerSubmit(input){
|
||||||
|
const query = input.value.trim();
|
||||||
|
if (!query) {
|
||||||
|
showToast('Please enter something in the Search Bar.','error','warning');
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
if (window.APP && typeof APP.handleSearch === 'function') {
|
||||||
|
APP.handleSearch(query);
|
||||||
|
if (input.id === 'searchInput') input.value = '';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
document.addEventListener('keydown', function (e) {
|
function handleIndicatorAction(){
|
||||||
if (e.key === 'Escape') {
|
const inputs = getSearchInputs().filter(isVisible);
|
||||||
const inputs = getSearchInputs();
|
const active = document.activeElement;
|
||||||
const active = document.activeElement;
|
if (inputs.includes(active) && active.value.trim()) {
|
||||||
if (inputs.includes(active)) {
|
triggerSubmit(active);
|
||||||
active.blur();
|
return;
|
||||||
e.preventDefault();
|
}
|
||||||
return;
|
const withText = inputs.find(i => i.value.trim());
|
||||||
}
|
if (withText) {
|
||||||
}
|
triggerSubmit(withText);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
focusFirstVisibleInput();
|
||||||
|
}
|
||||||
|
|
||||||
if (e.ctrlKey && e.key.toLowerCase() === 's') {
|
updateIndicatorState();
|
||||||
e.preventDefault();
|
getSearchInputs().forEach(i => i.addEventListener('input', updateIndicatorState));
|
||||||
focusFirstVisibleInput();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
document.querySelectorAll(
|
document.addEventListener('keydown', e => {
|
||||||
'.shortcut-indicator, .shortcut-indicator-2, .shortcut-indicator-3, .shortcut-indicator-4'
|
if (e.key === 'Escape') {
|
||||||
).forEach(function (el) {
|
const act = document.activeElement;
|
||||||
el.addEventListener('click', function (e) {
|
if (getSearchInputs().includes(act)) {
|
||||||
e.preventDefault();
|
act.blur();
|
||||||
focusFirstVisibleInput();
|
e.preventDefault();
|
||||||
});
|
}
|
||||||
});
|
}
|
||||||
|
if (e.ctrlKey && e.key.toLowerCase() === 's') {
|
||||||
|
e.preventDefault();
|
||||||
|
focusFirstVisibleInput();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
document.body.addEventListener('click', function (e) {
|
document.body.addEventListener('click', e => {
|
||||||
if (
|
const ind = e.target.closest('.shortcut-indicator, .shortcut-indicator-2, .shortcut-indicator-3, .shortcut-indicator-4');
|
||||||
e.target.classList.contains('shortcut-indicator') ||
|
if (!ind) return;
|
||||||
e.target.classList.contains('shortcut-indicator-2') ||
|
e.preventDefault();
|
||||||
e.target.classList.contains('shortcut-indicator-3') ||
|
if (ind.classList.contains('arrow-mode')) {
|
||||||
e.target.classList.contains('shortcut-indicator-4')
|
handleIndicatorAction();
|
||||||
) {
|
} else {
|
||||||
e.preventDefault();
|
focusFirstVisibleInput();
|
||||||
focusFirstVisibleInput();
|
}
|
||||||
}
|
});
|
||||||
});
|
|
||||||
|
|
||||||
const coolIframe = document.getElementById('cool-iframe');
|
const coolIframe = document.getElementById('cool-iframe');
|
||||||
if (coolIframe) {
|
if (coolIframe){
|
||||||
coolIframe.addEventListener('load', function () {
|
coolIframe.addEventListener('load', () => {
|
||||||
const doc = coolIframe.contentWindow.document;
|
const doc = coolIframe.contentWindow.document;
|
||||||
|
doc.addEventListener('keydown', innerE => {
|
||||||
doc.addEventListener('keydown', function (e) {
|
if (innerE.key === 'Escape') {
|
||||||
if (e.key === 'Escape') {
|
if (doc.activeElement.blur) doc.activeElement.blur();
|
||||||
if (doc.activeElement && doc.activeElement.blur) {
|
innerE.preventDefault();
|
||||||
doc.activeElement.blur();
|
}
|
||||||
e.preventDefault();
|
if (innerE.ctrlKey && innerE.key.toLowerCase() === 's') {
|
||||||
return;
|
innerE.preventDefault();
|
||||||
}
|
document.dispatchEvent(new KeyboardEvent('keydown', { key: 's', ctrlKey: true, bubbles: true }));
|
||||||
}
|
}
|
||||||
if (e.ctrlKey && e.key.toLowerCase() === 's') {
|
});
|
||||||
e.preventDefault();
|
doc.querySelectorAll('.shortcut-indicator, .shortcut-indicator-2, .shortcut-indicator-3, .shortcut-indicator-4')
|
||||||
document.dispatchEvent(new KeyboardEvent('keydown', {
|
.forEach(el => {
|
||||||
key: 's',
|
el.addEventListener('click', ev => {
|
||||||
ctrlKey: true
|
ev.preventDefault();
|
||||||
}));
|
window.parent.postMessage({ type: 'iframe-focus-search' }, '*');
|
||||||
}
|
|
||||||
});
|
});
|
||||||
|
});
|
||||||
doc.querySelectorAll(
|
|
||||||
'.shortcut-indicator, .shortcut-indicator-2, .shortcut-indicator-3, .shortcut-indicator-4'
|
|
||||||
).forEach(function (iframeEl) {
|
|
||||||
iframeEl.addEventListener('click', function (e) {
|
|
||||||
e.preventDefault();
|
|
||||||
window.parent.postMessage({
|
|
||||||
type: 'iframe-focus-search'
|
|
||||||
}, '*');
|
|
||||||
});
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
window.addEventListener('message', function (event) {
|
|
||||||
const msg = event.data;
|
|
||||||
if (msg.type === 'iframe-focus-search') {
|
|
||||||
focusFirstVisibleInput();
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
});
|
}
|
||||||
|
|
||||||
|
window.addEventListener('message', msgEvt => {
|
||||||
|
if (msgEvt.data?.type === 'iframe-focus-search'){
|
||||||
|
const inp = focusFirstVisibleInput();
|
||||||
|
if (inp && inp.value.trim()) triggerSubmit(inp);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
});
|
||||||
})();
|
})();
|
1085
public/wah/cute2.js
1085
public/wah/cute2.js
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user