!function(e,t){"use strict";ElementsKit_Helper.registerWidget("elementskit-content-ticker.default",(function(i){let n=i.find(".ekit-content-ticker-wrapper"),s=i.find(".ekitMarqueeSwiper"),r=n.data("content-settings"),a=r.settingOptions.tickerEffect;if("marquee"!==a){var o={loop:!0,speed:r.settingOptions.tickerSpeed?"typing"===a?100:1e3*r.settingOptions.tickerSpeed:1e3,slidesPerView:"auto",direction:r.settingOptions.tickerDirection?r.settingOptions.tickerDirection:"horizontal",effect:a?"typing"===a?"fade":a:"slide",fadeEffect:{crossFade:!0},grabCursor:"yes"==r.settingOptions.tickerGrabCursor,allowTouchMove:"yes"==r.settingOptions.tickerGrabCursor,navigation:{nextEl:i.find(".ekit-marquee-button-next").get(0),prevEl:i.find(".ekit-marquee-button-prev").get(0)},on:{init:function(){c(this)},slideChangeTransitionEnd:function(){c(this),p(this)}}};function c(e){if("vertical"===r.settingOptions.tickerDirection){n.find(".ekit-marquee-item").css({height:"auto"});let t=e.activeIndex,i=e.slides[t].scrollHeight;n.find(".ekit-marquee .swiper-wrapper, .ekit-marquee-item").css("height",`${i}px`),e.update()}}function p(t){if("typing"===a){let i=t.activeIndex,n=e(t.slides[i]).find(".ekit-title-and-description a"),s=n.text();n.empty();let a=0;!function o(){a<s.length&&(n[0].innerHTML+=s.charAt(a),a++,setTimeout(o,(r.settingOptions.tickerDelay-3e3)/s.length))}()}}"yes"===r.settingOptions.tickerAutoPlay&&(o.autoplay={delay:r.settingOptions.tickerDelay?r.settingOptions.tickerDelay:700,reverseDirection:"yes"===r.settingOptions.tickerReverseDirection,disableOnInteraction:!1},s.hover((function(){this.swiper.autoplay.stop(),s.find(".swiper-wrapper").css({"animation-play-state":"paused"})}),(function(){this.swiper.autoplay.start(),s.find(".swiper-wrapper").css({"animation-play-state":"running"})})));let d=i.find(`.${t.config.swiperClass}`);ElementsKit_Helper.swiper(d,o).then((function(e){}))}if("marquee"===a){let l=i.find(".ticker"),g=i.find(".marquee-wrapper"),f=g.clone(!0);"yes"===r.settingOptions.tickerReverseDirection?l.addClass("ticker-right"):l.addClass("ticker-left"),l.css({"padding-left":"100%"}),g.css({"padding-right":"100%"}),"yes"!==r.settingOptions.tickerGapBetween&&(l.append(f),"yes"===r.settingOptions.tickerReverseDirection?l.addClass("ticker-right-loop"):l.addClass("ticker-left-loop"),l.css({"padding-left":"unset",display:"flex"}),g.css({"padding-right":"unset"}))}}))}(jQuery,window.elementorFrontend);