$ show limbopro/Adblock4limbo
This repository is a comprehensive collection of ad-blocking filter lists, CSS styles, JavaScript scripts, and configuration files for proxy tools (Surge, QuantumultX, Shadowrocket, Clash) and browser extensions (uBlock Origin Lite, Tampermonkey). It targets both international and Chinese websites, with a strong focus on streaming, adult, and content farm sites. The core functionality is delivered through platform-specific rule lists (`.list`, `.conf`, `.sgmodule`, `.yaml`) and a set of userscripts that inject CSS/JS into web pages via MITM proxy or browser script managers. The repository also includes a large set of pre-compiled uBlock Origin Lite scriptlets that implement advanced ad-blocking techniques such as cookie removal, attribute removal, eval blocking, and timer manipulation. The project is community-driven, with issue templates for reporting new ad locations. While primarily a configuration/rule collection, it contains substantial JavaScript code that demonstrates client-side ad-blocking patterns.
The LLM identified 3 files worth highlighting for reuse:
A reusable confirmation dialog implemented as a userscript. It creates a modal overlay with customizable title, message, and buttons, and returns a Promise that resolves to the user's choice. Uses DOM injection and CSS styling, and can be called from any page script. Demonstrates a clean Promise-based async pattern for user interaction.
A userscript that detects video ads on a page and accelerates them to skip quickly. It adds a toggle button (persisted via localStorage) to enable/disable ad skipping. Uses MutationObserver to watch for video elements and applies speed changes. Self-contained and could be adapted for any video ad blocking scenario.
A userscript that automatically removes transparent overlays (e.g., clickjacking shields) from web pages. It uses a MutationObserver to monitor DOM changes and removes elements matching a configurable CSS selector (default: a transparent overlay). The logic is simple but effective, and can be reused for any site that uses overlays to block content.