1(function($) { 2 "use strict"; // Start of use strict 3 4 5 /*Logo*/ 6 $('.har_logo_eq span').each(function(){ 7 var animated = $(this); 8 function animate() { 9 animated.animate({ 10 height: Math.floor(Math.random() * 100) + '%' 11 }, 350); 12 } 13 setInterval(animate, 350); 14 }); 15 16 /*Firefly*/ 17 if ($('.har_firefly').length>0) { 18 $('.har_firefly').each(function(){ 19 var total = $(this).attr('data-total'); 20 var minPixel = $(this).attr('data-minPixel'); 21 var maxPixel = $(this).attr('data-maxPixel'); 22 $.firefly({ 23 minPixel: minPixel, 24 maxPixel: maxPixel, 25 color: 'none', 26 total : total, 27 on:'.har_firefly' 28 }); 29 }); 30 31 32 }; 33 34 35 /* Logo Lettering */ 36 if ($("#har_text_animation .har_studio_animation").length>0) 37 $("#har_text_animation .har_studio_animation").lettering(); 38 $("#har_text_animation .har_studio_animation span").each(function(){ 39 var min = 0; 40 var max = 50; 41 var randomNumber = Math.floor(Math.random()*(max-min+1)+min); 42 $(this).css('transition-delay', '0.'+randomNumber+'s'); 43 }); 44 45 /*Countdown*/ 46 $('.har_countdown').each(function(){ 47 var year = $(this).attr('data-year'); 48 var month = $(this).attr('data-month'); 49 var day = $(this).attr('data-day'); 50 $(this).countdown({until: new Date(year,month-1,day)}); 51 52 }); 53 54 /*CountTo*/ 55 $('.har_timer').appear(function() { 56 var e = $(this); 57 e.countTo({ 58 from: 0, 59 to: e.html(), 60 speed: 1300, 61 refreshInterval: 60 62 }) 63 }) 64 $('.date_picker').datepicker(); 65 66 /*RSVP Form*/ 67 $(".har_form").validate({ 68 submitHandler: function(form) { 69 var type = $(form).attr('id'); 70 send_form(type); 71 return false; 72 } 73 }); 74 75 function send_form(type){ 76 var arr = []; 77 $("#"+type+" .form-control").each(function(){ 78 79 var element = $(this).attr('name'); 80 var value = $(this).val(); 81 $(this).css({border:"1px solid #c4c4c4"}); 82 if($(this).prop('required') && value =="") { 83 $(this).css({border:"2px solid red"}); 84 $(this).focus(); 85 return false; 86 } 87 arr.push("'&"+element+"=' + "+value); 88 }) 89 90 91 var dataString = (arr.join (' + ')); 92 93 $.ajax({ 94 method: "POST", 95 url: "http://formspree.io/[email protected]", 96 data: dataString, 97 dataType: "json", 98 success: function() { 99 $("#"+type).html("<div id='form_send_message'>Thank you for your request, we will contact you as soon as possible.</div>", 1500); 100 } 101 }); 102 103 104 } 105 106 /*Gallery Lightbox*/ 107 $('.lightbox').magnificPopup({ 108 type: 'image', 109 gallery:{ 110 enabled:true 111 } 112 }); 113 $('.video').magnificPopup({ 114 type: 'iframe', 115 iframe: { 116 markup: '<div class="mfp-iframe-scaler">'+ 117 '<div class="mfp-close"></div>'+ 118 '<iframe class="mfp-iframe" frameborder="0" allowfullscreen></iframe>'+ 119 '</div>', // HTML markup of popup, `mfp-close` will be replaced by the close button 120 121 patterns: { 122 youtube: { 123 index: 'youtube.com/', // String that detects type of video (in this case YouTube). Simply via url.indexOf(index). 124 125 id: 'v=', // String that splits URL in a two parts, second part should be %id% 126 // Or null - full URL will be returned 127 // Or a function that should return %id%, for example: 128 // id: function(url) { return 'parsed id'; } 129 130 src: 'http://www.youtube.com/embed/%id%?autoplay=1' // URL that will be set as a source for iframe. 131 }, 132 vimeo: { 133 index: 'vimeo.com/', 134 id: '/', 135 src: 'http://player.vimeo.com/video/%id%?autoplay=1' 136 }, 137 gmaps: { 138 index: '//maps.google.', 139 src: '%id%&output=embed' 140 } 141 142 // you may add here more sources 143 144 }, 145 146 srcAction: 'iframe_src', // Templating object key. First part defines CSS selector, second attribute. "iframe_src" means: find "iframe" and set attribute "src". 147 } 148 149 }); 150 151 /*Instafeed*/ 152 if ($('#instagram-carousel').length>0) { 153 var feed = new Instafeed({ 154 get: 'user', 155 userId: 4822614316, 156 accessToken: '4822614316.1677ed0.91b18a0fed03493ebb793557e1b887ea', 157 sortBy: 'most-liked', 158 template: '<a href="{{link}}" target="_blank" class="har_insta_item"><img class="img-responsive" src="{{image}}" /></a>', 159 target: 'instagram-carousel', 160 limit: 9, 161 resolution: 'standard_resolution', 162 after: function () { 163 $('#instagram-carousel').owlCarousel({ 164 items: 5, 165 navigation: false, 166 pagination: false, 167 autoPlay: 4000, 168 loop:true 169 }); 170 } 171 172 });
173 feed.run(); 174 } 175 176 177 /*OWL Intro Slider*/ 178 $(".har_slider_carousel").owlCarousel({ 179 navigation : true, 180 pagination: false, 181 responsive: true, 182 responsiveRefreshRate : 200, 183 responsiveBaseElement:window, 184 slideSpeed : 300, 185 addClassActive:true, 186 paginationSpeed : 200, 187 rewindSpeed : 300, 188 items: 1, 189 autoPlay : 8000, 190 touchDrag:false, 191 singleItem:true, 192 transitionStyle: 'fade', 193 navigationText:['<i class="ti ti-angle-left"></i>','<i class="ti ti-angle-right"></i>'] 194 }); 195 196 /*OWL Team*/ 197 $(".har_team_slider").owlCarousel({ 198 navigation : true, 199 responsive: true, 200 addClassActive:true, 201 items:3, 202 itemsTablet:[1200,2], 203 itemsMobile : [700,1], 204 itemsDesktop:3, 205 autoPlay : false, 206 touchDrag:false, 207 navigationText:['<i class="ti ti-angle-left"></i>','<i class="ti ti-angle-right"></i>'] 208 }); 209 210 /*OWL Double*/ 211 $(".har_db_slider").owlCarousel({ 212 navigation : false, 213 responsive: true, 214 addClassActive:true, 215 items:2, 216 itemsTablet:[1000,2], 217 itemsMobile : [569,1], 218 itemsDesktop:2, 219 autoPlay : true, 220 touchDrag:false, 221 navigationText:['<i class="ti ti-angle-left"></i>','<i class="ti ti-angle-right"></i>'] 222 }); 223 224 /* OWL Team Single*/ 225 $(".har_team_slider_single").owlCarousel({ 226 navigation : true, 227 responsive: true, 228 addClassActive:true, 229 items:1, 230 autoPlay : true, 231 singleItem:true, 232 autoHeight : true, 233 touchDrag:false, 234 navigationText:['<i class="ti ti-angle-left"></i>','<i class="ti ti-angle-right"></i>'] 235 }); 236 237 238 /*OWL Carousel in Shop Item*/ 239 240 $(".har_shop_item_slider").owlCarousel({ 241 navigation : true, 242 responsive: true, 243 addClassActive:true, 244 items:1, 245 itemsTablet:[1000,2], 246 itemsMobile : [700,1], 247 itemsDesktop:1, 248 autoPlay : true, 249 touchDrag:false, 250 navigationText:['<i class="ti ti-angle-left"></i>','<i class="ti ti-angle-right"></i>'] 251 }); 252 253 254 /* Twitter Feed */ 255 256 $('.tweets-feed').each(function(index) { 257 jQuery(this).attr('id', 'tweets-' + index); 258 }).each(function(index) { 259 260 var TweetConfig = { 261 "id": jQuery('#tweets-' + index).attr('data-widget-id'), 262 "domId": '', 263 "maxTweets": 3, 264 "enableLinks": true, 265 "showUser": true, 266 "showTime": true, 267 "dateFunction": '', 268 "showRetweet": false, 269 "customCallback": handleTweets 270 }; 271 function handleTweets(tweets) { 272 var x = tweets.length; 273 var n = 0; 274 var element = document.getElementById('tweets-' + index); 275 var html = '<ul class="slides">'; 276 while (n < x) { 277 html += '<li>' + tweets[n] + '</li>'; 278 n++; 279 } 280 html += '</ul>'; 281 element.innerHTML = html; 282 return html; 283 } 284 twitterFetcher.fetch(TweetConfig); 285 }); 286 287 288 289 /* Section Background */ 290 $('.har_image_bck').each(function(){ 291 var image = $(this).attr('data-image'); 292 var gradient = $(this).attr('data-gradient'); 293 var color = $(this).attr('data-color'); 294 var blend = $(this).attr('data-blend'); 295 var opacity = $(this).attr('data-opacity'); 296 var position = $(this).attr('data-position'); 297 var height = $(this).attr('data-height'); 298 if (image){ 299 $(this).css('background-image', 'url('+image+')'); 300 } 301 if (gradient){ 302 $(this).css('background-image', gradient); 303 } 304 if (color){ 305 $(this).css('background-color', color); 306 } 307 if (blend){ 308 $(this).css('background-blend-mode', blend); 309 } 310 if (position){ 311 $(this).css('background-position', position); 312 } 313 if (opacity){ 314 $(this).css('opacity', opacity); 315 } 316 if (height){ 317 $(this).css('height', height); 318 } 319 320 }); 321 322 323 /*Youtube Player*/ 324 325 if ($('#bgndVideo').length>0) { 326 $('#bgndVideo').YTPlayer(); 327 }; 328 329 330 331 332 /* Over */ 333 $('.har_over, .har_head_bck').each(function(){ 334 var color = $(this).attr('data-color'); 335 var image = $(this).attr('data-image'); 336 var opacity = $(this).attr('data-opacity'); 337 var blend = $(this).attr('data-blend'); 338 if (color){ 339 $(this).css('background-color', color); 340 } 341 if (image){ 342 $(this).css('background-image', 'url('+image+')'); 343 } 344 if (opacity){ 345 $(this).css('opacity', opacity); 346 } 347 if (blend){ 348 $(this).css('mix-blend-mode', blend); 349 } 350 }); 351 352 /* Map */ 353 $('.har_accordion_location').on("click", function(e){
354 e.preventDefault(); 355 $('.har_accordion_map').slideToggle(200); 356 }); 357 358 /* Map Studio*/ 359 $('.har_map_over').on("click", function(e){ 360 $(this).parents('.har_section').toggleClass('active_map'); 361 }); 362 363 /* Mobile Menu */ 364 $('.har_top_menu_mobile_link').on("click", function(e){ 365 $(this).next('.har_top_menu_cont').fadeToggle(); 366 $(this).parents('.har_light_nav').toggleClass('active'); 367 }); 368 369 370 371 /*Scroll Effect*/ 372 $('.har_go').on("click", function(e){ 373 var anchor = $(this); 374 $('html, body').stop().animate({ 375 scrollTop: $(anchor.attr('href')).offset().top 376 }, 300); 377 e.preventDefault(); 378 }); 379 380 /*Animation Block Delay*/ 381 382 $('div[data-animation=animation_blocks]').each(function(){ 383 var i = 0; 384 $(this).find('.har_icon_box, .har_news_block, .har_service_block, .skill-bar-content, .har_anim_box, .har_portfolio_item_poloroid, .panel-default').each(function(){ 385 $(this).css('transition-delay','0.'+i+'s'); 386 i++; 387 }) 388 }) 389 390 /*Increase-Decrease*/ 391 $('.increase-qty').on("click", function(e){ 392 var qtya = $(this).parents('.add-to-cart').find('.qty').val(); 393 var qtyb = qtya * 1 + 1; 394 $(this).parents('.add-to-cart').find('#qty').val(qtyb); 395 e.preventDefault(); 396 }); 397 $('.decrease-qty').on("click", function(e){ 398 var qtya = $(this).parents('.add-to-cart').find('#qty').val(); 399 var qtyb = qtya * 1 - 1; 400 if (qtyb < 1) { 401 qtyb = 1; 402 } 403 $(this).parents('.add-to-cart').find('#qty').val(qtyb); 404 e.preventDefault(); 405 }); 406 407 /* Shortcode Nav */ 408 var top_offset = $('header').height() - 1; 409 410 $('#nav-sidebar').onePageNav({ 411 currentClass: 'current', 412 changeHash: false, 413 scrollSpeed: 700, 414 scrollOffset: top_offset, 415 scrollThreshold: 0.5, 416 filter: '', 417 easing: 'swing', 418 }); 419 420 421 422 /* Bootstrap */ 423 $('[data-toggle="tooltip"]').tooltip(); 424 $('[data-toggle="popover"]').popover(); 425 426 /* Anchor Scroll */ 427 $(window).scroll(function(){ 428 if ($(window).scrollTop() > 100) { 429 $(".har_logo").addClass('active'); 430 $('body').addClass('har_first_step'); 431 432 } 433 else { 434 $('body').removeClass('har_first_step'); 435 $(".har_logo").removeClass('active'); 436 } 437 if ($(window).scrollTop() > 500) { 438 $('body').addClass('har_second_step'); 439 } 440 else { 441 $('body').removeClass('har_second_step'); 442 } 443 }); 444 445 /* Fixed for Parallax */ 446 $(".har_fixed").css("background-attachment","fixed"); 447 448 449 /* Submenu */ 450 $('.har_parent').on({ 451 mouseenter:function(){ 452 $(this).find('ul').stop().fadeIn(300); 453 },mouseleave:function(){ 454 $(this).find('ul').stop().fadeOut(300); 455 } 456 }); 457 458 /* Mobile Menu */ 459 460 $('.har_mobile_menu_content .har_parent').on("click", function(e){ 461 $(this).find('ul').slideToggle(300); 462 }); 463 $('.har_mobile_menu').on("click", function(e){ 464 $(this).toggleClass('active'); 465 $('.har_mobile_menu_hor').toggleClass('active'); 466 }); 467 468 $('.har_header_search').on({ 469 mouseenter:function(){ 470 $(this).find('.har_header_search_cont, .har_header_basket_cont').stop().fadeToggle(); 471 },mouseleave:function(){ 472 $(this).find('.har_header_search_cont, .har_header_basket_cont').stop().fadeToggle(); 473 } 474 }); 475 476 /* Top Menu Click to Section */ 477 $('.har_top_menu_cont a[href*=\\#]:not([href=\\#])').on("click", function(){ 478 $(".har_mobile_menu").trigger('click'); 479 $('.har_top_menu_cont a[href*=\\#]:not([href=\\#])').removeClass('active'); 480 $(this).addClass('active'); 481 482 if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'') 483 || location.hostname == this.hostname) { 484 485 var target = $(this.hash); 486 target = target.length ? target : $('[name=' + this.hash.slice(1) +']'); 487 if (target.length) { 488 $('html,body').animate({ 489 scrollTop: target.offset().top 490 }, 1000); 491 return false; 492 } 493 } 494 }); 495 496 497 /* Block Autheight */ 498 if( !device.tablet() && !device.mobile() ) { 499 $('.har_auto_height').each(function(){ 500 setEqualHeight($(this).find('div[class^="col"]')); 501 }); 502 } 503 if( device.tablet() && device.landscape() ) { 504 $('.har_auto_height').each(function(){ 505 setEqualHeight($(this).find('div[class^="col"]')); 506 }); 507 } 508 509 $(window).resize(function() { 510 if( !device.tablet() && !device.mobile() ) { 511 $('.har_auto_height').each(function(){ 512 setEqualHeight($(this).find('div[class^="col"]')); 513 }); 514 } 515 if( device.tablet() && device.landscape() ) { 516 $('.har_auto_height').each(function(){ 517 setEqualHeight($(this).find('div[class^="col"]')); 518 }); 519 } 520 }); 521 522 /*Boxes AutoHeight*/ 523 function setEqualHeight(columns) 524 { 525 var tallestcolumn = 0; 526 columns.each( 527 function() 528 { 529 $(this).css('height','auto'); 530 var currentHeight = $(this).height(); 531 if(currentHeight > tallestcolumn) 532 { 533 tallestcolumn = currentHeight; 534 } 535 } 536 ); 537 columns.height(tallestcolumn); 538 } 539 540 /*Player*/ 541jQuery('.trak-item audio').attr('data-state','pause'); 542 543var pauseIf, 544 jPlayerPausePlay = 'pause'; 545jQuery("#jquery_jplayer_main").jPlayer({ 546 ready: function () { 547 548 if ( jQuery('.playlist-wrapper .jp-playlist .trak-item').length > 0 ) { 549 550 var $this = jQuery('.playlist-wrapper .jp-playlist .about-list').next(), 551 audioSrc = $this.data('audio'), 552 audioTitle = $this.find('audio').attr('title'), 553 audioThumb = $this.data('thumbnail'), 554 audioArtist = $this.data('artist'); 555 556 jQuery('.jp-audio-main .har-artist').text(audioArtist); 557 558 jQuery('.jp-audio-main .har-thumbnail img').attr('src',audioThumb); 559 560 $this.addClass('active'); 561 562 $this.find('audio').attr('data-state','pause'); 563 564 jQuery('.jp-jplayer').attr({ 565 'data-state':'pause', 566 'data-audio-src':audioSrc 567 }); 568 569 jQuery("#jquery_jplayer_main").jPlayer("setMedia", { 570 title: audioTitle, 571 m4a: audioSrc 572 }); 573 574 575 } 576 577 }, 578 swfPath: '../dist/jplayer', 579 solution: 'html, flash', 580 supplied: 'm4a, oga', 581 preload: 'metadata', 582 volume: 0.8, 583 muted: false, 584 backgroundColor: '#000000',
585 cssSelectorAncestor: '#jp_container_content', 586 cssSelector: { 587 play: '.har-play', 588 pause: '.har-pause', 589 // stop: '.jp-stop', 590 seekBar: '.har-seek-bar', 591 playBar: '.har-seek-bar > div', 592 mute: '.har-mute', 593 unmute: '.har-unmute', 594 volumeBar: '.har-volume-bar', 595 volumeBarValue: '.har-volume-bar-value', 596 // volumeMax: '.jp-volume-max', 597 // playbackRateBar: '.jp-playback-rate-bar', 598 // playbackRateBarValue: '.jp-playback-rate-bar-value', 599 currentTime: '.har-current-time', 600 duration: '.har-duration', 601 title: '.har-title', 602 // fullScreen: '.jp-full-screen', 603 // restoreScreen: '.jp-restore-screen', 604 // repeat: '.jp-repeat', 605 // repeatOff: '.jp-repeat-off', 606 // gui: '.jp-gui', 607 // noSolution: '.jp-no-solution' 608 }, 609 errorAlerts: true, 610 warningAlerts: false, 611 ended: function() { 612 613 var playingSongParent = jQuery('.trak-item.active'); 614 615 616 if ( playingSongParent.next().length > 0 ) { 617 618 var parentForFind = playingSongParent.next(), 619 songTitle = parentForFind.find('audio').attr('title'), 620 songSrc = parentForFind.data('audio'), 621 soundThumb = parentForFind.data('thumbnail'), 622 audioArtist = parentForFind.data('artist'), 623 jPlayerPausePlay = jQuery('.jp-jplayer').attr('data-state'); 624 625 jQuery('.jp-audio-main .har-artist').text(audioArtist); 626 627 jQuery('.trak-item').removeClass('active playing'); 628 629 parentForFind.addClass('active playing'); 630 631 jQuery('.har-thumbnail img').attr('src',soundThumb); 632 633 jQuery("#jquery_jplayer_main").jPlayer("setMedia", { 634 title: songTitle, 635 m4a: songSrc 636 }).jPlayer("play"); 637 638 parentForFind.find('audio').attr('data-state','play'); 639 640 jQuery('.jp-jplayer').attr({ 641 'data-state':'play', 642 'data-audio-src':songSrc 643 }); 644 645 646 } else { 647 648 playingSongParent.removeClass('playing'); 649 650 playingSongParent.find('audio').attr('data-state','pause'); 651 652 }; 653 654 }, 655 play: function() { 656 657 jQuery('.trak-item.active').addClass('playing'); 658 659 jQuery('.trak-item.active').find('audio').attr('data-state','play'); 660 661 jQuery('.jp-jplayer').attr('data-state','play'); 662 663 }, 664 pause: function() { 665 666 jQuery('.trak-item.active').removeClass('playing'); 667 668 jQuery('.trak-item.active').find('audio').attr('data-state','pause'); 669 670 jQuery('.jp-jplayer').attr('data-state','pause'); 671 672 } 673}); 674 675var playerPlayOne = { 676 677 init: function(){ 678 679 jQuery('.trak-item .play-pause-button').on('click',function(){ 680 681 if ( jQuery(this).parent().hasClass('active') ) {} else { 682 683 jQuery('.trak-item').removeClass('active playing'); 684 jQuery('.trak-item audio').data('state','pause'); 685 jQuery('.jp-jplayer').attr('data-state','pause'); 686 687 } 688 689 var parentForFind = jQuery(this).parent(), 690 songTitle = parentForFind.find('audio').attr('title'), 691 songSrc = parentForFind.data('audio'), 692 soundThumb = parentForFind.data('thumbnail'), 693 autioArtist = parentForFind.data('artist'), 694 findItemByTitlteClick = jQuery('.trak-item.active[data-audio="' + songSrc + '"][data-artist="' + audioArtist + '"][data-thumbnail="' + soundThumb + '"]'), 695 jPlayerPausePlay = jQuery(this).parent().find('audio').attr('data-state'), 696 pauseIf = jQuery('.jp-jplayer').attr('data-audio-src'); 697 698 if ( pauseIf == songSrc ) { 699 700 if ( jPlayerPausePlay == 'play' ) { 701 702 if ( parentForFind.hasClass('active') ) { 703 704 jQuery("#jquery_jplayer_main").jPlayer("pause"); 705 706 parentForFind.removeClass('playing'); 707 708 parentForFind.find('audio').attr('data-state','pause'); 709 710 jQuery('.jp-jplayer').attr('data-state','pause'); 711 712 findItemByTitlteClick.addClass('active'); 713 findItemByTitlteClick.removeClass('playing'); 714 715 } else { 716 717 jQuery('.trak-item').removeClass('active playing'); 718 719 parentForFind.addClass('active playing'); 720 721 var audioArtist = parentForFind.data('artist'); 722 723 jQuery('.jp-audio-main .har-artist').text(audioArtist); 724 725 jQuery("#jquery_jplayer_main").jPlayer("setMedia", { 726 title: songTitle, 727 m4a: songSrc 728 }).jPlayer("play"); 729 730 parentForFind.find('audio').attr('data-state','play'); 731 732 jQuery('.jp-jplayer').attr({ 733 'data-state':'play', 734 'data-audio-src':songSrc 735 }); 736 737 findItemByTitlteClick.addClass('active playing'); 738 739 var playingSongParent = jQuery('.trak-item.active'), 740 soundThumb = parentForFind.data('thumbnail'); 741 742 jQuery('.har-thumbnail img').attr('src',soundThumb); 743 744 } 745 746 } else if ( jPlayerPausePlay == 'pause' ) { 747 748 if ( parentForFind.hasClass('active') ) { 749 750 jQuery("#jquery_jplayer_main").jPlayer("play"); 751 752 parentForFind.addClass('playing'); 753 754 parentForFind.find('audio').attr('data-state','play'); 755 756 jQuery('.jp-jplayer').attr('data-state','play'); 757 758 findItemByTitlteClick.addClass('active playing'); 759 760 } else { 761 762 jQuery('.trak-item').removeClass('active playing'); 763 764 parentForFind.addClass('active playing'); 765 766 var audioArtist = parentForFind.data('artist'); 767 768 jQuery('.jp-audio-main .har-artist').text(audioArtist); 769 770 jQuery("#jquery_jplayer_main").jPlayer("setMedia", { 771 title: songTitle, 772 m4a: songSrc 773 }).jPlayer("play"); 774 775 parentForFind.find('audio').attr('data-state','play'); 776 777 jQuery('.jp-jplayer').attr({ 778 'data-state':'play', 779 'data-audio-src':songSrc 780 }); 781 782 findItemByTitlteClick.addClass('active playing'); 783 784 var playingSongParent = jQuery('.trak-item.active'), 785 soundThumb = parentForFind.data('thumbnail'); 786 787 jQuery('.har-thumbnail img').attr('src',soundThumb); 788 789 } 790 791 }; 792 793 } else { 794 795 jQuery('.trak-item').removeClass('active playing'); 796 797 parentForFind.addClass('active playing'); 798 799 var audioArtist = parentForFind.data('artist'); 800 801 jQuery('.jp-audio-main .har-artist').text(audioArtist); 802 803 jQuery("#jquery_jplayer_main").jPlayer("setMedia", { 804 title: songTitle, 805 m4a: songSrc 806 }).jPlayer("play"); 807 808 parentForFind.find('audio').attr('data-state','play'); 809 810 jQuery('.jp-jplayer').attr({ 811 'data-state':'play', 812 'data-audio-src':songSrc 813 }); 814 815 findItemByTitlteClick.addClass('active playing'); 816 817 var playingSongParent = jQuery('.trak-item.active'), 818 soundThumb = parentForFind.data('thumbnail'); 819 820 jQuery('.har-thumbnail img').attr('src',soundThumb); 821 822 }; 823 824 }); 825 826 }, 827 828 playPrevSong: function(){ 829 830 jQuery('.har-prev').on('click',function(){ 831 832 var playingSongParent = jQuery('.trak-item.active'); 833 834 if ( playingSongParent.prev().length > 0 ) { 835 836 var parentForFind = playingSongParent.prev(), 837 songTitle = parentForFind.find('audio').attr('title'), 838 songSrc = parentForFind.data('audio'), 839 soundThumb = parentForFind.data('thumbnail'), 840 audioArtist = parentForFind.data('artist'), 841 jPlayerPausePlay = jQuery('.jp-jplayer').attr('data-state'); 842 843 jQuery('.jp-audio-main .har-artist').text(audioArtist); 844 845 jQuery('.trak-item').removeClass('active playing'); 846 847 parentForFind.addClass('active playing'); 848 849 jQuery('.har-thumbnail img').attr('src',soundThumb); 850 851 jQuery("#jquery_jplayer_main").jPlayer("setMedia", { 852 title: songTitle, 853 m4a: songSrc 854 }).jPlayer("play"); 855 856 parentForFind.find('audio').attr('data-state','play'); 857 858 jQuery('.jp-jplayer').attr({ 859 'data-state':'play', 860 'data-audio-src':songSrc 861 }); 862 863 }; 864 865 }); 866 867 }, 868 869 playNextSong: function(){ 870 871 jQuery('.har-next').on('click',function(){ 872 873 var playingSongParent = jQuery('.trak-item.active'); 874 875 if ( playingSongParent.next().length > 0 ) { 876 877 var parentForFind = playingSongParent.next(), 878 songTitle = parentForFind.find('audio').attr('title'), 879 songSrc = parentForFind.data('audio'), 880 soundThumb = parentForFind.data('thumbnail'), 881 audioArtist = parentForFind.data('artist'), 882 jPlayerPausePlay = jQuery('.jp-jplayer').attr('data-state'); 883 884 jQuery('.jp-audio-main .har-artist').text(audioArtist); 885 886 jQuery('.trak-item').removeClass('active playing'); 887 888 parentForFind.addClass('active playing'); 889 890 jQuery('.har-thumbnail img').attr('src',soundThumb); 891 892 jQuery("#jquery_jplayer_main").jPlayer("setMedia", { 893 title: songTitle, 894 m4a: songSrc 895 }).jPlayer("play"); 896 897 parentForFind.find('audio').attr('data-state','play'); 898 899 jQuery('.jp-jplayer').attr({ 900 'data-state':'play', 901 'data-audio-src':songSrc 902 }); 903 904 }; 905 906 }); 907 908 } 909 910} 911jQuery(document).ready(function(){ 912 913 playerPlayOne.init(); 914 playerPlayOne.playPrevSong(); 915 playerPlayOne.playNextSong(); 916}); 917 918 919 // Open Close PlayList 920 $('#playlist-toggle').on('click',function(e){
921 e.preventDefault(); 922 $(this).toggleClass('close-icon'); 923 $('.playlist-wrapper').toggleClass('300').fadeToggle(300); 924 }); 925 926})(jQuery); 927 928 929 930$(window).load(function(){ 931 932 $(".har_preloader").fadeOut("slow"); 933 934 // Page loader 935 936 $("body").imagesLoaded(function(){ 937 $(".har_page_loader div").fadeOut(); 938 $(".har_page_loader").delay(200).fadeOut("slow"); 939 }); 940 941 942 /*SkroolR*/ 943 if( !device.tablet() && !device.mobile() ) { 944 var s = skrollr.init({ 945 forceHeight: false, 946 }); 947 $(window).stellar({ 948 horizontalScrolling: false, 949 responsive: true, 950 }); 951 } 952 953 /*Masonry*/ 954 955 var $grid = $('.grid').isotope({ 956 itemSelector: '.grid-item', 957 percentPosition: true, 958 masonry: { 959 columnWidth: '.grid-item' 960 } 961 }); 962 $grid.imagesLoaded().progress( function() { 963 $grid.isotope('layout'); 964 }); 965 $(window).resize(function(){ 966 $grid.isotope('layout'); 967 }); 968 969 970 971 $('.masonry').masonry({ 972 itemSelector: '.masonry-item', 973 }); 974 975 $('.filter-button-group').on( 'click', 'a', function() { 976 $(this).parents('.filter-button-group').find('a').removeClass('active'); 977 $(this).addClass('active'); 978 var filterValue = $(this).attr('data-filter'); 979 $grid.isotope({ filter: filterValue }); 980 }); 981 982 983}); 984
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.