1/** 2* testimonialCarousel 3* portfolioIsotope 4* portfolioMasory 5* portfolioCarousel 6* blogCarousel 7* blogMasory 8* slider 9* logoClient 10* googleMap 11* themesflatCounter 12* videothumbnail 13* progressBar 14* rowStyling 15* spacer 16* sectionVideo 17*/ 18 19;(function($) { 20 'use strict' 21 22var testimonialCarousel = function() { 23 $('.testimonial-sliders').each(function() { 24 var $this = $(this),datas = $this 25 if ( $().owlCarousel ) { 26 $this.find('.slide_nav .slides').owlCarousel({ 27 autoWidth:true, 28 nav: false, 29 dots: false, 30 margin: 4 31 }); 32 $this.find('.testimonial-slider').on('initialized.owl.carousel change.owl.carousel changed.owl.carousel', function(e) { 33 if (!e.namespace || e.type != 'initialized' && e.property.name != 'position') return; 34 var current = e.relatedTarget.current() 35 var items = $(this).find('.owl-stage').children() 36 var add = e.type == 'changed' || e.type == 'initialized' 37 var owl = $(this); 38 $this.find('.slide_nav li').on("click",function(){ 39 owl.trigger("to.owl.carousel", [$(this).parent().index(), 500, true]); 40 }) 41 $this.find('.slide_nav li').eq(e.relatedTarget.normalize(current) - 1).toggleClass('current', add); 42 }).owlCarousel({ 43 loop: true, 44 margin:datas.data('margin'), 45 nav: Boolean( datas.data('show_direction') )? true: false, 46 dots: Boolean( datas.data('show_control') )? true: false, 47 autoplay: Boolean( datas.data('autoplay') )? true: false, 48 items: datas.data('items'), 49 responsive:{ 50 0:{ 51 items: 1 52 }, 53 767:{ 54 items: next_item(datas.data('items') -1,$this.width()) 55 }, 56 991:{ 57 items: next_item(datas.data('items'),$this.width()) 58 }, 59 1200: { 60 items: datas.data('items') 61 } 62 } 63 }); 64 65 } 66 }); 67}; 68 69var portfolioIsotope = function() { 70 if ( $( '.portfolio-container' ).hasClass('show_filter_portfolio') ) { 71 if ( $().isotope ) { 72 var $container = $('.portfolio-container'); 73 $container.imagesLoaded(function(){ 74 $container.isotope({ 75 itemSelector: '.item', 76 transitionDuration: '1s' 77 }); 78 }); 79 $('.portfolio-filter li').on('click',function() { 80 var selector = $(this).find("a").attr('data-filter'); 81 $('.portfolio-filter li').removeClass('active'); 82 $(this).addClass('active'); 83 $container.isotope({ filter: selector }); 84 return false; 85 }); 86 }; 87 }; 88}; 89 90var portfolioMasory = function() { 91 if ( $().isotope ) { 92 var $container = $('.portfolio-container.masonry'); 93 $container.imagesLoaded(function(){ 94 $container.masonry({ 95 itemSelector: '.item', 96 columnWidth: 1, 97 transitionDuration: '0.5s', 98 layoutMode: 'masonry', 99 masonry: { columnWidth: $container.width() / 12 } 100 }); // isotope 101 }); 102 $(window).resize(function() { 103 $container.masonry({ 104 masonry: { columnWidth: $container.width() / 12 } 105 }); 106 }); // relayout 107 108 }; 109}; 110 111var portfolioCarousel = function() { 112 if ( $( ".themesflat-portfolio" ).hasClass( "themesflat_enable_carousel" ) ) { 113 if ( $().owlCarousel ) { 114 $('.themesflat-portfolio.themesflat_enable_carousel').find('.portfolio-container').owlCarousel({ 115 loop: true, 116 margin: 0, 117 nav: true, 118 dots: false, 119 autoplay: false, 120 responsive:{ 121 0:{ 122 items: 1 123 }, 124 480: { 125 items: 2 126 }, 127 767:{ 128 items: 2 129 }, 130 991:{ 131 items: 2 132 }, 133 1200: { 134 items: $('.portfolio-container').data('item') 135 } 136 } 137 }); 138 } 139 } 140}; 141 142var blogCarousel = function() { 143 if ( $().owlCarousel ) { 144 $(".blog-shortcode.has-carousel:not(.blog-masonry)").each(function() { 145 var $this = $(this),_items = $this.data('items'); 146 $this.owlCarousel({ 147 loop: true, 148 margin: 0, 149 nav: true, 150 dots: false, 151 autoplay: false, 152 responsive:{ 153 0:{ 154 items: next_item(_items-2,$this.width()) 155 }, 156 767:{ 157 items: next_item(_items-1,$this.width()) 158 }, 159 991:{ 160 items: next_item(_items,$this.width()) 161 }, 162 1200: { 163 items: _items 164 } 165 } 166 }); 167 }); 168 } 169}; 170 171var blogMasory = function() { 172 if ( $().isotope ) { 173 var $container = $('.blog-shortcode.blog-masonry'); 174 $container.imagesLoaded(function(){ 175 $container.masonry({ 176 itemSelector: '.entry', 177 transitionDuration: '0.5s', 178 layoutMode: 'masonry', 179 masonry: { columnWidth: $container.width() / 12 } 180 }); // isotope 181 }); 182 $(window).resize(function() { 183 $container.masonry({ 184 masonry: { columnWidth: $container.width() / 12 } 185 }); 186 }); // relayout 187 188 }; 189};
190 191var slider = function() { 192 if ($().owlCarousel){ 193 $('.themesflat_enable_slider').each(function() { 194 var $this = $(this), 195 datas = $this; 196 $this.owlCarousel({ 197 loop: true, 198 margin:datas.data('margin'), 199 nav: Boolean( datas.data('show_direction') )? true: false, 200 dots: Boolean( datas.data('show_control') )? true: false, 201 autoplay: Boolean( datas.data('autoplay') )? true: false, 202 items: datas.data('slides_per_view'), 203 responsive:{ 204 0:{ 205 items: 1 206 }, 207 767:{ 208 items: next_item(datas.data('slides_per_view') -1,$this.width()) 209 }, 210 991:{ 211 items: next_item(datas.data('slides_per_view'),$this.width()) 212 }, 213 1200: { 214 items: datas.data('slides_per_view') 215 } 216 } 217 }) 218 }) 219 } 220} 221 222var logoClient = function() { 223 $('.themesflat_client_slider').each(function() { 224 if ( $().owlCarousel ) { 225 var data = $(this).find('.themesflat_client_slider_inner'); 226 $('.themesflat_client_slider_inner').owlCarousel({ 227 loop: true, 228 margin: parseInt( data.data('margin') ), 229 nav: Boolean( data.data('hide_buttons') )? false: true, 230 dots: Boolean( data.data('hide_control') )? false: true, 231 autoplay: Boolean( data.data('autoplay') )? true: false, 232 responsive:{ 233 0:{ 234 items: 2 235 }, 236 480:{ 237 items: 3 238 }, 239 767:{ 240 items: 4 241 }, 242 991:{ 243 items: 5 244 }, 245 1200: { 246 items: parseInt( data.data('slides_per_view') ) 247 } 248 } 249 }); 250 } 251 }); 252}; 253 254var googleMap = function() { 255 if ( $().gmap3 ) { 256 $("#map").gmap3({ 257 map:{ 258 options:{ 259 zoom: 16, 260 mapTypeId: 'themesflat_style', 261 mapTypeControlOptions: { 262 mapTypeIds: ['themesflat_style', google.maps.MapTypeId.SATELLITE, google.maps.MapTypeId.HYBRID] 263 }, 264 scrollwheel: false 265 } 266 }, 267 getlatlng:{ 268 address: $('.themesflat-maps').data('address'), 269 callback: function(results) { 270 if ( !results ) return; 271 $(this).gmap3('get').setCenter(new google.maps.LatLng(results[0].geometry.location.lat(), results[0].geometry.location.lng())); 272 $(this).gmap3({ 273 marker:{ 274 latLng:results[0].geometry.location, 275 options:{ 276 icon: $('.themesflat-maps').data('images') 277 } 278 }, 279 overlay:{ 280 latLng:results[0].geometry.location, 281 options:{ 282 content: "<img src=".concat($('.themesflat-maps').data('images_layout_address')).concat(" alt='image'>"), 283 offset:{ 284 y:$('.themesflat-maps').data('address_x'), 285 x:$('.themesflat-maps').data('address_y') 286 } 287 } 288 } 289 }); 290 } 291 }, 292 styledmaptype:{ 293 id: "themesflat_style", 294 options:{ 295 name: "Themesflat Map" 296 }, 297 styles:[ 298 { 299 "featureType": "administrative", 300 "elementType": "labels.text.fill", 301 "stylers": [ 302 { 303 "color": "#444444" 304 } 305 ] 306 }, 307 { 308 "featureType": "landscape", 309 "elementType": "all", 310 "stylers": [ 311 { 312 "color": "#f2f2f2" 313 } 314 ] 315 }, 316 { 317 "featureType": "poi", 318 "elementType": "all", 319 "stylers": [ 320 { 321 "visibility": "off" 322 } 323 ] 324 }, 325 { 326 "featureType": "road", 327 "elementType": "all", 328 "stylers": [ 329 { 330 "saturation": -100 331 }, 332 { 333 "lightness": 45 334 } 335 ] 336 }, 337 { 338 "featureType": "road.highway", 339 "elementType": "all", 340 "stylers": [ 341 { 342 "visibility": "simplified" 343 } 344 ] 345 }, 346 { 347 "featureType": "road.arterial", 348 "elementType": "labels.icon", 349 "stylers": [ 350 { 351 "visibility": "off" 352 } 353 ] 354 }, 355 { 356 "featureType": "transit", 357 "elementType": "all", 358 "stylers": [ 359 { 360 "visibility": "off" 361 } 362 ] 363 }, 364 { 365 "featureType": "water", 366 "elementType": "all", 367 "stylers": [ 368 {
369 "color": "#46bcec" 370 }, 371 { 372 "visibility": "on" 373 } 374 ] 375 } 376 ] 377 }, 378 }); 379 } 380 $('#map').css( 'height', $('.themesflat-maps').data('height') ); 381}; 382 383var themesflatCounter = function() { 384 $('.themesflat_counter').on('on-appear', function() { 385 $(this).find('.numb-count').each(function() { 386 var to = parseInt( ($(this).attr('data-to')),10 ), speed = parseInt( ($(this).attr('data-speed')),10 ); 387 if ( $().countTo ) { 388 $(this).countTo({ 389 to: to, 390 speed: speed 391 }); 392 } 393 }); 394 }); 395}; 396 397var videothumbnail = function() { 398 $(document).on('click',".themesflat_video_embed a",function(e){ 399 e.preventDefault(); 400 var iframe = $(this).parent().find('iframe'); 401 iframe[0].src += "&autoplay=1"; 402 iframe.show(); 403 $(this).hide(); 404 }) 405} 406 407var progressBar = function() { 408 $('.progress-bar').on('on-appear', function() { 409 $(this).each(function() { 410 var percent = $(this).data('percent'); 411 $(this).find('.progress-animate').animate({ 412 "width": percent + '%' 413 }, $(this).find('.progress-animate').data('duration') ); 414 $(this).parent('.themesflat-progress').find('.perc').addClass('show').animate({ 415 "width": percent + '%' 416 }, $(this).find('.progress-animate').data('duration') ); 417 }); 418 }); 419}; 420 421var rowStyling = function() { 422 $(".vc_row").each(function( idx, el ) { 423 if ($(this).hasClass('themesflat-overlay')) { 424 var class_mask ='<div class="overlay"></div>'; 425 $(this).append(class_mask); 426 } 427 }); 428}; 429 430var spacer = function() { 431 $(".themesflat-spacer").each(function() { 432 var spacer_size = $(this).data( 'desktop' ); 433 if ( matchMedia( 'only screen and (max-width: 991px)' ).matches ) { 434 spacer_size = $(this).data( 'mobile' ) 435 } 436 if ( matchMedia( 'only screen and (max-width: 479px)' ).matches ) { 437 spacer_size = $(this).data( 'smobile' ) 438 } 439 440 $(this).css( "height", spacer_size ); 441 }); 442}; 443 444function next_item($item,$width) { 445 if (typeof $width =='undefined') { 446 $width = 0; 447 } 448 var $int_item = parseInt($item); 449 if ( $int_item -1 > 0) { 450 if (($width/$int_item) > 250) { 451 return $int_item 452 } 453 return $int_item -1; 454 } 455 else { 456 return 1; 457 } 458} 459 460var sectionVideo = function () { 461 $(".themesflat-video-fancybox").on("click", function(){ 462 $.fancybox({ 463 href: this.href, 464 type: $(this).data("type") 465 }); // fancybox 466 return false 467 }); // on 468 } 469 470 471// Dom Ready 472$(function() { 473 testimonialCarousel(); 474 portfolioIsotope(); 475 portfolioMasory(); 476 portfolioCarousel(); 477 blogCarousel(); 478 themesflatCounter(); 479 blogMasory(); 480 slider(); 481 logoClient(); 482 googleMap(); 483 videothumbnail(); 484 progressBar(); 485 rowStyling(); 486 spacer(); 487 sectionVideo(); 488}); 489})(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.