(window.webpackJsonp=window.webpackJsonp||[]).push([[2],{1:function(e,t,n){"use strict";n.r(t),n.d(t,"isRTL",(function(){return a})),n.d(t,"isMobile",(function(){return o})),n.d(t,"isDarkMode",(function(){return s})),n.d(t,"formatDate",(function(){return i})),n.d(t,"getParameterByName",(function(){return r})),n.d(t,"adjustImageGallery",(function(){return c})),n.d(t,"managePostImages",(function(){return l})),n.d(t,"makeImagesZoomable",(function(){return d}));var a=function(){var e=document.querySelector("html");return["ar","he","fa"].includes(e.getAttribute("lang"))},o=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"768px";return window.matchMedia("(max-width: ".concat(e,")")).matches},s=function(){var e=window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)");return e&&e.matches},i=function(e){return e?new Date(e).toLocaleDateString(document.documentElement.lang,{year:"numeric",month:"long",day:"numeric"}):""},r=function(e,t){t||(t=window.location.href),e=e.replace(/[\[\]]/g,"\\$&");var n=new RegExp("[?&]".concat(e,"(=([^&#]*)|&|#|$)")).exec(t);return n?n[2]?decodeURIComponent(n[2].replace(/\+/g," ")):"":null},c=function(){for(var e=document.querySelectorAll(".kg-gallery-image img"),t=0,n=e.length;t0){var n=t.substring(0,t.indexOf("?"));window.history.replaceState({},document.title,n)}},R=function(e){Object(h.isMobile)()||(e?(M.addClass("toggle-overflow"),_.addClass("toggle-overflow")):(M.removeClass("toggle-overflow"),_.removeClass("toggle-overflow")))};(s.click((function(){a.addClass("mobile-menu-opened"),f.addClass("opened"),B()})),d.click((function(){a.removeClass("mobile-menu-opened"),f.removeClass("opened"),B()})),g.click((function(){(A=!A)?(a.addClass("submenu-is-active"),g.addClass("active"),v.removeClass("closed").addClass("opened")):z()})),j.click((function(){y.addClass("opened"),setTimeout((function(){C.focus()}),400),B()})),k.click((function(){C.blur(),y.removeClass("opened"),B()})),C.keyup((function(){if(C.val().length>0&&L){var e=L.search(C.val()).filter((function(e){if(e.score<=.5)return e})),t="";if(e.length>0){for(var n=0,a=e.length;n

').concat(e[n].item.title,'

').concat(Object(h.formatDate)(e[n].item.published_at),"
");T.hide(),O.html(t),O.show()}else O.html(""),O.hide(),T.show()}else O.html(""),O.hide(),T.hide()})),x.change((function(){x.is(":checked")?(o()("html").attr("data-theme","dark"),localStorage.setItem("theme","dark")):(o()("html").attr("data-theme","light"),localStorage.setItem("theme","light"))})),x.hover((function(){R(!0)}),(function(){R(!1)})),S.click((function(){P(o()(this).parent())})),o()(window).click((function(e){A&&p&&!p.contains(e.target)&&(A=!1,z())})),o()(document).keyup((function(e){"Escape"===e.key&&y.hasClass("opened")&&k.click()})),I?(o()("html").attr("data-theme",I),"dark"===I&&x.attr("checked",!0)):Object(h.isDarkMode)()&&x.attr("checked",!0),a.length>0)&&new i.a(a[0],{tolerance:{down:10,up:20},offset:15,onUnpin:function(){if(!Object(h.isMobile)()&&D){var e=D[0];e&&e.state.isVisible&&e.hide()}}}).init();if(b.length>0){var V=new r.d(".js-recent-slider",{type:"slider",rewind:!1,perView:4,swipeThreshold:!1,dragThreshold:!1,gap:0,direction:Object(h.isRTL)()?"rtl":"ltr",breakpoints:{1024:{perView:3,swipeThreshold:80,dragThreshold:120},768:{perView:2,swipeThreshold:80,dragThreshold:120,peek:{before:0,after:115}},568:{perView:1,swipeThreshold:80,dragThreshold:120,peek:{before:0,after:115}}}});V.on("mount.after",(function(){Object(l.a)(".js-recent-article-title",50)})),V.mount({Swipe:r.c,Breakpoints:r.a})}if("undefined"!=typeof disableFadeAnimation&&disableFadeAnimation?o()("[data-aos]").addClass("no-aos-animation"):u.a.init({once:!0,startEvent:"DOMContentLoaded"}),w.length>0){var F=document.getElementById("secondary-navigation-template");D=Object(c.a)(".js-open-secondary-menu",{content:F.innerHTML,allowHTML:!0,arrow:!0,trigger:"click",interactive:!0,onShow:function(){R(!0)},onHidden:function(){R(!1)}})}Object(c.a)(".js-tooltip"),Object(l.a)(".js-article-card-title",100),Object(l.a)(".js-article-card-title-no-image",250),e=Object(h.getParameterByName)("action"),t=Object(h.getParameterByName)("stripe"),"subscribe"===e&&H("subscribe"),"signup"===e&&(window.location="".concat(ghostHost,"/signup/?action=checkout")),"checkout"===e&&H("signup"),"signin"===e&&H("signin"),"success"===t&&H("checkout"),"undefined"!=typeof ghostSearchApiKey?E(ghostHost,ghostSearchApiKey):(j.css("visibility","hidden"),k.remove(),y.remove())}))}},[[13,0,1]]]);