diff options
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/style/style.c | 2 | ||||
-rw-r--r-- | plugins/style/style.h | 2 | ||||
-rw-r--r-- | plugins/style/style.js | 11 |
3 files changed, 6 insertions, 9 deletions
diff --git a/plugins/style/style.c b/plugins/style/style.c index 7429ff4..88c82a7 100644 --- a/plugins/style/style.c +++ b/plugins/style/style.c @@ -1,7 +1,7 @@ #include <stdio.h> #include <stdlib.h> #include <string.h> -#define STYLE_N 6252 + 100 +#define STYLE_N 6073 + 100 void read_style_js(char* string) { diff --git a/plugins/style/style.h b/plugins/style/style.h index 40ebc7a..18175c4 100644 --- a/plugins/style/style.h +++ b/plugins/style/style.h @@ -1,7 +1,7 @@ #ifndef STYLE #define STYLE -#define STYLE_N 6252 + 100 +#define STYLE_N 6073 + 100 void read_style_js(char* string); diff --git a/plugins/style/style.js b/plugins/style/style.js index 4c17f17..9457a7b 100644 --- a/plugins/style/style.js +++ b/plugins/style/style.js @@ -95,13 +95,10 @@ if (document.domain == "twitter.com") { .querySelectorAll('[data-testid="videoPlayer"]') .forEach(function (videoPlayer) { var grandparentElement = videoPlayer.parentElement.parentElement.parentElement.parentElement.parentElement.parentElement; - // grandparentElement.style.display = "none"; - grandparentElement.innerHtml = "none"; - // Make sure not to replace the content if it's already been replaced - if (grandparentElement.getAttribute('data-content-replaced') !== 'true') { - grandparentElement.textContent = ' [twitter video]'; - grandparentElement.setAttribute('data-content-replaced', 'true'); - } + var newTextElement = document.createElement('div'); + newTextElement.textContent = '[twitter video]'; + newTextElement.style.borderWidth = '0px !important'; + grandparentElement.replaceWith(newTextElement); }); } |