From 9d9e57df1e1b484142d8c2d5a8b881cd0fd9f6a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Malte=20J=C3=BCrgens?= Date: Tue, 25 Oct 2022 20:25:47 +0200 Subject: [PATCH] add about message again --- assets/userscript.js | 44 ++++++++++++++++++++++---------------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/assets/userscript.js b/assets/userscript.js index c14806f..cf00169 100644 --- a/assets/userscript.js +++ b/assets/userscript.js @@ -131,28 +131,28 @@ setInterval(() => { } // Add about text in settings - // if ( - // document.getElementsByClassName("dirscordScreenaudioAboutText").length == 0 - // ) { - // for (const el of document.getElementsByClassName("info-3pQQBb")) { - // let aboutEl; - // if (window.discordScreenaudioKXMLGUI) { - // aboutEl = document.createElement("a"); - // aboutEl.addEventListener("click", () => { - // console.log("!discord-screenaudio-about"); - // }); - // } else { - // aboutEl = document.createElement("div"); - // } - // aboutEl.innerText = `discord-screenaudio ${window.discordScreenaudioVersion}`; - // aboutEl.style.fontSize = "12px"; - // aboutEl.style.color = "var(--text-muted)"; - // aboutEl.style.textTransform = "none"; - // aboutEl.classList.add("dirscordScreenaudioAboutText"); - // aboutEl.style.cursor = "pointer"; - // el.appendChild(aboutEl); - // } - // } + if ( + document.getElementsByClassName("dirscordScreenaudioAboutText").length == 0 + ) { + for (const el of document.getElementsByClassName("info-3pQQBb")) { + let aboutEl; + if (window.discordScreenaudioKXMLGUI) { + aboutEl = document.createElement("a"); + aboutEl.addEventListener("click", () => { + console.log("!discord-screenaudio-about"); + }); + } else { + aboutEl = document.createElement("div"); + } + aboutEl.innerText = `discord-screenaudio ${window.discordScreenaudioVersion}`; + aboutEl.style.fontSize = "12px"; + aboutEl.style.color = "var(--text-muted)"; + aboutEl.style.textTransform = "none"; + aboutEl.classList.add("dirscordScreenaudioAboutText"); + aboutEl.style.cursor = "pointer"; + el.appendChild(aboutEl); + } + } // Remove stream settings if stream is active document.getElementById("manage-streams-change-windows")?.remove();