aboutsummaryrefslogtreecommitdiff
path: root/plugins/style/style.js
diff options
context:
space:
mode:
authorNunoSempere <nuno.semperelh@protonmail.com>2024-03-21 08:29:13 -0300
committerNunoSempere <nuno.semperelh@protonmail.com>2024-03-21 08:29:13 -0300
commita1f4b0604fef81f5608fa47ad8359e02bee8bbd6 (patch)
tree7121c25aa6f68d9cc2666c97a9738d86d8dec7ac /plugins/style/style.js
parent386941e51e10a90d7aa291c703eb43f38bb59015 (diff)
add nationstates css snippet; reformat css
Diffstat (limited to 'plugins/style/style.js')
-rw-r--r--plugins/style/style.js33
1 files changed, 23 insertions, 10 deletions
diff --git a/plugins/style/style.js b/plugins/style/style.js
index 0fba49f..f826996 100644
--- a/plugins/style/style.js
+++ b/plugins/style/style.js
@@ -1,10 +1,17 @@
-// Replicates the Stylus app: <https://addons.mozilla.org/en-GB/firefox/addon/styl-us/>
+// Inspired by the Stylus app: <https://addons.mozilla.org/en-GB/firefox/addon/styl-us/>
var styles = null;
+/*
+
+.class
+#id
+
+*/
+
if (document.domain == "forum.effectivealtruism.org") {
- /*
styles = `
+ /*
.Layout-main {
margin-left: 100px;
}
@@ -19,12 +26,16 @@ if (document.domain == "forum.effectivealtruism.org") {
.intercom-lightweight-app{
display: none;
}
- `;
- var styleSheet = document.createElement("style");
- styleSheet.innerText = styles;
- document.head.appendChild(styleSheet);
- console.log("Style changed");
*/
+ `;
+}
+
+if (document.domain == "nationstates.net") {
+ styles = `
+ .adidentifier {
+ display: none;
+ }
+ `;
}
if (document.domain == "mail.proton.me") {
@@ -152,9 +163,11 @@ if (document.domain == "twitter.com") {
document
.querySelectorAll('[data-testid="videoPlayer"]')
.forEach(function (videoPlayer) {
- var grandparentElement = videoPlayer.parentElement.parentElement.parentElement.parentElement.parentElement.parentElement;
- var newTextElement = document.createElement('div');
- newTextElement.textContent = ' [ twitter video ] ';
+ var grandparentElement =
+ videoPlayer.parentElement.parentElement.parentElement.parentElement
+ .parentElement.parentElement;
+ var newTextElement = document.createElement("div");
+ newTextElement.textContent = " [ twitter video ] ";
newTextElement.style["margin-top"] = "10px";
newTextElement.style["margin-left"] = "10px";
newTextElement.style["margin-bottom"] = "10px";