1(function($) { 2 "use strict"; 3 4 5 var jws_dropdown_text = function($scope, $) { 6 $scope.find('.jws_dropdown_text').eq(0).each(function() { 7 8 }); 9 }; 10 11 12 13 var product_tabs_filter = function($scope, $) { 14 $scope.find('.jws-wrap').eq(0).each(function() { 15 var wrap = $(this); 16 if(wrap.hasClass('jws-carousel')) { 17 18 jws_carousel($scope, $); 19 20 } 21 if(wrap.hasClass('metro')){ 22 wrap.find('.products-tab').isotope({ 23 itemSelector: ".product-item", 24 layoutMode: 'masonry', 25 transitionDuration: "0.3s", 26 masonry: { 27 // use outer width of grid-sizer for columnWidth 28 columnWidth: '.grid-sizer', 29 } 30 }); 31 } 32 wrap.find('.jws-ajax-load a.ajax-load').on('click', function(e) { 33 e.preventDefault(); 34 var $this = $(this) , intervalID; 35 var key = $this.data('value'); 36 if($this.hasClass('active')) { 37 return; 38 } 39 clearInterval(intervalID); 40 wrap.addClass('jws-animated-products'); 41 $this.parents('.jws-ajax-load').find('a').removeClass('active'); 42 $this.addClass('active'); 43 if($this.hasClass('opened')) { 44 wrap.find('.products-tab').html(wrap.find('.products-tab').data(key)); 45 if(wrap.hasClass('jws-carousel')) { 46 jws_carousel($scope, $); 47 } 48 var iter = 0; 49 intervalID = setInterval(function() { 50 wrap.find('.product-item').eq(iter).addClass('jws-animated'); 51 iter++; 52 }, 100); 53 return; 54 } 55 $this.addClass('opened'); 56 wrap.addClass('loading'); 57 if(!wrap.find('.loader').length) { 58 wrap.append('<div class="loader"><svg class="circular" viewBox="25 25 50 50"><circle class="path" cx="50" cy="50" r="20" fill="none" stroke-width="2" stroke-miterlimit="10"/></svg></div>'); 59 } 60 var data = wrap.data('args'); 61 data.action = 'jws_ajax_product_filter'; 62 if($this.data('type') == 'product_cat') { 63 data.filter_categories = $this.data('value'); 64 } 65 if($this.data('type') == 'asset_type') { 66 data.asset_type = $this.data('value'); 67 } 68 $.ajax({ 69 url: wrap.data('url'), 70 data: data, 71 type: 'POST', 72 dataType: 'json', 73 }).success(function(response) { 74 wrap.removeClass('loading');
75 let content = response.items; 76 wrap.find('.products-tab').html(content); 77 wrap.find('.products-tab').data(key, content); 78 if(wrap.hasClass('jws-carousel')) { 79 jws_carousel($scope, $); 80 } 81 var iter = 0; 82 intervalID = setInterval(function() { 83 wrap.find('.product-item').eq(iter).addClass('jws-animated'); 84 iter++; 85 }, 100); 86 }).error(function(ex) { 87 console.log(ex); 88 }); 89 }); 90 91 wrap.find('.jws-products-load-more').off('click').on('click', function(e) { 92 e.preventDefault(); 93 var $this = $(this), 94 data = wrap.data('args'), 95 paged = wrap.data('paged'); 96 paged++; 97 loadProducts2(data, paged, wrap, $this) 98 }); 99 100 var loadProducts2 = function(data, paged, wrap, btn) { 101 var intervalID, 102 total = wrap.find('.product-item').length, 103 iter = total; 104 clearInterval(intervalID); 105 data.action = 'jws_ajax_product_filter'; 106 data.paged = paged; 107 btn.addClass('loading'); 108 wrap.find('.product-item').addClass('jws-animated'); 109 wrap.addClass('jws-animated-products'); 110 111 btn.append('<div class="loader"><svg class="circular" viewBox="25 25 50 50"><circle class="path" cx="50" cy="50" r="20" fill="none" stroke-width="2" stroke-miterlimit="10"/></svg></div>'); 112 $.ajax({ 113 url: wrap.data('url'), 114 data: data, 115 method: 'POST', 116 dataType: 'json', 117 success: function(response) { 118 119 if (response.items) { 120 wrap.find('.products-tab').append(response.items); 121 intervalID = setInterval(function() { 122 wrap.find('.product-item').eq(iter).addClass('jws-animated'); 123 iter++; 124 }, 100); 125 wrap.data('paged', paged); 126 } 127 128 if (response.status == 'no-more-posts') { 129 btn.hide(); 130 } 131 132 133 }, 134 error: function(data) { 135 console.log('ajax error'); 136 console.log(data); 137 }, 138 complete: function() { 139 btn.removeClass('loading'); 140 $('.loader').remove(); 141 142 }, 143 }); 144 }; 145 }); 146 }; 147 148 149 var jws_carousel = function($scope, $) { 150 151 $scope.find('.jws-carousel').eq(0).each(function() { 152 153 var $this = $(this); 154 155 jwsThemeModule.owl_caousel_init($(this).find('.carousel')); 156 157 158 }); 159 160 }; 161 162 /** 163 *------------------------------------------------------------------------------------------------------------------------------------------- 164 * Image Carousel 165 *------------------------------------------------------------------------------------------------------------------------------------------- 166 */ 167 var images_carousel = function($scope, $) { 168 $scope.find('.jws-image_carousel-element').eq(0).each(function() { 169 let $this = $(this); 170 if($this.find('.jws-image_carousel').hasClass('slider')) { 171 jwsThemeModule.owl_caousel_init($this.find('.jws-image_carousel')); 172 } 173 }); 174 }; 175 176 /** 177 *------------------------------------------------------------------------------------------------------------------------------------------- 178 * Banner Carousel 179 *------------------------------------------------------------------------------------------------------------------------------------------- 180 */ 181 var banner_carousel = function($scope, $) { 182 $scope.find('.jws-banner-element').eq(0).each(function() {
183 let $this = $(this); 184 if($this.find('.jws-banner').hasClass('slider')) { 185 jwsThemeModule.owl_caousel_init($this.find('.jws-banner')); 186 } 187 }); 188 }; 189 190 191 /** 192 *------------------------------------------------------------------------------------------------------------------------------------------- 193 * Time Line Carousel 194 *------------------------------------------------------------------------------------------------------------------------------------------- 195 */ 196 var time_line_carousel = function($scope, $) { 197 $scope.find('.jws_timeline').eq(0).each(function() { 198 let $this = $(this); 199 jwsThemeModule.owl_caousel_init($this.find('.jws_timeline_main ')); 200 }); 201 }; 202 203 /** 204 *------------------------------------------------------------------------------------------------------------------------------------------- 205 * Info Box Carousel 206 *------------------------------------------------------------------------------------------------------------------------------------------- 207 */ 208 var info_box_carousel = function($scope, $) { 209 $scope.find('.jws-info_box-element').eq(0).each(function() { 210 let $this = $(this); 211 if($this.find('.info_box ').hasClass('slider')) { 212 jwsThemeModule.owl_caousel_init($this.find('.info_box ')); 213 } 214 }); 215 }; 216 217 218 219 220 /** 221 *------------------------------------------------------------------------------------------------------------------------------------------- 222 * video popup 223 *------------------------------------------------------------------------------------------------------------------------------------------- 224 */ 225 var demo_filter = function($scope, $) { 226 $scope.find('.jws_demo_element').eq(0).each(function() { 227 228 }); 229 }; 230 /** 231 *------------------------------------------------------------------------------------------------------------------------------------------- 232 * video popup 233 *------------------------------------------------------------------------------------------------------------------------------------------- 234 */ 235 var video_popup = function($scope, $) { 236 237 $scope.find('.jws_video_popup').eq(0).each(function() { 238 239 240 241 242 243 }); 244 }; 245 246 247 248 /** 249 *------------------------------------------------------------------------------------------------------------------------------------------- 250 * gallery Filter 251 *------------------------------------------------------------------------------------------------------------------------------------------- 252 */ 253 var jws_gallery = function($scope, $) { 254 255 $scope.find('.jws_gallery_element').eq(0).each(function() { 256 var $this = $(this), 257 $container = $this.find('.jws_gallery'); 258 259 //init flickity 260 var pageDots = false; 261 if($container.hasClass('has-dots')) { 262 pageDots = true; 263 } 264 265 266 $container.magnificPopup({ 267 delegate: '.jws-popup-global', 268 type: 'image', 269 tLoading: 'Loading image #%curr%...', 270 mainClass: 'mfp-img-mobile', 271 gallery: { 272 enabled: true, 273 navigateByImgClick: true, 274 preload: [0,1] // Will preload 0 - before current, and 1 after the current image 275 }, 276 image: { 277 tError: '<a href="%url%">The image #%curr%</a> could not be loaded.', 278 279 } 280 }); 281 282 if(!$container.hasClass('slider')) { 283 284 $container.isotope({ 285 itemSelector: ".jws_gallery_item", 286 layoutMode: 'packery', 287 }); 288 289 290 } 291 292 if($container.hasClass('slider')) { 293 var current,current_side_item,current_side,current_index; 294 $container.on("initialized.owl.carousel", function(event) { 295 296 current = event.item.index; 297 current_side_item = $this.find('.owl-item').eq(current); 298 current_side = current_side_item.find('.slider-item'); 299 current_index = current_side.data('index'); 300 301 current_side_item.prev().removeClass('nextdiv').addClass('prevdiv'); 302 current_side_item.next().removeClass('prevdiv').addClass('nextdiv'); 303 if($container.hasClass('nav-with_number')) { 304 $container.append('<div class="owl-number"><span class="current">'+parseInt(current_index)+'</span>/<span class="total">
304'+event.item.count+'</span></div>') 305 } 306 307 }); 308 309 jwsThemeModule.owl_caousel_init($container); 310 311 $container.on('translate.owl.carousel', function(event) { 312 313 current = event.item.index; 314 current_side_item = $this.find('.owl-item').eq(current); 315 current_side = current_side_item.find('.slider-item'); 316 current_index = current_side.data('index'); 317 318 current_side_item.prev().removeClass('nextdiv').addClass('prevdiv'); 319 current_side_item.next().removeClass('prevdiv').addClass('nextdiv'); 320 321 $this.find(".owl-number .current").text(current_index); 322 323 }); 324 325 326 } 327 328 }); 329 }; 330 331 332 333 /** 334 *------------------------------------------------------------------------------------------------------------------------------------------- 335 * Google Map 336 *------------------------------------------------------------------------------------------------------------------------------------------- 337 */ 338 var WidgetjwsGoogleMapHandler = function($scope) { 339 if('undefined' == typeof $scope) return; 340 var selector = $scope.find('.jws-google-map').eq(0), 341 locations = selector.data('locations'), 342 map_style = (selector.data('custom-style') != '') ? selector.data('custom-style') : '', 343 predefined_style = (selector.data('predefined-style') != '') ? selector.data('predefined-style') : '', 344 info_window_size = (selector.data('max-width') != '') ? selector.data('max-width') : '', 345 animate = selector.data('animate'), 346 auto_center = selector.data('auto-center'), 347 maker_offset = selector.data('offset'), 348 map_options = selector.data('map_options'), 349 i = '', 350 bounds = new google.maps.LatLngBounds(), 351 marker_cluster = [], 352 className = 'map_pin_jws'; 353 var animation; 354 if('drop' == animate) { 355 animation = google.maps.Animation.DROP; 356 } else if('bounce' == animate) { 357 animation = google.maps.Animation.BOUNCE; 358 } 359 360 function _typeof(obj) { 361 var _typeof; 362 if(typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { 363 _typeof = function _typeof(obj) { 364 return typeof obj; 365 }; 366 } else { 367 _typeof = function _typeof(obj) { 368 return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; 369 }; 370 } 371 return _typeof(obj); 372 } 373 374 function CustomMarker(latlng, map, className) { 375 this.latlng_ = latlng; 376 this.className = className; // Once the LatLng and text are set, add the overlay to the map. This will 377 // trigger a call to panes_changed which should in turn call draw. 378 this.setMap(map); 379 } 380 if((typeof google === "undefined" ? "undefined" : _typeof(google)) !== _typeof(undefined) && _typeof(google.maps) !== _typeof(undefined)) { 381 CustomMarker.prototype = new google.maps.OverlayView(); 382 CustomMarker.prototype.draw = function() { 383 var me = this; // Check if the div has been created. 384 var div = this.div_, 385 divChild, 386 divChild2; 387 if(!div) { 388 // Create a overlay text DIV 389 div = this.div_ = document.createElement('DIV'); 390 div.className = this.className; 391 divChild = document.createElement("div"); 392 div.appendChild(divChild); 393 divChild2 = document.createElement("div"); 394 div.appendChild(divChild2); 395 google.maps.event.addDomListener(div, "click", function() { 396 google.maps.event.trigger(me, "click"); 397 }); // Then add the overlay to the DOM 398 var panes = this.getPanes(); 399 panes.overlayImage.appendChild(div); 400 } // Position the overlay 401 var point = this.getProjection().fromLatLngToDivPixel(this.latlng_); 402 if(point) { 403 div.style.left = point.x + 'px'; 404 div.style.top = point.y + 'px'; 405 } 406 }; 407 CustomMarker.prototype.remove = function() { 408 // Check if the overlay was on the map and needs to be removed. 409 if(this.div_) { 410 this.div_.parentNode.removeChild(this.div_); 411 this.div_ = null; 412 } 413 }; 414 CustomMarker.prototype.getPosition = function() { 415 return this.latlng_; 416 }; 417 } 418 var skins = { 419 "silver": "[{\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#f5f5f5\"}]},{\"elementType\":\"labels.icon\",\"stylers\":[{\"visibility\":\"off\"}]},{\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#616161\"}]},{\"elementType\":\"labels.text.stroke\",\"stylers\":[{\"color\":\"#f5f5f5\"}]},{\"featureType\":\"administrative.land_parcel\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#bdbdbd\"}]},{\"featureType\":\"poi\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#eeeeee\"}]},{\"featureType\":\"poi\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#757575\"}]},{\"featureType\":\"poi.park\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#e5e5e5\"}]},{\"featureType\":\"poi.park\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#9e9e9e\"}]},{\"featureType\":\"road\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#ffffff\"}]},{\"featureType\":\"road.arterial\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#757575\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#dadada\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#616161\"}]},{\"featureType\":\"road.local\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#9e9e9e\"}]},{\"featureType\":\"transit.line\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#e5e5e5\"}]},{\"featureType\":\"transit.station\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#eeeeee\"}]},{\"featureType\":\"water\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#c9c9c9\"}]},{\"featureType\":\"water\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#9e9e9e\"}]}]", 420 "retro": "[{\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#ebe3cd\"}]},{\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#523735\"}]},{\"elementType\":\"labels.text.stroke\",\"stylers\":[{\"color\":\"#f5f1e6\"}]},{\"featureType\":\"administrative\",\"elementType\":\"geometry.stroke\",\"stylers\":[{\"color\":\"#c9b2a6\"}]},{\"featureType\":\"administrative.land_parcel\",\"elementType\":\"geometry.stroke\",\"stylers\":[{\"color\":\"#dcd2be\"}]},{\"featureType\":\"administrative.land_parcel\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#ae9e90\"}]},{\"featureType\":\"landscape.natural\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#dfd2ae\"}]},{\"featureType\":\"poi\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#dfd2ae\"}]},{\"featureType\":\"poi\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#93817c\"}]},{\"featureType\":\"poi.park\",\"elementType\":\"geometry.fill\",\"stylers\":[{\"color\":\"#a5b076\"}]},{\"featureType\":\"poi.park\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#447530\"}]},{\"featureType\":\"road\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#f5f1e6\"}]},{\"featureType\":\"road.arterial\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#fdfcf8\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#f8c967\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"geometry.stroke\",\"stylers\":[{\"color\":\"#e9bc62\"}]},{\"featureType\":\"road.highway.controlled_access\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#e98d58\"}]},{\"featureType\":\"road.highway.controlled_access\",\"elementType\":\"geometry.stroke\",\"stylers\":[{\"color\":\"#db8555\"}]},{\"featureType\":\"road.local\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#806b63\"}]},{\"featureType\":\"transit.line\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#dfd2ae\"}]},{\"featureType\":\"transit.line\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#8f7d77\"}]},{\"featureType\":\"transit.line\",\"elementType\":\"labels.text.stroke\",\"stylers\":[{\"color\":\"#ebe3cd\"}]},{\"featureType\":\"transit.station\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#dfd2ae\"}]},{\"featureType\":\"water\",\"elementType\":\"geometry.fill\",\"stylers\":[{\"color\":\"#b9d3c2\"}]},{\"featureType\":\"water\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#92998d\"}]}]", 421 "dark": "[{\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#212121\"}]},{\"elementType\":\"labels.icon\",\"stylers\":[{\"visibility\":\"off\"}]},{\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#757575\"}]},{\"elementType\":\"labels.text.stroke\",\"stylers\":[{\"color\":\"#212121\"}]},{\"featureType\":\"administrative\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#757575\"}]},{\"featureType\":\"administrative.country\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#9e9e9e\"}]},{\"featureType\":\"administrative.land_parcel\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"administrative.locality\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#bdbdbd\"}]},{\"featureType\":\"poi\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#757575\"}]},{\"featureType\":\"poi.park\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#181818\"}]},{\"featureType\":\"poi.park\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#616161\"}]},{\"featureType\":\"poi.park\",\"elementType\":\"labels.text.stroke\",\"stylers\":[{\"color\":\"#1b1b1b\"}]},{\"featureType\":\"road\",\"elementType\":\"geometry.fill\",\"stylers\":[{\"color\":\"#2c2c2c\"}]},{\"featureType\":\"road\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#8a8a8a\"}]},{\"featureType\":\"road.arterial\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#373737\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#3c3c3c\"}]},{\"featureType\":\"road.highway.controlled_access\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#4e4e4e\"}]},{\"featureType\":\"road.local\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#616161\"}]},{\"featureType\":\"transit\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#757575\"}]},{\"featureType\":\"water\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#000000\"}]},{\"featureType\":\"water\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#3d3d3d\"}]}]", 422 "night": "[{\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#242f3e\"}]},{\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#746855\"}]},{\"elementType\":\"labels.text.stroke\",\"stylers\":[{\"color\":\"#242f3e\"}]},{\"featureType\":\"administrative.locality\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#d59563\"}]},{\"featureType\":\"poi\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#d59563\"}]},{\"featureType\":\"poi.park\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#263c3f\"}]},{\"featureType\":\"poi.park\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#6b9a76\"}]},{\"featureType\":\"road\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#38414e\"}]},{\"featureType\":\"road\",\"elementType\":\"geometry.stroke\",\"stylers\":[{\"color\":\"#212a37\"}]},{\"featureType\":\"road\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#9ca5b3\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#746855\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"geometry.stroke\",\"stylers\":[{\"color\":\"#1f2835\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#f3d19c\"}]},{\"featureType\":\"transit\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#2f3948\"}]},{\"featureType\":\"transit.station\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#d59563\"}]},{\"featureType\":\"water\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#17263c\"}]},{\"featureType\":\"water\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#515c6d\"}]},{\"featureType\":\"water\",\"elementType\":\"labels.text.stroke\",\"stylers\":[{\"color\":\"#17263c\"}]}]", 423 "aubergine": "[{\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#1d2
423c4d\"}]},{\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#8ec3b9\"}]},{\"elementType\":\"labels.text.stroke\",\"stylers\":[{\"color\":\"#1a3646\"}]},{\"featureType\":\"administrative.country\",\"elementType\":\"geometry.stroke\",\"stylers\":[{\"color\":\"#4b6878\"}]},{\"featureType\":\"administrative.land_parcel\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#64779e\"}]},{\"featureType\":\"administrative.province\",\"elementType\":\"geometry.stroke\",\"stylers\":[{\"color\":\"#4b6878\"}]},{\"featureType\":\"landscape.man_made\",\"elementType\":\"geometry.stroke\",\"stylers\":[{\"color\":\"#334e87\"}]},{\"featureType\":\"landscape.natural\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#023e58\"}]},{\"featureType\":\"poi\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#283d6a\"}]},{\"featureType\":\"poi\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#6f9ba5\"}]},{\"featureType\":\"poi\",\"elementType\":\"labels.text.stroke\",\"stylers\":[{\"color\":\"#1d2c4d\"}]},{\"featureType\":\"poi.park\",\"elementType\":\"geometry.fill\",\"stylers\":[{\"color\":\"#023e58\"}]},{\"featureType\":\"poi.park\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#3C7680\"}]},{\"featureType\":\"road\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#304a7d\"}]},{\"featureType\":\"road\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#98a5be\"}]},{\"featureType\":\"road\",\"elementType\":\"labels.text.stroke\",\"stylers\":[{\"color\":\"#1d2c4d\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#2c6675\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"geometry.stroke\",\"stylers\":[{\"color\":\"#255763\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#b0d5ce\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"labels.text.stroke\",\"stylers\":[{\"color\":\"#023e58\"}]},{\"featureType\":\"transit\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#98a5be\"}]},{\"featureType\":\"transit\",\"elementType\":\"labels.text.stroke\",\"stylers\":[{\"color\":\"#1d2c4d\"}]},{\"featureType\":\"transit.line\",\"elementType\":\"geometry.fill\",\"stylers\":[{\"color\":\"#283d6a\"}]},{\"featureType\":\"transit.station\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#3a4762\"}]},{\"featureType\":\"water\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#0e1626\"}]},{\"featureType\":\"water\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#4e6d70\"}]}]", 424 "magnesium": "[{\"featureType\":\"all\",\"stylers\":[{\"saturation\":0},{\"hue\":\"#e7ecf0\"}]},{\"featureType\":\"road\",\"stylers\":[{\"saturation\":-70}]},{\"featureType\":\"transit\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"poi\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"water\",\"stylers\":[{\"visibility\":\"simplified\"},{\"saturation\":-60}]}]", 425 "classic_blue": "[{\"featureType\":\"all\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"on\"}]},{\"featureType\":\"administrative.country\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"on\"}]},{\"featureType\":\"administrative.country\",\"elementType\":\"labels.text\",\"stylers\":[{\"visibility\":\"on\"}]},{\"featureType\":\"administrative.province\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"on\"}]},{\"featureType\":\"administrative.province\",\"elementType\":\"labels.text\",\"stylers\":[{\"visibility\":\"on\"}]},{\"featureType\":\"administrative.locality\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"on\"}]},{\"featureType\":\"administrative.neighborhood\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"administrative.land_parcel\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"landscape\",\"elementType\":\"all\",\"stylers\":[{\"hue\":\"#FFBB00\"},{\"saturation\":43.400000000000006},{\"lightness\":37.599999999999994},{\"gamma\":1}]},{\"featureType\":\"landscape\",\"elementType\":\"geometry.fill\",\"stylers\":[{\"saturation\":\"-40\"},{\"lightness\":\"36\"}]},{\"featureType\":\"landscape.man_made\",\"elementType\":\"geometry\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"landscape.natural\",\"elementType\":\"geometry.fill\",\"stylers\":[{\"saturation\":\"-77\"},{\"lightness\":\"28\"}]},{\"featureType\":\"landscape.natural\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"poi\",\"elementType\":\"all\",\"stylers\":[{\"hue\":\"#00FF6A\"}
425,{\"saturation\":-1.0989010989011234},{\"lightness\":11.200000000000017},{\"gamma\":1}]},{\"featureType\":\"poi\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"poi.attraction\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"poi.park\",\"elementType\":\"geometry.fill\",\"stylers\":[{\"saturation\":\"-24\"},{\"lightness\":\"61\"}]},{\"featureType\":\"road\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"on\"}]},{\"featureType\":\"road\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"visibility\":\"on\"}]},{\"featureType\":\"road\",\"elementType\":\"labels.icon\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"all\",\"stylers\":[{\"hue\":\"#FFC200\"},{\"saturation\":-61.8},{\"lightness\":45.599999999999994},{\"gamma\":1}]},{\"featureType\":\"road.highway\",\"elementType\":\"labels.icon\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"road.highway.controlled_access\",\"elementType\":\"labels.icon\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"road.arterial\",\"elementType\":\"all\",\"stylers\":[{\"hue\":\"#FF0300\"},{\"saturation\":-100},{\"lightness\":51.19999999999999},{\"gamma\":1}]},{\"featureType\":\"road.local\",\"elementType\":\"all\",\"stylers\":[{\"hue\":\"#ff0300\"},{\"saturation\":-100},{\"lightness\":52},{\"gamma\":1}]},{\"featureType\":\"road.local\",\"elementType\":\"labels.icon\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"transit\",\"elementType\":\"geometry\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"transit\",\"elementType\":\"geometry.stroke\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"transit\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"transit\",\"elementType\":\"labels.icon\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"transit.line\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"transit.station\",\"elementType\":\"labels.icon\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"water\",\"elementType\":\"all\",\"stylers\":[{\"hue\":\"#0078FF\"},{\"saturation\":-13.200000000000003},{\"lightness\":2.4000000000000057},{\"gamma\":1}]},{\"featureType\":\"water\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"off\"}]}]", 426 "aqua": "[{\"featureType\":\"administrative\",\"elementType\":\"labels.text.fill\",\"stylers\":[{\"color\":\"#444444\"}]},{\"featureType\":\"landscape\",\"elementType\":\"all\",\"stylers\":[{\"color\":\"#f2f2f2\"}]},{\"featureType\":\"poi\",\"elementType\":\"all\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"road\",\"elementType\":\"all\",\"stylers\":[{\"saturation\":-100},{\"lightness\":45}]},{\"featureType\":\"road.highway\",\"elementType\":\"all\",\"stylers\":[{\"visibility\":\"simplified\"}]},{\"featureType\":\"road.arterial\",\"elementType\":\"labels.icon\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"transit\",\"elementType\":\"all\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"water\",\"elementType\":\"all\",\"stylers\":[{\"color\":\"#46bcec\"},{\"visibility\":\"on\"}]}]", 427 "earth": "[{\"featureType\":\"landscape.man_made\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#f7f1df\"}]},{\"featureType\":\"landscape.natural\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#d0e3b4\"}]},{\"featureType\":\"landscape.natural.terrain\",\"elementType\":\"geometry\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"poi\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"poi.business\",\"elementType\":\"all\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"poi.medical\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#fbd3da\"}]},{\"featureType\":\"poi.park\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#bde6ab\"}]},{\"featureType\":\"road\",\"elementType\":\"geometry.stroke\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"road\",\"elementType\":\"labels\",\"stylers\":[{\"visibility\":\"off\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"geometry.fill\",\"stylers\":[{\"color\":\"#ffe15f\"}]},{\"featureType\":\"road.highway\",\"elementType\":\"geometry.stroke\",\"stylers\":[{\"color\":\"#efd1
42751\"}]},{\"featureType\":\"road.arterial\",\"elementType\":\"geometry.fill\",\"stylers\":[{\"color\":\"#ffffff\"}]},{\"featureType\":\"road.local\",\"elementType\":\"geometry.fill\",\"stylers\":[{\"color\":\"black\"}]},{\"featureType\":\"transit.station.airport\",\"elementType\":\"geometry.fill\",\"stylers\":[{\"color\":\"#cfb2db\"}]},{\"featureType\":\"water\",\"elementType\":\"geometry\",\"stylers\":[{\"color\":\"#a2daf2\"}]}]" 428 }; 429 if('undefined' != typeof skins[predefined_style]) { 430 map_style = JSON.parse(skins[predefined_style]); 431 } 432 (function initMap() { 433 var latlng = new google.maps.LatLng(locations[0][0], locations[0][1]); 434 map_options.center = latlng; 435 map_options.styles = map_style; 436 if(false == map_options.gestureHandling) { 437 map_options.gestureHandling = 'none'; 438 } 439 var map = new google.maps.Map($scope.find('.jws-google-map')[0], map_options); 440 var infowindow = new google.maps.InfoWindow(); 441 var marker; 442 for(i = 0; i < locations.length; i++) { 443 var title = locations[i][3]; 444 var description = locations[i][4]; 445 var images_info = locations[i][5]; 446 var icon_size = parseInt(locations[i][8]); 447 var icon_type = locations[i][6]; 448 var icon = ''; 449 var icon_url = locations[i][7]; 450 var enable_iw = locations[i][2]; 451 var click_open = locations[i][9]; 452 var lat = locations[i][0]; 453 var lng = locations[i][1]; 454 var infoWindow_opened = false; 455 if('undefined' === typeof locations[i]) { 456 return; 457 } 458 if('' != lat.length && '' != lng.length) { 459 if('custom' == icon_type) { 460 icon = { 461 url: icon_url, 462 }; 463 if(!isNaN(icon_size)) { 464 icon.scaledSize = new google.maps.Size(icon_size, icon_size); 465 icon.origin = new google.maps.Point(0, 0); 466 icon.anchor = new google.maps.Point(icon_size / 2, icon_size); 467 } 468 marker = new google.maps.Marker({ 469 position: new google.maps.LatLng(lat, lng), 470 map: map, 471 title: title, 472 icon: icon, 473 animation: animation 474 }); 475 } else if('html' == icon_type) { 476 marker = new CustomMarker(new google.maps.LatLng(lat, lng), map, className); 477 } else { 478 marker = new google.maps.Marker({ 479 position: new google.maps.LatLng(lat, lng), 480 map: map, 481 title: title, 482 icon: icon, 483 animation: animation 484 }); 485 } 486 if('undefined' !== typeof maker_offset) { 487 map.panBy(0, maker_offset); 488 } 489 if(locations.length > 1) { 490 // Extend the bounds to include each marker's position 491 bounds.extend(marker.position); 492 } 493 marker_cluster[i] = marker; 494 if(enable_iw && 'iw_open' == click_open) { 495 infoWindow_opened = true; 496 var has_image = ''; 497 if(images_info != '') { 498 has_image = ' has-image'; 499 } 500 501 var content_string = '<div class="jws-infowindow-content'+has_image+'">'; 502 503 504 if(images_info != '') { 505 content_string += '<div class="info-left"><img src="' + images_info + '"></div>'; 506 } 507 if('' != description.length) { 508 content_string += ' <div class="content-right"><div class="jws-infowindow-title">' + title + '</div><div class="jws-infowindow-description">' + description + '</div></div>'; 509 } 510 511 content_string += '</div>'; 512 if('' != info_window_size) { 513 var width_val = parseInt(info_window_size); 514 infowindow = new google.maps.InfoWindow({ 515 content: content_string, 516 maxWidth: width_val 517 }); 518 } else { 519 infowindow = new google.maps.InfoWindow({ 520 content: content_string, 521 }); 522 } 523 infowindow.open(map, marker); 524 } 525 // Adding close event for info window 526 infowindow.addListener('closeclick', ()=>{ 527 infoWindow_opened = false; 528 }); 529 if(enable_iw && '' != locations[i][3]) { 530 google.maps.event.addListener(marker, 'click', (function(marker, i) { 531 var infowindow = new google.maps.InfoWindow(); 532 var has_image = ''; 533 if(locations[i][5] != '') { 534 has_image = ' has-image'; 535 } 536 var content_string = '<div class="jws-infowindow-content'+has_image+'">'; 537 538 539 if('' != locations[i][5]) { 540 541 content_string += '<div class="info-left"><img src="' + locations[i][5] + '"></div>'; 542 543 } 544 545 content_string += '<div class="content-right"><div class="jws-infowindow-title">' + locations[i][3] + '</div>'; 546 if('' != locations[i][4].length) { 547 content_string += '<div class="jws-infowindow-description">' + locations[i][4] + '</div></div>'; 548 } 549 550 content_string += '</div>'; 551 552 return function() { 553 554 infowindow.setContent(content_string); 555 if('' != info_window_size) { 556 var width_val = parseInt(info_window_size); 557 var InfoWindowOptions = { 558 maxWidth: width_val 559 }; 560 infowindow.setOptions({ 561 options: InfoWindowOptions 562 }); 563 } 564 565 if(!infoWindow_opened) { 566 infowindow.open(map, marker); 567 } 568 569 570 }; 571 572 })(marker, i)); 573 } 574 } 575 } 576 if(locations.length > 1) { 577 if('center' == auto_center) { 578 // Now fit the map to the newly inclusive bounds. 579 map.fitBounds(bounds); 580 } 581 // Restore the zoom level after the map is done scaling. 582 var listener = google.maps.event.addListener(map, "idle", function() { 583 map.setZoom(map_options.zoom); 584 google.maps.event.removeListener(listener); 585 }); 586 } 587 })(); 588 }; 589 590 /** 591 * Menu Style. 592 * 593 */ 594 var jws_menu_list = function($scope, $) { 595 596 if('undefined' == typeof $scope) { 597 return; 598 } 599 600 $scope.find('.jws-menu-list').eq(0).each(function() { 601 var $this = $(this); 602 function onScroll() { 603 var scrollPos = $(document).scrollTop(); 604 $this.find('a').each(function() { 605 var currLink = $(this); 606 var refElement = $(currLink.attr("href")); 607 if(refElement.length > 0) { 608 if (refElement.position().top <= scrollPos + 100 && refElement.position().top + refElement.height() > scrollPos + 100) { 609 $this.find('a').parent().removeClass("current-menu-item"); 610 currLink.parent().addClass("current-menu-item"); 611 } else { 612 currLink.parent().removeClass("current-menu-item"); 613 } 614 } 615 }); 616 617 618 }; 619 onScroll(); 620 $(document).on("scroll", onScroll); 621 622 623 }); 624 625 } 626 627 628 var jws_menu_style = function($scope, $) { 629 if('undefined' == typeof $scope) { 630 return; 631 } 632 $scope.find('.jws_main_menu').eq(0).each(function() { 633 var $this = $(this); 634 $(this).find('.elementor-icon-list-item.active').parents('.nav > li').addClass('current-menu-item'); 635 if($this.closest('.elementor-widget-jws_menu_nav').hasClass('elementor-before-menu-skin-animation-line')) { 636 var main = $this.find(".jws_main_menu_inner"), 637 curent_item = main.find('> ul > li.current-menu-item , > ul > li.current-menu-ancestor'), 638 curent_item_sub = main.find('ul li.current-menu-item , .elementor-icon-list-item.active'); 639 if(main.find('> ul > li.current-menu-item').length == 0) { 640 if(curent_item_sub.length > 0) { 641 curent_item = curent_item_sub.parents('.nav > li'); 642 } else { 643 curent_item = main.find('> ul > li:first-child'); 644 } 645 } 646 }
647 /** Menu toggle **/ 648 $this.find('.click-show-menu-v').on('click', function() { 649 $this.find('.menu-toggle').toggleClass('open'); 650 }); 651 }); 652 //mega menu 653 var mainMenu = $('.elementor_jws_menu_layout_menu_horizontal').find('.nav'); 654 var mega_item = mainMenu.find(' > li.menu-item-design-mega_menu_full_width'); 655 656 if (mega_item.length > 0) { 657 $('.jws_header').addClass('has-mega-full'); 658 } 659 660 mega_item.mouseenter(function() { 661 $('.jws_header.has-mega-full').addClass('mega-has-hover'); 662 }); 663 664 mega_item.mouseleave(function() { 665 $('.jws_header.has-mega-full').removeClass('mega-has-hover'); 666 }); 667 668 669 }; 670 671 var tooltip = function($scope, $) { 672 $scope.find('.jws-tooltip-list').eq(0).each(function() { 673 $(this).find('button').on("click", function() { 674 var item = $(this).parents('li'); 675 item.toggleClass('active').siblings().removeClass('active'); 676 }); 677 }); 678 }; 679 var instagram = function($scope, $) { 680 $scope.find('.jws-instagram').eq(0).each(function() { 681 var $this = $(this); 682 var height_start = $this.find('.jws-instagram-item.col-xl-4').height(); 683 $this.find('.instagram-wap').css('height',height_start); 684 685 if($(this).hasClass('metro')){ 686 setTimeout(function() { 687 $this.find('.loader').remove(); 688 $this.find('.instagram-wap').removeClass('loading').isotope({ 689 itemSelector: ".jws-instagram-item", 690 layoutMode: 'masonry', 691 transitionDuration: "0.3s", 692 masonry: { 693 // use outer width of grid-sizer for columnWidth 694 columnWidth: '.grid-sizer', 695 } 696 }); 697 }, 2000); 698 } 699 }); 700 }; 701 702 703 var syncPosition = function(el,thumbnail_nav) { 704 var count = el.item.count - 1; 705 var current = Math.round(el.item.index - el.item.count / 2 - 0.5); 706 707 var clone_lenght = el.relatedTarget._clones.length; 708 709 if (current < 0) { 710 current = count; 711 } 712 if (current > count) { 713 current = 0; 714 } 715 716 717 var change_nav = thumbnail_nav 718 .find(".owl-item").not( ".cloned" ).find('.slider-item[data-index="'+current+'"]'); 719 var change = change_nav.parent().index(); 720 721 //to this 722 thumbnail_nav 723 .find(".owl-item") 724 .removeClass("current") 725 .eq(change) 726 .addClass("current"); 727 728 var end = thumbnail_nav 729 .find(".owl-item.active") 730 .last() 731 .index(); 732 733 if (change > end) { 734 thumbnail_nav.data("owl.carousel").to(change - 1, 100, true); 735 }else { 736 thumbnail_nav.data("owl.carousel").to(change, 100, true); 737 } 738 739 }; 740 741 742 var slider_elementor = function($scope, $) { 743 var $events, 744 prev_side, 745 current_side, 746 current, 747 current_index, 748 current_side_item; 749 750 $scope.find('.jws_slider_element').eq(0).each(function() { 751 var $container = $(this).find('.jws_slider'); 752 var $this = $(this); 753 var verticalSwiping = false; 754 var window_offset = 0; 755 var thumbnail_nav = $container.next('.thumbnail-nav'); 756 757 758 759 760 $container.on("initialized.owl.carousel", function(event) { 761 current = event.item.index; 762 current_side_item = $this.find('.owl-item').eq(current); 763 current_side = current_side_item.find('.slider-item'); 764 current_index = current_side.data('index') + 1; 765 $this.find(".jws-button-prev").text(parseInt(current_index)); 766 $this.find(".jws-button-next").text(parseInt(current_index + 1)); 767 $this.find(".jws-nav-pre span").css('width',parseInt(current_index) / event.item.count * 100+'%'); 768 769 current_side_item.prev().removeClass('nextdiv').addClass('prevdiv'); 770 current_side_item.next().removeClass('prevdiv').addClass('nextdiv'); 771 }); 772 773 774 jwsThemeModule.owl_caousel_init($container); 775 776 $container.on('translate.owl.carousel', function(event) { 777 778 current = event.item.index; 779 current_side_item = $this.find('.owl-item').eq(current); 780 current_side = current_side_item.find('.slider-item'); 781 current_index = current_side.data('index') + 1; 782 783 $events = 'no'; 784 section_change(current_side,$events); 785 786 current_side_item.prev().removeClass('nextdiv').addClass('prevdiv'); 787 current_side_item.next().removeClass('prevdiv').addClass('nextdiv'); 788 789 790 $this.find(".jws-button-prev").text(current_index); 791 console.log(parseInt(current)); 792 console.log(event.item.count); 793 if(parseInt(current_index + 1) > event.item.count) { 794 $this.find(".jws-button-next").text(current_index); 795 }else{ 796 $this.find(".jws-button-next").text(parseInt(current_index + 1)); 797 } 798 $this.find(".jws-nav-pre span").css('width',parseInt(current_index) / event.item.count * 100+'%'); 799 }); 800 801 802 $container.on('translated.owl.carousel', function(event) { 803 804 current = event.item.index; 805 current_side = $this.find('.owl-item').eq(current).find('.slider-item'); 806 807 808 $events = 'next'; 809 section_change(current_side,$events); 810 811 812 813 }); 814 815 $this.find(".jws-button-next").on('click',function() { 816 $container.trigger('next.owl.carousel'); 817 }); 818 $this.find(".jws-button-prev").on('click',function() { 819 $container.trigger('prev.owl.carousel'); 820 }); 821 822 if(thumbnail_nav.length) { 823 824 $container.on('changed.owl.carousel', function(event) { 825 syncPosition(event , thumbnail_nav); 826 }); 827 828 var options_nav = thumbnail_nav.data('owl-option'); 829 thumbnail_nav.on("initialized.owl.carousel", function() { 830 thumbnail_nav 831 .find(".owl-item") 832 .eq(0) 833 .addClass("current"); 834 }); 835 thumbnail_nav.owlCarousel(options_nav); 836 837 838 thumbnail_nav.on("click", ".owl-item", function(e){ 839 e.preventDefault(); 840 var number = $(this).find('.slider-item').data('index'); 841 var clone = $container.find('.cloned').length; 842 var change_nav = $container.find('.owl-item').not( ".cloned" ).find('.slider-item[data-index="'+number+'"]'); 843 $container.trigger("to.owl.carousel", change_nav.parent().index() - clone / 2 ) 844 845 846 }); 847 } 848 849 }); 850 function section_change($slick,$events) { 851 $slick.find('[data-element_type="widget"] , [data-element_type="section"] > [data-element_type="section"] , [data-element_type="column"]').each(function() { 852 var data = $(this).data('settings'); 853 var $this = $(this); 854 var $animation; 855 var $animation_delay; 856 if(data !== undefined ) { 857 858 if($this.hasClass('elementor-section') || $this.hasClass('elementor-column')) { 859 $animation = data.animation; 860 $animation_delay = data.animation_delay; 861 }else { 862 $animation = data._animation 863 $animation_delay = data._animation_delay; 864 } 865 866 if($animation !== undefined) { 867 $this.addClass('has_animated'); 868 } 869 if($animation_delay !== undefined) { 870 871 if($events == 'next') { 872 setTimeout(function(){ 873 $this.addClass('animated'); 874 $this.addClass($animation); 875 },$animation_delay); ; 876 }else { 877 $this.removeClass('animated'); 878 $this.removeClass($animation); 879 } 880 }else if(data !== undefined) { 881 if($events == 'next') { 882 setTimeout(function(){ 883 $this.addClass('animated'); 884 $this.addClass($animation); 885 },0); 886 }else { 887 $this.removeClass('animated'); 888 $this.removeClass($animation); 889 } 890 } 891 } 892 }); 893 894 } 895 896 }; 897 898 899 900 var countdown = function($scope, $) { 901 $scope.find('.countdown-container').eq(0).each(function() { 902 var $coundown = $(this).find('.countdown'); 903 $().jws_countdown($coundown); 904 }); 905 }; 906 907 var check_slider = function($scope, $) { 908 $scope.find('.elementor-main-swiper').eq(0).each(function() { 909 var slider = new Swiper ('.elementor-main-swiper', { 910 slidesPerView: 1, 911 centeredSlides: true, 912 loop: true, 913 loopedSlides: 6, //?????????????? 914 navigation: { 915 nextEl: '.swiper-button-next', 916 prevEl: '.swiper-button-prev', 917 }, 918 }); 919 }); 920 }; 921 922 var category_list = function($scope, $) { 923 924 $scope.find('.jws-category-list').eq(0).each(function() { 925 jwsThemeModule.owl_caousel_init($(this).find('.jws-slider')); 926 }); 927 }; 928 929 var initSection = function ($obj) { 930 var $events, 931 prev_side, 932 current_side, 933 current, 934 current_index, 935 current_side_item, 936 $container = $obj.children('.elementor-container'); 937 if($container.hasClass('jws_section_slider')) { 938 939 $container.eq(0).each(function() { 940 var $this = $(this); 941 var verticalSwiping = false;
942 var window_offset; 943 var thumbnail_nav = $container.next('.thumbnail-nav'); 944 945 946 947 $container.on("initialized.owl.carousel", function(event) { 948 current = event.item.index; 949 current_side_item = $this.find('.owl-item').eq(current); 950 current_side = current_side_item.find('> .elementor-column'); 951 current_side_item.prev().removeClass('nextdiv').addClass('prevdiv'); 952 current_side_item.next().removeClass('prevdiv').addClass('nextdiv'); 953 }); 954 955 956 jwsThemeModule.owl_caousel_init($container); 957 958 $container.on('translate.owl.carousel', function(event) { 959 960 current = event.item.index; 961 current_side_item = $this.find('.owl-item').eq(current); 962 current_side = current_side_item.find('> .elementor-column'); 963 964 $events = 'no'; 965 966 section_change(current_side,$events); 967 968 969 current_side_item.prev().removeClass('nextdiv').addClass('prevdiv'); 970 current_side_item.next().removeClass('prevdiv').addClass('nextdiv'); 971 972 973 }); 974 975 976 $container.on('translated.owl.carousel', function(event) { 977 978 current = event.item.index; 979 current_side = $this.find('.owl-item').eq(current).find('> .elementor-column'); 980 981 982 $events = 'next'; 983 984 section_change(current_side,$events); 985 986 987 988 }); 989 990 $this.find(".jws-button-next").on('click',function() { 991 $container.trigger('next.owl.carousel'); 992 }); 993 $this.find(".jws-button-prev").on('click',function() { 994 $container.trigger('prev.owl.carousel'); 995 }); 996 997 998 999 1000 }); 1001 function section_change($slick,$events) { 1002 $slick.find('[data-element_type="widget"]').each(function() { 1003 var data = $(this).data('settings'); 1004 var $this = $(this); 1005 var $animation; 1006 var $animation_delay; 1007 1008 if(data !== undefined ) { 1009 1010 if($this.hasClass('elementor-section') || $this.hasClass('elementor-column')) { 1011 $animation = data.animation; 1012 $animation_delay = data.animation_delay; 1013 }else { 1014 $animation = data._animation 1015 $animation_delay = data._animation_delay; 1016 } 1017 1018 if($animation !== undefined) { 1019 $this.addClass('has_animated'); 1020 } 1021 if($animation_delay !== undefined) { 1022 if($events == 'next') { 1023 setTimeout(function(){ 1024 $this.addClass('animated'); 1025 $this.addClass($animation); 1026 },$animation_delay); ; 1027 }else { 1028 $this.removeClass('animated'); 1029 $this.removeClass($animation); 1030 1031 } 1032 }else if(data !== undefined) { 1033 if($events == 'next') { 1034 setTimeout(function(){ 1035 $this.addClass('animated'); 1036 $this.addClass($animation); 1037 },0); 1038 }else { 1039 $this.removeClass('animated'); 1040 $this.removeClass($animation); 1041 1042 } 1043 } 1044 } 1045 }); 1046 1047 } 1048 } 1049 }; 1050 1051 1052 $(window).on('elementor/frontend/init', function() { 1053 1054 /* const $ = elementorFrontend.elements.window.jQuery, 1055 e = liquidThrottle((e => { 1056 const t = $(e.options.element.el), 1057 n = JSON.parse(t.attr("data-ca-options")), 1058 l = t.data("plugin_liquidCustomAnimations"); 1059 l && l.animationsTimeline && !l.animationsTimeline.isActive() && l.destroy(), t.liquidCustomAnimations(n) 1060 }), 300); 1061 // elementor.channels.editor.on("lqd_ca_apply", e); 1062 1063 */ 1064class D extends elementorModules.frontend.handlers.Base { 1065onInit(...e) { 1066 super.onInit(...e), this.handleDestroy(), this.initSplitText(), this.initTextRotator(), this.initInView() 1067 1068} 1069getDefaultSettings() { 1070 return { 1071 selectors: { 1072 splitTextElement: "[data-split-text]", 1073 textRotatorElement: "[data-text-rotator]", 1074 inViewElement: "[data-inview]", 1075 customAnimationElement: "[data-custom-animations]", 1076 } 1077 } 1078} 1079getDefaultElements() {
1080 const e = this.getSettings("selectors"); 1081 return { 1082 $splitTextElement: this.$element.find(e.splitTextElement), 1083 $textRotatorElement: this.$element.find(e.textRotatorElement), 1084 $inViewElement: this.$element.find(e.inViewElement), 1085 $customAnimationElement: this.$element.find(e.customAnimationElement) 1086 } 1087} 1088initSplitText() { 1089 this.elements.$splitTextElement.liquidSplitText() 1090} 1091initCustomAnimation() { 1092 this.elements.$customAnimationElement.liquidCustomAnimations() 1093} 1094initTextRotator() { 1095 // this.elements.$textRotatorElement.liquidTextRotator() 1096} 1097initInView() { 1098 // this.elements.$inViewElement.liquidInView() 1099} 1100onDestroy() { 1101 this.handleDestroy(), super.onDestroy() 1102} 1103handleDestroy() { 1104 this.handleSplitTextDestroy(), this.handleTextRotatorDestroy() 1105} 1106handleSplitTextDestroy() { 1107 if (!this.elements.$splitTextElement.length) return; 1108 const e = this.elements.$splitTextElement.data("plugin_liquidSplitText"); 1109 e && e.destroy() 1110} 1111handleTextRotatorDestroy() { 1112 if (!this.elements.$textRotatorElement.length) return; 1113 const e = this.elements.$textRotatorElement.data("plugin_liquidTextRotator"); 1114 e && e.destroy() 1115} 1116} 1117 1118elementorFrontend.elementsHandler.attachHandler("jws_advanced_heading", D); 1119 1120/* Marquee Advanced */ 1121 1122class Marquee extends elementorModules.frontend.handlers.Base { 1123 1124onInit(...e) { 1125 1126 super.onInit(...e), this.handleDestroy() , this.initMarquee(); 1127 1128 1129} 1130 1131getDefaultSettings() { 1132 return { 1133 selectors: { 1134 MarqueeElement: ".jws-marquee", 1135 } 1136 } 1137} 1138getDefaultElements() { 1139 const e = this.getSettings("selectors"); 1140 return { 1141 $marqueeElement: this.$element.find(e.MarqueeElement), 1142 } 1143} 1144 1145initMarquee() { 1146 const e = this.elements.$marqueeElement; 1147 imagesLoaded( e , function() { 1148 e.jwsMarquee(); 1149 }); 1150} 1151 1152 1153onDestroy() { 1154 this.handleDestroy(), super.onDestroy() 1155} 1156 1157handleDestroy() { 1158 1159} 1160 1161} 1162 1163elementorFrontend.elementsHandler.attachHandler("marquee_advanced", Marquee); 1164 1165 1166/* Rain Text Advanced */ 1167 1168class Rain_Text extends elementorModules.frontend.handlers.Base { 1169 1170 onInit(...e) { 1171 super.onInit(...e), this.handleDestroy(), this.initThrowable() 1172 } 1173 getDefaultSettings() { 1174 return { 1175 selectors: { 1176 throwableScene: "[data-lqd-throwable-scene]" 1177 } 1178 } 1179 } 1180 getDefaultElements() { 1181 const e = this.getSettings("selectors"); 1182 return { 1183 $throwableScene: this.$element.find(e.throwableScene) 1184 } 1185 } 1186 initThrowable() { 1187 this.elements.$throwableScene.liquidThrowable() 1188 } 1189 onDestroy() { 1190 this.handleDestroy(), super.onDestroy() 1191 } 1192 handleDestroy() { 1193 this.handleThrowableDestroy() 1194 } 1195 handleThrowableDestroy() { 1196 if (!this.elements.$throwableScene.length) return; 1197 const e = this.elements.$throwableScene.data("plugin_liquidThrowable"); 1198 e && e.destroy() 1199 } 1200 1201} 1202 1203elementorFrontend.elementsHandler.attachHandler("jws_rain_text", Rain_Text); 1204 1205 1206/* Svg Draw Advanced */ 1207 1208class Svg_Draw extends elementorModules.frontend.handlers.Base { 1209 1210 onInit(...e) { 1211 super.onInit(...e), this.initDrawShape() 1212 } 1213 getDefaultSettings() { 1214 return { 1215 selectors: { 1216 drawShapeElement: "[data-lqd-draw-shape]" 1217 } 1218 } 1219 } 1220 getDefaultElements() { 1221 const e = this.getSettings("selectors"); 1222 return { 1223 $drawShapeElement: this.$element.find(e.drawShapeElement) 1224 } 1225 } 1226 initDrawShape() { 1227 this.elements.$drawShapeElement.liquidDrawShape() 1228 } 1229 1230} 1231 1232elementorFrontend.elementsHandler.attachHandler("jws_svg_draw", Svg_Draw); 1233 1234 1235/* Tabs */ 1236 1237 1238class Tabs extends elementorModules.frontend.handlers.Base { 1239 1240onInit(...e) { 1241 super.onInit(...e); const settings = this.getSettings(); 1242 if (elementorFrontend.isEditMode()) { 1243 this.interlaceContainers(); 1244 } 1245 this.run_tab(); 1246 1247} 1248getDefaultSettings() { 1249 return { 1250 selectors: { 1251 tabContentContainers: '.tab-content > .e-con', 1252 contentItems: '.tab-item', 1253 nav: '.tab-nav', 1254 button: '.tab-nav li a', 1255 content: '.tab-content' 1256 } 1257 } 1258} 1259getDefaultElements() {
1260 const selectors = this.getSettings("selectors"); 1261 return { 1262 $contentContainers: this.findElement(selectors.tabContentContainers), 1263 $tabItems: this.findElement(selectors.contentItems), 1264 button: this.findElement(selectors.button), 1265 content: this.findElement(selectors.content), 1266 nav: this.findElement(selectors.nav), 1267 } 1268} 1269 1270onEditSettingsChange(propertyName, value) { 1271 console.log(propertyName); 1272 console.log(this.getEditSettings("activeItemIndex")); 1273} 1274 1275interlaceContainers() { 1276 const { 1277 $contentContainers, 1278 $tabItems 1279 } = this.getDefaultElements(); 1280 $contentContainers.each((index, element) => { 1281 $tabItems[index].appendChild(element); 1282 }); 1283} 1284 1285 1286run_tab() { 1287 1288 const { 1289 button, 1290 content, 1291 nav 1292 } = this.getDefaultElements(); 1293 1294 button.on('click',function(e) { 1295 1296 e.preventDefault(); 1297 var tab_id = $(this).attr('data-tab'); 1298 nav.find('li').removeClass('current'); 1299 $(this).parent().addClass('current'); 1300 1301 1302 content.find('>.tab-item').removeClass('current'); 1303 content.find("#" + tab_id).addClass('current'); 1304 1305 var pluginInstance = content.find("#" + tab_id).find('[data-custom-animations]').data('plugin_liquidCustomAnimations'); 1306 if (pluginInstance) { 1307 pluginInstance.destroy(); 1308 } 1309 content.find("#" + tab_id).find('[data-custom-animations]').liquidCustomAnimations(); 1310 1311 }); 1312 1313 1314 1315} 1316 1317 1318onDestroy() { 1319 this.handleDestroy(), super.onDestroy() 1320} 1321handleDestroy() { 1322 1323} 1324 1325} 1326 1327elementorFrontend.elementsHandler.attachHandler("jws_tab", Tabs); 1328 1329 1330 1331/* Jws_topics */ 1332 1333 1334class Jws_topics extends elementorModules.frontend.handlers.Base { 1335 1336onInit(...e) { 1337 super.onInit(...e); const settings = this.getSettings(); 1338 this.run_tab(); 1339 1340} 1341getDefaultSettings() { 1342 return { 1343 selectors: { 1344 contentItems: '.tab-item', 1345 nav: '.category-tag-nav', 1346 button: '.category-tag-nav li a', 1347 content: '.jws-courses-tags' 1348 } 1349 } 1350} 1351getDefaultElements() { 1352 const selectors = this.getSettings("selectors"); 1353 return { 1354 $tabItems: this.findElement(selectors.contentItems), 1355 button: this.findElement(selectors.button), 1356 content: this.findElement(selectors.content), 1357 nav: this.findElement(selectors.nav), 1358 settings: this.findElement(selectors.nav).data('args') 1359 } 1360} 1361 1362onEditSettingsChange(propertyName, value) { 1363 console.log(propertyName); 1364 console.log(this.getEditSettings("activeItemIndex")); 1365} 1366 1367 1368run_tab() { 1369 1370 const { 1371 button, 1372 content, 1373 nav, 1374 settings 1375 } = this.getDefaultElements(); 1376 1377 var data_args = settings; 1378 nav.removeAttr("data-args"); 1379 1380 1381 button.on('click',function(e) { 1382 1383 e.preventDefault(); 1384 var data = {}; 1385 var cat_filter = $(this).data('value'); 1386 data.action = 'load_coursess_tags'; 1387 data.cat_filter = cat_filter; 1388 data.settings = data_args; 1389 button.removeClass('active'); 1390 $(this).addClass('active'); 1391 1392 content.addClass('loading'); 1393 jwsThemeModule.jws_loader(content); 1394 1395 $.ajax({ 1396 url: jws_script.ajax_url, 1397 data:data, 1398 type: 'POST', 1399 dataType: 'json', 1400 success: function(response) { 1401 1402 console.log(response); 1403 content.html(response.data.content); 1404 1405 }, 1406 error: function($err) { 1407 console.log($err); 1408 }, 1409 complete: function() {content.removeClass('loading');}, 1410 }); 1411 1412 }); 1413 1414} 1415 1416 1417onDestroy() { 1418 this.handleDestroy(), super.onDestroy() 1419} 1420handleDestroy() { 1421 1422} 1423 1424} 1425 1426elementorFrontend.elementsHandler.attachHandler("jws_courses_tags", Jws_topics); 1427 1428 1429/* Button */ 1430 1431class g extends elementorModules.frontend.handlers.Base { 1432 onInit(...e) { 1433 super.onInit(...e), this.handleDestroy(), this.initLightbox(), this.initSplitText() 1434 } 1435 getDefaultSettings() { 1436 return { 1437 selectors: { 1438 localScrollElement: "[data-localscroll]", 1439 splitTextElement: "[data-split-text]" 1440 } 1441 } 1442 } 1443 getDefaultElements() {
1444 const e = this.getSettings("selectors"); 1445 return { 1446 $localScrollElement: this.$element.find(e.localScrollElement), 1447 $splitTextElement: this.$element.find(e.splitTextElement), 1448 $lightBoxElement: this.$element.find('.fresco') 1449 } 1450 } 1451 initLightbox() { 1452 1453 1454 this.elements.$lightBoxElement.magnificPopup({ 1455 disableOn: 700, 1456 type: 'iframe', 1457 mainClass: 'mfp-fade', 1458 removalDelay: 160, 1459 preloader: false, 1460 1461 fixedContentPos: false 1462 }); 1463 1464 1465 } 1466 initSplitText() { 1467 this.elements.$splitTextElement.liquidSplitText() 1468 } 1469 onDestroy() { 1470 this.handleDestroy(), super.onDestroy() 1471 } 1472 handleDestroy() { 1473 this.handleSplitTextDestroy() 1474 } 1475 handleSplitTextDestroy() { 1476 if (!this.elements.$splitTextElement.length) return; 1477 const e = this.elements.$splitTextElement.data("plugin_liquidSplitText"); 1478 e && e.destroy() 1479 } 1480} 1481 1482elementorFrontend.elementsHandler.attachHandler("jws_button_advanced", g); 1483 1484 elementorFrontend.hooks.addAction( 'frontend/element_ready/section', function( $element ) { 1485 initSection($element); 1486 }); 1487 1488 elementorFrontend.hooks.addAction('refresh_page_css', function (css) { 1489 var $obj = $('style#jws_elementor_custom_css'); 1490 if (!$obj.length) { 1491 $obj = $('<style id="jws_elementor_custom_css"></style>').appendTo('head'); 1492 } 1493 css = css.replace('/<script.*?\/script>/s', ''); 1494 $obj.html(css).appendTo('head'); 1495 }); 1496 1497 var widgets = { 1498 'jws_video_popup.default': video_popup, 1499 'jws_map.default': WidgetjwsGoogleMapHandler, 1500 'jws_menu_nav.default': jws_menu_style, 1501 'jws_gallery.default': jws_gallery, 1502 'jws_demo.default': [demo_filter], 1503 'jws-product-advanced.default': [product_tabs_filter], 1504 'tooltip.default': tooltip, 1505 'jws_instagram.default': instagram, 1506 'jws_slider.default': slider_elementor, 1507 'jws-category-list.default': category_list, 1508 'jws_widget_countdown.default': countdown, 1509 'jws_dropdown_text.default': jws_dropdown_text, 1510 'jws_image_carousel.default': images_carousel, 1511 'jws_banner.default': banner_carousel, 1512 'jws_info_box.default': info_box_carousel, 1513 'jws_timeline.default': time_line_carousel, 1514 1515 }; 1516 1517 $.each(widgets, function(widget, callback) { 1518 if('object' === typeof callback) { 1519 $.each(callback, function(index, cb) { 1520 elementorFrontend.hooks.addAction('frontend/element_ready/' + widget, cb); 1521 }); 1522 } else { 1523 elementorFrontend.hooks.addAction('frontend/element_ready/' + widget, callback); 1524 } 1525 }); 1526 }); 1527 1528 1529 1530})(jQuery); 1531 1532 1533 1534! function(e) { 1535 e(window).on("elementor/frontend/init", (function() { 1536 if (elementorFrontend && elementorModules.frontend) { 1537 class e extends elementorModules.frontend.handlers.SwiperBase { 1538 getDefaultSettings() { 1539 return { 1540 selectors: { 1541 slider: ".elementor-slides-wrapper", 1542 slide: ".swiper-slide", 1543 slideInnerContents: ".swiper-slide-contents", 1544 activeSlide: ".swiper-slide-active", 1545 activeDuplicate: ".swiper-slide-duplicate-active", 1546 slideDuplicate: ".swiper-slide-duplicate", 1547 customAnimationElement: "[data-custom-animations]", 1548 }, 1549 classes: { 1550 animated: "animated", 1551 kenBurnsActive: "elementor-ken-burns--active", 1552 slideBackground: "swiper-slide-bg" 1553 }, 1554 attributes: { 1555 dataSliderOptions: "slider_options", 1556 dataAnimation: "animation" 1557 } 1558 } 1559 } 1560 getDefaultElements() {
1561 const e = this.getSettings("selectors"), 1562 t = { 1563 $swiperContainer: this.$element.find(e.slider), 1564 $customAnimationElement: this.$element.find(e.customAnimationElement), 1565 }; 1566 return t.$slides = t.$swiperContainer.find(e.slide), t 1567 } 1568 getSwiperOptions() { 1569 const e = this.getElementSettings(), 1570 t = +e.slides_to_show || 1, 1571 s = 1 === t, 1572 i = elementorFrontend.config.responsive.activeBreakpoints, 1573 n = { 1574 mobile: 1, 1575 tablet: s ? 1 : 2 1576 }, 1577 a = { 1578 autoplay: this.getAutoplayConfig(), 1579 grabCursor: !0, 1580 initialSlide: this.getInitialSlide(), 1581 slidesPerView: t, 1582 slidesPerGroup: 1, 1583 loop: "yes" === e.infinite, 1584 autoHeight:"yes" === e.autoheight, 1585 centeredSlides: "yes" === e.center_mode, 1586 speed: e.transition_speed, 1587 effect: e.transition, 1588 observeParents: !0, 1589 observer: !0, 1590 handleElementorBreakpoints: !0, 1591 on: { 1592 slideChange: () => { 1593 this.handleKenBurns() 1594 } 1595 }, 1596 breakpoints: {} 1597 }; 1598 let o = t; 1599 Object.keys(i).reverse().forEach((t => { 1600 const s = n[t] ? n[t] : o; 1601 a.breakpoints[i[t].value] = { 1602 slidesPerView: +e["slides_to_show_" + t] || s, 1603 slidesPerGroup: +e["slides_to_scroll_" + t] || 1 1604 }, e.slide_spacing && (a.breakpoints[i[t].value].spaceBetween = this.getSpaceBetween(t)), o = +e["slides_to_show_" + t] || s 1605 })), e.slide_spacing && (a.spaceBetween = this.getSpaceBetween()); 1606 const r = "arrows" === e.navigation || "both" === e.navigation, 1607 l = "dots" === e.navigation || "both" === e.navigation; 1608 return r && (a.navigation = { 1609 prevEl: ".elementor-swiper-button-prev", 1610 nextEl: ".elementor-swiper-button-next" 1611 }), e.disable_drag && (a.allowTouchMove = !1), l && e.pagination && (a.pagination = { 1612 el: ".swiper-pagination", 1613 type: e.pagination, 1614 clickable: !0 1615 }, "dynamic" == e.pagination && (a.pagination.dynamicBullets = !0, delete a.pagination.type)), !0 === a.loop && (a.loopedSlides = this.getSlidesCount()), s ? "fade" === a.effect && (a.fadeEffect = { 1616 crossFade: !0 1617 }) : a.slidesPerGroup = +e.slides_to_scroll || 1, "coverflow" == a.effect ? a.coverflowEffect = { 1618 rotate: 50, 1619 stretch: 0, 1620 depth: 100, 1621 modifier: 1, 1622 slideShadows: !0 1623 } : "creative" == a.effect ? a.creativeEffect = { 1624 prev: { 1625 shadow: !0, 1626 translate: [0, 0, -400] 1627 }, 1628 next: { 1629 translate: ["100%", 0, 0] 1630 } 1631 } : "creative2" == a.effect ? (a.effect = "creative", a.creativeEffect = { 1632 perspective: !0, 1633 limitProgress: 2, 1634 shadowPerProgress: !0, 1635 prev: { 1636 shadow: !0, 1637 translate: ["-10%", 0, -200], 1638 rotate: [0, 0, -2] 1639 }, 1640 next: { 1641 shadow: !1, 1642 translate: ["120%", 0, 0] 1643 } 1644 }) : "creative3" == a.effect ? (a.effect = "creative", a.creativeEffect = { 1645 prev: { 1646 shadow: !0, 1647 translate: ["-125%", 0, -800], 1648 rotate: [0, 0, -90] 1649 }, 1650 next: { 1651 shadow: !0, 1652 translate: ["125%", 0, -800], 1653 rotate: [0, 0, 90] 1654 } 1655 }) : "creative4" == a.effect ? (a.effect = "creative", a.creativeEffect = { 1656 prev: { 1657 shadow: !0, 1658 origin: "left center", 1659 translate: ["-5%", 0, -200], 1660 rotate: [0, 100, 0] 1661 }, 1662 next: { 1663 origin: "right center", 1664 translate: ["5%", 0, -200], 1665 rotate: [0, -100, 0] 1666 } 1667 }) : "cube" == a.effect ? a.cubeEffect = { 1668 shadow: !0, 1669 slideShadows: !0, 1670 shadowOffset: 20, 1671 shadowScale: .94 1672 } : "coverflow2" == a.effect && (a.effect = "coverflow", a.coverflowEffect = { 1673 rotate: 0, 1674 stretch: 0, 1675 depth: 100, 1676 modifier: 3, 1677 slideShadows: !0 1678 }), a 1679 } 1680 getAutoplayConfig() { 1681 const e = this.getElementSettings(); 1682 return "yes" === e.autoplay && { 1683 stopOnLastSlide: !0, 1684 delay: e.autoplay_speed, 1685 disableOnInteraction: "yes" === e.pause_on_interaction 1686 } 1687 } 1688 initSingleSlideAnimations() {
1689 const e = this.getSettings(), 1690 t = this.elements.$swiperContainer.data(e.attributes.dataAnimation); 1691 1692 this.elements.$swiperContainer.find("." + e.classes.slideBackground).addClass(e.classes.kenBurnsActive), t && this.elements.$swiperContainer.find(e.selectors.slideInnerContents).addClass(e.classes.animated + " " + t) 1693 } 1694 async initSlider() { 1695 1696 const e = this.elements.$swiperContainer; 1697 const e2 = this.elements.$customAnimationElement; 1698 const e3 = 'dsadsa'; 1699 1700 if (!e.length) return; 1701 if (1 >= this.getSlidesCount()) return; 1702 const t = elementorFrontend.utils.swiper; 1703 var s = this.getSwiperOptions(); 1704 1705 this.swiper = await new t(e, s), e.data("swiper", this.swiper), this.handleKenBurns(); 1706 const i = this.getElementSettings(); 1707 "creative2" == i.transition && this.elements.$swiperContainer.css("overflow", "visible"), i.pause_on_hover && this.togglePauseOnHover(!0); 1708 const n = this.getSettings(), 1709 a = e.data(n.attributes.dataAnimation); 1710 this.swiper.on("slideChangeTransitionStart", (function() { 1711 e.find(n.selectors.slideInnerContents).removeClass(n.classes.animated + " " + a).hide() 1712 1713 1714 if (!e2.length) return; 1715 Object.values(e2).forEach(val => { 1716 1717 const e2a = jQuery(val).data("plugin_liquidCustomAnimations"); 1718 e2a && e2a.destroy() 1719 }); 1720 1721 1722 1723 })), this.swiper.on("slideChangeTransitionEnd", (function() { 1724 1725 e.find(n.selectors.slideInnerContents).show().addClass(n.classes.animated + " " + a) 1726 const anims = e.find(n.selectors.activeSlide).find('[data-custom-animations]').filter((i, element) => { 1727 1728 const $element = jQuery(element); 1729 1730 return $element; 1731 1732 }).get().reverse(); 1733 if (anims.length > 1) { 1734 jQuery(anims).liquidCustomAnimations(); 1735 } 1736 1737 1738 })) 1739 } 1740 handleCustomAnimationDestroy() { 1741 if (!this.elements.$customAnimationElement.length) return; 1742 const e = this.elements.$customAnimationElement.data("plugin_liquidCustomAnimations"); 1743 e && e.destroy() 1744 } 1745 onInit() { 1746 elementorFrontend.isEditMode() && this.findElement(".e-con").each((function() { 1747 jQuery(this).wrap('<div class="swiper-slide"></div>') 1748 })), elementorModules.frontend.handlers.Base.prototype.onInit.apply(this, arguments), 2 > this.getSlidesCount() ? this.initSingleSlideAnimations() : this.initSlider() 1749 } 1750 getChangeableProperties() { 1751 return { 1752 pause_on_hover: "pauseOnHover", 1753 pause_on_interaction: "disableOnInteraction", 1754 autoplay_speed: "delay", 1755 transition_speed: "speed" 1756 } 1757 } 1758 updateSwiperOption(e) { 1759 if (0 === e.indexOf("width")) return void this.swiper.update(); 1760 const t = this.getElementSettings(), 1761 s = t[e]; 1762 let i = this.getChangeableProperties()[e], 1763 n = s; 1764 switch (e) { 1765 case "autoplay_speed": 1766 i = "autoplay", n = { 1767 stopOnLastSlide: !0, 1768 delay: s, 1769 disableOnInteraction: "yes" === t.pause_on_interaction 1770 }; 1771 break; 1772 case "pause_on_hover": 1773 this.togglePauseOnHover("yes" === s); 1774 break; 1775 case "pause_on_interaction": 1776 n = "yes" === s 1777 } 1778 "pause_on_hover" !== e && (this.swiper.params[i] = n), this.swiper.update(
1778) 1779 } 1780 onElementChange(e) { 1781 if (0 === e.indexOf("slide_spacing")) return void this.updateSpaceBetween(e); 1782 if (1 >= this.getSlidesCount()) return; 1783 const t = this.getChangeableProperties(); 1784 Object.prototype.hasOwnProperty.call(t, e) && (this.updateSwiperOption(e), this.swiper.autoplay.start()) 1785 } 1786 getSpaceBetween() { 1787 let e = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : null; 1788 return elementorFrontend.utils.controls.getResponsiveControlValue(this.getElementSettings(), "slide_spacing", "size", e) || 0 1789 } 1790 updateSpaceBetween(e) { 1791 const t = e.match("slide_spacing_(.*)"), 1792 s = t ? t[1] : "desktop", 1793 i = this.getSpaceBetween(s); 1794 "desktop" !== s && (this.swiper.params.breakpoints[elementorFrontend.config.responsive.activeBreakpoints[s].value].spaceBetween = i), this.swiper.params.spaceBetween = i, this.swiper.update() 1795 } 1796 onEditSettingsChange(e) { 1797 console.log(this.getEditSettings("activeItemIndex")); 1798 1 >= this.getSlidesCount() || "activeItemIndex" === e && (this.swiper.slideToLoop(this.getEditSettings("activeItemIndex") - 1), this.swiper.autoplay.stop()) 1799 } 1800 1801 } 1802 elementorFrontend.elementsHandler.attachHandler("jws-nested-slider", e) 1803 } 1804 })) 1805}(window.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.