| @@ -1,172 +1,2090 @@ | ||
| 1 | +/*! elementor - v3.24.0 - 28-10-2024 */ | |
| 1 | 2 | /******/ (() => { // webpackBootstrap |
| 2 | 3 | /******/ var __webpack_modules__ = ({ |
| 3 | 4 | |
| 4 | -/***/ "../app/modules/import-export-customization/assets/js/shared/registry/base.js": | |
| 5 | -/*!************************************************************************************!*\ | |
| 6 | - !*** ../app/modules/import-export-customization/assets/js/shared/registry/base.js ***! | |
| 7 | - \************************************************************************************/ | |
| 8 | -/***/ ((__unused_webpack_module, exports, __webpack_require__) => { | |
| 5 | +/***/ "../node_modules/@reduxjs/toolkit/dist/redux-toolkit.esm.js": | |
| 6 | +/*!******************************************************************!*\ | |
| 7 | + !*** ../node_modules/@reduxjs/toolkit/dist/redux-toolkit.esm.js ***! | |
| 8 | + \******************************************************************/ | |
| 9 | +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { | |
| 9 | 10 | |
| 10 | 11 | "use strict"; |
| 12 | +__webpack_require__.r(__webpack_exports__); | |
| 13 | +/* harmony export */ __webpack_require__.d(__webpack_exports__, { | |
| 14 | +/* harmony export */ EnhancerArray: () => (/* binding */ EnhancerArray), | |
| 15 | +/* harmony export */ MiddlewareArray: () => (/* binding */ MiddlewareArray), | |
| 16 | +/* harmony export */ SHOULD_AUTOBATCH: () => (/* binding */ SHOULD_AUTOBATCH), | |
| 17 | +/* harmony export */ TaskAbortError: () => (/* binding */ TaskAbortError), | |
| 18 | +/* harmony export */ __DO_NOT_USE__ActionTypes: () => (/* reexport safe */ redux__WEBPACK_IMPORTED_MODULE_0__.__DO_NOT_USE__ActionTypes), | |
| 19 | +/* harmony export */ addListener: () => (/* binding */ addListener), | |
| 20 | +/* harmony export */ applyMiddleware: () => (/* reexport safe */ redux__WEBPACK_IMPORTED_MODULE_0__.applyMiddleware), | |
| 21 | +/* harmony export */ autoBatchEnhancer: () => (/* binding */ autoBatchEnhancer), | |
| 22 | +/* harmony export */ bindActionCreators: () => (/* reexport safe */ redux__WEBPACK_IMPORTED_MODULE_0__.bindActionCreators), | |
| 23 | +/* harmony export */ clearAllListeners: () => (/* binding */ clearAllListeners), | |
| 24 | +/* harmony export */ combineReducers: () => (/* reexport safe */ redux__WEBPACK_IMPORTED_MODULE_0__.combineReducers), | |
| 25 | +/* harmony export */ compose: () => (/* reexport safe */ redux__WEBPACK_IMPORTED_MODULE_0__.compose), | |
| 26 | +/* harmony export */ configureStore: () => (/* binding */ configureStore), | |
| 27 | +/* harmony export */ createAction: () => (/* binding */ createAction), | |
| 28 | +/* harmony export */ createActionCreatorInvariantMiddleware: () => (/* binding */ createActionCreatorInvariantMiddleware), | |
| 29 | +/* harmony export */ createAsyncThunk: () => (/* binding */ createAsyncThunk), | |
| 30 | +/* harmony export */ createDraftSafeSelector: () => (/* binding */ createDraftSafeSelector), | |
| 31 | +/* harmony export */ createEntityAdapter: () => (/* binding */ createEntityAdapter), | |
| 32 | +/* harmony export */ createImmutableStateInvariantMiddleware: () => (/* binding */ createImmutableStateInvariantMiddleware), | |
| 33 | +/* harmony export */ createListenerMiddleware: () => (/* binding */ createListenerMiddleware), | |
| 34 | +/* harmony export */ createNextState: () => (/* reexport safe */ immer__WEBPACK_IMPORTED_MODULE_2__["default"]), | |
| 35 | +/* harmony export */ createReducer: () => (/* binding */ createReducer), | |
| 36 | +/* harmony export */ createSelector: () => (/* reexport safe */ reselect__WEBPACK_IMPORTED_MODULE_1__.createSelector), | |
| 37 | +/* harmony export */ createSerializableStateInvariantMiddleware: () => (/* binding */ createSerializableStateInvariantMiddleware), | |
| 38 | +/* harmony export */ createSlice: () => (/* binding */ createSlice), | |
| 39 | +/* harmony export */ createStore: () => (/* reexport safe */ redux__WEBPACK_IMPORTED_MODULE_0__.createStore), | |
| 40 | +/* harmony export */ current: () => (/* reexport safe */ immer__WEBPACK_IMPORTED_MODULE_2__.current), | |
| 41 | +/* harmony export */ findNonSerializableValue: () => (/* binding */ findNonSerializableValue), | |
| 42 | +/* harmony export */ freeze: () => (/* reexport safe */ immer__WEBPACK_IMPORTED_MODULE_2__.freeze), | |
| 43 | +/* harmony export */ getDefaultMiddleware: () => (/* binding */ getDefaultMiddleware), | |
| 44 | +/* harmony export */ getType: () => (/* binding */ getType), | |
| 45 | +/* harmony export */ isAction: () => (/* binding */ isAction), | |
| 46 | +/* harmony export */ isActionCreator: () => (/* binding */ isActionCreator), | |
| 47 | +/* harmony export */ isAllOf: () => (/* binding */ isAllOf), | |
| 48 | +/* harmony export */ isAnyOf: () => (/* binding */ isAnyOf), | |
| 49 | +/* harmony export */ isAsyncThunkAction: () => (/* binding */ isAsyncThunkAction), | |
| 50 | +/* harmony export */ isDraft: () => (/* reexport safe */ immer__WEBPACK_IMPORTED_MODULE_2__.isDraft), | |
| 51 | +/* harmony export */ isFluxStandardAction: () => (/* binding */ isFSA), | |
| 52 | +/* harmony export */ isFulfilled: () => (/* binding */ isFulfilled), | |
| 53 | +/* harmony export */ isImmutableDefault: () => (/* binding */ isImmutableDefault), | |
| 54 | +/* harmony export */ isPending: () => (/* binding */ isPending), | |
| 55 | +/* harmony export */ isPlain: () => (/* binding */ isPlain), | |
| 56 | +/* harmony export */ isPlainObject: () => (/* binding */ isPlainObject), | |
| 57 | +/* harmony export */ isRejected: () => (/* binding */ isRejected), | |
| 58 | +/* harmony export */ isRejectedWithValue: () => (/* binding */ isRejectedWithValue), | |
| 59 | +/* harmony export */ legacy_createStore: () => (/* reexport safe */ redux__WEBPACK_IMPORTED_MODULE_0__.legacy_createStore), | |
| 60 | +/* harmony export */ miniSerializeError: () => (/* binding */ miniSerializeError), | |
| 61 | +/* harmony export */ nanoid: () => (/* binding */ nanoid), | |
| 62 | +/* harmony export */ original: () => (/* reexport safe */ immer__WEBPACK_IMPORTED_MODULE_2__.original), | |
| 63 | +/* harmony export */ prepareAutoBatched: () => (/* binding */ prepareAutoBatched), | |
| 64 | +/* harmony export */ removeListener: () => (/* binding */ removeListener), | |
| 65 | +/* harmony export */ unwrapResult: () => (/* binding */ unwrapResult) | |
| 66 | +/* harmony export */ }); | |
| 67 | +/* harmony import */ var immer__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! immer */ "../node_modules/@reduxjs/toolkit/node_modules/immer/dist/immer.esm.mjs"); | |
| 68 | +/* harmony import */ var redux__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! redux */ "../node_modules/redux/es/redux.js"); | |
| 69 | +/* harmony import */ var reselect__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! reselect */ "../node_modules/reselect/es/index.js"); | |
| 70 | +/* harmony import */ var redux_thunk__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! redux-thunk */ "../node_modules/redux-thunk/es/index.js"); | |
| 71 | +var __extends = (undefined && undefined.__extends) || (function () { | |
| 72 | + var extendStatics = function (d, b) { | |
| 73 | + extendStatics = Object.setPrototypeOf || | |
| 74 | + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || | |
| 75 | + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; | |
| 76 | + return extendStatics(d, b); | |
| 77 | + }; | |
| 78 | + return function (d, b) { | |
| 79 | + if (typeof b !== "function" && b !== null) | |
| 80 | + throw new TypeError("Class extends value " + String(b) + " is not a constructor or null"); | |
| 81 | + extendStatics(d, b); | |
| 82 | + function __() { this.constructor = d; } | |
| 83 | + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); | |
| 84 | + }; | |
| 85 | +})(); | |
| 86 | +var __generator = (undefined && undefined.__generator) || function (thisArg, body) { | |
| 87 | + var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g; | |
| 88 | + return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g; | |
| 89 | + function verb(n) { return function (v) { return step([n, v]); }; } | |
| 90 | + function step(op) { | |
| 91 | + if (f) throw new TypeError("Generator is already executing."); | |
| 92 | + while (_) try { | |
| 93 | + if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t; | |
| 94 | + if (y = 0, t) op = [op[0] & 2, t.value]; | |
| 95 | + switch (op[0]) { | |
| 96 | + case 0: case 1: t = op; break; | |
| 97 | + case 4: _.label++; return { value: op[1], done: false }; | |
| 98 | + case 5: _.label++; y = op[1]; op = [0]; continue; | |
| 99 | + case 7: op = _.ops.pop(); _.trys.pop(); continue; | |
| 100 | + default: | |
| 101 | + if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; } | |
| 102 | + if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; } | |
| 103 | + if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; } | |
| 104 | + if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; } | |
| 105 | + if (t[2]) _.ops.pop(); | |
| 106 | + _.trys.pop(); continue; | |
| 107 | + } | |
| 108 | + op = body.call(thisArg, _); | |
| 109 | + } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; } | |
| 110 | + if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true }; | |
| 111 | + } | |
| 112 | +}; | |
| 113 | +var __spreadArray = (undefined && undefined.__spreadArray) || function (to, from) { | |
| 114 | + for (var i = 0, il = from.length, j = to.length; i < il; i++, j++) | |
| 115 | + to[j] = from[i]; | |
| 116 | + return to; | |
| 117 | +}; | |
| 118 | +var __defProp = Object.defineProperty; | |
| 119 | +var __defProps = Object.defineProperties; | |
| 120 | +var __getOwnPropDescs = Object.getOwnPropertyDescriptors; | |
| 121 | +var __getOwnPropSymbols = Object.getOwnPropertySymbols; | |
| 122 | +var __hasOwnProp = Object.prototype.hasOwnProperty; | |
| 123 | +var __propIsEnum = Object.prototype.propertyIsEnumerable; | |
| 124 | +var __defNormalProp = function (obj, key, value) { return key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value: value }) : obj[key] = value; }; | |
| 125 | +var __spreadValues = function (a, b) { | |
| 126 | + for (var prop in b || (b = {})) | |
| 127 | + if (__hasOwnProp.call(b, prop)) | |
| 128 | + __defNormalProp(a, prop, b[prop]); | |
| 129 | + if (__getOwnPropSymbols) | |
| 130 | + for (var _i = 0, _c = __getOwnPropSymbols(b); _i < _c.length; _i++) { | |
| 131 | + var prop = _c[_i]; | |
| 132 | + if (__propIsEnum.call(b, prop)) | |
| 133 | + __defNormalProp(a, prop, b[prop]); | |
| 134 | + } | |
| 135 | + return a; | |
| 136 | +}; | |
| 137 | +var __spreadProps = function (a, b) { return __defProps(a, __getOwnPropDescs(b)); }; | |
| 138 | +var __async = function (__this, __arguments, generator) { | |
| 139 | + return new Promise(function (resolve, reject) { | |
| 140 | + var fulfilled = function (value) { | |
| 141 | + try { | |
| 142 | + step(generator.next(value)); | |
| 143 | + } | |
| 144 | + catch (e) { | |
| 145 | + reject(e); | |
| 146 | + } | |
| 147 | + }; | |
| 148 | + var rejected = function (value) { | |
| 149 | + try { | |
| 150 | + step(generator.throw(value)); | |
| 151 | + } | |
| 152 | + catch (e) { | |
| 153 | + reject(e); | |
| 154 | + } | |
| 155 | + }; | |
| 156 | + var step = function (x) { return x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected); }; | |
| 157 | + step((generator = generator.apply(__this, __arguments)).next()); | |
| 158 | + }); | |
| 159 | +}; | |
| 160 | +// src/index.ts | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | +// src/createDraftSafeSelector.ts | |
| 166 | + | |
| 167 | + | |
| 168 | +var createDraftSafeSelector = function () { | |
| 169 | + var args = []; | |
| 170 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 171 | + args[_i] = arguments[_i]; | |
| 172 | + } | |
| 173 | + var selector = reselect__WEBPACK_IMPORTED_MODULE_1__.createSelector.apply(void 0, args); | |
| 174 | + var wrappedSelector = function (value) { | |
| 175 | + var rest = []; | |
| 176 | + for (var _i = 1; _i < arguments.length; _i++) { | |
| 177 | + rest[_i - 1] = arguments[_i]; | |
| 178 | + } | |
| 179 | + return selector.apply(void 0, __spreadArray([(0,immer__WEBPACK_IMPORTED_MODULE_2__.isDraft)(value) ? (0,immer__WEBPACK_IMPORTED_MODULE_2__.current)(value) : value], rest)); | |
| 180 | + }; | |
| 181 | + return wrappedSelector; | |
| 182 | +}; | |
| 183 | +// src/configureStore.ts | |
| 184 | + | |
| 185 | +// src/devtoolsExtension.ts | |
| 186 | + | |
| 187 | +var composeWithDevTools = typeof window !== "undefined" && window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ ? window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ : function () { | |
| 188 | + if (arguments.length === 0) | |
| 189 | + return void 0; | |
| 190 | + if (typeof arguments[0] === "object") | |
| 191 | + return redux__WEBPACK_IMPORTED_MODULE_0__.compose; | |
| 192 | + return redux__WEBPACK_IMPORTED_MODULE_0__.compose.apply(null, arguments); | |
| 193 | +}; | |
| 194 | +var devToolsEnhancer = typeof window !== "undefined" && window.__REDUX_DEVTOOLS_EXTENSION__ ? window.__REDUX_DEVTOOLS_EXTENSION__ : function () { | |
| 195 | + return function (noop2) { | |
| 196 | + return noop2; | |
| 197 | + }; | |
| 198 | +}; | |
| 199 | +// src/isPlainObject.ts | |
| 200 | +function isPlainObject(value) { | |
| 201 | + if (typeof value !== "object" || value === null) | |
| 202 | + return false; | |
| 203 | + var proto = Object.getPrototypeOf(value); | |
| 204 | + if (proto === null) | |
| 205 | + return true; | |
| 206 | + var baseProto = proto; | |
| 207 | + while (Object.getPrototypeOf(baseProto) !== null) { | |
| 208 | + baseProto = Object.getPrototypeOf(baseProto); | |
| 209 | + } | |
| 210 | + return proto === baseProto; | |
| 211 | +} | |
| 212 | +// src/getDefaultMiddleware.ts | |
| 213 | + | |
| 214 | +// src/tsHelpers.ts | |
| 215 | +var hasMatchFunction = function (v) { | |
| 216 | + return v && typeof v.match === "function"; | |
| 217 | +}; | |
| 218 | +// src/createAction.ts | |
| 219 | +function createAction(type, prepareAction) { | |
| 220 | + function actionCreator() { | |
| 221 | + var args = []; | |
| 222 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 223 | + args[_i] = arguments[_i]; | |
| 224 | + } | |
| 225 | + if (prepareAction) { | |
| 226 | + var prepared = prepareAction.apply(void 0, args); | |
| 227 | + if (!prepared) { | |
| 228 | + throw new Error("prepareAction did not return an object"); | |
| 229 | + } | |
| 230 | + return __spreadValues(__spreadValues({ | |
| 231 | + type: type, | |
| 232 | + payload: prepared.payload | |
| 233 | + }, "meta" in prepared && { meta: prepared.meta }), "error" in prepared && { error: prepared.error }); | |
| 234 | + } | |
| 235 | + return { type: type, payload: args[0] }; | |
| 236 | + } | |
| 237 | + actionCreator.toString = function () { return "" + type; }; | |
| 238 | + actionCreator.type = type; | |
| 239 | + actionCreator.match = function (action) { return action.type === type; }; | |
| 240 | + return actionCreator; | |
| 241 | +} | |
| 242 | +function isAction(action) { | |
| 243 | + return isPlainObject(action) && "type" in action; | |
| 244 | +} | |
| 245 | +function isActionCreator(action) { | |
| 246 | + return typeof action === "function" && "type" in action && hasMatchFunction(action); | |
| 247 | +} | |
| 248 | +function isFSA(action) { | |
| 249 | + return isAction(action) && typeof action.type === "string" && Object.keys(action).every(isValidKey); | |
| 250 | +} | |
| 251 | +function isValidKey(key) { | |
| 252 | + return ["type", "payload", "error", "meta"].indexOf(key) > -1; | |
| 253 | +} | |
| 254 | +function getType(actionCreator) { | |
| 255 | + return "" + actionCreator; | |
| 256 | +} | |
| 257 | +// src/actionCreatorInvariantMiddleware.ts | |
| 258 | +function getMessage(type) { | |
| 259 | + var splitType = type ? ("" + type).split("/") : []; | |
| 260 | + var actionName = splitType[splitType.length - 1] || "actionCreator"; | |
| 261 | + return "Detected an action creator with type \"" + (type || "unknown") + "\" being dispatched. \nMake sure you're calling the action creator before dispatching, i.e. `dispatch(" + actionName + "())` instead of `dispatch(" + actionName + ")`. This is necessary even if the action has no payload."; | |
| 262 | +} | |
| 263 | +function createActionCreatorInvariantMiddleware(options) { | |
| 264 | + if (options === void 0) { options = {}; } | |
| 265 | + if (false) {} | |
| 266 | + var _c = options.isActionCreator, isActionCreator2 = _c === void 0 ? isActionCreator : _c; | |
| 267 | + return function () { return function (next) { return function (action) { | |
| 268 | + if (isActionCreator2(action)) { | |
| 269 | + console.warn(getMessage(action.type)); | |
| 270 | + } | |
| 271 | + return next(action); | |
| 272 | + }; }; }; | |
| 273 | +} | |
| 274 | +// src/utils.ts | |
| 275 | + | |
| 276 | +function getTimeMeasureUtils(maxDelay, fnName) { | |
| 277 | + var elapsed = 0; | |
| 278 | + return { | |
| 279 | + measureTime: function (fn) { | |
| 280 | + var started = Date.now(); | |
| 281 | + try { | |
| 282 | + return fn(); | |
| 283 | + } | |
| 284 | + finally { | |
| 285 | + var finished = Date.now(); | |
| 286 | + elapsed += finished - started; | |
| 287 | + } | |
| 288 | + }, | |
| 289 | + warnIfExceeded: function () { | |
| 290 | + if (elapsed > maxDelay) { | |
| 291 | + console.warn(fnName + " took " + elapsed + "ms, which is more than the warning threshold of " + maxDelay + "ms. \nIf your state or actions are very large, you may want to disable the middleware as it might cause too much of a slowdown in development mode. See https://redux-toolkit.js.org/api/getDefaultMiddleware for instructions.\nIt is disabled in production builds, so you don't need to worry about that."); | |
| 292 | + } | |
| 293 | + } | |
| 294 | + }; | |
| 295 | +} | |
| 296 | +var MiddlewareArray = /** @class */ (function (_super) { | |
| 297 | + __extends(MiddlewareArray, _super); | |
| 298 | + function MiddlewareArray() { | |
| 299 | + var args = []; | |
| 300 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 301 | + args[_i] = arguments[_i]; | |
| 302 | + } | |
| 303 | + var _this = _super.apply(this, args) || this; | |
| 304 | + Object.setPrototypeOf(_this, MiddlewareArray.prototype); | |
| 305 | + return _this; | |
| 306 | + } | |
| 307 | + Object.defineProperty(MiddlewareArray, Symbol.species, { | |
| 308 | + get: function () { | |
| 309 | + return MiddlewareArray; | |
| 310 | + }, | |
| 311 | + enumerable: false, | |
| 312 | + configurable: true | |
| 313 | + }); | |
| 314 | + MiddlewareArray.prototype.concat = function () { | |
| 315 | + var arr = []; | |
| 316 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 317 | + arr[_i] = arguments[_i]; | |
| 318 | + } | |
| 319 | + return _super.prototype.concat.apply(this, arr); | |
| 320 | + }; | |
| 321 | + MiddlewareArray.prototype.prepend = function () { | |
| 322 | + var arr = []; | |
| 323 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 324 | + arr[_i] = arguments[_i]; | |
| 325 | + } | |
| 326 | + if (arr.length === 1 && Array.isArray(arr[0])) { | |
| 327 | + return new (MiddlewareArray.bind.apply(MiddlewareArray, __spreadArray([void 0], arr[0].concat(this))))(); | |
| 328 | + } | |
| 329 | + return new (MiddlewareArray.bind.apply(MiddlewareArray, __spreadArray([void 0], arr.concat(this))))(); | |
| 330 | + }; | |
| 331 | + return MiddlewareArray; | |
| 332 | +}(Array)); | |
| 333 | +var EnhancerArray = /** @class */ (function (_super) { | |
| 334 | + __extends(EnhancerArray, _super); | |
| 335 | + function EnhancerArray() { | |
| 336 | + var args = []; | |
| 337 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 338 | + args[_i] = arguments[_i]; | |
| 339 | + } | |
| 340 | + var _this = _super.apply(this, args) || this; | |
| 341 | + Object.setPrototypeOf(_this, EnhancerArray.prototype); | |
| 342 | + return _this; | |
| 343 | + } | |
| 344 | + Object.defineProperty(EnhancerArray, Symbol.species, { | |
| 345 | + get: function () { | |
| 346 | + return EnhancerArray; | |
| 347 | + }, | |
| 348 | + enumerable: false, | |
| 349 | + configurable: true | |
| 350 | + }); | |
| 351 | + EnhancerArray.prototype.concat = function () { | |
| 352 | + var arr = []; | |
| 353 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 354 | + arr[_i] = arguments[_i]; | |
| 355 | + } | |
| 356 | + return _super.prototype.concat.apply(this, arr); | |
| 357 | + }; | |
| 358 | + EnhancerArray.prototype.prepend = function () { | |
| 359 | + var arr = []; | |
| 360 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 361 | + arr[_i] = arguments[_i]; | |
| 362 | + } | |
| 363 | + if (arr.length === 1 && Array.isArray(arr[0])) { | |
| 364 | + return new (EnhancerArray.bind.apply(EnhancerArray, __spreadArray([void 0], arr[0].concat(this))))(); | |
| 365 | + } | |
| 366 | + return new (EnhancerArray.bind.apply(EnhancerArray, __spreadArray([void 0], arr.concat(this))))(); | |
| 367 | + }; | |
| 368 | + return EnhancerArray; | |
| 369 | +}(Array)); | |
| 370 | +function freezeDraftable(val) { | |
| 371 | + return (0,immer__WEBPACK_IMPORTED_MODULE_2__.isDraftable)(val) ? (0,immer__WEBPACK_IMPORTED_MODULE_2__["default"])(val, function () { | |
| 372 | + }) : val; | |
| 373 | +} | |
| 374 | +// src/immutableStateInvariantMiddleware.ts | |
| 375 | +var isProduction = "development" === "production"; | |
| 376 | +var prefix = "Invariant failed"; | |
| 377 | +function invariant(condition, message) { | |
| 378 | + if (condition) { | |
| 379 | + return; | |
| 380 | + } | |
| 381 | + if (isProduction) { | |
| 382 | + throw new Error(prefix); | |
| 383 | + } | |
| 384 | + throw new Error(prefix + ": " + (message || "")); | |
| 385 | +} | |
| 386 | +function stringify(obj, serializer, indent, decycler) { | |
| 387 | + return JSON.stringify(obj, getSerialize(serializer, decycler), indent); | |
| 388 | +} | |
| 389 | +function getSerialize(serializer, decycler) { | |
| 390 | + var stack = [], keys = []; | |
| 391 | + if (!decycler) | |
| 392 | + decycler = function (_, value) { | |
| 393 | + if (stack[0] === value) | |
| 394 | + return "[Circular ~]"; | |
| 395 | + return "[Circular ~." + keys.slice(0, stack.indexOf(value)).join(".") + "]"; | |
| 396 | + }; | |
| 397 | + return function (key, value) { | |
| 398 | + if (stack.length > 0) { | |
| 399 | + var thisPos = stack.indexOf(this); | |
| 400 | + ~thisPos ? stack.splice(thisPos + 1) : stack.push(this); | |
| 401 | + ~thisPos ? keys.splice(thisPos, Infinity, key) : keys.push(key); | |
| 402 | + if (~stack.indexOf(value)) | |
| 403 | + value = decycler.call(this, key, value); | |
| 404 | + } | |
| 405 | + else | |
| 406 | + stack.push(value); | |
| 407 | + return serializer == null ? value : serializer.call(this, key, value); | |
| 408 | + }; | |
| 409 | +} | |
| 410 | +function isImmutableDefault(value) { | |
| 411 | + return typeof value !== "object" || value == null || Object.isFrozen(value); | |
| 412 | +} | |
| 413 | +function trackForMutations(isImmutable, ignorePaths, obj) { | |
| 414 | + var trackedProperties = trackProperties(isImmutable, ignorePaths, obj); | |
| 415 | + return { | |
| 416 | + detectMutations: function () { | |
| 417 | + return detectMutations(isImmutable, ignorePaths, trackedProperties, obj); | |
| 418 | + } | |
| 419 | + }; | |
| 420 | +} | |
| 421 | +function trackProperties(isImmutable, ignorePaths, obj, path, checkedObjects) { | |
| 422 | + if (ignorePaths === void 0) { ignorePaths = []; } | |
| 423 | + if (path === void 0) { path = ""; } | |
| 424 | + if (checkedObjects === void 0) { checkedObjects = new Set(); } | |
| 425 | + var tracked = { value: obj }; | |
| 426 | + if (!isImmutable(obj) && !checkedObjects.has(obj)) { | |
| 427 | + checkedObjects.add(obj); | |
| 428 | + tracked.children = {}; | |
| 429 | + for (var key in obj) { | |
| 430 | + var childPath = path ? path + "." + key : key; | |
| 431 | + if (ignorePaths.length && ignorePaths.indexOf(childPath) !== -1) { | |
| 432 | + continue; | |
| 433 | + } | |
| 434 | + tracked.children[key] = trackProperties(isImmutable, ignorePaths, obj[key], childPath); | |
| 435 | + } | |
| 436 | + } | |
| 437 | + return tracked; | |
| 438 | +} | |
| 439 | +function detectMutations(isImmutable, ignoredPaths, trackedProperty, obj, sameParentRef, path) { | |
| 440 | + if (ignoredPaths === void 0) { ignoredPaths = []; } | |
| 441 | + if (sameParentRef === void 0) { sameParentRef = false; } | |
| 442 | + if (path === void 0) { path = ""; } | |
| 443 | + var prevObj = trackedProperty ? trackedProperty.value : void 0; | |
| 444 | + var sameRef = prevObj === obj; | |
| 445 | + if (sameParentRef && !sameRef && !Number.isNaN(obj)) { | |
| 446 | + return { wasMutated: true, path: path }; | |
| 447 | + } | |
| 448 | + if (isImmutable(prevObj) || isImmutable(obj)) { | |
| 449 | + return { wasMutated: false }; | |
| 450 | + } | |
| 451 | + var keysToDetect = {}; | |
| 452 | + for (var key in trackedProperty.children) { | |
| 453 | + keysToDetect[key] = true; | |
| 454 | + } | |
| 455 | + for (var key in obj) { | |
| 456 | + keysToDetect[key] = true; | |
| 457 | + } | |
| 458 | + var hasIgnoredPaths = ignoredPaths.length > 0; | |
| 459 | + var _loop_1 = function (key) { | |
| 460 | + var nestedPath = path ? path + "." + key : key; | |
| 461 | + if (hasIgnoredPaths) { | |
| 462 | + var hasMatches = ignoredPaths.some(function (ignored) { | |
| 463 | + if (ignored instanceof RegExp) { | |
| 464 | + return ignored.test(nestedPath); | |
| 465 | + } | |
| 466 | + return nestedPath === ignored; | |
| 467 | + }); | |
| 468 | + if (hasMatches) { | |
| 469 | + return "continue"; | |
| 470 | + } | |
| 471 | + } | |
| 472 | + var result = detectMutations(isImmutable, ignoredPaths, trackedProperty.children[key], obj[key], sameRef, nestedPath); | |
| 473 | + if (result.wasMutated) { | |
| 474 | + return { value: result }; | |
| 475 | + } | |
| 476 | + }; | |
| 477 | + for (var key in keysToDetect) { | |
| 478 | + var state_1 = _loop_1(key); | |
| 479 | + if (typeof state_1 === "object") | |
| 480 | + return state_1.value; | |
| 481 | + } | |
| 482 | + return { wasMutated: false }; | |
| 483 | +} | |
| 484 | +function createImmutableStateInvariantMiddleware(options) { | |
| 485 | + if (options === void 0) { options = {}; } | |
| 486 | + if (false) {} | |
| 487 | + var _c = options.isImmutable, isImmutable = _c === void 0 ? isImmutableDefault : _c, ignoredPaths = options.ignoredPaths, _d = options.warnAfter, warnAfter = _d === void 0 ? 32 : _d, ignore = options.ignore; | |
| 488 | + ignoredPaths = ignoredPaths || ignore; | |
| 489 | + var track = trackForMutations.bind(null, isImmutable, ignoredPaths); | |
| 490 | + return function (_c) { | |
| 491 | + var getState = _c.getState; | |
| 492 | + var state = getState(); | |
| 493 | + var tracker = track(state); | |
| 494 | + var result; | |
| 495 | + return function (next) { return function (action) { | |
| 496 | + var measureUtils = getTimeMeasureUtils(warnAfter, "ImmutableStateInvariantMiddleware"); | |
| 497 | + measureUtils.measureTime(function () { | |
| 498 | + state = getState(); | |
| 499 | + result = tracker.detectMutations(); | |
| 500 | + tracker = track(state); | |
| 501 | + invariant(!result.wasMutated, "A state mutation was detected between dispatches, in the path '" + (result.path || "") + "'. This may cause incorrect behavior. (https://redux.js.org/style-guide/style-guide#do-not-mutate-state)"); | |
| 502 | + }); | |
| 503 | + var dispatchedAction = next(action); | |
| 504 | + measureUtils.measureTime(function () { | |
| 505 | + state = getState(); | |
| 506 | + result = tracker.detectMutations(); | |
| 507 | + tracker = track(state); | |
| 508 | + result.wasMutated && invariant(!result.wasMutated, "A state mutation was detected inside a dispatch, in the path: " + (result.path || "") + ". Take a look at the reducer(s) handling the action " + stringify(action) + ". (https://redux.js.org/style-guide/style-guide#do-not-mutate-state)"); | |
| 509 | + }); | |
| 510 | + measureUtils.warnIfExceeded(); | |
| 511 | + return dispatchedAction; | |
| 512 | + }; }; | |
| 513 | + }; | |
| 514 | +} | |
| 515 | +// src/serializableStateInvariantMiddleware.ts | |
| 516 | +function isPlain(val) { | |
| 517 | + var type = typeof val; | |
| 518 | + return val == null || type === "string" || type === "boolean" || type === "number" || Array.isArray(val) || isPlainObject(val); | |
| 519 | +} | |
| 520 | +function findNonSerializableValue(value, path, isSerializable, getEntries, ignoredPaths, cache) { | |
| 521 | + if (path === void 0) { path = ""; } | |
| 522 | + if (isSerializable === void 0) { isSerializable = isPlain; } | |
| 523 | + if (ignoredPaths === void 0) { ignoredPaths = []; } | |
| 524 | + var foundNestedSerializable; | |
| 525 | + if (!isSerializable(value)) { | |
| 526 | + return { | |
| 527 | + keyPath: path || "<root>", | |
| 528 | + value: value | |
| 529 | + }; | |
| 530 | + } | |
| 531 | + if (typeof value !== "object" || value === null) { | |
| 532 | + return false; | |
| 533 | + } | |
| 534 | + if (cache == null ? void 0 : cache.has(value)) | |
| 535 | + return false; | |
| 536 | + var entries = getEntries != null ? getEntries(value) : Object.entries(value); | |
| 537 | + var hasIgnoredPaths = ignoredPaths.length > 0; | |
| 538 | + var _loop_2 = function (key, nestedValue) { | |
| 539 | + var nestedPath = path ? path + "." + key : key; | |
| 540 | + if (hasIgnoredPaths) { | |
| 541 | + var hasMatches = ignoredPaths.some(function (ignored) { | |
| 542 | + if (ignored instanceof RegExp) { | |
| 543 | + return ignored.test(nestedPath); | |
| 544 | + } | |
| 545 | + return nestedPath === ignored; | |
| 546 | + }); | |
| 547 | + if (hasMatches) { | |
| 548 | + return "continue"; | |
| 549 | + } | |
| 550 | + } | |
| 551 | + if (!isSerializable(nestedValue)) { | |
| 552 | + return { value: { | |
| 553 | + keyPath: nestedPath, | |
| 554 | + value: nestedValue | |
| 555 | + } }; | |
| 556 | + } | |
| 557 | + if (typeof nestedValue === "object") { | |
| 558 | + foundNestedSerializable = findNonSerializableValue(nestedValue, nestedPath, isSerializable, getEntries, ignoredPaths, cache); | |
| 559 | + if (foundNestedSerializable) { | |
| 560 | + return { value: foundNestedSerializable }; | |
| 561 | + } | |
| 562 | + } | |
| 563 | + }; | |
| 564 | + for (var _i = 0, entries_1 = entries; _i < entries_1.length; _i++) { | |
| 565 | + var _c = entries_1[_i], key = _c[0], nestedValue = _c[1]; | |
| 566 | + var state_2 = _loop_2(key, nestedValue); | |
| 567 | + if (typeof state_2 === "object") | |
| 568 | + return state_2.value; | |
| 569 | + } | |
| 570 | + if (cache && isNestedFrozen(value)) | |
| 571 | + cache.add(value); | |
| 572 | + return false; | |
| 573 | +} | |
| 574 | +function isNestedFrozen(value) { | |
| 575 | + if (!Object.isFrozen(value)) | |
| 576 | + return false; | |
| 577 | + for (var _i = 0, _c = Object.values(value); _i < _c.length; _i++) { | |
| 578 | + var nestedValue = _c[_i]; | |
| 579 | + if (typeof nestedValue !== "object" || nestedValue === null) | |
| 580 | + continue; | |
| 581 | + if (!isNestedFrozen(nestedValue)) | |
| 582 | + return false; | |
| 583 | + } | |
| 584 | + return true; | |
| 585 | +} | |
| 586 | +function createSerializableStateInvariantMiddleware(options) { | |
| 587 | + if (options === void 0) { options = {}; } | |
| 588 | + if (false) {} | |
| 589 | + var _c = options.isSerializable, isSerializable = _c === void 0 ? isPlain : _c, getEntries = options.getEntries, _d = options.ignoredActions, ignoredActions = _d === void 0 ? [] : _d, _e = options.ignoredActionPaths, ignoredActionPaths = _e === void 0 ? ["meta.arg", "meta.baseQueryMeta"] : _e, _f = options.ignoredPaths, ignoredPaths = _f === void 0 ? [] : _f, _g = options.warnAfter, warnAfter = _g === void 0 ? 32 : _g, _h = options.ignoreState, ignoreState = _h === void 0 ? false : _h, _j = options.ignoreActions, ignoreActions = _j === void 0 ? false : _j, _k = options.disableCache, disableCache = _k === void 0 ? false : _k; | |
| 590 | + var cache = !disableCache && WeakSet ? new WeakSet() : void 0; | |
| 591 | + return function (storeAPI) { return function (next) { return function (action) { | |
| 592 | + var result = next(action); | |
| 593 | + var measureUtils = getTimeMeasureUtils(warnAfter, "SerializableStateInvariantMiddleware"); | |
| 594 | + if (!ignoreActions && !(ignoredActions.length && ignoredActions.indexOf(action.type) !== -1)) { | |
| 595 | + measureUtils.measureTime(function () { | |
| 596 | + var foundActionNonSerializableValue = findNonSerializableValue(action, "", isSerializable, getEntries, ignoredActionPaths, cache); | |
| 597 | + if (foundActionNonSerializableValue) { | |
| 598 | + var keyPath = foundActionNonSerializableValue.keyPath, value = foundActionNonSerializableValue.value; | |
| 599 | + console.error("A non-serializable value was detected in an action, in the path: `" + keyPath + "`. Value:", value, "\nTake a look at the logic that dispatched this action: ", action, "\n(See https://redux.js.org/faq/actions#why-should-type-be-a-string-or-at-least-serializable-why-should-my-action-types-be-constants)", "\n(To allow non-serializable values see: https://redux-toolkit.js.org/usage/usage-guide#working-with-non-serializable-data)"); | |
| 600 | + } | |
| 601 | + }); | |
| 602 | + } | |
| 603 | + if (!ignoreState) { | |
| 604 | + measureUtils.measureTime(function () { | |
| 605 | + var state = storeAPI.getState(); | |
| 606 | + var foundStateNonSerializableValue = findNonSerializableValue(state, "", isSerializable, getEntries, ignoredPaths, cache); | |
| 607 | + if (foundStateNonSerializableValue) { | |
| 608 | + var keyPath = foundStateNonSerializableValue.keyPath, value = foundStateNonSerializableValue.value; | |
| 609 | + console.error("A non-serializable value was detected in the state, in the path: `" + keyPath + "`. Value:", value, "\nTake a look at the reducer(s) handling this action type: " + action.type + ".\n(See https://redux.js.org/faq/organizing-state#can-i-put-functions-promises-or-other-non-serializable-items-in-my-store-state)"); | |
| 610 | + } | |
| 611 | + }); | |
| 612 | + measureUtils.warnIfExceeded(); | |
| 613 | + } | |
| 614 | + return result; | |
| 615 | + }; }; }; | |
| 616 | +} | |
| 617 | +// src/getDefaultMiddleware.ts | |
| 618 | +function isBoolean(x) { | |
| 619 | + return typeof x === "boolean"; | |
| 620 | +} | |
| 621 | +function curryGetDefaultMiddleware() { | |
| 622 | + return function curriedGetDefaultMiddleware(options) { | |
| 623 | + return getDefaultMiddleware(options); | |
| 624 | + }; | |
| 625 | +} | |
| 626 | +function getDefaultMiddleware(options) { | |
| 627 | + if (options === void 0) { options = {}; } | |
| 628 | + var _c = options.thunk, thunk = _c === void 0 ? true : _c, _d = options.immutableCheck, immutableCheck = _d === void 0 ? true : _d, _e = options.serializableCheck, serializableCheck = _e === void 0 ? true : _e, _f = options.actionCreatorCheck, actionCreatorCheck = _f === void 0 ? true : _f; | |
| 629 | + var middlewareArray = new MiddlewareArray(); | |
| 630 | + if (thunk) { | |
| 631 | + if (isBoolean(thunk)) { | |
| 632 | + middlewareArray.push(redux_thunk__WEBPACK_IMPORTED_MODULE_3__["default"]); | |
| 633 | + } | |
| 634 | + else { | |
| 635 | + middlewareArray.push(redux_thunk__WEBPACK_IMPORTED_MODULE_3__["default"].withExtraArgument(thunk.extraArgument)); | |
| 636 | + } | |
| 637 | + } | |
| 638 | + if (true) { | |
| 639 | + if (immutableCheck) { | |
| 640 | + var immutableOptions = {}; | |
| 641 | + if (!isBoolean(immutableCheck)) { | |
| 642 | + immutableOptions = immutableCheck; | |
| 643 | + } | |
| 644 | + middlewareArray.unshift(createImmutableStateInvariantMiddleware(immutableOptions)); | |
| 645 | + } | |
| 646 | + if (serializableCheck) { | |
| 647 | + var serializableOptions = {}; | |
| 648 | + if (!isBoolean(serializableCheck)) { | |
| 649 | + serializableOptions = serializableCheck; | |
| 650 | + } | |
| 651 | + middlewareArray.push(createSerializableStateInvariantMiddleware(serializableOptions)); | |
| 652 | + } | |
| 653 | + if (actionCreatorCheck) { | |
| 654 | + var actionCreatorOptions = {}; | |
| 655 | + if (!isBoolean(actionCreatorCheck)) { | |
| 656 | + actionCreatorOptions = actionCreatorCheck; | |
| 657 | + } | |
| 658 | + middlewareArray.unshift(createActionCreatorInvariantMiddleware(actionCreatorOptions)); | |
| 659 | + } | |
| 660 | + } | |
| 661 | + return middlewareArray; | |
| 662 | +} | |
| 663 | +// src/configureStore.ts | |
| 664 | +var IS_PRODUCTION = "development" === "production"; | |
| 665 | +function configureStore(options) { | |
| 666 | + var curriedGetDefaultMiddleware = curryGetDefaultMiddleware(); | |
| 667 | + var _c = options || {}, _d = _c.reducer, reducer = _d === void 0 ? void 0 : _d, _e = _c.middleware, middleware = _e === void 0 ? curriedGetDefaultMiddleware() : _e, _f = _c.devTools, devTools = _f === void 0 ? true : _f, _g = _c.preloadedState, preloadedState = _g === void 0 ? void 0 : _g, _h = _c.enhancers, enhancers = _h === void 0 ? void 0 : _h; | |
| 668 | + var rootReducer; | |
| 669 | + if (typeof reducer === "function") { | |
| 670 | + rootReducer = reducer; | |
| 671 | + } | |
| 672 | + else if (isPlainObject(reducer)) { | |
| 673 | + rootReducer = (0,redux__WEBPACK_IMPORTED_MODULE_0__.combineReducers)(reducer); | |
| 674 | + } | |
| 675 | + else { | |
| 676 | + throw new Error('"reducer" is a required argument, and must be a function or an object of functions that can be passed to combineReducers'); | |
| 677 | + } | |
| 678 | + var finalMiddleware = middleware; | |
| 679 | + if (typeof finalMiddleware === "function") { | |
| 680 | + finalMiddleware = finalMiddleware(curriedGetDefaultMiddleware); | |
| 681 | + if (!IS_PRODUCTION && !Array.isArray(finalMiddleware)) { | |
| 682 | + throw new Error("when using a middleware builder function, an array of middleware must be returned"); | |
| 683 | + } | |
| 684 | + } | |
| 685 | + if (!IS_PRODUCTION && finalMiddleware.some(function (item) { return typeof item !== "function"; })) { | |
| 686 | + throw new Error("each middleware provided to configureStore must be a function"); | |
| 687 | + } | |
| 688 | + var middlewareEnhancer = redux__WEBPACK_IMPORTED_MODULE_0__.applyMiddleware.apply(void 0, finalMiddleware); | |
| 689 | + var finalCompose = redux__WEBPACK_IMPORTED_MODULE_0__.compose; | |
| 690 | + if (devTools) { | |
| 691 | + finalCompose = composeWithDevTools(__spreadValues({ | |
| 692 | + trace: !IS_PRODUCTION | |
| 693 | + }, typeof devTools === "object" && devTools)); | |
| 694 | + } | |
| 695 | + var defaultEnhancers = new EnhancerArray(middlewareEnhancer); | |
| 696 | + var storeEnhancers = defaultEnhancers; | |
| 697 | + if (Array.isArray(enhancers)) { | |
| 698 | + storeEnhancers = __spreadArray([middlewareEnhancer], enhancers); | |
| 699 | + } | |
| 700 | + else if (typeof enhancers === "function") { | |
| 701 | + storeEnhancers = enhancers(defaultEnhancers); | |
| 702 | + } | |
| 703 | + var composedEnhancer = finalCompose.apply(void 0, storeEnhancers); | |
| 704 | + return (0,redux__WEBPACK_IMPORTED_MODULE_0__.createStore)(rootReducer, preloadedState, composedEnhancer); | |
| 705 | +} | |
| 706 | +// src/createReducer.ts | |
| 707 | + | |
| 708 | +// src/mapBuilders.ts | |
| 709 | +function executeReducerBuilderCallback(builderCallback) { | |
| 710 | + var actionsMap = {}; | |
| 711 | + var actionMatchers = []; | |
| 712 | + var defaultCaseReducer; | |
| 713 | + var builder = { | |
| 714 | + addCase: function (typeOrActionCreator, reducer) { | |
| 715 | + if (true) { | |
| 716 | + if (actionMatchers.length > 0) { | |
| 717 | + throw new Error("`builder.addCase` should only be called before calling `builder.addMatcher`"); | |
| 718 | + } | |
| 719 | + if (defaultCaseReducer) { | |
| 720 | + throw new Error("`builder.addCase` should only be called before calling `builder.addDefaultCase`"); | |
| 721 | + } | |
| 722 | + } | |
| 723 | + var type = typeof typeOrActionCreator === "string" ? typeOrActionCreator : typeOrActionCreator.type; | |
| 724 | + if (!type) { | |
| 725 | + throw new Error("`builder.addCase` cannot be called with an empty action type"); | |
| 726 | + } | |
| 727 | + if (type in actionsMap) { | |
| 728 | + throw new Error("`builder.addCase` cannot be called with two reducers for the same action type"); | |
| 729 | + } | |
| 730 | + actionsMap[type] = reducer; | |
| 731 | + return builder; | |
| 732 | + }, | |
| 733 | + addMatcher: function (matcher, reducer) { | |
| 734 | + if (true) { | |
| 735 | + if (defaultCaseReducer) { | |
| 736 | + throw new Error("`builder.addMatcher` should only be called before calling `builder.addDefaultCase`"); | |
| 737 | + } | |
| 738 | + } | |
| 739 | + actionMatchers.push({ matcher: matcher, reducer: reducer }); | |
| 740 | + return builder; | |
| 741 | + }, | |
| 742 | + addDefaultCase: function (reducer) { | |
| 743 | + if (true) { | |
| 744 | + if (defaultCaseReducer) { | |
| 745 | + throw new Error("`builder.addDefaultCase` can only be called once"); | |
| 746 | + } | |
| 747 | + } | |
| 748 | + defaultCaseReducer = reducer; | |
| 749 | + return builder; | |
| 750 | + } | |
| 751 | + }; | |
| 752 | + builderCallback(builder); | |
| 753 | + return [actionsMap, actionMatchers, defaultCaseReducer]; | |
| 754 | +} | |
| 755 | +// src/createReducer.ts | |
| 756 | +function isStateFunction(x) { | |
| 757 | + return typeof x === "function"; | |
| 758 | +} | |
| 759 | +var hasWarnedAboutObjectNotation = false; | |
| 760 | +function createReducer(initialState, mapOrBuilderCallback, actionMatchers, defaultCaseReducer) { | |
| 761 | + if (actionMatchers === void 0) { actionMatchers = []; } | |
| 762 | + if (true) { | |
| 763 | + if (typeof mapOrBuilderCallback === "object") { | |
| 764 | + if (!hasWarnedAboutObjectNotation) { | |
| 765 | + hasWarnedAboutObjectNotation = true; | |
| 766 | + console.warn("The object notation for `createReducer` is deprecated, and will be removed in RTK 2.0. Please use the 'builder callback' notation instead: https://redux-toolkit.js.org/api/createReducer"); | |
| 767 | + } | |
| 768 | + } | |
| 769 | + } | |
| 770 | + var _c = typeof mapOrBuilderCallback === "function" ? executeReducerBuilderCallback(mapOrBuilderCallback) : [mapOrBuilderCallback, actionMatchers, defaultCaseReducer], actionsMap = _c[0], finalActionMatchers = _c[1], finalDefaultCaseReducer = _c[2]; | |
| 771 | + var getInitialState; | |
| 772 | + if (isStateFunction(initialState)) { | |
| 773 | + getInitialState = function () { return freezeDraftable(initialState()); }; | |
| 774 | + } | |
| 775 | + else { | |
| 776 | + var frozenInitialState_1 = freezeDraftable(initialState); | |
| 777 | + getInitialState = function () { return frozenInitialState_1; }; | |
| 778 | + } | |
| 779 | + function reducer(state, action) { | |
| 780 | + if (state === void 0) { state = getInitialState(); } | |
| 781 | + var caseReducers = __spreadArray([ | |
| 782 | + actionsMap[action.type] | |
| 783 | + ], finalActionMatchers.filter(function (_c) { | |
| 784 | + var matcher = _c.matcher; | |
| 785 | + return matcher(action); | |
| 786 | + }).map(function (_c) { | |
| 787 | + var reducer2 = _c.reducer; | |
| 788 | + return reducer2; | |
| 789 | + })); | |
| 790 | + if (caseReducers.filter(function (cr) { return !!cr; }).length === 0) { | |
| 791 | + caseReducers = [finalDefaultCaseReducer]; | |
| 792 | + } | |
| 793 | + return caseReducers.reduce(function (previousState, caseReducer) { | |
| 794 | + if (caseReducer) { | |
| 795 | + if ((0,immer__WEBPACK_IMPORTED_MODULE_2__.isDraft)(previousState)) { | |
| 796 | + var draft = previousState; | |
| 797 | + var result = caseReducer(draft, action); | |
| 798 | + if (result === void 0) { | |
| 799 | + return previousState; | |
| 800 | + } | |
| 801 | + return result; | |
| 802 | + } | |
| 803 | + else if (!(0,immer__WEBPACK_IMPORTED_MODULE_2__.isDraftable)(previousState)) { | |
| 804 | + var result = caseReducer(previousState, action); | |
| 805 | + if (result === void 0) { | |
| 806 | + if (previousState === null) { | |
| 807 | + return previousState; | |
| 808 | + } | |
| 809 | + throw Error("A case reducer on a non-draftable value must not return undefined"); | |
| 810 | + } | |
| 811 | + return result; | |
| 812 | + } | |
| 813 | + else { | |
| 814 | + return (0,immer__WEBPACK_IMPORTED_MODULE_2__["default"])(previousState, function (draft) { | |
| 815 | + return caseReducer(draft, action); | |
| 816 | + }); | |
| 817 | + } | |
| 818 | + } | |
| 819 | + return previousState; | |
| 820 | + }, state); | |
| 821 | + } | |
| 822 | + reducer.getInitialState = getInitialState; | |
| 823 | + return reducer; | |
| 824 | +} | |
| 825 | +// src/createSlice.ts | |
| 826 | +var hasWarnedAboutObjectNotation2 = false; | |
| 827 | +function getType2(slice, actionKey) { | |
| 828 | + return slice + "/" + actionKey; | |
| 829 | +} | |
| 830 | +function createSlice(options) { | |
| 831 | + var name = options.name; | |
| 832 | + if (!name) { | |
| 833 | + throw new Error("`name` is a required option for createSlice"); | |
| 834 | + } | |
| 835 | + if (typeof process !== "undefined" && "development" === "development") { | |
| 836 | + if (options.initialState === void 0) { | |
| 837 | + console.error("You must provide an `initialState` value that is not `undefined`. You may have misspelled `initialState`"); | |
| 838 | + } | |
| 839 | + } | |
| 840 | + var initialState = typeof options.initialState == "function" ? options.initialState : freezeDraftable(options.initialState); | |
| 841 | + var reducers = options.reducers || {}; | |
| 842 | + var reducerNames = Object.keys(reducers); | |
| 843 | + var sliceCaseReducersByName = {}; | |
| 844 | + var sliceCaseReducersByType = {}; | |
| 845 | + var actionCreators = {}; | |
| 846 | + reducerNames.forEach(function (reducerName) { | |
| 847 | + var maybeReducerWithPrepare = reducers[reducerName]; | |
| 848 | + var type = getType2(name, reducerName); | |
| 849 | + var caseReducer; | |
| 850 | + var prepareCallback; | |
| 851 | + if ("reducer" in maybeReducerWithPrepare) { | |
| 852 | + caseReducer = maybeReducerWithPrepare.reducer; | |
| 853 | + prepareCallback = maybeReducerWithPrepare.prepare; | |
| 854 | + } | |
| 855 | + else { | |
| 856 | + caseReducer = maybeReducerWithPrepare; | |
| 857 | + } | |
| 858 | + sliceCaseReducersByName[reducerName] = caseReducer; | |
| 859 | + sliceCaseReducersByType[type] = caseReducer; | |
| 860 | + actionCreators[reducerName] = prepareCallback ? createAction(type, prepareCallback) : createAction(type); | |
| 861 | + }); | |
| 862 | + function buildReducer() { | |
| 863 | + if (true) { | |
| 864 | + if (typeof options.extraReducers === "object") { | |
| 865 | + if (!hasWarnedAboutObjectNotation2) { | |
| 866 | + hasWarnedAboutObjectNotation2 = true; | |
| 867 | + console.warn("The object notation for `createSlice.extraReducers` is deprecated, and will be removed in RTK 2.0. Please use the 'builder callback' notation instead: https://redux-toolkit.js.org/api/createSlice"); | |
| 868 | + } | |
| 869 | + } | |
| 870 | + } | |
| 871 | + var _c = typeof options.extraReducers === "function" ? executeReducerBuilderCallback(options.extraReducers) : [options.extraReducers], _d = _c[0], extraReducers = _d === void 0 ? {} : _d, _e = _c[1], actionMatchers = _e === void 0 ? [] : _e, _f = _c[2], defaultCaseReducer = _f === void 0 ? void 0 : _f; | |
| 872 | + var finalCaseReducers = __spreadValues(__spreadValues({}, extraReducers), sliceCaseReducersByType); | |
| 873 | + return createReducer(initialState, function (builder) { | |
| 874 | + for (var key in finalCaseReducers) { | |
| 875 | + builder.addCase(key, finalCaseReducers[key]); | |
| 876 | + } | |
| 877 | + for (var _i = 0, actionMatchers_1 = actionMatchers; _i < actionMatchers_1.length; _i++) { | |
| 878 | + var m = actionMatchers_1[_i]; | |
| 879 | + builder.addMatcher(m.matcher, m.reducer); | |
| 880 | + } | |
| 881 | + if (defaultCaseReducer) { | |
| 882 | + builder.addDefaultCase(defaultCaseReducer); | |
| 883 | + } | |
| 884 | + }); | |
| 885 | + } | |
| 886 | + var _reducer; | |
| 887 | + return { | |
| 888 | + name: name, | |
| 889 | + reducer: function (state, action) { | |
| 890 | + if (!_reducer) | |
| 891 | + _reducer = buildReducer(); | |
| 892 | + return _reducer(state, action); | |
| 893 | + }, | |
| 894 | + actions: actionCreators, | |
| 895 | + caseReducers: sliceCaseReducersByName, | |
| 896 | + getInitialState: function () { | |
| 897 | + if (!_reducer) | |
| 898 | + _reducer = buildReducer(); | |
| 899 | + return _reducer.getInitialState(); | |
| 900 | + } | |
| 901 | + }; | |
| 902 | +} | |
| 903 | +// src/entities/entity_state.ts | |
| 904 | +function getInitialEntityState() { | |
| 905 | + return { | |
| 906 | + ids: [], | |
| 907 | + entities: {} | |
| 908 | + }; | |
| 909 | +} | |
| 910 | +function createInitialStateFactory() { | |
| 911 | + function getInitialState(additionalState) { | |
| 912 | + if (additionalState === void 0) { additionalState = {}; } | |
| 913 | + return Object.assign(getInitialEntityState(), additionalState); | |
| 914 | + } | |
| 915 | + return { getInitialState: getInitialState }; | |
| 916 | +} | |
| 917 | +// src/entities/state_selectors.ts | |
| 918 | +function createSelectorsFactory() { | |
| 919 | + function getSelectors(selectState) { | |
| 920 | + var selectIds = function (state) { return state.ids; }; | |
| 921 | + var selectEntities = function (state) { return state.entities; }; | |
| 922 | + var selectAll = createDraftSafeSelector(selectIds, selectEntities, function (ids, entities) { return ids.map(function (id) { return entities[id]; }); }); | |
| 923 | + var selectId = function (_, id) { return id; }; | |
| 924 | + var selectById = function (entities, id) { return entities[id]; }; | |
| 925 | + var selectTotal = createDraftSafeSelector(selectIds, function (ids) { return ids.length; }); | |
| 926 | + if (!selectState) { | |
| 927 | + return { | |
| 928 | + selectIds: selectIds, | |
| 929 | + selectEntities: selectEntities, | |
| 930 | + selectAll: selectAll, | |
| 931 | + selectTotal: selectTotal, | |
| 932 | + selectById: createDraftSafeSelector(selectEntities, selectId, selectById) | |
| 933 | + }; | |
| 934 | + } | |
| 935 | + var selectGlobalizedEntities = createDraftSafeSelector(selectState, selectEntities); | |
| 936 | + return { | |
| 937 | + selectIds: createDraftSafeSelector(selectState, selectIds), | |
| 938 | + selectEntities: selectGlobalizedEntities, | |
| 939 | + selectAll: createDraftSafeSelector(selectState, selectAll), | |
| 940 | + selectTotal: createDraftSafeSelector(selectState, selectTotal), | |
| 941 | + selectById: createDraftSafeSelector(selectGlobalizedEntities, selectId, selectById) | |
| 942 | + }; | |
| 943 | + } | |
| 944 | + return { getSelectors: getSelectors }; | |
| 945 | +} | |
| 946 | +// src/entities/state_adapter.ts | |
| 947 | + | |
| 948 | +function createSingleArgumentStateOperator(mutator) { | |
| 949 | + var operator = createStateOperator(function (_, state) { return mutator(state); }); | |
| 950 | + return function operation(state) { | |
| 951 | + return operator(state, void 0); | |
| 952 | + }; | |
| 953 | +} | |
| 954 | +function createStateOperator(mutator) { | |
| 955 | + return function operation(state, arg) { | |
| 956 | + function isPayloadActionArgument(arg2) { | |
| 957 | + return isFSA(arg2); | |
| 958 | + } | |
| 959 | + var runMutator = function (draft) { | |
| 960 | + if (isPayloadActionArgument(arg)) { | |
| 961 | + mutator(arg.payload, draft); | |
| 962 | + } | |
| 963 | + else { | |
| 964 | + mutator(arg, draft); | |
| 965 | + } | |
| 966 | + }; | |
| 967 | + if ((0,immer__WEBPACK_IMPORTED_MODULE_2__.isDraft)(state)) { | |
| 968 | + runMutator(state); | |
| 969 | + return state; | |
| 970 | + } | |
| 971 | + else { | |
| 972 | + return (0,immer__WEBPACK_IMPORTED_MODULE_2__["default"])(state, runMutator); | |
| 973 | + } | |
| 974 | + }; | |
| 975 | +} | |
| 976 | +// src/entities/utils.ts | |
| 977 | +function selectIdValue(entity, selectId) { | |
| 978 | + var key = selectId(entity); | |
| 979 | + if ( true && key === void 0) { | |
| 980 | + console.warn("The entity passed to the `selectId` implementation returned undefined.", "You should probably provide your own `selectId` implementation.", "The entity that was passed:", entity, "The `selectId` implementation:", selectId.toString()); | |
| 981 | + } | |
| 982 | + return key; | |
| 983 | +} | |
| 984 | +function ensureEntitiesArray(entities) { | |
| 985 | + if (!Array.isArray(entities)) { | |
| 986 | + entities = Object.values(entities); | |
| 987 | + } | |
| 988 | + return entities; | |
| 989 | +} | |
| 990 | +function splitAddedUpdatedEntities(newEntities, selectId, state) { | |
| 991 | + newEntities = ensureEntitiesArray(newEntities); | |
| 992 | + var added = []; | |
| 993 | + var updated = []; | |
| 994 | + for (var _i = 0, newEntities_1 = newEntities; _i < newEntities_1.length; _i++) { | |
| 995 | + var entity = newEntities_1[_i]; | |
| 996 | + var id = selectIdValue(entity, selectId); | |
| 997 | + if (id in state.entities) { | |
| 998 | + updated.push({ id: id, changes: entity }); | |
| 999 | + } | |
| 1000 | + else { | |
| 1001 | + added.push(entity); | |
| 1002 | + } | |
| 1003 | + } | |
| 1004 | + return [added, updated]; | |
| 1005 | +} | |
| 1006 | +// src/entities/unsorted_state_adapter.ts | |
| 1007 | +function createUnsortedStateAdapter(selectId) { | |
| 1008 | + function addOneMutably(entity, state) { | |
| 1009 | + var key = selectIdValue(entity, selectId); | |
| 1010 | + if (key in state.entities) { | |
| 1011 | + return; | |
| 1012 | + } | |
| 1013 | + state.ids.push(key); | |
| 1014 | + state.entities[key] = entity; | |
| 1015 | + } | |
| 1016 | + function addManyMutably(newEntities, state) { | |
| 1017 | + newEntities = ensureEntitiesArray(newEntities); | |
| 1018 | + for (var _i = 0, newEntities_2 = newEntities; _i < newEntities_2.length; _i++) { | |
| 1019 | + var entity = newEntities_2[_i]; | |
| 1020 | + addOneMutably(entity, state); | |
| 1021 | + } | |
| 1022 | + } | |
| 1023 | + function setOneMutably(entity, state) { | |
| 1024 | + var key = selectIdValue(entity, selectId); | |
| 1025 | + if (!(key in state.entities)) { | |
| 1026 | + state.ids.push(key); | |
| 1027 | + } | |
| 1028 | + state.entities[key] = entity; | |
| 1029 | + } | |
| 1030 | + function setManyMutably(newEntities, state) { | |
| 1031 | + newEntities = ensureEntitiesArray(newEntities); | |
| 1032 | + for (var _i = 0, newEntities_3 = newEntities; _i < newEntities_3.length; _i++) { | |
| 1033 | + var entity = newEntities_3[_i]; | |
| 1034 | + setOneMutably(entity, state); | |
| 1035 | + } | |
| 1036 | + } | |
| 1037 | + function setAllMutably(newEntities, state) { | |
| 1038 | + newEntities = ensureEntitiesArray(newEntities); | |
| 1039 | + state.ids = []; | |
| 1040 | + state.entities = {}; | |
| 1041 | + addManyMutably(newEntities, state); | |
| 1042 | + } | |
| 1043 | + function removeOneMutably(key, state) { | |
| 1044 | + return removeManyMutably([key], state); | |
| 1045 | + } | |
| 1046 | + function removeManyMutably(keys, state) { | |
| 1047 | + var didMutate = false; | |
| 1048 | + keys.forEach(function (key) { | |
| 1049 | + if (key in state.entities) { | |
| 1050 | + delete state.entities[key]; | |
| 1051 | + didMutate = true; | |
| 1052 | + } | |
| 1053 | + }); | |
| 1054 | + if (didMutate) { | |
| 1055 | + state.ids = state.ids.filter(function (id) { return id in state.entities; }); | |
| 1056 | + } | |
| 1057 | + } | |
| 1058 | + function removeAllMutably(state) { | |
| 1059 | + Object.assign(state, { | |
| 1060 | + ids: [], | |
| 1061 | + entities: {} | |
| 1062 | + }); | |
| 1063 | + } | |
| 1064 | + function takeNewKey(keys, update, state) { | |
| 1065 | + var original2 = state.entities[update.id]; | |
| 1066 | + var updated = Object.assign({}, original2, update.changes); | |
| 1067 | + var newKey = selectIdValue(updated, selectId); | |
| 1068 | + var hasNewKey = newKey !== update.id; | |
| 1069 | + if (hasNewKey) { | |
| 1070 | + keys[update.id] = newKey; | |
| 1071 | + delete state.entities[update.id]; | |
| 1072 | + } | |
| 1073 | + state.entities[newKey] = updated; | |
| 1074 | + return hasNewKey; | |
| 1075 | + } | |
| 1076 | + function updateOneMutably(update, state) { | |
| 1077 | + return updateManyMutably([update], state); | |
| 1078 | + } | |
| 1079 | + function updateManyMutably(updates, state) { | |
| 1080 | + var newKeys = {}; | |
| 1081 | + var updatesPerEntity = {}; | |
| 1082 | + updates.forEach(function (update) { | |
| 1083 | + if (update.id in state.entities) { | |
| 1084 | + updatesPerEntity[update.id] = { | |
| 1085 | + id: update.id, | |
| 1086 | + changes: __spreadValues(__spreadValues({}, updatesPerEntity[update.id] ? updatesPerEntity[update.id].changes : null), update.changes) | |
| 1087 | + }; | |
| 1088 | + } | |
| 1089 | + }); | |
| 1090 | + updates = Object.values(updatesPerEntity); | |
| 1091 | + var didMutateEntities = updates.length > 0; | |
| 1092 | + if (didMutateEntities) { | |
| 1093 | + var didMutateIds = updates.filter(function (update) { return takeNewKey(newKeys, update, state); }).length > 0; | |
| 1094 | + if (didMutateIds) { | |
| 1095 | + state.ids = Object.keys(state.entities); | |
| 1096 | + } | |
| 1097 | + } | |
| 1098 | + } | |
| 1099 | + function upsertOneMutably(entity, state) { | |
| 1100 | + return upsertManyMutably([entity], state); | |
| 1101 | + } | |
| 1102 | + function upsertManyMutably(newEntities, state) { | |
| 1103 | + var _c = splitAddedUpdatedEntities(newEntities, selectId, state), added = _c[0], updated = _c[1]; | |
| 1104 | + updateManyMutably(updated, state); | |
| 1105 | + addManyMutably(added, state); | |
| 1106 | + } | |
| 1107 | + return { | |
| 1108 | + removeAll: createSingleArgumentStateOperator(removeAllMutably), | |
| 1109 | + addOne: createStateOperator(addOneMutably), | |
| 1110 | + addMany: createStateOperator(addManyMutably), | |
| 1111 | + setOne: createStateOperator(setOneMutably), | |
| 1112 | + setMany: createStateOperator(setManyMutably), | |
| 1113 | + setAll: createStateOperator(setAllMutably), | |
| 1114 | + updateOne: createStateOperator(updateOneMutably), | |
| 1115 | + updateMany: createStateOperator(updateManyMutably), | |
| 1116 | + upsertOne: createStateOperator(upsertOneMutably), | |
| 1117 | + upsertMany: createStateOperator(upsertManyMutably), | |
| 1118 | + removeOne: createStateOperator(removeOneMutably), | |
| 1119 | + removeMany: createStateOperator(removeManyMutably) | |
| 1120 | + }; | |
| 1121 | +} | |
| 1122 | +// src/entities/sorted_state_adapter.ts | |
| 1123 | +function createSortedStateAdapter(selectId, sort) { | |
| 1124 | + var _c = createUnsortedStateAdapter(selectId), removeOne = _c.removeOne, removeMany = _c.removeMany, removeAll = _c.removeAll; | |
| 1125 | + function addOneMutably(entity, state) { | |
| 1126 | + return addManyMutably([entity], state); | |
| 1127 | + } | |
| 1128 | + function addManyMutably(newEntities, state) { | |
| 1129 | + newEntities = ensureEntitiesArray(newEntities); | |
| 1130 | + var models = newEntities.filter(function (model) { return !(selectIdValue(model, selectId) in state.entities); }); | |
| 1131 | + if (models.length !== 0) { | |
| 1132 | + merge(models, state); | |
| 1133 | + } | |
| 1134 | + } | |
| 1135 | + function setOneMutably(entity, state) { | |
| 1136 | + return setManyMutably([entity], state); | |
| 1137 | + } | |
| 1138 | + function setManyMutably(newEntities, state) { | |
| 1139 | + newEntities = ensureEntitiesArray(newEntities); | |
| 1140 | + if (newEntities.length !== 0) { | |
| 1141 | + merge(newEntities, state); | |
| 1142 | + } | |
| 1143 | + } | |
| 1144 | + function setAllMutably(newEntities, state) { | |
| 1145 | + newEntities = ensureEntitiesArray(newEntities); | |
| 1146 | + state.entities = {}; | |
| 1147 | + state.ids = []; | |
| 1148 | + addManyMutably(newEntities, state); | |
| 1149 | + } | |
| 1150 | + function updateOneMutably(update, state) { | |
| 1151 | + return updateManyMutably([update], state); | |
| 1152 | + } | |
| 1153 | + function updateManyMutably(updates, state) { | |
| 1154 | + var appliedUpdates = false; | |
| 1155 | + for (var _i = 0, updates_1 = updates; _i < updates_1.length; _i++) { | |
| 1156 | + var update = updates_1[_i]; | |
| 1157 | + var entity = state.entities[update.id]; | |
| 1158 | + if (!entity) { | |
| 1159 | + continue; | |
| 1160 | + } | |
| 1161 | + appliedUpdates = true; | |
| 1162 | + Object.assign(entity, update.changes); | |
| 1163 | + var newId = selectId(entity); | |
| 1164 | + if (update.id !== newId) { | |
| 1165 | + delete state.entities[update.id]; | |
| 1166 | + state.entities[newId] = entity; | |
| 1167 | + } | |
| 1168 | + } | |
| 1169 | + if (appliedUpdates) { | |
| 1170 | + resortEntities(state); | |
| 1171 | + } | |
| 1172 | + } | |
| 1173 | + function upsertOneMutably(entity, state) { | |
| 1174 | + return upsertManyMutably([entity], state); | |
| 1175 | + } | |
| 1176 | + function upsertManyMutably(newEntities, state) { | |
| 1177 | + var _c = splitAddedUpdatedEntities(newEntities, selectId, state), added = _c[0], updated = _c[1]; | |
| 1178 | + updateManyMutably(updated, state); | |
| 1179 | + addManyMutably(added, state); | |
| 1180 | + } | |
| 1181 | + function areArraysEqual(a, b) { | |
| 1182 | + if (a.length !== b.length) { | |
| 1183 | + return false; | |
| 1184 | + } | |
| 1185 | + for (var i = 0; i < a.length && i < b.length; i++) { | |
| 1186 | + if (a[i] === b[i]) { | |
| 1187 | + continue; | |
| 1188 | + } | |
| 1189 | + return false; | |
| 1190 | + } | |
| 1191 | + return true; | |
| 1192 | + } | |
| 1193 | + function merge(models, state) { | |
| 1194 | + models.forEach(function (model) { | |
| 1195 | + state.entities[selectId(model)] = model; | |
| 1196 | + }); | |
| 1197 | + resortEntities(state); | |
| 1198 | + } | |
| 1199 | + function resortEntities(state) { | |
| 1200 | + var allEntities = Object.values(state.entities); | |
| 1201 | + allEntities.sort(sort); | |
| 1202 | + var newSortedIds = allEntities.map(selectId); | |
| 1203 | + var ids = state.ids; | |
| 1204 | + if (!areArraysEqual(ids, newSortedIds)) { | |
| 1205 | + state.ids = newSortedIds; | |
| 1206 | + } | |
| 1207 | + } | |
| 1208 | + return { | |
| 1209 | + removeOne: removeOne, | |
| 1210 | + removeMany: removeMany, | |
| 1211 | + removeAll: removeAll, | |
| 1212 | + addOne: createStateOperator(addOneMutably), | |
| 1213 | + updateOne: createStateOperator(updateOneMutably), | |
| 1214 | + upsertOne: createStateOperator(upsertOneMutably), | |
| 1215 | + setOne: createStateOperator(setOneMutably), | |
| 1216 | + setMany: createStateOperator(setManyMutably), | |
| 1217 | + setAll: createStateOperator(setAllMutably), | |
| 1218 | + addMany: createStateOperator(addManyMutably), | |
| 1219 | + updateMany: createStateOperator(updateManyMutably), | |
| 1220 | + upsertMany: createStateOperator(upsertManyMutably) | |
| 1221 | + }; | |
| 1222 | +} | |
| 1223 | +// src/entities/create_adapter.ts | |
| 1224 | +function createEntityAdapter(options) { | |
| 1225 | + if (options === void 0) { options = {}; } | |
| 1226 | + var _c = __spreadValues({ | |
| 1227 | + sortComparer: false, | |
| 1228 | + selectId: function (instance) { return instance.id; } | |
| 1229 | + }, options), selectId = _c.selectId, sortComparer = _c.sortComparer; | |
| 1230 | + var stateFactory = createInitialStateFactory(); | |
| 1231 | + var selectorsFactory = createSelectorsFactory(); | |
| 1232 | + var stateAdapter = sortComparer ? createSortedStateAdapter(selectId, sortComparer) : createUnsortedStateAdapter(selectId); | |
| 1233 | + return __spreadValues(__spreadValues(__spreadValues({ | |
| 1234 | + selectId: selectId, | |
| 1235 | + sortComparer: sortComparer | |
| 1236 | + }, stateFactory), selectorsFactory), stateAdapter); | |
| 1237 | +} | |
| 1238 | +// src/nanoid.ts | |
| 1239 | +var urlAlphabet = "ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW"; | |
| 1240 | +var nanoid = function (size) { | |
| 1241 | + if (size === void 0) { size = 21; } | |
| 1242 | + var id = ""; | |
| 1243 | + var i = size; | |
| 1244 | + while (i--) { | |
| 1245 | + id += urlAlphabet[Math.random() * 64 | 0]; | |
| 1246 | + } | |
| 1247 | + return id; | |
| 1248 | +}; | |
| 1249 | +// src/createAsyncThunk.ts | |
| 1250 | +var commonProperties = [ | |
| 1251 | + "name", | |
| 1252 | + "message", | |
| 1253 | + "stack", | |
| 1254 | + "code" | |
| 1255 | +]; | |
| 1256 | +var RejectWithValue = /** @class */ (function () { | |
| 1257 | + function RejectWithValue(payload, meta) { | |
| 1258 | + this.payload = payload; | |
| 1259 | + this.meta = meta; | |
| 1260 | + } | |
| 1261 | + return RejectWithValue; | |
| 1262 | +}()); | |
| 1263 | +var FulfillWithMeta = /** @class */ (function () { | |
| 1264 | + function FulfillWithMeta(payload, meta) { | |
| 1265 | + this.payload = payload; | |
| 1266 | + this.meta = meta; | |
| 1267 | + } | |
| 1268 | + return FulfillWithMeta; | |
| 1269 | +}()); | |
| 1270 | +var miniSerializeError = function (value) { | |
| 1271 | + if (typeof value === "object" && value !== null) { | |
| 1272 | + var simpleError = {}; | |
| 1273 | + for (var _i = 0, commonProperties_1 = commonProperties; _i < commonProperties_1.length; _i++) { | |
| 1274 | + var property = commonProperties_1[_i]; | |
| 1275 | + if (typeof value[property] === "string") { | |
| 1276 | + simpleError[property] = value[property]; | |
| 1277 | + } | |
| 1278 | + } | |
| 1279 | + return simpleError; | |
| 1280 | + } | |
| 1281 | + return { message: String(value) }; | |
| 1282 | +}; | |
| 1283 | +var createAsyncThunk = (function () { | |
| 1284 | + function createAsyncThunk2(typePrefix, payloadCreator, options) { | |
| 1285 | + var fulfilled = createAction(typePrefix + "/fulfilled", function (payload, requestId, arg, meta) { return ({ | |
| 1286 | + payload: payload, | |
| 1287 | + meta: __spreadProps(__spreadValues({}, meta || {}), { | |
| 1288 | + arg: arg, | |
| 1289 | + requestId: requestId, | |
| 1290 | + requestStatus: "fulfilled" | |
| 1291 | + }) | |
| 1292 | + }); }); | |
| 1293 | + var pending = createAction(typePrefix + "/pending", function (requestId, arg, meta) { return ({ | |
| 1294 | + payload: void 0, | |
| 1295 | + meta: __spreadProps(__spreadValues({}, meta || {}), { | |
| 1296 | + arg: arg, | |
| 1297 | + requestId: requestId, | |
| 1298 | + requestStatus: "pending" | |
| 1299 | + }) | |
| 1300 | + }); }); | |
| 1301 | + var rejected = createAction(typePrefix + "/rejected", function (error, requestId, arg, payload, meta) { return ({ | |
| 1302 | + payload: payload, | |
| 1303 | + error: (options && options.serializeError || miniSerializeError)(error || "Rejected"), | |
| 1304 | + meta: __spreadProps(__spreadValues({}, meta || {}), { | |
| 1305 | + arg: arg, | |
| 1306 | + requestId: requestId, | |
| 1307 | + rejectedWithValue: !!payload, | |
| 1308 | + requestStatus: "rejected", | |
| 1309 | + aborted: (error == null ? void 0 : error.name) === "AbortError", | |
| 1310 | + condition: (error == null ? void 0 : error.name) === "ConditionError" | |
| 1311 | + }) | |
| 1312 | + }); }); | |
| 1313 | + var displayedWarning = false; | |
| 1314 | + var AC = typeof AbortController !== "undefined" ? AbortController : /** @class */ (function () { | |
| 1315 | + function class_1() { | |
| 1316 | + this.signal = { | |
| 1317 | + aborted: false, | |
| 1318 | + addEventListener: function () { | |
| 1319 | + }, | |
| 1320 | + dispatchEvent: function () { | |
| 1321 | + return false; | |
| 1322 | + }, | |
| 1323 | + onabort: function () { | |
| 1324 | + }, | |
| 1325 | + removeEventListener: function () { | |
| 1326 | + }, | |
| 1327 | + reason: void 0, | |
| 1328 | + throwIfAborted: function () { | |
| 1329 | + } | |
| 1330 | + }; | |
| 1331 | + } | |
| 1332 | + class_1.prototype.abort = function () { | |
| 1333 | + if (true) { | |
| 1334 | + if (!displayedWarning) { | |
| 1335 | + displayedWarning = true; | |
| 1336 | + console.info("This platform does not implement AbortController. \nIf you want to use the AbortController to react to `abort` events, please consider importing a polyfill like 'abortcontroller-polyfill/dist/abortcontroller-polyfill-only'."); | |
| 1337 | + } | |
| 1338 | + } | |
| 1339 | + }; | |
| 1340 | + return class_1; | |
| 1341 | + }()); | |
| 1342 | + function actionCreator(arg) { | |
| 1343 | + return function (dispatch, getState, extra) { | |
| 1344 | + var requestId = (options == null ? void 0 : options.idGenerator) ? options.idGenerator(arg) : nanoid(); | |
| 1345 | + var abortController = new AC(); | |
| 1346 | + var abortReason; | |
| 1347 | + var started = false; | |
| 1348 | + function abort(reason) { | |
| 1349 | + abortReason = reason; | |
| 1350 | + abortController.abort(); | |
| 1351 | + } | |
| 1352 | + var promise2 = function () { | |
| 1353 | + return __async(this, null, function () { | |
| 1354 | + var _a, _b, finalAction, conditionResult, abortedPromise, err_1, skipDispatch; | |
| 1355 | + return __generator(this, function (_c) { | |
| 1356 | + switch (_c.label) { | |
| 1357 | + case 0: | |
| 1358 | + _c.trys.push([0, 4, , 5]); | |
| 1359 | + conditionResult = (_a = options == null ? void 0 : options.condition) == null ? void 0 : _a.call(options, arg, { getState: getState, extra: extra }); | |
| 1360 | + if (!isThenable(conditionResult)) return [3 /*break*/, 2]; | |
| 1361 | + return [4 /*yield*/, conditionResult]; | |
| 1362 | + case 1: | |
| 1363 | + conditionResult = _c.sent(); | |
| 1364 | + _c.label = 2; | |
| 1365 | + case 2: | |
| 1366 | + if (conditionResult === false || abortController.signal.aborted) { | |
| 1367 | + throw { | |
| 1368 | + name: "ConditionError", | |
| 1369 | + message: "Aborted due to condition callback returning false." | |
| 1370 | + }; | |
| 1371 | + } | |
| 1372 | + started = true; | |
| 1373 | + abortedPromise = new Promise(function (_, reject) { return abortController.signal.addEventListener("abort", function () { return reject({ | |
| 1374 | + name: "AbortError", | |
| 1375 | + message: abortReason || "Aborted" | |
| 1376 | + }); }); }); | |
| 1377 | + dispatch(pending(requestId, arg, (_b = options == null ? void 0 : options.getPendingMeta) == null ? void 0 : _b.call(options, { requestId: requestId, arg: arg }, { getState: getState, extra: extra }))); | |
| 1378 | + return [4 /*yield*/, Promise.race([ | |
| 1379 | + abortedPromise, | |
| 1380 | + Promise.resolve(payloadCreator(arg, { | |
| 1381 | + dispatch: dispatch, | |
| 1382 | + getState: getState, | |
| 1383 | + extra: extra, | |
| 1384 | + requestId: requestId, | |
| 1385 | + signal: abortController.signal, | |
| 1386 | + abort: abort, | |
| 1387 | + rejectWithValue: function (value, meta) { | |
| 1388 | + return new RejectWithValue(value, meta); | |
| 1389 | + }, | |
| 1390 | + fulfillWithValue: function (value, meta) { | |
| 1391 | + return new FulfillWithMeta(value, meta); | |
| 1392 | + } | |
| 1393 | + })).then(function (result) { | |
| 1394 | + if (result instanceof RejectWithValue) { | |
| 1395 | + throw result; | |
| 1396 | + } | |
| 1397 | + if (result instanceof FulfillWithMeta) { | |
| 1398 | + return fulfilled(result.payload, requestId, arg, result.meta); | |
| 1399 | + } | |
| 1400 | + return fulfilled(result, requestId, arg); | |
| 1401 | + }) | |
| 1402 | + ])]; | |
| 1403 | + case 3: | |
| 1404 | + finalAction = _c.sent(); | |
| 1405 | + return [3 /*break*/, 5]; | |
| 1406 | + case 4: | |
| 1407 | + err_1 = _c.sent(); | |
| 1408 | + finalAction = err_1 instanceof RejectWithValue ? rejected(null, requestId, arg, err_1.payload, err_1.meta) : rejected(err_1, requestId, arg); | |
| 1409 | + return [3 /*break*/, 5]; | |
| 1410 | + case 5: | |
| 1411 | + skipDispatch = options && !options.dispatchConditionRejection && rejected.match(finalAction) && finalAction.meta.condition; | |
| 1412 | + if (!skipDispatch) { | |
| 1413 | + dispatch(finalAction); | |
| 1414 | + } | |
| 1415 | + return [2 /*return*/, finalAction]; | |
| 1416 | + } | |
| 1417 | + }); | |
| 1418 | + }); | |
| 1419 | + }(); | |
| 1420 | + return Object.assign(promise2, { | |
| 1421 | + abort: abort, | |
| 1422 | + requestId: requestId, | |
| 1423 | + arg: arg, | |
| 1424 | + unwrap: function () { | |
| 1425 | + return promise2.then(unwrapResult); | |
| 1426 | + } | |
| 1427 | + }); | |
| 1428 | + }; | |
| 1429 | + } | |
| 1430 | + return Object.assign(actionCreator, { | |
| 1431 | + pending: pending, | |
| 1432 | + rejected: rejected, | |
| 1433 | + fulfilled: fulfilled, | |
| 1434 | + typePrefix: typePrefix | |
| 1435 | + }); | |
| 1436 | + } | |
| 1437 | + createAsyncThunk2.withTypes = function () { return createAsyncThunk2; }; | |
| 1438 | + return createAsyncThunk2; | |
| 1439 | +})(); | |
| 1440 | +function unwrapResult(action) { | |
| 1441 | + if (action.meta && action.meta.rejectedWithValue) { | |
| 1442 | + throw action.payload; | |
| 1443 | + } | |
| 1444 | + if (action.error) { | |
| 1445 | + throw action.error; | |
| 1446 | + } | |
| 1447 | + return action.payload; | |
| 1448 | +} | |
| 1449 | +function isThenable(value) { | |
| 1450 | + return value !== null && typeof value === "object" && typeof value.then === "function"; | |
| 1451 | +} | |
| 1452 | +// src/matchers.ts | |
| 1453 | +var matches = function (matcher, action) { | |
| 1454 | + if (hasMatchFunction(matcher)) { | |
| 1455 | + return matcher.match(action); | |
| 1456 | + } | |
| 1457 | + else { | |
| 1458 | + return matcher(action); | |
| 1459 | + } | |
| 1460 | +}; | |
| 1461 | +function isAnyOf() { | |
| 1462 | + var matchers = []; | |
| 1463 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 1464 | + matchers[_i] = arguments[_i]; | |
| 1465 | + } | |
| 1466 | + return function (action) { | |
| 1467 | + return matchers.some(function (matcher) { return matches(matcher, action); }); | |
| 1468 | + }; | |
| 1469 | +} | |
| 1470 | +function isAllOf() { | |
| 1471 | + var matchers = []; | |
| 1472 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 1473 | + matchers[_i] = arguments[_i]; | |
| 1474 | + } | |
| 1475 | + return function (action) { | |
| 1476 | + return matchers.every(function (matcher) { return matches(matcher, action); }); | |
| 1477 | + }; | |
| 1478 | +} | |
| 1479 | +function hasExpectedRequestMetadata(action, validStatus) { | |
| 1480 | + if (!action || !action.meta) | |
| 1481 | + return false; | |
| 1482 | + var hasValidRequestId = typeof action.meta.requestId === "string"; | |
| 1483 | + var hasValidRequestStatus = validStatus.indexOf(action.meta.requestStatus) > -1; | |
| 1484 | + return hasValidRequestId && hasValidRequestStatus; | |
| 1485 | +} | |
| 1486 | +function isAsyncThunkArray(a) { | |
| 1487 | + return typeof a[0] === "function" && "pending" in a[0] && "fulfilled" in a[0] && "rejected" in a[0]; | |
| 1488 | +} | |
| 1489 | +function isPending() { | |
| 1490 | + var asyncThunks = []; | |
| 1491 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 1492 | + asyncThunks[_i] = arguments[_i]; | |
| 1493 | + } | |
| 1494 | + if (asyncThunks.length === 0) { | |
| 1495 | + return function (action) { return hasExpectedRequestMetadata(action, ["pending"]); }; | |
| 1496 | + } | |
| 1497 | + if (!isAsyncThunkArray(asyncThunks)) { | |
| 1498 | + return isPending()(asyncThunks[0]); | |
| 1499 | + } | |
| 1500 | + return function (action) { | |
| 1501 | + var matchers = asyncThunks.map(function (asyncThunk) { return asyncThunk.pending; }); | |
| 1502 | + var combinedMatcher = isAnyOf.apply(void 0, matchers); | |
| 1503 | + return combinedMatcher(action); | |
| 1504 | + }; | |
| 1505 | +} | |
| 1506 | +function isRejected() { | |
| 1507 | + var asyncThunks = []; | |
| 1508 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 1509 | + asyncThunks[_i] = arguments[_i]; | |
| 1510 | + } | |
| 1511 | + if (asyncThunks.length === 0) { | |
| 1512 | + return function (action) { return hasExpectedRequestMetadata(action, ["rejected"]); }; | |
| 1513 | + } | |
| 1514 | + if (!isAsyncThunkArray(asyncThunks)) { | |
| 1515 | + return isRejected()(asyncThunks[0]); | |
| 1516 | + } | |
| 1517 | + return function (action) { | |
| 1518 | + var matchers = asyncThunks.map(function (asyncThunk) { return asyncThunk.rejected; }); | |
| 1519 | + var combinedMatcher = isAnyOf.apply(void 0, matchers); | |
| 1520 | + return combinedMatcher(action); | |
| 1521 | + }; | |
| 1522 | +} | |
| 1523 | +function isRejectedWithValue() { | |
| 1524 | + var asyncThunks = []; | |
| 1525 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 1526 | + asyncThunks[_i] = arguments[_i]; | |
| 1527 | + } | |
| 1528 | + var hasFlag = function (action) { | |
| 1529 | + return action && action.meta && action.meta.rejectedWithValue; | |
| 1530 | + }; | |
| 1531 | + if (asyncThunks.length === 0) { | |
| 1532 | + return function (action) { | |
| 1533 | + var combinedMatcher = isAllOf(isRejected.apply(void 0, asyncThunks), hasFlag); | |
| 1534 | + return combinedMatcher(action); | |
| 1535 | + }; | |
| 1536 | + } | |
| 1537 | + if (!isAsyncThunkArray(asyncThunks)) { | |
| 1538 | + return isRejectedWithValue()(asyncThunks[0]); | |
| 1539 | + } | |
| 1540 | + return function (action) { | |
| 1541 | + var combinedMatcher = isAllOf(isRejected.apply(void 0, asyncThunks), hasFlag); | |
| 1542 | + return combinedMatcher(action); | |
| 1543 | + }; | |
| 1544 | +} | |
| 1545 | +function isFulfilled() { | |
| 1546 | + var asyncThunks = []; | |
| 1547 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 1548 | + asyncThunks[_i] = arguments[_i]; | |
| 1549 | + } | |
| 1550 | + if (asyncThunks.length === 0) { | |
| 1551 | + return function (action) { return hasExpectedRequestMetadata(action, ["fulfilled"]); }; | |
| 1552 | + } | |
| 1553 | + if (!isAsyncThunkArray(asyncThunks)) { | |
| 1554 | + return isFulfilled()(asyncThunks[0]); | |
| 1555 | + } | |
| 1556 | + return function (action) { | |
| 1557 | + var matchers = asyncThunks.map(function (asyncThunk) { return asyncThunk.fulfilled; }); | |
| 1558 | + var combinedMatcher = isAnyOf.apply(void 0, matchers); | |
| 1559 | + return combinedMatcher(action); | |
| 1560 | + }; | |
| 1561 | +} | |
| 1562 | +function isAsyncThunkAction() { | |
| 1563 | + var asyncThunks = []; | |
| 1564 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 1565 | + asyncThunks[_i] = arguments[_i]; | |
| 1566 | + } | |
| 1567 | + if (asyncThunks.length === 0) { | |
| 1568 | + return function (action) { return hasExpectedRequestMetadata(action, ["pending", "fulfilled", "rejected"]); }; | |
| 1569 | + } | |
| 1570 | + if (!isAsyncThunkArray(asyncThunks)) { | |
| 1571 | + return isAsyncThunkAction()(asyncThunks[0]); | |
| 1572 | + } | |
| 1573 | + return function (action) { | |
| 1574 | + var matchers = []; | |
| 1575 | + for (var _i = 0, asyncThunks_1 = asyncThunks; _i < asyncThunks_1.length; _i++) { | |
| 1576 | + var asyncThunk = asyncThunks_1[_i]; | |
| 1577 | + matchers.push(asyncThunk.pending, asyncThunk.rejected, asyncThunk.fulfilled); | |
| 1578 | + } | |
| 1579 | + var combinedMatcher = isAnyOf.apply(void 0, matchers); | |
| 1580 | + return combinedMatcher(action); | |
| 1581 | + }; | |
| 1582 | +} | |
| 1583 | +// src/listenerMiddleware/utils.ts | |
| 1584 | +var assertFunction = function (func, expected) { | |
| 1585 | + if (typeof func !== "function") { | |
| 1586 | + throw new TypeError(expected + " is not a function"); | |
| 1587 | + } | |
| 1588 | +}; | |
| 1589 | +var noop = function () { | |
| 1590 | +}; | |
| 1591 | +var catchRejection = function (promise2, onError) { | |
| 1592 | + if (onError === void 0) { onError = noop; } | |
| 1593 | + promise2.catch(onError); | |
| 1594 | + return promise2; | |
| 1595 | +}; | |
| 1596 | +var addAbortSignalListener = function (abortSignal, callback) { | |
| 1597 | + abortSignal.addEventListener("abort", callback, { once: true }); | |
| 1598 | + return function () { return abortSignal.removeEventListener("abort", callback); }; | |
| 1599 | +}; | |
| 1600 | +var abortControllerWithReason = function (abortController, reason) { | |
| 1601 | + var signal = abortController.signal; | |
| 1602 | + if (signal.aborted) { | |
| 1603 | + return; | |
| 1604 | + } | |
| 1605 | + if (!("reason" in signal)) { | |
| 1606 | + Object.defineProperty(signal, "reason", { | |
| 1607 | + enumerable: true, | |
| 1608 | + value: reason, | |
| 1609 | + configurable: true, | |
| 1610 | + writable: true | |
| 1611 | + }); | |
| 1612 | + } | |
| 1613 | + ; | |
| 1614 | + abortController.abort(reason); | |
| 1615 | +}; | |
| 1616 | +// src/listenerMiddleware/exceptions.ts | |
| 1617 | +var task = "task"; | |
| 1618 | +var listener = "listener"; | |
| 1619 | +var completed = "completed"; | |
| 1620 | +var cancelled = "cancelled"; | |
| 1621 | +var taskCancelled = "task-" + cancelled; | |
| 1622 | +var taskCompleted = "task-" + completed; | |
| 1623 | +var listenerCancelled = listener + "-" + cancelled; | |
| 1624 | +var listenerCompleted = listener + "-" + completed; | |
| 1625 | +var TaskAbortError = /** @class */ (function () { | |
| 1626 | + function TaskAbortError(code) { | |
| 1627 | + this.code = code; | |
| 1628 | + this.name = "TaskAbortError"; | |
| 1629 | + this.message = task + " " + cancelled + " (reason: " + code + ")"; | |
| 1630 | + } | |
| 1631 | + return TaskAbortError; | |
| 1632 | +}()); | |
| 1633 | +// src/listenerMiddleware/task.ts | |
| 1634 | +var validateActive = function (signal) { | |
| 1635 | + if (signal.aborted) { | |
| 1636 | + throw new TaskAbortError(signal.reason); | |
| 1637 | + } | |
| 1638 | +}; | |
| 1639 | +function raceWithSignal(signal, promise2) { | |
| 1640 | + var cleanup = noop; | |
| 1641 | + return new Promise(function (resolve, reject) { | |
| 1642 | + var notifyRejection = function () { return reject(new TaskAbortError(signal.reason)); }; | |
| 1643 | + if (signal.aborted) { | |
| 1644 | + notifyRejection(); | |
| 1645 | + return; | |
| 1646 | + } | |
| 1647 | + cleanup = addAbortSignalListener(signal, notifyRejection); | |
| 1648 | + promise2.finally(function () { return cleanup(); }).then(resolve, reject); | |
| 1649 | + }).finally(function () { | |
| 1650 | + cleanup = noop; | |
| 1651 | + }); | |
| 1652 | +} | |
| 1653 | +var runTask = function (task2, cleanUp) { return __async(void 0, null, function () { | |
| 1654 | + var value, error_1; | |
| 1655 | + return __generator(this, function (_c) { | |
| 1656 | + switch (_c.label) { | |
| 1657 | + case 0: | |
| 1658 | + _c.trys.push([0, 3, 4, 5]); | |
| 1659 | + return [4 /*yield*/, Promise.resolve()]; | |
| 1660 | + case 1: | |
| 1661 | + _c.sent(); | |
| 1662 | + return [4 /*yield*/, task2()]; | |
| 1663 | + case 2: | |
| 1664 | + value = _c.sent(); | |
| 1665 | + return [2 /*return*/, { | |
| 1666 | + status: "ok", | |
| 1667 | + value: value | |
| 1668 | + }]; | |
| 1669 | + case 3: | |
| 1670 | + error_1 = _c.sent(); | |
| 1671 | + return [2 /*return*/, { | |
| 1672 | + status: error_1 instanceof TaskAbortError ? "cancelled" : "rejected", | |
| 1673 | + error: error_1 | |
| 1674 | + }]; | |
| 1675 | + case 4: | |
| 1676 | + cleanUp == null ? void 0 : cleanUp(); | |
| 1677 | + return [7 /*endfinally*/]; | |
| 1678 | + case 5: return [2 /*return*/]; | |
| 1679 | + } | |
| 1680 | + }); | |
| 1681 | +}); }; | |
| 1682 | +var createPause = function (signal) { | |
| 1683 | + return function (promise2) { | |
| 1684 | + return catchRejection(raceWithSignal(signal, promise2).then(function (output) { | |
| 1685 | + validateActive(signal); | |
| 1686 | + return output; | |
| 1687 | + })); | |
| 1688 | + }; | |
| 1689 | +}; | |
| 1690 | +var createDelay = function (signal) { | |
| 1691 | + var pause = createPause(signal); | |
| 1692 | + return function (timeoutMs) { | |
| 1693 | + return pause(new Promise(function (resolve) { return setTimeout(resolve, timeoutMs); })); | |
| 1694 | + }; | |
| 1695 | +}; | |
| 1696 | +// src/listenerMiddleware/index.ts | |
| 1697 | +var assign = Object.assign; | |
| 1698 | +var INTERNAL_NIL_TOKEN = {}; | |
| 1699 | +var alm = "listenerMiddleware"; | |
| 1700 | +var createFork = function (parentAbortSignal, parentBlockingPromises) { | |
| 1701 | + var linkControllers = function (controller) { return addAbortSignalListener(parentAbortSignal, function () { return abortControllerWithReason(controller, parentAbortSignal.reason); }); }; | |
| 1702 | + return function (taskExecutor, opts) { | |
| 1703 | + assertFunction(taskExecutor, "taskExecutor"); | |
| 1704 | + var childAbortController = new AbortController(); | |
| 1705 | + linkControllers(childAbortController); | |
| 1706 | + var result = runTask(function () { return __async(void 0, null, function () { | |
| 1707 | + var result2; | |
| 1708 | + return __generator(this, function (_c) { | |
| 1709 | + switch (_c.label) { | |
| 1710 | + case 0: | |
| 1711 | + validateActive(parentAbortSignal); | |
| 1712 | + validateActive(childAbortController.signal); | |
| 1713 | + return [4 /*yield*/, taskExecutor({ | |
| 1714 | + pause: createPause(childAbortController.signal), | |
| 1715 | + delay: createDelay(childAbortController.signal), | |
| 1716 | + signal: childAbortController.signal | |
| 1717 | + })]; | |
| 1718 | + case 1: | |
| 1719 | + result2 = _c.sent(); | |
| 1720 | + validateActive(childAbortController.signal); | |
| 1721 | + return [2 /*return*/, result2]; | |
| 1722 | + } | |
| 1723 | + }); | |
| 1724 | + }); }, function () { return abortControllerWithReason(childAbortController, taskCompleted); }); | |
| 1725 | + if (opts == null ? void 0 : opts.autoJoin) { | |
| 1726 | + parentBlockingPromises.push(result); | |
| 1727 | + } | |
| 1728 | + return { | |
| 1729 | + result: createPause(parentAbortSignal)(result), | |
| 1730 | + cancel: function () { | |
| 1731 | + abortControllerWithReason(childAbortController, taskCancelled); | |
| 1732 | + } | |
| 1733 | + }; | |
| 1734 | + }; | |
| 1735 | +}; | |
| 1736 | +var createTakePattern = function (startListening, signal) { | |
| 1737 | + var take = function (predicate, timeout) { return __async(void 0, null, function () { | |
| 1738 | + var unsubscribe, tuplePromise, promises, output; | |
| 1739 | + return __generator(this, function (_c) { | |
| 1740 | + switch (_c.label) { | |
| 1741 | + case 0: | |
| 1742 | + validateActive(signal); | |
| 1743 | + unsubscribe = function () { | |
| 1744 | + }; | |
| 1745 | + tuplePromise = new Promise(function (resolve, reject) { | |
| 1746 | + var stopListening = startListening({ | |
| 1747 | + predicate: predicate, | |
| 1748 | + effect: function (action, listenerApi) { | |
| 1749 | + listenerApi.unsubscribe(); | |
| 1750 | + resolve([ | |
| 1751 | + action, | |
| 1752 | + listenerApi.getState(), | |
| 1753 | + listenerApi.getOriginalState() | |
| 1754 | + ]); | |
| 1755 | + } | |
| 1756 | + }); | |
| 1757 | + unsubscribe = function () { | |
| 1758 | + stopListening(); | |
| 1759 | + reject(); | |
| 1760 | + }; | |
| 1761 | + }); | |
| 1762 | + promises = [ | |
| 1763 | + tuplePromise | |
| 1764 | + ]; | |
| 1765 | + if (timeout != null) { | |
| 1766 | + promises.push(new Promise(function (resolve) { return setTimeout(resolve, timeout, null); })); | |
| 1767 | + } | |
| 1768 | + _c.label = 1; | |
| 1769 | + case 1: | |
| 1770 | + _c.trys.push([1, , 3, 4]); | |
| 1771 | + return [4 /*yield*/, raceWithSignal(signal, Promise.race(promises))]; | |
| 1772 | + case 2: | |
| 1773 | + output = _c.sent(); | |
| 1774 | + validateActive(signal); | |
| 1775 | + return [2 /*return*/, output]; | |
| 1776 | + case 3: | |
| 1777 | + unsubscribe(); | |
| 1778 | + return [7 /*endfinally*/]; | |
| 1779 | + case 4: return [2 /*return*/]; | |
| 1780 | + } | |
| 1781 | + }); | |
| 1782 | + }); }; | |
| 1783 | + return function (predicate, timeout) { return catchRejection(take(predicate, timeout)); }; | |
| 1784 | +}; | |
| 1785 | +var getListenerEntryPropsFrom = function (options) { | |
| 1786 | + var type = options.type, actionCreator = options.actionCreator, matcher = options.matcher, predicate = options.predicate, effect = options.effect; | |
| 1787 | + if (type) { | |
| 1788 | + predicate = createAction(type).match; | |
| 1789 | + } | |
| 1790 | + else if (actionCreator) { | |
| 1791 | + type = actionCreator.type; | |
| 1792 | + predicate = actionCreator.match; | |
| 1793 | + } | |
| 1794 | + else if (matcher) { | |
| 1795 | + predicate = matcher; | |
| 1796 | + } | |
| 1797 | + else if (predicate) { | |
| 1798 | + } | |
| 1799 | + else { | |
| 1800 | + throw new Error("Creating or removing a listener requires one of the known fields for matching an action"); | |
| 1801 | + } | |
| 1802 | + assertFunction(effect, "options.listener"); | |
| 1803 | + return { predicate: predicate, type: type, effect: effect }; | |
| 1804 | +}; | |
| 1805 | +var createListenerEntry = function (options) { | |
| 1806 | + var _c = getListenerEntryPropsFrom(options), type = _c.type, predicate = _c.predicate, effect = _c.effect; | |
| 1807 | + var id = nanoid(); | |
| 1808 | + var entry = { | |
| 1809 | + id: id, | |
| 1810 | + effect: effect, | |
| 1811 | + type: type, | |
| 1812 | + predicate: predicate, | |
| 1813 | + pending: new Set(), | |
| 1814 | + unsubscribe: function () { | |
| 1815 | + throw new Error("Unsubscribe not initialized"); | |
| 1816 | + } | |
| 1817 | + }; | |
| 1818 | + return entry; | |
| 1819 | +}; | |
| 1820 | +var cancelActiveListeners = function (entry) { | |
| 1821 | + entry.pending.forEach(function (controller) { | |
| 1822 | + abortControllerWithReason(controller, listenerCancelled); | |
| 1823 | + }); | |
| 1824 | +}; | |
| 1825 | +var createClearListenerMiddleware = function (listenerMap) { | |
| 1826 | + return function () { | |
| 1827 | + listenerMap.forEach(cancelActiveListeners); | |
| 1828 | + listenerMap.clear(); | |
| 1829 | + }; | |
| 1830 | +}; | |
| 1831 | +var safelyNotifyError = function (errorHandler, errorToNotify, errorInfo) { | |
| 1832 | + try { | |
| 1833 | + errorHandler(errorToNotify, errorInfo); | |
| 1834 | + } | |
| 1835 | + catch (errorHandlerError) { | |
| 1836 | + setTimeout(function () { | |
| 1837 | + throw errorHandlerError; | |
| 1838 | + }, 0); | |
| 1839 | + } | |
| 1840 | +}; | |
| 1841 | +var addListener = createAction(alm + "/add"); | |
| 1842 | +var clearAllListeners = createAction(alm + "/removeAll"); | |
| 1843 | +var removeListener = createAction(alm + "/remove"); | |
| 1844 | +var defaultErrorHandler = function () { | |
| 1845 | + var args = []; | |
| 1846 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 1847 | + args[_i] = arguments[_i]; | |
| 1848 | + } | |
| 1849 | + console.error.apply(console, __spreadArray([alm + "/error"], args)); | |
| 1850 | +}; | |
| 1851 | +function createListenerMiddleware(middlewareOptions) { | |
| 1852 | + var _this = this; | |
| 1853 | + if (middlewareOptions === void 0) { middlewareOptions = {}; } | |
| 1854 | + var listenerMap = new Map(); | |
| 1855 | + var extra = middlewareOptions.extra, _c = middlewareOptions.onError, onError = _c === void 0 ? defaultErrorHandler : _c; | |
| 1856 | + assertFunction(onError, "onError"); | |
| 1857 | + var insertEntry = function (entry) { | |
| 1858 | + entry.unsubscribe = function () { return listenerMap.delete(entry.id); }; | |
| 1859 | + listenerMap.set(entry.id, entry); | |
| 1860 | + return function (cancelOptions) { | |
| 1861 | + entry.unsubscribe(); | |
| 1862 | + if (cancelOptions == null ? void 0 : cancelOptions.cancelActive) { | |
| 1863 | + cancelActiveListeners(entry); | |
| 1864 | + } | |
| 1865 | + }; | |
| 1866 | + }; | |
| 1867 | + var findListenerEntry = function (comparator) { | |
| 1868 | + for (var _i = 0, _c = Array.from(listenerMap.values()); _i < _c.length; _i++) { | |
| 1869 | + var entry = _c[_i]; | |
| 1870 | + if (comparator(entry)) { | |
| 1871 | + return entry; | |
| 1872 | + } | |
| 1873 | + } | |
| 1874 | + return void 0; | |
| 1875 | + }; | |
| 1876 | + var startListening = function (options) { | |
| 1877 | + var entry = findListenerEntry(function (existingEntry) { return existingEntry.effect === options.effect; }); | |
| 1878 | + if (!entry) { | |
| 1879 | + entry = createListenerEntry(options); | |
| 1880 | + } | |
| 1881 | + return insertEntry(entry); | |
| 1882 | + }; | |
| 1883 | + var stopListening = function (options) { | |
| 1884 | + var _c = getListenerEntryPropsFrom(options), type = _c.type, effect = _c.effect, predicate = _c.predicate; | |
| 1885 | + var entry = findListenerEntry(function (entry2) { | |
| 1886 | + var matchPredicateOrType = typeof type === "string" ? entry2.type === type : entry2.predicate === predicate; | |
| 1887 | + return matchPredicateOrType && entry2.effect === effect; | |
| 1888 | + }); | |
| 1889 | + if (entry) { | |
| 1890 | + entry.unsubscribe(); | |
| 1891 | + if (options.cancelActive) { | |
| 1892 | + cancelActiveListeners(entry); | |
| 1893 | + } | |
| 1894 | + } | |
| 1895 | + return !!entry; | |
| 1896 | + }; | |
| 1897 | + var notifyListener = function (entry, action, api, getOriginalState) { return __async(_this, null, function () { | |
| 1898 | + var internalTaskController, take, autoJoinPromises, listenerError_1; | |
| 1899 | + return __generator(this, function (_c) { | |
| 1900 | + switch (_c.label) { | |
| 1901 | + case 0: | |
| 1902 | + internalTaskController = new AbortController(); | |
| 1903 | + take = createTakePattern(startListening, internalTaskController.signal); | |
| 1904 | + autoJoinPromises = []; | |
| 1905 | + _c.label = 1; | |
| 1906 | + case 1: | |
| 1907 | + _c.trys.push([1, 3, 4, 6]); | |
| 1908 | + entry.pending.add(internalTaskController); | |
| 1909 | + return [4 /*yield*/, Promise.resolve(entry.effect(action, assign({}, api, { | |
| 1910 | + getOriginalState: getOriginalState, | |
| 1911 | + condition: function (predicate, timeout) { return take(predicate, timeout).then(Boolean); }, | |
| 1912 | + take: take, | |
| 1913 | + delay: createDelay(internalTaskController.signal), | |
| 1914 | + pause: createPause(internalTaskController.signal), | |
| 1915 | + extra: extra, | |
| 1916 | + signal: internalTaskController.signal, | |
| 1917 | + fork: createFork(internalTaskController.signal, autoJoinPromises), | |
| 1918 | + unsubscribe: entry.unsubscribe, | |
| 1919 | + subscribe: function () { | |
| 1920 | + listenerMap.set(entry.id, entry); | |
| 1921 | + }, | |
| 1922 | + cancelActiveListeners: function () { | |
| 1923 | + entry.pending.forEach(function (controller, _, set) { | |
| 1924 | + if (controller !== internalTaskController) { | |
| 1925 | + abortControllerWithReason(controller, listenerCancelled); | |
| 1926 | + set.delete(controller); | |
| 1927 | + } | |
| 1928 | + }); | |
| 1929 | + } | |
| 1930 | + })))]; | |
| 1931 | + case 2: | |
| 1932 | + _c.sent(); | |
| 1933 | + return [3 /*break*/, 6]; | |
| 1934 | + case 3: | |
| 1935 | + listenerError_1 = _c.sent(); | |
| 1936 | + if (!(listenerError_1 instanceof TaskAbortError)) { | |
| 1937 | + safelyNotifyError(onError, listenerError_1, { | |
| 1938 | + raisedBy: "effect" | |
| 1939 | + }); | |
| 1940 | + } | |
| 1941 | + return [3 /*break*/, 6]; | |
| 1942 | + case 4: return [4 /*yield*/, Promise.allSettled(autoJoinPromises)]; | |
| 1943 | + case 5: | |
| 1944 | + _c.sent(); | |
| 1945 | + abortControllerWithReason(internalTaskController, listenerCompleted); | |
| 1946 | + entry.pending.delete(internalTaskController); | |
| 1947 | + return [7 /*endfinally*/]; | |
| 1948 | + case 6: return [2 /*return*/]; | |
| 1949 | + } | |
| 1950 | + }); | |
| 1951 | + }); }; | |
| 1952 | + var clearListenerMiddleware = createClearListenerMiddleware(listenerMap); | |
| 1953 | + var middleware = function (api) { return function (next) { return function (action) { | |
| 1954 | + if (!isAction(action)) { | |
| 1955 | + return next(action); | |
| 1956 | + } | |
| 1957 | + if (addListener.match(action)) { | |
| 1958 | + return startListening(action.payload); | |
| 1959 | + } | |
| 1960 | + if (clearAllListeners.match(action)) { | |
| 1961 | + clearListenerMiddleware(); | |
| 1962 | + return; | |
| 1963 | + } | |
| 1964 | + if (removeListener.match(action)) { | |
| 1965 | + return stopListening(action.payload); | |
| 1966 | + } | |
| 1967 | + var originalState = api.getState(); | |
| 1968 | + var getOriginalState = function () { | |
| 1969 | + if (originalState === INTERNAL_NIL_TOKEN) { | |
| 1970 | + throw new Error(alm + ": getOriginalState can only be called synchronously"); | |
| 1971 | + } | |
| 1972 | + return originalState; | |
| 1973 | + }; | |
| 1974 | + var result; | |
| 1975 | + try { | |
| 1976 | + result = next(action); | |
| 1977 | + if (listenerMap.size > 0) { | |
| 1978 | + var currentState = api.getState(); | |
| 1979 | + var listenerEntries = Array.from(listenerMap.values()); | |
| 1980 | + for (var _i = 0, listenerEntries_1 = listenerEntries; _i < listenerEntries_1.length; _i++) { | |
| 1981 | + var entry = listenerEntries_1[_i]; | |
| 1982 | + var runListener = false; | |
| 1983 | + try { | |
| 1984 | + runListener = entry.predicate(action, currentState, originalState); | |
| 1985 | + } | |
| 1986 | + catch (predicateError) { | |
| 1987 | + runListener = false; | |
| 1988 | + safelyNotifyError(onError, predicateError, { | |
| 1989 | + raisedBy: "predicate" | |
| 1990 | + }); | |
| 1991 | + } | |
| 1992 | + if (!runListener) { | |
| 1993 | + continue; | |
| 1994 | + } | |
| 1995 | + notifyListener(entry, action, api, getOriginalState); | |
| 1996 | + } | |
| 1997 | + } | |
| 1998 | + } | |
| 1999 | + finally { | |
| 2000 | + originalState = INTERNAL_NIL_TOKEN; | |
| 2001 | + } | |
| 2002 | + return result; | |
| 2003 | + }; }; }; | |
| 2004 | + return { | |
| 2005 | + middleware: middleware, | |
| 2006 | + startListening: startListening, | |
| 2007 | + stopListening: stopListening, | |
| 2008 | + clearListeners: clearListenerMiddleware | |
| 2009 | + }; | |
| 2010 | +} | |
| 2011 | +// src/autoBatchEnhancer.ts | |
| 2012 | +var SHOULD_AUTOBATCH = "RTK_autoBatch"; | |
| 2013 | +var prepareAutoBatched = function () { return function (payload) { | |
| 2014 | + var _c; | |
| 2015 | + return ({ | |
| 2016 | + payload: payload, | |
| 2017 | + meta: (_c = {}, _c[SHOULD_AUTOBATCH] = true, _c) | |
| 2018 | + }); | |
| 2019 | +}; }; | |
| 2020 | +var promise; | |
| 2021 | +var queueMicrotaskShim = typeof queueMicrotask === "function" ? queueMicrotask.bind(typeof window !== "undefined" ? window : typeof __webpack_require__.g !== "undefined" ? __webpack_require__.g : globalThis) : function (cb) { return (promise || (promise = Promise.resolve())).then(cb).catch(function (err) { return setTimeout(function () { | |
| 2022 | + throw err; | |
| 2023 | +}, 0); }); }; | |
| 2024 | +var createQueueWithTimer = function (timeout) { | |
| 2025 | + return function (notify) { | |
| 2026 | + setTimeout(notify, timeout); | |
| 2027 | + }; | |
| 2028 | +}; | |
| 2029 | +var rAF = typeof window !== "undefined" && window.requestAnimationFrame ? window.requestAnimationFrame : createQueueWithTimer(10); | |
| 2030 | +var autoBatchEnhancer = function (options) { | |
| 2031 | + if (options === void 0) { options = { type: "raf" }; } | |
| 2032 | + return function (next) { return function () { | |
| 2033 | + var args = []; | |
| 2034 | + for (var _i = 0; _i < arguments.length; _i++) { | |
| 2035 | + args[_i] = arguments[_i]; | |
| 2036 | + } | |
| 2037 | + var store = next.apply(void 0, args); | |
| 2038 | + var notifying = true; | |
| 2039 | + var shouldNotifyAtEndOfTick = false; | |
| 2040 | + var notificationQueued = false; | |
| 2041 | + var listeners = new Set(); | |
| 2042 | + var queueCallback = options.type === "tick" ? queueMicrotaskShim : options.type === "raf" ? rAF : options.type === "callback" ? options.queueNotification : createQueueWithTimer(options.timeout); | |
| 2043 | + var notifyListeners = function () { | |
| 2044 | + notificationQueued = false; | |
| 2045 | + if (shouldNotifyAtEndOfTick) { | |
| 2046 | + shouldNotifyAtEndOfTick = false; | |
| 2047 | + listeners.forEach(function (l) { return l(); }); | |
| 2048 | + } | |
| 2049 | + }; | |
| 2050 | + return Object.assign({}, store, { | |
| 2051 | + subscribe: function (listener2) { | |
| 2052 | + var wrappedListener = function () { return notifying && listener2(); }; | |
| 2053 | + var unsubscribe = store.subscribe(wrappedListener); | |
| 2054 | + listeners.add(listener2); | |
| 2055 | + return function () { | |
| 2056 | + unsubscribe(); | |
| 2057 | + listeners.delete(listener2); | |
| 2058 | + }; | |
| 2059 | + }, | |
| 2060 | + dispatch: function (action) { | |
| 2061 | + var _a; | |
| 2062 | + try { | |
| 2063 | + notifying = !((_a = action == null ? void 0 : action.meta) == null ? void 0 : _a[SHOULD_AUTOBATCH]); | |
| 2064 | + shouldNotifyAtEndOfTick = !notifying; | |
| 2065 | + if (shouldNotifyAtEndOfTick) { | |
| 2066 | + if (!notificationQueued) { | |
| 2067 | + notificationQueued = true; | |
| 2068 | + queueCallback(notifyListeners); | |
| 2069 | + } | |
| 2070 | + } | |
| 2071 | + return store.dispatch(action); | |
| 2072 | + } | |
| 2073 | + finally { | |
| 2074 | + notifying = true; | |
| 2075 | + } | |
| 2076 | + } | |
| 2077 | + }); | |
| 2078 | + }; }; | |
| 2079 | +}; | |
| 2080 | +// src/index.ts | |
| 2081 | +(0,immer__WEBPACK_IMPORTED_MODULE_2__.enableES5)(); | |
| 2082 | + | |
| 2083 | +//# sourceMappingURL=redux-toolkit.esm.js.map | |
| 11 | 2084 | |
| 12 | - | |
| 13 | -var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ "../node_modules/@babel/runtime/helpers/interopRequireDefault.js"); | |
| 14 | -Object.defineProperty(exports, "__esModule", ({ | |
| 15 | - value: true | |
| 16 | -})); | |
| 17 | -exports.BaseRegistry = void 0; | |
| 18 | -var _toConsumableArray2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/toConsumableArray */ "../node_modules/@babel/runtime/helpers/toConsumableArray.js")); | |
| 19 | -var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ "../node_modules/@babel/runtime/helpers/defineProperty.js")); | |
| 20 | -var _objectWithoutProperties2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/objectWithoutProperties */ "../node_modules/@babel/runtime/helpers/objectWithoutProperties.js")); | |
| 21 | -var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); | |
| 22 | -var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); | |
| 23 | -var _excluded = ["children"]; | |
| 24 | -function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; } | |
| 25 | -function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } | |
| 26 | -var BaseRegistry = exports.BaseRegistry = /*#__PURE__*/function () { | |
| 27 | - function BaseRegistry() { | |
| 28 | - (0, _classCallCheck2.default)(this, BaseRegistry); | |
| 29 | - this.sections = new Map(); | |
| 30 | - } | |
| 31 | - return (0, _createClass2.default)(BaseRegistry, [{ | |
| 32 | - key: "register", | |
| 33 | - value: function register(section) { | |
| 34 | - var _this = this; | |
| 35 | - if (!section.key || !section.title) { | |
| 36 | - throw new Error('Template type must have key and title'); | |
| 37 | - } | |
| 38 | - var existingSection = this.get(section.key); | |
| 39 | - var formattedSection = existingSection || this.formatSection(section); | |
| 40 | - if (section.children) { | |
| 41 | - // If existing section has children, merge them with new children | |
| 42 | - if (formattedSection.children) { | |
| 43 | - var existingChildrenMap = new Map(formattedSection.children.map(function (child) { | |
| 44 | - return [child.key, child]; | |
| 45 | - })); | |
| 46 | - | |
| 47 | - // Override existing children with new ones and add new children | |
| 48 | - section.children.forEach(function (childSection) { | |
| 49 | - var formattedChild = _this.formatSection(childSection); | |
| 50 | - existingChildrenMap.set(childSection.key, formattedChild); | |
| 51 | - }); | |
| 52 | - formattedSection.children = Array.from(existingChildrenMap.values()); | |
| 53 | - } else { | |
| 54 | - formattedSection.children = section.children.map(function (childSection) { | |
| 55 | - return _this.formatSection(childSection); | |
| 56 | - }); | |
| 57 | - } | |
| 58 | - } | |
| 59 | - this.sections.set(section.key, formattedSection); | |
| 60 | - } | |
| 61 | - }, { | |
| 62 | - key: "formatSection", | |
| 63 | - value: function formatSection(_ref) { | |
| 64 | - var children = _ref.children, | |
| 65 | - section = (0, _objectWithoutProperties2.default)(_ref, _excluded); | |
| 66 | - return _objectSpread({ | |
| 67 | - key: section.key, | |
| 68 | - title: section.title, | |
| 69 | - description: section.description || '', | |
| 70 | - useParentDefault: section.useParentDefault !== false, | |
| 71 | - getInitialState: section.getInitialState || null, | |
| 72 | - component: section.component || null, | |
| 73 | - order: section.order || 10, | |
| 74 | - isAvailable: section.isAvailable || function () { | |
| 75 | - return true; | |
| 76 | - } | |
| 77 | - }, section); | |
| 78 | - } | |
| 79 | - }, { | |
| 80 | - key: "getAll", | |
| 81 | - value: function getAll() { | |
| 82 | - return Array.from(this.sections.values()).filter(function (type) { | |
| 83 | - return type.isAvailable(); | |
| 84 | - }).map(function (type) { | |
| 85 | - if (type.children) { | |
| 86 | - return _objectSpread(_objectSpread({}, type), {}, { | |
| 87 | - children: (0, _toConsumableArray2.default)(type.children).sort(function (a, b) { | |
| 88 | - return a.order - b.order; | |
| 89 | - }) | |
| 90 | - }); | |
| 91 | - } | |
| 92 | - return type; | |
| 93 | - }).sort(function (a, b) { | |
| 94 | - return a.order - b.order; | |
| 95 | - }); | |
| 96 | - } | |
| 97 | - }, { | |
| 98 | - key: "get", | |
| 99 | - value: function get(key) { | |
| 100 | - return this.sections.get(key); | |
| 101 | - } | |
| 102 | - }]); | |
| 103 | -}(); | |
| 104 | - | |
| 105 | 2085 | /***/ }), |
| 106 | 2086 | |
| 107 | -/***/ "../app/modules/import-export-customization/assets/js/shared/registry/customization-dialogs.js": | |
| 108 | -/*!*****************************************************************************************************!*\ | |
| 109 | - !*** ../app/modules/import-export-customization/assets/js/shared/registry/customization-dialogs.js ***! | |
| 110 | - \*****************************************************************************************************/ | |
| 111 | -/***/ ((__unused_webpack_module, exports, __webpack_require__) => { | |
| 112 | - | |
| 113 | -"use strict"; | |
| 114 | - | |
| 115 | - | |
| 116 | -Object.defineProperty(exports, "__esModule", ({ | |
| 117 | - value: true | |
| 118 | -})); | |
| 119 | -exports.customizationDialogsRegistry = void 0; | |
| 120 | -var _base = __webpack_require__(/*! ./base */ "../app/modules/import-export-customization/assets/js/shared/registry/base.js"); | |
| 121 | -var customizationDialogsRegistry = exports.customizationDialogsRegistry = new _base.BaseRegistry(); | |
| 122 | - | |
| 123 | -/***/ }), | |
| 124 | - | |
| 125 | -/***/ "../app/modules/import-export-customization/assets/js/shared/utils/template-registry-helpers.js": | |
| 126 | -/*!******************************************************************************************************!*\ | |
| 127 | - !*** ../app/modules/import-export-customization/assets/js/shared/utils/template-registry-helpers.js ***! | |
| 128 | - \******************************************************************************************************/ | |
| 129 | -/***/ ((__unused_webpack_module, exports, __webpack_require__) => { | |
| 130 | - | |
| 131 | -"use strict"; | |
| 132 | - | |
| 133 | - | |
| 134 | -var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ "../node_modules/@babel/runtime/helpers/interopRequireDefault.js"); | |
| 135 | -Object.defineProperty(exports, "__esModule", ({ | |
| 136 | - value: true | |
| 137 | -})); | |
| 138 | -exports.createGetInitialState = createGetInitialState; | |
| 139 | -var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ "../node_modules/@babel/runtime/helpers/defineProperty.js")); | |
| 140 | -function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; } | |
| 141 | -function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } | |
| 142 | -function createGetInitialState(exportGroup) { | |
| 143 | - var additionalProps = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; | |
| 144 | - return function (data, parentInitialState) { | |
| 145 | - var isEnabled = parentInitialState; | |
| 146 | - var isImport = data.hasOwnProperty('uploadedData'); | |
| 147 | - if (isImport) { | |
| 148 | - var _elementorAppConfig; | |
| 149 | - isEnabled = false; | |
| 150 | - var templates = data.uploadedData.manifest.templates; | |
| 151 | - var exportGroups = ((_elementorAppConfig = elementorAppConfig) === null || _elementorAppConfig === void 0 || (_elementorAppConfig = _elementorAppConfig['import-export-customization']) === null || _elementorAppConfig === void 0 ? void 0 : _elementorAppConfig.exportGroups) || {}; | |
| 152 | - for (var templateId in templates) { | |
| 153 | - var template = templates[templateId]; | |
| 154 | - var templateExportGroup = exportGroups[template.doc_type]; | |
| 155 | - if (templateExportGroup === exportGroup) { | |
| 156 | - isEnabled = true; | |
| 157 | - break; | |
| 158 | - } | |
| 159 | - } | |
| 160 | - } | |
| 161 | - return _objectSpread({ | |
| 162 | - enabled: isEnabled | |
| 163 | - }, additionalProps); | |
| 164 | - }; | |
| 165 | -} | |
| 166 | - | |
| 167 | -/***/ }), | |
| 168 | - | |
| 169 | 2087 | /***/ "../assets/dev/js/editor/utils/is-instanceof.js": |
| 170 | 2088 | /*!******************************************************!*\ |
| 171 | 2089 | !*** ../assets/dev/js/editor/utils/is-instanceof.js ***! |
| 172 | 2090 | \******************************************************/ |
| @@ -178,11 +2096,11 @@ | ||
| 178 | 2096 | Object.defineProperty(exports, "__esModule", ({ |
| 179 | 2097 | value: true |
| 180 | 2098 | })); |
| 181 | 2099 | exports["default"] = void 0; |
| 182 | -function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t.return || t.return(); } finally { if (u) throw o; } } }; } | |
| 183 | -function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } } | |
| 184 | -function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; } | |
| 2100 | +function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; } | |
| 2101 | +function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); } | |
| 2102 | +function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; } | |
| 185 | 2103 | /** |
| 186 | 2104 | * Some FileAPI objects such as FileList, DataTransferItem and DataTransferItemList has inconsistency with the retrieved |
| 187 | 2105 | * object (from events, etc.) and the actual JavaScript object so a regular instanceof doesn't work. This function can |
| 188 | 2106 | * check whether it's instanceof by using the objects constructor and prototype names. |
| @@ -190,16 +2108,16 @@ | ||
| 190 | 2108 | * @param object |
| 191 | 2109 | * @param constructors |
| 192 | 2110 | * @return {boolean} |
| 193 | 2111 | */ |
| 194 | -var _default = exports["default"] = function _default(object, constructors) { | |
| 2112 | +var _default = function _default(object, constructors) { | |
| 195 | 2113 | constructors = Array.isArray(constructors) ? constructors : [constructors]; |
| 196 | 2114 | var _iterator = _createForOfIteratorHelper(constructors), |
| 197 | 2115 | _step; |
| 198 | 2116 | try { |
| 199 | 2117 | for (_iterator.s(); !(_step = _iterator.n()).done;) { |
| 200 | - var constructor = _step.value; | |
| 201 | - if (object.constructor.name === constructor.prototype[Symbol.toStringTag]) { | |
| 2118 | + var _constructor = _step.value; | |
| 2119 | + if (object.constructor.name === _constructor.prototype[Symbol.toStringTag]) { | |
| 202 | 2120 | return true; |
| 203 | 2121 | } |
| 204 | 2122 | } |
| 205 | 2123 | } catch (err) { |
| @@ -208,8 +2126,9 @@ | ||
| 208 | 2126 | _iterator.f(); |
| 209 | 2127 | } |
| 210 | 2128 | return false; |
| 211 | 2129 | }; |
| 2130 | +exports["default"] = _default; | |
| 212 | 2131 | |
| 213 | 2132 | /***/ }), |
| 214 | 2133 | |
| 215 | 2134 | /***/ "../assets/dev/js/modules/imports/args-object.js": |
| @@ -228,16 +2147,18 @@ | ||
| 228 | 2147 | exports["default"] = void 0; |
| 229 | 2148 | var _typeof2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/typeof */ "../node_modules/@babel/runtime/helpers/typeof.js")); |
| 230 | 2149 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 231 | 2150 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 2151 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 232 | 2152 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 233 | 2153 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 234 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 235 | 2154 | var _instanceType = _interopRequireDefault(__webpack_require__(/*! ./instance-type */ "../assets/dev/js/modules/imports/instance-type.js")); |
| 236 | 2155 | var _isInstanceof = _interopRequireDefault(__webpack_require__(/*! ../../editor/utils/is-instanceof */ "../assets/dev/js/editor/utils/is-instanceof.js")); |
| 237 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 238 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 239 | -var ArgsObject = exports["default"] = /*#__PURE__*/function (_InstanceType) { | |
| 2156 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 2157 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 2158 | +var ArgsObject = /*#__PURE__*/function (_InstanceType) { | |
| 2159 | + (0, _inherits2.default)(ArgsObject, _InstanceType); | |
| 2160 | + var _super = _createSuper(ArgsObject); | |
| 240 | 2161 | /** |
| 241 | 2162 | * Function constructor(). |
| 242 | 2163 | * |
| 243 | 2164 | * Create ArgsObject. |
| @@ -246,9 +2167,9 @@ | ||
| 246 | 2167 | */ |
| 247 | 2168 | function ArgsObject(args) { |
| 248 | 2169 | var _this; |
| 249 | 2170 | (0, _classCallCheck2.default)(this, ArgsObject); |
| 250 | - _this = _callSuper(this, ArgsObject); | |
| 2171 | + _this = _super.call(this); | |
| 251 | 2172 | _this.args = args; |
| 252 | 2173 | return _this; |
| 253 | 2174 | } |
| 254 | 2175 | |
| @@ -261,10 +2182,9 @@ | ||
| 261 | 2182 | * @param {{}} args |
| 262 | 2183 | * |
| 263 | 2184 | * @throws {Error} |
| 264 | 2185 | */ |
| 265 | - (0, _inherits2.default)(ArgsObject, _InstanceType); | |
| 266 | - return (0, _createClass2.default)(ArgsObject, [{ | |
| 2186 | + (0, _createClass2.default)(ArgsObject, [{ | |
| 267 | 2187 | key: "requireArgument", |
| 268 | 2188 | value: function requireArgument(property) { |
| 269 | 2189 | var args = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : this.args; |
| 270 | 2190 | if (!Object.prototype.hasOwnProperty.call(args, property)) { |
| @@ -342,9 +2262,11 @@ | ||
| 342 | 2262 | value: function getInstanceType() { |
| 343 | 2263 | return 'ArgsObject'; |
| 344 | 2264 | } |
| 345 | 2265 | }]); |
| 2266 | + return ArgsObject; | |
| 346 | 2267 | }(_instanceType.default); |
| 2268 | +exports["default"] = ArgsObject; | |
| 347 | 2269 | |
| 348 | 2270 | /***/ }), |
| 349 | 2271 | |
| 350 | 2272 | /***/ "../assets/dev/js/modules/imports/force-method-implementation.js": |
| @@ -362,22 +2284,25 @@ | ||
| 362 | 2284 | })); |
| 363 | 2285 | exports["default"] = exports.ForceMethodImplementation = void 0; |
| 364 | 2286 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 365 | 2287 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 2288 | +var _assertThisInitialized2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/assertThisInitialized */ "../node_modules/@babel/runtime/helpers/assertThisInitialized.js")); | |
| 2289 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 366 | 2290 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 367 | 2291 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 368 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 369 | 2292 | var _wrapNativeSuper2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/wrapNativeSuper */ "../node_modules/@babel/runtime/helpers/wrapNativeSuper.js")); |
| 370 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 371 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 2293 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 2294 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 372 | 2295 | // TODO: Wrong location used as `elementorModules.ForceMethodImplementation(); should be` `elementorUtils.forceMethodImplementation()`; |
| 373 | -var ForceMethodImplementation = exports.ForceMethodImplementation = /*#__PURE__*/function (_Error) { | |
| 2296 | +var ForceMethodImplementation = /*#__PURE__*/function (_Error) { | |
| 2297 | + (0, _inherits2.default)(ForceMethodImplementation, _Error); | |
| 2298 | + var _super = _createSuper(ForceMethodImplementation); | |
| 374 | 2299 | function ForceMethodImplementation() { |
| 375 | 2300 | var _this; |
| 376 | 2301 | var info = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; |
| 377 | 2302 | var args = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; |
| 378 | 2303 | (0, _classCallCheck2.default)(this, ForceMethodImplementation); |
| 379 | - _this = _callSuper(this, ForceMethodImplementation, ["".concat(info.isStatic ? 'static ' : '').concat(info.fullName, "() should be implemented, please provide '").concat(info.functionName || info.fullName, "' functionality."), args]); | |
| 2304 | + _this = _super.call(this, "".concat(info.isStatic ? 'static ' : '').concat(info.fullName, "() should be implemented, please provide '").concat(info.functionName || info.fullName, "' functionality."), args); | |
| 380 | 2305 | |
| 381 | 2306 | // Allow to pass custom properties to the error. |
| 382 | 2307 | if (Object.keys(args).length) { |
| 383 | 2308 | // eslint-disable-next-line no-console |
| @@ -382,15 +2307,15 @@ | ||
| 382 | 2307 | if (Object.keys(args).length) { |
| 383 | 2308 | // eslint-disable-next-line no-console |
| 384 | 2309 | console.error(args); |
| 385 | 2310 | } |
| 386 | - Error.captureStackTrace(_this, ForceMethodImplementation); | |
| 2311 | + Error.captureStackTrace((0, _assertThisInitialized2.default)(_this), ForceMethodImplementation); | |
| 387 | 2312 | return _this; |
| 388 | 2313 | } |
| 389 | - (0, _inherits2.default)(ForceMethodImplementation, _Error); | |
| 390 | 2314 | return (0, _createClass2.default)(ForceMethodImplementation); |
| 391 | -}(/*#__PURE__*/(0, _wrapNativeSuper2.default)(Error)); | |
| 392 | -var _default = exports["default"] = function _default(args) { | |
| 2315 | +}( /*#__PURE__*/(0, _wrapNativeSuper2.default)(Error)); | |
| 2316 | +exports.ForceMethodImplementation = ForceMethodImplementation; | |
| 2317 | +var _default = function _default(args) { | |
| 393 | 2318 | var stack = Error().stack, |
| 394 | 2319 | caller = stack.split('\n')[2].trim(), |
| 395 | 2320 | callerName = caller.startsWith('at new') ? 'constructor' : caller.split(' ')[1], |
| 396 | 2321 | info = {}; |
| @@ -404,8 +2329,9 @@ | ||
| 404 | 2329 | info.isStatic = true; |
| 405 | 2330 | } |
| 406 | 2331 | throw new ForceMethodImplementation(info, args); |
| 407 | 2332 | }; |
| 2333 | +exports["default"] = _default; | |
| 408 | 2334 | |
| 409 | 2335 | /***/ }), |
| 410 | 2336 | |
| 411 | 2337 | /***/ "../assets/dev/js/modules/imports/instance-type.js": |
| @@ -423,12 +2349,11 @@ | ||
| 423 | 2349 | })); |
| 424 | 2350 | exports["default"] = void 0; |
| 425 | 2351 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 426 | 2352 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 2353 | +var _get2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/get */ "../node_modules/@babel/runtime/helpers/get.js")); | |
| 427 | 2354 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 428 | -var _get2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/get */ "../node_modules/@babel/runtime/helpers/get.js")); | |
| 429 | -function _superPropGet(t, o, e, r) { var p = (0, _get2.default)((0, _getPrototypeOf2.default)(1 & r ? t.prototype : t), o, e); return 2 & r && "function" == typeof p ? function (t) { return p.apply(e, t); } : p; } | |
| 430 | -var InstanceType = exports["default"] = /*#__PURE__*/function () { | |
| 2355 | +var InstanceType = /*#__PURE__*/function (_Symbol$hasInstance) { | |
| 431 | 2356 | function InstanceType() { |
| 432 | 2357 | var _this = this; |
| 433 | 2358 | (0, _classCallCheck2.default)(this, InstanceType); |
| 434 | 2359 | // Since anonymous classes sometimes do not get validated by babel, do it manually. |
| @@ -441,10 +2366,10 @@ | ||
| 441 | 2366 | prototypes.reverse().forEach(function (proto) { |
| 442 | 2367 | return _this instanceof proto; |
| 443 | 2368 | }); |
| 444 | 2369 | } |
| 445 | - return (0, _createClass2.default)(InstanceType, null, [{ | |
| 446 | - key: Symbol.hasInstance, | |
| 2370 | + (0, _createClass2.default)(InstanceType, null, [{ | |
| 2371 | + key: _Symbol$hasInstance, | |
| 447 | 2372 | value: function value(target) { |
| 448 | 2373 | /** |
| 449 | 2374 | * This is function extending being called each time JS uses instanceOf, since babel use it each time it create new class |
| 450 | 2375 | * its give's opportunity to mange capabilities of instanceOf operator. |
| @@ -449,9 +2374,9 @@ | ||
| 449 | 2374 | * This is function extending being called each time JS uses instanceOf, since babel use it each time it create new class |
| 450 | 2375 | * its give's opportunity to mange capabilities of instanceOf operator. |
| 451 | 2376 | * saving current class each time will give option later to handle instanceOf manually. |
| 452 | 2377 | */ |
| 453 | - var result = _superPropGet(InstanceType, Symbol.hasInstance, this, 2)([target]); | |
| 2378 | + var result = (0, _get2.default)((0, _getPrototypeOf2.default)(InstanceType), Symbol.hasInstance, this).call(this, target); | |
| 454 | 2379 | |
| 455 | 2380 | // Act normal when validate a class, which does not have instance type. |
| 456 | 2381 | if (target && !target.constructor.getInstanceType) { |
| 457 | 2382 | return result; |
| @@ -483,9 +2408,11 @@ | ||
| 483 | 2408 | value: function getInstanceType() { |
| 484 | 2409 | elementorModules.ForceMethodImplementation(); |
| 485 | 2410 | } |
| 486 | 2411 | }]); |
| 487 | -}(); | |
| 2412 | + return InstanceType; | |
| 2413 | +}(Symbol.hasInstance); | |
| 2414 | +exports["default"] = InstanceType; | |
| 488 | 2415 | |
| 489 | 2416 | /***/ }), |
| 490 | 2417 | |
| 491 | 2418 | /***/ "../assets/dev/js/modules/imports/module.js": |
| @@ -670,9 +2597,9 @@ | ||
| 670 | 2597 | value: true |
| 671 | 2598 | })); |
| 672 | 2599 | exports["default"] = void 0; |
| 673 | 2600 | var _viewModule = _interopRequireDefault(__webpack_require__(/*! ../view-module */ "../assets/dev/js/modules/imports/view-module.js")); |
| 674 | -var _default = exports["default"] = _viewModule.default.extend({ | |
| 2601 | +var _default = _viewModule.default.extend({ | |
| 675 | 2602 | getDefaultSettings: function getDefaultSettings() { |
| 676 | 2603 | return { |
| 677 | 2604 | container: null, |
| 678 | 2605 | items: null, |
| @@ -709,8 +2636,9 @@ | ||
| 709 | 2636 | } |
| 710 | 2637 | }); |
| 711 | 2638 | } |
| 712 | 2639 | }); |
| 2640 | +exports["default"] = _default; | |
| 713 | 2641 | |
| 714 | 2642 | /***/ }), |
| 715 | 2643 | |
| 716 | 2644 | /***/ "../assets/dev/js/modules/imports/utils/scroll.js": |
| @@ -729,13 +2657,13 @@ | ||
| 729 | 2657 | exports["default"] = void 0; |
| 730 | 2658 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 731 | 2659 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 732 | 2660 | // Moved from elementor pro: 'assets/dev/js/frontend/utils' |
| 733 | -var Scroll = exports["default"] = /*#__PURE__*/function () { | |
| 2661 | +var Scroll = /*#__PURE__*/function () { | |
| 734 | 2662 | function Scroll() { |
| 735 | 2663 | (0, _classCallCheck2.default)(this, Scroll); |
| 736 | 2664 | } |
| 737 | - return (0, _createClass2.default)(Scroll, null, [{ | |
| 2665 | + (0, _createClass2.default)(Scroll, null, [{ | |
| 738 | 2666 | key: "scrollObserver", |
| 739 | 2667 | value: |
| 740 | 2668 | /** |
| 741 | 2669 | * @param {Object} obj |
| @@ -825,9 +2753,11 @@ | ||
| 825 | 2753 | scrollPos = document.documentElement.scrollTop + document.body.scrollTop + heightOffset; |
| 826 | 2754 | return scrollPos / pageRange * 100; |
| 827 | 2755 | } |
| 828 | 2756 | }]); |
| 2757 | + return Scroll; | |
| 829 | 2758 | }(); |
| 2759 | +exports["default"] = Scroll; | |
| 830 | 2760 | |
| 831 | 2761 | /***/ }), |
| 832 | 2762 | |
| 833 | 2763 | /***/ "../assets/dev/js/modules/imports/view-module.js": |
| @@ -844,9 +2774,9 @@ | ||
| 844 | 2774 | value: true |
| 845 | 2775 | })); |
| 846 | 2776 | exports["default"] = void 0; |
| 847 | 2777 | var _module = _interopRequireDefault(__webpack_require__(/*! ./module */ "../assets/dev/js/modules/imports/module.js")); |
| 848 | -var _default = exports["default"] = _module.default.extend({ | |
| 2778 | +var _default = _module.default.extend({ | |
| 849 | 2779 | elements: null, |
| 850 | 2780 | getDefaultElements: function getDefaultElements() { |
| 851 | 2781 | return {}; |
| 852 | 2782 | }, |
| @@ -858,8 +2788,9 @@ | ||
| 858 | 2788 | initElements: function initElements() { |
| 859 | 2789 | this.elements = this.getDefaultElements(); |
| 860 | 2790 | } |
| 861 | 2791 | }); |
| 2792 | +exports["default"] = _default; | |
| 862 | 2793 | |
| 863 | 2794 | /***/ }), |
| 864 | 2795 | |
| 865 | 2796 | /***/ "../assets/dev/js/modules/modules.js": |
| @@ -881,11 +2812,9 @@ | ||
| 881 | 2812 | var _argsObject = _interopRequireDefault(__webpack_require__(/*! ./imports/args-object */ "../assets/dev/js/modules/imports/args-object.js")); |
| 882 | 2813 | var _masonry = _interopRequireDefault(__webpack_require__(/*! ./imports/utils/masonry */ "../assets/dev/js/modules/imports/utils/masonry.js")); |
| 883 | 2814 | var _scroll = _interopRequireDefault(__webpack_require__(/*! ./imports/utils/scroll */ "../assets/dev/js/modules/imports/utils/scroll.js")); |
| 884 | 2815 | var _forceMethodImplementation = _interopRequireDefault(__webpack_require__(/*! ./imports/force-method-implementation */ "../assets/dev/js/modules/imports/force-method-implementation.js")); |
| 885 | -var _templateRegistryHelpers = __webpack_require__(/*! ../../../../app/modules/import-export-customization/assets/js/shared/utils/template-registry-helpers */ "../app/modules/import-export-customization/assets/js/shared/utils/template-registry-helpers.js"); | |
| 886 | -var _customizationDialogs = __webpack_require__(/*! ../../../../app/modules/import-export-customization/assets/js/shared/registry/customization-dialogs */ "../app/modules/import-export-customization/assets/js/shared/registry/customization-dialogs.js"); | |
| 887 | -var baseModules = { | |
| 2816 | +var _default = window.elementorModules = { | |
| 888 | 2817 | Module: _module.default, |
| 889 | 2818 | ViewModule: _viewModule.default, |
| 890 | 2819 | ArgsObject: _argsObject.default, |
| 891 | 2820 | ForceMethodImplementation: _forceMethodImplementation.default, |
| @@ -891,20 +2820,11 @@ | ||
| 891 | 2820 | ForceMethodImplementation: _forceMethodImplementation.default, |
| 892 | 2821 | utils: { |
| 893 | 2822 | Masonry: _masonry.default, |
| 894 | 2823 | Scroll: _scroll.default |
| 895 | - }, | |
| 896 | - importExport: { | |
| 897 | - createGetInitialState: _templateRegistryHelpers.createGetInitialState, | |
| 898 | - customizationDialogsRegistry: _customizationDialogs.customizationDialogsRegistry | |
| 899 | 2824 | } |
| 900 | 2825 | }; |
| 901 | -if (!window.elementorModules) { | |
| 902 | - window.elementorModules = baseModules; | |
| 903 | -} else { | |
| 904 | - Object.assign(window.elementorModules, baseModules); | |
| 905 | -} | |
| 906 | -var _default = exports["default"] = window.elementorModules; | |
| 2826 | +exports["default"] = _default; | |
| 907 | 2827 | |
| 908 | 2828 | /***/ }), |
| 909 | 2829 | |
| 910 | 2830 | /***/ "../core/common/assets/js/views/modal/header.js": |
| @@ -922,25 +2842,21 @@ | ||
| 922 | 2842 | })); |
| 923 | 2843 | exports["default"] = void 0; |
| 924 | 2844 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 925 | 2845 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 2846 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 926 | 2847 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 927 | 2848 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 928 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 929 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 930 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 931 | -var _default = exports["default"] = /*#__PURE__*/function (_Marionette$LayoutVie) { | |
| 2849 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 2850 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 2851 | +var _default = /*#__PURE__*/function (_Marionette$LayoutVie) { | |
| 2852 | + (0, _inherits2.default)(_default, _Marionette$LayoutVie); | |
| 2853 | + var _super = _createSuper(_default); | |
| 932 | 2854 | function _default() { |
| 933 | 2855 | (0, _classCallCheck2.default)(this, _default); |
| 934 | - return _callSuper(this, _default, arguments); | |
| 2856 | + return _super.apply(this, arguments); | |
| 935 | 2857 | } |
| 936 | - (0, _inherits2.default)(_default, _Marionette$LayoutVie); | |
| 937 | - return (0, _createClass2.default)(_default, [{ | |
| 938 | - key: "tagName", | |
| 939 | - value: function tagName() { | |
| 940 | - return 'header'; | |
| 941 | - } | |
| 942 | - }, { | |
| 2858 | + (0, _createClass2.default)(_default, [{ | |
| 943 | 2859 | key: "className", |
| 944 | 2860 | value: function className() { |
| 945 | 2861 | return 'elementor-templates-modal__header'; |
| 946 | 2862 | } |
| @@ -972,31 +2888,8 @@ | ||
| 972 | 2888 | 'click @ui.closeModal': 'onCloseModalClick' |
| 973 | 2889 | }; |
| 974 | 2890 | } |
| 975 | 2891 | }, { |
| 976 | - key: "onRender", | |
| 977 | - value: function onRender() { | |
| 978 | - this.bindEscapeKey(); | |
| 979 | - } | |
| 980 | - }, { | |
| 981 | - key: "bindEscapeKey", | |
| 982 | - value: function bindEscapeKey() { | |
| 983 | - var _this = this; | |
| 984 | - this.onDocumentKeyDown = function (event) { | |
| 985 | - if ('Escape' === event.key) { | |
| 986 | - _this.onCloseModalClick(); | |
| 987 | - } | |
| 988 | - }; | |
| 989 | - document.addEventListener('keydown', this.onDocumentKeyDown); | |
| 990 | - } | |
| 991 | - }, { | |
| 992 | - key: "onDestroy", | |
| 993 | - value: function onDestroy() { | |
| 994 | - if (this.onDocumentKeyDown) { | |
| 995 | - document.removeEventListener('keydown', this.onDocumentKeyDown); | |
| 996 | - } | |
| 997 | - } | |
| 998 | - }, { | |
| 999 | 2892 | key: "templateHelpers", |
| 1000 | 2893 | value: function templateHelpers() { |
| 1001 | 2894 | return { |
| 1002 | 2895 | closeType: this.getOption('closeType') |
| @@ -1005,11 +2898,8 @@ | ||
| 1005 | 2898 | }, { |
| 1006 | 2899 | key: "onCloseModalClick", |
| 1007 | 2900 | value: function onCloseModalClick() { |
| 1008 | 2901 | this._parent._parent._parent.hideModal(); |
| 1009 | - var documentType = this.getDocumentType(); | |
| 1010 | - var customEvent = new CustomEvent("core/modal/close/".concat(documentType)); | |
| 1011 | - window.dispatchEvent(customEvent); | |
| 1012 | 2902 | if (this.isFloatingButtonLibraryClose()) { |
| 1013 | 2903 | $e.internal('document/save/set-is-modified', { |
| 1014 | 2904 | status: false |
| 1015 | 2905 | }); |
| @@ -1016,25 +2906,17 @@ | ||
| 1016 | 2906 | window.location.href = elementor.config.admin_floating_button_admin_url; |
| 1017 | 2907 | } |
| 1018 | 2908 | } |
| 1019 | 2909 | }, { |
| 1020 | - key: "getDocumentType", | |
| 1021 | - value: function getDocumentType() { | |
| 1022 | - var _elementor$config$doc, _elementor; | |
| 1023 | - var DEFAULT_TYPE = 'default'; | |
| 1024 | - if ('undefined' === typeof window.elementor) { | |
| 1025 | - return DEFAULT_TYPE; | |
| 1026 | - } | |
| 1027 | - return (_elementor$config$doc = (_elementor = elementor) === null || _elementor === void 0 || (_elementor = _elementor.config) === null || _elementor === void 0 || (_elementor = _elementor.document) === null || _elementor === void 0 ? void 0 : _elementor.type) !== null && _elementor$config$doc !== void 0 ? _elementor$config$doc : DEFAULT_TYPE; | |
| 1028 | - } | |
| 1029 | - }, { | |
| 1030 | 2910 | key: "isFloatingButtonLibraryClose", |
| 1031 | 2911 | value: function isFloatingButtonLibraryClose() { |
| 1032 | - var _elementor$config, _elementor$config2; | |
| 1033 | - return window.elementor && ((_elementor$config = elementor.config) === null || _elementor$config === void 0 ? void 0 : _elementor$config.admin_floating_button_admin_url) && 'floating-buttons' === ((_elementor$config2 = elementor.config) === null || _elementor$config2 === void 0 || (_elementor$config2 = _elementor$config2.document) === null || _elementor$config2 === void 0 ? void 0 : _elementor$config2.type) && (this.$el.closest('.dialog-lightbox-widget-content').find('.elementor-template-library-template-floating_button').length || this.$el.closest('.dialog-lightbox-widget-content').find('#elementor-template-library-preview').length || this.$el.closest('.dialog-lightbox-widget-content').find('#elementor-template-library-templates-empty').length); | |
| 2912 | + var _elementor$config, _elementor$config2, _elementor$config2$do; | |
| 2913 | + return window.elementor && ((_elementor$config = elementor.config) === null || _elementor$config === void 0 ? void 0 : _elementor$config.admin_floating_button_admin_url) && 'floating-buttons' === ((_elementor$config2 = elementor.config) === null || _elementor$config2 === void 0 ? void 0 : (_elementor$config2$do = _elementor$config2.document) === null || _elementor$config2$do === void 0 ? void 0 : _elementor$config2$do.type) && (this.$el.closest('.dialog-lightbox-widget-content').find('.elementor-template-library-template-floating_button').length || this.$el.closest('.dialog-lightbox-widget-content').find('#elementor-template-library-preview').length || this.$el.closest('.dialog-lightbox-widget-content').find('#elementor-template-library-templates-empty').length); | |
| 1034 | 2914 | } |
| 1035 | 2915 | }]); |
| 2916 | + return _default; | |
| 1036 | 2917 | }(Marionette.LayoutView); |
| 2918 | +exports["default"] = _default; | |
| 1037 | 2919 | |
| 1038 | 2920 | /***/ }), |
| 1039 | 2921 | |
| 1040 | 2922 | /***/ "../core/common/assets/js/views/modal/layout.js": |
| @@ -1052,23 +2934,24 @@ | ||
| 1052 | 2934 | })); |
| 1053 | 2935 | exports["default"] = void 0; |
| 1054 | 2936 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 1055 | 2937 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 2938 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1056 | 2939 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 1057 | 2940 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 1058 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1059 | 2941 | var _header = _interopRequireDefault(__webpack_require__(/*! ./header */ "../core/common/assets/js/views/modal/header.js")); |
| 1060 | 2942 | var _logo = _interopRequireDefault(__webpack_require__(/*! ./logo */ "../core/common/assets/js/views/modal/logo.js")); |
| 1061 | 2943 | var _loading = _interopRequireDefault(__webpack_require__(/*! ./loading */ "../core/common/assets/js/views/modal/loading.js")); |
| 1062 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 1063 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 1064 | -var _default = exports["default"] = /*#__PURE__*/function (_Marionette$LayoutVie) { | |
| 2944 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 2945 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 2946 | +var _default = /*#__PURE__*/function (_Marionette$LayoutVie) { | |
| 2947 | + (0, _inherits2.default)(_default, _Marionette$LayoutVie); | |
| 2948 | + var _super = _createSuper(_default); | |
| 1065 | 2949 | function _default() { |
| 1066 | 2950 | (0, _classCallCheck2.default)(this, _default); |
| 1067 | - return _callSuper(this, _default, arguments); | |
| 2951 | + return _super.apply(this, arguments); | |
| 1068 | 2952 | } |
| 1069 | - (0, _inherits2.default)(_default, _Marionette$LayoutVie); | |
| 1070 | - return (0, _createClass2.default)(_default, [{ | |
| 2953 | + (0, _createClass2.default)(_default, [{ | |
| 1071 | 2954 | key: "el", |
| 1072 | 2955 | value: function el() { |
| 1073 | 2956 | return this.getModal().getElements('widget'); |
| 1074 | 2957 | } |
| @@ -1175,9 +3058,11 @@ | ||
| 1175 | 3058 | value: function showLogo() { |
| 1176 | 3059 | this.getHeaderView().logoArea.show(new _logo.default(this.getLogoOptions())); |
| 1177 | 3060 | } |
| 1178 | 3061 | }]); |
| 3062 | + return _default; | |
| 1179 | 3063 | }(Marionette.LayoutView); |
| 3064 | +exports["default"] = _default; | |
| 1180 | 3065 | |
| 1181 | 3066 | /***/ }), |
| 1182 | 3067 | |
| 1183 | 3068 | /***/ "../core/common/assets/js/views/modal/loading.js": |
| @@ -1195,20 +3080,21 @@ | ||
| 1195 | 3080 | })); |
| 1196 | 3081 | exports["default"] = void 0; |
| 1197 | 3082 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 1198 | 3083 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 3084 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1199 | 3085 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 1200 | 3086 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 1201 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1202 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 1203 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 1204 | -var _default = exports["default"] = /*#__PURE__*/function (_Marionette$ItemView) { | |
| 3087 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 3088 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 3089 | +var _default = /*#__PURE__*/function (_Marionette$ItemView) { | |
| 3090 | + (0, _inherits2.default)(_default, _Marionette$ItemView); | |
| 3091 | + var _super = _createSuper(_default); | |
| 1205 | 3092 | function _default() { |
| 1206 | 3093 | (0, _classCallCheck2.default)(this, _default); |
| 1207 | - return _callSuper(this, _default, arguments); | |
| 3094 | + return _super.apply(this, arguments); | |
| 1208 | 3095 | } |
| 1209 | - (0, _inherits2.default)(_default, _Marionette$ItemView); | |
| 1210 | - return (0, _createClass2.default)(_default, [{ | |
| 3096 | + (0, _createClass2.default)(_default, [{ | |
| 1211 | 3097 | key: "id", |
| 1212 | 3098 | value: function id() { |
| 1213 | 3099 | return 'elementor-template-library-loading'; |
| 1214 | 3100 | } |
| @@ -1217,9 +3103,11 @@ | ||
| 1217 | 3103 | value: function getTemplate() { |
| 1218 | 3104 | return '#tmpl-elementor-template-library-loading'; |
| 1219 | 3105 | } |
| 1220 | 3106 | }]); |
| 3107 | + return _default; | |
| 1221 | 3108 | }(Marionette.ItemView); |
| 3109 | +exports["default"] = _default; | |
| 1222 | 3110 | |
| 1223 | 3111 | /***/ }), |
| 1224 | 3112 | |
| 1225 | 3113 | /***/ "../core/common/assets/js/views/modal/logo.js": |
| @@ -1237,20 +3125,21 @@ | ||
| 1237 | 3125 | })); |
| 1238 | 3126 | exports["default"] = void 0; |
| 1239 | 3127 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 1240 | 3128 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 3129 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1241 | 3130 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 1242 | 3131 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 1243 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1244 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 1245 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 1246 | -var _default = exports["default"] = /*#__PURE__*/function (_Marionette$ItemView) { | |
| 3132 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 3133 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 3134 | +var _default = /*#__PURE__*/function (_Marionette$ItemView) { | |
| 3135 | + (0, _inherits2.default)(_default, _Marionette$ItemView); | |
| 3136 | + var _super = _createSuper(_default); | |
| 1247 | 3137 | function _default() { |
| 1248 | 3138 | (0, _classCallCheck2.default)(this, _default); |
| 1249 | - return _callSuper(this, _default, arguments); | |
| 3139 | + return _super.apply(this, arguments); | |
| 1250 | 3140 | } |
| 1251 | - (0, _inherits2.default)(_default, _Marionette$ItemView); | |
| 1252 | - return (0, _createClass2.default)(_default, [{ | |
| 3141 | + (0, _createClass2.default)(_default, [{ | |
| 1253 | 3142 | key: "getTemplate", |
| 1254 | 3143 | value: function getTemplate() { |
| 1255 | 3144 | return '#tmpl-elementor-templates-modal__header__logo'; |
| 1256 | 3145 | } |
| @@ -1281,9 +3170,11 @@ | ||
| 1281 | 3170 | clickCallback(); |
| 1282 | 3171 | } |
| 1283 | 3172 | } |
| 1284 | 3173 | }]); |
| 3174 | + return _default; | |
| 1285 | 3175 | }(Marionette.ItemView); |
| 3176 | +exports["default"] = _default; | |
| 1286 | 3177 | |
| 1287 | 3178 | /***/ }), |
| 1288 | 3179 | |
| 1289 | 3180 | /***/ "../modules/web-cli/assets/js/modules/command-base.js": |
| @@ -1301,25 +3192,26 @@ | ||
| 1301 | 3192 | })); |
| 1302 | 3193 | exports["default"] = void 0; |
| 1303 | 3194 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 1304 | 3195 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 3196 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1305 | 3197 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 1306 | 3198 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 1307 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1308 | 3199 | var _commandInfra = _interopRequireDefault(__webpack_require__(/*! ./command-infra */ "../modules/web-cli/assets/js/modules/command-infra.js")); |
| 1309 | 3200 | var _deprecation = _interopRequireDefault(__webpack_require__(/*! elementor-api/utils/deprecation */ "../modules/web-cli/assets/js/utils/deprecation.js")); |
| 1310 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 1311 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 3201 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 3202 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 1312 | 3203 | /** |
| 1313 | 3204 | * @name $e.modules.CommandBase |
| 1314 | 3205 | */ |
| 1315 | -var CommandBase = exports["default"] = /*#__PURE__*/function (_CommandInfra) { | |
| 3206 | +var CommandBase = /*#__PURE__*/function (_CommandInfra) { | |
| 3207 | + (0, _inherits2.default)(CommandBase, _CommandInfra); | |
| 3208 | + var _super = _createSuper(CommandBase); | |
| 1316 | 3209 | function CommandBase() { |
| 1317 | 3210 | (0, _classCallCheck2.default)(this, CommandBase); |
| 1318 | - return _callSuper(this, CommandBase, arguments); | |
| 3211 | + return _super.apply(this, arguments); | |
| 1319 | 3212 | } |
| 1320 | - (0, _inherits2.default)(CommandBase, _CommandInfra); | |
| 1321 | - return (0, _createClass2.default)(CommandBase, [{ | |
| 3213 | + (0, _createClass2.default)(CommandBase, [{ | |
| 1322 | 3214 | key: "onBeforeRun", |
| 1323 | 3215 | value: function onBeforeRun() { |
| 1324 | 3216 | var args = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; |
| 1325 | 3217 | $e.hooks.runUIBefore(this.command, args); |
| @@ -1341,9 +3233,9 @@ | ||
| 1341 | 3233 | key: "onAfterApply", |
| 1342 | 3234 | value: function onAfterApply() { |
| 1343 | 3235 | var args = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; |
| 1344 | 3236 | var result = arguments.length > 1 ? arguments[1] : undefined; |
| 1345 | - return $e.hooks.runDataAfter(this.command, args, result); | |
| 3237 | + $e.hooks.runDataAfter(this.command, args, result); | |
| 1346 | 3238 | } |
| 1347 | 3239 | }, { |
| 1348 | 3240 | key: "onCatchApply", |
| 1349 | 3241 | value: function onCatchApply(e) { |
| @@ -1398,9 +3290,11 @@ | ||
| 1398 | 3290 | value: function getInstanceType() { |
| 1399 | 3291 | return 'CommandBase'; |
| 1400 | 3292 | } |
| 1401 | 3293 | }]); |
| 3294 | + return CommandBase; | |
| 1402 | 3295 | }(_commandInfra.default); |
| 3296 | +exports["default"] = CommandBase; | |
| 1403 | 3297 | |
| 1404 | 3298 | /***/ }), |
| 1405 | 3299 | |
| 1406 | 3300 | /***/ "../modules/web-cli/assets/js/modules/command-callback-base.js": |
| @@ -1418,24 +3312,25 @@ | ||
| 1418 | 3312 | })); |
| 1419 | 3313 | exports["default"] = void 0; |
| 1420 | 3314 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 1421 | 3315 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 3316 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1422 | 3317 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 1423 | 3318 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 1424 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1425 | 3319 | var _commandBase = _interopRequireDefault(__webpack_require__(/*! ./command-base */ "../modules/web-cli/assets/js/modules/command-base.js")); |
| 1426 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 1427 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 3320 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 3321 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 1428 | 3322 | /** |
| 1429 | 3323 | * To support pure callbacks in the API(commands.js), to ensure they have registered with the proper context. |
| 1430 | 3324 | */ |
| 1431 | -var CommandCallbackBase = exports["default"] = /*#__PURE__*/function (_CommandBase) { | |
| 3325 | +var CommandCallbackBase = /*#__PURE__*/function (_CommandBase) { | |
| 3326 | + (0, _inherits2.default)(CommandCallbackBase, _CommandBase); | |
| 3327 | + var _super = _createSuper(CommandCallbackBase); | |
| 1432 | 3328 | function CommandCallbackBase() { |
| 1433 | 3329 | (0, _classCallCheck2.default)(this, CommandCallbackBase); |
| 1434 | - return _callSuper(this, CommandCallbackBase, arguments); | |
| 3330 | + return _super.apply(this, arguments); | |
| 1435 | 3331 | } |
| 1436 | - (0, _inherits2.default)(CommandCallbackBase, _CommandBase); | |
| 1437 | - return (0, _createClass2.default)(CommandCallbackBase, [{ | |
| 3332 | + (0, _createClass2.default)(CommandCallbackBase, [{ | |
| 1438 | 3333 | key: "apply", |
| 1439 | 3334 | value: function apply() { |
| 1440 | 3335 | var args = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; |
| 1441 | 3336 | return this.constructor.getCallback()(args); |
| @@ -1458,9 +3353,11 @@ | ||
| 1458 | 3353 | value: function getCallback() { |
| 1459 | 3354 | return this.registerConfig.callback; |
| 1460 | 3355 | } |
| 1461 | 3356 | }]); |
| 3357 | + return CommandCallbackBase; | |
| 1462 | 3358 | }(_commandBase.default); |
| 3359 | +exports["default"] = CommandCallbackBase; | |
| 1463 | 3360 | |
| 1464 | 3361 | /***/ }), |
| 1465 | 3362 | |
| 1466 | 3363 | /***/ "../modules/web-cli/assets/js/modules/command-infra.js": |
| @@ -1478,20 +3375,22 @@ | ||
| 1478 | 3375 | })); |
| 1479 | 3376 | exports["default"] = void 0; |
| 1480 | 3377 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 1481 | 3378 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 3379 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1482 | 3380 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 1483 | 3381 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 1484 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1485 | 3382 | var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ "../node_modules/@babel/runtime/helpers/defineProperty.js")); |
| 1486 | 3383 | var _argsObject = _interopRequireDefault(__webpack_require__(/*! elementor-assets-js/modules/imports/args-object */ "../assets/dev/js/modules/imports/args-object.js")); |
| 1487 | 3384 | var _deprecation = _interopRequireDefault(__webpack_require__(/*! elementor-api/utils/deprecation */ "../modules/web-cli/assets/js/utils/deprecation.js")); |
| 1488 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 1489 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 3385 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 3386 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 1490 | 3387 | /** |
| 1491 | 3388 | * @typedef {import('../modules/component-base')} ComponentBase |
| 1492 | 3389 | */ |
| 1493 | -var CommandInfra = exports["default"] = /*#__PURE__*/function (_ArgsObject) { | |
| 3390 | +var CommandInfra = /*#__PURE__*/function (_ArgsObject) { | |
| 3391 | + (0, _inherits2.default)(CommandInfra, _ArgsObject); | |
| 3392 | + var _super = _createSuper(CommandInfra); | |
| 1494 | 3393 | /** |
| 1495 | 3394 | * Function constructor(). |
| 1496 | 3395 | * |
| 1497 | 3396 | * Create Commands Base. |
| @@ -1501,9 +3400,9 @@ | ||
| 1501 | 3400 | function CommandInfra() { |
| 1502 | 3401 | var _this; |
| 1503 | 3402 | var args = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; |
| 1504 | 3403 | (0, _classCallCheck2.default)(this, CommandInfra); |
| 1505 | - _this = _callSuper(this, CommandInfra, [args]); | |
| 3404 | + _this = _super.call(this, args); | |
| 1506 | 3405 | if (!_this.constructor.registerConfig) { |
| 1507 | 3406 | throw RangeError('Doing it wrong: Each command type should have `registerConfig`.'); |
| 1508 | 3407 | } |
| 1509 | 3408 | |
| @@ -1530,10 +3429,9 @@ | ||
| 1530 | 3429 | * Initialize command, called after construction. |
| 1531 | 3430 | * |
| 1532 | 3431 | * @param {{}} args |
| 1533 | 3432 | */ |
| 1534 | - (0, _inherits2.default)(CommandInfra, _ArgsObject); | |
| 1535 | - return (0, _createClass2.default)(CommandInfra, [{ | |
| 3433 | + (0, _createClass2.default)(CommandInfra, [{ | |
| 1536 | 3434 | key: "currentCommand", |
| 1537 | 3435 | get: |
| 1538 | 3436 | /** |
| 1539 | 3437 | * @deprecated since 3.7.0, use `this.command` instead. |
| @@ -1697,9 +3595,11 @@ | ||
| 1697 | 3595 | value: function setRegisterConfig(config) { |
| 1698 | 3596 | this.registerConfig = Object.freeze(config); |
| 1699 | 3597 | } |
| 1700 | 3598 | }]); |
| 3599 | + return CommandInfra; | |
| 1701 | 3600 | }(_argsObject.default); |
| 3601 | +exports["default"] = CommandInfra; | |
| 1702 | 3602 | /** |
| 1703 | 3603 | * @type {Object} |
| 1704 | 3604 | */ |
| 1705 | 3605 | (0, _defineProperty2.default)(CommandInfra, "registerConfig", null); |
| @@ -1721,28 +3621,32 @@ | ||
| 1721 | 3621 | })); |
| 1722 | 3622 | exports["default"] = exports.Close = void 0; |
| 1723 | 3623 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 1724 | 3624 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 3625 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1725 | 3626 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 1726 | 3627 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 1727 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1728 | 3628 | var _commandBase = _interopRequireDefault(__webpack_require__(/*! elementor-api/modules/command-base */ "../modules/web-cli/assets/js/modules/command-base.js")); |
| 1729 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 1730 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 1731 | -var Close = exports.Close = /*#__PURE__*/function (_CommandBase) { | |
| 3629 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 3630 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 3631 | +var Close = /*#__PURE__*/function (_CommandBase) { | |
| 3632 | + (0, _inherits2.default)(Close, _CommandBase); | |
| 3633 | + var _super = _createSuper(Close); | |
| 1732 | 3634 | function Close() { |
| 1733 | 3635 | (0, _classCallCheck2.default)(this, Close); |
| 1734 | - return _callSuper(this, Close, arguments); | |
| 3636 | + return _super.apply(this, arguments); | |
| 1735 | 3637 | } |
| 1736 | - (0, _inherits2.default)(Close, _CommandBase); | |
| 1737 | - return (0, _createClass2.default)(Close, [{ | |
| 3638 | + (0, _createClass2.default)(Close, [{ | |
| 1738 | 3639 | key: "apply", |
| 1739 | 3640 | value: function apply() { |
| 1740 | 3641 | this.component.close(); |
| 1741 | 3642 | } |
| 1742 | 3643 | }]); |
| 3644 | + return Close; | |
| 1743 | 3645 | }(_commandBase.default); |
| 1744 | -var _default = exports["default"] = Close; | |
| 3646 | +exports.Close = Close; | |
| 3647 | +var _default = Close; | |
| 3648 | +exports["default"] = _default; | |
| 1745 | 3649 | |
| 1746 | 3650 | /***/ }), |
| 1747 | 3651 | |
| 1748 | 3652 | /***/ "../modules/web-cli/assets/js/modules/commands/index.js": |
| @@ -1796,28 +3700,32 @@ | ||
| 1796 | 3700 | })); |
| 1797 | 3701 | exports["default"] = exports.Open = void 0; |
| 1798 | 3702 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 1799 | 3703 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 3704 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1800 | 3705 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 1801 | 3706 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 1802 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1803 | 3707 | var _commandBase = _interopRequireDefault(__webpack_require__(/*! elementor-api/modules/command-base */ "../modules/web-cli/assets/js/modules/command-base.js")); |
| 1804 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 1805 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 1806 | -var Open = exports.Open = /*#__PURE__*/function (_CommandBase) { | |
| 3708 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 3709 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 3710 | +var Open = /*#__PURE__*/function (_CommandBase) { | |
| 3711 | + (0, _inherits2.default)(Open, _CommandBase); | |
| 3712 | + var _super = _createSuper(Open); | |
| 1807 | 3713 | function Open() { |
| 1808 | 3714 | (0, _classCallCheck2.default)(this, Open); |
| 1809 | - return _callSuper(this, Open, arguments); | |
| 3715 | + return _super.apply(this, arguments); | |
| 1810 | 3716 | } |
| 1811 | - (0, _inherits2.default)(Open, _CommandBase); | |
| 1812 | - return (0, _createClass2.default)(Open, [{ | |
| 3717 | + (0, _createClass2.default)(Open, [{ | |
| 1813 | 3718 | key: "apply", |
| 1814 | 3719 | value: function apply() { |
| 1815 | 3720 | $e.route(this.component.getNamespace()); |
| 1816 | 3721 | } |
| 1817 | 3722 | }]); |
| 3723 | + return Open; | |
| 1818 | 3724 | }(_commandBase.default); |
| 1819 | -var _default = exports["default"] = Open; | |
| 3725 | +exports.Open = Open; | |
| 3726 | +var _default = Open; | |
| 3727 | +exports["default"] = _default; | |
| 1820 | 3728 | |
| 1821 | 3729 | /***/ }), |
| 1822 | 3730 | |
| 1823 | 3731 | /***/ "../modules/web-cli/assets/js/modules/commands/toggle.js": |
| @@ -1835,21 +3743,22 @@ | ||
| 1835 | 3743 | })); |
| 1836 | 3744 | exports["default"] = exports.Toggle = void 0; |
| 1837 | 3745 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 1838 | 3746 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 3747 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1839 | 3748 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 1840 | 3749 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 1841 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1842 | 3750 | var _commandBase = _interopRequireDefault(__webpack_require__(/*! elementor-api/modules/command-base */ "../modules/web-cli/assets/js/modules/command-base.js")); |
| 1843 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 1844 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 1845 | -var Toggle = exports.Toggle = /*#__PURE__*/function (_CommandBase) { | |
| 3751 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 3752 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 3753 | +var Toggle = /*#__PURE__*/function (_CommandBase) { | |
| 3754 | + (0, _inherits2.default)(Toggle, _CommandBase); | |
| 3755 | + var _super = _createSuper(Toggle); | |
| 1846 | 3756 | function Toggle() { |
| 1847 | 3757 | (0, _classCallCheck2.default)(this, Toggle); |
| 1848 | - return _callSuper(this, Toggle, arguments); | |
| 3758 | + return _super.apply(this, arguments); | |
| 1849 | 3759 | } |
| 1850 | - (0, _inherits2.default)(Toggle, _CommandBase); | |
| 1851 | - return (0, _createClass2.default)(Toggle, [{ | |
| 3760 | + (0, _createClass2.default)(Toggle, [{ | |
| 1852 | 3761 | key: "apply", |
| 1853 | 3762 | value: function apply() { |
| 1854 | 3763 | if (this.component.isOpen) { |
| 1855 | 3764 | this.component.close(); |
| @@ -1857,10 +3766,13 @@ | ||
| 1857 | 3766 | $e.route(this.component.getNamespace()); |
| 1858 | 3767 | } |
| 1859 | 3768 | } |
| 1860 | 3769 | }]); |
| 3770 | + return Toggle; | |
| 1861 | 3771 | }(_commandBase.default); |
| 1862 | -var _default = exports["default"] = Toggle; | |
| 3772 | +exports.Toggle = Toggle; | |
| 3773 | +var _default = Toggle; | |
| 3774 | +exports["default"] = _default; | |
| 1863 | 3775 | |
| 1864 | 3776 | /***/ }), |
| 1865 | 3777 | |
| 1866 | 3778 | /***/ "../modules/web-cli/assets/js/modules/component-base.js": |
| @@ -1880,32 +3792,33 @@ | ||
| 1880 | 3792 | var _defineProperty2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/defineProperty */ "../node_modules/@babel/runtime/helpers/defineProperty.js")); |
| 1881 | 3793 | var _slicedToArray2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/slicedToArray */ "../node_modules/@babel/runtime/helpers/slicedToArray.js")); |
| 1882 | 3794 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 1883 | 3795 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 3796 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1884 | 3797 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 1885 | 3798 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 1886 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 1887 | 3799 | var _commandCallbackBase = _interopRequireDefault(__webpack_require__(/*! elementor-api/modules/command-callback-base */ "../modules/web-cli/assets/js/modules/command-callback-base.js")); |
| 1888 | -var _toolkit = __webpack_require__(/*! @reduxjs/toolkit */ "@reduxjs/toolkit"); | |
| 3800 | +var _toolkit = __webpack_require__(/*! @reduxjs/toolkit */ "../node_modules/@reduxjs/toolkit/dist/redux-toolkit.esm.js"); | |
| 1889 | 3801 | var _module = _interopRequireDefault(__webpack_require__(/*! elementor/assets/dev/js/modules/imports/module.js */ "../assets/dev/js/modules/imports/module.js")); |
| 1890 | 3802 | var _forceMethodImplementation = _interopRequireDefault(__webpack_require__(/*! ../utils/force-method-implementation */ "../modules/web-cli/assets/js/utils/force-method-implementation.js")); |
| 1891 | 3803 | var _deprecation = _interopRequireDefault(__webpack_require__(/*! elementor-api/utils/deprecation */ "../modules/web-cli/assets/js/utils/deprecation.js")); |
| 1892 | -function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; } | |
| 1893 | -function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } | |
| 1894 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 1895 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 3804 | +function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; } | |
| 3805 | +function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; } | |
| 3806 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 3807 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 1896 | 3808 | /** |
| 1897 | 3809 | * @typedef {import('./command-infra')} CommandInfra |
| 1898 | 3810 | * @typedef {import('./hook-base')} HookBase |
| 1899 | 3811 | * @typedef {import('../core/states/ui-state-base')} UiStateBase |
| 1900 | 3812 | */ |
| 1901 | -var ComponentBase = exports["default"] = /*#__PURE__*/function (_Module) { | |
| 3813 | +var ComponentBase = /*#__PURE__*/function (_Module) { | |
| 3814 | + (0, _inherits2.default)(ComponentBase, _Module); | |
| 3815 | + var _super = _createSuper(ComponentBase); | |
| 1902 | 3816 | function ComponentBase() { |
| 1903 | 3817 | (0, _classCallCheck2.default)(this, ComponentBase); |
| 1904 | - return _callSuper(this, ComponentBase, arguments); | |
| 3818 | + return _super.apply(this, arguments); | |
| 1905 | 3819 | } |
| 1906 | - (0, _inherits2.default)(ComponentBase, _Module); | |
| 1907 | - return (0, _createClass2.default)(ComponentBase, [{ | |
| 3820 | + (0, _createClass2.default)(ComponentBase, [{ | |
| 1908 | 3821 | key: "__construct", |
| 1909 | 3822 | value: function __construct() { |
| 1910 | 3823 | var args = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; |
| 1911 | 3824 | if (args.manager) { |
| @@ -1961,11 +3874,11 @@ | ||
| 1961 | 3874 | Object.values(this.getUiStates()).forEach(function (instance) { |
| 1962 | 3875 | return _this.registerUiState(instance); |
| 1963 | 3876 | }); |
| 1964 | 3877 | Object.entries(this.getStates()).forEach(function (_ref9) { |
| 1965 | - var _ref0 = (0, _slicedToArray2.default)(_ref9, 2), | |
| 1966 | - id = _ref0[0], | |
| 1967 | - state = _ref0[1]; | |
| 3878 | + var _ref10 = (0, _slicedToArray2.default)(_ref9, 2), | |
| 3879 | + id = _ref10[0], | |
| 3880 | + state = _ref10[1]; | |
| 1968 | 3881 | return _this.registerState(id, state); |
| 1969 | 3882 | }); |
| 1970 | 3883 | } |
| 1971 | 3884 | |
| @@ -2156,13 +4069,14 @@ | ||
| 2156 | 4069 | registerConfig.callback = context; |
| 2157 | 4070 | |
| 2158 | 4071 | // Unique class. |
| 2159 | 4072 | context = /*#__PURE__*/function (_CommandCallbackBase) { |
| 4073 | + (0, _inherits2.default)(context, _CommandCallbackBase); | |
| 4074 | + var _super2 = _createSuper(context); | |
| 2160 | 4075 | function context() { |
| 2161 | 4076 | (0, _classCallCheck2.default)(this, context); |
| 2162 | - return _callSuper(this, context, arguments); | |
| 4077 | + return _super2.apply(this, arguments); | |
| 2163 | 4078 | } |
| 2164 | - (0, _inherits2.default)(context, _CommandCallbackBase); | |
| 2165 | 4079 | return (0, _createClass2.default)(context); |
| 2166 | 4080 | }(_commandCallbackBase.default); |
| 2167 | 4081 | } |
| 2168 | 4082 | context.setRegisterConfig(registerConfig); |
| @@ -2387,12 +4301,12 @@ | ||
| 2387 | 4301 | var _this5 = this; |
| 2388 | 4302 | var commands = {}; |
| 2389 | 4303 | |
| 2390 | 4304 | // Convert `Commands` to `ComponentBase` workable format. |
| 2391 | - Object.entries(commandsFromImport).forEach(function (_ref1) { | |
| 2392 | - var _ref10 = (0, _slicedToArray2.default)(_ref1, 2), | |
| 2393 | - className = _ref10[0], | |
| 2394 | - Class = _ref10[1]; | |
| 4305 | + Object.entries(commandsFromImport).forEach(function (_ref11) { | |
| 4306 | + var _ref12 = (0, _slicedToArray2.default)(_ref11, 2), | |
| 4307 | + className = _ref12[0], | |
| 4308 | + Class = _ref12[1]; | |
| 2395 | 4309 | var command = _this5.normalizeCommandName(className); |
| 2396 | 4310 | commands[command] = Class; |
| 2397 | 4311 | }); |
| 2398 | 4312 | return commands; |
| @@ -2452,9 +4366,11 @@ | ||
| 2452 | 4366 | value: function toggleHistoryClass() { |
| 2453 | 4367 | document.body.classList.toggle('e-routes-has-history', !!$e.routes.getHistory(this.getServiceName()).length); |
| 2454 | 4368 | } |
| 2455 | 4369 | }]); |
| 4370 | + return ComponentBase; | |
| 2456 | 4371 | }(_module.default); |
| 4372 | +exports["default"] = ComponentBase; | |
| 2457 | 4373 | |
| 2458 | 4374 | /***/ }), |
| 2459 | 4375 | |
| 2460 | 4376 | /***/ "../modules/web-cli/assets/js/modules/component-modal-base.js": |
| @@ -2471,33 +4387,33 @@ | ||
| 2471 | 4387 | Object.defineProperty(exports, "__esModule", ({ |
| 2472 | 4388 | value: true |
| 2473 | 4389 | })); |
| 2474 | 4390 | exports["default"] = void 0; |
| 2475 | -var _readOnlyError2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/readOnlyError */ "../node_modules/@babel/runtime/helpers/readOnlyError.js")); | |
| 2476 | 4391 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 2477 | 4392 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 4393 | +var _get2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/get */ "../node_modules/@babel/runtime/helpers/get.js")); | |
| 4394 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 2478 | 4395 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 2479 | 4396 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 2480 | -var _get2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/get */ "../node_modules/@babel/runtime/helpers/get.js")); | |
| 2481 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 2482 | 4397 | var _componentBase = _interopRequireDefault(__webpack_require__(/*! ./component-base */ "../modules/web-cli/assets/js/modules/component-base.js")); |
| 2483 | 4398 | var commands = _interopRequireWildcard(__webpack_require__(/*! ./commands/ */ "../modules/web-cli/assets/js/modules/commands/index.js")); |
| 2484 | 4399 | var _forceMethodImplementation = _interopRequireDefault(__webpack_require__(/*! ../utils/force-method-implementation */ "../modules/web-cli/assets/js/utils/force-method-implementation.js")); |
| 2485 | -function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); } | |
| 2486 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 2487 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 2488 | -function _superPropGet(t, o, e, r) { var p = (0, _get2.default)((0, _getPrototypeOf2.default)(1 & r ? t.prototype : t), o, e); return 2 & r && "function" == typeof p ? function (t) { return p.apply(e, t); } : p; } | |
| 2489 | -var ComponentModalBase = exports["default"] = /*#__PURE__*/function (_ComponentBase) { | |
| 4400 | +function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); } | |
| 4401 | +function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; } | |
| 4402 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 4403 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 4404 | +var ComponentModalBase = /*#__PURE__*/function (_ComponentBase) { | |
| 4405 | + (0, _inherits2.default)(ComponentModalBase, _ComponentBase); | |
| 4406 | + var _super = _createSuper(ComponentModalBase); | |
| 2490 | 4407 | function ComponentModalBase() { |
| 2491 | 4408 | (0, _classCallCheck2.default)(this, ComponentModalBase); |
| 2492 | - return _callSuper(this, ComponentModalBase, arguments); | |
| 4409 | + return _super.apply(this, arguments); | |
| 2493 | 4410 | } |
| 2494 | - (0, _inherits2.default)(ComponentModalBase, _ComponentBase); | |
| 2495 | - return (0, _createClass2.default)(ComponentModalBase, [{ | |
| 4411 | + (0, _createClass2.default)(ComponentModalBase, [{ | |
| 2496 | 4412 | key: "registerAPI", |
| 2497 | 4413 | value: function registerAPI() { |
| 2498 | 4414 | var _this = this; |
| 2499 | - _superPropGet(ComponentModalBase, "registerAPI", this, 3)([]); | |
| 4415 | + (0, _get2.default)((0, _getPrototypeOf2.default)(ComponentModalBase.prototype), "registerAPI", this).call(this); | |
| 2500 | 4416 | $e.shortcuts.register('esc', { |
| 2501 | 4417 | scopes: [this.getNamespace()], |
| 2502 | 4418 | callback: function callback() { |
| 2503 | 4419 | return _this.close(); |
| @@ -2534,13 +4450,12 @@ | ||
| 2534 | 4450 | } |
| 2535 | 4451 | }, { |
| 2536 | 4452 | key: "close", |
| 2537 | 4453 | value: function close() { |
| 2538 | - if (!_superPropGet(ComponentModalBase, "close", this, 3)([])) { | |
| 4454 | + if (!(0, _get2.default)((0, _getPrototypeOf2.default)(ComponentModalBase.prototype), "close", this).call(this)) { | |
| 2539 | 4455 | return false; |
| 2540 | 4456 | } |
| 2541 | - var close = elementor.hooks.applyFilters('component/modal/close', this.layout.getModal().hide.bind(this.layout.getModal()), this); | |
| 2542 | - close(); | |
| 4457 | + this.layout.getModal().hide(); | |
| 2543 | 4458 | return true; |
| 2544 | 4459 | } |
| 2545 | 4460 | }, { |
| 2546 | 4461 | key: "getModalLayout", |
| @@ -2547,9 +4462,11 @@ | ||
| 2547 | 4462 | value: function getModalLayout() { |
| 2548 | 4463 | (0, _forceMethodImplementation.default)(); |
| 2549 | 4464 | } |
| 2550 | 4465 | }]); |
| 4466 | + return ComponentModalBase; | |
| 2551 | 4467 | }(_componentBase.default); |
| 4468 | +exports["default"] = ComponentModalBase; | |
| 2552 | 4469 | |
| 2553 | 4470 | /***/ }), |
| 2554 | 4471 | |
| 2555 | 4472 | /***/ "../modules/web-cli/assets/js/modules/hook-break.js": |
| @@ -2567,22 +4484,24 @@ | ||
| 2567 | 4484 | })); |
| 2568 | 4485 | exports["default"] = void 0; |
| 2569 | 4486 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 2570 | 4487 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 4488 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 2571 | 4489 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 2572 | 4490 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 2573 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 2574 | 4491 | var _wrapNativeSuper2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/wrapNativeSuper */ "../node_modules/@babel/runtime/helpers/wrapNativeSuper.js")); |
| 2575 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 2576 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 2577 | -var HookBreak = exports["default"] = /*#__PURE__*/function (_Error) { | |
| 4492 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 4493 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 4494 | +var HookBreak = /*#__PURE__*/function (_Error) { | |
| 4495 | + (0, _inherits2.default)(HookBreak, _Error); | |
| 4496 | + var _super = _createSuper(HookBreak); | |
| 2578 | 4497 | function HookBreak() { |
| 2579 | 4498 | (0, _classCallCheck2.default)(this, HookBreak); |
| 2580 | - return _callSuper(this, HookBreak, ['HookBreak']); | |
| 4499 | + return _super.call(this, 'HookBreak'); | |
| 2581 | 4500 | } |
| 2582 | - (0, _inherits2.default)(HookBreak, _Error); | |
| 2583 | 4501 | return (0, _createClass2.default)(HookBreak); |
| 2584 | -}(/*#__PURE__*/(0, _wrapNativeSuper2.default)(Error)); | |
| 4502 | +}( /*#__PURE__*/(0, _wrapNativeSuper2.default)(Error)); | |
| 4503 | +exports["default"] = HookBreak; | |
| 2585 | 4504 | |
| 2586 | 4505 | /***/ }), |
| 2587 | 4506 | |
| 2588 | 4507 | /***/ "../modules/web-cli/assets/js/utils/console.js": |
| @@ -2600,13 +4519,13 @@ | ||
| 2600 | 4519 | })); |
| 2601 | 4520 | exports["default"] = void 0; |
| 2602 | 4521 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 2603 | 4522 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 2604 | -var Console = exports["default"] = /*#__PURE__*/function () { | |
| 4523 | +var Console = /*#__PURE__*/function () { | |
| 2605 | 4524 | function Console() { |
| 2606 | 4525 | (0, _classCallCheck2.default)(this, Console); |
| 2607 | 4526 | } |
| 2608 | - return (0, _createClass2.default)(Console, null, [{ | |
| 4527 | + (0, _createClass2.default)(Console, null, [{ | |
| 2609 | 4528 | key: "error", |
| 2610 | 4529 | value: function error(message) { |
| 2611 | 4530 | // Show an error if devTools is available. |
| 2612 | 4531 | if ($e.devTools) { |
| @@ -2630,9 +4549,11 @@ | ||
| 2630 | 4549 | args.unshift('%c %c', style, ''); |
| 2631 | 4550 | (_console = console).warn.apply(_console, args); // eslint-disable-line no-console |
| 2632 | 4551 | } |
| 2633 | 4552 | }]); |
| 4553 | + return Console; | |
| 2634 | 4554 | }(); |
| 4555 | +exports["default"] = Console; | |
| 2635 | 4556 | |
| 2636 | 4557 | /***/ }), |
| 2637 | 4558 | |
| 2638 | 4559 | /***/ "../modules/web-cli/assets/js/utils/deprecation.js": |
| @@ -2660,9 +4581,8 @@ | ||
| 2660 | 4581 | * @property {number} major2 The second number |
| 2661 | 4582 | * @property {number} minor The third number |
| 2662 | 4583 | * @property {string} build The fourth number |
| 2663 | 4584 | */ |
| 2664 | - | |
| 2665 | 4585 | var softDeprecated = function softDeprecated(name, version, replacement) { |
| 2666 | 4586 | if (elementorWebCliConfig.isDebug) { |
| 2667 | 4587 | deprecatedMessage('soft', name, version, replacement); |
| 2668 | 4588 | } |
| @@ -2676,13 +4596,13 @@ | ||
| 2676 | 4596 | message += " - Use `".concat(replacement, "` instead"); |
| 2677 | 4597 | } |
| 2678 | 4598 | _console.default.warn(message); |
| 2679 | 4599 | }; |
| 2680 | -var Deprecation = exports["default"] = /*#__PURE__*/function () { | |
| 4600 | +var Deprecation = /*#__PURE__*/function () { | |
| 2681 | 4601 | function Deprecation() { |
| 2682 | 4602 | (0, _classCallCheck2.default)(this, Deprecation); |
| 2683 | 4603 | } |
| 2684 | - return (0, _createClass2.default)(Deprecation, null, [{ | |
| 4604 | + (0, _createClass2.default)(Deprecation, null, [{ | |
| 2685 | 4605 | key: "deprecated", |
| 2686 | 4606 | value: function deprecated(name, version, replacement) { |
| 2687 | 4607 | if (this.isHardDeprecated(version)) { |
| 2688 | 4608 | hardDeprecated(name, version, replacement); |
| @@ -2777,9 +4697,11 @@ | ||
| 2777 | 4697 | var total = this.compareVersion(version, elementorWebCliConfig.version); |
| 2778 | 4698 | return total < 0 || total >= 8; |
| 2779 | 4699 | } |
| 2780 | 4700 | }]); |
| 4701 | + return Deprecation; | |
| 2781 | 4702 | }(); |
| 4703 | +exports["default"] = Deprecation; | |
| 2782 | 4704 | |
| 2783 | 4705 | /***/ }), |
| 2784 | 4706 | |
| 2785 | 4707 | /***/ "../modules/web-cli/assets/js/utils/force-method-implementation.js": |
| @@ -2797,28 +4719,31 @@ | ||
| 2797 | 4719 | })); |
| 2798 | 4720 | exports["default"] = exports.ForceMethodImplementation = void 0; |
| 2799 | 4721 | var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); |
| 2800 | 4722 | var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); |
| 4723 | +var _assertThisInitialized2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/assertThisInitialized */ "../node_modules/@babel/runtime/helpers/assertThisInitialized.js")); | |
| 4724 | +var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 2801 | 4725 | var _possibleConstructorReturn2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/possibleConstructorReturn */ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js")); |
| 2802 | 4726 | var _getPrototypeOf2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/getPrototypeOf */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js")); |
| 2803 | -var _inherits2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/inherits */ "../node_modules/@babel/runtime/helpers/inherits.js")); | |
| 2804 | 4727 | var _wrapNativeSuper2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/wrapNativeSuper */ "../node_modules/@babel/runtime/helpers/wrapNativeSuper.js")); |
| 2805 | -function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); } | |
| 2806 | -function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } | |
| 4728 | +function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; } | |
| 4729 | +function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } } | |
| 2807 | 4730 | // TODO: Copied from `assets/dev/js/modules/imports/force-method-implementation.js`; |
| 2808 | -var ForceMethodImplementation = exports.ForceMethodImplementation = /*#__PURE__*/function (_Error) { | |
| 4731 | +var ForceMethodImplementation = /*#__PURE__*/function (_Error) { | |
| 4732 | + (0, _inherits2.default)(ForceMethodImplementation, _Error); | |
| 4733 | + var _super = _createSuper(ForceMethodImplementation); | |
| 2809 | 4734 | function ForceMethodImplementation() { |
| 2810 | 4735 | var _this; |
| 2811 | 4736 | var info = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; |
| 2812 | 4737 | (0, _classCallCheck2.default)(this, ForceMethodImplementation); |
| 2813 | - _this = _callSuper(this, ForceMethodImplementation, ["".concat(info.isStatic ? 'static ' : '').concat(info.fullName, "() should be implemented, please provide '").concat(info.functionName || info.fullName, "' functionality.")]); | |
| 2814 | - Error.captureStackTrace(_this, ForceMethodImplementation); | |
| 4738 | + _this = _super.call(this, "".concat(info.isStatic ? 'static ' : '').concat(info.fullName, "() should be implemented, please provide '").concat(info.functionName || info.fullName, "' functionality.")); | |
| 4739 | + Error.captureStackTrace((0, _assertThisInitialized2.default)(_this), ForceMethodImplementation); | |
| 2815 | 4740 | return _this; |
| 2816 | 4741 | } |
| 2817 | - (0, _inherits2.default)(ForceMethodImplementation, _Error); | |
| 2818 | 4742 | return (0, _createClass2.default)(ForceMethodImplementation); |
| 2819 | -}(/*#__PURE__*/(0, _wrapNativeSuper2.default)(Error)); | |
| 2820 | -var _default = exports["default"] = function _default() { | |
| 4743 | +}( /*#__PURE__*/(0, _wrapNativeSuper2.default)(Error)); | |
| 4744 | +exports.ForceMethodImplementation = ForceMethodImplementation; | |
| 4745 | +var _default = function _default() { | |
| 2821 | 4746 | var stack = Error().stack, |
| 2822 | 4747 | caller = stack.split('\n')[2].trim(), |
| 2823 | 4748 | callerName = caller.startsWith('at new') ? 'constructor' : caller.split(' ')[1], |
| 2824 | 4749 | info = {}; |
| @@ -2832,11 +4757,1097 @@ | ||
| 2832 | 4757 | info.isStatic = true; |
| 2833 | 4758 | } |
| 2834 | 4759 | throw new ForceMethodImplementation(info); |
| 2835 | 4760 | }; |
| 4761 | +exports["default"] = _default; | |
| 2836 | 4762 | |
| 2837 | 4763 | /***/ }), |
| 2838 | 4764 | |
| 4765 | +/***/ "../node_modules/redux-thunk/es/index.js": | |
| 4766 | +/*!***********************************************!*\ | |
| 4767 | + !*** ../node_modules/redux-thunk/es/index.js ***! | |
| 4768 | + \***********************************************/ | |
| 4769 | +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { | |
| 4770 | + | |
| 4771 | +"use strict"; | |
| 4772 | +__webpack_require__.r(__webpack_exports__); | |
| 4773 | +/* harmony export */ __webpack_require__.d(__webpack_exports__, { | |
| 4774 | +/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__) | |
| 4775 | +/* harmony export */ }); | |
| 4776 | +/** A function that accepts a potential "extra argument" value to be injected later, | |
| 4777 | + * and returns an instance of the thunk middleware that uses that value | |
| 4778 | + */ | |
| 4779 | +function createThunkMiddleware(extraArgument) { | |
| 4780 | + // Standard Redux middleware definition pattern: | |
| 4781 | + // See: https://redux.js.org/tutorials/fundamentals/part-4-store#writing-custom-middleware | |
| 4782 | + var middleware = function middleware(_ref) { | |
| 4783 | + var dispatch = _ref.dispatch, | |
| 4784 | + getState = _ref.getState; | |
| 4785 | + return function (next) { | |
| 4786 | + return function (action) { | |
| 4787 | + // The thunk middleware looks for any functions that were passed to `store.dispatch`. | |
| 4788 | + // If this "action" is really a function, call it and return the result. | |
| 4789 | + if (typeof action === 'function') { | |
| 4790 | + // Inject the store's `dispatch` and `getState` methods, as well as any "extra arg" | |
| 4791 | + return action(dispatch, getState, extraArgument); | |
| 4792 | + } // Otherwise, pass the action down the middleware chain as usual | |
| 4793 | + | |
| 4794 | + | |
| 4795 | + return next(action); | |
| 4796 | + }; | |
| 4797 | + }; | |
| 4798 | + }; | |
| 4799 | + | |
| 4800 | + return middleware; | |
| 4801 | +} | |
| 4802 | + | |
| 4803 | +var thunk = createThunkMiddleware(); // Attach the factory function so users can create a customized version | |
| 4804 | +// with whatever "extra arg" they want to inject into their thunks | |
| 4805 | + | |
| 4806 | +thunk.withExtraArgument = createThunkMiddleware; | |
| 4807 | +/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (thunk); | |
| 4808 | + | |
| 4809 | +/***/ }), | |
| 4810 | + | |
| 4811 | +/***/ "../node_modules/redux/es/redux.js": | |
| 4812 | +/*!*****************************************!*\ | |
| 4813 | + !*** ../node_modules/redux/es/redux.js ***! | |
| 4814 | + \*****************************************/ | |
| 4815 | +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { | |
| 4816 | + | |
| 4817 | +"use strict"; | |
| 4818 | +__webpack_require__.r(__webpack_exports__); | |
| 4819 | +/* harmony export */ __webpack_require__.d(__webpack_exports__, { | |
| 4820 | +/* harmony export */ __DO_NOT_USE__ActionTypes: () => (/* binding */ ActionTypes), | |
| 4821 | +/* harmony export */ applyMiddleware: () => (/* binding */ applyMiddleware), | |
| 4822 | +/* harmony export */ bindActionCreators: () => (/* binding */ bindActionCreators), | |
| 4823 | +/* harmony export */ combineReducers: () => (/* binding */ combineReducers), | |
| 4824 | +/* harmony export */ compose: () => (/* binding */ compose), | |
| 4825 | +/* harmony export */ createStore: () => (/* binding */ createStore), | |
| 4826 | +/* harmony export */ legacy_createStore: () => (/* binding */ legacy_createStore) | |
| 4827 | +/* harmony export */ }); | |
| 4828 | +/* harmony import */ var _babel_runtime_helpers_esm_objectSpread2__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @babel/runtime/helpers/esm/objectSpread2 */ "../node_modules/@babel/runtime/helpers/esm/objectSpread2.js"); | |
| 4829 | + | |
| 4830 | + | |
| 4831 | +/** | |
| 4832 | + * Adapted from React: https://github.com/facebook/react/blob/master/packages/shared/formatProdErrorMessage.js | |
| 4833 | + * | |
| 4834 | + * Do not require this module directly! Use normal throw error calls. These messages will be replaced with error codes | |
| 4835 | + * during build. | |
| 4836 | + * @param {number} code | |
| 4837 | + */ | |
| 4838 | +function formatProdErrorMessage(code) { | |
| 4839 | + return "Minified Redux error #" + code + "; visit https://redux.js.org/Errors?code=" + code + " for the full message or " + 'use the non-minified dev environment for full errors. '; | |
| 4840 | +} | |
| 4841 | + | |
| 4842 | +// Inlined version of the `symbol-observable` polyfill | |
| 4843 | +var $$observable = (function () { | |
| 4844 | + return typeof Symbol === 'function' && Symbol.observable || '@@observable'; | |
| 4845 | +})(); | |
| 4846 | + | |
| 4847 | +/** | |
| 4848 | + * These are private action types reserved by Redux. | |
| 4849 | + * For any unknown actions, you must return the current state. | |
| 4850 | + * If the current state is undefined, you must return the initial state. | |
| 4851 | + * Do not reference these action types directly in your code. | |
| 4852 | + */ | |
| 4853 | +var randomString = function randomString() { | |
| 4854 | + return Math.random().toString(36).substring(7).split('').join('.'); | |
| 4855 | +}; | |
| 4856 | + | |
| 4857 | +var ActionTypes = { | |
| 4858 | + INIT: "@@redux/INIT" + randomString(), | |
| 4859 | + REPLACE: "@@redux/REPLACE" + randomString(), | |
| 4860 | + PROBE_UNKNOWN_ACTION: function PROBE_UNKNOWN_ACTION() { | |
| 4861 | + return "@@redux/PROBE_UNKNOWN_ACTION" + randomString(); | |
| 4862 | + } | |
| 4863 | +}; | |
| 4864 | + | |
| 4865 | +/** | |
| 4866 | + * @param {any} obj The object to inspect. | |
| 4867 | + * @returns {boolean} True if the argument appears to be a plain object. | |
| 4868 | + */ | |
| 4869 | +function isPlainObject(obj) { | |
| 4870 | + if (typeof obj !== 'object' || obj === null) return false; | |
| 4871 | + var proto = obj; | |
| 4872 | + | |
| 4873 | + while (Object.getPrototypeOf(proto) !== null) { | |
| 4874 | + proto = Object.getPrototypeOf(proto); | |
| 4875 | + } | |
| 4876 | + | |
| 4877 | + return Object.getPrototypeOf(obj) === proto; | |
| 4878 | +} | |
| 4879 | + | |
| 4880 | +// Inlined / shortened version of `kindOf` from https://github.com/jonschlinkert/kind-of | |
| 4881 | +function miniKindOf(val) { | |
| 4882 | + if (val === void 0) return 'undefined'; | |
| 4883 | + if (val === null) return 'null'; | |
| 4884 | + var type = typeof val; | |
| 4885 | + | |
| 4886 | + switch (type) { | |
| 4887 | + case 'boolean': | |
| 4888 | + case 'string': | |
| 4889 | + case 'number': | |
| 4890 | + case 'symbol': | |
| 4891 | + case 'function': | |
| 4892 | + { | |
| 4893 | + return type; | |
| 4894 | + } | |
| 4895 | + } | |
| 4896 | + | |
| 4897 | + if (Array.isArray(val)) return 'array'; | |
| 4898 | + if (isDate(val)) return 'date'; | |
| 4899 | + if (isError(val)) return 'error'; | |
| 4900 | + var constructorName = ctorName(val); | |
| 4901 | + | |
| 4902 | + switch (constructorName) { | |
| 4903 | + case 'Symbol': | |
| 4904 | + case 'Promise': | |
| 4905 | + case 'WeakMap': | |
| 4906 | + case 'WeakSet': | |
| 4907 | + case 'Map': | |
| 4908 | + case 'Set': | |
| 4909 | + return constructorName; | |
| 4910 | + } // other | |
| 4911 | + | |
| 4912 | + | |
| 4913 | + return type.slice(8, -1).toLowerCase().replace(/\s/g, ''); | |
| 4914 | +} | |
| 4915 | + | |
| 4916 | +function ctorName(val) { | |
| 4917 | + return typeof val.constructor === 'function' ? val.constructor.name : null; | |
| 4918 | +} | |
| 4919 | + | |
| 4920 | +function isError(val) { | |
| 4921 | + return val instanceof Error || typeof val.message === 'string' && val.constructor && typeof val.constructor.stackTraceLimit === 'number'; | |
| 4922 | +} | |
| 4923 | + | |
| 4924 | +function isDate(val) { | |
| 4925 | + if (val instanceof Date) return true; | |
| 4926 | + return typeof val.toDateString === 'function' && typeof val.getDate === 'function' && typeof val.setDate === 'function'; | |
| 4927 | +} | |
| 4928 | + | |
| 4929 | +function kindOf(val) { | |
| 4930 | + var typeOfVal = typeof val; | |
| 4931 | + | |
| 4932 | + if (true) { | |
| 4933 | + typeOfVal = miniKindOf(val); | |
| 4934 | + } | |
| 4935 | + | |
| 4936 | + return typeOfVal; | |
| 4937 | +} | |
| 4938 | + | |
| 4939 | +/** | |
| 4940 | + * @deprecated | |
| 4941 | + * | |
| 4942 | + * **We recommend using the `configureStore` method | |
| 4943 | + * of the `@reduxjs/toolkit` package**, which replaces `createStore`. | |
| 4944 | + * | |
| 4945 | + * Redux Toolkit is our recommended approach for writing Redux logic today, | |
| 4946 | + * including store setup, reducers, data fetching, and more. | |
| 4947 | + * | |
| 4948 | + * **For more details, please read this Redux docs page:** | |
| 4949 | + * **https://redux.js.org/introduction/why-rtk-is-redux-today** | |
| 4950 | + * | |
| 4951 | + * `configureStore` from Redux Toolkit is an improved version of `createStore` that | |
| 4952 | + * simplifies setup and helps avoid common bugs. | |
| 4953 | + * | |
| 4954 | + * You should not be using the `redux` core package by itself today, except for learning purposes. | |
| 4955 | + * The `createStore` method from the core `redux` package will not be removed, but we encourage | |
| 4956 | + * all users to migrate to using Redux Toolkit for all Redux code. | |
| 4957 | + * | |
| 4958 | + * If you want to use `createStore` without this visual deprecation warning, use | |
| 4959 | + * the `legacy_createStore` import instead: | |
| 4960 | + * | |
| 4961 | + * `import { legacy_createStore as createStore} from 'redux'` | |
| 4962 | + * | |
| 4963 | + */ | |
| 4964 | + | |
| 4965 | +function createStore(reducer, preloadedState, enhancer) { | |
| 4966 | + var _ref2; | |
| 4967 | + | |
| 4968 | + if (typeof preloadedState === 'function' && typeof enhancer === 'function' || typeof enhancer === 'function' && typeof arguments[3] === 'function') { | |
| 4969 | + throw new Error( false ? 0 : 'It looks like you are passing several store enhancers to ' + 'createStore(). This is not supported. Instead, compose them ' + 'together to a single function. See https://redux.js.org/tutorials/fundamentals/part-4-store#creating-a-store-with-enhancers for an example.'); | |
| 4970 | + } | |
| 4971 | + | |
| 4972 | + if (typeof preloadedState === 'function' && typeof enhancer === 'undefined') { | |
| 4973 | + enhancer = preloadedState; | |
| 4974 | + preloadedState = undefined; | |
| 4975 | + } | |
| 4976 | + | |
| 4977 | + if (typeof enhancer !== 'undefined') { | |
| 4978 | + if (typeof enhancer !== 'function') { | |
| 4979 | + throw new Error( false ? 0 : "Expected the enhancer to be a function. Instead, received: '" + kindOf(enhancer) + "'"); | |
| 4980 | + } | |
| 4981 | + | |
| 4982 | + return enhancer(createStore)(reducer, preloadedState); | |
| 4983 | + } | |
| 4984 | + | |
| 4985 | + if (typeof reducer !== 'function') { | |
| 4986 | + throw new Error( false ? 0 : "Expected the root reducer to be a function. Instead, received: '" + kindOf(reducer) + "'"); | |
| 4987 | + } | |
| 4988 | + | |
| 4989 | + var currentReducer = reducer; | |
| 4990 | + var currentState = preloadedState; | |
| 4991 | + var currentListeners = []; | |
| 4992 | + var nextListeners = currentListeners; | |
| 4993 | + var isDispatching = false; | |
| 4994 | + /** | |
| 4995 | + * This makes a shallow copy of currentListeners so we can use | |
| 4996 | + * nextListeners as a temporary list while dispatching. | |
| 4997 | + * | |
| 4998 | + * This prevents any bugs around consumers calling | |
| 4999 | + * subscribe/unsubscribe in the middle of a dispatch. | |
| 5000 | + */ | |
| 5001 | + | |
| 5002 | + function ensureCanMutateNextListeners() { | |
| 5003 | + if (nextListeners === currentListeners) { | |
| 5004 | + nextListeners = currentListeners.slice(); | |
| 5005 | + } | |
| 5006 | + } | |
| 5007 | + /** | |
| 5008 | + * Reads the state tree managed by the store. | |
| 5009 | + * | |
| 5010 | + * @returns {any} The current state tree of your application. | |
| 5011 | + */ | |
| 5012 | + | |
| 5013 | + | |
| 5014 | + function getState() { | |
| 5015 | + if (isDispatching) { | |
| 5016 | + throw new Error( false ? 0 : 'You may not call store.getState() while the reducer is executing. ' + 'The reducer has already received the state as an argument. ' + 'Pass it down from the top reducer instead of reading it from the store.'); | |
| 5017 | + } | |
| 5018 | + | |
| 5019 | + return currentState; | |
| 5020 | + } | |
| 5021 | + /** | |
| 5022 | + * Adds a change listener. It will be called any time an action is dispatched, | |
| 5023 | + * and some part of the state tree may potentially have changed. You may then | |
| 5024 | + * call `getState()` to read the current state tree inside the callback. | |
| 5025 | + * | |
| 5026 | + * You may call `dispatch()` from a change listener, with the following | |
| 5027 | + * caveats: | |
| 5028 | + * | |
| 5029 | + * 1. The subscriptions are snapshotted just before every `dispatch()` call. | |
| 5030 | + * If you subscribe or unsubscribe while the listeners are being invoked, this | |
| 5031 | + * will not have any effect on the `dispatch()` that is currently in progress. | |
| 5032 | + * However, the next `dispatch()` call, whether nested or not, will use a more | |
| 5033 | + * recent snapshot of the subscription list. | |
| 5034 | + * | |
| 5035 | + * 2. The listener should not expect to see all state changes, as the state | |
| 5036 | + * might have been updated multiple times during a nested `dispatch()` before | |
| 5037 | + * the listener is called. It is, however, guaranteed that all subscribers | |
| 5038 | + * registered before the `dispatch()` started will be called with the latest | |
| 5039 | + * state by the time it exits. | |
| 5040 | + * | |
| 5041 | + * @param {Function} listener A callback to be invoked on every dispatch. | |
| 5042 | + * @returns {Function} A function to remove this change listener. | |
| 5043 | + */ | |
| 5044 | + | |
| 5045 | + | |
| 5046 | + function subscribe(listener) { | |
| 5047 | + if (typeof listener !== 'function') { | |
| 5048 | + throw new Error( false ? 0 : "Expected the listener to be a function. Instead, received: '" + kindOf(listener) + "'"); | |
| 5049 | + } | |
| 5050 | + | |
| 5051 | + if (isDispatching) { | |
| 5052 | + throw new Error( false ? 0 : 'You may not call store.subscribe() while the reducer is executing. ' + 'If you would like to be notified after the store has been updated, subscribe from a ' + 'component and invoke store.getState() in the callback to access the latest state. ' + 'See https://redux.js.org/api/store#subscribelistener for more details.'); | |
| 5053 | + } | |
| 5054 | + | |
| 5055 | + var isSubscribed = true; | |
| 5056 | + ensureCanMutateNextListeners(); | |
| 5057 | + nextListeners.push(listener); | |
| 5058 | + return function unsubscribe() { | |
| 5059 | + if (!isSubscribed) { | |
| 5060 | + return; | |
| 5061 | + } | |
| 5062 | + | |
| 5063 | + if (isDispatching) { | |
| 5064 | + throw new Error( false ? 0 : 'You may not unsubscribe from a store listener while the reducer is executing. ' + 'See https://redux.js.org/api/store#subscribelistener for more details.'); | |
| 5065 | + } | |
| 5066 | + | |
| 5067 | + isSubscribed = false; | |
| 5068 | + ensureCanMutateNextListeners(); | |
| 5069 | + var index = nextListeners.indexOf(listener); | |
| 5070 | + nextListeners.splice(index, 1); | |
| 5071 | + currentListeners = null; | |
| 5072 | + }; | |
| 5073 | + } | |
| 5074 | + /** | |
| 5075 | + * Dispatches an action. It is the only way to trigger a state change. | |
| 5076 | + * | |
| 5077 | + * The `reducer` function, used to create the store, will be called with the | |
| 5078 | + * current state tree and the given `action`. Its return value will | |
| 5079 | + * be considered the **next** state of the tree, and the change listeners | |
| 5080 | + * will be notified. | |
| 5081 | + * | |
| 5082 | + * The base implementation only supports plain object actions. If you want to | |
| 5083 | + * dispatch a Promise, an Observable, a thunk, or something else, you need to | |
| 5084 | + * wrap your store creating function into the corresponding middleware. For | |
| 5085 | + * example, see the documentation for the `redux-thunk` package. Even the | |
| 5086 | + * middleware will eventually dispatch plain object actions using this method. | |
| 5087 | + * | |
| 5088 | + * @param {Object} action A plain object representing “what changed”. It is | |
| 5089 | + * a good idea to keep actions serializable so you can record and replay user | |
| 5090 | + * sessions, or use the time travelling `redux-devtools`. An action must have | |
| 5091 | + * a `type` property which may not be `undefined`. It is a good idea to use | |
| 5092 | + * string constants for action types. | |
| 5093 | + * | |
| 5094 | + * @returns {Object} For convenience, the same action object you dispatched. | |
| 5095 | + * | |
| 5096 | + * Note that, if you use a custom middleware, it may wrap `dispatch()` to | |
| 5097 | + * return something else (for example, a Promise you can await). | |
| 5098 | + */ | |
| 5099 | + | |
| 5100 | + | |
| 5101 | + function dispatch(action) { | |
| 5102 | + if (!isPlainObject(action)) { | |
| 5103 | + throw new Error( false ? 0 : "Actions must be plain objects. Instead, the actual type was: '" + kindOf(action) + "'. You may need to add middleware to your store setup to handle dispatching other values, such as 'redux-thunk' to handle dispatching functions. See https://redux.js.org/tutorials/fundamentals/part-4-store#middleware and https://redux.js.org/tutorials/fundamentals/part-6-async-logic#using-the-redux-thunk-middleware for examples."); | |
| 5104 | + } | |
| 5105 | + | |
| 5106 | + if (typeof action.type === 'undefined') { | |
| 5107 | + throw new Error( false ? 0 : 'Actions may not have an undefined "type" property. You may have misspelled an action type string constant.'); | |
| 5108 | + } | |
| 5109 | + | |
| 5110 | + if (isDispatching) { | |
| 5111 | + throw new Error( false ? 0 : 'Reducers may not dispatch actions.'); | |
| 5112 | + } | |
| 5113 | + | |
| 5114 | + try { | |
| 5115 | + isDispatching = true; | |
| 5116 | + currentState = currentReducer(currentState, action); | |
| 5117 | + } finally { | |
| 5118 | + isDispatching = false; | |
| 5119 | + } | |
| 5120 | + | |
| 5121 | + var listeners = currentListeners = nextListeners; | |
| 5122 | + | |
| 5123 | + for (var i = 0; i < listeners.length; i++) { | |
| 5124 | + var listener = listeners[i]; | |
| 5125 | + listener(); | |
| 5126 | + } | |
| 5127 | + | |
| 5128 | + return action; | |
| 5129 | + } | |
| 5130 | + /** | |
| 5131 | + * Replaces the reducer currently used by the store to calculate the state. | |
| 5132 | + * | |
| 5133 | + * You might need this if your app implements code splitting and you want to | |
| 5134 | + * load some of the reducers dynamically. You might also need this if you | |
| 5135 | + * implement a hot reloading mechanism for Redux. | |
| 5136 | + * | |
| 5137 | + * @param {Function} nextReducer The reducer for the store to use instead. | |
| 5138 | + * @returns {void} | |
| 5139 | + */ | |
| 5140 | + | |
| 5141 | + | |
| 5142 | + function replaceReducer(nextReducer) { | |
| 5143 | + if (typeof nextReducer !== 'function') { | |
| 5144 | + throw new Error( false ? 0 : "Expected the nextReducer to be a function. Instead, received: '" + kindOf(nextReducer)); | |
| 5145 | + } | |
| 5146 | + | |
| 5147 | + currentReducer = nextReducer; // This action has a similiar effect to ActionTypes.INIT. | |
| 5148 | + // Any reducers that existed in both the new and old rootReducer | |
| 5149 | + // will receive the previous state. This effectively populates | |
| 5150 | + // the new state tree with any relevant data from the old one. | |
| 5151 | + | |
| 5152 | + dispatch({ | |
| 5153 | + type: ActionTypes.REPLACE | |
| 5154 | + }); | |
| 5155 | + } | |
| 5156 | + /** | |
| 5157 | + * Interoperability point for observable/reactive libraries. | |
| 5158 | + * @returns {observable} A minimal observable of state changes. | |
| 5159 | + * For more information, see the observable proposal: | |
| 5160 | + * https://github.com/tc39/proposal-observable | |
| 5161 | + */ | |
| 5162 | + | |
| 5163 | + | |
| 5164 | + function observable() { | |
| 5165 | + var _ref; | |
| 5166 | + | |
| 5167 | + var outerSubscribe = subscribe; | |
| 5168 | + return _ref = { | |
| 5169 | + /** | |
| 5170 | + * The minimal observable subscription method. | |
| 5171 | + * @param {Object} observer Any object that can be used as an observer. | |
| 5172 | + * The observer object should have a `next` method. | |
| 5173 | + * @returns {subscription} An object with an `unsubscribe` method that can | |
| 5174 | + * be used to unsubscribe the observable from the store, and prevent further | |
| 5175 | + * emission of values from the observable. | |
| 5176 | + */ | |
| 5177 | + subscribe: function subscribe(observer) { | |
| 5178 | + if (typeof observer !== 'object' || observer === null) { | |
| 5179 | + throw new Error( false ? 0 : "Expected the observer to be an object. Instead, received: '" + kindOf(observer) + "'"); | |
| 5180 | + } | |
| 5181 | + | |
| 5182 | + function observeState() { | |
| 5183 | + if (observer.next) { | |
| 5184 | + observer.next(getState()); | |
| 5185 | + } | |
| 5186 | + } | |
| 5187 | + | |
| 5188 | + observeState(); | |
| 5189 | + var unsubscribe = outerSubscribe(observeState); | |
| 5190 | + return { | |
| 5191 | + unsubscribe: unsubscribe | |
| 5192 | + }; | |
| 5193 | + } | |
| 5194 | + }, _ref[$$observable] = function () { | |
| 5195 | + return this; | |
| 5196 | + }, _ref; | |
| 5197 | + } // When a store is created, an "INIT" action is dispatched so that every | |
| 5198 | + // reducer returns their initial state. This effectively populates | |
| 5199 | + // the initial state tree. | |
| 5200 | + | |
| 5201 | + | |
| 5202 | + dispatch({ | |
| 5203 | + type: ActionTypes.INIT | |
| 5204 | + }); | |
| 5205 | + return _ref2 = { | |
| 5206 | + dispatch: dispatch, | |
| 5207 | + subscribe: subscribe, | |
| 5208 | + getState: getState, | |
| 5209 | + replaceReducer: replaceReducer | |
| 5210 | + }, _ref2[$$observable] = observable, _ref2; | |
| 5211 | +} | |
| 5212 | +/** | |
| 5213 | + * Creates a Redux store that holds the state tree. | |
| 5214 | + * | |
| 5215 | + * **We recommend using `configureStore` from the | |
| 5216 | + * `@reduxjs/toolkit` package**, which replaces `createStore`: | |
| 5217 | + * **https://redux.js.org/introduction/why-rtk-is-redux-today** | |
| 5218 | + * | |
| 5219 | + * The only way to change the data in the store is to call `dispatch()` on it. | |
| 5220 | + * | |
| 5221 | + * There should only be a single store in your app. To specify how different | |
| 5222 | + * parts of the state tree respond to actions, you may combine several reducers | |
| 5223 | + * into a single reducer function by using `combineReducers`. | |
| 5224 | + * | |
| 5225 | + * @param {Function} reducer A function that returns the next state tree, given | |
| 5226 | + * the current state tree and the action to handle. | |
| 5227 | + * | |
| 5228 | + * @param {any} [preloadedState] The initial state. You may optionally specify it | |
| 5229 | + * to hydrate the state from the server in universal apps, or to restore a | |
| 5230 | + * previously serialized user session. | |
| 5231 | + * If you use `combineReducers` to produce the root reducer function, this must be | |
| 5232 | + * an object with the same shape as `combineReducers` keys. | |
| 5233 | + * | |
| 5234 | + * @param {Function} [enhancer] The store enhancer. You may optionally specify it | |
| 5235 | + * to enhance the store with third-party capabilities such as middleware, | |
| 5236 | + * time travel, persistence, etc. The only store enhancer that ships with Redux | |
| 5237 | + * is `applyMiddleware()`. | |
| 5238 | + * | |
| 5239 | + * @returns {Store} A Redux store that lets you read the state, dispatch actions | |
| 5240 | + * and subscribe to changes. | |
| 5241 | + */ | |
| 5242 | + | |
| 5243 | +var legacy_createStore = createStore; | |
| 5244 | + | |
| 5245 | +/** | |
| 5246 | + * Prints a warning in the console if it exists. | |
| 5247 | + * | |
| 5248 | + * @param {String} message The warning message. | |
| 5249 | + * @returns {void} | |
| 5250 | + */ | |
| 5251 | +function warning(message) { | |
| 5252 | + /* eslint-disable no-console */ | |
| 5253 | + if (typeof console !== 'undefined' && typeof console.error === 'function') { | |
| 5254 | + console.error(message); | |
| 5255 | + } | |
| 5256 | + /* eslint-enable no-console */ | |
| 5257 | + | |
| 5258 | + | |
| 5259 | + try { | |
| 5260 | + // This error was thrown as a convenience so that if you enable | |
| 5261 | + // "break on all exceptions" in your console, | |
| 5262 | + // it would pause the execution at this line. | |
| 5263 | + throw new Error(message); | |
| 5264 | + } catch (e) {} // eslint-disable-line no-empty | |
| 5265 | + | |
| 5266 | +} | |
| 5267 | + | |
| 5268 | +function getUnexpectedStateShapeWarningMessage(inputState, reducers, action, unexpectedKeyCache) { | |
| 5269 | + var reducerKeys = Object.keys(reducers); | |
| 5270 | + var argumentName = action && action.type === ActionTypes.INIT ? 'preloadedState argument passed to createStore' : 'previous state received by the reducer'; | |
| 5271 | + | |
| 5272 | + if (reducerKeys.length === 0) { | |
| 5273 | + return 'Store does not have a valid reducer. Make sure the argument passed ' + 'to combineReducers is an object whose values are reducers.'; | |
| 5274 | + } | |
| 5275 | + | |
| 5276 | + if (!isPlainObject(inputState)) { | |
| 5277 | + return "The " + argumentName + " has unexpected type of \"" + kindOf(inputState) + "\". Expected argument to be an object with the following " + ("keys: \"" + reducerKeys.join('", "') + "\""); | |
| 5278 | + } | |
| 5279 | + | |
| 5280 | + var unexpectedKeys = Object.keys(inputState).filter(function (key) { | |
| 5281 | + return !reducers.hasOwnProperty(key) && !unexpectedKeyCache[key]; | |
| 5282 | + }); | |
| 5283 | + unexpectedKeys.forEach(function (key) { | |
| 5284 | + unexpectedKeyCache[key] = true; | |
| 5285 | + }); | |
| 5286 | + if (action && action.type === ActionTypes.REPLACE) return; | |
| 5287 | + | |
| 5288 | + if (unexpectedKeys.length > 0) { | |
| 5289 | + return "Unexpected " + (unexpectedKeys.length > 1 ? 'keys' : 'key') + " " + ("\"" + unexpectedKeys.join('", "') + "\" found in " + argumentName + ". ") + "Expected to find one of the known reducer keys instead: " + ("\"" + reducerKeys.join('", "') + "\". Unexpected keys will be ignored."); | |
| 5290 | + } | |
| 5291 | +} | |
| 5292 | + | |
| 5293 | +function assertReducerShape(reducers) { | |
| 5294 | + Object.keys(reducers).forEach(function (key) { | |
| 5295 | + var reducer = reducers[key]; | |
| 5296 | + var initialState = reducer(undefined, { | |
| 5297 | + type: ActionTypes.INIT | |
| 5298 | + }); | |
| 5299 | + | |
| 5300 | + if (typeof initialState === 'undefined') { | |
| 5301 | + throw new Error( false ? 0 : "The slice reducer for key \"" + key + "\" returned undefined during initialization. " + "If the state passed to the reducer is undefined, you must " + "explicitly return the initial state. The initial state may " + "not be undefined. If you don't want to set a value for this reducer, " + "you can use null instead of undefined."); | |
| 5302 | + } | |
| 5303 | + | |
| 5304 | + if (typeof reducer(undefined, { | |
| 5305 | + type: ActionTypes.PROBE_UNKNOWN_ACTION() | |
| 5306 | + }) === 'undefined') { | |
| 5307 | + throw new Error( false ? 0 : "The slice reducer for key \"" + key + "\" returned undefined when probed with a random type. " + ("Don't try to handle '" + ActionTypes.INIT + "' or other actions in \"redux/*\" ") + "namespace. They are considered private. Instead, you must return the " + "current state for any unknown actions, unless it is undefined, " + "in which case you must return the initial state, regardless of the " + "action type. The initial state may not be undefined, but can be null."); | |
| 5308 | + } | |
| 5309 | + }); | |
| 5310 | +} | |
| 5311 | +/** | |
| 5312 | + * Turns an object whose values are different reducer functions, into a single | |
| 5313 | + * reducer function. It will call every child reducer, and gather their results | |
| 5314 | + * into a single state object, whose keys correspond to the keys of the passed | |
| 5315 | + * reducer functions. | |
| 5316 | + * | |
| 5317 | + * @param {Object} reducers An object whose values correspond to different | |
| 5318 | + * reducer functions that need to be combined into one. One handy way to obtain | |
| 5319 | + * it is to use ES6 `import * as reducers` syntax. The reducers may never return | |
| 5320 | + * undefined for any action. Instead, they should return their initial state | |
| 5321 | + * if the state passed to them was undefined, and the current state for any | |
| 5322 | + * unrecognized action. | |
| 5323 | + * | |
| 5324 | + * @returns {Function} A reducer function that invokes every reducer inside the | |
| 5325 | + * passed object, and builds a state object with the same shape. | |
| 5326 | + */ | |
| 5327 | + | |
| 5328 | + | |
| 5329 | +function combineReducers(reducers) { | |
| 5330 | + var reducerKeys = Object.keys(reducers); | |
| 5331 | + var finalReducers = {}; | |
| 5332 | + | |
| 5333 | + for (var i = 0; i < reducerKeys.length; i++) { | |
| 5334 | + var key = reducerKeys[i]; | |
| 5335 | + | |
| 5336 | + if (true) { | |
| 5337 | + if (typeof reducers[key] === 'undefined') { | |
| 5338 | + warning("No reducer provided for key \"" + key + "\""); | |
| 5339 | + } | |
| 5340 | + } | |
| 5341 | + | |
| 5342 | + if (typeof reducers[key] === 'function') { | |
| 5343 | + finalReducers[key] = reducers[key]; | |
| 5344 | + } | |
| 5345 | + } | |
| 5346 | + | |
| 5347 | + var finalReducerKeys = Object.keys(finalReducers); // This is used to make sure we don't warn about the same | |
| 5348 | + // keys multiple times. | |
| 5349 | + | |
| 5350 | + var unexpectedKeyCache; | |
| 5351 | + | |
| 5352 | + if (true) { | |
| 5353 | + unexpectedKeyCache = {}; | |
| 5354 | + } | |
| 5355 | + | |
| 5356 | + var shapeAssertionError; | |
| 5357 | + | |
| 5358 | + try { | |
| 5359 | + assertReducerShape(finalReducers); | |
| 5360 | + } catch (e) { | |
| 5361 | + shapeAssertionError = e; | |
| 5362 | + } | |
| 5363 | + | |
| 5364 | + return function combination(state, action) { | |
| 5365 | + if (state === void 0) { | |
| 5366 | + state = {}; | |
| 5367 | + } | |
| 5368 | + | |
| 5369 | + if (shapeAssertionError) { | |
| 5370 | + throw shapeAssertionError; | |
| 5371 | + } | |
| 5372 | + | |
| 5373 | + if (true) { | |
| 5374 | + var warningMessage = getUnexpectedStateShapeWarningMessage(state, finalReducers, action, unexpectedKeyCache); | |
| 5375 | + | |
| 5376 | + if (warningMessage) { | |
| 5377 | + warning(warningMessage); | |
| 5378 | + } | |
| 5379 | + } | |
| 5380 | + | |
| 5381 | + var hasChanged = false; | |
| 5382 | + var nextState = {}; | |
| 5383 | + | |
| 5384 | + for (var _i = 0; _i < finalReducerKeys.length; _i++) { | |
| 5385 | + var _key = finalReducerKeys[_i]; | |
| 5386 | + var reducer = finalReducers[_key]; | |
| 5387 | + var previousStateForKey = state[_key]; | |
| 5388 | + var nextStateForKey = reducer(previousStateForKey, action); | |
| 5389 | + | |
| 5390 | + if (typeof nextStateForKey === 'undefined') { | |
| 5391 | + var actionType = action && action.type; | |
| 5392 | + throw new Error( false ? 0 : "When called with an action of type " + (actionType ? "\"" + String(actionType) + "\"" : '(unknown type)') + ", the slice reducer for key \"" + _key + "\" returned undefined. " + "To ignore an action, you must explicitly return the previous state. " + "If you want this reducer to hold no value, you can return null instead of undefined."); | |
| 5393 | + } | |
| 5394 | + | |
| 5395 | + nextState[_key] = nextStateForKey; | |
| 5396 | + hasChanged = hasChanged || nextStateForKey !== previousStateForKey; | |
| 5397 | + } | |
| 5398 | + | |
| 5399 | + hasChanged = hasChanged || finalReducerKeys.length !== Object.keys(state).length; | |
| 5400 | + return hasChanged ? nextState : state; | |
| 5401 | + }; | |
| 5402 | +} | |
| 5403 | + | |
| 5404 | +function bindActionCreator(actionCreator, dispatch) { | |
| 5405 | + return function () { | |
| 5406 | + return dispatch(actionCreator.apply(this, arguments)); | |
| 5407 | + }; | |
| 5408 | +} | |
| 5409 | +/** | |
| 5410 | + * Turns an object whose values are action creators, into an object with the | |
| 5411 | + * same keys, but with every function wrapped into a `dispatch` call so they | |
| 5412 | + * may be invoked directly. This is just a convenience method, as you can call | |
| 5413 | + * `store.dispatch(MyActionCreators.doSomething())` yourself just fine. | |
| 5414 | + * | |
| 5415 | + * For convenience, you can also pass an action creator as the first argument, | |
| 5416 | + * and get a dispatch wrapped function in return. | |
| 5417 | + * | |
| 5418 | + * @param {Function|Object} actionCreators An object whose values are action | |
| 5419 | + * creator functions. One handy way to obtain it is to use ES6 `import * as` | |
| 5420 | + * syntax. You may also pass a single function. | |
| 5421 | + * | |
| 5422 | + * @param {Function} dispatch The `dispatch` function available on your Redux | |
| 5423 | + * store. | |
| 5424 | + * | |
| 5425 | + * @returns {Function|Object} The object mimicking the original object, but with | |
| 5426 | + * every action creator wrapped into the `dispatch` call. If you passed a | |
| 5427 | + * function as `actionCreators`, the return value will also be a single | |
| 5428 | + * function. | |
| 5429 | + */ | |
| 5430 | + | |
| 5431 | + | |
| 5432 | +function bindActionCreators(actionCreators, dispatch) { | |
| 5433 | + if (typeof actionCreators === 'function') { | |
| 5434 | + return bindActionCreator(actionCreators, dispatch); | |
| 5435 | + } | |
| 5436 | + | |
| 5437 | + if (typeof actionCreators !== 'object' || actionCreators === null) { | |
| 5438 | + throw new Error( false ? 0 : "bindActionCreators expected an object or a function, but instead received: '" + kindOf(actionCreators) + "'. " + "Did you write \"import ActionCreators from\" instead of \"import * as ActionCreators from\"?"); | |
| 5439 | + } | |
| 5440 | + | |
| 5441 | + var boundActionCreators = {}; | |
| 5442 | + | |
| 5443 | + for (var key in actionCreators) { | |
| 5444 | + var actionCreator = actionCreators[key]; | |
| 5445 | + | |
| 5446 | + if (typeof actionCreator === 'function') { | |
| 5447 | + boundActionCreators[key] = bindActionCreator(actionCreator, dispatch); | |
| 5448 | + } | |
| 5449 | + } | |
| 5450 | + | |
| 5451 | + return boundActionCreators; | |
| 5452 | +} | |
| 5453 | + | |
| 5454 | +/** | |
| 5455 | + * Composes single-argument functions from right to left. The rightmost | |
| 5456 | + * function can take multiple arguments as it provides the signature for | |
| 5457 | + * the resulting composite function. | |
| 5458 | + * | |
| 5459 | + * @param {...Function} funcs The functions to compose. | |
| 5460 | + * @returns {Function} A function obtained by composing the argument functions | |
| 5461 | + * from right to left. For example, compose(f, g, h) is identical to doing | |
| 5462 | + * (...args) => f(g(h(...args))). | |
| 5463 | + */ | |
| 5464 | +function compose() { | |
| 5465 | + for (var _len = arguments.length, funcs = new Array(_len), _key = 0; _key < _len; _key++) { | |
| 5466 | + funcs[_key] = arguments[_key]; | |
| 5467 | + } | |
| 5468 | + | |
| 5469 | + if (funcs.length === 0) { | |
| 5470 | + return function (arg) { | |
| 5471 | + return arg; | |
| 5472 | + }; | |
| 5473 | + } | |
| 5474 | + | |
| 5475 | + if (funcs.length === 1) { | |
| 5476 | + return funcs[0]; | |
| 5477 | + } | |
| 5478 | + | |
| 5479 | + return funcs.reduce(function (a, b) { | |
| 5480 | + return function () { | |
| 5481 | + return a(b.apply(void 0, arguments)); | |
| 5482 | + }; | |
| 5483 | + }); | |
| 5484 | +} | |
| 5485 | + | |
| 5486 | +/** | |
| 5487 | + * Creates a store enhancer that applies middleware to the dispatch method | |
| 5488 | + * of the Redux store. This is handy for a variety of tasks, such as expressing | |
| 5489 | + * asynchronous actions in a concise manner, or logging every action payload. | |
| 5490 | + * | |
| 5491 | + * See `redux-thunk` package as an example of the Redux middleware. | |
| 5492 | + * | |
| 5493 | + * Because middleware is potentially asynchronous, this should be the first | |
| 5494 | + * store enhancer in the composition chain. | |
| 5495 | + * | |
| 5496 | + * Note that each middleware will be given the `dispatch` and `getState` functions | |
| 5497 | + * as named arguments. | |
| 5498 | + * | |
| 5499 | + * @param {...Function} middlewares The middleware chain to be applied. | |
| 5500 | + * @returns {Function} A store enhancer applying the middleware. | |
| 5501 | + */ | |
| 5502 | + | |
| 5503 | +function applyMiddleware() { | |
| 5504 | + for (var _len = arguments.length, middlewares = new Array(_len), _key = 0; _key < _len; _key++) { | |
| 5505 | + middlewares[_key] = arguments[_key]; | |
| 5506 | + } | |
| 5507 | + | |
| 5508 | + return function (createStore) { | |
| 5509 | + return function () { | |
| 5510 | + var store = createStore.apply(void 0, arguments); | |
| 5511 | + | |
| 5512 | + var _dispatch = function dispatch() { | |
| 5513 | + throw new Error( false ? 0 : 'Dispatching while constructing your middleware is not allowed. ' + 'Other middleware would not be applied to this dispatch.'); | |
| 5514 | + }; | |
| 5515 | + | |
| 5516 | + var middlewareAPI = { | |
| 5517 | + getState: store.getState, | |
| 5518 | + dispatch: function dispatch() { | |
| 5519 | + return _dispatch.apply(void 0, arguments); | |
| 5520 | + } | |
| 5521 | + }; | |
| 5522 | + var chain = middlewares.map(function (middleware) { | |
| 5523 | + return middleware(middlewareAPI); | |
| 5524 | + }); | |
| 5525 | + _dispatch = compose.apply(void 0, chain)(store.dispatch); | |
| 5526 | + return (0,_babel_runtime_helpers_esm_objectSpread2__WEBPACK_IMPORTED_MODULE_0__["default"])((0,_babel_runtime_helpers_esm_objectSpread2__WEBPACK_IMPORTED_MODULE_0__["default"])({}, store), {}, { | |
| 5527 | + dispatch: _dispatch | |
| 5528 | + }); | |
| 5529 | + }; | |
| 5530 | + }; | |
| 5531 | +} | |
| 5532 | + | |
| 5533 | + | |
| 5534 | + | |
| 5535 | + | |
| 5536 | +/***/ }), | |
| 5537 | + | |
| 5538 | +/***/ "../node_modules/reselect/es/defaultMemoize.js": | |
| 5539 | +/*!*****************************************************!*\ | |
| 5540 | + !*** ../node_modules/reselect/es/defaultMemoize.js ***! | |
| 5541 | + \*****************************************************/ | |
| 5542 | +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { | |
| 5543 | + | |
| 5544 | +"use strict"; | |
| 5545 | +__webpack_require__.r(__webpack_exports__); | |
| 5546 | +/* harmony export */ __webpack_require__.d(__webpack_exports__, { | |
| 5547 | +/* harmony export */ createCacheKeyComparator: () => (/* binding */ createCacheKeyComparator), | |
| 5548 | +/* harmony export */ defaultEqualityCheck: () => (/* binding */ defaultEqualityCheck), | |
| 5549 | +/* harmony export */ defaultMemoize: () => (/* binding */ defaultMemoize) | |
| 5550 | +/* harmony export */ }); | |
| 5551 | +// Cache implementation based on Erik Rasmussen's `lru-memoize`: | |
| 5552 | +// https://github.com/erikras/lru-memoize | |
| 5553 | +var NOT_FOUND = 'NOT_FOUND'; | |
| 5554 | + | |
| 5555 | +function createSingletonCache(equals) { | |
| 5556 | + var entry; | |
| 5557 | + return { | |
| 5558 | + get: function get(key) { | |
| 5559 | + if (entry && equals(entry.key, key)) { | |
| 5560 | + return entry.value; | |
| 5561 | + } | |
| 5562 | + | |
| 5563 | + return NOT_FOUND; | |
| 5564 | + }, | |
| 5565 | + put: function put(key, value) { | |
| 5566 | + entry = { | |
| 5567 | + key: key, | |
| 5568 | + value: value | |
| 5569 | + }; | |
| 5570 | + }, | |
| 5571 | + getEntries: function getEntries() { | |
| 5572 | + return entry ? [entry] : []; | |
| 5573 | + }, | |
| 5574 | + clear: function clear() { | |
| 5575 | + entry = undefined; | |
| 5576 | + } | |
| 5577 | + }; | |
| 5578 | +} | |
| 5579 | + | |
| 5580 | +function createLruCache(maxSize, equals) { | |
| 5581 | + var entries = []; | |
| 5582 | + | |
| 5583 | + function get(key) { | |
| 5584 | + var cacheIndex = entries.findIndex(function (entry) { | |
| 5585 | + return equals(key, entry.key); | |
| 5586 | + }); // We found a cached entry | |
| 5587 | + | |
| 5588 | + if (cacheIndex > -1) { | |
| 5589 | + var entry = entries[cacheIndex]; // Cached entry not at top of cache, move it to the top | |
| 5590 | + | |
| 5591 | + if (cacheIndex > 0) { | |
| 5592 | + entries.splice(cacheIndex, 1); | |
| 5593 | + entries.unshift(entry); | |
| 5594 | + } | |
| 5595 | + | |
| 5596 | + return entry.value; | |
| 5597 | + } // No entry found in cache, return sentinel | |
| 5598 | + | |
| 5599 | + | |
| 5600 | + return NOT_FOUND; | |
| 5601 | + } | |
| 5602 | + | |
| 5603 | + function put(key, value) { | |
| 5604 | + if (get(key) === NOT_FOUND) { | |
| 5605 | + // TODO Is unshift slow? | |
| 5606 | + entries.unshift({ | |
| 5607 | + key: key, | |
| 5608 | + value: value | |
| 5609 | + }); | |
| 5610 | + | |
| 5611 | + if (entries.length > maxSize) { | |
| 5612 | + entries.pop(); | |
| 5613 | + } | |
| 5614 | + } | |
| 5615 | + } | |
| 5616 | + | |
| 5617 | + function getEntries() { | |
| 5618 | + return entries; | |
| 5619 | + } | |
| 5620 | + | |
| 5621 | + function clear() { | |
| 5622 | + entries = []; | |
| 5623 | + } | |
| 5624 | + | |
| 5625 | + return { | |
| 5626 | + get: get, | |
| 5627 | + put: put, | |
| 5628 | + getEntries: getEntries, | |
| 5629 | + clear: clear | |
| 5630 | + }; | |
| 5631 | +} | |
| 5632 | + | |
| 5633 | +var defaultEqualityCheck = function defaultEqualityCheck(a, b) { | |
| 5634 | + return a === b; | |
| 5635 | +}; | |
| 5636 | +function createCacheKeyComparator(equalityCheck) { | |
| 5637 | + return function areArgumentsShallowlyEqual(prev, next) { | |
| 5638 | + if (prev === null || next === null || prev.length !== next.length) { | |
| 5639 | + return false; | |
| 5640 | + } // Do this in a for loop (and not a `forEach` or an `every`) so we can determine equality as fast as possible. | |
| 5641 | + | |
| 5642 | + | |
| 5643 | + var length = prev.length; | |
| 5644 | + | |
| 5645 | + for (var i = 0; i < length; i++) { | |
| 5646 | + if (!equalityCheck(prev[i], next[i])) { | |
| 5647 | + return false; | |
| 5648 | + } | |
| 5649 | + } | |
| 5650 | + | |
| 5651 | + return true; | |
| 5652 | + }; | |
| 5653 | +} | |
| 5654 | +// defaultMemoize now supports a configurable cache size with LRU behavior, | |
| 5655 | +// and optional comparison of the result value with existing values | |
| 5656 | +function defaultMemoize(func, equalityCheckOrOptions) { | |
| 5657 | + var providedOptions = typeof equalityCheckOrOptions === 'object' ? equalityCheckOrOptions : { | |
| 5658 | + equalityCheck: equalityCheckOrOptions | |
| 5659 | + }; | |
| 5660 | + var _providedOptions$equa = providedOptions.equalityCheck, | |
| 5661 | + equalityCheck = _providedOptions$equa === void 0 ? defaultEqualityCheck : _providedOptions$equa, | |
| 5662 | + _providedOptions$maxS = providedOptions.maxSize, | |
| 5663 | + maxSize = _providedOptions$maxS === void 0 ? 1 : _providedOptions$maxS, | |
| 5664 | + resultEqualityCheck = providedOptions.resultEqualityCheck; | |
| 5665 | + var comparator = createCacheKeyComparator(equalityCheck); | |
| 5666 | + var cache = maxSize === 1 ? createSingletonCache(comparator) : createLruCache(maxSize, comparator); // we reference arguments instead of spreading them for performance reasons | |
| 5667 | + | |
| 5668 | + function memoized() { | |
| 5669 | + var value = cache.get(arguments); | |
| 5670 | + | |
| 5671 | + if (value === NOT_FOUND) { | |
| 5672 | + // @ts-ignore | |
| 5673 | + value = func.apply(null, arguments); | |
| 5674 | + | |
| 5675 | + if (resultEqualityCheck) { | |
| 5676 | + var entries = cache.getEntries(); | |
| 5677 | + var matchingEntry = entries.find(function (entry) { | |
| 5678 | + return resultEqualityCheck(entry.value, value); | |
| 5679 | + }); | |
| 5680 | + | |
| 5681 | + if (matchingEntry) { | |
| 5682 | + value = matchingEntry.value; | |
| 5683 | + } | |
| 5684 | + } | |
| 5685 | + | |
| 5686 | + cache.put(arguments, value); | |
| 5687 | + } | |
| 5688 | + | |
| 5689 | + return value; | |
| 5690 | + } | |
| 5691 | + | |
| 5692 | + memoized.clearCache = function () { | |
| 5693 | + return cache.clear(); | |
| 5694 | + }; | |
| 5695 | + | |
| 5696 | + return memoized; | |
| 5697 | +} | |
| 5698 | + | |
| 5699 | +/***/ }), | |
| 5700 | + | |
| 5701 | +/***/ "../node_modules/reselect/es/index.js": | |
| 5702 | +/*!********************************************!*\ | |
| 5703 | + !*** ../node_modules/reselect/es/index.js ***! | |
| 5704 | + \********************************************/ | |
| 5705 | +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { | |
| 5706 | + | |
| 5707 | +"use strict"; | |
| 5708 | +__webpack_require__.r(__webpack_exports__); | |
| 5709 | +/* harmony export */ __webpack_require__.d(__webpack_exports__, { | |
| 5710 | +/* harmony export */ createSelector: () => (/* binding */ createSelector), | |
| 5711 | +/* harmony export */ createSelectorCreator: () => (/* binding */ createSelectorCreator), | |
| 5712 | +/* harmony export */ createStructuredSelector: () => (/* binding */ createStructuredSelector), | |
| 5713 | +/* harmony export */ defaultEqualityCheck: () => (/* reexport safe */ _defaultMemoize__WEBPACK_IMPORTED_MODULE_0__.defaultEqualityCheck), | |
| 5714 | +/* harmony export */ defaultMemoize: () => (/* reexport safe */ _defaultMemoize__WEBPACK_IMPORTED_MODULE_0__.defaultMemoize) | |
| 5715 | +/* harmony export */ }); | |
| 5716 | +/* harmony import */ var _defaultMemoize__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./defaultMemoize */ "../node_modules/reselect/es/defaultMemoize.js"); | |
| 5717 | + | |
| 5718 | + | |
| 5719 | + | |
| 5720 | +function getDependencies(funcs) { | |
| 5721 | + var dependencies = Array.isArray(funcs[0]) ? funcs[0] : funcs; | |
| 5722 | + | |
| 5723 | + if (!dependencies.every(function (dep) { | |
| 5724 | + return typeof dep === 'function'; | |
| 5725 | + })) { | |
| 5726 | + var dependencyTypes = dependencies.map(function (dep) { | |
| 5727 | + return typeof dep === 'function' ? "function " + (dep.name || 'unnamed') + "()" : typeof dep; | |
| 5728 | + }).join(', '); | |
| 5729 | + throw new Error("createSelector expects all input-selectors to be functions, but received the following types: [" + dependencyTypes + "]"); | |
| 5730 | + } | |
| 5731 | + | |
| 5732 | + return dependencies; | |
| 5733 | +} | |
| 5734 | + | |
| 5735 | +function createSelectorCreator(memoize) { | |
| 5736 | + for (var _len = arguments.length, memoizeOptionsFromArgs = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { | |
| 5737 | + memoizeOptionsFromArgs[_key - 1] = arguments[_key]; | |
| 5738 | + } | |
| 5739 | + | |
| 5740 | + var createSelector = function createSelector() { | |
| 5741 | + for (var _len2 = arguments.length, funcs = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) { | |
| 5742 | + funcs[_key2] = arguments[_key2]; | |
| 5743 | + } | |
| 5744 | + | |
| 5745 | + var _recomputations = 0; | |
| 5746 | + | |
| 5747 | + var _lastResult; // Due to the intricacies of rest params, we can't do an optional arg after `...funcs`. | |
| 5748 | + // So, start by declaring the default value here. | |
| 5749 | + // (And yes, the words 'memoize' and 'options' appear too many times in this next sequence.) | |
| 5750 | + | |
| 5751 | + | |
| 5752 | + var directlyPassedOptions = { | |
| 5753 | + memoizeOptions: undefined | |
| 5754 | + }; // Normally, the result func or "output selector" is the last arg | |
| 5755 | + | |
| 5756 | + var resultFunc = funcs.pop(); // If the result func is actually an _object_, assume it's our options object | |
| 5757 | + | |
| 5758 | + if (typeof resultFunc === 'object') { | |
| 5759 | + directlyPassedOptions = resultFunc; // and pop the real result func off | |
| 5760 | + | |
| 5761 | + resultFunc = funcs.pop(); | |
| 5762 | + } | |
| 5763 | + | |
| 5764 | + if (typeof resultFunc !== 'function') { | |
| 5765 | + throw new Error("createSelector expects an output function after the inputs, but received: [" + typeof resultFunc + "]"); | |
| 5766 | + } // Determine which set of options we're using. Prefer options passed directly, | |
| 5767 | + // but fall back to options given to createSelectorCreator. | |
| 5768 | + | |
| 5769 | + | |
| 5770 | + var _directlyPassedOption = directlyPassedOptions, | |
| 5771 | + _directlyPassedOption2 = _directlyPassedOption.memoizeOptions, | |
| 5772 | + memoizeOptions = _directlyPassedOption2 === void 0 ? memoizeOptionsFromArgs : _directlyPassedOption2; // Simplifying assumption: it's unlikely that the first options arg of the provided memoizer | |
| 5773 | + // is an array. In most libs I've looked at, it's an equality function or options object. | |
| 5774 | + // Based on that, if `memoizeOptions` _is_ an array, we assume it's a full | |
| 5775 | + // user-provided array of options. Otherwise, it must be just the _first_ arg, and so | |
| 5776 | + // we wrap it in an array so we can apply it. | |
| 5777 | + | |
| 5778 | + var finalMemoizeOptions = Array.isArray(memoizeOptions) ? memoizeOptions : [memoizeOptions]; | |
| 5779 | + var dependencies = getDependencies(funcs); | |
| 5780 | + var memoizedResultFunc = memoize.apply(void 0, [function recomputationWrapper() { | |
| 5781 | + _recomputations++; // apply arguments instead of spreading for performance. | |
| 5782 | + | |
| 5783 | + return resultFunc.apply(null, arguments); | |
| 5784 | + }].concat(finalMemoizeOptions)); // If a selector is called with the exact same arguments we don't need to traverse our dependencies again. | |
| 5785 | + | |
| 5786 | + var selector = memoize(function dependenciesChecker() { | |
| 5787 | + var params = []; | |
| 5788 | + var length = dependencies.length; | |
| 5789 | + | |
| 5790 | + for (var i = 0; i < length; i++) { | |
| 5791 | + // apply arguments instead of spreading and mutate a local list of params for performance. | |
| 5792 | + // @ts-ignore | |
| 5793 | + params.push(dependencies[i].apply(null, arguments)); | |
| 5794 | + } // apply arguments instead of spreading for performance. | |
| 5795 | + | |
| 5796 | + | |
| 5797 | + _lastResult = memoizedResultFunc.apply(null, params); | |
| 5798 | + return _lastResult; | |
| 5799 | + }); | |
| 5800 | + Object.assign(selector, { | |
| 5801 | + resultFunc: resultFunc, | |
| 5802 | + memoizedResultFunc: memoizedResultFunc, | |
| 5803 | + dependencies: dependencies, | |
| 5804 | + lastResult: function lastResult() { | |
| 5805 | + return _lastResult; | |
| 5806 | + }, | |
| 5807 | + recomputations: function recomputations() { | |
| 5808 | + return _recomputations; | |
| 5809 | + }, | |
| 5810 | + resetRecomputations: function resetRecomputations() { | |
| 5811 | + return _recomputations = 0; | |
| 5812 | + } | |
| 5813 | + }); | |
| 5814 | + return selector; | |
| 5815 | + }; // @ts-ignore | |
| 5816 | + | |
| 5817 | + | |
| 5818 | + return createSelector; | |
| 5819 | +} | |
| 5820 | +var createSelector = /* #__PURE__ */createSelectorCreator(_defaultMemoize__WEBPACK_IMPORTED_MODULE_0__.defaultMemoize); | |
| 5821 | +// Manual definition of state and output arguments | |
| 5822 | +var createStructuredSelector = function createStructuredSelector(selectors, selectorCreator) { | |
| 5823 | + if (selectorCreator === void 0) { | |
| 5824 | + selectorCreator = createSelector; | |
| 5825 | + } | |
| 5826 | + | |
| 5827 | + if (typeof selectors !== 'object') { | |
| 5828 | + throw new Error('createStructuredSelector expects first argument to be an object ' + ("where each property is a selector, instead received a " + typeof selectors)); | |
| 5829 | + } | |
| 5830 | + | |
| 5831 | + var objectKeys = Object.keys(selectors); | |
| 5832 | + var resultSelector = selectorCreator( // @ts-ignore | |
| 5833 | + objectKeys.map(function (key) { | |
| 5834 | + return selectors[key]; | |
| 5835 | + }), function () { | |
| 5836 | + for (var _len3 = arguments.length, values = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) { | |
| 5837 | + values[_key3] = arguments[_key3]; | |
| 5838 | + } | |
| 5839 | + | |
| 5840 | + return values.reduce(function (composition, value, index) { | |
| 5841 | + composition[objectKeys[index]] = value; | |
| 5842 | + return composition; | |
| 5843 | + }, {}); | |
| 5844 | + }); | |
| 5845 | + return resultSelector; | |
| 5846 | +}; | |
| 5847 | + | |
| 5848 | +/***/ }), | |
| 5849 | + | |
| 2839 | 5850 | /***/ "../node_modules/@babel/runtime/helpers/arrayLikeToArray.js": |
| 2840 | 5851 | /*!******************************************************************!*\ |
| 2841 | 5852 | !*** ../node_modules/@babel/runtime/helpers/arrayLikeToArray.js ***! |
| 2842 | 5853 | \******************************************************************/ |
| @@ -2841,12 +5852,12 @@ | ||
| 2841 | 5852 | !*** ../node_modules/@babel/runtime/helpers/arrayLikeToArray.js ***! |
| 2842 | 5853 | \******************************************************************/ |
| 2843 | 5854 | /***/ ((module) => { |
| 2844 | 5855 | |
| 2845 | -function _arrayLikeToArray(r, a) { | |
| 2846 | - (null == a || a > r.length) && (a = r.length); | |
| 2847 | - for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; | |
| 2848 | - return n; | |
| 5856 | +function _arrayLikeToArray(arr, len) { | |
| 5857 | + if (len == null || len > arr.length) len = arr.length; | |
| 5858 | + for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; | |
| 5859 | + return arr2; | |
| 2849 | 5860 | } |
| 2850 | 5861 | module.exports = _arrayLikeToArray, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 2851 | 5862 | |
| 2852 | 5863 | /***/ }), |
| @@ -2856,29 +5867,15 @@ | ||
| 2856 | 5867 | !*** ../node_modules/@babel/runtime/helpers/arrayWithHoles.js ***! |
| 2857 | 5868 | \****************************************************************/ |
| 2858 | 5869 | /***/ ((module) => { |
| 2859 | 5870 | |
| 2860 | -function _arrayWithHoles(r) { | |
| 2861 | - if (Array.isArray(r)) return r; | |
| 5871 | +function _arrayWithHoles(arr) { | |
| 5872 | + if (Array.isArray(arr)) return arr; | |
| 2862 | 5873 | } |
| 2863 | 5874 | module.exports = _arrayWithHoles, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 2864 | 5875 | |
| 2865 | 5876 | /***/ }), |
| 2866 | 5877 | |
| 2867 | -/***/ "../node_modules/@babel/runtime/helpers/arrayWithoutHoles.js": | |
| 2868 | -/*!*******************************************************************!*\ | |
| 2869 | - !*** ../node_modules/@babel/runtime/helpers/arrayWithoutHoles.js ***! | |
| 2870 | - \*******************************************************************/ | |
| 2871 | -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { | |
| 2872 | - | |
| 2873 | -var arrayLikeToArray = __webpack_require__(/*! ./arrayLikeToArray.js */ "../node_modules/@babel/runtime/helpers/arrayLikeToArray.js"); | |
| 2874 | -function _arrayWithoutHoles(r) { | |
| 2875 | - if (Array.isArray(r)) return arrayLikeToArray(r); | |
| 2876 | -} | |
| 2877 | -module.exports = _arrayWithoutHoles, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 2878 | - | |
| 2879 | -/***/ }), | |
| 2880 | - | |
| 2881 | 5878 | /***/ "../node_modules/@babel/runtime/helpers/assertThisInitialized.js": |
| 2882 | 5879 | /*!***********************************************************************!*\ |
| 2883 | 5880 | !*** ../node_modules/@babel/runtime/helpers/assertThisInitialized.js ***! |
| 2884 | 5881 | \***********************************************************************/ |
| @@ -2883,11 +5880,13 @@ | ||
| 2883 | 5880 | !*** ../node_modules/@babel/runtime/helpers/assertThisInitialized.js ***! |
| 2884 | 5881 | \***********************************************************************/ |
| 2885 | 5882 | /***/ ((module) => { |
| 2886 | 5883 | |
| 2887 | -function _assertThisInitialized(e) { | |
| 2888 | - if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); | |
| 2889 | - return e; | |
| 5884 | +function _assertThisInitialized(self) { | |
| 5885 | + if (self === void 0) { | |
| 5886 | + throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); | |
| 5887 | + } | |
| 5888 | + return self; | |
| 2890 | 5889 | } |
| 2891 | 5890 | module.exports = _assertThisInitialized, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 2892 | 5891 | |
| 2893 | 5892 | /***/ }), |
| @@ -2897,10 +5896,12 @@ | ||
| 2897 | 5896 | !*** ../node_modules/@babel/runtime/helpers/classCallCheck.js ***! |
| 2898 | 5897 | \****************************************************************/ |
| 2899 | 5898 | /***/ ((module) => { |
| 2900 | 5899 | |
| 2901 | -function _classCallCheck(a, n) { | |
| 2902 | - if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); | |
| 5900 | +function _classCallCheck(instance, Constructor) { | |
| 5901 | + if (!(instance instanceof Constructor)) { | |
| 5902 | + throw new TypeError("Cannot call a class as a function"); | |
| 5903 | + } | |
| 2903 | 5904 | } |
| 2904 | 5905 | module.exports = _classCallCheck, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 2905 | 5906 | |
| 2906 | 5907 | /***/ }), |
| @@ -2910,10 +5911,10 @@ | ||
| 2910 | 5911 | !*** ../node_modules/@babel/runtime/helpers/construct.js ***! |
| 2911 | 5912 | \***********************************************************/ |
| 2912 | 5913 | /***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 2913 | 5914 | |
| 5915 | +var setPrototypeOf = __webpack_require__(/*! ./setPrototypeOf.js */ "../node_modules/@babel/runtime/helpers/setPrototypeOf.js"); | |
| 2914 | 5916 | var isNativeReflectConstruct = __webpack_require__(/*! ./isNativeReflectConstruct.js */ "../node_modules/@babel/runtime/helpers/isNativeReflectConstruct.js"); |
| 2915 | -var setPrototypeOf = __webpack_require__(/*! ./setPrototypeOf.js */ "../node_modules/@babel/runtime/helpers/setPrototypeOf.js"); | |
| 2916 | 5917 | function _construct(t, e, r) { |
| 2917 | 5918 | if (isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); |
| 2918 | 5919 | var o = [null]; |
| 2919 | 5920 | o.push.apply(o, e); |
| @@ -2930,18 +5931,24 @@ | ||
| 2930 | 5931 | \*************************************************************/ |
| 2931 | 5932 | /***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 2932 | 5933 | |
| 2933 | 5934 | var toPropertyKey = __webpack_require__(/*! ./toPropertyKey.js */ "../node_modules/@babel/runtime/helpers/toPropertyKey.js"); |
| 2934 | -function _defineProperties(e, r) { | |
| 2935 | - for (var t = 0; t < r.length; t++) { | |
| 2936 | - var o = r[t]; | |
| 2937 | - o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, toPropertyKey(o.key), o); | |
| 5935 | +function _defineProperties(target, props) { | |
| 5936 | + for (var i = 0; i < props.length; i++) { | |
| 5937 | + var descriptor = props[i]; | |
| 5938 | + descriptor.enumerable = descriptor.enumerable || false; | |
| 5939 | + descriptor.configurable = true; | |
| 5940 | + if ("value" in descriptor) descriptor.writable = true; | |
| 5941 | + Object.defineProperty(target, toPropertyKey(descriptor.key), descriptor); | |
| 2938 | 5942 | } |
| 2939 | 5943 | } |
| 2940 | -function _createClass(e, r, t) { | |
| 2941 | - return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { | |
| 2942 | - writable: !1 | |
| 2943 | - }), e; | |
| 5944 | +function _createClass(Constructor, protoProps, staticProps) { | |
| 5945 | + if (protoProps) _defineProperties(Constructor.prototype, protoProps); | |
| 5946 | + if (staticProps) _defineProperties(Constructor, staticProps); | |
| 5947 | + Object.defineProperty(Constructor, "prototype", { | |
| 5948 | + writable: false | |
| 5949 | + }); | |
| 5950 | + return Constructor; | |
| 2944 | 5951 | } |
| 2945 | 5952 | module.exports = _createClass, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 2946 | 5953 | |
| 2947 | 5954 | /***/ }), |
| @@ -2952,15 +5959,21 @@ | ||
| 2952 | 5959 | \****************************************************************/ |
| 2953 | 5960 | /***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 2954 | 5961 | |
| 2955 | 5962 | var toPropertyKey = __webpack_require__(/*! ./toPropertyKey.js */ "../node_modules/@babel/runtime/helpers/toPropertyKey.js"); |
| 2956 | -function _defineProperty(e, r, t) { | |
| 2957 | - return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, { | |
| 2958 | - value: t, | |
| 2959 | - enumerable: !0, | |
| 2960 | - configurable: !0, | |
| 2961 | - writable: !0 | |
| 2962 | - }) : e[r] = t, e; | |
| 5963 | +function _defineProperty(obj, key, value) { | |
| 5964 | + key = toPropertyKey(key); | |
| 5965 | + if (key in obj) { | |
| 5966 | + Object.defineProperty(obj, key, { | |
| 5967 | + value: value, | |
| 5968 | + enumerable: true, | |
| 5969 | + configurable: true, | |
| 5970 | + writable: true | |
| 5971 | + }); | |
| 5972 | + } else { | |
| 5973 | + obj[key] = value; | |
| 5974 | + } | |
| 5975 | + return obj; | |
| 2963 | 5976 | } |
| 2964 | 5977 | module.exports = _defineProperty, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 2965 | 5978 | |
| 2966 | 5979 | /***/ }), |
| @@ -2972,15 +5985,22 @@ | ||
| 2972 | 5985 | /***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 2973 | 5986 | |
| 2974 | 5987 | var superPropBase = __webpack_require__(/*! ./superPropBase.js */ "../node_modules/@babel/runtime/helpers/superPropBase.js"); |
| 2975 | 5988 | function _get() { |
| 2976 | - return module.exports = _get = "undefined" != typeof Reflect && Reflect.get ? Reflect.get.bind() : function (e, t, r) { | |
| 2977 | - var p = superPropBase(e, t); | |
| 2978 | - if (p) { | |
| 2979 | - var n = Object.getOwnPropertyDescriptor(p, t); | |
| 2980 | - return n.get ? n.get.call(arguments.length < 3 ? e : r) : n.value; | |
| 2981 | - } | |
| 2982 | - }, module.exports.__esModule = true, module.exports["default"] = module.exports, _get.apply(null, arguments); | |
| 5989 | + if (typeof Reflect !== "undefined" && Reflect.get) { | |
| 5990 | + module.exports = _get = Reflect.get.bind(), module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 5991 | + } else { | |
| 5992 | + module.exports = _get = function _get(target, property, receiver) { | |
| 5993 | + var base = superPropBase(target, property); | |
| 5994 | + if (!base) return; | |
| 5995 | + var desc = Object.getOwnPropertyDescriptor(base, property); | |
| 5996 | + if (desc.get) { | |
| 5997 | + return desc.get.call(arguments.length < 3 ? target : receiver); | |
| 5998 | + } | |
| 5999 | + return desc.value; | |
| 6000 | + }, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 6001 | + } | |
| 6002 | + return _get.apply(this, arguments); | |
| 2983 | 6003 | } |
| 2984 | 6004 | module.exports = _get, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 2985 | 6005 | |
| 2986 | 6006 | /***/ }), |
| @@ -2990,12 +6010,13 @@ | ||
| 2990 | 6010 | !*** ../node_modules/@babel/runtime/helpers/getPrototypeOf.js ***! |
| 2991 | 6011 | \****************************************************************/ |
| 2992 | 6012 | /***/ ((module) => { |
| 2993 | 6013 | |
| 2994 | -function _getPrototypeOf(t) { | |
| 2995 | - return module.exports = _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { | |
| 2996 | - return t.__proto__ || Object.getPrototypeOf(t); | |
| 2997 | - }, module.exports.__esModule = true, module.exports["default"] = module.exports, _getPrototypeOf(t); | |
| 6014 | +function _getPrototypeOf(o) { | |
| 6015 | + module.exports = _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { | |
| 6016 | + return o.__proto__ || Object.getPrototypeOf(o); | |
| 6017 | + }, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 6018 | + return _getPrototypeOf(o); | |
| 2998 | 6019 | } |
| 2999 | 6020 | module.exports = _getPrototypeOf, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 3000 | 6021 | |
| 3001 | 6022 | /***/ }), |
| @@ -3006,19 +6027,23 @@ | ||
| 3006 | 6027 | \**********************************************************/ |
| 3007 | 6028 | /***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 3008 | 6029 | |
| 3009 | 6030 | var setPrototypeOf = __webpack_require__(/*! ./setPrototypeOf.js */ "../node_modules/@babel/runtime/helpers/setPrototypeOf.js"); |
| 3010 | -function _inherits(t, e) { | |
| 3011 | - if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); | |
| 3012 | - t.prototype = Object.create(e && e.prototype, { | |
| 6031 | +function _inherits(subClass, superClass) { | |
| 6032 | + if (typeof superClass !== "function" && superClass !== null) { | |
| 6033 | + throw new TypeError("Super expression must either be null or a function"); | |
| 6034 | + } | |
| 6035 | + subClass.prototype = Object.create(superClass && superClass.prototype, { | |
| 3013 | 6036 | constructor: { |
| 3014 | - value: t, | |
| 3015 | - writable: !0, | |
| 3016 | - configurable: !0 | |
| 6037 | + value: subClass, | |
| 6038 | + writable: true, | |
| 6039 | + configurable: true | |
| 3017 | 6040 | } |
| 3018 | - }), Object.defineProperty(t, "prototype", { | |
| 3019 | - writable: !1 | |
| 3020 | - }), e && setPrototypeOf(t, e); | |
| 6041 | + }); | |
| 6042 | + Object.defineProperty(subClass, "prototype", { | |
| 6043 | + writable: false | |
| 6044 | + }); | |
| 6045 | + if (superClass) setPrototypeOf(subClass, superClass); | |
| 3021 | 6046 | } |
| 3022 | 6047 | module.exports = _inherits, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 3023 | 6048 | |
| 3024 | 6049 | /***/ }), |
| @@ -3028,11 +6053,11 @@ | ||
| 3028 | 6053 | !*** ../node_modules/@babel/runtime/helpers/interopRequireDefault.js ***! |
| 3029 | 6054 | \***********************************************************************/ |
| 3030 | 6055 | /***/ ((module) => { |
| 3031 | 6056 | |
| 3032 | -function _interopRequireDefault(e) { | |
| 3033 | - return e && e.__esModule ? e : { | |
| 3034 | - "default": e | |
| 6057 | +function _interopRequireDefault(obj) { | |
| 6058 | + return obj && obj.__esModule ? obj : { | |
| 6059 | + "default": obj | |
| 3035 | 6060 | }; |
| 3036 | 6061 | } |
| 3037 | 6062 | module.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 3038 | 6063 | |
| @@ -3043,13 +6068,13 @@ | ||
| 3043 | 6068 | !*** ../node_modules/@babel/runtime/helpers/isNativeFunction.js ***! |
| 3044 | 6069 | \******************************************************************/ |
| 3045 | 6070 | /***/ ((module) => { |
| 3046 | 6071 | |
| 3047 | -function _isNativeFunction(t) { | |
| 6072 | +function _isNativeFunction(fn) { | |
| 3048 | 6073 | try { |
| 3049 | - return -1 !== Function.toString.call(t).indexOf("[native code]"); | |
| 3050 | - } catch (n) { | |
| 3051 | - return "function" == typeof t; | |
| 6074 | + return Function.toString.call(fn).indexOf("[native code]") !== -1; | |
| 6075 | + } catch (e) { | |
| 6076 | + return typeof fn === "function"; | |
| 3052 | 6077 | } |
| 3053 | 6078 | } |
| 3054 | 6079 | module.exports = _isNativeFunction, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 3055 | 6080 | |
| @@ -3072,21 +6097,8 @@ | ||
| 3072 | 6097 | module.exports = _isNativeReflectConstruct, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 3073 | 6098 | |
| 3074 | 6099 | /***/ }), |
| 3075 | 6100 | |
| 3076 | -/***/ "../node_modules/@babel/runtime/helpers/iterableToArray.js": | |
| 3077 | -/*!*****************************************************************!*\ | |
| 3078 | - !*** ../node_modules/@babel/runtime/helpers/iterableToArray.js ***! | |
| 3079 | - \*****************************************************************/ | |
| 3080 | -/***/ ((module) => { | |
| 3081 | - | |
| 3082 | -function _iterableToArray(r) { | |
| 3083 | - if ("undefined" != typeof Symbol && null != r[Symbol.iterator] || null != r["@@iterator"]) return Array.from(r); | |
| 3084 | -} | |
| 3085 | -module.exports = _iterableToArray, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 3086 | - | |
| 3087 | -/***/ }), | |
| 3088 | - | |
| 3089 | 6101 | /***/ "../node_modules/@babel/runtime/helpers/iterableToArrayLimit.js": |
| 3090 | 6102 | /*!**********************************************************************!*\ |
| 3091 | 6103 | !*** ../node_modules/@babel/runtime/helpers/iterableToArrayLimit.js ***! |
| 3092 | 6104 | \**********************************************************************/ |
| @@ -3135,62 +6147,8 @@ | ||
| 3135 | 6147 | module.exports = _nonIterableRest, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 3136 | 6148 | |
| 3137 | 6149 | /***/ }), |
| 3138 | 6150 | |
| 3139 | -/***/ "../node_modules/@babel/runtime/helpers/nonIterableSpread.js": | |
| 3140 | -/*!*******************************************************************!*\ | |
| 3141 | - !*** ../node_modules/@babel/runtime/helpers/nonIterableSpread.js ***! | |
| 3142 | - \*******************************************************************/ | |
| 3143 | -/***/ ((module) => { | |
| 3144 | - | |
| 3145 | -function _nonIterableSpread() { | |
| 3146 | - throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); | |
| 3147 | -} | |
| 3148 | -module.exports = _nonIterableSpread, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 3149 | - | |
| 3150 | -/***/ }), | |
| 3151 | - | |
| 3152 | -/***/ "../node_modules/@babel/runtime/helpers/objectWithoutProperties.js": | |
| 3153 | -/*!*************************************************************************!*\ | |
| 3154 | - !*** ../node_modules/@babel/runtime/helpers/objectWithoutProperties.js ***! | |
| 3155 | - \*************************************************************************/ | |
| 3156 | -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { | |
| 3157 | - | |
| 3158 | -var objectWithoutPropertiesLoose = __webpack_require__(/*! ./objectWithoutPropertiesLoose.js */ "../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js"); | |
| 3159 | -function _objectWithoutProperties(e, t) { | |
| 3160 | - if (null == e) return {}; | |
| 3161 | - var o, | |
| 3162 | - r, | |
| 3163 | - i = objectWithoutPropertiesLoose(e, t); | |
| 3164 | - if (Object.getOwnPropertySymbols) { | |
| 3165 | - var n = Object.getOwnPropertySymbols(e); | |
| 3166 | - for (r = 0; r < n.length; r++) o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); | |
| 3167 | - } | |
| 3168 | - return i; | |
| 3169 | -} | |
| 3170 | -module.exports = _objectWithoutProperties, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 3171 | - | |
| 3172 | -/***/ }), | |
| 3173 | - | |
| 3174 | -/***/ "../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js": | |
| 3175 | -/*!******************************************************************************!*\ | |
| 3176 | - !*** ../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js ***! | |
| 3177 | - \******************************************************************************/ | |
| 3178 | -/***/ ((module) => { | |
| 3179 | - | |
| 3180 | -function _objectWithoutPropertiesLoose(r, e) { | |
| 3181 | - if (null == r) return {}; | |
| 3182 | - var t = {}; | |
| 3183 | - for (var n in r) if ({}.hasOwnProperty.call(r, n)) { | |
| 3184 | - if (-1 !== e.indexOf(n)) continue; | |
| 3185 | - t[n] = r[n]; | |
| 3186 | - } | |
| 3187 | - return t; | |
| 3188 | -} | |
| 3189 | -module.exports = _objectWithoutPropertiesLoose, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 3190 | - | |
| 3191 | -/***/ }), | |
| 3192 | - | |
| 3193 | 6151 | /***/ "../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js": |
| 3194 | 6152 | /*!***************************************************************************!*\ |
| 3195 | 6153 | !*** ../node_modules/@babel/runtime/helpers/possibleConstructorReturn.js ***! |
| 3196 | 6154 | \***************************************************************************/ |
| @@ -3197,30 +6155,20 @@ | ||
| 3197 | 6155 | /***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 3198 | 6156 | |
| 3199 | 6157 | var _typeof = (__webpack_require__(/*! ./typeof.js */ "../node_modules/@babel/runtime/helpers/typeof.js")["default"]); |
| 3200 | 6158 | var assertThisInitialized = __webpack_require__(/*! ./assertThisInitialized.js */ "../node_modules/@babel/runtime/helpers/assertThisInitialized.js"); |
| 3201 | -function _possibleConstructorReturn(t, e) { | |
| 3202 | - if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; | |
| 3203 | - if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); | |
| 3204 | - return assertThisInitialized(t); | |
| 6159 | +function _possibleConstructorReturn(self, call) { | |
| 6160 | + if (call && (_typeof(call) === "object" || typeof call === "function")) { | |
| 6161 | + return call; | |
| 6162 | + } else if (call !== void 0) { | |
| 6163 | + throw new TypeError("Derived constructors may only return object or undefined"); | |
| 6164 | + } | |
| 6165 | + return assertThisInitialized(self); | |
| 3205 | 6166 | } |
| 3206 | 6167 | module.exports = _possibleConstructorReturn, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 3207 | 6168 | |
| 3208 | 6169 | /***/ }), |
| 3209 | 6170 | |
| 3210 | -/***/ "../node_modules/@babel/runtime/helpers/readOnlyError.js": | |
| 3211 | -/*!***************************************************************!*\ | |
| 3212 | - !*** ../node_modules/@babel/runtime/helpers/readOnlyError.js ***! | |
| 3213 | - \***************************************************************/ | |
| 3214 | -/***/ ((module) => { | |
| 3215 | - | |
| 3216 | -function _readOnlyError(r) { | |
| 3217 | - throw new TypeError('"' + r + '" is read-only'); | |
| 3218 | -} | |
| 3219 | -module.exports = _readOnlyError, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 3220 | - | |
| 3221 | -/***/ }), | |
| 3222 | - | |
| 3223 | 6171 | /***/ "../node_modules/@babel/runtime/helpers/setPrototypeOf.js": |
| 3224 | 6172 | /*!****************************************************************!*\ |
| 3225 | 6173 | !*** ../node_modules/@babel/runtime/helpers/setPrototypeOf.js ***! |
| 3226 | 6174 | \****************************************************************/ |
| @@ -3225,12 +6173,14 @@ | ||
| 3225 | 6173 | !*** ../node_modules/@babel/runtime/helpers/setPrototypeOf.js ***! |
| 3226 | 6174 | \****************************************************************/ |
| 3227 | 6175 | /***/ ((module) => { |
| 3228 | 6176 | |
| 3229 | -function _setPrototypeOf(t, e) { | |
| 3230 | - return module.exports = _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { | |
| 3231 | - return t.__proto__ = e, t; | |
| 3232 | - }, module.exports.__esModule = true, module.exports["default"] = module.exports, _setPrototypeOf(t, e); | |
| 6177 | +function _setPrototypeOf(o, p) { | |
| 6178 | + module.exports = _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { | |
| 6179 | + o.__proto__ = p; | |
| 6180 | + return o; | |
| 6181 | + }, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 6182 | + return _setPrototypeOf(o, p); | |
| 3233 | 6183 | } |
| 3234 | 6184 | module.exports = _setPrototypeOf, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 3235 | 6185 | |
| 3236 | 6186 | /***/ }), |
| @@ -3244,10 +6194,10 @@ | ||
| 3244 | 6194 | var arrayWithHoles = __webpack_require__(/*! ./arrayWithHoles.js */ "../node_modules/@babel/runtime/helpers/arrayWithHoles.js"); |
| 3245 | 6195 | var iterableToArrayLimit = __webpack_require__(/*! ./iterableToArrayLimit.js */ "../node_modules/@babel/runtime/helpers/iterableToArrayLimit.js"); |
| 3246 | 6196 | var unsupportedIterableToArray = __webpack_require__(/*! ./unsupportedIterableToArray.js */ "../node_modules/@babel/runtime/helpers/unsupportedIterableToArray.js"); |
| 3247 | 6197 | var nonIterableRest = __webpack_require__(/*! ./nonIterableRest.js */ "../node_modules/@babel/runtime/helpers/nonIterableRest.js"); |
| 3248 | -function _slicedToArray(r, e) { | |
| 3249 | - return arrayWithHoles(r) || iterableToArrayLimit(r, e) || unsupportedIterableToArray(r, e) || nonIterableRest(); | |
| 6198 | +function _slicedToArray(arr, i) { | |
| 6199 | + return arrayWithHoles(arr) || iterableToArrayLimit(arr, i) || unsupportedIterableToArray(arr, i) || nonIterableRest(); | |
| 3250 | 6200 | } |
| 3251 | 6201 | module.exports = _slicedToArray, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 3252 | 6202 | |
| 3253 | 6203 | /***/ }), |
| @@ -3258,33 +6208,19 @@ | ||
| 3258 | 6208 | \***************************************************************/ |
| 3259 | 6209 | /***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 3260 | 6210 | |
| 3261 | 6211 | var getPrototypeOf = __webpack_require__(/*! ./getPrototypeOf.js */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js"); |
| 3262 | -function _superPropBase(t, o) { | |
| 3263 | - for (; !{}.hasOwnProperty.call(t, o) && null !== (t = getPrototypeOf(t));); | |
| 3264 | - return t; | |
| 6212 | +function _superPropBase(object, property) { | |
| 6213 | + while (!Object.prototype.hasOwnProperty.call(object, property)) { | |
| 6214 | + object = getPrototypeOf(object); | |
| 6215 | + if (object === null) break; | |
| 6216 | + } | |
| 6217 | + return object; | |
| 3265 | 6218 | } |
| 3266 | 6219 | module.exports = _superPropBase, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 3267 | 6220 | |
| 3268 | 6221 | /***/ }), |
| 3269 | 6222 | |
| 3270 | -/***/ "../node_modules/@babel/runtime/helpers/toConsumableArray.js": | |
| 3271 | -/*!*******************************************************************!*\ | |
| 3272 | - !*** ../node_modules/@babel/runtime/helpers/toConsumableArray.js ***! | |
| 3273 | - \*******************************************************************/ | |
| 3274 | -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { | |
| 3275 | - | |
| 3276 | -var arrayWithoutHoles = __webpack_require__(/*! ./arrayWithoutHoles.js */ "../node_modules/@babel/runtime/helpers/arrayWithoutHoles.js"); | |
| 3277 | -var iterableToArray = __webpack_require__(/*! ./iterableToArray.js */ "../node_modules/@babel/runtime/helpers/iterableToArray.js"); | |
| 3278 | -var unsupportedIterableToArray = __webpack_require__(/*! ./unsupportedIterableToArray.js */ "../node_modules/@babel/runtime/helpers/unsupportedIterableToArray.js"); | |
| 3279 | -var nonIterableSpread = __webpack_require__(/*! ./nonIterableSpread.js */ "../node_modules/@babel/runtime/helpers/nonIterableSpread.js"); | |
| 3280 | -function _toConsumableArray(r) { | |
| 3281 | - return arrayWithoutHoles(r) || iterableToArray(r) || unsupportedIterableToArray(r) || nonIterableSpread(); | |
| 3282 | -} | |
| 3283 | -module.exports = _toConsumableArray, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 3284 | - | |
| 3285 | -/***/ }), | |
| 3286 | - | |
| 3287 | 6223 | /***/ "../node_modules/@babel/runtime/helpers/toPrimitive.js": |
| 3288 | 6224 | /*!*************************************************************!*\ |
| 3289 | 6225 | !*** ../node_modules/@babel/runtime/helpers/toPrimitive.js ***! |
| 3290 | 6226 | \*************************************************************/ |
| @@ -3314,9 +6250,9 @@ | ||
| 3314 | 6250 | var _typeof = (__webpack_require__(/*! ./typeof.js */ "../node_modules/@babel/runtime/helpers/typeof.js")["default"]); |
| 3315 | 6251 | var toPrimitive = __webpack_require__(/*! ./toPrimitive.js */ "../node_modules/@babel/runtime/helpers/toPrimitive.js"); |
| 3316 | 6252 | function toPropertyKey(t) { |
| 3317 | 6253 | var i = toPrimitive(t, "string"); |
| 3318 | - return "symbol" == _typeof(i) ? i : i + ""; | |
| 6254 | + return "symbol" == _typeof(i) ? i : String(i); | |
| 3319 | 6255 | } |
| 3320 | 6256 | module.exports = toPropertyKey, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 3321 | 6257 | |
| 3322 | 6258 | /***/ }), |
| @@ -3329,13 +6265,13 @@ | ||
| 3329 | 6265 | |
| 3330 | 6266 | function _typeof(o) { |
| 3331 | 6267 | "@babel/helpers - typeof"; |
| 3332 | 6268 | |
| 3333 | - return module.exports = _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { | |
| 6269 | + return (module.exports = _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { | |
| 3334 | 6270 | return typeof o; |
| 3335 | 6271 | } : function (o) { |
| 3336 | 6272 | return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; |
| 3337 | - }, module.exports.__esModule = true, module.exports["default"] = module.exports, _typeof(o); | |
| 6273 | + }, module.exports.__esModule = true, module.exports["default"] = module.exports), _typeof(o); | |
| 3338 | 6274 | } |
| 3339 | 6275 | module.exports = _typeof, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 3340 | 6276 | |
| 3341 | 6277 | /***/ }), |
| @@ -3346,14 +6282,15 @@ | ||
| 3346 | 6282 | \****************************************************************************/ |
| 3347 | 6283 | /***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 3348 | 6284 | |
| 3349 | 6285 | var arrayLikeToArray = __webpack_require__(/*! ./arrayLikeToArray.js */ "../node_modules/@babel/runtime/helpers/arrayLikeToArray.js"); |
| 3350 | -function _unsupportedIterableToArray(r, a) { | |
| 3351 | - if (r) { | |
| 3352 | - if ("string" == typeof r) return arrayLikeToArray(r, a); | |
| 3353 | - var t = {}.toString.call(r).slice(8, -1); | |
| 3354 | - return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? arrayLikeToArray(r, a) : void 0; | |
| 3355 | - } | |
| 6286 | +function _unsupportedIterableToArray(o, minLen) { | |
| 6287 | + if (!o) return; | |
| 6288 | + if (typeof o === "string") return arrayLikeToArray(o, minLen); | |
| 6289 | + var n = Object.prototype.toString.call(o).slice(8, -1); | |
| 6290 | + if (n === "Object" && o.constructor) n = o.constructor.name; | |
| 6291 | + if (n === "Map" || n === "Set") return Array.from(o); | |
| 6292 | + if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen); | |
| 3356 | 6293 | } |
| 3357 | 6294 | module.exports = _unsupportedIterableToArray, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 3358 | 6295 | |
| 3359 | 6296 | /***/ }), |
| @@ -3367,43 +6304,212 @@ | ||
| 3367 | 6304 | var getPrototypeOf = __webpack_require__(/*! ./getPrototypeOf.js */ "../node_modules/@babel/runtime/helpers/getPrototypeOf.js"); |
| 3368 | 6305 | var setPrototypeOf = __webpack_require__(/*! ./setPrototypeOf.js */ "../node_modules/@babel/runtime/helpers/setPrototypeOf.js"); |
| 3369 | 6306 | var isNativeFunction = __webpack_require__(/*! ./isNativeFunction.js */ "../node_modules/@babel/runtime/helpers/isNativeFunction.js"); |
| 3370 | 6307 | var construct = __webpack_require__(/*! ./construct.js */ "../node_modules/@babel/runtime/helpers/construct.js"); |
| 3371 | -function _wrapNativeSuper(t) { | |
| 3372 | - var r = "function" == typeof Map ? new Map() : void 0; | |
| 3373 | - return module.exports = _wrapNativeSuper = function _wrapNativeSuper(t) { | |
| 3374 | - if (null === t || !isNativeFunction(t)) return t; | |
| 3375 | - if ("function" != typeof t) throw new TypeError("Super expression must either be null or a function"); | |
| 3376 | - if (void 0 !== r) { | |
| 3377 | - if (r.has(t)) return r.get(t); | |
| 3378 | - r.set(t, Wrapper); | |
| 6308 | +function _wrapNativeSuper(Class) { | |
| 6309 | + var _cache = typeof Map === "function" ? new Map() : undefined; | |
| 6310 | + module.exports = _wrapNativeSuper = function _wrapNativeSuper(Class) { | |
| 6311 | + if (Class === null || !isNativeFunction(Class)) return Class; | |
| 6312 | + if (typeof Class !== "function") { | |
| 6313 | + throw new TypeError("Super expression must either be null or a function"); | |
| 3379 | 6314 | } |
| 6315 | + if (typeof _cache !== "undefined") { | |
| 6316 | + if (_cache.has(Class)) return _cache.get(Class); | |
| 6317 | + _cache.set(Class, Wrapper); | |
| 6318 | + } | |
| 3380 | 6319 | function Wrapper() { |
| 3381 | - return construct(t, arguments, getPrototypeOf(this).constructor); | |
| 6320 | + return construct(Class, arguments, getPrototypeOf(this).constructor); | |
| 3382 | 6321 | } |
| 3383 | - return Wrapper.prototype = Object.create(t.prototype, { | |
| 6322 | + Wrapper.prototype = Object.create(Class.prototype, { | |
| 3384 | 6323 | constructor: { |
| 3385 | 6324 | value: Wrapper, |
| 3386 | - enumerable: !1, | |
| 3387 | - writable: !0, | |
| 3388 | - configurable: !0 | |
| 6325 | + enumerable: false, | |
| 6326 | + writable: true, | |
| 6327 | + configurable: true | |
| 3389 | 6328 | } |
| 3390 | - }), setPrototypeOf(Wrapper, t); | |
| 3391 | - }, module.exports.__esModule = true, module.exports["default"] = module.exports, _wrapNativeSuper(t); | |
| 6329 | + }); | |
| 6330 | + return setPrototypeOf(Wrapper, Class); | |
| 6331 | + }, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 6332 | + return _wrapNativeSuper(Class); | |
| 3392 | 6333 | } |
| 3393 | 6334 | module.exports = _wrapNativeSuper, module.exports.__esModule = true, module.exports["default"] = module.exports; |
| 3394 | 6335 | |
| 3395 | 6336 | /***/ }), |
| 3396 | 6337 | |
| 3397 | -/***/ "@reduxjs/toolkit": | |
| 3398 | -/*!************************************************!*\ | |
| 3399 | - !*** external "elementorVendors.reduxToolkit" ***! | |
| 3400 | - \************************************************/ | |
| 3401 | -/***/ ((module) => { | |
| 6338 | +/***/ "../node_modules/@babel/runtime/helpers/esm/defineProperty.js": | |
| 6339 | +/*!********************************************************************!*\ | |
| 6340 | + !*** ../node_modules/@babel/runtime/helpers/esm/defineProperty.js ***! | |
| 6341 | + \********************************************************************/ | |
| 6342 | +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => { | |
| 3402 | 6343 | |
| 3403 | 6344 | "use strict"; |
| 3404 | -module.exports = elementorVendors.reduxToolkit; | |
| 6345 | +__webpack_require__.r(__webpack_exports__); | |
| 6346 | +/* harmony export */ __webpack_require__.d(__webpack_exports__, { | |
| 6347 | +/* harmony export */ "default": () => (/* binding */ _defineProperty) | |
| 6348 | +/* harmony export */ }); | |
| 6349 | +/* harmony import */ var _toPropertyKey_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./toPropertyKey.js */ "../node_modules/@babel/runtime/helpers/esm/toPropertyKey.js"); | |
| 3405 | 6350 | |
| 6351 | +function _defineProperty(obj, key, value) { | |
| 6352 | + key = (0,_toPropertyKey_js__WEBPACK_IMPORTED_MODULE_0__["default"])(key); | |
| 6353 | + if (key in obj) { | |
| 6354 | + Object.defineProperty(obj, key, { | |
| 6355 | + value: value, | |
| 6356 | + enumerable: true, | |
| 6357 | + configurable: true, | |
| 6358 | + writable: true | |
| 6359 | + }); | |
| 6360 | + } else { | |
| 6361 | + obj[key] = value; | |
| 6362 | + } | |
| 6363 | + return obj; | |
| 6364 | +} | |
| 6365 | + | |
| 6366 | +/***/ }), | |
| 6367 | + | |
| 6368 | +/***/ "../node_modules/@babel/runtime/helpers/esm/objectSpread2.js": | |
| 6369 | +/*!*******************************************************************!*\ | |
| 6370 | + !*** ../node_modules/@babel/runtime/helpers/esm/objectSpread2.js ***! | |
| 6371 | + \*******************************************************************/ | |
| 6372 | +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => { | |
| 6373 | + | |
| 6374 | +"use strict"; | |
| 6375 | +__webpack_require__.r(__webpack_exports__); | |
| 6376 | +/* harmony export */ __webpack_require__.d(__webpack_exports__, { | |
| 6377 | +/* harmony export */ "default": () => (/* binding */ _objectSpread2) | |
| 6378 | +/* harmony export */ }); | |
| 6379 | +/* harmony import */ var _defineProperty_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./defineProperty.js */ "../node_modules/@babel/runtime/helpers/esm/defineProperty.js"); | |
| 6380 | + | |
| 6381 | +function ownKeys(e, r) { | |
| 6382 | + var t = Object.keys(e); | |
| 6383 | + if (Object.getOwnPropertySymbols) { | |
| 6384 | + var o = Object.getOwnPropertySymbols(e); | |
| 6385 | + r && (o = o.filter(function (r) { | |
| 6386 | + return Object.getOwnPropertyDescriptor(e, r).enumerable; | |
| 6387 | + })), t.push.apply(t, o); | |
| 6388 | + } | |
| 6389 | + return t; | |
| 6390 | +} | |
| 6391 | +function _objectSpread2(e) { | |
| 6392 | + for (var r = 1; r < arguments.length; r++) { | |
| 6393 | + var t = null != arguments[r] ? arguments[r] : {}; | |
| 6394 | + r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { | |
| 6395 | + (0,_defineProperty_js__WEBPACK_IMPORTED_MODULE_0__["default"])(e, r, t[r]); | |
| 6396 | + }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { | |
| 6397 | + Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); | |
| 6398 | + }); | |
| 6399 | + } | |
| 6400 | + return e; | |
| 6401 | +} | |
| 6402 | + | |
| 6403 | +/***/ }), | |
| 6404 | + | |
| 6405 | +/***/ "../node_modules/@babel/runtime/helpers/esm/toPrimitive.js": | |
| 6406 | +/*!*****************************************************************!*\ | |
| 6407 | + !*** ../node_modules/@babel/runtime/helpers/esm/toPrimitive.js ***! | |
| 6408 | + \*****************************************************************/ | |
| 6409 | +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => { | |
| 6410 | + | |
| 6411 | +"use strict"; | |
| 6412 | +__webpack_require__.r(__webpack_exports__); | |
| 6413 | +/* harmony export */ __webpack_require__.d(__webpack_exports__, { | |
| 6414 | +/* harmony export */ "default": () => (/* binding */ toPrimitive) | |
| 6415 | +/* harmony export */ }); | |
| 6416 | +/* harmony import */ var _typeof_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./typeof.js */ "../node_modules/@babel/runtime/helpers/esm/typeof.js"); | |
| 6417 | + | |
| 6418 | +function toPrimitive(t, r) { | |
| 6419 | + if ("object" != (0,_typeof_js__WEBPACK_IMPORTED_MODULE_0__["default"])(t) || !t) return t; | |
| 6420 | + var e = t[Symbol.toPrimitive]; | |
| 6421 | + if (void 0 !== e) { | |
| 6422 | + var i = e.call(t, r || "default"); | |
| 6423 | + if ("object" != (0,_typeof_js__WEBPACK_IMPORTED_MODULE_0__["default"])(i)) return i; | |
| 6424 | + throw new TypeError("@@toPrimitive must return a primitive value."); | |
| 6425 | + } | |
| 6426 | + return ("string" === r ? String : Number)(t); | |
| 6427 | +} | |
| 6428 | + | |
| 6429 | +/***/ }), | |
| 6430 | + | |
| 6431 | +/***/ "../node_modules/@babel/runtime/helpers/esm/toPropertyKey.js": | |
| 6432 | +/*!*******************************************************************!*\ | |
| 6433 | + !*** ../node_modules/@babel/runtime/helpers/esm/toPropertyKey.js ***! | |
| 6434 | + \*******************************************************************/ | |
| 6435 | +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => { | |
| 6436 | + | |
| 6437 | +"use strict"; | |
| 6438 | +__webpack_require__.r(__webpack_exports__); | |
| 6439 | +/* harmony export */ __webpack_require__.d(__webpack_exports__, { | |
| 6440 | +/* harmony export */ "default": () => (/* binding */ toPropertyKey) | |
| 6441 | +/* harmony export */ }); | |
| 6442 | +/* harmony import */ var _typeof_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./typeof.js */ "../node_modules/@babel/runtime/helpers/esm/typeof.js"); | |
| 6443 | +/* harmony import */ var _toPrimitive_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./toPrimitive.js */ "../node_modules/@babel/runtime/helpers/esm/toPrimitive.js"); | |
| 6444 | + | |
| 6445 | + | |
| 6446 | +function toPropertyKey(t) { | |
| 6447 | + var i = (0,_toPrimitive_js__WEBPACK_IMPORTED_MODULE_1__["default"])(t, "string"); | |
| 6448 | + return "symbol" == (0,_typeof_js__WEBPACK_IMPORTED_MODULE_0__["default"])(i) ? i : String(i); | |
| 6449 | +} | |
| 6450 | + | |
| 6451 | +/***/ }), | |
| 6452 | + | |
| 6453 | +/***/ "../node_modules/@babel/runtime/helpers/esm/typeof.js": | |
| 6454 | +/*!************************************************************!*\ | |
| 6455 | + !*** ../node_modules/@babel/runtime/helpers/esm/typeof.js ***! | |
| 6456 | + \************************************************************/ | |
| 6457 | +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => { | |
| 6458 | + | |
| 6459 | +"use strict"; | |
| 6460 | +__webpack_require__.r(__webpack_exports__); | |
| 6461 | +/* harmony export */ __webpack_require__.d(__webpack_exports__, { | |
| 6462 | +/* harmony export */ "default": () => (/* binding */ _typeof) | |
| 6463 | +/* harmony export */ }); | |
| 6464 | +function _typeof(o) { | |
| 6465 | + "@babel/helpers - typeof"; | |
| 6466 | + | |
| 6467 | + return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { | |
| 6468 | + return typeof o; | |
| 6469 | + } : function (o) { | |
| 6470 | + return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; | |
| 6471 | + }, _typeof(o); | |
| 6472 | +} | |
| 6473 | + | |
| 6474 | +/***/ }), | |
| 6475 | + | |
| 6476 | +/***/ "../node_modules/@reduxjs/toolkit/node_modules/immer/dist/immer.esm.mjs": | |
| 6477 | +/*!******************************************************************************!*\ | |
| 6478 | + !*** ../node_modules/@reduxjs/toolkit/node_modules/immer/dist/immer.esm.mjs ***! | |
| 6479 | + \******************************************************************************/ | |
| 6480 | +/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => { | |
| 6481 | + | |
| 6482 | +"use strict"; | |
| 6483 | +__webpack_require__.r(__webpack_exports__); | |
| 6484 | +/* harmony export */ __webpack_require__.d(__webpack_exports__, { | |
| 6485 | +/* harmony export */ Immer: () => (/* binding */ un), | |
| 6486 | +/* harmony export */ applyPatches: () => (/* binding */ pn), | |
| 6487 | +/* harmony export */ castDraft: () => (/* binding */ K), | |
| 6488 | +/* harmony export */ castImmutable: () => (/* binding */ $), | |
| 6489 | +/* harmony export */ createDraft: () => (/* binding */ ln), | |
| 6490 | +/* harmony export */ current: () => (/* binding */ R), | |
| 6491 | +/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__), | |
| 6492 | +/* harmony export */ enableAllPlugins: () => (/* binding */ J), | |
| 6493 | +/* harmony export */ enableES5: () => (/* binding */ F), | |
| 6494 | +/* harmony export */ enableMapSet: () => (/* binding */ C), | |
| 6495 | +/* harmony export */ enablePatches: () => (/* binding */ T), | |
| 6496 | +/* harmony export */ finishDraft: () => (/* binding */ dn), | |
| 6497 | +/* harmony export */ freeze: () => (/* binding */ d), | |
| 6498 | +/* harmony export */ immerable: () => (/* binding */ L), | |
| 6499 | +/* harmony export */ isDraft: () => (/* binding */ r), | |
| 6500 | +/* harmony export */ isDraftable: () => (/* binding */ t), | |
| 6501 | +/* harmony export */ nothing: () => (/* binding */ H), | |
| 6502 | +/* harmony export */ original: () => (/* binding */ e), | |
| 6503 | +/* harmony export */ produce: () => (/* binding */ fn), | |
| 6504 | +/* harmony export */ produceWithPatches: () => (/* binding */ cn), | |
| 6505 | +/* harmony export */ setAutoFreeze: () => (/* binding */ sn), | |
| 6506 | +/* harmony export */ setUseProxies: () => (/* binding */ vn) | |
| 6507 | +/* harmony export */ }); | |
| 6508 | +function n(n){for(var r=arguments.length,t=Array(r>1?r-1:0),e=1;e<r;e++)t[e-1]=arguments[e];if(true){var i=Y[n],o=i?"function"==typeof i?i.apply(null,t):i:"unknown error nr: "+n;throw Error("[Immer] "+o)}throw Error("[Immer] minified error nr: "+n+(t.length?" "+t.map((function(n){return"'"+n+"'"})).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function r(n){return!!n&&!!n[Q]}function t(n){var r;return!!n&&(function(n){if(!n||"object"!=typeof n)return!1;var r=Object.getPrototypeOf(n);if(null===r)return!0;var t=Object.hasOwnProperty.call(r,"constructor")&&r.constructor;return t===Object||"function"==typeof t&&Function.toString.call(t)===Z}(n)||Array.isArray(n)||!!n[L]||!!(null===(r=n.constructor)||void 0===r?void 0:r[L])||s(n)||v(n))}function e(t){return r(t)||n(23,t),t[Q].t}function i(n,r,t){void 0===t&&(t=!1),0===o(n)?(t?Object.keys:nn)(n).forEach((function(e){t&&"symbol"==typeof e||r(e,n[e],n)})):n.forEach((function(t,e){return r(e,t,n)}))}function o(n){var r=n[Q];return r?r.i>3?r.i-4:r.i:Array.isArray(n)?1:s(n)?2:v(n)?3:0}function u(n,r){return 2===o(n)?n.has(r):Object.prototype.hasOwnProperty.call(n,r)}function a(n,r){return 2===o(n)?n.get(r):n[r]}function f(n,r,t){var e=o(n);2===e?n.set(r,t):3===e?n.add(t):n[r]=t}function c(n,r){return n===r?0!==n||1/n==1/r:n!=n&&r!=r}function s(n){return X&&n instanceof Map}function v(n){return q&&n instanceof Set}function p(n){return n.o||n.t}function l(n){if(Array.isArray(n))return Array.prototype.slice.call(n);var r=rn(n);delete r[Q];for(var t=nn(r),e=0;e<t.length;e++){var i=t[e],o=r[i];!1===o.writable&&(o.writable=!0,o.configurable=!0),(o.get||o.set)&&(r[i]={configurable:!0,writable:!0,enumerable:o.enumerable,value:n[i]})}return Object.create(Object.getPrototypeOf(n),r)}function d(n,e){return void 0===e&&(e=!1),y(n)||r(n)||!t(n)||(o(n)>1&&(n.set=n.add=n.clear=n.delete=h),Object.freeze(n),e&&i(n,(function(n,r){return d(r,!0)}),!0)),n}function h(){n(2)}function y(n){return null==n||"object"!=typeof n||Object.isFrozen(n)}function b(r){var t=tn[r];return t||n(18,r),t}function m(n,r){tn[n]||(tn[n]=r)}function _(){return false||U||n(0),U}function j(n,r){r&&(b("Patches"),n.u=[],n.s=[],n.v=r)}function g(n){O(n),n.p.forEach(S),n.p=null}function O(n){n===U&&(U=n.l)}function w(n){return U={p:[],l:U,h:n,m:!0,_:0}}function S(n){var r=n[Q];0===r.i||1===r.i?r.j():r.g=!0}function P(r,e){e._=e.p.length;var i=e.p[0],o=void 0!==r&&r!==i;return e.h.O||b("ES5").S(e,r,o),o?(i[Q].P&&(g(e),n(4)),t(r)&&(r=M(e,r),e.l||x(e,r)),e.u&&b("Patches").M(i[Q].t,r,e.u,e.s)):r=M(e,i,[]),g(e),e.u&&e.v(e.u,e.s),r!==H?r:void 0}function M(n,r,t){if(y(r))return r;var e=r[Q];if(!e)return i(r,(function(i,o){return A(n,e,r,i,o,t)}),!0),r;if(e.A!==n)return r;if(!e.P)return x(n,e.t,!0),e.t;if(!e.I){e.I=!0,e.A._--;var o=4===e.i||5===e.i?e.o=l(e.k):e.o,u=o,a=!1;3===e.i&&(u=new Set(o),o.clear(),a=!0),i(u,(function(r,i){return A(n,e,o,r,i,t,a)})),x(n,o,!1),t&&n.u&&b("Patches").N(e,t,n.u,n.s)}return e.o}function A(e,i,o,a,c,s,v){if( true&&c===o&&n(5),r(c)){var p=M(e,c,s&&i&&3!==i.i&&!u(i.R,a)?s.concat(a):void 0);if(f(o,a,p),!r(p))return;e.m=!1}else v&&o.add(c);if(t(c)&&!y(c)){if(!e.h.D&&e._<1)return;M(e,c),i&&i.A.l||x(e,c)}}function x(n,r,t){void 0===t&&(t=!1),!n.l&&n.h.D&&n.m&&d(r,t)}function z(n,r){var t=n[Q];return(t?p(t):n)[r]}function I(n,r){if(r in n)for(var t=Object.getPrototypeOf(n);t;){var e=Object.getOwnPropertyDescriptor(t,r);if(e)return e;t=Object.getPrototypeOf(t)}}function k(n){n.P||(n.P=!0,n.l&&k(n.l))}function E(n){n.o||(n.o=l(n.t))}function N(n,r,t){var e=s(r)?b("MapSet").F(r,t):v(r)?b("MapSet").T(r,t):n.O?function(n,r){var t=Array.isArray(n),e={i:t?1:0,A:r?r.A:_(),P:!1,I:!1,R:{},l:r,t:n,k:null,o:null,j:null,C:!1},i=e,o=en;t&&(i=[e],o=on);var u=Proxy.revocable(i,o),a=u.revoke,f=u.proxy;return e.k=f,e.j=a,f}(r,t):b("ES5").J(r,t);return(t?t.A:_()).p.push(e),e}function R(e){return r(e)||n(22,e),function n(r){if(!t(r))return r;var e,u=r[Q],c=o(r);if(u){if(!u.P&&(u.i<4||!b("ES5").K(u)))return u.t;u.I=!0,e=D(r,c),u.I=!1}else e=D(r,c);return i(e,(function(r,t){u&&a(u.t,r)===t||f(e,r,n(t))})),3===c?new Set(e):e}(e)}function D(n,r){switch(r){case 2:return new Map(n);case 3:return Array.from(n)}return l(n)}function F(){function t(n,r){var t=s[n];return t?t.enumerable=r:s[n]=t={configurable:!0,enumerable:r,get:function(){var r=this[Q];return true&&f(r),en.get(r,n)},set:function(r){var t=this[Q]; true&&f(t),en.set(t,n,r)}},t}function e(n){for(var r=n.length-1;r>=0;r--){var t=n[r][Q];if(!t.P)switch(t.i){case 5:a(t)&&k(t);break;case 4:o(t)&&k(t)}}}function o(n){for(var r=n.t,t=n.k,e=nn(t),i=e.length-1;i>=0;i--){var o=e[i];if(o!==Q){var a=r[o];if(void 0===a&&!u(r,o))return!0;var f=t[o],s=f&&f[Q];if(s?s.t!==a:!c(f,a))return!0}}var v=!!r[Q];return e.length!==nn(r).length+(v?0:1)}function a(n){var r=n.k;if(r.length!==n.t.length)return!0;var t=Object.getOwnPropertyDescriptor(r,r.length-1);if(t&&!t.get)return!0;for(var e=0;e<r.length;e++)if(!r.hasOwnProperty(e))return!0;return!1}function f(r){r.g&&n(3,JSON.stringify(p(r)))}var s={};m("ES5",{J:function(n,r){var e=Array.isArray(n),i=function(n,r){if(n){for(var e=Array(r.length),i=0;i<r.length;i++)Object.defineProperty(e,""+i,t(i,!0));return e}var o=rn(r);delete o[Q];for(var u=nn(o),a=0;a<u.length;a++){var f=u[a];o[f]=t(f,n||!!o[f].enumerable)}return Object.create(Object.getPrototypeOf(r),o)}(e,n),o={i:e?5:4,A:r?r.A:_(),P:!1,I:!1,R:{},l:r,t:n,k:i,o:null,g:!1,C:!1};return Object.defineProperty(i,Q,{value:o,writable:!0}),i},S:function(n,t,o){o?r(t)&&t[Q].A===n&&e(n.p):(n.u&&function n(r){if(r&&"object"==typeof r){var t=r[Q];if(t){var e=t.t,o=t.k,f=t.R,c=t.i;if(4===c)i(o,(function(r){r!==Q&&(void 0!==e[r]||u(e,r)?f[r]||n(o[r]):(f[r]=!0,k(t)))})),i(e,(function(n){void 0!==o[n]||u(o,n)||(f[n]=!1,k(t))}));else if(5===c){if(a(t)&&(k(t),f.length=!0),o.length<e.length)for(var s=o.length;s<e.length;s++)f[s]=!1;else for(var v=e.length;v<o.length;v++)f[v]=!0;for(var p=Math.min(o.length,e.length),l=0;l<p;l++)o.hasOwnProperty(l)||(f[l]=!0),void 0===f[l]&&n(o[l])}}}}(n.p[0]),e(n.p))},K:function(n){return 4===n.i?o(n):a(n)}})}function T(){function e(n){if(!t(n))return n;if(Array.isArray(n))return n.map(e);if(s(n))return new Map(Array.from(n.entries()).map((function(n){return[n[0],e(n[1])]})));if(v(n))return new Set(Array.from(n).map(e));var r=Object.create(Object.getPrototypeOf(n));for(var i in n)r[i]=e(n[i]);return u(n,L)&&(r[L]=n[L]),r}function f(n){return r(n)?e(n):n}var c="add";m("Patches",{$:function(r,t){return t.forEach((function(t){for(var i=t.path,u=t.op,f=r,s=0;s<i.length-1;s++){var v=o(f),p=i[s];"string"!=typeof p&&"number"!=typeof p&&(p=""+p),0!==v&&1!==v||"__proto__"!==p&&"constructor"!==p||n(24),"function"==typeof f&&"prototype"===p&&n(24),"object"!=typeof(f=a(f,p))&&n(15,i.join("/"))}var l=o(f),d=e(t.value),h=i[i.length-1];switch(u){case"replace":switch(l){case 2:return f.set(h,d);case 3:n(16);default:return f[h]=d}case c:switch(l){case 1:return"-"===h?f.push(d):f.splice(h,0,d);case 2:return f.set(h,d);case 3:return f.add(d);default:return f[h]=d}case"remove":switch(l){case 1:return f.splice(h,1);case 2:return f.delete(h);case 3:return f.delete(t.value);default:return delete f[h]}default:n(17,u)}})),r},N:function(n,r,t,e){switch(n.i){case 0:case 4:case 2:return function(n,r,t,e){var o=n.t,s=n.o;i(n.R,(function(n,i){var v=a(o,n),p=a(s,n),l=i?u(o,n)?"replace":c:"remove";if(v!==p||"replace"!==l){var d=r.concat(n);t.push("remove"===l?{op:l,path:d}:{op:l,path:d,value:p}),e.push(l===c?{op:"remove",path:d}:"remove"===l?{op:c,path:d,value:f(v)}:{op:"replace",path:d,value:f(v)})}}))}(n,r,t,e);case 5:case 1:return function(n,r,t,e){var i=n.t,o=n.R,u=n.o;if(u.length<i.length){var a=[u,i];i=a[0],u=a[1];var s=[e,t];t=s[0],e=s[1]}for(var v=0;v<i.length;v++)if(o[v]&&u[v]!==i[v]){var p=r.concat([v]);t.push({op:"replace",path:p,value:f(u[v])}),e.push({op:"replace",path:p,value:f(i[v])})}for(var l=i.length;l<u.length;l++){var d=r.concat([l]);t.push({op:c,path:d,value:f(u[l])})}i.length<u.length&&e.push({op:"replace",path:r.concat(["length"]),value:i.length})}(n,r,t,e);case 3:return function(n,r,t,e){var i=n.t,o=n.o,u=0;i.forEach((function(n){if(!o.has(n)){var i=r.concat([u]);t.push({op:"remove",path:i,value:n}),e.unshift({op:c,path:i,value:n})}u++})),u=0,o.forEach((function(n){if(!i.has(n)){var o=r.concat([u]);t.push({op:c,path:o,value:n}),e.unshift({op:"remove",path:o,value:n})}u++}))}(n,r,t,e)}},M:function(n,r,t,e){t.push({op:"replace",path:[],value:r===H?void 0:r}),e.push({op:"replace",path:[],value:n})}})}function C(){function r(n,r){function t(){this.constructor=n}a(n,r),n.prototype=(t.prototype=r.prototype,new t)}function e(n){n.o||(n.R=new Map,n.o=new Map(n.t))}function o(n){n.o||(n.o=new Set,n.t.forEach((function(r){if(t(r)){var e=N(n.A.h,r,n);n.p.set(r,e),n.o.add(e)}else n.o.add(r)})))}function u(r){r.g&&n(3,JSON.stringify(p(r)))}var a=function(n,r){return(a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var t in r)r.hasOwnProperty(t)&&(n[t]=r[t])})(n,r)},f=function(){function n(n,r){return this[Q]={i:2,l:r,A:r?r.A:_(),P:!1,I:!1,o:void 0,R:void 0,t:n,k:this,C:!1,g:!1},this}r(n,Map);var o=n.prototype;return Object.defineProperty(o,"size",{get:function(){return p(this[Q]).size}}),o.has=function(n){return p(this[Q]).has(n)},o.set=function(n,r){var t=this[Q];return u(t),p(t).has(n)&&p(t).get(n)===r||(e(t),k(t),t.R.set(n,!0),t.o.set(n,r),t.R.set(n,!0)),this},o.delete=function(n){if(!this.has(n))return!1;var r=this[Q];return u(r),e(r),k(r),r.t.has(n)?r.R.set(n,!1):r.R.delete(n),r.o.delete(n),!0},o.clear=function(){var n=this[Q];u(n),p(n).size&&(e(n),k(n),n.R=new Map,i(n.t,(function(r){n.R.set(r,!1)})),n.o.clear())},o.forEach=function(n,r){var t=this;p(this[Q]).forEach((function(e,i){n.call(r,t.get(i),i,t)}))},o.get=function(n){var r=this[Q];u(r);var i=p(r).get(n);if(r.I||!t(i))return i;if(i!==r.t.get(n))return i;var o=N(r.A.h,i,r);return e(r),r.o.set(n,o),o},o.keys=function(){return p(this[Q]).keys()},o.values=function(){var n,r=this,t=this.keys();return(n={})[V]=function(){return r.values()},n.next=function(){var n=t.next();return n.done?n:{done:!1,value:r.get(n.value)}},n},o.entries=function(){var n,r=this,t=this.keys();return(n={})[V]=function(){return r.entries()},n.next=function(){var n=t.next();if(n.done)return n;var e=r.get(n.value);return{done:!1,value:[n.value,e]}},n},o[V]=function(){return this.entries()},n}(),c=function(){function n(n,r){return this[Q]={i:3,l:r,A:r?r.A:_(),P:!1,I:!1,o:void 0,t:n,k:this,p:new Map,g:!1,C:!1},this}r(n,Set);var t=n.prototype;return Object.defineProperty(t,"size",{get:function(){return p(this[Q]).size}}),t.has=function(n){var r=this[Q];return u(r),r.o?!!r.o.has(n)||!(!r.p.has(n)||!r.o.has(r.p.get(n))):r.t.has(n)},t.add=function(n){var r=this[Q];return u(r),this.has(n)||(o(r),k(r),r.o.add(n)),this},t.delete=function(n){if(!this.has(n))return!1;var r=this[Q];return u(r),o(r),k(r),r.o.delete(n)||!!r.p.has(n)&&r.o.delete(r.p.get(n))},t.clear=function(){var n=this[Q];u(n),p(n).size&&(o(n),k(n),n.o.clear())},t.values=function(){var n=this[Q];return u(n),o(n),n.o.values()},t.entries=function(){var n=this[Q];return u(n),o(n),n.o.entries()},t.keys=function(){return this.values()},t[V]=function(){return this.values()},t.forEach=function(n,r){for(var t=this.values(),e=t.next();!e.done;)n.call(r,e.value,e.value,this),e=t.next()},n}();m("MapSet",{F:function(n,r){return new f(n,r)},T:function(n,r){return new c(n,r)}})}function J(){F(),C(),T()}function K(n){return n}function $(n){return n}var G,U,W="undefined"!=typeof Symbol&&"symbol"==typeof Symbol("x"),X="undefined"!=typeof Map,q="undefined"!=typeof Set,B="undefined"!=typeof Proxy&&void 0!==Proxy.revocable&&"undefined"!=typeof Reflect,H=W?Symbol.for("immer-nothing"):((G={})["immer-nothing"]=!0,G),L=W?Symbol.for("immer-draftable"):"__$immer_draftable",Q=W?Symbol.for("immer-state"):"__$immer_state",V="undefined"!=typeof Symbol&&Symbol.iterator||"@@iterator",Y={0:"Illegal state",1:"Immer drafts cannot have computed properties",2:"This object has been frozen and should not be mutated",3:function(n){return"Cannot use a proxy that has been revoked. Did you pass an object from inside an immer function to an async process? "+n},4:"An immer producer returned a new value *and* modified its draft. Either return a new value *or* modify the draft.",5:"Immer forbids circular references",6:"The first or second argument to `produce` must be a function",7:"The third argument to `produce` must be a function or undefined",8:"First argument to `createDraft` must be a plain object, an array, or an immerable object",9:"First argument to `finishDraft` must be a draft returned by `createDraft`",10:"The given draft is already finalized",11:"Object.defineProperty() cannot be used on an Immer draft",12:"Object.setPrototypeOf() cannot be used on an Immer draft",13:"Immer only supports deleting array indices",14:"Immer only supports setting array indices and the 'length' property",15:function(n){return"Cannot apply patch, path doesn't resolve: "+n},16:'Sets cannot have "replace" patches.',17:function(n){return"Unsupported patch operation: "+n},18:function(n){return"The plugin for '"+n+"' has not been loaded into Immer. To enable the plugin, import and call `enable"+n+"()` when initializing your application."},20:"Cannot use proxies if Proxy, Proxy.revocable or Reflect are not available",21:function(n){return"produce can only be called on things that are draftable: plain objects, arrays, Map, Set or classes that are marked with '[immerable]: true'. Got '"+n+"'"},22:function(n){return"'current' expects a draft, got: "+n},23:function(n){return"'original' expects a draft, got: "+n},24:"Patching reserved attributes like __proto__, prototype and constructor is not allowed"},Z=""+Object.prototype.constructor,nn="undefined"!=typeof Reflect&&Reflect.ownKeys?Reflect.ownKeys:void 0!==Object.getOwnPropertySymbols?function(n){return Object.getOwnPropertyNames(n).concat(Object.getOwnPropertySymbols(n))}:Object.getOwnPropertyNames,rn=Object.getOwnPropertyDescriptors||function(n){var r={};return nn(n).forEach((function(t){r[t]=Object.getOwnPropertyDescriptor(n,t)})),r},tn={},en={get:function(n,r){if(r===Q)return n;var e=p(n);if(!u(e,r))return function(n,r,t){var e,i=I(r,t);return i?"value"in i?i.value:null===(e=i.get)||void 0===e?void 0:e.call(n.k):void 0}(n,e,r);var i=e[r];return n.I||!t(i)?i:i===z(n.t,r)?(E(n),n.o[r]=N(n.A.h,i,n)):i},has:function(n,r){return r in p(n)},ownKeys:function(n){return Reflect.ownKeys(p(n))},set:function(n,r,t){var e=I(p(n),r);if(null==e?void 0:e.set)return e.set.call(n.k,t),!0;if(!n.P){var i=z(p(n),r),o=null==i?void 0:i[Q];if(o&&o.t===t)return n.o[r]=t,n.R[r]=!1,!0;if(c(t,i)&&(void 0!==t||u(n.t,r)))return!0;E(n),k(n)}return n.o[r]===t&&(void 0!==t||r in n.o)||Number.isNaN(t)&&Number.isNaN(n.o[r])||(n.o[r]=t,n.R[r]=!0),!0},deleteProperty:function(n,r){return void 0!==z(n.t,r)||r in n.t?(n.R[r]=!1,E(n),k(n)):delete n.R[r],n.o&&delete n.o[r],!0},getOwnPropertyDescriptor:function(n,r){var t=p(n),e=Reflect.getOwnPropertyDescriptor(t,r);return e?{writable:!0,configurable:1!==n.i||"length"!==r,enumerable:e.enumerable,value:t[r]}:e},defineProperty:function(){n(11)},getPrototypeOf:function(n){return Object.getPrototypeOf(n.t)},setPrototypeOf:function(){n(12)}},on={};i(en,(function(n,r){on[n]=function(){return arguments[0]=arguments[0][0],r.apply(this,arguments)}})),on.deleteProperty=function(r,t){return true&&isNaN(parseInt(t))&&n(13),on.set.call(this,r,t,void 0)},on.set=function(r,t,e){return true&&"length"!==t&&isNaN(parseInt(t))&&n(14),en.set.call(this,r[0],t,e,r[0])};var un=function(){function e(r){var e=this;this.O=B,this.D=!0,this.produce=function(r,i,o){if("function"==typeof r&&"function"!=typeof i){var u=i;i=r;var a=e;return function(n){var r=this;void 0===n&&(n=u);for(var t=arguments.length,e=Array(t>1?t-1:0),o=1;o<t;o++)e[o-1]=arguments[o];return a.produce(n,(function(n){var t;return(t=i).call.apply(t,[r,n].concat(e))}))}}var f;if("function"!=typeof i&&n(6),void 0!==o&&"function"!=typeof o&&n(7),t(r)){var c=w(e),s=N(e,r,void 0),v=!0;try{f=i(s),v=!1}finally{v?g(c):O(c)}return"undefined"!=typeof Promise&&f instanceof Promise?f.then((function(n){return j(c,o),P(n,c)}),(function(n){throw g(c),n})):(j(c,o),P(f,c))}if(!r||"object"!=typeof r){if(void 0===(f=i(r))&&(f=r),f===H&&(f=void 0),e.D&&d(f,!0),o){var p=[],l=[];b("Patches").M(r,f,p,l),o(p,l)}return f}n(21,r)},this.produceWithPatches=function(n,r){if("function"==typeof n)return function(r){for(var t=arguments.length,i=Array(t>1?t-1:0),o=1;o<t;o++)i[o-1]=arguments[o];return e.produceWithPatches(r,(function(r){return n.apply(void 0,[r].concat(i))}))};var t,i,o=e.produce(n,r,(function(n,r){t=n,i=r}));return"undefined"!=typeof Promise&&o instanceof Promise?o.then((function(n){return[n,t,i]})):[o,t,i]},"boolean"==typeof(null==r?void 0:r.useProxies)&&this.setUseProxies(r.useProxies),"boolean"==typeof(null==r?void 0:r.autoFreeze)&&this.setAutoFreeze(r.autoFreeze)}var i=e.prototype;return i.createDraft=function(e){t(e)||n(8),r(e)&&(e=R(e));var i=w(this),o=N(this,e,void 0);return o[Q].C=!0,O(i),o},i.finishDraft=function(r,t){var e=r&&r[Q]; true&&(e&&e.C||n(9),e.I&&n(10));var i=e.A;return j(i,t),P(void 0,i)},i.setAutoFreeze=function(n){this.D=n},i.setUseProxies=function(r){r&&!B&&n(20),this.O=r},i.applyPatches=function(n,t){var e;for(e=t.length-1;e>=0;e--){var i=t[e];if(0===i.path.length&&"replace"===i.op){n=i.value;break}}e>-1&&(t=t.slice(e+1));var o=b("Patches").$;return r(n)?o(n,t):this.produce(n,(function(n){return o(n,t)}))},e}(),an=new un,fn=an.produce,cn=an.produceWithPatches.bind(an),sn=an.setAutoFreeze.bind(an),vn=an.setUseProxies.bind(an),pn=an.applyPatches.bind(an),ln=an.createDraft.bind(an),dn=an.finishDraft.bind(an);/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (fn); | |
| 6509 | +//# sourceMappingURL=immer.esm.js.map | |
| 6510 | + | |
| 6511 | + | |
| 3406 | 6512 | /***/ }) |
| 3407 | 6513 | |
| 3408 | 6514 | /******/ }); |
| 3409 | 6515 | /************************************************************************/ |
| @@ -3431,10 +6537,51 @@ | ||
| 3431 | 6537 | /******/ return module.exports; |
| 3432 | 6538 | /******/ } |
| 3433 | 6539 | /******/ |
| 3434 | 6540 | /************************************************************************/ |
| 6541 | +/******/ /* webpack/runtime/define property getters */ | |
| 6542 | +/******/ (() => { | |
| 6543 | +/******/ // define getter functions for harmony exports | |
| 6544 | +/******/ __webpack_require__.d = (exports, definition) => { | |
| 6545 | +/******/ for(var key in definition) { | |
| 6546 | +/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { | |
| 6547 | +/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); | |
| 6548 | +/******/ } | |
| 6549 | +/******/ } | |
| 6550 | +/******/ }; | |
| 6551 | +/******/ })(); | |
| 6552 | +/******/ | |
| 6553 | +/******/ /* webpack/runtime/global */ | |
| 6554 | +/******/ (() => { | |
| 6555 | +/******/ __webpack_require__.g = (function() { | |
| 6556 | +/******/ if (typeof globalThis === 'object') return globalThis; | |
| 6557 | +/******/ try { | |
| 6558 | +/******/ return this || new Function('return this')(); | |
| 6559 | +/******/ } catch (e) { | |
| 6560 | +/******/ if (typeof window === 'object') return window; | |
| 6561 | +/******/ } | |
| 6562 | +/******/ })(); | |
| 6563 | +/******/ })(); | |
| 6564 | +/******/ | |
| 6565 | +/******/ /* webpack/runtime/hasOwnProperty shorthand */ | |
| 6566 | +/******/ (() => { | |
| 6567 | +/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) | |
| 6568 | +/******/ })(); | |
| 6569 | +/******/ | |
| 6570 | +/******/ /* webpack/runtime/make namespace object */ | |
| 6571 | +/******/ (() => { | |
| 6572 | +/******/ // define __esModule on exports | |
| 6573 | +/******/ __webpack_require__.r = (exports) => { | |
| 6574 | +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { | |
| 6575 | +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); | |
| 6576 | +/******/ } | |
| 6577 | +/******/ Object.defineProperty(exports, '__esModule', { value: true }); | |
| 6578 | +/******/ }; | |
| 6579 | +/******/ })(); | |
| 6580 | +/******/ | |
| 6581 | +/************************************************************************/ | |
| 3435 | 6582 | var __webpack_exports__ = {}; |
| 3436 | -// This entry needs to be wrapped in an IIFE because it needs to be in strict mode. | |
| 6583 | +// This entry need to be wrapped in an IIFE because it need to be in strict mode. | |
| 3437 | 6584 | (() => { |
| 3438 | 6585 | "use strict"; |
| 3439 | 6586 | /*!*******************************************!*\ |
| 3440 | 6587 | !*** ../core/common/assets/js/modules.js ***! |