1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-09-29 22:27:12 +02:00
Commit Graph

2281 Commits

Author SHA1 Message Date
Raymond Hill
b1c55b3de9
Emphasize entity portion of hostnames in _"My rules"_ 2020-11-19 11:33:09 -05:00
Raymond Hill
38cecddcd1
Improve zapper's detection of scroll-locked documents 2020-11-18 14:11:36 -05:00
Raymond Hill
ee2fd45f00
Ensure we do not extract truncated URL for Homepage directive
Related feedback:
- b12e0e05ea (commitcomment-44309540)
2020-11-18 12:14:23 -05:00
Raymond Hill
b12e0e05ea
Extract Homepage URL from a list when present
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1346

Additionally, fixed a case of filter list being compiled
twice at subscription time.
2020-11-18 10:02:22 -05:00
Raymond Hill
d87a3b950f
Sort on base domains rather than TLDs in "My rules" pane
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1293
2020-11-18 08:01:00 -05:00
Raymond Hill
a683297931
Fix type assignment in logger page
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1349
2020-11-17 11:18:59 -05:00
Raymond Hill
e360e90d1e
Fix invalid support URL in document-blocked page
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1345
2020-11-15 10:19:09 -05:00
Raymond Hill
46d7f8a70c
Fine tune click-to-load widget
Notably, add clickable link to open the widget
in its own tab. Also, allows the URL to be text-
selected so that it becomes possible to use the
selection in a browser contextual menu's "Open
in a new tab" option.
2020-11-14 08:34:47 -05:00
Raymond Hill
5cf9bcf27c
Fine tune code of optimizeOriginHitTests()
Related commit:
- b265f2644d
2020-11-14 07:28:51 -05:00
Raymond Hill
4afb3dc149
Allow domain= with entity values into pre-test buckets
Related commit:
- b265f2644d

Filters which have `domain=` option with an entity
value will no longer be prevented from joining
pre-test buckets.
2020-11-14 07:04:21 -05:00
Raymond Hill
56cd238ad4
Disable auto activation of dark theme in next release
Until a fully usable dark theme is available. uBO's
incomplete dark theme can still be forced by setting
advanced setting `uiTheme` to `dark`.
2020-11-13 12:15:29 -05:00
Raymond Hill
eb8433cb19
Enable cloud storage compression by default in next release
Related commit:
- d8b6b31eca
2020-11-13 12:14:06 -05:00
Raymond Hill
2cfeaddbed
Fine tune various static filtering code
Notably, make `queryprune` option available only
to filter list authors, until there are guards
against bad filters in some future and until the
option syntax and behavior is fully settled.

Instances of `queryprune` in filter lists will be
compiled, however instances of `queryprune` in
_"My filters"_ will be ignored unless users
indicated they are a filter list author.
2020-11-13 09:23:25 -05:00
Raymond Hill
525d7b1b3b
Fine tune port connection code
Related commit:
- a223031b98
2020-11-13 08:32:51 -05:00
Raymond Hill
02b4d149e3
Do not skip querypruning when no-strict-blocking is true
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1341
2020-11-13 08:30:43 -05:00
Raymond Hill
a223031b98
Work around Firefox's data: favIconUrl leak
Related issue:
- https://bugzilla.mozilla.org/show_bug.cgi?id=1652925
2020-11-12 12:14:59 -05:00
Raymond Hill
280dd8ddd6
Fix picker use of extraneous body in suggested filter
Related feedback:
- https://www.reddit.com/r/uBlockOrigin/comments/jregqx/
2020-11-11 09:39:07 -05:00
Raymond Hill
cfb050f521
Detect bad queryprune values
`queryprune=` values are used as literal regex
value after converting leading/trailing `|` into
`^`/`$`.
2020-11-11 08:15:39 -05:00
Raymond Hill
8cc3779fb3
Last commit changes compiled format 2020-11-11 08:15:27 -05:00
Raymond Hill
0e851c035e
Revisit realm & action bits
The important bit is now considered an action bit
so that there is no more a need for the `important`
property in the parser. The modify bit is now
considered a realm bit.

