1 AOS.init({ 2 duration: 800, 3 easing: 'slide', 4 once: false 5 }); 6 7jQuery(document).ready(function($) { 8 9 "use strict"; 10 11 12 $(".loader").delay(100).fadeOut("slow"); 13 $("#overlayer").delay(100).fadeOut("slow"); 14 15 16 var siteMenuClone = function() { 17 18 $('.js-clone-nav').each(function() { 19 var $this = $(this); 20 $this.clone().attr('class', 'site-nav-wrap').appendTo('.site-mobile-menu-body'); 21 }); 22 23 24 setTimeout(function() { 25 26 var counter = 0; 27 $('.site-mobile-menu .has-children').each(function(){ 28 var $this = $(this); 29 30 $this.prepend('<span class="arrow-collapse collapsed">'); 31 32 $this.find('.arrow-collapse').attr({ 33 'data-toggle' : 'collapse', 34 'data-target' : '#collapseItem' + counter, 35 }); 36 37 $this.find('> ul').attr({ 38 'class' : 'collapse', 39 'id' : 'collapseItem' + counter, 40 }); 41 42 counter++; 43 44 }); 45 46 }, 1000); 47 48 $('body').on('click', '.arrow-collapse', function(e) { 49 var $this = $(this); 50 if ( $this.closest('li').find('.collapse').hasClass('show') ) { 51 $this.removeClass('active'); 52 } else { 53 $this.addClass('active'); 54 } 55 e.preventDefault(); 56 57 }); 58 59 $(window).resize(function() { 60 var $this = $(this), 61 w = $this.width(); 62 63 if ( w > 768 ) { 64 if ( $('body').hasClass('offcanvas-menu') ) { 65 $('body').removeClass('offcanvas-menu'); 66 } 67 } 68 }) 69 70 $('body').on('click', '.js-menu-toggle', function(e) { 71 var $this = $(this); 72 e.preventDefault(); 73 74 if ( $('body').hasClass('offcanvas-menu') ) { 75 $('body').removeClass('offcanvas-menu'); 76 $this.removeClass('active'); 77 } else { 78 $('body').addClass('offcanvas-menu'); 79 $this.addClass('active'); 80 } 81 }) 82 83 // click outisde offcanvas 84 $(document).mouseup(function(e) { 85 var container = $(".site-mobile-menu"); 86 if (!container.is(e.target) && container.has(e.target).length === 0) { 87 if ( $('body').hasClass('offcanvas-menu') ) { 88 $('body').removeClass('offcanvas-menu'); 89 } 90 } 91 }); 92 }; 93 siteMenuClone(); 94 95 96 var sitePlusMinus = function() { 97 $('.js-btn-minus').on('click', function(e){ 98 e.preventDefault(); 99 if ( $(this).closest('.input-group').find('.form-control').val() != 0 ) { 100 $(this).closest('.input-group').find('.form-control').val(parseInt($(this).closest('.input-group').find('.form-control').val()) - 1); 101 } else { 102 $(this).closest('.input-group').find('.form-control').val(parseInt(0)); 103 } 104 }); 105 $('.js-btn-plus').on('click', function(e){ 106 e.preventDefault(); 107 $(this).closest('.input-group').find('.form-control').val(parseInt($(this).closest('.input-group').find('.form-control').val()) + 1); 108 }); 109 }; 110 // sitePlusMinus(); 111 112 113 var siteSliderRange = function() { 114 $( "#slider-range" ).slider({ 115 range: true, 116 min: 0, 117 max: 500, 118 values: [ 75, 300 ], 119 slide: function( event, ui ) { 120 $( "#amount" ).val( "$" + ui.values[ 0 ] + " - $" + ui.values[ 1 ] ); 121 } 122 }); 123 $( "#amount" ).val( "$" + $( "#slider-range" ).slider( "values", 0 ) + 124 " - $" + $( "#slider-range" ).slider( "values", 1 ) ); 125 }; 126 // siteSliderRange(); 127 128 129 130 var siteCarousel = function () { 131 if ( $('.nonloop-block-13').length > 0 ) { 132 $('.nonloop-block-13').owlCarousel({ 133 center: false, 134 items: 1, 135 loop: true, 136 stagePadding: 0, 137 margin: 0, 138 smartSpeed: 1000, 139 autoplay: true, 140 nav: true, 141 navText: ['<span class="icon-arrow_back">', '<span class="icon-arrow_forward">'], 142 responsive:{ 143 600:{ 144 margin: 0, 145 nav: true, 146 items: 2 147 }, 148 1000:{ 149 margin: 0, 150 stagePadding: 0, 151 nav: true, 152 items: 2 153 }, 154 1200:{ 155 margin: 0, 156 stagePadding: 0, 157 nav: true, 158 items: 3 159 } 160 } 161 }); 162 } 163 164 $('.slide-one-item').owlCarousel({ 165 center: false, 166 items: 1, 167 loop: true, 168 stagePadding: 0, 169 margin: 0, 170 autoplay: true, 171 pauseOnHover: false, 172 nav: true, 173 navText: ['<span class="icon-keyboard_arrow_left">', '<span class="icon-keyboard_arrow_right">'] 174 }); 175 176 // $('.slide-one-item-alt').owlCarousel({ 177 // center: false, 178 // items: 1, 179 // loop: true, 180 // stagePadding: 0, 181 // smartSpeed: 700, 182 // margin: 0, 183 // autoplay: true, 184 // pauseOnHover: false, 185 186 // }); 187 188 // $('.slide-one-item-alt-text').owlCarousel({ 189 // center: false, 190 // items: 1, 191 // loop: true, 192 // stagePadding: 0, 193 // smartSpeed: 700, 194 // margin: 0, 195 // autoplay: true, 196 // pauseOnHover: false, 197 // }); 198 199 $('.slide-one-item-alt').owlCarousel({ 200 center: false, 201 items: 1, 202 loop: true, 203 stagePadding: 0, 204 margin: 0, 205 smartSpeed: 1000, 206 autoplay: true, 207 pauseOnHover: true, 208 onDragged: function(event) { 209 console.log('event : ',event.relatedTarget['_drag']['direction']) 210 if ( event.relatedTarget['_drag']['direction'] == 'left') { 211 $('.slide-one-item-alt-text').trigger('next.owl.carousel'); 212 } else { 213 $('.slide-one-item-alt-text').trigger('prev.owl.carousel'); 214 } 215 } 216 }); 217 $('.slide-one-item-alt-text').owlCarousel({ 218 center: false, 219 items: 1, 220 loop: true, 221 stagePadding: 0, 222 margin: 0, 223 smartSpeed: 1000, 224 autoplay: true, 225 pauseOnHover: true, 226 onDragged: function(event) { 227 console.log('event : ',event.relatedTarget['_drag']['direction']) 228 if ( event.relatedTarget['_drag']['direction'] == 'left') { 229 $('.slide-one-item-alt').trigger('next.owl.carousel'); 230 } else { 231 $('.slide-one-item-alt').trigger('prev.owl.carousel'); 232 } 233 } 234 }); 235 236 237 $('.custom-next').click(function(e) { 238 e.preventDefault(); 239 $('.slide-one-item-alt').trigger('next.owl.carousel'); 240 $('.slide-one-item-alt-text').trigger('next.owl.carousel'); 241 }); 242 $('.custom-prev').click(function(e) { 243 e.preventDefault(); 244 $('.slide-one-item-alt').trigger('prev.owl.carousel'); 245 $('.slide-one-item-alt-text').trigger('prev.owl.carousel'); 246 }); 247 248 }; 249 siteCarousel(); 250 251 var siteStellar = function() { 252 $(window).stellar({ 253 responsive: false,
254 parallaxBackgrounds: true, 255 parallaxElements: true, 256 horizontalScrolling: false, 257 hideDistantElements: false, 258 scrollProperty: 'scroll' 259 }); 260 }; 261 // siteStellar(); 262 263 var siteCountDown = function() { 264 265 $('#date-countdown').countdown('2020/10/10', function(event) { 266 var $this = $(this).html(event.strftime('' 267 + '<span class="countdown-block"><span class="label">%w</span> weeks </span>' 268 + '<span class="countdown-block"><span class="label">%d</span> days </span>' 269 + '<span class="countdown-block"><span class="label">%H</span> hr </span>' 270 + '<span class="countdown-block"><span class="label">%M</span> min </span>' 271 + '<span class="countdown-block"><span class="label">%S</span> sec</span>')); 272 }); 273 274 }; 275 siteCountDown(); 276 277 var siteDatePicker = function() { 278 279 if ( $('.datepicker').length > 0 ) { 280 $('.datepicker').datepicker(); 281 } 282 283 }; 284 siteDatePicker(); 285 286 var siteSticky = function() { 287 $(".js-sticky-header").sticky({topSpacing:0}); 288 }; 289 siteSticky(); 290 291 // navigation 292 var OnePageNavigation = function() { 293 var navToggler = $('.site-menu-toggle'); 294 $("body").on("click", ".main-menu li a[href^='#'], .smoothscroll[href^='#'], .site-mobile-menu .site-nav-wrap li a", function(e) { 295 e.preventDefault(); 296 297 var hash = this.hash; 298 299 $('html, body').animate({ 300 'scrollTop': $(hash).offset().top 301 }, 600, 'easeInOutExpo', function(){ 302 window.location.hash = hash; 303 }); 304 305 }); 306 }; 307 OnePageNavigation(); 308 309 var siteScroll = function() { 310 311 312 313 $(window).scroll(function() { 314 315 var st = $(this).scrollTop(); 316 317 if (st > 100) { 318 $('.js-sticky-header').addClass('shrink'); 319 } else { 320 $('.js-sticky-header').removeClass('shrink'); 321 } 322 323 }) 324 325 }; 326 siteScroll(); 327 328 329 var siteIstotope = function() { 330 /* activate jquery isotope */ 331 var $container = $('#posts').isotope({ 332 itemSelector : '.item', 333 isFitWidth: true 334 }); 335 336 $(window).resize(function(){ 337 $container.isotope({ 338 columnWidth: '.col-sm-3' 339 }); 340 }); 341 342 $container.isotope({ filter: '*' }); 343 344 // filter items on button click 345 $('#filters').on( 'click', 'button', function() { 346 var filterValue = $(this).attr('data-filter'); 347 $container.isotope({ filter: filterValue }); 348 $('#filters button').removeClass('active'); 349 $(this).addClass('active'); 350 }); 351 } 352 353 siteIstotope(); 354 355 356 $('.fancybox').on('click', function() { 357 var visibleLinks = $('.fancybox'); 358 359 $.fancybox.open( visibleLinks, {}, visibleLinks.index( this ) ); 360 361 return false; 362 }); 363 364});
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.