PageSourceSearch

https://indigo-elk-878029.hostingersite.com/wp-content/themes/muzex/assets/js/main.js?ver=1791001674

js indigo-elk-878029.hostingersite.com collected 2026-10-03 04:28:57 UTC 18,613 bytes, 570 lines download raw bytes

1(function ($) {
2    "use strict";
3	
4
5
6    if($('.curved-circle').length) {
7        $('.curved-circle').circleType({position: 'absolute', dir: 1, radius: 57, forceHeight: true, forceWidth: true});
8    }
9	
10
11	
12    //Submenu Dropdown Toggle
13    if ($('.main-nav__main-navigation li.dropdown ul').length) {
14        $('.main-nav__main-navigation li.dropdown').append('<button class="dropdown-btn"><i class="fa fa-angle-right"></i></button>');
15    }
16	
17
18
19    function dynamicCurrentMenuClass(selector) {
20        let FileName = window.location.href.split('/').reverse()[0];
21
22        selector.find('li').each(function () {
23            let anchor = $(this).find('a');
24            if ($(anchor).attr('href') == FileName) {
25                $(this).addClass('current');
26            }
27        });
28        // if any li has .current elmnt add class
29        selector.children('li').each(function () {
30            if ($(this).find('.current').length) {
31                $(this).addClass('current');
32            }
33        });
34        // if no file name return 
35        if ('' == FileName) {
36            selector.find('li').eq(0).addClass('current');
37        }
38    }
39
40    // mobile menu
41
42    if ($('.main-nav__main-navigation').length) {
43        let mobileNavContainer = $('.mobile-nav__container');
44        let mainNavContent = $('.main-nav__main-navigation').html();
45
46
47
48        mobileNavContainer.append(function () {
49            return mainNavContent;
50        });
51
52
53
54        //Dropdown Button
55        mobileNavContainer.find('li.dropdown .dropdown-btn').on('click', function () {
56            $(this).toggleClass('open');
57            $(this).prev('ul').slideToggle(500);
58        });
59
60        // dynamic current class        
61        let mainNavUL = $('.main-nav__main-navigation').find('.main-nav__navigation-box');
62        let mobileNavUL = mobileNavContainer.find('.main-nav__navigation-box');
63
64        dynamicCurrentMenuClass(mainNavUL);
65        dynamicCurrentMenuClass(mobileNavUL);
66
67
68    }
69
70
71    if ($('.mc-form').length) {
72        var mcURL = $('.mc-form').data('url');
73        $('.mc-form').ajaxChimp({
74            url: mcURL,
75            callback: function (resp) {
76                // appending response
77                $('.mc-form__response').append(function () {
78                    return '<p class="mc-message">' + resp.msg + '</p>';
79                })
80                // making things based on response
81                if (resp.result === 'success') {
82                    // Do stuff
83                    $('.mc-form').removeClass('errored').addClass('successed');
84                    $('.mc-form__response').removeClass('errored').addClass('successed');
85                    $('.mc-form').find('input').val('');
86
87                    $('.mc-form__response p').fadeOut(10000);
88
89                }
90                if (resp.result === 'error') {
91                    $('.mc-form').removeClass('successed').addClass('errored');
92                    $('.mc-form__response').removeClass('successed').addClass('errored');
93                    $('.mc-form').find('input').val('');
94
95                    $('.mc-form__response p').fadeOut(10000);
96
97                }
98            }
99        });
100
101    }
102
103		//Fact Counter + Text Count
104	if($('.count-box').length){
105		$('.count-box').appear(function(){
106	
107			var $t = $(this),
108				n = $t.find(".count-text").attr("data-stop"),
109				r = parseInt($t.find(".count-text").attr("data-speed"), 10);
110				
111			if (!$t.hasClass("counted")) {
112				$t.addClass("counted");
113				$({
114					countNum: $t.find(".count-text").text()
115				}).animate({
116					countNum: n
117				}, {
118					duration: r,
119					easing: "linear",
120					step: function() {
121						$t.find(".count-text").text(Math.floor(this.countNum));
122					},
123					complete: function() {
124						$t.find(".count-text").text(this.countNum);
125					}
126				});
127			}
128			
129		},{accY: 0});
130	}
131	
132
133    if ($('.datepicker').length) {
134        $('.datepicker').datepicker();
135    }
136
137
138    if ($('.plan-visit__tab-links').length) {
139        var planVisitLink = $('.plan-visit__tab-links').find('.nav-link');
140        planVisitLink.on('click', function (e) {
141            var target = $(this).attr('data-target');
142            // animate
143            $('html, body').animate({
144                scrollTop: $(target).offset().top - 50
145            }, 1000);
146
147
148            planVisitLink.removeClass('active');
149            $(this).addClass('active');
150
151            return false;
152        })
153    }
154
155   /* if ($('.contact-form-validated').length) {
156        $('.contact-form-validated').validate({ // initialize the plugin
157            rules: {
158                fname: {
159                    required: true
160                },
161                lname: {
162                    required: true
163                },
164                name: {
165                    required: true
166                },
167                email: {
168                    required: true,
169                    email: true
170                },
171                service: {
172                    required: true
173                },
174                message: {
175                    required: true
176                },
177                subject: {
178                    required: true
179                }
180            },
181            submitHandler: function (form) {
182                // sending value with ajax request
183                $.post($(form).attr('action'), $(form).serialize(), function (response) {
184                    $(form).parent().find('.result').append(response);
185                    $(form).find('input[type="text"]').val('');
186                    $(form).find('input[type="email"]').val('');
187                    $(form).find('textarea').val('');
188                });
189                return false;
190            }
191        });
192    }*/
193    if ($('.counter').length) {
194        $('.counter').counterUp({
195            delay: 10,
196            time: 3000
197        });
198    }
199    if ($('.img-popup').length) {
200        var groups = {};
201        $('.img-popup').each(function () {
202            var id = parseInt($(this).attr('data-group'), 10);
203
204            if (!groups[id]) {
205                groups[id] = [];
206            }
207
208            groups[id].push(this);
209        });
210
211
212        $.each(groups, function () {
213
214            $(this).magnificPopup({
215                type: 'image',
216                closeOnContentClick: true,
217                closeBtnInside: false,
218                gallery: {
219                    enabled: true
220                }
221            });
222
223        });
224
225    };
226    if ($('.wow').length) {
227        var wow = new WOW({
228            boxClass: 'wow', // animated element css class (default is wow)
229            animateClass: 'animated', // animation css class (default is animated)
230
231            mobile: true, // trigger animations on mobile devices (default is true)
232            live: true // act on asynchronously loaded content (default is true)
233        });
234        wow.init();
235    }
236
237    if ($('.video-popup').length) {
238        $('.video-popup').magnificPopup({
239            disableOn: 700,
240            type: 'iframe',
241            mainClass: 'mfp-fade',
242            removalDelay: 160,
243            preloader: true,
244
245            fixedContentPos: false
246        });
247    }
248    if ($('[data-toggle="tooltip"]').length) {
249        $('[data-toggle="tooltip"]').tooltip();
250    }
251    if ($('.stricky').length) {
252        $('.stricky').addClass('original').clone(true).insertAfter('.stricky').addClass('stricked-menu').removeClass('original');
253    }
254    if ($('.scroll-to-target').length) {
255        $(".scroll-to-target").on('click', function () {
256            var target = $(this).attr('data-target');
257            // animate
258            $('html, body').animate({
259                scrollTop: $(target).offset().top
260            }, 1000);
261
262            return false;
263
264        });
265    }
266
267    if ($('.side-menu__toggler').length) {
268        $('.side-menu__toggler').on('click', function (e) {
269            $('.side-menu__block').toggleClass('active');
270            e.preventDefault();
271        });
272    }
273
274    if ($('.side-menu__block-overlay').length) {
275        $('.side-menu__block-overlay').on('click', function (e) {
276            $('.side-menu__block').removeClass('active');
277            e.preventDefault();
278        });
279    }
280
281    if ($('.side-content__toggler').length) {
282        $('.side-content__toggler').on('click', function (e) {
283            $('.side-content__block').toggleClass('active');
284            e.preventDefault();
285        });
286    }
287
288    if ($('.side-content__block-overlay').length) {
289        $('.side-content__block-overlay').on('click', function (e) {
290            $('.side-content__block').removeClass('active');
291            e.preventDefault();
292        });
293    }
294
295
296    if ($('.search-popup__toggler').length) {
297        $('.search-popup__toggler').on('click', function (e) {
298            $('.search-popup').addClass('active');
299            e.preventDefault();
300        });
301    }
302
303    if ($('.search-popup__overlay').length) {
304        $('.search-popup__overlay').on('click', function (e) {
305            $('.search-popup').removeClass('active');
306            e.preventDefault();
307        });
308    }
309    $(window).on('scroll', function () {
310        if ($('.scroll-to-top').length) {
311            var strickyScrollPos = 100;
312            if ($(window).scrollTop() > strickyScrollPos) {
313                $('.scroll-to-top').fadeIn(500);
314            } else if ($(this).scrollTop() <= strickyScrollPos) {
315                $('.scroll-to-top').fadeOut(500);
316            }
317        }
318        if ($('.stricked-menu').length) {
319            var headerScrollPos = 100;
320            var stricky = $('.stricked-menu');
321            if ($(window).scrollTop() > headerScrollPos) {
322                stricky.addClass('stricky-fixed');
323            } else if ($(this).scrollTop() <= headerScrollPos) {
324                stricky.removeClass('stricky-fixed');
325            }
326        }
327    });
328    if ($('.accrodion-grp').length) {
329        var accrodionGrp = $('.accrodion-grp');
330        accrodionGrp.each(function () {
331            var accrodionName = $(this).data('grp-name');
332            var Self = $(this);
333            var accordion = Self.find('.accrodion');
334            Self.addClass(accrodionName);
335            Self.find('.accrodion .accrodion-content').hide();
336            Self.find('.accrodion.active').find('.accrodion-content').show();
337            accordion.each(function () {
338                $(this).find('.accrodion-title').on('click', function () {
339                    if ($(this).parent().hasClass('active') === false) {
340                        $('.accrodion-grp.' + accrodionName).find('.accrodion').removeClass('active');
341                        $('.accrodion-grp.' + accrodionName).find('.accrodion').find('.accrodion-content').slideUp();
342                        $(this).parent().addClass('active');
343                        $(this).parent().find('.accrodion-content').slideDown();
344                    };
345
346
347                });
348            });
349        });
350
351    };
352
353
354
355    $(window).on('load', function () {
356
357
358        if ($('.thm__owl-carousel').length) {
359            $('.thm__owl-carousel').each(function () {
360
361                var Self = $(this);
362                var carouselOptions = Self.data('options');
363                var carouselPrevSelector = Self.data('carousel-prev-btn');
364                var carouselNextSelector = Self.data('carousel-next-btn');
365                var thmCarousel = Self.owlCarousel(carouselOptions);
366                if (carouselPrevSelector !== undefined) {
367                    $(carouselPrevSelector).on('click', function () {
368                        thmCarousel.trigger('prev.owl.carousel', [1000]);
369                        return false;
370                    });
371                }
372                if (carouselNextSelector !== undefined) {
373                    $(carouselNextSelector).on('click', function () {
374                        thmCarousel.trigger('next.owl.carousel', [1000]);
375                        return false;
376                    });
377                }
378            });
379        }
380
381        // owl dots margin increment
382        if ($('.thm__owl-dot-1').length) {
383            var count = 10;
384            $('.thm__owl-dot-1').find('.owl-dot span').each(function () {
385                count += 10;
386                $(this).css('left', '+=' + count + 'px');
387            });
388        }
389        if ($('.thm__owl-dot-rtl-1').length) {
390            var count = 10;
391            $('.thm__owl-dot-rtl-1').find('.owl-dot span').each(function () {
392                count += 10;
393                $(this).css('right', '+=' + count + 'px');
394            });
395        }
396        if ($('.thm__owl-dot-2').length) {
397            var count = 10;
398            $('.thm__owl-dot-2').find('.owl-dot span').each(function () {
399                count += 10;
400                $(this).css('top', '+=' + count + 'px');
401            });
402        }
403        if ($('.preloader').length) {
404            $('.preloader').fadeOut('slow');
405        }
406
407        if ($('.side-menu__block-inner').length) {
408            $('.side-menu__block-inner').mCustomScrollbar({
409                axis: 'y',
410                theme: 'dark'
411            });
412        }
413        
414
415        if ($('.side-content__block-inner').length) {
416            $('.side-content__block-inner').mCustomScrollbar({
417                axis: 'y',
418                theme: 'dark'
419            });
420        }
421
422        if ($('.custom-cursor__overlay').length) {
423
424            // / cursor /
425            var cursor = $(".custom-cursor__overlay .cursor"),
426                follower = $(".custom-cursor__overlay .cursor-follower");
427
428            var posX = 0,
429                posY = 0;
430
431            var mouseX = 0,
432                mouseY = 0;
433
434            TweenMax.to({}, 0.016, {
435                repeat: -1,
436                onRepeat: function () {
437                    posX += (mouseX - posX) / 9;
438                    posY += (mouseY - posY) / 9;
439
440                    TweenMax.set(follower, {
441                        css: {
442                            left: posX - 22,
443                            top: posY - 22
444                        }
445                    });
446
447                    TweenMax.set(cursor, {
448                        css: {
449                            left: mouseX,
450                            top: mouseY
451                        }
452                    });
453
454                }
455            });
456
457            $(document).on("mousemove", function (e) {
458                var scrollTop = window.pageYOffset || document.documentElement.scrollTop;
459                mouseX = e.pageX;
460                mouseY = e.pageY - scrollTop;
461            });
462            $("button, a").on("mouseenter", function () {
463                cursor.addClass("active");
464                follower.addClass("active");
465            });
466            $("button, a").on("mouseleave", function () {
467                cursor.removeClass("active");
468                follower.removeClass("active");
469            });
470            $(".custom-cursor__overlay").on("mouseenter", function () {
471                cursor.addClass("close-cursor");
472                follower.addClass("close-cursor");
473            });
474            $(".custom-cursor__overlay").on("mouseleave", function () {
475                cursor.removeClass("close-cursor");
476                follower.removeClass("close-cursor");
477            });
478        }
479
480
481        if ($('.masonary-layout').length) {
482            $('.masonary-layout').isotope({
483                layoutMode: 'masonry',
484                itemSelector: '.masonary-item'
485            });
486        }
487
488        if ($('.post-filter').length) {
489            var postFilterList = $('.post-filter li');
490            // for first init
491            $('.filter-layout').isotope({
492                filter: '.filter-item',
493                animationOptions: {
494                    duration: 500,
495                    easing: 'linear',
496                    queue: false
497                }
498            });
499            // on click filter links
500            postFilterList.children('span').on('click', function () {
501                var Self = $(this);
502                var selector = Self.parent().attr('data-filter');
503                postFilterList.children('span').parent().removeClass('active');
504                Self.parent().addClass('active');
505
506
507                $('.filter-layout').isotope({
508                    filter: selector,
509                    animationOptions: {
510                        duration: 500,
511                        easing: 'linear',
512                        queue: false
513                    }
514                });
515                return false;
516            });
517        }
518
519        if ($('.post-filter.has-dynamic-filter-counter').length) {
520            // var allItem = $('.single-filter-item').length;
521
522            var activeFilterItem = $('.post-filter.has-dynamic-filter-counter').find('li');
523
524            activeFilterItem.each(function () {
525                var filterElement = $(this).data('filter');
526                var count = $('.gallery-content').find(filterElement).length;
527                $(this).children('span').append('<span class="count"><b>' + count + '</b></span>');
528            });
529        }
530
531    });
532
533})(jQuery);
534
535
536(function($) {
537   'use strict'
538    var testMobile;
539    var isMobile = {
540        Android: function() {
541            return navigator.userAgent.match(/Android/i);
542        },
543        BlackBerry: function() {
544            return navigator.userAgent.match(/BlackBerry/i);
545        },
546        iOS: function() {
547            return navigator.userAgent.match(/iPhone|iPad|iPod/i);
548        },
549        Opera: function() {
550            return navigator.userAgent.match(/Opera Mini/i);
551        },
552        Windows: function() {
553            return navigator.userAgent.match(/IEMobile/i);
554        },
555        any: function() {
556            return (isMobile.Android() || isMobile.BlackBerry() || isMobile.iOS() || isMobile.Opera() || isMobile.Windows());
557        }
558    };
559  var parallax = function() {
560    testMobile = isMobile.any();
561    if (testMobile == null) {
562      $(".parallax").parallax("50%", 0.3);
563    }
564  };
565  // Dom Ready
566  $(function() {
567    parallax();
568     });
569})(jQuery);
570!function(n){var t=n(window),e=t.height();t.resize(function(){e=t.height()}),n.fn.parallax=function(o,r,i){function u(){var i=t.scrollTop();l.each(function(t,u){var l=n(u),f=l.offset().top,s=a(l);i>f+s||f>i+e||l.css("backgroundPosition",o+" "+Math.round((l.data("firstTop")-i)*r)+"px")})}var a,l=n(this);l.each(function(t,e){$element=n(e),$element.data("firstTop",$element.offset().top)}),a=i?function(n){return n.outerHeight(!0)}:function(n){return n.height()},(arguments.length<1||null===o)&&(o="50%"),(arguments.length<2||null===r)&&(r=.1),(arguments.length<3||null===i)&&(i=!0),t.bind("scroll",u).resize(u),u()}}(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.