mirror of
https://github.com/iamadamdev/bypass-paywalls-chrome
synced 2025-04-30 01:34:26 +02:00
Fix medium.com
This commit is contained in:
parent
c5d321b13c
commit
586e48d65b
@ -218,10 +218,18 @@ if (matchDomain('elmercurio.com')) {
|
|||||||
const articlesLeftModal = document.getElementsByClassName('paywall-meter-module__story-paywall-container__1UgCE')[0];
|
const articlesLeftModal = document.getElementsByClassName('paywall-meter-module__story-paywall-container__1UgCE')[0];
|
||||||
const paywall = document.getElementById('paywallDmp');
|
const paywall = document.getElementById('paywallDmp');
|
||||||
removeDOMElement(articlesLeftModal, paywall);
|
removeDOMElement(articlesLeftModal, paywall);
|
||||||
} else if (matchDomain('medium.com')) {
|
} else if (matchDomain('medium.com') || document.querySelector('script[src^="https://cdn-client.medium.com/"]')) {
|
||||||
const bottomMessageText = 'Get one more story in your member preview when you sign up. It’s free.';
|
const paywall = document.querySelector('div#paywall-background-color');
|
||||||
const DOMElementsToTextDiv = pageContains('div', bottomMessageText);
|
removeDOMElement(paywall);
|
||||||
if (DOMElementsToTextDiv[2]) removeDOMElement(DOMElementsToTextDiv[2]);
|
if (paywall) {
|
||||||
|
extensionApi.runtime.sendMessage({ request: 'refreshCurrentTab' });
|
||||||
|
}
|
||||||
|
window.setTimeout(function () {
|
||||||
|
const meter = document.querySelector('[id*="highlight-meter-"]');
|
||||||
|
if (meter) {
|
||||||
|
meter.hidden = true;
|
||||||
|
}
|
||||||
|
}, 500); // Delay (in milliseconds)
|
||||||
} else if (matchDomain('theglobeandmail.com')) {
|
} else if (matchDomain('theglobeandmail.com')) {
|
||||||
document.addEventListener('DOMContentLoaded', () => {
|
document.addEventListener('DOMContentLoaded', () => {
|
||||||
const realArticle = document.querySelector('.js-c-article-body');
|
const realArticle = document.querySelector('.js-c-article-body');
|
||||||
|
Loading…
x
Reference in New Issue
Block a user