Fix-update South China Morning Post (amp)

This commit is contained in:
magnolia1234 2021-05-10 18:12:59 +02:00
parent 62196d517b
commit 7315735372
4 changed files with 13 additions and 3 deletions

View File

@ -372,7 +372,7 @@ var blockedRegexes = {
'thesaturdaypaper.com.au': /\.thesaturdaypaper\.com\.au\/sites\/all\/modules\/custom\/node_meter\/pw\.js/,
'science-et-vie.com': /\.qiota\.com\//,
'sciencesetavenir.fr': /\.poool\.fr\//,
'scmp.com': /\.tinypass\.com\//,
'scmp.com': /(\.tinypass\.com\/|cdn\.ampproject\.org\/v\d\/amp-(access|ad|analytics|consent|fx-flying-carpet)-.+\.js)/,
'seekingalpha.com': /(\.tinypass\.com\/|cdn\.ampproject\.org(\/.+)?\/v\d\/amp-(access|ad|loader)-.+\.js)/,
'sfchronicle.com': /\.blueconic\.net\//,
'shz.de': /cdn\.ampproject\.org\/v\d\/amp-(access|(sticky-)?ad|fx-flying-carpet)-.+\.js/,
@ -1034,7 +1034,7 @@ ext_api.webRequest.onBeforeSendHeaders.addListener(function(details) {
let usa_today_site = (matchUrlDomain('gannett-cdn.com', details.url) && matchUrlDomain(['usatoday.com'], header_referer));
allow_ext_source = allow_ext_source || inkl_site || cl_elmerc_site || es_elesp_site || it_repubblica_site || uk_nlr_site || usa_discmag_site || usa_mw_site || usa_today_site;
bpc_amp_site = (matchUrlDomain('cdn.ampproject.org', details.url) && matchUrlDomain(['asiatimes.com', 'augsburger-allgemeine.de', 'barrons.com', 'belfasttelegraph.co.uk', 'cicero.de', 'cmjornal.pt', 'elmundo.es', 'elpais.com', 'elperiodico.com', 'expansion.com', 'freiepresse.de', 'independent.ie', 'irishtimes.com', 'la-croix.com', 'lne.es', 'marketwatch.com', 'nationalreview.com', 'noz.de', 'nwzonline.de', 'seekingalpha.com', 'shz.de', 'sueddeutsche.de', 'svz.de', 'telegraph.co.uk'].concat(au_news_corp_domains, au_nine_domains, de_madsack_domains, es_epiberica_domains, es_grupo_vocento_domains, fr_groupe_ebra_domains, fr_groupe_la_depeche_domains, it_repubblica_domains, usa_mcc_domains, usa_theathletic_domains), header_referer));
bpc_amp_site = (matchUrlDomain('cdn.ampproject.org', details.url) && matchUrlDomain(['asiatimes.com', 'augsburger-allgemeine.de', 'barrons.com', 'belfasttelegraph.co.uk', 'cicero.de', 'cmjornal.pt', 'elmundo.es', 'elpais.com', 'elperiodico.com', 'expansion.com', 'freiepresse.de', 'independent.ie', 'irishtimes.com', 'la-croix.com', 'lne.es', 'marketwatch.com', 'nationalreview.com', 'noz.de', 'nwzonline.de', 'scmp.com', 'seekingalpha.com', 'shz.de', 'sueddeutsche.de', 'svz.de', 'telegraph.co.uk'].concat(au_news_corp_domains, au_nine_domains, de_madsack_domains, es_epiberica_domains, es_grupo_vocento_domains, fr_groupe_ebra_domains, fr_groupe_la_depeche_domains, it_repubblica_domains, usa_mcc_domains, usa_theathletic_domains), header_referer));
}
if (!isSiteEnabled(details) && !allow_ext_source && !bpc_amp_site && !au_apn_site && !au_swm_site) {

View File

@ -2,6 +2,7 @@
Changelog Bypass Paywalls Clean - Firefox
Post-release
Fix-update South China Morning Post (amp)
* v2.2.0.0 (2021-05-09)
Add Asia Times

View File

@ -2096,6 +2096,15 @@ else if (matchDomain('republic.ru')) {
removeDOMElement(paywall);
}
else if (matchDomain('scmp.com') && window.location.href.includes('/amp.')) {
let div_hidden_all = document.querySelectorAll('div.article-body[amp-access][amp-access-hide]');
for (let div_hidden of div_hidden_all)
div_hidden.removeAttribute('amp-access-hide');
let default_meters = document.querySelectorAll('div.default-meter, div#archive-article-meter');
let adverts = document.querySelectorAll('amp-ad, div.ad-banner, div.advert-fly-carpet-container, div.inline-advert');
removeDOMElement(...default_meters, ...adverts);
}
else if (matchDomain('scribd.com')) {
let blurred_pages = document.querySelectorAll('.blurred_page');
for (let blurred_page of blurred_pages) {

View File

@ -512,5 +512,5 @@
"*://*.wallkit.net/*",
"*://*.wsj.net/*"
],
"version": "2.2.0.0"
"version": "2.2.0.1"
}