1(function($) { 2 3 "use strict"; 4 5 /* - Contact Map */ 6 function initialize(obj) { 7 8 var lat = $('#'+obj).attr("data-lat"); 9 var lng = $('#'+obj).attr("data-lng"); 10 var contentString = $('#'+obj).attr("data-string"); 11 var myLatlng = new google.maps.LatLng(lat,lng); 12 var map, marker, infowindow; 13 var image = $('#'+obj).attr("data-marker"); 14 var zoomLevel = parseInt($("#"+obj).attr("data-zoom") ,10); 15 var styles = [ 16 {"featureType": "all","elementType": "labels.text.fill","stylers": [{"saturation": 36},{"color": "#000000"},{"lightness": 40}]}, 17 {"featureType": "all","elementType": "labels.text.stroke","stylers": [{"visibility": "on"},{"color": "#000000"},{"lightness": 16}]}, 18 {"featureType": "all","elementType": "labels.icon","stylers": [{"visibility": "off"}]}, 19 {"featureType": "administrative","elementType": "geometry.fill","stylers": [{"color": "#000000"},{"lightness": 20}]}, 20 {"featureType": "administrative","elementType": "geometry.stroke","stylers": [{"color": "#000000"},{"lightness": 17},{"weight": 1.2}]}, 21 {"featureType": "landscape","elementType": "geometry","stylers": [{"color": "#000000"},{"lightness": 20}]}, 22 {"featureType": "poi","elementType": "geometry","stylers": [{"color": "#000000"},{"lightness": 21}]}, 23 {"featureType": "road.highway","elementType": "geometry.fill","stylers": [{"color": "#000000"},{"lightness": 17}]}, 24 {"featureType": "road.highway","elementType": "geometry.stroke","stylers": [{"color": "#000000"},{"lightness": 29},{"weight": 0.2}]}, 25 {"featureType": "road.arterial","elementType": "geometry","stylers": [{"color": "#000000"},{"lightness": 18}]}, 26 {"featureType": "road.local","elementType": "geometry","stylers": [{"color": "#000000"},{"lightness": 16}]}, 27 {"featureType": "transit","elementType": "geometry","stylers": [{"color": "#000000"},{"lightness": 19}]}, 28 {"featureType": "water","elementType": "geometry","stylers": [{"color": "#000000"},{"lightness": 17}]} 29 ] 30 var styledMap = new google.maps.StyledMapType(styles,{name: "Styled Map"}); 31 var mapOptions = { 32 zoom: zoomLevel, 33 disableDefaultUI: true, 34 center: myLatlng, 35 scrollwheel: false, 36 mapTypeControlOptions: { 37 mapTypeIds: [google.maps.MapTypeId.ROADMAP, "map_style"] 38 } 39 } 40 map = new google.maps.Map(document.getElementById(obj), mapOptions); 41 map.mapTypes.set('map_style', styledMap); 42 map.setMapTypeId('map_style'); 43 infowindow = new google.maps.InfoWindow({ 44 content: contentString, 45 maxWidth: 300 46 }); 47 marker = new google.maps.Marker({ 48 position: myLatlng, 49 map: map, 50 icon: image 51 }); 52 if(contentString != '') { 53 google.maps.event.addListener(marker, 'click', function() { 54 infowindow.open(map,marker); 55 }); 56 } 57 } 58 59 window.initMap = function() {} 60 61 62 /* - Gallery */ 63 function gallery() { 64 if($(".gallery-fitrow").length){ 65 var $container = $(".gallery-fitrow"); 66 $container.isotope({ 67 layoutMode: 'fitRows', 68 itemSelector: ".gallery-box", 69 gutter: 0, 70 transitionDuration: "0.5s" 71 }); 72 73 $("#filters a").on("click",function(){ 74 $('#filters a').removeClass("active"); 75 $(this).addClass("active"); 76 var selector = $(this).attr("data-filter"); 77 $container.isotope({ filter: selector }); 78 return false; 79 }); 80 } 81 } 82 83 /* - Contact Section */ 84 function cnt_box_height() { 85 if($(".contact-section .cnt-detail-box").length) { 86 var maxHeight = 0; 87 $(".cnt-detail-box").each(function(){ 88 if ($(this).height() > maxHeight) { maxHeight = $(this).height(); } 89 }); 90 $(".cnt-detail-box").height(maxHeight); 91 } 92 } 93 94 /* - History Section */ 95 function history_img() { 96 var width = $(window).width(); 97 var history_content_height = $(".history-section .history-details").height(); 98 if ( width >= 992 ) { 99 $( ".history-section .img-block" ).removeAttr("style"); 100 $( ".history-section .img-block img" ).remove(); 101 var history_image = $(".history-section .img-block").attr("data-image"); 102 $( ".history-section .img-block" ).css({"background-image":"url('" + history_image
102+ "')","height": history_content_height }); 103 } else { 104 $( ".history-section .img-block" ).removeAttr("style"); 105 $( ".history-section .img-block img" ).remove(); 106 var history_image = $(".history-section .img-block").attr("data-image"); 107 $( ".history-section .img-block" ).append("<img src='"+ history_image +"' />") 108 } 109 } 110 111 /* - Venu Section 2 */ 112 function venu_img() { 113 var width = $(window).width(); 114 var venu_section_height = $(".venu-section-2").height(); 115 if ( width >= 992 ) { 116 $( ".venu-img" ).removeAttr("style"); 117 $( ".venu-img img" ).remove(); 118 var venu_img = $(".venu-img").attr("data-image"); 119 $( ".venu-img" ).css({"background-image":"url('" + venu_img + "')","height": venu_section_height }); 120 } else { 121 $( ".venu-img" ).removeAttr("style"); 122 $( ".venu-img img" ).remove(); 123 var venu_img = $(".venu-img").attr("data-image"); 124 $( ".venu-img" ).append("<img src='"+ venu_img +"' />") 125 } 126 } 127 128 /* - Events List */ 129 function event_list() { 130 $(".event-section2 .events-content .events-list .events-list-box").each(function(index){ 131 $(".event-section2 .events-content .events-list .events-list-box > div").removeAttr("style"); 132 var event_height = $(".event-section2 .events-content .events-list .events-list-box").eq(index).height(); 133 if( event_height > 80 ) { 134 $(".event-section2 .events-content .events-list .events-list-box > div").css("height",event_height); 135 } else { 136 $(".event-section2 .events-content .events-list .events-list-box > div").css("min-height","80px"); 137 } 138 }); 139 } 140 141 function event_img_block() { 142 var width = $(window).width(); 143 var event_height = $(".event-section2").height(); 144 if ( width >= 992 ) { 145 $(".event-section2 .event-img-block").removeAttr("style"); 146 $( ".event-section2 .event-img-block > img" ).remove(); 147 var event_image = $(".event-section2 .event-img-block").attr("data-image"); 148 $( ".event-section2 .event-img-block" ).css({"background-image":"url('" + event_image + "')","height": event_height }); 149 } else { 150 $(".event-section2 .event-img-block").removeAttr("style"); 151 $( ".event-section2 .event-img-block > img" ).remove(); 152 var event_image = $(".event-section2 .event-img-block").attr("data-image"); 153 $( ".event-section2 .event-img-block" ).prepend("<img src='"+ event_image +"' />") 154 } 155 if ( width >= 992 ) { 156 var event_img_block_height = $(".event-section2 .event-img-block").height(); 157 var event_img_content_height = $(".event-section2 .event-img-block .event-img-content-box").height(); 158 var event_img_content_padding = ( event_img_block_height - event_img_content_height ) / 2 ; 159 $(".event-section2 .event-img-block").css({"padding-top":event_img_content_padding,"padding-bottom":event_img_content_padding}); 160 } else { 161 $(".event-section2 .event-img-block").removeAttr("style"); 162 } 163 } 164 165 /* Event - Document Ready */ 166 $(document).on("ready",function() { 167 168 /* - Contact Map Initialization */ 169 if($("#map-canvas-contact").length==1){ 170 initialize("map-canvas-contact"); 171 } 172 173 /* - Event Map */ 174 if($("#map-canvas-event-single").length==1){ 175 initialize("map-canvas-event-single"); 176 } 177 178 /* - History Section */ 179 if( $(".history-section").length ) { 180 history_img(); 181 } 182 183 /* - Testimonial Carousel */ 184 if( $(".testimonial-carousel").length ) { 185 $(".testimonial-carousel").owlCarousel({ 186 loop: true, 187 margin: 0, 188 nav: false, 189 dots: true, 190 autoplay: false, 191 responsive:{ 192 0:{ 193 items: 1 194 }, 195 992:{ 196 items: 2 197 } 198 } 199 }); 200 } 201 202 /* - Testimonial Section 2 */ 203 if( $(".testimonial-section2").length ) { 204 $("#testimonial2").on('slid.bs.carousel', function () { 205 $( "ol.testi-thumb li.active" ).removeClass('active'); 206 var idx = $('div.active').index('div.item'); 207 $('ol.testi-thumb li[data-slide-to="'+ idx+'"]').addClass('active'); 208 }); 209 210 $('ol.testi-thumb li').on("click",function(){ 211 $('ol.testi-thumb li.active').removeClass("active"); 212 $(this).addClass("active"); 213 }); 214 } 215 216 /* - Counter Section */ 217 if($(".counter-section").length) { 218 $( ".counter-section" ).each(function () 219 { 220 var $this = $(this); 221 var myVal = $(this).data("value"); 222 223 $this.appear(function() 224 { 225 var statistics_item_count = 0; 226 var statistics_count = 0; 227 statistics_item_count = $( "[id*='statistics_count-']" ).length; 228 229 for(var i=1; i<=statistics_item_count; i++) 230 { 231 statistics_count = $( "[id*='statistics_count-"+ i +"']" ).attr( "data-statistics_percent" ); 232 $("[id*='statistics_count-"+ i +"']").animateNumber({ number: statistics_count }, 4000); 233 } 234 }); 235 }); 236 } 237 238 /* - Venu Section 2 */ 239 if($(".venu-section-2").length){ 240 venu_img(); 241 } 242 243 /* - Event List */ 244 if($(".event-section2").length){ 245 event_list(); 246 event_img_block(); 247 } 248 249 /* - Gallery Section */ 250 gallery(); 251 if($(".gallery-list").length){ 252 var url; 253 $(".gallery-list .gallery-box").magnificPopup({ 254 delegate: "a.zoom-out", 255 type: "image", 256 tLoading: "Loading image #%curr%...", 257 mainClass: "mfp-img-mobile", 258 gallery: { 259 enabled: true, 260 navigateByImgClick: false, 261 preload: [0,1] // Will preload 0 - before current, and 1 after the current image 262 }, 263 image: { 264 tError: "<a href="%url%">The image #%curr%</a> could not be loaded.", 265 } 266 }); 267 } 268 269 /* - Client Carousel */ 270 if( $(".clients-carousel").length ) { 271 $(".clients-carousel").owlCarousel({ 272 loop: true, 273 margin: 0, 274 nav: false, 275 dots: true, 276 autoplay: false, 277 responsive:{ 278 0:{ 279 items: 1 280 }, 281 500:{ 282 items: 2 283 }, 284 600:{ 285 items: 3 286 }, 287 1000:{ 288 items: 5 289 } 290 } 291 }); 292 } 293 294 /* - Video Section */ 295 $(".video-section a,.intro-section a.video-play-icon").magnificPopup({ 296 disableOn: 700, 297 type: "iframe", 298 mainClass: "mfp-fade", 299 removalDelay: 160, 300 preloader: false,
301 fixedContentPos: false 302 }); 303 304 }); /* Event - Document Ready */ 305 306 307 /* ## Event - Window Resize */ 308 $( window ).on("resize",function() { 309 /* - History Section */ 310 history_img(); 311 312 cnt_box_height(); 313 314 /* - Venu Section 2 */ 315 venu_img(); 316 317 /* - Event List */ 318 event_list(); 319 event_img_block(); 320 }); 321 322 323 $(window).on("load",function() { 324 /* - Gallery Section */ 325 gallery(); 326 327 cnt_box_height(); 328 }); 329 330})(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.