Fix Mediahuis Noord

This commit is contained in:
magnolia1234 2023-03-01 08:46:00 +01:00
parent aa96d4469e
commit d8f77d0d6e
5 changed files with 28 additions and 13 deletions

View file

@ -5,6 +5,7 @@ Updates: https://gitlab.com/magnolia1234/bypass-paywalls-firefox-clean/-/release
Post-release
Add Bloomberg Adria
Add DN.no (cached articles only)
Fix Mediahuis Noord
Fix mobile user-agent for Google webcache
* v3.0.7.0 (2023-02-26)
@ -1673,7 +1674,7 @@ Fix Corriere Della Sera
* v1.6.4.3 (2020-02-12)
Add CommonWealth Magazine Taiwan
Add El Mercurio (Chile)
Add Leeuwarder Courant & Dagblad van het Noorden (Netherlands)
Add Lc.nl & DvhN.nl
* v1.6.4.2 (2020-02-03)
Add Fd.nl (Googlebot)

View file

@ -2117,7 +2117,7 @@ else if (matchDomain(be_roularta_domains)) {
else if (matchDomain(['lc.nl', 'dvhn.nl'])) {
if (true) {
let paywall = document.querySelector('div.signupPlus');
let paywall = document.querySelector('div.signupPlus, div.pw-wrapper');
if (paywall) {
let intro = document.querySelector('div.startPayWall');
removeDOMElement(paywall, intro);
@ -2144,8 +2144,8 @@ else if (matchDomain(['lc.nl', 'dvhn.nl'])) {
let article_html = parser.parseFromString('<div>' + par.code + '</div>', 'text/html');
elem = article_html.querySelector('div');
}
} else if (par.typename === 'Story_insertbox') {
if (par.insertbox_head) {
} else if (par.insertbox_head || par.insertbox_text) {
if (par.insertbox_head && par.insertbox_head.length > 2) {
let span = document.createElement('span');
span.innerText = par.insertbox_head;
elem.appendChild(span);
@ -2159,6 +2159,7 @@ else if (matchDomain(['lc.nl', 'dvhn.nl'])) {
let span = document.createElement('span');
span.innerText = child.text;
elem.appendChild(span);
elem.appendChild(document.createElement('br'));
} else if (child.children) {
for (let sub_child of child.children) {
if (sub_child.text) {
@ -2187,6 +2188,12 @@ else if (matchDomain(['lc.nl', 'dvhn.nl'])) {
par_link.href = child.href;
par_link.innerText = child.children[0].text;
elem.appendChild(par_link);
} else if (child.children.length && child.children[0].text) {
if (child.children[0].text.length > 2) {
let span = document.createElement('span');
span.innerText = child.children[0].text;
elem.appendChild(span);
}
}
}
} else if (par.typename.length > 2)
@ -4632,14 +4639,18 @@ else if ((domain = matchDomain(usa_lee_ent_domains)) || document.querySelector('
let elem_hidden = document.querySelectorAll('html[class], body[class]');
for (let elem of elem_hidden)
elem.removeAttribute('class');
} else if (!domain) {
let subscriber_only = document.querySelectorAll('div.subscriber-only:not(.encrypted-content)');
for (let elem of subscriber_only) {
elem.removeAttribute('style');
elem.removeAttribute('class');
} else {
if (!domain) {
let subscriber_only = document.querySelectorAll('div.subscriber-only:not(.encrypted-content)');
for (let elem of subscriber_only) {
elem.removeAttribute('style');
elem.removeAttribute('class');
}
let banners = document.querySelectorAll('div.subscription-required, div.redacted-overlay');
removeDOMElement(...banners);
}
let banners = document.querySelectorAll('div.subscription-required, div.redacted-overlay, div.tnt-ads-container');
removeDOMElement(...banners);
let ads = document.querySelectorAll('div.tnt-ads-container');
removeDOMElement(...ads);
}
}

View file

@ -51,5 +51,5 @@
"webRequestBlocking",
"*://*/*"
],
"version": "3.0.7.2"
"version": "3.0.7.3"
}

View file

@ -342,6 +342,9 @@
"block_regex": "loader-cdn\\.azureedge\\.net",
"domain": "pressherald.com"
},
"Quickmath.com": {
"domain": "quickmath.com"
},
"Reviewjournal.com": {
"allow_cookies": 1,
"block_regex": "js\\.matheranalytics\\.com",

View file

@ -745,5 +745,5 @@
"*://*.wallkit.net/*",
"*://webcache.googleusercontent.com/*"
],
"version": "3.0.7.2"
"version": "3.0.7.3"
}