From f470e4d5cf29c0c481a0a3837df3fe28d54809e8 Mon Sep 17 00:00:00 2001 From: arg0WAK Date: Thu, 23 Apr 2026 16:06:46 +0300 Subject: [PATCH] Add TheVerge paywall remover user script --- LICENSE | 21 +++++++++ README.md | 58 ++++++++++++++++++++++++ script/theverge-paywall-remover.user.js | 60 +++++++++++++++++++++++++ 3 files changed, 139 insertions(+) create mode 100644 LICENSE create mode 100644 README.md create mode 100644 script/theverge-paywall-remover.user.js diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..b02f37f --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2026 Barış + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..740726c --- /dev/null +++ b/README.md @@ -0,0 +1,58 @@ +# TheVerge Unlimited Reading (Paywall Remover) + +![Tampermonkey](https://img.shields.io/badge/userscript-tampermonkey-blue) +![Platform](https://img.shields.io/badge/platform-web-green) +![Status](https://img.shields.io/badge/status-active-success) +![License](https://img.shields.io/badge/license-MIT-lightgrey) + +A lightweight userscript that removes intrusive overlays on The Verge and restores a clean, distraction-free reading experience. + +--- + +## Installation + +Click below to install directly in Tampermonkey: + +[![Install](https://img.shields.io/badge/Install-Tampermonkey-blue?style=for-the-badge&logo=javascript)](https://raw.githubusercontent.com/arg0WAK/theverge-paywall-remover/main/script/theverge-paywall-remover.user.js) + +--- + +## How it works + +This script uses two layered approaches: + +### DOM observer (fallback) +Detects dynamically injected overlays and removes them automatically. + +--- + +## Release Notes + +### v1.0.0 +- Initial release +- Overlay removal system +- Scroll restoration fix +- Dynamic DOM handling support + +--- + +## Keywords + +```txt +theverge clean view +theverge reading mode +remove overlay theverge +zephr overlay remover +article clean mode +scroll unlock page +website readability enhancer +userscript reading fix +tampermonkey verge script +``` + +--- + +## Disclaimer + +This project is intended for educational and UI experimentation purposes. +Websites may change structure at any time. diff --git a/script/theverge-paywall-remover.user.js b/script/theverge-paywall-remover.user.js new file mode 100644 index 0000000..141d524 --- /dev/null +++ b/script/theverge-paywall-remover.user.js @@ -0,0 +1,60 @@ +// ==UserScript== +// @name TheVerge Unlimited Reading +// @namespace https://github.com/arg0WAK +// @version 2026-04-23 +// @description Kills paywall overlays and gives you your scroll back on The Verge. +// @author github.com/arg0WAK +// @match https://www.theverge.com/* +// @icon https://www.google.com/s2/favicons?sz=64&domain=theverge.com +// @grant none +// ==/UserScript== + +const forbiddenSelectors = [ + '.zephr-zone-footer', + '.zephr-footer-container', + '.zephr-overlay', + '#zephr-zone-footer', + '#zephr-footer-container', + '#zephr-overlay' +]; + +const isRoot = el => + el === document.body || el === document.documentElement; + +const fixStyles = el => { + if (!isRoot(el)) return; + + const s = getComputedStyle(el); + + if (s.overflow === 'hidden') { + el.style.setProperty('overflow', 'unset', 'important'); + } + + if (s.position === 'fixed') { + el.style.cssText += ` + position:unset !important; + padding:0 !important; + top:unset !important; + `; + } +}; + +const clean = () => + forbiddenSelectors.forEach(sel => + document.querySelectorAll(sel).forEach(el => el.remove()) + ); + +new MutationObserver(muts => { + muts.forEach(m => { + if (m.type === 'attributes') fixStyles(m.target); + if (m.type === 'childList') clean(); + }); +}).observe(document, { + subtree: true, + childList: true, + attributes: true, + attributeFilter: ['style'] +}); + +[document.body, document.documentElement].forEach(fixStyles); +clean();