Last active
May 21, 2024 22:22
-
-
Save Kurotaku-sama/017f6c568597eeace3a41b42174f0443 to your computer and use it in GitHub Desktop.
This script insert a button which allow you to unfollow all curators that are currently shown
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Steam unfollow all shown curators | |
// @name:de Steam entfolge allen geladenen Kuratoren | |
// @namespace kurotaku.de | |
// @version 1.0.2 | |
// @description This script insert a button which allow you to unfollow all curators that are currently shown | |
// @description:de Dieses Skript fügt einen Button hinzu, mit der Sie alle Kuratoren, die derzeit angezeigt werden, entfolgen können | |
// @author Kurotaku | |
// @license MIT | |
// @match https://store.steampowered.com/curators/mycurators/ | |
// @icon https://steamcommunity.com/favicon.ico | |
// @updateURL https://gist.github.com/Kurotaku-sama/017f6c568597eeace3a41b42174f0443/raw/Steam%2520unfollow%2520all%2520shown%2520curators.user.js | |
// @downloadURL https://gist.github.com/Kurotaku-sama/017f6c568597eeace3a41b42174f0443/raw/Steam%2520unfollow%2520all%2520shown%2520curators.user.js | |
// @grant none | |
// ==/UserScript== | |
(function() { | |
let nav = document.querySelector(".navigation_bar"); | |
let button = "<a id='k-unfollow-curators' class='btn_green_steamui btn_medium' href='#'><span>Unfollow all loaded curators</span></a>"; | |
if(nav) { | |
nav.insertAdjacentHTML("afterend", button); | |
document.getElementById("k-unfollow-curators").addEventListener ("click", unfollow_curators , false); | |
} | |
})(); | |
function unfollow_curators() { | |
let elements = document.querySelectorAll(".following_button"); | |
for(let i = 0; i < elements.length; i++) { | |
elements[i].click() ; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment