Código 1
Código 1
(function() {
'use strict';
const exerciseContainer =
document.querySelector('div[class^="BookEditionPage__Container"]');
if (exerciseContainer) observerPaywall.observe(exerciseContainer,
observerPaywallConfig);
document.querySelectorAll('.paywall').forEach(el => {
el.classList.replace('paywall', 'autoHeight');
});
const paywallElements =
document.querySelectorAll('[class*="ExpandPaywallContainer"]');
paywallElements.forEach(el => {
el.remove();
});
const paywallOverlays =
document.querySelectorAll('[class*="PaywallOverlayContainer"]');
paywallOverlays.forEach(el => {
el.parentNode.style.height = 'auto !important';
el.remove();
});
const paywallHeadings =
document.querySelectorAll('[class*="PaywallHeadingsSection"]');
paywallHeadings.forEach(el => {
el.remove();
});
}
window.removePaywall = removePaywall;
const observerStyleConfig = {
attributes: true,
attributeOldValue: true,
}
const observerPaywallConfig = {
...observerStyleConfig,
childList: true,
}
window.onload = () => {
removePaywall();
}