Fix latimes.com

This commit is contained in:
Adam 2023-10-15 13:57:55 -07:00
parent badfe3685a
commit a93a4beb34
2 changed files with 3 additions and 11 deletions

View File

@ -226,7 +226,7 @@ const blockedRegexes = {
'dailytelegraph.com.au': /cdn\.ampproject\.org\/v\d\/amp-(access|ad|consent)-.+\.js/, 'dailytelegraph.com.au': /cdn\.ampproject\.org\/v\d\/amp-(access|ad|consent)-.+\.js/,
'theglobeandmail.com': /(\.theglobeandmail\.com\/pf\/dist\/engine\/react\.js|smartwall\.theglobeandmail\.com\/)/, 'theglobeandmail.com': /(\.theglobeandmail\.com\/pf\/dist\/engine\/react\.js|smartwall\.theglobeandmail\.com\/)/,
'nytimes.com': /(\.nytimes\.com\/meter\.js|mwcm\.nyt\.com\/.+\.js|cooking\.nytimes\.com\/api\/.+\/access)/, 'nytimes.com': /(\.nytimes\.com\/meter\.js|mwcm\.nyt\.com\/.+\.js|cooking\.nytimes\.com\/api\/.+\/access)/,
'latimes.com': /(metering\.platform\.latimes\.com\/|cdn\.ampproject\.org\/v\d\/amp-(access|subscriptions)-.+\.js)/, 'latimes.com': /\.californiatimes\.com\/meteringjs/,
'theathletic.com': /cdn\.ampproject\.org\/v\d\/amp-(access|subscriptions)-.+\.js/, 'theathletic.com': /cdn\.ampproject\.org\/v\d\/amp-(access|subscriptions)-.+\.js/,
'japantimes.co.jp': /cdn\.cxense\.com\//, 'japantimes.co.jp': /cdn\.cxense\.com\//,
'scmp.com': /(\.tinypass\.com\/|cdn\.ampproject\.org\/v\d\/amp-access-.+\.js)/, 'scmp.com': /(\.tinypass\.com\/|cdn\.ampproject\.org\/v\d\/amp-access-.+\.js)/,

View File

@ -641,16 +641,8 @@ if (matchDomain('elmercurio.com')) {
body.removeAttribute('class'); body.removeAttribute('class');
} }
} else if (matchDomain('latimes.com')) { } else if (matchDomain('latimes.com')) {
const paywall = document.querySelector('metering-modal'); const ads = document.querySelectorAll('div.enhancement, div.google-dfp-ad-wrapper');
const incognitoWall = document.querySelector('metering-toppanel'); hideDOMElement(...ads);
if (paywall) {
removeDOMElement(paywall);
} else if (incognitoWall) {
removeDOMElement(incognitoWall);
}
if (paywall || incognitoWall) {
document.body.removeAttribute('style');
}
} else if (matchDomain('foreignpolicy.com')) { } else if (matchDomain('foreignpolicy.com')) {
const contentUngated = document.querySelector('div.content-ungated'); const contentUngated = document.querySelector('div.content-ungated');
removeDOMElement(contentUngated); removeDOMElement(contentUngated);