diff --git a/background.js b/background.js index 313e4411..65b5127b 100644 --- a/background.js +++ b/background.js @@ -325,6 +325,7 @@ var blockedRegexes = { 'foreignpolicy.com': /(cdn\.cxense\.com\/|\.tinypass\.com\/)/, 'fortune.com': /\.tinypass\.com\//, 'freiepresse.de': /cdn\.ampproject\.org\/v\d\/amp-(access|ad|consent)-.+\.js/, + 'ft.com': /cdn\.ampproject\.org\/v\d\/amp-(access|ad|subscriptions)-.+\.js/, 'ftm.nl': /\.ftm\.nl\/js\/routing\?/, 'gestion.pe': /\/gestion\.pe\/pf\/dist\/engine\/react\.js/, 'globes.co.il': /\.tinypass\.com\//, @@ -1282,7 +1283,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 || usa_law360_site || usa_mw_site || usa_natgeo_site || usa_today_site; - bpc_amp_site = (matchUrlDomain('cdn.ampproject.org', details.url) && matchUrlDomain(['aachener-zeitung.de', 'asiatimes.com', 'augsburger-allgemeine.de', 'barrons.com', 'belfasttelegraph.co.uk', 'cicero.de', 'cmjornal.pt', 'elpais.com', 'elperiodico.com', 'freiepresse.de', 'handelsblatt.com', 'ilfattoquotidiano.it', 'inc42.com', 'independent.ie', 'irishtimes.com', 'la-croix.com', 'marketwatch.com', 'nationalreview.com', 'noz.de', 'nwzonline.de', 'scmp.com', 'seekingalpha.com', 'shz.de', 'staradvertiser.com', 'sueddeutsche.de', 'svz.de', 'telegraph.co.uk', 'washingtonpost.com', 'westfalen-blatt.de', 'wn.de', 'wsj.com'].concat(amp_unhide, au_news_corp_domains, au_nine_domains, de_madsack_domains, es_epiberica_domains, es_grupo_vocento_domains, es_unidad_domains, fr_groupe_ebra_domains, fr_groupe_la_depeche_domains, it_repubblica_domains, usa_mcc_domains, usa_mng_domains, usa_theathletic_domains), header_referer)); + bpc_amp_site = (matchUrlDomain('cdn.ampproject.org', details.url) && matchUrlDomain(['aachener-zeitung.de', 'asiatimes.com', 'augsburger-allgemeine.de', 'barrons.com', 'belfasttelegraph.co.uk', 'cicero.de', 'cmjornal.pt', 'elpais.com', 'elperiodico.com', 'freiepresse.de', 'ft.com', 'handelsblatt.com', 'ilfattoquotidiano.it', 'inc42.com', 'independent.ie', 'irishtimes.com', 'la-croix.com', 'marketwatch.com', 'nationalreview.com', 'noz.de', 'nwzonline.de', 'scmp.com', 'seekingalpha.com', 'shz.de', 'staradvertiser.com', 'sueddeutsche.de', 'svz.de', 'telegraph.co.uk', 'washingtonpost.com', 'westfalen-blatt.de', 'wn.de', 'wsj.com'].concat(amp_unhide, au_news_corp_domains, au_nine_domains, de_madsack_domains, es_epiberica_domains, es_grupo_vocento_domains, es_unidad_domains, fr_groupe_ebra_domains, fr_groupe_la_depeche_domains, it_repubblica_domains, usa_mcc_domains, usa_mng_domains, usa_theathletic_domains), header_referer)); } if (!isSiteEnabled(details) && !allow_ext_source && !bpc_amp_site && !au_swm_site) { diff --git a/changelog.txt b/changelog.txt index 81083242..cafdf963 100644 --- a/changelog.txt +++ b/changelog.txt @@ -2,6 +2,7 @@ Changelog Bypass Paywalls Clean - Firefox Post-release +Fix Financial Times (amp) * v2.4.0.0 (2021-10-17) Add Westfaelische Nachrichten (Germany) diff --git a/contentScript.js b/contentScript.js index 1ca3aa91..68dc3d11 100644 --- a/contentScript.js +++ b/contentScript.js @@ -1970,10 +1970,16 @@ else if (matchDomain('foreignpolicy.com')) { } else if (matchDomain('ft.com')) { - let cookie_banner = document.querySelector('.o-banner__outer'); - let ribbon = document.querySelector('.js-article-ribbon'); - let ads = document.querySelector('.o-ads'); - removeDOMElement(cookie_banner, ribbon, ads); + if (window.location.hostname.startsWith('amp.')) { + let subscr_section = document.querySelector('[subscriptions-section="content"]'); + if (subscr_section) + subscr_section.removeAttribute('subscriptions-section'); + } else { + let cookie_banner = document.querySelector('.o-banner__outer'); + let ribbon = document.querySelector('.js-article-ribbon'); + let ads = document.querySelector('.o-ads'); + removeDOMElement(cookie_banner, ribbon, ads); + } } else if (matchDomain('griffithreview.com')) { diff --git a/sites.js b/sites.js index 03ec31e0..ff84320e 100644 --- a/sites.js +++ b/sites.js @@ -17,7 +17,6 @@ var defaultSites = "Augsburger Allgemeine": "augsburger-allgemeine.de", "Australia News Corp": "###_au_news_corp", "Australian Community Media (daily)": "###_au_comm_media", - "Australian Provincial Newspapers (daily) (opt-in)": "###_au_prov_news", "Barron's": "barrons.com", "BBC History Extra": "historyextra.com", "Belfast Telegraph (opt-in)": "belfasttelegraph.co.uk",