@description
Conditionally prevent assignment to `innerHTML` property.
@param [selector]
Optional. The element must matches `selector` for the prevention to take
place.
@param [pattern]
Optional. A pattern to match against the assigned value. The pattern can be
a plain string, or a regex. Prepend with `!` to reverse the match condition.
As discussed with filter list volunteers.
`generichide` option is implicitly enforced on all sites unless an
exception overrides `generichide`. Though rare, sometimes a
`generichide` exception needs to be overridden so that generic
cosmetic filtering is made possible on a specific site.
This commit is to add support for restoring generic cosmetic
filtering on sites which were excluded through a `generichide`
exception.
Concretely, this is needed to ensure the test suite can properly
verify that generic cosmetic filtering is working when the
filtering mode is set to "complete":
||ublockorigin.github.io^$generichide,important
Related issue:
https://github.com/uBlockOrigin/uBlock-issues/issues/3576
This is the first step, a trivial code change which disable the
injection of `Cache-Control` header in Firefox.
In the next dev cycle, the second step will be to remove all
the code related to `Cache-Control` injection.
New syntax for scriptlet-based filtering: it is now possible to
inject a scriptlet in a context according to whether an ancestor
origin matches a specific hostname. Example:
example.com>>##+js(set, iAmEmbeddedInExampleDotCom, true)
The new `>>` specifier means that the scriptlet will not be injected
in `example.com`, but will be injected in all direct and indirect
embedded contexts in pages loaded from `example.com`
The new ancestor domain specifier also works for entity directives:
example.*##+js(set, iAmEmbeddedInExampleDotEffectiveTLD, true)
This is an experimental feature, to be further evaluated and
discussed by filter list maintainers. This is not a complete
implementation, by choice. Do not open issues regarding this
new syntax, the current shortcomings are known.
The new syntax is being discussed internally at:
https://github.com/uBlockOrigin/uBlock-discussions/discussions/244
This extends coverage of strict-blocking to pattern-based filters
with `doc` filter option.
When proceeding with a URL-skip URL present, no temporary bypass
will be created when the "Don't warn me again about this site" is
left unchecked. The idea is to avoid the intermediate redirects
if we navigate again on the same strict-blocked site, while a
temporary bypass would prevent this.
uBO's "Badware risks" list has been spinned off as its own list.
The idea is that should a site be strict-blocked from that list,
we would want to know the strict-block is due to the
"Badware risks" list.
Deserialization failed to restore proper ArrayBuffer when used by
multiple TypedArrays.
This didn't affect uBO since this specific code path was never
taken.