Add Scribd (unblur text of documents)

This commit is contained in:
magnolia1234 2020-01-05 17:41:06 +01:00 committed by GitHub
parent a2a953f24c
commit cdaa4c20a5
5 changed files with 20 additions and 2 deletions

View file

@ -63,6 +63,7 @@
[Quartz](https://qz.com)\
[Quora](https://www.quora.com)\
[Scientific American](https://scientificamerican.com)\
[Scribd](http://scribd.com)\
[Statista](https://www.statista.com)\
[SunSentinel](https://www.sun-sentinel.com)\
[Tech in Asia]:(https://www.techinasia.com)\

View file

@ -60,6 +60,7 @@ var defaultSites = {
'Quartz': 'qz.com',
'Quora': 'quora.com',
'Scientific American': 'scientificamerican.com',
'Scribd': 'scribd.com',
'Statista': 'statista.com',
'SunSentinel': 'sun-sentinel.com',
'Tech in Asia': 'techinasia.com',
@ -142,6 +143,7 @@ const allow_cookies = [
'quora.com',
'qz.com',
'scientificamerican.com',
'scribd.com',
'spectator.co.uk',
'telegraaf.nl',
'telegraph.co.uk',

View file

@ -279,6 +279,18 @@ if (window.location.href.indexOf("theglobeandmail.com") !== -1) {
});
}
if (window.location.href.indexOf("scribd.com") !== -1) {
const blur = document.querySelectorAll('.blurred_page');
for (let i = 0; i < blur.length; i++) {
blur[i].classList.remove('blurred_page');
}
const portal = document.querySelector('.between_page_portal_root');
const page_module = document.querySelector('.between_page_module');
const promo = document.querySelector('.auto__doc_page_webpack_doc_page_body_static_promo_study');
const ad = document.querySelector('.auto__explain_scribd_v2_advertisement');
removeDOMElement(portal, page_module, promo, ad);
}
function removeDOMElement(...elements) {
for (let element of elements) {
if (element) element.remove();

View file

@ -30,7 +30,8 @@
"*://*.newcastleherald.com.au/*",
"*://*.thestar.com/*",
"*://*.afr.com/*",
"*://*.theglobeandmail.com/*"
"*://*.theglobeandmail.com/*",
"*://*.scribd.com/*"
],
"js": ["contentScript.js"]
}
@ -166,7 +167,8 @@
"*://*.leparisien.fr/*",
"*://*.lesechos.fr/*",
"*://*.theathletic.com/*",
"*://*.techinasia.com/*"
"*://*.techinasia.com/*",
"*://*.scribd.com/*"
],
"version": "1.6.3"
}

View file

@ -58,6 +58,7 @@ var defaultSites = {
'Quartz': 'qz.com',
'Quora': 'quora.com',
'Scientific American': 'scientificamerican.com',
'Scribd (documents only)': 'scribd.com',
'Statista': 'statista.com',
'SunSentinel': 'sun-sentinel.com',
'Tech in Asia': 'techinasia.com',