feat: Introduce a Python health checker, reorganize static assets and data, and remove Zsh helper scripts.

This commit is contained in:
Marco Gallegos
2025-12-17 19:38:01 -06:00
parent 0d4601385c
commit e8d8a58c46
12 changed files with 422 additions and 728 deletions

14
htmls/README.md Normal file
View File

@@ -0,0 +1,14 @@
# HTML Templates
This directory contains HTML files that serve as templates or specific pages for the application, not meant to be served as static assets from the root.
## Organization
* `telegram.html`: A specific HTML page used for Telegram redirection logic.
* Other `.html` files: Should be specific templates or special pages.
## Best Practices
* HTML files in this directory are typically served dynamically by the Express server for specific routes.
* Keep the HTML semantic and clean.
* Avoid placing general static HTML assets here; those should reside in the project root if they are meant to be served as part of the primary static content.

53
htmls/telegram.html Normal file
View File

@@ -0,0 +1,53 @@
<!DOCTYPE html>
<html>
<head>
<title>Redirecting to Telegram...</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
</head>
<body>
<p>If you are not redirected automatically, <a href="https://telegram.org/apps">click here</a>.</p>
<script>
(function() {
var userAgent = navigator.userAgent || navigator.vendor || window.opera;
var telegramUrl = "tg://";
var iosAppStoreUrl = "https://apps.apple.com/es/app/telegram-messenger/id686449807";
var androidPlayStoreUrl = "https://play.google.com/store/apps/details?id=org.telegram.messenger&pcampaignid=web_share";
var fallbackUrl = "https://telegram.org/apps";
var isIOS = /iPad|iPhone|iPod/.test(userAgent) && !window.MSStream;
var isAndroid = /android/i.test(userAgent);
window.location.replace(telegramUrl);
var timeout;
if (isIOS) {
timeout = setTimeout(function() {
window.location.replace(iosAppStoreUrl);
}, 2000);
} else if (isAndroid) {
timeout = setTimeout(function() {
window.location.replace(androidPlayStoreUrl);
}, 2000);
} else {
timeout = setTimeout(function() {
window.location.replace(fallbackUrl);
}, 2000);
}
// Clear the timeout if the app opens successfully
function clearFallbackTimeout() {
clearTimeout(timeout);
}
window.addEventListener("pagehide", clearFallbackTimeout);
window.addEventListener("blur", clearFallbackTimeout);
document.addEventListener("visibilitychange", function() {
if (document.hidden) {
clearFallbackTimeout();
}
});
})();
</script>
</body>
</html>