1jQuery(window).on( 'load', function($) { 2 3 'use strict'; 4 5 if ( jQuery('.vc_progress_bar').length > 0 ) { 6 jQuery('.vc_progress_bar').on( 'appear', function() { 7 jQuery(window).trigger('resize'); 8 jQuery.waypoints('refresh'); 9 }); 10 } 11 12/* ============================================== 13PAGE LOADER 14============================================== */ 15 16 if ( document.getElementById("pageloader") ) { 17 jQuery(".mid").delay(0).fadeOut(); 18 jQuery(".outter").delay(0).fadeOut(); 19 jQuery("#pageloader").delay(300).fadeOut("slow", function() { 20 if (typeof startRainySound == 'function') { startRainySound(); } 21 }); 22 } 23 24 jQuery("#pageloader").delay(300).fadeOut("slow"); 25 26/* ============================================== 27NAVIGATION DROP DOWN MENU 28=============================================== */ 29 30 jQuery('.nav-menu-desktop .menu-item-has-children').on( "mouseenter", function() { 31 jQuery(this).find('.dropdown-menu,.sub-menu').first().stop(true, true).fadeIn(250); 32 }); 33 jQuery('.nav-menu-desktop .menu-item-has-children').on( "mouseleave", function() { 34 jQuery(this).find('.dropdown-menu,.sub-menu').first().stop(true, true).fadeOut(250) 35 }); 36 37 jQuery('body').on('touchstart.dropdown', '.dropdown-menu, .work-image', function (e) { e.stopPropagation(); }); 38 39 40/* ============================================== 41PROJECT 01 HOME (SUPER SLIDES) 42=============================================== */ 43 44 jQuery('#project').superslides({ 45 play: 8000, 46 animation: 'fade', 47 inherit_width_from: window, 48 inherit_height_from: window, 49 }); 50 51/* ============================================== 52MAGNIFIC POPUP 53=============================================== */ 54 55 //for single image 56 jQuery('.mp-image').each(function() { 57 jQuery(this).magnificPopup({type:'image'}); 58 }); 59 jQuery('.mp-video, mp-map').each(function() { 60 jQuery(this).magnificPopup({type:'iframe'}); 61 }); 62 63 // for image gallery 64 jQuery('.mp-gallery').each(function() { // the containers for all your galleries 65 jQuery(this).magnificPopup({ 66 delegate: 'a', // the selector for gallery item 67 type: 'image', 68 fixedContentPos: false, 69 gallery: { 70 enabled:true 71 } 72 }); 73 }); 74 75/* ============================================== 76PRETTY PHOTO 77=============================================== */ 78 79 jQuery("a[data-rel^='prettyPhoto']").each(function() { 80 jQuery(this).prettyPhoto({ 81 theme: "light_square", 82 default_width: 700, 83 default_height: 400, 84 }); 85 }); 86 87/* ============================================== 88Fit Videos 89=============================================== */ 90 91 jQuery(".fitvid").fitVids(); 92 93/* ============================================== 94CUSTOM IMAGE SLIDER 95=============================================== */ 96 97 jQuery('.custom_slider').flexslider({ 98 animation: "fade", 99 selector: ".image_slider .slide", 100 controlNav: true, 101 directionNav: true, 102 animationSpeed: 500, 103 slideshowSpeed: 5000, 104 pauseOnHover: true, 105 direction: "vertical", 106 start: function(slider){ 107 jQuery('body').removeClass('loading'); 108 } 109 }); 110 111/* ============================================== 112FLEX SLIDER FOR PORTFOLIO VERSION 113=============================================== */ 114 115 jQuery('.inner-portfolio .text-slider').flexslider({ 116 animation: "fade", 117 selector: "ul.texts li.slide", 118 controlNav: false, 119 directionNav: true, 120 slideshowSpeed: 5000, 121 direction: "vertical", 122 start: function(slider){ 123 jQuery('body').removeClass('loading'); 124 } 125 }); 126 127/* ============================================== 128FLEX SLIDER FOR PORTFOLIO VERSION 129=============================================== */ 130 131 jQuery('.inner-portfolio .circle-image-slider').flexslider({ 132 animation: "fade", 133 selector: "ul.circle-slider li.slide", 134 controlNav: false, 135 directionNav: true, 136 slideshowSpeed: 5000, 137 direction: "vertical", 138 start: function(slider){ 139 jQuery('body').removeClass('loading'); 140 } 141 }); 142 143/* ============================================== 144CAROUSEL SLIDER FOR TEAM BOXES 145=============================================== */ 146 147 jQuery(".team-boxes").each( function() { 148 149 var autoPlay = false;
150 var slideSpeed = 700; 151 var paginationSpeed = 900; 152 153 if ( jQuery(this).data('carousel-autoplay') != '' && jQuery(this).data('carousel-autoplay') != 'false' ) { 154 autoPlay = jQuery(this).data('carousel-autoplay'); 155 } 156 if ( jQuery(this).data('carousel-slidespeed') != '' && jQuery(this).data('carousel-slidespeed') != '700' ) { 157 slideSpeed = jQuery(this).data('carousel-slidespeed'); 158 } 159 if ( jQuery(this).data('carousel-paginationspeed') != '' && jQuery(this).data('carousel-paginationspeed') != '900' ) { 160 paginationSpeed = jQuery(this).data('carousel-paginationspeed'); 161 } 162 163 jQuery(this).owlCarousel({ 164 items : 4, 165 // Responsive Settings 166 itemsDesktop : [1169,4], 167 itemsDesktopSmall : [1024,3], 168 itemsTablet : [640,2], 169 itemsTabletSmall : false, 170 itemsMobile : [560,1], 171 stopOnHover: true, 172 // End Responsive Settings 173 slideSpeed : slideSpeed, 174 autoPlay : autoPlay, 175 paginationSpeed : paginationSpeed, 176 rewindSpeed : paginationSpeed 177 }); 178 }); 179 180 181 // Modall fix for iOS 182 183 jQuery('.member-detail-button').on( "touchend", function() { 184 185 var target = jQuery(this).data('target'); 186 jQuery(target).addClass('in').css({'display':'block','opacity':'1'}); 187 188 }); 189 190 jQuery('.modal-head .close').on( "touchend", function() { 191 192 var target = jQuery(this).closest('.modal').attr('id'); 193 jQuery('#'+target).removeClass('in').css({'display':'none','opacity':'0'}); 194 195 }); 196 197 198 199/* ============================================== 200CAROUSEL SLIDER FOR CLIENTS 201=============================================== */ 202 203 jQuery('.clients').each( function() { 204 205 var autoPlay = 6000; 206 var slideSpeed = 700; 207 var paginationSpeed = 900; 208 209 if ( jQuery(this).data('carousel-autoplay') != '' && jQuery(this).data('carousel-autoplay') != '6000' ) { 210 autoPlay = jQuery(this).data('carousel-autoplay'); 211 } 212 213 if ( jQuery(this).data('carousel-paginationspeed') != '' && jQuery(this).data('carousel-paginationspeed') != '900' ) { 214 paginationSpeed = jQuery(this).data('carousel-paginationspeed'); 215 } 216 217 jQuery(this).owlCarousel({ 218 items : 3, 219 // Responsive Settings 220 itemsDesktop : [1169,3], 221 itemsDesktopSmall : [979,3], 222 itemsTablet : [768,2], 223 itemsTabletSmall : false, 224 itemsMobile : [479,1], 225 // End Responsive Settings 226 mouseDrag : false, 227 pagination : true, 228 navigation : false, 229 touchDrag : true, 230 stopOnHover: true, 231 slideSpeed : slideSpeed, 232 autoPlay : autoPlay, 233 paginationSpeed : paginationSpeed, 234 rewindSpeed : paginationSpeed 235 }); 236 237 }); 238 239 240/* ============================================== 241CAROUSEL SLIDER FOR CLIENT LOGOS 242=============================================== */ 243 244jQuery('.logos').each( function() { 245 246 var autoPlay = 6000; 247 var slideSpeed = 700; 248 var paginationSpeed = 900; 249 var carouselCols = 5; 250 251 if ( jQuery(this).data('carousel-autoplay') != '' && jQuery(this).data('carousel-autoplay') != '6000' ) { 252 autoPlay = jQuery(this).data('carousel-autoplay'); 253 } 254 255 if ( jQuery(this).data('carousel-slidespeed') != '' && jQuery(this).data('carousel-slidespeed') != '700' ) { 256 slideSpeed = jQuery(this).data('carousel-slidespeed'); 257 } 258 259 if ( jQuery(this).data('carousel-paginationspeed') != '' && jQuery(this).data('carousel-paginationspeed') != '900' ) { 260 paginationSpeed = jQuery(this).data('carousel-paginationspeed'); 261 } 262 263 if ( jQuery(this).data('carousel-cols') != '' && jQuery(this).data('carousel-cols') != '5' ) { 264 carouselCols = jQuery(this).data('carousel-cols'); 265 } 266 267 jQuery(this).owlCarousel({ 268 items : carouselCols, 269 // Responsive Settings 270 itemsDesktop : [1169,5], 271 itemsDesktopSmall : [979,4],
272 itemsTablet : [768,3], 273 itemsTabletSmall : false, 274 itemsMobile : [479,2], 275 // End Responsive Settings 276 slideSpeed : slideSpeed, 277 autoPlay : autoPlay, 278 paginationSpeed : paginationSpeed, 279 rewindSpeed : paginationSpeed 280 }); 281 282}); 283 284 285/* ============================================== 286FEATURED WORKS SLIDER 287=============================================== */ 288 289 jQuery(".vntd-portfolio-carousel .works").each( function() { 290 291 var autoPlay = false; 292 var slideSpeed = 700; 293 var paginationSpeed = 900; 294 295 if ( jQuery(this).data('carousel-autoplay') != '' && jQuery(this).data('carousel-autoplay') != 'false' ) { 296 autoPlay = jQuery(this).data('carousel-autoplay'); 297 } 298 299 if ( jQuery(this).data('carousel-slidespeed') != '' && jQuery(this).data('carousel-slidespeed') != '700' ) { 300 slideSpeed = jQuery(this).data('carousel-slidespeed'); 301 } 302 303 if ( jQuery(this).data('carousel-paginationspeed') != '' && jQuery(this).data('carousel-paginationspeed') != '900' ) { 304 paginationSpeed = jQuery(this).data('carousel-paginationspeed'); 305 } 306 307 jQuery(this).owlCarousel({ 308 items : 4, 309 // Responsive Settings 310 itemsDesktop : [1169,4], 311 itemsDesktopSmall : [1100,3], 312 itemsTablet : [960,2], 313 itemsMobile : [640,1], 314 // End Responsive Settings 315 pagination : false, 316 navigation : true, 317 mouseDrag : false, 318 stopOnHover : true, 319 autoPlay : autoPlay, 320 slideSpeed : slideSpeed, 321 paginationSpeed : paginationSpeed, 322 rewindSpeed : paginationSpeed 323 }); 324 }); 325 326 327/* ============================================== 328SERVİCES SLIDER 329=============================================== */ 330 331 jQuery(".service-boxes").each( function() { 332 333 var autoPlay = 6000; 334 var slideSpeed = 700; 335 var paginationSpeed = 900; 336 337 if ( jQuery(this).data('carousel-autoplay') != '' && jQuery(this).data('carousel-autoplay') != '6000' ) { 338 autoPlay = jQuery(this).data('carousel-autoplay'); 339 } 340 341 if ( jQuery(this).data('carousel-slidespeed') != '' && jQuery(this).data('carousel-slidespeed') != '700' ) { 342 slideSpeed = jQuery(this).data('carousel-slidespeed'); 343 } 344 345 if ( jQuery(this).data('carousel-paginationspeed') != '' && jQuery(this).data('carousel-paginationspeed') != '900' ) { 346 paginationSpeed = jQuery(this).data('carousel-paginationspeed'); 347 } 348 349 jQuery(this).owlCarousel({ 350 items : 4, 351 // Responsive Settings 352 itemsDesktop : [1169,4], 353 itemsDesktopSmall : [979,3], 354 itemsTablet : [768,2], 355 itemsTabletSmall : false, 356 itemsMobile : [479,1], 357 stopOnHover: true, 358 // End Responsive Settings 359 pagination : false, 360 navigation : true, 361 mouseDrag : true, 362 autoPlay : autoPlay, 363 slideSpeed : slideSpeed, 364 paginationSpeed : paginationSpeed, 365 rewindSpeed : paginationSpeed 366 }); 367 368 }); 369 370/* ============================================== 371FULLSCREEN VIDEO PLAYER 372=============================================== */ 373 374jQuery(".player").each(function() { 375 jQuery(this).mb_YTPlayer(); 376}); 377 378/* ============================================== 379FLEX SLIDER FOR TESTIMONIALS 380=============================================== */ 381 382 jQuery('.testimonials').each( function() { 383 384 var slideshowSpeed = 5000; 385 var animationSpeed = 500; 386 387 if ( jQuery(this).data('slideshowspeed') != '' && jQuery(this).data('slideshowspeed') != '5000' ) { 388 slideshowSpeed = jQuery(this).data('slideshowspeed'); 389 } 390 391 if ( jQuery(this).data('animationspeed') != '' && jQuery(this).data('animationspeed') != '500' ) { 392 animationSpeed = jQuery(this).data('animationspeed'); 393 } 394 395 jQuery(this).flexslider({ 396 animation: "fade", 397 selector: "ul.text-slider li.text", 398 controlNav: false, 399 directionNav: true , 400 slideshowSpeed: slideshowSpeed, 401 animationSpeed: animationSpeed, 402 start: function(slider){ 403 jQuery('body').removeClass('loading'); 404 } 405 }); 406 407 }); 408 409 var $wpAdminBar = jQuery('#wpadminbar'); 410 if ($wpAdminBar.length) { 411 jQuery("#navigation-sticky").sticky({topSpacing:$wpAdminBar.height()}); 412 } else { 413 jQuery("#navigation-sticky").sticky({topSpacing:0}); 414 } 415 416/* ============================================== 417SOFT SCROLL EFFECT FOR NAVIGATION LINKS 418=============================================== */ 419 var firstScroll = true; 420 421 jQuery('.nav-menu-desktop a,.scroll,.nav-menu-desktop .ex-link a,a.ex-link,.slide-button,.page-numbers').on( 'click', function(event) { 422 423 if(jQuery(this).hasClass('ex-link') && document.getElementById("pageloader") || jQuery(this).closest('li').hasClass('ex-link') && document.getElementById("pageloader")) { 424 if( /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent) ) { 425 426 jQuery('.mbYTP_wrapper').addClass('mobile-bg'); 427 jQuery('section , div').addClass('b-scroll'); 428 jQuery('.animated').addClass('visible'); 429 430 } 431 else{ 432 //if (jQuery.browser.mozilla) {} 433 //else if (jQuery.browser.safari) {} 434 //else{ 435 // Select to link 436 437 //} 438 } 439 var Exlink = this.getAttribute('href'); 440 // Fade In Page Loader 441 jQuery('#pageloader').fadeIn(350, function(){ 442 jQuery(".mid").fadeIn(); 443 jQuery(".outter").fadeIn(); 444 document.location.href = Exlink; 445 }); 446 return false;
447 448 } 449 450 var $anchor = jQuery(this); 451 452 if ( $anchor.attr('href').indexOf( '#' ) !== -1 ) { 453 454 var headerH = jQuery('#navigation, #navigation-sticky').outerHeight(); 455 var extra = 0; 456 457 var scrollSpeed = 900; 458 var northData = jQuery('#north-data'); 459 if ( northData.length > 0 ) { 460 if ( northData.data('scroll-speed') != '' && northData.data('scroll-speed') != 1200 ) { 461 scrollSpeed = northData.data('scroll-speed'); 462 } 463 } 464 465 jQuery('html,body').stop().animate({ 466 scrollTop: jQuery($anchor.attr('href')).offset().top + extra - headerH + "px" 467 },scrollSpeed, 'easeInOutExpo', function() { 468 if ( firstScroll == true ) { 469 jQuery('html,body').stop().animate({ 470 scrollTop: jQuery($anchor.attr('href')).offset().top + extra - headerH + "px" 471 },scrollSpeed, 'easeInOutExpo' ); 472 firstScroll = false; 473 } 474 475 }); 476 477 event.preventDefault(); 478 479 } 480 481 }); 482 483 484/* ============================================== 485NAVIGATION SECTION CHANGEABLE BACKGROUND SCRIPT 486=============================================== */ 487 488 var menu = jQuery('#navigation'); 489 jQuery(window).scroll(function () { 490 var y = jQuery(this).scrollTop(); 491 var homeH,z,homeHOffset; 492 homeH = homeHOffset = 0; 493 if(document.getElementById("first")) { 494 homeH = jQuery('#first').outerHeight(); 495 homeHOffset = jQuery('#first').offset().top; 496 } 497 498 var headerH = jQuery('#navigation').outerHeight(); 499 z = homeHOffset + homeH - headerH; 500 if (y >= z) { 501 menu.removeClass('first-nav').addClass('second-nav'); 502 } 503 else{ 504 menu.removeClass('second-nav').addClass('first-nav'); 505 } 506 }); 507 508 509 510/* ============================================== 511BACK TO TOP BUTTON 512=============================================== */ 513 514 // hide #back-top first 515 jQuery("#back-top").hide(); 516 517 // fade in #back-top 518 jQuery(window).scroll(function () { 519 if (jQuery(this).scrollTop() > 500) { 520 jQuery('#back-top').fadeIn(); 521 } else { 522 jQuery('#back-top').fadeOut(); 523 } 524 }); 525 526/* ============================================== 527WHAT WE DO EFFECTS 528=============================================== */ 529 530 var $containerFirst = jQuery('.w-items'); 531 532 $containerFirst.isotope({ 533 resizable: false, 534 //masonry: { columnWidth: $containerFirst.width() / 5 }, 535 itemSelector : '.w-item' , 536 hiddenStyle: { opacity: 0, }, 537 visibleStyle: { opacity: 1,}, 538 transformsEnabled: false, 539 }); 540 541 var $optionSets = jQuery('#w-options .w-option-set'), 542 $optionLinks = $optionSets.find('a'); 543 544 545 var first_tab = jQuery('#w-options .w-option-set li:first-child a').attr('data-option-value'); 546 // Your First Selected Item 547 $containerFirst.isotope({ filter: first_tab }); 548 549 $optionLinks.on( 'click', function(){ 550 var $this = jQuery(this); 551 552 // don't proceed if already selected 553 if ( $this.hasClass('selected') ) { 554 return false; 555 } 556 var $optionSet = $this.parents('.w-option-set'); 557 $optionSet.find('.selected').removeClass('selected'); 558 $this.addClass('selected'); 559 560 // make option object dynamically, i.e. { filter: '.my-filter-class' } 561 var options = {}, 562 key = $optionSet.attr('data-option-key'), 563 value = $this.attr('data-option-value'); 564 // parse 'false' as false boolean 565 value = value === 'false' ? false : value; 566 options[ key ] = value; 567 if ( key === 'layoutMode' && typeof changeLayoutMode === 'function' ) { 568 // changes in layout modes need extra logic 569 changeLayoutMode( $this, options ) 570 } else { 571 // otherwise, apply new options 572 $containerFirst.isotope( options ); 573 } 574 575 if( /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent) ) { 576 var wItemsTop = jQuery('.w-items').offset().top; 577 578 var headerHH = jQuery('#navigation, #navigation-sticky').outerHeight(); 579 580 var AdminBarHH = 0; 581 582 if (jQuery('#wpadminbar').length) { 583 var AdminBarHH = jQuery('#wpadminbar').height(); 584 } 585 586 jQuery('html,body').stop().animate({ 587 scrollTop: wItemsTop - headerHH - AdminBarHH - 20 + "px" 588 },600, 'easeInOutExpo'); 589 } 590 591 return false;
592 }); 593 594 jQuery(window).resize(function () { 595 if(jQuery('.w-items').length) { 596 jQuery('.w-items').isotope('reLayout'); 597 } 598 jQuery( '.vntd-fullscreen-slider' ).css({ 'height' : jQuery(window).height() }); 599 }); 600 601 602/* ============================================== 603PORTFOLIO ITEMS 604=============================================== */ 605 606 var $container = jQuery('.portfolio-items'); 607 608 $container.isotope({ 609 itemSelector : '.item' 610 }); 611 612 jQuery(window).resize( function() { 613 $container.isotope( 'reLayout' ); 614 }); 615 616 var $optionSets = jQuery('#options .option-set'), 617 $optionLinks = $optionSets.find('a'); 618 619 $optionLinks.on( 'click', function(){ 620 var $this = jQuery(this); 621 622 // don't proceed if already selected 623 if ( $this.hasClass('selected') ) { 624 return false; 625 } 626 var $optionSet = $this.parents('.option-set'); 627 $optionSet.find('.selected').removeClass('selected'); 628 $this.addClass('selected'); 629 630 // make option object dynamically, i.e. { filter: '.my-filter-class' } 631 var options = {}, 632 key = $optionSet.attr('data-option-key'), 633 value = $this.attr('data-option-value'); 634 // parse 'false' as false boolean 635 value = value === 'false' ? false : value; 636 options[ key ] = value; 637 if ( key === 'layoutMode' && typeof changeLayoutMode === 'function' ) { 638 // changes in layout modes need extra logic 639 changeLayoutMode( $this, options ) 640 } else { 641 // otherwise, apply new options 642 $container.isotope( options ); 643 } 644 645 return false; 646 }); 647 648 649 650 }); // END FUNCTION 651 652/* ============================================== 653PARALLAX CALLING 654=============================================== */ 655 656 ( function ( $ ) { 657 'use strict'; 658 jQuery(document).ready(function(){ 659 660 if ( jQuery(".fact").length > 0 && jQuery(".fact").appear !== undefined ) { 661 jQuery(".fact").appear(function(){ 662 jQuery('.fact').each(function(){ 663 var dataperc = jQuery(this).attr('data-perc'); 664 jQuery(this).find('.factor').delay(6000).countTo({ 665 from: 0, 666 to: dataperc, 667 speed: 3000, 668 refreshInterval: 50, 669 670 }); 671 }); 672 }); 673 } 674 675 /* ============================================== 676 HOME PAGE IMAGE SLIDER (SUPER SLIDES) 677 =============================================== */ 678 679 jQuery('.fullscreen-slider , .p-section').each( function() { 680 681 var sliderSpeed = 12000; 682 var animationSpeed = 800; 683 var animationType = 'fade'; 684 685 if ( jQuery(this).data('bg-sliderspeed') != '' && jQuery(this).data('bg-sliderspeed') != '12000' ) { 686 sliderSpeed = jQuery(this).data('bg-sliderspeed'); 687 } 688 if ( jQuery(this).data('bg-animationspeed') != '' && jQuery(this).data('bg-animationspeed') != '800' ) { 689 animationSpeed = jQuery(this).data('bg-animationspeed'); 690 } 691 if ( jQuery(this).data('bg-animationtype') != '' && jQuery(this).data('bg-animationtype') != 'fade' ) { 692 animationType = jQuery(this).data('bg-animationtype'); 693 } 694 695 jQuery(this).superslides({ 696 play: sliderSpeed, 697 animation_speed: animationSpeed, 698 animation: animationType, 699 inherit_height_from: window, 700 }); 701 702 }); 703 704 705 jQuery( '.fullscreen-slider,.vntd-fullscreen-slider' ).css({ 'height' : jQuery(window).height() }); 706 707 /* ============================================== 708 CAROUSEL SLIDER FOR HOME BOXES (V1) 709 =============================================== */ 710 711 jQuery(".home-boxes").each( function() { 712 713 var autoPlay = 15000; 714 var slideSpeed = 400; 715 var paginationSpeed = 600; 716 717 if ( jQuery(this).data('carousel-autoplay') != '' && jQuery(this).data('carousel-autoplay') != '15000' ) { 718 autoPlay = jQuery(this).data('carousel-autoplay'); 719 } 720 if ( jQuery(this).data('carousel-slidespeed') != '' && jQuery(this).data('carousel-slidespeed') != '400' ) { 721 slideSpeed = jQuery(this).data('carousel-slidespeed'); 722 } 723 if ( jQuery(this).data('carousel-paginationspeed') != '' && jQuery(this).data('carousel-paginationspeed') != '600' ) { 724 paginationSpeed = jQuery(this).data('carousel-paginationspeed'); 725 } 726 727 jQuery(this).owlCarousel({ 728 items : 3, 729 // Responsive Settings 730 itemsDesktop : [1169,3], 731 itemsDesktopSmall : [979,2], 732 itemsTablet : [600,1], 733 itemsTabletSmall : false, 734 itemsMobile : [560,1], 735 stopOnHover: true, 736 // End Responsive Settings 737 slideSpeed : slideSpeed, 738 autoPlay : autoPlay, 739 paginationSpeed : paginationSpeed, 740 rewindSpeed : paginationSpeed 741 }); 742 743 }); 744 745 746 /* ============================================== 747 FLEX SLIDER FOR HOME TEXTS V1 748 =============================================== */ 749 750 jQuery('.v1 .text-slider').each( function() { 751 752 var animationSpeed = 600; 753 var slideshowSpeed = 5000; 754 755 if ( jQuery(this).data('animationspeed') != '' && jQuery(this).data('animationspeed') != '600' ) { 756 animationSpeed = jQuery(this).data('animationspeed'); 757 } 758 if ( jQuery(this).data('slideshowspeed') != '' && jQuery(this).data('slideshowspeed') != '5000' ) { 759 slideshowSpeed = jQuery(this).data('slideshowspeed'); 760 } 761 762 jQuery(this).flexslider({ 763 animation: "slide", 764 selector: "ul.home-texts li.slide", 765 controlNav: false, 766 directionNav: true, 767 touch: true, 768 animationSpeed: animationSpeed, 769 slideshowSpeed: slideshowSpeed, 770 direction: "vertical", 771 start: function(slider){ 772 jQuery('body').removeClass('loading'); 773 } 774 }); 775 776 }); 777 778 /* ============================================== 779 FLEX SLIDER FOR HOME TEXTS V2 780 =============================================== */ 781 782 jQuery('.v2 .text-slider').each( function() { 783 784 var animationSpeed = 600; 785 var slideshowSpeed = 5000; 786 787 if ( jQuery(this).data('animationspeed') != '' && jQuery(this).data('animationspeed') != '600' ) { 788 animationSpeed = jQuery(this).data('animationspeed'); 789 } 790 if ( jQuery(this).data('slideshowspeed') != '' && jQuery(this).data('slideshowspeed') != '5000' ) { 791 slideshowSpeed = jQuery(this).data('slideshowspeed'); 792 } 793 794 jQuery(this).flexslider({ 795 animation: "fade", 796 selector: "ul.home-texts li.slide", 797 controlNav: false, 798 directionNav: true, 799 animationSpeed: animationSpeed, 800 slideshowSpeed: slideshowSpeed, 801 direction: "vertical", 802 start: function(slider){ 803 jQuery('body').removeClass('loading'); 804 } 805 }); 806 }); 807 808 809 jQuery('.panel-group .panel:first-child').find('.panel-collapse').addClass('in'); 810 811 jQuery('.tab-content .tab-pane:first-child').addClass('active in'); 812 813 jQuery(window).on( 'load', function () {
814 parallaxInit(); 815 }); 816 function parallaxInit() { 817 testMobile = isMobile.any(); 818 if (testMobile == null) 819 { 820 //Parallax Classes 821 jQuery('body .parallax').each(function() { 822 jQuery(this).parallax("50%", 0.5); 823 }); 824 } 825 } 826 parallaxInit(); 827 }); 828 //Mobile Detect 829 var testMobile; 830 var isMobile = { 831 Android: function() { 832 return navigator.userAgent.match(/Android/i); 833 }, 834 BlackBerry: function() { 835 return navigator.userAgent.match(/BlackBerry/i); 836 }, 837 iOS: function() { 838 return navigator.userAgent.match(/iPhone|iPad|iPod/i); 839 }, 840 Opera: function() { 841 return navigator.userAgent.match(/Opera Mini/i); 842 }, 843 Windows: function() { 844 return navigator.userAgent.match(/IEMobile/i); 845 }, 846 any: function() { 847 return (isMobile.Android() || isMobile.BlackBerry() || isMobile.iOS() || isMobile.Opera() || isMobile.Windows()); 848 } 849 }; 850 }( jQuery )); 851 852/* ============================================== 853COUNT FACTORS 854=============================================== */ 855 856 857(function($) { 858 859 'use strict'; 860 861 $.fn.countTo = function(options) { 862 // merge the default plugin settings with the custom options 863 options = $.extend({}, $.fn.countTo.defaults, options || {}); 864 865 // how many times to update the value, and how much to increment the value on each update 866 var loops = Math.ceil(options.speed / options.refreshInterval), 867 increment = (options.to - options.from) / loops; 868 869 return jQuery(this).each(function() { 870 var _this = this, 871 loopCount = 0, 872 value = options.from, 873 interval = setInterval(updateTimer, options.refreshInterval); 874 875 function updateTimer() { 876 value += increment; 877 loopCount++; 878 jQuery(_this).html(value.toFixed(options.decimals)); 879 880 if (typeof(options.onUpdate) == 'function') { 881 options.onUpdate.call(_this, value); 882 } 883 884 if (loopCount >= loops) { 885 clearInterval(interval); 886 value = options.to; 887 888 if (typeof(options.onComplete) == 'function') { 889 options.onComplete.call(_this, value); 890 } 891 } 892 } 893 }); 894 }; 895 896 $.fn.countTo.defaults = { 897 from: 0, // the number the element should start at 898 to: 100, // the number the element should end at 899 speed: 1000, // how long it should take to count between the target numbers 900 refreshInterval: 100, // how often the element should be updated 901 decimals: 0, // the number of decimal places to show 902 onUpdate: null, // callback method for every time the element is updated, 903 onComplete: null, // callback method for when the element finishes updating 904 }; 905})(jQuery); 906 907/* ============================================== 908ANIMATED SKILL BARS 909=============================================== */ 910jQuery(window).on( 'load', function(){ 911 912 'use strict'; 913 914 jQuery('.modal-right .progress-bar').each(function() { 915 datavl = jQuery(this).attr('data-value'), 916 jQuery(this).animate({ "width" : datavl + "%"}, '300'); 917 }); 918 919}); 920 921 922 923 924 jQuery(window).on( 'load', function(){ 925 926 'use strict'; 927 928 /* ============================================== 929 NAVIGATION SECTION CHANGEABLE BACKGROUND SCRIPT 930 =============================================== */ 931 932 setTimeout(updateScrollSpy, 1000); 933 934 }); 935 936 937function updateScrollSpy() { 938 jQuery('body').scrollspy({ 939 target: '.nav-menu-desktop', 940 offset: 95 941 }); 942} 943/* ============================================== 944MOBILE BACKGROUND FOR VIDEO BACKGROUNDS 945=============================================== */ 946 947jQuery(window).on( 'load', function(){ 948 'use strict'; 949 if( /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent) ) { 950 //jQuery('.mbYTP_wrapper').addClass('mobile-bg'); 951 952 if ( jQuery('.mbYTP_wrapper').closest('.vc_row').css('background-image') == 'none' ) { 953 //console.log("Bg image: " + jQuery('.mbYTP_wrapper').closest('.vc_row').css('background-image') ); 954 jQuery('.mbYTP_wrapper').addClass('mobile-bg'); 955 jQuery('.mbYTP_wrapper').remove(); 956 } else { 957 jQuery('.mbYTP_wrapper').remove(); 958 } 959 960 jQuery('section , div').addClass('b-scroll'); 961 jQuery('.animated').addClass('visible'); 962 963 if( jQuery('body').hasClass('header-not-sticky-mobile') ) { 964 jQuery('.first-nav').removeClass('first-nav').addClass('second-nav'); 965 } 966 967 } 968 else{ 969 //ANIMATED ITEMS 970 if ( jQuery('.animated.vntd-animated').length > 0 ) { 971 jQuery('.animated.vntd-animated').appear(function() { 972 973 var elem = jQuery(this); 974 var animation = elem.data('animation'); 975 if(!animation) { 976 animation = 'fadeInLeft'; 977 } 978 if ( !elem.hasClass('visible') ) { 979 980 var animationDelay = elem.data('animation-delay'); 981 if ( animationDelay ) { 982 setTimeout(function(){ 983 elem.addClass( animation + " visible" ); 984 }, animationDelay); 985 } else { 986 setTimeout(function(){ 987 elem.addClass( animation + " visible" ); 988 }, 300); 989 } 990 } 991 }); 992 } 993 994 } 995 996}); 997 998 999jQuery(document).ready(function() { 1000 1001 'use strict'; 1002 1003 var firstScroll = true; 1004 1005 jQuery(window).trigger('resize'); 1006 1007 /* ============================================== 1008 MOBILE NAV BUTTON 1009 =============================================== */ 1010 1011 jQuery( ".mobile-nav-button" ).on( 'click',function() { 1012 jQuery( ".nav-inner .nav-menu-mobile" ).slideToggle( "medium", function() { 1013 if ( jQuery( ".nav-inner .nav-menu-mobile" ).hasClass( 'nav-menu-mobile-open') ) { 1014 jQuery( ".nav-inner .nav-menu-mobile" ).removeClass( 'nav-menu-mobile-open' ); 1015 } else { 1016 jQuery( ".nav-inner .nav-menu-mobile" ).addClass( 'nav-menu-mobile-open' ); 1017 } 1018 }); 1019 //jQuery(".nav-inner .nav-menu").css('display','block'); 1020 }); 1021 1022 if ( jQuery('.progress-bar').length > 0 ) { 1023 jQuery('.progress-bar').appear(function(){ 1024 datavl = jQuery(this).attr('data-value'), 1025 jQuery(this).animate({ "width" : datavl + "%"}, '300'); 1026 }); 1027 } 1028 1029 jQuery('.nav-inner .nav-menu-desktop ul.nav li a').on( 'click', function () { 1030 if (jQuery(window).width() < 1000) { 1031 jQuery(".nav-menu").slideToggle("2000") 1032 } 1033 }); 1034 1035 jQuery('.nav-menu-mobile a').on( 'click', function(event) { 1036 var parent = jQuery(this).closest('li'); 1037 //event.preventDefault(); 1038 1039 if( parent.hasClass('menu-item-has-children') && !jQuery(this).attr('data-click-count') ) { 1040 1041 parent.find("> .dropdown-menu,> .sub-menu").slideToggle("medium"); 1042 //jQuery(this).attr('href', '#'); 1043 jQuery(this).attr( 'data-click-count', 1 ); 1044 event.preventDefault(); 1045 1046 } else { 1047 1048 if(jQuery(this).hasClass('ex-link') && document.getElementById("pageloader")) { 1049 1050 var Exlink = this.getAttribute('href'); 1051 // Fade In Page Loader 1052 jQuery('#pageloader').fadeIn(350, function(){ 1053 jQuery(".mid").fadeIn(); 1054 jQuery(".outter").fadeIn(); 1055 document.location.href = Exlink; 1056 }); 1057 return false;
1058 1059 } 1060 1061 var $anchor = jQuery(this); 1062 var headerH = jQuery('#navigation, #navigation-sticky').outerHeight(); 1063 var extra = 0; 1064 1065 jQuery(this).attr( 'data-click-count', 0 ); 1066 if( parent.hasClass('menu-item-has-children') ) { 1067 parent.attr( 'data-click-count', 0 ); 1068 } 1069 var scrollSpeed = 1200; 1070 var northData = jQuery('#north-data'); 1071 1072 if ( northData.length > 0 ) { 1073 if ( northData.data('scroll-speed') != '' && northData.data('scroll-speed') != 1200 ) { 1074 scrollSpeed = northData.data('scroll-speed'); 1075 } 1076 } 1077 1078 jQuery('html,body').stop().animate({ 1079 scrollTop: jQuery($anchor.attr('href')).offset().top + extra - headerH + "px" 1080 }, scrollSpeed, 'easeInOutExpo', function() { 1081 if ( firstScroll == true ) { 1082 jQuery('html,body').stop().animate({ 1083 scrollTop: jQuery($anchor.attr('href')).offset().top + extra - headerH + "px" 1084 },scrollSpeed, 'easeInOutExpo' ); 1085 firstScroll = false; 1086 } 1087 1088 }); 1089 1090 event.preventDefault(); 1091 1092 //var linkURL = this.getAttribute('href'); 1093 //document.location.href = linkURL; 1094 1095 if ( jQuery(window).width() < 1006 ) { 1096 jQuery( ".nav-inner .nav-menu-mobile" ).slideToggle( "medium" ); 1097 } 1098 1099 } 1100 1101 1102 }); 1103 1104 1105});
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.