Merge pull request #364 from magnolia1234/master

Add Scientific American (fix free-article limit) & The Hindu & fix Le Monde & fix Bloomberg & fix default websites in options
master
Adam 2019-11-10 11:34:43 -08:00 committed by GitHub
commit d25418dc2e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 19 additions and 6 deletions

View File

@ -54,6 +54,7 @@
[Parool](https://www.parool.nl)\ [Parool](https://www.parool.nl)\
[Quartz](https://qz.com)\ [Quartz](https://qz.com)\
[Quora](https://www.quora.com)\ [Quora](https://www.quora.com)\
[Scientific American](https://scientificamerican.com)\
[Statista](https://www.statista.com)\ [Statista](https://www.statista.com)\
[SunSentinel](https://www.sun-sentinel.com)\ [SunSentinel](https://www.sun-sentinel.com)\
[Telegraaf](https://telegraaf.nl)\ [Telegraaf](https://telegraaf.nl)\
@ -67,6 +68,7 @@
[The Diplomat](https://www.thediplomat.com)\ [The Diplomat](https://www.thediplomat.com)\
[The Globe and Mail](https://www.theglobeandmail.com)\ [The Globe and Mail](https://www.theglobeandmail.com)\
[The Herald](https://www.theherald.com.au)\ [The Herald](https://www.theherald.com.au)\
[The Hindu](https://www.thehindu.com)\
[The Japan Times](https://www.japantimes.co.jp)\ [The Japan Times](https://www.japantimes.co.jp)\
[TheMarker](https://www.themarker.com)\ [TheMarker](https://www.themarker.com)\
[The Mercury News](https://www.mercurynews.com)\ [The Mercury News](https://www.mercurynews.com)\

View File

@ -32,7 +32,7 @@ var defaultSites = {
'Inc.com': 'inc.com', 'Inc.com': 'inc.com',
'Investors Chronicle': 'investorschronicle.co.uk', 'Investors Chronicle': 'investorschronicle.co.uk',
'La Repubblica': 'repubblica.it', 'La Repubblica': 'repubblica.it',
'Le Monde': 'lemonde.fr', 'Le Monde': 'lemonde.fr',
'Le Temps': 'letemps.ch', 'Le Temps': 'letemps.ch',
'Los Angeles Times': 'latimes.com', 'Los Angeles Times': 'latimes.com',
'Medium': 'medium.com', 'Medium': 'medium.com',
@ -51,9 +51,10 @@ var defaultSites = {
'Parool': 'parool.nl', 'Parool': 'parool.nl',
'Quartz': 'qz.com', 'Quartz': 'qz.com',
'Quora': 'quora.com', 'Quora': 'quora.com',
'Scientific American': 'scientificamerican.com',
'Statista': 'statista.com', 'Statista': 'statista.com',
'Telegraaf': 'telegraaf.nl',
'SunSentinel': 'sun-sentinel.com', 'SunSentinel': 'sun-sentinel.com',
'Telegraaf': 'telegraaf.nl',
'The Advocate': 'theadvocate.com.au', 'The Advocate': 'theadvocate.com.au',
'The Age': 'theage.com.au', 'The Age': 'theage.com.au',
'The Atlantic': 'theatlantic.com', 'The Atlantic': 'theatlantic.com',
@ -64,6 +65,7 @@ var defaultSites = {
'The Diplomat': 'thediplomat.com', 'The Diplomat': 'thediplomat.com',
'The Globe and Mail': 'theglobeandmail.com', 'The Globe and Mail': 'theglobeandmail.com',
'The Herald': 'theherald.com.au', 'The Herald': 'theherald.com.au',
'The Hindu': 'thehindu.com',
'The Japan Times': 'japantimes.co.jp', 'The Japan Times': 'japantimes.co.jp',
'TheMarker': 'themarker.com', 'TheMarker': 'themarker.com',
'The Mercury News': 'mercurynews.com', 'The Mercury News': 'mercurynews.com',
@ -116,6 +118,7 @@ const allow_cookies = [
'ocregister.com', 'ocregister.com',
'parool.nl', 'parool.nl',
'qz.com', 'qz.com',
'scientificamerican.com',
'spectator.co.uk', 'spectator.co.uk',
'telegraaf.nl', 'telegraaf.nl',
'theadvocate.com.au', 'theadvocate.com.au',
@ -153,6 +156,7 @@ const remove_cookies = [
'nytimes.com', 'nytimes.com',
'ocregister.com', 'ocregister.com',
'qz.com', 'qz.com',
'scientificamerican.com',
'spectator.co.uk', 'spectator.co.uk',
'telegraaf.nl', 'telegraaf.nl',
'theadvocate.com.au', 'theadvocate.com.au',
@ -181,6 +185,7 @@ const remove_cookies_select_drop = {
// Override User-Agent with Googlebot // Override User-Agent with Googlebot
const use_google_bot = [ const use_google_bot = [
'barrons.com', 'barrons.com',
'lemonde.fr',
'nytimes.com', 'nytimes.com',
'quora.com', 'quora.com',
'telegraph.co.uk', 'telegraph.co.uk',

View File

@ -106,8 +106,10 @@ if (window.location.href.indexOf("bloombergquint.com") !== -1) {
} }
if (window.location.href.indexOf("bloomberg.com") !== -1) { if (window.location.href.indexOf("bloomberg.com") !== -1) {
const paywall = document.getElementById('paywall-banner'); document.addEventListener('DOMContentLoaded', () => {
removeDOMElement(paywall); const paywall = document.getElementById('paywall-banner');
removeDOMElement(paywall);
});
} }
if (window.location.href.indexOf('telegraaf.nl') !== -1) { if (window.location.href.indexOf('telegraaf.nl') !== -1) {

View File

@ -138,7 +138,9 @@
"*://*.telegraaf.nl/*", "*://*.telegraaf.nl/*",
"*://*.trouw.nl/*", "*://*.trouw.nl/*",
"*://*.vn.nl/*", "*://*.vn.nl/*",
"*://*.lemonde.fr/*" "*://*.lemonde.fr/*",
"*://*.scientificamerican.com/*",
"*://*.thehindu.com/*"
], ],
"version": "1.6.0" "version": "1.6.0"
} }

View File

@ -49,6 +49,7 @@ var defaultSites = {
'Parool': 'parool.nl', 'Parool': 'parool.nl',
'Quartz': 'qz.com', 'Quartz': 'qz.com',
'Quora': 'quora.com', 'Quora': 'quora.com',
'Scientific American': 'scientificamerican.com',
'Statista': 'statista.com', 'Statista': 'statista.com',
'SunSentinel': 'sun-sentinel.com', 'SunSentinel': 'sun-sentinel.com',
'Telegraaf': 'telegraaf.nl', 'Telegraaf': 'telegraaf.nl',
@ -62,6 +63,7 @@ var defaultSites = {
'The Diplomat': 'thediplomat.com', 'The Diplomat': 'thediplomat.com',
'The Globe and Mail (javascript disabled)': 'theglobeandmail.com', 'The Globe and Mail (javascript disabled)': 'theglobeandmail.com',
'The Herald': 'theherald.com.au', 'The Herald': 'theherald.com.au',
'The Hindu': 'thehindu.com',
'The Japan Times': 'japantimes.co.jp', 'The Japan Times': 'japantimes.co.jp',
'TheMarker': 'themarker.com', 'TheMarker': 'themarker.com',
'The Mercury News': 'mercurynews.com', 'The Mercury News': 'mercurynews.com',
@ -131,7 +133,7 @@ function renderOptions() {
inputEl.type = 'checkbox'; inputEl.type = 'checkbox';
inputEl.dataset.key = key; inputEl.dataset.key = key;
inputEl.dataset.value = value; inputEl.dataset.value = value;
inputEl.checked = key in sites; inputEl.checked = (key in sites) || (key.replace(/\s\(.*\)/, '') in sites);
labelEl.appendChild(inputEl); labelEl.appendChild(inputEl);
labelEl.appendChild(document.createTextNode(' '+key)); labelEl.appendChild(document.createTextNode(' '+key));