PageSourceSearch

https://mbmarathon.com/wp-content/cache/min/1/wp-content/plugins/u…/assets/js/main.js?ver=1783440119

js mbmarathon.com collected 2026-09-26 13:45:20 UTC 10,568 bytes, 37 lines download raw bytes

1(function($){"use strict";$.exists=function(selector){return $(selector).length>0};$(window).on("load",function(){$(window).trigger("scroll");$(window).trigger("resize");isotopMsSetup();preloaderSetup()});$(document).on("ready",function(){$(window).trigger("resize");backgroundImage();primaryMenuSetup();mobileMenu();onePage();scrollFunction();stickyFooter();progressBar();swiperSlider();modalVideo();counterSetup();parallax();tabs();isotopMsSetup();accordianSetup();rippleSetup();layerParallax();overlay();youtubeBg();contactForm()});$(window).on("resize",function(){stickyFooter();mobileMenu();scrollFunction();isotopMsSetup()});$(window).on("scroll",function(){stickyFooter();scrollFunction()});function preloaderSetup(){$(".ts-preloader-wave").fadeOut();$("#ts-preloader").delay(150).fadeOut("slow")}
2function backgroundImage(){if($.exists(".ts-bg")){$(".ts-bg").each(function(){var src=$(this).attr("data-src");$(this).css({"background-image":"url("+src+")"})})}}
3function primaryMenuSetup(){$('.ts-main-nav').before('<div class="ts-m-menu-btn"><span></span></div>');$('.ts-m-menu-btn').on('click',function(){$(this).toggleClass('ts-m-menu-btn-ext');$(this).siblings('.ts-main-nav').slideToggle('slow')});$('.menu-item-has-children ').append('<i class="ts-plus ts-dropdown"></i>');$('.ts-dropdown').on('click',function(){$(this).prev().slideToggle('slow');$(this).toggleClass('ts-plus ts-minus')});$('.ts-mega-wrapper>li>a').removeAttr("href");$('.ts-mega-wrapper>li>a').on('click',function(){$(this).siblings().slideToggle();$(this).toggleClass('ts-megamenu-plus')});$('.ts-solid-header.ts-sticky-header').before('<div class="ts-solid-header-height"></div>')}
4function mobileMenu(){if($(window).width()<=991){$('.ts-primary-nav').addClass('ts-m-menu').removeClass('ts-primary-nav');$('.ts-profile-toggle').addClass('ts-offset-menu')}else{$('.ts-m-menu').addClass('ts-primary-nav').removeClass('ts-m-menu');$('.ts-profile-toggle').removeClass('ts-offset-menu')}
5var solidHeaderHight=$('.ts-solid-header').height()+'px';$('.ts-solid-header-height').css('height',solidHeaderHight)}
6function onePage(){$('.ts-onepage .ts-primary-nav-list a').on('click',function(){var thisAttr=$(this).attr('href');if($(thisAttr).length){var scrollPoint=$(thisAttr).offset().top-80;$('body,html').animate({scrollTop:scrollPoint},600)}
7return!1})}
8function scrollFunction(){var scroll=$(window).scrollTop();if(scroll>=10){$('.ts-site-header').addClass('small-height')}else{$('.ts-site-header').removeClass('small-height')}}
9function stickyFooter(){var footerHeight=($('.ts-sticky-footer').height())+'px';$('.ts-content').css("margin-bottom",footerHeight)}
10function progressBar(){var bar=new ProgressBar.Line(progress,{strokeWidth:4,easing:'easeInOut',duration:1400,color:'#FFEA82',trailColor:'#eee',trailWidth:1,svgStyle:{width:'100%',height:'100%'}});bar.animate(1.0)}
11function modalVideo(){$(document).on('click','.ts-video-open',function(e){e.preventDefault();var video=$(this).attr('href');$('.ts-video-popup-container iframe').attr('src',video);$('.ts-video-popup').addClass('active')});$('.ts-video-popup-close, .ts-video-popup-layer').on('click',function(e){$('.ts-video-popup').removeClass('active');$('html').removeClass('overflow-hidden');$('.ts-video-popup-container iframe').attr('src','about:blank')
12e.preventDefault()})}
13function counterSetup(){if($.exists('.ts-counter')){const ready=(selector,callback)=>{window.addEventListener('DOMContentLoaded',function(){const elems=[...document.querySelectorAll(selector)];if(elems.length){for(let elem of elems){callback(elem)}}})};ready('.ts-counter',(stat)=>{const patt=/(\D+)?(\d+)(\D+)?(\d+)?(\D+)?/;const time=1000;let result=[...patt.exec(stat.textContent)];let fresh=!0;let ticks;result.shift();result=result.filter(res=>res!=null);while(stat.firstChild){stat.removeChild(stat.firstChild)}
14for(let res of result){if(isNaN(res)){stat.insertAdjacentHTML('beforeend',`<span>${res}</span>`)}else{for(let i=0;i<res.length;i++){stat.insertAdjacentHTML('beforeend',`<span data-value="${res[i]}">
15                <span>&ndash;</span>
16                ${Array(parseInt(res[i], 10) + 1).join(0).split(0).map((x, j) => `<span>${j}</span>`).join('')}
17              </span>`)}}}
18ticks=[...stat.querySelectorAll('span[data-value]')];let activate=()=>{let top=stat.getBoundingClientRect().top;let offset=(window.innerHeight);if(top<offset){for(let tick of ticks){let dist=parseInt(tick.getAttribute('data-value'),10)+1;tick.style.transform=`translateY(-${(dist) * 100}%)`}
19window.removeEventListener('scroll',activate)}}
20window.addEventListener('scroll',activate);activate()})}}
21function swiperSlider(){for(var i=0;i<$('.swiper-container').length;i++){var mySwiper=mySwiper+i;var swiperMain=$('.swiper-container').eq(i);var swiperControl=swiperMain.parents('.ts-slider');swiperMain.addClass('swiper-container'+i);swiperControl.find('.pagination').addClass('pagination'+i);swiperControl.find('.swiper-arrow-right').addClass('swiper-arrow-right'+i);swiperControl.find('.swiper-arrow-left').addClass('swiper-arrow-left'+i);var activeSwiper='.swiper-container'+i;var activePagination='.pagination'+i;var arrowRight='.swiper-arrow-right'+i;var arrowLeft='.swiper-arrow-left'+i;var autoPlay=parseInt($(activeSwiper).attr('data-autoplay'),10);(autoPlay===0)?(autoPlay=!1):(autoPlay=!0);var sliderLoop=parseInt($(activeSwiper).attr('data-loop'),10);(sliderLoop===0)?(sliderLoop=!1):(sliderLoop=!0);var sliderEffect=$(activeSwiper).attr('data-effect');if(sliderEffect==='fade'){sliderEffect='fade'}else{sliderEffect=''}
22var sliderSpeed=parseInt($(activeSwiper).attr('data-speed'),10);
22var slidesPerView=$(activeSwiper).attr('data-slides-per-view');var slideView=parseInt($(activeSwiper).attr('data-add-slides'),10);var xlPoint=parseInt($(activeSwiper).attr('data-lg-slides'),10);var lgPoint=parseInt($(activeSwiper).attr('data-md-slides'),10);var mdPoint=parseInt($(activeSwiper).attr('data-sm-slides'),10);var smPoint=parseInt($(activeSwiper).attr('data-xs-slides'),10);var sliderBreakpoints={};if(slidesPerView==1){slidesPerView=1}else if(slidesPerView==='auto'){slidesPerView='auto'}else{slidesPerView=slideView;sliderBreakpoints={575:{slidesPerView:smPoint},767:{slidesPerView:mdPoint},991:{slidesPerView:lgPoint},1199:{slidesPerView:xlPoint}}}
23mySwiper=new Swiper(activeSwiper,{loop:sliderLoop,autoplay:autoPlay,effect:sliderEffect,speed:sliderSpeed,pagination:{el:activePagination,clickable:!0,},navigation:{nextEl:arrowRight,prevEl:arrowLeft,},slidesPerView:slidesPerView,breakpoints:sliderBreakpoints})}}
24function parallax(){if($.exists('.ts-parallax')){var numItems=$('.ts-parallax').length;for(var loopI=0;loopI<numItems;loopI++){$('body').find('.ts-parallax').eq(loopI).addClass('ts-parallax'+loopI);var speed=$('.ts-parallax'+loopI).data('speed');$('.ts-parallax'+loopI).parallax('50%',speed)}}}
25function tabs(){$('.ts-tabs.ts-fade-tabs .ts-tab-links a').on('click',function(e){var currentAttrValue=$(this).attr('href');$('.ts-tabs '+currentAttrValue).fadeIn(400).siblings().hide();$(this).parents('li').addClass('active').siblings().removeClass('active');e.preventDefault()})}
26function isotopMsSetup(){if($.exists('.ts-isotop')){$('.ts-isotop').isotope({itemSelector:'.ts-isotop-item',transitionDuration:'0.60s',percentPosition:!0,masonry:{columnWidth:'.ts-grid-sizer'}});$('.ts-isotop-filter ul li').on('click',function(event){$(this).siblings('.active').removeClass('active');$(this).addClass('active');event.preventDefault()});$('.ts-isotop-filter ul').on('click','a',function(){var filterElement=$(this).attr('data-filter');$(this).parents('.ts-isotop-filter').next().isotope({filter:filterElement})})}}
27function accordianSetup(){var $this=$(this);$('.ts-accordian').children('.ts-accordian-body').hide();$('.ts-accordian.active').children('.ts-accordian-body').show();$('.ts-accordian-title').on('click',function(){$(this).parent('.ts-accordian').siblings().children('.ts-accordian-body').slide
27Up(250);$(this).siblings().slideDown(250);$(this).parents('.ts-accordian').addClass('active');$(this).parent('.ts-accordian').siblings().removeClass('active')})}
28function rippleSetup(){if($.exists('.ripple-version')){$('.ripple-version').ripples({resolution:512,dropRadius:20,perturbance:0.04,})}}
29function layerParallax(){if($.exists('#ts-sayer-parallax')){var scene=document.getElementById('ts-sayer-parallax');var parallax=new Parallax(scene)}}
30function overlay(){$(".ts-overlay").each(function(){var overlayOpacity=$(this).attr("data-opacity");$(this).css('opacity',overlayOpacity)})}
31function youtubeBg(){if($.exists('.player')){$(".player").YTPlayer()}}
32if($.exists('.mailchimp')){if($('.mailchimp').length>0){$('.mailchimp').ajaxChimp({language:'es',callback:mailchimpCallback})}
33function mailchimpCallback(resp){if(resp.result==='success'){$('.subscription-success').html('<i class="fa fa-check"></i><br/>'+resp.msg).fadeIn(1000);$('.subscription-error').fadeOut(500)}else if(resp.result==='error'){$('.subscription-error').html('<i class="fa fa-times"></i><br/>'+resp.msg).fadeIn(1000)}}
34$.ajaxChimp.translations.es={'submit':'Submitting...',0:'We have sent you a confirmation email',1:'Please enter a value',2:'An email address must contain a single @',3:'The domain portion of the email address is invalid (the portion after the @: )',4:'The username portion of the email address is invalid (the portion before the @: )',5:'This email address looks fake or invalid. Please enter a real email address'}}
35function contactForm(){if($.exists('#submit')){$('#cf-msg').hide();$('#cf #submit').on('click',function(){var name=$('#name').val();var subject=$('#subject').val();var email=$('#email').val();var msg=$('#msg').val();var regex=/^([a-zA-Z0-9_.+-])+\@(([a-zA-Z0-9-])+\.)+([a-zA-Z0-9]{2,4})+$/;if(!regex.test(email)){$('#cf-msg').fadeIn().html('<div class="alert alert-danger"><strong>Warning!</strong> Please Enter Valied Email.</div>');return!1}
36name=$.trim(name);subject=$.trim(subject);email=$.trim(email);msg=$.trim(msg);if(name!=''&&email!=''&&msg!=''){var values="name="+name+"&subject="+subject+"&email="+email+" &msg="+msg;$.ajax({type:"POST",url:"assets/php/mail.php",data:values,success:function(){$('#name').val('');$('#subject').val('');$('#email').val('');$('#msg').val('');$('#cf-msg').fadeIn().html('<div class="alert alert-success"><strong>Success!</strong> Email has been sent successfully.</div>');setTimeout(function(){$('#cf-msg').fadeOut('slow')},4000)}})}else{$('#cf-msg').fadeIn().html('<div class="alert alert-danger"><strong>Warning!</strong> All fields are required.</div>')}
37return!1})}}})(jQuery)

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.