Add Substack (link to Google Search Tool)

Update popup (12ft.io)
merge-requests/14/head
magnolia1234 1 year ago
parent fd4179fc54
commit 2e0c0e3582

@ -173,6 +173,7 @@ Grouped in options:\
##### Magazines/Blogs
[Medium](https://www.medium.com)\
[Substack](https://substack.com) (link to Google Search Tool; opt-in to custom sites for custom domains)\
Grouped in options:\
*Medium custom domains* like (opt-in to custom sites for unlisted)\
[Better Programming](https://betterprogramming.pub) -
@ -904,7 +905,7 @@ Remember to check the [previous requests](https://gitlab.com/magnolia1234/bypass
3. Disable Javascript on the site (by browser, uBlock Origin or other add-on).
4. Add the domain as custom site for more bypass options.
5. Open page in reader view (by browser or add-on).
6. Try one of the archive sites.
6. Try one of the archive sites (for Google Search Tool copy html (tab) code to https://html.onlineviewer.net).
### Add custom site
Add your own custom site (also for testing).

@ -1309,6 +1309,8 @@ function clear_cookies() {
if (!enabledSites.includes(custom_domain))
enabledSites.push(custom_domain);
ext_api.tabs.reload({bypassCache: true});
if (rules.add_ext_link && rules.add_ext_link_type)
add_ext_link[custom_domain] = {css: rules.add_ext_link, type: rules.add_ext_link_type};
}
var chrome_scheme = 'light';
@ -1324,7 +1326,7 @@ ext_api.runtime.onMessage.addListener(function (message, sender) {
let custom_domain = message.data.domain;
let group = message.data.group;
if (group) {
let nofix_groups = ['###_substack_custom', '###_ch_tamedia', '###_fi_alma_talent', '###_it_citynews'];
let nofix_groups = ['###_ch_tamedia', '###_fi_alma_talent', '###_it_citynews'];
if (enabledSites.concat(nofix_groups).includes(group) && !custom_flex_domains.includes(custom_domain)) {
let rules;
if (group === 'elmercurio.com')

@ -5,7 +5,9 @@ Updates: https://gitlab.com/magnolia1234/bypass-paywalls-firefox-clean/-/release
Post-release
Add El Observador, El Pais & La Diaria (Uruguay)
Add Jacobin.de
Add Substack (link to Google Search Tool; opt-in to custom sites for custom domains)
Fix Berlingske.dk
Update popup (12ft.io)
* v3.1.3.0 (2023-04-10)
Add Haas Mediengruppe (opt-in to custom sites)

@ -5027,7 +5027,7 @@ function amp_unhide_subscr_section(amp_ads_sel = 'amp-ad, .ad', replace_iframes
}
function amp_unhide_access_hide(amp_access = '', amp_access_not = '', amp_ads_sel = 'amp-ad, .ad', replace_iframes = true, amp_iframe_link = false, source = '') {
let access_hide = document.querySelectorAll('[amp-access' + amp_access + '][amp-access-hide]:not([amp-access="error"], [amp-access^="message"]):not(.piano)');
let access_hide = document.querySelectorAll('[amp-access' + amp_access + '][amp-access-hide]:not([amp-access="error"], [amp-access^="message"], .piano)');
for (let elem of access_hide)
elem.removeAttribute('amp-access-hide');
if (amp_access_not) {
@ -5059,7 +5059,7 @@ function googleWebcacheLink(url, text_fail = 'BPC > Full article text:\r\n') {
return externalLink(['webcache.googleusercontent.com'], 'https://{domain}/search?q=cache:{url}', url, text_fail);
}
function googleSearchToolLink(url, text_fail = 'BPC > Full article text:\r\n') {
function googleSearchToolLink(url, text_fail = 'BPC > Full article text (copy html (tab) code to html.onlineviewer.net):\r\n') {
return externalLink(['search.google.com'], 'https://search.google.com/test/rich-results?url={url}', encodeURIComponent(url), text_fail);
}
@ -5068,11 +5068,9 @@ function ext_12ftLink(url, text_fail = 'BPC > Full article text:\r\n') {
}
function externalLink(domains, ext_url_templ, url, text_fail = 'BPC > Full article text:\r\n') {
if (domains.includes('search.google.com'))
text_fail = 'BPC > Full article text (copy html (tab) code to online html viewer):\r\n'
let text_fail_div = document.createElement('div');
text_fail_div.id = 'bpc_archive';
text_fail_div.setAttribute('style', 'margin: 20px; font-weight: bold; color:red;');
text_fail_div.setAttribute('style', 'margin: 20px; font-weight: bold; color: red;');
text_fail_div.appendChild(document.createTextNode(text_fail));
for (let domain of domains) {
let ext_url = ext_url_templ.replace('{domain}', domain).replace('{url}', url.split('?')[0]);

@ -38,7 +38,7 @@ window.setTimeout(function () {
else if (document.querySelector('script[src*="/leaky-paywall"], link[href*="/leaky-paywall"]'))
group = '###_wp_leaky_paywall';
else if (document.querySelector('script[src*="/substackcdn.com/"], link[rel="stylesheet"][href*="/substackcdn.com/"]'))
group = '###_substack_custom';// no fix
group = '###_substack_custom';
else if (hostname.match(/\.(com|net)\.au$/)) {
if (document.querySelector('a[href*="/australiancommunitymedia.zendesk.com/"]'))
group = '###_au_comm_media';

@ -51,5 +51,5 @@
"webRequestBlocking",
"*://*/*"
],
"version": "3.1.3.2"
"version": "3.1.3.3"
}

@ -394,7 +394,7 @@
"domain": "stylist.co.uk"
},
"Substack.com": {
"add_ext_link": "div.paywall:not(.modal-paywall)|div.available-content",
"add_ext_link": "div.paywall:not(.modal-paywall)|article",
"add_ext_link_type": "google_search_tool",
"allow_cookies": 1,
"domain": "substack.com"

@ -581,6 +581,7 @@
"*://*.stocknews.com/*",
"*://*.stratfor.com/*",
"*://*.studocu.com/*",
"*://*.substack.com/*",
"*://*.sudinfo.be/*",
"*://*.sudouest.fr/*",
"*://*.sueddeutsche.de/*",
@ -747,8 +748,10 @@
"*://*.ndcmediagroep.nl/*",
"*://*.nyt.com/*",
"*://*.pasedigital.cl/*",
"*://*.substackcdn.com/*",
"*://*.wallkit.net/*",
"*://html.onlineviewer.net/*",
"*://webcache.googleusercontent.com/*"
],
"version": "3.1.3.2"
"version": "3.1.3.3"
}

@ -84,6 +84,7 @@ function showArchiveLinks() {
let archive_array = {
'Archive.today': 'https://archive.today?run=1&url=' + url_enc,
'Google webcache': 'https://webcache.googleusercontent.com/search?q=cache:' + url_enc,
'12ft.io': 'https://12ft.io/' + url,
'Google Search Tool\n(use online html-viewer - no fix)': 'https://search.google.com/test/rich-results?url=' + url_enc
};
let archive_id = document.querySelector('span#archive');
@ -93,7 +94,7 @@ function showArchiveLinks() {
let elem_div = document.createElement('div');
let elem = document.createElement('a');
elem.innerText = key;
if (!(matchDomain(['google.com', 'googleusercontent.com'], hostname) || hostname.match(/^archive\.\w{2}$/))) {
if (!(matchDomain(['12ft.io', 'google.com', 'googleusercontent.com'], hostname) || hostname.match(/^archive\.\w{2}$/))) {
elem.href = archive_array[key];
elem.target = '_blank';
elem_div.appendChild(elem);

@ -2383,6 +2383,22 @@ var defaultSites = {
block_regex_general: /\/steadyhq\.com\//,
excluded_domains: ["steadyhq.com"]
},
"Substack (link to Google Search Tool; opt-in to custom sites for custom domains)": {
domain: "###_substack_custom",
group: [
"substack.com",
"html.onlineviewer.net"
],
add_ext_link: "div.paywall:not(.modal-paywall)|article",
add_ext_link_type: "google_search_tool",
allow_cookies: 1,
exception: [{
domain: "html.onlineviewer.net",
allow_cookies: 1,
block_regex: /\/substackcdn\.com\/min\/main\.bundle\.js/
}
]
},
"TownNews sites (Blox CMS; not encrypted)": {
domain: "###_usa_townnews",
block_regex_general: /\/shared-content\/art\/tncms\/user\/user\.js/
@ -2510,4 +2526,4 @@ var au_news_corp_nofix_domains = ['cairnspost.com.au', 'geelongadvertiser.com.au
var be_mediahuis_nofix_domains = ['gva.be', 'hbvl.be', 'nieuwsblad.be', 'standaard.be'];
var de_rp_medien_nofix_domains = ['ga.de', 'rp-online.de', 'saarbruecker-zeitung.de', 'volksfreund.de'];
var it_gedi_nofix_domains = ['gelocal.it', 'huffingtonpost.it', 'ilsecoloxix.it', 'lastampa.it', 'limesonline.com', 'repubblica.it'];
var nofix_sites = ['aamulehti.fi', 'africaintelligence.com', 'africaintelligence.fr', 'aftenposten.no', 'asiatimes.com', 'badische-zeitung.de', 'bild.de', 'borsen.dk', 'business-standard.com', 'businesstimes.com.sg', 'caixin.com', 'caixinglobal.com', 'caravanmagazine.in', 'catalyst-journal.com', 'courrierinternational.com', 'diepresse.com', 'dn.se', 'elordenmundial.com', 'epw.in', 'expresso.pt', 'finance.si', 'ftchinese.com', 'gamestar.de', 'golem.de', 'handelsblatt.com', 'heise.de', 'hln.be', 'hs.fi', 'ilsole24ore.com', 'investors.com', 'iltalehti.fi', 'jacobinmag.com', 'jeuneafrique.com', 'kleinezeitung.at', 'lavie.fr', 'lavozdegalicia.es', 'law360.com', 'le1hebdo.fr', 'leconomiste.com', 'lemonde.fr', 'lequipe.fr', 'letemps.ch', 'liberation.fr', 'lopinion.fr', 'medianama.com', 'mediapart.fr', 'milanofinanza.it', 'mittelbayerische.de', 'mondediplo.com', 'moneycontrol.com', 'nationaljournal.com', 'nature.com', 'nbr.co.nz', 'nn.de', 'nwzonline.de', 'ouest-france.fr', 'philonomist.com', 'pnp.de', 'politicopro.com', 'politiken.dk', 'pressreader.com', 'publico.pt', 'republic.ru', 'rheinpfalz.de', 'rnz.de', 'ruhrnachrichten.de', 'saechsische.de', 'schwarzwaelder-bote.de', 'statnews.com', 'stern.de', 'stimme.de', 'straitstimes.com', 'stuttgarter-nachrichten.de', 'stuttgarter-zeitung.de', 'substack.com', 'suedkurier.de', 'swp.de', 'techcrunch.com', 'the-ken.com', 'thedispatch.com', 'theinformation.com', 'themorningcontext.com', 'theparisreview.org', 'thewirechina.com', 'welt.de', 'weser-kurier.de', 'wiwo.de', 'worldpoliticsreview.com', 'ynet.co.il'].concat(au_news_corp_nofix_domains, be_mediahuis_nofix_domains, de_rp_medien_nofix_domains, it_gedi_nofix_domains);
var nofix_sites = ['aamulehti.fi', 'africaintelligence.com', 'africaintelligence.fr', 'aftenposten.no', 'asiatimes.com', 'badische-zeitung.de', 'bild.de', 'borsen.dk', 'business-standard.com', 'businesstimes.com.sg', 'caixin.com', 'caixinglobal.com', 'caravanmagazine.in', 'catalyst-journal.com', 'courrierinternational.com', 'diepresse.com', 'dn.se', 'elordenmundial.com', 'epw.in', 'expresso.pt', 'finance.si', 'ftchinese.com', 'gamestar.de', 'golem.de', 'handelsblatt.com', 'heise.de', 'hln.be', 'hs.fi', 'ilsole24ore.com', 'investors.com', 'iltalehti.fi', 'jacobinmag.com', 'jeuneafrique.com', 'kleinezeitung.at', 'lavie.fr', 'lavozdegalicia.es', 'law360.com', 'le1hebdo.fr', 'leconomiste.com', 'lemonde.fr', 'lequipe.fr', 'letemps.ch', 'liberation.fr', 'lopinion.fr', 'medianama.com', 'mediapart.fr', 'milanofinanza.it', 'mittelbayerische.de', 'mondediplo.com', 'moneycontrol.com', 'nationaljournal.com', 'nature.com', 'nbr.co.nz', 'nn.de', 'nwzonline.de', 'ouest-france.fr', 'philonomist.com', 'pnp.de', 'politicopro.com', 'politiken.dk', 'pressreader.com', 'publico.pt', 'republic.ru', 'rheinpfalz.de', 'rnz.de', 'ruhrnachrichten.de', 'saechsische.de', 'schwarzwaelder-bote.de', 'statnews.com', 'stern.de', 'stimme.de', 'straitstimes.com', 'stuttgarter-nachrichten.de', 'stuttgarter-zeitung.de', 'suedkurier.de', 'swp.de', 'techcrunch.com', 'the-ken.com', 'thedispatch.com', 'theinformation.com', 'themorningcontext.com', 'theparisreview.org', 'thewirechina.com', 'welt.de', 'weser-kurier.de', 'wiwo.de', 'worldpoliticsreview.com', 'ynet.co.il'].concat(au_news_corp_nofix_domains, be_mediahuis_nofix_domains, de_rp_medien_nofix_domains, it_gedi_nofix_domains);

Loading…
Cancel
Save