@wp-blocks/make-pot 1.2.0 → 1.3.0

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.
Files changed (96) hide show
  1. package/biome.json +12 -0
  2. package/lib/assets/block-i18n.js +1 -0
  3. package/lib/assets/package-i18n.js +1 -0
  4. package/lib/assets/theme-i18n.js +1 -0
  5. package/lib/assets/wp-plugin-i18n.js +1 -0
  6. package/lib/assets/wp-theme-i18n.js +1 -0
  7. package/lib/cli/getArgs.js +1 -0
  8. package/lib/cli/parseCli.js +1 -110
  9. package/lib/const.js +1 -82
  10. package/lib/extractors/css.js +1 -42
  11. package/lib/extractors/headers.js +1 -73
  12. package/lib/extractors/json.js +1 -69
  13. package/lib/extractors/php.js +2 -49
  14. package/lib/extractors/schema.js +1 -100
  15. package/lib/extractors/text.js +1 -18
  16. package/lib/extractors/utils.js +1 -55
  17. package/lib/fs/fs.js +1 -0
  18. package/lib/fs/glob.js +3 -83
  19. package/lib/index.js +1 -26
  20. package/lib/parser/exec.js +3 -49
  21. package/lib/parser/makePot.js +1 -0
  22. package/lib/parser/patterns.js +1 -33
  23. package/lib/parser/process.js +1 -38
  24. package/lib/parser/progress.js +1 -21
  25. package/lib/parser/taskRunner.js +1 -33
  26. package/lib/parser/tree.js +1 -104
  27. package/lib/run.js +1 -0
  28. package/lib/types.js +1 -3
  29. package/lib/utils/common.js +2 -0
  30. package/package.json +68 -75
  31. package/tsconfig.json +4 -20
  32. package/ .prettierignore +0 -3
  33. package/.editorconfig +0 -15
  34. package/.eslintrc.json +0 -12
  35. package/jest.config.json +0 -18
  36. package/lib/assets/block-i18n.json +0 -17
  37. package/lib/assets/package-i18n.json +0 -13
  38. package/lib/assets/theme-i18n.json +0 -86
  39. package/lib/assets/wp-plugin-i18n.json +0 -14
  40. package/lib/assets/wp-theme-i18n.json +0 -13
  41. package/lib/cli/index.d.ts +0 -1
  42. package/lib/cli/index.js +0 -114
  43. package/lib/cli/index.js.map +0 -1
  44. package/lib/cli/parseCli.d.ts +0 -3
  45. package/lib/cli/parseCli.js.map +0 -1
  46. package/lib/const.d.ts +0 -140
  47. package/lib/const.js.map +0 -1
  48. package/lib/extractors/css.d.ts +0 -2
  49. package/lib/extractors/css.js.map +0 -1
  50. package/lib/extractors/headers.d.ts +0 -5
  51. package/lib/extractors/headers.js.map +0 -1
  52. package/lib/extractors/index.d.ts +0 -2
  53. package/lib/extractors/index.js +0 -50
  54. package/lib/extractors/index.js.map +0 -1
  55. package/lib/extractors/json.d.ts +0 -10
  56. package/lib/extractors/json.js.map +0 -1
  57. package/lib/extractors/php.d.ts +0 -3
  58. package/lib/extractors/php.js.map +0 -1
  59. package/lib/extractors/schema.d.ts +0 -84
  60. package/lib/extractors/schema.js.map +0 -1
  61. package/lib/extractors/text.d.ts +0 -1
  62. package/lib/extractors/text.js.map +0 -1
  63. package/lib/extractors/utils.d.ts +0 -5
  64. package/lib/extractors/utils.js.map +0 -1
  65. package/lib/fs/glob.d.ts +0 -13
  66. package/lib/fs/glob.js.map +0 -1
  67. package/lib/fs/index.d.ts +0 -2
  68. package/lib/fs/index.js +0 -58
  69. package/lib/fs/index.js.map +0 -1
  70. package/lib/index.d.ts +0 -2
  71. package/lib/index.js.map +0 -1
  72. package/lib/parser/exec.d.ts +0 -2
  73. package/lib/parser/exec.js.map +0 -1
  74. package/lib/parser/index.d.ts +0 -2
  75. package/lib/parser/index.js +0 -30
  76. package/lib/parser/index.js.map +0 -1
  77. package/lib/parser/patterns.d.ts +0 -2
  78. package/lib/parser/patterns.js.map +0 -1
  79. package/lib/parser/process.d.ts +0 -4
  80. package/lib/parser/process.js.map +0 -1
  81. package/lib/parser/progress.d.ts +0 -3
  82. package/lib/parser/progress.js.map +0 -1
  83. package/lib/parser/taskRunner.d.ts +0 -4
  84. package/lib/parser/taskRunner.js.map +0 -1
  85. package/lib/parser/tree.d.ts +0 -2
  86. package/lib/parser/tree.js.map +0 -1
  87. package/lib/types.d.ts +0 -50
  88. package/lib/types.js.map +0 -1
  89. package/lib/utils/index.d.ts +0 -9
  90. package/lib/utils/index.js +0 -83
  91. package/lib/utils/index.js.map +0 -1
  92. package/tests/extract.test.ts +0 -382
  93. package/tests/getFiles.test.ts +0 -114
  94. package/tests/ignoreFunction.test.ts +0 -102
  95. package/tests/jsonParse.ts +0 -51
  96. package/tests/tree.test.ts +0 -151