When the modify bit is set, the action bits become
available to be used to further narrow the realm.
This could be useful in the future if we want to
spread the population of modifier filters across
different buckets.
2020-11-11 07:53:46 -05:00
Raymond Hill
32eca67154
Reuse one instance of domain option iterator
Reusing the same iterator instance for all cases
of `domain=` option parsing should reduce memory
churning.

Additonally, fine tune regex used to extract
valid token from regex-based filters to increase
likelihood of being able to extract a valid
token.
2020-11-10 12:49:46 -05:00
Raymond Hill
8985376b00
Fix timing issue with cached redirection to web accessible resources
Reported internally by @gwarser.

In rare occasion, a timing issue could cause uBO to redirect
to a web accessible resource meant to be used for another
network request. This is a regression introduced with the
following commit:

- 2e5d32e967

Additionally, I identified another issue which would cause
cached redirection to fail when a cache entry with redirection
to a web accessible resource was being reused, an issue which
could especially affect pages which are generated dynamically
(i.e. without full page reload).
2020-11-10 10:43:26 -05:00
Raymond Hill
76ef4811a3
Fix queryprune for tabless requests
Related feedback:
- https://github.com/uBlockOrigin/uBlock-issues/issues/760#issuecomment-724693549
2020-11-10 08:58:39 -05:00
Raymond Hill
0196993828
Use buffer-like approach for filterUnits array
filterUnits is now treated as a buffer which is
pre-allocated and which will grow in chunks so as
to minimize memory allocations. Entries are never
released, just null-ed.

Additionally, move urlTokenizer into the static
network filtering engine, since it's not used
anywhere else.
2020-11-09 06:54:51 -05:00
Raymond Hill
db4f02199d
Convert filterSequences into a const variable
Making filterSequences constant allows to no longer
mind how the array is accessed in loops.
2020-11-08 16:00:24 -05:00
Raymond Hill
50da6706a4
Code review of static network filtering engine
- Convert this.categories Map() into an array;

- Fix case of potentially using an invalid UintArray32
  (regression from latest changes)
2020-11-08 13:50:36 -05:00
Raymond Hill
96bfe3c9a7
Convert filterUnits into a const variable
Making filterUnits constant allows to no longer
mind how the array is accessed in loops.
2020-11-08 10:30:47 -05:00
Raymond Hill
cb91d167d1
Fine tune static network filtering engine code
Notably, defer the post-load optimization operations
to a few seconds after the filters have been all
loaded in memory -- this is not a critical step for
the filtering engine to work properly, hence this
can be delayed in order to ensure readiness as soon
as possible.
2020-11-07 13:25:01 -05:00
Raymond Hill
efea83a825
Incrementally improve static filtering parser
Most notably, the `denyallow=` option now requires
the presence of a valid `domain=` option to not be
rejected.

Using `denyallow=` without narrowing down using the
`domain=` option leads to catastrophic blocking
behvior, hence the requirement for a valid `domain=`
option.
2020-11-07 13:20:02 -05:00
Raymond Hill
1d679143d2
Enable origin-hit coalescing optimisation for modifier filters
Related commit:
- b265f2644d

The optimization in the commit above was meant to
improve the performance of lookup operations of
modifier filters, but I forgot to enable the
optimisation for that class of filters.

This means this commit brings another significant
performance gain on top of the previous commit, as
shown by the built-in benchmark.

Additionally a few minor code rearrangements.
2020-11-06 18:24:46 -05:00
Raymond Hill
b265f2644d
Coallesce origin hit filters into their own bucket
Performance-related work.

There is a fair number of filters which can't be tokenized
in uBO's own filter lists. Majority of those filters also
declare a `domain=` option, examples:

    *$script,redirect-rule=noopjs,domain=...
    *$script,3p,domain=...,denyallow=...
    *$frame,3p,domain=...

Such filters can be found in uBO's asset viewer using the
following search expression:

    /^\*?\$[^\n]*?domain=/

Some filter buckets will contain many of those filters, for
instance one of the bucket holding untokenizable `redirect=`
filters has over 170 entries, which must be all visited when
collating all matching `redirect=` filters.

When a bucket contains many such filters, I found that it's
worth to extract all the non-negated hostname values from
`domain=` options into a single hntrie and perform a pre-test
at match() time to find out whether the current origin of a
network request matches any one of the collected hostnames,
so as to avoid iterating through all the filters.

Since there is rarely a match() for vast majority of network
requests with `domain=` option, this pre-test saves a good
amount of work, and this is measurable with the built-in
benchmark.
2020-11-06 12:04:03 -05:00
Raymond Hill
19331f1ab5
Fine tune latest changes for performance
Related commits:
- 157cef6034
- 1e2eb037e5
2020-11-04 07:50:51 -05:00
Raymond Hill
157cef6034
Re-classify redirect= option as a modifier option
This commit moves the parsing, compiling and enforcement
of the `redirect=` and `redirect-rule=` network filter
options into the static network filtering engine as
modifier options -- just like `csp=` and `queryprune=`.

This solves the two following issues:

- https://github.com/gorhill/uBlock/issues/3590
- https://github.com/uBlockOrigin/uBlock-issues/issues/1008#issuecomment-716164214

Additionally, `redirect=` option is not longer afflicted
by static network filtering syntax quirks, `redirect=`
filters can be used with any other static filtering
modifier options, can be excepted using `@@` and can be
badfilter-ed.

Since more than one `redirect=` directives could be found
to apply to a single network request, the concept of
redirect priority is introduced.

