diff --git a/README.md b/README.md index 45db6f9..946d397 100644 --- a/README.md +++ b/README.md @@ -835,13 +835,12 @@ You can also exclude a specific domain which is grouped in options. ### Troubleshooting * This add-on works best alongside the adblocker [uBlock Origin](https://addons.mozilla.org/firefox/addon/ublock-origin). -* Add usefull custom filter [Fanboy's Enhanced Tracking List](https://www.fanboy.co.nz/enhancedstats.txt) * If a site doesn't work, try turning off uBlock and refreshing. * Make sure the (new) site is checked under Options. * You will be logged out for most of the sites you have checked. * Make sure you're running the latest version of Bypass Paywalls Clean. * If none of these work, you can [submit an issue](https://gitlab.com/magnolia1234/bypass-paywalls-firefox-clean/-/issues). -* If you live in the EU, also consider installing the extension [I don't care about cookies](https://addons.mozilla.org/firefox/addon/i-dont-care-about-cookies) in order to remove cookie warnings (or add filter [Easylist Cookies](https://easylist-downloads.adblockplus.org/easylist-cookie.txt) | [I don't care about cookies custom filter](https://www.i-dont-care-about-cookies.eu/abp) to uBlock Origin). Some sites need to set a consent-cookie for (social) media. +* If you live in the EU, also consider adding these filters to your adblocker (in order to remove cookie warnings): [Easylist Cookies](https://easylist-downloads.adblockplus.org/easylist-cookie.txt) | [I don't care about cookies custom filter](https://www.i-dont-care-about-cookies.eu/abp). Some sites need to set a consent-cookie for (social) media. ### Changelog-releases * Visit the [changelog page](https://gitlab.com/magnolia1234/bypass-paywalls-firefox-clean/-/blob/master/changelog.txt). diff --git a/background.js b/background.js index 190329c..1caab8c 100644 --- a/background.js +++ b/background.js @@ -682,6 +682,7 @@ ext_api.webRequest.onHeadersReceived.addListener(function (details) { var block_js = [ "*://*.blueconic.net/*", "*://*.cxense.com/*", + "*://*.ensighten.com/*/Bootstrap.js*", "*://*.evolok.net/*", "*://*.newsmemory.com/?meter*", "*://*.onecount.net/*", @@ -705,7 +706,7 @@ var block_js = [ "*://js.matheranalytics.com/*", "*://js.pelcro.com/*", "*://loader-cdn.azureedge.net/prod/*/loader.min.js*", - "*://nexus.ensighten.com/*/Bootstrap.js*", + ]; // Disable javascript for these sites/general paywall-scripts @@ -885,9 +886,9 @@ ext_api.webRequest.onBeforeSendHeaders.addListener(function(details) { if (usa_gannett_domain) usa_gannett_domains = customAddRules(usa_gannett_domains, '', blockedRegexes['azcentral.com'], 'googlebot', '', true); else { - var usa_hearst_comm_domain = (matchUrlDomain('treg.hearstnp.com', details.url) && ['script'].includes(details.type) && !matchUrlDomain(usa_hearst_comm_domains, header_referer) && enabledSites.includes('###_usa_hearst_comm')); + var usa_hearst_comm_domain = (matchUrlDomain('treg.hearstnp.com', details.url) && ['script'].includes(details.type) && !matchUrlDomain(usa_hearst_comm_domains.concat(['sfgate.com']), header_referer) && enabledSites.includes('###_usa_hearst_comm')); if (usa_hearst_comm_domain) - usa_hearst_comm_domains = customAddRules(usa_hearst_comm_domains, '', blockedRegexes['houstonchronicle.com']); + usa_hearst_comm_domains = customAddRules(usa_hearst_comm_domains, {allow_cookies: 1}, blockedRegexes['houstonchronicle.com']); else { // block script for additional Lee Enterprises sites (opt-in to custom sites) var usa_lee_ent_domain = (details.url.match(/\.townnews\.com\/(central\.)?leetemplates\.com\//) && ['script'].includes(details.type) && diff --git a/changelog.txt b/changelog.txt index bb30bd4..779696a 100644 --- a/changelog.txt +++ b/changelog.txt @@ -2,6 +2,7 @@ Changelog Bypass Paywalls Clean - Firefox Post-release +Fix Hearst Communications (newspapers) * v2.8.5.0 (2022-09-18) Add 60 Millions de consommateurs diff --git a/contentScript.js b/contentScript.js index d36275a..137dfc4 100644 --- a/contentScript.js +++ b/contentScript.js @@ -950,6 +950,8 @@ else if (matchDomain('elconfidencial.com')) { let premium = document.querySelector('div.newsType__content--closed'); if (premium) premium.classList.remove('newsType__content--closed'); + let ads = document.querySelectorAll('div[id^="mega_"], div[id^="roba_"]'); + removeDOMElement(...ads); } else if (matchDomain('eldiario.es')) { diff --git a/custom/sites_custom.json b/custom/sites_custom.json index 04a765a..77f5cfd 100644 --- a/custom/sites_custom.json +++ b/custom/sites_custom.json @@ -89,6 +89,12 @@ "domain": "gplanet.co.il", "ld_json": "div.subscription-form|div.content-inner" }, + "Heidi.news": { + "allow_cookies": 1, + "block_regex": "\\.piano\\.io\\/", + "domain": "heidi.news", + "useragent": "googlebot" + }, "Heraldscotland.com": { "allow_cookies": 1, "block_regex": "\\.tinypass\\.com\\/", diff --git a/manifest.json b/manifest.json index e54f6b8..b16c32a 100644 --- a/manifest.json +++ b/manifest.json @@ -707,5 +707,5 @@ "*://gcm.omerlocdn.com/*", "*://webcache.googleusercontent.com/*" ], - "version": "2.8.5.0" + "version": "2.8.5.1" } diff --git a/sites.js b/sites.js index 12e7e7a..c55213a 100644 --- a/sites.js +++ b/sites.js @@ -782,7 +782,8 @@ var defaultSites = { "houstonchronicle.com", "sfchronicle.com" ], - block_regex: /(\.blueconic\.net\/|cdn\.ampproject\.org\/v\d\/amp-access-.+\.js)/ + allow_cookies: 1, + block_regex: "(\\.{domain}\\/script\\.js|\\.blueconic\\.net\\/|\\.ensighten\\.com\\/|js\\.matheranalytics\\.com\\/)" }, "Hearst Communications magazines": { domain: "###_usa_hearst_comm_mag", @@ -804,7 +805,7 @@ var defaultSites = { "womenshealthmag.com" ], allow_cookies: 1, - block_regex: /nexus\.ensighten\.com\/hearst\/mag\/Bootstrap\.js/ + block_regex: /\.ensighten\.com\/.+\/Bootstrap\.js/ }, "Hindustan Times": { domain: "hindustantimes.com", @@ -1262,7 +1263,7 @@ var defaultSites = { "Neue Zürcher Zeitung (+ regional/opt-in to custom sites)": { domain: "nzz.ch", allow_cookies: 1, - block_regex: /(\.piano\.io\/|(ens\.nzz\.ch|nexus\.ensighten\.com)\/.+\/Bootstrap\.js|cdn\.ampproject\.org\/v\d\/amp-access-.+\.js)/, + block_regex: /(\.piano\.io\/|(ens\.nzz\.ch|\.ensighten\.com)\/.+\/Bootstrap\.js|cdn\.ampproject\.org\/v\d\/amp-access-.+\.js)/, useragent: "googlebot" }, "New Left Review": { diff --git a/sites_updated.json b/sites_updated.json index fb9408c..93ec743 100644 --- a/sites_updated.json +++ b/sites_updated.json @@ -4,11 +4,6 @@ "allow_cookies": 1, "block_regex": "\\.poool\\.fr\\/" }, - "Berliner Zeitung": { - "domain": "berliner-zeitung.de", - "allow_cookies": 1, - "useragent": "googlebot" - }, "Esprit": { "domain": "esprit.presse.fr", "allow_cookies": 1, @@ -24,6 +19,16 @@ "allow_cookies": 1, "block_regex": "(\\.tinypass\\.com\\/|\\/{domain}\\/pf\\/dist\\/engine\\/react\\.js)" }, + "Hearst Communications (newspapers)": { + "domain": "###_usa_hearst_comm", + "group": [ + "expressnews.com", + "houstonchronicle.com", + "sfchronicle.com" + ], + "allow_cookies": 1, + "block_regex": "(\\.{domain}\\/script\\.js|\\.blueconic\\.net\\/|\\.ensighten\\.com\\/|js\\.matheranalytics\\.com\\/)" + }, "L'Express": { "domain": "lexpress.fr", "allow_cookies": 1,