', {
class: classes.swiperWrapper
}),
kenBurnsActive = elementSettings.background_slideshow_ken_burns;
let slideInnerClass = classes.slideBackground;
if (kenBurnsActive) {
slideInnerClass += ' ' + classes.kenBurns;
const kenBurnsDirection = 'in' === elementSettings.background_slideshow_ken_burns_zoom_direction ? 'kenBurnsIn' : 'kenBurnsOut';
slideInnerClass += ' ' + classes[kenBurnsDirection];
}
this.elements.$slides = jQuery();
elementSettings.background_slideshow_gallery.forEach(slide => {
const $slide = jQuery('
', {
class: classes.swiperSlide
}),
$slidebg = jQuery('
', {
class: slideInnerClass,
style: 'background-image: url("' + slide.url + '");'
});
$slide.append($slidebg);
$wrapper.append($slide);
this.elements.$slides = this.elements.$slides.add($slide);
});
$container.append($wrapper);
this.$element.prepend($container);
this.elements.$backgroundSlideShowContainer = $container;
}
async initSlider() {
if (1 >= this.getSlidesCount()) {
return;
}
const elementSettings = this.getElementSettings();
const Swiper = elementorFrontend.utils.swiper;
this.swiper = await new Swiper(this.elements.$backgroundSlideShowContainer, this.getSwiperOptions()); // Expose the swiper instance in the frontend
this.elements.$backgroundSlideShowContainer.data('swiper', this.swiper);
if (elementSettings.background_slideshow_ken_burns) {
this.handleKenBurns();
}
}
activate() {
this.buildSwiperElements();
this.initSlider();
}
deactivate() {
if (this.swiper) {
this.swiper.destroy();
this.elements.$backgroundSlideShowContainer.remove();
}
}
run() {
if ('slideshow' === this.getElementSettings('background_background')) {
this.activate();
} else {
this.deactivate();
}
}
onInit() {
super.onInit();
if (this.getElementSettings('background_slideshow_gallery')) {
this.run();
}
}
onDestroy() {
super.onDestroy();
this.deactivate();
}
onElementChange(propertyName) {
if ('background_background' === propertyName) {
this.run();
}
}
}
exports.default = BackgroundSlideshow;
/***/ }),
/***/ "../assets/dev/js/frontend/handlers/column.js":
/*!****************************************************!*\
!*** ../assets/dev/js/frontend/handlers/column.js ***!
\****************************************************/
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
"use strict";
var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ "../node_modules/@babel/runtime/helpers/interopRequireDefault.js");
Object.defineProperty(exports, "__esModule", ({
value: true
}));
exports.default = void 0;
var _backgroundSlideshow = _interopRequireDefault(__webpack_require__(/*! ./background-slideshow */ "../assets/dev/js/frontend/handlers/background-slideshow.js"));
var _default = [_backgroundSlideshow.default];
exports.default = _default;
/***/ }),
/***/ "../assets/dev/js/frontend/handlers/global.js":
/*!****************************************************!*\
!*** ../assets/dev/js/frontend/handlers/global.js ***!
\****************************************************/
/***/ ((__unused_webpack_module, exports) => {
"use strict";
Object.defineProperty(exports, "__esModule", ({
value: true
}));
exports.default = void 0;
class GlobalHandler extends elementorModules.frontend.handlers.Base {
getWidgetType() {
return 'global';
}
animate() {
const $element = this.$element,
animation = this.getAnimation();
if ('none' === animation) {
$element.removeClass('elementor-invisible');
return;
}
const elementSettings = this.getElementSettings(),
animationDelay = elementSettings._animation_delay || elementSettings.animation_delay || 0;
$element.removeClass(animation);
if (this.currentAnimation) {
$element.removeClass(this.currentAnimation);
}
this.currentAnimation = animation;
setTimeout(() => {
$element.removeClass('elementor-invisible').addClass('animated ' + animation);
}, animationDelay);
}
getAnimation() {
return this.getCurrentDeviceSetting('animation') || this.getCurrentDeviceSetting('_animation');
}
onInit(...args) {
super.onInit(...args);
if (this.getAnimation()) {
const observer = elementorModules.utils.Scroll.scrollObserver({
callback: event => {
if (event.isInViewport) {
this.animate();
observer.unobserve(this.$element[0]);
}
}
});
observer.observe(this.$element[0]);
}
}
onElementChange(propertyName) {
if (/^_?animation/.test(propertyName)) {
this.animate();
}
}
}
var _default = $scope => {
elementorFrontend.elementsHandler.addHandler(GlobalHandler, {
$element: $scope
});
};
exports.default = _default;
/***/ }),
/***/ "../assets/dev/js/frontend/handlers/section/background-video.js":
/*!**********************************************************************!*\
!*** ../assets/dev/js/frontend/handlers/section/background-video.js ***!
\**********************************************************************/
/***/ ((__unused_webpack_module, exports) => {
"use strict";
Object.defineProperty(exports, "__esModule", ({
value: true
}));
exports.default = void 0;
class BackgroundVideo extends elementorModules.frontend.handlers.Base {
getDefaultSettings() {
return {
selectors: {
backgroundVideoContainer: '.elementor-background-video-container',
backgroundVideoEmbed: '.elementor-background-video-embed',
backgroundVideoHosted: '.elementor-background-video-hosted'
}
};
}
getDefaultElements() {
const selectors = this.getSettings('selectors'),
elements = {
$backgroundVideoContainer: this.$element.find(selectors.backgroundVideoContainer)
};
elements.$backgroundVideoEmbed = elements.$backgroundVideoContainer.children(selectors.backgroundVideoEmbed);
elements.$backgroundVideoHosted = elements.$backgroundVideoContainer.children(selectors.backgroundVideoHosted);
return elements;
}
calcVideosSize($video) {
let aspectRatioSetting = '16:9';
if ('vimeo' === this.videoType) {
aspectRatioSetting = $video[0].width + ':' + $video[0].height;
}
const containerWidth = this.elements.$backgroundVideoContainer.outerWidth(),
containerHeight = this.elements.$backgroundVideoContainer.outerHeight(),
aspectRatioArray = aspectRatioSetting.split(':'),
aspectRatio = aspectRatioArray[0] / aspectRatioArray[1],
ratioWidth = containerWidth / aspectRatio,
ratioHeight = containerHeight * aspectRatio,
isWidthFixed = containerWidth / containerHeight > aspectRatio;
return {
width: isWidthFixed ? containerWidth : ratioHeight,
height: isWidthFixed ? ratioWidth : containerHeight
};
}
changeVideoSize() {
if (!('hosted' === this.videoType) && !this.player) {
return;
}
let $video;
if ('youtube' === this.videoType) {
$video = jQuery(this.player.getIframe());
} else if ('vimeo' === this.videoType) {
$video = jQuery(this.player.element);
} else if ('hosted' === this.videoType) {
$video = this.elements.$backgroundVideoHosted;
}
if (!$video) {
return;
}
const size = this.calcVideosSize($video);
$video.width(size.width).height(size.height);
}
startVideoLoop(firstTime) {
// If the section has been removed
if (!this.player.getIframe().contentWindow) {
return;
}
const elementSettings = this.getElementSettings(),
startPoint = elementSettings.background_video_start || 0,
endPoint = elementSettings.background_video_end;
if (elementSettings.background_play_once && !firstTime) {
this.player.stopVideo();
return;
}
this.player.seekTo(startPoint);
if (endPoint) {
const durationToEnd = endPoint - startPoint + 1;
setTimeout(() => {
this.startVideoLoop(false);
}, durationToEnd * 1000);
}
}
prepareVimeoVideo(Vimeo, videoId) {
const elementSettings = this.getElementSettings(),
startTime = elementSettings.background_video_start ? elementSettings.background_video_start : 0,
videoSize = this.elements.$backgroundVideoContainer.outerWidth(),
vimeoOptions = {
id: videoId,
width: videoSize.width,
autoplay: true,
loop: !elementSettings.background_play_once,
transparent: false,
background: true,
muted: true
};
this.player = new Vimeo.Player(this.elements.$backgroundVideoContainer, vimeoOptions); // Handle user-defined start/end times
this.handleVimeoStartEndTimes(elementSettings);
this.player.ready().then(() => {
jQuery(this.player.element).addClass('elementor-background-video-embed');
this.changeVideoSize();
});
}
handleVimeoStartEndTimes(elementSettings) {
// If a start time is defined, set the start time
if (elementSettings.background_video_start) {
this.player.on('play', data => {
if (0 === data.seconds) {
this.player.setCurrentTime(elementSettings.background_video_start);
}
});
}
this.player.on('timeupdate', data => {
// If an end time is defined, handle ending the video
if (elementSettings.background_video_end && elementSettings.background_video_end < data.seconds) {
if (elementSettings.background_play_once) {
// Stop at user-defined end time if not loop
this.player.pause();
} else {
// Go to start time if loop
this.player.setCurrentTime(elementSettings.background_video_start);
}
} // If start time is defined but an end time is not, go to user-defined start time at video end.
// Vimeo JS API has an 'ended' event, but it never fires when infinite loop is defined, so we
// get the video duration (returns a promise) then use duration-0.5s as end time
this.player.getDuration().then(duration => {
if (elementSettings.background_video_start && !elementSettings.background_video_end && data.seconds > duration - 0.5) {
this.player.setCurrentTime(elementSettings.background_video_start);
}
});
});
}
prepareYTVideo(YT, videoID) {
const $backgroundVideoContainer = this.elements.$backgroundVideoContainer,
elementSettings = this.getElementSettings();
let startStateCode = YT.PlayerState.PLAYING; // Since version 67, Chrome doesn't fire the `PLAYING` state at start time
if (window.chrome) {
startStateCode = YT.PlayerState.UNSTARTED;
}
const playerOptions = {
videoId: videoID,
events: {
onReady: () => {
this.player.mute();
this.changeVideoSize();
this.startVideoLoop(true);
this.player.playVideo();
},
onStateChange: event => {
switch (event.data) {
case startStateCode:
$backgroundVideoContainer.removeClass('elementor-invisible elementor-loading');
break;
case YT.PlayerState.ENDED:
this.player.seekTo(elementSettings.background_video_start || 0);
if (elementSettings.background_play_once) {
this.player.destroy();
}
}
}
},
playerVars: {
controls: 0,
rel: 0,
playsinline: 1
}
}; // To handle CORS issues, when the default host is changed, the origin parameter has to be set.
if (elementSettings.background_privacy_mode) {
playerOptions.host = 'https://www.youtube-nocookie.com';
playerOptions.origin = window.location.hostname;
}
$backgroundVideoContainer.addClass('elementor-loading elementor-invisible');
this.player = new YT.Player(this.elements.$backgroundVideoEmbed[0], playerOptions);
}
activate() {
let videoLink = this.getElementSettings('background_video_link'),
videoID;
const playOnce = this.getElementSettings('background_play_once');
if (-1 !== videoLink.indexOf('vimeo.com')) {
this.videoType = 'vimeo';
this.apiProvider = elementorFrontend.utils.vimeo;
} else if (videoLink.match(/^(?:https?:\/\/)?(?:www\.)?(?:m\.)?(?:youtu\.be\/|youtube\.com)/)) {
this.videoType = 'youtube';
this.apiProvider = elementorFrontend.utils.youtube;
}
if (this.apiProvider) {
videoID = this.apiProvider.getVideoIDFromURL(videoLink);
this.apiProvider.onApiReady(apiObject => {
if ('youtube' === this.videoType) {
this.prepareYTVideo(apiObject, videoID);
}
if ('vimeo' === this.videoType) {
this.prepareVimeoVideo(apiObject, videoID);
}
});
} else {
this.videoType = 'hosted';
const startTime = this.getElementSettings('background_video_start'),
endTime = this.getElementSettings('background_video_end');
if (startTime || endTime) {
videoLink += '#t=' + (startTime || 0) + (endTime ? ',' + endTime : '');
}
this.elements.$backgroundVideoHosted.attr('src', videoLink).one('canplay', this.changeVideoSize.bind(this));
if (playOnce) {
this.elements.$backgroundVideoHosted.on('ended', () => {
this.elements.$backgroundVideoHosted.hide();
});
}
}
elementorFrontend.elements.$window.on('resize', this.changeVideoSize);
}
deactivate() {
if ('youtube' === this.videoType && this.player.getIframe() || 'vimeo' === this.videoType) {
this.player.destroy();
} else {
this.elements.$backgroundVideoHosted.removeAttr('src').off('ended');
}
elementorFrontend.elements.$window.off('resize', this.changeVideoSize);
}
run() {
const elementSettings = this.getElementSettings();
if (!elementSettings.background_play_on_mobile && 'mobile' === elementorFrontend.getCurrentDeviceMode()) {
return;
}
if ('video' === elementSettings.background_background && elementSettings.background_video_link) {
this.activate();
} else {
this.deactivate();
}
}
onInit(...args) {
super.onInit(...args);
this.changeVideoSize = this.changeVideoSize.bind(this);
this.run();
}
onElementChange(propertyName) {
if ('background_background' === propertyName) {
this.run();
}
}
}
exports.default = BackgroundVideo;
/***/ }),
/***/ "../assets/dev/js/frontend/handlers/section/handles-position.js":
/*!**********************************************************************!*\
!*** ../assets/dev/js/frontend/handlers/section/handles-position.js ***!
\**********************************************************************/
/***/ ((__unused_webpack_module, exports) => {
"use strict";
Object.defineProperty(exports, "__esModule", ({
value: true
}));
exports.default = void 0;
class HandlesPosition extends elementorModules.frontend.handlers.Base {
isActive() {
return elementorFrontend.isEditMode();
}
isFirstSection() {
return this.$element[0] === document.querySelector('.elementor-edit-mode .elementor-top-section');
}
isOverflowHidden() {
return 'hidden' === this.$element.css('overflow');
}
getOffset() {
if ('body' === elementor.config.document.container) {
return this.$element.offset().top;
}
const $container = jQuery(elementor.config.document.container);
return this.$element.offset().top - $container.offset().top;
}
setHandlesPosition() {
const document = elementor.documents.getCurrent();
if (!document || !document.container.isEditable()) {
return;
}
const isOverflowHidden = this.isOverflowHidden();
if (!isOverflowHidden && !this.isFirstSection()) {
return;
}
const offset = isOverflowHidden ? 0 : this.getOffset(),
$handlesElement = this.$element.find('> .elementor-element-overlay > .elementor-editor-section-settings'),
insideHandleClass = 'elementor-section--handles-inside';
if (offset < 25) {
this.$element.addClass(insideHandleClass);
if (offset < -5) {
$handlesElement.css('top', -offset);
} else {
$handlesElement.css('top', '');
}
} else {
this.$element.removeClass(insideHandleClass);
}
}
onInit() {
if (!this.isActive()) {
return;
}
this.setHandlesPosition();
this.$element.on('mouseenter', this.setHandlesPosition.bind(this));
}
}
exports.default = HandlesPosition;
/***/ }),
/***/ "../assets/dev/js/frontend/handlers/section/section.js":
/*!*************************************************************!*\
!*** ../assets/dev/js/frontend/handlers/section/section.js ***!
\*************************************************************/
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
"use strict";
var _interopRequireDefault = __webpack_require__(/*! @babel/runtime/helpers/interopRequireDefault */ "../node_modules/@babel/runtime/helpers/interopRequireDefault.js");
Object.defineProperty(exports, "__esModule", ({
value: true
}));
exports.default = void 0;
var _backgroundSlideshow = _interopRequireDefault(__webpack_require__(/*! ../background-slideshow */ "../assets/dev/js/frontend/handlers/background-slideshow.js"));
var _backgroundVideo = _interopRequireDefault(__webpack_require__(/*! ./background-video */ "../assets/dev/js/frontend/handlers/section/background-video.js"));
var _handlesPosition = _interopRequireDefault(__webpack_require__(/*! ./handles-position */ "../assets/dev/js/frontend/handlers/section/handles-position.js"));
var _stretchedSection = _interopRequireDefault(__webpack_require__(/*! ./stretched-section */ "../assets/dev/js/frontend/handlers/section/stretched-section.js"));
var _shapes = _interopRequireDefault(__webpack_require__(/*! ./shapes */ "../assets/dev/js/frontend/handlers/section/shapes.js"));
var _default = [_stretchedSection.default, // Must run before BackgroundSlideshow to init the slideshow only after the stretch.
_backgroundSlideshow.default, _backgroundVideo.default, _handlesPosition.default, _shapes.default];
exports.default = _default;
/***/ }),
/***/ "../assets/dev/js/frontend/handlers/section/shapes.js":
/*!************************************************************!*\
!*** ../assets/dev/js/frontend/handlers/section/shapes.js ***!
\************************************************************/
/***/ ((__unused_webpack_module, exports) => {
"use strict";
Object.defineProperty(exports, "__esModule", ({
value: true
}));
exports.default = void 0;
class Shapes extends elementorModules.frontend.handlers.Base {
getDefaultSettings() {
return {
selectors: {
container: '> .elementor-shape-%s'
},
svgURL: elementorFrontend.config.urls.assets + 'shapes/'
};
}
getDefaultElements() {
const elements = {},
selectors = this.getSettings('selectors');
elements.$topContainer = this.$element.find(selectors.container.replace('%s', 'top'));
elements.$bottomContainer = this.$element.find(selectors.container.replace('%s', 'bottom'));
return elements;
}
isActive() {
return elementorFrontend.isEditMode();
}
getSvgURL(shapeType, fileName) {
let svgURL = this.getSettings('svgURL') + fileName + '.svg';
if (elementor.config.additional_shapes && shapeType in elementor.config.additional_shapes) {
svgURL = elementor.config.additional_shapes[shapeType];
if (-1 < fileName.indexOf('-negative')) {
svgURL = svgURL.replace('.svg', '-negative.svg');
}
}
return svgURL;
}
buildSVG(side) {
const baseSettingKey = 'shape_divider_' + side,
shapeType = this.getElementSettings(baseSettingKey),
$svgContainer = this.elements['$' + side + 'Container'];
$svgContainer.attr('data-shape', shapeType);
if (!shapeType) {
$svgContainer.empty(); // Shape-divider set to 'none'
return;
}
let fileName = shapeType;
if (this.getElementSettings(baseSettingKey + '_negative')) {
fileName += '-negative';
}
const svgURL = this.getSvgURL(shapeType, fileName);
jQuery.get(svgURL, data => {
$svgContainer.empty().append(data.childNodes[0]);
});
this.setNegative(side);
}
setNegative(side) {
this.elements['$' + side + 'Container'].attr('data-negative', !!this.getElementSettings('shape_divider_' + side + '_negative'));
}
onInit(...args) {
if (!this.isActive(this.getSettings())) {
return;
}
super.onInit(...args);
['top', 'bottom'].forEach(side => {
if (this.getElementSettings('shape_divider_' + side)) {
this.buildSVG(side);
}
});
}
onElementChange(propertyName) {
const shapeChange = propertyName.match(/^shape_divider_(top|bottom)$/);
if (shapeChange) {
this.buildSVG(shapeChange[1]);
return;
}
const negativeChange = propertyName.match(/^shape_divider_(top|bottom)_negative$/);
if (negativeChange) {
this.buildSVG(negativeChange[1]);
this.setNegative(negativeChange[1]);
}
}
}
exports.default = Shapes;
/***/ }),
/***/ "../assets/dev/js/frontend/handlers/section/stretched-section.js":
/*!***********************************************************************!*\
!*** ../assets/dev/js/frontend/handlers/section/stretched-section.js ***!
\***********************************************************************/
/***/ ((__unused_webpack_module, exports) => {
"use strict";
Object.defineProperty(exports, "__esModule", ({
value: true
}));
exports.default = void 0;
class StretchedSection extends elementorModules.frontend.handlers.Base {
bindEvents() {
const handlerID = this.getUniqueHandlerID();
elementorFrontend.addListenerOnce(handlerID, 'resize', this.stretch);
elementorFrontend.addListenerOnce(handlerID, 'sticky:stick', this.stretch, this.$element);
elementorFrontend.addListenerOnce(handlerID, 'sticky:unstick', this.stretch, this.$element);
if (elementorFrontend.isEditMode()) {
this.onKitChangeStretchContainerChange = this.onKitChangeStretchContainerChange.bind(this);
elementor.channels.editor.on('kit:change:stretchContainer', this.onKitChangeStretchContainerChange);
}
}
unbindEvents() {
elementorFrontend.removeListeners(this.getUniqueHandlerID(), 'resize', this.stretch);
if (elementorFrontend.isEditMode()) {
elementor.channels.editor.off('kit:change:stretchContainer', this.onKitChangeStretchContainerChange);
}
}
isActive(settings) {
return elementorFrontend.isEditMode() || settings.$element.hasClass('elementor-section-stretched');
}
initStretch() {
this.stretch = this.stretch.bind(this);
this.stretchElement = new elementorModules.frontend.tools.StretchElement({
element: this.$element,
selectors: {
container: this.getStretchContainer()
}
});
}
getStretchContainer() {
return elementorFrontend.getKitSettings('stretched_section_container') || window;
}
stretch() {
if (!this.getElementSettings('stretch_section')) {
return;
}
this.stretchElement.stretch();
}
onInit(...args) {
if (!this.isActive(this.getSettings())) {
return;
}
this.initStretch();
super.onInit(...args);
this.stretch();
}
onElementChange(propertyName) {
if ('stretch_section' === propertyName) {
if (this.getElementSettings('stretch_section')) {
this.stretch();
} else {
this.stretchElement.reset();
}
}
}
onKitChangeStretchContainerChange() {
this.stretchElement.setSettings('selectors.container', this.getStretchContainer());
this.stretch();
}
}
exports.default = StretchedSection;
/***/ }),
/***/ "../assets/dev/js/frontend/utils/anchors.js":
/*!**************************************************!*\
!*** ../assets/dev/js/frontend/utils/anchors.js ***!
\**************************************************/
/***/ ((module) => {
"use strict";
module.exports = elementorModules.ViewModule.extend({
getDefaultSettings: function () {
return {
scrollDuration: 500,
selectors: {
links: 'a[href*="#"]',
targets: '.elementor-element, .elementor-menu-anchor',
scrollable: 'html, body'
}
};
},
getDefaultElements: function () {
var $ = jQuery,
selectors = this.getSettings('selectors');
return {
$scrollable: $(selectors.scrollable)
};
},
bindEvents: function () {
elementorFrontend.elements.$document.on('click', this.getSettings('selectors.links'), this.handleAnchorLinks);
},
handleAnchorLinks: function (event) {
var clickedLink = event.currentTarget,
isSamePathname = location.pathname === clickedLink.pathname,
isSameHostname = location.hostname === clickedLink.hostname,
$anchor;
if (!isSameHostname || !isSamePathname || clickedLink.hash.length < 2) {
return;
}
try {
$anchor = jQuery(clickedLink.hash).filter(this.getSettings('selectors.targets'));
} catch (e) {
return;
}
if (!$anchor.length) {
return;
}
var scrollTop = $anchor.offset().top,
$wpAdminBar = elementorFrontend.elements.$wpAdminBar,
$activeStickies = jQuery('.elementor-section.elementor-sticky--active:visible'),
maxStickyHeight = 0;
if ($wpAdminBar.length > 0) {
scrollTop -= $wpAdminBar.height();
} // Offset height of tallest sticky
if ($activeStickies.length > 0) {
maxStickyHeight = Math.max.apply(null, $activeStickies.map(function () {
return jQuery(this).outerHeight();
}).get());
scrollTop -= maxStickyHeight;
}
event.preventDefault();
scrollTop = elementorFrontend.hooks.applyFilters('frontend/handlers/menu_anchor/scroll_top_distance', scrollTop);
this.elements.$scrollable.animate({
scrollTop: scrollTop
}, this.getSettings('scrollDuration'), 'linear');
},
onInit: function () {
elementorModules.ViewModule.prototype.onInit.apply(this, arguments);
this.bindEvents();
}
});
/***/ }),
/***/ "../assets/dev/js/frontend/utils/assets-loader.js":
/*!********************************************************!*\
!*** ../assets/dev/js/frontend/utils/assets-loader.js ***!
\********************************************************/
/***/ ((__unused_webpack_module, exports) => {
"use strict";
Object.defineProperty(exports, "__esModule", ({
value: true
}));
exports.default = void 0;
class AssetsLoader {
getScriptElement(src) {
const scriptElement = document.createElement('script');
scriptElement.src = src;
return scriptElement;
}
getStyleElement(src) {
const styleElement = document.createElement('link');
styleElement.rel = 'stylesheet';
styleElement.href = src;
return styleElement;
}
load(type, key) {
const assetData = AssetsLoader.assets[type][key];
if (!assetData.loader) {
assetData.loader = new Promise(resolve => {
const element = 'style' === type ? this.getStyleElement(assetData.src) : this.getScriptElement(assetData.src);
element.onload = () => resolve(true);
const parent = 'head' === assetData.parent ? assetData.parent : 'body';
document[parent].appendChild(element);
});
}
return assetData.loader;
}
}
exports.default = AssetsLoader;
const fileSuffix = elementorFrontendConfig.environmentMode.isScriptDebug ? '' : '.min';
AssetsLoader.assets = {
script: {
dialog: {
src: `${elementorFrontendConfig.urls.assets}lib/dialog/dialog${fileSuffix}.js?ver=4.8.1`
},
'share-link': {
src: `${elementorFrontendConfig.urls.assets}lib/share-link/share-link${fileSuffix}.js?ver=${elementorFrontendConfig.version}`
},
swiper: {
src: `${elementorFrontendConfig.urls.assets}lib/swiper/swiper${fileSuffix}.js?ver=5.3.6`
}
},
style: {}
};
/***/ }),
/***/ "../assets/dev/js/frontend/utils/lightbox/lightbox-manager.js":
/*!********************************************************************!*\
!*** ../assets/dev/js/frontend/utils/lightbox/lightbox-manager.js ***!
\********************************************************************/
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
"use strict";
Object.defineProperty(exports, "__esModule", ({
value: true
}));
exports.default = void 0;
class LightboxManager extends elementorModules.ViewModule {
static getLightbox() {
const lightboxPromise = new Promise(resolveLightbox => {
__webpack_require__.e(/*! import() | lightbox */ "lightbox").then(__webpack_require__.t.bind(__webpack_require__, /*! elementor-frontend/utils/lightbox/lightbox */ "../assets/dev/js/frontend/utils/lightbox/lightbox.js", 23)).then(({
default: LightboxModule
}) => resolveLightbox(new LightboxModule()));
}),
dialogPromise = elementorFrontend.utils.assetsLoader.load('script', 'dialog'),
shareLinkPromise = elementorFrontend.utils.assetsLoader.load('script', 'share-link');
return Promise.all([lightboxPromise, dialogPromise, shareLinkPromise]).then(() => lightboxPromise);
}
getDefaultSettings() {
return {
selectors: {
links: 'a, [data-elementor-lightbox]'
}
};
}
getDefaultElements() {
return {
$links: jQuery(this.getSettings('selectors.links'))
};
}
isLightboxLink(element) {
// Check for lowercase `a` to make sure it works also for links inside SVGs.
if ('a' === element.tagName.toLowerCase() && (element.hasAttribute('download') || !/^[^?]+\.(png|jpe?g|gif|svg|webp)(\?.*)?$/i.test(element.href)) && !element.dataset.elementorLightboxVideo) {
return false;
}
const generalOpenInLightbox = elementorFrontend.getKitSettings('global_image_lightbox'),
currentLinkOpenInLightbox = element.dataset.elementorOpenLightbox;
return 'yes' === currentLinkOpenInLightbox || generalOpenInLightbox && 'no' !== currentLinkOpenInLightbox;
}
async onLinkClick(event) {
const element = event.currentTarget,
$target = jQuery(event.target),
editMode = elementorFrontend.isEditMode(),
isColorPickingMode = editMode && elementor.$previewContents.find('body').hasClass('elementor-editor__ui-state__color-picker'),
isClickInsideElementor = !!$target.closest('.elementor-edit-area').length;
if (!this.isLightboxLink(element)) {
if (editMode && isClickInsideElementor) {
event.preventDefault();
}
return;
}
event.preventDefault();
if (editMode && !elementor.getPreferences('lightbox_in_editor')) {
return;
} // Disable lightbox on color picking mode.
if (isColorPickingMode) {
return;
}
const lightbox = this.isOptimizedAssetsLoading() ? await LightboxManager.getLightbox() : elementorFrontend.utils.lightbox;
lightbox.createLightbox(element);
}
isOptimizedAssetsLoading() {
return elementorFrontend.config.experimentalFeatures.e_optimized_assets_loading;
}
bindEvents() {
elementorFrontend.elements.$document.on('click', this.getSettings('selectors.links'), event => this.onLinkClick(event));
}
onInit(...args) {
super.onInit(...args);
if (!this.isOptimizedAssetsLoading() || elementorFrontend.isEditMode()) {
return;
} // Detecting lightbox links on init will reduce the time of waiting to the lightbox to be display on slow connections.
this.elements.$links.each((index, element) => {
if (this.isLightboxLink(element)) {
LightboxManager.getLightbox(); // Breaking the iteration when the library loading has already been triggered.
return false;
}
});
}
}
exports.default = LightboxManager;
/***/ }),
/***/ "../assets/dev/js/frontend/utils/swiper-bc.js":
/*!****************************************************!*\
!*** ../assets/dev/js/frontend/utils/swiper-bc.js ***!
\****************************************************/
/***/ ((__unused_webpack_module, exports) => {
"use strict";
Object.defineProperty(exports, "__esModule", ({
value: true
}));
exports.default = void 0;
class SwiperBC {
constructor(container, config) {
this.config = config;
if (this.config.breakpoints) {
// The config is passed as a param to allow adjustConfig to be called outside of this wrapper
this.config = this.adjustConfig(config);
} // In case of a legacy behaviour the constructor should return a new Swiper instance instead of a Promise.
if (config.legacy) {
return this.createSwiperInstance(container, this.config);
}
return new Promise(resolve => {
if (!elementorFrontend.config.experimentalFeatures.e_optimized_assets_loading) {
return resolve(this.createSwiperInstance(container, this.config));
}
elementorFrontend.utils.assetsLoader.load('script', 'swiper').then(() => resolve(this.createSwiperInstance(container, this.config)));
});
}
createSwiperInstance(container, config) {
// The condition should run only once to prevent an additional overwrite of the SwiperSource.
if (!SwiperBC.isSwiperLoaded && elementorFrontend.config.experimentalFeatures.e_optimized_assets_loading) {
SwiperSource = window.Swiper;
SwiperBC.isSwiperLoaded = true; // Once the SwiperSource has the Swiper lib function, we need to overwrite window.Swiper with the legacySwiper class.
legacySwiper();
}
SwiperSource.prototype.adjustConfig = this.adjustConfig;
return new SwiperSource(container, config);
} // Backwards compatibility for Elementor Pro <2.9.0 (old Swiper version - <5.0.0)
// In Swiper 5.0.0 and up, breakpoints changed from acting as max-width to acting as min-width
adjustConfig(config) {
// Only reverse the breakpoints if the handle param has been defined
if (!config.handleElementorBreakpoints) {
return config;
}
const elementorBreakpoints = elementorFrontend.config.responsive.activeBreakpoints,
elementorBreakpointValues = elementorFrontend.breakpoints.getBreakpointValues();
Object.keys(config.breakpoints).forEach(configBPKey => {
const configBPKeyInt = parseInt(configBPKey);
let breakpointToUpdate; // The `configBPKeyInt + 1` is a BC Fix for Elementor Pro Carousels from 2.8.0-2.8.3 used with Elementor >= 2.9.0
if (configBPKeyInt === elementorBreakpoints.mobile.value || configBPKeyInt + 1 === elementorBreakpoints.mobile.value) {
// This handles the mobile breakpoint. Elementor's default sm breakpoint is never actually used,
// so the mobile breakpoint (md) needs to be handled separately and set to the 0 breakpoint (xs)
breakpointToUpdate = 0;
} else if (elementorBreakpoints.widescreen && (configBPKeyInt === elementorBreakpoints.widescreen.value || configBPKeyInt + 1 === elementorBreakpoints.widescreen.value)) {
// Widescreen is a min-width breakpoint. Since in Swiper >5.0 the breakpoint system is min-width based,
// the value we pass to the Swiper instance in this case is the breakpoint from the user, unchanged.
breakpointToUpdate = configBPKeyInt;
} else {
// Find the index of the current config breakpoint in the Elementor Breakpoints array
const currentBPIndexInElementorBPs = elementorBreakpointValues.findIndex(elementorBP => {
// BC Fix for Elementor Pro Carousels from 2.8.0-2.8.3 used with Elementor >= 2.9.0
return configBPKeyInt === elementorBP || configBPKeyInt + 1 === elementorBP;
}); // For all other Swiper config breakpoints, move them one breakpoint down on the breakpoint list,
// according to the array of Elementor's global breakpoints
breakpointToUpdate = elementorBreakpointValues[currentBPIndexInElementorBPs - 1];
}
config.breakpoints[breakpointToUpdate] = config.breakpoints[configBPKey]; // Then reset the settings in the original breakpoint key to the default values
config.breakpoints[configBPKey] = {
slidesPerView: config.slidesPerView,
slidesPerGroup: config.slidesPerGroup ? config.slidesPerGroup : 1
};
});
return config;
}
} // The following code is needed to support Pro version < 3.1.0.
exports.default = SwiperBC;
SwiperBC.isSwiperLoaded = false; // In the legacy behavior, window.Swiper was a class that returns an instance of the Swiper lib function after config adjustments.
function legacySwiper() {
window.Swiper = class {
constructor(container, config) {
config.legacy = true;
return new SwiperBC(container, config);
}
};
}
let SwiperSource = window.Swiper; // In case that the Swiper lib exists (meaning not in optimized mode) we overwrite the window.Swiper with a class that supports legacy behavior.
if (SwiperSource) {
legacySwiper();
}
/***/ }),
/***/ "../assets/dev/js/frontend/utils/url-actions.js":
/*!******************************************************!*\
!*** ../assets/dev/js/frontend/utils/url-actions.js ***!
\******************************************************/
/***/ ((__unused_webpack_module, exports) => {
"use strict";
Object.defineProperty(exports, "__esModule", ({
value: true
}));
exports.default = void 0;
class _default extends elementorModules.ViewModule {
getDefaultSettings() {
return {
selectors: {
links: 'a[href^="%23elementor-action"], a[href^="#elementor-action"]'
}
};
}
bindEvents() {
elementorFrontend.elements.$document.on('click', this.getSettings('selectors.links'), this.runLinkAction.bind(this));
}
initActions() {
this.actions = {
lightbox: async settings => {
const lightbox = await elementorFrontend.utils.lightbox;
if (settings.id) {
lightbox.openSlideshow(settings.id, settings.url);
} else {
lightbox.showModal(settings);
}
}
};
}
addAction(name, callback) {
this.actions[name] = callback;
}
runAction(url, ...restArgs) {
url = decodeURIComponent(url);
const actionMatch = url.match(/action=(.+?)&/),
settingsMatch = url.match(/settings=(.+)/);
if (!actionMatch) {
return;
}
const action = this.actions[actionMatch[1]];
if (!action) {
return;
}
let settings = {};
if (settingsMatch) {
settings = JSON.parse(atob(settingsMatch[1]));
}
action(settings, ...restArgs);
}
runLinkAction(event) {
event.preventDefault();
this.runAction(jQuery(event.currentTarget).attr('href'), event);
}
runHashAction() {
if (location.hash) {
this.runAction(location.hash);
}
}
createActionHash(action, settings) {
// We need to encode the hash tag (#) here, in order to support share links for a variety of providers
return encodeURIComponent(`#elementor-action:action=${action}&settings=${btoa(JSON.stringify(settings))}`);
}
onInit() {
super.onInit();
this.initActions();
elementorFrontend.on('components:init', this.runHashAction.bind(this));
}
}
exports.default = _default;
/***/ }),
/***/ "../assets/dev/js/frontend/utils/utils.js":
/*!************************************************!*\
!*** ../assets/dev/js/frontend/utils/utils.js ***!
\************************************************/
/***/ ((__unused_webpack_module, exports) => {
"use strict";
Object.defineProperty(exports, "__esModule", ({
value: true
}));
exports.escapeHTML = void 0;
// Escape HTML special chars to prevent XSS.
const escapeHTML = str => {
const specialChars = {
'&': '&',
'<': '<',
'>': '>',
"'": ''',
'"': '"'
};
return str.replace(/[&<>'"]/g, tag => specialChars[tag] || tag);
};
exports.escapeHTML = escapeHTML;
/***/ }),
/***/ "../assets/dev/js/frontend/utils/video-api/base-loader.js":
/*!****************************************************************!*\
!*** ../assets/dev/js/frontend/utils/video-api/base-loader.js ***!
\****************************************************************/
/***/ ((__unused_webpack_module, exports) => {
"use strict";
Object.defineProperty(exports, "__esModule", ({
value: true
}));
exports.default = void 0;
class BaseLoader extends elementorModules.ViewModule {
getDefaultSettings() {
return {
isInserted: false,
selectors: {
firstScript: 'script:first'
}
};
}
getDefaultElements() {
return {
$firstScript: jQuery(this.getSettings('selectors.firstScript'))
};
}
insertAPI() {
this.elements.$firstScript.before(jQuery('