1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-11-06 19:02:30 +01:00
Commit Graph

15 Commits

Author SHA1 Message Date
Raymond Hill
417dab538c
[mv3] Fix generating allowAllRequests rule when default mode is no-filtering 2024-08-04 11:59:16 -04:00
Raymond Hill
9562b19a93
Fall back to "Basic" when removing all-urls from "No filtering"
Related discussion:
https://github.com/uBlockOrigin/uBOL-home/issues/156#issuecomment-2254576670
2024-08-01 11:24:42 -04:00
Raymond Hill
0e8ff10e92
[mv3] Mind service workers for sites in "no filtering" mode
Related issue:
https://github.com/uBlockOrigin/uBOL-home/issues/114
2024-01-31 09:59:45 -05:00
Raymond Hill
a969a672e0
Change official description in source code top comment 2023-12-04 12:10:34 -05:00
Raymond Hill
a77c23c74f
[mv3] Improve and cleanup options page
Additionally, ensure the options page stay in sync with the
internal state of the extension.
2023-11-29 16:11:22 -05:00
Raymond Hill
d7acad6c90
[mv3] Add textarea to list/edit trusted sites
Related issue:
https://github.com/uBlockOrigin/uBOL-home/issues/29
2023-11-28 21:13:44 -05:00
Raymond Hill
d19e62a595
[mv3] Add support for admin configurations
See `managed_storage.json` for available settings. Currently
only `noFiltering` setting is availale.

`noFiltering` is an array of strings, each being a domain for
which no filtering should occur.

Related discussion:
- https://github.com/uBlockOrigin/uBOL-issues/discussions/35
2023-06-13 11:40:41 -04:00
Raymond Hill
1ad7410077
[mv3] Fine tune various portions of code 2023-06-06 13:42:22 -04:00
Raymond Hill
6d9bef28ff
[mv3] Fix issue with updateContentScripts API and other fixes
Avoid using updateContentScripts() as it suffers from an unexpected
behavior, causing injected content scripts to lose proper order
at injection time. The order in which content scripts are injected
is key for uBOL content scripts. Potential out of order injection
was causing cosmetic filtering to be broken.

Use actual storage API to persist data across service worker
wake-ups and browser launches. uBOL was trying to avoid using
storage API, at the cost of somewhat hacky code (using DNR API
to persist settings).

Make use of session storage if available, to speed up
initialization of waking up the service worker (which at this
point is necessary to properly implement cosmetic filtering).
2023-06-05 09:15:59 -04:00
Raymond Hill
56f67631d6
Fix regression in handling mode changes 2023-05-20 17:21:14 -04:00
Raymond Hill
13a4f869d2
Fix sticky blocking mode
Related issue:
- https://github.com/uBlockOrigin/uBOL-issues/issues/42

Take into account that subdomains inherit the blocking mode
of their parent domain when toggling blocking mode of specific
hostnames.
2023-05-19 15:08:23 -04:00
Raymond Hill
8616b395b2
Internally support no-filtering as default mode
Even though this cannot be set through the user interface.
2023-04-21 19:24:43 -04:00
Raymond Hill
433adac6ff
[mv3] Add ability to handle entity-based CSS and scriptlet injection filters
This commit adds the ability to inject entity-based plain CSS
filters and also a set of the most commonly used entity-based
scriptlet injection filters.

Since the scripting API is not compatible with entity patterns,
the entity-related content scripts are injected in all documents
and the entity-matching is done by the content script themselves.

Given this, entity-based content scripts are enabled only when
working in the Complete filtering mode, there won't be any
entity-based filters injected in lower modes.

Also, since there is no way to reasonably have access to the
Public Suffix List in the content scripts, the entity-matching
algorithm is an approximation, though I expect false positives
to be rare (time will tell). In the event of such false
positive, simply falling back to Optimal mode will fix the
issue.

The following issues have been fixed at the same time:

Fixed the no-filtering mode related rules having lower priority
then redirect rules, i.e. redirect rules would still be applied
despite disabling all filtering on a site.

Fixed improper detection of changes to the generic-related CSS
content script, potentially causing undue delays when for example
trying to access the popup panel while working in Complete mode.
The scripting MV3 can be quite slow when registering/updating
large content scripts, so uBOL does its best to call the API only
if really needed, but there had been a regression in the recent
builds preventing uBO from properly detecting unchanged content
script parameters.
2022-10-20 15:48:06 -04:00
Raymond Hill
b4c63f6ae5
[mv3] Handle permissions being revoked while uBOL is disabled 2022-10-18 08:48:31 -04:00
Raymond Hill
8eb28a446c
[mv3] Introduce per-site filtering modes in lieu of per-site toggle switch 2022-10-10 12:28:24 -04:00