| @@ -1,459 +1,2778 @@ | ||
| 1 | -/******/ (() => { // webpackBootstrap | |
| 2 | -/******/ var __webpack_modules__ = ({ | |
| 1 | +(function(_wordpress_i18n, react) { | |
| 3 | 2 | |
| 4 | -/***/ "../assets/dev/js/utils/events.js": | |
| 5 | -/*!****************************************!*\ | |
| 6 | - !*** ../assets/dev/js/utils/events.js ***! | |
| 7 | - \****************************************/ | |
| 8 | -/***/ ((__unused_webpack_module, exports, __webpack_require__) => { | |
| 3 | +//#region \0rolldown/runtime.js | |
| 4 | + var __create = Object.create; | |
| 5 | + var __defProp = Object.defineProperty; | |
| 6 | + var __name = (target, value) => __defProp(target, "name", { | |
| 7 | + value, | |
| 8 | + configurable: true | |
| 9 | + }); | |
| 10 | + var __getOwnPropDesc = Object.getOwnPropertyDescriptor; | |
| 11 | + var __getOwnPropNames = Object.getOwnPropertyNames; | |
| 12 | + var __getProtoOf = Object.getPrototypeOf; | |
| 13 | + var __hasOwnProp = Object.prototype.hasOwnProperty; | |
| 14 | + var __esmMin = (fn, res, err) => () => { | |
| 15 | + if (err) throw err[0]; | |
| 16 | + try { | |
| 17 | + return fn && (res = fn(fn = 0)), res; | |
| 18 | + } catch (e) { | |
| 19 | + throw err = [e], e; | |
| 20 | + } | |
| 21 | + }; | |
| 22 | + var __commonJSMin = (cb, mod) => () => (mod || (cb((mod = { exports: {} }).exports, mod), cb = null), mod.exports); | |
| 23 | + var __exportAll = (all, no_symbols) => { | |
| 24 | + let target = {}; | |
| 25 | + for (var name in all) { | |
| 26 | + __defProp(target, name, { | |
| 27 | + get: all[name], | |
| 28 | + enumerable: true | |
| 29 | + }); | |
| 30 | + } | |
| 31 | + if (!no_symbols) { | |
| 32 | + __defProp(target, Symbol.toStringTag, { value: "Module" }); | |
| 33 | + } | |
| 34 | + return target; | |
| 35 | + }; | |
| 36 | + var __copyProps = (to, from, except, desc) => { | |
| 37 | + if (from && typeof from === "object" || typeof from === "function") { | |
| 38 | + for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) { | |
| 39 | + key = keys[i]; | |
| 40 | + if (!__hasOwnProp.call(to, key) && key !== except) { | |
| 41 | + __defProp(to, key, { | |
| 42 | + get: ((k) => from[k]).bind(null, key), | |
| 43 | + enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable | |
| 44 | + }); | |
| 45 | + } | |
| 46 | + } | |
| 47 | + } | |
| 48 | + return to; | |
| 49 | + }; | |
| 50 | + var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { | |
| 51 | + value: mod, | |
| 52 | + enumerable: true | |
| 53 | + }) : target, mod)); | |
| 9 | 54 | |
| 10 | -"use strict"; | |
| 55 | +//#endregion | |
| 56 | +react = __toESM(react); | |
| 11 | 57 | |
| 58 | +//#region node_modules/@babel/runtime/helpers/esm/classCallCheck.js | |
| 59 | + function _classCallCheck(a, n) { | |
| 60 | + if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); | |
| 61 | + } | |
| 62 | + var init_classCallCheck = __esmMin((() => {})); | |
| 12 | 63 | |
| 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["default"] = exports.Events = void 0; | |
| 18 | -var _classCallCheck2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/classCallCheck */ "../node_modules/@babel/runtime/helpers/classCallCheck.js")); | |
| 19 | -var _createClass2 = _interopRequireDefault(__webpack_require__(/*! @babel/runtime/helpers/createClass */ "../node_modules/@babel/runtime/helpers/createClass.js")); | |
| 20 | -var Events = exports.Events = /*#__PURE__*/function () { | |
| 21 | - function Events() { | |
| 22 | - (0, _classCallCheck2.default)(this, Events); | |
| 23 | - } | |
| 24 | - return (0, _createClass2.default)(Events, null, [{ | |
| 25 | - key: "dispatch", | |
| 26 | - value: | |
| 27 | - /** | |
| 28 | - * Dispatch an Elementor event. | |
| 29 | - * | |
| 30 | - * Will dispatch both native event & jQuery event (as BC). | |
| 31 | - * By default, `bcEvent` is `null`. | |
| 32 | - * | |
| 33 | - * @param {Object} context - The context that will dispatch the event. | |
| 34 | - * @param {string} event - Event to dispatch. | |
| 35 | - * @param {*} data - Data to pass to the event, default to `null`. | |
| 36 | - * @param {string|null} bcEvent - BC event to dispatch, default to `null`. | |
| 37 | - * | |
| 38 | - * @return {void} | |
| 39 | - */ | |
| 40 | - function dispatch(context, event) { | |
| 41 | - var data = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null; | |
| 42 | - var bcEvent = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : null; | |
| 43 | - // Make sure to use the native context if it's a jQuery instance. | |
| 44 | - context = context instanceof jQuery ? context[0] : context; | |
| 64 | +//#endregion | |
| 65 | +//#region node_modules/@babel/runtime/helpers/esm/typeof.js | |
| 66 | + function _typeof(o) { | |
| 67 | + "@babel/helpers - typeof"; | |
| 68 | + return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o) { | |
| 69 | + return typeof o; | |
| 70 | + } : function(o) { | |
| 71 | + return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; | |
| 72 | + }, _typeof(o); | |
| 73 | + } | |
| 74 | + var init_typeof = __esmMin((() => {})); | |
| 45 | 75 | |
| 46 | - // Dispatch the BC event only if exists. | |
| 47 | - if (bcEvent) { | |
| 48 | - context.dispatchEvent(new CustomEvent(bcEvent, { | |
| 49 | - detail: data | |
| 50 | - })); | |
| 51 | - } | |
| 76 | +//#endregion | |
| 77 | +//#region node_modules/@babel/runtime/helpers/esm/toPrimitive.js | |
| 78 | + function toPrimitive(t, r) { | |
| 79 | + if ("object" != _typeof(t) || !t) return t; | |
| 80 | + var e = t[Symbol.toPrimitive]; | |
| 81 | + if (void 0 !== e) { | |
| 82 | + var i = e.call(t, r || "default"); | |
| 83 | + if ("object" != _typeof(i)) return i; | |
| 84 | + throw new TypeError("@@toPrimitive must return a primitive value."); | |
| 85 | + } | |
| 86 | + return ("string" === r ? String : Number)(t); | |
| 87 | + } | |
| 88 | + var init_toPrimitive = __esmMin((() => { | |
| 89 | + init_typeof(); | |
| 90 | + })); | |
| 52 | 91 | |
| 53 | - // jQuery's `.on()` listens also to native custom events, so there is no need | |
| 54 | - // to dispatch also a jQuery event. | |
| 55 | - context.dispatchEvent(new CustomEvent(event, { | |
| 56 | - detail: data | |
| 57 | - })); | |
| 58 | - } | |
| 59 | - }]); | |
| 60 | -}(); | |
| 61 | -var _default = exports["default"] = Events; | |
| 92 | +//#endregion | |
| 93 | +//#region node_modules/@babel/runtime/helpers/esm/toPropertyKey.js | |
| 94 | + function toPropertyKey(t) { | |
| 95 | + var i = toPrimitive(t, "string"); | |
| 96 | + return "symbol" == _typeof(i) ? i : i + ""; | |
| 97 | + } | |
| 98 | + var init_toPropertyKey = __esmMin((() => { | |
| 99 | + init_typeof(); | |
| 100 | + init_toPrimitive(); | |
| 101 | + })); | |
| 62 | 102 | |
| 63 | -/***/ }), | |
| 103 | +//#endregion | |
| 104 | +//#region node_modules/@babel/runtime/helpers/esm/createClass.js | |
| 105 | + function _defineProperties(e, r) { | |
| 106 | + for (var t = 0; t < r.length; t++) { | |
| 107 | + var o = r[t]; | |
| 108 | + o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, toPropertyKey(o.key), o); | |
| 109 | + } | |
| 110 | + } | |
| 111 | + function _createClass(e, r, t) { | |
| 112 | + return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; | |
| 113 | + } | |
| 114 | + var init_createClass = __esmMin((() => { | |
| 115 | + init_toPropertyKey(); | |
| 116 | + })); | |
| 64 | 117 | |
| 65 | -/***/ "../node_modules/@babel/runtime/helpers/classCallCheck.js": | |
| 66 | -/*!****************************************************************!*\ | |
| 67 | - !*** ../node_modules/@babel/runtime/helpers/classCallCheck.js ***! | |
| 68 | - \****************************************************************/ | |
| 69 | -/***/ ((module) => { | |
| 118 | +//#endregion | |
| 119 | +//#region assets/dev/js/utils/events.js | |
| 120 | + init_classCallCheck(); | |
| 121 | + init_createClass(); | |
| 122 | + var Events = /*#__PURE__*/ function() { | |
| 123 | + function Events() { | |
| 124 | + _classCallCheck(this, Events); | |
| 125 | + } | |
| 126 | + return _createClass(Events, null, [{ | |
| 127 | + key: "dispatch", | |
| 128 | + value: function dispatch(context, event) { | |
| 129 | + var data = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : null; | |
| 130 | + var bcEvent = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : null; | |
| 131 | + context = context instanceof jQuery ? context[0] : context; | |
| 132 | + if (bcEvent) context.dispatchEvent(new CustomEvent(bcEvent, { detail: data })); | |
| 133 | + context.dispatchEvent(new CustomEvent(event, { detail: data })); | |
| 134 | + } | |
| 135 | + }]); | |
| 136 | + }(); | |
| 70 | 137 | |
| 71 | -function _classCallCheck(a, n) { | |
| 72 | - if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); | |
| 73 | -} | |
| 74 | -module.exports = _classCallCheck, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 138 | +//#endregion | |
| 139 | +//#region \0vite/preload-helper.js | |
| 140 | + var scriptRel = "modulepreload"; | |
| 141 | + var assetsURL = function(dep) { | |
| 142 | + return "/" + dep; | |
| 143 | + }; | |
| 144 | + var seen = {}; | |
| 145 | + var __vitePreload = function preload(baseModule, deps, importerUrl) { | |
| 146 | + let promise = Promise.resolve(); | |
| 147 | + if (false && deps && deps.length > 0) { | |
| 148 | + const links = document.getElementsByTagName("link"); | |
| 149 | + const cspNonceMeta = document.querySelector("meta[property=csp-nonce]"); | |
| 150 | + const cspNonce = (cspNonceMeta === null || cspNonceMeta === void 0 ? void 0 : cspNonceMeta.nonce) || (cspNonceMeta === null || cspNonceMeta === void 0 ? void 0 : cspNonceMeta.getAttribute("nonce")); | |
| 151 | + function allSettled(promises) { | |
| 152 | + return Promise.all(promises.map((p) => Promise.resolve(p).then((value) => ({ | |
| 153 | + status: "fulfilled", | |
| 154 | + value | |
| 155 | + }), (reason) => ({ | |
| 156 | + status: "rejected", | |
| 157 | + reason | |
| 158 | + })))); | |
| 159 | + } | |
| 160 | + function importMetaResolve(specifier) { | |
| 161 | + if ({}.resolve) return {}.resolve(specifier); | |
| 162 | + return new URL( | |
| 163 | + specifier, | |
| 164 | + /** #__KEEP__ */ | |
| 165 | + {}.url | |
| 166 | + ).href; | |
| 167 | + } | |
| 168 | + promise = allSettled(deps.map((dep) => { | |
| 169 | + dep = assetsURL(dep, importerUrl); | |
| 170 | + dep = importMetaResolve(dep); | |
| 171 | + if (dep in seen) return; | |
| 172 | + seen[dep] = true; | |
| 173 | + const isCss = dep.endsWith(".css"); | |
| 174 | + for (let i = links.length - 1; i >= 0; i--) { | |
| 175 | + const link = links[i]; | |
| 176 | + if (link.href === dep && (!isCss || link.rel === "stylesheet")) return; | |
| 177 | + } | |
| 178 | + const link = document.createElement("link"); | |
| 179 | + link.rel = isCss ? "stylesheet" : scriptRel; | |
| 180 | + if (!isCss) link.as = "script"; | |
| 181 | + link.crossOrigin = ""; | |
| 182 | + link.href = dep; | |
| 183 | + if (cspNonce) link.setAttribute("nonce", cspNonce); | |
| 184 | + document.head.appendChild(link); | |
| 185 | + if (isCss) return new Promise((res, rej) => { | |
| 186 | + link.addEventListener("load", res); | |
| 187 | + link.addEventListener("error", () => rej(/* @__PURE__ */ new Error(`Unable to preload CSS for ${dep}`))); | |
| 188 | + }); | |
| 189 | + })); | |
| 190 | + } | |
| 191 | + function handlePreloadError(err) { | |
| 192 | + const e = new Event("vite:preloadError", { cancelable: true }); | |
| 193 | + e.payload = err; | |
| 194 | + window.dispatchEvent(e); | |
| 195 | + if (!e.defaultPrevented) throw err; | |
| 196 | + } | |
| 197 | + return promise.then((res) => { | |
| 198 | + for (const item of res || []) { | |
| 199 | + if (item.status !== "rejected") continue; | |
| 200 | + handlePreloadError(item.reason); | |
| 201 | + } | |
| 202 | + return baseModule().catch(handlePreloadError); | |
| 203 | + }); | |
| 204 | + }; | |
| 75 | 205 | |
| 76 | -/***/ }), | |
| 206 | +//#endregion | |
| 207 | +//#region node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js | |
| 208 | + function _assertThisInitialized(e) { | |
| 209 | + if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); | |
| 210 | + return e; | |
| 211 | + } | |
| 212 | + var init_assertThisInitialized = __esmMin((() => {})); | |
| 77 | 213 | |
| 78 | -/***/ "../node_modules/@babel/runtime/helpers/createClass.js": | |
| 79 | -/*!*************************************************************!*\ | |
| 80 | - !*** ../node_modules/@babel/runtime/helpers/createClass.js ***! | |
| 81 | - \*************************************************************/ | |
| 82 | -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { | |
| 214 | +//#endregion | |
| 215 | +//#region node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js | |
| 216 | + function _possibleConstructorReturn(t, e) { | |
| 217 | + if (e && ("object" == _typeof(e) || "function" == typeof e)) return e; | |
| 218 | + if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined"); | |
| 219 | + return _assertThisInitialized(t); | |
| 220 | + } | |
| 221 | + var init_possibleConstructorReturn = __esmMin((() => { | |
| 222 | + init_typeof(); | |
| 223 | + init_assertThisInitialized(); | |
| 224 | + })); | |
| 83 | 225 | |
| 84 | -var toPropertyKey = __webpack_require__(/*! ./toPropertyKey.js */ "../node_modules/@babel/runtime/helpers/toPropertyKey.js"); | |
| 85 | -function _defineProperties(e, r) { | |
| 86 | - for (var t = 0; t < r.length; t++) { | |
| 87 | - var o = r[t]; | |
| 88 | - o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, toPropertyKey(o.key), o); | |
| 89 | - } | |
| 90 | -} | |
| 91 | -function _createClass(e, r, t) { | |
| 92 | - return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { | |
| 93 | - writable: !1 | |
| 94 | - }), e; | |
| 95 | -} | |
| 96 | -module.exports = _createClass, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 226 | +//#endregion | |
| 227 | +//#region node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js | |
| 228 | + function _getPrototypeOf(t) { | |
| 229 | + return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(t) { | |
| 230 | + return t.__proto__ || Object.getPrototypeOf(t); | |
| 231 | + }, _getPrototypeOf(t); | |
| 232 | + } | |
| 233 | + var init_getPrototypeOf = __esmMin((() => {})); | |
| 97 | 234 | |
| 98 | -/***/ }), | |
| 235 | +//#endregion | |
| 236 | +//#region node_modules/@babel/runtime/helpers/esm/superPropBase.js | |
| 237 | + function _superPropBase(t, o) { | |
| 238 | + for (; !{}.hasOwnProperty.call(t, o) && null !== (t = _getPrototypeOf(t));); | |
| 239 | + return t; | |
| 240 | + } | |
| 241 | + var init_superPropBase = __esmMin((() => { | |
| 242 | + init_getPrototypeOf(); | |
| 243 | + })); | |
| 99 | 244 | |
| 100 | -/***/ "../node_modules/@babel/runtime/helpers/interopRequireDefault.js": | |
| 101 | -/*!***********************************************************************!*\ | |
| 102 | - !*** ../node_modules/@babel/runtime/helpers/interopRequireDefault.js ***! | |
| 103 | - \***********************************************************************/ | |
| 104 | -/***/ ((module) => { | |
| 245 | +//#endregion | |
| 246 | +//#region node_modules/@babel/runtime/helpers/esm/get.js | |
| 247 | + function _get() { | |
| 248 | + return _get = "undefined" != typeof Reflect && Reflect.get ? Reflect.get.bind() : function(e, t, r) { | |
| 249 | + var p = _superPropBase(e, t); | |
| 250 | + if (p) { | |
| 251 | + var n = Object.getOwnPropertyDescriptor(p, t); | |
| 252 | + return n.get ? n.get.call(arguments.length < 3 ? e : r) : n.value; | |
| 253 | + } | |
| 254 | + }, _get.apply(null, arguments); | |
| 255 | + } | |
| 256 | + var init_get = __esmMin((() => { | |
| 257 | + init_superPropBase(); | |
| 258 | + })); | |
| 105 | 259 | |
| 106 | -function _interopRequireDefault(e) { | |
| 107 | - return e && e.__esModule ? e : { | |
| 108 | - "default": e | |
| 109 | - }; | |
| 110 | -} | |
| 111 | -module.exports = _interopRequireDefault, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 260 | +//#endregion | |
| 261 | +//#region node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js | |
| 262 | + function _setPrototypeOf(t, e) { | |
| 263 | + return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(t, e) { | |
| 264 | + return t.__proto__ = e, t; | |
| 265 | + }, _setPrototypeOf(t, e); | |
| 266 | + } | |
| 267 | + var init_setPrototypeOf = __esmMin((() => {})); | |
| 112 | 268 | |
| 113 | -/***/ }), | |
| 269 | +//#endregion | |
| 270 | +//#region node_modules/@babel/runtime/helpers/esm/inherits.js | |
| 271 | + function _inherits(t, e) { | |
| 272 | + if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function"); | |
| 273 | + t.prototype = Object.create(e && e.prototype, { constructor: { | |
| 274 | + value: t, | |
| 275 | + writable: !0, | |
| 276 | + configurable: !0 | |
| 277 | + } }), Object.defineProperty(t, "prototype", { writable: !1 }), e && _setPrototypeOf(t, e); | |
| 278 | + } | |
| 279 | + var init_inherits = __esmMin((() => { | |
| 280 | + init_setPrototypeOf(); | |
| 281 | + })); | |
| 114 | 282 | |
| 115 | -/***/ "../node_modules/@babel/runtime/helpers/toPrimitive.js": | |
| 116 | -/*!*************************************************************!*\ | |
| 117 | - !*** ../node_modules/@babel/runtime/helpers/toPrimitive.js ***! | |
| 118 | - \*************************************************************/ | |
| 119 | -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { | |
| 283 | +//#endregion | |
| 284 | +//#region node_modules/@babel/runtime/helpers/esm/defineProperty.js | |
| 285 | + function _defineProperty(e, r, t) { | |
| 286 | + return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, { | |
| 287 | + value: t, | |
| 288 | + enumerable: !0, | |
| 289 | + configurable: !0, | |
| 290 | + writable: !0 | |
| 291 | + }) : e[r] = t, e; | |
| 292 | + } | |
| 293 | + var init_defineProperty = __esmMin((() => { | |
| 294 | + init_toPropertyKey(); | |
| 295 | + })); | |
| 120 | 296 | |
| 121 | -var _typeof = (__webpack_require__(/*! ./typeof.js */ "../node_modules/@babel/runtime/helpers/typeof.js")["default"]); | |
| 122 | -function toPrimitive(t, r) { | |
| 123 | - if ("object" != _typeof(t) || !t) return t; | |
| 124 | - var e = t[Symbol.toPrimitive]; | |
| 125 | - if (void 0 !== e) { | |
| 126 | - var i = e.call(t, r || "default"); | |
| 127 | - if ("object" != _typeof(i)) return i; | |
| 128 | - throw new TypeError("@@toPrimitive must return a primitive value."); | |
| 129 | - } | |
| 130 | - return ("string" === r ? String : Number)(t); | |
| 131 | -} | |
| 132 | -module.exports = toPrimitive, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 297 | +//#endregion | |
| 298 | +//#region modules/nested-elements/assets/js/editor/utils.js | |
| 299 | + function extractNestedItemTitle(container, index) { | |
| 300 | + var title = container.view.model.config.defaults.elements_title; | |
| 301 | + return (0, _wordpress_i18n.sprintf)(title, index); | |
| 302 | + } | |
| 303 | + function isWidgetSupportNesting(widgetType) { | |
| 304 | + var widgetConfig = elementor.widgetsCache[widgetType]; | |
| 305 | + if (!widgetConfig) return false; | |
| 306 | + return widgetConfig.support_nesting; | |
| 307 | + } | |
| 308 | + function isWidgetSupportAtomicRepeaters(widgetType) { | |
| 309 | + var widgetConfig = elementor.widgetsCache[widgetType]; | |
| 310 | + if (!widgetConfig) return false; | |
| 311 | + return widgetConfig.support_improved_repeaters; | |
| 312 | + } | |
| 313 | + function findChildContainerOrFail(container, index) { | |
| 314 | + var childView = container.view.children.findByIndex(index); | |
| 315 | + if (!childView) throw new Error("Child container was not found for the current repeater item."); | |
| 316 | + return childView.getContainer(); | |
| 317 | + } | |
| 318 | + function shouldUseAtomicRepeaters(widgetType) { | |
| 319 | + return isWidgetSupportNesting(widgetType) && isWidgetSupportAtomicRepeaters(widgetType); | |
| 320 | + } | |
| 321 | + function sortViewsByModels(container) { | |
| 322 | + var models = container.model.get("elements").models; | |
| 323 | + var children = container.view.children; | |
| 324 | + var updatedViews = {}; | |
| 325 | + models.forEach(function(model, index) { | |
| 326 | + var view = children.findByModel(model); | |
| 327 | + view._index = index; | |
| 328 | + updatedViews[view.cid] = view; | |
| 329 | + }); | |
| 330 | + return updatedViews; | |
| 331 | + } | |
| 332 | + var init_utils = __esmMin((() => {})); | |
| 133 | 333 | |
| 134 | -/***/ }), | |
| 334 | +//#endregion | |
| 335 | +//#region modules/nested-elements/assets/js/editor/nested-repeater/models/nested-model-base.js | |
| 336 | + function _callSuper$12(t, o, e) { | |
| 337 | + return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$12() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); | |
| 338 | + } | |
| 339 | + function _isNativeReflectConstruct$12() { | |
| 340 | + try { | |
| 341 | + var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {})); | |
| 342 | + } catch (t) {} | |
| 343 | + return (_isNativeReflectConstruct$12 = function _isNativeReflectConstruct() { | |
| 344 | + return !!t; | |
| 345 | + })(); | |
| 346 | + } | |
| 347 | + function _superPropGet$7(t, o, e, r) { | |
| 348 | + var p = _get(_getPrototypeOf(1 & r ? t.prototype : t), o, e); | |
| 349 | + return 2 & r && "function" == typeof p ? function(t) { | |
| 350 | + return p.apply(e, t); | |
| 351 | + } : p; | |
| 352 | + } | |
| 353 | + var NestedModelBase; | |
| 354 | + var init_nested_model_base = __esmMin((() => { | |
| 355 | + init_classCallCheck(); | |
| 356 | + init_createClass(); | |
| 357 | + init_possibleConstructorReturn(); | |
| 358 | + init_getPrototypeOf(); | |
| 359 | + init_get(); | |
| 360 | + init_inherits(); | |
| 361 | + init_utils(); | |
| 362 | + __name(_callSuper$12, "_callSuper"); | |
| 363 | + __name(_isNativeReflectConstruct$12, "_isNativeReflectConstruct"); | |
| 364 | + __name(_superPropGet$7, "_superPropGet"); | |
| 365 | + NestedModelBase = /*#__PURE__*/ function(_elementor$modules$el) { | |
| 366 | + function NestedModelBase() { | |
| 367 | + _classCallCheck(this, NestedModelBase); | |
| 368 | + return _callSuper$12(this, NestedModelBase, arguments); | |
| 369 | + } | |
| 370 | + _inherits(NestedModelBase, _elementor$modules$el); | |
| 371 | + return _createClass(NestedModelBase, [ | |
| 372 | + { | |
| 373 | + key: "initialize", | |
| 374 | + value: function initialize(options) { | |
| 375 | + this.config = elementor.widgetsCache[options.widgetType]; | |
| 376 | + this.set("supportRepeaterChildren", true); | |
| 377 | + if (0 === this.get("elements").length && $e.commands.currentTrace.includes("document/elements/create")) this.onElementCreate(); | |
| 378 | + _superPropGet$7(NestedModelBase, "initialize", this, 3)([options]); | |
| 379 | + } | |
| 380 | + }, | |
| 381 | + { | |
| 382 | + key: "isValidChild", | |
| 383 | + value: function isValidChild(childModel) { | |
| 384 | + var parentElType = this.get("elType"); | |
| 385 | + return "container" === childModel.get("elType") && "widget" === parentElType && isWidgetSupportNesting(this.get("widgetType")) && childModel.get("isLocked"); | |
| 386 | + } | |
| 387 | + }, | |
| 388 | + { | |
| 389 | + key: "getDefaultChildren", | |
| 390 | + value: function getDefaultChildren() { | |
| 391 | + var defaults = this.config.defaults; | |
| 392 | + var result = []; | |
| 393 | + defaults.elements.forEach(function(element) { | |
| 394 | + element.id = elementorCommon.helpers.getUniqueId(); | |
| 395 | + element.settings = element.settings || {}; | |
| 396 | + element.elements = element.elements || []; | |
| 397 | + element.isLocked = true; | |
| 398 | + result.push(element); | |
| 399 | + }); | |
| 400 | + return result; | |
| 401 | + } | |
| 402 | + }, | |
| 403 | + { | |
| 404 | + key: "onElementCreate", | |
| 405 | + value: function onElementCreate() { | |
| 406 | + this.set("elements", this.getDefaultChildren()); | |
| 407 | + } | |
| 408 | + } | |
| 409 | + ]); | |
| 410 | + }(elementor.modules.elements.models.Element); | |
| 411 | + })); | |
| 135 | 412 | |
| 136 | -/***/ "../node_modules/@babel/runtime/helpers/toPropertyKey.js": | |
| 137 | -/*!***************************************************************!*\ | |
| 138 | - !*** ../node_modules/@babel/runtime/helpers/toPropertyKey.js ***! | |
| 139 | - \***************************************************************/ | |
| 140 | -/***/ ((module, __unused_webpack_exports, __webpack_require__) => { | |
| 413 | +//#endregion | |
| 414 | +//#region modules/nested-elements/assets/js/editor/nested-repeater/views/nested-view-base.js | |
| 415 | + function _callSuper$11(t, o, e) { | |
| 416 | + return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$11() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); | |
| 417 | + } | |
| 418 | + function _isNativeReflectConstruct$11() { | |
| 419 | + try { | |
| 420 | + var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {})); | |
| 421 | + } catch (t) {} | |
| 422 | + return (_isNativeReflectConstruct$11 = function _isNativeReflectConstruct() { | |
| 423 | + return !!t; | |
| 424 | + })(); | |
| 425 | + } | |
| 426 | + function _superPropGet$6(t, o, e, r) { | |
| 427 | + var p = _get(_getPrototypeOf(1 & r ? t.prototype : t), o, e); | |
| 428 | + return 2 & r && "function" == typeof p ? function(t) { | |
| 429 | + return p.apply(e, t); | |
| 430 | + } : p; | |
| 431 | + } | |
| 432 | + var NestedViewBase; | |
| 433 | + var init_nested_view_base = __esmMin((() => { | |
| 434 | + init_classCallCheck(); | |
| 435 | + init_createClass(); | |
| 436 | + init_possibleConstructorReturn(); | |
| 437 | + init_getPrototypeOf(); | |
| 438 | + init_get(); | |
| 439 | + init_inherits(); | |
| 440 | + __name(_callSuper$11, "_callSuper"); | |
| 441 | + __name(_isNativeReflectConstruct$11, "_isNativeReflectConstruct"); | |
| 442 | + __name(_superPropGet$6, "_superPropGet"); | |
| 443 | + NestedViewBase = /*#__PURE__*/ function(_elementor$modules$el) { | |
| 444 | + function NestedViewBase() { | |
| 445 | + _classCallCheck(this, NestedViewBase); | |
| 446 | + return _callSuper$11(this, NestedViewBase, arguments); | |
| 447 | + } | |
| 448 | + _inherits(NestedViewBase, _elementor$modules$el); | |
| 449 | + return _createClass(NestedViewBase, [ | |
| 450 | + { | |
| 451 | + key: "getChildViewContainer", | |
| 452 | + value: function getChildViewContainer(containerView, childView) { | |
| 453 | + var _this$model$config$de = this.model.config.defaults; | |
| 454 | + var customSelector = _this$model$config$de.elements_placeholder_selector; | |
| 455 | + var childContainerSelector = _this$model$config$de.child_container_placeholder_selector; | |
| 456 | + if (childView !== void 0 && childView._index !== void 0 && childContainerSelector) return containerView.$el.find("".concat(childContainerSelector, ":nth-child(").concat(childView._index + 1, ")")); | |
| 457 | + if (customSelector) return containerView.$el.find(this.model.config.defaults.elements_placeholder_selector); | |
| 458 | + return _superPropGet$6(NestedViewBase, "getChildViewContainer", this, 3)([containerView, childView]); | |
| 459 | + } | |
| 460 | + }, | |
| 461 | + { | |
| 462 | + key: "getChildType", | |
| 463 | + value: function getChildType() { | |
| 464 | + return ["container"]; | |
| 465 | + } | |
| 466 | + }, | |
| 467 | + { | |
| 468 | + key: "onRender", | |
| 469 | + value: function onRender() { | |
| 470 | + _superPropGet$6(NestedViewBase, "onRender", this, 3)([]); | |
| 471 | + this.normalizeAttributes(); | |
| 472 | + } | |
| 473 | + } | |
| 474 | + ]); | |
| 475 | + }(elementor.modules.elements.views.BaseWidget); | |
| 476 | + })); | |
| 141 | 477 | |
| 142 | -var _typeof = (__webpack_require__(/*! ./typeof.js */ "../node_modules/@babel/runtime/helpers/typeof.js")["default"]); | |
| 143 | -var toPrimitive = __webpack_require__(/*! ./toPrimitive.js */ "../node_modules/@babel/runtime/helpers/toPrimitive.js"); | |
| 144 | -function toPropertyKey(t) { | |
| 145 | - var i = toPrimitive(t, "string"); | |
| 146 | - return "symbol" == _typeof(i) ? i : i + ""; | |
| 147 | -} | |
| 148 | -module.exports = toPropertyKey, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 478 | +//#endregion | |
| 479 | +//#region modules/nested-elements/assets/js/editor/nested-repeater/controls/repeater.js | |
| 480 | + function _callSuper$10(t, o, e) { | |
| 481 | + return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$10() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); | |
| 482 | + } | |
| 483 | + function _isNativeReflectConstruct$10() { | |
| 484 | + try { | |
| 485 | + var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {})); | |
| 486 | + } catch (t) {} | |
| 487 | + return (_isNativeReflectConstruct$10 = function _isNativeReflectConstruct() { | |
| 488 | + return !!t; | |
| 489 | + })(); | |
| 490 | + } | |
| 491 | + function _superPropGet$5(t, o, e, r) { | |
| 492 | + var p = _get(_getPrototypeOf(1 & r ? t.prototype : t), o, e); | |
| 493 | + return 2 & r && "function" == typeof p ? function(t) { | |
| 494 | + return p.apply(e, t); | |
| 495 | + } : p; | |
| 496 | + } | |
| 497 | + var Repeater; | |
| 498 | + var init_repeater = __esmMin((() => { | |
| 499 | + init_defineProperty(); | |
| 500 | + init_classCallCheck(); | |
| 501 | + init_createClass(); | |
| 502 | + init_possibleConstructorReturn(); | |
| 503 | + init_getPrototypeOf(); | |
| 504 | + init_get(); | |
| 505 | + init_inherits(); | |
| 506 | + init_utils(); | |
| 507 | + __name(_callSuper$10, "_callSuper"); | |
| 508 | + __name(_isNativeReflectConstruct$10, "_isNativeReflectConstruct"); | |
| 509 | + __name(_superPropGet$5, "_superPropGet"); | |
| 510 | + Repeater = /*#__PURE__*/ function(_elementor$modules$co) { | |
| 511 | + function Repeater() { | |
| 512 | + _classCallCheck(this, Repeater); | |
| 513 | + return _callSuper$10(this, Repeater, arguments); | |
| 514 | + } | |
| 515 | + _inherits(Repeater, _elementor$modules$co); | |
| 516 | + return _createClass(Repeater, [ | |
| 517 | + { | |
| 518 | + key: "className", | |
| 519 | + value: function className() { | |
| 520 | + return _superPropGet$5(Repeater, "className", this, 3)([]).replace("nested-elements-repeater", "repeater"); | |
| 521 | + } | |
| 522 | + }, | |
| 523 | + { | |
| 524 | + key: "getDefaults", | |
| 525 | + value: function getDefaults() { | |
| 526 | + var widgetContainer = this.options.container; | |
| 527 | + var defaults = widgetContainer.model.config.defaults; | |
| 528 | + var index = widgetContainer.children.length + 1; | |
| 529 | + return _defineProperty({ _id: "" }, defaults.repeater_title_setting, extractNestedItemTitle(widgetContainer, index)); | |
| 530 | + } | |
| 531 | + }, | |
| 532 | + { | |
| 533 | + key: "onChildviewClickDuplicate", | |
| 534 | + value: function onChildviewClickDuplicate(childView) { | |
| 535 | + $e.run("document/repeater/duplicate", { | |
| 536 | + container: this.options.container, | |
| 537 | + name: this.model.get("name"), | |
| 538 | + index: childView._index | |
| 539 | + }); | |
| 540 | + this.toggleMinRowsClass(); | |
| 541 | + } | |
| 542 | + }, | |
| 543 | + { | |
| 544 | + key: "updateActiveRow", | |
| 545 | + value: function updateActiveRow() { | |
| 546 | + if (!this.currentEditableChild) return; | |
| 547 | + $e.run("document/repeater/select", { | |
| 548 | + container: this.container, | |
| 549 | + index: this.currentEditableChild.itemIndex, | |
| 550 | + options: { useHistory: false } | |
| 551 | + }); | |
| 552 | + } | |
| 553 | + } | |
| 554 | + ]); | |
| 555 | + }(elementor.modules.controls.Repeater); | |
| 556 | + })); | |
| 149 | 557 | |
| 150 | -/***/ }), | |
| 558 | +//#endregion | |
| 559 | +//#region modules/nested-elements/assets/js/editor/nested-repeater/hooks/data/base.js | |
| 560 | + function _callSuper$9(t, o, e) { | |
| 561 | + return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$9() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); | |
| 562 | + } | |
| 563 | + function _isNativeReflectConstruct$9() { | |
| 564 | + try { | |
| 565 | + var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {})); | |
| 566 | + } catch (t) {} | |
| 567 | + return (_isNativeReflectConstruct$9 = function _isNativeReflectConstruct() { | |
| 568 | + return !!t; | |
| 569 | + })(); | |
| 570 | + } | |
| 571 | + var Base; | |
| 572 | + var init_base = __esmMin((() => { | |
| 573 | + init_classCallCheck(); | |
| 574 | + init_createClass(); | |
| 575 | + init_possibleConstructorReturn(); | |
| 576 | + init_getPrototypeOf(); | |
| 577 | + init_inherits(); | |
| 578 | + init_utils(); | |
| 579 | + __name(_callSuper$9, "_callSuper"); | |
| 580 | + __name(_isNativeReflectConstruct$9, "_isNativeReflectConstruct"); | |
| 581 | + Base = /*#__PURE__*/ function(_$e$modules$hookData$) { | |
| 582 | + function Base() { | |
| 583 | + _classCallCheck(this, Base); | |
| 584 | + return _callSuper$9(this, Base, arguments); | |
| 585 | + } | |
| 586 | + _inherits(Base, _$e$modules$hookData$); | |
| 587 | + return _createClass(Base, [{ | |
| 588 | + key: "getContainerType", | |
| 589 | + value: function getContainerType() { | |
| 590 | + return "widget"; | |
| 591 | + } | |
| 592 | + }, { | |
| 593 | + key: "getConditions", | |
| 594 | + value: function getConditions(args) { | |
| 595 | + return isWidgetSupportNesting(args.container.model.get("widgetType")); | |
| 596 | + } | |
| 597 | + }]); | |
| 598 | + }($e.modules.hookData.After); | |
| 599 | + })); | |
| 151 | 600 | |
| 152 | -/***/ "../node_modules/@babel/runtime/helpers/typeof.js": | |
| 153 | -/*!********************************************************!*\ | |
| 154 | - !*** ../node_modules/@babel/runtime/helpers/typeof.js ***! | |
| 155 | - \********************************************************/ | |
| 156 | -/***/ ((module) => { | |
| 601 | +//#endregion | |
| 602 | +//#region modules/nested-elements/assets/js/editor/nested-repeater/hooks/data/document/repeater/insert/nested-repeater-create-container.js | |
| 603 | + function _callSuper$8(t, o, e) { | |
| 604 | + return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$8() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); | |
| 605 | + } | |
| 606 | + function _isNativeReflectConstruct$8() { | |
| 607 | + try { | |
| 608 | + var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {})); | |
| 609 | + } catch (t) {} | |
| 610 | + return (_isNativeReflectConstruct$8 = function _isNativeReflectConstruct() { | |
| 611 | + return !!t; | |
| 612 | + })(); | |
| 613 | + } | |
| 614 | + function _superPropGet$4(t, o, e, r) { | |
| 615 | + var p = _get(_getPrototypeOf(1 & r ? t.prototype : t), o, e); | |
| 616 | + return 2 & r && "function" == typeof p ? function(t) { | |
| 617 | + return p.apply(e, t); | |
| 618 | + } : p; | |
| 619 | + } | |
| 620 | + var NestedRepeaterCreateContainer; | |
| 621 | + var init_nested_repeater_create_container = __esmMin((() => { | |
| 622 | + init_classCallCheck(); | |
| 623 | + init_createClass(); | |
| 624 | + init_possibleConstructorReturn(); | |
| 625 | + init_getPrototypeOf(); | |
| 626 | + init_get(); | |
| 627 | + init_inherits(); | |
| 628 | + init_base(); | |
| 629 | + init_utils(); | |
| 630 | + __name(_callSuper$8, "_callSuper"); | |
| 631 | + __name(_isNativeReflectConstruct$8, "_isNativeReflectConstruct"); | |
| 632 | + __name(_superPropGet$4, "_superPropGet"); | |
| 633 | + NestedRepeaterCreateContainer = /*#__PURE__*/ function(_Base) { | |
| 634 | + function NestedRepeaterCreateContainer() { | |
| 635 | + _classCallCheck(this, NestedRepeaterCreateContainer); | |
| 636 | + return _callSuper$8(this, NestedRepeaterCreateContainer, arguments); | |
| 637 | + } | |
| 638 | + _inherits(NestedRepeaterCreateContainer, _Base); | |
| 639 | + return _createClass(NestedRepeaterCreateContainer, [ | |
| 640 | + { | |
| 641 | + key: "getId", | |
| 642 | + value: function getId() { | |
| 643 | + return "document/repeater/insert--nested-repeater-create-container"; | |
| 644 | + } | |
| 645 | + }, | |
| 646 | + { | |
| 647 | + key: "getCommand", | |
| 648 | + value: function getCommand() { | |
| 649 | + return "document/repeater/insert"; | |
| 650 | + } | |
| 651 | + }, | |
| 652 | + { | |
| 653 | + key: "getConditions", | |
| 654 | + value: function getConditions(args) { | |
| 655 | + var isCommandCalledDirectly = $e.commands.isCurrentFirstTrace(this.getCommand()); | |
| 656 | + return _superPropGet$4(NestedRepeaterCreateContainer, "getConditions", this, 3)([args]) && isCommandCalledDirectly; | |
| 657 | + } | |
| 658 | + }, | |
| 659 | + { | |
| 660 | + key: "apply", | |
| 661 | + value: function apply(_ref) { | |
| 662 | + var container = _ref.container; | |
| 663 | + var name = _ref.name; | |
| 664 | + var index = container.repeaters[name].children.length; | |
| 665 | + $e.run("document/elements/create", { | |
| 666 | + container, | |
| 667 | + model: { | |
| 668 | + elType: "container", | |
| 669 | + isLocked: true, | |
| 670 | + _title: extractNestedItemTitle(container, index) | |
| 671 | + }, | |
| 672 | + options: { edit: false } | |
| 673 | + }); | |
| 674 | + if (shouldUseAtomicRepeaters(container.settings.get("widgetType"))) elementor.$preview[0].contentWindow.dispatchEvent(new CustomEvent("elementor/nested-container/atomic-repeater", { detail: { | |
| 675 | + container, | |
| 676 | + action: { type: "create" } | |
| 677 | + } })); | |
| 678 | + } | |
| 679 | + } | |
| 680 | + ]); | |
| 681 | + }(Base); | |
| 682 | + })); | |
| 157 | 683 | |
| 158 | -function _typeof(o) { | |
| 159 | - "@babel/helpers - typeof"; | |
| 684 | +//#endregion | |
| 685 | +//#region modules/nested-elements/assets/js/editor/nested-repeater/hooks/data/document/repeater/remove/nested-repeater-remove-container.js | |
| 686 | + function _callSuper$7(t, o, e) { | |
| 687 | + return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$7() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); | |
| 688 | + } | |
| 689 | + function _isNativeReflectConstruct$7() { | |
| 690 | + try { | |
| 691 | + var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {})); | |
| 692 | + } catch (t) {} | |
| 693 | + return (_isNativeReflectConstruct$7 = function _isNativeReflectConstruct() { | |
| 694 | + return !!t; | |
| 695 | + })(); | |
| 696 | + } | |
| 697 | + function _superPropGet$3(t, o, e, r) { | |
| 698 | + var p = _get(_getPrototypeOf(1 & r ? t.prototype : t), o, e); | |
| 699 | + return 2 & r && "function" == typeof p ? function(t) { | |
| 700 | + return p.apply(e, t); | |
| 701 | + } : p; | |
| 702 | + } | |
| 703 | + var NestedRepeaterRemoveContainer; | |
| 704 | + var init_nested_repeater_remove_container = __esmMin((() => { | |
| 705 | + init_classCallCheck(); | |
| 706 | + init_createClass(); | |
| 707 | + init_possibleConstructorReturn(); | |
| 708 | + init_getPrototypeOf(); | |
| 709 | + init_get(); | |
| 710 | + init_inherits(); | |
| 711 | + init_base(); | |
| 712 | + init_utils(); | |
| 713 | + __name(_callSuper$7, "_callSuper"); | |
| 714 | + __name(_isNativeReflectConstruct$7, "_isNativeReflectConstruct"); | |
| 715 | + __name(_superPropGet$3, "_superPropGet"); | |
| 716 | + NestedRepeaterRemoveContainer = /*#__PURE__*/ function(_Base) { | |
| 717 | + function NestedRepeaterRemoveContainer() { | |
| 718 | + _classCallCheck(this, NestedRepeaterRemoveContainer); | |
| 719 | + return _callSuper$7(this, NestedRepeaterRemoveContainer, arguments); | |
| 720 | + } | |
| 721 | + _inherits(NestedRepeaterRemoveContainer, _Base); | |
| 722 | + return _createClass(NestedRepeaterRemoveContainer, [ | |
| 723 | + { | |
| 724 | + key: "getId", | |
| 725 | + value: function getId() { | |
| 726 | + return "document/repeater/remove--nested-elements-remove-container"; | |
| 727 | + } | |
| 728 | + }, | |
| 729 | + { | |
| 730 | + key: "getCommand", | |
| 731 | + value: function getCommand() { | |
| 732 | + return "document/repeater/remove"; | |
| 733 | + } | |
| 734 | + }, | |
| 735 | + { | |
| 736 | + key: "getConditions", | |
| 737 | + value: function getConditions(args) { | |
| 738 | + var isCommandCalledDirectly = $e.commands.isCurrentFirstTrace(this.getCommand()); | |
| 739 | + return _superPropGet$3(NestedRepeaterRemoveContainer, "getConditions", this, 3)([args]) && isCommandCalledDirectly; | |
| 740 | + } | |
| 741 | + }, | |
| 742 | + { | |
| 743 | + key: "apply", | |
| 744 | + value: function apply(_ref) { | |
| 745 | + var container = _ref.container; | |
| 746 | + var index = _ref.index; | |
| 747 | + $e.run("document/elements/delete", { | |
| 748 | + container: findChildContainerOrFail(container, index), | |
| 749 | + force: true | |
| 750 | + }); | |
| 751 | + if (shouldUseAtomicRepeaters(container.settings.get("widgetType"))) elementor.$preview[0].contentWindow.dispatchEvent(new CustomEvent("elementor/nested-container/atomic-repeater", { detail: { | |
| 752 | + container, | |
| 753 | + action: { type: "remove" } | |
| 754 | + } })); | |
| 755 | + } | |
| 756 | + } | |
| 757 | + ]); | |
| 758 | + }(Base); | |
| 759 | + })); | |
| 160 | 760 | |
| 161 | - return module.exports = _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { | |
| 162 | - return typeof o; | |
| 163 | - } : function (o) { | |
| 164 | - return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; | |
| 165 | - }, module.exports.__esModule = true, module.exports["default"] = module.exports, _typeof(o); | |
| 166 | -} | |
| 167 | -module.exports = _typeof, module.exports.__esModule = true, module.exports["default"] = module.exports; | |
| 761 | +//#endregion | |
| 762 | +//#region modules/nested-elements/assets/js/editor/nested-repeater/hooks/data/document/repeater/move/nested-repeater-move-container.js | |
| 763 | + function _callSuper$6(t, o, e) { | |
| 764 | + return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$6() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); | |
| 765 | + } | |
| 766 | + function _isNativeReflectConstruct$6() { | |
| 767 | + try { | |
| 768 | + var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {})); | |
| 769 | + } catch (t) {} | |
| 770 | + return (_isNativeReflectConstruct$6 = function _isNativeReflectConstruct() { | |
| 771 | + return !!t; | |
| 772 | + })(); | |
| 773 | + } | |
| 774 | + var NestedRepeaterMoveContainer; | |
| 775 | + var init_nested_repeater_move_container = __esmMin((() => { | |
| 776 | + init_classCallCheck(); | |
| 777 | + init_createClass(); | |
| 778 | + init_possibleConstructorReturn(); | |
| 779 | + init_getPrototypeOf(); | |
| 780 | + init_inherits(); | |
| 781 | + init_base(); | |
| 782 | + init_utils(); | |
| 783 | + __name(_callSuper$6, "_callSuper"); | |
| 784 | + __name(_isNativeReflectConstruct$6, "_isNativeReflectConstruct"); | |
| 785 | + NestedRepeaterMoveContainer = /*#__PURE__*/ function(_Base) { | |
| 786 | + function NestedRepeaterMoveContainer() { | |
| 787 | + _classCallCheck(this, NestedRepeaterMoveContainer); | |
| 788 | + return _callSuper$6(this, NestedRepeaterMoveContainer, arguments); | |
| 789 | + } | |
| 790 | + _inherits(NestedRepeaterMoveContainer, _Base); | |
| 791 | + return _createClass(NestedRepeaterMoveContainer, [ | |
| 792 | + { | |
| 793 | + key: "getId", | |
| 794 | + value: function getId() { | |
| 795 | + return "document/repeater/move--nested-repeater-move-container"; | |
| 796 | + } | |
| 797 | + }, | |
| 798 | + { | |
| 799 | + key: "getCommand", | |
| 800 | + value: function getCommand() { | |
| 801 | + return "document/repeater/move"; | |
| 802 | + } | |
| 803 | + }, | |
| 804 | + { | |
| 805 | + key: "apply", | |
| 806 | + value: function apply(_ref) { | |
| 807 | + var container = _ref.container; | |
| 808 | + var sourceIndex = _ref.sourceIndex; | |
| 809 | + var targetIndex = _ref.targetIndex; | |
| 810 | + var result = $e.run("document/elements/move", { | |
| 811 | + container: findChildContainerOrFail(container, sourceIndex), | |
| 812 | + target: container, | |
| 813 | + options: { | |
| 814 | + at: targetIndex, | |
| 815 | + edit: false | |
| 816 | + } | |
| 817 | + }); | |
| 818 | + if (shouldUseAtomicRepeaters(container.settings.get("widgetType"))) { | |
| 819 | + container.view.children._views = sortViewsByModels(container); | |
| 820 | + elementor.$preview[0].contentWindow.dispatchEvent(new CustomEvent("elementor/nested-container/atomic-repeater", { detail: { | |
| 821 | + container, | |
| 822 | + targetContainer: result, | |
| 823 | + index: targetIndex, | |
| 824 | + action: { type: "move" } | |
| 825 | + } })); | |
| 826 | + } | |
| 827 | + } | |
| 828 | + } | |
| 829 | + ]); | |
| 830 | + }(Base); | |
| 831 | + })); | |
| 168 | 832 | |
| 169 | -/***/ }), | |
| 833 | +//#endregion | |
| 834 | +//#region modules/nested-elements/assets/js/editor/nested-repeater/hooks/data/document/repeater/duplicate/nested-repeater-duplicate-container.js | |
| 835 | + function _callSuper$5(t, o, e) { | |
| 836 | + return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$5() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); | |
| 837 | + } | |
| 838 | + function _isNativeReflectConstruct$5() { | |
| 839 | + try { | |
| 840 | + var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {})); | |
| 841 | + } catch (t) {} | |
| 842 | + return (_isNativeReflectConstruct$5 = function _isNativeReflectConstruct() { | |
| 843 | + return !!t; | |
| 844 | + })(); | |
| 845 | + } | |
| 846 | + var NestedRepeaterDuplicateContainer; | |
| 847 | + var init_nested_repeater_duplicate_container = __esmMin((() => { | |
| 848 | + init_classCallCheck(); | |
| 849 | + init_createClass(); | |
| 850 | + init_possibleConstructorReturn(); | |
| 851 | + init_getPrototypeOf(); | |
| 852 | + init_inherits(); | |
| 853 | + init_base(); | |
| 854 | + init_utils(); | |
| 855 | + __name(_callSuper$5, "_callSuper"); | |
| 856 | + __name(_isNativeReflectConstruct$5, "_isNativeReflectConstruct"); | |
| 857 | + NestedRepeaterDuplicateContainer = /*#__PURE__*/ function(_Base) { | |
| 858 | + function NestedRepeaterDuplicateContainer() { | |
| 859 | + _classCallCheck(this, NestedRepeaterDuplicateContainer); | |
| 860 | + return _callSuper$5(this, NestedRepeaterDuplicateContainer, arguments); | |
| 861 | + } | |
| 862 | + _inherits(NestedRepeaterDuplicateContainer, _Base); | |
| 863 | + return _createClass(NestedRepeaterDuplicateContainer, [ | |
| 864 | + { | |
| 865 | + key: "getId", | |
| 866 | + value: function getId() { | |
| 867 | + return "document/repeater/duplicate--nested-repeater-duplicate-container"; | |
| 868 | + } | |
| 869 | + }, | |
| 870 | + { | |
| 871 | + key: "getCommand", | |
| 872 | + value: function getCommand() { | |
| 873 | + return "document/repeater/duplicate"; | |
| 874 | + } | |
| 875 | + }, | |
| 876 | + { | |
| 877 | + key: "apply", | |
| 878 | + value: function apply(_ref) { | |
| 879 | + var container = _ref.container; | |
| 880 | + var index = _ref.index; | |
| 881 | + var result = $e.run("document/elements/duplicate", { | |
| 882 | + container: findChildContainerOrFail(container, index), | |
| 883 | + options: { edit: false } | |
| 884 | + }); | |
| 885 | + if (shouldUseAtomicRepeaters(container.settings.get("widgetType"))) { | |
| 886 | + container.view.children._views = sortViewsByModels(container); | |
| 887 | + elementor.$preview[0].contentWindow.dispatchEvent(new CustomEvent("elementor/nested-container/atomic-repeater", { detail: { | |
| 888 | + container, | |
| 889 | + targetContainer: result, | |
| 890 | + index, | |
| 891 | + action: { type: "duplicate" } | |
| 892 | + } })); | |
| 893 | + } else container.render(); | |
| 894 | + } | |
| 895 | + } | |
| 896 | + ]); | |
| 897 | + }(Base); | |
| 898 | + })); | |
| 170 | 899 | |
| 171 | -/***/ "@wordpress/i18n": | |
| 172 | -/*!**************************!*\ | |
| 173 | - !*** external "wp.i18n" ***! | |
| 174 | - \**************************/ | |
| 175 | -/***/ ((module) => { | |
| 900 | +//#endregion | |
| 901 | +//#region modules/nested-elements/assets/js/editor/nested-repeater/hooks/ui/panel/editor/open/nested-repeater-focus-current-edited-container.js | |
| 902 | + function _callSuper$4(t, o, e) { | |
| 903 | + return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$4() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); | |
| 904 | + } | |
| 905 | + function _isNativeReflectConstruct$4() { | |
| 906 | + try { | |
| 907 | + var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {})); | |
| 908 | + } catch (t) {} | |
| 909 | + return (_isNativeReflectConstruct$4 = function _isNativeReflectConstruct() { | |
| 910 | + return !!t; | |
| 911 | + })(); | |
| 912 | + } | |
| 913 | + var NAVIGATION_DEPTH_SENSITIVITY_TIMEOUT, NestedRepeaterFocusCurrentEditedContainer; | |
| 914 | + var init_nested_repeater_focus_current_edited_container = __esmMin((() => { | |
| 915 | + init_classCallCheck(); | |
| 916 | + init_createClass(); | |
| 917 | + init_possibleConstructorReturn(); | |
| 918 | + init_getPrototypeOf(); | |
| 919 | + init_inherits(); | |
| 920 | + init_utils(); | |
| 921 | + __name(_callSuper$4, "_callSuper"); | |
| 922 | + __name(_isNativeReflectConstruct$4, "_isNativeReflectConstruct"); | |
| 923 | + NAVIGATION_DEPTH_SENSITIVITY_TIMEOUT = 250; | |
| 924 | + NestedRepeaterFocusCurrentEditedContainer = /*#__PURE__*/ function(_$e$modules$hookUI$Af) { | |
| 925 | + function NestedRepeaterFocusCurrentEditedContainer() { | |
| 926 | + _classCallCheck(this, NestedRepeaterFocusCurrentEditedContainer); | |
| 927 | + return _callSuper$4(this, NestedRepeaterFocusCurrentEditedContainer, arguments); | |
| 928 | + } | |
| 929 | + _inherits(NestedRepeaterFocusCurrentEditedContainer, _$e$modules$hookUI$Af); | |
| 930 | + return _createClass(NestedRepeaterFocusCurrentEditedContainer, [ | |
| 931 | + { | |
| 932 | + key: "getCommand", | |
| 933 | + value: function getCommand() { | |
| 934 | + return "panel/editor/open"; | |
| 935 | + } | |
| 936 | + }, | |
| 937 | + { | |
| 938 | + key: "getId", | |
| 939 | + value: function getId() { | |
| 940 | + return "nested-repeater-focus-current-edited-container"; | |
| 941 | + } | |
| 942 | + }, | |
| 943 | + { | |
| 944 | + key: "getConditions", | |
| 945 | + value: function getConditions(args) { | |
| 946 | + var _this$navigationMap; | |
| 947 | + if ($e.commands.isCurrentFirstTrace("document/elements/create")) return false; | |
| 948 | + var allParents = args.view.container.getParentAncestry(); | |
| 949 | + if (allParents.some(function(parent) { | |
| 950 | + return isWidgetSupportNesting(parent.model.get("widgetType")); | |
| 951 | + })) this.navigationMap = this.getNavigationMapForContainers(allParents.filter(function(container) { | |
| 952 | + return "container" === container.type && "widget" === container.parent.type; | |
| 953 | + })).filter(function(map) { | |
| 954 | + return map.index !== map.current; | |
| 955 | + }); | |
| 956 | + return (_this$navigationMap = this.navigationMap) === null || _this$navigationMap === void 0 ? void 0 : _this$navigationMap.length; | |
| 957 | + } | |
| 958 | + }, | |
| 959 | + { | |
| 960 | + key: "apply", | |
| 961 | + value: function apply() { | |
| 962 | + var depth = 1; | |
| 963 | + this.navigationMap.forEach(function(_ref) { | |
| 964 | + var container = _ref.container; | |
| 965 | + var index = _ref.index; | |
| 966 | + setTimeout(function() { | |
| 967 | + $e.run("document/repeater/select", { | |
| 968 | + container, | |
| 969 | + index: index++, | |
| 970 | + options: { useHistory: false } | |
| 971 | + }); | |
| 972 | + }, NAVIGATION_DEPTH_SENSITIVITY_TIMEOUT * depth); | |
| 973 | + ++depth; | |
| 974 | + }); | |
| 975 | + } | |
| 976 | + }, | |
| 977 | + { | |
| 978 | + key: "getNavigationMapForContainers", | |
| 979 | + value: function getNavigationMapForContainers(containers) { | |
| 980 | + return containers.map(function(container) { | |
| 981 | + return { | |
| 982 | + current: container.parent.model.get("editSettings").get("activeItemIndex"), | |
| 983 | + container: container.parent, | |
| 984 | + index: container.parent.children.indexOf(container) + 1 | |
| 985 | + }; | |
| 986 | + }).reverse(); | |
| 987 | + } | |
| 988 | + } | |
| 989 | + ]); | |
| 990 | + }($e.modules.hookUI.After); | |
| 991 | + })); | |
| 176 | 992 | |
| 177 | -"use strict"; | |
| 178 | -module.exports = wp.i18n; | |
| 993 | +//#endregion | |
| 994 | +//#region modules/nested-elements/assets/js/editor/nested-repeater/hooks/index.js | |
| 995 | + var hooks_exports = /* @__PURE__ */ __exportAll({ | |
| 996 | + NestedRepeaterCreateContainer: () => NestedRepeaterCreateContainer, | |
| 997 | + NestedRepeaterDuplicateContainer: () => NestedRepeaterDuplicateContainer, | |
| 998 | + NestedRepeaterFocusCurrentEditedContainer: () => NestedRepeaterFocusCurrentEditedContainer, | |
| 999 | + NestedRepeaterMoveContainer: () => NestedRepeaterMoveContainer, | |
| 1000 | + NestedRepeaterRemoveContainer: () => NestedRepeaterRemoveContainer | |
| 1001 | + }); | |
| 1002 | + var init_hooks = __esmMin((() => { | |
| 1003 | + init_nested_repeater_create_container(); | |
| 1004 | + init_nested_repeater_remove_container(); | |
| 1005 | + init_nested_repeater_move_container(); | |
| 1006 | + init_nested_repeater_duplicate_container(); | |
| 1007 | + init_nested_repeater_focus_current_edited_container(); | |
| 1008 | + })); | |
| 179 | 1009 | |
| 180 | -/***/ }), | |
| 1010 | +//#endregion | |
| 1011 | +//#region modules/nested-elements/assets/js/editor/nested-repeater/component.js | |
| 1012 | + function _callSuper$3(t, o, e) { | |
| 1013 | + return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$3() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); | |
| 1014 | + } | |
| 1015 | + function _isNativeReflectConstruct$3() { | |
| 1016 | + try { | |
| 1017 | + var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {})); | |
| 1018 | + } catch (t) {} | |
| 1019 | + return (_isNativeReflectConstruct$3 = function _isNativeReflectConstruct() { | |
| 1020 | + return !!t; | |
| 1021 | + })(); | |
| 1022 | + } | |
| 1023 | + function _superPropGet$2(t, o, e, r) { | |
| 1024 | + var p = _get(_getPrototypeOf(1 & r ? t.prototype : t), o, e); | |
| 1025 | + return 2 & r && "function" == typeof p ? function(t) { | |
| 1026 | + return p.apply(e, t); | |
| 1027 | + } : p; | |
| 1028 | + } | |
| 1029 | + var Component$1; | |
| 1030 | + var init_component$1 = __esmMin((() => { | |
| 1031 | + init_classCallCheck(); | |
| 1032 | + init_createClass(); | |
| 1033 | + init_possibleConstructorReturn(); | |
| 1034 | + init_getPrototypeOf(); | |
| 1035 | + init_get(); | |
| 1036 | + init_inherits(); | |
| 1037 | + init_defineProperty(); | |
| 1038 | + init_nested_model_base(); | |
| 1039 | + init_nested_view_base(); | |
| 1040 | + init_repeater(); | |
| 1041 | + init_hooks(); | |
| 1042 | + __name(_callSuper$3, "_callSuper"); | |
| 1043 | + __name(_isNativeReflectConstruct$3, "_isNativeReflectConstruct"); | |
| 1044 | + __name(_superPropGet$2, "_superPropGet"); | |
| 1045 | + Component$1 = /*#__PURE__*/ function(_$e$modules$Component) { | |
| 1046 | + function Component() { | |
| 1047 | + var _this; | |
| 1048 | + _classCallCheck(this, Component); | |
| 1049 | + for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) args[_key] = arguments[_key]; | |
| 1050 | + _this = _callSuper$3(this, Component, [].concat(args)); | |
| 1051 | + _defineProperty(_this, "exports", { | |
| 1052 | + NestedModelBase, | |
| 1053 | + NestedViewBase | |
| 1054 | + }); | |
| 1055 | + return _this; | |
| 1056 | + } | |
| 1057 | + _inherits(Component, _$e$modules$Component); | |
| 1058 | + return _createClass(Component, [ | |
| 1059 | + { | |
| 1060 | + key: "registerAPI", | |
| 1061 | + value: function registerAPI() { | |
| 1062 | + _superPropGet$2(Component, "registerAPI", this, 3)([]); | |
| 1063 | + elementor.addControlView("nested-elements-repeater", Repeater); | |
| 1064 | + } | |
| 1065 | + }, | |
| 1066 | + { | |
| 1067 | + key: "getNamespace", | |
| 1068 | + value: function getNamespace() { | |
| 1069 | + return "nested-elements/nested-repeater"; | |
| 1070 | + } | |
| 1071 | + }, | |
| 1072 | + { | |
| 1073 | + key: "defaultHooks", | |
| 1074 | + value: function defaultHooks() { | |
| 1075 | + return this.importHooks(hooks_exports); | |
| 1076 | + } | |
| 1077 | + } | |
| 1078 | + ]); | |
| 1079 | + }($e.modules.ComponentBase); | |
| 1080 | + })); | |
| 181 | 1081 | |
| 182 | -/***/ "react": | |
| 183 | -/*!************************!*\ | |
| 184 | - !*** external "React" ***! | |
| 185 | - \************************/ | |
| 186 | -/***/ ((module) => { | |
| 1082 | +//#endregion | |
| 1083 | +//#region modules/nested-elements/assets/js/editor/component.js | |
| 1084 | + function _callSuper$2(t, o, e) { | |
| 1085 | + return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$2() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); | |
| 1086 | + } | |
| 1087 | + function _isNativeReflectConstruct$2() { | |
| 1088 | + try { | |
| 1089 | + var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {})); | |
| 1090 | + } catch (t) {} | |
| 1091 | + return (_isNativeReflectConstruct$2 = function _isNativeReflectConstruct() { | |
| 1092 | + return !!t; | |
| 1093 | + })(); | |
| 1094 | + } | |
| 1095 | + function _superPropGet$1(t, o, e, r) { | |
| 1096 | + var p = _get(_getPrototypeOf(1 & r ? t.prototype : t), o, e); | |
| 1097 | + return 2 & r && "function" == typeof p ? function(t) { | |
| 1098 | + return p.apply(e, t); | |
| 1099 | + } : p; | |
| 1100 | + } | |
| 1101 | + var Component; | |
| 1102 | + var init_component = __esmMin((() => { | |
| 1103 | + init_classCallCheck(); | |
| 1104 | + init_createClass(); | |
| 1105 | + init_possibleConstructorReturn(); | |
| 1106 | + init_getPrototypeOf(); | |
| 1107 | + init_get(); | |
| 1108 | + init_inherits(); | |
| 1109 | + init_component$1(); | |
| 1110 | + __name(_callSuper$2, "_callSuper"); | |
| 1111 | + __name(_isNativeReflectConstruct$2, "_isNativeReflectConstruct"); | |
| 1112 | + __name(_superPropGet$1, "_superPropGet"); | |
| 1113 | + Component = /*#__PURE__*/ function(_$e$modules$Component) { | |
| 1114 | + function Component() { | |
| 1115 | + _classCallCheck(this, Component); | |
| 1116 | + return _callSuper$2(this, Component, arguments); | |
| 1117 | + } | |
| 1118 | + _inherits(Component, _$e$modules$Component); | |
| 1119 | + return _createClass(Component, [{ | |
| 1120 | + key: "getNamespace", | |
| 1121 | + value: function getNamespace() { | |
| 1122 | + return "nested-elements"; | |
| 1123 | + } | |
| 1124 | + }, { | |
| 1125 | + key: "registerAPI", | |
| 1126 | + value: function registerAPI() { | |
| 1127 | + $e.components.register(new Component$1()); | |
| 1128 | + _superPropGet$1(Component, "registerAPI", this, 3)([]); | |
| 1129 | + } | |
| 1130 | + }]); | |
| 1131 | + }($e.modules.ComponentBase); | |
| 1132 | + })); | |
| 187 | 1133 | |
| 188 | -"use strict"; | |
| 189 | -module.exports = React; | |
| 1134 | +//#endregion | |
| 1135 | +//#region modules/nested-elements/assets/js/editor/module.js | |
| 1136 | + var module_exports = /* @__PURE__ */ __exportAll({ default: () => NestedElementsModule }); | |
| 1137 | + var NestedElementsModule; | |
| 1138 | + var init_module = __esmMin((() => { | |
| 1139 | + init_createClass(); | |
| 1140 | + init_classCallCheck(); | |
| 1141 | + init_component(); | |
| 1142 | + NestedElementsModule = /*#__PURE__*/ _createClass(function NestedElementsModule() { | |
| 1143 | + _classCallCheck(this, NestedElementsModule); | |
| 1144 | + this.component = $e.components.register(new Component()); | |
| 1145 | + }); | |
| 1146 | + })); | |
| 190 | 1147 | |
| 191 | -/***/ }) | |
| 1148 | +//#endregion | |
| 1149 | +//#region modules/nested-elements/assets/js/editor/views/view.js | |
| 1150 | + var view_exports = /* @__PURE__ */ __exportAll({ | |
| 1151 | + View: () => View, | |
| 1152 | + default: () => View | |
| 1153 | + }); | |
| 1154 | + function _callSuper$1(t, o, e) { | |
| 1155 | + return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$1() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); | |
| 1156 | + } | |
| 1157 | + function _isNativeReflectConstruct$1() { | |
| 1158 | + try { | |
| 1159 | + var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {})); | |
| 1160 | + } catch (t) {} | |
| 1161 | + return (_isNativeReflectConstruct$1 = function _isNativeReflectConstruct() { | |
| 1162 | + return !!t; | |
| 1163 | + })(); | |
| 1164 | + } | |
| 1165 | + function _superPropGet(t, o, e, r) { | |
| 1166 | + var p = _get(_getPrototypeOf(1 & r ? t.prototype : t), o, e); | |
| 1167 | + return 2 & r && "function" == typeof p ? function(t) { | |
| 1168 | + return p.apply(e, t); | |
| 1169 | + } : p; | |
| 1170 | + } | |
| 1171 | + var View; | |
| 1172 | + var init_view = __esmMin((() => { | |
| 1173 | + init_classCallCheck(); | |
| 1174 | + init_createClass(); | |
| 1175 | + init_possibleConstructorReturn(); | |
| 1176 | + init_getPrototypeOf(); | |
| 1177 | + init_get(); | |
| 1178 | + init_inherits(); | |
| 1179 | + __name(_callSuper$1, "_callSuper"); | |
| 1180 | + __name(_isNativeReflectConstruct$1, "_isNativeReflectConstruct"); | |
| 1181 | + View = /*#__PURE__*/ function(_$e$components$get$ex) { | |
| 1182 | + function View() { | |
| 1183 | + _classCallCheck(this, View); | |
| 1184 | + return _callSuper$1(this, View, arguments); | |
| 1185 | + } | |
| 1186 | + _inherits(View, _$e$components$get$ex); | |
| 1187 | + return _createClass(View, [{ | |
| 1188 | + key: "events", | |
| 1189 | + value: function events() { | |
| 1190 | + var _this = this; | |
| 1191 | + var events = _superPropGet(View, "events", this, 3)([]); | |
| 1192 | + events.click = function(e) { | |
| 1193 | + if (elementor.documents.currentDocument.id.toString() !== e.target.closest(".elementor").dataset.elementorId) return; | |
| 1194 | + var closest = e.target.closest(".elementor-element"); | |
| 1195 | + var targetContainer = null; | |
| 1196 | + if (["container", "widget"].includes(closest === null || closest === void 0 ? void 0 : closest.dataset.element_type)) { | |
| 1197 | + var container = elementor.getContainer(closest.dataset.id); | |
| 1198 | + if (container.view.isEmpty()) return true; | |
| 1199 | + targetContainer = container; | |
| 1200 | + } | |
| 1201 | + e.stopPropagation(); | |
| 1202 | + $e.run("document/elements/select", { container: targetContainer || _this.getContainer() }); | |
| 1203 | + }; | |
| 1204 | + return events; | |
| 1205 | + } | |
| 1206 | + }, { | |
| 1207 | + key: "renderHTML", | |
| 1208 | + value: function renderHTML() { | |
| 1209 | + var templateType = this.getTemplateType(); | |
| 1210 | + var editModel = this.getEditModel(); | |
| 1211 | + if ("js" === templateType) { | |
| 1212 | + editModel.setHtmlCache(); | |
| 1213 | + this.render(); | |
| 1214 | + } else editModel.renderRemoteServer(); | |
| 1215 | + } | |
| 1216 | + }]); | |
| 1217 | + }($e.components.get("nested-elements/nested-repeater").exports.NestedViewBase); | |
| 1218 | + })); | |
| 192 | 1219 | |
| 193 | -/******/ }); | |
| 194 | -/************************************************************************/ | |
| 195 | -/******/ // The module cache | |
| 196 | -/******/ var __webpack_module_cache__ = {}; | |
| 197 | -/******/ | |
| 198 | -/******/ // The require function | |
| 199 | -/******/ function __webpack_require__(moduleId) { | |
| 200 | -/******/ // Check if module is in cache | |
| 201 | -/******/ var cachedModule = __webpack_module_cache__[moduleId]; | |
| 202 | -/******/ if (cachedModule !== undefined) { | |
| 203 | -/******/ return cachedModule.exports; | |
| 204 | -/******/ } | |
| 205 | -/******/ // Create a new module (and put it into the cache) | |
| 206 | -/******/ var module = __webpack_module_cache__[moduleId] = { | |
| 207 | -/******/ // no module.id needed | |
| 208 | -/******/ // no module.loaded needed | |
| 209 | -/******/ exports: {} | |
| 210 | -/******/ }; | |
| 211 | -/******/ | |
| 212 | -/******/ // Execute the module function | |
| 213 | -/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); | |
| 214 | -/******/ | |
| 215 | -/******/ // Return the exports of the module | |
| 216 | -/******/ return module.exports; | |
| 217 | -/******/ } | |
| 218 | -/******/ | |
| 219 | -/******/ // expose the modules object (__webpack_modules__) | |
| 220 | -/******/ __webpack_require__.m = __webpack_modules__; | |
| 221 | -/******/ | |
| 222 | -/************************************************************************/ | |
| 223 | -/******/ /* webpack/runtime/ensure chunk */ | |
| 224 | -/******/ (() => { | |
| 225 | -/******/ __webpack_require__.f = {}; | |
| 226 | -/******/ // This file contains only the entry chunk. | |
| 227 | -/******/ // The chunk loading function for additional chunks | |
| 228 | -/******/ __webpack_require__.e = (chunkId) => { | |
| 229 | -/******/ return Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => { | |
| 230 | -/******/ __webpack_require__.f[key](chunkId, promises); | |
| 231 | -/******/ return promises; | |
| 232 | -/******/ }, [])); | |
| 233 | -/******/ }; | |
| 234 | -/******/ })(); | |
| 235 | -/******/ | |
| 236 | -/******/ /* webpack/runtime/get javascript chunk filename */ | |
| 237 | -/******/ (() => { | |
| 238 | -/******/ // This function allow to reference async chunks | |
| 239 | -/******/ __webpack_require__.u = (chunkId) => { | |
| 240 | -/******/ // return url for filenames not based on template | |
| 241 | -/******/ if (chunkId === "modules_nested-elements_assets_js_editor_module_js") return "3d410a099008411bb011.bundle.js"; | |
| 242 | -/******/ if (chunkId === "vendors-node_modules_prop-types_index_js-node_modules_babel_runtime_helpers_slicedToArray_js") return "6a19e86dd8c1f9165dbe.bundle.js"; | |
| 243 | -/******/ if (chunkId === "modules_nested-elements_assets_js_editor_nested-element-types-base_js") return "9b97a73ee8fdc5fb7dc3.bundle.js"; | |
| 244 | -/******/ if (chunkId === "modules_nested-elements_assets_js_editor_views_view_js") return "197583acd246fea0e25d.bundle.js"; | |
| 245 | -/******/ // return url for filenames based on template | |
| 246 | -/******/ return undefined; | |
| 247 | -/******/ }; | |
| 248 | -/******/ })(); | |
| 249 | -/******/ | |
| 250 | -/******/ /* webpack/runtime/global */ | |
| 251 | -/******/ (() => { | |
| 252 | -/******/ __webpack_require__.g = (function() { | |
| 253 | -/******/ if (typeof globalThis === 'object') return globalThis; | |
| 254 | -/******/ try { | |
| 255 | -/******/ return this || new Function('return this')(); | |
| 256 | -/******/ } catch (e) { | |
| 257 | -/******/ if (typeof window === 'object') return window; | |
| 258 | -/******/ } | |
| 259 | -/******/ })(); | |
| 260 | -/******/ })(); | |
| 261 | -/******/ | |
| 262 | -/******/ /* webpack/runtime/hasOwnProperty shorthand */ | |
| 263 | -/******/ (() => { | |
| 264 | -/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) | |
| 265 | -/******/ })(); | |
| 266 | -/******/ | |
| 267 | -/******/ /* webpack/runtime/load script */ | |
| 268 | -/******/ (() => { | |
| 269 | -/******/ var inProgress = {}; | |
| 270 | -/******/ var dataWebpackPrefix = "elementor:"; | |
| 271 | -/******/ // loadScript function to load a script via script tag | |
| 272 | -/******/ __webpack_require__.l = (url, done, key, chunkId) => { | |
| 273 | -/******/ if(inProgress[url]) { inProgress[url].push(done); return; } | |
| 274 | -/******/ var script, needAttach; | |
| 275 | -/******/ if(key !== undefined) { | |
| 276 | -/******/ var scripts = document.getElementsByTagName("script"); | |
| 277 | -/******/ for(var i = 0; i < scripts.length; i++) { | |
| 278 | -/******/ var s = scripts[i]; | |
| 279 | -/******/ if(s.getAttribute("src") == url || s.getAttribute("data-webpack") == dataWebpackPrefix + key) { script = s; break; } | |
| 280 | -/******/ } | |
| 281 | -/******/ } | |
| 282 | -/******/ if(!script) { | |
| 283 | -/******/ needAttach = true; | |
| 284 | -/******/ script = document.createElement('script'); | |
| 285 | -/******/ | |
| 286 | -/******/ script.charset = 'utf-8'; | |
| 287 | -/******/ if (__webpack_require__.nc) { | |
| 288 | -/******/ script.setAttribute("nonce", __webpack_require__.nc); | |
| 289 | -/******/ } | |
| 290 | -/******/ script.setAttribute("data-webpack", dataWebpackPrefix + key); | |
| 291 | -/******/ | |
| 292 | -/******/ script.src = url; | |
| 293 | -/******/ } | |
| 294 | -/******/ inProgress[url] = [done]; | |
| 295 | -/******/ var onScriptComplete = (prev, event) => { | |
| 296 | -/******/ // avoid mem leaks in IE. | |
| 297 | -/******/ script.onerror = script.onload = null; | |
| 298 | -/******/ clearTimeout(timeout); | |
| 299 | -/******/ var doneFns = inProgress[url]; | |
| 300 | -/******/ delete inProgress[url]; | |
| 301 | -/******/ script.parentNode && script.parentNode.removeChild(script); | |
| 302 | -/******/ doneFns && doneFns.forEach((fn) => (fn(event))); | |
| 303 | -/******/ if(prev) return prev(event); | |
| 304 | -/******/ } | |
| 305 | -/******/ var timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000); | |
| 306 | -/******/ script.onerror = onScriptComplete.bind(null, script.onerror); | |
| 307 | -/******/ script.onload = onScriptComplete.bind(null, script.onload); | |
| 308 | -/******/ needAttach && document.head.appendChild(script); | |
| 309 | -/******/ }; | |
| 310 | -/******/ })(); | |
| 311 | -/******/ | |
| 312 | -/******/ /* webpack/runtime/publicPath */ | |
| 313 | -/******/ (() => { | |
| 314 | -/******/ var scriptUrl; | |
| 315 | -/******/ if (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + ""; | |
| 316 | -/******/ var document = __webpack_require__.g.document; | |
| 317 | -/******/ if (!scriptUrl && document) { | |
| 318 | -/******/ if (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT') | |
| 319 | -/******/ scriptUrl = document.currentScript.src; | |
| 320 | -/******/ if (!scriptUrl) { | |
| 321 | -/******/ var scripts = document.getElementsByTagName("script"); | |
| 322 | -/******/ if(scripts.length) { | |
| 323 | -/******/ var i = scripts.length - 1; | |
| 324 | -/******/ while (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src; | |
| 325 | -/******/ } | |
| 326 | -/******/ } | |
| 327 | -/******/ } | |
| 328 | -/******/ // When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration | |
| 329 | -/******/ // or pass an empty string ("") and set the __webpack_public_path__ variable from your code to use your own logic. | |
| 330 | -/******/ if (!scriptUrl) throw new Error("Automatic publicPath is not supported in this browser"); | |
| 331 | -/******/ scriptUrl = scriptUrl.replace(/^blob:/, "").replace(/#.*$/, "").replace(/\?.*$/, "").replace(/\/[^\/]+$/, "/"); | |
| 332 | -/******/ __webpack_require__.p = scriptUrl; | |
| 333 | -/******/ })(); | |
| 334 | -/******/ | |
| 335 | -/******/ /* webpack/runtime/jsonp chunk loading */ | |
| 336 | -/******/ (() => { | |
| 337 | -/******/ // no baseURI | |
| 338 | -/******/ | |
| 339 | -/******/ // object to store loaded and loading chunks | |
| 340 | -/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched | |
| 341 | -/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded | |
| 342 | -/******/ var installedChunks = { | |
| 343 | -/******/ "nested-elements": 0 | |
| 344 | -/******/ }; | |
| 345 | -/******/ | |
| 346 | -/******/ __webpack_require__.f.j = (chunkId, promises) => { | |
| 347 | -/******/ // JSONP chunk loading for javascript | |
| 348 | -/******/ var installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined; | |
| 349 | -/******/ if(installedChunkData !== 0) { // 0 means "already installed". | |
| 350 | -/******/ | |
| 351 | -/******/ // a Promise means "currently loading". | |
| 352 | -/******/ if(installedChunkData) { | |
| 353 | -/******/ promises.push(installedChunkData[2]); | |
| 354 | -/******/ } else { | |
| 355 | -/******/ if(true) { // all chunks have JS | |
| 356 | -/******/ // setup Promise in chunk cache | |
| 357 | -/******/ var promise = new Promise((resolve, reject) => (installedChunkData = installedChunks[chunkId] = [resolve, reject])); | |
| 358 | -/******/ promises.push(installedChunkData[2] = promise); | |
| 359 | -/******/ | |
| 360 | -/******/ // start chunk loading | |
| 361 | -/******/ var url = __webpack_require__.p + __webpack_require__.u(chunkId); | |
| 362 | -/******/ // create error before stack unwound to get useful stacktrace later | |
| 363 | -/******/ var error = new Error(); | |
| 364 | -/******/ var loadingEnded = (event) => { | |
| 365 | -/******/ if(__webpack_require__.o(installedChunks, chunkId)) { | |
| 366 | -/******/ installedChunkData = installedChunks[chunkId]; | |
| 367 | -/******/ if(installedChunkData !== 0) installedChunks[chunkId] = undefined; | |
| 368 | -/******/ if(installedChunkData) { | |
| 369 | -/******/ var errorType = event && (event.type === 'load' ? 'missing' : event.type); | |
| 370 | -/******/ var realSrc = event && event.target && event.target.src; | |
| 371 | -/******/ error.message = 'Loading chunk ' + chunkId + ' failed.\n(' + errorType + ': ' + realSrc + ')'; | |
| 372 | -/******/ error.name = 'ChunkLoadError'; | |
| 373 | -/******/ error.type = errorType; | |
| 374 | -/******/ error.request = realSrc; | |
| 375 | -/******/ installedChunkData[1](error); | |
| 376 | -/******/ } | |
| 377 | -/******/ } | |
| 378 | -/******/ }; | |
| 379 | -/******/ __webpack_require__.l(url, loadingEnded, "chunk-" + chunkId, chunkId); | |
| 380 | -/******/ } | |
| 381 | -/******/ } | |
| 382 | -/******/ } | |
| 383 | -/******/ }; | |
| 384 | -/******/ | |
| 385 | -/******/ // no prefetching | |
| 386 | -/******/ | |
| 387 | -/******/ // no preloaded | |
| 388 | -/******/ | |
| 389 | -/******/ // no HMR | |
| 390 | -/******/ | |
| 391 | -/******/ // no HMR manifest | |
| 392 | -/******/ | |
| 393 | -/******/ // no on chunks loaded | |
| 394 | -/******/ | |
| 395 | -/******/ // install a JSONP callback for chunk loading | |
| 396 | -/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { | |
| 397 | -/******/ var [chunkIds, moreModules, runtime] = data; | |
| 398 | -/******/ // add "moreModules" to the modules object, | |
| 399 | -/******/ // then flag all "chunkIds" as loaded and fire callback | |
| 400 | -/******/ var moduleId, chunkId, i = 0; | |
| 401 | -/******/ if(chunkIds.some((id) => (installedChunks[id] !== 0))) { | |
| 402 | -/******/ for(moduleId in moreModules) { | |
| 403 | -/******/ if(__webpack_require__.o(moreModules, moduleId)) { | |
| 404 | -/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; | |
| 405 | -/******/ } | |
| 406 | -/******/ } | |
| 407 | -/******/ if(runtime) var result = runtime(__webpack_require__); | |
| 408 | -/******/ } | |
| 409 | -/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); | |
| 410 | -/******/ for(;i < chunkIds.length; i++) { | |
| 411 | -/******/ chunkId = chunkIds[i]; | |
| 412 | -/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { | |
| 413 | -/******/ installedChunks[chunkId][0](); | |
| 414 | -/******/ } | |
| 415 | -/******/ installedChunks[chunkId] = 0; | |
| 416 | -/******/ } | |
| 417 | -/******/ | |
| 418 | -/******/ } | |
| 419 | -/******/ | |
| 420 | -/******/ var chunkLoadingGlobal = self["webpackChunkelementor"] = self["webpackChunkelementor"] || []; | |
| 421 | -/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); | |
| 422 | -/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); | |
| 423 | -/******/ })(); | |
| 424 | -/******/ | |
| 425 | -/************************************************************************/ | |
| 426 | -var __webpack_exports__ = {}; | |
| 427 | -// This entry needs to be wrapped in an IIFE because it needs to be in strict mode. | |
| 428 | -(() => { | |
| 429 | -"use strict"; | |
| 430 | -/*!************************************************************!*\ | |
| 431 | - !*** ../modules/nested-elements/assets/js/editor/index.js ***! | |
| 432 | - \************************************************************/ | |
| 1220 | +//#endregion | |
| 1221 | +//#region node_modules/prop-types/node_modules/react-is/cjs/react-is.development.js | |
| 1222 | +/** @license React v16.13.1 | |
| 1223 | + * react-is.development.js | |
| 1224 | + * | |
| 1225 | + * Copyright (c) Facebook, Inc. and its affiliates. | |
| 1226 | + * | |
| 1227 | + * This source code is licensed under the MIT license found in the | |
| 1228 | + * LICENSE file in the root directory of this source tree. | |
| 1229 | + */ | |
| 1230 | + var require_react_is_development = /* @__PURE__ */ __commonJSMin(((exports) => { | |
| 1231 | + (function() { | |
| 1232 | + "use strict"; | |
| 1233 | + var hasSymbol = typeof Symbol === "function" && Symbol.for; | |
| 1234 | + var REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for("react.element") : 60103; | |
| 1235 | + var REACT_PORTAL_TYPE = hasSymbol ? Symbol.for("react.portal") : 60106; | |
| 1236 | + var REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for("react.fragment") : 60107; | |
| 1237 | + var REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for("react.strict_mode") : 60108; | |
| 1238 | + var REACT_PROFILER_TYPE = hasSymbol ? Symbol.for("react.profiler") : 60114; | |
| 1239 | + var REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for("react.provider") : 60109; | |
| 1240 | + var REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for("react.context") : 60110; | |
| 1241 | + var REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for("react.async_mode") : 60111; | |
| 1242 | + var REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for("react.concurrent_mode") : 60111; | |
| 1243 | + var REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for("react.forward_ref") : 60112; | |
| 1244 | + var REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for("react.suspense") : 60113; | |
| 1245 | + var REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for("react.suspense_list") : 60120; | |
| 1246 | + var REACT_MEMO_TYPE = hasSymbol ? Symbol.for("react.memo") : 60115; | |
| 1247 | + var REACT_LAZY_TYPE = hasSymbol ? Symbol.for("react.lazy") : 60116; | |
| 1248 | + var REACT_BLOCK_TYPE = hasSymbol ? Symbol.for("react.block") : 60121; | |
| 1249 | + var REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for("react.fundamental") : 60117; | |
| 1250 | + var REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for("react.responder") : 60118; | |
| 1251 | + var REACT_SCOPE_TYPE = hasSymbol ? Symbol.for("react.scope") : 60119; | |
| 1252 | + function isValidElementType(type) { | |
| 1253 | + return typeof type === "string" || typeof type === "function" || type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === "object" && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE); | |
| 1254 | + } | |
| 1255 | + function typeOf(object) { | |
| 1256 | + if (typeof object === "object" && object !== null) { | |
| 1257 | + var $$typeof = object.$$typeof; | |
| 1258 | + switch ($$typeof) { | |
| 1259 | + case REACT_ELEMENT_TYPE: | |
| 1260 | + var type = object.type; | |
| 1261 | + switch (type) { | |
| 1262 | + case REACT_ASYNC_MODE_TYPE: | |
| 1263 | + case REACT_CONCURRENT_MODE_TYPE: | |
| 1264 | + case REACT_FRAGMENT_TYPE: | |
| 1265 | + case REACT_PROFILER_TYPE: | |
| 1266 | + case REACT_STRICT_MODE_TYPE: | |
| 1267 | + case REACT_SUSPENSE_TYPE: return type; | |
| 1268 | + default: | |
| 1269 | + var $$typeofType = type && type.$$typeof; | |
| 1270 | + switch ($$typeofType) { | |
| 1271 | + case REACT_CONTEXT_TYPE: | |
| 1272 | + case REACT_FORWARD_REF_TYPE: | |
| 1273 | + case REACT_LAZY_TYPE: | |
| 1274 | + case REACT_MEMO_TYPE: | |
| 1275 | + case REACT_PROVIDER_TYPE: return $$typeofType; | |
| 1276 | + default: return $$typeof; | |
| 1277 | + } | |
| 1278 | + } | |
| 1279 | + case REACT_PORTAL_TYPE: return $$typeof; | |
| 1280 | + } | |
| 1281 | + } | |
| 1282 | + } | |
| 1283 | + var AsyncMode = REACT_ASYNC_MODE_TYPE; | |
| 1284 | + var ConcurrentMode = REACT_CONCURRENT_MODE_TYPE; | |
| 1285 | + var ContextConsumer = REACT_CONTEXT_TYPE; | |
| 1286 | + var ContextProvider = REACT_PROVIDER_TYPE; | |
| 1287 | + var Element = REACT_ELEMENT_TYPE; | |
| 1288 | + var ForwardRef = REACT_FORWARD_REF_TYPE; | |
| 1289 | + var Fragment = REACT_FRAGMENT_TYPE; | |
| 1290 | + var Lazy = REACT_LAZY_TYPE; | |
| 1291 | + var Memo = REACT_MEMO_TYPE; | |
| 1292 | + var Portal = REACT_PORTAL_TYPE; | |
| 1293 | + var Profiler = REACT_PROFILER_TYPE; | |
| 1294 | + var StrictMode = REACT_STRICT_MODE_TYPE; | |
| 1295 | + var Suspense = REACT_SUSPENSE_TYPE; | |
| 1296 | + var hasWarnedAboutDeprecatedIsAsyncMode = false; | |
| 1297 | + function isAsyncMode(object) { | |
| 1298 | + if (!hasWarnedAboutDeprecatedIsAsyncMode) { | |
| 1299 | + hasWarnedAboutDeprecatedIsAsyncMode = true; | |
| 1300 | + console["warn"]("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API."); | |
| 1301 | + } | |
| 1302 | + return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE; | |
| 1303 | + } | |
| 1304 | + function isConcurrentMode(object) { | |
| 1305 | + return typeOf(object) === REACT_CONCURRENT_MODE_TYPE; | |
| 1306 | + } | |
| 1307 | + function isContextConsumer(object) { | |
| 1308 | + return typeOf(object) === REACT_CONTEXT_TYPE; | |
| 1309 | + } | |
| 1310 | + function isContextProvider(object) { | |
| 1311 | + return typeOf(object) === REACT_PROVIDER_TYPE; | |
| 1312 | + } | |
| 1313 | + function isElement(object) { | |
| 1314 | + return typeof object === "object" && object !== null && object.$$typeof === REACT_ELEMENT_TYPE; | |
| 1315 | + } | |
| 1316 | + function isForwardRef(object) { | |
| 1317 | + return typeOf(object) === REACT_FORWARD_REF_TYPE; | |
| 1318 | + } | |
| 1319 | + function isFragment(object) { | |
| 1320 | + return typeOf(object) === REACT_FRAGMENT_TYPE; | |
| 1321 | + } | |
| 1322 | + function isLazy(object) { | |
| 1323 | + return typeOf(object) === REACT_LAZY_TYPE; | |
| 1324 | + } | |
| 1325 | + function isMemo(object) { | |
| 1326 | + return typeOf(object) === REACT_MEMO_TYPE; | |
| 1327 | + } | |
| 1328 | + function isPortal(object) { | |
| 1329 | + return typeOf(object) === REACT_PORTAL_TYPE; | |
| 1330 | + } | |
| 1331 | + function isProfiler(object) { | |
| 1332 | + return typeOf(object) === REACT_PROFILER_TYPE; | |
| 1333 | + } | |
| 1334 | + function isStrictMode(object) { | |
| 1335 | + return typeOf(object) === REACT_STRICT_MODE_TYPE; | |
| 1336 | + } | |
| 1337 | + function isSuspense(object) { | |
| 1338 | + return typeOf(object) === REACT_SUSPENSE_TYPE; | |
| 1339 | + } | |
| 1340 | + exports.AsyncMode = AsyncMode; | |
| 1341 | + exports.ConcurrentMode = ConcurrentMode; | |
| 1342 | + exports.ContextConsumer = ContextConsumer; | |
| 1343 | + exports.ContextProvider = ContextProvider; | |
| 1344 | + exports.Element = Element; | |
| 1345 | + exports.ForwardRef = ForwardRef; | |
| 1346 | + exports.Fragment = Fragment; | |
| 1347 | + exports.Lazy = Lazy; | |
| 1348 | + exports.Memo = Memo; | |
| 1349 | + exports.Portal = Portal; | |
| 1350 | + exports.Profiler = Profiler; | |
| 1351 | + exports.StrictMode = StrictMode; | |
| 1352 | + exports.Suspense = Suspense; | |
| 1353 | + exports.isAsyncMode = isAsyncMode; | |
| 1354 | + exports.isConcurrentMode = isConcurrentMode; | |
| 1355 | + exports.isContextConsumer = isContextConsumer; | |
| 1356 | + exports.isContextProvider = isContextProvider; | |
| 1357 | + exports.isElement = isElement; | |
| 1358 | + exports.isForwardRef = isForwardRef; | |
| 1359 | + exports.isFragment = isFragment; | |
| 1360 | + exports.isLazy = isLazy; | |
| 1361 | + exports.isMemo = isMemo; | |
| 1362 | + exports.isPortal = isPortal; | |
| 1363 | + exports.isProfiler = isProfiler; | |
| 1364 | + exports.isStrictMode = isStrictMode; | |
| 1365 | + exports.isSuspense = isSuspense; | |
| 1366 | + exports.isValidElementType = isValidElementType; | |
| 1367 | + exports.typeOf = typeOf; | |
| 1368 | + })(); | |
| 1369 | + })); | |
| 433 | 1370 | |
| 1371 | +//#endregion | |
| 1372 | +//#region node_modules/prop-types/node_modules/react-is/index.js | |
| 1373 | + var require_react_is = /* @__PURE__ */ __commonJSMin(((exports, module) => { | |
| 1374 | + module.exports = require_react_is_development(); | |
| 1375 | + })); | |
| 434 | 1376 | |
| 435 | -var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ "../node_modules/@babel/runtime/helpers/interopRequireDefault.js"); | |
| 436 | -var _events = _interopRequireDefault(__webpack_require__(/*! elementor-utils/events */ "../assets/dev/js/utils/events.js")); | |
| 437 | -elementorCommon.elements.$window.on('elementor:init-components', function () { | |
| 438 | - // Put promise of loading so other modules can use/await it. | |
| 439 | - elementor.modules.nestedElements = __webpack_require__.e(/*! import() */ "modules_nested-elements_assets_js_editor_module_js").then(__webpack_require__.bind(__webpack_require__, /*! ../editor/module */ "../modules/nested-elements/assets/js/editor/module.js")); | |
| 440 | - elementor.modules.nestedElements.then(function (module) { | |
| 441 | - elementor.modules.nestedElements = new module.default(); | |
| 442 | - elementor.modules.elements.types.NestedElementBase = Promise.all(/*! import() */[__webpack_require__.e("vendors-node_modules_prop-types_index_js-node_modules_babel_runtime_helpers_slicedToArray_js"), __webpack_require__.e("modules_nested-elements_assets_js_editor_nested-element-types-base_js")]).then(__webpack_require__.bind(__webpack_require__, /*! ./nested-element-types-base */ "../modules/nested-elements/assets/js/editor/nested-element-types-base.js")); | |
| 443 | - elementor.modules.elements.types.NestedElementBase.then(function (nestedElementBaseModule) { | |
| 444 | - elementor.modules.elements.types.NestedElementBase = nestedElementBaseModule.default; | |
| 445 | - __webpack_require__.e(/*! import() */ "modules_nested-elements_assets_js_editor_views_view_js").then(__webpack_require__.bind(__webpack_require__, /*! ./views/view */ "../modules/nested-elements/assets/js/editor/views/view.js")).then(function (View) { | |
| 446 | - $e.components.get('nested-elements').exports = { | |
| 447 | - NestedView: View.default | |
| 448 | - }; | |
| 449 | - }).then(function () { | |
| 450 | - _events.default.dispatch(elementorCommon.elements.$window, 'elementor/nested-element-type-loaded'); | |
| 451 | - }); | |
| 452 | - }); | |
| 453 | - }); | |
| 454 | -}); | |
| 455 | -})(); | |
| 1377 | +//#endregion | |
| 1378 | +//#region node_modules/object-assign/index.js | |
| 1379 | +/* | |
| 1380 | + object-assign | |
| 1381 | + (c) Sindre Sorhus | |
| 1382 | + @license MIT | |
| 1383 | + */ | |
| 1384 | + var require_object_assign = /* @__PURE__ */ __commonJSMin(((exports, module) => { | |
| 1385 | + var getOwnPropertySymbols = Object.getOwnPropertySymbols; | |
| 1386 | + var hasOwnProperty = Object.prototype.hasOwnProperty; | |
| 1387 | + var propIsEnumerable = Object.prototype.propertyIsEnumerable; | |
| 1388 | + function toObject(val) { | |
| 1389 | + if (val === null || val === void 0) throw new TypeError("Object.assign cannot be called with null or undefined"); | |
| 1390 | + return Object(val); | |
| 1391 | + } | |
| 1392 | + function shouldUseNative() { | |
| 1393 | + try { | |
| 1394 | + if (!Object.assign) return false; | |
| 1395 | + var test1 = /* @__PURE__ */ new String("abc"); | |
| 1396 | + test1[5] = "de"; | |
| 1397 | + if (Object.getOwnPropertyNames(test1)[0] === "5") return false; | |
| 1398 | + var test2 = {}; | |
| 1399 | + for (var i = 0; i < 10; i++) test2["_" + String.fromCharCode(i)] = i; | |
| 1400 | + if (Object.getOwnPropertyNames(test2).map(function(n) { | |
| 1401 | + return test2[n]; | |
| 1402 | + }).join("") !== "0123456789") return false; | |
| 1403 | + var test3 = {}; | |
| 1404 | + "abcdefghijklmnopqrst".split("").forEach(function(letter) { | |
| 1405 | + test3[letter] = letter; | |
| 1406 | + }); | |
| 1407 | + if (Object.keys(Object.assign({}, test3)).join("") !== "abcdefghijklmnopqrst") return false; | |
| 1408 | + return true; | |
| 1409 | + } catch (err) { | |
| 1410 | + return false; | |
| 1411 | + } | |
| 1412 | + } | |
| 1413 | + module.exports = shouldUseNative() ? Object.assign : function(target, source) { | |
| 1414 | + var from; | |
| 1415 | + var to = toObject(target); | |
| 1416 | + var symbols; | |
| 1417 | + for (var s = 1; s < arguments.length; s++) { | |
| 1418 | + from = Object(arguments[s]); | |
| 1419 | + for (var key in from) if (hasOwnProperty.call(from, key)) to[key] = from[key]; | |
| 1420 | + if (getOwnPropertySymbols) { | |
| 1421 | + symbols = getOwnPropertySymbols(from); | |
| 1422 | + for (var i = 0; i < symbols.length; i++) if (propIsEnumerable.call(from, symbols[i])) to[symbols[i]] = from[symbols[i]]; | |
| 1423 | + } | |
| 1424 | + } | |
| 1425 | + return to; | |
| 1426 | + }; | |
| 1427 | + })); | |
| 456 | 1428 | |
| 457 | -/******/ })() | |
| 458 | -; | |
| 1429 | +//#endregion | |
| 1430 | +//#region node_modules/prop-types/lib/ReactPropTypesSecret.js | |
| 1431 | +/** | |
| 1432 | + * Copyright (c) 2013-present, Facebook, Inc. | |
| 1433 | + * | |
| 1434 | + * This source code is licensed under the MIT license found in the | |
| 1435 | + * LICENSE file in the root directory of this source tree. | |
| 1436 | + */ | |
| 1437 | + var require_ReactPropTypesSecret = /* @__PURE__ */ __commonJSMin(((exports, module) => { | |
| 1438 | + var ReactPropTypesSecret = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"; | |
| 1439 | + module.exports = ReactPropTypesSecret; | |
| 1440 | + })); | |
| 1441 | + | |
| 1442 | +//#endregion | |
| 1443 | +//#region node_modules/prop-types/lib/has.js | |
| 1444 | + var require_has = /* @__PURE__ */ __commonJSMin(((exports, module) => { | |
| 1445 | + module.exports = Function.call.bind(Object.prototype.hasOwnProperty); | |
| 1446 | + })); | |
| 1447 | + | |
| 1448 | +//#endregion | |
| 1449 | +//#region node_modules/prop-types/checkPropTypes.js | |
| 1450 | +/** | |
| 1451 | + * Copyright (c) 2013-present, Facebook, Inc. | |
| 1452 | + * | |
| 1453 | + * This source code is licensed under the MIT license found in the | |
| 1454 | + * LICENSE file in the root directory of this source tree. | |
| 1455 | + */ | |
| 1456 | + var require_checkPropTypes = /* @__PURE__ */ __commonJSMin(((exports, module) => { | |
| 1457 | + var printWarning = function() {}; | |
| 1458 | + var ReactPropTypesSecret = require_ReactPropTypesSecret(); | |
| 1459 | + var loggedTypeFailures = {}; | |
| 1460 | + var has = require_has(); | |
| 1461 | + printWarning = function(text) { | |
| 1462 | + var message = "Warning: " + text; | |
| 1463 | + if (typeof console !== "undefined") console.error(message); | |
| 1464 | + try { | |
| 1465 | + throw new Error(message); | |
| 1466 | + } catch (x) {} | |
| 1467 | + }; | |
| 1468 | + /** | |
| 1469 | + * Assert that the values match with the type specs. | |
| 1470 | + * Error messages are memorized and will only be shown once. | |
| 1471 | + * | |
| 1472 | + * @param {object} typeSpecs Map of name to a ReactPropType | |
| 1473 | + * @param {object} values Runtime values that need to be type-checked | |
| 1474 | + * @param {string} location e.g. "prop", "context", "child context" | |
| 1475 | + * @param {string} componentName Name of the component for error messages. | |
| 1476 | + * @param {?Function} getStack Returns the component stack. | |
| 1477 | + * @private | |
| 1478 | + */ | |
| 1479 | + function checkPropTypes(typeSpecs, values, location, componentName, getStack) { | |
| 1480 | + for (var typeSpecName in typeSpecs) if (has(typeSpecs, typeSpecName)) { | |
| 1481 | + var error; | |
| 1482 | + try { | |
| 1483 | + if (typeof typeSpecs[typeSpecName] !== "function") { | |
| 1484 | + var err = Error((componentName || "React class") + ": " + location + " type `" + typeSpecName + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof typeSpecs[typeSpecName] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."); | |
| 1485 | + err.name = "Invariant Violation"; | |
| 1486 | + throw err; | |
| 1487 | + } | |
| 1488 | + error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); | |
| 1489 | + } catch (ex) { | |
| 1490 | + error = ex; | |
| 1491 | + } | |
| 1492 | + if (error && !(error instanceof Error)) printWarning((componentName || "React class") + ": type specification of " + location + " `" + typeSpecName + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof error + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."); | |
| 1493 | + if (error instanceof Error && !(error.message in loggedTypeFailures)) { | |
| 1494 | + loggedTypeFailures[error.message] = true; | |
| 1495 | + var stack = getStack ? getStack() : ""; | |
| 1496 | + printWarning("Failed " + location + " type: " + error.message + (stack != null ? stack : "")); | |
| 1497 | + } | |
| 1498 | + } | |
| 1499 | + } | |
| 1500 | + /** | |
| 1501 | + * Resets warning cache when testing. | |
| 1502 | + * | |
| 1503 | + * @private | |
| 1504 | + */ | |
| 1505 | + checkPropTypes.resetWarningCache = function() { | |
| 1506 | + loggedTypeFailures = {}; | |
| 1507 | + }; | |
| 1508 | + module.exports = checkPropTypes; | |
| 1509 | + })); | |
| 1510 | + | |
| 1511 | +//#endregion | |
| 1512 | +//#region node_modules/prop-types/factoryWithTypeCheckers.js | |
| 1513 | +/** | |
| 1514 | + * Copyright (c) 2013-present, Facebook, Inc. | |
| 1515 | + * | |
| 1516 | + * This source code is licensed under the MIT license found in the | |
| 1517 | + * LICENSE file in the root directory of this source tree. | |
| 1518 | + */ | |
| 1519 | + var require_factoryWithTypeCheckers = /* @__PURE__ */ __commonJSMin(((exports, module) => { | |
| 1520 | + var ReactIs = require_react_is(); | |
| 1521 | + var assign = require_object_assign(); | |
| 1522 | + var ReactPropTypesSecret = require_ReactPropTypesSecret(); | |
| 1523 | + var has = require_has(); | |
| 1524 | + var checkPropTypes = require_checkPropTypes(); | |
| 1525 | + var printWarning = function() {}; | |
| 1526 | + printWarning = function(text) { | |
| 1527 | + var message = "Warning: " + text; | |
| 1528 | + if (typeof console !== "undefined") console.error(message); | |
| 1529 | + try { | |
| 1530 | + throw new Error(message); | |
| 1531 | + } catch (x) {} | |
| 1532 | + }; | |
| 1533 | + function emptyFunctionThatReturnsNull() { | |
| 1534 | + return null; | |
| 1535 | + } | |
| 1536 | + module.exports = function(isValidElement, throwOnDirectAccess) { | |
| 1537 | + var ITERATOR_SYMBOL = typeof Symbol === "function" && Symbol.iterator; | |
| 1538 | + var FAUX_ITERATOR_SYMBOL = "@@iterator"; | |
| 1539 | + /** | |
| 1540 | + * Returns the iterator method function contained on the iterable object. | |
| 1541 | + * | |
| 1542 | + * Be sure to invoke the function with the iterable as context: | |
| 1543 | + * | |
| 1544 | + * var iteratorFn = getIteratorFn(myIterable); | |
| 1545 | + * if (iteratorFn) { | |
| 1546 | + * var iterator = iteratorFn.call(myIterable); | |
| 1547 | + * ... | |
| 1548 | + * } | |
| 1549 | + * | |
| 1550 | + * @param {?object} maybeIterable | |
| 1551 | + * @return {?function} | |
| 1552 | + */ | |
| 1553 | + function getIteratorFn(maybeIterable) { | |
| 1554 | + var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]); | |
| 1555 | + if (typeof iteratorFn === "function") return iteratorFn; | |
| 1556 | + } | |
| 1557 | + /** | |
| 1558 | + * Collection of methods that allow declaration and validation of props that are | |
| 1559 | + * supplied to React components. Example usage: | |
| 1560 | + * | |
| 1561 | + * var Props = require('ReactPropTypes'); | |
| 1562 | + * var MyArticle = React.createClass({ | |
| 1563 | + * propTypes: { | |
| 1564 | + * // An optional string prop named "description". | |
| 1565 | + * description: Props.string, | |
| 1566 | + * | |
| 1567 | + * // A required enum prop named "category". | |
| 1568 | + * category: Props.oneOf(['News','Photos']).isRequired, | |
| 1569 | + * | |
| 1570 | + * // A prop named "dialog" that requires an instance of Dialog. | |
| 1571 | + * dialog: Props.instanceOf(Dialog).isRequired | |
| 1572 | + * }, | |
| 1573 | + * render: function() { ... } | |
| 1574 | + * }); | |
| 1575 | + * | |
| 1576 | + * A more formal specification of how these methods are used: | |
| 1577 | + * | |
| 1578 | + * type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...) | |
| 1579 | + * decl := ReactPropTypes.{type}(.isRequired)? | |
| 1580 | + * | |
| 1581 | + * Each and every declaration produces a function with the same signature. This | |
| 1582 | + * allows the creation of custom validation functions. For example: | |
| 1583 | + * | |
| 1584 | + * var MyLink = React.createClass({ | |
| 1585 | + * propTypes: { | |
| 1586 | + * // An optional string or URI prop named "href". | |
| 1587 | + * href: function(props, propName, componentName) { | |
| 1588 | + * var propValue = props[propName]; | |
| 1589 | + * if (propValue != null && typeof propValue !== 'string' && | |
| 1590 | + * !(propValue instanceof URI)) { | |
| 1591 | + * return new Error( | |
| 1592 | + * 'Expected a string or an URI for ' + propName + ' in ' + | |
| 1593 | + * componentName | |
| 1594 | + * ); | |
| 1595 | + * } | |
| 1596 | + * } | |
| 1597 | + * }, | |
| 1598 | + * render: function() {...} | |
| 1599 | + * }); | |
| 1600 | + * | |
| 1601 | + * @internal | |
| 1602 | + */ | |
| 1603 | + var ANONYMOUS = "<<anonymous>>"; | |
| 1604 | + var ReactPropTypes = { | |
| 1605 | + array: createPrimitiveTypeChecker("array"), | |
| 1606 | + bigint: createPrimitiveTypeChecker("bigint"), | |
| 1607 | + bool: createPrimitiveTypeChecker("boolean"), | |
| 1608 | + func: createPrimitiveTypeChecker("function"), | |
| 1609 | + number: createPrimitiveTypeChecker("number"), | |
| 1610 | + object: createPrimitiveTypeChecker("object"), | |
| 1611 | + string: createPrimitiveTypeChecker("string"), | |
| 1612 | + symbol: createPrimitiveTypeChecker("symbol"), | |
| 1613 | + any: createAnyTypeChecker(), | |
| 1614 | + arrayOf: createArrayOfTypeChecker, | |
| 1615 | + element: createElementTypeChecker(), | |
| 1616 | + elementType: createElementTypeTypeChecker(), | |
| 1617 | + instanceOf: createInstanceTypeChecker, | |
| 1618 | + node: createNodeChecker(), | |
| 1619 | + objectOf: createObjectOfTypeChecker, | |
| 1620 | + oneOf: createEnumTypeChecker, | |
| 1621 | + oneOfType: createUnionTypeChecker, | |
| 1622 | + shape: createShapeTypeChecker, | |
| 1623 | + exact: createStrictShapeTypeChecker | |
| 1624 | + }; | |
| 1625 | + /** | |
| 1626 | + * inlined Object.is polyfill to avoid requiring consumers ship their own | |
| 1627 | + * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is | |
| 1628 | + */ | |
| 1629 | + function is(x, y) { | |
| 1630 | + if (x === y) return x !== 0 || 1 / x === 1 / y; | |
| 1631 | + else return x !== x && y !== y; | |
| 1632 | + } | |
| 1633 | + /** | |
| 1634 | + * We use an Error-like object for backward compatibility as people may call | |
| 1635 | + * PropTypes directly and inspect their output. However, we don't use real | |
| 1636 | + * Errors anymore. We don't inspect their stack anyway, and creating them | |
| 1637 | + * is prohibitively expensive if they are created too often, such as what | |
| 1638 | + * happens in oneOfType() for any type before the one that matched. | |
| 1639 | + */ | |
| 1640 | + function PropTypeError(message, data) { | |
| 1641 | + this.message = message; | |
| 1642 | + this.data = data && typeof data === "object" ? data : {}; | |
| 1643 | + this.stack = ""; | |
| 1644 | + } | |
| 1645 | + PropTypeError.prototype = Error.prototype; | |
| 1646 | + function createChainableTypeChecker(validate) { | |
| 1647 | + var manualPropTypeCallCache = {}; | |
| 1648 | + var manualPropTypeWarningCount = 0; | |
| 1649 | + function checkType(isRequired, props, propName, componentName, location, propFullName, secret) { | |
| 1650 | + componentName = componentName || ANONYMOUS; | |
| 1651 | + propFullName = propFullName || propName; | |
| 1652 | + if (secret !== ReactPropTypesSecret) { | |
| 1653 | + if (throwOnDirectAccess) { | |
| 1654 | + var err = /* @__PURE__ */ new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types"); | |
| 1655 | + err.name = "Invariant Violation"; | |
| 1656 | + throw err; | |
| 1657 | + } else if (typeof console !== "undefined") { | |
| 1658 | + var cacheKey = componentName + ":" + propName; | |
| 1659 | + if (!manualPropTypeCallCache[cacheKey] && manualPropTypeWarningCount < 3) { | |
| 1660 | + printWarning("You are manually calling a React.PropTypes validation function for the `" + propFullName + "` prop on `" + componentName + "`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."); | |
| 1661 | + manualPropTypeCallCache[cacheKey] = true; | |
| 1662 | + manualPropTypeWarningCount++; | |
| 1663 | + } | |
| 1664 | + } | |
| 1665 | + } | |
| 1666 | + if (props[propName] == null) { | |
| 1667 | + if (isRequired) { | |
| 1668 | + if (props[propName] === null) return new PropTypeError("The " + location + " `" + propFullName + "` is marked as required " + ("in `" + componentName + "`, but its value is `null`.")); | |
| 1669 | + return new PropTypeError("The " + location + " `" + propFullName + "` is marked as required in " + ("`" + componentName + "`, but its value is `undefined`.")); | |
| 1670 | + } | |
| 1671 | + return null; | |
| 1672 | + } else return validate(props, propName, componentName, location, propFullName); | |
| 1673 | + } | |
| 1674 | + var chainedCheckType = checkType.bind(null, false); | |
| 1675 | + chainedCheckType.isRequired = checkType.bind(null, true); | |
| 1676 | + return chainedCheckType; | |
| 1677 | + } | |
| 1678 | + function createPrimitiveTypeChecker(expectedType) { | |
| 1679 | + function validate(props, propName, componentName, location, propFullName, secret) { | |
| 1680 | + var propValue = props[propName]; | |
| 1681 | + if (getPropType(propValue) !== expectedType) { | |
| 1682 | + var preciseType = getPreciseType(propValue); | |
| 1683 | + return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type " + ("`" + preciseType + "` supplied to `" + componentName + "`, expected ") + ("`" + expectedType + "`."), { expectedType }); | |
| 1684 | + } | |
| 1685 | + return null; | |
| 1686 | + } | |
| 1687 | + return createChainableTypeChecker(validate); | |
| 1688 | + } | |
| 1689 | + function createAnyTypeChecker() { | |
| 1690 | + return createChainableTypeChecker(emptyFunctionThatReturnsNull); | |
| 1691 | + } | |
| 1692 | + function createArrayOfTypeChecker(typeChecker) { | |
| 1693 | + function validate(props, propName, componentName, location, propFullName) { | |
| 1694 | + if (typeof typeChecker !== "function") return new PropTypeError("Property `" + propFullName + "` of component `" + componentName + "` has invalid PropType notation inside arrayOf."); | |
| 1695 | + var propValue = props[propName]; | |
| 1696 | + if (!Array.isArray(propValue)) { | |
| 1697 | + var propType = getPropType(propValue); | |
| 1698 | + return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type " + ("`" + propType + "` supplied to `" + componentName + "`, expected an array.")); | |
| 1699 | + } | |
| 1700 | + for (var i = 0; i < propValue.length; i++) { | |
| 1701 | + var error = typeChecker(propValue, i, componentName, location, propFullName + "[" + i + "]", ReactPropTypesSecret); | |
| 1702 | + if (error instanceof Error) return error; | |
| 1703 | + } | |
| 1704 | + return null; | |
| 1705 | + } | |
| 1706 | + return createChainableTypeChecker(validate); | |
| 1707 | + } | |
| 1708 | + function createElementTypeChecker() { | |
| 1709 | + function validate(props, propName, componentName, location, propFullName) { | |
| 1710 | + var propValue = props[propName]; | |
| 1711 | + if (!isValidElement(propValue)) { | |
| 1712 | + var propType = getPropType(propValue); | |
| 1713 | + return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type " + ("`" + propType + "` supplied to `" + componentName + "`, expected a single ReactElement.")); | |
| 1714 | + } | |
| 1715 | + return null; | |
| 1716 | + } | |
| 1717 | + return createChainableTypeChecker(validate); | |
| 1718 | + } | |
| 1719 | + function createElementTypeTypeChecker() { | |
| 1720 | + function validate(props, propName, componentName, location, propFullName) { | |
| 1721 | + var propValue = props[propName]; | |
| 1722 | + if (!ReactIs.isValidElementType(propValue)) { | |
| 1723 | + var propType = getPropType(propValue); | |
| 1724 | + return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type " + ("`" + propType + "` supplied to `" + componentName + "`, expected a single ReactElement type.")); | |
| 1725 | + } | |
| 1726 | + return null; | |
| 1727 | + } | |
| 1728 | + return createChainableTypeChecker(validate); | |
| 1729 | + } | |
| 1730 | + function createInstanceTypeChecker(expectedClass) { | |
| 1731 | + function validate(props, propName, componentName, location, propFullName) { | |
| 1732 | + if (!(props[propName] instanceof expectedClass)) { | |
| 1733 | + var expectedClassName = expectedClass.name || ANONYMOUS; | |
| 1734 | + var actualClassName = getClassName(props[propName]); | |
| 1735 | + return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type " + ("`" + actualClassName + "` supplied to `" + componentName + "`, expected ") + ("instance of `" + expectedClassName + "`.")); | |
| 1736 | + } | |
| 1737 | + return null; | |
| 1738 | + } | |
| 1739 | + return createChainableTypeChecker(validate); | |
| 1740 | + } | |
| 1741 | + function createEnumTypeChecker(expectedValues) { | |
| 1742 | + if (!Array.isArray(expectedValues)) { | |
| 1743 | + if (arguments.length > 1) printWarning("Invalid arguments supplied to oneOf, expected an array, got " + arguments.length + " arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."); | |
| 1744 | + else printWarning("Invalid argument supplied to oneOf, expected an array."); | |
| 1745 | + return emptyFunctionThatReturnsNull; | |
| 1746 | + } | |
| 1747 | + function validate(props, propName, componentName, location, propFullName) { | |
| 1748 | + var propValue = props[propName]; | |
| 1749 | + for (var i = 0; i < expectedValues.length; i++) if (is(propValue, expectedValues[i])) return null; | |
| 1750 | + var valuesString = JSON.stringify(expectedValues, function replacer(key, value) { | |
| 1751 | + if (getPreciseType(value) === "symbol") return String(value); | |
| 1752 | + return value; | |
| 1753 | + }); | |
| 1754 | + return new PropTypeError("Invalid " + location + " `" + propFullName + "` of value `" + String(propValue) + "` " + ("supplied to `" + componentName + "`, expected one of " + valuesString + ".")); | |
| 1755 | + } | |
| 1756 | + return createChainableTypeChecker(validate); | |
| 1757 | + } | |
| 1758 | + function createObjectOfTypeChecker(typeChecker) { | |
| 1759 | + function validate(props, propName, componentName, location, propFullName) { | |
| 1760 | + if (typeof typeChecker !== "function") return new PropTypeError("Property `" + propFullName + "` of component `" + componentName + "` has invalid PropType notation inside objectOf."); | |
| 1761 | + var propValue = props[propName]; | |
| 1762 | + var propType = getPropType(propValue); | |
| 1763 | + if (propType !== "object") return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type " + ("`" + propType + "` supplied to `" + componentName + "`, expected an object.")); | |
| 1764 | + for (var key in propValue) if (has(propValue, key)) { | |
| 1765 | + var error = typeChecker(propValue, key, componentName, location, propFullName + "." + key, ReactPropTypesSecret); | |
| 1766 | + if (error instanceof Error) return error; | |
| 1767 | + } | |
| 1768 | + return null; | |
| 1769 | + } | |
| 1770 | + return createChainableTypeChecker(validate); | |
| 1771 | + } | |
| 1772 | + function createUnionTypeChecker(arrayOfTypeCheckers) { | |
| 1773 | + if (!Array.isArray(arrayOfTypeCheckers)) { | |
| 1774 | + printWarning("Invalid argument supplied to oneOfType, expected an instance of array."); | |
| 1775 | + return emptyFunctionThatReturnsNull; | |
| 1776 | + } | |
| 1777 | + for (var i = 0; i < arrayOfTypeCheckers.length; i++) { | |
| 1778 | + var checker = arrayOfTypeCheckers[i]; | |
| 1779 | + if (typeof checker !== "function") { | |
| 1780 | + printWarning("Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + getPostfixForTypeWarning(checker) + " at index " + i + "."); | |
| 1781 | + return emptyFunctionThatReturnsNull; | |
| 1782 | + } | |
| 1783 | + } | |
| 1784 | + function validate(props, propName, componentName, location, propFullName) { | |
| 1785 | + var expectedTypes = []; | |
| 1786 | + for (var i = 0; i < arrayOfTypeCheckers.length; i++) { | |
| 1787 | + var checker = arrayOfTypeCheckers[i]; | |
| 1788 | + var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret); | |
| 1789 | + if (checkerResult == null) return null; | |
| 1790 | + if (checkerResult.data && has(checkerResult.data, "expectedType")) expectedTypes.push(checkerResult.data.expectedType); | |
| 1791 | + } | |
| 1792 | + var expectedTypesMessage = expectedTypes.length > 0 ? ", expected one of type [" + expectedTypes.join(", ") + "]" : ""; | |
| 1793 | + return new PropTypeError("Invalid " + location + " `" + propFullName + "` supplied to " + ("`" + componentName + "`" + expectedTypesMessage + ".")); | |
| 1794 | + } | |
| 1795 | + return createChainableTypeChecker(validate); | |
| 1796 | + } | |
| 1797 | + function createNodeChecker() { | |
| 1798 | + function validate(props, propName, componentName, location, propFullName) { | |
| 1799 | + if (!isNode(props[propName])) return new PropTypeError("Invalid " + location + " `" + propFullName + "` supplied to " + ("`" + componentName + "`, expected a ReactNode.")); | |
| 1800 | + return null; | |
| 1801 | + } | |
| 1802 | + return createChainableTypeChecker(validate); | |
| 1803 | + } | |
| 1804 | + function invalidValidatorError(componentName, location, propFullName, key, type) { | |
| 1805 | + return new PropTypeError((componentName || "React class") + ": " + location + " type `" + propFullName + "." + key + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + type + "`."); | |
| 1806 | + } | |
| 1807 | + function createShapeTypeChecker(shapeTypes) { | |
| 1808 | + function validate(props, propName, componentName, location, propFullName) { | |
| 1809 | + var propValue = props[propName]; | |
| 1810 | + var propType = getPropType(propValue); | |
| 1811 | + if (propType !== "object") return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type `" + propType + "` " + ("supplied to `" + componentName + "`, expected `object`.")); | |
| 1812 | + for (var key in shapeTypes) { | |
| 1813 | + var checker = shapeTypes[key]; | |
| 1814 | + if (typeof checker !== "function") return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker)); | |
| 1815 | + var error = checker(propValue, key, componentName, location, propFullName + "." + key, ReactPropTypesSecret); | |
| 1816 | + if (error) return error; | |
| 1817 | + } | |
| 1818 | + return null; | |
| 1819 | + } | |
| 1820 | + return createChainableTypeChecker(validate); | |
| 1821 | + } | |
| 1822 | + function createStrictShapeTypeChecker(shapeTypes) { | |
| 1823 | + function validate(props, propName, componentName, location, propFullName) { | |
| 1824 | + var propValue = props[propName]; | |
| 1825 | + var propType = getPropType(propValue); | |
| 1826 | + if (propType !== "object") return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type `" + propType + "` " + ("supplied to `" + componentName + "`, expected `object`.")); | |
| 1827 | + for (var key in assign({}, props[propName], shapeTypes)) { | |
| 1828 | + var checker = shapeTypes[key]; | |
| 1829 | + if (has(shapeTypes, key) && typeof checker !== "function") return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker)); | |
| 1830 | + if (!checker) return new PropTypeError("Invalid " + location + " `" + propFullName + "` key `" + key + "` supplied to `" + componentName + "`.\nBad object: " + JSON.stringify(props[propName], null, " ") + "\nValid keys: " + JSON.stringify(Object.keys(shapeTypes), null, " ")); | |
| 1831 | + var error = checker(propValue, key, componentName, location, propFullName + "." + key, ReactPropTypesSecret); | |
| 1832 | + if (error) return error; | |
| 1833 | + } | |
| 1834 | + return null; | |
| 1835 | + } | |
| 1836 | + return createChainableTypeChecker(validate); | |
| 1837 | + } | |
| 1838 | + function isNode(propValue) { | |
| 1839 | + switch (typeof propValue) { | |
| 1840 | + case "number": | |
| 1841 | + case "string": | |
| 1842 | + case "undefined": return true; | |
| 1843 | + case "boolean": return !propValue; | |
| 1844 | + case "object": | |
| 1845 | + if (Array.isArray(propValue)) return propValue.every(isNode); | |
| 1846 | + if (propValue === null || isValidElement(propValue)) return true; | |
| 1847 | + var iteratorFn = getIteratorFn(propValue); | |
| 1848 | + if (iteratorFn) { | |
| 1849 | + var iterator = iteratorFn.call(propValue); | |
| 1850 | + var step; | |
| 1851 | + if (iteratorFn !== propValue.entries) { | |
| 1852 | + while (!(step = iterator.next()).done) if (!isNode(step.value)) return false; | |
| 1853 | + } else while (!(step = iterator.next()).done) { | |
| 1854 | + var entry = step.value; | |
| 1855 | + if (entry) { | |
| 1856 | + if (!isNode(entry[1])) return false; | |
| 1857 | + } | |
| 1858 | + } | |
| 1859 | + } else return false; | |
| 1860 | + return true; | |
| 1861 | + default: return false; | |
| 1862 | + } | |
| 1863 | + } | |
| 1864 | + function isSymbol(propType, propValue) { | |
| 1865 | + if (propType === "symbol") return true; | |
| 1866 | + if (!propValue) return false; | |
| 1867 | + if (propValue["@@toStringTag"] === "Symbol") return true; | |
| 1868 | + if (typeof Symbol === "function" && propValue instanceof Symbol) return true; | |
| 1869 | + return false; | |
| 1870 | + } | |
| 1871 | + function getPropType(propValue) { | |
| 1872 | + var propType = typeof propValue; | |
| 1873 | + if (Array.isArray(propValue)) return "array"; | |
| 1874 | + if (propValue instanceof RegExp) return "object"; | |
| 1875 | + if (isSymbol(propType, propValue)) return "symbol"; | |
| 1876 | + return propType; | |
| 1877 | + } | |
| 1878 | + function getPreciseType(propValue) { | |
| 1879 | + if (typeof propValue === "undefined" || propValue === null) return "" + propValue; | |
| 1880 | + var propType = getPropType(propValue); | |
| 1881 | + if (propType === "object") { | |
| 1882 | + if (propValue instanceof Date) return "date"; | |
| 1883 | + else if (propValue instanceof RegExp) return "regexp"; | |
| 1884 | + } | |
| 1885 | + return propType; | |
| 1886 | + } | |
| 1887 | + function getPostfixForTypeWarning(value) { | |
| 1888 | + var type = getPreciseType(value); | |
| 1889 | + switch (type) { | |
| 1890 | + case "array": | |
| 1891 | + case "object": return "an " + type; | |
| 1892 | + case "boolean": | |
| 1893 | + case "date": | |
| 1894 | + case "regexp": return "a " + type; | |
| 1895 | + default: return type; | |
| 1896 | + } | |
| 1897 | + } | |
| 1898 | + function getClassName(propValue) { | |
| 1899 | + if (!propValue.constructor || !propValue.constructor.name) return ANONYMOUS; | |
| 1900 | + return propValue.constructor.name; | |
| 1901 | + } | |
| 1902 | + ReactPropTypes.checkPropTypes = checkPropTypes; | |
| 1903 | + ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache; | |
| 1904 | + ReactPropTypes.PropTypes = ReactPropTypes; | |
| 1905 | + return ReactPropTypes; | |
| 1906 | + }; | |
| 1907 | + })); | |
| 1908 | + | |
| 1909 | +//#endregion | |
| 1910 | +//#region node_modules/prop-types/index.js | |
| 1911 | + var require_prop_types = /* @__PURE__ */ __commonJSMin(((exports, module) => { | |
| 1912 | + var ReactIs = require_react_is(); | |
| 1913 | + var throwOnDirectAccess = true; | |
| 1914 | + module.exports = require_factoryWithTypeCheckers()(ReactIs.isElement, throwOnDirectAccess); | |
| 1915 | + })); | |
| 1916 | + | |
| 1917 | +//#endregion | |
| 1918 | +//#region node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js | |
| 1919 | + function _arrayWithHoles(r) { | |
| 1920 | + if (Array.isArray(r)) return r; | |
| 1921 | + } | |
| 1922 | + var init_arrayWithHoles = __esmMin((() => {})); | |
| 1923 | + | |
| 1924 | +//#endregion | |
| 1925 | +//#region node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js | |
| 1926 | + function _iterableToArrayLimit(r, l) { | |
| 1927 | + var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; | |
| 1928 | + if (null != t) { | |
| 1929 | + var e; | |
| 1930 | + var n; | |
| 1931 | + var i; | |
| 1932 | + var u; | |
| 1933 | + var a = []; | |
| 1934 | + var f = !0; | |
| 1935 | + var o = !1; | |
| 1936 | + try { | |
| 1937 | + if (i = (t = t.call(r)).next, 0 === l) { | |
| 1938 | + if (Object(t) !== t) return; | |
| 1939 | + f = !1; | |
| 1940 | + } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); | |
| 1941 | + } catch (r) { | |
| 1942 | + o = !0, n = r; | |
| 1943 | + } finally { | |
| 1944 | + try { | |
| 1945 | + if (!f && null != t["return"] && (u = t["return"](), Object(u) !== u)) return; | |
| 1946 | + } finally { | |
| 1947 | + if (o) throw n; | |
| 1948 | + } | |
| 1949 | + } | |
| 1950 | + return a; | |
| 1951 | + } | |
| 1952 | + } | |
| 1953 | + var init_iterableToArrayLimit = __esmMin((() => {})); | |
| 1954 | + | |
| 1955 | +//#endregion | |
| 1956 | +//#region node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js | |
| 1957 | + function _arrayLikeToArray(r, a) { | |
| 1958 | + (null == a || a > r.length) && (a = r.length); | |
| 1959 | + for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; | |
| 1960 | + return n; | |
| 1961 | + } | |
| 1962 | + var init_arrayLikeToArray = __esmMin((() => {})); | |
| 1963 | + | |
| 1964 | +//#endregion | |
| 1965 | +//#region node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js | |
| 1966 | + function _unsupportedIterableToArray(r, a) { | |
| 1967 | + if (r) { | |
| 1968 | + if ("string" == typeof r) return _arrayLikeToArray(r, a); | |
| 1969 | + var t = {}.toString.call(r).slice(8, -1); | |
| 1970 | + 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; | |
| 1971 | + } | |
| 1972 | + } | |
| 1973 | + var init_unsupportedIterableToArray = __esmMin((() => { | |
| 1974 | + init_arrayLikeToArray(); | |
| 1975 | + })); | |
| 1976 | + | |
| 1977 | +//#endregion | |
| 1978 | +//#region node_modules/@babel/runtime/helpers/esm/nonIterableRest.js | |
| 1979 | + function _nonIterableRest() { | |
| 1980 | + throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); | |
| 1981 | + } | |
| 1982 | + var init_nonIterableRest = __esmMin((() => {})); | |
| 1983 | + | |
| 1984 | +//#endregion | |
| 1985 | +//#region node_modules/@babel/runtime/helpers/esm/slicedToArray.js | |
| 1986 | + function _slicedToArray(r, e) { | |
| 1987 | + return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); | |
| 1988 | + } | |
| 1989 | + var init_slicedToArray = __esmMin((() => { | |
| 1990 | + init_arrayWithHoles(); | |
| 1991 | + init_iterableToArrayLimit(); | |
| 1992 | + init_unsupportedIterableToArray(); | |
| 1993 | + init_nonIterableRest(); | |
| 1994 | + })); | |
| 1995 | + | |
| 1996 | +//#endregion | |
| 1997 | +//#region modules/nested-elements/assets/js/editor/views/add-section-area.js | |
| 1998 | + function AddSectionArea(props) { | |
| 1999 | + var addAreaElementRef = (0, react.useRef)(); | |
| 2000 | + var containerHelper = elementor.helpers.container; | |
| 2001 | + (0, react.useEffect)(function() { | |
| 2002 | + var $addAreaElementRef = jQuery(addAreaElementRef.current); | |
| 2003 | + var defaultDroppableOptions = props.container.view.getDroppableOptions(); | |
| 2004 | + defaultDroppableOptions.placeholder = false; | |
| 2005 | + defaultDroppableOptions.items = "> .elementor-add-section-inner"; | |
| 2006 | + defaultDroppableOptions.hasDraggingOnChildClass = "elementor-dragging-on-child"; | |
| 2007 | + $addAreaElementRef.html5Droppable(defaultDroppableOptions); | |
| 2008 | + return function() { | |
| 2009 | + $addAreaElementRef.html5Droppable("destroy"); | |
| 2010 | + }; | |
| 2011 | + }, []); | |
| 2012 | + return /*#__PURE__*/ react.default.createElement("div", { | |
| 2013 | + className: "elementor-add-section", | |
| 2014 | + onClick: function onClick() { | |
| 2015 | + return containerHelper.openEditMode(props.container); | |
| 2016 | + }, | |
| 2017 | + ref: addAreaElementRef, | |
| 2018 | + role: "button", | |
| 2019 | + tabIndex: "0" | |
| 2020 | + }, /*#__PURE__*/ react.default.createElement("div", { className: "elementor-add-section-inner" }, /*#__PURE__*/ react.default.createElement("div", { className: "e-view elementor-add-new-section" }, /*#__PURE__*/ react.default.createElement("button", { | |
| 2021 | + type: "button", | |
| 2022 | + className: "elementor-add-section-area-button elementor-add-section-button", | |
| 2023 | + "aria-label": (0, _wordpress_i18n.__)("Add new container", "elementor"), | |
| 2024 | + onClick: function handleAddContainerClick() { | |
| 2025 | + props.setIsRenderPresets(true); | |
| 2026 | + } | |
| 2027 | + }, /*#__PURE__*/ react.default.createElement("i", { | |
| 2028 | + className: "eicon-plus", | |
| 2029 | + "aria-hidden": "true" | |
| 2030 | + })), /*#__PURE__*/ react.default.createElement("div", { className: "elementor-add-section-drag-title" }, (0, _wordpress_i18n.__)("Drag widget here", "elementor"))))); | |
| 2031 | + } | |
| 2032 | + var import_prop_types$2; | |
| 2033 | + var init_add_section_area = __esmMin((() => { | |
| 2034 | + import_prop_types$2 = /* @__PURE__ */ __toESM(require_prop_types()); | |
| 2035 | + AddSectionArea.propTypes = { | |
| 2036 | + container: import_prop_types$2.default.object.isRequired, | |
| 2037 | + setIsRenderPresets: import_prop_types$2.default.func.isRequired | |
| 2038 | + }; | |
| 2039 | + })); | |
| 2040 | + | |
| 2041 | +//#endregion | |
| 2042 | +//#region assets/dev/js/editor/utils/editor-one-events.js | |
| 2043 | + function ownKeys$1(e, r) { | |
| 2044 | + var t = Object.keys(e); | |
| 2045 | + if (Object.getOwnPropertySymbols) { | |
| 2046 | + var o = Object.getOwnPropertySymbols(e); | |
| 2047 | + r && (o = o.filter(function(r) { | |
| 2048 | + return Object.getOwnPropertyDescriptor(e, r).enumerable; | |
| 2049 | + })), t.push.apply(t, o); | |
| 2050 | + } | |
| 2051 | + return t; | |
| 2052 | + } | |
| 2053 | + function _objectSpread$1(e) { | |
| 2054 | + for (var r = 1; r < arguments.length; r++) { | |
| 2055 | + var t = null != arguments[r] ? arguments[r] : {}; | |
| 2056 | + r % 2 ? ownKeys$1(Object(t), !0).forEach(function(r) { | |
| 2057 | + _defineProperty(e, r, t[r]); | |
| 2058 | + }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$1(Object(t)).forEach(function(r) { | |
| 2059 | + Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); | |
| 2060 | + }); | |
| 2061 | + } | |
| 2062 | + return e; | |
| 2063 | + } | |
| 2064 | + var EditorOneEventManager; | |
| 2065 | + var init_editor_one_events = __esmMin((() => { | |
| 2066 | + init_defineProperty(); | |
| 2067 | + init_classCallCheck(); | |
| 2068 | + init_createClass(); | |
| 2069 | + __name(ownKeys$1, "ownKeys"); | |
| 2070 | + __name(_objectSpread$1, "_objectSpread"); | |
| 2071 | + EditorOneEventManager = /*#__PURE__*/ function() { | |
| 2072 | + function EditorOneEventManager() { | |
| 2073 | + _classCallCheck(this, EditorOneEventManager); | |
| 2074 | + } | |
| 2075 | + return _createClass(EditorOneEventManager, null, [ | |
| 2076 | + { | |
| 2077 | + key: "getEventsManager", | |
| 2078 | + value: function getEventsManager() { | |
| 2079 | + var _elementorCommon; | |
| 2080 | + return (_elementorCommon = elementorCommon) === null || _elementorCommon === void 0 ? void 0 : _elementorCommon.eventsManager; | |
| 2081 | + } | |
| 2082 | + }, | |
| 2083 | + { | |
| 2084 | + key: "getConfig", | |
| 2085 | + value: function getConfig() { | |
| 2086 | + var _this$getEventsManage; | |
| 2087 | + return (_this$getEventsManage = this.getEventsManager()) === null || _this$getEventsManage === void 0 ? void 0 : _this$getEventsManage.config; | |
| 2088 | + } | |
| 2089 | + }, | |
| 2090 | + { | |
| 2091 | + key: "canSendEvents", | |
| 2092 | + value: function canSendEvents() { | |
| 2093 | + var _elementorCommon2; | |
| 2094 | + return ((_elementorCommon2 = elementorCommon) === null || _elementorCommon2 === void 0 || (_elementorCommon2 = _elementorCommon2.config) === null || _elementorCommon2 === void 0 || (_elementorCommon2 = _elementorCommon2.editor_events) === null || _elementorCommon2 === void 0 ? void 0 : _elementorCommon2.can_send_events) || false; | |
| 2095 | + } | |
| 2096 | + }, | |
| 2097 | + { | |
| 2098 | + key: "isEventsManagerAvailable", | |
| 2099 | + value: function isEventsManagerAvailable() { | |
| 2100 | + var eventsManager = this.getEventsManager(); | |
| 2101 | + return eventsManager && "function" === typeof eventsManager.dispatchEvent; | |
| 2102 | + } | |
| 2103 | + }, | |
| 2104 | + { | |
| 2105 | + key: "dispatchEvent", | |
| 2106 | + value: function dispatchEvent(eventName, payload) { | |
| 2107 | + try { | |
| 2108 | + if (!this.isEventsManagerAvailable() || !this.canSendEvents()) return false; | |
| 2109 | + this.getEventsManager().dispatchEvent(eventName, payload); | |
| 2110 | + return true; | |
| 2111 | + } catch (error) { | |
| 2112 | + return false; | |
| 2113 | + } | |
| 2114 | + } | |
| 2115 | + }, | |
| 2116 | + { | |
| 2117 | + key: "toLowerSnake", | |
| 2118 | + value: function toLowerSnake(value) { | |
| 2119 | + if (!value || "string" !== typeof value) return value; | |
| 2120 | + return value.replace(/\s+/g, "_").toLowerCase(); | |
| 2121 | + } | |
| 2122 | + }, | |
| 2123 | + { | |
| 2124 | + key: "decodeHtmlEntities", | |
| 2125 | + value: function decodeHtmlEntities(text) { | |
| 2126 | + if (!text || "string" !== typeof text) return text; | |
| 2127 | + return new DOMParser().parseFromString(text, "text/html").body.textContent || text; | |
| 2128 | + } | |
| 2129 | + }, | |
| 2130 | + { | |
| 2131 | + key: "isInEditorContext", | |
| 2132 | + value: function isInEditorContext() { | |
| 2133 | + var _window$elementor; | |
| 2134 | + return "undefined" !== typeof window.elementor && !!((_window$elementor = window.elementor) !== null && _window$elementor !== void 0 && _window$elementor.documents); | |
| 2135 | + } | |
| 2136 | + }, | |
| 2137 | + { | |
| 2138 | + key: "getFinderContext", | |
| 2139 | + value: function getFinderContext() { | |
| 2140 | + var _config$appTypes; | |
| 2141 | + var _config$appTypes2; | |
| 2142 | + var _config$locations; | |
| 2143 | + var _config$locations2; | |
| 2144 | + var config = this.getConfig(); | |
| 2145 | + var isEditor = this.isInEditorContext(); | |
| 2146 | + return { | |
| 2147 | + windowName: isEditor ? config === null || config === void 0 || (_config$appTypes = config.appTypes) === null || _config$appTypes === void 0 ? void 0 : _config$appTypes.editor : config === null || config === void 0 || (_config$appTypes2 = config.appTypes) === null || _config$appTypes2 === void 0 ? void 0 : _config$appTypes2.wpAdmin, | |
| 2148 | + targetLocation: this.toLowerSnake(isEditor ? config === null || config === void 0 || (_config$locations = config.locations) === null || _config$locations === void 0 ? void 0 : _config$locations.topBar : config === null || config === void 0 || (_config$locations2 = config.locations) === null || _config$locations2 === void 0 ? void 0 : _config$locations2.sidebar) | |
| 2149 | + }; | |
| 2150 | + } | |
| 2151 | + }, | |
| 2152 | + { | |
| 2153 | + key: "createBasePayload", | |
| 2154 | + value: function createBasePayload() { | |
| 2155 | + var _config$appTypes$edit; | |
| 2156 | + var _config$appTypes3; | |
| 2157 | + var overrides = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}; | |
| 2158 | + var config = this.getConfig(); | |
| 2159 | + return _objectSpread$1({ window_name: (_config$appTypes$edit = config === null || config === void 0 || (_config$appTypes3 = config.appTypes) === null || _config$appTypes3 === void 0 ? void 0 : _config$appTypes3.editor) !== null && _config$appTypes$edit !== void 0 ? _config$appTypes$edit : "editor" }, overrides); | |
| 2160 | + } | |
| 2161 | + }, | |
| 2162 | + { | |
| 2163 | + key: "sendTopBarPublishDropdown", | |
| 2164 | + value: function sendTopBarPublishDropdown(targetName) { | |
| 2165 | + var _config$names; | |
| 2166 | + var _config$triggers; | |
| 2167 | + var _config$targetTypes; | |
| 2168 | + var _config$interactionRe; | |
| 2169 | + var _config$locations3; | |
| 2170 | + var _config$secondaryLoca; | |
| 2171 | + var _config$targetTypes2; | |
| 2172 | + var config = this.getConfig(); | |
| 2173 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names = config.names) === null || _config$names === void 0 || (_config$names = _config$names.editorOne) === null || _config$names === void 0 ? void 0 : _config$names.topBarPublishDropdown, this.createBasePayload({ | |
| 2174 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers = config.triggers) === null || _config$triggers === void 0 ? void 0 : _config$triggers.click), | |
| 2175 | + target_type: config === null || config === void 0 || (_config$targetTypes = config.targetTypes) === null || _config$targetTypes === void 0 ? void 0 : _config$targetTypes.dropdownItem, | |
| 2176 | + target_name: targetName, | |
| 2177 | + interaction_result: config === null || config === void 0 || (_config$interactionRe = config.interactionResults) === null || _config$interactionRe === void 0 ? void 0 : _config$interactionRe.actionSelected, | |
| 2178 | + target_location: this.toLowerSnake(config === null || config === void 0 || (_config$locations3 = config.locations) === null || _config$locations3 === void 0 ? void 0 : _config$locations3.topBar), | |
| 2179 | + location_l1: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca = config.secondaryLocations) === null || _config$secondaryLoca === void 0 ? void 0 : _config$secondaryLoca.publishDropdown), | |
| 2180 | + location_l2: config === null || config === void 0 || (_config$targetTypes2 = config.targetTypes) === null || _config$targetTypes2 === void 0 ? void 0 : _config$targetTypes2.dropdownItem, | |
| 2181 | + interaction_description: "User selected an action from the publish dropdown" | |
| 2182 | + })); | |
| 2183 | + } | |
| 2184 | + }, | |
| 2185 | + { | |
| 2186 | + key: "sendTopBarPageList", | |
| 2187 | + value: function sendTopBarPageList(targetName) { | |
| 2188 | + var _config$names2; | |
| 2189 | + var _config$triggers2; | |
| 2190 | + var _config$targetTypes3; | |
| 2191 | + var _config$interactionRe2; | |
| 2192 | + var _config$interactionRe3; | |
| 2193 | + var _config$locations4; | |
| 2194 | + var _config$secondaryLoca2; | |
| 2195 | + var _config$targetTypes4; | |
| 2196 | + var isCreate = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : false; | |
| 2197 | + var config = this.getConfig(); | |
| 2198 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names2 = config.names) === null || _config$names2 === void 0 || (_config$names2 = _config$names2.editorOne) === null || _config$names2 === void 0 ? void 0 : _config$names2.topBarPageList, this.createBasePayload({ | |
| 2199 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers2 = config.triggers) === null || _config$triggers2 === void 0 ? void 0 : _config$triggers2.click), | |
| 2200 | + target_type: config === null || config === void 0 || (_config$targetTypes3 = config.targetTypes) === null || _config$targetTypes3 === void 0 ? void 0 : _config$targetTypes3.dropdownItem, | |
| 2201 | + target_name: targetName, | |
| 2202 | + interaction_result: isCreate ? config === null || config === void 0 || (_config$interactionRe2 = config.interactionResults) === null || _config$interactionRe2 === void 0 ? void 0 : _config$interactionRe2.create : config === null || config === void 0 || (_config$interactionRe3 = config.interactionResults) === null || _config$interactionRe3 === void 0 ? void 0 : _config$interactionRe3.navigate, | |
| 2203 | + target_location: this.toLowerSnake(config === null || config === void 0 || (_config$locations4 = config.locations) === null || _config$locations4 === void 0 ? void 0 : _config$locations4.topBar), | |
| 2204 | + location_l1: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca2 = config.secondaryLocations) === null || _config$secondaryLoca2 === void 0 ? void 0 : _config$secondaryLoca2.pageListDropdown), | |
| 2205 | + location_l2: config === null || config === void 0 || (_config$targetTypes4 = config.targetTypes) === null || _config$targetTypes4 === void 0 ? void 0 : _config$targetTypes4.dropdownItem, | |
| 2206 | + interaction_description: "User selected an action from the page list dropdown" | |
| 2207 | + })); | |
| 2208 | + } | |
| 2209 | + }, | |
| 2210 | + { | |
| 2211 | + key: "sendSiteSettingsSession", | |
| 2212 | + value: function sendSiteSettingsSession(_ref) { | |
| 2213 | + var _config$names3; | |
| 2214 | + var _config$triggers3; | |
| 2215 | + var _config$interactionRe4; | |
| 2216 | + var _config$locations5; | |
| 2217 | + var _config$secondaryLoca3; | |
| 2218 | + var targetType = _ref.targetType; | |
| 2219 | + var _ref$visitedItems = _ref.visitedItems; | |
| 2220 | + var visitedItems = _ref$visitedItems === void 0 ? [] : _ref$visitedItems; | |
| 2221 | + var _ref$savedItems = _ref.savedItems; | |
| 2222 | + var savedItems = _ref$savedItems === void 0 ? [] : _ref$savedItems; | |
| 2223 | + var state = _ref.state; | |
| 2224 | + var config = this.getConfig(); | |
| 2225 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names3 = config.names) === null || _config$names3 === void 0 || (_config$names3 = _config$names3.editorOne) === null || _config$names3 === void 0 ? void 0 : _config$names3.siteSettingsSession, this.createBasePayload({ | |
| 2226 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers3 = config.triggers) === null || _config$triggers3 === void 0 ? void 0 : _config$triggers3.click), | |
| 2227 | + target_type: targetType, | |
| 2228 | + target_name: "site_settings", | |
| 2229 | + interaction_result: config === null || config === void 0 || (_config$interactionRe4 = config.interactionResults) === null || _config$interactionRe4 === void 0 ? void 0 : _config$interactionRe4.sessionEnd, | |
| 2230 | + target_location: this.toLowerSnake(config === null || config === void 0 || (_config$locations5 = config.locations) === null || _config$locations5 === void 0 ? void 0 : _config$locations5.leftPanel), | |
| 2231 | + location_l1: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca3 = config.secondaryLocations) === null || _config$secondaryLoca3 === void 0 ? void 0 : _config$secondaryLoca3.siteSettings), | |
| 2232 | + interaction_description: "Records areas visited as part of the site setting session", | |
| 2233 | + metadata: { | |
| 2234 | + visited_items: visitedItems, | |
| 2235 | + saved_items: savedItems | |
| 2236 | + }, | |
| 2237 | + state | |
| 2238 | + })); | |
| 2239 | + } | |
| 2240 | + }, | |
| 2241 | + { | |
| 2242 | + key: "sendELibraryNav", | |
| 2243 | + value: function sendELibraryNav(tabName) { | |
| 2244 | + var _config$names4; | |
| 2245 | + var _config$triggers4; | |
| 2246 | + var _config$targetTypes5; | |
| 2247 | + var _config$interactionRe5; | |
| 2248 | + var _config$locations6; | |
| 2249 | + var _config$secondaryLoca4; | |
| 2250 | + var config = this.getConfig(); | |
| 2251 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names4 = config.names) === null || _config$names4 === void 0 || (_config$names4 = _config$names4.editorOne) === null || _config$names4 === void 0 ? void 0 : _config$names4.eLibraryNav, this.createBasePayload({ | |
| 2252 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers4 = config.triggers) === null || _config$triggers4 === void 0 ? void 0 : _config$triggers4.tabSelect), | |
| 2253 | + target_type: config === null || config === void 0 || (_config$targetTypes5 = config.targetTypes) === null || _config$targetTypes5 === void 0 ? void 0 : _config$targetTypes5.tab, | |
| 2254 | + target_name: this.toLowerSnake(tabName), | |
| 2255 | + interaction_result: config === null || config === void 0 || (_config$interactionRe5 = config.interactionResults) === null || _config$interactionRe5 === void 0 ? void 0 : _config$interactionRe5.tabChanged, | |
| 2256 | + target_location: this.toLowerSnake(config === null || config === void 0 || (_config$locations6 = config.locations) === null || _config$locations6 === void 0 ? void 0 : _config$locations6.elementorLibrary), | |
| 2257 | + location_l1: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca4 = config.secondaryLocations) === null || _config$secondaryLoca4 === void 0 ? void 0 : _config$secondaryLoca4.libraryTabs), | |
| 2258 | + interaction_description: "User navigates within elementor library" | |
| 2259 | + })); | |
| 2260 | + } | |
| 2261 | + }, | |
| 2262 | + { | |
| 2263 | + key: "sendELibraryInsert", | |
| 2264 | + value: function sendELibraryInsert(_ref2) { | |
| 2265 | + var _config$triggers5; | |
| 2266 | + var _config$targetTypes6; | |
| 2267 | + var _config$interactionRe6; | |
| 2268 | + var _config$locations7; | |
| 2269 | + var _config$secondaryLoca5; | |
| 2270 | + var _config$names5; | |
| 2271 | + var assetId = _ref2.assetId; | |
| 2272 | + var assetName = _ref2.assetName; | |
| 2273 | + var libraryType = _ref2.libraryType; | |
| 2274 | + var _ref2$proRequired = _ref2.proRequired; | |
| 2275 | + var proRequired = _ref2$proRequired === void 0 ? false : _ref2$proRequired; | |
| 2276 | + var config = this.getConfig(); | |
| 2277 | + var payload = this.createBasePayload({ | |
| 2278 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers5 = config.triggers) === null || _config$triggers5 === void 0 ? void 0 : _config$triggers5.insert), | |
| 2279 | + target_type: config === null || config === void 0 || (_config$targetTypes6 = config.targetTypes) === null || _config$targetTypes6 === void 0 ? void 0 : _config$targetTypes6.button, | |
| 2280 | + target_name: String(assetId), | |
| 2281 | + interaction_result: config === null || config === void 0 || (_config$interactionRe6 = config.interactionResults) === null || _config$interactionRe6 === void 0 ? void 0 : _config$interactionRe6.assetInserted, | |
| 2282 | + target_location: this.toLowerSnake(config === null || config === void 0 || (_config$locations7 = config.locations) === null || _config$locations7 === void 0 ? void 0 : _config$locations7.elementorLibrary), | |
| 2283 | + location_l1: this.toLowerSnake(libraryType), | |
| 2284 | + location_l2: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca5 = config.secondaryLocations) === null || _config$secondaryLoca5 === void 0 ? void 0 : _config$secondaryLoca5.assetCard), | |
| 2285 | + interaction_description: "User inserts block/pages from elementor library", | |
| 2286 | + metadata: { | |
| 2287 | + template_id: String(assetId), | |
| 2288 | + template_name: this.decodeHtmlEntities(assetName) || "" | |
| 2289 | + } | |
| 2290 | + }); | |
| 2291 | + if (proRequired) payload.state = "pro_plan_required"; | |
| 2292 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names5 = config.names) === null || _config$names5 === void 0 || (_config$names5 = _config$names5.editorOne) === null || _config$names5 === void 0 ? void 0 : _config$names5.eLibraryInsert, payload); | |
| 2293 | + } | |
| 2294 | + }, | |
| 2295 | + { | |
| 2296 | + key: "sendELibraryFavorite", | |
| 2297 | + value: function sendELibraryFavorite(_ref3) { | |
| 2298 | + var _config$triggers6; | |
| 2299 | + var _config$targetTypes7; | |
| 2300 | + var _config$interactionRe7; | |
| 2301 | + var _config$locations8; | |
| 2302 | + var _config$secondaryLoca6; | |
| 2303 | + var _config$names6; | |
| 2304 | + var assetId = _ref3.assetId; | |
| 2305 | + var assetName = _ref3.assetName; | |
| 2306 | + var libraryType = _ref3.libraryType; | |
| 2307 | + var isFavorite = _ref3.isFavorite; | |
| 2308 | + var _ref3$proRequired = _ref3.proRequired; | |
| 2309 | + var proRequired = _ref3$proRequired === void 0 ? false : _ref3$proRequired; | |
| 2310 | + var config = this.getConfig(); | |
| 2311 | + var payload = this.createBasePayload({ | |
| 2312 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers6 = config.triggers) === null || _config$triggers6 === void 0 ? void 0 : _config$triggers6.click), | |
| 2313 | + target_type: config === null || config === void 0 || (_config$targetTypes7 = config.targetTypes) === null || _config$targetTypes7 === void 0 ? void 0 : _config$targetTypes7.toggle, | |
| 2314 | + target_name: String(assetId), | |
| 2315 | + interaction_result: config === null || config === void 0 || (_config$interactionRe7 = config.interactionResults) === null || _config$interactionRe7 === void 0 ? void 0 : _config$interactionRe7.assetFavorite, | |
| 2316 | + target_value: Boolean(isFavorite), | |
| 2317 | + target_location: this.toLowerSnake(config === null || config === void 0 || (_config$locations8 = config.locations) === null || _config$locations8 === void 0 ? void 0 : _config$locations8.elementorLibrary), | |
| 2318 | + location_l1: this.toLowerSnake(libraryType), | |
| 2319 | + location_l2: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca6 = config.secondaryLocations) === null || _config$secondaryLoca6 === void 0 ? void 0 : _config$secondaryLoca6.assetCard), | |
| 2320 | + interaction_description: "User favorite block/pages from elementor library", | |
| 2321 | + metadata: { | |
| 2322 | + template_id: String(assetId), | |
| 2323 | + template_name: this.decodeHtmlEntities(assetName) || "" | |
| 2324 | + } | |
| 2325 | + }); | |
| 2326 | + if (proRequired) payload.state = "pro_plan_required"; | |
| 2327 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names6 = config.names) === null || _config$names6 === void 0 || (_config$names6 = _config$names6.editorOne) === null || _config$names6 === void 0 ? void 0 : _config$names6.eLibraryFavorite, payload); | |
| 2328 | + } | |
| 2329 | + }, | |
| 2330 | + { | |
| 2331 | + key: "sendELibraryGenerateAi", | |
| 2332 | + value: function sendELibraryGenerateAi(_ref4) { | |
| 2333 | + var _config$names7; | |
| 2334 | + var _config$triggers7; | |
| 2335 | + var _config$targetTypes8; | |
| 2336 | + var _config$interactionRe8; | |
| 2337 | + var _config$locations9; | |
| 2338 | + var _config$secondaryLoca7; | |
| 2339 | + var assetId = _ref4.assetId; | |
| 2340 | + var assetName = _ref4.assetName; | |
| 2341 | + var libraryType = _ref4.libraryType; | |
| 2342 | + var config = this.getConfig(); | |
| 2343 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names7 = config.names) === null || _config$names7 === void 0 || (_config$names7 = _config$names7.editorOne) === null || _config$names7 === void 0 ? void 0 : _config$names7.eLibraryGenerateAi, this.createBasePayload({ | |
| 2344 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers7 = config.triggers) === null || _config$triggers7 === void 0 ? void 0 : _config$triggers7.click), | |
| 2345 | + target_type: config === null || config === void 0 || (_config$targetTypes8 = config.targetTypes) === null || _config$targetTypes8 === void 0 ? void 0 : _config$targetTypes8.button, | |
| 2346 | + target_name: String(assetId), | |
| 2347 | + interaction_result: config === null || config === void 0 || (_config$interactionRe8 = config.interactionResults) === null || _config$interactionRe8 === void 0 ? void 0 : _config$interactionRe8.aiGenerate, | |
| 2348 | + target_location: this.toLowerSnake(config === null || config === void 0 || (_config$locations9 = config.locations) === null || _config$locations9 === void 0 ? void 0 : _config$locations9.elementorLibrary), | |
| 2349 | + location_l1: this.toLowerSnake(libraryType), | |
| 2350 | + location_l2: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca7 = config.secondaryLocations) === null || _config$secondaryLoca7 === void 0 ? void 0 : _config$secondaryLoca7.assetCard), | |
| 2351 | + interaction_description: "User generated block/page based on a library asset", | |
| 2352 | + metadata: { | |
| 2353 | + template_id: String(assetId), | |
| 2354 | + template_name: this.decodeHtmlEntities(assetName) || "" | |
| 2355 | + } | |
| 2356 | + })); | |
| 2357 | + } | |
| 2358 | + }, | |
| 2359 | + { | |
| 2360 | + key: "sendFinderSearchInput", | |
| 2361 | + value: function sendFinderSearchInput(_ref5) { | |
| 2362 | + var _config$triggers8; | |
| 2363 | + var _config$targetTypes9; | |
| 2364 | + var _config$interactionRe9; | |
| 2365 | + var _config$interactionRe0; | |
| 2366 | + var _config$secondaryLoca8; | |
| 2367 | + var _config$names8; | |
| 2368 | + var resultsCount = _ref5.resultsCount; | |
| 2369 | + var _ref5$searchTerm = _ref5.searchTerm; | |
| 2370 | + var searchTerm = _ref5$searchTerm === void 0 ? null : _ref5$searchTerm; | |
| 2371 | + var config = this.getConfig(); | |
| 2372 | + var hasResults = resultsCount > 0; | |
| 2373 | + var finderContext = this.getFinderContext(); | |
| 2374 | + var payload = this.createBasePayload({ | |
| 2375 | + window_name: finderContext.windowName, | |
| 2376 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers8 = config.triggers) === null || _config$triggers8 === void 0 ? void 0 : _config$triggers8.typing), | |
| 2377 | + target_type: config === null || config === void 0 || (_config$targetTypes9 = config.targetTypes) === null || _config$targetTypes9 === void 0 ? void 0 : _config$targetTypes9.searchInput, | |
| 2378 | + target_name: "finder", | |
| 2379 | + interaction_result: hasResults ? config === null || config === void 0 || (_config$interactionRe9 = config.interactionResults) === null || _config$interactionRe9 === void 0 ? void 0 : _config$interactionRe9.resultsUpdated : config === null || config === void 0 || (_config$interactionRe0 = config.interactionResults) === null || _config$interactionRe0 === void 0 ? void 0 : _config$interactionRe0.noResults, | |
| 2380 | + target_location: finderContext.targetLocation, | |
| 2381 | + location_l1: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca8 = config.secondaryLocations) === null || _config$secondaryLoca8 === void 0 ? void 0 : _config$secondaryLoca8.finder), | |
| 2382 | + interaction_description: "Finder search input, follows debounce behavior", | |
| 2383 | + metadata: { results_count: resultsCount } | |
| 2384 | + }); | |
| 2385 | + if (!hasResults && searchTerm) payload.metadata.search_term = searchTerm; | |
| 2386 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names8 = config.names) === null || _config$names8 === void 0 || (_config$names8 = _config$names8.editorOne) === null || _config$names8 === void 0 ? void 0 : _config$names8.finderSearchInput, payload); | |
| 2387 | + } | |
| 2388 | + }, | |
| 2389 | + { | |
| 2390 | + key: "sendFinderResultSelect", | |
| 2391 | + value: function sendFinderResultSelect(choice) { | |
| 2392 | + var _config$names9; | |
| 2393 | + var _config$triggers9; | |
| 2394 | + var _config$targetTypes0; | |
| 2395 | + var _config$interactionRe1; | |
| 2396 | + var _config$secondaryLoca9; | |
| 2397 | + var _config$secondaryLoca0; | |
| 2398 | + var config = this.getConfig(); | |
| 2399 | + var finderContext = this.getFinderContext(); | |
| 2400 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names9 = config.names) === null || _config$names9 === void 0 || (_config$names9 = _config$names9.editorOne) === null || _config$names9 === void 0 ? void 0 : _config$names9.finderResultSelect, this.createBasePayload({ | |
| 2401 | + window_name: finderContext.windowName, | |
| 2402 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers9 = config.triggers) === null || _config$triggers9 === void 0 ? void 0 : _config$triggers9.click), | |
| 2403 | + target_type: config === null || config === void 0 || (_config$targetTypes0 = config.targetTypes) === null || _config$targetTypes0 === void 0 ? void 0 : _config$targetTypes0.searchResult, | |
| 2404 | + target_name: choice, | |
| 2405 | + interaction_result: config === null || config === void 0 || (_config$interactionRe1 = config.interactionResults) === null || _config$interactionRe1 === void 0 ? void 0 : _config$interactionRe1.selected, | |
| 2406 | + target_location: finderContext.targetLocation, | |
| 2407 | + location_l1: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca9 = config.secondaryLocations) === null || _config$secondaryLoca9 === void 0 ? void 0 : _config$secondaryLoca9.finder), | |
| 2408 | + location_l2: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca0 = config.secondaryLocations) === null || _config$secondaryLoca0 === void 0 ? void 0 : _config$secondaryLoca0.finderResults), | |
| 2409 | + interaction_description: "Finder search results was selected" | |
| 2410 | + })); | |
| 2411 | + } | |
| 2412 | + }, | |
| 2413 | + { | |
| 2414 | + key: "sendCanvasEmptyBoxAction", | |
| 2415 | + value: function sendCanvasEmptyBoxAction(_ref6) { | |
| 2416 | + var _config$triggers0; | |
| 2417 | + var _config$targetTypes1; | |
| 2418 | + var _config$interactionRe10; | |
| 2419 | + var _config$locations0; | |
| 2420 | + var _config$secondaryLoca1; | |
| 2421 | + var _config$names0; | |
| 2422 | + var targetName = _ref6.targetName; | |
| 2423 | + var _ref6$metadata = _ref6.metadata; | |
| 2424 | + var metadata = _ref6$metadata === void 0 ? {} : _ref6$metadata; | |
| 2425 | + var _ref6$containerCreate = _ref6.containerCreated; | |
| 2426 | + var containerCreated = _ref6$containerCreate === void 0 ? null : _ref6$containerCreate; | |
| 2427 | + var config = this.getConfig(); | |
| 2428 | + var payload = this.createBasePayload({ | |
| 2429 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers0 = config.triggers) === null || _config$triggers0 === void 0 ? void 0 : _config$triggers0.click), | |
| 2430 | + target_type: config === null || config === void 0 || (_config$targetTypes1 = config.targetTypes) === null || _config$targetTypes1 === void 0 ? void 0 : _config$targetTypes1.buttons, | |
| 2431 | + target_name: targetName, | |
| 2432 | + interaction_result: config === null || config === void 0 || (_config$interactionRe10 = config.interactionResults) === null || _config$interactionRe10 === void 0 ? void 0 : _config$interactionRe10.selected, | |
| 2433 | + target_location: this.toLowerSnake(config === null || config === void 0 || (_config$locations0 = config.locations) === null || _config$locations0 === void 0 ? void 0 : _config$locations0.canvas), | |
| 2434 | + location_l1: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca1 = config.secondaryLocations) === null || _config$secondaryLoca1 === void 0 ? void 0 : _config$secondaryLoca1.emptyBox), | |
| 2435 | + interaction_description: "Empty box on canvas actions" | |
| 2436 | + }); | |
| 2437 | + if (Object.keys(metadata).length > 0) payload.metadata = metadata; | |
| 2438 | + if (containerCreated !== null) payload.state = containerCreated; | |
| 2439 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names0 = config.names) === null || _config$names0 === void 0 || (_config$names0 = _config$names0.editorOne) === null || _config$names0 === void 0 ? void 0 : _config$names0.canvasEmptyBoxAction, payload); | |
| 2440 | + } | |
| 2441 | + }, | |
| 2442 | + { | |
| 2443 | + key: "sendWidgetPanelSearch", | |
| 2444 | + value: function sendWidgetPanelSearch(_ref7) { | |
| 2445 | + var _config$triggers1; | |
| 2446 | + var _config$targetTypes10; | |
| 2447 | + var _config$interactionRe11; | |
| 2448 | + var _config$interactionRe12; | |
| 2449 | + var _config$locations1; | |
| 2450 | + var _config$locations10; | |
| 2451 | + var _config$secondaryLoca10; | |
| 2452 | + var _config$names1; | |
| 2453 | + var resultsCount = _ref7.resultsCount; | |
| 2454 | + var _ref7$userInput = _ref7.userInput; | |
| 2455 | + var userInput = _ref7$userInput === void 0 ? null : _ref7$userInput; | |
| 2456 | + var config = this.getConfig(); | |
| 2457 | + var hasResults = resultsCount > 0; | |
| 2458 | + var payload = this.createBasePayload({ | |
| 2459 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers1 = config.triggers) === null || _config$triggers1 === void 0 ? void 0 : _config$triggers1.typing), | |
| 2460 | + target_type: config === null || config === void 0 || (_config$targetTypes10 = config.targetTypes) === null || _config$targetTypes10 === void 0 ? void 0 : _config$targetTypes10.searchWidget, | |
| 2461 | + target_name: "search_widget", | |
| 2462 | + interaction_result: hasResults ? config === null || config === void 0 || (_config$interactionRe11 = config.interactionResults) === null || _config$interactionRe11 === void 0 ? void 0 : _config$interactionRe11.resultsUpdated : config === null || config === void 0 || (_config$interactionRe12 = config.interactionResults) === null || _config$interactionRe12 === void 0 ? void 0 : _config$interactionRe12.noResults, | |
| 2463 | + target_location: this.toLowerSnake(config === null || config === void 0 || (_config$locations1 = config.locations) === null || _config$locations1 === void 0 ? void 0 : _config$locations1.leftPanel), | |
| 2464 | + location_l1: this.toLowerSnake(config === null || config === void 0 || (_config$locations10 = config.locations) === null || _config$locations10 === void 0 ? void 0 : _config$locations10.widgetPanel), | |
| 2465 | + location_l2: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca10 = config.secondaryLocations) === null || _config$secondaryLoca10 === void 0 ? void 0 : _config$secondaryLoca10.searchBar), | |
| 2466 | + interaction_description: "Widget search input, follows debounce behavior" | |
| 2467 | + }); | |
| 2468 | + if (!hasResults && userInput) payload.metadata = { user_input: userInput }; | |
| 2469 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names1 = config.names) === null || _config$names1 === void 0 || (_config$names1 = _config$names1.editorOne) === null || _config$names1 === void 0 ? void 0 : _config$names1.widgetPanelSearch, payload); | |
| 2470 | + } | |
| 2471 | + }, | |
| 2472 | + { | |
| 2473 | + key: "createWpDashPayload", | |
| 2474 | + value: function createWpDashPayload() { | |
| 2475 | + var _config$appTypes$wpDa; | |
| 2476 | + var _config$appTypes4; | |
| 2477 | + var _config$locations11; | |
| 2478 | + var overrides = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}; | |
| 2479 | + var config = this.getConfig(); | |
| 2480 | + return this.createBasePayload(_objectSpread$1({ | |
| 2481 | + window_name: (_config$appTypes$wpDa = config === null || config === void 0 || (_config$appTypes4 = config.appTypes) === null || _config$appTypes4 === void 0 ? void 0 : _config$appTypes4.wpDash) !== null && _config$appTypes$wpDa !== void 0 ? _config$appTypes$wpDa : "wpdash", | |
| 2482 | + target_location: this.toLowerSnake(config === null || config === void 0 || (_config$locations11 = config.locations) === null || _config$locations11 === void 0 ? void 0 : _config$locations11.wpDashAdmin), | |
| 2483 | + location_l2: "" | |
| 2484 | + }, overrides)); | |
| 2485 | + } | |
| 2486 | + }, | |
| 2487 | + { | |
| 2488 | + key: "sendWpDashElementorMenuClick", | |
| 2489 | + value: function sendWpDashElementorMenuClick() { | |
| 2490 | + var _config$names10; | |
| 2491 | + var _config$triggers10; | |
| 2492 | + var _config$targetTypes11; | |
| 2493 | + var _config$interactionRe13; | |
| 2494 | + var _config$secondaryLoca11; | |
| 2495 | + var config = this.getConfig(); | |
| 2496 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names10 = config.names) === null || _config$names10 === void 0 || (_config$names10 = _config$names10.editorOne) === null || _config$names10 === void 0 ? void 0 : _config$names10.wpDashElementorMenuClick, this.createWpDashPayload({ | |
| 2497 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers10 = config.triggers) === null || _config$triggers10 === void 0 ? void 0 : _config$triggers10.click), | |
| 2498 | + target_type: config === null || config === void 0 || (_config$targetTypes11 = config.targetTypes) === null || _config$targetTypes11 === void 0 ? void 0 : _config$targetTypes11.wpDashAdminMenuItem, | |
| 2499 | + target_name: "elementor_menu_item", | |
| 2500 | + interaction_result: config === null || config === void 0 || (_config$interactionRe13 = config.interactionResults) === null || _config$interactionRe13 === void 0 ? void 0 : _config$interactionRe13.elementorSideMenuOpened, | |
| 2501 | + location_l1: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca11 = config.secondaryLocations) === null || _config$secondaryLoca11 === void 0 ? void 0 : _config$secondaryLoca11.wpDashElementorCoreMenu), | |
| 2502 | + interaction_description: "core_user_clicked_elementor_menu_item" | |
| 2503 | + })); | |
| 2504 | + } | |
| 2505 | + }, | |
| 2506 | + { | |
| 2507 | + key: "sendWpDashEditorSubMenuHover", | |
| 2508 | + value: function sendWpDashEditorSubMenuHover() { | |
| 2509 | + var _config$names11; | |
| 2510 | + var _config$triggers11; | |
| 2511 | + var _config$targetTypes12; | |
| 2512 | + var _config$interactionRe14; | |
| 2513 | + var _config$secondaryLoca12; | |
| 2514 | + var config = this.getConfig(); | |
| 2515 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names11 = config.names) === null || _config$names11 === void 0 || (_config$names11 = _config$names11.editorOne) === null || _config$names11 === void 0 ? void 0 : _config$names11.wpDashEditorSubMenuHover, this.createWpDashPayload({ | |
| 2516 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers11 = config.triggers) === null || _config$triggers11 === void 0 ? void 0 : _config$triggers11.hover), | |
| 2517 | + target_type: config === null || config === void 0 || (_config$targetTypes12 = config.targetTypes) === null || _config$targetTypes12 === void 0 ? void 0 : _config$targetTypes12.wpDashEditorMenu, | |
| 2518 | + target_name: "wpdash_editor_sub_menu", | |
| 2519 | + interaction_result: config === null || config === void 0 || (_config$interactionRe14 = config.interactionResults) === null || _config$interactionRe14 === void 0 ? void 0 : _config$interactionRe14.editorSubMenuOpened, | |
| 2520 | + location_l1: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca12 = config.secondaryLocations) === null || _config$secondaryLoca12 === void 0 ? void 0 : _config$secondaryLoca12.wpDashElementorCoreSubMenu), | |
| 2521 | + interaction_description: "core_user_hovered_sub_menu" | |
| 2522 | + })); | |
| 2523 | + } | |
| 2524 | + }, | |
| 2525 | + { | |
| 2526 | + key: "sendWpDashThemeBuilderClick", | |
| 2527 | + value: function sendWpDashThemeBuilderClick() { | |
| 2528 | + var _config$names12; | |
| 2529 | + var _config$triggers12; | |
| 2530 | + var _config$targetTypes13; | |
| 2531 | + var _config$interactionRe15; | |
| 2532 | + var _config$secondaryLoca13; | |
| 2533 | + var config = this.getConfig(); | |
| 2534 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names12 = config.names) === null || _config$names12 === void 0 || (_config$names12 = _config$names12.editorOne) === null || _config$names12 === void 0 ? void 0 : _config$names12.wpDashThemeBuilderClick, this.createWpDashPayload({ | |
| 2535 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers12 = config.triggers) === null || _config$triggers12 === void 0 ? void 0 : _config$triggers12.click), | |
| 2536 | + target_type: config === null || config === void 0 || (_config$targetTypes13 = config.targetTypes) === null || _config$targetTypes13 === void 0 ? void 0 : _config$targetTypes13.wpDashSubMenuItem, | |
| 2537 | + target_name: "theme_builder_menu_item", | |
| 2538 | + interaction_result: config === null || config === void 0 || (_config$interactionRe15 = config.interactionResults) === null || _config$interactionRe15 === void 0 ? void 0 : _config$interactionRe15.themeBuilderPromotionWindow, | |
| 2539 | + location_l1: this.toLowerSnake(config === null || config === void 0 || (_config$secondaryLoca13 = config.secondaryLocations) === null || _config$secondaryLoca13 === void 0 ? void 0 : _config$secondaryLoca13.wpDashThemeBuilder), | |
| 2540 | + interaction_description: "core_user_clicked_theme_builder_menu_item" | |
| 2541 | + })); | |
| 2542 | + } | |
| 2543 | + }, | |
| 2544 | + { | |
| 2545 | + key: "sendSidebarMenuItemClicked", | |
| 2546 | + value: function sendSidebarMenuItemClicked(_ref8) { | |
| 2547 | + var eventId = _ref8.eventId; | |
| 2548 | + var groupEventId = _ref8.groupEventId; | |
| 2549 | + try { | |
| 2550 | + var _config$windowNames; | |
| 2551 | + var _config$triggers13; | |
| 2552 | + var _config$targetTypes14; | |
| 2553 | + var _config$interactionRe16; | |
| 2554 | + var _config$locations12; | |
| 2555 | + var _config$names13; | |
| 2556 | + var config = this.getConfig(); | |
| 2557 | + var payload = this.createBasePayload({ | |
| 2558 | + window_name: config === null || config === void 0 || (_config$windowNames = config.windowNames) === null || _config$windowNames === void 0 ? void 0 : _config$windowNames.sidebarMenu, | |
| 2559 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers13 = config.triggers) === null || _config$triggers13 === void 0 ? void 0 : _config$triggers13.click), | |
| 2560 | + target_type: config === null || config === void 0 || (_config$targetTypes14 = config.targetTypes) === null || _config$targetTypes14 === void 0 ? void 0 : _config$targetTypes14.link, | |
| 2561 | + target_name: eventId, | |
| 2562 | + interaction_result: config === null || config === void 0 || (_config$interactionRe16 = config.interactionResults) === null || _config$interactionRe16 === void 0 ? void 0 : _config$interactionRe16.pageOpened, | |
| 2563 | + target_location: this.toLowerSnake(config === null || config === void 0 || (_config$locations12 = config.locations) === null || _config$locations12 === void 0 ? void 0 : _config$locations12.sidebar) | |
| 2564 | + }); | |
| 2565 | + if (groupEventId) payload.location_l1 = groupEventId; | |
| 2566 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names13 = config.names) === null || _config$names13 === void 0 || (_config$names13 = _config$names13.editorOne) === null || _config$names13 === void 0 ? void 0 : _config$names13.sidebarMenuItemClicked, payload); | |
| 2567 | + } catch (error) { | |
| 2568 | + return false; | |
| 2569 | + } | |
| 2570 | + } | |
| 2571 | + }, | |
| 2572 | + { | |
| 2573 | + key: "sendSidebarMenuGroupToggled", | |
| 2574 | + value: function sendSidebarMenuGroupToggled(_ref9) { | |
| 2575 | + var eventId = _ref9.eventId; | |
| 2576 | + var isExpanded = _ref9.isExpanded; | |
| 2577 | + try { | |
| 2578 | + var _config$interactionRe17; | |
| 2579 | + var _config$interactionRe18; | |
| 2580 | + var _config$names14; | |
| 2581 | + var _config$windowNames2; | |
| 2582 | + var _config$triggers14; | |
| 2583 | + var _config$targetTypes15; | |
| 2584 | + var _config$locations13; | |
| 2585 | + var config = this.getConfig(); | |
| 2586 | + var interactionResult = isExpanded ? config === null || config === void 0 || (_config$interactionRe17 = config.interactionResults) === null || _config$interactionRe17 === void 0 ? void 0 : _config$interactionRe17.expanded : config === null || config === void 0 || (_config$interactionRe18 = config.interactionResults) === null || _config$interactionRe18 === void 0 ? void 0 : _config$interactionRe18.collapsed; | |
| 2587 | + return this.dispatchEvent(config === null || config === void 0 || (_config$names14 = config.names) === null || _config$names14 === void 0 || (_config$names14 = _config$names14.editorOne) === null || _config$names14 === void 0 ? void 0 : _config$names14.sidebarMenuGroupToggled, this.createBasePayload({ | |
| 2588 | + window_name: config === null || config === void 0 || (_config$windowNames2 = config.windowNames) === null || _config$windowNames2 === void 0 ? void 0 : _config$windowNames2.sidebarMenu, | |
| 2589 | + interaction_type: this.toLowerSnake(config === null || config === void 0 || (_config$triggers14 = config.triggers) === null || _config$triggers14 === void 0 ? void 0 : _config$triggers14.click), | |
| 2590 | + target_type: config === null || config === void 0 || (_config$targetTypes15 = config.targetTypes) === null || _config$targetTypes15 === void 0 ? void 0 : _config$targetTypes15.toggle, | |
| 2591 | + target_name: eventId, | |
| 2592 | + interaction_result: interactionResult, | |
| 2593 | + target_location: this.toLowerSnake(config === null || config === void 0 || (_config$locations13 = config.locations) === null || _config$locations13 === void 0 ? void 0 : _config$locations13.sidebar) | |
| 2594 | + })); | |
| 2595 | + } catch (error) { | |
| 2596 | + return false; | |
| 2597 | + } | |
| 2598 | + } | |
| 2599 | + } | |
| 2600 | + ]); | |
| 2601 | + }(); | |
| 2602 | + })); | |
| 2603 | + | |
| 2604 | +//#endregion | |
| 2605 | +//#region modules/nested-elements/assets/js/editor/views/select-preset.js | |
| 2606 | + function SelectPreset(props) { | |
| 2607 | + var containerHelper = elementor.helpers.container; | |
| 2608 | + var onPresetSelected = function onPresetSelected(preset, container) { | |
| 2609 | + var options = { createWrapper: false }; | |
| 2610 | + EditorOneEventManager.sendCanvasEmptyBoxAction({ | |
| 2611 | + targetName: "add_container", | |
| 2612 | + metadata: { | |
| 2613 | + container_type: "flexbox", | |
| 2614 | + structure_type: preset | |
| 2615 | + }, | |
| 2616 | + containerCreated: true | |
| 2617 | + }); | |
| 2618 | + containerHelper.createContainerFromPreset(preset, container, options); | |
| 2619 | + }; | |
| 2620 | + return /*#__PURE__*/ react.default.createElement(react.default.Fragment, null, /*#__PURE__*/ react.default.createElement("button", { | |
| 2621 | + type: "button", | |
| 2622 | + className: "elementor-add-section-close", | |
| 2623 | + "aria-label": (0, _wordpress_i18n.__)("Close", "elementor"), | |
| 2624 | + onClick: function handleClose() { | |
| 2625 | + EditorOneEventManager.sendCanvasEmptyBoxAction({ | |
| 2626 | + targetName: "close", | |
| 2627 | + containerCreated: false | |
| 2628 | + }); | |
| 2629 | + props.setIsRenderPresets(false); | |
| 2630 | + } | |
| 2631 | + }, /*#__PURE__*/ react.default.createElement("i", { | |
| 2632 | + className: "eicon-close", | |
| 2633 | + "aria-hidden": "true" | |
| 2634 | + })), /*#__PURE__*/ react.default.createElement("div", { className: "e-view e-con-select-preset" }, /*#__PURE__*/ react.default.createElement("div", { className: "e-con-select-preset__title" }, (0, _wordpress_i18n.__)("Select your Structure", "elementor")), /*#__PURE__*/ react.default.createElement("div", { className: "e-con-select-preset__list" }, elementor.presetsFactory.getContainerPresets().map(function(preset) { | |
| 2635 | + return /*#__PURE__*/ react.default.createElement("button", { | |
| 2636 | + type: "button", | |
| 2637 | + className: "e-con-preset", | |
| 2638 | + "data-preset": preset, | |
| 2639 | + key: preset, | |
| 2640 | + onClick: function onClick() { | |
| 2641 | + return onPresetSelected(preset, props.container); | |
| 2642 | + }, | |
| 2643 | + dangerouslySetInnerHTML: { __html: elementor.presetsFactory.generateContainerPreset(preset) } | |
| 2644 | + }); | |
| 2645 | + })))); | |
| 2646 | + } | |
| 2647 | + var import_prop_types$1; | |
| 2648 | + var init_select_preset = __esmMin((() => { | |
| 2649 | + import_prop_types$1 = /* @__PURE__ */ __toESM(require_prop_types()); | |
| 2650 | + init_editor_one_events(); | |
| 2651 | + SelectPreset.propTypes = { | |
| 2652 | + container: import_prop_types$1.default.object.isRequired, | |
| 2653 | + setIsRenderPresets: import_prop_types$1.default.func.isRequired | |
| 2654 | + }; | |
| 2655 | + })); | |
| 2656 | + | |
| 2657 | +//#endregion | |
| 2658 | +//#region modules/nested-elements/assets/js/editor/views/empty.js | |
| 2659 | + function ownKeys(e, r) { | |
| 2660 | + var t = Object.keys(e); | |
| 2661 | + if (Object.getOwnPropertySymbols) { | |
| 2662 | + var o = Object.getOwnPropertySymbols(e); | |
| 2663 | + r && (o = o.filter(function(r) { | |
| 2664 | + return Object.getOwnPropertyDescriptor(e, r).enumerable; | |
| 2665 | + })), t.push.apply(t, o); | |
| 2666 | + } | |
| 2667 | + return t; | |
| 2668 | + } | |
| 2669 | + function _objectSpread(e) { | |
| 2670 | + for (var r = 1; r < arguments.length; r++) { | |
| 2671 | + var t = null != arguments[r] ? arguments[r] : {}; | |
| 2672 | + r % 2 ? ownKeys(Object(t), !0).forEach(function(r) { | |
| 2673 | + _defineProperty(e, r, t[r]); | |
| 2674 | + }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function(r) { | |
| 2675 | + Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); | |
| 2676 | + }); | |
| 2677 | + } | |
| 2678 | + return e; | |
| 2679 | + } | |
| 2680 | + function Empty(props) { | |
| 2681 | + var _useState2 = _slicedToArray((0, react.useState)(false), 2); | |
| 2682 | + var isRenderPresets = _useState2[0]; | |
| 2683 | + var setIsRenderPresets = _useState2[1]; | |
| 2684 | + props = _objectSpread(_objectSpread({}, props), {}, { setIsRenderPresets }); | |
| 2685 | + return isRenderPresets ? /*#__PURE__*/ react.default.createElement(SelectPreset, props) : /*#__PURE__*/ react.default.createElement(AddSectionArea, props); | |
| 2686 | + } | |
| 2687 | + var import_prop_types; | |
| 2688 | + var init_empty = __esmMin((() => { | |
| 2689 | + import_prop_types = /* @__PURE__ */ __toESM(require_prop_types()); | |
| 2690 | + init_defineProperty(); | |
| 2691 | + init_slicedToArray(); | |
| 2692 | + init_add_section_area(); | |
| 2693 | + init_select_preset(); | |
| 2694 | + Empty.propTypes = { container: import_prop_types.default.object.isRequired }; | |
| 2695 | + })); | |
| 2696 | + | |
| 2697 | +//#endregion | |
| 2698 | +//#region modules/nested-elements/assets/js/editor/nested-element-types-base.js | |
| 2699 | + var nested_element_types_base_exports = /* @__PURE__ */ __exportAll({ | |
| 2700 | + NestedElementTypesBase: () => NestedElementTypesBase, | |
| 2701 | + default: () => NestedElementTypesBase | |
| 2702 | + }); | |
| 2703 | + function _callSuper(t, o, e) { | |
| 2704 | + return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); | |
| 2705 | + } | |
| 2706 | + function _isNativeReflectConstruct() { | |
| 2707 | + try { | |
| 2708 | + var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {})); | |
| 2709 | + } catch (t) {} | |
| 2710 | + return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { | |
| 2711 | + return !!t; | |
| 2712 | + })(); | |
| 2713 | + } | |
| 2714 | + var NestedElementTypesBase; | |
| 2715 | + var init_nested_element_types_base = __esmMin((() => { | |
| 2716 | + init_classCallCheck(); | |
| 2717 | + init_createClass(); | |
| 2718 | + init_possibleConstructorReturn(); | |
| 2719 | + init_getPrototypeOf(); | |
| 2720 | + init_inherits(); | |
| 2721 | + init_view(); | |
| 2722 | + init_empty(); | |
| 2723 | + NestedElementTypesBase = /*#__PURE__*/ function(_elementor$modules$el) { | |
| 2724 | + function NestedElementTypesBase() { | |
| 2725 | + _classCallCheck(this, NestedElementTypesBase); | |
| 2726 | + return _callSuper(this, NestedElementTypesBase, arguments); | |
| 2727 | + } | |
| 2728 | + _inherits(NestedElementTypesBase, _elementor$modules$el); | |
| 2729 | + return _createClass(NestedElementTypesBase, [ | |
| 2730 | + { | |
| 2731 | + key: "getType", | |
| 2732 | + value: function getType() { | |
| 2733 | + elementorModules.ForceMethodImplementation(); | |
| 2734 | + } | |
| 2735 | + }, | |
| 2736 | + { | |
| 2737 | + key: "getView", | |
| 2738 | + value: function getView() { | |
| 2739 | + return View; | |
| 2740 | + } | |
| 2741 | + }, | |
| 2742 | + { | |
| 2743 | + key: "getEmptyView", | |
| 2744 | + value: function getEmptyView() { | |
| 2745 | + return Empty; | |
| 2746 | + } | |
| 2747 | + }, | |
| 2748 | + { | |
| 2749 | + key: "getModel", | |
| 2750 | + value: function getModel() { | |
| 2751 | + return $e.components.get("nested-elements/nested-repeater").exports.NestedModelBase; | |
| 2752 | + } | |
| 2753 | + } | |
| 2754 | + ]); | |
| 2755 | + }(elementor.modules.elements.types.Base); | |
| 2756 | + })); | |
| 2757 | + | |
| 2758 | +//#endregion | |
| 2759 | +//#region modules/nested-elements/assets/js/editor/index.js | |
| 2760 | + elementorCommon.elements.$window.on("elementor:init-components", function() { | |
| 2761 | + elementor.modules.nestedElements = __vitePreload(() => Promise.resolve().then(() => (init_module(), module_exports)), void 0); | |
| 2762 | + elementor.modules.nestedElements.then(function(module) { | |
| 2763 | + elementor.modules.nestedElements = new module.default(); | |
| 2764 | + elementor.modules.elements.types.NestedElementBase = __vitePreload(() => Promise.resolve().then(() => (init_nested_element_types_base(), nested_element_types_base_exports)), void 0); | |
| 2765 | + elementor.modules.elements.types.NestedElementBase.then(function(nestedElementBaseModule) { | |
| 2766 | + elementor.modules.elements.types.NestedElementBase = nestedElementBaseModule.default; | |
| 2767 | + __vitePreload(() => Promise.resolve().then(() => (init_view(), view_exports)).then(function(View) { | |
| 2768 | + $e.components.get("nested-elements").exports = { NestedView: View.default }; | |
| 2769 | + }), void 0).then(function() { | |
| 2770 | + Events.dispatch(elementorCommon.elements.$window, "elementor/nested-element-type-loaded"); | |
| 2771 | + }); | |
| 2772 | + }); | |
| 2773 | + }); | |
| 2774 | + }); | |
| 2775 | + | |
| 2776 | +//#endregion | |
| 2777 | +})(wp.i18n, React); | |
| 459 | 2778 | //# sourceMappingURL=nested-elements.js.map |