package/package.json CHANGED
@@ -1,75 +1,68 @@
1
- {
2
- "name": "@wp-blocks/make-pot",
3
- "version": "1.2.0",
4
- "license": "GPL-3.0-or-later",
5
- "homepage": "https://wp-blocks.github.io/make-pot/",
6
- "description": "A Node.js script for generating a POT file from source code",
7
- "authors": [
8
- "Erik Golinelli <erik@codekraft.it> (https://codekraft.it/)",
9
- "John Hooks <bitmachina@outlook.com> (https://johnhooks.io/)"
10
- ],
11
- "main": "lib/index.js",
12
- "keywords": [
13
- "gettext",
14
- "i18n",
15
- "pot",
16
- "WordPress",
17
- "translation",
18
- "internalization"
19
- ],
20
- "scripts": {
21
- "postinstall": "npm rebuild tree-sitter tree-sitter-typescript tree-sitter-php tree-sitter-javascript --force",
22
- "build": "tsc --build",
23
- "watch": "tsc --watch",
24
- "clean": "tsc --build --clean",
25
- "lint": "eslint ./src ./tests --fix",
26
- "test": "jest --coverage",
27
- "update-snapshots": "jest -- -u",
28
- "run": "node ./lib/index.js tests/fixtures/vinyl/"
29
- },
30
- "bin": {
31
- "make-pot": "lib/index.js"
32
- },
33
- "repository": {
34
- "type": "git",
35
- "url": "https://github.com/wp-blocks/makePot.git"
36
- },
37
- "bugs": {
38
- "url": "https://github.com/wp-blocks/makePot/issues"
39
- },
40
- "dependencies": {
41
- "axios": "^1.6.8",
42
- "cli-progress": "^3.12.0",
43
- "gettext-merger": "^1.2.1",
44
- "gettext-parser": "^7.0.1",
45
- "glob": "^10.3.10",
46
- "tree-sitter": "^0.20.6",
47
- "tree-sitter-javascript": "^0.20.4",
48
- "tree-sitter-php": "^0.20.0",
49
- "tree-sitter-typescript": "^0.20.5",
50
- "yargs": "^17.7.2"
51
- },
52
- "devDependencies": {
53
- "@jest/globals": "^29.7.0",
54
- "@types/cli-progress": "^3.11.5",
55
- "@types/gettext-parser": "^4.0.4",
56
- "@types/jest": "^29.5.12",
57
- "@types/node": "^20.11.28",
58
- "@types/strip-comments": "^2.0.4",
59
- "@types/yargs": "^17.0.32",
60
- "@typescript-eslint/eslint-plugin": "^6.18.1",
61
- "@typescript-eslint/parser": "^6.14.0",
62
- "eslint": "^8.57.0",
63
- "eslint-config-standard": "^17.1.0",
64
- "eslint-config-standard-with-typescript": "^43.0.0",
65
- "eslint-plugin-import": "^2.29.1",
66
- "eslint-plugin-n": "^16.6.1",
67
- "eslint-plugin-promise": "^6.1.1",
68
- "husky": "^9.0.11",
69
- "jest": "^29.7.0",
70
- "lint-staged": "^15.2.2",
71
- "prettier": "3.2.5",
72
- "ts-jest": "^29.1.2",
73
- "typescript": "^5.4.2"
74
- }
75
- }
1
+ {
2
+ "name": "@wp-blocks/make-pot",
3
+ "version": "1.3.0",
4
+ "license": "GPL-3.0-or-later",
5
+ "homepage": "https://wp-blocks.github.io/make-pot/",
6
+ "description": "A Node.js script for generating a POT file from source code",
7
+ "authors": [
8
+ "Erik Golinelli <erik@codekraft.it> (https://codekraft.it/)",
9
+ "John Hooks <bitmachina@outlook.com> (https://johnhooks.io/)"
10
+ ],
11
+ "main": "lib/run.js",
12
+ "bin": {
13
+ "make-pot": "lib/index.js"
14
+ },
15
+ "type": "commonjs",
16
+ "engines": {
17
+ "node": ">=16.0.0"
18
+ },
19
+ "files": ["lib", "*.md", "*.json", "LICENSE"],
20
+ "keywords": [
21
+ "gettext",
22
+ "i18n",
23
+ "pot",
24
+ "WordPress",
25
+ "translation",
26
+ "internalization"
27
+ ],
28
+ "scripts": {
29
+ "postinstall": "npm rebuild tree-sitter tree-sitter-typescript tree-sitter-php tree-sitter-javascript --force",
30
+ "build": "npx esbuild ./src/**/* --format=cjs --minify --outdir=lib --platform=node",
31
+ "watch": "tsc --watch",
32
+ "lint": "npx @biomejs/biome check --apply src",
33
+ "test": "node --test",
34
+ "ci:bundle": "npx esbuild ./src/index.ts --format=cjs --outdir=lib --bundle --external:tree-sitter --external:tree-sitter-typescript --external:tree-sitter-php --external:tree-sitter-javascript --platform=node",
35
+ "test:ci": "npm run ci:bundle && node --test",
36
+ "test:watch": "node --test --watch",
37
+ "test:coverage": "node --test --experimental-test-coverage",
38
+ "run": "node ./lib/index.js tests/fixtures/vinyl/"
39
+ },
40
+ "repository": {
41
+ "type": "git",
42
+ "url": "https://github.com/wp-blocks/makePot.git"
43
+ },
44
+ "bugs": {
45
+ "url": "https://github.com/wp-blocks/makePot/issues"
46
+ },
47
+ "dependencies": {
48
+ "axios": "^1.6.8",
49
+ "cli-progress": "^3.12.0",
50
+ "gettext-merger": "^1.2.1",
51
+ "gettext-parser": "^4.0.4",
52
+ "glob": "^10.3.10",
53
+ "tree-sitter": "^0.20.6",
54
+ "tree-sitter-javascript": "^0.20.4",
55
+ "tree-sitter-php": "^0.20.0",
56
+ "tree-sitter-typescript": "^0.20.5",
57
+ "yargs": "^17.7.1"
58
+ },
59
+ "devDependencies": {
60
+ "@biomejs/biome": "1.7.3",
61
+ "@types/cli-progress": "^3.11.5",
62
+ "@types/gettext-parser": "^4.0.4",
63
+ "@types/node": "^20.11.28",
64
+ "@types/yargs": "^17.0.32",
65
+ "esbuild": "0.21.1",
66
+ "typescript": "^5.4.5"
67
+ }
68
+ }
package/tsconfig.json CHANGED
@@ -1,32 +1,16 @@
1
1
  {
2
2
  "compilerOptions": {
3
- "module": "NodeNext",
4
- "target": "ES2021",
5
- "lib": [ "es2021" ],
3
+ "module": "commonjs",
4
+ "moduleResolution": "Node16",
6
5
  "noImplicitAny": true,
7
- "removeComments": true,
8
6
  "preserveConstEnums": true,
9
7
  "sourceMap": true,
10
8
  "strict": true,
11
- "declaration": true,
12
9
  "downlevelIteration": true,
13
10
  "esModuleInterop": true,
14
11
  "resolveJsonModule": true,
15
- "allowSyntheticDefaultImports": true,
16
- "experimentalDecorators": true,
17
- // Import non-ES modules as default imports.
18
12
  "outDir": "lib",
19
- "rootDir": "src",
20
- // Minify
21
- "pretty": false,
22
- // types
23
- "typeRoots": [
24
- "src/types.d.ts",
25
- "node_modules/@types",
26
- "@types"
27
- ]
13
+ "rootDir": "src"
28
14
  },
29
- "include": [
30
- "./src/**/*"
31
- ]
15
+ "include": ["./src/**/*", "./tsconfig.json"]
32
16
  }
