@adguard/agtree 1.1.7 → 1.1.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -0
- package/dist/agtree.cjs +167 -3
- package/dist/agtree.d.ts +2 -2
- package/dist/agtree.esm.js +167 -3
- package/dist/agtree.iife.min.js +12 -6
- package/dist/agtree.umd.min.js +12 -6
- package/dist/build.txt +1 -1
- package/package.json +113 -108
- package/CHANGELOG.md +0 -106
package/dist/build.txt
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
version=1.1.
|
|
1
|
+
version=1.1.8
|
package/package.json
CHANGED
|
@@ -1,110 +1,115 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
2
|
+
"name": "@adguard/agtree",
|
|
3
|
+
"version": "1.1.8",
|
|
4
|
+
"description": "Universal adblock filter list parser.",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"adblock",
|
|
7
|
+
"filter",
|
|
8
|
+
"list",
|
|
9
|
+
"parser",
|
|
10
|
+
"ast"
|
|
11
|
+
],
|
|
12
|
+
"author": "Adguard Software Ltd.",
|
|
13
|
+
"license": "MIT",
|
|
14
|
+
"repository": {
|
|
15
|
+
"type": "git",
|
|
16
|
+
"url": "git+https://github.com/AdguardTeam/tsurlfilter.git",
|
|
17
|
+
"directory": "packages/agtree"
|
|
18
|
+
},
|
|
19
|
+
"bugs": {
|
|
20
|
+
"url": "https://github.com/AdguardTeam/tsurlfilter/issues"
|
|
21
|
+
},
|
|
22
|
+
"homepage": "https://github.com/AdguardTeam/tsurlfilter/tree/master/packages/agtree#readme",
|
|
23
|
+
"type": "module",
|
|
24
|
+
"main": "dist/agtree.cjs",
|
|
25
|
+
"module": "dist/agtree.esm.js",
|
|
26
|
+
"browser": "dist/agtree.umd.min.js",
|
|
27
|
+
"types": "dist/agtree.d.ts",
|
|
28
|
+
"exports": {
|
|
29
|
+
".": {
|
|
30
|
+
"types": "./dist/agtree.d.ts",
|
|
31
|
+
"import": "./dist/agtree.esm.js",
|
|
32
|
+
"require": "./dist/agtree.cjs"
|
|
18
33
|
},
|
|
19
|
-
"
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
"
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
"
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
"
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
"
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
"
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
"
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
"dependencies": {
|
|
102
|
-
"@adguard/ecss-tree": "^1.0.8",
|
|
103
|
-
"@adguard/scriptlets": "^1.9.61",
|
|
104
|
-
"clone-deep": "^4.0.1",
|
|
105
|
-
"json5": "^2.2.3",
|
|
106
|
-
"semver": "^7.5.3",
|
|
107
|
-
"tldts": "^5.7.112",
|
|
108
|
-
"xregexp": "^5.1.1"
|
|
109
|
-
}
|
|
110
|
-
}
|
|
34
|
+
"./es": "./dist/agtree.esm.js",
|
|
35
|
+
"./iife": "./dist/agtree.iife.min.js",
|
|
36
|
+
"./umd": "./dist/agtree.umd.min.js"
|
|
37
|
+
},
|
|
38
|
+
"files": [
|
|
39
|
+
"dist"
|
|
40
|
+
],
|
|
41
|
+
"engines": {
|
|
42
|
+
"node": ">=14"
|
|
43
|
+
},
|
|
44
|
+
"devDependencies": {
|
|
45
|
+
"@babel/core": "^7.22.5",
|
|
46
|
+
"@babel/preset-env": "^7.22.5",
|
|
47
|
+
"@rollup/plugin-alias": "^5.0.0",
|
|
48
|
+
"@rollup/plugin-babel": "^6.0.3",
|
|
49
|
+
"@rollup/plugin-commonjs": "^25.0.2",
|
|
50
|
+
"@rollup/plugin-json": "^6.0.0",
|
|
51
|
+
"@rollup/plugin-node-resolve": "^15.1.0",
|
|
52
|
+
"@rollup/plugin-terser": "^0.4.3",
|
|
53
|
+
"@rollup/plugin-typescript": "^11.1.2",
|
|
54
|
+
"@rollup/plugin-yaml": "^4.1.1",
|
|
55
|
+
"@swc/core": "^1.3.100",
|
|
56
|
+
"@swc/helpers": "^0.5.3",
|
|
57
|
+
"@swc/jest": "^0.2.29",
|
|
58
|
+
"@types/clone-deep": "^4.0.1",
|
|
59
|
+
"@types/fs-extra": "^11.0.4",
|
|
60
|
+
"@types/jest": "^29.5.3",
|
|
61
|
+
"@types/js-yaml": "^4.0.5",
|
|
62
|
+
"@types/node": "^20.2.3",
|
|
63
|
+
"@types/semver": "^7.5.0",
|
|
64
|
+
"@typescript-eslint/eslint-plugin": "^5.60.1",
|
|
65
|
+
"@typescript-eslint/parser": "^5.60.1",
|
|
66
|
+
"eslint": "^8.43.0",
|
|
67
|
+
"eslint-config-airbnb-typescript": "^17.0.0",
|
|
68
|
+
"eslint-plugin-import": "^2.27.5",
|
|
69
|
+
"eslint-plugin-import-newlines": "^1.3.1",
|
|
70
|
+
"eslint-plugin-jsdoc": "^46.4.0",
|
|
71
|
+
"fs-extra": "^11.2.0",
|
|
72
|
+
"glob": "^9.3.2",
|
|
73
|
+
"jest": "^29.5.0",
|
|
74
|
+
"js-yaml": "^4.1.0",
|
|
75
|
+
"jsdoc": "^4.0.2",
|
|
76
|
+
"markdownlint": "^0.29.0",
|
|
77
|
+
"markdownlint-cli": "^0.35.0",
|
|
78
|
+
"regenerator-runtime": "^0.14.0",
|
|
79
|
+
"rimraf": "^5.0.1",
|
|
80
|
+
"rollup": "^3.25.3",
|
|
81
|
+
"rollup-plugin-dts": "^5.3.0",
|
|
82
|
+
"rollup-plugin-node-externals": "^6.1.1",
|
|
83
|
+
"rollup-plugin-polyfill-node": "^0.12.0",
|
|
84
|
+
"superstruct": "^1.0.3",
|
|
85
|
+
"ts-node": "^10.9.2",
|
|
86
|
+
"typescript": "^5.0.4",
|
|
87
|
+
"yaml-jest-transform": "^2.0.2",
|
|
88
|
+
"zod": "^3.22.2"
|
|
89
|
+
},
|
|
90
|
+
"dependencies": {
|
|
91
|
+
"@adguard/ecss-tree": "^1.0.8",
|
|
92
|
+
"@adguard/scriptlets": "^1.9.61",
|
|
93
|
+
"clone-deep": "^4.0.1",
|
|
94
|
+
"json5": "^2.2.3",
|
|
95
|
+
"semver": "^7.5.3",
|
|
96
|
+
"tldts": "^5.7.112",
|
|
97
|
+
"xregexp": "^5.1.1"
|
|
98
|
+
},
|
|
99
|
+
"scripts": {
|
|
100
|
+
"build": "pnpm clean && pnpm build-types && pnpm build-txt && pnpm rollup --config rollup.config.ts --configPlugin typescript && pnpm clean-types",
|
|
101
|
+
"build-txt": "node --no-warnings=ExperimentalWarning --loader ts-node/esm scripts/build-txt.ts",
|
|
102
|
+
"build-types": "tsc --declaration --emitDeclarationOnly --outdir dist/types",
|
|
103
|
+
"check-compatibility-tables": "node --no-warnings=ExperimentalWarning --loader ts-node/esm scripts/check-compatibility-tables.ts",
|
|
104
|
+
"check-types": "tsc --noEmit",
|
|
105
|
+
"clean": "rimraf dist",
|
|
106
|
+
"clean-types": "rimraf dist/types",
|
|
107
|
+
"coverage": "jest --runInBand --coverage",
|
|
108
|
+
"increment": "pnpm version patch --no-git-tag-version",
|
|
109
|
+
"lint": "pnpm lint:ts && pnpm lint:md",
|
|
110
|
+
"lint:md": "markdownlint .",
|
|
111
|
+
"lint:ts": "eslint . --cache --ext .ts",
|
|
112
|
+
"precommit": "pnpm check-types && pnpm lint && pnpm test",
|
|
113
|
+
"test": "jest --runInBand"
|
|
114
|
+
}
|
|
115
|
+
}
|
package/CHANGELOG.md
DELETED
|
@@ -1,106 +0,0 @@
|
|
|
1
|
-
# AGTree Changelog
|
|
2
|
-
|
|
3
|
-
All notable changes to this project will be documented in this file.
|
|
4
|
-
|
|
5
|
-
The format is based on [Keep a Changelog][keepachangelog], and this project adheres to [Semantic Versioning][semver].
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
## 1.1.7 - 2023-11-07
|
|
9
|
-
|
|
10
|
-
### Added
|
|
11
|
-
|
|
12
|
-
- Support of `referrerpolicy` modifier [#98](https://github.com/AdguardTeam/tsurlfilter/issues/98)
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
## 1.1.6 - 2023-09-22
|
|
16
|
-
|
|
17
|
-
### Changed
|
|
18
|
-
|
|
19
|
-
- Converter now returns an object with `result` and `isConverted` properties instead of just `result`
|
|
20
|
-
- Filter list converter now accepts a second argument `tolerant` which allows to convert filter lists with invalid rules
|
|
21
|
-
|
|
22
|
-
### Added
|
|
23
|
-
|
|
24
|
-
- `RawRuleConverter` class for converting raw rules
|
|
25
|
-
- `RawFilterListConverter` class for converting raw filter lists
|
|
26
|
-
|
|
27
|
-
### Fixed
|
|
28
|
-
|
|
29
|
-
- Improved converter's performance
|
|
30
|
-
|
|
31
|
-
## 1.1.5 - 2023-09-05
|
|
32
|
-
|
|
33
|
-
### Changed
|
|
34
|
-
|
|
35
|
-
- Validation of `$csp` and `$permissions` modifiers value
|
|
36
|
-
by custom pre-defined validator instead of regular expression
|
|
37
|
-
|
|
38
|
-
### Added
|
|
39
|
-
|
|
40
|
-
- Exports to `package.json`
|
|
41
|
-
|
|
42
|
-
## 1.1.4 - 2023-08-30
|
|
43
|
-
|
|
44
|
-
### Fixed
|
|
45
|
-
|
|
46
|
-
- Validation of `$redirect` and `$replace` modifiers by `ModifierValidator.validate()`
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
## 1.1.3 - 2023-08-28
|
|
50
|
-
|
|
51
|
-
### Added
|
|
52
|
-
|
|
53
|
-
- Validation of modifier values due to `value_format`
|
|
54
|
-
|
|
55
|
-
## Changed
|
|
56
|
-
|
|
57
|
-
- `ModifierValidator.validate()` result type `ValidationResult` — `valid` property instead of `ok`
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
## 1.1.2 - 2023-08-14
|
|
61
|
-
|
|
62
|
-
### Fixed
|
|
63
|
-
|
|
64
|
-
- Compatibility tables validation of ABP syntax `$rewrite`
|
|
65
|
-
- Detecting closing parenthesis in ADG/uBO scriptlets while parsing
|
|
66
|
-
|
|
67
|
-
## 1.1.1 - 2023-08-11
|
|
68
|
-
|
|
69
|
-
### Fixed
|
|
70
|
-
|
|
71
|
-
- Validation of assignable modifiers which may be used without a value
|
|
72
|
-
|
|
73
|
-
## 1.1.0 - 2023-08-10
|
|
74
|
-
|
|
75
|
-
### Added
|
|
76
|
-
|
|
77
|
-
- Compatibility tables for modifiers
|
|
78
|
-
- Validator for modifiers
|
|
79
|
-
- Basic rule converter
|
|
80
|
-
- New utils (regex, quotes)
|
|
81
|
-
|
|
82
|
-
### Changed
|
|
83
|
-
|
|
84
|
-
- Updated dependencies
|
|
85
|
-
- Improved library build
|
|
86
|
-
- Improved CSSTree utils
|
|
87
|
-
- Export CSSTree utils
|
|
88
|
-
- Store raw data while parsing
|
|
89
|
-
- General code improvements
|
|
90
|
-
|
|
91
|
-
### Fixed
|
|
92
|
-
|
|
93
|
-
- Package metadata
|
|
94
|
-
- Type import/export
|
|
95
|
-
- Modifier list parsing
|
|
96
|
-
- Scriptlet parsing
|
|
97
|
-
- Metadata parsing
|
|
98
|
-
|
|
99
|
-
## 1.0.1 - 2023-05-24
|
|
100
|
-
|
|
101
|
-
### Added
|
|
102
|
-
|
|
103
|
-
- Migrated parser from AGLint to a separate package.
|
|
104
|
-
|
|
105
|
-
[keepachangelog]: https://keepachangelog.com/en/1.0.0/
|
|
106
|
-
[semver]: https://semver.org/spec/v2.0.0.html
|