| 1 |
"use strict"; |
| 2 |
(self["webpackChunkelementorFrontend"] = self["webpackChunkelementorFrontend"] || []).push([["frontend"],{ |
| 3 |
|
| 4 |
/***/ "../assets/dev/js/frontend/documents-manager.js": |
| 5 |
/*!******************************************************!*\ |
| 6 |
!*** ../assets/dev/js/frontend/documents-manager.js ***! |
| 7 |
\******************************************************/ |
| 8 |
/***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ "../node_modules/@babel/runtime/helpers/interopRequireDefault.js"); |
| 13 |
Object.defineProperty(exports, "__esModule", ({ |
| 14 |
value: true |
| 15 |
})); |
| 16 |
exports["default"] = void 0; |
| 17 |
var _document = _interopRequireDefault(__webpack_require__(/*! ./document */ "../assets/dev/js/frontend/document.js")); |
| 18 |
class _default extends elementorModules.ViewModule { |
| 19 |
constructor(...args) { |
| 20 |
super(...args); |
| 21 |
this.documents = {}; |
| 22 |
this.initDocumentClasses(); |
| 23 |
this.attachDocumentsClasses(); |
| 24 |
} |
| 25 |
getDefaultSettings() { |
| 26 |
return { |
| 27 |
selectors: { |
| 28 |
document: '.elementor' |
| 29 |
} |
| 30 |
}; |
| 31 |
} |
| 32 |
getDefaultElements() { |
| 33 |
const selectors = this.getSettings('selectors'); |
| 34 |
return { |
| 35 |
$documents: jQuery(selectors.document) |
| 36 |
}; |
| 37 |
} |
| 38 |
initDocumentClasses() { |
| 39 |
this.documentClasses = { |
| 40 |
base: _document.default |
| 41 |
}; |
| 42 |
elementorFrontend.hooks.doAction('elementor/frontend/documents-manager/init-classes', this); |
| 43 |
} |
| 44 |
addDocumentClass(documentType, documentClass) { |
| 45 |
this.documentClasses[documentType] = documentClass; |
| 46 |
} |
| 47 |
attachDocumentsClasses() { |
| 48 |
this.elements.$documents.each((index, document) => this.attachDocumentClass(jQuery(document))); |
| 49 |
} |
| 50 |
attachDocumentClass($document) { |
| 51 |
const documentData = $document.data(), |
| 52 |
documentID = documentData.elementorId, |
| 53 |
documentType = documentData.elementorType, |
| 54 |
DocumentClass = this.documentClasses[documentType] || this.documentClasses.base; |
| 55 |
this.documents[documentID] = new DocumentClass({ |
| 56 |
$element: $document, |
| 57 |
id: documentID |
| 58 |
}); |
| 59 |
} |
| 60 |
} |
| 61 |
exports["default"] = _default; |
| 62 |
|
| 63 |
/***/ }), |
| 64 |
|
| 65 |
/***/ "../assets/dev/js/frontend/elements-handlers-manager.js": |
| 66 |
/*!**************************************************************!*\ |
| 67 |
!*** ../assets/dev/js/frontend/elements-handlers-manager.js ***! |
| 68 |
\**************************************************************/ |
| 69 |
/***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 70 |
|
| 71 |
|
| 72 |
|
| 73 |
var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ "../node_modules/@babel/runtime/helpers/interopRequireDefault.js"); |
| 74 |
__webpack_require__(/*! core-js/modules/esnext.iterator.constructor.js */ "../node_modules/core-js/modules/esnext.iterator.constructor.js"); |
| 75 |
__webpack_require__(/*! core-js/modules/esnext.iterator.for-each.js */ "../node_modules/core-js/modules/esnext.iterator.for-each.js"); |
| 76 |
var _global = _interopRequireDefault(__webpack_require__(/*! ./handlers/global */ "../assets/dev/js/frontend/handlers/global.js")); |
| 77 |
var _container = _interopRequireDefault(__webpack_require__(/*! ./handlers/container/container */ "../assets/dev/js/frontend/handlers/container/container.js")); |
| 78 |
var _section = _interopRequireDefault(__webpack_require__(/*! ./handlers/section/section */ "../assets/dev/js/frontend/handlers/section/section.js")); |
| 79 |
var _column = _interopRequireDefault(__webpack_require__(/*! ./handlers/column */ "../assets/dev/js/frontend/handlers/column.js")); |
| 80 |
/* global elementorFrontendConfig */ |
| 81 |
|
| 82 |
module.exports = function ($) { |
| 83 |
const handlersInstances = {}; |
| 84 |
this.elementsHandlers = { |
| 85 |
'accordion.default': () => __webpack_require__.e(/*! import() | accordion */ "accordion").then(__webpack_require__.bind(__webpack_require__, /*! ./handlers/accordion */ "../assets/dev/js/frontend/handlers/accordion.js")), |
| 86 |
'alert.default': () => __webpack_require__.e(/*! import() | alert */ "alert").then(__webpack_require__.bind(__webpack_require__, /*! ./handlers/alert */ "../assets/dev/js/frontend/handlers/alert.js")), |
| 87 |
'counter.default': () => __webpack_require__.e(/*! import() | counter */ "counter").then(__webpack_require__.bind(__webpack_require__, /*! ./handlers/counter */ "../assets/dev/js/frontend/handlers/counter.js")), |
| 88 |
'progress.default': () => __webpack_require__.e(/*! import() | progress */ "progress").then(__webpack_require__.bind(__webpack_require__, /*! ./handlers/progress */ "../assets/dev/js/frontend/handlers/progress.js")), |
| 89 |
'tabs.default': () => __webpack_require__.e(/*! import() | tabs */ "tabs").then(__webpack_require__.bind(__webpack_require__, /*! ./handlers/tabs */ "../assets/dev/js/frontend/handlers/tabs.js")), |
| 90 |
'toggle.default': () => __webpack_require__.e(/*! import() | toggle */ "toggle").then(__webpack_require__.bind(__webpack_require__, /*! ./handlers/toggle */ "../assets/dev/js/frontend/handlers/toggle.js")), |
| 91 |
'video.default': () => __webpack_require__.e(/*! import() | video */ "video").then(__webpack_require__.bind(__webpack_require__, /*! ./handlers/video */ "../assets/dev/js/frontend/handlers/video.js")), |
| 92 |
'image-carousel.default': () => __webpack_require__.e(/*! import() | image-carousel */ "image-carousel").then(__webpack_require__.bind(__webpack_require__, /*! ./handlers/image-carousel */ "../assets/dev/js/frontend/handlers/image-carousel.js")), |
| 93 |
'text-editor.default': () => __webpack_require__.e(/*! import() | text-editor */ "text-editor").then(__webpack_require__.bind(__webpack_require__, /*! ./handlers/text-editor */ "../assets/dev/js/frontend/handlers/text-editor.js")), |
| 94 |
'wp-widget-media_audio.default': () => __webpack_require__.e(/*! import() | wp-audio */ "wp-audio").then(__webpack_require__.bind(__webpack_require__, /*! ./handlers/wp-audio */ "../assets/dev/js/frontend/handlers/wp-audio.js")), |
| 95 |
container: _container.default, |
| 96 |
section: _section.default, |
| 97 |
column: _column.default |
| 98 |
}; |
| 99 |
if (elementorFrontendConfig.experimentalFeatures['nested-elements']) { |
| 100 |
this.elementsHandlers['nested-tabs.default'] = () => __webpack_require__.e(/*! import() | nested-tabs */ "nested-tabs").then(__webpack_require__.bind(__webpack_require__, /*! elementor/modules/nested-tabs/assets/js/frontend/handlers/nested-tabs */ "../modules/nested-tabs/assets/js/frontend/handlers/nested-tabs.js")); |
| 101 |
} |
| 102 |
if (elementorFrontendConfig.experimentalFeatures['nested-elements']) { |
| 103 |
this.elementsHandlers['nested-accordion.default'] = () => __webpack_require__.e(/*! import() | nested-accordion */ "nested-accordion").then(__webpack_require__.bind(__webpack_require__, /*! elementor/modules/nested-accordion/assets/js/frontend/handlers/nested-accordion */ "../modules/nested-accordion/assets/js/frontend/handlers/nested-accordion.js")); |
| 104 |
} |
| 105 |
if (elementorFrontendConfig.experimentalFeatures.container) { |
| 106 |
this.elementsHandlers['contact-buttons.default'] = () => __webpack_require__.e(/*! import() | contact-buttons */ "contact-buttons").then(__webpack_require__.bind(__webpack_require__, /*! elementor/modules/floating-buttons/assets/js/floating-buttons/frontend/handlers/contact-buttons */ "../modules/floating-buttons/assets/js/floating-buttons/frontend/handlers/contact-buttons.js")); |
| 107 |
this.elementsHandlers['floating-bars-var-1.default'] = () => __webpack_require__.e(/*! import() | floating-bars */ "floating-bars").then(__webpack_require__.bind(__webpack_require__, /*! elementor/modules/floating-buttons/assets/js/floating-bars/frontend/handlers/floating-bars */ "../modules/floating-buttons/assets/js/floating-bars/frontend/handlers/floating-bars.js")); |
| 108 |
} |
| 109 |
const addGlobalHandlers = () => elementorFrontend.hooks.addAction('frontend/element_ready/global', _global.default); |
| 110 |
const addElementsHandlers = () => { |
| 111 |
$.each(this.elementsHandlers, (elementName, Handlers) => { |
| 112 |
const elementData = elementName.split('.'); |
| 113 |
elementName = elementData[0]; |
| 114 |
const skin = elementData[1] || null; |
| 115 |
this.attachHandler(elementName, Handlers, skin); |
| 116 |
}); |
| 117 |
}; |
| 118 |
const isClassHandler = Handler => Handler.prototype?.getUniqueHandlerID; |
| 119 |
const addHandlerWithHook = (elementBaseName, Handler, skin = 'default') => { |
| 120 |
skin = skin ? '.' + skin : ''; |
| 121 |
const elementName = elementBaseName + skin; |
| 122 |
elementorFrontend.hooks.addAction(`frontend/element_ready/${elementName}`, $element => { |
| 123 |
if (isClassHandler(Handler)) { |
| 124 |
this.addHandler(Handler, { |
| 125 |
$element, |
| 126 |
elementName |
| 127 |
}, true); |
| 128 |
} else { |
| 129 |
const handlerValue = Handler(); |
| 130 |
if (!handlerValue) { |
| 131 |
return; |
| 132 |
} |
| 133 |
if (handlerValue instanceof Promise) { |
| 134 |
handlerValue.then(({ |
| 135 |
default: dynamicHandler |
| 136 |
}) => { |
| 137 |
this.addHandler(dynamicHandler, { |
| 138 |
$element, |
| 139 |
elementName |
| 140 |
}, true); |
| 141 |
}); |
| 142 |
} else { |
| 143 |
this.addHandler(handlerValue, { |
| 144 |
$element, |
| 145 |
elementName |
| 146 |
}, true); |
| 147 |
} |
| 148 |
} |
| 149 |
}); |
| 150 |
}; |
| 151 |
this.addHandler = function (HandlerClass, options) { |
| 152 |
const elementID = options.$element.data('model-cid'); |
| 153 |
let handlerID; |
| 154 |
|
| 155 |
// If element is in edit mode |
| 156 |
if (elementID) { |
| 157 |
handlerID = HandlerClass.prototype.getConstructorID(); |
| 158 |
if (!handlersInstances[elementID]) { |
| 159 |
handlersInstances[elementID] = {}; |
| 160 |
} |
| 161 |
const oldHandler = handlersInstances[elementID][handlerID]; |
| 162 |
if (oldHandler) { |
| 163 |
oldHandler.onDestroy(); |
| 164 |
} |
| 165 |
} |
| 166 |
const newHandler = new HandlerClass(options); |
| 167 |
elementorFrontend.hooks.doAction(`frontend/element_handler_ready/${options.elementName}`, options.$element, $); |
| 168 |
if (elementID) { |
| 169 |
handlersInstances[elementID][handlerID] = newHandler; |
| 170 |
} |
| 171 |
}; |
| 172 |
this.attachHandler = (elementName, Handlers, skin) => { |
| 173 |
if (!Array.isArray(Handlers)) { |
| 174 |
Handlers = [Handlers]; |
| 175 |
} |
| 176 |
Handlers.forEach(Handler => addHandlerWithHook(elementName, Handler, skin)); |
| 177 |
}; |
| 178 |
this.getHandler = function (handlerName) { |
| 179 |
const elementHandler = this.elementsHandlers[handlerName]; |
| 180 |
if (isClassHandler(elementHandler)) { |
| 181 |
return elementHandler; |
| 182 |
} |
| 183 |
return new Promise(res => { |
| 184 |
elementHandler().then(({ |
| 185 |
default: dynamicHandler |
| 186 |
}) => { |
| 187 |
res(dynamicHandler); |
| 188 |
}); |
| 189 |
}); |
| 190 |
}; |
| 191 |
|
| 192 |
/** |
| 193 |
* @param {string} handlerName |
| 194 |
* @deprecated since 3.1.0, use `elementorFrontend.elementsHandler.getHandler` instead. |
| 195 |
*/ |
| 196 |
this.getHandlers = function (handlerName) { |
| 197 |
elementorDevTools.deprecation.deprecated('getHandlers', '3.1.0', 'elementorFrontend.elementsHandler.getHandler'); |
| 198 |
if (handlerName) { |
| 199 |
return this.getHandler(handlerName); |
| 200 |
} |
| 201 |
return this.elementsHandlers; |
| 202 |
}; |
| 203 |
this.runReadyTrigger = function (scope) { |
| 204 |
const isDelayChildHandlers = !!scope.closest('[data-delay-child-handlers="true"]') && 0 !== scope.closest('[data-delay-child-handlers="true"]').length; |
| 205 |
if (elementorFrontend.config.is_static || isDelayChildHandlers) { |
| 206 |
return; |
| 207 |
} |
| 208 |
|
| 209 |
// Initializing the `$scope` as frontend jQuery instance |
| 210 |
const $scope = jQuery(scope), |
| 211 |
elementType = $scope.attr('data-element_type'); |
| 212 |
if (!elementType) { |
| 213 |
return; |
| 214 |
} |
| 215 |
elementorFrontend.hooks.doAction('frontend/element_ready/global', $scope, $); |
| 216 |
elementorFrontend.hooks.doAction(`frontend/element_ready/${elementType}`, $scope, $); |
| 217 |
if ('widget' === elementType) { |
| 218 |
const widgetType = $scope.attr('data-widget_type'); |
| 219 |
elementorFrontend.hooks.doAction(`frontend/element_ready/${widgetType}`, $scope, $); |
| 220 |
} |
| 221 |
}; |
| 222 |
this.init = () => { |
| 223 |
addGlobalHandlers(); |
| 224 |
addElementsHandlers(); |
| 225 |
}; |
| 226 |
}; |
| 227 |
|
| 228 |
/***/ }), |
| 229 |
|
| 230 |
/***/ "../assets/dev/js/frontend/frontend.js": |
| 231 |
/*!*********************************************!*\ |
| 232 |
!*** ../assets/dev/js/frontend/frontend.js ***! |
| 233 |
\*********************************************/ |
| 234 |
/***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 235 |
|
| 236 |
|
| 237 |
|
| 238 |
var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ "../node_modules/@babel/runtime/helpers/interopRequireDefault.js"); |
| 239 |
Object.defineProperty(exports, "__esModule", ({ |
| 240 |
value: true |
| 241 |
})); |
| 242 |
exports["default"] = void 0; |
| 243 |
__webpack_require__(/*! core-js/modules/esnext.iterator.constructor.js */ "../node_modules/core-js/modules/esnext.iterator.constructor.js"); |
| 244 |
__webpack_require__(/*! core-js/modules/esnext.iterator.find.js */ "../node_modules/core-js/modules/esnext.iterator.find.js"); |
| 245 |
__webpack_require__(/*! core-js/modules/esnext.iterator.for-each.js */ "../node_modules/core-js/modules/esnext.iterator.for-each.js"); |
| 246 |
__webpack_require__(/*! ../public-path */ "../assets/dev/js/public-path.js"); |
| 247 |
var _documentsManager = _interopRequireDefault(__webpack_require__(/*! ./documents-manager */ "../assets/dev/js/frontend/documents-manager.js")); |
| 248 |
var _storage = _interopRequireDefault(__webpack_require__(/*! elementor-common/utils/storage */ "../core/common/assets/js/utils/storage.js")); |
| 249 |
var _environment = _interopRequireDefault(__webpack_require__(/*! elementor-common/utils/environment */ "../core/common/assets/js/utils/environment.js")); |
| 250 |
var _youtubeLoader = _interopRequireDefault(__webpack_require__(/*! ./utils/video-api/youtube-loader */ "../assets/dev/js/frontend/utils/video-api/youtube-loader.js")); |
| 251 |
var _vimeoLoader = _interopRequireDefault(__webpack_require__(/*! ./utils/video-api/vimeo-loader */ "../assets/dev/js/frontend/utils/video-api/vimeo-loader.js")); |
| 252 |
var _baseLoader = _interopRequireDefault(__webpack_require__(/*! ./utils/video-api/base-loader */ "../assets/dev/js/frontend/utils/video-api/base-loader.js")); |
| 253 |
var _urlActions = _interopRequireDefault(__webpack_require__(/*! ./utils/url-actions */ "../assets/dev/js/frontend/utils/url-actions.js")); |
| 254 |
var _swiper = _interopRequireDefault(__webpack_require__(/*! ./utils/swiper */ "../assets/dev/js/frontend/utils/swiper.js")); |
| 255 |
var _lightboxManager = _interopRequireDefault(__webpack_require__(/*! ./utils/lightbox/lightbox-manager */ "../assets/dev/js/frontend/utils/lightbox/lightbox-manager.js")); |
| 256 |
var _assetsLoader = _interopRequireDefault(__webpack_require__(/*! ./utils/assets-loader */ "../assets/dev/js/frontend/utils/assets-loader.js")); |
| 257 |
var _breakpoints = _interopRequireDefault(__webpack_require__(/*! elementor-utils/breakpoints */ "../assets/dev/js/utils/breakpoints.js")); |
| 258 |
var _events = _interopRequireDefault(__webpack_require__(/*! elementor-utils/events */ "../assets/dev/js/utils/events.js")); |
| 259 |
var _frontend = _interopRequireDefault(__webpack_require__(/*! elementor/modules/shapes/assets/js/frontend/frontend */ "../modules/shapes/assets/js/frontend/frontend.js")); |
| 260 |
var _controls = _interopRequireDefault(__webpack_require__(/*! ./utils/controls */ "../assets/dev/js/frontend/utils/controls.js")); |
| 261 |
var _anchorScrollMargin = _interopRequireDefault(__webpack_require__(/*! ./utils/anchor-scroll-margin */ "../assets/dev/js/frontend/utils/anchor-scroll-margin.js")); |
| 262 |
var _utils = __webpack_require__(/*! elementor-frontend/utils/utils */ "../assets/dev/js/frontend/utils/utils.js"); |
| 263 |
/* global elementorFrontendConfig */ |
| 264 |
|
| 265 |
const EventManager = __webpack_require__(/*! elementor-utils/hooks */ "../assets/dev/js/utils/hooks.js"), |
| 266 |
ElementsHandler = __webpack_require__(/*! elementor-frontend/elements-handlers-manager */ "../assets/dev/js/frontend/elements-handlers-manager.js"); |
| 267 |
class Frontend extends elementorModules.ViewModule { |
| 268 |
constructor(...args) { |
| 269 |
super(...args); |
| 270 |
this.config = elementorFrontendConfig; |
| 271 |
this.config.legacyMode = { |
| 272 |
/** |
| 273 |
* @deprecated since 3.1.0 |
| 274 |
*/ |
| 275 |
get elementWrappers() { |
| 276 |
if (elementorFrontend.isEditMode()) { |
| 277 |
window.top.elementorDevTools.deprecation.deprecated('elementorFrontend.config.legacyMode.elementWrappers', '3.1.0'); |
| 278 |
} |
| 279 |
return false; |
| 280 |
} |
| 281 |
}; |
| 282 |
this.populateActiveBreakpointsConfig(); |
| 283 |
} |
| 284 |
|
| 285 |
/** |
| 286 |
* @deprecated since 2.5.0, use `elementorModules.frontend.handlers.Base` instead. |
| 287 |
*/ |
| 288 |
get Module() { |
| 289 |
if (this.isEditMode()) { |
| 290 |
parent.elementorDevTools.deprecation.deprecated('elementorFrontend.Module', '2.5.0', 'elementorModules.frontend.handlers.Base'); |
| 291 |
} |
| 292 |
return elementorModules.frontend.handlers.Base; |
| 293 |
} |
| 294 |
getDefaultSettings() { |
| 295 |
return { |
| 296 |
selectors: { |
| 297 |
elementor: '.elementor', |
| 298 |
adminBar: '#wpadminbar' |
| 299 |
} |
| 300 |
}; |
| 301 |
} |
| 302 |
getDefaultElements() { |
| 303 |
const defaultElements = { |
| 304 |
window, |
| 305 |
$window: jQuery(window), |
| 306 |
$document: jQuery(document), |
| 307 |
$head: jQuery(document.head), |
| 308 |
$body: jQuery(document.body), |
| 309 |
$deviceMode: jQuery('<span>', { |
| 310 |
id: 'elementor-device-mode', |
| 311 |
class: 'elementor-screen-only' |
| 312 |
}) |
| 313 |
}; |
| 314 |
defaultElements.$body.append(defaultElements.$deviceMode); |
| 315 |
return defaultElements; |
| 316 |
} |
| 317 |
bindEvents() { |
| 318 |
this.elements.$window.on('resize', () => this.setDeviceModeData()); |
| 319 |
} |
| 320 |
|
| 321 |
/** |
| 322 |
* @param {string} elementName |
| 323 |
* @deprecated since 2.4.0, use `this.elements` instead. |
| 324 |
*/ |
| 325 |
getElements(elementName) { |
| 326 |
return this.getItems(this.elements, elementName); |
| 327 |
} |
| 328 |
|
| 329 |
/** |
| 330 |
* @param {string} settingName |
| 331 |
* @deprecated since 2.4.0, this method was never in use. |
| 332 |
*/ |
| 333 |
getPageSettings(settingName) { |
| 334 |
const settingsObject = this.isEditMode() ? elementor.settings.page.model.attributes : this.config.settings.page; |
| 335 |
return this.getItems(settingsObject, settingName); |
| 336 |
} |
| 337 |
|
| 338 |
/** |
| 339 |
* @param {string} settingName |
| 340 |
* @deprecated since 3.0.0, use `getKitSettings()` instead and remove the `elementor_` prefix. |
| 341 |
*/ |
| 342 |
getGeneralSettings(settingName) { |
| 343 |
if (this.isEditMode()) { |
| 344 |
parent.elementorDevTools.deprecation.deprecated('getGeneralSettings()', '3.0.0', 'getKitSettings() and remove the `elementor_` prefix'); |
| 345 |
} |
| 346 |
return this.getKitSettings(`elementor_${settingName}`); |
| 347 |
} |
| 348 |
getKitSettings(settingName) { |
| 349 |
// TODO: use Data API. |
| 350 |
return this.getItems(this.config.kit, settingName); |
| 351 |
} |
| 352 |
getCurrentDeviceMode() { |
| 353 |
return getComputedStyle(this.elements.$deviceMode[0], ':after').content.replace(/"/g, ''); |
| 354 |
} |
| 355 |
getDeviceSetting(deviceMode, settings, settingKey) { |
| 356 |
// Add specific handling for widescreen since it is larger than desktop. |
| 357 |
if ('widescreen' === deviceMode) { |
| 358 |
return this.getWidescreenSetting(settings, settingKey); |
| 359 |
} |
| 360 |
const devices = elementorFrontend.breakpoints.getActiveBreakpointsList({ |
| 361 |
largeToSmall: true, |
| 362 |
withDesktop: true |
| 363 |
}); |
| 364 |
let deviceIndex = devices.indexOf(deviceMode); |
| 365 |
while (deviceIndex > 0) { |
| 366 |
const currentDevice = devices[deviceIndex], |
| 367 |
fullSettingKey = settingKey + '_' + currentDevice, |
| 368 |
deviceValue = settings[fullSettingKey]; |
| 369 |
|
| 370 |
// Accept 0 as value. |
| 371 |
if (deviceValue || 0 === deviceValue) { |
| 372 |
return deviceValue; |
| 373 |
} |
| 374 |
deviceIndex--; |
| 375 |
} |
| 376 |
return settings[settingKey]; |
| 377 |
} |
| 378 |
getWidescreenSetting(settings, settingKey) { |
| 379 |
const deviceMode = 'widescreen', |
| 380 |
widescreenSettingKey = settingKey + '_' + deviceMode; |
| 381 |
let settingToReturn; |
| 382 |
|
| 383 |
// If the device mode is 'widescreen', and the setting exists - return it. |
| 384 |
if (settings[widescreenSettingKey]) { |
| 385 |
settingToReturn = settings[widescreenSettingKey]; |
| 386 |
} else { |
| 387 |
// Otherwise, return the desktop setting |
| 388 |
settingToReturn = settings[settingKey]; |
| 389 |
} |
| 390 |
return settingToReturn; |
| 391 |
} |
| 392 |
getCurrentDeviceSetting(settings, settingKey) { |
| 393 |
return this.getDeviceSetting(elementorFrontend.getCurrentDeviceMode(), settings, settingKey); |
| 394 |
} |
| 395 |
isEditMode() { |
| 396 |
return this.config.environmentMode.edit; |
| 397 |
} |
| 398 |
isWPPreviewMode() { |
| 399 |
return this.config.environmentMode.wpPreview; |
| 400 |
} |
| 401 |
initDialogsManager() { |
| 402 |
let dialogsManager; |
| 403 |
this.getDialogsManager = () => { |
| 404 |
if (!dialogsManager) { |
| 405 |
dialogsManager = new DialogsManager.Instance(); |
| 406 |
} |
| 407 |
return dialogsManager; |
| 408 |
}; |
| 409 |
} |
| 410 |
initOnReadyComponents() { |
| 411 |
this.utils = { |
| 412 |
youtube: new _youtubeLoader.default(), |
| 413 |
vimeo: new _vimeoLoader.default(), |
| 414 |
baseVideoLoader: new _baseLoader.default(), |
| 415 |
get lightbox() { |
| 416 |
return _lightboxManager.default.getLightbox(); |
| 417 |
}, |
| 418 |
urlActions: new _urlActions.default(), |
| 419 |
swiper: _swiper.default, |
| 420 |
environment: _environment.default, |
| 421 |
assetsLoader: new _assetsLoader.default(), |
| 422 |
escapeHTML: _utils.escapeHTML, |
| 423 |
events: _events.default, |
| 424 |
controls: new _controls.default(), |
| 425 |
anchor_scroll_margin: new _anchorScrollMargin.default() |
| 426 |
}; |
| 427 |
|
| 428 |
// TODO: BC since 2.4.0 |
| 429 |
this.modules = { |
| 430 |
StretchElement: elementorModules.frontend.tools.StretchElement, |
| 431 |
Masonry: elementorModules.utils.Masonry |
| 432 |
}; |
| 433 |
this.elementsHandler.init(); |
| 434 |
if (this.isEditMode()) { |
| 435 |
elementor.once('document:loaded', () => this.onDocumentLoaded()); |
| 436 |
} else { |
| 437 |
this.onDocumentLoaded(); |
| 438 |
} |
| 439 |
} |
| 440 |
initOnReadyElements() { |
| 441 |
this.elements.$wpAdminBar = this.elements.$document.find(this.getSettings('selectors.adminBar')); |
| 442 |
} |
| 443 |
addUserAgentClasses() { |
| 444 |
for (const [key, value] of Object.entries(_environment.default)) { |
| 445 |
if (value) { |
| 446 |
this.elements.$body.addClass('e--ua-' + key); |
| 447 |
} |
| 448 |
} |
| 449 |
} |
| 450 |
setDeviceModeData() { |
| 451 |
this.elements.$body.attr('data-elementor-device-mode', this.getCurrentDeviceMode()); |
| 452 |
} |
| 453 |
addListenerOnce(listenerID, event, callback, to) { |
| 454 |
if (!to) { |
| 455 |
to = this.elements.$window; |
| 456 |
} |
| 457 |
if (!this.isEditMode()) { |
| 458 |
to.on(event, callback); |
| 459 |
return; |
| 460 |
} |
| 461 |
this.removeListeners(listenerID, event, to); |
| 462 |
if (to instanceof jQuery) { |
| 463 |
const eventNS = event + '.' + listenerID; |
| 464 |
to.on(eventNS, callback); |
| 465 |
} else { |
| 466 |
to.on(event, callback, listenerID); |
| 467 |
} |
| 468 |
} |
| 469 |
removeListeners(listenerID, event, callback, from) { |
| 470 |
if (!from) { |
| 471 |
from = this.elements.$window; |
| 472 |
} |
| 473 |
if (from instanceof jQuery) { |
| 474 |
const eventNS = event + '.' + listenerID; |
| 475 |
from.off(eventNS, callback); |
| 476 |
} else { |
| 477 |
from.off(event, callback, listenerID); |
| 478 |
} |
| 479 |
} |
| 480 |
|
| 481 |
// Based on underscore function |
| 482 |
debounce(func, wait) { |
| 483 |
let timeout; |
| 484 |
return function () { |
| 485 |
const context = this, |
| 486 |
args = arguments; |
| 487 |
const later = () => { |
| 488 |
timeout = null; |
| 489 |
func.apply(context, args); |
| 490 |
}; |
| 491 |
const callNow = !timeout; |
| 492 |
clearTimeout(timeout); |
| 493 |
timeout = setTimeout(later, wait); |
| 494 |
if (callNow) { |
| 495 |
func.apply(context, args); |
| 496 |
} |
| 497 |
}; |
| 498 |
} |
| 499 |
muteMigrationTraces() { |
| 500 |
jQuery.migrateMute = true; |
| 501 |
jQuery.migrateTrace = false; |
| 502 |
} |
| 503 |
|
| 504 |
/** |
| 505 |
* Initialize the modules' widgets handlers. |
| 506 |
*/ |
| 507 |
initModules() { |
| 508 |
const handlers = { |
| 509 |
shapes: _frontend.default |
| 510 |
}; |
| 511 |
|
| 512 |
// TODO: BC - Deprecated since 3.5.0 |
| 513 |
elementorFrontend.trigger('elementor/modules/init:before'); |
| 514 |
|
| 515 |
// TODO: Use this instead. |
| 516 |
elementorFrontend.trigger('elementor/modules/init/before'); |
| 517 |
Object.entries(handlers).forEach(([moduleName, ModuleClass]) => { |
| 518 |
this.modulesHandlers[moduleName] = new ModuleClass(); |
| 519 |
}); |
| 520 |
} |
| 521 |
populateActiveBreakpointsConfig() { |
| 522 |
this.config.responsive.activeBreakpoints = {}; |
| 523 |
Object.entries(this.config.responsive.breakpoints).forEach(([breakpointKey, breakpointData]) => { |
| 524 |
if (breakpointData.is_enabled) { |
| 525 |
this.config.responsive.activeBreakpoints[breakpointKey] = breakpointData; |
| 526 |
} |
| 527 |
}); |
| 528 |
} |
| 529 |
init() { |
| 530 |
this.hooks = new EventManager(); |
| 531 |
this.breakpoints = new _breakpoints.default(this.config.responsive); |
| 532 |
this.storage = new _storage.default(); |
| 533 |
this.elementsHandler = new ElementsHandler(jQuery); |
| 534 |
this.modulesHandlers = {}; |
| 535 |
this.addUserAgentClasses(); |
| 536 |
this.setDeviceModeData(); |
| 537 |
this.initDialogsManager(); |
| 538 |
if (this.isEditMode()) { |
| 539 |
this.muteMigrationTraces(); |
| 540 |
} |
| 541 |
|
| 542 |
// Keep this line before `initOnReadyComponents` call |
| 543 |
_events.default.dispatch(this.elements.$window, 'elementor/frontend/init'); |
| 544 |
this.initModules(); |
| 545 |
this.initOnReadyElements(); |
| 546 |
this.initOnReadyComponents(); |
| 547 |
} |
| 548 |
onDocumentLoaded() { |
| 549 |
this.documentsManager = new _documentsManager.default(); |
| 550 |
this.trigger('components:init'); |
| 551 |
new _lightboxManager.default(); |
| 552 |
} |
| 553 |
} |
| 554 |
exports["default"] = Frontend; |
| 555 |
window.elementorFrontend = new Frontend(); |
| 556 |
if (!elementorFrontend.isEditMode()) { |
| 557 |
jQuery(() => elementorFrontend.init()); |
| 558 |
} |
| 559 |
|
| 560 |
/***/ }), |
| 561 |
|
| 562 |
/***/ "../assets/dev/js/frontend/handlers/column.js": |
| 563 |
/*!****************************************************!*\ |
| 564 |
!*** ../assets/dev/js/frontend/handlers/column.js ***! |
| 565 |
\****************************************************/ |
| 566 |
/***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 567 |
|
| 568 |
|
| 569 |
|
| 570 |
Object.defineProperty(exports, "__esModule", ({ |
| 571 |
value: true |
| 572 |
})); |
| 573 |
exports["default"] = void 0; |
| 574 |
var _default = exports["default"] = [() => __webpack_require__.e(/*! import() | shared-frontend-handlers */ "shared-frontend-handlers").then(__webpack_require__.bind(__webpack_require__, /*! ./background-slideshow */ "../assets/dev/js/frontend/handlers/background-slideshow.js"))]; |
| 575 |
|
| 576 |
/***/ }), |
| 577 |
|
| 578 |
/***/ "../assets/dev/js/frontend/handlers/container/container.js": |
| 579 |
/*!*****************************************************************!*\ |
| 580 |
!*** ../assets/dev/js/frontend/handlers/container/container.js ***! |
| 581 |
\*****************************************************************/ |
| 582 |
/***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 583 |
|
| 584 |
|
| 585 |
|
| 586 |
Object.defineProperty(exports, "__esModule", ({ |
| 587 |
value: true |
| 588 |
})); |
| 589 |
exports["default"] = void 0; |
| 590 |
var _createEditorHandler = __webpack_require__(/*! ../create-editor-handler */ "../assets/dev/js/frontend/handlers/create-editor-handler.js"); |
| 591 |
var _default = exports["default"] = [() => __webpack_require__.e(/*! import() | shared-frontend-handlers */ "shared-frontend-handlers").then(__webpack_require__.bind(__webpack_require__, /*! ../background-slideshow */ "../assets/dev/js/frontend/handlers/background-slideshow.js")), () => __webpack_require__.e(/*! import() | shared-frontend-handlers */ "shared-frontend-handlers").then(__webpack_require__.bind(__webpack_require__, /*! ../background-video */ "../assets/dev/js/frontend/handlers/background-video.js")), (0, _createEditorHandler.createEditorHandler)(() => __webpack_require__.e(/*! import() | shared-editor-handlers */ "shared-editor-handlers").then(__webpack_require__.bind(__webpack_require__, /*! ../handles-position */ "../assets/dev/js/frontend/handlers/handles-position.js"))), (0, _createEditorHandler.createEditorHandler)(() => __webpack_require__.e(/*! import() | container-editor-handlers */ "container-editor-handlers").then(__webpack_require__.bind(__webpack_require__, /*! ./shapes */ "../assets/dev/js/frontend/handlers/container/shapes.js"))), (0, _createEditorHandler.createEditorHandler)(() => __webpack_require__.e(/*! import() | container-editor-handlers */ "container-editor-handlers").then(__webpack_require__.bind(__webpack_require__, /*! ./grid-container */ "../assets/dev/js/frontend/handlers/container/grid-container.js")))]; |
| 592 |
|
| 593 |
/***/ }), |
| 594 |
|
| 595 |
/***/ "../assets/dev/js/frontend/handlers/create-editor-handler.js": |
| 596 |
/*!*******************************************************************!*\ |
| 597 |
!*** ../assets/dev/js/frontend/handlers/create-editor-handler.js ***! |
| 598 |
\*******************************************************************/ |
| 599 |
/***/ ((__unused_webpack_module, exports) => { |
| 600 |
|
| 601 |
|
| 602 |
|
| 603 |
Object.defineProperty(exports, "__esModule", ({ |
| 604 |
value: true |
| 605 |
})); |
| 606 |
exports.createEditorHandler = createEditorHandler; |
| 607 |
function createEditorHandler(importer) { |
| 608 |
return () => { |
| 609 |
return new Promise(resolve => { |
| 610 |
if (elementorFrontend.isEditMode()) { |
| 611 |
importer().then(resolve); |
| 612 |
} |
| 613 |
}); |
| 614 |
}; |
| 615 |
} |
| 616 |
|
| 617 |
/***/ }), |
| 618 |
|
| 619 |
/***/ "../assets/dev/js/frontend/handlers/global.js": |
| 620 |
/*!****************************************************!*\ |
| 621 |
!*** ../assets/dev/js/frontend/handlers/global.js ***! |
| 622 |
\****************************************************/ |
| 623 |
/***/ ((__unused_webpack_module, exports) => { |
| 624 |
|
| 625 |
|
| 626 |
|
| 627 |
Object.defineProperty(exports, "__esModule", ({ |
| 628 |
value: true |
| 629 |
})); |
| 630 |
exports["default"] = void 0; |
| 631 |
class GlobalHandler extends elementorModules.frontend.handlers.Base { |
| 632 |
getWidgetType() { |
| 633 |
return 'global'; |
| 634 |
} |
| 635 |
animate() { |
| 636 |
const $element = this.$element, |
| 637 |
animation = this.getAnimation(); |
| 638 |
if ('none' === animation) { |
| 639 |
$element.removeClass('elementor-invisible'); |
| 640 |
return; |
| 641 |
} |
| 642 |
const elementSettings = this.getElementSettings(), |
| 643 |
animationDelay = elementSettings._animation_delay || elementSettings.animation_delay || 0; |
| 644 |
$element.removeClass(animation); |
| 645 |
if (this.currentAnimation) { |
| 646 |
$element.removeClass(this.currentAnimation); |
| 647 |
} |
| 648 |
this.currentAnimation = animation; |
| 649 |
setTimeout(() => { |
| 650 |
$element.removeClass('elementor-invisible').addClass('animated ' + animation); |
| 651 |
}, animationDelay); |
| 652 |
} |
| 653 |
getAnimation() { |
| 654 |
return this.getCurrentDeviceSetting('animation') || this.getCurrentDeviceSetting('_animation'); |
| 655 |
} |
| 656 |
onInit(...args) { |
| 657 |
super.onInit(...args); |
| 658 |
if (this.getAnimation()) { |
| 659 |
const observer = elementorModules.utils.Scroll.scrollObserver({ |
| 660 |
callback: event => { |
| 661 |
if (event.isInViewport) { |
| 662 |
this.animate(); |
| 663 |
observer.unobserve(this.$element[0]); |
| 664 |
} |
| 665 |
} |
| 666 |
}); |
| 667 |
observer.observe(this.$element[0]); |
| 668 |
} |
| 669 |
} |
| 670 |
onElementChange(propertyName) { |
| 671 |
if (/^_?animation/.test(propertyName)) { |
| 672 |
this.animate(); |
| 673 |
} |
| 674 |
} |
| 675 |
} |
| 676 |
var _default = $scope => { |
| 677 |
elementorFrontend.elementsHandler.addHandler(GlobalHandler, { |
| 678 |
$element: $scope |
| 679 |
}); |
| 680 |
}; |
| 681 |
exports["default"] = _default; |
| 682 |
|
| 683 |
/***/ }), |
| 684 |
|
| 685 |
/***/ "../assets/dev/js/frontend/handlers/section/section.js": |
| 686 |
/*!*************************************************************!*\ |
| 687 |
!*** ../assets/dev/js/frontend/handlers/section/section.js ***! |
| 688 |
\*************************************************************/ |
| 689 |
/***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 690 |
|
| 691 |
|
| 692 |
|
| 693 |
Object.defineProperty(exports, "__esModule", ({ |
| 694 |
value: true |
| 695 |
})); |
| 696 |
exports["default"] = void 0; |
| 697 |
var _createEditorHandler = __webpack_require__(/*! ../create-editor-handler */ "../assets/dev/js/frontend/handlers/create-editor-handler.js"); |
| 698 |
var _default = exports["default"] = [() => __webpack_require__.e(/*! import() | section-frontend-handlers */ "section-frontend-handlers").then(__webpack_require__.bind(__webpack_require__, /*! ./stretched-section */ "../assets/dev/js/frontend/handlers/section/stretched-section.js")), |
| 699 |
// Must run before BackgroundSlideshow to init the slideshow only after the stretch. |
| 700 |
() => __webpack_require__.e(/*! import() | shared-frontend-handlers */ "shared-frontend-handlers").then(__webpack_require__.bind(__webpack_require__, /*! ../background-slideshow */ "../assets/dev/js/frontend/handlers/background-slideshow.js")), () => __webpack_require__.e(/*! import() | shared-frontend-handlers */ "shared-frontend-handlers").then(__webpack_require__.bind(__webpack_require__, /*! ../background-video */ "../assets/dev/js/frontend/handlers/background-video.js")), (0, _createEditorHandler.createEditorHandler)(() => __webpack_require__.e(/*! import() | shared-editor-handlers */ "shared-editor-handlers").then(__webpack_require__.bind(__webpack_require__, /*! ../handles-position */ "../assets/dev/js/frontend/handlers/handles-position.js"))), (0, _createEditorHandler.createEditorHandler)(() => __webpack_require__.e(/*! import() | section-editor-handlers */ "section-editor-handlers").then(__webpack_require__.bind(__webpack_require__, /*! ./shapes */ "../assets/dev/js/frontend/handlers/section/shapes.js")))]; |
| 701 |
|
| 702 |
/***/ }), |
| 703 |
|
| 704 |
/***/ "../assets/dev/js/frontend/utils/anchor-scroll-margin.js": |
| 705 |
/*!***************************************************************!*\ |
| 706 |
!*** ../assets/dev/js/frontend/utils/anchor-scroll-margin.js ***! |
| 707 |
\***************************************************************/ |
| 708 |
/***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 709 |
|
| 710 |
|
| 711 |
|
| 712 |
Object.defineProperty(exports, "__esModule", ({ |
| 713 |
value: true |
| 714 |
})); |
| 715 |
exports["default"] = void 0; |
| 716 |
__webpack_require__(/*! core-js/modules/es.array.push.js */ "../node_modules/core-js/modules/es.array.push.js"); |
| 717 |
__webpack_require__(/*! core-js/modules/esnext.iterator.constructor.js */ "../node_modules/core-js/modules/esnext.iterator.constructor.js"); |
| 718 |
__webpack_require__(/*! core-js/modules/esnext.iterator.filter.js */ "../node_modules/core-js/modules/esnext.iterator.filter.js"); |
| 719 |
__webpack_require__(/*! core-js/modules/esnext.iterator.for-each.js */ "../node_modules/core-js/modules/esnext.iterator.for-each.js"); |
| 720 |
class _default extends elementorModules.ViewModule { |
| 721 |
getDefaultSettings() { |
| 722 |
return { |
| 723 |
selectors: { |
| 724 |
links: '.elementor-element a[href*="#"]', |
| 725 |
stickyElements: '.elementor-element.elementor-sticky' |
| 726 |
} |
| 727 |
}; |
| 728 |
} |
| 729 |
onInit() { |
| 730 |
this.observeStickyElements(() => { |
| 731 |
this.initializeStickyAndAnchorTracking(); |
| 732 |
}); |
| 733 |
} |
| 734 |
observeStickyElements(callback) { |
| 735 |
const observer = new MutationObserver(mutationsList => { |
| 736 |
for (const mutation of mutationsList) { |
| 737 |
if ('childList' === mutation.type || 'attributes' === mutation.type && mutation.target.classList.contains('elementor-sticky')) { |
| 738 |
callback(); |
| 739 |
} |
| 740 |
} |
| 741 |
}); |
| 742 |
observer.observe(document.body, { |
| 743 |
childList: true, |
| 744 |
subtree: true, |
| 745 |
attributes: true, |
| 746 |
attributeFilter: ['class', 'style'] |
| 747 |
}); |
| 748 |
} |
| 749 |
initializeStickyAndAnchorTracking() { |
| 750 |
const anchorLinks = this.getAllAnchorLinks(); |
| 751 |
const stickyElements = this.getAllStickyElements(); |
| 752 |
const trackedElements = []; |
| 753 |
if (!stickyElements.length > 0 && !anchorLinks.length > 0) { |
| 754 |
return; |
| 755 |
} |
| 756 |
this.trackStickyElements(stickyElements, trackedElements); |
| 757 |
this.trackAnchorLinks(anchorLinks, trackedElements); |
| 758 |
this.organizeStickyAndAnchors(trackedElements); |
| 759 |
} |
| 760 |
trackAnchorLinks(anchorLinks, trackedElements) { |
| 761 |
anchorLinks.forEach(element => { |
| 762 |
const target = this.getAnchorTarget(element); |
| 763 |
const scrollPosition = this.getScrollPosition(target); |
| 764 |
trackedElements.push({ |
| 765 |
element: target, |
| 766 |
type: 'anchor', |
| 767 |
scrollPosition |
| 768 |
}); |
| 769 |
}); |
| 770 |
} |
| 771 |
trackStickyElements(stickyElements, trackedElements) { |
| 772 |
stickyElements.forEach(element => { |
| 773 |
const settings = this.getElementSettings(element); |
| 774 |
if (!settings || !settings.sticky_anchor_link_offset) { |
| 775 |
return; |
| 776 |
} |
| 777 |
const { |
| 778 |
sticky_anchor_link_offset: scrollMarginTop |
| 779 |
} = settings; |
| 780 |
if (0 === scrollMarginTop) { |
| 781 |
return; |
| 782 |
} |
| 783 |
const scrollPosition = this.getScrollPosition(element); |
| 784 |
trackedElements.push({ |
| 785 |
scrollMarginTop, |
| 786 |
type: 'sticky', |
| 787 |
scrollPosition |
| 788 |
}); |
| 789 |
}); |
| 790 |
} |
| 791 |
organizeStickyAndAnchors(elements) { |
| 792 |
const stickyList = this.filterAndSortElementsByType(elements, 'sticky'); |
| 793 |
const anchorList = this.filterAndSortElementsByType(elements, 'anchor'); |
| 794 |
stickyList.forEach((sticky, index) => { |
| 795 |
this.defineCurrentStickyRange(sticky, index, stickyList, anchorList); |
| 796 |
}); |
| 797 |
} |
| 798 |
defineCurrentStickyRange(sticky, index, stickyList, anchorList) { |
| 799 |
const nextStickyScrollPosition = index + 1 < stickyList.length ? stickyList[index + 1].scrollPosition : Infinity; |
| 800 |
sticky.anchor = anchorList.filter(anchor => { |
| 801 |
const withinRange = anchor.scrollPosition > sticky.scrollPosition && anchor.scrollPosition < nextStickyScrollPosition; |
| 802 |
if (withinRange) { |
| 803 |
anchor.element.style.scrollMarginTop = `${sticky.scrollMarginTop}px`; |
| 804 |
} |
| 805 |
return withinRange; |
| 806 |
}); |
| 807 |
} |
| 808 |
getScrollPosition(element) { |
| 809 |
let offsetTop = 0; |
| 810 |
while (element) { |
| 811 |
offsetTop += element.offsetTop; |
| 812 |
element = element.offsetParent; |
| 813 |
} |
| 814 |
return offsetTop; |
| 815 |
} |
| 816 |
getAllStickyElements() { |
| 817 |
const allStickyElements = document.querySelectorAll(this.getSettings('selectors.stickyElements')); |
| 818 |
return Array.from(allStickyElements).filter((anchor, index, self) => index === self.findIndex(t => t.getAttribute('data-id') === anchor.getAttribute('data-id'))); |
| 819 |
} |
| 820 |
getAllAnchorLinks() { |
| 821 |
const allAnchors = document.querySelectorAll(this.getSettings('selectors.links')); |
| 822 |
return Array.from(allAnchors).filter((anchor, index, self) => index === self.findIndex(t => t.getAttribute('href') === anchor.getAttribute('href'))); |
| 823 |
} |
| 824 |
filterAndSortElementsByType(elements, type) { |
| 825 |
return elements.filter(item => type === item.type).sort((a, b) => a.scrollPosition - b.scrollPosition); |
| 826 |
} |
| 827 |
isValidSelector(hash) { |
| 828 |
const validSelectorPattern = /^#[A-Za-z_][\w-]*$/; |
| 829 |
return validSelectorPattern.test(hash); |
| 830 |
} |
| 831 |
getAnchorTarget(element) { |
| 832 |
const hash = element?.hash; |
| 833 |
if (!this.isValidSelector(hash)) { |
| 834 |
return null; |
| 835 |
} |
| 836 |
return document.querySelector(hash); |
| 837 |
} |
| 838 |
getElementSettings(element) { |
| 839 |
return JSON.parse(element.getAttribute('data-settings')); |
| 840 |
} |
| 841 |
} |
| 842 |
exports["default"] = _default; |
| 843 |
|
| 844 |
/***/ }), |
| 845 |
|
| 846 |
/***/ "../assets/dev/js/frontend/utils/assets-loader.js": |
| 847 |
/*!********************************************************!*\ |
| 848 |
!*** ../assets/dev/js/frontend/utils/assets-loader.js ***! |
| 849 |
\********************************************************/ |
| 850 |
/***/ ((__unused_webpack_module, exports) => { |
| 851 |
|
| 852 |
|
| 853 |
|
| 854 |
Object.defineProperty(exports, "__esModule", ({ |
| 855 |
value: true |
| 856 |
})); |
| 857 |
exports["default"] = void 0; |
| 858 |
class AssetsLoader { |
| 859 |
getScriptElement(src) { |
| 860 |
const scriptElement = document.createElement('script'); |
| 861 |
scriptElement.src = src; |
| 862 |
return scriptElement; |
| 863 |
} |
| 864 |
getStyleElement(src) { |
| 865 |
const styleElement = document.createElement('link'); |
| 866 |
styleElement.rel = 'stylesheet'; |
| 867 |
styleElement.href = src; |
| 868 |
return styleElement; |
| 869 |
} |
| 870 |
load(type, key) { |
| 871 |
const assetData = AssetsLoader.assets[type][key]; |
| 872 |
if (!assetData.loader) { |
| 873 |
assetData.loader = this.isAssetLoaded(assetData, type) ? Promise.resolve(true) : this.loadAsset(assetData, type); |
| 874 |
} |
| 875 |
return assetData.loader; |
| 876 |
} |
| 877 |
isAssetLoaded(assetData, assetType) { |
| 878 |
const filePath = 'script' === assetType ? `script[src="${assetData.src}"]` : `link[href="${assetData.src}"]`; |
| 879 |
return !!document.querySelectorAll(filePath)?.length; |
| 880 |
} |
| 881 |
loadAsset(assetData, assetType) { |
| 882 |
return new Promise(resolve => { |
| 883 |
const element = 'style' === assetType ? this.getStyleElement(assetData.src) : this.getScriptElement(assetData.src); |
| 884 |
element.onload = () => resolve(true); |
| 885 |
this.appendAsset(assetData, element); |
| 886 |
}); |
| 887 |
} |
| 888 |
appendAsset(assetData, element) { |
| 889 |
const beforeElement = document.querySelector(assetData.before); |
| 890 |
if (!!beforeElement) { |
| 891 |
beforeElement.insertAdjacentElement('beforebegin', element); |
| 892 |
return; |
| 893 |
} |
| 894 |
const parent = 'head' === assetData.parent ? assetData.parent : 'body'; |
| 895 |
document[parent].appendChild(element); |
| 896 |
} |
| 897 |
} |
| 898 |
exports["default"] = AssetsLoader; |
| 899 |
const assetsUrl = elementorFrontendConfig.urls.assets; |
| 900 |
const fileSuffix = elementorFrontendConfig.environmentMode.isScriptDebug ? '' : '.min'; |
| 901 |
const pluginVersion = elementorFrontendConfig.version; |
| 902 |
AssetsLoader.assets = { |
| 903 |
script: { |
| 904 |
dialog: { |
| 905 |
src: `${assetsUrl}lib/dialog/dialog${fileSuffix}.js?ver=4.9.3` |
| 906 |
}, |
| 907 |
'share-link': { |
| 908 |
src: `${assetsUrl}lib/share-link/share-link${fileSuffix}.js?ver=${pluginVersion}` |
| 909 |
}, |
| 910 |
// TODO: Remove 'swiper' in v3.29.0 [ED-16272]. |
| 911 |
swiper: { |
| 912 |
src: `${assetsUrl}lib/swiper/v8/swiper${fileSuffix}.js?ver=8.4.5` |
| 913 |
} |
| 914 |
}, |
| 915 |
style: { |
| 916 |
swiper: { |
| 917 |
src: `${assetsUrl}lib/swiper/v8/css/swiper${fileSuffix}.css?ver=8.4.5`, |
| 918 |
parent: 'head' |
| 919 |
}, |
| 920 |
'e-lightbox': { |
| 921 |
src: elementorFrontendConfig?.responsive?.hasCustomBreakpoints ? `${elementorFrontendConfig.urls.uploadUrl}/elementor/css/custom-lightbox.min.css?ver=${pluginVersion}` : `${assetsUrl}css/conditionals/lightbox${fileSuffix}.css?ver=${pluginVersion}` |
| 922 |
}, |
| 923 |
dialog: { |
| 924 |
src: `${assetsUrl}css/conditionals/dialog${fileSuffix}.css?ver=${pluginVersion}`, |
| 925 |
parent: 'head', |
| 926 |
before: '#elementor-frontend-css' |
| 927 |
} |
| 928 |
} |
| 929 |
}; |
| 930 |
|
| 931 |
/***/ }), |
| 932 |
|
| 933 |
/***/ "../assets/dev/js/frontend/utils/controls.js": |
| 934 |
/*!***************************************************!*\ |
| 935 |
!*** ../assets/dev/js/frontend/utils/controls.js ***! |
| 936 |
\***************************************************/ |
| 937 |
/***/ ((__unused_webpack_module, exports) => { |
| 938 |
|
| 939 |
|
| 940 |
|
| 941 |
Object.defineProperty(exports, "__esModule", ({ |
| 942 |
value: true |
| 943 |
})); |
| 944 |
exports["default"] = void 0; |
| 945 |
class Controls { |
| 946 |
/** |
| 947 |
* Get Control Value |
| 948 |
* |
| 949 |
* Retrieves a control value. |
| 950 |
* This function has been copied from `elementor/assets/dev/js/editor/utils/conditions.js`. |
| 951 |
* |
| 952 |
* @since 3.11.0 |
| 953 |
* |
| 954 |
* @param {{}} controlSettings A settings object (e.g. element settings - keys and values) |
| 955 |
* @param {string} controlKey The control key name |
| 956 |
* @param {string} controlSubKey A specific property of the control object. |
| 957 |
* @return {*} Control Value |
| 958 |
*/ |
| 959 |
getControlValue(controlSettings, controlKey, controlSubKey) { |
| 960 |
let value; |
| 961 |
if ('object' === typeof controlSettings[controlKey] && controlSubKey) { |
| 962 |
value = controlSettings[controlKey][controlSubKey]; |
| 963 |
} else { |
| 964 |
value = controlSettings[controlKey]; |
| 965 |
} |
| 966 |
return value; |
| 967 |
} |
| 968 |
|
| 969 |
/** |
| 970 |
* Get the value of a responsive control. |
| 971 |
* |
| 972 |
* Retrieves the value of a responsive control for the current device or for this first parent device which has a control value. |
| 973 |
* |
| 974 |
* @since 3.11.0 |
| 975 |
* |
| 976 |
* @param {{}} controlSettings A settings object (e.g. element settings - keys and values) |
| 977 |
* @param {string} controlKey The control key name |
| 978 |
* @param {string} controlSubKey A specific property of the control object. |
| 979 |
* @param {string} device If we want to get a value for a specific device mode. |
| 980 |
* @return {*} Control Value |
| 981 |
*/ |
| 982 |
getResponsiveControlValue(controlSettings, controlKey, controlSubKey = '', device = null) { |
| 983 |
const currentDeviceMode = device || elementorFrontend.getCurrentDeviceMode(), |
| 984 |
controlValueDesktop = this.getControlValue(controlSettings, controlKey, controlSubKey); |
| 985 |
|
| 986 |
// Set the control value for the current device mode. |
| 987 |
// First check the widescreen device mode. |
| 988 |
if ('widescreen' === currentDeviceMode) { |
| 989 |
const controlValueWidescreen = this.getControlValue(controlSettings, `${controlKey}_widescreen`, controlSubKey); |
| 990 |
return !!controlValueWidescreen || 0 === controlValueWidescreen ? controlValueWidescreen : controlValueDesktop; |
| 991 |
} |
| 992 |
|
| 993 |
// Loop through all responsive and desktop device modes. |
| 994 |
const activeBreakpoints = elementorFrontend.breakpoints.getActiveBreakpointsList({ |
| 995 |
withDesktop: true |
| 996 |
}); |
| 997 |
let parentDeviceMode = currentDeviceMode, |
| 998 |
deviceIndex = activeBreakpoints.indexOf(currentDeviceMode), |
| 999 |
controlValue = ''; |
| 1000 |
while (deviceIndex <= activeBreakpoints.length) { |
| 1001 |
if ('desktop' === parentDeviceMode) { |
| 1002 |
controlValue = controlValueDesktop; |
| 1003 |
break; |
| 1004 |
} |
| 1005 |
const responsiveControlKey = `${controlKey}_${parentDeviceMode}`, |
| 1006 |
responsiveControlValue = this.getControlValue(controlSettings, responsiveControlKey, controlSubKey); |
| 1007 |
if (!!responsiveControlValue || 0 === responsiveControlValue) { |
| 1008 |
controlValue = responsiveControlValue; |
| 1009 |
break; |
| 1010 |
} |
| 1011 |
|
| 1012 |
// If no control value has been set for the current device mode, then check the parent device mode. |
| 1013 |
deviceIndex++; |
| 1014 |
parentDeviceMode = activeBreakpoints[deviceIndex]; |
| 1015 |
} |
| 1016 |
return controlValue; |
| 1017 |
} |
| 1018 |
} |
| 1019 |
exports["default"] = Controls; |
| 1020 |
|
| 1021 |
/***/ }), |
| 1022 |
|
| 1023 |
/***/ "../assets/dev/js/frontend/utils/lightbox/lightbox-manager.js": |
| 1024 |
/*!********************************************************************!*\ |
| 1025 |
!*** ../assets/dev/js/frontend/utils/lightbox/lightbox-manager.js ***! |
| 1026 |
\********************************************************************/ |
| 1027 |
/***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 1028 |
|
| 1029 |
|
| 1030 |
|
| 1031 |
Object.defineProperty(exports, "__esModule", ({ |
| 1032 |
value: true |
| 1033 |
})); |
| 1034 |
exports["default"] = void 0; |
| 1035 |
__webpack_require__(/*! core-js/modules/esnext.iterator.constructor.js */ "../node_modules/core-js/modules/esnext.iterator.constructor.js"); |
| 1036 |
__webpack_require__(/*! core-js/modules/esnext.iterator.find.js */ "../node_modules/core-js/modules/esnext.iterator.find.js"); |
| 1037 |
class LightboxManager extends elementorModules.ViewModule { |
| 1038 |
static getLightbox() { |
| 1039 |
const lightboxPromise = new Promise(resolveLightbox => { |
| 1040 |
Promise.all(/*! import() | lightbox */[__webpack_require__.e("vendors-node_modules_dompurify_dist_purify_cjs_js"), __webpack_require__.e("lightbox")]).then(__webpack_require__.t.bind(__webpack_require__, /*! elementor-frontend/utils/lightbox/lightbox */ "../assets/dev/js/frontend/utils/lightbox/lightbox.js", 23)).then(({ |
| 1041 |
default: LightboxModule |
| 1042 |
}) => resolveLightbox(new LightboxModule())); |
| 1043 |
}), |
| 1044 |
dialogScriptPromise = elementorFrontend.utils.assetsLoader.load('script', 'dialog'), |
| 1045 |
dialogStylePromise = elementorFrontend.utils.assetsLoader.load('style', 'dialog'), |
| 1046 |
shareLinkPromise = elementorFrontend.utils.assetsLoader.load('script', 'share-link'), |
| 1047 |
swiperStylePromise = elementorFrontend.utils.assetsLoader.load('style', 'swiper'), |
| 1048 |
lightboxStylePromise = elementorFrontend.utils.assetsLoader.load('style', 'e-lightbox'); |
| 1049 |
return Promise.all([lightboxPromise, dialogScriptPromise, dialogStylePromise, shareLinkPromise, swiperStylePromise, lightboxStylePromise]).then(() => lightboxPromise); |
| 1050 |
} |
| 1051 |
getDefaultSettings() { |
| 1052 |
return { |
| 1053 |
selectors: { |
| 1054 |
links: 'a, [data-elementor-lightbox]', |
| 1055 |
slideshow: '[data-elementor-lightbox-slideshow]' |
| 1056 |
} |
| 1057 |
}; |
| 1058 |
} |
| 1059 |
getDefaultElements() { |
| 1060 |
return { |
| 1061 |
$links: jQuery(this.getSettings('selectors.links')), |
| 1062 |
$slideshow: jQuery(this.getSettings('selectors.slideshow')) |
| 1063 |
}; |
| 1064 |
} |
| 1065 |
isLightboxLink(element) { |
| 1066 |
// Check for lowercase `a` to make sure it works also for links inside SVGs. |
| 1067 |
if ('a' === element.tagName.toLowerCase() && (element.hasAttribute('download') || !/^[^?]+\.(png|jpe?g|gif|svg|webp|avif)(\?.*)?$/i.test(element.href)) && !element.dataset.elementorLightboxVideo) { |
| 1068 |
return false; |
| 1069 |
} |
| 1070 |
const generalOpenInLightbox = elementorFrontend.getKitSettings('global_image_lightbox'), |
| 1071 |
currentLinkOpenInLightbox = element.dataset.elementorOpenLightbox; |
| 1072 |
return 'yes' === currentLinkOpenInLightbox || generalOpenInLightbox && 'no' !== currentLinkOpenInLightbox; |
| 1073 |
} |
| 1074 |
isLightboxSlideshow() { |
| 1075 |
return 0 !== this.elements.$slideshow.length; |
| 1076 |
} |
| 1077 |
async onLinkClick(event) { |
| 1078 |
const element = event.currentTarget, |
| 1079 |
$target = jQuery(event.target), |
| 1080 |
editMode = elementorFrontend.isEditMode(), |
| 1081 |
isColorPickingMode = editMode && elementor.$previewContents.find('body').hasClass('elementor-editor__ui-state__color-picker'), |
| 1082 |
isClickInsideElementor = !!$target.closest('.elementor-edit-area').length; |
| 1083 |
if (!this.isLightboxLink(element)) { |
| 1084 |
if (editMode && isClickInsideElementor) { |
| 1085 |
event.preventDefault(); |
| 1086 |
} |
| 1087 |
return; |
| 1088 |
} |
| 1089 |
event.preventDefault(); |
| 1090 |
if (editMode && !elementor.getPreferences('lightbox_in_editor')) { |
| 1091 |
return; |
| 1092 |
} |
| 1093 |
|
| 1094 |
// Disable lightbox on color picking mode. |
| 1095 |
if (isColorPickingMode) { |
| 1096 |
return; |
| 1097 |
} |
| 1098 |
const lightbox = await LightboxManager.getLightbox(); |
| 1099 |
lightbox.createLightbox(element); |
| 1100 |
} |
| 1101 |
bindEvents() { |
| 1102 |
elementorFrontend.elements.$document.on('click', this.getSettings('selectors.links'), event => this.onLinkClick(event)); |
| 1103 |
} |
| 1104 |
onInit(...args) { |
| 1105 |
super.onInit(...args); |
| 1106 |
if (elementorFrontend.isEditMode()) { |
| 1107 |
return; |
| 1108 |
} |
| 1109 |
this.maybeActivateLightboxOnLink(); |
| 1110 |
} |
| 1111 |
maybeActivateLightboxOnLink() { |
| 1112 |
// Detecting lightbox links on init will reduce the time of waiting to the lightbox to be display on slow connections. |
| 1113 |
this.elements.$links.each((index, element) => { |
| 1114 |
if (this.isLightboxLink(element)) { |
| 1115 |
LightboxManager.getLightbox(); |
| 1116 |
|
| 1117 |
// Breaking the iteration when the library loading has already been triggered. |
| 1118 |
return false; |
| 1119 |
} |
| 1120 |
}); |
| 1121 |
} |
| 1122 |
} |
| 1123 |
exports["default"] = LightboxManager; |
| 1124 |
|
| 1125 |
/***/ }), |
| 1126 |
|
| 1127 |
/***/ "../assets/dev/js/frontend/utils/swiper.js": |
| 1128 |
/*!*************************************************!*\ |
| 1129 |
!*** ../assets/dev/js/frontend/utils/swiper.js ***! |
| 1130 |
\*************************************************/ |
| 1131 |
/***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 1132 |
|
| 1133 |
|
| 1134 |
|
| 1135 |
Object.defineProperty(exports, "__esModule", ({ |
| 1136 |
value: true |
| 1137 |
})); |
| 1138 |
exports["default"] = void 0; |
| 1139 |
__webpack_require__(/*! core-js/modules/esnext.iterator.constructor.js */ "../node_modules/core-js/modules/esnext.iterator.constructor.js"); |
| 1140 |
__webpack_require__(/*! core-js/modules/esnext.iterator.for-each.js */ "../node_modules/core-js/modules/esnext.iterator.for-each.js"); |
| 1141 |
class SwiperHandler { |
| 1142 |
constructor(container, config) { |
| 1143 |
this.config = config; |
| 1144 |
if (this.config.breakpoints) { |
| 1145 |
// The config is passed as a param to allow adjustConfig to be called outside of this wrapper |
| 1146 |
this.config = this.adjustConfig(config); |
| 1147 |
} |
| 1148 |
if (container instanceof jQuery) { |
| 1149 |
container = container[0]; |
| 1150 |
} |
| 1151 |
|
| 1152 |
// The Swiper will overlap the column width when applying custom margin values on the column. |
| 1153 |
container.closest('.elementor-widget-wrap')?.classList.add('e-swiper-container'); |
| 1154 |
container.closest('.elementor-widget')?.classList.add('e-widget-swiper'); |
| 1155 |
return new Promise(resolve => { |
| 1156 |
// TODO: Remove in v3.29.0 [ED-16272]. |
| 1157 |
if ('undefined' === typeof Swiper) { |
| 1158 |
elementorFrontend.utils.assetsLoader.load('script', 'swiper').then(() => resolve(this.createSwiperInstance(container, this.config))); |
| 1159 |
return; |
| 1160 |
} |
| 1161 |
if ('function' === typeof Swiper && 'undefined' === typeof window.Swiper) { |
| 1162 |
window.Swiper = Swiper; |
| 1163 |
} |
| 1164 |
resolve(this.createSwiperInstance(container, this.config)); |
| 1165 |
}); |
| 1166 |
} |
| 1167 |
createSwiperInstance(container, config) { |
| 1168 |
const SwiperSource = window.Swiper; |
| 1169 |
SwiperSource.prototype.adjustConfig = this.adjustConfig; |
| 1170 |
config = this.applyMotionPreferences(config); |
| 1171 |
return new SwiperSource(container, config); |
| 1172 |
} |
| 1173 |
|
| 1174 |
// Backwards compatibility for Elementor Pro <2.9.0 (old Swiper version - <5.0.0) |
| 1175 |
// In Swiper 5.0.0 and up, breakpoints changed from acting as max-width to acting as min-width |
| 1176 |
adjustConfig(config) { |
| 1177 |
// Only reverse the breakpoints if the handle param has been defined |
| 1178 |
if (!config.handleElementorBreakpoints) { |
| 1179 |
return config; |
| 1180 |
} |
| 1181 |
const elementorBreakpoints = elementorFrontend.config.responsive.activeBreakpoints, |
| 1182 |
elementorBreakpointValues = elementorFrontend.breakpoints.getBreakpointValues(); |
| 1183 |
Object.keys(config.breakpoints).forEach(configBPKey => { |
| 1184 |
const configBPKeyInt = parseInt(configBPKey); |
| 1185 |
let breakpointToUpdate; |
| 1186 |
|
| 1187 |
// The `configBPKeyInt + 1` is a BC Fix for Elementor Pro Carousels from 2.8.0-2.8.3 used with Elementor >= 2.9.0 |
| 1188 |
if (configBPKeyInt === elementorBreakpoints.mobile.value || configBPKeyInt + 1 === elementorBreakpoints.mobile.value) { |
| 1189 |
// This handles the mobile breakpoint. Elementor's default sm breakpoint is never actually used, |
| 1190 |
// so the mobile breakpoint (md) needs to be handled separately and set to the 0 breakpoint (xs) |
| 1191 |
breakpointToUpdate = 0; |
| 1192 |
} else if (elementorBreakpoints.widescreen && (configBPKeyInt === elementorBreakpoints.widescreen.value || configBPKeyInt + 1 === elementorBreakpoints.widescreen.value)) { |
| 1193 |
// Widescreen is a min-width breakpoint. Since in Swiper >5.0 the breakpoint system is min-width based, |
| 1194 |
// the value we pass to the Swiper instance in this case is the breakpoint from the user, unchanged. |
| 1195 |
breakpointToUpdate = configBPKeyInt; |
| 1196 |
} else { |
| 1197 |
// Find the index of the current config breakpoint in the Elementor Breakpoints array |
| 1198 |
const currentBPIndexInElementorBPs = elementorBreakpointValues.findIndex(elementorBP => { |
| 1199 |
// BC Fix for Elementor Pro Carousels from 2.8.0-2.8.3 used with Elementor >= 2.9.0 |
| 1200 |
return configBPKeyInt === elementorBP || configBPKeyInt + 1 === elementorBP; |
| 1201 |
}); |
| 1202 |
|
| 1203 |
// For all other Swiper config breakpoints, move them one breakpoint down on the breakpoint list, |
| 1204 |
// according to the array of Elementor's global breakpoints |
| 1205 |
breakpointToUpdate = elementorBreakpointValues[currentBPIndexInElementorBPs - 1]; |
| 1206 |
} |
| 1207 |
config.breakpoints[breakpointToUpdate] = config.breakpoints[configBPKey]; |
| 1208 |
|
| 1209 |
// Then reset the settings in the original breakpoint key to the default values |
| 1210 |
config.breakpoints[configBPKey] = { |
| 1211 |
slidesPerView: config.slidesPerView, |
| 1212 |
slidesPerGroup: config.slidesPerGroup ? config.slidesPerGroup : 1 |
| 1213 |
}; |
| 1214 |
}); |
| 1215 |
return config; |
| 1216 |
} |
| 1217 |
applyMotionPreferences(config) { |
| 1218 |
const prefersReducedMotion = window.matchMedia('(prefers-reduced-motion: reduce)').matches; |
| 1219 |
if (!prefersReducedMotion) { |
| 1220 |
return config; |
| 1221 |
} |
| 1222 |
return Object.assign({}, config, { |
| 1223 |
speed: 0, |
| 1224 |
autoplay: false |
| 1225 |
}); |
| 1226 |
} |
| 1227 |
} |
| 1228 |
exports["default"] = SwiperHandler; |
| 1229 |
|
| 1230 |
/***/ }), |
| 1231 |
|
| 1232 |
/***/ "../assets/dev/js/frontend/utils/url-actions.js": |
| 1233 |
/*!******************************************************!*\ |
| 1234 |
!*** ../assets/dev/js/frontend/utils/url-actions.js ***! |
| 1235 |
\******************************************************/ |
| 1236 |
/***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 1237 |
|
| 1238 |
|
| 1239 |
|
| 1240 |
Object.defineProperty(exports, "__esModule", ({ |
| 1241 |
value: true |
| 1242 |
})); |
| 1243 |
exports["default"] = void 0; |
| 1244 |
__webpack_require__(/*! core-js/modules/web.dom-exception.stack.js */ "../node_modules/core-js/modules/web.dom-exception.stack.js"); |
| 1245 |
class _default extends elementorModules.ViewModule { |
| 1246 |
getDefaultSettings() { |
| 1247 |
return { |
| 1248 |
selectors: { |
| 1249 |
links: 'a[href^="%23elementor-action"], a[href^="#elementor-action"]' |
| 1250 |
} |
| 1251 |
}; |
| 1252 |
} |
| 1253 |
bindEvents() { |
| 1254 |
elementorFrontend.elements.$document.on('click', this.getSettings('selectors.links'), this.runLinkAction.bind(this)); |
| 1255 |
} |
| 1256 |
initActions() { |
| 1257 |
this.actions = { |
| 1258 |
lightbox: async settings => { |
| 1259 |
const lightbox = await elementorFrontend.utils.lightbox; |
| 1260 |
if (settings.slideshow) { |
| 1261 |
// Handle slideshow display |
| 1262 |
lightbox.openSlideshow(settings.slideshow, settings.url); |
| 1263 |
} else { |
| 1264 |
// If the settings has an ID - the lightbox target content is an image - the ID is an attachment ID. |
| 1265 |
if (settings.id) { |
| 1266 |
settings.type = 'image'; |
| 1267 |
} |
| 1268 |
lightbox.showModal(settings); |
| 1269 |
} |
| 1270 |
} |
| 1271 |
}; |
| 1272 |
} |
| 1273 |
addAction(name, callback) { |
| 1274 |
this.actions[name] = callback; |
| 1275 |
} |
| 1276 |
runAction(url, ...restArgs) { |
| 1277 |
url = decodeURI(url); |
| 1278 |
url = decodeURIComponent(url); |
| 1279 |
const actionMatch = url.match(/action=(.+?)&/); |
| 1280 |
if (!actionMatch) { |
| 1281 |
return; |
| 1282 |
} |
| 1283 |
const action = this.actions[actionMatch[1]]; |
| 1284 |
if (!action) { |
| 1285 |
return; |
| 1286 |
} |
| 1287 |
let settings = {}; |
| 1288 |
const settingsMatch = url.match(/settings=(.+)/); |
| 1289 |
if (settingsMatch) { |
| 1290 |
settings = JSON.parse(atob(settingsMatch[1])); |
| 1291 |
} |
| 1292 |
settings.previousEvent = event; |
| 1293 |
action(settings, ...restArgs); |
| 1294 |
} |
| 1295 |
runLinkAction(event) { |
| 1296 |
event.preventDefault(); |
| 1297 |
this.runAction(jQuery(event.currentTarget).attr('href'), event); |
| 1298 |
} |
| 1299 |
runHashAction() { |
| 1300 |
if (!location.hash) { |
| 1301 |
return; |
| 1302 |
} |
| 1303 |
|
| 1304 |
// Only if an element with this action hash exists on the page do we allow running the action. |
| 1305 |
const elementWithHash = document.querySelector(`[data-e-action-hash="${location.hash}"], a[href*="${location.hash}"]`); |
| 1306 |
if (elementWithHash) { |
| 1307 |
this.runAction(elementWithHash.getAttribute('data-e-action-hash')); |
| 1308 |
} |
| 1309 |
} |
| 1310 |
createActionHash(action, settings) { |
| 1311 |
// We need to encode the hash tag (#) here, in order to support share links for a variety of providers |
| 1312 |
return encodeURIComponent(`#elementor-action:action=${action}&settings=${btoa(JSON.stringify(settings))}`); |
| 1313 |
} |
| 1314 |
onInit() { |
| 1315 |
super.onInit(); |
| 1316 |
this.initActions(); |
| 1317 |
elementorFrontend.on('components:init', this.runHashAction.bind(this)); |
| 1318 |
} |
| 1319 |
} |
| 1320 |
exports["default"] = _default; |
| 1321 |
|
| 1322 |
/***/ }), |
| 1323 |
|
| 1324 |
/***/ "../assets/dev/js/frontend/utils/utils.js": |
| 1325 |
/*!************************************************!*\ |
| 1326 |
!*** ../assets/dev/js/frontend/utils/utils.js ***! |
| 1327 |
\************************************************/ |
| 1328 |
/***/ ((__unused_webpack_module, exports) => { |
| 1329 |
|
| 1330 |
|
| 1331 |
|
| 1332 |
Object.defineProperty(exports, "__esModule", ({ |
| 1333 |
value: true |
| 1334 |
})); |
| 1335 |
exports.isScrollSnapActive = exports.escapeHTML = void 0; |
| 1336 |
// Escape HTML special chars to prevent XSS. |
| 1337 |
const escapeHTML = str => { |
| 1338 |
const specialChars = { |
| 1339 |
'&': '&', |
| 1340 |
'<': '<', |
| 1341 |
'>': '>', |
| 1342 |
"'": ''', |
| 1343 |
'"': '"' |
| 1344 |
}; |
| 1345 |
return str.replace(/[&<>'"]/g, tag => specialChars[tag] || tag); |
| 1346 |
}; |
| 1347 |
|
| 1348 |
// Check if Scroll-Snap is active. |
| 1349 |
exports.escapeHTML = escapeHTML; |
| 1350 |
const isScrollSnapActive = () => { |
| 1351 |
const scrollSnapStatus = elementorFrontend.isEditMode() ? elementor.settings.page.model.attributes?.scroll_snap : elementorFrontend.config.settings.page?.scroll_snap; |
| 1352 |
return 'yes' === scrollSnapStatus ? true : false; |
| 1353 |
}; |
| 1354 |
exports.isScrollSnapActive = isScrollSnapActive; |
| 1355 |
|
| 1356 |
/***/ }), |
| 1357 |
|
| 1358 |
/***/ "../assets/dev/js/frontend/utils/video-api/base-loader.js": |
| 1359 |
/*!****************************************************************!*\ |
| 1360 |
!*** ../assets/dev/js/frontend/utils/video-api/base-loader.js ***! |
| 1361 |
\****************************************************************/ |
| 1362 |
/***/ ((__unused_webpack_module, exports) => { |
| 1363 |
|
| 1364 |
|
| 1365 |
|
| 1366 |
Object.defineProperty(exports, "__esModule", ({ |
| 1367 |
value: true |
| 1368 |
})); |
| 1369 |
exports["default"] = void 0; |
| 1370 |
class BaseLoader extends elementorModules.ViewModule { |
| 1371 |
getDefaultSettings() { |
| 1372 |
return { |
| 1373 |
isInserted: false, |
| 1374 |
selectors: { |
| 1375 |
firstScript: 'script:first' |
| 1376 |
} |
| 1377 |
}; |
| 1378 |
} |
| 1379 |
getDefaultElements() { |
| 1380 |
return { |
| 1381 |
$firstScript: jQuery(this.getSettings('selectors.firstScript')) |
| 1382 |
}; |
| 1383 |
} |
| 1384 |
insertAPI() { |
| 1385 |
this.elements.$firstScript.before(jQuery('<script>', { |
| 1386 |
src: this.getApiURL() |
| 1387 |
})); |
| 1388 |
this.setSettings('isInserted', true); |
| 1389 |
} |
| 1390 |
getVideoIDFromURL(url) { |
| 1391 |
const videoIDParts = url.match(this.getURLRegex()); |
| 1392 |
return videoIDParts && videoIDParts[1]; |
| 1393 |
} |
| 1394 |
onApiReady(callback) { |
| 1395 |
if (!this.getSettings('isInserted')) { |
| 1396 |
this.insertAPI(); |
| 1397 |
} |
| 1398 |
if (this.isApiLoaded()) { |
| 1399 |
callback(this.getApiObject()); |
| 1400 |
} else { |
| 1401 |
// If not ready check again by timeout.. |
| 1402 |
setTimeout(() => { |
| 1403 |
this.onApiReady(callback); |
| 1404 |
}, 350); |
| 1405 |
} |
| 1406 |
} |
| 1407 |
getAutoplayURL(videoURL) { |
| 1408 |
return videoURL.replace('&autoplay=0', '') + '&autoplay=1'; |
| 1409 |
} |
| 1410 |
} |
| 1411 |
exports["default"] = BaseLoader; |
| 1412 |
|
| 1413 |
/***/ }), |
| 1414 |
|
| 1415 |
/***/ "../assets/dev/js/frontend/utils/video-api/vimeo-loader.js": |
| 1416 |
/*!*****************************************************************!*\ |
| 1417 |
!*** ../assets/dev/js/frontend/utils/video-api/vimeo-loader.js ***! |
| 1418 |
\*****************************************************************/ |
| 1419 |
/***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 1420 |
|
| 1421 |
|
| 1422 |
|
| 1423 |
var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ "../node_modules/@babel/runtime/helpers/interopRequireDefault.js"); |
| 1424 |
Object.defineProperty(exports, "__esModule", ({ |
| 1425 |
value: true |
| 1426 |
})); |
| 1427 |
exports["default"] = void 0; |
| 1428 |
var _baseLoader = _interopRequireDefault(__webpack_require__(/*! ./base-loader */ "../assets/dev/js/frontend/utils/video-api/base-loader.js")); |
| 1429 |
class VimeoLoader extends _baseLoader.default { |
| 1430 |
getApiURL() { |
| 1431 |
return 'https://player.vimeo.com/api/player.js'; |
| 1432 |
} |
| 1433 |
getURLRegex() { |
| 1434 |
return /^(?:https?:\/\/)?(?:www|player\.)?(?:vimeo\.com\/)?(?:video\/|external\/)?(\d+)([^.?&#"'>]?)/; |
| 1435 |
} |
| 1436 |
isApiLoaded() { |
| 1437 |
return window.Vimeo; |
| 1438 |
} |
| 1439 |
getApiObject() { |
| 1440 |
return Vimeo; |
| 1441 |
} |
| 1442 |
getAutoplayURL(videoURL) { |
| 1443 |
// Vimeo requires the '#t=' param to be last in the URL. |
| 1444 |
const timeMatch = videoURL.match(/#t=[^&]*/); |
| 1445 |
return videoURL.replace(timeMatch[0], '') + timeMatch; |
| 1446 |
} |
| 1447 |
} |
| 1448 |
exports["default"] = VimeoLoader; |
| 1449 |
|
| 1450 |
/***/ }), |
| 1451 |
|
| 1452 |
/***/ "../assets/dev/js/frontend/utils/video-api/youtube-loader.js": |
| 1453 |
/*!*******************************************************************!*\ |
| 1454 |
!*** ../assets/dev/js/frontend/utils/video-api/youtube-loader.js ***! |
| 1455 |
\*******************************************************************/ |
| 1456 |
/***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 1457 |
|
| 1458 |
|
| 1459 |
|
| 1460 |
var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ "../node_modules/@babel/runtime/helpers/interopRequireDefault.js"); |
| 1461 |
Object.defineProperty(exports, "__esModule", ({ |
| 1462 |
value: true |
| 1463 |
})); |
| 1464 |
exports["default"] = void 0; |
| 1465 |
var _baseLoader = _interopRequireDefault(__webpack_require__(/*! ./base-loader */ "../assets/dev/js/frontend/utils/video-api/base-loader.js")); |
| 1466 |
class YoutubeLoader extends _baseLoader.default { |
| 1467 |
getApiURL() { |
| 1468 |
return 'https://www.youtube.com/iframe_api'; |
| 1469 |
} |
| 1470 |
getURLRegex() { |
| 1471 |
return /^(?:https?:\/\/)?(?:www\.)?(?:m\.)?(?:youtu\.be\/|youtube\.com\/(?:(?:watch)?\?(?:.*&)?vi?=|(?:embed|v|vi|user|shorts)\/))([^?&"'>]+)/; |
| 1472 |
} |
| 1473 |
isApiLoaded() { |
| 1474 |
return window.YT && YT.loaded; |
| 1475 |
} |
| 1476 |
getApiObject() { |
| 1477 |
return YT; |
| 1478 |
} |
| 1479 |
} |
| 1480 |
exports["default"] = YoutubeLoader; |
| 1481 |
|
| 1482 |
/***/ }), |
| 1483 |
|
| 1484 |
/***/ "../assets/dev/js/public-path.js": |
| 1485 |
/*!***************************************!*\ |
| 1486 |
!*** ../assets/dev/js/public-path.js ***! |
| 1487 |
\***************************************/ |
| 1488 |
/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { |
| 1489 |
|
| 1490 |
|
| 1491 |
|
| 1492 |
/* eslint-disable camelcase */ |
| 1493 |
__webpack_require__.p = elementorFrontendConfig.urls.assets + 'js/'; |
| 1494 |
|
| 1495 |
/***/ }), |
| 1496 |
|
| 1497 |
/***/ "../assets/dev/js/utils/breakpoints.js": |
| 1498 |
/*!*********************************************!*\ |
| 1499 |
!*** ../assets/dev/js/utils/breakpoints.js ***! |
| 1500 |
\*********************************************/ |
| 1501 |
/***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 1502 |
|
| 1503 |
|
| 1504 |
|
| 1505 |
Object.defineProperty(exports, "__esModule", ({ |
| 1506 |
value: true |
| 1507 |
})); |
| 1508 |
exports["default"] = void 0; |
| 1509 |
__webpack_require__(/*! core-js/modules/es.array.push.js */ "../node_modules/core-js/modules/es.array.push.js"); |
| 1510 |
__webpack_require__(/*! core-js/modules/esnext.iterator.constructor.js */ "../node_modules/core-js/modules/esnext.iterator.constructor.js"); |
| 1511 |
__webpack_require__(/*! core-js/modules/esnext.iterator.for-each.js */ "../node_modules/core-js/modules/esnext.iterator.for-each.js"); |
| 1512 |
__webpack_require__(/*! core-js/modules/esnext.iterator.map.js */ "../node_modules/core-js/modules/esnext.iterator.map.js"); |
| 1513 |
/** |
| 1514 |
* Breakpoints |
| 1515 |
* |
| 1516 |
* This utility class contains helper functions relating to Elementor's breakpoints system. |
| 1517 |
* |
| 1518 |
* @since 3.4.0 |
| 1519 |
*/ |
| 1520 |
class Breakpoints extends elementorModules.Module { |
| 1521 |
constructor(responsiveConfig) { |
| 1522 |
super(); |
| 1523 |
|
| 1524 |
// The passed config is either `elementor.config.responsive` or `elementorFrontend.config.responsive` |
| 1525 |
this.responsiveConfig = responsiveConfig; |
| 1526 |
} |
| 1527 |
|
| 1528 |
/** |
| 1529 |
* Get Active Breakpoints List |
| 1530 |
* |
| 1531 |
* Returns a flat array containing the active breakpoints/devices. By default, it returns the li |
| 1532 |
* the list ordered from smallest to largest breakpoint. If `true` is passed as a parameter, it reverses the order. |
| 1533 |
* |
| 1534 |
* @since 3.4.0 |
| 1535 |
* |
| 1536 |
* @param {Object} args |
| 1537 |
*/ |
| 1538 |
getActiveBreakpointsList(args = {}) { |
| 1539 |
const defaultArgs = { |
| 1540 |
largeToSmall: false, |
| 1541 |
withDesktop: false |
| 1542 |
}; |
| 1543 |
args = { |
| 1544 |
...defaultArgs, |
| 1545 |
...args |
| 1546 |
}; |
| 1547 |
const breakpointKeys = Object.keys(this.responsiveConfig.activeBreakpoints); |
| 1548 |
if (args.withDesktop) { |
| 1549 |
// If there is an active 'widescreen' breakpoint, insert the artificial 'desktop' device below it. |
| 1550 |
const widescreenIndex = breakpointKeys.indexOf('widescreen'), |
| 1551 |
indexToInsertDesktopDevice = -1 === widescreenIndex ? breakpointKeys.length : breakpointKeys.length - 1; |
| 1552 |
breakpointKeys.splice(indexToInsertDesktopDevice, 0, 'desktop'); |
| 1553 |
} |
| 1554 |
if (args.largeToSmall) { |
| 1555 |
breakpointKeys.reverse(); |
| 1556 |
} |
| 1557 |
return breakpointKeys; |
| 1558 |
} |
| 1559 |
|
| 1560 |
/** |
| 1561 |
* Get Active Breakpoint Values |
| 1562 |
* |
| 1563 |
* Returns a flat array containing the list of active breakpoint values, from smallest to largest. |
| 1564 |
* |
| 1565 |
* @since 3.4.0 |
| 1566 |
*/ |
| 1567 |
getBreakpointValues() { |
| 1568 |
const { |
| 1569 |
activeBreakpoints |
| 1570 |
} = this.responsiveConfig, |
| 1571 |
breakpointValues = []; |
| 1572 |
Object.values(activeBreakpoints).forEach(breakpointConfig => { |
| 1573 |
breakpointValues.push(breakpointConfig.value); |
| 1574 |
}); |
| 1575 |
return breakpointValues; |
| 1576 |
} |
| 1577 |
|
| 1578 |
/** |
| 1579 |
* Get Desktop Previous Device Key |
| 1580 |
* |
| 1581 |
* Returns the key of the device directly under desktop (can be 'tablet', 'tablet_extra', 'laptop'). |
| 1582 |
* |
| 1583 |
* @since 3.4.0 |
| 1584 |
* |
| 1585 |
* @return {string} device key |
| 1586 |
*/ |
| 1587 |
getDesktopPreviousDeviceKey() { |
| 1588 |
let desktopPreviousDevice = ''; |
| 1589 |
const { |
| 1590 |
activeBreakpoints |
| 1591 |
} = this.responsiveConfig, |
| 1592 |
breakpointKeys = Object.keys(activeBreakpoints), |
| 1593 |
numOfDevices = breakpointKeys.length; |
| 1594 |
if ('min' === activeBreakpoints[breakpointKeys[numOfDevices - 1]].direction) { |
| 1595 |
// If the widescreen breakpoint is active, the device that's previous to desktop is the last one before |
| 1596 |
// widescreen. |
| 1597 |
desktopPreviousDevice = breakpointKeys[numOfDevices - 2]; |
| 1598 |
} else { |
| 1599 |
// If the widescreen breakpoint isn't active, we just take the last device returned by the config. |
| 1600 |
desktopPreviousDevice = breakpointKeys[numOfDevices - 1]; |
| 1601 |
} |
| 1602 |
return desktopPreviousDevice; |
| 1603 |
} |
| 1604 |
|
| 1605 |
/** |
| 1606 |
* Get Device Minimum Breakpoint |
| 1607 |
* |
| 1608 |
* Returns the minimum point in the device's display range. For each device, the minimum point of its display range |
| 1609 |
* is the max point of the device below it + 1px. For example, if the active devices are mobile, tablet, |
| 1610 |
* and desktop, and the mobile breakpoint is 767px, the minimum display point for tablet devices is 768px. |
| 1611 |
* |
| 1612 |
* @since 3.4.0 |
| 1613 |
* |
| 1614 |
* @return {number|*} minimum breakpoint |
| 1615 |
*/ |
| 1616 |
getDesktopMinPoint() { |
| 1617 |
const { |
| 1618 |
activeBreakpoints |
| 1619 |
} = this.responsiveConfig, |
| 1620 |
desktopPreviousDevice = this.getDesktopPreviousDeviceKey(); |
| 1621 |
return activeBreakpoints[desktopPreviousDevice].value + 1; |
| 1622 |
} |
| 1623 |
|
| 1624 |
/** |
| 1625 |
* Get Device Minimum Breakpoint |
| 1626 |
* |
| 1627 |
* Returns the minimum point in the device's display range. For each device, the minimum point of its display range |
| 1628 |
* is the max point of the device below it + 1px. For example, if the active devices are mobile, tablet, |
| 1629 |
* and desktop, and the mobile breakpoint is 767px, the minimum display point for tablet devices is 768px. |
| 1630 |
* |
| 1631 |
* @since 3.4.0 |
| 1632 |
* |
| 1633 |
* @param {string} device |
| 1634 |
* @return {number|*} minimum breakpoint |
| 1635 |
*/ |
| 1636 |
getDeviceMinBreakpoint(device) { |
| 1637 |
if ('desktop' === device) { |
| 1638 |
return this.getDesktopMinPoint(); |
| 1639 |
} |
| 1640 |
const { |
| 1641 |
activeBreakpoints |
| 1642 |
} = this.responsiveConfig, |
| 1643 |
breakpointNames = Object.keys(activeBreakpoints); |
| 1644 |
let minBreakpoint; |
| 1645 |
if (breakpointNames[0] === device) { |
| 1646 |
// For the lowest breakpoint, the min point is always 320. |
| 1647 |
minBreakpoint = 320; |
| 1648 |
} else if ('widescreen' === device) { |
| 1649 |
// Widescreen only has a minimum point. In this case, the breakpoint |
| 1650 |
// value in the Breakpoints config is itself the device min point. |
| 1651 |
if (activeBreakpoints[device]) { |
| 1652 |
minBreakpoint = activeBreakpoints[device].value; |
| 1653 |
} else { |
| 1654 |
// If the widescreen breakpoint does not exist in the active breakpoints config (for example, in the |
| 1655 |
// case this method runs as the breakpoint is being added), get the value from the full config. |
| 1656 |
minBreakpoint = this.responsiveConfig.breakpoints.widescreen; |
| 1657 |
} |
| 1658 |
} else { |
| 1659 |
const deviceNameIndex = breakpointNames.indexOf(device), |
| 1660 |
previousIndex = deviceNameIndex - 1; |
| 1661 |
minBreakpoint = activeBreakpoints[breakpointNames[previousIndex]].value + 1; |
| 1662 |
} |
| 1663 |
return minBreakpoint; |
| 1664 |
} |
| 1665 |
|
| 1666 |
/** |
| 1667 |
* Get Active Match Regex |
| 1668 |
* |
| 1669 |
* Returns a regular expression containing all active breakpoints prefixed with an underscore. |
| 1670 |
* |
| 1671 |
* @return {RegExp} Active Match Regex |
| 1672 |
*/ |
| 1673 |
getActiveMatchRegex() { |
| 1674 |
return new RegExp(this.getActiveBreakpointsList().map(device => '_' + device).join('|') + '$'); |
| 1675 |
} |
| 1676 |
} |
| 1677 |
exports["default"] = Breakpoints; |
| 1678 |
|
| 1679 |
/***/ }), |
| 1680 |
|
| 1681 |
/***/ "../assets/dev/js/utils/events.js": |
| 1682 |
/*!****************************************!*\ |
| 1683 |
!*** ../assets/dev/js/utils/events.js ***! |
| 1684 |
\****************************************/ |
| 1685 |
/***/ ((__unused_webpack_module, exports) => { |
| 1686 |
|
| 1687 |
|
| 1688 |
|
| 1689 |
Object.defineProperty(exports, "__esModule", ({ |
| 1690 |
value: true |
| 1691 |
})); |
| 1692 |
exports["default"] = exports.Events = void 0; |
| 1693 |
class Events { |
| 1694 |
/** |
| 1695 |
* Dispatch an Elementor event. |
| 1696 |
* |
| 1697 |
* Will dispatch both native event & jQuery event (as BC). |
| 1698 |
* By default, `bcEvent` is `null`. |
| 1699 |
* |
| 1700 |
* @param {Object} context - The context that will dispatch the event. |
| 1701 |
* @param {string} event - Event to dispatch. |
| 1702 |
* @param {*} data - Data to pass to the event, default to `null`. |
| 1703 |
* @param {string|null} bcEvent - BC event to dispatch, default to `null`. |
| 1704 |
* |
| 1705 |
* @return {void} |
| 1706 |
*/ |
| 1707 |
static dispatch(context, event, data = null, bcEvent = null) { |
| 1708 |
// Make sure to use the native context if it's a jQuery instance. |
| 1709 |
context = context instanceof jQuery ? context[0] : context; |
| 1710 |
|
| 1711 |
// Dispatch the BC event only if exists. |
| 1712 |
if (bcEvent) { |
| 1713 |
context.dispatchEvent(new CustomEvent(bcEvent, { |
| 1714 |
detail: data |
| 1715 |
})); |
| 1716 |
} |
| 1717 |
|
| 1718 |
// jQuery's `.on()` listens also to native custom events, so there is no need |
| 1719 |
// to dispatch also a jQuery event. |
| 1720 |
context.dispatchEvent(new CustomEvent(event, { |
| 1721 |
detail: data |
| 1722 |
})); |
| 1723 |
} |
| 1724 |
} |
| 1725 |
exports.Events = Events; |
| 1726 |
var _default = exports["default"] = Events; |
| 1727 |
|
| 1728 |
/***/ }), |
| 1729 |
|
| 1730 |
/***/ "../assets/dev/js/utils/hooks.js": |
| 1731 |
/*!***************************************!*\ |
| 1732 |
!*** ../assets/dev/js/utils/hooks.js ***! |
| 1733 |
\***************************************/ |
| 1734 |
/***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 1735 |
|
| 1736 |
|
| 1737 |
|
| 1738 |
/** |
| 1739 |
* Handles managing all events for whatever you plug it into. Priorities for hooks are based on lowest to highest in |
| 1740 |
* that, lowest priority hooks are fired first. |
| 1741 |
*/ |
| 1742 |
__webpack_require__(/*! core-js/modules/es.array.push.js */ "../node_modules/core-js/modules/es.array.push.js"); |
| 1743 |
var EventManager = function () { |
| 1744 |
var slice = Array.prototype.slice, |
| 1745 |
MethodsAvailable; |
| 1746 |
|
| 1747 |
/** |
| 1748 |
* Contains the hooks that get registered with this EventManager. The array for storage utilizes a "flat" |
| 1749 |
* object literal such that looking up the hook utilizes the native object literal hash. |
| 1750 |
*/ |
| 1751 |
var STORAGE = { |
| 1752 |
actions: {}, |
| 1753 |
filters: {} |
| 1754 |
}; |
| 1755 |
|
| 1756 |
/** |
| 1757 |
* Removes the specified hook by resetting the value of it. |
| 1758 |
* |
| 1759 |
* @param {string} type Type of hook, either 'actions' or 'filters' |
| 1760 |
* @param {Function} hook The hook (namespace.identifier) to remove |
| 1761 |
* @param {Function} callback |
| 1762 |
* @param {*} context |
| 1763 |
* @private |
| 1764 |
*/ |
| 1765 |
function _removeHook(type, hook, callback, context) { |
| 1766 |
var handlers, handler, i; |
| 1767 |
if (!STORAGE[type][hook]) { |
| 1768 |
return; |
| 1769 |
} |
| 1770 |
if (!callback) { |
| 1771 |
STORAGE[type][hook] = []; |
| 1772 |
} else { |
| 1773 |
handlers = STORAGE[type][hook]; |
| 1774 |
if (!context) { |
| 1775 |
for (i = handlers.length; i--;) { |
| 1776 |
if (handlers[i].callback === callback) { |
| 1777 |
handlers.splice(i, 1); |
| 1778 |
} |
| 1779 |
} |
| 1780 |
} else { |
| 1781 |
for (i = handlers.length; i--;) { |
| 1782 |
handler = handlers[i]; |
| 1783 |
if (handler.callback === callback && handler.context === context) { |
| 1784 |
handlers.splice(i, 1); |
| 1785 |
} |
| 1786 |
} |
| 1787 |
} |
| 1788 |
} |
| 1789 |
} |
| 1790 |
|
| 1791 |
/** |
| 1792 |
* Use an insert sort for keeping our hooks organized based on priority. This function is ridiculously faster |
| 1793 |
* than bubble sort, etc: http://jsperf.com/javascript-sort |
| 1794 |
* |
| 1795 |
* @param {Array<*>} hooks The custom array containing all of the appropriate hooks to perform an insert sort on. |
| 1796 |
* @private |
| 1797 |
*/ |
| 1798 |
function _hookInsertSort(hooks) { |
| 1799 |
var tmpHook, j, prevHook; |
| 1800 |
for (var i = 1, len = hooks.length; i < len; i++) { |
| 1801 |
tmpHook = hooks[i]; |
| 1802 |
j = i; |
| 1803 |
while ((prevHook = hooks[j - 1]) && prevHook.priority > tmpHook.priority) { |
| 1804 |
hooks[j] = hooks[j - 1]; |
| 1805 |
--j; |
| 1806 |
} |
| 1807 |
hooks[j] = tmpHook; |
| 1808 |
} |
| 1809 |
return hooks; |
| 1810 |
} |
| 1811 |
|
| 1812 |
/** |
| 1813 |
* Adds the hook to the appropriate storage container |
| 1814 |
* |
| 1815 |
* @param {string} type 'actions' or 'filters' |
| 1816 |
* @param {Array<*>} hook The hook (namespace.identifier) to add to our event manager |
| 1817 |
* @param {Function} callback The function that will be called when the hook is executed. |
| 1818 |
* @param {number} priority The priority of this hook. Must be an integer. |
| 1819 |
* @param {*} [context] A value to be used for this |
| 1820 |
* @private |
| 1821 |
*/ |
| 1822 |
function _addHook(type, hook, callback, priority, context) { |
| 1823 |
var hookObject = { |
| 1824 |
callback, |
| 1825 |
priority, |
| 1826 |
context |
| 1827 |
}; |
| 1828 |
|
| 1829 |
// Utilize 'prop itself' : http://jsperf.com/hasownproperty-vs-in-vs-undefined/19 |
| 1830 |
var hooks = STORAGE[type][hook]; |
| 1831 |
if (hooks) { |
| 1832 |
// TEMP FIX BUG |
| 1833 |
var hasSameCallback = false; |
| 1834 |
jQuery.each(hooks, function () { |
| 1835 |
if (this.callback === callback) { |
| 1836 |
hasSameCallback = true; |
| 1837 |
return false; |
| 1838 |
} |
| 1839 |
}); |
| 1840 |
if (hasSameCallback) { |
| 1841 |
return; |
| 1842 |
} |
| 1843 |
// END TEMP FIX BUG |
| 1844 |
|
| 1845 |
hooks.push(hookObject); |
| 1846 |
hooks = _hookInsertSort(hooks); |
| 1847 |
} else { |
| 1848 |
hooks = [hookObject]; |
| 1849 |
} |
| 1850 |
STORAGE[type][hook] = hooks; |
| 1851 |
} |
| 1852 |
|
| 1853 |
/** |
| 1854 |
* Runs the specified hook. If it is an action, the value is not modified but if it is a filter, it is. |
| 1855 |
* |
| 1856 |
* @param {string} type 'actions' or 'filters' |
| 1857 |
* @param {*} hook The hook ( namespace.identifier ) to be ran. |
| 1858 |
* @param {Array<*>} args Arguments to pass to the action/filter. If it's a filter, args is actually a single parameter. |
| 1859 |
* @private |
| 1860 |
*/ |
| 1861 |
function _runHook(type, hook, args) { |
| 1862 |
var handlers = STORAGE[type][hook], |
| 1863 |
i, |
| 1864 |
len; |
| 1865 |
if (!handlers) { |
| 1866 |
return 'filters' === type ? args[0] : false; |
| 1867 |
} |
| 1868 |
len = handlers.length; |
| 1869 |
if ('filters' === type) { |
| 1870 |
for (i = 0; i < len; i++) { |
| 1871 |
args[0] = handlers[i].callback.apply(handlers[i].context, args); |
| 1872 |
} |
| 1873 |
} else { |
| 1874 |
for (i = 0; i < len; i++) { |
| 1875 |
handlers[i].callback.apply(handlers[i].context, args); |
| 1876 |
} |
| 1877 |
} |
| 1878 |
return 'filters' === type ? args[0] : true; |
| 1879 |
} |
| 1880 |
|
| 1881 |
/** |
| 1882 |
* Adds an action to the event manager. |
| 1883 |
* |
| 1884 |
* @param {string} action Must contain namespace.identifier |
| 1885 |
* @param {Function} callback Must be a valid callback function before this action is added |
| 1886 |
* @param {number} [priority=10] Used to control when the function is executed in relation to other callbacks bound to the same hook |
| 1887 |
* @param {*} [context] Supply a value to be used for this |
| 1888 |
*/ |
| 1889 |
function addAction(action, callback, priority, context) { |
| 1890 |
if ('string' === typeof action && 'function' === typeof callback) { |
| 1891 |
priority = parseInt(priority || 10, 10); |
| 1892 |
_addHook('actions', action, callback, priority, context); |
| 1893 |
} |
| 1894 |
return MethodsAvailable; |
| 1895 |
} |
| 1896 |
|
| 1897 |
/** |
| 1898 |
* Performs an action if it exists. You can pass as many arguments as you want to this function; the only rule is |
| 1899 |
* that the first argument must always be the action. |
| 1900 |
*/ |
| 1901 |
function doAction(/* Action, arg1, arg2, ... */ |
| 1902 |
) { |
| 1903 |
var args = slice.call(arguments); |
| 1904 |
var action = args.shift(); |
| 1905 |
if ('string' === typeof action) { |
| 1906 |
_runHook('actions', action, args); |
| 1907 |
} |
| 1908 |
return MethodsAvailable; |
| 1909 |
} |
| 1910 |
|
| 1911 |
/** |
| 1912 |
* Removes the specified action if it contains a namespace.identifier & exists. |
| 1913 |
* |
| 1914 |
* @param {string} action The action to remove |
| 1915 |
* @param {Function} [callback] Callback function to remove |
| 1916 |
*/ |
| 1917 |
function removeAction(action, callback) { |
| 1918 |
if ('string' === typeof action) { |
| 1919 |
_removeHook('actions', action, callback); |
| 1920 |
} |
| 1921 |
return MethodsAvailable; |
| 1922 |
} |
| 1923 |
|
| 1924 |
/** |
| 1925 |
* Adds a filter to the event manager. |
| 1926 |
* |
| 1927 |
* @param {string} filter Must contain namespace.identifier |
| 1928 |
* @param {Function} callback Must be a valid callback function before this action is added |
| 1929 |
* @param {number} [priority=10] Used to control when the function is executed in relation to other callbacks bound to the same hook |
| 1930 |
* @param {*} [context] Supply a value to be used for this |
| 1931 |
*/ |
| 1932 |
function addFilter(filter, callback, priority, context) { |
| 1933 |
if ('string' === typeof filter && 'function' === typeof callback) { |
| 1934 |
priority = parseInt(priority || 10, 10); |
| 1935 |
_addHook('filters', filter, callback, priority, context); |
| 1936 |
} |
| 1937 |
return MethodsAvailable; |
| 1938 |
} |
| 1939 |
|
| 1940 |
/** |
| 1941 |
* Performs a filter if it exists. You should only ever pass 1 argument to be filtered. The only rule is that |
| 1942 |
* the first argument must always be the filter. |
| 1943 |
*/ |
| 1944 |
function applyFilters(/* Filter, filtered arg, arg2, ... */ |
| 1945 |
) { |
| 1946 |
var args = slice.call(arguments); |
| 1947 |
var filter = args.shift(); |
| 1948 |
if ('string' === typeof filter) { |
| 1949 |
return _runHook('filters', filter, args); |
| 1950 |
} |
| 1951 |
return MethodsAvailable; |
| 1952 |
} |
| 1953 |
|
| 1954 |
/** |
| 1955 |
* Removes the specified filter if it contains a namespace.identifier & exists. |
| 1956 |
* |
| 1957 |
* @param {string} filter The action to remove |
| 1958 |
* @param {Function} [callback] Callback function to remove |
| 1959 |
*/ |
| 1960 |
function removeFilter(filter, callback) { |
| 1961 |
if ('string' === typeof filter) { |
| 1962 |
_removeHook('filters', filter, callback); |
| 1963 |
} |
| 1964 |
return MethodsAvailable; |
| 1965 |
} |
| 1966 |
|
| 1967 |
/** |
| 1968 |
* Maintain a reference to the object scope so our public methods never get confusing. |
| 1969 |
*/ |
| 1970 |
MethodsAvailable = { |
| 1971 |
removeFilter, |
| 1972 |
applyFilters, |
| 1973 |
addFilter, |
| 1974 |
removeAction, |
| 1975 |
doAction, |
| 1976 |
addAction |
| 1977 |
}; |
| 1978 |
|
| 1979 |
// Return all of the publicly available methods |
| 1980 |
return MethodsAvailable; |
| 1981 |
}; |
| 1982 |
module.exports = EventManager; |
| 1983 |
|
| 1984 |
/***/ }), |
| 1985 |
|
| 1986 |
/***/ "../core/common/assets/js/utils/environment.js": |
| 1987 |
/*!*****************************************************!*\ |
| 1988 |
!*** ../core/common/assets/js/utils/environment.js ***! |
| 1989 |
\*****************************************************/ |
| 1990 |
/***/ ((__unused_webpack_module, exports) => { |
| 1991 |
|
| 1992 |
|
| 1993 |
|
| 1994 |
Object.defineProperty(exports, "__esModule", ({ |
| 1995 |
value: true |
| 1996 |
})); |
| 1997 |
exports["default"] = void 0; |
| 1998 |
const matchUserAgent = UserAgentStr => { |
| 1999 |
return userAgent.indexOf(UserAgentStr) >= 0; |
| 2000 |
}, |
| 2001 |
userAgent = navigator.userAgent, |
| 2002 |
// Solution influenced by https://stackoverflow.com/questions/9847580/how-to-detect-safari-chrome-ie-firefox-and-opera-browser |
| 2003 |
|
| 2004 |
// Opera 8.0+ |
| 2005 |
isOpera = !!window.opr && !!opr.addons || !!window.opera || matchUserAgent(' OPR/'), |
| 2006 |
// Firefox 1.0+ |
| 2007 |
isFirefox = matchUserAgent('Firefox'), |
| 2008 |
// Safari 3.0+ "[object HTMLElementConstructor]" |
| 2009 |
isSafari = /^((?!chrome|android).)*safari/i.test(userAgent) || /constructor/i.test(window.HTMLElement) || (p => { |
| 2010 |
return '[object SafariRemoteNotification]' === p.toString(); |
| 2011 |
})(!window.safari || typeof safari !== 'undefined' && safari.pushNotification), |
| 2012 |
// Internet Explorer 6-11 |
| 2013 |
isIE = /Trident|MSIE/.test(userAgent) && (/* @cc_on!@*/ false || !!document.documentMode), |
| 2014 |
// Edge 20+ |
| 2015 |
isEdge = !isIE && !!window.StyleMedia || matchUserAgent('Edg'), |
| 2016 |
// Google Chrome (Not accurate) |
| 2017 |
isChrome = !!window.chrome && matchUserAgent('Chrome') && !(isEdge || isOpera), |
| 2018 |
// Blink engine |
| 2019 |
isBlink = matchUserAgent('Chrome') && !!window.CSS, |
| 2020 |
// Apple Webkit engine |
| 2021 |
isAppleWebkit = matchUserAgent('AppleWebKit') && !isBlink, |
| 2022 |
isTouchDevice = 'ontouchstart' in window || navigator.maxTouchPoints > 0 || navigator.msMaxTouchPoints > 0, |
| 2023 |
environment = { |
| 2024 |
isTouchDevice, |
| 2025 |
appleWebkit: isAppleWebkit, |
| 2026 |
blink: isBlink, |
| 2027 |
chrome: isChrome, |
| 2028 |
edge: isEdge, |
| 2029 |
firefox: isFirefox, |
| 2030 |
ie: isIE, |
| 2031 |
mac: matchUserAgent('Macintosh'), |
| 2032 |
opera: isOpera, |
| 2033 |
safari: isSafari, |
| 2034 |
webkit: matchUserAgent('AppleWebKit') |
| 2035 |
}; |
| 2036 |
var _default = exports["default"] = environment; |
| 2037 |
|
| 2038 |
/***/ }), |
| 2039 |
|
| 2040 |
/***/ "../core/common/assets/js/utils/storage.js": |
| 2041 |
/*!*************************************************!*\ |
| 2042 |
!*** ../core/common/assets/js/utils/storage.js ***! |
| 2043 |
\*************************************************/ |
| 2044 |
/***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 2045 |
|
| 2046 |
|
| 2047 |
|
| 2048 |
Object.defineProperty(exports, "__esModule", ({ |
| 2049 |
value: true |
| 2050 |
})); |
| 2051 |
exports["default"] = void 0; |
| 2052 |
__webpack_require__(/*! core-js/modules/esnext.iterator.constructor.js */ "../node_modules/core-js/modules/esnext.iterator.constructor.js"); |
| 2053 |
__webpack_require__(/*! core-js/modules/esnext.iterator.for-each.js */ "../node_modules/core-js/modules/esnext.iterator.for-each.js"); |
| 2054 |
class _default extends elementorModules.Module { |
| 2055 |
get(key, options) { |
| 2056 |
options = options || {}; |
| 2057 |
let storage; |
| 2058 |
try { |
| 2059 |
storage = options.session ? sessionStorage : localStorage; |
| 2060 |
} catch (e) { |
| 2061 |
return key ? undefined : {}; |
| 2062 |
} |
| 2063 |
let elementorStorage = storage.getItem('elementor'); |
| 2064 |
if (elementorStorage) { |
| 2065 |
elementorStorage = JSON.parse(elementorStorage); |
| 2066 |
} else { |
| 2067 |
elementorStorage = {}; |
| 2068 |
} |
| 2069 |
if (!elementorStorage.__expiration) { |
| 2070 |
elementorStorage.__expiration = {}; |
| 2071 |
} |
| 2072 |
const expiration = elementorStorage.__expiration; |
| 2073 |
let expirationToCheck = []; |
| 2074 |
if (key) { |
| 2075 |
if (expiration[key]) { |
| 2076 |
expirationToCheck = [key]; |
| 2077 |
} |
| 2078 |
} else { |
| 2079 |
expirationToCheck = Object.keys(expiration); |
| 2080 |
} |
| 2081 |
let entryExpired = false; |
| 2082 |
expirationToCheck.forEach(expirationKey => { |
| 2083 |
if (new Date(expiration[expirationKey]) < new Date()) { |
| 2084 |
delete elementorStorage[expirationKey]; |
| 2085 |
delete expiration[expirationKey]; |
| 2086 |
entryExpired = true; |
| 2087 |
} |
| 2088 |
}); |
| 2089 |
if (entryExpired) { |
| 2090 |
this.save(elementorStorage, options.session); |
| 2091 |
} |
| 2092 |
if (key) { |
| 2093 |
return elementorStorage[key]; |
| 2094 |
} |
| 2095 |
return elementorStorage; |
| 2096 |
} |
| 2097 |
set(key, value, options) { |
| 2098 |
options = options || {}; |
| 2099 |
const elementorStorage = this.get(null, options); |
| 2100 |
elementorStorage[key] = value; |
| 2101 |
if (options.lifetimeInSeconds) { |
| 2102 |
const date = new Date(); |
| 2103 |
date.setTime(date.getTime() + options.lifetimeInSeconds * 1000); |
| 2104 |
elementorStorage.__expiration[key] = date.getTime(); |
| 2105 |
} |
| 2106 |
this.save(elementorStorage, options.session); |
| 2107 |
} |
| 2108 |
save(object, session) { |
| 2109 |
let storage; |
| 2110 |
try { |
| 2111 |
storage = session ? sessionStorage : localStorage; |
| 2112 |
} catch (e) { |
| 2113 |
return; |
| 2114 |
} |
| 2115 |
storage.setItem('elementor', JSON.stringify(object)); |
| 2116 |
} |
| 2117 |
} |
| 2118 |
exports["default"] = _default; |
| 2119 |
|
| 2120 |
/***/ }), |
| 2121 |
|
| 2122 |
/***/ "../modules/shapes/assets/js/frontend/frontend.js": |
| 2123 |
/*!********************************************************!*\ |
| 2124 |
!*** ../modules/shapes/assets/js/frontend/frontend.js ***! |
| 2125 |
\********************************************************/ |
| 2126 |
/***/ ((__unused_webpack_module, exports, __webpack_require__) => { |
| 2127 |
|
| 2128 |
|
| 2129 |
|
| 2130 |
Object.defineProperty(exports, "__esModule", ({ |
| 2131 |
value: true |
| 2132 |
})); |
| 2133 |
exports["default"] = void 0; |
| 2134 |
class _default extends elementorModules.Module { |
| 2135 |
constructor() { |
| 2136 |
super(); |
| 2137 |
elementorFrontend.elementsHandler.attachHandler('text-path', () => Promise.all(/*! import() | text-path */[__webpack_require__.e("vendors-node_modules_dompurify_dist_purify_cjs_js"), __webpack_require__.e("text-path")]).then(__webpack_require__.bind(__webpack_require__, /*! ./handlers/text-path */ "../modules/shapes/assets/js/frontend/handlers/text-path.js"))); |
| 2138 |
} |
| 2139 |
} |
| 2140 |
exports["default"] = _default; |
| 2141 |
|
| 2142 |
/***/ }), |
| 2143 |
|
| 2144 |
/***/ "../node_modules/core-js/internals/a-possible-prototype.js": |
| 2145 |
/*!*****************************************************************!*\ |
| 2146 |
!*** ../node_modules/core-js/internals/a-possible-prototype.js ***! |
| 2147 |
\*****************************************************************/ |
| 2148 |
/***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 2149 |
|
| 2150 |
|
| 2151 |
var isPossiblePrototype = __webpack_require__(/*! ../internals/is-possible-prototype */ "../node_modules/core-js/internals/is-possible-prototype.js"); |
| 2152 |
|
| 2153 |
var $String = String; |
| 2154 |
var $TypeError = TypeError; |
| 2155 |
|
| 2156 |
module.exports = function (argument) { |
| 2157 |
if (isPossiblePrototype(argument)) return argument; |
| 2158 |
throw new $TypeError("Can't set " + $String(argument) + ' as a prototype'); |
| 2159 |
}; |
| 2160 |
|
| 2161 |
|
| 2162 |
/***/ }), |
| 2163 |
|
| 2164 |
/***/ "../node_modules/core-js/internals/dom-exception-constants.js": |
| 2165 |
/*!********************************************************************!*\ |
| 2166 |
!*** ../node_modules/core-js/internals/dom-exception-constants.js ***! |
| 2167 |
\********************************************************************/ |
| 2168 |
/***/ ((module) => { |
| 2169 |
|
| 2170 |
|
| 2171 |
module.exports = { |
| 2172 |
IndexSizeError: { s: 'INDEX_SIZE_ERR', c: 1, m: 1 }, |
| 2173 |
DOMStringSizeError: { s: 'DOMSTRING_SIZE_ERR', c: 2, m: 0 }, |
| 2174 |
HierarchyRequestError: { s: 'HIERARCHY_REQUEST_ERR', c: 3, m: 1 }, |
| 2175 |
WrongDocumentError: { s: 'WRONG_DOCUMENT_ERR', c: 4, m: 1 }, |
| 2176 |
InvalidCharacterError: { s: 'INVALID_CHARACTER_ERR', c: 5, m: 1 }, |
| 2177 |
NoDataAllowedError: { s: 'NO_DATA_ALLOWED_ERR', c: 6, m: 0 }, |
| 2178 |
NoModificationAllowedError: { s: 'NO_MODIFICATION_ALLOWED_ERR', c: 7, m: 1 }, |
| 2179 |
NotFoundError: { s: 'NOT_FOUND_ERR', c: 8, m: 1 }, |
| 2180 |
NotSupportedError: { s: 'NOT_SUPPORTED_ERR', c: 9, m: 1 }, |
| 2181 |
InUseAttributeError: { s: 'INUSE_ATTRIBUTE_ERR', c: 10, m: 1 }, |
| 2182 |
InvalidStateError: { s: 'INVALID_STATE_ERR', c: 11, m: 1 }, |
| 2183 |
SyntaxError: { s: 'SYNTAX_ERR', c: 12, m: 1 }, |
| 2184 |
InvalidModificationError: { s: 'INVALID_MODIFICATION_ERR', c: 13, m: 1 }, |
| 2185 |
NamespaceError: { s: 'NAMESPACE_ERR', c: 14, m: 1 }, |
| 2186 |
InvalidAccessError: { s: 'INVALID_ACCESS_ERR', c: 15, m: 1 }, |
| 2187 |
ValidationError: { s: 'VALIDATION_ERR', c: 16, m: 0 }, |
| 2188 |
TypeMismatchError: { s: 'TYPE_MISMATCH_ERR', c: 17, m: 1 }, |
| 2189 |
SecurityError: { s: 'SECURITY_ERR', c: 18, m: 1 }, |
| 2190 |
NetworkError: { s: 'NETWORK_ERR', c: 19, m: 1 }, |
| 2191 |
AbortError: { s: 'ABORT_ERR', c: 20, m: 1 }, |
| 2192 |
URLMismatchError: { s: 'URL_MISMATCH_ERR', c: 21, m: 1 }, |
| 2193 |
QuotaExceededError: { s: 'QUOTA_EXCEEDED_ERR', c: 22, m: 1 }, |
| 2194 |
TimeoutError: { s: 'TIMEOUT_ERR', c: 23, m: 1 }, |
| 2195 |
InvalidNodeTypeError: { s: 'INVALID_NODE_TYPE_ERR', c: 24, m: 1 }, |
| 2196 |
DataCloneError: { s: 'DATA_CLONE_ERR', c: 25, m: 1 } |
| 2197 |
}; |
| 2198 |
|
| 2199 |
|
| 2200 |
/***/ }), |
| 2201 |
|
| 2202 |
/***/ "../node_modules/core-js/internals/error-stack-clear.js": |
| 2203 |
/*!**************************************************************!*\ |
| 2204 |
!*** ../node_modules/core-js/internals/error-stack-clear.js ***! |
| 2205 |
\**************************************************************/ |
| 2206 |
/***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 2207 |
|
| 2208 |
|
| 2209 |
var uncurryThis = __webpack_require__(/*! ../internals/function-uncurry-this */ "../node_modules/core-js/internals/function-uncurry-this.js"); |
| 2210 |
|
| 2211 |
var $Error = Error; |
| 2212 |
var replace = uncurryThis(''.replace); |
| 2213 |
|
| 2214 |
var TEST = (function (arg) { return String(new $Error(arg).stack); })('zxcasd'); |
| 2215 |
// eslint-disable-next-line redos/no-vulnerable, sonarjs/slow-regex -- safe |
| 2216 |
var V8_OR_CHAKRA_STACK_ENTRY = /\n\s*at [^:]*:[^\n]*/; |
| 2217 |
var IS_V8_OR_CHAKRA_STACK = V8_OR_CHAKRA_STACK_ENTRY.test(TEST); |
| 2218 |
|
| 2219 |
module.exports = function (stack, dropEntries) { |
| 2220 |
if (IS_V8_OR_CHAKRA_STACK && typeof stack == 'string' && !$Error.prepareStackTrace) { |
| 2221 |
while (dropEntries--) stack = replace(stack, V8_OR_CHAKRA_STACK_ENTRY, ''); |
| 2222 |
} return stack; |
| 2223 |
}; |
| 2224 |
|
| 2225 |
|
| 2226 |
/***/ }), |
| 2227 |
|
| 2228 |
/***/ "../node_modules/core-js/internals/function-uncurry-this-accessor.js": |
| 2229 |
/*!***************************************************************************!*\ |
| 2230 |
!*** ../node_modules/core-js/internals/function-uncurry-this-accessor.js ***! |
| 2231 |
\***************************************************************************/ |
| 2232 |
/***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 2233 |
|
| 2234 |
|
| 2235 |
var uncurryThis = __webpack_require__(/*! ../internals/function-uncurry-this */ "../node_modules/core-js/internals/function-uncurry-this.js"); |
| 2236 |
var aCallable = __webpack_require__(/*! ../internals/a-callable */ "../node_modules/core-js/internals/a-callable.js"); |
| 2237 |
|
| 2238 |
module.exports = function (object, key, method) { |
| 2239 |
try { |
| 2240 |
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe |
| 2241 |
return uncurryThis(aCallable(Object.getOwnPropertyDescriptor(object, key)[method])); |
| 2242 |
} catch (error) { /* empty */ } |
| 2243 |
}; |
| 2244 |
|
| 2245 |
|
| 2246 |
/***/ }), |
| 2247 |
|
| 2248 |
/***/ "../node_modules/core-js/internals/inherit-if-required.js": |
| 2249 |
/*!****************************************************************!*\ |
| 2250 |
!*** ../node_modules/core-js/internals/inherit-if-required.js ***! |
| 2251 |
\****************************************************************/ |
| 2252 |
/***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 2253 |
|
| 2254 |
|
| 2255 |
var isCallable = __webpack_require__(/*! ../internals/is-callable */ "../node_modules/core-js/internals/is-callable.js"); |
| 2256 |
var isObject = __webpack_require__(/*! ../internals/is-object */ "../node_modules/core-js/internals/is-object.js"); |
| 2257 |
var setPrototypeOf = __webpack_require__(/*! ../internals/object-set-prototype-of */ "../node_modules/core-js/internals/object-set-prototype-of.js"); |
| 2258 |
|
| 2259 |
// makes subclassing work correct for wrapped built-ins |
| 2260 |
module.exports = function ($this, dummy, Wrapper) { |
| 2261 |
var NewTarget, NewTargetPrototype; |
| 2262 |
if ( |
| 2263 |
// it can work only with native `setPrototypeOf` |
| 2264 |
setPrototypeOf && |
| 2265 |
// we haven't completely correct pre-ES6 way for getting `new.target`, so use this |
| 2266 |
isCallable(NewTarget = dummy.constructor) && |
| 2267 |
NewTarget !== Wrapper && |
| 2268 |
isObject(NewTargetPrototype = NewTarget.prototype) && |
| 2269 |
NewTargetPrototype !== Wrapper.prototype |
| 2270 |
) setPrototypeOf($this, NewTargetPrototype); |
| 2271 |
return $this; |
| 2272 |
}; |
| 2273 |
|
| 2274 |
|
| 2275 |
/***/ }), |
| 2276 |
|
| 2277 |
/***/ "../node_modules/core-js/internals/is-possible-prototype.js": |
| 2278 |
/*!******************************************************************!*\ |
| 2279 |
!*** ../node_modules/core-js/internals/is-possible-prototype.js ***! |
| 2280 |
\******************************************************************/ |
| 2281 |
/***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 2282 |
|
| 2283 |
|
| 2284 |
var isObject = __webpack_require__(/*! ../internals/is-object */ "../node_modules/core-js/internals/is-object.js"); |
| 2285 |
|
| 2286 |
module.exports = function (argument) { |
| 2287 |
return isObject(argument) || argument === null; |
| 2288 |
}; |
| 2289 |
|
| 2290 |
|
| 2291 |
/***/ }), |
| 2292 |
|
| 2293 |
/***/ "../node_modules/core-js/internals/normalize-string-argument.js": |
| 2294 |
/*!**********************************************************************!*\ |
| 2295 |
!*** ../node_modules/core-js/internals/normalize-string-argument.js ***! |
| 2296 |
\**********************************************************************/ |
| 2297 |
/***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 2298 |
|
| 2299 |
|
| 2300 |
var toString = __webpack_require__(/*! ../internals/to-string */ "../node_modules/core-js/internals/to-string.js"); |
| 2301 |
|
| 2302 |
module.exports = function (argument, $default) { |
| 2303 |
return argument === undefined ? arguments.length < 2 ? '' : $default : toString(argument); |
| 2304 |
}; |
| 2305 |
|
| 2306 |
|
| 2307 |
/***/ }), |
| 2308 |
|
| 2309 |
/***/ "../node_modules/core-js/internals/object-set-prototype-of.js": |
| 2310 |
/*!********************************************************************!*\ |
| 2311 |
!*** ../node_modules/core-js/internals/object-set-prototype-of.js ***! |
| 2312 |
\********************************************************************/ |
| 2313 |
/***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 2314 |
|
| 2315 |
|
| 2316 |
/* eslint-disable no-proto -- safe */ |
| 2317 |
var uncurryThisAccessor = __webpack_require__(/*! ../internals/function-uncurry-this-accessor */ "../node_modules/core-js/internals/function-uncurry-this-accessor.js"); |
| 2318 |
var isObject = __webpack_require__(/*! ../internals/is-object */ "../node_modules/core-js/internals/is-object.js"); |
| 2319 |
var requireObjectCoercible = __webpack_require__(/*! ../internals/require-object-coercible */ "../node_modules/core-js/internals/require-object-coercible.js"); |
| 2320 |
var aPossiblePrototype = __webpack_require__(/*! ../internals/a-possible-prototype */ "../node_modules/core-js/internals/a-possible-prototype.js"); |
| 2321 |
|
| 2322 |
// `Object.setPrototypeOf` method |
| 2323 |
// https://tc39.es/ecma262/#sec-object.setprototypeof |
| 2324 |
// Works with __proto__ only. Old v8 can't work with null proto objects. |
| 2325 |
// eslint-disable-next-line es/no-object-setprototypeof -- safe |
| 2326 |
module.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () { |
| 2327 |
var CORRECT_SETTER = false; |
| 2328 |
var test = {}; |
| 2329 |
var setter; |
| 2330 |
try { |
| 2331 |
setter = uncurryThisAccessor(Object.prototype, '__proto__', 'set'); |
| 2332 |
setter(test, []); |
| 2333 |
CORRECT_SETTER = test instanceof Array; |
| 2334 |
} catch (error) { /* empty */ } |
| 2335 |
return function setPrototypeOf(O, proto) { |
| 2336 |
requireObjectCoercible(O); |
| 2337 |
aPossiblePrototype(proto); |
| 2338 |
if (!isObject(O)) return O; |
| 2339 |
if (CORRECT_SETTER) setter(O, proto); |
| 2340 |
else O.__proto__ = proto; |
| 2341 |
return O; |
| 2342 |
}; |
| 2343 |
}() : undefined); |
| 2344 |
|
| 2345 |
|
| 2346 |
/***/ }), |
| 2347 |
|
| 2348 |
/***/ "../node_modules/core-js/internals/to-string.js": |
| 2349 |
/*!******************************************************!*\ |
| 2350 |
!*** ../node_modules/core-js/internals/to-string.js ***! |
| 2351 |
\******************************************************/ |
| 2352 |
/***/ ((module, __unused_webpack_exports, __webpack_require__) => { |
| 2353 |
|
| 2354 |
|
| 2355 |
var classof = __webpack_require__(/*! ../internals/classof */ "../node_modules/core-js/internals/classof.js"); |
| 2356 |
|
| 2357 |
var $String = String; |
| 2358 |
|
| 2359 |
module.exports = function (argument) { |
| 2360 |
if (classof(argument) === 'Symbol') throw new TypeError('Cannot convert a Symbol value to a string'); |
| 2361 |
return $String(argument); |
| 2362 |
}; |
| 2363 |
|
| 2364 |
|
| 2365 |
/***/ }), |
| 2366 |
|
| 2367 |
/***/ "../node_modules/core-js/modules/web.dom-exception.stack.js": |
| 2368 |
/*!******************************************************************!*\ |
| 2369 |
!*** ../node_modules/core-js/modules/web.dom-exception.stack.js ***! |
| 2370 |
\******************************************************************/ |
| 2371 |
/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => { |
| 2372 |
|
| 2373 |
|
| 2374 |
var $ = __webpack_require__(/*! ../internals/export */ "../node_modules/core-js/internals/export.js"); |
| 2375 |
var globalThis = __webpack_require__(/*! ../internals/global-this */ "../node_modules/core-js/internals/global-this.js"); |
| 2376 |
var getBuiltIn = __webpack_require__(/*! ../internals/get-built-in */ "../node_modules/core-js/internals/get-built-in.js"); |
| 2377 |
var createPropertyDescriptor = __webpack_require__(/*! ../internals/create-property-descriptor */ "../node_modules/core-js/internals/create-property-descriptor.js"); |
| 2378 |
var defineProperty = (__webpack_require__(/*! ../internals/object-define-property */ "../node_modules/core-js/internals/object-define-property.js").f); |
| 2379 |
var hasOwn = __webpack_require__(/*! ../internals/has-own-property */ "../node_modules/core-js/internals/has-own-property.js"); |
| 2380 |
var anInstance = __webpack_require__(/*! ../internals/an-instance */ "../node_modules/core-js/internals/an-instance.js"); |
| 2381 |
var inheritIfRequired = __webpack_require__(/*! ../internals/inherit-if-required */ "../node_modules/core-js/internals/inherit-if-required.js"); |
| 2382 |
var normalizeStringArgument = __webpack_require__(/*! ../internals/normalize-string-argument */ "../node_modules/core-js/internals/normalize-string-argument.js"); |
| 2383 |
var DOMExceptionConstants = __webpack_require__(/*! ../internals/dom-exception-constants */ "../node_modules/core-js/internals/dom-exception-constants.js"); |
| 2384 |
var clearErrorStack = __webpack_require__(/*! ../internals/error-stack-clear */ "../node_modules/core-js/internals/error-stack-clear.js"); |
| 2385 |
var DESCRIPTORS = __webpack_require__(/*! ../internals/descriptors */ "../node_modules/core-js/internals/descriptors.js"); |
| 2386 |
var IS_PURE = __webpack_require__(/*! ../internals/is-pure */ "../node_modules/core-js/internals/is-pure.js"); |
| 2387 |
|
| 2388 |
var DOM_EXCEPTION = 'DOMException'; |
| 2389 |
var Error = getBuiltIn('Error'); |
| 2390 |
var NativeDOMException = getBuiltIn(DOM_EXCEPTION); |
| 2391 |
|
| 2392 |
var $DOMException = function DOMException() { |
| 2393 |
anInstance(this, DOMExceptionPrototype); |
| 2394 |
var argumentsLength = arguments.length; |
| 2395 |
var message = normalizeStringArgument(argumentsLength < 1 ? undefined : arguments[0]); |
| 2396 |
var name = normalizeStringArgument(argumentsLength < 2 ? undefined : arguments[1], 'Error'); |
| 2397 |
var that = new NativeDOMException(message, name); |
| 2398 |
var error = new Error(message); |
| 2399 |
error.name = DOM_EXCEPTION; |
| 2400 |
defineProperty(that, 'stack', createPropertyDescriptor(1, clearErrorStack(error.stack, 1))); |
| 2401 |
inheritIfRequired(that, this, $DOMException); |
| 2402 |
return that; |
| 2403 |
}; |
| 2404 |
|
| 2405 |
var DOMExceptionPrototype = $DOMException.prototype = NativeDOMException.prototype; |
| 2406 |
|
| 2407 |
var ERROR_HAS_STACK = 'stack' in new Error(DOM_EXCEPTION); |
| 2408 |
var DOM_EXCEPTION_HAS_STACK = 'stack' in new NativeDOMException(1, 2); |
| 2409 |
|
| 2410 |
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe |
| 2411 |
var descriptor = NativeDOMException && DESCRIPTORS && Object.getOwnPropertyDescriptor(globalThis, DOM_EXCEPTION); |
| 2412 |
|
| 2413 |
// Bun ~ 0.1.1 DOMException have incorrect descriptor and we can't redefine it |
| 2414 |
// https://github.com/Jarred-Sumner/bun/issues/399 |
| 2415 |
var BUGGY_DESCRIPTOR = !!descriptor && !(descriptor.writable && descriptor.configurable); |
| 2416 |
|
| 2417 |
var FORCED_CONSTRUCTOR = ERROR_HAS_STACK && !BUGGY_DESCRIPTOR && !DOM_EXCEPTION_HAS_STACK; |
| 2418 |
|
| 2419 |
// `DOMException` constructor patch for `.stack` where it's required |
| 2420 |
// https://webidl.spec.whatwg.org/#es-DOMException-specialness |
| 2421 |
$({ global: true, constructor: true, forced: IS_PURE || FORCED_CONSTRUCTOR }, { // TODO: fix export logic |
| 2422 |
DOMException: FORCED_CONSTRUCTOR ? $DOMException : NativeDOMException |
| 2423 |
}); |
| 2424 |
|
| 2425 |
var PolyfilledDOMException = getBuiltIn(DOM_EXCEPTION); |
| 2426 |
var PolyfilledDOMExceptionPrototype = PolyfilledDOMException.prototype; |
| 2427 |
|
| 2428 |
if (PolyfilledDOMExceptionPrototype.constructor !== PolyfilledDOMException) { |
| 2429 |
if (!IS_PURE) { |
| 2430 |
defineProperty(PolyfilledDOMExceptionPrototype, 'constructor', createPropertyDescriptor(1, PolyfilledDOMException)); |
| 2431 |
} |
| 2432 |
|
| 2433 |
for (var key in DOMExceptionConstants) if (hasOwn(DOMExceptionConstants, key)) { |
| 2434 |
var constant = DOMExceptionConstants[key]; |
| 2435 |
var constantName = constant.s; |
| 2436 |
if (!hasOwn(PolyfilledDOMException, constantName)) { |
| 2437 |
defineProperty(PolyfilledDOMException, constantName, createPropertyDescriptor(6, constant.c)); |
| 2438 |
} |
| 2439 |
} |
| 2440 |
} |
| 2441 |
|
| 2442 |
|
| 2443 |
/***/ }) |
| 2444 |
|
| 2445 |
}, |
| 2446 |
/******/ __webpack_require__ => { // webpackRuntimeModules |
| 2447 |
/******/ var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId)) |
| 2448 |
/******/ __webpack_require__.O(0, ["frontend-modules"], () => (__webpack_exec__("../assets/dev/js/frontend/frontend.js"))); |
| 2449 |
/******/ var __webpack_exports__ = __webpack_require__.O(); |
| 2450 |
/******/ } |
| 2451 |
]); |
| 2452 |
//# sourceMappingURL=frontend.js.map |