@adguard/agtree 1.1.6 → 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/dist/build.txt CHANGED
@@ -1 +1 @@
1
- version=1.1.6
1
+ version=1.1.8
package/package.json CHANGED
@@ -1,110 +1,115 @@
1
1
  {
2
- "name": "@adguard/agtree",
3
- "version": "1.1.6",
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"
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
- "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
- "import": "./dist/agtree.esm.js",
31
- "require": "./dist/agtree.cjs"
32
- },
33
- "./es": "./dist/agtree.esm.js",
34
- "./iife": "./dist/agtree.iife.min.js",
35
- "./umd": "./dist/agtree.umd.min.js"
36
- },
37
- "files": [
38
- "dist"
39
- ],
40
- "engines": {
41
- "node": ">=14"
42
- },
43
- "scripts": {
44
- "build": "yarn clean && yarn build-types && yarn build-txt && yarn rollup --config rollup.config.ts --configPlugin typescript && yarn clean-types",
45
- "build-txt": "ts-node-esm scripts/build-txt.ts",
46
- "build-types": "tsc --declaration --emitDeclarationOnly --outdir dist/types",
47
- "check-compatibility-tables": "node --no-warnings --loader ts-node/esm --experimental-specifier-resolution=node scripts/check-compatibility-tables.ts",
48
- "check-types": "tsc --noEmit",
49
- "clean": "rimraf dist",
50
- "clean-types": "rimraf dist/types",
51
- "coverage": "jest --runInBand --coverage",
52
- "increment": "yarn version --patch --no-git-tag-version",
53
- "lint": "yarn lint:ts && yarn lint:md",
54
- "lint:md": "markdownlint .",
55
- "lint:ts": "eslint . --cache --ext .ts",
56
- "precommit": "yarn check-types && yarn lint && yarn test",
57
- "test": "jest --runInBand"
58
- },
59
- "devDependencies": {
60
- "@babel/core": "^7.22.5",
61
- "@babel/preset-env": "^7.22.5",
62
- "@rollup/plugin-alias": "^5.0.0",
63
- "@rollup/plugin-babel": "^6.0.3",
64
- "@rollup/plugin-commonjs": "^25.0.2",
65
- "@rollup/plugin-json": "^6.0.0",
66
- "@rollup/plugin-node-resolve": "^15.1.0",
67
- "@rollup/plugin-terser": "^0.4.3",
68
- "@rollup/plugin-typescript": "^11.1.2",
69
- "@rollup/plugin-yaml": "^4.1.1",
70
- "@swc/core": "^1.3.66",
71
- "@swc/jest": "^0.2.26",
72
- "@types/clone-deep": "^4.0.1",
73
- "@types/jest": "^29.5.3",
74
- "@types/js-yaml": "^4.0.5",
75
- "@types/node": "^20.2.3",
76
- "@types/semver": "^7.5.0",
77
- "@typescript-eslint/eslint-plugin": "^5.60.1",
78
- "@typescript-eslint/parser": "^5.60.1",
79
- "eslint": "^8.43.0",
80
- "eslint-config-airbnb-typescript": "^17.0.0",
81
- "eslint-plugin-import": "^2.27.5",
82
- "eslint-plugin-import-newlines": "^1.3.1",
83
- "eslint-plugin-jsdoc": "^46.4.0",
84
- "glob": "^9.3.2",
85
- "jest": "^29.5.0",
86
- "js-yaml": "^4.1.0",
87
- "jsdoc": "^4.0.2",
88
- "markdownlint": "^0.29.0",
89
- "markdownlint-cli": "^0.35.0",
90
- "rimraf": "^5.0.1",
91
- "rollup": "^3.25.3",
92
- "rollup-plugin-dts": "^5.3.0",
93
- "rollup-plugin-node-externals": "^6.1.1",
94
- "rollup-plugin-polyfill-node": "^0.12.0",
95
- "superstruct": "^1.0.3",
96
- "ts-node": "^10.9.1",
97
- "typescript": "^5.0.4",
98
- "yaml-jest-transform": "^2.0.2",
99
- "zod": "^3.22.2"
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,99 +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.6 - 2023-09-22
9
-
10
- ### Changed
11
-
12
- - Converter now returns an object with `result` and `isConverted` properties instead of just `result`
13
- - Filter list converter now accepts a second argument `tolerant` which allows to convert filter lists with invalid rules
14
-
15
- ### Added
16
-
17
- - `RawRuleConverter` class for converting raw rules
18
- - `RawFilterListConverter` class for converting raw filter lists
19
-
20
- ### Fixed
21
-
22
- - Improved converter's performance
23
-
24
- ## 1.1.5 - 2023-09-05
25
-
26
- ### Changed
27
-
28
- - Validation of `$csp` and `$permissions` modifiers value
29
- by custom pre-defined validator instead of regular expression
30
-
31
- ### Added
32
-
33
- - Exports to `package.json`
34
-
35
- ## 1.1.4 - 2023-08-30
36
-
37
- ### Fixed
38
-
39
- - Validation of `$redirect` and `$replace` modifiers by `ModifierValidator.validate()`
40
-
41
-
42
- ## 1.1.3 - 2023-08-28
43
-
44
- ### Added
45
-
46
- - Validation of modifier values due to `value_format`
47
-
48
- ## Changed
49
-
50
- - `ModifierValidator.validate()` result type `ValidationResult` — `valid` property instead of `ok`
51
-
52
-
53
- ## 1.1.2 - 2023-08-14
54
-
55
- ### Fixed
56
-
57
- - Compatibility tables validation of ABP syntax `$rewrite`
58
- - Detecting closing parenthesis in ADG/uBO scriptlets while parsing
59
-
60
- ## 1.1.1 - 2023-08-11
61
-
62
- ### Fixed
63
-
64
- - Validation of assignable modifiers which may be used without a value
65
-
66
- ## 1.1.0 - 2023-08-10
67
-
68
- ### Added
69
-
70
- - Compatibility tables for modifiers
71
- - Validator for modifiers
72
- - Basic rule converter
73
- - New utils (regex, quotes)
74
-
75
- ### Changed
76
-
77
- - Updated dependencies
78
- - Improved library build
79
- - Improved CSSTree utils
80
- - Export CSSTree utils
81
- - Store raw data while parsing
82
- - General code improvements
83
-
84
- ### Fixed
85
-
86
- - Package metadata
87
- - Type import/export
88
- - Modifier list parsing
89
- - Scriptlet parsing
90
- - Metadata parsing
91
-
92
- ## 1.0.1 - 2023-05-24
93
-
94
- ### Added
95
-
96
- - Migrated parser from AGLint to a separate package.
97
-
98
- [keepachangelog]: https://keepachangelog.com/en/1.0.0/
99
- [semver]: https://semver.org/spec/v2.0.0.html