Visitar URL original
GitHub - onlyless/chrome-div-blocker: Chrome extension to select and hide div areas, with rules saved per site. · GitHub
Skip to content

About

Chrome extension to select and hide div areas, with rules saved per site.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

Div Blocker

English | 简体中文

A lightweight Chrome Manifest V3 extension that lets you select and hide div areas on web pages. Rules are saved locally for each hostname and reapplied when the page loads or new elements appear.

Install

  1. Download chrome-div-blocker-v0.1.0.zip from Releases.
  2. Extract the ZIP into a folder you intend to keep.
  3. Open chrome://extensions in Chrome and enable Developer mode.
  4. Click Load unpacked and select the extracted folder containing manifest.json.
  5. Refresh any web pages that were already open before installation.

You can also clone this repository and load its root folder directly. No build step or dependency installation is required.

Use

  • Open the extension popup and click Select div to hide.
  • Move the pointer over the page to highlight a div, then click to hide it. Press Escape to cancel.
  • Open the popup to see rules for the current hostname. Click Delete to remove a rule and restore matching elements on the current page.

Rules apply across pages on the same hostname. Subdomains have separate rules. Browser-protected pages cannot be controlled. Rules use CSS selectors, so a site's layout changes may require selecting the area again. Selection operates in the top-level page, not inside embedded frames.

Privacy and permissions

Rules, including selectors and a short text label from the selected element, are stored in chrome.storage.local. The extension contains no analytics or external network requests.

  • activeTab: access the current tab when using the popup.
  • storage: save hiding rules locally.
  • Content scripts run on supported URLs to apply saved rules and handle selection.

Development

The extension uses plain JavaScript, HTML, and CSS. To regenerate the included icons, run node generate-icons.js with Node.js. After editing the extension, reload it on chrome://extensions and refresh the web page.

About

Chrome extension to select and hide div areas, with rules saved per site.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages