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

7138 Commits

Author SHA1 Message Date
Raymond Hill
ce644c5960
Remove code unused in next release
Since https://github.com/uBlockOrigin/uBlock-issues/issues/156
won't be fixed in next release, no need to ship
with code which will be unused, and anyways only once
the fix is worked on will it be clear exactly what needs
to be used by scriptlets to deal harmoniously with
property listener collisions.
2019-07-11 10:17:06 -04:00
Raymond Hill
9ef06da310
Minor code review re. https://github.com/uBlockOrigin/uBlock-issues/issues/658 2019-07-11 09:50:12 -04:00
Raymond Hill
c499ce82a9
Use Reflect.construct(t) rather than new t()
Using `new` seemed to work but it's maybe
semantically better to use `Reflect.construct`.
2019-07-11 09:45:53 -04:00
Raymond Hill
7183ce8f42
Make Firefox dev build auto-update 2019-07-10 17:34:34 -04:00
Raymond Hill
80402d202a
Import translation work from https://crowdin.com/project/ublock 2019-07-10 17:29:48 -04:00
Raymond Hill
6b7c8be266
New revision for release candidate 2019-07-10 17:27:08 -04:00
Raymond Hill
874e92af2d
Fix regression in URL rules validation
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/665

Regression:
- 2f63fb3fd4
2019-07-10 17:24:01 -04:00
Raymond Hill
9a95fbff94
Restore erroneously remove comments in migration 2019-07-10 08:11:51 -04:00
Raymond Hill
291c1c0400
Make Firefox dev build auto-update 2019-07-09 11:54:23 -04:00
Raymond Hill
8ab12d0db4
New revision for release candidate 2019-07-09 11:39:30 -04:00
Raymond Hill
b54522caa1
[scriptlet engine] Mind old scriptlet names not using .js
Related commit:
- 5552d6717d
2019-07-09 11:36:42 -04:00
Raymond Hill
5c449f59f2
[redirect engine] Use shorter name as the official name
- nobab.js => bab-defuser.js
- nofab.js => fuckadblock.js-3.2.0
2019-07-09 11:04:12 -04:00
Raymond Hill
01bcc2b8a0
Make Firefox dev build auto-update 2019-07-08 12:39:27 -04:00
Raymond Hill
e72307a6e7
New revision for release candidate 2019-07-08 12:34:44 -04:00
Raymond Hill
fee217c59c
Fix regression introduced in 2f63fb3fd4
Related feedback:
- 2f63fb3fd4 (commitcomment-34222571)
2019-07-08 12:33:11 -04:00
Raymond Hill
93ab568baf
Make Firefox dev build auto-update 2019-07-08 11:00:09 -04:00
Raymond Hill
8033b8a13b
New revision for release candidate 2019-07-08 10:52:51 -04:00
Raymond Hill
2f63fb3fd4
Prevent adding known invalid URL-based rules
Related discussion:
- https://github.com/uBlockOrigin/uBlock-issues/issues/662#issuecomment-509220702

Currently, `doc` (aka `main_frame`) rules are not
evaluated to decide whether a network request must
be blocked or not, by design. This commits adjust
uBO's UI to account for this.
2019-07-08 10:49:53 -04:00
Raymond Hill
e55cae6232
Fine tune new resources-related code
Make sure the parser is safely compatible with old
resources format -- for those users still using
custom resources (via `userResourcesLocation`).

Prepare code for future fix to
<https://github.com/uBlockOrigin/uBlock-issues/issues/156>:

This commit introduces a new private Map() object,
`uBOSafe`, accessible by all injected scriptlets. This
private safe can be used to store data which can be shared
with different scriptlets. The idea is for scriptlets to
use that safe to graciously deal with the need to install
multiple listeners for the same property.
2019-07-08 08:56:36 -04:00
Raymond Hill
da4c4ded8d
Add a way to reload resources in dev build
Since resources are now immutable, by default they are
only compiled once each time uBO updates to a new
version. However I need a way to force a re-compiling
of the resource in the dev build. This commit adds code
to invalidate the resources selfie when forcing the
update of any filter list.
2019-07-08 08:41:28 -04:00
Raymond Hill
ad9b34bc7a
Code review of 9d1913a16e
Also eat backslash for `\\`, to allow searching for
literal `\n`, `\t`.
2019-07-07 07:52:37 -04:00
Raymond Hill
7fc31512f2
Make Firefox dev build auto-update 2019-07-07 07:38:13 -04:00
Raymond Hill
d802d400fa
New revision for dev build 2019-07-07 07:34:07 -04:00
Raymond Hill
47a5caef54
Fix last newline not being automatically appended
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/657
2019-07-07 06:57:30 -04:00
Raymond Hill
9d1913a16e
Eat backslashes only for common control characters
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/658
2019-07-07 06:29:14 -04:00
Raymond Hill
2acaf3c433
Fix background color of previewed image in logger
Related feedback:
- https://www.reddit.com/r/uBlockOrigin/comments/c9u5xy/
2019-07-06 17:26:35 -04:00
Raymond Hill
0acdd2ab5c
Make Firefox dev build auto-update 2019-07-06 14:01:12 -04:00
Raymond Hill
d64f4a2569
New revision for dev build 2019-07-06 13:55:52 -04:00
Raymond Hill
4c201c90e1
Remove strat mime type in scriptlets.js
Related ffedback:
- 6f5aa947fb (commitcomment-34205920)
2019-07-06 13:53:36 -04:00
Raymond Hill
8954175252
Make Firefox dev build auto-update 2019-07-06 13:03:04 -04:00
Raymond Hill
6d2f66fef6
Import translation work from https://crowdin.com/project/ublock 2019-07-06 12:56:27 -04:00
Raymond Hill
7a8cadacc4
New revision for dev build 2019-07-06 12:52:33 -04:00
Raymond Hill
6f5aa947fb
Finalize converting resources.txt into immutable resources
With hindsight, I revised decisions made earlier during
this development cycle:

Un-redirectable scriptlets have been removed from
/web_accessible_resources and instead put in the new
/assets/resources/scriptlets.js, which contains all
scriptlets used for web page injection purpose.

uBO will no longer fetch a remote version of built-in
resources.

Advanced setting `userResourcesLocation` will still be
honoured by uBO, and if set, will be fetched every
time at least one asset is updated.
2019-07-06 12:36:28 -04:00
Raymond Hill
813b390dda
Make Firefox dev build auto-update 2019-07-05 18:30:31 -04:00
Raymond Hill
b827cdcad2
New revision for dev build 2019-07-05 18:26:03 -04:00
Raymond Hill
ae56c4dfe8
Fix whitelist status evaluation of tabless network requests
Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/651

The `behnind-the-scene` context was wrongly used to
evaluate the whitelist status of the context of tabless
network requests. The document origin must be used
instead when it's available.

Additionally, much code has been revisited for better
ES6 syntax compliance.
2019-07-05 17:44:08 -04:00
Raymond Hill
9693d07a6d
Code review of https://github.com/gorhill/uBlock/commit/f930da7ad64a 2019-07-05 12:33:14 -04:00
Raymond Hill
f930da7ad6
Fix regression of reverse-lookup of scriptlet filters in logger
Related commit:
- 5552d6717d
2019-07-05 11:44:40 -04:00
Raymond Hill
e107b6bcf1
Fix typo in comment 2019-07-05 10:32:19 -04:00
Raymond Hill
5552d6717d
Implement scriptlet token normalization
The goal is to be able to specify a scriptlet token
without the `.js` part at the end, because that part
is essentially redundant with the `+js` part of
the syntax.

When the next stable release is in widespread use
(to determine), scriptlet tokens will have to be
specified without the `.js` part, and with this
commit the logger will already report the normalized
version of scriptlets.

Eventually, when the migration to sans-`.js` is
complete (also to determine), the internal
normalization of the token will be removed and this
will become official syntax.

Filter list maintainers will have to mind that
uAssets is becoming in use beyond uBO (i.e. Brave)
when skipping the `.js` part -- hopefully Brave will
go along with the change here, which is to remove a
bit of tediousness for filter list maintainers.
2019-07-05 10:10:59 -04:00
Raymond Hill
6220e1d3eb
Add missing newline 2019-07-05 08:22:26 -04:00
Raymond Hill
3e1de012a6
Make Firefox dev build auto-update 2019-07-05 08:11:01 -04:00
Raymond Hill
9a6506e585
New revision for dev build 2019-07-05 08:00:50 -04:00
Raymond Hill
3e53963be3
Fix window.open-defuser
Matching logic has been erronesouly reverse.
2019-07-05 07:59:02 -04:00
Raymond Hill
a992875c94
Save only modified immediate hidden settings 2019-07-05 07:33:09 -04:00
Raymond Hill
34073b41df
Make Firefox dev build auto-update 2019-07-04 16:04:14 -04:00
Raymond Hill
b3ea68a08d
Import translation work from https://crowdin.com/project/ublock 2019-07-04 15:50:20 -04:00
Raymond Hill
8083855aa8
New revision for dev build 2019-07-04 15:48:36 -04:00
Raymond Hill
1fb9845c35
Remove useless code 2019-07-04 14:10:23 -04:00
Raymond Hill
f9e680f111
Convert more resources as immutable
Related commit:
- 152cea2dfe
2019-07-04 14:08:56 -04:00