Created
October 30, 2021 09:48
-
-
Save NO-ob/d1d6c160719df0f530ab9a37292801f4 to your computer and use it in GitHub Desktop.
Adds padding to fanbox on palemoon as its broken
This file contains hidden or 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 Fanbox padding for palemoon | |
// @namespace http://tampermonkey.net/ | |
// @version 0.1 | |
// @description try to take over the world! | |
// @author You | |
// @match https://www.fanbox.cc/ | |
// @icon https://www.google.com/s2/favicons?domain=fanbox.cc | |
// @grant none | |
// ==/UserScript== | |
(function() { | |
'use strict'; | |
(new MutationObserver(addPadding)).observe(document, { | |
childList: true, | |
subtree: true | |
}); | |
})(); | |
function addPadding(){ | |
if (document.querySelector("div#root > div:nth-child(5) > div")){ | |
document.querySelector("div#root > div:nth-child(5) > div").style.padding = "0 20% 0 20%"; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment