@wordpress/data-controls 2.30.0 → 3.1.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 +8 -0
- package/README.md +13 -11
- package/build/index.js +30 -9
- package/build/index.js.map +1 -1
- package/build-module/index.js +31 -10
- package/build-module/index.js.map +1 -1
- package/build-types/index.d.ts +111 -0
- package/build-types/index.d.ts.map +1 -0
- package/package.json +6 -5
- package/src/{index.js → index.ts} +37 -13
- package/tsconfig.json +14 -0
- package/tsconfig.tsbuildinfo +1 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,14 @@
|
|
|
2
2
|
|
|
3
3
|
## Unreleased
|
|
4
4
|
|
|
5
|
+
## 3.1.0 (2023-04-26)
|
|
6
|
+
|
|
7
|
+
## 3.0.0 (2023-04-12)
|
|
8
|
+
|
|
9
|
+
### Breaking Changes
|
|
10
|
+
|
|
11
|
+
- Publish Typescript build types to npm. ([#49647](https://github.com/WordPress/gutenberg/pull/49647))
|
|
12
|
+
|
|
5
13
|
## 2.30.0 (2023-03-29)
|
|
6
14
|
|
|
7
15
|
## 2.29.0 (2023-03-15)
|
package/README.md
CHANGED
|
@@ -47,8 +47,7 @@ _Returns_
|
|
|
47
47
|
|
|
48
48
|
### controls
|
|
49
49
|
|
|
50
|
-
The default export is what you use to register the controls with your custom
|
|
51
|
-
store.
|
|
50
|
+
The default export is what you use to register the controls with your custom store.
|
|
52
51
|
|
|
53
52
|
_Usage_
|
|
54
53
|
|
|
@@ -78,30 +77,33 @@ _Returns_
|
|
|
78
77
|
|
|
79
78
|
### dispatch
|
|
80
79
|
|
|
81
|
-
Control for dispatching an action in a registered data store.
|
|
82
|
-
Alias for the `dispatch` control in the `@wordpress/data` package.
|
|
80
|
+
Control for dispatching an action in a registered data store. Alias for the `dispatch` control in the `@wordpress/data` package.
|
|
83
81
|
|
|
84
82
|
_Parameters_
|
|
85
83
|
|
|
86
|
-
-
|
|
84
|
+
- _storeNameOrDescriptor_ `string | StoreDescriptor`: The store object or identifier.
|
|
85
|
+
- _actionName_ `string`: The action name.
|
|
86
|
+
- _args_ `any[]`: Arguments passed without change to the `@wordpress/data` control.
|
|
87
87
|
|
|
88
88
|
### select
|
|
89
89
|
|
|
90
|
-
Control for resolving a selector in a registered data store.
|
|
91
|
-
Alias for the `resolveSelect` built-in control in the `@wordpress/data` package.
|
|
90
|
+
Control for resolving a selector in a registered data store. Alias for the `resolveSelect` built-in control in the `@wordpress/data` package.
|
|
92
91
|
|
|
93
92
|
_Parameters_
|
|
94
93
|
|
|
95
|
-
-
|
|
94
|
+
- _storeNameOrDescriptor_ `string | StoreDescriptor`: The store object or identifier.
|
|
95
|
+
- _selectorName_ `string`: The selector name.
|
|
96
|
+
- _args_ `any[]`: Arguments passed without change to the `@wordpress/data` control.
|
|
96
97
|
|
|
97
98
|
### syncSelect
|
|
98
99
|
|
|
99
|
-
Control for calling a selector in a registered data store.
|
|
100
|
-
Alias for the `select` built-in control in the `@wordpress/data` package.
|
|
100
|
+
Control for calling a selector in a registered data store. Alias for the `select` built-in control in the `@wordpress/data` package.
|
|
101
101
|
|
|
102
102
|
_Parameters_
|
|
103
103
|
|
|
104
|
-
-
|
|
104
|
+
- _storeNameOrDescriptor_ `string | StoreDescriptor`: The store object or identifier.
|
|
105
|
+
- _selectorName_ `string`: The selector name.
|
|
106
|
+
- _args_ `any[]`: Arguments passed without change to the `@wordpress/data` control.
|
|
105
107
|
|
|
106
108
|
<!-- END TOKEN(Autogenerated API docs) -->
|
|
107
109
|
|
package/build/index.js
CHANGED
|
@@ -51,46 +51,67 @@ function apiFetch(request) {
|
|
|
51
51
|
* Control for resolving a selector in a registered data store.
|
|
52
52
|
* Alias for the `resolveSelect` built-in control in the `@wordpress/data` package.
|
|
53
53
|
*
|
|
54
|
-
* @param
|
|
54
|
+
* @param storeNameOrDescriptor The store object or identifier.
|
|
55
|
+
* @param selectorName The selector name.
|
|
56
|
+
* @param args Arguments passed without change to the `@wordpress/data` control.
|
|
55
57
|
*/
|
|
56
58
|
|
|
57
59
|
|
|
58
|
-
function select() {
|
|
60
|
+
function select(storeNameOrDescriptor, selectorName) {
|
|
59
61
|
(0, _deprecated.default)('`select` control in `@wordpress/data-controls`', {
|
|
60
62
|
since: '5.7',
|
|
61
63
|
alternative: 'built-in `resolveSelect` control in `@wordpress/data`'
|
|
62
64
|
});
|
|
63
|
-
|
|
65
|
+
|
|
66
|
+
for (var _len = arguments.length, args = new Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) {
|
|
67
|
+
args[_key - 2] = arguments[_key];
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
return _data.controls.resolveSelect(storeNameOrDescriptor, selectorName, ...args);
|
|
64
71
|
}
|
|
65
72
|
/**
|
|
66
73
|
* Control for calling a selector in a registered data store.
|
|
67
74
|
* Alias for the `select` built-in control in the `@wordpress/data` package.
|
|
68
75
|
*
|
|
69
|
-
* @param
|
|
76
|
+
* @param storeNameOrDescriptor The store object or identifier.
|
|
77
|
+
* @param selectorName The selector name.
|
|
78
|
+
* @param args Arguments passed without change to the `@wordpress/data` control.
|
|
70
79
|
*/
|
|
71
80
|
|
|
72
81
|
|
|
73
|
-
function syncSelect() {
|
|
82
|
+
function syncSelect(storeNameOrDescriptor, selectorName) {
|
|
74
83
|
(0, _deprecated.default)('`syncSelect` control in `@wordpress/data-controls`', {
|
|
75
84
|
since: '5.7',
|
|
76
85
|
alternative: 'built-in `select` control in `@wordpress/data`'
|
|
77
86
|
});
|
|
78
|
-
|
|
87
|
+
|
|
88
|
+
for (var _len2 = arguments.length, args = new Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) {
|
|
89
|
+
args[_key2 - 2] = arguments[_key2];
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
return _data.controls.select(storeNameOrDescriptor, selectorName, ...args);
|
|
79
93
|
}
|
|
80
94
|
/**
|
|
81
95
|
* Control for dispatching an action in a registered data store.
|
|
82
96
|
* Alias for the `dispatch` control in the `@wordpress/data` package.
|
|
83
97
|
*
|
|
84
|
-
* @param
|
|
98
|
+
* @param storeNameOrDescriptor The store object or identifier.
|
|
99
|
+
* @param actionName The action name.
|
|
100
|
+
* @param args Arguments passed without change to the `@wordpress/data` control.
|
|
85
101
|
*/
|
|
86
102
|
|
|
87
103
|
|
|
88
|
-
function dispatch() {
|
|
104
|
+
function dispatch(storeNameOrDescriptor, actionName) {
|
|
89
105
|
(0, _deprecated.default)('`dispatch` control in `@wordpress/data-controls`', {
|
|
90
106
|
since: '5.7',
|
|
91
107
|
alternative: 'built-in `dispatch` control in `@wordpress/data`'
|
|
92
108
|
});
|
|
93
|
-
|
|
109
|
+
|
|
110
|
+
for (var _len3 = arguments.length, args = new Array(_len3 > 2 ? _len3 - 2 : 0), _key3 = 2; _key3 < _len3; _key3++) {
|
|
111
|
+
args[_key3 - 2] = arguments[_key3];
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
return _data.controls.dispatch(storeNameOrDescriptor, actionName, ...args);
|
|
94
115
|
}
|
|
95
116
|
/**
|
|
96
117
|
* Dispatches a control action for awaiting on a promise to be resolved.
|
package/build/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["@wordpress/data-controls/src/index.
|
|
1
|
+
{"version":3,"sources":["@wordpress/data-controls/src/index.ts"],"names":["apiFetch","request","type","select","storeNameOrDescriptor","selectorName","since","alternative","args","dataControls","resolveSelect","syncSelect","dispatch","actionName","__unstableAwaitPromise","promise","controls","AWAIT_PROMISE","API_FETCH"],"mappings":";;;;;;;;;;;;;;AAGA;;AACA;;AACA;;AALA;AACA;AACA;;AAOA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAASA,QAAT,CAAmBC,OAAnB,EAA8C;AACpD,SAAO;AACNC,IAAAA,IAAI,EAAE,WADA;AAEND,IAAAA;AAFM,GAAP;AAIA;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AACO,SAASE,MAAT,CACNC,qBADM,EAENC,YAFM,EAIL;AACD,2BAAY,gDAAZ,EAA8D;AAC7DC,IAAAA,KAAK,EAAE,KADsD;AAE7DC,IAAAA,WAAW,EAAE;AAFgD,GAA9D;;AADC,oCADEC,IACF;AADEA,IAAAA,IACF;AAAA;;AAMD,SAAOC,eAAaC,aAAb,CACNN,qBADM,EAENC,YAFM,EAGN,GAAGG,IAHG,CAAP;AAKA;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AACO,SAASG,UAAT,CACNP,qBADM,EAENC,YAFM,EAIL;AACD,2BAAY,oDAAZ,EAAkE;AACjEC,IAAAA,KAAK,EAAE,KAD0D;AAEjEC,IAAAA,WAAW,EAAE;AAFoD,GAAlE;;AADC,qCADEC,IACF;AADEA,IAAAA,IACF;AAAA;;AAMD,SAAOC,eAAaN,MAAb,CAAqBC,qBAArB,EAA4CC,YAA5C,EAA0D,GAAGG,IAA7D,CAAP;AACA;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AACO,SAASI,QAAT,CACNR,qBADM,EAENS,UAFM,EAIL;AACD,2BAAY,kDAAZ,EAAgE;AAC/DP,IAAAA,KAAK,EAAE,KADwD;AAE/DC,IAAAA,WAAW,EAAE;AAFkD,GAAhE;;AADC,qCADEC,IACF;AADEA,IAAAA,IACF;AAAA;;AAMD,SAAOC,eAAaG,QAAb,CAAuBR,qBAAvB,EAA8CS,UAA9C,EAA0D,GAAGL,IAA7D,CAAP;AACA;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AACO,MAAMM,sBAAsB,GAAG,UAAgBC,OAAhB,EAAwC;AAC7E,SAAO;AACNb,IAAAA,IAAI,EAAE,eADA;AAENa,IAAAA;AAFM,GAAP;AAIA,CALM;AAOP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;AACO,MAAMC,QAAQ,GAAG;AACvBC,EAAAA,aAAa,EAAE;AAAA,QAAO;AAAEF,MAAAA;AAAF,KAAP;AAAA,WAAmDA,OAAnD;AAAA,GADQ;;AAEvBG,EAAAA,SAAS,QAA8C;AAAA,QAA5C;AAAEjB,MAAAA;AAAF,KAA4C;AACtD,WAAO,uBAAcA,OAAd,CAAP;AACA;;AAJsB,CAAjB","sourcesContent":["/**\n * WordPress dependencies\n */\nimport triggerFetch from '@wordpress/api-fetch';\nimport { controls as dataControls } from '@wordpress/data';\nimport deprecated from '@wordpress/deprecated';\nimport type { StoreDescriptor } from '@wordpress/data';\nimport type { APIFetchOptions } from '@wordpress/api-fetch';\n\n/**\n * Dispatches a control action for triggering an api fetch call.\n *\n * @param {Object} request Arguments for the fetch request.\n *\n * @example\n * ```js\n * import { apiFetch } from '@wordpress/data-controls';\n *\n * // Action generator using apiFetch\n * export function* myAction() {\n * \tconst path = '/v2/my-api/items';\n * \tconst items = yield apiFetch( { path } );\n * \t// do something with the items.\n * }\n * ```\n *\n * @return {Object} The control descriptor.\n */\nexport function apiFetch( request: APIFetchOptions ) {\n\treturn {\n\t\ttype: 'API_FETCH',\n\t\trequest,\n\t};\n}\n\n/**\n * Control for resolving a selector in a registered data store.\n * Alias for the `resolveSelect` built-in control in the `@wordpress/data` package.\n *\n * @param storeNameOrDescriptor The store object or identifier.\n * @param selectorName The selector name.\n * @param args Arguments passed without change to the `@wordpress/data` control.\n */\nexport function select(\n\tstoreNameOrDescriptor: string | StoreDescriptor,\n\tselectorName: string,\n\t...args: any[]\n) {\n\tdeprecated( '`select` control in `@wordpress/data-controls`', {\n\t\tsince: '5.7',\n\t\talternative: 'built-in `resolveSelect` control in `@wordpress/data`',\n\t} );\n\n\treturn dataControls.resolveSelect(\n\t\tstoreNameOrDescriptor,\n\t\tselectorName,\n\t\t...args\n\t);\n}\n\n/**\n * Control for calling a selector in a registered data store.\n * Alias for the `select` built-in control in the `@wordpress/data` package.\n *\n * @param storeNameOrDescriptor The store object or identifier.\n * @param selectorName The selector name.\n * @param args Arguments passed without change to the `@wordpress/data` control.\n */\nexport function syncSelect(\n\tstoreNameOrDescriptor: string | StoreDescriptor,\n\tselectorName: string,\n\t...args: any[]\n) {\n\tdeprecated( '`syncSelect` control in `@wordpress/data-controls`', {\n\t\tsince: '5.7',\n\t\talternative: 'built-in `select` control in `@wordpress/data`',\n\t} );\n\n\treturn dataControls.select( storeNameOrDescriptor, selectorName, ...args );\n}\n\n/**\n * Control for dispatching an action in a registered data store.\n * Alias for the `dispatch` control in the `@wordpress/data` package.\n *\n * @param storeNameOrDescriptor The store object or identifier.\n * @param actionName The action name.\n * @param args Arguments passed without change to the `@wordpress/data` control.\n */\nexport function dispatch(\n\tstoreNameOrDescriptor: string | StoreDescriptor,\n\tactionName: string,\n\t...args: any[]\n) {\n\tdeprecated( '`dispatch` control in `@wordpress/data-controls`', {\n\t\tsince: '5.7',\n\t\talternative: 'built-in `dispatch` control in `@wordpress/data`',\n\t} );\n\n\treturn dataControls.dispatch( storeNameOrDescriptor, actionName, ...args );\n}\n\n/**\n * Dispatches a control action for awaiting on a promise to be resolved.\n *\n * @param {Object} promise Promise to wait for.\n *\n * @example\n * ```js\n * import { __unstableAwaitPromise } from '@wordpress/data-controls';\n *\n * // Action generator using apiFetch\n * export function* myAction() {\n * \tconst promise = getItemsAsync();\n * \tconst items = yield __unstableAwaitPromise( promise );\n * \t// do something with the items.\n * }\n * ```\n *\n * @return {Object} The control descriptor.\n */\nexport const __unstableAwaitPromise = function < T >( promise: Promise< T > ) {\n\treturn {\n\t\ttype: 'AWAIT_PROMISE',\n\t\tpromise,\n\t};\n};\n\n/**\n * The default export is what you use to register the controls with your custom\n * store.\n *\n * @example\n * ```js\n * // WordPress dependencies\n * import { controls } from '@wordpress/data-controls';\n * import { registerStore } from '@wordpress/data';\n *\n * // Internal dependencies\n * import reducer from './reducer';\n * import * as selectors from './selectors';\n * import * as actions from './actions';\n * import * as resolvers from './resolvers';\n *\n * registerStore( 'my-custom-store', {\n * reducer,\n * controls,\n * actions,\n * selectors,\n * resolvers,\n * } );\n * ```\n * @return {Object} An object for registering the default controls with the\n * store.\n */\nexport const controls = {\n\tAWAIT_PROMISE: < T >( { promise }: { promise: Promise< T > } ) => promise,\n\tAPI_FETCH( { request }: { request: APIFetchOptions } ) {\n\t\treturn triggerFetch( request );\n\t},\n};\n"]}
|
package/build-module/index.js
CHANGED
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
import triggerFetch from '@wordpress/api-fetch';
|
|
5
5
|
import { controls as dataControls } from '@wordpress/data';
|
|
6
6
|
import deprecated from '@wordpress/deprecated';
|
|
7
|
+
|
|
7
8
|
/**
|
|
8
9
|
* Dispatches a control action for triggering an api fetch call.
|
|
9
10
|
*
|
|
@@ -23,7 +24,6 @@ import deprecated from '@wordpress/deprecated';
|
|
|
23
24
|
*
|
|
24
25
|
* @return {Object} The control descriptor.
|
|
25
26
|
*/
|
|
26
|
-
|
|
27
27
|
export function apiFetch(request) {
|
|
28
28
|
return {
|
|
29
29
|
type: 'API_FETCH',
|
|
@@ -34,43 +34,64 @@ export function apiFetch(request) {
|
|
|
34
34
|
* Control for resolving a selector in a registered data store.
|
|
35
35
|
* Alias for the `resolveSelect` built-in control in the `@wordpress/data` package.
|
|
36
36
|
*
|
|
37
|
-
* @param
|
|
37
|
+
* @param storeNameOrDescriptor The store object or identifier.
|
|
38
|
+
* @param selectorName The selector name.
|
|
39
|
+
* @param args Arguments passed without change to the `@wordpress/data` control.
|
|
38
40
|
*/
|
|
39
41
|
|
|
40
|
-
export function select() {
|
|
42
|
+
export function select(storeNameOrDescriptor, selectorName) {
|
|
41
43
|
deprecated('`select` control in `@wordpress/data-controls`', {
|
|
42
44
|
since: '5.7',
|
|
43
45
|
alternative: 'built-in `resolveSelect` control in `@wordpress/data`'
|
|
44
46
|
});
|
|
45
|
-
|
|
47
|
+
|
|
48
|
+
for (var _len = arguments.length, args = new Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) {
|
|
49
|
+
args[_key - 2] = arguments[_key];
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
return dataControls.resolveSelect(storeNameOrDescriptor, selectorName, ...args);
|
|
46
53
|
}
|
|
47
54
|
/**
|
|
48
55
|
* Control for calling a selector in a registered data store.
|
|
49
56
|
* Alias for the `select` built-in control in the `@wordpress/data` package.
|
|
50
57
|
*
|
|
51
|
-
* @param
|
|
58
|
+
* @param storeNameOrDescriptor The store object or identifier.
|
|
59
|
+
* @param selectorName The selector name.
|
|
60
|
+
* @param args Arguments passed without change to the `@wordpress/data` control.
|
|
52
61
|
*/
|
|
53
62
|
|
|
54
|
-
export function syncSelect() {
|
|
63
|
+
export function syncSelect(storeNameOrDescriptor, selectorName) {
|
|
55
64
|
deprecated('`syncSelect` control in `@wordpress/data-controls`', {
|
|
56
65
|
since: '5.7',
|
|
57
66
|
alternative: 'built-in `select` control in `@wordpress/data`'
|
|
58
67
|
});
|
|
59
|
-
|
|
68
|
+
|
|
69
|
+
for (var _len2 = arguments.length, args = new Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) {
|
|
70
|
+
args[_key2 - 2] = arguments[_key2];
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
return dataControls.select(storeNameOrDescriptor, selectorName, ...args);
|
|
60
74
|
}
|
|
61
75
|
/**
|
|
62
76
|
* Control for dispatching an action in a registered data store.
|
|
63
77
|
* Alias for the `dispatch` control in the `@wordpress/data` package.
|
|
64
78
|
*
|
|
65
|
-
* @param
|
|
79
|
+
* @param storeNameOrDescriptor The store object or identifier.
|
|
80
|
+
* @param actionName The action name.
|
|
81
|
+
* @param args Arguments passed without change to the `@wordpress/data` control.
|
|
66
82
|
*/
|
|
67
83
|
|
|
68
|
-
export function dispatch() {
|
|
84
|
+
export function dispatch(storeNameOrDescriptor, actionName) {
|
|
69
85
|
deprecated('`dispatch` control in `@wordpress/data-controls`', {
|
|
70
86
|
since: '5.7',
|
|
71
87
|
alternative: 'built-in `dispatch` control in `@wordpress/data`'
|
|
72
88
|
});
|
|
73
|
-
|
|
89
|
+
|
|
90
|
+
for (var _len3 = arguments.length, args = new Array(_len3 > 2 ? _len3 - 2 : 0), _key3 = 2; _key3 < _len3; _key3++) {
|
|
91
|
+
args[_key3 - 2] = arguments[_key3];
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
return dataControls.dispatch(storeNameOrDescriptor, actionName, ...args);
|
|
74
95
|
}
|
|
75
96
|
/**
|
|
76
97
|
* Dispatches a control action for awaiting on a promise to be resolved.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["@wordpress/data-controls/src/index.
|
|
1
|
+
{"version":3,"sources":["@wordpress/data-controls/src/index.ts"],"names":["triggerFetch","controls","dataControls","deprecated","apiFetch","request","type","select","storeNameOrDescriptor","selectorName","since","alternative","args","resolveSelect","syncSelect","dispatch","actionName","__unstableAwaitPromise","promise","AWAIT_PROMISE","API_FETCH"],"mappings":"AAAA;AACA;AACA;AACA,OAAOA,YAAP,MAAyB,sBAAzB;AACA,SAASC,QAAQ,IAAIC,YAArB,QAAyC,iBAAzC;AACA,OAAOC,UAAP,MAAuB,uBAAvB;;AAIA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,QAAT,CAAmBC,OAAnB,EAA8C;AACpD,SAAO;AACNC,IAAAA,IAAI,EAAE,WADA;AAEND,IAAAA;AAFM,GAAP;AAIA;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AACA,OAAO,SAASE,MAAT,CACNC,qBADM,EAENC,YAFM,EAIL;AACDN,EAAAA,UAAU,CAAE,gDAAF,EAAoD;AAC7DO,IAAAA,KAAK,EAAE,KADsD;AAE7DC,IAAAA,WAAW,EAAE;AAFgD,GAApD,CAAV;;AADC,oCADEC,IACF;AADEA,IAAAA,IACF;AAAA;;AAMD,SAAOV,YAAY,CAACW,aAAb,CACNL,qBADM,EAENC,YAFM,EAGN,GAAGG,IAHG,CAAP;AAKA;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AACA,OAAO,SAASE,UAAT,CACNN,qBADM,EAENC,YAFM,EAIL;AACDN,EAAAA,UAAU,CAAE,oDAAF,EAAwD;AACjEO,IAAAA,KAAK,EAAE,KAD0D;AAEjEC,IAAAA,WAAW,EAAE;AAFoD,GAAxD,CAAV;;AADC,qCADEC,IACF;AADEA,IAAAA,IACF;AAAA;;AAMD,SAAOV,YAAY,CAACK,MAAb,CAAqBC,qBAArB,EAA4CC,YAA5C,EAA0D,GAAGG,IAA7D,CAAP;AACA;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AACA,OAAO,SAASG,QAAT,CACNP,qBADM,EAENQ,UAFM,EAIL;AACDb,EAAAA,UAAU,CAAE,kDAAF,EAAsD;AAC/DO,IAAAA,KAAK,EAAE,KADwD;AAE/DC,IAAAA,WAAW,EAAE;AAFkD,GAAtD,CAAV;;AADC,qCADEC,IACF;AADEA,IAAAA,IACF;AAAA;;AAMD,SAAOV,YAAY,CAACa,QAAb,CAAuBP,qBAAvB,EAA8CQ,UAA9C,EAA0D,GAAGJ,IAA7D,CAAP;AACA;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AACA,OAAO,MAAMK,sBAAsB,GAAG,UAAgBC,OAAhB,EAAwC;AAC7E,SAAO;AACNZ,IAAAA,IAAI,EAAE,eADA;AAENY,IAAAA;AAFM,GAAP;AAIA,CALM;AAOP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AACA,OAAO,MAAMjB,QAAQ,GAAG;AACvBkB,EAAAA,aAAa,EAAE;AAAA,QAAO;AAAED,MAAAA;AAAF,KAAP;AAAA,WAAmDA,OAAnD;AAAA,GADQ;;AAEvBE,EAAAA,SAAS,QAA8C;AAAA,QAA5C;AAAEf,MAAAA;AAAF,KAA4C;AACtD,WAAOL,YAAY,CAAEK,OAAF,CAAnB;AACA;;AAJsB,CAAjB","sourcesContent":["/**\n * WordPress dependencies\n */\nimport triggerFetch from '@wordpress/api-fetch';\nimport { controls as dataControls } from '@wordpress/data';\nimport deprecated from '@wordpress/deprecated';\nimport type { StoreDescriptor } from '@wordpress/data';\nimport type { APIFetchOptions } from '@wordpress/api-fetch';\n\n/**\n * Dispatches a control action for triggering an api fetch call.\n *\n * @param {Object} request Arguments for the fetch request.\n *\n * @example\n * ```js\n * import { apiFetch } from '@wordpress/data-controls';\n *\n * // Action generator using apiFetch\n * export function* myAction() {\n * \tconst path = '/v2/my-api/items';\n * \tconst items = yield apiFetch( { path } );\n * \t// do something with the items.\n * }\n * ```\n *\n * @return {Object} The control descriptor.\n */\nexport function apiFetch( request: APIFetchOptions ) {\n\treturn {\n\t\ttype: 'API_FETCH',\n\t\trequest,\n\t};\n}\n\n/**\n * Control for resolving a selector in a registered data store.\n * Alias for the `resolveSelect` built-in control in the `@wordpress/data` package.\n *\n * @param storeNameOrDescriptor The store object or identifier.\n * @param selectorName The selector name.\n * @param args Arguments passed without change to the `@wordpress/data` control.\n */\nexport function select(\n\tstoreNameOrDescriptor: string | StoreDescriptor,\n\tselectorName: string,\n\t...args: any[]\n) {\n\tdeprecated( '`select` control in `@wordpress/data-controls`', {\n\t\tsince: '5.7',\n\t\talternative: 'built-in `resolveSelect` control in `@wordpress/data`',\n\t} );\n\n\treturn dataControls.resolveSelect(\n\t\tstoreNameOrDescriptor,\n\t\tselectorName,\n\t\t...args\n\t);\n}\n\n/**\n * Control for calling a selector in a registered data store.\n * Alias for the `select` built-in control in the `@wordpress/data` package.\n *\n * @param storeNameOrDescriptor The store object or identifier.\n * @param selectorName The selector name.\n * @param args Arguments passed without change to the `@wordpress/data` control.\n */\nexport function syncSelect(\n\tstoreNameOrDescriptor: string | StoreDescriptor,\n\tselectorName: string,\n\t...args: any[]\n) {\n\tdeprecated( '`syncSelect` control in `@wordpress/data-controls`', {\n\t\tsince: '5.7',\n\t\talternative: 'built-in `select` control in `@wordpress/data`',\n\t} );\n\n\treturn dataControls.select( storeNameOrDescriptor, selectorName, ...args );\n}\n\n/**\n * Control for dispatching an action in a registered data store.\n * Alias for the `dispatch` control in the `@wordpress/data` package.\n *\n * @param storeNameOrDescriptor The store object or identifier.\n * @param actionName The action name.\n * @param args Arguments passed without change to the `@wordpress/data` control.\n */\nexport function dispatch(\n\tstoreNameOrDescriptor: string | StoreDescriptor,\n\tactionName: string,\n\t...args: any[]\n) {\n\tdeprecated( '`dispatch` control in `@wordpress/data-controls`', {\n\t\tsince: '5.7',\n\t\talternative: 'built-in `dispatch` control in `@wordpress/data`',\n\t} );\n\n\treturn dataControls.dispatch( storeNameOrDescriptor, actionName, ...args );\n}\n\n/**\n * Dispatches a control action for awaiting on a promise to be resolved.\n *\n * @param {Object} promise Promise to wait for.\n *\n * @example\n * ```js\n * import { __unstableAwaitPromise } from '@wordpress/data-controls';\n *\n * // Action generator using apiFetch\n * export function* myAction() {\n * \tconst promise = getItemsAsync();\n * \tconst items = yield __unstableAwaitPromise( promise );\n * \t// do something with the items.\n * }\n * ```\n *\n * @return {Object} The control descriptor.\n */\nexport const __unstableAwaitPromise = function < T >( promise: Promise< T > ) {\n\treturn {\n\t\ttype: 'AWAIT_PROMISE',\n\t\tpromise,\n\t};\n};\n\n/**\n * The default export is what you use to register the controls with your custom\n * store.\n *\n * @example\n * ```js\n * // WordPress dependencies\n * import { controls } from '@wordpress/data-controls';\n * import { registerStore } from '@wordpress/data';\n *\n * // Internal dependencies\n * import reducer from './reducer';\n * import * as selectors from './selectors';\n * import * as actions from './actions';\n * import * as resolvers from './resolvers';\n *\n * registerStore( 'my-custom-store', {\n * reducer,\n * controls,\n * actions,\n * selectors,\n * resolvers,\n * } );\n * ```\n * @return {Object} An object for registering the default controls with the\n * store.\n */\nexport const controls = {\n\tAWAIT_PROMISE: < T >( { promise }: { promise: Promise< T > } ) => promise,\n\tAPI_FETCH( { request }: { request: APIFetchOptions } ) {\n\t\treturn triggerFetch( request );\n\t},\n};\n"]}
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
import type { StoreDescriptor } from '@wordpress/data';
|
|
2
|
+
import type { APIFetchOptions } from '@wordpress/api-fetch';
|
|
3
|
+
/**
|
|
4
|
+
* Dispatches a control action for triggering an api fetch call.
|
|
5
|
+
*
|
|
6
|
+
* @param {Object} request Arguments for the fetch request.
|
|
7
|
+
*
|
|
8
|
+
* @example
|
|
9
|
+
* ```js
|
|
10
|
+
* import { apiFetch } from '@wordpress/data-controls';
|
|
11
|
+
*
|
|
12
|
+
* // Action generator using apiFetch
|
|
13
|
+
* export function* myAction() {
|
|
14
|
+
* const path = '/v2/my-api/items';
|
|
15
|
+
* const items = yield apiFetch( { path } );
|
|
16
|
+
* // do something with the items.
|
|
17
|
+
* }
|
|
18
|
+
* ```
|
|
19
|
+
*
|
|
20
|
+
* @return {Object} The control descriptor.
|
|
21
|
+
*/
|
|
22
|
+
export declare function apiFetch(request: APIFetchOptions): {
|
|
23
|
+
type: string;
|
|
24
|
+
request: import("@wordpress/api-fetch/build-types/types").APIFetchOptions;
|
|
25
|
+
};
|
|
26
|
+
/**
|
|
27
|
+
* Control for resolving a selector in a registered data store.
|
|
28
|
+
* Alias for the `resolveSelect` built-in control in the `@wordpress/data` package.
|
|
29
|
+
*
|
|
30
|
+
* @param storeNameOrDescriptor The store object or identifier.
|
|
31
|
+
* @param selectorName The selector name.
|
|
32
|
+
* @param args Arguments passed without change to the `@wordpress/data` control.
|
|
33
|
+
*/
|
|
34
|
+
export declare function select(storeNameOrDescriptor: string | StoreDescriptor, selectorName: string, ...args: any[]): Object;
|
|
35
|
+
/**
|
|
36
|
+
* Control for calling a selector in a registered data store.
|
|
37
|
+
* Alias for the `select` built-in control in the `@wordpress/data` package.
|
|
38
|
+
*
|
|
39
|
+
* @param storeNameOrDescriptor The store object or identifier.
|
|
40
|
+
* @param selectorName The selector name.
|
|
41
|
+
* @param args Arguments passed without change to the `@wordpress/data` control.
|
|
42
|
+
*/
|
|
43
|
+
export declare function syncSelect(storeNameOrDescriptor: string | StoreDescriptor, selectorName: string, ...args: any[]): Object;
|
|
44
|
+
/**
|
|
45
|
+
* Control for dispatching an action in a registered data store.
|
|
46
|
+
* Alias for the `dispatch` control in the `@wordpress/data` package.
|
|
47
|
+
*
|
|
48
|
+
* @param storeNameOrDescriptor The store object or identifier.
|
|
49
|
+
* @param actionName The action name.
|
|
50
|
+
* @param args Arguments passed without change to the `@wordpress/data` control.
|
|
51
|
+
*/
|
|
52
|
+
export declare function dispatch(storeNameOrDescriptor: string | StoreDescriptor, actionName: string, ...args: any[]): Object;
|
|
53
|
+
/**
|
|
54
|
+
* Dispatches a control action for awaiting on a promise to be resolved.
|
|
55
|
+
*
|
|
56
|
+
* @param {Object} promise Promise to wait for.
|
|
57
|
+
*
|
|
58
|
+
* @example
|
|
59
|
+
* ```js
|
|
60
|
+
* import { __unstableAwaitPromise } from '@wordpress/data-controls';
|
|
61
|
+
*
|
|
62
|
+
* // Action generator using apiFetch
|
|
63
|
+
* export function* myAction() {
|
|
64
|
+
* const promise = getItemsAsync();
|
|
65
|
+
* const items = yield __unstableAwaitPromise( promise );
|
|
66
|
+
* // do something with the items.
|
|
67
|
+
* }
|
|
68
|
+
* ```
|
|
69
|
+
*
|
|
70
|
+
* @return {Object} The control descriptor.
|
|
71
|
+
*/
|
|
72
|
+
export declare const __unstableAwaitPromise: <T>(promise: Promise<T>) => {
|
|
73
|
+
type: string;
|
|
74
|
+
promise: Promise<T>;
|
|
75
|
+
};
|
|
76
|
+
/**
|
|
77
|
+
* The default export is what you use to register the controls with your custom
|
|
78
|
+
* store.
|
|
79
|
+
*
|
|
80
|
+
* @example
|
|
81
|
+
* ```js
|
|
82
|
+
* // WordPress dependencies
|
|
83
|
+
* import { controls } from '@wordpress/data-controls';
|
|
84
|
+
* import { registerStore } from '@wordpress/data';
|
|
85
|
+
*
|
|
86
|
+
* // Internal dependencies
|
|
87
|
+
* import reducer from './reducer';
|
|
88
|
+
* import * as selectors from './selectors';
|
|
89
|
+
* import * as actions from './actions';
|
|
90
|
+
* import * as resolvers from './resolvers';
|
|
91
|
+
*
|
|
92
|
+
* registerStore( 'my-custom-store', {
|
|
93
|
+
* reducer,
|
|
94
|
+
* controls,
|
|
95
|
+
* actions,
|
|
96
|
+
* selectors,
|
|
97
|
+
* resolvers,
|
|
98
|
+
* } );
|
|
99
|
+
* ```
|
|
100
|
+
* @return {Object} An object for registering the default controls with the
|
|
101
|
+
* store.
|
|
102
|
+
*/
|
|
103
|
+
export declare const controls: {
|
|
104
|
+
AWAIT_PROMISE: <T>({ promise }: {
|
|
105
|
+
promise: Promise<T>;
|
|
106
|
+
}) => Promise<T>;
|
|
107
|
+
API_FETCH({ request }: {
|
|
108
|
+
request: APIFetchOptions;
|
|
109
|
+
}): Promise<unknown>;
|
|
110
|
+
};
|
|
111
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAC;AACvD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAE5D;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,QAAQ,CAAE,OAAO,EAAE,eAAe;;;EAKjD;AAED;;;;;;;GAOG;AACH,wBAAgB,MAAM,CACrB,qBAAqB,EAAE,MAAM,GAAG,eAAe,EAC/C,YAAY,EAAE,MAAM,EACpB,GAAG,IAAI,EAAE,GAAG,EAAE,UAYd;AAED;;;;;;;GAOG;AACH,wBAAgB,UAAU,CACzB,qBAAqB,EAAE,MAAM,GAAG,eAAe,EAC/C,YAAY,EAAE,MAAM,EACpB,GAAG,IAAI,EAAE,GAAG,EAAE,UAQd;AAED;;;;;;;GAOG;AACH,wBAAgB,QAAQ,CACvB,qBAAqB,EAAE,MAAM,GAAG,eAAe,EAC/C,UAAU,EAAE,MAAM,EAClB,GAAG,IAAI,EAAE,GAAG,EAAE,UAQd;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,sBAAsB;;;CAKlC,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,eAAO,MAAM,QAAQ;;;;;iBAEe,eAAe;;CAGlD,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wordpress/data-controls",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.1.0",
|
|
4
4
|
"description": "A set of common controls for the @wordpress/data api.",
|
|
5
5
|
"author": "The WordPress Contributors",
|
|
6
6
|
"license": "GPL-2.0-or-later",
|
|
@@ -25,14 +25,15 @@
|
|
|
25
25
|
"main": "build/index.js",
|
|
26
26
|
"module": "build-module/index.js",
|
|
27
27
|
"react-native": "src/index",
|
|
28
|
+
"types": "build-types",
|
|
28
29
|
"dependencies": {
|
|
29
30
|
"@babel/runtime": "^7.16.0",
|
|
30
|
-
"@wordpress/api-fetch": "^6.
|
|
31
|
-
"@wordpress/data": "^9.
|
|
32
|
-
"@wordpress/deprecated": "^3.
|
|
31
|
+
"@wordpress/api-fetch": "^6.29.0",
|
|
32
|
+
"@wordpress/data": "^9.2.0",
|
|
33
|
+
"@wordpress/deprecated": "^3.32.0"
|
|
33
34
|
},
|
|
34
35
|
"publishConfig": {
|
|
35
36
|
"access": "public"
|
|
36
37
|
},
|
|
37
|
-
"gitHead": "
|
|
38
|
+
"gitHead": "6df0c62d43b8901414ccd22ffbe56eaa99d012a6"
|
|
38
39
|
}
|
|
@@ -4,6 +4,8 @@
|
|
|
4
4
|
import triggerFetch from '@wordpress/api-fetch';
|
|
5
5
|
import { controls as dataControls } from '@wordpress/data';
|
|
6
6
|
import deprecated from '@wordpress/deprecated';
|
|
7
|
+
import type { StoreDescriptor } from '@wordpress/data';
|
|
8
|
+
import type { APIFetchOptions } from '@wordpress/api-fetch';
|
|
7
9
|
|
|
8
10
|
/**
|
|
9
11
|
* Dispatches a control action for triggering an api fetch call.
|
|
@@ -24,7 +26,7 @@ import deprecated from '@wordpress/deprecated';
|
|
|
24
26
|
*
|
|
25
27
|
* @return {Object} The control descriptor.
|
|
26
28
|
*/
|
|
27
|
-
export function apiFetch( request ) {
|
|
29
|
+
export function apiFetch( request: APIFetchOptions ) {
|
|
28
30
|
return {
|
|
29
31
|
type: 'API_FETCH',
|
|
30
32
|
request,
|
|
@@ -35,45 +37,67 @@ export function apiFetch( request ) {
|
|
|
35
37
|
* Control for resolving a selector in a registered data store.
|
|
36
38
|
* Alias for the `resolveSelect` built-in control in the `@wordpress/data` package.
|
|
37
39
|
*
|
|
38
|
-
* @param
|
|
40
|
+
* @param storeNameOrDescriptor The store object or identifier.
|
|
41
|
+
* @param selectorName The selector name.
|
|
42
|
+
* @param args Arguments passed without change to the `@wordpress/data` control.
|
|
39
43
|
*/
|
|
40
|
-
export function select(
|
|
44
|
+
export function select(
|
|
45
|
+
storeNameOrDescriptor: string | StoreDescriptor,
|
|
46
|
+
selectorName: string,
|
|
47
|
+
...args: any[]
|
|
48
|
+
) {
|
|
41
49
|
deprecated( '`select` control in `@wordpress/data-controls`', {
|
|
42
50
|
since: '5.7',
|
|
43
51
|
alternative: 'built-in `resolveSelect` control in `@wordpress/data`',
|
|
44
52
|
} );
|
|
45
53
|
|
|
46
|
-
return dataControls.resolveSelect(
|
|
54
|
+
return dataControls.resolveSelect(
|
|
55
|
+
storeNameOrDescriptor,
|
|
56
|
+
selectorName,
|
|
57
|
+
...args
|
|
58
|
+
);
|
|
47
59
|
}
|
|
48
60
|
|
|
49
61
|
/**
|
|
50
62
|
* Control for calling a selector in a registered data store.
|
|
51
63
|
* Alias for the `select` built-in control in the `@wordpress/data` package.
|
|
52
64
|
*
|
|
53
|
-
* @param
|
|
65
|
+
* @param storeNameOrDescriptor The store object or identifier.
|
|
66
|
+
* @param selectorName The selector name.
|
|
67
|
+
* @param args Arguments passed without change to the `@wordpress/data` control.
|
|
54
68
|
*/
|
|
55
|
-
export function syncSelect(
|
|
69
|
+
export function syncSelect(
|
|
70
|
+
storeNameOrDescriptor: string | StoreDescriptor,
|
|
71
|
+
selectorName: string,
|
|
72
|
+
...args: any[]
|
|
73
|
+
) {
|
|
56
74
|
deprecated( '`syncSelect` control in `@wordpress/data-controls`', {
|
|
57
75
|
since: '5.7',
|
|
58
76
|
alternative: 'built-in `select` control in `@wordpress/data`',
|
|
59
77
|
} );
|
|
60
78
|
|
|
61
|
-
return dataControls.select( ...args );
|
|
79
|
+
return dataControls.select( storeNameOrDescriptor, selectorName, ...args );
|
|
62
80
|
}
|
|
63
81
|
|
|
64
82
|
/**
|
|
65
83
|
* Control for dispatching an action in a registered data store.
|
|
66
84
|
* Alias for the `dispatch` control in the `@wordpress/data` package.
|
|
67
85
|
*
|
|
68
|
-
* @param
|
|
86
|
+
* @param storeNameOrDescriptor The store object or identifier.
|
|
87
|
+
* @param actionName The action name.
|
|
88
|
+
* @param args Arguments passed without change to the `@wordpress/data` control.
|
|
69
89
|
*/
|
|
70
|
-
export function dispatch(
|
|
90
|
+
export function dispatch(
|
|
91
|
+
storeNameOrDescriptor: string | StoreDescriptor,
|
|
92
|
+
actionName: string,
|
|
93
|
+
...args: any[]
|
|
94
|
+
) {
|
|
71
95
|
deprecated( '`dispatch` control in `@wordpress/data-controls`', {
|
|
72
96
|
since: '5.7',
|
|
73
97
|
alternative: 'built-in `dispatch` control in `@wordpress/data`',
|
|
74
98
|
} );
|
|
75
99
|
|
|
76
|
-
return dataControls.dispatch( ...args );
|
|
100
|
+
return dataControls.dispatch( storeNameOrDescriptor, actionName, ...args );
|
|
77
101
|
}
|
|
78
102
|
|
|
79
103
|
/**
|
|
@@ -95,7 +119,7 @@ export function dispatch( ...args ) {
|
|
|
95
119
|
*
|
|
96
120
|
* @return {Object} The control descriptor.
|
|
97
121
|
*/
|
|
98
|
-
export const __unstableAwaitPromise = function ( promise ) {
|
|
122
|
+
export const __unstableAwaitPromise = function < T >( promise: Promise< T > ) {
|
|
99
123
|
return {
|
|
100
124
|
type: 'AWAIT_PROMISE',
|
|
101
125
|
promise,
|
|
@@ -130,8 +154,8 @@ export const __unstableAwaitPromise = function ( promise ) {
|
|
|
130
154
|
* store.
|
|
131
155
|
*/
|
|
132
156
|
export const controls = {
|
|
133
|
-
AWAIT_PROMISE: ( { promise } ) => promise,
|
|
134
|
-
API_FETCH( { request } ) {
|
|
157
|
+
AWAIT_PROMISE: < T >( { promise }: { promise: Promise< T > } ) => promise,
|
|
158
|
+
API_FETCH( { request }: { request: APIFetchOptions } ) {
|
|
135
159
|
return triggerFetch( request );
|
|
136
160
|
},
|
|
137
161
|
};
|
package/tsconfig.json
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
{
|
|
2
|
+
"extends": "../../tsconfig.base.json",
|
|
3
|
+
"compilerOptions": {
|
|
4
|
+
"rootDir": "src",
|
|
5
|
+
"declarationDir": "build-types",
|
|
6
|
+
"types": [ "gutenberg-env" ]
|
|
7
|
+
},
|
|
8
|
+
"references": [
|
|
9
|
+
{ "path": "../api-fetch" },
|
|
10
|
+
{ "path": "../data" },
|
|
11
|
+
{ "path": "../deprecated" }
|
|
12
|
+
],
|
|
13
|
+
"include": [ "src/**/*" ]
|
|
14
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"program":{"fileNames":["../../node_modules/typescript/lib/lib.es5.d.ts","../../node_modules/typescript/lib/lib.es2015.d.ts","../../node_modules/typescript/lib/lib.es2016.d.ts","../../node_modules/typescript/lib/lib.es2017.d.ts","../../node_modules/typescript/lib/lib.es2018.d.ts","../../node_modules/typescript/lib/lib.es2019.d.ts","../../node_modules/typescript/lib/lib.es2020.d.ts","../../node_modules/typescript/lib/lib.es2021.d.ts","../../node_modules/typescript/lib/lib.es2022.d.ts","../../node_modules/typescript/lib/lib.esnext.d.ts","../../node_modules/typescript/lib/lib.dom.d.ts","../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../node_modules/typescript/lib/lib.es2019.array.d.ts","../../node_modules/typescript/lib/lib.es2019.object.d.ts","../../node_modules/typescript/lib/lib.es2019.string.d.ts","../../node_modules/typescript/lib/lib.es2019.symbol.d.ts","../../node_modules/typescript/lib/lib.es2019.intl.d.ts","../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../node_modules/typescript/lib/lib.es2020.date.d.ts","../../node_modules/typescript/lib/lib.es2020.promise.d.ts","../../node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../../node_modules/typescript/lib/lib.es2020.string.d.ts","../../node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../../node_modules/typescript/lib/lib.es2020.intl.d.ts","../../node_modules/typescript/lib/lib.es2020.number.d.ts","../../node_modules/typescript/lib/lib.es2021.promise.d.ts","../../node_modules/typescript/lib/lib.es2021.string.d.ts","../../node_modules/typescript/lib/lib.es2021.weakref.d.ts","../../node_modules/typescript/lib/lib.es2021.intl.d.ts","../../node_modules/typescript/lib/lib.es2022.array.d.ts","../../node_modules/typescript/lib/lib.es2022.error.d.ts","../../node_modules/typescript/lib/lib.es2022.intl.d.ts","../../node_modules/typescript/lib/lib.es2022.object.d.ts","../../node_modules/typescript/lib/lib.es2022.sharedmemory.d.ts","../../node_modules/typescript/lib/lib.es2022.string.d.ts","../../node_modules/typescript/lib/lib.esnext.intl.d.ts","../api-fetch/build-types/types.d.ts","../api-fetch/build-types/middlewares/nonce.d.ts","../api-fetch/build-types/middlewares/preloading.d.ts","../api-fetch/build-types/middlewares/root-url.d.ts","../api-fetch/build-types/middlewares/fetch-all-middleware.d.ts","../api-fetch/build-types/middlewares/media-upload.d.ts","../api-fetch/build-types/index.d.ts","../element/node_modules/@types/react/global.d.ts","../../node_modules/csstype/index.d.ts","../../node_modules/@types/prop-types/index.d.ts","../../node_modules/@types/scheduler/tracing.d.ts","../element/node_modules/@types/react/index.d.ts","../element/build-types/react.d.ts","../element/build-types/create-interpolate-element.d.ts","../../node_modules/@types/react/index.d.ts","../../node_modules/@types/react-dom/index.d.ts","../../node_modules/@types/react-dom/client.d.ts","../element/build-types/react-platform.d.ts","../element/build-types/utils.d.ts","../element/build-types/platform.d.ts","../element/build-types/serialize.d.ts","../element/build-types/raw-html.d.ts","../element/build-types/index.d.ts","../data/build-types/components/with-select/index.d.ts","../data/build-types/components/with-dispatch/index.d.ts","../data/build-types/components/with-registry/index.d.ts","../../node_modules/redux/index.d.ts","../data/build-types/types.d.ts","../data/build-types/components/use-dispatch/use-dispatch.d.ts","../data/build-types/components/use-dispatch/use-dispatch-with-map.d.ts","../data/build-types/components/use-dispatch/index.d.ts","../data/build-types/components/async-mode-provider/use-async-mode.d.ts","../data/build-types/components/async-mode-provider/context.d.ts","../data/build-types/components/async-mode-provider/index.d.ts","../data/build-types/registry.d.ts","../data/build-types/controls.d.ts","../data/build-types/redux-store/index.d.ts","../data/build-types/plugins/persistence/index.d.ts","../data/build-types/plugins/index.d.ts","../data/build-types/components/registry-provider/use-registry.d.ts","../data/build-types/components/registry-provider/context.d.ts","../data/build-types/components/registry-provider/index.d.ts","../data/build-types/components/use-select/index.d.ts","../data/build-types/factory.d.ts","../data/build-types/index.d.ts","../../node_modules/utility-types/dist/aliases-and-guards.d.ts","../../node_modules/utility-types/dist/mapped-types.d.ts","../../node_modules/utility-types/dist/utility-types.d.ts","../../node_modules/utility-types/dist/functional-helpers.d.ts","../../node_modules/utility-types/dist/index.d.ts","../deprecated/build-types/index.d.ts","./src/index.ts","../../typings/gutenberg-env/index.d.ts","../../node_modules/@types/react/global.d.ts"],"fileInfos":[{"version":"8730f4bf322026ff5229336391a18bcaa1f94d4f82416c8b2f3954e2ccaae2ba","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06","4b421cbfb3a38a27c279dec1e9112c3d1da296f77a1a85ddadf7e7a425d45d18","1fc5ab7a764205c68fa10d381b08417795fc73111d6dd16b5b1ed36badb743d9","746d62152361558ea6d6115cf0da4dd10ede041d14882ede3568bce5dc4b4f1f","d11a03592451da2d1065e09e61f4e2a9bf68f780f4f6623c18b57816a9679d17","aea179452def8a6152f98f63b191b84e7cbd69b0e248c91e61fb2e52328abe8c",{"version":"3aafcb693fe5b5c3bd277bd4c3a617b53db474fe498fc5df067c5603b1eebde7","affectsGlobalScope":true},{"version":"adb996790133eb33b33aadb9c09f15c2c575e71fb57a62de8bf74dbf59ec7dfb","affectsGlobalScope":true},{"version":"8cc8c5a3bac513368b0157f3d8b31cfdcfe78b56d3724f30f80ed9715e404af8","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"c5c05907c02476e4bde6b7e76a79ffcd948aedd14b6a8f56e4674221b0417398","affectsGlobalScope":true},{"version":"5f406584aef28a331c36523df688ca3650288d14f39c5d2e555c95f0d2ff8f6f","affectsGlobalScope":true},{"version":"22f230e544b35349cfb3bd9110b6ef37b41c6d6c43c3314a31bd0d9652fcec72","affectsGlobalScope":true},{"version":"7ea0b55f6b315cf9ac2ad622b0a7813315bb6e97bf4bb3fbf8f8affbca7dc695","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"eb26de841c52236d8222f87e9e6a235332e0788af8c87a71e9e210314300410a","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"81cac4cbc92c0c839c70f8ffb94eb61e2d32dc1c3cf6d95844ca099463cf37ea","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"d154ea5bb7f7f9001ed9153e876b2d5b8f5c2bb9ec02b3ae0d239ec769f1f2ae","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"9d57b2b5d15838ed094aa9ff1299eecef40b190722eb619bac4616657a05f951","affectsGlobalScope":true},{"version":"6c51b5dd26a2c31dbf37f00cfc32b2aa6a92e19c995aefb5b97a3a64f1ac99de","affectsGlobalScope":true},{"version":"6e7997ef61de3132e4d4b2250e75343f487903ddf5370e7ce33cf1b9db9a63ed","affectsGlobalScope":true},{"version":"2ad234885a4240522efccd77de6c7d99eecf9b4de0914adb9a35c0c22433f993","affectsGlobalScope":true},{"version":"5e5e095c4470c8bab227dbbc61374878ecead104c74ab9960d3adcccfee23205","affectsGlobalScope":true},{"version":"09aa50414b80c023553090e2f53827f007a301bc34b0495bfb2c3c08ab9ad1eb","affectsGlobalScope":true},{"version":"d7f680a43f8cd12a6b6122c07c54ba40952b0c8aa140dcfcf32eb9e6cb028596","affectsGlobalScope":true},{"version":"3787b83e297de7c315d55d4a7c546ae28e5f6c0a361b7a1dcec1f1f50a54ef11","affectsGlobalScope":true},{"version":"e7e8e1d368290e9295ef18ca23f405cf40d5456fa9f20db6373a61ca45f75f40","affectsGlobalScope":true},{"version":"faf0221ae0465363c842ce6aa8a0cbda5d9296940a8e26c86e04cc4081eea21e","affectsGlobalScope":true},{"version":"06393d13ea207a1bfe08ec8d7be562549c5e2da8983f2ee074e00002629d1871","affectsGlobalScope":true},{"version":"2768ef564cfc0689a1b76106c421a2909bdff0acbe87da010785adab80efdd5c","affectsGlobalScope":true},{"version":"b248e32ca52e8f5571390a4142558ae4f203ae2f94d5bac38a3084d529ef4e58","affectsGlobalScope":true},{"version":"6c55633c733c8378db65ac3da7a767c3cf2cf3057f0565a9124a16a3a2019e87","affectsGlobalScope":true},{"version":"fb4416144c1bf0323ccbc9afb0ab289c07312214e8820ad17d709498c865a3fe","affectsGlobalScope":true},{"version":"5b0ca94ec819d68d33da516306c15297acec88efeb0ae9e2b39f71dbd9685ef7","affectsGlobalScope":true},{"version":"34c839eaaa6d78c8674ae2c37af2236dee6831b13db7b4ef4df3ec889a04d4f2","affectsGlobalScope":true},{"version":"34478567f8a80171f88f2f30808beb7da15eac0538ae91282dd33dce928d98ed","affectsGlobalScope":true},{"version":"ab7d58e6161a550ff92e5aff755dc37fe896245348332cd5f1e1203479fe0ed1","affectsGlobalScope":true},{"version":"6bda95ea27a59a276e46043b7065b55bd4b316c25e70e29b572958fa77565d43","affectsGlobalScope":true},{"version":"aedb8de1abb2ff1095c153854a6df7deae4a5709c37297f9d6e9948b6806fa66","affectsGlobalScope":true},{"version":"a4da0551fd39b90ca7ce5f68fb55d4dc0c1396d589b612e1902f68ee090aaada","affectsGlobalScope":true},{"version":"11ffe3c281f375fff9ffdde8bbec7669b4dd671905509079f866f2354a788064","affectsGlobalScope":true},{"version":"52d1bb7ab7a3306fd0375c8bff560feed26ed676a5b0457fa8027b563aecb9a4","affectsGlobalScope":true},"c590af0064d3c4c10981a9d7b8033083e101e809bcd6677bbcad7592c18aaf85","6b3d3ecbf6958624910af080a873cd84b5b99d513eb52147f18fe04a51cb19ce","ea9b95f45cd90b16200134d1f79e36380d57b866300b479b3e5b62a6dbeb92bb","14bc80bd2cb4c72aaaf27cfcdb62377cf3e3366f9e9045fa8ca232629457aca9","ff164c4671955c882140da80d0a6a69552ba5c2ddce3969f74c5c9d63683744b","dca26c859f7b4b8cf118dc9b5e99d295a3031bbd980e488819ed830ba769b890","1152220b82b14ecd456908cf61b6089b49596278eace0d10030384f8e31ba5ee",{"version":"bbdf156fea2fabed31a569445835aeedcc33643d404fcbaa54541f06c109df3f","affectsGlobalScope":true},"381899b8d1d4c1be716f18cb5242ba39f66f4b1e31d45af62a32a99f8edcb39d","f7b46d22a307739c145e5fddf537818038fdfffd580d79ed717f4d4d37249380","f5a8b384f182b3851cec3596ccc96cb7464f8d3469f48c74bf2befb782a19de5",{"version":"5917af4ff931b050dba49a1dedd9c00f15f7b3dc4345ad8491bfacd2ec68ed32","affectsGlobalScope":true},"6fb72c65c5af8c4ed7d41afecd1ebb463d1e074291ae5e8a187d0922fd40f59b","ab6f9c23c44e0b20c2be80af46ffc9d0e6681efa05ee1704bb4c9fcef8e61497",{"version":"5917af4ff931b050dba49a1dedd9c00f15f7b3dc4345ad8491bfacd2ec68ed32","affectsGlobalScope":true},"e4dd91dd4789a109aab51d8a0569a282369fcda9ba6f2b2297bc61bacfb1a042","83e27bbd7304ea67f9afa1535f1d4fdb15866089f0d893c784cbb5b1c6fb3386","c4b39848e2fb237507a7acae0b83a34271c9d72714faae6a6b9075527205111b","d2d9e98a2b167079474768593e1e7125fc3db055add8fbdb5977e3d05a8a3696","6462da67490105ba7d98cf312c2faf8794c425781128b161ea8394d66502eec8","62359da52b6c8d00c50c2e50738fac82e902f916fdf458d8159e7edb1c60c3a8","1e0ac21bc775686383ea8c8e48bd98b385e6195b25c85525a7affd08a2cd38b9","0449615e1ed03c7d54fc435a63b7ef0cb4e5cea5ac40c9a63280a46f7eeae0ff","f647358d9c48f01ca886cf4e022a31cbc9f84a5706cd85df656b0b8e3ec118eb","3e04bd7b52acb9c393909520bc6bf74989ed3cb8cee63c9ae88e20467a8f02d9","a958d081d81c1194d1878b28f081d0144d95f4e36c6b375e357cb982e8b40705",{"version":"8f19251323456195ec9236df857bac3b8f97b73b540ef06ead2ceccc3884954f","affectsGlobalScope":true},"161ae38e8fa5c0a1a8002eceba810f99734edd08493c15bdd0c0e3034ea13606","e3e12de1cc9a3f289b1ea267336edf625260cdaa50a3dbb33b61fc58e5a792c7","d23aeb9ad9955d3b6df7a972355dd465aaa0f7b8c223834f9499585b75f2ab04","cf000108177216c2ffd9962c785dfe0eb36306b14817894115be2d8f470552d6","61937532d01a86bc9f9847e016305cec9b5a716db5a630a0c37049a477d18f60","c792ecb733fc79337b7b497d3298dc31217f0f2b944ade255037dea871915353","61e8a34952f23c48deff3e85e982b1b3a600d15fb4d3b7c07a9096505ad2c35c","4fe57f4d9ea10f6069813ca18818838ce21258f42e79f898b4fb7860ce0c58ca","1e525db7ea2d7369211b74756f1034e4219134c3c99c0e147998caf43b10e017","e11c156803f0c4423e71cafc494033b48f1493b411acd77e50a769d551dafb7e","d2c8976d6e6874ce159fc31c8511fffde72dcdf230394750ea4ef3c02a32e52e","fb6fa5434ecf7670f3dba36bced663afe875282d1231fb3ae95eeedae85ce4cf","e4cb6f9e4d40f538e26c72cc81ebd8ebae3317f940f39696e30d1381f36e5a0a","30289252a73fce7ff4b88369c829ed1f8533ccc028c55b264fc96fb576ffdd6a","3f473bb1c974b627227610013561332ea2f8e6eed0e86e87eaef96b6146d28c8","ce5bdb993fed19ff6f8a7a9ae3dd2fbe650c45c6552e7fe33e24bc4c51363b81","c8bd10b6cdcb527ce859b9c5b4b6168f270cec11cb051cc77eb4dead206b5e0f","24539d95c2bac8f3cf5a4375089230403743faea1460c8c58dd1a5ccaeca3d32","bd0d80db12ef1aceefc4f9d3eb88517b9634fa747ae8475981da8655292feab8","55e68fb1618e3f55f7866b8c8415152159309a14b716370081ab0b7af96d876e","bf0491af2455f92282b61807be2be6e7ad7d532e47fac7b698019d3617c28ff7","5d874fb879ab8601c02549817dceb2d0a30729cb7e161625dd6f819bbff1ec0b","ee551a880882770c4f56a0964a9767c9feafe497a5be52652527d098c88d85cb","b192606574769a5566620f9bf19358a3994bc2726ecdeaad9c66f3333b2687c8",{"version":"553d27e36429fa444b363f856554c1b1dc5c2b5a604ae8f158f66f27956603ea","signature":"5a54cf53c8232c1f12a0f7f65c7777b6b068bf19267b845e8683c52de3e05d65"},{"version":"084d8b571b1e8b984824263889aabc2c37d29b49f7cbab3e4ebd05e4c02891eb","affectsGlobalScope":true}],"options":{"allowSyntheticDefaultImports":true,"composite":true,"declaration":true,"declarationDir":"./build-types","declarationMap":true,"emitDeclarationOnly":true,"esModuleInterop":false,"importsNotUsedAsValues":2,"jsx":1,"module":99,"noFallthroughCasesInSwitch":true,"noImplicitReturns":true,"noUnusedLocals":true,"noUnusedParameters":true,"rootDir":"./src","strict":true,"target":99},"fileIdsList":[[67],[64,65,66,109],[101,102,103,104],[101],[102],[56,57,58,59,60,61],[56],[62,100,106],[87,88],[67,90],[95,96],[84,85],[83],[78],[79,80,81,83,86,89,90,91,92,94,97,98,99],[93],[90],[82],[105],[68],[68,69,73,74,75,76,77],[71,72],[67,68],[63,64,65,66],[56,62,100]],"referencedMap":[[72,1],[71,1],[70,2],[105,3],[102,4],[103,5],[62,6],[60,7],[61,7],[57,7],[58,7],[59,7],[107,8],[88,1],[89,9],[96,10],[97,11],[86,12],[84,13],[98,13],[80,14],[81,1],[79,14],[91,13],[100,15],[94,16],[93,17],[92,13],[90,13],[83,18],[106,19],[69,20],[78,21],[77,1],[73,22],[68,1],[76,23],[67,24]],"exportedModulesMap":[[72,1],[71,1],[70,2],[105,3],[102,4],[103,5],[62,6],[60,7],[61,7],[57,7],[58,7],[59,7],[107,25],[88,1],[89,9],[96,10],[97,11],[86,12],[84,13],[98,13],[80,14],[81,1],[79,14],[91,13],[100,15],[94,16],[93,17],[92,13],[90,13],[83,18],[106,19],[69,20],[78,21],[77,1],[73,22],[68,1],[76,23],[67,24]],"semanticDiagnosticsPerFile":[65,72,71,70,66,64,82,11,13,12,2,14,15,16,17,18,19,20,21,3,4,25,22,23,24,26,27,28,5,29,30,31,32,6,36,33,34,35,37,7,38,43,44,39,40,41,42,8,48,45,46,47,49,9,50,51,52,53,54,1,10,55,101,104,105,102,103,62,60,61,57,58,59,56,107,88,89,87,96,97,95,86,85,84,98,80,81,79,91,99,100,94,93,92,90,83,106,69,78,75,77,73,68,76,74,63,67,108],"latestChangedDtsFile":"./build-types/index.d.ts"},"version":"4.9.5"}
|