Fix Quotidiano.net sites

merge-requests/3/head
magnolia1234 2 years ago
parent 0e9594456c
commit 227042557b

@ -123,9 +123,10 @@ function setDefaultOptions() {
}
function check_sites_updated() {
//var sites_updated_json = 'https://gitlab.com/magnolia1234/bypass-paywalls-' + url_loc + '-clean/-/raw/master/sites_updated.json';
var sites_updated_json = 'https://bitbucket.org/magnolia1234/bypass-paywalls-firefox-clean/raw/master/sites_updated.json';
fetch(sites_updated_json)
let url = 'https://gitlab.com/magnolia1234/bypass-paywalls-' + url_loc + '-clean/-/raw/master/sites_updated.json';
//let url = 'https://bitbucket.org/magnolia1234/bypass-paywalls-firefox-clean/raw/master/sites_updated.json';
let proxyurl = 'https://bpc2-cors-anywhere.herokuapp.com/';
fetch(proxyurl + url, {headers: {"Content-Type": "text/plain", "X-Requested-With": "XMLHttpRequest"} })
.then(response => {
if (response.ok) {
response.json().then(json => {
@ -1130,9 +1131,10 @@ function updateBadge(activeTab) {
var ext_version_new;
function check_update() {
//var manifest_new = 'https://gitlab.com/magnolia1234/bypass-paywalls-' + url_loc + '-clean/-/raw/master/manifest.json';
var manifest_new = 'https://bitbucket.org/magnolia1234/bypass-paywalls-firefox-clean/raw/master/manifest.json';
fetch(manifest_new)
let url = 'https://gitlab.com/magnolia1234/bypass-paywalls-' + url_loc + '-clean/raw/master/manifest.json';
//let url = 'https://bitbucket.org/magnolia1234/bypass-paywalls-firefox-clean/raw/master/manifest.json';
let proxyurl = 'https://bpc2-cors-anywhere.herokuapp.com/';
fetch(proxyurl + url, {headers: {"Content-Type": "text/plain", "X-Requested-With": "XMLHttpRequest"} })
.then(response => {
if (response.ok) {
response.json().then(json => {

@ -7,6 +7,7 @@ Fix Live Law
Fix NewcastleHerald.com.au
Fix Lequipe.fr (json)
Fix Neue Osnabrucker Zeitung (amp)
Fix Quotidiano.net sites
Update block general paywall script (Pigeon)
* v2.5.6.0 (2022-02-13)

@ -1408,11 +1408,11 @@ else if (matchDomain(it_quotidiano_domains)) {
if (window.location.pathname.endsWith('/amp')) {
amp_unhide_access_hide('="c.customGranted"', '="NOT c.customGranted"', 'amp-ad, amp-fx-flying-carpet');
} else {
let detail_text_truncated = document.querySelector('div.detail-text--truncated');
let detail_page_paywall = document.querySelector('body.detail-page--paywall');
if (detail_page_paywall) {
removeDOMElement(detail_text_truncated);
detail_page_paywall.classList.remove('detail-page--paywall');
let paywall = document.querySelector('div[data-testid="paywall-container"]');
let amphtml = document.querySelector('link[rel="amphtml"]');
if (paywall && amphtml) {
removeDOMElement(paywall);
window.location.href = amphtml.href;
}
}
}

@ -619,5 +619,5 @@
"*://*.wallkit.net/*",
"*://*.wsj.net/*"
],
"version": "2.5.6.5"
"version": "2.5.6.6"
}

@ -1,4 +1,5 @@
var ext_api = chrome || browser;
var ext_api = (typeof browser === 'object') ? browser : chrome;
var url_loc = (typeof browser === 'object') ? 'firefox' : 'chrome';
var manifestData = ext_api.runtime.getManifest();
var versionString = 'v' + manifestData.version;
@ -20,9 +21,9 @@ function show_update(ext_version_new, check = true) {
anchorEl.innerText = 'New release v' + ext_version_new;
if (manifestData.applications && manifestData.applications.gecko.id.includes('magnolia')) {
if (installType === 'development')
anchorEl.href = 'https://gitlab.com/magnolia1234/bypass-paywalls-firefox-clean';
anchorEl.href = 'https://gitlab.com/magnolia1234/bypass-paywalls-' + url_loc + '-clean';
else
anchorEl.href = 'https://gitlab.com/magnolia1234/bypass-paywalls-firefox-clean/-/releases';
anchorEl.href = 'https://gitlab.com/magnolia1234/bypass-paywalls-' + url_loc + '-clean/-/releases';
} else
anchorEl.href = 'https://addons.mozilla.org/en-US/firefox/addon/bypass-paywalls-clean';
anchorEl.target = '_blank';
@ -45,11 +46,10 @@ function show_update(ext_version_new, check = true) {
function check_version_update(ext_version_new, popup) {
if (!popup) {
const proxyurl = "https://bpc-cors-anywhere.herokuapp.com/";
//const manifest_new = 'https://gitlab.com/magnolia1234/bypass-paywalls-firefox-clean/-/raw/master/manifest.json';
const manifest_new = 'https://bitbucket.org/magnolia1234/bypass-paywalls-firefox-clean/raw/master/manifest.json';
//fetch(proxyurl + manifest_new, { headers: { "Content-Type": "application/json", "X-Requested-With": "XMLHttpRequest" } })
fetch(manifest_new)
let manifest_new = 'https://gitlab.com/magnolia1234/bypass-paywalls-' + url_loc + '-clean/raw/master/manifest.json';
//let manifest_new = 'https://bitbucket.org/magnolia1234/bypass-paywalls-firefox-clean/raw/master/manifest.json';
let proxyurl = 'https://bpc2-cors-anywhere.herokuapp.com/';
fetch(proxyurl + manifest_new, {headers: {"Content-Type": "text/plain", "X-Requested-With": "XMLHttpRequest"} })
.then(response => {
if (response.ok) {
response.json().then(json => {

Loading…
Cancel
Save