mirror of
https://gitlab.com/magnolia1234/bypass-paywalls-firefox-clean.git
synced 2024-11-10 05:47:46 +01:00
Fix Nautilus
This commit is contained in:
parent
5e94f70bff
commit
342527b124
6 changed files with 32 additions and 2 deletions
|
@ -617,11 +617,12 @@ ext_api.webRequest.onHeadersReceived.addListener(function (details) {
|
|||
['blocking', 'responseHeaders']);
|
||||
|
||||
// block inline script
|
||||
var block_js_inline = ["*://*.elpais.com/*", "*://*.theglobeandmail.com/*"];
|
||||
var block_js_inline = ["*://*.elpais.com/*", "*://*.nautil.us/*", "*://*.theglobeandmail.com/*"];
|
||||
if (block_js_inline.length)
|
||||
ext_api.webRequest.onHeadersReceived.addListener(function (details) {
|
||||
let url_path = details.url.split('?')[0];
|
||||
let excluded = (matchUrlDomain('elpais.com', details.url) && (url_path.includes('/elpais.com') || !url_path.includes('.html')))
|
||||
|| (matchUrlDomain('nautil.us', details.url) && !details.url.match(/((\w)+(\-)+){3,}/))
|
||||
|| (matchUrlDomain('theglobeandmail.com', details.url) && (!enabledSites.includes('#options_optin_tgam_premium') || !details.url.includes('?rel=premium')));
|
||||
if (!isSiteEnabled(details) || excluded)
|
||||
return;
|
||||
|
|
|
@ -7,6 +7,7 @@ Fix Business Standard
|
|||
Fix Helsingin Sanomat (dynamic-json)
|
||||
Fix Koelner Stadt-Anzeiger & Koelnische Rundschau
|
||||
Fix LesEchos.fr
|
||||
Fix Nautilus
|
||||
Fix Repubblica.it & LaStampa.it (videos-gtm)
|
||||
|
||||
* v2.7.2.0 (2022-06-06)
|
||||
|
|
|
@ -3190,6 +3190,23 @@ else if (matchDomain('nationalreview.com')) {
|
|||
removeDOMElement(...adverts);
|
||||
}
|
||||
|
||||
else if (matchDomain('nautil.us')) {
|
||||
// plus code in contentScript_once.js
|
||||
let hidden_images = document.querySelectorAll('img[src^="data:image"][data-src]');
|
||||
for (let hidden_image of hidden_images)
|
||||
hidden_image.src = hidden_image.getAttribute('data-src');
|
||||
let empty_video_iframes = document.querySelectorAll('iframe[src="about:blank"][data-litespeed-src]');
|
||||
for (let empty_video_iframe of empty_video_iframes)
|
||||
empty_video_iframe.src = empty_video_iframe.getAttribute('data-litespeed-src');
|
||||
window.setTimeout(function () {
|
||||
let banners = document.querySelectorAll('div[class^="a__sc-np"], div.subscibe-bar');
|
||||
removeDOMElement(...banners);
|
||||
let overflows = document.querySelectorAll('html[style], body[style]');
|
||||
for (let overflow of overflows)
|
||||
overflow.removeAttribute('style');
|
||||
}, 1000);
|
||||
}
|
||||
|
||||
else if (matchDomain('newleftreview.org')) {
|
||||
window.setTimeout(function () {
|
||||
let url = window.location.href;
|
||||
|
|
|
@ -53,6 +53,15 @@ else if (matchDomain('nationalgeographic.com')) {
|
|||
waitDOMElement('div[id^="fittPortal"]', 'DIV', natgeo_func, false);
|
||||
}
|
||||
|
||||
else if (matchDomain('nautil.us')) {
|
||||
let hidden_images = document.querySelectorAll('img[src^="data:image"][data-src]');
|
||||
for (let hidden_image of hidden_images)
|
||||
hidden_image.src = hidden_image.getAttribute('data-src');
|
||||
let empty_video_iframes = document.querySelectorAll('iframe[src="about:blank"][data-litespeed-src]');
|
||||
for (let empty_video_iframe of empty_video_iframes)
|
||||
empty_video_iframe.src = empty_video_iframe.getAttribute('data-litespeed-src');
|
||||
}
|
||||
|
||||
else if (matchDomain('nyteknik.se')) {
|
||||
window.setTimeout(function () {
|
||||
let hidden_images = document.querySelectorAll('img[src=""][data-proxy-image]');
|
||||
|
|
|
@ -41,6 +41,7 @@
|
|||
"matches": [
|
||||
"*://*.inkl.com/*",
|
||||
"*://*.nationalgeographic.com/*",
|
||||
"*://*.nautil.us/*",
|
||||
"*://*.nyteknik.se/*",
|
||||
"*://*.nzherald.co.nz/*",
|
||||
"*://*.gitlab.com/magnolia1234"
|
||||
|
|
3
sites.js
3
sites.js
|
@ -1228,7 +1228,8 @@ var defaultSites = {
|
|||
useragent: "googlebot"
|
||||
},
|
||||
"Nautilus": {
|
||||
domain: "nautil.us"
|
||||
domain: "nautil.us",
|
||||
allow_cookies: 1
|
||||
},
|
||||
"Neue Osnabrücker Zeitung": {
|
||||
domain: "noz.de",
|
||||
|
|
Loading…
Reference in a new issue