mirror of
https://gitlab.com/magnolia1234/bypass-paywalls-firefox-clean.git
synced 2024-11-13 01:34:16 +01:00
Fix Lequipe.fr (json)
This commit is contained in:
parent
8a5ccb807a
commit
bdf58ab505
5 changed files with 33 additions and 24 deletions
|
@ -2,6 +2,7 @@
|
||||||
Changelog Bypass Paywalls Clean - Firefox
|
Changelog Bypass Paywalls Clean - Firefox
|
||||||
|
|
||||||
Post-release
|
Post-release
|
||||||
|
Fix Lequipe.fr (json)
|
||||||
|
|
||||||
* v2.5.6.0 (2022-02-13)
|
* v2.5.6.0 (2022-02-13)
|
||||||
Add Condé Nast magazines & Vogue Business
|
Add Condé Nast magazines & Vogue Business
|
||||||
|
@ -206,7 +207,7 @@ Update custom sites (block regex for default sites)
|
||||||
|
|
||||||
* v2.4.0.0 (2021-10-17)
|
* v2.4.0.0 (2021-10-17)
|
||||||
Add Westfaelische Nachrichten (Germany)
|
Add Westfaelische Nachrichten (Germany)
|
||||||
Remove Australian Provincial Newspapers (fix obsolete)
|
Remove Australian Provincial Newspapers (obsolete)
|
||||||
Fix GElocal.it
|
Fix GElocal.it
|
||||||
Fix National Review
|
Fix National Review
|
||||||
Fix Ruhr Nachrichten (amp)
|
Fix Ruhr Nachrichten (amp)
|
||||||
|
@ -275,7 +276,7 @@ Fix group Crain Communications
|
||||||
Add Ad Age & Automotive News (group Crain Communications)
|
Add Ad Age & Automotive News (group Crain Communications)
|
||||||
Add MediaNews Group (local USA)
|
Add MediaNews Group (local USA)
|
||||||
Add The Intercept
|
Add The Intercept
|
||||||
Remove Slader (fix obsolete)
|
Remove Slader (obsolete)
|
||||||
Fix group Mediahuis Nederland Regional
|
Fix group Mediahuis Nederland Regional
|
||||||
Fix Medium (timing)
|
Fix Medium (timing)
|
||||||
Fix The Australian
|
Fix The Australian
|
||||||
|
@ -353,7 +354,7 @@ Update custom sites (set useragent Bingbot)
|
||||||
|
|
||||||
* v2.2.6.0 (2021-06-20)
|
* v2.2.6.0 (2021-06-20)
|
||||||
Add group Mediahuis Nederland Regional
|
Add group Mediahuis Nederland Regional
|
||||||
Remove The Northern Star (fix obsolete)
|
Remove The Northern Star (obsolete)
|
||||||
Fix Atlantico.fr
|
Fix Atlantico.fr
|
||||||
Fix Boston Globe (no opt-in)
|
Fix Boston Globe (no opt-in)
|
||||||
Fix Foreign Policy
|
Fix Foreign Policy
|
||||||
|
|
|
@ -1131,26 +1131,34 @@ else if (matchDomain('lequipe.fr')) {
|
||||||
if (par_type) {
|
if (par_type) {
|
||||||
article.innerHTML = '';
|
article.innerHTML = '';
|
||||||
let json_split = json.split('__type:' + par_type);
|
let json_split = json.split('__type:' + par_type);
|
||||||
if (json_split.length < 5) {
|
|
||||||
par_type = json.split('content:"')[1].split('"},{__type:')[1].split(',')[0];
|
|
||||||
json_split = json.split('__type:' + par_type);
|
|
||||||
}
|
|
||||||
let article_dom;
|
let article_dom;
|
||||||
let article_text = '';
|
let article_text = '';
|
||||||
let parser = new DOMParser();
|
let parser = new DOMParser();
|
||||||
for (let par of json_split) {
|
for (let par_main of json_split) {
|
||||||
par = par.split('}')[0];
|
if (par_main.includes(',content:')) {
|
||||||
if (par.includes(',content:')) {
|
if (par_main.split(',content:"').length > 2) {
|
||||||
let content = par.split(',content:')[1].split('",')[0];
|
if (par_main.startsWith(',title:'))
|
||||||
let par_title = '';
|
article_text += '<p><strong>' + par_main.split(',title:')[1].split(',')[0].replace(/^\"|\"$/g, '') + '</strong></p>';
|
||||||
if (par.includes(',title:'))
|
par_type = json.split('content:')[1].split('"},{__type:')[1].split(',')[0];
|
||||||
par_title = par.split(',title:')[1].split(',')[0].replace(/^\"|\"$/g, '');
|
pars = par_main.split('__type:' + par_type);
|
||||||
if (content) {
|
} else {
|
||||||
par = content.replace('class=', '');
|
pars = [par_main];
|
||||||
if (par_title.length > 2)
|
}
|
||||||
par = '<strong>' + par_title + '</strong><br><br>' + content;
|
for (let par of pars) {
|
||||||
par = par.replace(/\\u003C/g, '<').replace(/\\u003E/g, '>').replace(/\\u002F/g, '/').replace(/\\"/g, '"').replace(/^\"|\"$/g, '');
|
par = par.split('}')[0];
|
||||||
article_text += '<p>' + par + '</p>';
|
if (par.includes(',content:')) {
|
||||||
|
let content = par.split(',content:')[1].split('",')[0];
|
||||||
|
let par_title = '';
|
||||||
|
if (par.includes(',title:'))
|
||||||
|
par_title = par.split(',title:')[1].split(',')[0].replace(/^\"|\"$/g, '');
|
||||||
|
if (content) {
|
||||||
|
par = content.replace('class=', '');
|
||||||
|
if (par_title.length > 2)
|
||||||
|
par = '<strong>' + par_title + '</strong><br><br>' + content;
|
||||||
|
par = par.replace(/\\u003C/g, '<').replace(/\\u003E/g, '>').replace(/\\u002F/g, '/').replace(/\\"/g, '"').replace(/^\"|\"$/g, '');
|
||||||
|
article_text += '<p>' + par + '</p>';
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -620,5 +620,5 @@
|
||||||
"*://*.wallkit.net/*",
|
"*://*.wallkit.net/*",
|
||||||
"*://*.wsj.net/*"
|
"*://*.wsj.net/*"
|
||||||
],
|
],
|
||||||
"version": "2.5.6.0"
|
"version": "2.5.6.1"
|
||||||
}
|
}
|
||||||
|
|
4
sites.js
4
sites.js
|
@ -647,7 +647,7 @@ var defaultSites = {
|
||||||
allow_cookies: 1,
|
allow_cookies: 1,
|
||||||
block_regex: /(\.piano\.io\/|cdn\.cxense\.com\/|cdn\.ampproject\.org\/v\d\/amp-(access|analytics)-.+\.js)/
|
block_regex: /(\.piano\.io\/|cdn\.cxense\.com\/|cdn\.ampproject\.org\/v\d\/amp-(access|analytics)-.+\.js)/
|
||||||
},
|
},
|
||||||
"Grupo Vocento (Spain, regional daily)": {
|
"Grupo Vocento": {
|
||||||
domain: "###_es_grupo_vocento",
|
domain: "###_es_grupo_vocento",
|
||||||
group: [
|
group: [
|
||||||
"diariosur.es",
|
"diariosur.es",
|
||||||
|
@ -1626,7 +1626,7 @@ var defaultSites = {
|
||||||
allow_cookies: 1,
|
allow_cookies: 1,
|
||||||
block_regex: /(\.tinypass\.com\/|\.telegraph\.co\.uk\/martech\/js\/|cdn\.ampproject\.org\/v\d\/amp-(access|(sticky-)?ad)-.+\.js)/
|
block_regex: /(\.tinypass\.com\/|\.telegraph\.co\.uk\/martech\/js\/|cdn\.ampproject\.org\/v\d\/amp-(access|(sticky-)?ad)-.+\.js)/
|
||||||
},
|
},
|
||||||
"The Times": {
|
"The Times (UK)": {
|
||||||
domain: "thetimes.co.uk",
|
domain: "thetimes.co.uk",
|
||||||
allow_cookies: 1,
|
allow_cookies: 1,
|
||||||
useragent: "googlebot"
|
useragent: "googlebot"
|
||||||
|
|
|
@ -114,7 +114,7 @@
|
||||||
"block_regex": "(journey\\.vogue\\.com\\/build-.+\\.js|cdn\\.ampproject\\.org\\/v\\d\\/amp-(ad|subscriptions)-.+\\.js)",
|
"block_regex": "(journey\\.vogue\\.com\\/build-.+\\.js|cdn\\.ampproject\\.org\\/v\\d\\/amp-(ad|subscriptions)-.+\\.js)",
|
||||||
"useragent": "googlebot"
|
"useragent": "googlebot"
|
||||||
},
|
},
|
||||||
"Voguebusiness.com": {
|
"Vogue Business": {
|
||||||
"allow_cookies": 1,
|
"allow_cookies": 1,
|
||||||
"domain": "voguebusiness.com",
|
"domain": "voguebusiness.com",
|
||||||
"useragent": "googlebot"
|
"useragent": "googlebot"
|
||||||
|
|
Loading…
Reference in a new issue