Edit File by line

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93
/home/sportsfe.../httpdocs/clone/wp-inclu.../js/dist
File: data-controls.js
/******/ (() => { // webpackBootstrap
[0] Fix | Delete
/******/ "use strict";
[1] Fix | Delete
/******/ // The require scope
[2] Fix | Delete
/******/ var __webpack_require__ = {};
[3] Fix | Delete
/******/
[4] Fix | Delete
/************************************************************************/
[5] Fix | Delete
/******/ /* webpack/runtime/compat get default export */
[6] Fix | Delete
/******/ (() => {
[7] Fix | Delete
/******/ // getDefaultExport function for compatibility with non-harmony modules
[8] Fix | Delete
/******/ __webpack_require__.n = (module) => {
[9] Fix | Delete
/******/ var getter = module && module.__esModule ?
[10] Fix | Delete
/******/ () => (module['default']) :
[11] Fix | Delete
/******/ () => (module);
[12] Fix | Delete
/******/ __webpack_require__.d(getter, { a: getter });
[13] Fix | Delete
/******/ return getter;
[14] Fix | Delete
/******/ };
[15] Fix | Delete
/******/ })();
[16] Fix | Delete
/******/
[17] Fix | Delete
/******/ /* webpack/runtime/define property getters */
[18] Fix | Delete
/******/ (() => {
[19] Fix | Delete
/******/ // define getter functions for harmony exports
[20] Fix | Delete
/******/ __webpack_require__.d = (exports, definition) => {
[21] Fix | Delete
/******/ for(var key in definition) {
[22] Fix | Delete
/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
[23] Fix | Delete
/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
[24] Fix | Delete
/******/ }
[25] Fix | Delete
/******/ }
[26] Fix | Delete
/******/ };
[27] Fix | Delete
/******/ })();
[28] Fix | Delete
/******/
[29] Fix | Delete
/******/ /* webpack/runtime/hasOwnProperty shorthand */
[30] Fix | Delete
/******/ (() => {
[31] Fix | Delete
/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
[32] Fix | Delete
/******/ })();
[33] Fix | Delete
/******/
[34] Fix | Delete
/******/ /* webpack/runtime/make namespace object */
[35] Fix | Delete
/******/ (() => {
[36] Fix | Delete
/******/ // define __esModule on exports
[37] Fix | Delete
/******/ __webpack_require__.r = (exports) => {
[38] Fix | Delete
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
[39] Fix | Delete
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
[40] Fix | Delete
/******/ }
[41] Fix | Delete
/******/ Object.defineProperty(exports, '__esModule', { value: true });
[42] Fix | Delete
/******/ };
[43] Fix | Delete
/******/ })();
[44] Fix | Delete
/******/
[45] Fix | Delete
/************************************************************************/
[46] Fix | Delete
var __webpack_exports__ = {};
[47] Fix | Delete
// ESM COMPAT FLAG
[48] Fix | Delete
__webpack_require__.r(__webpack_exports__);
[49] Fix | Delete
[50] Fix | Delete
// EXPORTS
[51] Fix | Delete
__webpack_require__.d(__webpack_exports__, {
[52] Fix | Delete
__unstableAwaitPromise: () => (/* binding */ __unstableAwaitPromise),
[53] Fix | Delete
apiFetch: () => (/* binding */ apiFetch),
[54] Fix | Delete
controls: () => (/* binding */ controls),
[55] Fix | Delete
dispatch: () => (/* binding */ dispatch),
[56] Fix | Delete
select: () => (/* binding */ build_module_select),
[57] Fix | Delete
syncSelect: () => (/* binding */ syncSelect)
[58] Fix | Delete
});
[59] Fix | Delete
[60] Fix | Delete
;// CONCATENATED MODULE: external ["wp","apiFetch"]
[61] Fix | Delete
const external_wp_apiFetch_namespaceObject = window["wp"]["apiFetch"];
[62] Fix | Delete
var external_wp_apiFetch_default = /*#__PURE__*/__webpack_require__.n(external_wp_apiFetch_namespaceObject);
[63] Fix | Delete
;// CONCATENATED MODULE: external ["wp","data"]
[64] Fix | Delete
const external_wp_data_namespaceObject = window["wp"]["data"];
[65] Fix | Delete
;// CONCATENATED MODULE: external ["wp","deprecated"]
[66] Fix | Delete
const external_wp_deprecated_namespaceObject = window["wp"]["deprecated"];
[67] Fix | Delete
var external_wp_deprecated_default = /*#__PURE__*/__webpack_require__.n(external_wp_deprecated_namespaceObject);
[68] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/data-controls/build-module/index.js
[69] Fix | Delete
/**
[70] Fix | Delete
* WordPress dependencies
[71] Fix | Delete
*/
[72] Fix | Delete
[73] Fix | Delete
[74] Fix | Delete
[75] Fix | Delete
/**
[76] Fix | Delete
* Dispatches a control action for triggering an api fetch call.
[77] Fix | Delete
*
[78] Fix | Delete
* @param {Object} request Arguments for the fetch request.
[79] Fix | Delete
*
[80] Fix | Delete
* @example
[81] Fix | Delete
* ```js
[82] Fix | Delete
* import { apiFetch } from '@wordpress/data-controls';
[83] Fix | Delete
*
[84] Fix | Delete
* // Action generator using apiFetch
[85] Fix | Delete
* export function* myAction() {
[86] Fix | Delete
* const path = '/v2/my-api/items';
[87] Fix | Delete
* const items = yield apiFetch( { path } );
[88] Fix | Delete
* // do something with the items.
[89] Fix | Delete
* }
[90] Fix | Delete
* ```
[91] Fix | Delete
*
[92] Fix | Delete
* @return {Object} The control descriptor.
[93] Fix | Delete
*/
[94] Fix | Delete
function apiFetch(request) {
[95] Fix | Delete
return {
[96] Fix | Delete
type: 'API_FETCH',
[97] Fix | Delete
request
[98] Fix | Delete
};
[99] Fix | Delete
}
[100] Fix | Delete
[101] Fix | Delete
/**
[102] Fix | Delete
* Control for resolving a selector in a registered data store.
[103] Fix | Delete
* Alias for the `resolveSelect` built-in control in the `@wordpress/data` package.
[104] Fix | Delete
*
[105] Fix | Delete
* @param storeNameOrDescriptor The store object or identifier.
[106] Fix | Delete
* @param selectorName The selector name.
[107] Fix | Delete
* @param args Arguments passed without change to the `@wordpress/data` control.
[108] Fix | Delete
*/
[109] Fix | Delete
function build_module_select(storeNameOrDescriptor, selectorName, ...args) {
[110] Fix | Delete
external_wp_deprecated_default()('`select` control in `@wordpress/data-controls`', {
[111] Fix | Delete
since: '5.7',
[112] Fix | Delete
alternative: 'built-in `resolveSelect` control in `@wordpress/data`'
[113] Fix | Delete
});
[114] Fix | Delete
return external_wp_data_namespaceObject.controls.resolveSelect(storeNameOrDescriptor, selectorName, ...args);
[115] Fix | Delete
}
[116] Fix | Delete
[117] Fix | Delete
/**
[118] Fix | Delete
* Control for calling a selector in a registered data store.
[119] Fix | Delete
* Alias for the `select` built-in control in the `@wordpress/data` package.
[120] Fix | Delete
*
[121] Fix | Delete
* @param storeNameOrDescriptor The store object or identifier.
[122] Fix | Delete
* @param selectorName The selector name.
[123] Fix | Delete
* @param args Arguments passed without change to the `@wordpress/data` control.
[124] Fix | Delete
*/
[125] Fix | Delete
function syncSelect(storeNameOrDescriptor, selectorName, ...args) {
[126] Fix | Delete
external_wp_deprecated_default()('`syncSelect` control in `@wordpress/data-controls`', {
[127] Fix | Delete
since: '5.7',
[128] Fix | Delete
alternative: 'built-in `select` control in `@wordpress/data`'
[129] Fix | Delete
});
[130] Fix | Delete
return external_wp_data_namespaceObject.controls.select(storeNameOrDescriptor, selectorName, ...args);
[131] Fix | Delete
}
[132] Fix | Delete
[133] Fix | Delete
/**
[134] Fix | Delete
* Control for dispatching an action in a registered data store.
[135] Fix | Delete
* Alias for the `dispatch` control in the `@wordpress/data` package.
[136] Fix | Delete
*
[137] Fix | Delete
* @param storeNameOrDescriptor The store object or identifier.
[138] Fix | Delete
* @param actionName The action name.
[139] Fix | Delete
* @param args Arguments passed without change to the `@wordpress/data` control.
[140] Fix | Delete
*/
[141] Fix | Delete
function dispatch(storeNameOrDescriptor, actionName, ...args) {
[142] Fix | Delete
external_wp_deprecated_default()('`dispatch` control in `@wordpress/data-controls`', {
[143] Fix | Delete
since: '5.7',
[144] Fix | Delete
alternative: 'built-in `dispatch` control in `@wordpress/data`'
[145] Fix | Delete
});
[146] Fix | Delete
return external_wp_data_namespaceObject.controls.dispatch(storeNameOrDescriptor, actionName, ...args);
[147] Fix | Delete
}
[148] Fix | Delete
[149] Fix | Delete
/**
[150] Fix | Delete
* Dispatches a control action for awaiting on a promise to be resolved.
[151] Fix | Delete
*
[152] Fix | Delete
* @param {Object} promise Promise to wait for.
[153] Fix | Delete
*
[154] Fix | Delete
* @example
[155] Fix | Delete
* ```js
[156] Fix | Delete
* import { __unstableAwaitPromise } from '@wordpress/data-controls';
[157] Fix | Delete
*
[158] Fix | Delete
* // Action generator using apiFetch
[159] Fix | Delete
* export function* myAction() {
[160] Fix | Delete
* const promise = getItemsAsync();
[161] Fix | Delete
* const items = yield __unstableAwaitPromise( promise );
[162] Fix | Delete
* // do something with the items.
[163] Fix | Delete
* }
[164] Fix | Delete
* ```
[165] Fix | Delete
*
[166] Fix | Delete
* @return {Object} The control descriptor.
[167] Fix | Delete
*/
[168] Fix | Delete
const __unstableAwaitPromise = function (promise) {
[169] Fix | Delete
return {
[170] Fix | Delete
type: 'AWAIT_PROMISE',
[171] Fix | Delete
promise
[172] Fix | Delete
};
[173] Fix | Delete
};
[174] Fix | Delete
[175] Fix | Delete
/**
[176] Fix | Delete
* The default export is what you use to register the controls with your custom
[177] Fix | Delete
* store.
[178] Fix | Delete
*
[179] Fix | Delete
* @example
[180] Fix | Delete
* ```js
[181] Fix | Delete
* // WordPress dependencies
[182] Fix | Delete
* import { controls } from '@wordpress/data-controls';
[183] Fix | Delete
* import { registerStore } from '@wordpress/data';
[184] Fix | Delete
*
[185] Fix | Delete
* // Internal dependencies
[186] Fix | Delete
* import reducer from './reducer';
[187] Fix | Delete
* import * as selectors from './selectors';
[188] Fix | Delete
* import * as actions from './actions';
[189] Fix | Delete
* import * as resolvers from './resolvers';
[190] Fix | Delete
*
[191] Fix | Delete
* registerStore( 'my-custom-store', {
[192] Fix | Delete
* reducer,
[193] Fix | Delete
* controls,
[194] Fix | Delete
* actions,
[195] Fix | Delete
* selectors,
[196] Fix | Delete
* resolvers,
[197] Fix | Delete
* } );
[198] Fix | Delete
* ```
[199] Fix | Delete
* @return {Object} An object for registering the default controls with the
[200] Fix | Delete
* store.
[201] Fix | Delete
*/
[202] Fix | Delete
const controls = {
[203] Fix | Delete
AWAIT_PROMISE: ({
[204] Fix | Delete
promise
[205] Fix | Delete
}) => promise,
[206] Fix | Delete
API_FETCH({
[207] Fix | Delete
request
[208] Fix | Delete
}) {
[209] Fix | Delete
return external_wp_apiFetch_default()(request);
[210] Fix | Delete
}
[211] Fix | Delete
};
[212] Fix | Delete
[213] Fix | Delete
(window.wp = window.wp || {}).dataControls = __webpack_exports__;
[214] Fix | Delete
/******/ })()
[215] Fix | Delete
;
[216] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function