/*! jQuery Migrate v3.4.0 | (c) OpenJS Foundation and other contributors | jquery.org/license */ "undefined"==typeof jQuery.migrateMute&&(jQuery.migrateMute=!0),function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery"],function(e){return t(e,window)}):"object"==typeof module&&module.exports?module.exports=t(require("jquery"),window):t(jQuery,window)}(function(s,n){"use strict";function e(e){return 0<=function(e,t){for(var r=/^(\d+)\.(\d+)\.(\d+)/,n=r.exec(e)||[],o=r.exec(t)||[],a=1;a<=3;a++){if(+n[a]>+o[a])return 1;if(+n[a]<+o[a])return-1}return 0}(s.fn.jquery,e)}s.migrateVersion="3.4.0";var t=Object.create(null),o=(s.migrateDisablePatches=function(){for(var e=0;e\x20\t\r\n\f]*)[^>]*)\/>/gi),_=(s.UNSAFE_restoreLegacyHtmlPrefilter=function(){s.migrateEnablePatches("self-closed-tags")},d(s,"htmlPrefilter",function(e){var t,r;return(r=(t=e).replace(O,"<$1>"))!==t&&C(t)!==C(r)&&i("self-closed-tags","HTML tags must be properly nested and closed: "+t),e.replace(O,"<$1>")},"self-closed-tags"),s.migrateDisablePatches("self-closed-tags"),s.fn.offset);return d(s.fn,"offset",function(){var e=this[0];return!e||e.nodeType&&e.getBoundingClientRect?_.apply(this,arguments):(i("offset-valid-elem","jQuery.fn.offset() requires a valid DOM element"),arguments.length?this:void 0)},"offset-valid-elem"),s.ajax&&(H=s.param,d(s,"param",function(e,t){var r=s.ajaxSettings&&s.ajaxSettings.traditional;return void 0===t&&r&&(i("param-ajax-traditional","jQuery.param() no longer uses jQuery.ajaxSettings.traditional"),t=r),H.call(this,e,t)},"param-ajax-traditional")),u(s.fn,"andSelf",s.fn.addBack,"andSelf","jQuery.fn.andSelf() is deprecated and removed, use jQuery.fn.addBack()"),s.Deferred&&(E=s.Deferred,M=[["resolve","done",s.Callbacks("once memory"),s.Callbacks("once memory"),"resolved"],["reject","fail",s.Callbacks("once memory"),s.Callbacks("once memory"),"rejected"],["notify","progress",s.Callbacks("memory"),s.Callbacks("memory")]],d(s,"Deferred",function(e){var a=E(),i=a.promise();function t(){var o=arguments;return s.Deferred(function(n){s.each(M,function(e,t){var r="function"==typeof o[e]&&o[e];a[t[1]](function(){var e=r&&r.apply(this,arguments);e&&"function"==typeof e.promise?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[t[0]+"With"](this===i?n.promise():this,r?[e]:arguments)})}),o=null}).promise()}return u(a,"pipe",t,"deferred-pipe","deferred.pipe() is deprecated"),u(i,"pipe",t,"deferred-pipe","deferred.pipe() is deprecated"),e&&e.call(a,a),a},"deferred-pipe"),s.Deferred.exceptionHook=E.exceptionHook),s}); CLI_ACCEPT_COOKIE_NAME=(typeof CLI_ACCEPT_COOKIE_NAME!=='undefined'?CLI_ACCEPT_COOKIE_NAME:'viewed_cookie_policy');CLI_PREFERENCE_COOKIE=(typeof CLI_PREFERENCE_COOKIE!=='undefined'?CLI_PREFERENCE_COOKIE:'CookieLawInfoConsent');CLI_ACCEPT_COOKIE_EXPIRE=(typeof CLI_ACCEPT_COOKIE_EXPIRE!=='undefined'?CLI_ACCEPT_COOKIE_EXPIRE:365);CLI_COOKIEBAR_AS_POPUP=(typeof CLI_COOKIEBAR_AS_POPUP!=='undefined'?CLI_COOKIEBAR_AS_POPUP:false);var CLI_Cookie={set:function(name,value,days){var secure="";if(true===Boolean(Cli_Data.secure_cookies)){secure=";secure";} if(days){var date=new Date();date.setTime(date.getTime()+(days*24*60*60*1000));var expires="; expires="+date.toGMTString();}else{var expires="";} document.cookie=name+"="+value+secure+expires+"; path=/";if(days<1){host_name=window.location.hostname;document.cookie=name+"="+value+expires+"; path=/; domain=."+host_name+";";if(host_name.indexOf("www")!=1){var host_name_withoutwww=host_name.replace('www','');document.cookie=name+"="+value+secure+expires+"; path=/; domain="+host_name_withoutwww+";";} host_name=host_name.substring(host_name.lastIndexOf(".",host_name.lastIndexOf(".")-1));document.cookie=name+"="+value+secure+expires+"; path=/; domain="+host_name+";";}},read:function(name){var nameEQ=name+"=";var ca=document.cookie.split(';');for(var i=0;i0&&this.main_link.hasClass('cli-minimize-bar')){this.hideHeader();cliBlocker.cookieBar(false);this.showagain_elm.slideDown(this.settings.animate_speed_show);return true;} return false;},attachEvents:function(){jQuery(document).on('click','.wt-cli-privacy-btn',function(e){e.preventDefault();CLI.accept_close();CLI.settingsPopUpClose();});jQuery('.wt-cli-accept-btn').on("click",function(e){e.preventDefault();CLI.acceptRejectCookies(jQuery(this));});jQuery('.wt-cli-accept-all-btn').on("click",function(e){e.preventDefault();CLI.acceptRejectCookies(jQuery(this),'accept');});jQuery('.wt-cli-reject-btn').on("click",function(e){e.preventDefault();CLI.acceptRejectCookies(jQuery(this),'reject');});this.settingsPopUp();this.settingsTabbedAccordion();this.toggleUserPreferenceCheckBox();this.hideCookieBarOnClose();this.cookieLawInfoRunCallBacks();},acceptRejectCookies(element,action='custom'){var open_link=element[0].hasAttribute("href")&&element.attr("href")!='#'?true:false;var new_window=false;if(action=='accept'){this.enableAllCookies();this.accept_close();new_window=CLI.settings.button_7_new_win?true:false;}else if(action=='reject'){this.disableAllCookies();this.reject_close();new_window=Boolean(this.settings.button_3_new_win)?true:false;}else{this.accept_close();new_window=Boolean(this.settings.button_1_new_win)?true:false;} if(open_link){if(new_window){window.open(element.attr("href"),'_blank');}else{window.location.href=element.attr("href");}}},toggleUserPreferenceCheckBox:function(){jQuery('.cli-user-preference-checkbox').each(function(){categoryCookie='cookielawinfo-'+jQuery(this).attr('data-id');categoryCookieValue=CLI_Cookie.read(categoryCookie);if(categoryCookieValue==null){if(jQuery(this).is(':checked')){CLI_Cookie.set(categoryCookie,'yes',CLI_ACCEPT_COOKIE_EXPIRE);}else{CLI_Cookie.set(categoryCookie,'no',CLI_ACCEPT_COOKIE_EXPIRE);}}else{if(categoryCookieValue=="yes"){jQuery(this).prop("checked",true);}else{jQuery(this).prop("checked",false);}}});jQuery('.cli-user-preference-checkbox').on("click",function(e){var dataID=jQuery(this).attr('data-id');var currentToggleElm=jQuery('.cli-user-preference-checkbox[data-id='+dataID+']');if(jQuery(this).is(':checked')){CLI_Cookie.set('cookielawinfo-'+dataID,'yes',CLI_ACCEPT_COOKIE_EXPIRE);currentToggleElm.prop('checked',true);}else{CLI_Cookie.set('cookielawinfo-'+dataID,'no',CLI_ACCEPT_COOKIE_EXPIRE);currentToggleElm.prop('checked',false);} CLI.checkCategories();CLI.generateConsent();});},settingsPopUp:function(){jQuery(document).on('click','.cli_settings_button',function(e){e.preventDefault();CLI.settingsModal.addClass("cli-show").css({'opacity':0}).animate({'opacity':1});CLI.settingsModal.removeClass('cli-blowup cli-out').addClass("cli-blowup");jQuery('body').addClass("cli-modal-open");jQuery(".cli-settings-overlay").addClass("cli-show");jQuery("#cookie-law-info-bar").css({'opacity':.1});if(!jQuery('.cli-settings-mobile').is(':visible')){CLI.settingsModal.find('.cli-nav-link:eq(0)').trigger("click");}});jQuery('#cliModalClose').on("click",function(e){CLI.settingsPopUpClose();});CLI.settingsModal.on("click",function(e){if(!(document.getElementsByClassName('cli-modal-dialog')[0].contains(e.target))){CLI.settingsPopUpClose();}});jQuery('.cli_enable_all_btn').on("click",function(e){var cli_toggle_btn=jQuery(this);var enable_text=cli_toggle_btn.attr('data-enable-text');var disable_text=cli_toggle_btn.attr('data-disable-text');if(cli_toggle_btn.hasClass('cli-enabled')){CLI.disableAllCookies();cli_toggle_btn.html(enable_text);}else{CLI.enableAllCookies();cli_toggle_btn.html(disable_text);} jQuery(this).toggleClass('cli-enabled');});this.privacyReadmore();},settingsTabbedAccordion:function(){jQuery(".cli-tab-header").on("click",function(e){if(!(jQuery(e.target).hasClass('cli-slider')||jQuery(e.target).hasClass('cli-user-preference-checkbox'))){if(jQuery(this).hasClass("cli-tab-active")){jQuery(this).removeClass("cli-tab-active");jQuery(this).siblings(".cli-tab-content").slideUp(200);}else{jQuery(".cli-tab-header").removeClass("cli-tab-active");jQuery(this).addClass("cli-tab-active");jQuery(".cli-tab-content").slideUp(200);jQuery(this).siblings(".cli-tab-content").slideDown(200);}}});},settingsPopUpClose:function(){this.settingsModal.removeClass('cli-show');this.settingsModal.addClass('cli-out');jQuery('body').removeClass("cli-modal-open");jQuery(".cli-settings-overlay").removeClass("cli-show");jQuery("#cookie-law-info-bar").css({'opacity':1});},privacyReadmore:function(){var el=jQuery('.cli-privacy-content .cli-privacy-content-text');if(el.length>0){var clone=el.clone(),originalHtml=clone.html(),originalHeight=el.outerHeight(),Trunc={addReadmore:function(textBlock){if(textBlock.html().length>250){jQuery('.cli-privacy-readmore').show();}else{jQuery('.cli-privacy-readmore').hide();}},truncateText:function(textBlock){var strippedText=jQuery('
').html(textBlock.html());strippedText.find('table').remove();textBlock.html(strippedText.html());currentText=textBlock.text();if(currentText.trim().length>250){var newStr=currentText.substring(0,250);textBlock.empty().html(newStr).append('...');}},replaceText:function(textBlock,original){return textBlock.html(original);}};Trunc.addReadmore(el);Trunc.truncateText(el);jQuery('a.cli-privacy-readmore').on("click",function(e){e.preventDefault();if(jQuery('.cli-privacy-overview').hasClass('cli-collapsed')){Trunc.truncateText(el);jQuery('.cli-privacy-overview').removeClass('cli-collapsed');el.css('height','100%');}else{jQuery('.cli-privacy-overview').addClass('cli-collapsed');Trunc.replaceText(el,originalHtml);}});}},attachDelete:function(){this.delete_link.on("click",function(e){CLI_Cookie.erase(CLI_ACCEPT_COOKIE_NAME);for(var k in Cli_Data.nn_cookie_ids){CLI_Cookie.erase(Cli_Data.nn_cookie_ids[k]);} CLI.generateConsent();return false;});},configButtons:function(){this.main_button.css('color',this.settings.button_1_link_colour);if(Boolean(this.settings.button_1_as_button)){this.main_button.css('background-color',this.settings.button_1_button_colour);this.main_button.on('mouseenter',function(){jQuery(this).css('background-color',CLI.settings.button_1_button_hover);}).on('mouseleave',function(){jQuery(this).css('background-color',CLI.settings.button_1_button_colour);});} this.main_link.css('color',this.settings.button_2_link_colour);if(Boolean(this.settings.button_2_as_button)){this.main_link.css('background-color',this.settings.button_2_button_colour);this.main_link.on('mouseenter',function(){jQuery(this).css('background-color',CLI.settings.button_2_button_hover);}).on('mouseleave',function(){jQuery(this).css('background-color',CLI.settings.button_2_button_colour);});} this.reject_link.css('color',this.settings.button_3_link_colour);if(Boolean(this.settings.button_3_as_button)){this.reject_link.css('background-color',this.settings.button_3_button_colour);this.reject_link.on('mouseenter',function(){jQuery(this).css('background-color',CLI.settings.button_3_button_hover);}).on('mouseleave',function(){jQuery(this).css('background-color',CLI.settings.button_3_button_colour);});} this.settings_button.css('color',this.settings.button_4_link_colour);if(Boolean(this.settings.button_4_as_button)){this.settings_button.css('background-color',this.settings.button_4_button_colour);this.settings_button.on('mouseenter',function(){jQuery(this).css('background-color',CLI.settings.button_4_button_hover);}).on('mouseleave',function(){jQuery(this).css('background-color',CLI.settings.button_4_button_colour);});} this.accept_all_button.css('color',this.settings.button_7_link_colour);if(this.settings.button_7_as_button){this.accept_all_button.css('background-color',this.settings.button_7_button_colour);this.accept_all_button.on('mouseenter',function(){jQuery(this).css('background-color',CLI.settings.button_7_button_hover);}).on('mouseleave',function(){jQuery(this).css('background-color',CLI.settings.button_7_button_colour);});}},toggleBar:function(){if(CLI_COOKIEBAR_AS_POPUP){this.barAsPopUp(1);} if(CLI.settings.cookie_bar_as=='widget'){this.barAsWidget(1);} if(!CLI_Cookie.exists(CLI_ACCEPT_COOKIE_NAME)){this.displayHeader();}else{this.hideHeader();} if(Boolean(this.settings.show_once_yn)){setTimeout(function(){CLI.close_header();},CLI.settings.show_once);} if(CLI.js_blocking_enabled===false){if(Boolean(Cli_Data.ccpaEnabled)===true){if(Cli_Data.ccpaType==='ccpa'&&Boolean(Cli_Data.ccpaBarEnabled)===false){cliBlocker.cookieBar(false);}}else{jQuery('.wt-cli-ccpa-opt-out,.wt-cli-ccpa-checkbox,.wt-cli-ccpa-element').remove();}} this.showagain_elm.on("click",function(e){e.preventDefault();CLI.showagain_elm.slideUp(CLI.settings.animate_speed_hide,function(){CLI.bar_elm.slideDown(CLI.settings.animate_speed_show);if(CLI_COOKIEBAR_AS_POPUP){CLI.showPopupOverlay();}});});},configShowAgain:function(){this.showagain_config={'background-color':this.settings.background,'color':this.l1hs(this.settings.text),'position':'fixed','font-family':this.settings.font_family};if(Boolean(this.settings.border_on)){var border_to_hide='border-'+this.settings.notify_position_vertical;this.showagain_config['border']='1px solid '+this.l1hs(this.settings.border);this.showagain_config[border_to_hide]='none';} var cli_win=jQuery(window);var cli_winw=cli_win.width();var showagain_x_pos=this.settings.showagain_x_position;if(cli_winw<300){showagain_x_pos=10;this.showagain_config.width=cli_winw-20;}else{this.showagain_config.width='auto';} var cli_defw=cli_winw>400?500:cli_winw-20;if(CLI_COOKIEBAR_AS_POPUP){var sa_pos=this.settings.popup_showagain_position;var sa_pos_arr=sa_pos.split('-');if(sa_pos_arr[1]=='left'){this.showagain_config.left=showagain_x_pos;}else if(sa_pos_arr[1]=='right'){this.showagain_config.right=showagain_x_pos;} if(sa_pos_arr[0]=='top'){this.showagain_config.top=0;}else if(sa_pos_arr[0]=='bottom'){this.showagain_config.bottom=0;} this.bar_config['position']='fixed';}else if(this.settings.cookie_bar_as=='widget'){this.showagain_config.bottom=0;if(this.settings.widget_position=='left'){this.showagain_config.left=showagain_x_pos;}else if(this.settings.widget_position=='right'){this.showagain_config.right=showagain_x_pos;}}else{if(this.settings.notify_position_vertical=="top"){this.showagain_config.top='0';}else if(this.settings.notify_position_vertical=="bottom"){this.bar_config['position']='fixed';this.bar_config['bottom']='0';this.showagain_config.bottom='0';} if(this.settings.notify_position_horizontal=="left"){this.showagain_config.left=showagain_x_pos;}else if(this.settings.notify_position_horizontal=="right"){this.showagain_config.right=showagain_x_pos;}} this.showagain_elm.css(this.showagain_config);},configBar:function(){this.bar_config={'background-color':this.settings.background,'color':this.settings.text,'font-family':this.settings.font_family};if(this.settings.notify_position_vertical=="top"){this.bar_config['top']='0';if(Boolean(this.settings.header_fix)===true){this.bar_config['position']='fixed';}}else{this.bar_config['bottom']='0';} this.configShowAgain();this.bar_elm.css(this.bar_config).hide();},l1hs:function(str){if(str.charAt(0)=="#"){str=str.substring(1,str.length);}else{return"#"+str;} return this.l1hs(str);},close_header:function(){CLI_Cookie.set(CLI_ACCEPT_COOKIE_NAME,'yes',CLI_ACCEPT_COOKIE_EXPIRE);this.hideHeader();},accept_close:function(){this.hidePopupOverlay();this.generateConsent();this.cookieLawInfoRunCallBacks();CLI_Cookie.set(CLI_ACCEPT_COOKIE_NAME,'yes',CLI_ACCEPT_COOKIE_EXPIRE);if(Boolean(this.settings.notify_animate_hide)){if(CLI.js_blocking_enabled===true){this.bar_elm.slideUp(this.settings.animate_speed_hide,cliBlocker.runScripts);}else{this.bar_elm.slideUp(this.settings.animate_speed_hide);}}else{if(CLI.js_blocking_enabled===true){this.bar_elm.hide(0,cliBlocker.runScripts);}else{this.bar_elm.hide();}} if(Boolean(this.settings.showagain_tab)){this.showagain_elm.slideDown(this.settings.animate_speed_show);} if(Boolean(this.settings.accept_close_reload)===true){this.reload_current_page();} return false;},reject_close:function(){this.hidePopupOverlay();this.generateConsent();this.cookieLawInfoRunCallBacks();for(var k in Cli_Data.nn_cookie_ids){CLI_Cookie.erase(Cli_Data.nn_cookie_ids[k]);} CLI_Cookie.set(CLI_ACCEPT_COOKIE_NAME,'no',CLI_ACCEPT_COOKIE_EXPIRE);if(Boolean(this.settings.notify_animate_hide)){if(CLI.js_blocking_enabled===true){this.bar_elm.slideUp(this.settings.animate_speed_hide,cliBlocker.runScripts);}else{this.bar_elm.slideUp(this.settings.animate_speed_hide);}}else{if(CLI.js_blocking_enabled===true){this.bar_elm.hide(cliBlocker.runScripts);}else{this.bar_elm.hide();}} if(Boolean(this.settings.showagain_tab)){this.showagain_elm.slideDown(this.settings.animate_speed_show);} if(Boolean(this.settings.reject_close_reload)===true){this.reload_current_page();} return false;},reload_current_page:function(){window.location.reload(true);},closeOnScroll:function(){if(window.pageYOffset>100&&!CLI_Cookie.read(CLI_ACCEPT_COOKIE_NAME)){CLI.accept_close();if(Boolean(CLI.settings.scroll_close_reload)===true){window.location.reload();} window.removeEventListener("scroll",CLI.closeOnScroll,false);}},displayHeader:function(){if(Boolean(this.settings.notify_animate_show)){this.bar_elm.slideDown(this.settings.animate_speed_show);}else{this.bar_elm.show();} this.showagain_elm.hide();if(CLI_COOKIEBAR_AS_POPUP){this.showPopupOverlay();}},hideHeader:function(){if(Boolean(this.settings.showagain_tab)){if(Boolean(this.settings.notify_animate_show)){this.showagain_elm.slideDown(this.settings.animate_speed_show);}else{this.showagain_elm.show();}}else{this.showagain_elm.hide();} this.bar_elm.slideUp(this.settings.animate_speed_show);this.hidePopupOverlay();},hidePopupOverlay:function(){jQuery('body').removeClass("cli-barmodal-open");jQuery(".cli-popupbar-overlay").removeClass("cli-show");},showPopupOverlay:function(){if(this.bar_elm.length){if(Boolean(this.settings.popup_overlay)){jQuery('body').addClass("cli-barmodal-open");jQuery(".cli-popupbar-overlay").addClass("cli-show");}}},barAsWidget:function(a){var cli_elm=this.bar_elm;cli_elm.attr('data-cli-type','widget');var cli_win=jQuery(window);var cli_winh=cli_win.height()-40;var cli_winw=cli_win.width();var cli_defw=cli_winw>400?300:cli_winw-30;cli_elm.css({'width':cli_defw,'height':'auto','max-height':cli_winh,'overflow':'auto','position':'fixed','box-sizing':'border-box'});if(this.checkifStyleAttributeExist()===false){cli_elm.css({'padding':'25px 15px'});} if(this.settings.widget_position=='left'){cli_elm.css({'left':'15px','right':'auto','bottom':'15px','top':'auto'});}else{cli_elm.css({'left':'auto','right':'15px','bottom':'15px','top':'auto'});} if(a){this.setResize();}},barAsPopUp:function(a){if(typeof cookie_law_info_bar_as_popup==='function'){return false;} var cli_elm=this.bar_elm;cli_elm.attr('data-cli-type','popup');var cli_win=jQuery(window);var cli_winh=cli_win.height()-40;var cli_winw=cli_win.width();var cli_defw=cli_winw>700?500:cli_winw-20;cli_elm.css({'width':cli_defw,'height':'auto','max-height':cli_winh,'bottom':'','top':'50%','left':'50%','margin-left':(cli_defw/2)*-1,'margin-top':'-100px','overflow':'auto'}).addClass('cli-bar-popup cli-modal-content');if(this.checkifStyleAttributeExist()===false){cli_elm.css({'padding':'25px 15px'});} cli_h=cli_elm.height();li_h=cli_h<200?200:cli_h;cli_elm.css({'top':'50%','margin-top':((cli_h/2)+30)*-1});setTimeout(function(){cli_elm.css({'bottom':''});},100);if(a){this.setResize();}},setResize:function(){var resizeTmr=null;jQuery(window).resize(function(){clearTimeout(resizeTmr);resizeTmr=setTimeout(function(){if(CLI_COOKIEBAR_AS_POPUP){CLI.barAsPopUp();} if(CLI.settings.cookie_bar_as=='widget'){CLI.barAsWidget();} CLI.configShowAgain();},500);});},enableAllCookies:function(){jQuery('.cli-user-preference-checkbox').each(function(){var cli_chkbox_elm=jQuery(this);var cli_chkbox_data_id=cli_chkbox_elm.attr('data-id');if(cli_chkbox_data_id!='checkbox-necessary'){cli_chkbox_elm.prop('checked',true);CLI_Cookie.set('cookielawinfo-'+cli_chkbox_data_id,'yes',CLI_ACCEPT_COOKIE_EXPIRE);}});},disableAllCookies:function(){jQuery('.cli-user-preference-checkbox').each(function(){var cli_chkbox_elm=jQuery(this);var cli_chkbox_data_id=cli_chkbox_elm.attr('data-id');cliCategorySlug=cli_chkbox_data_id.replace('checkbox-','');if(Cli_Data.strictlyEnabled.indexOf(cliCategorySlug)===-1){cli_chkbox_elm.prop('checked',false);CLI_Cookie.set('cookielawinfo-'+cli_chkbox_data_id,'no',CLI_ACCEPT_COOKIE_EXPIRE);}});},hideCookieBarOnClose:function(){jQuery(document).on('click','.cli_cookie_close_button',function(e){e.preventDefault();var elm=jQuery(this);if(Cli_Data.ccpaType==='ccpa'){CLI.enableAllCookies();} CLI.accept_close();});},checkCategories:function(){var cliAllowedCategories=[];var cli_categories={};jQuery('.cli-user-preference-checkbox').each(function(){var status=false;cli_chkbox_elm=jQuery(this);cli_chkbox_data_id=cli_chkbox_elm.attr('data-id');cli_chkbox_data_id=cli_chkbox_data_id.replace('checkbox-','');cli_chkbox_data_id_trimmed=cli_chkbox_data_id.replace('-','_') if(jQuery(cli_chkbox_elm).is(':checked')){status=true;cliAllowedCategories.push(cli_chkbox_data_id);} cli_categories[cli_chkbox_data_id_trimmed]=status;});CLI.allowedCategories=cliAllowedCategories;},cookieLawInfoRunCallBacks:function(){this.checkCategories();if(CLI_Cookie.read(CLI_ACCEPT_COOKIE_NAME)=='yes'){if("function"==typeof CookieLawInfo_Accept_Callback){CookieLawInfo_Accept_Callback();}}},generateConsent:function(){var preferenceCookie=CLI_Cookie.read(CLI_PREFERENCE_COOKIE);cliConsent={};if(preferenceCookie!==null){cliConsent=window.atob(preferenceCookie);cliConsent=JSON.parse(cliConsent);} cliConsent.ver=Cli_Data.consentVersion;categories=[];jQuery('.cli-user-preference-checkbox').each(function(){categoryVal='';cli_chkbox_data_id=jQuery(this).attr('data-id');cli_chkbox_data_id=cli_chkbox_data_id.replace('checkbox-','');if(jQuery(this).is(':checked')){categoryVal=true;}else{categoryVal=false;} cliConsent[cli_chkbox_data_id]=categoryVal;});cliConsent=JSON.stringify(cliConsent);cliConsent=window.btoa(cliConsent);CLI_Cookie.set(CLI_PREFERENCE_COOKIE,cliConsent,CLI_ACCEPT_COOKIE_EXPIRE);},addStyleAttribute:function(){var bar=this.bar_elm;var styleClass='';if(jQuery(bar).find('.cli-bar-container').length>0){styleClass=jQuery('.cli-bar-container').attr('class');styleClass=styleClass.replace('cli-bar-container','');styleClass=styleClass.trim();jQuery(bar).attr('data-cli-style',styleClass);}},getParameterByName:function(name,url){if(!url){url=window.location.href;} name=name.replace(/[\[\]]/g,'\\$&');var regex=new RegExp('[?&]'+name+'(=([^&#]*)|&|#|$)'),results=regex.exec(url);if(!results){return null;} if(!results[2]){return'';} return decodeURIComponent(results[2].replace(/\+/g,' '));},CookieLawInfo_Callback:function(enableBar,enableBlocking){enableBar=typeof enableBar!=='undefined'?enableBar:true;enableBlocking=typeof enableBlocking!=='undefined'?enableBlocking:true;if(CLI.js_blocking_enabled===true&&Boolean(Cli_Data.custom_integration)===true){cliBlocker.cookieBar(enableBar);cliBlocker.runScripts(enableBlocking);}},checkifStyleAttributeExist:function(){var exist=false;var attr=this.bar_elm.attr('data-cli-style');if(typeof attr!==typeof undefined&&attr!==false){exist=true;} return exist;},reviewConsent:function(){jQuery(document).on('click','.cli_manage_current_consent,.wt-cli-manage-consent-link',function(){CLI.displayHeader();});},mayBeSetPreferenceCookie:function(){if(CLI.getParameterByName('cli_bypass')==="1"){CLI.generateConsent();}}} var cliBlocker={blockingStatus:true,scriptsLoaded:false,ccpaEnabled:false,ccpaRegionBased:false,ccpaApplicable:false,ccpaBarEnabled:false,cliShowBar:true,isBypassEnabled:CLI.getParameterByName('cli_bypass'),checkPluginStatus:function(callbackA,callbackB){this.ccpaEnabled=Boolean(Cli_Data.ccpaEnabled);this.ccpaRegionBased=Boolean(Cli_Data.ccpaRegionBased);this.ccpaBarEnabled=Boolean(Cli_Data.ccpaBarEnabled);if(Boolean(Cli_Data.custom_integration)===true){callbackA(false);}else{if(this.ccpaEnabled===true){this.ccpaApplicable=true;if(Cli_Data.ccpaType==='ccpa'){if(this.ccpaBarEnabled!==true){this.cliShowBar=false;this.blockingStatus=false;}}}else{jQuery('.wt-cli-ccpa-opt-out,.wt-cli-ccpa-checkbox,.wt-cli-ccpa-element').remove();} if(cliBlocker.isBypassEnabled==="1"){cliBlocker.blockingStatus=false;} callbackA(this.cliShowBar);callbackB(this.blockingStatus);}},cookieBar:function(showbar){showbar=typeof showbar!=='undefined'?showbar:true;cliBlocker.cliShowBar=showbar;if(cliBlocker.cliShowBar===false){CLI.bar_elm.hide();CLI.showagain_elm.hide();CLI.settingsModal.removeClass('cli-blowup cli-out');CLI.hidePopupOverlay();jQuery(".cli-settings-overlay").removeClass("cli-show");}else{if(!CLI_Cookie.exists(CLI_ACCEPT_COOKIE_NAME)){CLI.displayHeader();}else{CLI.hideHeader();}}},removeCookieByCategory:function(){if(cliBlocker.blockingStatus===true){if(CLI_Cookie.read(CLI_ACCEPT_COOKIE_NAME)!==null){var non_necessary_cookies=Cli_Data.non_necessary_cookies;for(var key in non_necessary_cookies){currentCategory=key;if(CLI.allowedCategories.indexOf(currentCategory)===-1){var nonNecessaryCookies=non_necessary_cookies[currentCategory];for(var i=0;i0){var runList=[] var typeAttr Array.prototype.forEach.call($scripts,function($script){typeAttr=$script.getAttribute('type') runList.push(function(callback){cliScriptFuncs.insertScript($script,callback)})}) cliScriptFuncs.seq(runList,cliScriptFuncs.scriptsDone);}}};genericFuncs.renderByElement(cliBlocker.removeCookieByCategory);},ccpaOptedOut:function(){var ccpaOptedOut=false;var preferenceCookie=CLI_Cookie.read(CLI_PREFERENCE_COOKIE);if(preferenceCookie!==null){cliConsent=window.atob(preferenceCookie);cliConsent=JSON.parse(cliConsent);if(typeof cliConsent.ccpaOptout!=='undefined'){ccpaOptedOut=cliConsent.ccpaOptout;}} return ccpaOptedOut;}} jQuery(document).ready(function(){if(typeof cli_cookiebar_settings!='undefined'){CLI.set({settings:cli_cookiebar_settings});if(CLI.js_blocking_enabled===true){cliBlocker.checkPluginStatus(cliBlocker.cookieBar,cliBlocker.runScripts);}}}); (function(t){function e(e){return u?e.data("events"):t._data(e[0]).events}function n(t,n,r){var i=e(t),a=i[n];if(!u){var s=r?a.splice(a.delegateCount-1,1)[0]:a.pop();return a.splice(r?0:a.delegateCount||0,0,s),void 0}r?i.live.unshift(i.live.pop()):a.unshift(a.pop())}function r(e,r,i){var a=r.split(/\s+/);e.each(function(){for(var e=0;a.length>e;++e){var r=a[e].trim().match(/[^\.]+/i)[0];n(t(this),r,i)}})}function i(e){t.fn[e+"First"]=function(){var n=t.makeArray(arguments),i=n.shift();return i&&(t.fn[e].apply(this,arguments),r(this,i)),this}}var a=t.fn.jquery.split("."),s=parseInt(a[0]),f=parseInt(a[1]),u=1>s||1==s&&7>f;i("bind"),i("one"),t.fn.delegateFirst=function(){var e=t.makeArray(arguments),n=e[1];return n&&(e.splice(0,2),t.fn.delegate.apply(this,arguments),r(this,n,!0)),this},t.fn.liveFirst=function(){var e=t.makeArray(arguments);return e.unshift(this.selector),t.fn.delegateFirst.apply(t(document),e),this},u||(t.fn.onFirst=function(e,n){var i=t(this),a="string"==typeof n;if(t.fn.on.apply(i,arguments),"object"==typeof e)for(type in e)e.hasOwnProperty(type)&&r(i,type,a);else"string"==typeof e&&r(i,e,a);return i})})(jQuery); !function(e){var n=!1;if("function"==typeof define&&define.amd&&(define(e),n=!0),"object"==typeof exports&&(module.exports=e(),n=!0),!n){var o=window.Cookies,t=window.Cookies=e();t.noConflict=function(){return window.Cookies=o,t}}}(function(){function e(){for(var e=0,n={};e1){if(i=e({path:"/"},t.defaults,i),"number"==typeof i.expires){var a=new Date;a.setMilliseconds(a.getMilliseconds()+864e5*i.expires),i.expires=a}try{c=JSON.stringify(r),/^[\{\[]/.test(c)&&(r=c)}catch(e){}return r=o.write?o.write(r,n):encodeURIComponent(String(r)).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent),n=encodeURIComponent(String(n)),n=n.replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent),n=n.replace(/[\(\)]/g,escape),document.cookie=[n,"=",r,i.expires?"; expires="+i.expires.toUTCString():"",i.path?"; path="+i.path:"",i.domain?"; domain="+i.domain:"",i.secure?"; secure":""].join("")}n||(c={});for(var p=document.cookie?document.cookie.split("; "):[],s=/(%[0-9A-Z]{2})+/g,d=0;d>>0;if(len===0){return false;} var n=fromIndex|0;var k=Math.max(n>=0?n:len-Math.abs(n),0);function sameValueZero(x,y){return x===y||(typeof x==='number'&&typeof y==='number'&&isNaN(x)&&isNaN(y));} while(k()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;return re.test(email);} function getDomain(url){url=url.replace(/(https?:\/\/)?(www.)?/i,'');if(url.indexOf('/')!==-1){return url.split('/')[0];} return url;} function loadPixels(){if(!options.gdpr.all_disabled_by_api){if(!options.gdpr.facebook_disabled_by_api){Facebook.loadPixel();} if(!options.gdpr.analytics_disabled_by_api){Analytics.loadPixel();} if(!options.gdpr.pinterest_disabled_by_api){Pinterest.loadPixel();} if(!options.gdpr.bing_disabled_by_api){Bing.loadPixel();}} if(options.gdpr.consent_magic_integration_enabled&&typeof CS_Data!=="undefined"){if(typeof CS_Data.cs_google_analytics_consent_mode!=="undefined"&&CS_Data.cs_google_analytics_consent_mode==1){Analytics.loadPixel();}}} function checkSession(){if(Cookies.get('pys_start_session')===undefined||Cookies.get('pys_session_limit')===undefined){firstVisit=true;return true} return false} function getTrafficSource(){try{let referrer=document.referrer.toString(),source;let direct=referrer.length===0;let internal=direct?false:referrer.indexOf(options.siteUrl)===0;let external=!direct&&!internal;if(external===false){source='direct';}else{source=referrer;} if(source!=='direct'){return getDomain(source);}else{return source;}}catch(e){console.error(e);return'direct';}} function getQueryVars(){try{var result={},tmp=[];window.location.search.substr(1).split("&").forEach(function(item){tmp=item.split('=');if(tmp.length>1){result[tmp[0]]=tmp[1];}});return result;}catch(e){console.error(e);return{};}} function getLandingPageValue(){let name="pys_landing_page" if(options.visit_data_model==="last_visit"){name="last_pys_landing_page"} if(Cookies.get(name)&&Cookies.get(name)!=="undefined"){return Cookies.get(name);} else if(options.hasOwnProperty("tracking_analytics")&&options.tracking_analytics.TrafficLanding){return options.tracking_analytics.TrafficLanding;}else{return"";}} function getTrafficSourceValue(){let name="pysTrafficSource" if(options.visit_data_model==="last_visit"){name="last_pysTrafficSource"} if(Cookies.get(name)&&Cookies.get(name)!=="undefined"){return Cookies.get(name);} else if(options.hasOwnProperty("tracking_analytics")&&options.tracking_analytics.TrafficSource){return options.tracking_analytics.TrafficSource;}else{return"";}} function getUTMId(useLast=false){try{let cookiePrefix='pys_' let terms=[];if(useLast){cookiePrefix='last_pys_'} $.each(utmId,function(index,name){if(Cookies.get(cookiePrefix+name)){terms[name]=Cookies.get(cookiePrefix+name)} else if(options.hasOwnProperty("tracking_analytics")&&options.tracking_analytics.TrafficUtmsId[name]){terms[name]=filterEmails(options.tracking_analytics.TrafficUtmsId[name])}});return terms;}catch(e){console.error(e);return[];}} function getUTMs(useLast=false){try{let cookiePrefix='pys_' if(useLast){cookiePrefix='last_pys_'} let terms=[];$.each(utmTerms,function(index,name){if(Cookies.get(cookiePrefix+name)){let value=Cookies.get(cookiePrefix+name);terms[name]=filterEmails(value);} else if(options.hasOwnProperty("tracking_analytics")&&options.tracking_analytics.TrafficUtms[name]){terms[name]=filterEmails(options.tracking_analytics.TrafficUtms[name])}});return terms;}catch(e){console.error(e);return[];}} function getDateTime(){var dateTime=new Array();var date=new Date(),days=['Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday'],months=['January','February','March','April','May','June','July','August','September','October','November','December'],hours=['00-01','01-02','02-03','03-04','04-05','05-06','06-07','07-08','08-09','09-10','10-11','11-12','12-13','13-14','14-15','15-16','16-17','17-18','18-19','19-20','20-21','21-22','22-23','23-24'];dateTime.push(hours[date.getHours()]);dateTime.push(days[date.getDay()]);dateTime.push(months[date.getMonth()]);return dateTime;} function filterEmails(value){return validateEmail(value)?undefined:value;} return{PRODUCT_SIMPLE:0,PRODUCT_VARIABLE:1,PRODUCT_BUNDLE:2,PRODUCT_GROUPED:3,utmTerms:utmTerms,utmId:utmId,fireEventForAllPixel:function(functionName,events){if(events.hasOwnProperty(Facebook.tag())) Facebook[functionName](events[Facebook.tag()]);if(events.hasOwnProperty(Analytics.tag())) Analytics[functionName](events[Analytics.tag()]);if(events.hasOwnProperty(Pinterest.tag())) Pinterest[functionName](events[Pinterest.tag()]);if(events.hasOwnProperty(Bing.tag())) Bing[functionName](events[Bing.tag()]);},setupPinterestObject:function(){Pinterest=window.pys.Pinterest||Pinterest;return Pinterest;},setupBingObject:function(){Bing=window.pys.Bing||Bing;return Bing;},copyProperties:function(from,to){for(var key in from){if("function"==typeof from[key]){continue;} to[key]=from[key];} return to;},manageCookies:function(){if(options.gdpr.cookiebot_integration_enabled&&typeof Cookiebot!=='undefined'){if(Cookiebot.consented===false&&!Cookiebot.consent['marketing']&&!Cookiebot.consent['statistics']){return;}} let cm_consent_not_expressed=false;if(options.gdpr.consent_magic_integration_enabled&&window.CS_Data!==undefined&&window.CS_Data.cs_refresh_after_consent==1){if(Cookies.get('cs_viewed_cookie_policy')===undefined){cm_consent_not_expressed=true;}} if(!cm_consent_not_expressed&&isNewSession&&!options.cookie.disabled_all_cookie&&!options.cookie.disabled_start_session_cookie){let duration=options.last_visit_duration*60000 var now=new Date();now.setTime(now.getTime()+duration);Cookies.set('pys_session_limit',true,{expires:now}) Cookies.set('pys_start_session',true);} if(options.gdpr.ajax_enabled&&!options.gdpr.consent_magic_integration_enabled){$.get({url:options.ajaxUrl,dataType:'json',data:{action:'pys_get_gdpr_filters_values'},success:function(res){if(res.success){options.gdpr.all_disabled_by_api=res.data.all_disabled_by_api;options.gdpr.facebook_disabled_by_api=res.data.facebook_disabled_by_api;options.gdpr.tiktok_disabled_by_api=res.data.tiktok_disabled_by_api;options.gdpr.analytics_disabled_by_api=res.data.analytics_disabled_by_api;options.gdpr.google_ads_disabled_by_api=res.data.google_ads_disabled_by_api;options.gdpr.pinterest_disabled_by_api=res.data.pinterest_disabled_by_api;options.gdpr.bing_disabled_by_api=res.data.bing_disabled_by_api;options.cookie.externalID_disabled_by_api=res.data.externalID_disabled_by_api;options.cookie.disabled_all_cookie=res.data.disabled_all_cookie;options.cookie.disabled_advanced_form_data_cookie=res.data.disabled_advanced_form_data_cookie;options.cookie.disabled_landing_page_cookie=res.data.disabled_landing_page_cookie;options.cookie.disabled_first_visit_cookie=res.data.disabled_first_visit_cookie;options.cookie.disabled_trafficsource_cookie=res.data.disabled_trafficsource_cookie;options.cookie.disabled_utmTerms_cookie=res.data.disabled_utmTerms_cookie;options.cookie.disabled_utmId_cookie=res.data.disabled_utmId_cookie;}}});} if(options.ajaxForServerEvent&&!Cookies.get('pbid')){if(Facebook.advancedMatching()&&Facebook.advancedMatching().external_id&&!(options.cookie.disabled_all_cookie||options.cookie.externalID_disabled_by_api)){let expires=parseInt(options.external_id_expire||180);Cookies.set('pbid',Facebook.advancedMatching().external_id,{expires:expires,path:'/'});} else{jQuery.ajax({url:options.ajaxUrl,dataType:'json',data:{action:'pys_get_pbid'},success:function(res){if(res.data&&res.data.pbid!=false&&options.send_external_id){if(!(options.cookie.disabled_all_cookie||options.cookie.externalID_disabled_by_api)){var expires=parseInt(options.external_id_expire||180);Cookies.set('pbid',res.data.pbid,{expires:expires,path:'/'});} if(options.hasOwnProperty('facebook')){options.facebook.advancedMatching={...options.facebook.advancedMatching,external_id:res.data.pbid};}}}});}} let expires=parseInt(options.cookie_duration);let queryVars=getQueryVars();let landing=window.location.href.split('?')[0];try{if(Cookies.get('pys_first_visit')===undefined&&(!options.cookie.disabled_all_cookie)){if(!options.cookie.disabled_first_visit_cookie) {Cookies.set('pys_first_visit',true,{expires:expires});} else{Cookies.remove('pys_first_visit')} if(!options.cookie.disabled_trafficsource_cookie) {Cookies.set('pysTrafficSource',getTrafficSource(),{expires:expires});} else{Cookies.remove('pysTrafficSource')} if(!options.cookie.disabled_landing_page_cookie) {Cookies.set('pys_landing_page',landing,{expires:expires});} else{Cookies.remove('pys_landing_page')} if(!options.cookie.disabled_utmTerms_cookie) {$.each(utmTerms,function(index,name){if(queryVars.hasOwnProperty(name)){Cookies.set('pys_'+name,queryVars[name],{expires:expires});}else{Cookies.remove('pys_'+name)}});} else{$.each(utmTerms,function(index,name){Cookies.remove('pys_'+name)});} if(!options.cookie.disabled_utmId_cookie) {$.each(utmId,function(index,name){if(queryVars.hasOwnProperty(name)){Cookies.set('pys_'+name,queryVars[name],{expires:expires});}else{Cookies.remove('pys_'+name)}})} else{$.each(utmId,function(index,name){Cookies.remove('pys_'+name)});}} if(isNewSession&&(!options.cookie.disabled_all_cookie)){if(!options.cookie.disabled_trafficsource_cookie) {Cookies.set('last_pysTrafficSource',getTrafficSource(),{expires:expires});} else{Cookies.remove('last_pysTrafficSource')} if(!options.cookie.disabled_landing_page_cookie) {Cookies.set('last_pys_landing_page',landing,{expires:expires});} else{Cookies.remove('last_pys_landing_page')} if(!options.cookie.disabled_utmTerms_cookie) {$.each(utmTerms,function(index,name){if(queryVars.hasOwnProperty(name)){Cookies.set('last_pys_'+name,queryVars[name],{expires:expires});}else{Cookies.remove('last_pys_'+name)}});} else{$.each(utmTerms,function(index,name){Cookies.remove('last_pys_'+name)});} if(!options.cookie.disabled_utmId_cookie) {$.each(utmId,function(index,name){if(queryVars.hasOwnProperty(name)){Cookies.set('last_pys_'+name,queryVars[name],{expires:expires});}else{Cookies.remove('last_pys_'+name)}})} else{$.each(utmId,function(index,name){Cookies.remove('last_pys_'+name)});}} if(options.cookie.disabled_start_session_cookie){Cookies.remove('pys_start_session') Cookies.remove('pys_session_limit')} if(options.cookie.disabled_all_cookie) {Cookies.remove('pys_first_visit') Cookies.remove('pysTrafficSource') Cookies.remove('pys_landing_page') Cookies.remove('last_pys_landing_page') Cookies.remove('last_pysTrafficSource') Cookies.remove('pys_start_session') Cookies.remove('pys_session_limit') $.each(Utils.utmTerms,function(index,name){Cookies.remove('pys_'+name)});$.each(Utils.utmId,function(index,name){Cookies.remove('pys_'+name)}) $.each(Utils.utmTerms,function(index,name){Cookies.remove('last_pys_'+name)});$.each(Utils.utmId,function(index,name){Cookies.remove('last_pys_'+name)});}}catch(e){console.error(e);}},clone:function(obj){var copy;if(null==obj||"object"!=typeof obj)return obj;if(obj instanceof Date){copy=new Date();copy.setTime(obj.getTime());return copy;} if(obj instanceof Array){copy=[];for(var i=0,len=obj.length;i0&&link.indexOf('.')!==-1){link=link.substring(link.indexOf(".")+1);return link;}else{return"";}},getLinkFilename:function(link){link=link.substring(0,(link.indexOf("#")===-1)?link.length:link.indexOf("#"));link=link.substring(0,(link.indexOf("?")===-1)?link.length:link.indexOf("?"));link=link.substring(link.lastIndexOf("/")+1,link.length);if(link.length>0&&link.indexOf('.')!==-1){return link;}else{return"";}},isCheckoutPage:function(){return $('body').hasClass('woocommerce-checkout')||document.querySelector('.woocommerce-checkout')||$('body').hasClass('edd-checkout');},addCheckoutFields:function(){var utm="";var utms=getUTMs() $.each(utmTerms,function(index,name){if(index>0){utm+="|";} utm+=name+":"+utms[name];});var utmIdList="";var utmsIds=getUTMId() $.each(utmId,function(index,name){if(index>0){utmIdList+="|";} utmIdList+=name+":"+utmsIds[name];});var utmIdListLast="";var utmsIdsLast=getUTMId(true) $.each(utmId,function(index,name){if(index>0){utmIdListLast+="|";} utmIdListLast+=name+":"+utmsIdsLast[name];});var utmLast="";var utmsLast=getUTMs(true) $.each(utmTerms,function(index,name){if(index>0){utmLast+="|";} utmLast+=name+":"+utmsLast[name];});var dateTime=getDateTime();var landing=getLandingPageValue();var lastLanding=getLandingPageValue();var trafic=getTrafficSourceValue();var lastTrafic=getTrafficSourceValue();var $form=null;if($('body').hasClass('woocommerce-checkout')){$form=$("form.woocommerce-checkout");}else{$form=$("#edd_purchase_form");} var inputs={'pys_utm':utm,'pys_utm_id':utmIdList,'pys_browser_time':dateTime.join("|"),'pys_landing':landing,'pys_source':trafic,'pys_order_type':$(".wcf-optin-form").length>0?"wcf-optin":"normal",'last_pys_landing':lastLanding,'last_pys_source':lastTrafic,'last_pys_utm':utmLast,'last_pys_utm_id':utmIdListLast,} Object.keys(inputs).forEach(function(key,index){$form.append(" ");});},getAdvancedFormData:function(){let dataStr=Cookies.get("pys_advanced_form_data");if(dataStr===undefined){return{'first_name':"",'last_name':"",'email':"",'phone':""};}else{return JSON.parse(dataStr);}}};}(options);var Facebook=function(options){var defaultEventTypes=['PageView','ViewContent','Search','AddToCart','AddToWishlist','InitiateCheckout','AddPaymentInfo','Purchase','Lead','Subscribe','CustomizeProduct','FindLocation','StartTrial','SubmitApplication','Schedule','Contact','Donate'];var initialized=false;var genereateFbp=function(){return!Cookies.get('_fbp')?'fb.1.'+Date.now()+'.'+Math.floor(1000000000+Math.random()*9000000000):Cookies.get('_fbp');};var genereateFbc=function(){return getUrlParameter('fbclid')?'fb.1.'+Date.now()+'.'+getUrlParameter('fbclid'):''};var isApiDisabled=options.gdpr.all_disabled_by_api||options.gdpr.facebook_disabled_by_api||options.gdpr.cookiebot_integration_enabled||options.gdpr.consent_magic_integration_enabled||options.gdpr.cookie_notice_integration_enabled||options.gdpr.cookie_law_info_integration_enabled;function sendFbServerEvent(allData,name,params){let eventId=null;if(options.facebook.serverApiEnabled){if(allData.e_id==="woo_remove_from_cart"){Facebook.updateEventId(allData.name);allData.eventID=Facebook.getEventId(allData.name);}else{if(options.ajaxForServerEvent||isApiDisabled||allData.delay>0||allData.type!=="static") {allData.eventID=pys_generate_token(36);var json={action:'pys_api_event',pixel:'facebook',event:name,data:params,ids:options.facebook.pixelIds,eventID:allData.eventID,url:window.location.href,ajax_event:options.ajax_event};if(allData.hasOwnProperty('woo_order')){json['woo_order']=allData.woo_order;} if(allData.hasOwnProperty('edd_order')){json['edd_order']=allData.edd_order;} if(name=='PageView'){let expires=parseInt(options.cookie_duration);timeoutDelay=0;if(allData.delay>0) {timeoutDelay=allData.delay;} if(!Cookies.get('_fbp')) {timeoutDelay=100;} if(getUrlParameter('fbclid')&&!Cookies.get('_fbc')) {timeoutDelay=100;} setTimeout(function(){if(!Cookies.get('_fbp')) {Cookies.set('_fbp',genereateFbp(),{expires:expires});json['data']['_fbp']=genereateFbp();} if(getUrlParameter('fbclid')&&!Cookies.get('_fbc')) {Cookies.set('_fbc',genereateFbc(),{expires:expires});json['data']['_fbc']=genereateFbc();} jQuery.ajax({type:'POST',url:options.ajaxUrl,data:json,headers:{'Cache-Control':'no-cache'},success:function(){},});},timeoutDelay)} else {jQuery.ajax({type:'POST',url:options.ajaxUrl,data:json,headers:{'Cache-Control':'no-cache'},success:function(){},});}}} eventId=allData.eventID} return eventId;} function fireEvent(name,allData){if(typeof window.pys_event_data_filter==="function"&&window.pys_disable_event_filter(name,'facebook')){return;} var actionType=defaultEventTypes.includes(name)?'track':'trackCustom';var data=allData.params;var params={};var arg={};Utils.copyProperties(data,params);let eventId=sendFbServerEvent(allData,name,params) if("hCR"===name){return;} if(options.debug){console.log('[Facebook] '+name,params,"eventID",eventId);} if(eventId!=null){arg.eventID=eventId;} if(name=='PageView'){fbq(actionType,name,data,arg);} else{fbq(actionType,name,params,arg);}} return{tag:function(){return"facebook";},isEnabled:function(){return options.hasOwnProperty('facebook');},disable:function(){initialized=false;},advancedMatching:function(){if(options.facebook.advancedMatchingEnabled){let advancedMatchingForm=Utils.getAdvancedFormData();let advancedMatching={};if(Object.keys(options.facebook.advancedMatching).length>0){advancedMatching=options.facebook.advancedMatching;} if(!advancedMatching.hasOwnProperty("em")&&advancedMatchingForm.hasOwnProperty("email")&&advancedMatchingForm["email"].length>0){advancedMatching["em"]=advancedMatchingForm["email"];} if(!advancedMatching.hasOwnProperty("ph")&&advancedMatchingForm.hasOwnProperty("phone")&&advancedMatchingForm["phone"].length>0){advancedMatching["ph"]=advancedMatchingForm["phone"];} if(!advancedMatching.hasOwnProperty("fn")&&advancedMatchingForm.hasOwnProperty("first_name")&&advancedMatchingForm["first_name"].length>0){advancedMatching["fn"]=advancedMatchingForm["first_name"];} if(!advancedMatching.hasOwnProperty("ln")&&advancedMatchingForm.hasOwnProperty("last_name")&&advancedMatchingForm["last_name"].length>0){advancedMatching["ln"]=advancedMatchingForm["last_name"];} if(!advancedMatching.hasOwnProperty("external_id")){if(Cookies.get('pbid')||(options.hasOwnProperty('pbid')&&options.pbid)){advancedMatching["external_id"]=Cookies.get('pbid')?Cookies.get('pbid'):options.pbid;}} else if(advancedMatching.external_id!=Cookies.get('pbid')) {advancedMatching["external_id"]=Cookies.get('pbid')?Cookies.get('pbid'):advancedMatching.external_id;} if(Object.keys(advancedMatching).length>0){return advancedMatching;}} return false},loadPixel:function(){if(initialized||!this.isEnabled()||!Utils.consentGiven('facebook')){return;} !function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod?n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';n.agent='dvpixelyoursite';n.queue=[];t=b.createElement(e);t.async=!0;t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window,document,'script','https://connect.facebook.net/en_US/fbevents.js');options.facebook.pixelIds.forEach(function(pixelId){if(options.facebook.removeMetadata){fbq('set','autoConfig',false,pixelId);} let advancedMatching=Facebook.advancedMatching();if(options.gdpr.consent_magic_integration_enabled&&typeof CS_Data!=="undefined"){if(!advancedMatching){fbq('init',pixelId);}else{var test_prefix=CS_Data.test_prefix;var cs_advanced_matching=Cookies.get('cs_enabled_advanced_matching'+test_prefix);if(jQuery('#cs_enabled_advanced_matching'+test_prefix).length>0){if(cs_advanced_matching=='yes'){fbq('init',pixelId,advancedMatching);}else{fbq('init',pixelId);}}else{fbq('init',pixelId,advancedMatching);}}}else{if(!advancedMatching){fbq('init',pixelId);}else{fbq('init',pixelId,advancedMatching);}}});initialized=true;Utils.fireStaticEvents('facebook');},fireEvent:function(name,data){if(!initialized||!this.isEnabled()){return false;} data.delay=data.delay||0;data.params=data.params||{};if(data.delay===0){fireEvent(name,data);}else{setTimeout(function(name,params){fireEvent(name,params);},data.delay*1000,name,data);} return true;},onCommentEvent:function(event){this.fireEvent(event.name,event);},onDownloadEvent:function(event){this.fireEvent(event.name,event);},onFormEvent:function(event){this.fireEvent(event.name,event);},onWooAddToCartOnButtonEvent:function(product_id){if(!options.dynamicEvents.woo_add_to_cart_on_button_click.hasOwnProperty(this.tag())) return;var event=options.dynamicEvents.woo_add_to_cart_on_button_click[this.tag()];if(window.pysWooProductData.hasOwnProperty(product_id)){if(window.pysWooProductData[product_id].hasOwnProperty('facebook')){event=Utils.copyProperties(event,{}) Utils.copyProperties(window.pysWooProductData[product_id]['facebook'].params,event.params) this.fireEvent(event.name,event);}}},onWooAddToCartOnSingleEvent:function(product_id,qty,product_type,$form){window.pysWooProductData=window.pysWooProductData||[];if(!options.dynamicEvents.woo_add_to_cart_on_button_click.hasOwnProperty(this.tag())) return;var event=Utils.clone(options.dynamicEvents.woo_add_to_cart_on_button_click[this.tag()]);if(product_type===Utils.PRODUCT_VARIABLE&&!options.facebook.wooVariableAsSimple){product_id=parseInt($form.find('input[name="variation_id"]').val());} if(window.pysWooProductData.hasOwnProperty(product_id)){if(window.pysWooProductData[product_id].hasOwnProperty('facebook')){Utils.copyProperties(window.pysWooProductData[product_id]['facebook'].params,event.params);var groupValue=0;if(product_type===Utils.PRODUCT_GROUPED){$form.find(".woocommerce-grouped-product-list .qty").each(function(index){var childId=$(this).attr('name').replaceAll("quantity[","").replaceAll("]","");var quantity=parseInt($(this).val());if(isNaN(quantity)){quantity=0;} var childItem=window.pysWooProductData[product_id]['facebook'].grouped[childId];if(quantity==0){event.params.content_ids.forEach(function(el,index,array){if(el==childItem.content_id){array.splice(index,1);}});} if(event.params.hasOwnProperty('contents')){event.params.contents.forEach(function(el,index,array){if(el.id==childItem.content_id){if(quantity>0){el.quantity=quantity;}else{array.splice(index,1);}}});} groupValue+=childItem.price*quantity;});if(groupValue==0)return;} if(options.woo.addToCartOnButtonValueEnabled&&options.woo.addToCartOnButtonValueOption!=='global'){if(product_type===Utils.PRODUCT_GROUPED){event.params.value=groupValue;}else if(product_type===Utils.PRODUCT_BUNDLE){var data=$(".bundle_form .bundle_data").data("bundle_form_data");var items_sum=getBundlePriceOnSingleProduct(data);event.params.value=(parseInt(data.base_price)+items_sum)*qty;}else{event.params.value=event.params.value*qty;}} if(event.params.hasOwnProperty('contents')&&product_type!==Utils.PRODUCT_GROUPED){event.params.contents[0].quantity=qty;} this.fireEvent(event.name,event);}}},onWooRemoveFromCartEvent:function(event){this.fireEvent(event.name,event);},onEddAddToCartOnButtonEvent:function(download_id,price_index,qty){if(!options.dynamicEvents.edd_add_to_cart_on_button_click.hasOwnProperty(this.tag())) return;var event=Utils.clone(options.dynamicEvents.edd_add_to_cart_on_button_click[this.tag()]);if(window.pysEddProductData.hasOwnProperty(download_id)){var index;if(price_index){index=download_id+'_'+price_index;}else{index=download_id;} if(window.pysEddProductData[download_id].hasOwnProperty(index)){if(window.pysEddProductData[download_id][index].hasOwnProperty('facebook')){Utils.copyProperties(window.pysEddProductData[download_id][index]['facebook']["params"],event.params) if(options.edd.addToCartOnButtonValueEnabled&&options.edd.addToCartOnButtonValueOption!=='global'){event.params.value=event.params.value*qty;} var contents=event.params.contents;contents[0].quantity=qty;event.params.contents=contents;this.fireEvent(event.name,event);}}}},onEddRemoveFromCartEvent:function(event){this.fireEvent(event.name,event);},onPageScroll:function(event){this.fireEvent(event.name,event);},onTime:function(event){this.fireEvent(event.name,event);},initEventIdCookies:function(key){var ids={};ids[key]=pys_generate_token(36) Cookies.set('pys_fb_event_id',JSON.stringify(ids));},updateEventId:function(key){var cooData=Cookies.get("pys_fb_event_id") if(cooData===undefined){this.initEventIdCookies(key);}else{var data=JSON.parse(cooData);data[key]=pys_generate_token(36);Cookies.set('pys_fb_event_id',JSON.stringify(data));}},getEventId:function(key){var data=Cookies.get("pys_fb_event_id");if(data===undefined){this.initEventIdCookies(key);data=Cookies.get("pys_fb_event_id");} return JSON.parse(data)[key];},};}(options);var Analytics=function(options){var initialized=false;function fireEvent(name,data){if(typeof window.pys_event_data_filter==="function"&&window.pys_disable_event_filter(name,'ga')){return;} var eventParams=Utils.copyProperties(data,{});var _fireEvent=function(tracking_id,name,params){params['send_to']=tracking_id;if(options.debug){console.log('[Google Analytics #'+tracking_id+'] '+name,params);} gtag('event',name,params);};options.ga.trackingIds.forEach(function(tracking_id){var copyParams=Utils.copyProperties(eventParams,{});var params=mapParamsTov4(tracking_id,name,copyParams) _fireEvent(tracking_id,name,params);});} function mapParamsTov4(tag,name,param){delete param.landing_page;if(isv4(tag)){delete param.traffic_source;delete param.event_category;delete param.event_label;delete param.ecomm_prodid;delete param.ecomm_pagetype;delete param.ecomm_totalvalue;if(name==='search'){param['search']=param.search_term;delete param.search_term;delete param.dynx_itemid;delete param.dynx_pagetype;delete param.dynx_totalvalue;}} return param;} function isv4(tag){return tag.indexOf('G')===0;} return{tag:function(){return"ga";},isEnabled:function(){return options.hasOwnProperty('ga');},disable:function(){initialized=false;},loadPixel:function(){if(initialized||!this.isEnabled()||!Utils.consentGiven('analytics')){return;} Utils.loadGoogleTag(options.ga.trackingIds[0]);var config={};if(options.ga.crossDomainEnabled){config.linker={accept_incoming:options.ga.crossDomainAcceptIncoming,domains:options.ga.crossDomainDomains};} options.ga.trackingIds.forEach(function(trackingId,index){var obj=options.ga.isDebugEnabled;var searchValue="index_"+index;config.debug_mode=false;for(var key in obj){if(obj.hasOwnProperty(key)&&obj[key]===searchValue){config.debug_mode=true;break;}} if(!config.debug_mode) {delete config.debug_mode;} if(isv4(trackingId)){if(options.ga.disableAdvertisingFeatures){config.allow_google_signals=false} if(options.ga.disableAdvertisingPersonalization){config.allow_ad_personalization_signals=false}} if(options.gdpr.cookiebot_integration_enabled&&typeof Cookiebot!=='undefined'){var cookiebot_consent_category=options.gdpr['cookiebot_analytics_consent_category'];if(options.gdpr['analytics_prior_consent_enabled']){if(Cookiebot.consented===true&&Cookiebot.consent[cookiebot_consent_category]){gtag('config',trackingId,config);}}else{if(Cookiebot.consent[cookiebot_consent_category]){gtag('config',trackingId,config);}}} else {gtag('config',trackingId,config);}});initialized=true;Utils.fireStaticEvents('ga');},fireEvent:function(name,data){if(!initialized||!this.isEnabled()){return false;} data.delay=data.delay||0;data.params=data.params||{};if(data.delay===0){fireEvent(name,data.params);}else{setTimeout(function(name,params){fireEvent(name,params);},data.delay*1000,name,data.params);} return true;},onCommentEvent:function(event){this.fireEvent(event.name,event);},onDownloadEvent:function(event){this.fireEvent(event.name,event);},onFormEvent:function(event){this.fireEvent(event.name,event);},onWooAddToCartOnButtonEvent:function(product_id){if(!options.dynamicEvents.woo_add_to_cart_on_button_click.hasOwnProperty(this.tag())) return;var event=Utils.clone(options.dynamicEvents.woo_add_to_cart_on_button_click[this.tag()]);if(window.pysWooProductData.hasOwnProperty(product_id)){if(window.pysWooProductData[product_id].hasOwnProperty('ga')){Utils.copyProperties(window.pysWooProductData[product_id]['ga'].params,event.params) this.fireEvent(event.name,event);}}},onWooAddToCartOnSingleEvent:function(product_id,qty,product_type,$form){window.pysWooProductData=window.pysWooProductData||[];if(!options.dynamicEvents.woo_add_to_cart_on_button_click.hasOwnProperty(this.tag())) return;var event=Utils.clone(options.dynamicEvents.woo_add_to_cart_on_button_click[this.tag()]);if(product_type===Utils.PRODUCT_VARIABLE&&!options.ga.wooVariableAsSimple){product_id=parseInt($form.find('input[name="variation_id"]').val());} if(window.pysWooProductData.hasOwnProperty(product_id)){if(window.pysWooProductData[product_id].hasOwnProperty('ga')){Utils.copyProperties(window.pysWooProductData[product_id]['ga'].params,event.params);if(product_type===Utils.PRODUCT_GROUPED){var groupValue=0;$form.find(".woocommerce-grouped-product-list .qty").each(function(index){var childId=$(this).attr('name').replaceAll("quantity[","").replaceAll("]","");var quantity=parseInt($(this).val());if(isNaN(quantity)){quantity=0;} var childItem=window.pysWooProductData[product_id]['ga'].grouped[childId];event.params.items.forEach(function(el,index,array){if(el.id==childItem.content_id){if(quantity>0){el.quantity=quantity;}else{array.splice(index,1);}}});groupValue+=childItem.price*quantity;});if(options.woo.addToCartOnButtonValueEnabled&&options.woo.addToCartOnButtonValueOption!=='global'&&event.params.hasOwnProperty('ecomm_totalvalue')){event.params.ecomm_totalvalue=groupValue;} if(groupValue==0)return;}else{event.params.items[0].quantity=qty;} if(options.woo.addToCartOnButtonValueEnabled&&options.woo.addToCartOnButtonValueOption!=='global'&&product_type!==Utils.PRODUCT_GROUPED) {if(event.params.hasOwnProperty('ecomm_totalvalue')){event.params.ecomm_totalvalue=event.params.items[0].price*qty;}} this.fireEvent(event.name,event);}}},onWooRemoveFromCartEvent:function(event){this.fireEvent(event.name,event);},onEddAddToCartOnButtonEvent:function(download_id,price_index,qty){if(!options.dynamicEvents.edd_add_to_cart_on_button_click.hasOwnProperty(this.tag())) return;var event=Utils.clone(options.dynamicEvents.edd_add_to_cart_on_button_click[this.tag()]);if(window.pysEddProductData.hasOwnProperty(download_id)){var index;if(price_index){index=download_id+'_'+price_index;}else{index=download_id;} if(window.pysEddProductData[download_id].hasOwnProperty(index)){if(window.pysEddProductData[download_id][index].hasOwnProperty('ga')){Utils.copyProperties(window.pysEddProductData[download_id][index]['ga'].params,event.params);event.params.items[0].quantity=qty;this.fireEvent(event.name,event);}}}},onEddRemoveFromCartEvent:function(event){this.fireEvent(event.name,event);},onPageScroll:function(event){this.fireEvent(event.name,event);},onTime:function(event){this.fireEvent(event.name,event);},};}(options);window.pys=window.pys||{};window.pys.Facebook=Facebook;window.pys.Analytics=Analytics;window.pys.Utils=Utils;$(document).ready(function(){if($("#pys_late_event").length>0){var events=JSON.parse($("#pys_late_event").attr("dir"));for(var key in events){var event={};event[events[key].e_id]=[events[key]];if(options.staticEvents.hasOwnProperty(key)){Object.assign(options.staticEvents[key],event);}else{options.staticEvents[key]=event;}}} var Pinterest=Utils.setupPinterestObject();var Bing=Utils.setupBingObject();if(options.hasOwnProperty('cookie')) {if(options.cookie.externalID_disabled_by_api||options.cookie.disabled_all_cookie) {Cookies.remove('pbid')} if(options.cookie.disabled_advanced_form_data_cookie||options.cookie.disabled_all_cookie) {Cookies.remove('pys_advanced_form_data')} if(options.cookie.disabled_landing_page_cookie||options.cookie.disabled_all_cookie) {Cookies.remove('pys_landing_page') Cookies.remove('last_pys_landing_page')} if(options.cookie.disabled_trafficsource_cookie||options.cookie.disabled_all_cookie) {Cookies.remove('pysTrafficSource') Cookies.remove('last_pysTrafficSource')} if(options.cookie.disabled_first_visit_cookie||options.cookie.disabled_all_cookie) {Cookies.remove('pys_first_visit')} if(options.cookie.disabled_utmTerms_cookie||options.cookie.disabled_all_cookie) {$.each(Utils.utmTerms,function(index,name){Cookies.remove('pys_'+name)});$.each(Utils.utmTerms,function(index,name){Cookies.remove('last_pys_'+name)});} if(options.cookie.disabled_utmId_cookie||options.cookie.disabled_all_cookie) {$.each(Utils.utmId,function(index,name){Cookies.remove('pys_'+name)}) $.each(Utils.utmId,function(index,name){Cookies.remove('last_pys_'+name)});}} if(options.gdpr.cookie_law_info_integration_enabled){var cli_cookie=Cookies.get('cookieyes-consent')??Cookies.get('viewed_cookie_policy');if(typeof cli_cookie!=='undefined'){if(cli_cookie===Cookies.get('cookieyes-consent')&&getCookieYes('analytics')=='yes'){Utils.manageCookies();}else if(cli_cookie===Cookies.get('viewed_cookie_policy')&&cli_cookie=='yes'){Utils.manageCookies();}}} else {Utils.manageCookies();} Utils.setupGdprCallbacks();if(options.dynamicEvents.hasOwnProperty("automatic_event_scroll")){var singlePageScroll=function(){var docHeight=$(document).height()-$(window).height();var isFired=false;if(options.dynamicEvents.hasOwnProperty("automatic_event_scroll")){var pixels=Object.keys(options.dynamicEvents.automatic_event_scroll);for(var i=0;i0){if(options.dynamicEvents.hasOwnProperty("automatic_event_download")){var pixels=Object.keys(options.dynamicEvents.automatic_event_download);for(var i=0;i{var form_id=$(event.target).attr('data-formid');sendFormAction($(event.target),form_id);}) $(document).on('frmFormComplete',function(event,form,response){const form_id=$(form).find('input[name="form_id"]').val();sendFormAction($(event.target),form_id);});$(document).onFirst('nfFormSubmitResponse',function(event,data){const form_id=data.response.data.form_id;sendFormAction($(event.target),form_id);});var fluentForms=$('form.frm-fluent-form');fluentForms.each(function(){var $form=$(this);$form.on('fluentform_submission_success',function(event){var $formItem=$(this);var form_id=$formItem.attr('data-form_id');sendFormAction($(event.target),form_id);});});} Utils.loadPixels();if(Utils.isCheckoutPage()){Utils.addCheckoutFields();}});var sendFormAction=function(form_target,formId){var params={form_id:formId,text:form_target.find('[type="submit"]').is('input')?form_target.find('[type="submit"]').val():form_target.find('.forminator-button-submit').text()!=''?form_target.find('.forminator-button-submit').text():form_target.find('[type="submit"]').text()};if(options.dynamicEvents.hasOwnProperty("automatic_event_form")){var pixels=Object.keys(options.dynamicEvents.automatic_event_form);for(var i=0;iObject.assign(ac,{[cv.split("=")[0].trim()]:cv.split("=")[1]}),{})["cookieyes-consent"];const{[key]:value}=cookies.split(",").reduce((obj,pair)=>((pair=pair.split(":")),(obj[pair[0]]=pair[1]),obj),{});return value;}; let WP_Statistics_CheckTime=60000;let WP_Statistics_Dnd_Active=parseInt(navigator.msDoNotTrack||window.doNotTrack||navigator.doNotTrack,10);let wpStatisticsUserOnline={init:function(){if(typeof WP_Statistics_Tracker_Object=="undefined"){console.log('Variable WP_Statistics_Tracker_Object not found on the page source. Please ensure that you have excluded the /wp-content/plugins/wp-statistics/assets/js/tracker.js file from your cache and then clear your cache.');}else{this.checkHitRequestConditions();this.keepUserOnline();}},checkHitRequestConditions:function(){if(WP_Statistics_Tracker_Object.option.cacheCompatibility){if(WP_Statistics_Tracker_Object.option.dntEnabled){if(WP_Statistics_Dnd_Active!==1){this.sendHitRequest();}}else{this.sendHitRequest();}}},sendHitRequest:async function(){try{const referred=encodeURIComponent(document.referrer);const timestamp=Date.now();const requestUrl=`${WP_Statistics_Tracker_Object.hitRequestUrl}&referred=${referred}&_=${timestamp}`;const response=await fetch(requestUrl,{method:'GET',headers:{'Content-Type':'application/json;charset=UTF-8',},});if(!response.ok){console.error('Hit request failed!');}}catch(error){console.error('An error occurred on sending hit request:',error);}},sendOnlineUserRequest:function(){var WP_Statistics_http=new XMLHttpRequest();WP_Statistics_http.open("GET",WP_Statistics_Tracker_Object.keepOnlineRequestUrl);WP_Statistics_http.setRequestHeader("Content-Type","application/json;charset=UTF-8");WP_Statistics_http.send(null);},keepUserOnline:function(){setInterval(function(){if(!document.hidden){if(WP_Statistics_Tracker_Object.option.dntEnabled){if(WP_Statistics_Dnd_Active!==1){this.sendOnlineUserRequest();}}else{this.sendOnlineUserRequest();}}}.bind(this),WP_Statistics_CheckTime);},};document.addEventListener('DOMContentLoaded',function(){wpStatisticsUserOnline.init();}); (function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId]){return installedModules[moduleId].exports;} var module=installedModules[moduleId]={i:moduleId,l:false,exports:{}};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.l=true;return module.exports;} __webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.d=function(exports,name,getter){if(!__webpack_require__.o(exports,name)){Object.defineProperty(exports,name,{configurable:false,enumerable:true,get:getter});}};__webpack_require__.n=function(module){var getter=module&&module.__esModule?function getDefault(){return module['default'];}:function getModuleExports(){return module;};__webpack_require__.d(getter,'a',getter);return getter;};__webpack_require__.o=function(object,property){return Object.prototype.hasOwnProperty.call(object,property);};__webpack_require__.p="/wp-content/themes/motofocusv2/dist/";return __webpack_require__(__webpack_require__.s=34);}) ([,(function(module,exports){function isObject(value){var type=typeof value;return value!=null&&(type=='object'||type=='function');} module.exports=isObject;}),(function(module,exports,__webpack_require__){var freeGlobal=__webpack_require__(12);var freeSelf=typeof self=='object'&&self&&self.Object===Object&&self;var root=freeGlobal||freeSelf||Function('return this')();module.exports=root;}),(function(module,exports,__webpack_require__){var root=__webpack_require__(2);var Symbol=root.Symbol;module.exports=Symbol;}),(function(module,exports,__webpack_require__){var isObject=__webpack_require__(1),now=__webpack_require__(11),toNumber=__webpack_require__(14);var FUNC_ERROR_TEXT='Expected a function';var nativeMax=Math.max,nativeMin=Math.min;function debounce(func,wait,options){var lastArgs,lastThis,maxWait,result,timerId,lastCallTime,lastInvokeTime=0,leading=false,maxing=false,trailing=true;if(typeof func!='function'){throw new TypeError(FUNC_ERROR_TEXT);} wait=toNumber(wait)||0;if(isObject(options)){leading=!!options.leading;maxing='maxWait'in options;maxWait=maxing?nativeMax(toNumber(options.maxWait)||0,wait):maxWait;trailing='trailing'in options?!!options.trailing:trailing;} function invokeFunc(time){var args=lastArgs,thisArg=lastThis;lastArgs=lastThis=undefined;lastInvokeTime=time;result=func.apply(thisArg,args);return result;} function leadingEdge(time){lastInvokeTime=time;timerId=setTimeout(timerExpired,wait);return leading?invokeFunc(time):result;} function remainingWait(time){var timeSinceLastCall=time-lastCallTime,timeSinceLastInvoke=time-lastInvokeTime,timeWaiting=wait-timeSinceLastCall;return maxing?nativeMin(timeWaiting,maxWait-timeSinceLastInvoke):timeWaiting;} function shouldInvoke(time){var timeSinceLastCall=time-lastCallTime,timeSinceLastInvoke=time-lastInvokeTime;return(lastCallTime===undefined||(timeSinceLastCall>=wait)||(timeSinceLastCall<0)||(maxing&&timeSinceLastInvoke>=maxWait));} function timerExpired(){var time=now();if(shouldInvoke(time)){return trailingEdge(time);} timerId=setTimeout(timerExpired,remainingWait(time));} function trailingEdge(time){timerId=undefined;if(trailing&&lastArgs){return invokeFunc(time);} lastArgs=lastThis=undefined;return result;} function cancel(){if(timerId!==undefined){clearTimeout(timerId);} lastInvokeTime=0;lastArgs=lastCallTime=lastThis=timerId=undefined;} function flush(){return timerId===undefined?result:trailingEdge(now());} function debounced(){var time=now(),isInvoking=shouldInvoke(time);lastArgs=arguments;lastThis=this;lastCallTime=time;if(isInvoking){if(timerId===undefined){return leadingEdge(lastCallTime);} if(maxing){timerId=setTimeout(timerExpired,wait);return invokeFunc(lastCallTime);}} if(timerId===undefined){timerId=setTimeout(timerExpired,wait);} return result;} debounced.cancel=cancel;debounced.flush=flush;return debounced;} module.exports=debounce;}),(function(module,__webpack_exports__,__webpack_require__){"use strict";__webpack_exports__["a"]=getCookie;function getCookie(cname){var name=cname+"=";var decodedCookie=decodeURIComponent(document.cookie);var ca=decodedCookie.split(';');for(var i=0;i li:first-child')){this.category_id=this.element.querySelector('ul > li:first-child').getAttribute('data-category');} this.target=this.element.querySelector('.dropdown-menu');return;}else if(!this.element.classList.contains('item-depth-1')&&!this.element.classList.contains('menu-item-has-children')){this.element.insertAdjacentHTML('beforeend','');this.target=this.element.querySelector('.dropdown-menu');}else if(this.element.classList.contains('item-depth-1')){this.target=this.element.parentElement.parentElement.parentElement.querySelector('.dropdown-menu');this.element.addEventListener('mouseover',this.show.bind(this));this.element.addEventListener('mouseout',this.hide.bind(this));this.show();}else{this.target=this.element.querySelector('.dropdown-menu');} this.call();} call(){this.target.classList.remove('loaded');let _this=this;const data=new FormData();data.append('action','load_posts_in_menu');data.append('category',this.category_id.toString());data.append('object',this.object);fetch('/wp-admin/admin-ajax.php',{method:'POST',body:data,}).then(response=>response.json()).then(data=>{_this.addHTML(data);}).catch((error)=>{console.error('Error:',error);});} addHTML(response){let template='';response.forEach(function(value,key){let img='';if(value.image!=''){img=``;} template=template+`
${img} ${value.date}

${value.title}

`;if(key==2){template='
'+template+'
';}});if(response.length<=2){template='
'+template;} template=template+'
';this.insert(template);this.status='loaded';} insert(html){this.element.classList.add('loaded');if(!this.target.querySelector('.has-megamenu.item-'+this.category_id)){let style='';if(this.status=='mouseout'){style='style="display:none;"';}else{this.target.classList.add('loaded');} this.target.insertAdjacentHTML('beforeend','
'+html+'
');} this.status='append';} show(){this.status='mouseover';var hasMegamenu=this.target.querySelectorAll('.has-megamenu');hasMegamenu.forEach(function(menu){menu.style.display='none';});if(this.target.querySelector('.has-megamenu.item-'+this.category_id)){this.target.querySelector('.has-megamenu.item-'+this.category_id).style.display='block';}} hide(){this.status='mouseout';}} __webpack_exports__["a"]=MegaMenu;}),(function(module,exports,__webpack_require__){var root=__webpack_require__(2);var now=function(){return root.Date.now();};module.exports=now;}),(function(module,exports,__webpack_require__){(function(global){var freeGlobal=typeof global=='object'&&global&&global.Object===Object&&global;module.exports=freeGlobal;}.call(exports,__webpack_require__(13)))}),(function(module,exports){var g;g=(function(){return this;})();try{g=g||Function("return this")()||(1,eval)("this");}catch(e){if(typeof window==="object") g=window;} module.exports=g;}),(function(module,exports,__webpack_require__){var isObject=__webpack_require__(1),isSymbol=__webpack_require__(15);var NAN=0/0;var reTrim=/^\s+|\s+$/g;var reIsBadHex=/^[-+]0x[0-9a-f]+$/i;var reIsBinary=/^0b[01]+$/i;var reIsOctal=/^0o[0-7]+$/i;var freeParseInt=parseInt;function toNumber(value){if(typeof value=='number'){return value;} if(isSymbol(value)){return NAN;} if(isObject(value)){var other=typeof value.valueOf=='function'?value.valueOf():value;value=isObject(other)?(other+''):other;} if(typeof value!='string'){return value===0?value:+value;} value=value.replace(reTrim,'');var isBinary=reIsBinary.test(value);return(isBinary||reIsOctal.test(value))?freeParseInt(value.slice(2),isBinary?2:8):(reIsBadHex.test(value)?NAN:+value);} module.exports=toNumber;}),(function(module,exports,__webpack_require__){var baseGetTag=__webpack_require__(16),isObjectLike=__webpack_require__(19);var symbolTag='[object Symbol]';function isSymbol(value){return typeof value=='symbol'||(isObjectLike(value)&&baseGetTag(value)==symbolTag);} module.exports=isSymbol;}),(function(module,exports,__webpack_require__){var Symbol=__webpack_require__(3),getRawTag=__webpack_require__(17),objectToString=__webpack_require__(18);var nullTag='[object Null]',undefinedTag='[object Undefined]';var symToStringTag=Symbol?Symbol.toStringTag:undefined;function baseGetTag(value){if(value==null){return value===undefined?undefinedTag:nullTag;} return(symToStringTag&&symToStringTag in Object(value))?getRawTag(value):objectToString(value);} module.exports=baseGetTag;}),(function(module,exports,__webpack_require__){var Symbol=__webpack_require__(3);var objectProto=Object.prototype;var hasOwnProperty=objectProto.hasOwnProperty;var nativeObjectToString=objectProto.toString;var symToStringTag=Symbol?Symbol.toStringTag:undefined;function getRawTag(value){var isOwn=hasOwnProperty.call(value,symToStringTag),tag=value[symToStringTag];try{value[symToStringTag]=undefined;var unmasked=true;}catch(e){} var result=nativeObjectToString.call(value);if(unmasked){if(isOwn){value[symToStringTag]=tag;}else{delete value[symToStringTag];}} return result;} module.exports=getRawTag;}),(function(module,exports){var objectProto=Object.prototype;var nativeObjectToString=objectProto.toString;function objectToString(value){return nativeObjectToString.call(value);} module.exports=objectToString;}),(function(module,exports){function isObjectLike(value){return value!=null&&typeof value=='object';} module.exports=isObjectLike;}),(function(module,__webpack_exports__,__webpack_require__){"use strict";__webpack_exports__["a"]=(function(tag){var s=document.createElement('script');if(tag.getAttribute('src')){s.setAttribute('src',tag.getAttribute('src'));}else{s.innerHTML=tag.innerHTML;} if(tag.getAttribute('async')){s.setAttribute('async',tag.getAttribute('async'));} if(tag.getAttribute('id')){s.setAttribute('id',tag.getAttribute('id'));s.onload=function(){document.body.dispatchEvent(new CustomEvent('mf_lazyloaded_'+tag.getAttribute('id')));};} document.body.appendChild(s);});}),(function(module,__webpack_exports__,__webpack_require__){"use strict";var __WEBPACK_IMPORTED_MODULE_0_lodash_debounce__=__webpack_require__(4);var __WEBPACK_IMPORTED_MODULE_0_lodash_debounce___default=__webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_lodash_debounce__);var __WEBPACK_IMPORTED_MODULE_1_lodash_isArray__=__webpack_require__(22);var __WEBPACK_IMPORTED_MODULE_1_lodash_isArray___default=__webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_lodash_isArray__);var __WEBPACK_IMPORTED_MODULE_2_lodash_isObject__=__webpack_require__(1);var __WEBPACK_IMPORTED_MODULE_2_lodash_isObject___default=__webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2_lodash_isObject__);if(window.AdOcean_Emission==undefined){window.AdOcean_Emission=function(){};} if(window.AdOcean_Not_Emission==undefined){window.AdOcean_Not_Emission=function(){};} class Adocean{constructor(){this.window_sizes=[{min:1601,max:5000,name:'desktop',},{min:1200,max:1600.8,name:'largeDesktop',},{min:992,max:1199,name:'smallDesktop',},{min:768.2,max:992,name:'tablet',},{min:0,max:768,name:'phone',},];this.banners=[];this.placement=[];if(adobanners.length<=0){return;} this.detectDevices(true);window.addEventListener('resize',__WEBPACK_IMPORTED_MODULE_0_lodash_debounce___default()(this.detectDevices.bind(this,true),30));document.body.addEventListener('mf_banners_refresh_position',this.detectDevices.bind(this,false));this.banners=adobanners[mfadomaster.name];this.showBanners();let div=document.createElement('div');div.style.display='none';this.styks=div;this.__inAfter(document.body,this.styks);} addPlacement(_banner,target){let banner=JSON.parse(JSON.stringify(_banner));if(__WEBPACK_IMPORTED_MODULE_2_lodash_isObject___default()(banner.target)&&!__WEBPACK_IMPORTED_MODULE_1_lodash_isArray___default()(banner.target)){let _target=banner.target;for(let prop in _target){if(__WEBPACK_IMPORTED_MODULE_1_lodash_isArray___default()(_target[prop])){_target[prop][0]=(target+' '+_target[prop][0]).trim();}else{_target[prop]=(target+' '+_target[prop]).trim();}} banner.target=_target;}else{if(__WEBPACK_IMPORTED_MODULE_1_lodash_isArray___default()(banner.target)){banner.target[0]=(target+' '+banner.target[0]).trim();}else{banner.target=(target+' '+banner.target).trim();}} banner.container=this.display(banner,false);this.banners.push(banner);} detectDevices(event){let device=null;for(let i=0;i-1){banner.container.remove();_this.banners.splice(index,1);} if(banner.callbackNoEmmit!=undefined){banner.callbackNoEmmit(_this);} setTimeout(function(){document.body.dispatchEvent(new CustomEvent('mf_banners_no_showed'));},100);}});}else{ado.placement({id:banner.id,server:'gpl.adocean.pl',vars:mfadoparams,onServerEmission:function(){_this.__addAdInfo(container);container.className+=' active';if(banner.callbackEmmit!=undefined){banner.callbackEmmit(_this);} setTimeout(function(){document.body.dispatchEvent(new CustomEvent('mf_banners_showed'));},100);},onServerEmissionEmpty:function(){_this.__addAdInfo(container);container.className+=' active';if(banner.callbackEmmit!=undefined){banner.callbackEmmit(this);} setTimeout(function(){document.body.dispatchEvent(new CustomEvent('mf_banners_showed'));},100);}});} return container;} insert(banner,container){let selector=banner.target;if(__WEBPACK_IMPORTED_MODULE_2_lodash_isObject___default()(selector)&&!__WEBPACK_IMPORTED_MODULE_1_lodash_isArray___default()(selector)){selector=selector[this.device]!=undefined?selector[this.device]:selector.desktop;} let target=this.__getTarget(__WEBPACK_IMPORTED_MODULE_1_lodash_isArray___default()(selector)?selector[0]:selector);if(target==null){return false;} let method=Array.isArray(selector)?selector[1]:'appendAfter';if(banner.method!=undefined&&target!=undefined&&this.device=='desktop'){method=banner.method;} switch(method){case'appendAfter':this.__appendAfter(target,container);break;case'appendBefore':this.__appendBefore(target,container);break;case'inAfter':this.__inAfter(target,container);break;case'inBefore':this.__inBefore(target,container);break;}} __appendAfter(referenceNode,newNode){if(referenceNode){referenceNode.parentNode.insertBefore(newNode,referenceNode.nextSibling);}} __appendBefore(referenceNode,newNode){if(referenceNode){referenceNode.parentNode.insertBefore(newNode,referenceNode);}} __inBefore(referenceNode,newNode){if(referenceNode){referenceNode.insertBefore(newNode,referenceNode.childNodes[0]);}} __inAfter(referenceNode,newNode){if(referenceNode){referenceNode.appendChild(newNode);}} __addAdInfo(container){let txt=document.createElement('span');txt.innerText=Lang.advertisement;txt.style.left="50%";txt.style.transform="translateX(-50%)";txt.style.color="#868686";txt.style.top="-12px";txt.style.fontSize="10px";txt.style.textTransform="uppercase";txt.style.lineHeight="10px";txt.style.margin="auto auto";txt.style.position="absolute";container.insertBefore(txt,container.childNodes[0]);} moveBanners(event=true){if(!this.banners){return;} for(let i=0;i