mirror of
https://gitlab.com/magnolia1234/bypass-paywalls-firefox-clean.git
synced 2024-11-10 03:41:57 +01:00
Add JungeFreiheit.de
This commit is contained in:
parent
3ad581b4f8
commit
335972557b
8 changed files with 62 additions and 6 deletions
|
@ -582,6 +582,7 @@ Grouped in options:\
|
|||
[Frankfurter Allgemeine Zeitung](https://www.faz.net) -
|
||||
[Freie Presse](https://www.freiepresse.de) -
|
||||
[Jacobin Magazin](https://jacobin.de) -
|
||||
[Junge Freiheit](https://jungefreiheit.de) -
|
||||
[Kölner Stadt-Anzeiger](https://www.ksta.de) -
|
||||
[Kölnische Rundschau](https://www.rundschau-online.de) -
|
||||
[Krautreporter](https://krautreporter.de) -
|
||||
|
|
|
@ -6,6 +6,7 @@ Post-release
|
|||
Add Bhaskar (India)
|
||||
Add Granta Magazine (UK)
|
||||
Add Interesting Engineering
|
||||
Add JungeFreiheit.de
|
||||
Add Vn.at
|
||||
Fix Media Group Westfalen
|
||||
Fix Mediahuis Nederland Regional (js)
|
||||
|
|
|
@ -927,6 +927,39 @@ else if (matchDomain('jacobin.de')) {
|
|||
}
|
||||
}
|
||||
|
||||
else if (matchDomain('jungefreiheit.de')) {
|
||||
let paywall = document.querySelector('div.paywall-teaser-box');
|
||||
if (paywall && dompurify_loaded) {
|
||||
removeDOMElement(paywall);
|
||||
let json_url_dom = document.querySelector('head > link[rel="alternate"][type="application/json"][href]');
|
||||
if (json_url_dom) {
|
||||
let json_url = json_url_dom.href;
|
||||
fetch(json_url)
|
||||
.then(response => {
|
||||
if (response.ok) {
|
||||
response.json().then(json => {
|
||||
let json_text = json.content.rendered;
|
||||
let content = document.querySelector('div.elementor-widget-container > p');
|
||||
if (json_text && content) {
|
||||
let parser = new DOMParser();
|
||||
let doc = parser.parseFromString('<div>' + DOMPurify.sanitize(json_text) + '</div>', 'text/html');
|
||||
let content_new = doc.querySelector('div');
|
||||
content.parentNode.replaceChild(content_new, content);
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
let fade = document.querySelector('div[style*="background-image: url"]');
|
||||
removeDOMElement(fade);
|
||||
}
|
||||
window.setTimeout(function () {
|
||||
let banners = document.querySelectorAll('div > small');
|
||||
for (let elem of banners)
|
||||
hideDOMElement(elem.parentNode);
|
||||
}, 1000);
|
||||
}
|
||||
|
||||
else if (matchDomain('krautreporter.de')) {
|
||||
let paywall = document.querySelector('.js-article-paywall');
|
||||
if (paywall) {
|
||||
|
@ -1173,7 +1206,6 @@ else if (matchDomain('vol.at')) {
|
|||
if (paywall && dompurify_loaded) {
|
||||
paywall.removeAttribute('class');
|
||||
if (!paywall.hasChildNodes()) {
|
||||
console.log('empty');
|
||||
let json_script = document.querySelector('script#externalPostDataNode');
|
||||
if (json_script) {
|
||||
try {
|
||||
|
@ -4403,7 +4435,7 @@ else if (matchDomain('puck.news')) {
|
|||
let doc = parser.parseFromString('<div>' + DOMPurify.sanitize(json_text) + '</div>', 'text/html');
|
||||
content.innerHTML = '';
|
||||
let content_new = doc.querySelector('div');
|
||||
content.appendChild(content_new, content);
|
||||
content.appendChild(content_new);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -4734,7 +4766,7 @@ else if (matchDomain('theamericanconservative.com')) {
|
|||
let doc = parser.parseFromString('<div>' + DOMPurify.sanitize(json_text) + '</div>', 'text/html');
|
||||
let content_new = doc.querySelector('div');
|
||||
content.innerHTML = '';
|
||||
content.appendChild(content_new, content);
|
||||
content.appendChild(content_new);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -5205,7 +5237,7 @@ else if (matchDomain('thewrap.com')) {
|
|||
let doc = parser.parseFromString('<div>' + DOMPurify.sanitize(json_text) + '</div>', 'text/html');
|
||||
content.innerHTML = '';
|
||||
let content_new = doc.querySelector('div');
|
||||
content.appendChild(content_new, content);
|
||||
content.appendChild(content_new);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
|
@ -54,5 +54,5 @@
|
|||
"webRequestBlocking",
|
||||
"*://*/*"
|
||||
],
|
||||
"version": "3.3.6.7"
|
||||
"version": "3.3.6.8"
|
||||
}
|
||||
|
|
|
@ -732,6 +732,16 @@
|
|||
"domain": "utilityweek.co.uk",
|
||||
"useragent": "googlebot"
|
||||
},
|
||||
"Van-magazin.de": {
|
||||
"allow_cookies": 1,
|
||||
"domain": "van-magazin.de",
|
||||
"ld_json_url": "div.newspack-metered-paywall-block|div.entry-content"
|
||||
},
|
||||
"Van-magazine.com": {
|
||||
"allow_cookies": 1,
|
||||
"domain": "van-magazine.com",
|
||||
"ld_json_url": "div.newspack-metered-paywall-block|div.entry-content"
|
||||
},
|
||||
"Washingtontimes.com": {
|
||||
"allow_cookies": 1,
|
||||
"block_regex": "\\.tinypass\\.com",
|
||||
|
|
|
@ -362,6 +362,7 @@
|
|||
"*://*.journalstar.com/*",
|
||||
"*://*.jpost.com/*",
|
||||
"*://*.jsonline.com/*",
|
||||
"*://*.jungefreiheit.de/*",
|
||||
"*://*.kansas.com/*",
|
||||
"*://*.kansascity.com/*",
|
||||
"*://*.kentucky.com/*",
|
||||
|
@ -805,5 +806,5 @@
|
|||
"*://*.wyleex.com/*",
|
||||
"*://webcache.googleusercontent.com/*"
|
||||
],
|
||||
"version": "3.3.6.7"
|
||||
"version": "3.3.6.8"
|
||||
}
|
||||
|
|
5
sites.js
5
sites.js
|
@ -1177,6 +1177,11 @@ var defaultSites = {
|
|||
allow_cookies: 1,
|
||||
cs_dompurify: 1
|
||||
},
|
||||
"Junge Freiheit": {
|
||||
domain: "jungefreiheit.de",
|
||||
allow_cookies: 1,
|
||||
cs_dompurify: 1
|
||||
},
|
||||
"Kölner Stadt-Anzeiger": {
|
||||
domain: "ksta.de",
|
||||
allow_cookies: 1,
|
||||
|
|
|
@ -50,6 +50,12 @@
|
|||
"ld_json_url": "div.article-sign-up-container|div.article-excerpt",
|
||||
"upd_version": "3.3.6.6"
|
||||
},
|
||||
"Junge Freiheit": {
|
||||
"domain": "jungefreiheit.de",
|
||||
"allow_cookies": 1,
|
||||
"ld_json_url": "div.paywall-teaser-box|div.elementor-widget-container > p",
|
||||
"upd_version": "3.3.6.8"
|
||||
},
|
||||
"Mediahuis Nederland Regional": {
|
||||
"domain": "###_nl_mediahuis_region",
|
||||
"group": [
|
||||
|
|
Loading…
Reference in a new issue