@@ -1,3 +0,0 @@
1
- # Ignore artifacts:
2
- build
3
- coverage
package/.editorconfig DELETED
@@ -1,15 +0,0 @@
1
- # This file is for unifying the coding style for different editors and IDEs
2
- # editorconfig.org
3
-
4
- # WordPress Coding Standards
5
- # https://make.wordpress.org/core/handbook/coding-standards/
6
-
7
- root = true
8
-
9
- [*]
10
- charset = utf-8
11
- end_of_line = lf
12
- insert_final_newline = true
13
- trim_trailing_whitespace = true
14
- indent_size = 4
15
- indent_style = tab
package/.eslintrc.json DELETED
@@ -1,12 +0,0 @@
1
- {
2
- "env": {
3
- "browser": true,
4
- "node": true,
5
- "commonjs": true,
6
- "es2021": true
7
- },
8
- "extends": ["eslint:recommended", "plugin:@typescript-eslint/recommended"],
9
- "parser": "@typescript-eslint/parser",
10
- "plugins": ["@typescript-eslint"],
11
- "root": true
12
- }
package/jest.config.json DELETED
@@ -1,18 +0,0 @@
1
- {
2
- "preset": "ts-jest",
3
- "testEnvironment": "node",
4
- "testRegex": "(/tests/.*(test|spec))\\.tsx?$",
5
- "transformIgnorePatterns": ["/node_modules/"],
6
- "coverageThreshold": {
7
- "global": {
8
- "branches": 10,
9
- "functions": 10,
10
- "lines": 10,
11
- "statements": 10
12
- }
13
- },
14
- "collectCoverageFrom": ["./src/**/*.{js,jsx,ts,tsx}", "!**/tests/**"],
15
- "coverageReporters": [ "json", "lcov", "text", "clover" ],
16
- "collectCoverage": true,
17
- "coverageDirectory": "docs/coverage"
18
- }
@@ -1,17 +0,0 @@
1
- {
2
- "title": "block title",
3
- "description": "block description",
4
- "keywords": ["block keyword"],
5
- "styles": [
6
- {
7
- "label": "block style label"
8
- }
9
- ],
10
- "variations": [
11
- {
12
- "title": "block variation title",
13
- "description": "block variation description",
14
- "keywords": ["block variation keyword"]
15
- }
16
- ]
17
- }
@@ -1,13 +0,0 @@
1
- {
2
- "name": "name",
3
- "url": "url",
4
- "description": "description",
5
- "author": "author",
6
- "authorEmail": "authorEmail",
7
- "version": "version",
8
- "bugs": "bugs",
9
- "bugs.url": "bugsUrl",
10
- "bugs.email": "bugsEmail",
11
- "license": "license",
12
- "repository": "repository"
13
- }
@@ -1,86 +0,0 @@
1
- {
2
- "title": "Style variation name",
3
- "settings": {
4
- "typography": {
5
- "fontSizes": [
6
- {
7
- "name": "Font size name"
8
- }
9
- ],
10
- "fontFamilies": [
11
- {
12
- "name": "Font family name"
13
- }
14
- ]
15
- },
16
- "color": {
17
- "palette": [
18
- {
19
- "name": "Color name"
20
- }
21
- ],
22
- "gradients": [
23
- {
24
- "name": "Gradient name"
25
- }
26
- ],
27
- "duotone": [
28
- {
29
- "name": "Duotone name"
30
- }
31
- ]
32
- },
33
- "spacing": {
34
- "spacingSizes": [
35
- {
36
- "name": "Space size name"
37
- }
38
- ]
39
- },
40
- "blocks": {
41
- "*": {
42
- "typography": {
43
- "fontSizes": [
44
- {
45
- "name": "Font size name"
46
- }
47
- ],
48
- "fontFamilies": [
49
- {
50
- "name": "Font family name"
51
- }
52
- ]
53
- },
54
- "color": {
55
- "palette": [
56
- {
57
- "name": "Color name"
58
- }
59
- ],
60
- "gradients": [
61
- {
62
- "name": "Gradient name"
63
- }
64
- ]
65
- },
66
- "spacing": {
67
- "spacingSizes": [
68
- {
69
- "name": "Space size name"
70
- }
71
- ]
72
- }
73
- }
74
- }
75
- },
76
- "customTemplates": [
77
- {
78
- "title": "Custom template name"
79
- }
80
- ],
81
- "templateParts": [
82
- {
83
- "title": "Template part name"
84
- }
85
- ]
86
- }
@@ -1,14 +0,0 @@
1
- {
2
- "name": "Plugin Name",
3
- "url": "Plugin URI",
4
- "description": "Description",
5
- "version": "Version",
6
- "author": "Author",
7
- "authorUri": "Author URI",
8
- "tags": "Tags",
9
- "license": "License",
10
- "licenseUri": "License URI",
11
- "updateUri": "Update URI",
12
- "domainPath": "Domain Path",
13
- "textDomain": "Text Domain"
14
- }
@@ -1,13 +0,0 @@
1
- {
2
- "name": "Theme Name",
3
- "author": "Author",
4
- "authorUri": "Author URI",
5
- "description": "Description",
6
- "url": "Theme URI",
7
- "tags": "Tags",
8
- "version": "Version",
9
- "license": "License",
10
- "licenseUri": "License URI",
11
- "domainPath": "Domain Path",
12
- "textDomain": "Text Domain"
13
- }
@@ -1 +0,0 @@
1
- export declare function getArgs(): import("../types").Args;
package/lib/cli/index.js DELETED
@@ -1,114 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.getArgs = void 0;
7
- const yargs_1 = __importDefault(require("yargs"));
8
- const helpers_1 = require("yargs/helpers");
9
- const process_1 = __importDefault(require("process"));
10
- const parseCli_1 = require("./parseCli");
11
- function getArgs() {
12
- const args = (0, yargs_1.default)((0, helpers_1.hideBin)(process_1.default.argv))
13
- .help('h')
14
- .alias('help', 'help')
15
- .usage('Usage: $0 <source> [destination] [options]')
16
- .positional('sourceDirectory', {
17
- describe: 'Source directory',
18
- type: 'string',
19
- })
20
- .positional('destination', {
21
- describe: 'Destination directory',
22
- type: 'string',
23
- })
24
- .options({
25
- slug: {
26
- describe: 'Plugin or theme slug',
27
- type: 'string',
28
- },
29
- domain: {
30
- describe: 'Text domain to look for in the source code',
31
- type: 'string',
32
- },
33
- 'skip-js': {
34
- describe: 'Skip JavaScript files',
35
- type: 'boolean',
36
- },
37
- 'skip-php': {
38
- describe: 'Skip PHP files',
39
- type: 'boolean',
40
- },
41
- 'skip-blade': {
42
- describe: 'Skip Blade files',
43
- type: 'boolean',
44
- },
45
- 'skip-block-json': {
46
- describe: 'Skip block.json files',
47
- type: 'boolean',
48
- },
49
- 'skip-theme-json': {
50
- describe: 'Skip theme.json files',
51
- type: 'boolean',
52
- },
53
- 'skip-audit': {
54
- describe: 'Skip auditing of strings',
55
- type: 'boolean',
56
- },
57
- headers: {
58
- describe: 'Headers',
59
- type: 'string',
60
- },
61
- 'file-comment': {
62
- describe: 'File comment',
63
- type: 'string',
64
- },
65
- 'package-name': {
66
- describe: 'Package name',
67
- type: 'string',
68
- },
69
- location: {
70
- describe: 'Include location information',
71
- type: 'boolean',
72
- },
73
- 'ignore-domain': {
74
- describe: 'Ignore text domain',
75
- type: 'boolean',
76
- },
77
- mergePaths: {
78
- describe: 'Merge with existing POT file(s)',
79
- type: 'string',
80
- },
81
- subtractPaths: {
82
- describe: 'Subtract strings from existing POT file(s)',
83
- type: 'string',
84
- },
85
- subtractAndMerge: {
86
- describe: 'Subtract and merge strings from existing POT file(s)',
87
- type: 'boolean',
88
- },
89
- include: {
90
- describe: 'Include specific files',
91
- type: 'string',
92
- },
93
- exclude: {
94
- describe: 'Exclude specific files',
95
- type: 'string',
96
- },
97
- silent: {
98
- describe: 'No output to stdout',
99
- type: 'boolean',
100
- },
101
- json: {
102
- describe: 'Output the json gettext data',
103
- type: 'boolean',
104
- },
105
- output: {
106
- describe: 'Output the gettext data',
107
- type: 'boolean',
108
- },
109
- })
110
- .parseSync();
111
- return (0, parseCli_1.parseCliArgs)(args);
112
- }
113
- exports.getArgs = getArgs;
114
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/cli/index.ts"],"names":[],"mappings":";;;;;;AAAA,kDAAyB;AACzB,2CAAuC;AACvC,sDAA6B;AAE7B,yCAAyC;AAOzC,SAAgB,OAAO;IACtB,MAAM,IAAI,GAAG,IAAA,eAAK,EAAC,IAAA,iBAAO,EAAC,iBAAO,CAAC,IAAI,CAAC,CAAC;SAC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AC9B,IAAI,EAAE,SAAS;SACf;QACD,UAAU,EAAE;YACX,QAAQ,EAAE,iCAAiC;YAC3C,IAAI,EAAE,QAAQ;SACd;QACD,aAAa,EAAE;YACd,QAAQ,EAAE,4CAA4C;YACtD,IAAI,EAAE,QAAQ;SACd;QACD,gBAAgB,EAAE;YACjB,QAAQ,EACP,sDAAsD;YACvD,IAAI,EAAE,SAAS;SACf;QACD,OAAO,EAAE;YACR,QAAQ,EAAE,wBAAwB;YAClC,IAAI,EAAE,QAAQ;SACd;QACD,OAAO,EAAE;YACR,QAAQ,EAAE,wBAAwB;YAClC,IAAI,EAAE,QAAQ;SACd;QACD,MAAM,EAAE;YACP,QAAQ,EAAE,qBAAqB;YAC/B,IAAI,EAAE,SAAS;SACf;QACD,IAAI,EAAE;YACL,QAAQ,EAAE,8BAA8B;YACxC,IAAI,EAAE,SAAS;SACf;QACD,MAAM,EAAE;YACP,QAAQ,EAAE,yBAAyB;YACnC,IAAI,EAAE,SAAS;SACf;KACD,CAAC;SACD,SAAS,EAAE,CAAA;IACb,OAAO,IAAA,uBAAY,EAAC,IAAI,CAAC,CAAA;AAC1B,CAAC;AAtGD,0BAsGC"}
@@ -1,3 +0,0 @@
1
- import yargs from 'yargs';
2
- import { Args } from '../types';
3
- export declare function parseCliArgs(args: yargs.PositionalOptions & yargs.Options & yargs.Arguments): Args;
@@ -1 +0,0 @@
1
- {"version":3,"file":"parseCli.js","sourceRoot":"","sources":["../../src/cli/parseCli.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AACA,oCAAuC;AACvC,2CAA4B;AAC5B,iDAAkC;AAClC,oCAAgD;AAEhD,mDAAwC;AAExC,SAAS,eAAe,CAAC,cAAsB,GAAG,EAAE,IAAY;IAC/D,MAAM,uBAAuB,GAAG,WAAW,CAAA;IAE3C,IAAI,CAAC;QACJ,IAAA,oBAAU,EACT,IAAI,CAAC,IAAI,CAAC,uBAAuB,EAAE,IAAI,GAAG,MAAM,CAAC,EAC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AAK,EAAE,CAAC,CAAC,IAAI,CAAC,SAAS;gBACvB,SAAS,EAAE,CAAC,CAAC,IAAI,CAAC,aAAa;gBAC/B,SAAS,EAAE,CAAC,CAAC,IAAI,CAAC,aAAa;gBAC/B,KAAK,EAAE,CAAC,CAAC,IAAI,CAAC,SAAS;aACvB;SACD;QAED,OAAO,EAAE;YACR,WAAW,EAAG,IAAI,CAAC,WAAsB,IAAI,EAAE;SAC/C;QAED,QAAQ,EAAE;YACT,UAAU,EAAE,IAAA,oBAAY,EAAC,IAAI,CAAC,UAAoB,CAAC,IAAI,EAAE;YACzD,aAAa,EAAE,IAAA,oBAAY,EAAC,IAAI,CAAC,aAAuB,CAAC,IAAI,EAAE;YAC/D,gBAAgB,EAAE,CAAC,CAAC,IAAI,CAAC,gBAAgB;YACzC,OAAO,EAAE,IAAA,oBAAY,EAAC,IAAI,CAAC,OAAiB,CAAC,IAAI,CAAC,IAAI,CAAC;YACvD,OAAO,EACN,IAAA,oBAAY,EAAC,IAAI,CAAC,OAAiB,CAAC,IAAI,6BAAqB;SAC9D;KACD,CAAA;IAED,UAAU,CAAC,KAAK,CAAC,IAAI,GAAG,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,SAAS,CAAA;IAEjE,OAAO,UAAU,CAAA;AAClB,CAAC;AA3DD,oCA2DC"}
package/lib/const.d.ts DELETED
@@ -1,140 +0,0 @@
1
- export declare const pkgJson: Record<string, unknown>;
2
- export declare const themeJson: {
3
- title: string;
4
- settings: {
5
- typography: {
6
- fontSizes: {
7
- name: string;
8
- }[];
9
- fontFamilies: {
10
- name: string;
11
- }[];
12
- };
13
- color: {
14
- palette: {
15
- name: string;
16
- }[];
17
- gradients: {
18
- name: string;
19
- }[];
20
- duotone: {
21
- name: string;
22
- }[];
23
- };
24
- spacing: {
25
- spacingSizes: {
26
- name: string;
27
- }[];
28
- };
29
- blocks: {
30
- "*": {
31
- typography: {
32
- fontSizes: {
33
- name: string;
34
- }[];
35
- fontFamilies: {
36
- name: string;
37
- }[];
38
- };
39
- color: {
40
- palette: {
41
- name: string;
42
- }[];
43
- gradients: {
44
- name: string;
45
- }[];
46
- };
47
- spacing: {
48
- spacingSizes: {
49
- name: string;
50
- }[];
51
- };
52
- };
53
- };
54
- };
55
- customTemplates: {
56
- title: string;
57
- }[];
58
- templateParts: {
59
- title: string;
60
- }[];
61
- };
62
- export declare const blockJson: {
63
- title: string;
64
- description: string;
65
- keywords: string[];
66
- styles: {
67
- label: string;
68
- }[];
69
- variations: {
70
- title: string;
71
- description: string;
72
- keywords: string[];
73
- }[];
74
- };
75
- export declare const pkgJsonHeaders: {
76
- name: string;
77
- url: string;
78
- description: string;
79
- author: string;
80
- authorEmail: string;
81
- version: string;
82
- bugs: string;
83
- "bugs.url": string;
84
- "bugs.email": string;
85
- license: string;
86
- repository: string;
87
- };
88
- export declare const pluginHeaders: {
89
- name: string;
90
- url: string;
91
- description: string;
92
- version: string;
93
- author: string;
94
- authorUri: string;
95
- tags: string;
96
- license: string;
97
- licenseUri: string;
98
- updateUri: string;
99
- domainPath: string;
100
- textDomain: string;
101
- };
102
- export declare const themeHeaders: {
103
- name: string;
104
- author: string;
105
- authorUri: string;
106
- description: string;
107
- url: string;
108
- tags: string;
109
- version: string;
110
- license: string;
111
- licenseUri: string;
112
- domainPath: string;
113
- textDomain: string;
114
- };
115
- export declare const DEFAULT_EXCLUDED_PATH: string[];
116
- export declare const allowedFiles: string[];
117
- export declare const i18nFunctions: {
118
- __: string[];
119
- esc_attr__: string[];
120
- esc_html__: string[];
121
- esc_xml__: string[];
122
- _e: string[];
123
- esc_attr_e: string[];
124
- esc_html_e: string[];
125
- esc_xml_e: string[];
126
- _x: string[];
127
- _ex: string[];
128
- esc_attr_x: string[];
129
- esc_html_x: string[];
130
- esc_xml_x: string[];
131
- _n: string[];
132
- _nx: string[];
133
- _n_noop: string[];
134
- _nx_noop: string[];
135
- _: string[];
136
- _c: string[];
137
- _nc: string[];
138
- __ngettext: string[];
139
- __ngettext_noop: string[];
140
- };