By default, `redirect=` directives have an implicit
priority of 0. Filter authors can declare an explicit
priority by appending `:[integer]` to the token of the
`redirect=` option, for example:

    ||example.com/*.js$1p,script,redirect=noopjs:100

The priority dictates which redirect token out of many
will be ultimately used. Cases of multiple `redirect=`
directives applying to a single blocked network request
are expected to be rather unlikely.

Explicit redirect priority should be used if and only if
there is a case of redirect ambiguity to solve.
2020-11-03 09:15:26 -05:00
Raymond Hill
9c43a48445
URLSearchParams() can't be iterated as a Map()
Related feedback:
- https://github.com/uBlockOrigin/uBlock-issues/issues/760#issuecomment-720434320
2020-11-02 07:41:21 -05:00
Raymond Hill
d536c7ab11
Use const when value does not change 2020-11-02 04:57:42 -05:00
Raymond Hill
5468b92643
Built-in redirect token none must be seen as valid
Related feedback:
- 1727585faa (commitcomment-43787843)
2020-11-02 04:52:47 -05:00
Raymond Hill
f76471f56b
Fix bad pruning logic
Related feedback:
- https://github.com/uBlockOrigin/uBlock-issues/issues/760#issuecomment-720140135
2020-11-02 04:51:40 -05:00
Raymond Hill
c75b27c052
Fix top document partyness
Reported internally.

Regression from:
- 1e2eb037e5

Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/760
2020-11-01 06:25:26 -05:00
Raymond Hill
64dc5f7807
Fix wrongly reported network filter options in logger
Regression from:
- 1e2eb037e5

Related feedback:
- 1e2eb037e5 (commitcomment-43759481)
2020-10-31 13:47:35 -04:00
Raymond Hill
1e2eb037e5
Add new filter option queryprune=
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/760

The purpose of this new network filter option is to remove
query parameters form the URL of network requests.

The name `queryprune` has been picked over `querystrip`
since the purpose of the option is to remove some
parameters from the URL rather than all parameters.

`queryprune` is a modifier option (like `csp`) in that it
does not cause a network request to be blocked but rather
modified before being emitted.

`queryprune` must be assigned a value, which value will
determine which parameters from a query string will be
removed. The syntax for the value is that of regular
expression *except* for the following rules:

- do not wrap the regex directive between `/`
- do not use regex special values `^` and `$`
- do not use literal comma character in the value,
  though you can use hex-encoded version, `\x2c`
- to match the start of a query parameter, prepend `|`
- to match the end of a query parameter, append `|`

`queryprune` regex-like values will be tested against each
key-value parameter pair as `[key]=[value]` string. This
way you can prune according to either the key, the value,
or both.

This commit introduces the concept of modifier filter
options, which as of now are:

- `csp=`
- `queryprune=`

They both work in similar way when used with `important`
option or when used in exception filters. Modifier
options can apply to any network requests, hence the
logger reports the type of the network requests, and no
longer use the modifier as the type, i.e. `csp` filters
are no longer reported as requests of type `csp`.

Though modifier options can apply to any network requests,
for the time being the `csp=` modifier option still apply
only to top or embedded (frame) documents, just as before.
In some future we may want to apply `csp=` directives to
network requests of type script, to control the behavior
of service workers for example.

A new built-in filter expression has been added to the
logger: "modified", which allow to see all the network
requests which were modified before being emitted. The
translation work for this new option will be available
in a future commit.
2020-10-31 10:42:53 -04:00
Raymond Hill
ba2ef925e9
Fix incorrect reset value
This could cause spurious error messages in dev console of
content page.
2020-10-31 10:18:42 -04:00
Raymond Hill
2b88c8b545
Fix incorrect count in built-in benchmark 2020-10-29 06:01:04 -04:00
Raymond Hill
a1aa9bd54f
Disable button until benchmark session is completed 2020-10-27 13:07:05 -04:00
Raymond Hill
4059a92838
Fine tune built-in benchmark
Additionally, add a button in the About pane
to launch benchmark sessions. The button will
be available only when advanced setting
`benchmarkDatasetURL` is set and pointing to
a valid dataset.
2020-10-27 12:59:31 -04:00
Raymond Hill
0bbf5b52ab
Improve token extraction from regex-based filters 2020-10-25 13:06:26 -04:00
Raymond Hill
ed2ad57dca
Ensure no-large-element styling is removed 2020-10-25 08:05:26 -04:00
Raymond Hill
a1a008098c
More fine tuning of no-large-media-elements content script
Related issue:
- https://github.com/gorhill/uBlock/issues/1390
2020-10-23 07:29:14 -04:00
Raymond Hill
2b5a853d8c
Fix regex to validate URL of imported lists
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1306
2020-10-23 06:25:08 -04:00
Raymond Hill
37b195f61d
Remove all event handlers from no-large-media-elements content scripts
Related issue:
- https://github.com/gorhill/uBlock/issues/1390
2020-10-22 09:01:59 -04:00
Raymond Hill
0628d2ec9f
Improve interactivity of no-large-media-elements content scripts
Related issue:
- https://github.com/gorhill/uBlock/issues/1390#issuecomment-713174183
2020-10-22 08:44:55 -04:00
Raymond Hill
b75758808e
Ensure the bottom of dashboard panes is visible
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1304

On small displays, not being able to scroll down
could become a usability issue.
2020-10-21 12:50:24 -04:00
Raymond Hill
ee059540f7
Cache element picker's optimized candidates for reuse
Optimized candidates computed for each depth are now
cached for reuse. This reduces the amount of work
done when moving the depth slider.
2020-10-20 05:37:07 -04:00
Raymond Hill
3ef41e1d78
Exclude cached resources from large-media-element blocking
Related feedback:
- https://github.com/gorhill/uBlock/issues/1390#issuecomment-187310719
2020-10-19 08:01:03 -04:00
Raymond Hill
927d55134d
Remove discarding of assumed unoptimal selectors
This was a bad idea.

Related commit:
- 4c5197322f
2020-10-18 11:06:40 -04:00
Raymond Hill
53dd339d78
Improve interactivity for blocked large media elements
Related issues:
- https://github.com/gorhill/uBlock/issues/1390
- https://github.com/gorhill/uBlock/issues/2334

The deadline to interactively load a specific media
element has been extended from 2sec to 5sec.

Clicking over a blocked large media element will cause
uBO to lookup and handle all potentially blocked large
elements at the cursor position. This should take care
of being able to unblock media elements hidden under
other DOM object.

The CSS style applied to blocked large media elements
has been fine tuned to improve interactivity.

uBO will now remember the specific media elements which
were unblocked and keep them exempted from being
further blocked. This would be an issue when unblocking
a video and then a bit later seeking to another point
in the video, in which case uBO would again block
network requests for that video.
2020-10-18 10:07:46 -04:00
Raymond Hill
9947fcf4d5
Improve layout of popup panel when rendered in a tab
This brings back the ability to screenshot the whole
list of domains when the popup panel is opened in a
tab.
2020-10-18 10:00:55 -04:00
Raymond Hill
6a10319f21
Fix broken advanced property uiStyles
Related commit:
- e3a6d8465f
2020-10-17 12:05:03 -04:00
Raymond Hill
32b08dc732
Mind whitespaces when double-clicking to select filter option value 2020-10-16 17:13:55 -04:00
Raymond Hill
4c5197322f
Improve specificity slider in element picker
The specificity slider will now be more intuitive
by ordering candidates by match count from highest
match count to the left to the lowest match count
to the right.

Candidates with same match counts will be discarded
and replaced with the shortest candidate.
2020-10-16 17:12:22 -04:00
Raymond Hill
38e1bbbe68
Better word selection for static network filters
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1134

Double-clicking on...

... a filter option will cause the option to be
wholly selected, including `=[value]` if present;

... a value assigned to a filter option will cause
the value to be wholly selected, except when the
value is a hostname/entity, in which case all the
labels from the cursor position to the right-most
label will be selected.
2020-10-16 10:06:00 -04:00
Raymond Hill
a095b83250
Use a CodeMirror editor instance in element picker
This allows to bring in all the benefits of
syntax highlighting and enhanced editing
features in the element picker, like auto-
completion, etc.

This is also a necessary step to possibly solve
the following issue:

- https://github.com/gorhill/uBlock/issues/2035

Additionally, incrementally improved the behavior
of uBO's custom CodeMirror static filtering syntax
mode when double-clicking somewhere in a static
extended filter:

- on a class/id string will cause the whole
  class/id string to be   selected, including the
  prepending `.`/`#`.

- somewhere in a hostname/entity will cause all
  the labels from the cursor position to the
  right-most label to be selected (subject to
  change/fine-tune as per feedback of filter
  list maintainers).

Related feedback:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1134#issuecomment-679421316
2020-10-14 10:21:30 -04:00
Raymond Hill
3da97673d9
Remove more remnants of obsolete pseudo user styles code
Related commit:
- 5c68867b92
2020-10-13 07:19:06 -04:00
Raymond Hill
6e010ecc0f
Prevent set-constant properties from being overtaken
Related feedback:
- https://github.com/uBlockOrigin/uBlock-issues/issues/156#issuecomment-707095193

Additionally, while investigating the issue I removed
code which is no longer needed since content scripts
are now injected in `about:blank` frames since 1.29.0.
2020-10-12 10:08:51 -04:00
Raymond Hill
1727585faa
Hightlight to warn about unknown redirect tokens
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1134
2020-10-11 08:59:44 -04:00
Raymond Hill
6ff72af4aa
Only URLs in comments can be selected through double-click 2020-10-11 07:45:58 -04:00
Raymond Hill
2e5d32e967
Fine tune code related to click-to-load feature
The redirectable resource has been renamed
`click2load.html`, so as to avoid uses of dash
characters and to also allow for future different
click-to-load resources.
2020-10-10 08:36:30 -04:00
Raymond Hill
5916920985
Add support for click-to-load of embedded frames
Additionally, as a requirement to support click-to-load
feature, redirected resources will from now on no
longer be collapsed.

Related issues:
- https://github.com/gorhill/uBlock/issues/2688
- https://github.com/gorhill/uBlock/issues/3619
- https://github.com/gorhill/uBlock/issues/1899

This new feature should considered in its draft
stage and it needs to be fine-tuned as per
feedback.

Important: Only embedded frames can be converted
into click-to-load widgets, as only these can be
properly shieded from access by page content.

Examples of usage:

    ||youtube.com/embed/$3p,frame,redirect=clicktoload
    ||scribd.com/embeds/$3p,frame,redirect=clicktoload
    ||player.vimeo.com/video/$3p,frame,redirect=clicktoload
2020-10-09 13:50:54 -04:00
Raymond Hill
c3f267db8f
Improve bad filter detection in element picker
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1280
2020-10-08 09:49:35 -04:00
Raymond Hill
4f00c08f6b
Fix detection of already present comment
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1281

Related feedback:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1281#issuecomment-705081202
2020-10-07 14:23:57 -04:00
Raymond Hill
46ec969411
Add ability to use full URL in auto-generated comment
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1281

New supported placeholder: `{{url}}`, which will be
replaced by the full URL of the page for which a filter
is created.
2020-10-07 11:52:38 -04:00
Raymond Hill
04b11b4311
Fix restore backup feature
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1282
2020-10-06 21:02:51 -04:00
Raymond Hill
778338fce8
Fix picker generating overly long candidate cosmetic filters
Related feedback:
- https://www.reddit.com/r/uBlockOrigin/comments/j5tx8x/understand_the_element_blocker_and_feedback/g7wf2q9/

Regression from:
- https://github.com/gorhill/uBlock/commit/9eb455ab5eb2
2020-10-06 17:26:28 -04:00
Raymond Hill
57048d57b2
Reject improper use of procedural operator in selector list
Related feedback:
- https://github.com/uBlockOrigin/uBlock-issues/issues/382#issuecomment-703725346
2020-10-06 12:39:05 -04:00
Raymond Hill
aff75b3527
Fix typo breaking the collapsing of placeholders
Related issue:
- https://github.com/gorhill/uBlock/issues/2848
2020-10-05 14:20:43 -04:00
Raymond Hill
d97c46ffd3
Use a user stylesheet to implement the collapsing of placeholders
Related issue:
- https://github.com/gorhill/uBlock/issues/2848
2020-10-05 09:13:07 -04:00
Raymond Hill
f4aebc9390
Backup/restore only modified advanced settings
This reduces the size of the backup file and also
ensures that default values can be changed.
2020-10-03 12:34:21 -04:00
Raymond Hill
e3a6d8465f
Add advanced setting to force a light/dark theme
Related feedback:
- https://github.com/uBlockOrigin/uBlock-issues/issues/401#issuecomment-703075797

Name: `uiTheme`
Default: `unset`
Values:
- `unset`: uBO will pick the theme according to
  browser's `prefers-color-scheme`
- `light`: force light scheme
- `dark`: force dark theme

This advanced setting is not to be documented yet as
it has not been decided this is a long term solution.
2020-10-03 07:13:40 -04:00
Raymond Hill
fef375a594
Minor improvements to syntax highlight of static filters
Double-cliking on a URL will cause the whole URL to be
selected, thus making it easier to navigate to this
URL (through your browser "Open in new tab" entry in
contextual menu).

Unrecognized scriptlet names will be highlighted so as
to warn that the filter is not going to be effective.
2020-09-30 10:01:10 -04:00
Raymond Hill
15e0778750
Prevent spurious instantiation of procedural filterer
Injecting declarative CSS `:style()` selector could cause
the instatiation of the procedural filterer, even when
there was no actual procedural cosmetic filter to
enforce.

This commit ensure that the procedural cosmetic filterer
is instantiated only when there are actual procedural
filters to enforce.
2020-09-24 10:53:18 -04:00
Raymond Hill
5df51d63d1
Do not syntax-highlight ... in "My rules" pane 2020-09-23 11:14:09 -04:00
Raymond Hill
99f605d28a
Minor code review of subscriber scriptlet 2020-09-21 07:25:24 -04:00
Raymond Hill
b3b2fc3b42
Remove unused property 2020-09-20 09:29:17 -04:00
Raymond Hill
6b15e8c423
Fix highlighting of good/bad hostnames in "My rules" pane
Related feedback:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1249#issuecomment-695755743
2020-09-20 08:58:04 -04:00
Raymond Hill
c181ab2911
Fix ability to set temporary cosmetic filter exceptions
Regression from:
- 35aefed926
2020-09-19 10:00:21 -04:00
Raymond Hill
3f299ef623
Improve validation of hostname in domain= and denyallow options
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1249

For "exotic" hostname values, the browser's own API will be
used to ultimately validate hostname values.
2020-09-18 10:23:02 -04:00
Raymond Hill
328d6a09f4
Fix broken styling of selectors with pseudo elements
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/382

Additionally, fix minor parsing issues with AdGuard's
cosmetic filters.
2020-09-14 14:58:25 -04:00
Raymond Hill
fe9797cacc
Add easylist.to as a valid target for subscriber content script 2020-09-14 08:43:51 -04:00
Raymond Hill
714f07dc25
Work around instances of over-encoded subscription URLs
Related feedback:
- https://github.com/uBlockOrigin/uBlock-issues/issues/763#issuecomment-691696716
2020-09-13 13:41:25 -04:00
Raymond Hill
4c7635514a
Fine tuning changes to click-to-subscribe code
Related feedback:
- https://github.com/uBlockOrigin/uBlock-issues/issues/763#issuecomment-691682195

Additionally, enable an existing subscription when
subscribing again to it.
2020-09-13 11:44:42 -04:00
Raymond Hill
e60042595c
Revisit the behavior of the click-to-subscribe content script
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/763

Changes:

From now on, uBO will allow click-to-subscribe on only
a few select domains, currently:
- https://filterlists.com/
- https://github.com/
- https://github.io/

More domains can be added if and only the demonstration
is made that more than a marginal number of filter lists
can be subscribed from those domains.

The browser alert box is no longer used to confirm
subscription to a filter list. Instead, the asset
viewer has been expanded to serve that purpose. This
way, users can peruse at the content of a filter list
before subscribing to it.
2020-09-13 08:01:53 -04:00
Raymond Hill
da7ff2b382
Remove now pointless use of important in CSS styles
Now that the element picker user interface is isolated
frompage content world, there is no need to use the
`important` modifier for the element picker's own
CSS styles.
2020-09-12 11:36:30 -04:00
Raymond Hill
05893a6c16
Fix swipe right to exit zapper/picker on touch displays
Regression from:
- d23f9c6a8b
2020-09-12 11:29:39 -04:00
Raymond Hill
218f774ba0
Fix broken localized string in some languages
Reported as feedback at:
- https://crowdin.com/translate/ublock
2020-09-12 10:37:08 -04:00
Raymond Hill
b73b24ebb1
Fix slider's responsiveness to layout changes
Related commit:
- f01bda1159
2020-09-12 08:26:44 -04:00
Raymond Hill
f01bda1159
Rework visuals of element picker sliders
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/851
2020-09-12 07:28:46 -04:00
Raymond Hill
ead49e083a
Fix delete key handling in element zapper
Related feedback:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1237#issuecomment-690897502
2020-09-11 08:12:45 -04:00
Raymond Hill
f0ef680a86
Remove pointless test for parent node presence
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1240
2020-09-11 07:58:01 -04:00
Raymond Hill
df83a0847f
Forgot to commit last minute changes in element picker
Related commit:
- 260f762c83
2020-09-10 10:40:07 -04:00
Raymond Hill
260f762c83
Add widget to control selector depth to element picker
Further iterating on the work done in following commit:
- 1268f0ae43

This commit adds a new widget to the element picker to
control the depth of a cosmetic filter selector. The
new widget is essentially just another way of selecting
the depth, which is still controllable through picking
one of the cosmetic filters in the list of candidates.
2020-09-10 10:32:53 -04:00
Raymond Hill
6f7801d433
Fix zapper not being able to remove SVG elements
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1237
2020-09-09 10:51:30 -04:00