From da0d372737a96f3e30274c4ad049ab79c073178d Mon Sep 17 00:00:00 2001 From: Zinibow Date: Tue, 6 Jan 2026 19:00:17 -0800 Subject: [PATCH 01/31] Add Psychonaut Wiki activity --- websites/P/PsychonautWiki/metadata.json | 24 +++++++++++ websites/P/PsychonautWiki/presence.ts | 57 +++++++++++++++++++++++++ 2 files changed, 81 insertions(+) create mode 100644 websites/P/PsychonautWiki/metadata.json create mode 100644 websites/P/PsychonautWiki/presence.ts diff --git a/websites/P/PsychonautWiki/metadata.json b/websites/P/PsychonautWiki/metadata.json new file mode 100644 index 000000000000..6bd3be2301f9 --- /dev/null +++ b/websites/P/PsychonautWiki/metadata.json @@ -0,0 +1,24 @@ +{ + "$schema": "https://schemas.premid.app/metadata/1.15", + "apiVersion": 1, + "author": { + "id": "538604507064696832", + "name": "talon2" + }, + "service": "PsychonautWiki", + "description": { + "en": "PsychonautWiki is a community-driven encyclopedia documenting Psychonautics with evidence-based sources to promote education, safe practices, and personal autonomy" + }, + "url": "psychonautwiki.org", + "version": "1.0.0", + "logo": "https://i.imgur.com/8BOtvbS.jpeg", + "thumbnail": "https://i.imgur.com/8BOtvbS.jpeg", + "color": "#000000", + "category": "other", + "tags": [ + "wiki", + "encyclopedia", + "psychonaut", + "drugs" + ] +} diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts new file mode 100644 index 000000000000..b376fa61f609 --- /dev/null +++ b/websites/P/PsychonautWiki/presence.ts @@ -0,0 +1,57 @@ +import { Assets } from 'premid' + +const browsingTimestamp = Math.floor(Date.now() / 1000) + +function updatePresence() { + const location = document.location + const pathname = location?.pathname ?? '' + const search = location?.search ?? '' + + let pageName = 'Homepage' + let detailsText = 'Browsing Psychonaut Wiki' + + if (pathname === '/wiki/Main_Page') { + pageName = 'Main Page' + detailsText = 'Browsing Main Page' + } else if (pathname.startsWith('/wiki/User:')) { + const parts = pathname.split('/') + const username = + parts.length >= 3 && parts[2] + ? decodeURIComponent(parts[2].replace(/_/g, ' ')) + : 'Unknown User' + pageName = username + detailsText = `Viewing user "${username}"'s page` + } else if (pathname.startsWith('/w/index.php') && search.includes('action=history')) { + const params = new URLSearchParams(search) + const titleParam = params.get('title') + const title = titleParam + ? decodeURIComponent(titleParam.replace(/_/g, ' ')) + : 'Unknown Page' + pageName = title + detailsText = `Viewing revision history of "${title}"` + } else if (pathname.startsWith('/wiki/')) { + const parts = pathname.split('/') + const article = + parts.length >= 3 && parts[2] + ? decodeURIComponent(parts[2].replace(/_/g, ' ')) + : 'Unknown Article' + pageName = article + detailsText = 'Reading article' + } + + const presenceData = { + largeImageKey: 'https://i.imgur.com/8BOtvbS.jpeg', + details: detailsText, + state: pageName, + startTimestamp: browsingTimestamp, + } + + const pmid = (window as any)?.PMID + if (pmid && typeof pmid.setActivity === 'function') { + pmid.setActivity(presenceData) + } +} + +updatePresence() +window.addEventListener('popstate', updatePresence) +window.addEventListener('pushstate', updatePresence) From 5c775e89f419125d62353a1beee2c7555452ac4f Mon Sep 17 00:00:00 2001 From: Zinibow Date: Tue, 6 Jan 2026 19:20:30 -0800 Subject: [PATCH 02/31] Fixed Code --- websites/P/PsychonautWiki/metadata.json | 28 +++++---- websites/P/PsychonautWiki/presence.ts | 76 ++++++++----------------- 2 files changed, 42 insertions(+), 62 deletions(-) diff --git a/websites/P/PsychonautWiki/metadata.json b/websites/P/PsychonautWiki/metadata.json index 6bd3be2301f9..591b590d8ee2 100644 --- a/websites/P/PsychonautWiki/metadata.json +++ b/websites/P/PsychonautWiki/metadata.json @@ -1,24 +1,30 @@ { - "$schema": "https://schemas.premid.app/metadata/1.15", - "apiVersion": 1, + "$schema": "https://schemas.premid.app/metadata/1.9", "author": { "id": "538604507064696832", "name": "talon2" }, "service": "PsychonautWiki", + "altnames": [ + "Psychonaut Wiki" + ], "description": { - "en": "PsychonautWiki is a community-driven encyclopedia documenting Psychonautics with evidence-based sources to promote education, safe practices, and personal autonomy" + "en": "PsychonautWiki is an encyclopedia that documents all aspects of psychonautic theory from an evidence-based perspective. It provides education, encourages safe practices, and emphasizes that substances should not be abused." }, "url": "psychonautwiki.org", "version": "1.0.0", - "logo": "https://i.imgur.com/8BOtvbS.jpeg", - "thumbnail": "https://i.imgur.com/8BOtvbS.jpeg", - "color": "#000000", + "logo": "https://i.imgur.com/6RhpGcI.png", + "thumbnail": "https://i.imgur.com/6RhpGcI.png", + "color": "#808080", "category": "other", "tags": [ - "wiki", - "encyclopedia", - "psychonaut", - "drugs" - ] + "drugs", + "harm-reduction", + "psychonaut" + ], + "regExp": "", + "iFrameRegExp": "", + "readLogs": false, + "warning": false, + "settings": [] } diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index b376fa61f609..5a2d75c4ad17 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -1,57 +1,31 @@ -import { Assets } from 'premid' +const presence = new Presence({ + clientId: "1432152324163502130", +}); -const browsingTimestamp = Math.floor(Date.now() / 1000) - -function updatePresence() { - const location = document.location - const pathname = location?.pathname ?? '' - const search = location?.search ?? '' - - let pageName = 'Homepage' - let detailsText = 'Browsing Psychonaut Wiki' +enum ActivityAssets { + Logo = "logo", +} - if (pathname === '/wiki/Main_Page') { - pageName = 'Main Page' - detailsText = 'Browsing Main Page' - } else if (pathname.startsWith('/wiki/User:')) { - const parts = pathname.split('/') - const username = - parts.length >= 3 && parts[2] - ? decodeURIComponent(parts[2].replace(/_/g, ' ')) - : 'Unknown User' - pageName = username - detailsText = `Viewing user "${username}"'s page` - } else if (pathname.startsWith('/w/index.php') && search.includes('action=history')) { - const params = new URLSearchParams(search) - const titleParam = params.get('title') - const title = titleParam - ? decodeURIComponent(titleParam.replace(/_/g, ' ')) - : 'Unknown Page' - pageName = title - detailsText = `Viewing revision history of "${title}"` - } else if (pathname.startsWith('/wiki/')) { - const parts = pathname.split('/') - const article = - parts.length >= 3 && parts[2] - ? decodeURIComponent(parts[2].replace(/_/g, ' ')) - : 'Unknown Article' - pageName = article - detailsText = 'Reading article' - } +presence.on("UpdateData", async () => { + const { pathname } = document.location; - const presenceData = { - largeImageKey: 'https://i.imgur.com/8BOtvbS.jpeg', - details: detailsText, - state: pageName, - startTimestamp: browsingTimestamp, - } + const presenceData: PresenceData = { + largeImageKey: ActivityAssets.Logo, + startTimestamp: Math.floor(Date.now() / 1000), + details: "Browsing PsychonautWiki", + state: "", + }; - const pmid = (window as any)?.PMID - if (pmid && typeof pmid.setActivity === 'function') { - pmid.setActivity(presenceData) + if (pathname === "/wiki/Main_Page") { + presenceData.state = "Browsing the Main Page"; + } else if (pathname.startsWith("/wiki/")) { + const articleName = decodeURIComponent( + pathname.replace("/wiki/", "").replace(/_/g, " ") + ); + presenceData.state = `Browsing the article "${articleName}"`; + } else { + presenceData.state = "Browsing the Wiki"; } -} -updatePresence() -window.addEventListener('popstate', updatePresence) -window.addEventListener('pushstate', updatePresence) + presence.setActivity(presenceData); +}); From 7ac34b85003165b5af318a7a62a2f96b54b40ab9 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Tue, 6 Jan 2026 19:30:13 -0800 Subject: [PATCH 03/31] Fixed Website Detection --- websites/P/PsychonautWiki/metadata.json | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/websites/P/PsychonautWiki/metadata.json b/websites/P/PsychonautWiki/metadata.json index 591b590d8ee2..58f1ddc7937e 100644 --- a/websites/P/PsychonautWiki/metadata.json +++ b/websites/P/PsychonautWiki/metadata.json @@ -9,9 +9,10 @@ "Psychonaut Wiki" ], "description": { - "en": "PsychonautWiki is an encyclopedia that documents all aspects of psychonautic theory from an evidence-based perspective. It provides education, encourages safe practices, and emphasizes that substances should not be abused." + "en": "PsychonautWiki is an encyclopedia that documents all aspects of psychonautic theory from an evidence-based perspective. It provides education, encourages safe practices, and emphasizes that substances should not be abused. Do not do drugs." }, "url": "psychonautwiki.org", + "regExp": "https?://(www\\.)?psychonautwiki\\.org/.*", "version": "1.0.0", "logo": "https://i.imgur.com/6RhpGcI.png", "thumbnail": "https://i.imgur.com/6RhpGcI.png", @@ -21,10 +22,5 @@ "drugs", "harm-reduction", "psychonaut" - ], - "regExp": "", - "iFrameRegExp": "", - "readLogs": false, - "warning": false, - "settings": [] + ] } From 420cfc60965df75dcda8b7b36fbf3989e4f91ff3 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Tue, 6 Jan 2026 19:48:35 -0800 Subject: [PATCH 04/31] Fixed Random Stuff --- websites/P/PsychonautWiki/metadata.json | 2 +- websites/P/PsychonautWiki/presence.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/websites/P/PsychonautWiki/metadata.json b/websites/P/PsychonautWiki/metadata.json index 58f1ddc7937e..3d22d332b449 100644 --- a/websites/P/PsychonautWiki/metadata.json +++ b/websites/P/PsychonautWiki/metadata.json @@ -23,4 +23,4 @@ "harm-reduction", "psychonaut" ] -} +} \ No newline at end of file diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index 5a2d75c4ad17..da77de15f20a 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -28,4 +28,4 @@ presence.on("UpdateData", async () => { } presence.setActivity(presenceData); -}); +}); \ No newline at end of file From 3dab617bdb30ab744272726b15158af9e5a24301 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Tue, 6 Jan 2026 20:23:28 -0800 Subject: [PATCH 05/31] Fixed Logos And Timestamps --- .vscode/settings.json | 2 +- websites/P/PsychonautWiki/metadata.json | 4 +-- websites/P/PsychonautWiki/presence.ts | 42 +++++++++++-------------- 3 files changed, 21 insertions(+), 27 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index 219811356583..bcb0f2e0cce7 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -49,7 +49,7 @@ ], // Other settings - "discord.enabled": false, + "discord.enabled": true, "yaml.schemas": { "https://json.schemastore.org/github-issue-config.json": "../.github/ISSUE_TEMPLATE/config.yml" } diff --git a/websites/P/PsychonautWiki/metadata.json b/websites/P/PsychonautWiki/metadata.json index 3d22d332b449..ca5cd4983d9c 100644 --- a/websites/P/PsychonautWiki/metadata.json +++ b/websites/P/PsychonautWiki/metadata.json @@ -14,8 +14,8 @@ "url": "psychonautwiki.org", "regExp": "https?://(www\\.)?psychonautwiki\\.org/.*", "version": "1.0.0", - "logo": "https://i.imgur.com/6RhpGcI.png", - "thumbnail": "https://i.imgur.com/6RhpGcI.png", + "logo": "https://i.imgur.com/GPxHYOV.png", + "thumbnail": "https://i.imgur.com/GPxHYOV.png", "color": "#808080", "category": "other", "tags": [ diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index da77de15f20a..16eda7831e52 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -1,31 +1,25 @@ +// Calculate the timestamp once at page load +const browsingTimestamp = Math.floor(Date.now() / 1000) + const presence = new Presence({ - clientId: "1432152324163502130", -}); + clientId: '1432152324163502130', +}) -enum ActivityAssets { - Logo = "logo", -} +presence.on('UpdateData', async () => { + if (document.location.hostname !== 'psychonautwiki.org') return -presence.on("UpdateData", async () => { - const { pathname } = document.location; + const pathname = document.location.pathname const presenceData: PresenceData = { - largeImageKey: ActivityAssets.Logo, - startTimestamp: Math.floor(Date.now() / 1000), - details: "Browsing PsychonautWiki", - state: "", - }; - - if (pathname === "/wiki/Main_Page") { - presenceData.state = "Browsing the Main Page"; - } else if (pathname.startsWith("/wiki/")) { - const articleName = decodeURIComponent( - pathname.replace("/wiki/", "").replace(/_/g, " ") - ); - presenceData.state = `Browsing the article "${articleName}"`; - } else { - presenceData.state = "Browsing the Wiki"; + largeImageKey: 'https://i.imgur.com/GPxHYOV.png', + startTimestamp: browsingTimestamp, // only set once + details: + pathname === '/wiki/Main_Page' + ? 'Browsing the Main Page' + : pathname.startsWith('/wiki/') + ? `Browsing the article "${decodeURIComponent(pathname.replace('/wiki/', '').replace(/_/g, ' '))}"` + : 'Browsing the Wiki', } - presence.setActivity(presenceData); -}); \ No newline at end of file + presence.setActivity(presenceData) +}) \ No newline at end of file From c4071aa3b6f31ca135c18f23bb5db7dcb1304747 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Tue, 6 Jan 2026 20:33:28 -0800 Subject: [PATCH 06/31] Fixed Random --- websites/P/PsychonautWiki/presence.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index 16eda7831e52..b8a78eb30711 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -1,4 +1,3 @@ -// Calculate the timestamp once at page load const browsingTimestamp = Math.floor(Date.now() / 1000) const presence = new Presence({ From cb8fa1a69ec14ce3903612c1f019c276466142fc Mon Sep 17 00:00:00 2001 From: Zinibow Date: Tue, 6 Jan 2026 20:34:38 -0800 Subject: [PATCH 07/31] Removed Comment --- websites/P/PsychonautWiki/presence.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index b8a78eb30711..9141d2ed0b81 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -11,7 +11,7 @@ presence.on('UpdateData', async () => { const presenceData: PresenceData = { largeImageKey: 'https://i.imgur.com/GPxHYOV.png', - startTimestamp: browsingTimestamp, // only set once + startTimestamp: browsingTimestamp, details: pathname === '/wiki/Main_Page' ? 'Browsing the Main Page' From 2e276cf5a0ae293e3d33cca015a917fc6ac4249c Mon Sep 17 00:00:00 2001 From: Zinibow Date: Tue, 6 Jan 2026 23:38:26 -0800 Subject: [PATCH 08/31] Fix ESLints Dumb Errors --- websites/P/PsychonautWiki/metadata.json | 2 +- websites/P/PsychonautWiki/presence.ts | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/websites/P/PsychonautWiki/metadata.json b/websites/P/PsychonautWiki/metadata.json index ca5cd4983d9c..209b8df7fbf4 100644 --- a/websites/P/PsychonautWiki/metadata.json +++ b/websites/P/PsychonautWiki/metadata.json @@ -23,4 +23,4 @@ "harm-reduction", "psychonaut" ] -} \ No newline at end of file +} diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index 9141d2ed0b81..f9b2c84ba29a 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -14,11 +14,11 @@ presence.on('UpdateData', async () => { startTimestamp: browsingTimestamp, details: pathname === '/wiki/Main_Page' - ? 'Browsing the Main Page' - : pathname.startsWith('/wiki/') - ? `Browsing the article "${decodeURIComponent(pathname.replace('/wiki/', '').replace(/_/g, ' '))}"` - : 'Browsing the Wiki', + ? 'Browsing the Main Page' + : pathname.startsWith('/wiki/') + ? `Browsing the article "${decodeURIComponent(pathname.replace('/wiki/', '').replace(/_/g, ' '))}"` + : 'Browsing the Wiki', } presence.setActivity(presenceData) -}) \ No newline at end of file +}) From 18d41e58693b32a74513f60f9fe200eb75461f2c Mon Sep 17 00:00:00 2001 From: Zinibow Date: Tue, 6 Jan 2026 23:45:47 -0800 Subject: [PATCH 09/31] Fix ESLints Dumb Errors V2 --- websites/P/PsychonautWiki/presence.ts | 32 ++++++++++++++------------- 1 file changed, 17 insertions(+), 15 deletions(-) diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index f9b2c84ba29a..84ec8ee16fbf 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -1,24 +1,26 @@ -const browsingTimestamp = Math.floor(Date.now() / 1000) +const browsingTimestamp = Math.floor(Date.now() / 1000); const presence = new Presence({ - clientId: '1432152324163502130', -}) + clientId: "1432152324163502130", +}); -presence.on('UpdateData', async () => { - if (document.location.hostname !== 'psychonautwiki.org') return +presence.on("UpdateData", async () => { + if (document.location.hostname !== "psychonautwiki.org") return; - const pathname = document.location.pathname + const pathname = document.location.pathname; const presenceData: PresenceData = { - largeImageKey: 'https://i.imgur.com/GPxHYOV.png', + largeImageKey: "https://i.imgur.com/GPxHYOV.png", startTimestamp: browsingTimestamp, details: - pathname === '/wiki/Main_Page' - ? 'Browsing the Main Page' - : pathname.startsWith('/wiki/') - ? `Browsing the article "${decodeURIComponent(pathname.replace('/wiki/', '').replace(/_/g, ' '))}"` - : 'Browsing the Wiki', - } + pathname === "/wiki/Main_Page" + ? "Browsing the Main Page" + : pathname.startsWith("/wiki/") + ? `Browsing the article "${decodeURIComponent( + pathname.replace("/wiki/", "").replace(/_/g, " "), + )}"` + : "Browsing the Wiki", + }; - presence.setActivity(presenceData) -}) + presence.setActivity(presenceData); +}); From 3ae0964b1d9b2145fd99ad6359c9f974b9b8c95a Mon Sep 17 00:00:00 2001 From: Zinibow Date: Tue, 6 Jan 2026 23:51:38 -0800 Subject: [PATCH 10/31] Fix ESLints Dumb Errors --- websites/P/PsychonautWiki/presence.ts | 32 +++++++++++++-------------- 1 file changed, 15 insertions(+), 17 deletions(-) diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index 84ec8ee16fbf..f8ba0ec30289 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -1,26 +1,24 @@ -const browsingTimestamp = Math.floor(Date.now() / 1000); +const browsingTimestamp = Math.floor(Date.now() / 1000) const presence = new Presence({ - clientId: "1432152324163502130", -}); + clientId: '1432152324163502130', +}) -presence.on("UpdateData", async () => { - if (document.location.hostname !== "psychonautwiki.org") return; +presence.on('UpdateData', async () => { + if (document.location.hostname !== 'psychonautwiki.org') return - const pathname = document.location.pathname; + const pathname = document.location.pathname const presenceData: PresenceData = { - largeImageKey: "https://i.imgur.com/GPxHYOV.png", + largeImageKey: 'https://i.imgur.com/GPxHYOV.png', startTimestamp: browsingTimestamp, details: - pathname === "/wiki/Main_Page" - ? "Browsing the Main Page" - : pathname.startsWith("/wiki/") - ? `Browsing the article "${decodeURIComponent( - pathname.replace("/wiki/", "").replace(/_/g, " "), - )}"` - : "Browsing the Wiki", - }; + pathname === '/wiki/Main_Page' + ? 'Browsing the Main Page' + : pathname.startsWith('/wiki/') + ? `Browsing the article "${decodeURIComponent(pathname.replace('/wiki/', '').replace(/_/g, ' '))}"` + : 'Browsing the Wiki', + } - presence.setActivity(presenceData); -}); + presence.setActivity(presenceData) +}) \ No newline at end of file From f708327888ab4114176b19c5cd22936d40afe346 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Tue, 6 Jan 2026 23:58:30 -0800 Subject: [PATCH 11/31] Fix ESLints Dumb Errors V2 --- websites/P/PsychonautWiki/presence.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index f8ba0ec30289..ce53e5a694ba 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -14,11 +14,11 @@ presence.on('UpdateData', async () => { startTimestamp: browsingTimestamp, details: pathname === '/wiki/Main_Page' - ? 'Browsing the Main Page' - : pathname.startsWith('/wiki/') + ? 'Browsing the Main Page' + : pathname.startsWith('/wiki/') ? `Browsing the article "${decodeURIComponent(pathname.replace('/wiki/', '').replace(/_/g, ' '))}"` : 'Browsing the Wiki', } presence.setActivity(presenceData) -}) \ No newline at end of file +}) From 51c7ec1865ca958f35787e5fc62c91c307ecb880 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Wed, 7 Jan 2026 00:03:03 -0800 Subject: [PATCH 12/31] Fix ESLints Dumb Errors FINAL --- websites/P/PsychonautWiki/presence.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index ce53e5a694ba..7333259597c6 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -7,6 +7,7 @@ const presence = new Presence({ presence.on('UpdateData', async () => { if (document.location.hostname !== 'psychonautwiki.org') return + const pathname = document.location.pathname const presenceData: PresenceData = { From b9547e3b2f64dea4b27453809e0019577307998b Mon Sep 17 00:00:00 2001 From: Zinibow Date: Wed, 7 Jan 2026 00:09:13 -0800 Subject: [PATCH 13/31] Fix ESLints Dumb Errors Final V2 --- websites/P/PsychonautWiki/presence.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index 7333259597c6..ce53e5a694ba 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -7,7 +7,6 @@ const presence = new Presence({ presence.on('UpdateData', async () => { if (document.location.hostname !== 'psychonautwiki.org') return - const pathname = document.location.pathname const presenceData: PresenceData = { From cdc9ec9cf44d496f56b02ff2ff7d1bb01e757b98 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Wed, 7 Jan 2026 19:06:54 -0800 Subject: [PATCH 14/31] Added Editing Articles --- .vscode/settings.json | 4 +- package-lock.json | 78 +++++++++++++++++++-------- package.json | 1 - websites/P/PsychonautWiki/presence.ts | 53 ++++++++++++------ 4 files changed, 95 insertions(+), 41 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index bcb0f2e0cce7..d421a1d64964 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,7 +1,7 @@ { // Disable the default formatter, use eslint instead - "prettier.enable": false, - "editor.formatOnSave": false, + "prettier.enable": true, + "editor.formatOnSave": true, // Auto fix "editor.codeActionsOnSave": { diff --git a/package-lock.json b/package-lock.json index af8545407b66..c7d15e7b8eef 100644 --- a/package-lock.json +++ b/package-lock.json @@ -12,7 +12,6 @@ "@types/node": "^24.9.2", "@vitest/coverage-v8": "^4.0.6", "@vitest/ui": "^4.0.6", - "eslint": "^9.38.0", "eslint-plugin-format": "^1.0.2", "eslint-plugin-json-schema-validator": "^5.4.1", "pmd": "file:cli", @@ -1071,9 +1070,9 @@ } }, "node_modules/@eslint/js": { - "version": "9.38.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.38.0.tgz", - "integrity": "sha512-UZ1VpFvXf9J06YG9xQBdnzU+kthors6KjhMAl6f4gH4usHyh31rUf2DLGInT8RFYIReYXNSydgPY0V2LuWgl7A==", + "version": "9.39.2", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.39.2.tgz", + "integrity": "sha512-q1mjIoW1VX4IvSocvM/vbTiveKC4k9eLrajNEuSsmjymSDEbpGddtpfOoN7YGAqBK3NG+uqo8ia4PDTt8buCYA==", "dev": true, "license": "MIT", "engines": { @@ -1118,19 +1117,32 @@ } }, "node_modules/@eslint/plugin-kit": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.4.0.tgz", - "integrity": "sha512-sB5uyeq+dwCWyPi31B2gQlVlo+j5brPlWx4yZBrEaRo/nhdDE8Xke1gsGgtiBdaBTxuTkceLVuVt/pclrasb0A==", + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.4.1.tgz", + "integrity": "sha512-43/qtrDUokr7LJqoF2c3+RInu/t4zfrpYdoSDfYyhg52rwLV6TnOvdG4fXm7IkSB3wErkcmJS9iEhjVtOSEjjA==", "dev": true, "license": "Apache-2.0", "dependencies": { - "@eslint/core": "^0.16.0", + "@eslint/core": "^0.17.0", "levn": "^0.4.1" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" } }, + "node_modules/@eslint/plugin-kit/node_modules/@eslint/core": { + "version": "0.17.0", + "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.17.0.tgz", + "integrity": "sha512-yL/sLrpmtDaFEiUj1osRP4TI2MDz1AddJL+jZ7KSqvBuliN4xqYY54IfdN8qD8Toa6g1iloph1fxQNkjOxrrpQ==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "@types/json-schema": "^7.0.15" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + } + }, "node_modules/@fastify/busboy": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/@fastify/busboy/-/busboy-2.1.1.tgz", @@ -2096,6 +2108,7 @@ "integrity": "sha512-1LFfa/qnMQvEOAdzlQymH0ulepxbxnCYAKJZfMci/5XJyIHWgEYnDmgnKakbTh7CH2tFQ5O60oYDvns4i9RAIg==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "@octokit/auth-token": "^4.0.0", "@octokit/graphql": "^7.1.0", @@ -2639,6 +2652,7 @@ "integrity": "sha512-IeZF+8H0ns6prg4VrkhgL+yrvDXWDH2cKchrbh80ejG9dQgZWp10epHMbgRuQvgchLII/lfh6Xn3lu6+6L86Hw==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "@eslint-community/eslint-utils": "^4.9.0", "@typescript-eslint/types": "^8.46.1", @@ -2809,6 +2823,7 @@ "integrity": "sha512-uWN8YqxXxqFMX2RqGOrumsKeti4LlmIMIyV0lgut4jx7KQBcBiW6vkDtIBvHnHIquwNfJhk8v2OtmO8zXWHfPA==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "undici-types": "~7.16.0" } @@ -2890,6 +2905,7 @@ "integrity": "sha512-BnOroVl1SgrPLywqxyqdJ4l3S2MsKVLDVxZvjI1Eoe8ev2r3kGDo+PcMihNmDE+6/KjkTubSJnmqGZZjQSBq/g==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "@typescript-eslint/scope-manager": "8.46.2", "@typescript-eslint/types": "8.46.2", @@ -3284,7 +3300,6 @@ "integrity": "sha512-oOdAkwqUfW1WqpwSYJce06wvt6HljgY3fGeM9NcVA1HaYOij3mZG9Rkysn0OHuyUAGMbEbARIpsG+LPVlBJ5/Q==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@babel/parser": "^7.25.3", "@vue/shared": "3.5.13", @@ -3299,7 +3314,6 @@ "integrity": "sha512-ZOJ46sMOKUjO3e94wPdCzQ6P1Lx/vhp2RSvfaab88Ajexs0AHeV0uasYhi99WPaogmBlRHNRuly8xV75cNTMDA==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@vue/compiler-core": "3.5.13", "@vue/shared": "3.5.13" @@ -3330,7 +3344,6 @@ "integrity": "sha512-wMH6vrYHxQl/IybKJagqbquvxpWCuVYpoUJfCqFZwa/JY1GdATAQ+TgVtgrwwMZ0D07QhA99rs/EAAWfvG6KpA==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@vue/compiler-dom": "3.5.13", "@vue/shared": "3.5.13" @@ -3341,8 +3354,7 @@ "resolved": "https://registry.npmjs.org/@vue/shared/-/shared-3.5.13.tgz", "integrity": "sha512-/hnE/qP5ZoGpol0a5mDi45bOd7t3tjYJBjsgCsivow7D48cJeV5l05RD82lPqi7gRiphZM37rnhW1l6ZoCNNnQ==", "dev": true, - "license": "MIT", - "peer": true + "license": "MIT" }, "node_modules/acorn": { "version": "8.15.0", @@ -3350,6 +3362,7 @@ "integrity": "sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg==", "dev": true, "license": "MIT", + "peer": true, "bin": { "acorn": "bin/acorn" }, @@ -3600,6 +3613,7 @@ } ], "license": "MIT", + "peer": true, "dependencies": { "baseline-browser-mapping": "^2.8.19", "caniuse-lite": "^1.0.30001751", @@ -4224,7 +4238,6 @@ "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==", "dev": true, "license": "BSD-2-Clause", - "peer": true, "engines": { "node": ">=0.12" }, @@ -4354,20 +4367,21 @@ } }, "node_modules/eslint": { - "version": "9.38.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.38.0.tgz", - "integrity": "sha512-t5aPOpmtJcZcz5UJyY2GbvpDlsK5E8JqRqoKtfiKE3cNh437KIqfJr3A3AKf5k64NPx6d0G3dno6XDY05PqPtw==", + "version": "9.39.2", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.39.2.tgz", + "integrity": "sha512-LEyamqS7W5HB3ujJyvi0HQK/dtVINZvd5mAAp9eT5S/ujByGjiZLCzPcHVzuXbpJDJF/cxwHlfceVUDZ2lnSTw==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "@eslint-community/eslint-utils": "^4.8.0", "@eslint-community/regexpp": "^4.12.1", "@eslint/config-array": "^0.21.1", - "@eslint/config-helpers": "^0.4.1", - "@eslint/core": "^0.16.0", + "@eslint/config-helpers": "^0.4.2", + "@eslint/core": "^0.17.0", "@eslint/eslintrc": "^3.3.1", - "@eslint/js": "9.38.0", - "@eslint/plugin-kit": "^0.4.0", + "@eslint/js": "9.39.2", + "@eslint/plugin-kit": "^0.4.1", "@humanfs/node": "^0.16.6", "@humanwhocodes/module-importer": "^1.0.1", "@humanwhocodes/retry": "^0.4.2", @@ -4589,6 +4603,7 @@ "integrity": "sha512-ySrDaLQZbreNAr/Betq6ocd5Hxy3+LBIfWNV2621EQQ6yGf/ZSLtN2MiM62WO2YQTX+nSFhv332Tpp51q+AkZQ==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "@dprint/formatter": "^0.3.0", "@dprint/markdown": "^0.17.8", @@ -5116,6 +5131,19 @@ "url": "https://opencollective.com/eslint" } }, + "node_modules/eslint/node_modules/@eslint/core": { + "version": "0.17.0", + "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.17.0.tgz", + "integrity": "sha512-yL/sLrpmtDaFEiUj1osRP4TI2MDz1AddJL+jZ7KSqvBuliN4xqYY54IfdN8qD8Toa6g1iloph1fxQNkjOxrrpQ==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "@types/json-schema": "^7.0.15" + }, + "engines": { + "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + } + }, "node_modules/eslint/node_modules/brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", @@ -5199,8 +5227,7 @@ "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-2.0.2.tgz", "integrity": "sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==", "dev": true, - "license": "MIT", - "peer": true + "license": "MIT" }, "node_modules/esutils": { "version": "2.0.3", @@ -6196,6 +6223,7 @@ "integrity": "sha512-uuPNLJkKN8NXAlZlQ6kmUF9qO+T6Kyd7oV4+/7yy8Jz6+MZNyhPq8EdLpdfnPVzUC8qSf1b4j1azKaGnFsjmsw==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "acorn": "^8.5.0", "eslint-visitor-keys": "^3.0.0", @@ -8793,6 +8821,7 @@ "integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==", "dev": true, "license": "Apache-2.0", + "peer": true, "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" @@ -8961,6 +8990,7 @@ "integrity": "sha512-ZWyE8YXEXqJrrSLvYgrRP7p62OziLW7xI5HYGWFzOvupfAlrLvURSzv/FyGyy0eidogEM3ujU+kUG1zuHgb6Ug==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "esbuild": "^0.25.0", "fdir": "^6.5.0", @@ -9036,6 +9066,7 @@ "integrity": "sha512-gR7INfiVRwnEOkCk47faros/9McCZMp5LM+OMNWGLaDBSvJxIzwjgNFufkuePBNaesGRnLmNfW+ddbUJRZn0nQ==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "@vitest/expect": "4.0.6", "@vitest/mocker": "4.0.6", @@ -9121,6 +9152,7 @@ "integrity": "sha512-CydUvFOQKD928UzZhTp4pr2vWz1L+H99t7Pkln2QSPdvmURT0MoC4wUccfCnuEaihNsu9aYYyk+bep8rlfkUXw==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "debug": "^4.4.0", "eslint-scope": "^8.2.0", diff --git a/package.json b/package.json index 697895b9c1ec..408bb2307d8f 100644 --- a/package.json +++ b/package.json @@ -18,7 +18,6 @@ "@types/node": "^24.9.2", "@vitest/coverage-v8": "^4.0.6", "@vitest/ui": "^4.0.6", - "eslint": "^9.38.0", "eslint-plugin-format": "^1.0.2", "eslint-plugin-json-schema-validator": "^5.4.1", "pmd": "file:cli", diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index ce53e5a694ba..d41e0502705e 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -1,24 +1,47 @@ -const browsingTimestamp = Math.floor(Date.now() / 1000) +const browsingTimestamp = Math.floor(Date.now() / 1000); const presence = new Presence({ - clientId: '1432152324163502130', -}) + clientId: "1432152324163502130", +}); -presence.on('UpdateData', async () => { - if (document.location.hostname !== 'psychonautwiki.org') return +presence.on("UpdateData", async () => { + if (document.location.hostname !== "psychonautwiki.org") return; - const pathname = document.location.pathname + const { pathname, search } = document.location; + const params = new URLSearchParams(search); + + let articleName: string | null = null; + + if (pathname.startsWith("/w/index.php") && params.has("title")) { + articleName = decodeURIComponent(params.get("title")!) + .replace(/_/g, " ") + .trim(); + } else if (pathname.startsWith("/wiki/")) { + articleName = decodeURIComponent(pathname.replace("/wiki/", "")) + .replace(/_/g, " ") + .trim(); + } + + const action = params.get("action"); + const isEditing = + params.has("veaction") || action === "edit" || action === "submit"; const presenceData: PresenceData = { - largeImageKey: 'https://i.imgur.com/GPxHYOV.png', + largeImageKey: "https://i.imgur.com/GPxHYOV.png", startTimestamp: browsingTimestamp, - details: - pathname === '/wiki/Main_Page' - ? 'Browsing the Main Page' - : pathname.startsWith('/wiki/') - ? `Browsing the article "${decodeURIComponent(pathname.replace('/wiki/', '').replace(/_/g, ' '))}"` - : 'Browsing the Wiki', + }; + + if (isEditing) { + presenceData.details = articleName + ? `Editing article "${articleName}"` + : "Editing article"; + } else if (pathname === "/wiki/Main_Page") { + presenceData.details = "Browsing the Main Page"; + } else if (articleName) { + presenceData.details = `Browsing the article "${articleName}"`; + } else { + presenceData.details = "Browsing the Wiki"; } - presence.setActivity(presenceData) -}) + presence.setActivity(presenceData); +}); From 8f482645ea0ee276e814852e0a6452351db5a953 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Wed, 7 Jan 2026 20:20:20 -0800 Subject: [PATCH 15/31] Fixed All ESLint Issues --- cli/src/commands/checkDns.ts | 1 - package-lock.json | 41 ++++++++++++-------------------- package.json | 2 ++ websites/K/Kayoanime/presence.ts | 2 -- 4 files changed, 17 insertions(+), 29 deletions(-) diff --git a/cli/src/commands/checkDns.ts b/cli/src/commands/checkDns.ts index d84d60415ef9..fbaf6baf36a5 100644 --- a/cli/src/commands/checkDns.ts +++ b/cli/src/commands/checkDns.ts @@ -52,7 +52,6 @@ export async function checkDns( fix?: boolean } = {}, ) { - let activities: ActivityMetadataAndFolder[] = [] if (all) { diff --git a/package-lock.json b/package-lock.json index c7d15e7b8eef..e31242bd5478 100644 --- a/package-lock.json +++ b/package-lock.json @@ -12,6 +12,8 @@ "@types/node": "^24.9.2", "@vitest/coverage-v8": "^4.0.6", "@vitest/ui": "^4.0.6", + "baseline-browser-mapping": "^2.9.12", + "eslint": "^9.38.0", "eslint-plugin-format": "^1.0.2", "eslint-plugin-json-schema-validator": "^5.4.1", "pmd": "file:cli", @@ -1070,9 +1072,9 @@ } }, "node_modules/@eslint/js": { - "version": "9.39.2", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.39.2.tgz", - "integrity": "sha512-q1mjIoW1VX4IvSocvM/vbTiveKC4k9eLrajNEuSsmjymSDEbpGddtpfOoN7YGAqBK3NG+uqo8ia4PDTt8buCYA==", + "version": "9.38.0", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.38.0.tgz", + "integrity": "sha512-UZ1VpFvXf9J06YG9xQBdnzU+kthors6KjhMAl6f4gH4usHyh31rUf2DLGInT8RFYIReYXNSydgPY0V2LuWgl7A==", "dev": true, "license": "MIT", "engines": { @@ -3536,9 +3538,9 @@ "license": "MIT" }, "node_modules/baseline-browser-mapping": { - "version": "2.8.21", - "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.8.21.tgz", - "integrity": "sha512-JU0h5APyQNsHOlAM7HnQnPToSDQoEBZqzu/YBlqDnEeymPnZDREeXJA3KBMQee+dKteAxZ2AtvQEvVYdZf241Q==", + "version": "2.9.12", + "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.9.12.tgz", + "integrity": "sha512-Mij6Lij93pTAIsSYy5cyBQ975Qh9uLEc5rwGTpomiZeXZL9yIS6uORJakb3ScHgfs0serMMfIbXzokPMuEiRyw==", "dev": true, "license": "Apache-2.0", "bin": { @@ -4367,9 +4369,9 @@ } }, "node_modules/eslint": { - "version": "9.39.2", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.39.2.tgz", - "integrity": "sha512-LEyamqS7W5HB3ujJyvi0HQK/dtVINZvd5mAAp9eT5S/ujByGjiZLCzPcHVzuXbpJDJF/cxwHlfceVUDZ2lnSTw==", + "version": "9.38.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.38.0.tgz", + "integrity": "sha512-t5aPOpmtJcZcz5UJyY2GbvpDlsK5E8JqRqoKtfiKE3cNh437KIqfJr3A3AKf5k64NPx6d0G3dno6XDY05PqPtw==", "dev": true, "license": "MIT", "peer": true, @@ -4377,11 +4379,11 @@ "@eslint-community/eslint-utils": "^4.8.0", "@eslint-community/regexpp": "^4.12.1", "@eslint/config-array": "^0.21.1", - "@eslint/config-helpers": "^0.4.2", - "@eslint/core": "^0.17.0", + "@eslint/config-helpers": "^0.4.1", + "@eslint/core": "^0.16.0", "@eslint/eslintrc": "^3.3.1", - "@eslint/js": "9.39.2", - "@eslint/plugin-kit": "^0.4.1", + "@eslint/js": "9.38.0", + "@eslint/plugin-kit": "^0.4.0", "@humanfs/node": "^0.16.6", "@humanwhocodes/module-importer": "^1.0.1", "@humanwhocodes/retry": "^0.4.2", @@ -5131,19 +5133,6 @@ "url": "https://opencollective.com/eslint" } }, - "node_modules/eslint/node_modules/@eslint/core": { - "version": "0.17.0", - "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.17.0.tgz", - "integrity": "sha512-yL/sLrpmtDaFEiUj1osRP4TI2MDz1AddJL+jZ7KSqvBuliN4xqYY54IfdN8qD8Toa6g1iloph1fxQNkjOxrrpQ==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@types/json-schema": "^7.0.15" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, "node_modules/eslint/node_modules/brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", diff --git a/package.json b/package.json index 408bb2307d8f..9a5e874453a8 100644 --- a/package.json +++ b/package.json @@ -18,6 +18,8 @@ "@types/node": "^24.9.2", "@vitest/coverage-v8": "^4.0.6", "@vitest/ui": "^4.0.6", + "baseline-browser-mapping": "^2.9.12", + "eslint": "^9.38.0", "eslint-plugin-format": "^1.0.2", "eslint-plugin-json-schema-validator": "^5.4.1", "pmd": "file:cli", diff --git a/websites/K/Kayoanime/presence.ts b/websites/K/Kayoanime/presence.ts index bd790c61c526..9b9d18f1e9b2 100644 --- a/websites/K/Kayoanime/presence.ts +++ b/websites/K/Kayoanime/presence.ts @@ -27,7 +27,6 @@ presence.on( }, ) presence.on('UpdateData', async () => { - const fetch_img = document.querySelector('meta[property="og:image"]') ?.content @@ -58,7 +57,6 @@ presence.on('UpdateData', async () => { default: if (document.querySelector('.entry-header-outer > .entry-header > h1 ')) { - if (fetch_img) { presenceData.largeImageKey = fetch_img } From 879003f2e004ff2618c74315467a162e116d2687 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Wed, 7 Jan 2026 20:30:03 -0800 Subject: [PATCH 16/31] Fixed ESLint V2 --- .vscode/settings.json | 4 +- websites/P/PsychonautWiki/presence.ts | 65 ++++++++++++++------------- 2 files changed, 37 insertions(+), 32 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index d421a1d64964..bcb0f2e0cce7 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,7 +1,7 @@ { // Disable the default formatter, use eslint instead - "prettier.enable": true, - "editor.formatOnSave": true, + "prettier.enable": false, + "editor.formatOnSave": false, // Auto fix "editor.codeActionsOnSave": { diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index d41e0502705e..1282cefe5c90 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -1,47 +1,52 @@ -const browsingTimestamp = Math.floor(Date.now() / 1000); +const browsingTimestamp = Math.floor(Date.now() / 1000) const presence = new Presence({ - clientId: "1432152324163502130", -}); + clientId: '1432152324163502130', +}) -presence.on("UpdateData", async () => { - if (document.location.hostname !== "psychonautwiki.org") return; +presence.on('UpdateData', async () => { + if (document.location.hostname !== 'psychonautwiki.org') + return - const { pathname, search } = document.location; - const params = new URLSearchParams(search); + const { pathname, search } = document.location + const params = new URLSearchParams(search) - let articleName: string | null = null; + let articleName: string | null = null - if (pathname.startsWith("/w/index.php") && params.has("title")) { - articleName = decodeURIComponent(params.get("title")!) - .replace(/_/g, " ") - .trim(); - } else if (pathname.startsWith("/wiki/")) { - articleName = decodeURIComponent(pathname.replace("/wiki/", "")) - .replace(/_/g, " ") - .trim(); + if (pathname.startsWith('/w/index.php') && params.has('title')) { + articleName = decodeURIComponent(params.get('title')!) + .replace(/_/g, ' ') + .trim() + } + else if (pathname.startsWith('/wiki/')) { + articleName = decodeURIComponent(pathname.replace('/wiki/', '')) + .replace(/_/g, ' ') + .trim() } - const action = params.get("action"); - const isEditing = - params.has("veaction") || action === "edit" || action === "submit"; + const action = params.get('action') + const isEditing + = params.has('veaction') || action === 'edit' || action === 'submit' const presenceData: PresenceData = { - largeImageKey: "https://i.imgur.com/GPxHYOV.png", + largeImageKey: 'https://i.imgur.com/GPxHYOV.png', startTimestamp: browsingTimestamp, - }; + } if (isEditing) { presenceData.details = articleName ? `Editing article "${articleName}"` - : "Editing article"; - } else if (pathname === "/wiki/Main_Page") { - presenceData.details = "Browsing the Main Page"; - } else if (articleName) { - presenceData.details = `Browsing the article "${articleName}"`; - } else { - presenceData.details = "Browsing the Wiki"; + : 'Editing article' + } + else if (pathname === '/wiki/Main_Page') { + presenceData.details = 'Browsing the Main Page' + } + else if (articleName) { + presenceData.details = `Browsing the article "${articleName}"` + } + else { + presenceData.details = 'Browsing the Wiki' } - presence.setActivity(presenceData); -}); + presence.setActivity(presenceData) +}) From dcf3a439c746e32dc4b29f4b554fc0a07a28eafe Mon Sep 17 00:00:00 2001 From: Zinibow Date: Thu, 8 Jan 2026 14:31:21 -0800 Subject: [PATCH 17/31] Did Recommended Changes --- .vscode/settings.json | 2 +- cli/src/commands/checkDns.ts | 1 + package-lock.json | 51 ++++++++----------------- package.json | 1 - websites/K/Kayoanime/presence.ts | 2 + websites/P/PsychonautWiki/metadata.json | 4 +- 6 files changed, 21 insertions(+), 40 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index bcb0f2e0cce7..219811356583 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -49,7 +49,7 @@ ], // Other settings - "discord.enabled": true, + "discord.enabled": false, "yaml.schemas": { "https://json.schemastore.org/github-issue-config.json": "../.github/ISSUE_TEMPLATE/config.yml" } diff --git a/cli/src/commands/checkDns.ts b/cli/src/commands/checkDns.ts index fbaf6baf36a5..7375db1e5109 100644 --- a/cli/src/commands/checkDns.ts +++ b/cli/src/commands/checkDns.ts @@ -52,6 +52,7 @@ export async function checkDns( fix?: boolean } = {}, ) { + let activities: ActivityMetadataAndFolder[] = [] if (all) { diff --git a/package-lock.json b/package-lock.json index e31242bd5478..af8545407b66 100644 --- a/package-lock.json +++ b/package-lock.json @@ -12,7 +12,6 @@ "@types/node": "^24.9.2", "@vitest/coverage-v8": "^4.0.6", "@vitest/ui": "^4.0.6", - "baseline-browser-mapping": "^2.9.12", "eslint": "^9.38.0", "eslint-plugin-format": "^1.0.2", "eslint-plugin-json-schema-validator": "^5.4.1", @@ -1119,32 +1118,19 @@ } }, "node_modules/@eslint/plugin-kit": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.4.1.tgz", - "integrity": "sha512-43/qtrDUokr7LJqoF2c3+RInu/t4zfrpYdoSDfYyhg52rwLV6TnOvdG4fXm7IkSB3wErkcmJS9iEhjVtOSEjjA==", + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.4.0.tgz", + "integrity": "sha512-sB5uyeq+dwCWyPi31B2gQlVlo+j5brPlWx4yZBrEaRo/nhdDE8Xke1gsGgtiBdaBTxuTkceLVuVt/pclrasb0A==", "dev": true, "license": "Apache-2.0", "dependencies": { - "@eslint/core": "^0.17.0", + "@eslint/core": "^0.16.0", "levn": "^0.4.1" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" } }, - "node_modules/@eslint/plugin-kit/node_modules/@eslint/core": { - "version": "0.17.0", - "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.17.0.tgz", - "integrity": "sha512-yL/sLrpmtDaFEiUj1osRP4TI2MDz1AddJL+jZ7KSqvBuliN4xqYY54IfdN8qD8Toa6g1iloph1fxQNkjOxrrpQ==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@types/json-schema": "^7.0.15" - }, - "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" - } - }, "node_modules/@fastify/busboy": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/@fastify/busboy/-/busboy-2.1.1.tgz", @@ -2110,7 +2096,6 @@ "integrity": "sha512-1LFfa/qnMQvEOAdzlQymH0ulepxbxnCYAKJZfMci/5XJyIHWgEYnDmgnKakbTh7CH2tFQ5O60oYDvns4i9RAIg==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@octokit/auth-token": "^4.0.0", "@octokit/graphql": "^7.1.0", @@ -2654,7 +2639,6 @@ "integrity": "sha512-IeZF+8H0ns6prg4VrkhgL+yrvDXWDH2cKchrbh80ejG9dQgZWp10epHMbgRuQvgchLII/lfh6Xn3lu6+6L86Hw==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@eslint-community/eslint-utils": "^4.9.0", "@typescript-eslint/types": "^8.46.1", @@ -2825,7 +2809,6 @@ "integrity": "sha512-uWN8YqxXxqFMX2RqGOrumsKeti4LlmIMIyV0lgut4jx7KQBcBiW6vkDtIBvHnHIquwNfJhk8v2OtmO8zXWHfPA==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "undici-types": "~7.16.0" } @@ -2907,7 +2890,6 @@ "integrity": "sha512-BnOroVl1SgrPLywqxyqdJ4l3S2MsKVLDVxZvjI1Eoe8ev2r3kGDo+PcMihNmDE+6/KjkTubSJnmqGZZjQSBq/g==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@typescript-eslint/scope-manager": "8.46.2", "@typescript-eslint/types": "8.46.2", @@ -3302,6 +3284,7 @@ "integrity": "sha512-oOdAkwqUfW1WqpwSYJce06wvt6HljgY3fGeM9NcVA1HaYOij3mZG9Rkysn0OHuyUAGMbEbARIpsG+LPVlBJ5/Q==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "@babel/parser": "^7.25.3", "@vue/shared": "3.5.13", @@ -3316,6 +3299,7 @@ "integrity": "sha512-ZOJ46sMOKUjO3e94wPdCzQ6P1Lx/vhp2RSvfaab88Ajexs0AHeV0uasYhi99WPaogmBlRHNRuly8xV75cNTMDA==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "@vue/compiler-core": "3.5.13", "@vue/shared": "3.5.13" @@ -3346,6 +3330,7 @@ "integrity": "sha512-wMH6vrYHxQl/IybKJagqbquvxpWCuVYpoUJfCqFZwa/JY1GdATAQ+TgVtgrwwMZ0D07QhA99rs/EAAWfvG6KpA==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "@vue/compiler-dom": "3.5.13", "@vue/shared": "3.5.13" @@ -3356,7 +3341,8 @@ "resolved": "https://registry.npmjs.org/@vue/shared/-/shared-3.5.13.tgz", "integrity": "sha512-/hnE/qP5ZoGpol0a5mDi45bOd7t3tjYJBjsgCsivow7D48cJeV5l05RD82lPqi7gRiphZM37rnhW1l6ZoCNNnQ==", "dev": true, - "license": "MIT" + "license": "MIT", + "peer": true }, "node_modules/acorn": { "version": "8.15.0", @@ -3364,7 +3350,6 @@ "integrity": "sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg==", "dev": true, "license": "MIT", - "peer": true, "bin": { "acorn": "bin/acorn" }, @@ -3538,9 +3523,9 @@ "license": "MIT" }, "node_modules/baseline-browser-mapping": { - "version": "2.9.12", - "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.9.12.tgz", - "integrity": "sha512-Mij6Lij93pTAIsSYy5cyBQ975Qh9uLEc5rwGTpomiZeXZL9yIS6uORJakb3ScHgfs0serMMfIbXzokPMuEiRyw==", + "version": "2.8.21", + "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.8.21.tgz", + "integrity": "sha512-JU0h5APyQNsHOlAM7HnQnPToSDQoEBZqzu/YBlqDnEeymPnZDREeXJA3KBMQee+dKteAxZ2AtvQEvVYdZf241Q==", "dev": true, "license": "Apache-2.0", "bin": { @@ -3615,7 +3600,6 @@ } ], "license": "MIT", - "peer": true, "dependencies": { "baseline-browser-mapping": "^2.8.19", "caniuse-lite": "^1.0.30001751", @@ -4240,6 +4224,7 @@ "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==", "dev": true, "license": "BSD-2-Clause", + "peer": true, "engines": { "node": ">=0.12" }, @@ -4374,7 +4359,6 @@ "integrity": "sha512-t5aPOpmtJcZcz5UJyY2GbvpDlsK5E8JqRqoKtfiKE3cNh437KIqfJr3A3AKf5k64NPx6d0G3dno6XDY05PqPtw==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@eslint-community/eslint-utils": "^4.8.0", "@eslint-community/regexpp": "^4.12.1", @@ -4605,7 +4589,6 @@ "integrity": "sha512-ySrDaLQZbreNAr/Betq6ocd5Hxy3+LBIfWNV2621EQQ6yGf/ZSLtN2MiM62WO2YQTX+nSFhv332Tpp51q+AkZQ==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@dprint/formatter": "^0.3.0", "@dprint/markdown": "^0.17.8", @@ -5216,7 +5199,8 @@ "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-2.0.2.tgz", "integrity": "sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==", "dev": true, - "license": "MIT" + "license": "MIT", + "peer": true }, "node_modules/esutils": { "version": "2.0.3", @@ -6212,7 +6196,6 @@ "integrity": "sha512-uuPNLJkKN8NXAlZlQ6kmUF9qO+T6Kyd7oV4+/7yy8Jz6+MZNyhPq8EdLpdfnPVzUC8qSf1b4j1azKaGnFsjmsw==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "acorn": "^8.5.0", "eslint-visitor-keys": "^3.0.0", @@ -8810,7 +8793,6 @@ "integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==", "dev": true, "license": "Apache-2.0", - "peer": true, "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" @@ -8979,7 +8961,6 @@ "integrity": "sha512-ZWyE8YXEXqJrrSLvYgrRP7p62OziLW7xI5HYGWFzOvupfAlrLvURSzv/FyGyy0eidogEM3ujU+kUG1zuHgb6Ug==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "esbuild": "^0.25.0", "fdir": "^6.5.0", @@ -9055,7 +9036,6 @@ "integrity": "sha512-gR7INfiVRwnEOkCk47faros/9McCZMp5LM+OMNWGLaDBSvJxIzwjgNFufkuePBNaesGRnLmNfW+ddbUJRZn0nQ==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@vitest/expect": "4.0.6", "@vitest/mocker": "4.0.6", @@ -9141,7 +9121,6 @@ "integrity": "sha512-CydUvFOQKD928UzZhTp4pr2vWz1L+H99t7Pkln2QSPdvmURT0MoC4wUccfCnuEaihNsu9aYYyk+bep8rlfkUXw==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "debug": "^4.4.0", "eslint-scope": "^8.2.0", diff --git a/package.json b/package.json index 9a5e874453a8..697895b9c1ec 100644 --- a/package.json +++ b/package.json @@ -18,7 +18,6 @@ "@types/node": "^24.9.2", "@vitest/coverage-v8": "^4.0.6", "@vitest/ui": "^4.0.6", - "baseline-browser-mapping": "^2.9.12", "eslint": "^9.38.0", "eslint-plugin-format": "^1.0.2", "eslint-plugin-json-schema-validator": "^5.4.1", diff --git a/websites/K/Kayoanime/presence.ts b/websites/K/Kayoanime/presence.ts index 9b9d18f1e9b2..13fd170bf3ab 100644 --- a/websites/K/Kayoanime/presence.ts +++ b/websites/K/Kayoanime/presence.ts @@ -28,6 +28,7 @@ presence.on( ) presence.on('UpdateData', async () => { const fetch_img = document.querySelector('meta[property="og:image"]') + ?.content const presenceData: PresenceData = { @@ -57,6 +58,7 @@ presence.on('UpdateData', async () => { default: if (document.querySelector('.entry-header-outer > .entry-header > h1 ')) { + if (fetch_img) { presenceData.largeImageKey = fetch_img } diff --git a/websites/P/PsychonautWiki/metadata.json b/websites/P/PsychonautWiki/metadata.json index 209b8df7fbf4..1a9ec7f4bbe8 100644 --- a/websites/P/PsychonautWiki/metadata.json +++ b/websites/P/PsychonautWiki/metadata.json @@ -1,5 +1,5 @@ { - "$schema": "https://schemas.premid.app/metadata/1.9", + "$schema": "https://schemas.premid.app/metadata/1.16", "author": { "id": "538604507064696832", "name": "talon2" @@ -15,7 +15,7 @@ "regExp": "https?://(www\\.)?psychonautwiki\\.org/.*", "version": "1.0.0", "logo": "https://i.imgur.com/GPxHYOV.png", - "thumbnail": "https://i.imgur.com/GPxHYOV.png", + "thumbnail": "https://i.imgur.com/QwNGXcq.png", "color": "#808080", "category": "other", "tags": [ From f540062705010c3ca65d2f4312c1c216f23e624b Mon Sep 17 00:00:00 2001 From: Zinibow Date: Thu, 8 Jan 2026 14:36:06 -0800 Subject: [PATCH 18/31] Did Recommended Changes V2 --- cli/src/commands/checkDns.ts | 2 +- websites/K/Kayoanime/presence.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cli/src/commands/checkDns.ts b/cli/src/commands/checkDns.ts index 7375db1e5109..d84d60415ef9 100644 --- a/cli/src/commands/checkDns.ts +++ b/cli/src/commands/checkDns.ts @@ -52,7 +52,7 @@ export async function checkDns( fix?: boolean } = {}, ) { - + let activities: ActivityMetadataAndFolder[] = [] if (all) { diff --git a/websites/K/Kayoanime/presence.ts b/websites/K/Kayoanime/presence.ts index 13fd170bf3ab..bd790c61c526 100644 --- a/websites/K/Kayoanime/presence.ts +++ b/websites/K/Kayoanime/presence.ts @@ -27,8 +27,8 @@ presence.on( }, ) presence.on('UpdateData', async () => { - const fetch_img = document.querySelector('meta[property="og:image"]') + const fetch_img = document.querySelector('meta[property="og:image"]') ?.content const presenceData: PresenceData = { @@ -58,7 +58,7 @@ presence.on('UpdateData', async () => { default: if (document.querySelector('.entry-header-outer > .entry-header > h1 ')) { - + if (fetch_img) { presenceData.largeImageKey = fetch_img } From ad4c52a25deac5c2602d02343f859933ab4cbee7 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Thu, 8 Jan 2026 14:41:03 -0800 Subject: [PATCH 19/31] Added API Version --- websites/P/PsychonautWiki/metadata.json | 1 + 1 file changed, 1 insertion(+) diff --git a/websites/P/PsychonautWiki/metadata.json b/websites/P/PsychonautWiki/metadata.json index 1a9ec7f4bbe8..c57890f83912 100644 --- a/websites/P/PsychonautWiki/metadata.json +++ b/websites/P/PsychonautWiki/metadata.json @@ -1,5 +1,6 @@ { "$schema": "https://schemas.premid.app/metadata/1.16", + "apiVersion": 1, "author": { "id": "538604507064696832", "name": "talon2" From 7c3088a06a104d561a4224939f59d3bc3fa6ab3f Mon Sep 17 00:00:00 2001 From: Zinibow Date: Thu, 8 Jan 2026 14:43:17 -0800 Subject: [PATCH 20/31] Fixed API Version --- websites/P/PsychonautWiki/metadata.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/websites/P/PsychonautWiki/metadata.json b/websites/P/PsychonautWiki/metadata.json index c57890f83912..1c2ff751ae3d 100644 --- a/websites/P/PsychonautWiki/metadata.json +++ b/websites/P/PsychonautWiki/metadata.json @@ -1,6 +1,6 @@ { "$schema": "https://schemas.premid.app/metadata/1.16", - "apiVersion": 1, + "apiVersion": 1, "author": { "id": "538604507064696832", "name": "talon2" From f12dce8b35ccf74b493c75e1bfff390dcc7bdcb2 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Sat, 10 Jan 2026 16:33:33 -0800 Subject: [PATCH 21/31] Removed Useless Website Matching --- websites/P/PsychonautWiki/v2/metadata.json | 27 ++++++++++++++++++++++ websites/P/PsychonautWiki/v2/presence.ts | 20 ++++++++++++++++ 2 files changed, 47 insertions(+) create mode 100644 websites/P/PsychonautWiki/v2/metadata.json create mode 100644 websites/P/PsychonautWiki/v2/presence.ts diff --git a/websites/P/PsychonautWiki/v2/metadata.json b/websites/P/PsychonautWiki/v2/metadata.json new file mode 100644 index 000000000000..ca2ad14990d9 --- /dev/null +++ b/websites/P/PsychonautWiki/v2/metadata.json @@ -0,0 +1,27 @@ +{ + "$schema": "https://schemas.premid.app/metadata/1.16", + "apiVersion": 2, + "author": { + "id": "538604507064696832", + "name": "talon2" + }, + "service": "PsychonautWiki", + "altnames": [ + "Psychonaut Wiki" + ], + "description": { + "en": "PsychonautWiki is an encyclopedia that documents all aspects of psychonautic theory from an evidence-based perspective. It provides education, encourages safe practices, and emphasizes that substances should not be abused. Do not do drugs." + }, + "url": "psychonautwiki.org", + "regExp": "https?://(www\\.)?psychonautwiki\\.org/.*", + "version": "1.0.0", + "logo": "https://i.imgur.com/GPxHYOV.png", + "thumbnail": "https://i.imgur.com/QwNGXcq.png", + "color": "#808080", + "category": "other", + "tags": [ + "drugs", + "harm-reduction", + "psychonaut" + ] +} diff --git a/websites/P/PsychonautWiki/v2/presence.ts b/websites/P/PsychonautWiki/v2/presence.ts new file mode 100644 index 000000000000..d4688f60c9a1 --- /dev/null +++ b/websites/P/PsychonautWiki/v2/presence.ts @@ -0,0 +1,20 @@ +import { Assets } from 'premid' + +const presence = new Presence({ + clientId: '', +}) +const browsingTimestamp = Math.floor(Date.now() / 1000) + +enum ActivityAssets { // Other default assets can be found at index.d.ts + Logo = '', +} + +presence.on('UpdateData', async () => { + const presenceData: PresenceData = { + largeImageKey: ActivityAssets.Logo, + startTimestamp: browsingTimestamp, + smallImageKey: Assets.Play, + } + + presence.setActivity(presenceData) +}) From a35775ea4eca1882c6b0c7776268ecf5f62a62ab Mon Sep 17 00:00:00 2001 From: Zinibow Date: Sat, 10 Jan 2026 16:35:10 -0800 Subject: [PATCH 22/31] Removed Useless Website Matching V2 --- websites/P/PsychonautWiki/presence.ts | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index 1282cefe5c90..c7a42f426b14 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -5,28 +5,29 @@ const presence = new Presence({ }) presence.on('UpdateData', async () => { - if (document.location.hostname !== 'psychonautwiki.org') - return - const { pathname, search } = document.location const params = new URLSearchParams(search) let articleName: string | null = null - if (pathname.startsWith('/w/index.php') && params.has('title')) { + // /w/index.php?title=ArticleName + if (params.has('title')) { articleName = decodeURIComponent(params.get('title')!) .replace(/_/g, ' ') .trim() } + // /wiki/ArticleName else if (pathname.startsWith('/wiki/')) { - articleName = decodeURIComponent(pathname.replace('/wiki/', '')) + articleName = decodeURIComponent(pathname.slice(6)) .replace(/_/g, ' ') .trim() } const action = params.get('action') - const isEditing - = params.has('veaction') || action === 'edit' || action === 'submit' + const isEditing = + params.has('veaction') || + action === 'edit' || + action === 'submit' const presenceData: PresenceData = { largeImageKey: 'https://i.imgur.com/GPxHYOV.png', From 7a2ff25b1054b6fd3be58afbdd373b9698fd6c9e Mon Sep 17 00:00:00 2001 From: Zinibow Date: Sat, 10 Jan 2026 16:40:42 -0800 Subject: [PATCH 23/31] Fixed ESLint Issues --- websites/P/PsychonautWiki/presence.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/PsychonautWiki/presence.ts index c7a42f426b14..baf9ffc966eb 100644 --- a/websites/P/PsychonautWiki/presence.ts +++ b/websites/P/PsychonautWiki/presence.ts @@ -24,10 +24,10 @@ presence.on('UpdateData', async () => { } const action = params.get('action') - const isEditing = - params.has('veaction') || - action === 'edit' || - action === 'submit' + const isEditing + = params.has('veaction') + || action === 'edit' + || action === 'submit' const presenceData: PresenceData = { largeImageKey: 'https://i.imgur.com/GPxHYOV.png', From 018639784f5746598f97964d16d10a27edd8b5dc Mon Sep 17 00:00:00 2001 From: Zinibow Date: Sat, 10 Jan 2026 16:52:35 -0800 Subject: [PATCH 24/31] Added Space In Folder Names --- websites/P/{PsychonautWiki => Psychonaut Wiki}/metadata.json | 0 websites/P/{PsychonautWiki => Psychonaut Wiki}/presence.ts | 0 websites/P/{PsychonautWiki => Psychonaut Wiki}/v2/metadata.json | 0 websites/P/{PsychonautWiki => Psychonaut Wiki}/v2/presence.ts | 0 4 files changed, 0 insertions(+), 0 deletions(-) rename websites/P/{PsychonautWiki => Psychonaut Wiki}/metadata.json (100%) rename websites/P/{PsychonautWiki => Psychonaut Wiki}/presence.ts (100%) rename websites/P/{PsychonautWiki => Psychonaut Wiki}/v2/metadata.json (100%) rename websites/P/{PsychonautWiki => Psychonaut Wiki}/v2/presence.ts (100%) diff --git a/websites/P/PsychonautWiki/metadata.json b/websites/P/Psychonaut Wiki/metadata.json similarity index 100% rename from websites/P/PsychonautWiki/metadata.json rename to websites/P/Psychonaut Wiki/metadata.json diff --git a/websites/P/PsychonautWiki/presence.ts b/websites/P/Psychonaut Wiki/presence.ts similarity index 100% rename from websites/P/PsychonautWiki/presence.ts rename to websites/P/Psychonaut Wiki/presence.ts diff --git a/websites/P/PsychonautWiki/v2/metadata.json b/websites/P/Psychonaut Wiki/v2/metadata.json similarity index 100% rename from websites/P/PsychonautWiki/v2/metadata.json rename to websites/P/Psychonaut Wiki/v2/metadata.json diff --git a/websites/P/PsychonautWiki/v2/presence.ts b/websites/P/Psychonaut Wiki/v2/presence.ts similarity index 100% rename from websites/P/PsychonautWiki/v2/presence.ts rename to websites/P/Psychonaut Wiki/v2/presence.ts From 56569cc91f13e3de51afa37e105e9ae20c48efa0 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Sat, 10 Jan 2026 16:56:27 -0800 Subject: [PATCH 25/31] Fixed service --- websites/P/Psychonaut Wiki/metadata.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/websites/P/Psychonaut Wiki/metadata.json b/websites/P/Psychonaut Wiki/metadata.json index 1c2ff751ae3d..e0fd896e3e3a 100644 --- a/websites/P/Psychonaut Wiki/metadata.json +++ b/websites/P/Psychonaut Wiki/metadata.json @@ -5,7 +5,7 @@ "id": "538604507064696832", "name": "talon2" }, - "service": "PsychonautWiki", + "service": "Psychonaut Wiki", "altnames": [ "Psychonaut Wiki" ], From e53cd2bf0bbb65754d9369c4136e932e2853b034 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Sat, 10 Jan 2026 17:03:04 -0800 Subject: [PATCH 26/31] Fixed Accidental Changes To Other Folders --- websites/H/HTB Academy/metadata.json | 2 +- websites/H/HTB Academy/presence.ts | 52 ++-- websites/H/HackTheBox/metadata.json | 30 ++- websites/H/HackTheBox/presence.ts | 376 +++++++++++++++------------ 4 files changed, 269 insertions(+), 191 deletions(-) diff --git a/websites/H/HTB Academy/metadata.json b/websites/H/HTB Academy/metadata.json index f883938813b1..90b862d6ab86 100644 --- a/websites/H/HTB Academy/metadata.json +++ b/websites/H/HTB Academy/metadata.json @@ -11,7 +11,7 @@ }, "url": "academy.hackthebox.com", "regExp": "^https?[:][/][/]academy[.]hackthebox[.]com[/]", - "version": "1.1.0", + "version": "1.1.1", "logo": "https://cdn.rcd.gg/PreMiD/websites/H/HTB%20Academy/assets/logo.jpg", "thumbnail": "https://cdn.rcd.gg/PreMiD/websites/H/HTB%20Academy/assets/thumbnail.png", "color": "#40a832", diff --git a/websites/H/HTB Academy/presence.ts b/websites/H/HTB Academy/presence.ts index 64d4a5f9f8ca..a43d4e5ec0e8 100644 --- a/websites/H/HTB Academy/presence.ts +++ b/websites/H/HTB Academy/presence.ts @@ -1,64 +1,62 @@ const presence = new Presence({ clientId: '1200517025383075840', }) -const browsingTimestamp = Math.floor(Date.now() / 1000) -const { pathname } = document.location presence.on('UpdateData', async () => { + const { pathname } = document.location + const presenceData: PresenceData = { largeImageKey: 'https://cdn.rcd.gg/PreMiD/websites/H/HTB%20Academy/assets/logo.jpg', - startTimestamp: browsingTimestamp, } if (pathname === '/' || pathname === '/login') { presenceData.details = 'Breaching into the Academy' } + else if (pathname.includes('/dashboard')) { presenceData.details = 'Browsing the dashboard' - presenceData.state = `Off: ${document.querySelector('.red .progress')?.textContent} ` - + `Def: ${document.querySelector('.blue .progress')?.textContent} ` - + `Gen: ${document.querySelector('.green .progress')?.textContent}` + const off = document.querySelector('.redPercent')?.textContent || '0' + const def = document.querySelector('.bluePercent')?.textContent || '0' + const gen = document.querySelector('.greenPercent')?.textContent || '0' + + presenceData.state = `Off: ${off}% | Def: ${def}% | Gen: ${gen}%` } + else if (pathname.includes('/exams')) { presenceData.details = 'Browsing the exams' } + else if (pathname.includes('/paths')) { presenceData.details = 'Browsing paths' } + else if (pathname.includes('/modules')) { presenceData.details = 'Browsing modules' } - else if (pathname.includes('/section')) { - let module: HTMLElement | null - if (document.querySelector('.iterminal')) { - module = document.querySelector( - '#layout-wrapper > div.main-content > div > div:nth-child(2) > div > div > h4', - ) - } - else { - module = document.querySelector( - '#layout-wrapper > div.main-content > div > div:nth-child(1) > div > div > h4', - ) - } + else if (pathname.includes('/section')) { + const moduleName = document.querySelector('.page-title.mb-0.font-size-18.letter-spacing-1-2')?.textContent + const sectionElement = document.querySelector('.breadcrumb-item.active') + const sectionName = sectionElement?.textContent?.trim() || 'Reading Section' - presenceData.details = `Reading Module: ${module?.textContent}` - presenceData.state = `Section: ${ - document.querySelector('.training-module h1')?.textContent - }` + presenceData.details = `Reading Module: ${moduleName}` + presenceData.state = `Section: ${sectionName}` } + else if (pathname.includes('/details')) { + const title = document.querySelector('.page-title-box .page-title')?.textContent?.trim() presenceData.details = 'Reading details about module:' - presenceData.state = `"${ - document.querySelector('.page-title-box .page-title')?.textContent - }"` + presenceData.state = title ? `"${title}"` : 'Unknown Module' } + else if (pathname.includes('/my-certificates')) { - presenceData.details = 'Looking at their certificates' + presenceData.details = 'Looking at certificates' + presenceData.state = 'Admiration Mode' } + else if (pathname.includes('/my-badges')) { - presenceData.details = 'Looking at their badges' + presenceData.details = 'Looking at badges' } presence.setActivity(presenceData) diff --git a/websites/H/HackTheBox/metadata.json b/websites/H/HackTheBox/metadata.json index 575111c85033..78cdead797ab 100644 --- a/websites/H/HackTheBox/metadata.json +++ b/websites/H/HackTheBox/metadata.json @@ -5,18 +5,42 @@ "id": "937757295453044806", "name": "Atsukoro1" }, + "contributors": [ + { + "name": "firstoften", + "id": "339316517558681610" + } + ], "service": "HackTheBox", "description": { "en": "Hack The Box is a massive, online cybersecurity training platform, allowing individuals, companies, universities and all kinds of organizations around the world to level up their hacking skills." }, "url": "app.hackthebox.com", "regExp": "^https?[:][/][/]app[.]hackthebox[.]com[/]", - "version": "1.1.0", + "version": "1.2.0", "logo": "https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/logo.png", "thumbnail": "https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/thumbnail.jpeg", "color": "#9fef00", "category": "other", - "tags": [ - "hacking" + "tags": ["hacking"], + "settings": [ + { + "id": "showRank", + "title": "Show Rank", + "icon": "fas fa-trophy", + "value": true + }, + { + "id": "showGlobalRanking", + "title": "Show Global Ranking", + "icon": "fas fa-globe", + "value": true + }, + { + "id": "showFlags", + "title": "Show owned flags", + "icon": "fas fa-flag", + "value": true + } ] } diff --git a/websites/H/HackTheBox/presence.ts b/websites/H/HackTheBox/presence.ts index b0605148f828..62017379e975 100644 --- a/websites/H/HackTheBox/presence.ts +++ b/websites/H/HackTheBox/presence.ts @@ -1,185 +1,241 @@ -const presences: Record = { - '/challenges/retired': { - details: 'Challenges', - state: 'Browsing retired challenges', - }, - '/challenges/todo': { - details: 'Challenges', - state: 'Browsing to-do list', - }, - '/challenges': { - details: 'Challenges', - state: 'Browsing active challenges', - }, - '/login': { - details: 'Login', - state: 'Logging in', - }, - '/fortresses': { - details: 'Fortresses', - state: 'Browsing fortresses', - }, - '/endgames': { - details: 'Endgames', - state: 'Browsing endgames', - }, - '/starting-point': { - details: 'Starting Point', - state: 'Browsing starting points', - }, - '/rankings': { - details: 'Rankings', - state: 'Browsing rankings', - }, - '/register': { - details: 'Register', - state: 'Creating new account', - }, - '/machines/list/unreleased': { - details: 'Machines', - state: 'Browsing scheduled machines', - }, - '/machines/list/active': { - details: 'Machines', - state: 'Browsing active machines', - }, - '/machines/list/retired': { - details: 'Machines', - state: 'Browsing retired machines', - }, - '/machines/list/todo': { - details: 'Machines', - state: 'Browsing machines to-do list', - }, - '/home': { - details: 'Homepage', - }, - '/machines/{}': { - details: 'Playing machine', - }, - '/challenges/{}': { - details: 'Playing challenge', - }, - '/profile/overview': { - details: 'Profile', - state: 'Browsing profile overview', - }, - '/profile/settings': { - details: 'Profile', - state: 'Changing profile settings', - }, - '/profile/subscriptions/plans': { - details: 'Profile', - state: 'Browsing subscriptions', - }, - '/users/{}': { - details: 'Looking at profile', - }, - '/tracks': { - details: 'Tracks', - state: 'Browsing tracks', - }, +interface DashboardSettings { + showRank: boolean + showGlobalRanking: boolean + showFlags: boolean } + const presence = new Presence({ - clientId: '1042105891681472595', + clientId: '1453343201061638175', }) -function getHomePageDetails() { - return `${ - document - .querySelectorAll('.text-left.font-size15.col')[0] - ?.querySelectorAll('.color-green')[0] - ?.textContent - }, Rank: ${ - document.querySelectorAll('.htb-text2.font-size15.text-left.mb-0')[0] - ?.textContent - }` +const ASSETS = { + logo: 'https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/logo.png', + machines: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/machines.png', + challenges: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/challenges.png', + sherlocks: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/sherlocks.png', + tracks: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/tracks.png', + prolabs: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/prolabs.png', + fortress: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/fortress.png', + seasonal: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/seasonal.png', + homepage: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/homepage.png', + rankings: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/rankings.png', + starting: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/starting-point.png', } -function getPersonalProfileDetails() { - return document.querySelectorAll('.htb-subtitle.greenOnHover')[0]?.textContent ?? null +function getUsername(): string { + const userElement = document.querySelector('span.htb-text-primary.htb-heading-xl.htb-font-bold') + const name = userElement?.textContent?.trim() + return name ? `Username: ${name}` : 'Browsing Dashboard' } -function getMachineDetails() { - const container = document.querySelector('.text-left.pl-8.pt-3') - const status = document - .querySelectorAll('.htb-label2.offline-text.text-left.pl-3')[0] - ?.textContent - ?.includes('offline') - ? 'offline' - : 'online' - - return `${container?.querySelectorAll('.d-inline-block')[0]?.textContent} (${ - container?.querySelectorAll('.d-inline-block')[1]?.textContent - }) - ${status}` +function getBrowsingState(context: string): string { + const params = new URLSearchParams(window.location.search) + const tab = params.get('tab') + + const states: Record = { + retired: 'retired', + unreleased: 'unreleased', + favorites: 'favorite', + active: 'active', + } + + const stateType = tab && states[tab] ? states[tab] : 'all' + return `Browsing ${stateType} ${context}` } -function getChallengeDetails() { - const name = document - .querySelectorAll('.text-left.pl-8.pt-4')[0] - ?.querySelector('.d-inline-block') - ?.textContent +function getResourceName(index: number): string | null { + const parts = window.location.pathname.split('/') + return parts[index] ? decodeURIComponent(parts[index]) : null +} - return `${name} - ${ - document.querySelectorAll('.htb-label2.offline-text.text-left.pl-3')[0] - ?.textContent - }` +function getDashboardStat(labelText: string): string | null { + const label = Array.from(document.getElementsByTagName('dt')).find(el => + el.textContent?.includes(labelText), + ) + return label?.nextElementSibling?.textContent?.trim() || null } -function getUserId() { - return document.cookie - .split(';') - .find(item => item.includes('ajs_user_id')) - ?.split('=')[1] +function getHomePageDetails(settings: DashboardSettings) { + const parts: string[] = [] + + if (settings.showRank) { + const rank = document.querySelector('h3.htb-heading-xl')?.textContent + if (rank) + parts.push(`Rank: '${rank}'`) + } + + if (settings.showGlobalRanking) { + const globalRank = getDashboardStat('Global Ranking') + if (globalRank) + parts.push(`Global: ${globalRank}`) + } + if (settings.showFlags) { + const flags = getDashboardStat('Flags') + if (flags) + parts.push(`Flags: ${flags}`) + } + return parts.length > 0 ? parts.join(' | ') : 'Browsing Dashboard' } -function executeMethod(path: string): string | null { - switch (path) { - case '/home': - return getHomePageDetails() - case '/profile/overview': - return getPersonalProfileDetails() - case '/machines/{}': - return getMachineDetails() - case '/challenges/{}': - return getChallengeDetails() - default: - return null +function getMachineDetails() { + const name = getResourceName(2) || 'Unknown Machine' + const statusEl = document.querySelector('.htb-status') + const statusText = statusEl?.textContent?.trim().toLowerCase() || 'offline' + const machineImg = document.querySelector('.avatar-icon-name-details img') + const src = machineImg?.getAttribute('src') + + const avatar = (src && src.startsWith('http')) ? src : null + + return { + details: statusText.includes('online') ? `Playing Machine '${name}'` : `Looking at '${name}' Machine`, + state: statusText.includes('online') + ? `${statusEl?.previousElementSibling?.textContent?.trim() || 'Server'} - Online` + : 'Status: Offline', + avatar, + } +} + +function getProlabDetails() { + const name = document.querySelector('[data-test-id="navigation-header--title"]')?.textContent?.trim() + + if (name) { + return `Browsing/Solving '${name}' Prolab` } } presence.on('UpdateData', async () => { - let presenceData: PresenceData = {} - - for (const [path, data] of Object.entries(presences)) { - presenceData = { - ...presenceData, - largeImageKey: 'https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/logo.png', - buttons: [ - { - label: 'View Profile', - url: `https://app.hackthebox.com/users/${getUserId()}`, - }, - ], - } - - if ( - document.location.pathname.includes(path) - || new RegExp(path.replace(/\{\}/g, '.*'), 'g').test( - document.location.pathname, - ) - ) { - presenceData = { - ...presenceData, - ...data, - ...(!data.state - && (path.includes('{}') || path === '/home') && { - state: executeMethod(path), - }), + const [showRank, showGlobalRanking, showFlags] = await Promise.all([ + presence.getSetting('showRank'), + presence.getSetting('showGlobalRanking'), + presence.getSetting('showFlags'), + ]) + + const settings: DashboardSettings = { + showRank, + showGlobalRanking, + showFlags, + } + + const path = window.location.pathname + const parts = path.split('/').filter(Boolean) + const root = parts[0] + const resource = parts[1] + + const presenceData: PresenceData = { + largeImageKey: ASSETS.logo, + largeImageText: 'HackTheBox', + } as PresenceData + + switch (`/${root}`) { + case '/home': + presenceData.details = getUsername() + presenceData.state = getHomePageDetails(settings) + presenceData.smallImageKey = ASSETS.homepage + presenceData.smallImageText = 'Homepage' + break + + case '/login': + presenceData.details = 'Logging in' + break + + case '/register': + presenceData.details = 'Creating new account' + break + + case '/rankings': + presenceData.details = 'Looking at the rankings' + presenceData.smallImageKey = ASSETS.rankings + presenceData.smallImageText = 'Rankings' + break + + case '/seasonal': + presenceData.details = 'Browsing the season' + presenceData.smallImageKey = ASSETS.seasonal + presenceData.smallImageText = 'Seasonal' + break + + case '/fortresses': + presenceData.details = 'Browsing fortresses' + presenceData.smallImageKey = ASSETS.fortress + presenceData.smallImageText = 'Fortresses' + break + + case '/tracks': + presenceData.state = 'Browsing tracks' + presenceData.smallImageKey = ASSETS.tracks + presenceData.smallImageText = 'Tracks' + break + + case '/starting-point': + presenceData.state = 'Browsing starting points' + presenceData.smallImageKey = ASSETS.starting + presenceData.smallImageText = 'Starting Point' + break + + case '/machines': + presenceData.smallImageKey = ASSETS.machines + presenceData.smallImageText = 'Machines' + + if (resource) { + const machineData = getMachineDetails() + + presenceData.details = machineData.details + presenceData.state = machineData.state + + if (machineData.avatar) { + presenceData.smallImageKey = machineData.avatar + presenceData.smallImageText = decodeURIComponent(resource) + } + } + else { + presenceData.state = getBrowsingState('machines') + } + break + + case '/challenges': + presenceData.smallImageKey = ASSETS.challenges + presenceData.smallImageText = 'Challenges' + if (resource) { + const name = getResourceName(2) + presenceData.state = name ? `Solving Challenge: '${name}'` : 'Solving Challenge' + } + else { + presenceData.state = getBrowsingState('challenges') + } + break + + case '/sherlocks': + presenceData.smallImageKey = ASSETS.sherlocks + presenceData.smallImageText = 'Sherlocks' + if (resource) { + const name = getResourceName(2) + presenceData.state = name ? `Solving Sherlock: '${name}'` : 'Solving Sherlock' + } + else { + presenceData.state = getBrowsingState('Sherlocks') + } + break + + case '/prolabs': + presenceData.smallImageKey = ASSETS.prolabs + presenceData.smallImageText = 'Prolabs' + if (resource) { + presenceData.details = getProlabDetails() + } + else { + presenceData.details = 'Browsing Prolabs' + } + break + + case '/users': + if (resource) { + presenceData.details = 'Looking at profile' } + break + + default: break - } } presence.setActivity(presenceData) From d175b456645a9b814cfbb0bb7ff881df106ad246 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Sat, 10 Jan 2026 17:06:49 -0800 Subject: [PATCH 27/31] Fixed Accidental Changes To Other Folders V2 --- websites/H/HackTheBox/metadata.json | 6 ++++-- websites/H/HackTheBox/presence.ts | 20 ++++++++++---------- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/websites/H/HackTheBox/metadata.json b/websites/H/HackTheBox/metadata.json index 78cdead797ab..cbbff9ca6a3e 100644 --- a/websites/H/HackTheBox/metadata.json +++ b/websites/H/HackTheBox/metadata.json @@ -17,12 +17,14 @@ }, "url": "app.hackthebox.com", "regExp": "^https?[:][/][/]app[.]hackthebox[.]com[/]", - "version": "1.2.0", + "version": "1.2.1", "logo": "https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/logo.png", "thumbnail": "https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/thumbnail.jpeg", "color": "#9fef00", "category": "other", - "tags": ["hacking"], + "tags": [ + "hacking" + ], "settings": [ { "id": "showRank", diff --git a/websites/H/HackTheBox/presence.ts b/websites/H/HackTheBox/presence.ts index 62017379e975..f5db09c7c8aa 100644 --- a/websites/H/HackTheBox/presence.ts +++ b/websites/H/HackTheBox/presence.ts @@ -10,16 +10,16 @@ const presence = new Presence({ const ASSETS = { logo: 'https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/logo.png', - machines: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/machines.png', - challenges: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/challenges.png', - sherlocks: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/sherlocks.png', - tracks: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/tracks.png', - prolabs: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/prolabs.png', - fortress: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/fortress.png', - seasonal: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/seasonal.png', - homepage: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/homepage.png', - rankings: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/rankings.png', - starting: 'https://raw.githubusercontent.com/sirschubert/htb-assets/refs/heads/main/assets/starting-point.png', + machines: 'https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/0.png', + challenges: 'https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/1.png', + sherlocks: 'https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/2.png', + tracks: 'https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/3.png', + prolabs: 'https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/4.png', + fortress: 'https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/5.png', + seasonal: 'https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/6.png', + homepage: 'https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/7.png', + rankings: 'https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/8.png', + starting: 'https://cdn.rcd.gg/PreMiD/websites/H/HackTheBox/assets/9.png', } function getUsername(): string { From 6cfa92e1fb997d0be18c4a55e33bc95a8ae86373 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Sat, 10 Jan 2026 17:12:00 -0800 Subject: [PATCH 28/31] Fixed Folder Names --- websites/P/Psychonaut Wiki/metadata.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/websites/P/Psychonaut Wiki/metadata.json b/websites/P/Psychonaut Wiki/metadata.json index e0fd896e3e3a..20d942634b7a 100644 --- a/websites/P/Psychonaut Wiki/metadata.json +++ b/websites/P/Psychonaut Wiki/metadata.json @@ -7,7 +7,7 @@ }, "service": "Psychonaut Wiki", "altnames": [ - "Psychonaut Wiki" + "PsychonautWiki" ], "description": { "en": "PsychonautWiki is an encyclopedia that documents all aspects of psychonautic theory from an evidence-based perspective. It provides education, encourages safe practices, and emphasizes that substances should not be abused. Do not do drugs." From 0d994f707669938f48f0079a8c616fb2e65ad93d Mon Sep 17 00:00:00 2001 From: Zinibow Date: Sat, 10 Jan 2026 17:14:02 -0800 Subject: [PATCH 29/31] Changed Version --- websites/P/Psychonaut Wiki/metadata.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/websites/P/Psychonaut Wiki/metadata.json b/websites/P/Psychonaut Wiki/metadata.json index 20d942634b7a..f02a3dfdda13 100644 --- a/websites/P/Psychonaut Wiki/metadata.json +++ b/websites/P/Psychonaut Wiki/metadata.json @@ -14,7 +14,7 @@ }, "url": "psychonautwiki.org", "regExp": "https?://(www\\.)?psychonautwiki\\.org/.*", - "version": "1.0.0", + "version": "1.0.1", "logo": "https://i.imgur.com/GPxHYOV.png", "thumbnail": "https://i.imgur.com/QwNGXcq.png", "color": "#808080", From 06bc1ca69b65a959972f81b3088741728a14e762 Mon Sep 17 00:00:00 2001 From: Zinibow Date: Sat, 10 Jan 2026 17:20:08 -0800 Subject: [PATCH 30/31] Fixed Version And Removed Useless Folders --- websites/P/Psychonaut Wiki/metadata.json | 2 +- websites/P/Psychonaut Wiki/v2/metadata.json | 27 --------------------- websites/P/Psychonaut Wiki/v2/presence.ts | 20 --------------- 3 files changed, 1 insertion(+), 48 deletions(-) delete mode 100644 websites/P/Psychonaut Wiki/v2/metadata.json delete mode 100644 websites/P/Psychonaut Wiki/v2/presence.ts diff --git a/websites/P/Psychonaut Wiki/metadata.json b/websites/P/Psychonaut Wiki/metadata.json index f02a3dfdda13..20d942634b7a 100644 --- a/websites/P/Psychonaut Wiki/metadata.json +++ b/websites/P/Psychonaut Wiki/metadata.json @@ -14,7 +14,7 @@ }, "url": "psychonautwiki.org", "regExp": "https?://(www\\.)?psychonautwiki\\.org/.*", - "version": "1.0.1", + "version": "1.0.0", "logo": "https://i.imgur.com/GPxHYOV.png", "thumbnail": "https://i.imgur.com/QwNGXcq.png", "color": "#808080", diff --git a/websites/P/Psychonaut Wiki/v2/metadata.json b/websites/P/Psychonaut Wiki/v2/metadata.json deleted file mode 100644 index ca2ad14990d9..000000000000 --- a/websites/P/Psychonaut Wiki/v2/metadata.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "$schema": "https://schemas.premid.app/metadata/1.16", - "apiVersion": 2, - "author": { - "id": "538604507064696832", - "name": "talon2" - }, - "service": "PsychonautWiki", - "altnames": [ - "Psychonaut Wiki" - ], - "description": { - "en": "PsychonautWiki is an encyclopedia that documents all aspects of psychonautic theory from an evidence-based perspective. It provides education, encourages safe practices, and emphasizes that substances should not be abused. Do not do drugs." - }, - "url": "psychonautwiki.org", - "regExp": "https?://(www\\.)?psychonautwiki\\.org/.*", - "version": "1.0.0", - "logo": "https://i.imgur.com/GPxHYOV.png", - "thumbnail": "https://i.imgur.com/QwNGXcq.png", - "color": "#808080", - "category": "other", - "tags": [ - "drugs", - "harm-reduction", - "psychonaut" - ] -} diff --git a/websites/P/Psychonaut Wiki/v2/presence.ts b/websites/P/Psychonaut Wiki/v2/presence.ts deleted file mode 100644 index d4688f60c9a1..000000000000 --- a/websites/P/Psychonaut Wiki/v2/presence.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { Assets } from 'premid' - -const presence = new Presence({ - clientId: '', -}) -const browsingTimestamp = Math.floor(Date.now() / 1000) - -enum ActivityAssets { // Other default assets can be found at index.d.ts - Logo = '', -} - -presence.on('UpdateData', async () => { - const presenceData: PresenceData = { - largeImageKey: ActivityAssets.Logo, - startTimestamp: browsingTimestamp, - smallImageKey: Assets.Play, - } - - presence.setActivity(presenceData) -}) From 8a5016b1c1cfb0bcb4c3dd13e500000b6ff3d993 Mon Sep 17 00:00:00 2001 From: Zinbow <48457344+Zinibow@users.noreply.github.com> Date: Mon, 12 Jan 2026 19:45:07 -0800 Subject: [PATCH 31/31] Update websites/P/Psychonaut Wiki/metadata.json Co-authored-by: Bas van Zanten Signed-off-by: Zinbow <48457344+Zinibow@users.noreply.github.com> --- websites/P/Psychonaut Wiki/metadata.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/websites/P/Psychonaut Wiki/metadata.json b/websites/P/Psychonaut Wiki/metadata.json index 20d942634b7a..84bfb4b00b04 100644 --- a/websites/P/Psychonaut Wiki/metadata.json +++ b/websites/P/Psychonaut Wiki/metadata.json @@ -13,7 +13,7 @@ "en": "PsychonautWiki is an encyclopedia that documents all aspects of psychonautic theory from an evidence-based perspective. It provides education, encourages safe practices, and emphasizes that substances should not be abused. Do not do drugs." }, "url": "psychonautwiki.org", - "regExp": "https?://(www\\.)?psychonautwiki\\.org/.*", + "regExp": "^https?[:][/][/]([a-z0-9-]+[.])*psychonautwiki[.]org[/]", "version": "1.0.0", "logo": "https://i.imgur.com/GPxHYOV.png", "thumbnail": "https://i.imgur.com/QwNGXcq.png",