Merge pull request 'main' (#4) from ashley/poke:main into main

Reviewed-on: https://codeberg.org/Korbs/poke/pulls/4
This commit is contained in:
Korbs 2024-05-10 07:09:15 +00:00
commit adf09e5dfa
5 changed files with 45 additions and 10 deletions

View file

@ -82,6 +82,14 @@ document.addEventListener('DOMContentLoaded', function() {
window.addEventListener('resize', lazyLoadBg);
});
const htmlContent = `<!DOCTYPE html><html><head><title>Browser is not supported :p</title><style>body{margin-left:auto;margin-right:auto;display:flex;max-width:43em;font-family:sans-serif;background-color:white;}</style></head><body><h1>Heyo :3</h1><br><p style="margin-top:4em;margin-left:-7.4em;">hoi - poke does and <b>will not work</b> on Internet Explorer :p<br>if u wanna use poke try using Firefox (firefox.com) or Chromium :3<br>love u :3</p></body></html>`;
if (/MSIE \d|Trident.*rv:/.test(navigator.userAgent)) {
document.open();
document.write(htmlContent);
document.close();
}
// Fade in elements on scroll or fullscreen change
function fadeInElements() {
const elements = document.querySelectorAll('.fade-in');

View file

@ -1993,7 +1993,7 @@ window.addEventListener("unload", cleanup)
<!-- BUNDLE -->
<!-- BUNDLE -->
<!-- BUNDLE -->
<!-- BUNDLE --><script src="/static/app.bundle.js?version=25.01.2024&bundledate=250124_1120" > </script><!-- BUNDLE -->
<!-- BUNDLE --><script src="/static/app.bundle.js?version=08.05.2024&bundledate=080524_1657" > </script><!-- BUNDLE -->
<!-- BUNDLE -->
<!-- BUNDLE -->
<!-- BUNDLE -->

View file

@ -8,9 +8,9 @@
"proxy": true,
"official": true,
"DEFAULT": true,
"region": "🇺🇸",
"region": "🇩🇪",
"software": {
"name": "poketube",
"name": "poke",
"version": "lastest",
"branch": "dev"
}
@ -24,7 +24,7 @@
"piwik": false,
"region": "🇺🇸",
"software": {
"name": "poketube",
"name": "poke",
"version": "lastest",
"branch": "dev"
}
@ -38,7 +38,7 @@
"piwik": false,
"region": "🇺🇸",
"software": {
"name": "poketube",
"name": "poke",
"version": "latest",
"branch": "dev"
}
@ -52,7 +52,7 @@
"piwik": false,
"region": "🇬🇧",
"software": {
"name": "poketube",
"name": "poke",
"version": "latest",
"branch": "dev"
}
@ -67,7 +67,7 @@
"proxy": false,
"region": "🇺🇸",
"software": {
"name": "poketube",
"name": "poke",
"version": "latest",
"branch": "dev"
}
@ -97,7 +97,7 @@
"proxy": false,
"region": "🇳🇱",
"software": {
"name": "poketube",
"name": "poke",
"version": "latest",
"branch": "dev"
}
@ -111,7 +111,21 @@
"proxy": false,
"region": "🇳🇱",
"software": {
"name": "poketube",
"name": "poke",
"version": "latest",
"branch": "dev"
}
}
], [
"poke.blahai.gay",
{
"uri": "https://poke.blahai.gay/",
"CLOUDFLARE": true,
"piwik": false,
"proxy": false,
"region": "🇩🇪",
"software": {
"name": "poke",
"version": "latest",
"branch": "dev"
}

View file

@ -30,6 +30,7 @@ const pkg = require("../../../package.json");
const os = require('os');
const cnf = require("../../../config.json");
const innertube = require("../libpoketube-youtubei-objects.json");
const { exec } = require('child_process');
const verfull = "v24.0605-VeE-MINOR_UPDATE-stable-dev-nonLTS-git-MTcxNTAwOTczNQ==";
const versmol = "v24.0605-vEe"
@ -211,6 +212,8 @@ app.use("/sb/i/:v/:imagePath/:img", async function (req, res) {
});
app.get("/api/version.json", async (req, res) => {
let latestCommitHash;
const invidious = await modules
.fetch("https://invid-api.poketube.fun/api/v1/stats")
.then((res) => res.text())
@ -220,12 +223,22 @@ app.use("/sb/i/:v/:imagePath/:img", async function (req, res) {
const totalMemory = os.totalmem() / (1024 * 1024 * 1024);
const roundedMemory = totalMemory.toFixed(2);
exec('git rev-list HEAD -n 1 --abbrev-commit', (error, stdout, stderr) => {
if (error || stderr) {
console.error(`Error executing command: ${error || stderr}`);
return;
}
latestCommitHash = stdout.trim();
});
const response = {
pt_version: {
version:versmol,
version_full:verfull
},
branch,
commit: latestCommitHash,
updatequote,
relaseunixdate,
vernum: versionnumber,

View file

@ -14,7 +14,7 @@
"INNERTUBE_CONTEXT_CLIENT_NAME": "1",
"INNERTUBE_CONTEXT_CLIENT_VERSION": "2.20240214.05.00",
"INNERTUBE_CONTEXT_GL": "US",
"INNERTUBE_CONTEXT_HL": "en-US"
"INNERTUBE_CONTEXT_HL": "en"
},
"LATEST_ECATCHER_SERVICE_PARAMS": { "client.name": "WEB" },
"INNERTUBE_API_KEYS": {