PageSourceSearch

https://www.skelec.kn/wp-content/themes/skelec/assets/js/custom-scripts.js?ver=1.0.0

js skelec.kn collected 2026-10-02 05:42:01 UTC 13,815 bytes, 536 lines download raw bytes

1jQuery(document).ready(function ($) {
2  'use strict';
3
4  //===== Menu Active =====//
5  var pgurl = window.location.href.substr(window.location.href.lastIndexOf("/") + 1);
6  $("nav ul li a").each(function () {
7    if ($(this).attr("href") == pgurl || $(this).attr("href") == '')
8    $(this).parent('li').addClass("active").parent().parent().addClass("active").parent().parent().addClass("active");
9  });
10
11  //===== Menu Active =====//
12  var pgurl = window.location.href.substr(window.location.href.lastIndexOf("/") + 1);
13  $(".rsnp-mnu ul li a").each(function () {
14    if ($(this).attr("href") == pgurl || $(this).attr("href") == '')
15    $(this).parent('li').addClass("active").parent().parent().addClass("active-parent").parent().parent().addClass("active-parent");
16  });
17  
18  //Main Slider Carousel
19  if ($('.team-caro').length) {
20	  $('.team-caro.owl-carousel').owlCarousel({
21		loop:true,
22		margin:10,
23		nav:false,
24		dots:false,
25		arrows:false,
26		stagePadding:0,
27		responsiveClass:true,
28		responsive:{
29			0:{
30				items:1,
31				nav:false
32			},
33			600:{
34				items:3,
35				nav:false
36			},
37			1000:{
38				items:4,
39				nav:false,
40				loop:false
41			}
42		}
43	  });
44	}
45
46	$(window).load(function() {
47		if ($('.sn-main-slider-carousel').length) {
48		$('.sn-main-slider-carousel').owlCarousel({
49			animateOut: 'fadeOut',
50    		animateIn: 'fadeIn',
51			loop:false,
52			margin:0,
53			nav:true,
54			autoHeight: true,
55			smartSpeed: 1000,
56			autoplay: 6000,
57			navText: [ '<span class="fa fa-angle-left"></span>', '<span class="fa fa-angle-right"></span>' ],
58			responsive:{
59				0:{
60					items:1
61				},
62				600:{
63					items:1
64				},
65				800:{
66					items:1
67				},
68				1024:{
69					items:1
70				},
71				1200:{
72					items:1
73				}
74			}
75		});    		
76	  }
77	});
78
79  //===== Width =====//
80  var width = window.innerWidth;
81
82  //===== Wow Animation Setting =====//
83  if ($(".wow").length > 0) {
84    var wow = new WOW({
85      boxClass:     'wow',      // default
86      animateClass: 'animated', // default
87      offset:       0,          // default
88      mobile:       true,       // default
89      live:         true        // default
90    }); 
91
92    wow.init();
93  }
94
95  //===== Header Search =====//
96  $('.search-btn').on('click', function () {
97    $('.header-search').addClass('active');
98    return false;
99  });
100  $('.search-close-btn').on('click', function () {
101    $('.header-search').removeClass('active');
102    return false;
103  });
104
105  //===== Side Menu =====//
106  $('.rspn-mnu-btn').on('click', function () {
107    $('.rsnp-mnu').addClass('slidein');
108    return false;
109  });
110  $('.rspn-mnu-cls').on('click', function () {
111    $('.rsnp-mnu').removeClass('slidein');
112  });
113  $('.rsnp-mnu li.menu-item-has-children > a').on('click', function () {
114    $(this).parent().siblings('li').children('ul').slideUp();
115    $(this).parent().siblings('li').removeClass('active');
116    $(this).parent().children('ul').slideToggle();
117    $(this).parent().toggleClass('active');
118    return false;
119  });
120
121  //===== Select =====//
122  if ($('.slc-wrp > select').length > 0) {
123    jQuery('.slc-wrp > select').selectpicker();
124  }
125
126  //===== Sticky Sidebar =====//
127  if(width > 991) {
128    if ($('.post-detail-wrap > div.row > div').length > 0) {
129      $('.post-detail-wrap > div.row > div').theiaStickySidebar({
130        additionalMarginTop: 40,
131        additionalMarginBottom: 40
132      });
133    }
134  }
135
136  //===== Counter Up =====//
137  if ($.isFunction($.fn.counterUp)) {
138    $('.counter').counterUp({
139      delay: 10,
140      time: 2000
141    });
142  }
143
144  //===== LightBox =====//
145  if ($.isFunction($.fn.fancybox)) {
146    $('[data-fancybox],[data-fancybox="gallery"]').fancybox({});
147  }
148
149  //===== Scrollbar =====//
150  if ($('.rsnp-mnu').length > 0) {
151    var ps = new PerfectScrollbar('.rsnp-mnu');
152  }
153
154  //===== Calendar =====//
155  if ($('#calendar').length > 0) {
156    $('#calendar').fullCalendar({
157      defaultDate: '2021-02-12',
158      editable: true,
159      eventLimit: true // allow "more" link when too many events
160    });
161  }
162
163  //===== Contact Form Validation =====//
164  if($('#email-form').length){
165    $('form#email-form').submit(function (e) {
166      e.preventDefault();
167      var fname = $('#email-form .fname').val();
168      var email = $('#email-form .email').val();
169      var subject = $('#email-form .subject').val();
170      var message = $('#email-form .contact_message').val();
171      if(fname == '' || email == '') {
172        $(this).children('.response').html('<div class="failed alert alert-warning text-center rounded-pill mt-2">Please fill the required fields.</div>');
173        return false;
174      }
175      $.ajax({
176        url: "sendemail.php",
177        method: "POST",
178        data: $(this).serialize(),
179        beforeSend: () => {
180          $(this).children('.response').html('<div class="text-info"><img src="assets/images/preloader.gif"> Loading...</div>');
181        },
182        success: (data) => {
183          $(this).children('.response').fadeIn().html(data);
184          setTimeout(function () {
185            $(this).children('.response').fadeOut("slow");
186          }, 5000);
187          $(this).trigger("reset");
188        },
189        error: (res) => {
190          console.log(res);
191          $(this).children('.response').fadeIn().html(data);
192        }
193      });
194    });
195  }
196
197  //===== Slick Carousel =====//
198  if ($.isFunction($.fn.slick)) {
199
200    //=== Featured Area Carousel ===//
201    $('.feat-caro').slick({
202      initialSlide: 0,
203      infinite: true,
204      slidesToShow: 1,
205      slidesToScroll: 1,
206      fade: true,
207      autoplay: false,
208      autoplaySpeed: 6000,
209      cssEase: 'cubic-bezier(0.7, 0, 0.3, 1)',
210      speed: 1500,
211      draggable: true,
212      dots: false,
213      arrows: true,
214      pauseOnDotsHover: true,
215      pauseOnFocus: false,
216      pauseOnHover: false,
217      prevArrow:"<button type='button' class='slick-prev'><i class='flaticon-arrow-pointing-to-right'></i></button>",
218      nextArrow:"<button type='button' class='slick-next'><i class='flaticon-arrow-pointing-to-left'></i></button>",
219      responsive: [{
220        breakpoint: 1076,
221        settings: {
222          slidesToShow: 1,
223          slidesToScroll: 1,
224          dots: true,
225          arrows: false
226        }
227      },
228      {
229        breakpoint: 851,
230        settings: {
231          slidesToShow: 1,
232          slidesToScroll: 1,
233          dots: true,
234          arrows: false
235        }
236      },
237      {
238        breakpoint: 576,
239        settings: {
240          slidesToShow: 1,
241          slidesToScroll: 1,
242          dots: true,
243          arrows: false
244        }
245      }]
246    });
247
248    //=== Featured Area Carousel 2 ===//
249    $('.feat-caro2').slick({
250      initialSlide: 0,
251      infinite: true,
252      slidesToShow: 1,
253      slidesToScroll: 1,
254      fade: true,
255      autoplay: false,
256      autoplaySpeed: 6000,
257      cssEase: 'cubic-bezier(0.7, 0, 0.3, 1)',
258      speed: 1500,
259      draggable: true,
260      dots: false,
261      arrows: true,
262      pauseOnDotsHover: true,
263      pauseOnFocus: false,
264      pauseOnHover: false,
265      prevArrow:"<button type='button' class='slick-prev'><i class='flaticon-arrow-pointing-to-right'></i></button>",
266      nextArrow:"<button type='button' class='slick-next'><i class='flaticon-arrow-pointing-to-left'></i></button>",
267      responsive: [{
268        breakpoint: 995,
269        settings: {
270          slidesToShow: 1,
271          slidesToScroll: 1,
272          dots: true,
273          arrows: false
274        }
275      },
276      {
277        breakpoint: 851,
278        settings: {
279          slidesToShow: 1,
280          slidesToScroll: 1,
281          dots: true,
282          arrows: false
283        }
284      },
285      {
286        breakpoint: 770,
287        settings: {
288          slidesToShow: 1,
289          slidesToScroll: 1,
290          dots: true,
291          arrows: false
292        }
293      },
294      {
295        breakpoint: 576,
296        settings: {
297          slidesToShow: 1,
298          slidesToScroll: 1,
299          dots: true,
300          arrows: false
301        }
302      }]
303    });
304
305    //=== Featured Area Image Carousel ===//
306    $('.feat-img-caro').slick({
307      initialSlide: 0,
308      infinite: true,
309      slidesToShow: 1,
310      slidesToScroll: 1,
311      fade: true,
312      autoplay: true,
313      autoplaySpeed: 6000,
314      cssEase: 'cubic-bezier(0.7, 0, 0.3, 1)',
315      speed: 1500,
316      draggable: true,
317      dots: false,
318      arrows: false,
319      pauseOnDotsHover: true,
320      pauseOnFocus: false,
321      pauseOnHover: false,
322      prevArrow:"<button type='button' class='slick-prev'><i class='flaticon-arrow-pointing-to-right'></i></button>",
323      nextArrow:"<button type='button' class='slick-next'><i class='flaticon-arrow-pointing-to-left'></i></button>",
324      responsive: [{
325        breakpoint: 981,
326        settings: {
327          slidesToShow: 1,
328          slidesToScroll: 1
329        }
330      },
331      {
332        breakpoint: 851,
333        settings: {
334          slidesToShow: 1,
335          slidesToScroll: 1
336        }
337      },
338      {
339        breakpoint: 770,
340        settings: {
341          slidesToShow: 1,
342          slidesToScroll: 1
343        }
344      },
345      {
346        breakpoint: 576,
347        settings: {
348          slidesToShow: 1,
349          slidesToScroll: 1
350        }
351      },
352      {
353        breakpoint: 490,
354        settings: {
355          slidesToShow: 1,
356          slidesToScroll: 1
357        }
358      }]
359    });
360
361    //=== News Carousel ===//
362    $('.news-caro').slick({
363      arrows: true,
364      initialSlide: 0,
365      infinite: true,
366      slidesToShow: 3,
367      slidesToScroll: 1,
368      fade: false,
369      autoplay: false,
370      autoplaySpeed: 5000,
371      speed: 1000,
372      draggable: true,
373      dots: false,
374      pauseOnDotsHover: true,
375      pauseOnFocus: false,
376      pauseOnHover: false,
377      prevArrow:"<button type='button' class='slick-prev'><i class='flaticon-angle-pointing-to-left'></i></button>",
378      nextArrow:"<button type='button' class='slick-next'><i class='flaticon-angle-arrow-pointing-to-right'></i></button>",
379      responsive: [{
380        breakpoint: 1210,
381        settings: {
382          slidesToShow: 3,
383          slidesToScroll: 1,
384          arrows: false,
385          dots: true
386        }
387      },
388      {
389        breakpoint: 995,
390        settings: {
391          slidesToShow: 2,
392          slidesToScroll: 1,
393          arrows: false,
394          dots: true
395        }
396      },
397      {
398        breakpoint: 576,
399        settings: {
400          slidesToShow: 1,
401          slidesToScroll: 1,
402          arrows: false,
403          dots: true
404        }
405      }]
406    });
407
408    //===== Testimonials Carousel =====//
409    $('.testi-list-caro').slick({
410      slidesToShow: 1,
411      slidesToScroll: 1,
412      arrows: true,
413      autoplay: true,
414      prevArrow:"<button type='button' class='slick-prev'><i class='flaticon-angle-pointing-to-left'></i></button>",
415      nextArrow:"<button type='button' class='slick-next'><i class='flaticon-angle-arrow-pointing-to-right'></i></button>",
416      // slide: 'li',
417      fade: true,
418      asNavFor: '.testi-nav-caro',
419      responsive: [{
420      breakpoint: 1290,
421        settings: {
422          slidesToShow: 1,
423          slidesToScroll: 1,
424          arrows: false
425        }
426      },
427      {
428      breakpoint: 850,
429        settings: {
430          slidesToShow: 1,
431          slidesToScroll: 1,
432          arrows: false
433        }
434      },
435      {
436      breakpoint: 480,
437        settings: {
438          slidesToShow: 1,
439          slidesToScroll: 1,
440          arrows: false
441        }
442      }]
443    });
444
445    $('.testi-nav-caro').slick({
446      slidesToShow: 3,
447      slidesToScroll: 1,
448      asNavFor: '.testi-list-caro',
449      dots: false,
450      arrows: false,
451      // slide: 'li',
452      centerMode: true,
453      vertical: true,
454      centerPadding: '0px',
455      focusOnSelect: true,
456      prevArrow:"<button type='button' class='slick-prev'><i class='flaticon-angle-pointing-to-left'></i></button>",
457      nextArrow:"<button type='button' class='slick-next'><i class='flaticon-angle-arrow-pointing-to-right'></i></button>",
458      responsive: [{
459      breakpoint: 1200,
460        settings: {
461          slidesToShow: 3,
462          slidesToScroll: 1,
463          infinite: true,
464        }
465      },
466      {
467      breakpoint: 995,
468        settings: {
469          slidesToShow: 3,
470          slidesToScroll: 1,
471          arrows: false,
472          vertical: false
473        }
474      },
475      {
476      breakpoint: 480,
477        settings: {
478          slidesToShow: 3,
479          slidesToScroll: 1,
480          arrows: false,
481          vertical: false
482        }
483      }]
484    });
485
486  }
487
488}); //===== Document Ready Ends =====//
489
490//===== Window onLoad =====//
491jQuery(window).on('load',function ($) {
492  'use strict';
493  
494  //===== Page Loader =====//
495  jQuery("#preloader").fadeOut(300);
496
497  //===== Isotope =====//
498  if (jQuery('.fltr-itm').length > 0) {
499    if (jQuery().isotope) {
500      var jQuerycontainer = jQuery('.masonry'); // cache container
501      jQuerycontainer.isotope({
502        itemSelector: '.fltr-itm',
503        columnWidth: .1
504      });
505      jQuery('.filter-links a').on('click',function () {
506        var selector = jQuery(this).attr('data-filter');
507        jQuery('.filter-links li').removeClass('active');
508        jQuery(this).parent().addClass('active');
509        jQuerycontainer.isotope({ filter: selector });
510        return false;
511      });
512      jQuerycontainer.isotope('layout'); // layout/layout
513    }
514
515    jQuery(window).resize(function () {
516      if (jQuery().isotope) {
517        jQuery('.masonry').isotope('layout'); // layout/relayout on window resize
518      }
519    });
520  }
521
522});//===== Window onLoad Ends =====//
523
524//===== Sticky Header =====//
525jQuery(window).on('scroll',function ($) {
526  'use strict';
527
528  var menu_height = jQuery('header').innerHeight();
529  var scroll = jQuery(window).scrollTop();
530  if (scroll >= menu_height) {
531    jQuery('body').addClass('sticky');
532  } else {
533    jQuery('body').removeClass('sticky');
534  }
535
536});//===== Window onScroll Ends =====//

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.