CSS: display transition animation, force opacity to 1, reset inline image style - firefox-fix-web - Firefox extension: fix web
(HTM) git clone git://git.codemadness.org/firefox-fix-web
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) README
(DIR) LICENSE
---
(DIR) commit 811b6ccb33519cc9dd18fba6bb9f03e0a757bd31
(DIR) parent 50c08611c320e7df13a56ce7ecaf2b36681733a7
(HTM) Author: Hiltjo Posthuma <hiltjo@codemadness.org>
Date: Sun, 2 Sep 2018 21:16:21 +0200
CSS: display transition animation, force opacity to 1, reset inline image style
Diffstat:
A extension/global/anim.css | 4 ++++
M extension/global/fiximg.js | 2 ++
M extension/manifest.json | 3 ++-
3 files changed, 8 insertions(+), 1 deletion(-)
---
(DIR) diff --git a/extension/global/anim.css b/extension/global/anim.css
@@ -0,0 +1,4 @@
+* {
+ transition: 0s !important;
+ opacity: 1 !important;
+}
(DIR) diff --git a/extension/global/fiximg.js b/extension/global/fiximg.js
@@ -1,9 +1,11 @@
(function() {
Array.from(document.querySelectorAll("img[data-mediumthumb]")).map(function(img) {
img.src = img.getAttribute("data-mediumthumb");
+ img.style.display = null; // reset inline display style
});
Array.from(document.querySelectorAll("img[data-original]")).map(function(img) {
img.src = img.getAttribute("data-original");
+ img.style.display = null; // reset inline display style
});
})();
(DIR) diff --git a/extension/manifest.json b/extension/manifest.json
@@ -13,7 +13,8 @@
"content_scripts": [
{
"matches": [ "*://*/*" ],
- "js": [ "global/focus.js", "global/fiximg.js" ]
+ "js": [ "global/focus.js", "global/fiximg.js" ],
+ "css": [ "global/anim.css" ]
},
{
"matches": [ "*://www.gamekings.tv/*" ],