@wordpress/abilities 0.3.0 → 0.3.1-next.06ee73755.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.
- package/CHANGELOG.md +0 -2
- package/LICENSE.md +1 -1
- package/build/{api.js → api.cjs} +3 -3
- package/build/{index.js → index.cjs} +4 -4
- package/build/store/{actions.js → actions.cjs} +2 -2
- package/build/store/{constants.js → constants.cjs} +1 -1
- package/build/store/{index.js → index.cjs} +5 -5
- package/build/store/{reducer.js → reducer.cjs} +2 -2
- package/build/store/{selectors.js → selectors.cjs} +1 -1
- package/build/store/{types.js → types.cjs} +1 -1
- package/build/{types.js → types.cjs} +1 -1
- package/build/{validation.js → validation.cjs} +1 -1
- package/build-module/{api.js → api.mjs} +3 -3
- package/build-module/{index.js → index.mjs} +4 -4
- package/build-module/store/{actions.js → actions.mjs} +2 -2
- package/build-module/store/{constants.js → constants.mjs} +1 -1
- package/build-module/store/{index.js → index.mjs} +5 -5
- package/build-module/store/{reducer.js → reducer.mjs} +2 -2
- package/build-module/store/{selectors.js → selectors.mjs} +1 -1
- package/build-module/store/types.mjs +1 -0
- package/build-module/types.mjs +1 -0
- package/build-module/{validation.js → validation.mjs} +1 -1
- package/package.json +10 -10
- package/build-module/store/types.js +0 -1
- package/build-module/types.js +0 -1
- /package/build/{api.js.map → api.cjs.map} +0 -0
- /package/build/{index.js.map → index.cjs.map} +0 -0
- /package/build/store/{actions.js.map → actions.cjs.map} +0 -0
- /package/build/store/{constants.js.map → constants.cjs.map} +0 -0
- /package/build/store/{index.js.map → index.cjs.map} +0 -0
- /package/build/store/{reducer.js.map → reducer.cjs.map} +0 -0
- /package/build/store/{selectors.js.map → selectors.cjs.map} +0 -0
- /package/build/store/{types.js.map → types.cjs.map} +0 -0
- /package/build/{types.js.map → types.cjs.map} +0 -0
- /package/build/{validation.js.map → validation.cjs.map} +0 -0
- /package/build-module/{api.js.map → api.mjs.map} +0 -0
- /package/build-module/{index.js.map → index.mjs.map} +0 -0
- /package/build-module/store/{actions.js.map → actions.mjs.map} +0 -0
- /package/build-module/store/{constants.js.map → constants.mjs.map} +0 -0
- /package/build-module/store/{index.js.map → index.mjs.map} +0 -0
- /package/build-module/store/{reducer.js.map → reducer.mjs.map} +0 -0
- /package/build-module/store/{selectors.js.map → selectors.mjs.map} +0 -0
- /package/build-module/store/{types.js.map → types.mjs.map} +0 -0
- /package/build-module/{types.js.map → types.mjs.map} +0 -0
- /package/build-module/{validation.js.map → validation.mjs.map} +0 -0
package/CHANGELOG.md
CHANGED
package/LICENSE.md
CHANGED
package/build/{api.js → api.cjs}
RENAMED
|
@@ -33,8 +33,8 @@ __export(api_exports, {
|
|
|
33
33
|
module.exports = __toCommonJS(api_exports);
|
|
34
34
|
var import_data = require("@wordpress/data");
|
|
35
35
|
var import_i18n = require("@wordpress/i18n");
|
|
36
|
-
var import_store = require("./store");
|
|
37
|
-
var import_validation = require("./validation");
|
|
36
|
+
var import_store = require("./store/index.cjs");
|
|
37
|
+
var import_validation = require("./validation.cjs");
|
|
38
38
|
function getAbilities(args = {}) {
|
|
39
39
|
return (0, import_data.select)(import_store.store).getAbilities(args);
|
|
40
40
|
}
|
|
@@ -139,4 +139,4 @@ async function executeAbility(name, input) {
|
|
|
139
139
|
unregisterAbility,
|
|
140
140
|
unregisterAbilityCategory
|
|
141
141
|
});
|
|
142
|
-
//# sourceMappingURL=api.
|
|
142
|
+
//# sourceMappingURL=api.cjs.map
|
|
@@ -33,9 +33,9 @@ __export(index_exports, {
|
|
|
33
33
|
validateValueFromSchema: () => import_validation.validateValueFromSchema
|
|
34
34
|
});
|
|
35
35
|
module.exports = __toCommonJS(index_exports);
|
|
36
|
-
var import_api = require("./api");
|
|
37
|
-
var import_store = require("./store");
|
|
38
|
-
var import_validation = require("./validation");
|
|
36
|
+
var import_api = require("./api.cjs");
|
|
37
|
+
var import_store = require("./store/index.cjs");
|
|
38
|
+
var import_validation = require("./validation.cjs");
|
|
39
39
|
// Annotate the CommonJS export names for ESM import in node:
|
|
40
40
|
0 && (module.exports = {
|
|
41
41
|
executeAbility,
|
|
@@ -50,4 +50,4 @@ var import_validation = require("./validation");
|
|
|
50
50
|
unregisterAbilityCategory,
|
|
51
51
|
validateValueFromSchema
|
|
52
52
|
});
|
|
53
|
-
//# sourceMappingURL=index.
|
|
53
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -27,7 +27,7 @@ __export(actions_exports, {
|
|
|
27
27
|
});
|
|
28
28
|
module.exports = __toCommonJS(actions_exports);
|
|
29
29
|
var import_i18n = require("@wordpress/i18n");
|
|
30
|
-
var import_constants = require("./constants");
|
|
30
|
+
var import_constants = require("./constants.cjs");
|
|
31
31
|
function filterAnnotations(sourceAnnotations, allowedKeys) {
|
|
32
32
|
const annotations = {};
|
|
33
33
|
if (sourceAnnotations) {
|
|
@@ -190,4 +190,4 @@ function unregisterAbilityCategory(slug) {
|
|
|
190
190
|
unregisterAbility,
|
|
191
191
|
unregisterAbilityCategory
|
|
192
192
|
});
|
|
193
|
-
//# sourceMappingURL=actions.
|
|
193
|
+
//# sourceMappingURL=actions.cjs.map
|
|
@@ -34,10 +34,10 @@ __export(store_exports, {
|
|
|
34
34
|
});
|
|
35
35
|
module.exports = __toCommonJS(store_exports);
|
|
36
36
|
var import_data = require("@wordpress/data");
|
|
37
|
-
var import_reducer = __toESM(require("./reducer"));
|
|
38
|
-
var actions = __toESM(require("./actions"));
|
|
39
|
-
var selectors = __toESM(require("./selectors"));
|
|
40
|
-
var import_constants = require("./constants");
|
|
37
|
+
var import_reducer = __toESM(require("./reducer.cjs"));
|
|
38
|
+
var actions = __toESM(require("./actions.cjs"));
|
|
39
|
+
var selectors = __toESM(require("./selectors.cjs"));
|
|
40
|
+
var import_constants = require("./constants.cjs");
|
|
41
41
|
var store = (0, import_data.createReduxStore)(import_constants.STORE_NAME, {
|
|
42
42
|
reducer: import_reducer.default,
|
|
43
43
|
actions,
|
|
@@ -48,4 +48,4 @@ var store = (0, import_data.createReduxStore)(import_constants.STORE_NAME, {
|
|
|
48
48
|
0 && (module.exports = {
|
|
49
49
|
store
|
|
50
50
|
});
|
|
51
|
-
//# sourceMappingURL=index.
|
|
51
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -24,7 +24,7 @@ __export(reducer_exports, {
|
|
|
24
24
|
});
|
|
25
25
|
module.exports = __toCommonJS(reducer_exports);
|
|
26
26
|
var import_data = require("@wordpress/data");
|
|
27
|
-
var import_constants = require("./constants");
|
|
27
|
+
var import_constants = require("./constants.cjs");
|
|
28
28
|
var ABILITY_KEYS = [
|
|
29
29
|
"name",
|
|
30
30
|
"label",
|
|
@@ -103,4 +103,4 @@ var reducer_default = (0, import_data.combineReducers)({
|
|
|
103
103
|
abilitiesByName,
|
|
104
104
|
categoriesBySlug
|
|
105
105
|
});
|
|
106
|
-
//# sourceMappingURL=reducer.
|
|
106
|
+
//# sourceMappingURL=reducer.cjs.map
|
|
@@ -16,4 +16,4 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
16
16
|
// packages/abilities/src/store/types.ts
|
|
17
17
|
var types_exports = {};
|
|
18
18
|
module.exports = __toCommonJS(types_exports);
|
|
19
|
-
//# sourceMappingURL=types.
|
|
19
|
+
//# sourceMappingURL=types.cjs.map
|
|
@@ -16,4 +16,4 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
16
16
|
// packages/abilities/src/types.ts
|
|
17
17
|
var types_exports = {};
|
|
18
18
|
module.exports = __toCommonJS(types_exports);
|
|
19
|
-
//# sourceMappingURL=types.
|
|
19
|
+
//# sourceMappingURL=types.cjs.map
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
// packages/abilities/src/api.ts
|
|
2
2
|
import { dispatch, select } from "@wordpress/data";
|
|
3
3
|
import { sprintf } from "@wordpress/i18n";
|
|
4
|
-
import { store } from "./store";
|
|
5
|
-
import { validateValueFromSchema } from "./validation";
|
|
4
|
+
import { store } from "./store/index.mjs";
|
|
5
|
+
import { validateValueFromSchema } from "./validation.mjs";
|
|
6
6
|
function getAbilities(args = {}) {
|
|
7
7
|
return select(store).getAbilities(args);
|
|
8
8
|
}
|
|
@@ -106,4 +106,4 @@ export {
|
|
|
106
106
|
unregisterAbility,
|
|
107
107
|
unregisterAbilityCategory
|
|
108
108
|
};
|
|
109
|
-
//# sourceMappingURL=api.
|
|
109
|
+
//# sourceMappingURL=api.mjs.map
|
|
@@ -9,9 +9,9 @@ import {
|
|
|
9
9
|
unregisterAbility,
|
|
10
10
|
registerAbilityCategory,
|
|
11
11
|
unregisterAbilityCategory
|
|
12
|
-
} from "./api";
|
|
13
|
-
import { store } from "./store";
|
|
14
|
-
import { validateValueFromSchema } from "./validation";
|
|
12
|
+
} from "./api.mjs";
|
|
13
|
+
import { store } from "./store/index.mjs";
|
|
14
|
+
import { validateValueFromSchema } from "./validation.mjs";
|
|
15
15
|
export {
|
|
16
16
|
executeAbility,
|
|
17
17
|
getAbilities,
|
|
@@ -25,4 +25,4 @@ export {
|
|
|
25
25
|
unregisterAbilityCategory,
|
|
26
26
|
validateValueFromSchema
|
|
27
27
|
};
|
|
28
|
-
//# sourceMappingURL=index.
|
|
28
|
+
//# sourceMappingURL=index.mjs.map
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
UNREGISTER_ABILITY_CATEGORY,
|
|
8
8
|
ABILITY_NAME_PATTERN,
|
|
9
9
|
CATEGORY_SLUG_PATTERN
|
|
10
|
-
} from "./constants";
|
|
10
|
+
} from "./constants.mjs";
|
|
11
11
|
function filterAnnotations(sourceAnnotations, allowedKeys) {
|
|
12
12
|
const annotations = {};
|
|
13
13
|
if (sourceAnnotations) {
|
|
@@ -169,4 +169,4 @@ export {
|
|
|
169
169
|
unregisterAbility,
|
|
170
170
|
unregisterAbilityCategory
|
|
171
171
|
};
|
|
172
|
-
//# sourceMappingURL=actions.
|
|
172
|
+
//# sourceMappingURL=actions.mjs.map
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
// packages/abilities/src/store/index.ts
|
|
2
2
|
import { createReduxStore, register } from "@wordpress/data";
|
|
3
|
-
import reducer from "./reducer";
|
|
4
|
-
import * as actions from "./actions";
|
|
5
|
-
import * as selectors from "./selectors";
|
|
6
|
-
import { STORE_NAME } from "./constants";
|
|
3
|
+
import reducer from "./reducer.mjs";
|
|
4
|
+
import * as actions from "./actions.mjs";
|
|
5
|
+
import * as selectors from "./selectors.mjs";
|
|
6
|
+
import { STORE_NAME } from "./constants.mjs";
|
|
7
7
|
var store = createReduxStore(STORE_NAME, {
|
|
8
8
|
reducer,
|
|
9
9
|
actions,
|
|
@@ -13,4 +13,4 @@ register(store);
|
|
|
13
13
|
export {
|
|
14
14
|
store
|
|
15
15
|
};
|
|
16
|
-
//# sourceMappingURL=index.
|
|
16
|
+
//# sourceMappingURL=index.mjs.map
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
UNREGISTER_ABILITY,
|
|
6
6
|
REGISTER_ABILITY_CATEGORY,
|
|
7
7
|
UNREGISTER_ABILITY_CATEGORY
|
|
8
|
-
} from "./constants";
|
|
8
|
+
} from "./constants.mjs";
|
|
9
9
|
var ABILITY_KEYS = [
|
|
10
10
|
"name",
|
|
11
11
|
"label",
|
|
@@ -87,4 +87,4 @@ var reducer_default = combineReducers({
|
|
|
87
87
|
export {
|
|
88
88
|
reducer_default as default
|
|
89
89
|
};
|
|
90
|
-
//# sourceMappingURL=reducer.
|
|
90
|
+
//# sourceMappingURL=reducer.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=types.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=types.mjs.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wordpress/abilities",
|
|
3
|
-
"version": "0.3.0",
|
|
3
|
+
"version": "0.3.1-next.06ee73755.0",
|
|
4
4
|
"description": "JavaScript client for WordPress Abilities API.",
|
|
5
5
|
"author": "The WordPress Contributors",
|
|
6
6
|
"license": "GPL-2.0-or-later",
|
|
@@ -24,29 +24,29 @@
|
|
|
24
24
|
"npm": ">=8.19.2"
|
|
25
25
|
},
|
|
26
26
|
"files": [
|
|
27
|
+
"src",
|
|
27
28
|
"build",
|
|
28
29
|
"build-module",
|
|
29
30
|
"build-types",
|
|
30
|
-
"src",
|
|
31
31
|
"*.md"
|
|
32
32
|
],
|
|
33
|
-
"main": "build/index.
|
|
34
|
-
"module": "build-module/index.
|
|
33
|
+
"main": "build/index.cjs",
|
|
34
|
+
"module": "build-module/index.mjs",
|
|
35
35
|
"exports": {
|
|
36
36
|
".": {
|
|
37
37
|
"types": "./build-types/index.d.ts",
|
|
38
|
-
"import": "./build-module/index.
|
|
39
|
-
"require": "./build/index.
|
|
38
|
+
"import": "./build-module/index.mjs",
|
|
39
|
+
"require": "./build/index.cjs"
|
|
40
40
|
},
|
|
41
41
|
"./package.json": "./package.json"
|
|
42
42
|
},
|
|
43
43
|
"wpScriptModuleExports": {
|
|
44
|
-
".": "./build-module/index.
|
|
44
|
+
".": "./build-module/index.mjs"
|
|
45
45
|
},
|
|
46
46
|
"types": "build-types",
|
|
47
47
|
"dependencies": {
|
|
48
|
-
"@wordpress/data": "^10.37.0",
|
|
49
|
-
"@wordpress/i18n": "^6.10.0",
|
|
48
|
+
"@wordpress/data": "^10.37.1-next.06ee73755.0",
|
|
49
|
+
"@wordpress/i18n": "^6.10.1-next.06ee73755.0",
|
|
50
50
|
"ajv": "^8.17.1",
|
|
51
51
|
"ajv-draft-04": "^1.0.0",
|
|
52
52
|
"ajv-formats": "^3.0.1"
|
|
@@ -54,5 +54,5 @@
|
|
|
54
54
|
"publishConfig": {
|
|
55
55
|
"access": "public"
|
|
56
56
|
},
|
|
57
|
-
"gitHead": "
|
|
57
|
+
"gitHead": "fd315436f44683a993d5f053789b5279d95b2872"
|
|
58
58
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=types.js.map
|
package/build-module/types.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=types.js.map
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|