1 2; /* Start:"a:4:{s:4:"full";s:56:"/local/modules/bitrix66.reg/js/script.js?179134981524436";s:6:"source";s:40:"/local/modules/bitrix66.reg/js/script.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/ 3//window.BXDEBUG = true; 4 5BX.ready(BX('number')); 6 7BX.registerAjax = { 8 9 init: function(version = '') { 10 if(!BX.message('USER_ID')) { 11 $('body').removeClass('menu-mobile-fix menu-mobile menu-desktop').addClass('banner noscroll'); 12 $('.modal-mask, .menu-toggler').removeClass('active'); 13 14 this.result = {}; 15 this.version = version; 16 17 if (version) { 18 BX.setCookie('BITRIX_SM_BANNER', 'N', {path: '/'}); 19 } 20 21 this.textBlockHTML = 'ÐобÑо пожаловаÑÑ'; 22 switch (version) { 23 case 'order': 24 this.textBlockHTML = 'Скидка -10% <span>на пеÑвÑй заказ</span>'; 25 break; 26 case 'app': 27 this.textBlockHTML = 'Скидка -10% <span>на пеÑвÑй заказ</span> <span>ÑеÑез пÑиложение</span>'; 28 break; 29 } 30 31 clearTimeout(this.timerId); 32 BX.remove(BX("register3" + version)); 33 BX.remove(BX("popup-window-overlay-register3" + version)); 34 this.popupRegistrationForm(); 35 36 //var md = new MobileDetect(window.navigator.userAgent); && !md.is('iPhone') 37 if (this.codeNumber) 38 this.codeNumber.focus(); 39 if (this.phoneNumber && !this.version) 40 this.phoneNumber.focus(); 41 } 42 }, 43 popupRegistrationForm: function () { 44 this.alertDanger; 45 this.alertSuccess; 46 this.reloadClose = false; 47 this.phoneNumber; 48 //BX.SidePanel.Instance.closeAll([immediately = false]); 49 let oPopup = this.version ? 'register3sale'+this.version : 'register3'; 50 this.oPopup = new BX.PopupWindow(oPopup, null, { 51 //titleBar: {content: BX.create("h2", {html: 'ÐолÑÑиÑе ÑÐºÐ¸Ð´ÐºÑ <br>по пÑогÑамме лоÑлÑноÑÑи <br>Online Fashion Club', 'props': {'className': 'access-title-bar'}})}, 52 autoHide: true, 53 offsetTop: 1, 54 offsetLeft: 0, 55 lightShadow: true, 56 closeIcon: { 57 opacity: 1 58 }, 59 closeByEsc: true, 60 overlay: { 61 backgroundColor: 'black', opacity: '65' 62 }, 63 events: { 64 onPopupShow: function() { 65 66 }, 67 onPopupClose : function(){ 68 this.destroy(); 69 $('body').removeClass('banner noscroll'); 70 //location.reload(); 71 } 72 } 73 }); 74 75 this.registerBlock = BX.create('DIV', {props: {className: 'registerAjax'},}); 76 this.editRegistrationForm(this.registerBlock); 77 this.oPopup.show(); 78 }, 79 80 editAuthorizationForm: function (name) { 81 82 /*this.imageBlock = BX.create('DIV', { 83 props: {className: 'imageBanner'}, 84 });*/ 85 86 this.textBlock = BX.create('DIV', { 87 props: {className: 'textBanner'}, 88 html: this.textBlockHTML, 89 }); 90 91 this.alertSuccess = BX.create('DIV', { 92 props: {className: 'textAuth'}, 93 html: name ? name+', Ð¼Ñ ÑÐ°Ð´Ñ Ð²Ð¸Ð´ÐµÑÑ Ð²Ð°Ñ Ñнова!' : 'Ðелаем пÑиÑÑнÑÑ Ð¿Ð¾ÐºÑпок!' 94 }); 95 this.titleBlock = BX.create('DIV', { 96 props: {className: 'titleBanner'}, 97 children: [ 98 this.textBlock, 99 this.version ? '' : this.alertSuccess, 100 ] 101 }); 102 103 if(this.version) { 104 this.authFormNodes = BX.create('div', { 105 props: {className: 'text-send-promocod'}, 106 html: 'СÑоимоÑÑÑ ÑоваÑов на ÑайÑе ÑейÑÐ°Ñ Ñ ÑÑеÑом ÐаÑей пеÑÑоналÑной Ñкидки.' 107 }); 108 109 this.bannerBlock = BX.create('DIV', { 110 props: {className: 'wrapBanner'}, 111 children: [ 112 BX.create('DIV', { 113 props: {className: 'popupBanner'}, 114 children: [ 115 BX.create('DIV', { 116 props: {className: 'authBanner'}, 117 children: [ 118 this.titleBlock, 119 this.authFormNodes, 120 this.alertSuccess, 121 ] 122 }), 123 ], 124 }), 125 BX.create('DIV', {props: {className: 'imageBanner'}}) 126 ] 127 }); 128 }else{ 129 this.bannerBlock = BX.create('DIV', { 130 props: {className: 'popupBanner'}, 131 children: [ 132 BX.create('DIV', { 133 props: {className: 'authBanner'}, 134 children: [ 135 this.titleBlock, 136 ] 137 }), 138 ], 139 }); 140 } 141 142 this.reloadClose = true; 143 this.oPopup.setContent(this.bannerBlock); 144 }, 145 146 editRegistrationForm: function (authContent) { 147 let smsInterval = 60; 148 if(this.result.SMS_AUTH) { 149 localStorage.setItem('SMS_AUTH_DATA', JSON.stringify(this.result.SMS_AUTH)); 150 localStorage.setItem('PHONE_NUMBER', this.phoneNumber.value); 151 localStorage.setItem('SMS_AUTH_TIMER', smsInterval); 152 localStorage.setItem('SMS_AUTH_START', Date.now()); 153 }else if (localStorage.getItem('SMS_AUTH_DATA')){ 154 this.result.SMS_AUTH = JSON.parse(localStorage.getItem('SMS_AUTH_DATA')); 155 var interval = smsInterval - Math.round(Number(Date.now() - localStorage.getItem('SMS_AUTH_START')) / 1000); 156 if(interval > 0) { 157 localStorage.setItem('SMS_AUTH_TIMER', interval); 158 }else { 159 localStorage.setItem('SMS_AUTH_TIMER', 0); 160 } 161 } 162 163 var showSmsConfirm = this.result.SMS_AUTH && this.result.SMS_AUTH.TYPE === 'OK'; 164 165 this.alertDanger = BX.create('DIV', { 166 props: {id: 'bx_register_error', className: 'alert alert-danger'}, 167 style: {display: 'none'} 168 }); 169 170 /*this.imageBlock = BX.create('DIV', { 171 props: {className: 'imageBanner'}, 172 });*/ 173 174 if (showSmsConfirm) { 175 this.textBlock = BX.create('DIV', { 176 props: {className: 'textBanner'}, 177 html: this.version ? this.textBlockHTML : 'ÐвÑоÑизаÑиÑ', 178 }); 179 this.alertSuccess = BX.create('DIV', { 180 props: {className: 'textAuth'} 181 }); 182 this.titleBlock = BX.create('DIV', { 183 props: {className: 'titleBanner'}, 184 children: [ 185 this.textBlock, 186 this.version ? '' : this.alertDanger, 187 this.version ? '' : this.alertSuccess, 188 ] 189 }); 190 this.codeNumber = BX.create('INPUT', { 191 attrs: {'inputmode': 'tel', 'data-send': true}, 192 props: { 193 name: 'SMS_CODE', 194 className: "form-control", 195 type: 'text', 196 size: 40, 197 }, 198 events: { 199 bxchange: BX.delegate(function (e) { 200 this.hideError(); 201 this.confirmSmsCode(); 202 }, this), 203 } 204 }); 205 206 new BX.MaskedInput({ 207 mask: '999999',
208 input: this.codeNumber, 209 placeholder: ' ' 210 }); 211 212 this.codeWrap = BX.create('DIV', { 213 props: { 214 className: "input-background phoneCode" 215 }, 216 children: [ 217 this.codeNumber 218 ], 219 events: { 220 click: BX.delegate(function () { 221 this.codeNumber.focus(); 222 }, this) 223 } 224 225 }); 226 //ÐодÑвеÑдиÑÑ ÑелеÑон 227 this.codeButton = BX.create('INPUT', { 228 props: { 229 type: 'button', 230 className: "form-button", 231 value: 'ÐойÑи', 232 }, 233 events: { 234 click: BX.delegate(function () { 235 this.confirmSmsCode(); 236 }, this) 237 } 238 }); 239 240 this.authFormNodes = BX.create('DIV', { 241 props: {className: 'bx-authform-formgroup-container'}, 242 children: [ 243 this.codeWrap, 244 this.codeButton, 245 ] 246 }); 247 248 if(this.version) { 249 this.bannerBlock = BX.create('DIV', { 250 props: {className: 'wrapBanner'}, 251 children: [ 252 BX.create('DIV', { 253 props: {className: 'popupBanner'}, 254 children: [ 255 BX.create('DIV', { 256 props: {className: 'authBanner'}, 257 children: [ 258 this.titleBlock, 259 this.registerBlock, 260 this.alertSuccess, 261 ] 262 }), 263 ], 264 }), 265 BX.create('DIV', {props: {className: 'imageBanner'}}) 266 ] 267 }); 268 }else { 269 this.bannerBlock = BX.create('DIV', { 270 props: {className: 'popupBanner'}, 271 children: [ 272 BX.create('DIV', { 273 props: {className: 'authBanner'}, 274 children: [ 275 this.titleBlock, 276 this.registerBlock, 277 ] 278 }) 279 ] 280 }); 281 } 282 283 this.activatePhoneAuth(); 284 } else { 285 this.textBlock = BX.create('DIV', { 286 props: { 287 className: 'textBanner' 288 }, 289 html: this.version ? this.textBlockHTML : 'ÐÑ Ð¾Ð´ / РегиÑÑÑаÑиÑ', 290 }); 291 this.textBlock2 = BX.create('DIV', { 292 html: 'Ðе ÑаÑпÑоÑÑÑанÑеÑÑÑ Ð½Ð° ÑоваÑÑ Ñо Ñкидкой', 293 }); 294 this.checkAd = BX.create('INPUT', { 295 props: { 296 name: 'REG_AD', 297 type: 'checkbox', 298 } 299 }); 300 let checkAdText = BX.create('SPAN', { 301 html: 'СоглаÑен полÑÑаÑÑ <a href="/about/o-reklame/" target="_blank">инÑоÑмаÑÐ¸Ñ Ð¾ ÑÐºÐ¸Ð´ÐºÐ°Ñ Ð¸ ÑпеÑпÑедложениÑÑ </a>' 302 }); 303 /*this.phoneButton = BX.create('INPUT', { 304 props: { 305 type: 'button', 306 className: "form-button", 307 value: this.version ? 'полÑÑиÑÑ ÑкидкÑ' : 'полÑÑиÑÑ ÐºÐ¾Ð´', 308 }, 309 events: { 310 click: BX.delegate(function () { 311 this.doRegister(); 312 }, this) 313 } 314 });*/ 315 this.alertSuccess = BX.create('DIV', { 316 props: {className: 'textAuth'}, 317 children: [ 318 //BX.create('DIV', {html: 'ÐÐ°Ð¶Ð¸Ð¼Ð°Ñ Ð½Ð° кнопкÑ,'}), 319 BX.create('DIV', {html: 'РегиÑÑÑиÑÑÑÑÑ, Ð²Ñ ÑоглаÑаеÑеÑÑ Ñ <a href="/about/privacy-policy/" target="_blank">ÐолиÑикой конÑиденÑиалÑноÑÑи</a>'}), 320 BX.create('DIV', { 321 props: { 322 className: 'reg_ad', 323 }, 324 children: [ 325 this.checkAd, 326 checkAdText 327 ] 328 }), 329 ] 330 }); 331 this.captcha = BX.create('DIV', { 332 attrs: {'data-sitekey': 'ysc1_gH5Gbbso1AQ9Xh1ofqKWDBZhZTooGWvqA3BbloVN9f5dd56a'}, 333 props: { 334 id: 'captcha-container', 335 className: 'smart-captcha' 336 } 337 }); 338 this.titleBlock = BX.create('DIV', { 339 props: {className: 'titleBanner'}, 340 children: [ 341 this.textBlock, 342 this.textBlock2, 343 this.version ? '' : this.alertSuccess, 344 this.version ? '' : this.alertDanger, 345 ] 346 }); 347 this.phoneNumber = BX.create('INPUT', { 348 attrs: {'inputmode': 'tel', 'data-next': 'captcha_w
348ord', 'placeholder': '8 (900) 000-00-00'}, 349 props: { 350 name: 'PHONE_NUMBER', 351 type: 'text', 352 className: "form-control", 353 size: 40, 354 value: '', 355 }, 356 }); 357 this.yandexCaptcha(); 358 new BX.PhoneNumber.Input({ 359 node: this.phoneNumber, 360 forceLeadingPlus: false, 361 defaultCountry: 'ru', 362 onChange: function (e) { 363 } 364 }); 365 this.phoneWrap = BX.create('DIV', { 366 props: { 367 className: "input-background" 368 }, 369 children: [ 370 this.phoneNumber 371 ], 372 events: { 373 click: BX.delegate(function () { 374 this.phoneNumber.focus(); 375 }, this) 376 } 377 378 }); 379 380 this.authFormNodes = BX.create('div', { 381 props: {className: 'bx-authform-formgroup-container'}, 382 children: [ 383 this.phoneWrap, 384 //this.phoneButton, 385 ] 386 }); 387 388 if(this.version) { 389 this.bannerBlock = BX.create('DIV', { 390 props: {className: 'wrapBanner'}, 391 children: [ 392 BX.create('DIV', { 393 props: {className: 'popupBanner'}, 394 children: [ 395 BX.create('DIV', { 396 props: {className: 'authBanner'}, 397 children: [ 398 this.titleBlock, 399 this.registerBlock, 400 this.captcha, 401 this.alertSuccess, 402 ] 403 }), 404 ], 405 }), 406 BX.create('DIV', {props: {className: 'imageBanner'}}) 407 ] 408 }); 409 }else{ 410 this.bannerBlock = BX.create('DIV', { 411 props: {className: 'popupBanner'}, 412 children: [ 413 BX.create('DIV', { 414 props: {className: 'authBanner'}, 415 children: [ 416 this.titleBlock, 417 this.registerBlock, 418 this.captcha, 419 this.alertSuccess, 420 ] 421 }), 422 ] 423 }); 424 } 425 } 426 427 authContent.innerHTML = ''; 428 authContent.appendChild( 429 BX.create('DIV', {props: {className: 'bx-authform'}, children: [this.authFormNodes, this.version ? this.alertDanger : '']}) 430 ); 431 this.oPopup.setContent(this.bannerBlock); 432 }, 433 434 activatePhoneAuth: function() 435 { 436 this.containerId = 'bx_register_resend'; 437 this.errorContainerId = 'bx_register_error'; 438 439 var container = this.alertSuccess; 440 if(container) 441 { 442 let smsTimer = localStorage.getItem('SMS_AUTH_TIMER'); 443 if(smsTimer > 0) { 444 container.appendChild(BX.create('DIV', { 445 props: {className: this.containerId + '_phone'}, 446 html: 'Ðа Ð½Ð¾Ð¼ÐµÑ ' + localStorage.getItem('PHONE_NUMBER') + ' бÑл оÑпÑавлен код.' 447 })); 448 container.appendChild(BX.create('SPAN', { 449 html: 'ÐведиÑе код Ð´Ð»Ñ Ð°Ð²ÑоÑизаÑии в ÑеÑение ' 450 })); 451 this.containerCounter = container.appendChild(BX.create('SPAN', { 452 props: {id: this.containerId + '_counter'}, 453 text: smsTimer 454 })); 455 container.appendChild(BX.create('SPAN', {text: ' Ñек.'})); 456 this.startTimer(smsTimer); 457 }else{ 458 this.result.SMS_AUTH = ''; 459 this.registerBlock.innerHTML = ''; 460 localStorage.removeItem('SMS_AUTH_DATA'); 461 localStorage.removeItem('PHONE_NUMBER'); 462 localStorage.removeItem('SMS_AUTH_TIMER'); 463 localStorage.removeItem('SMS_AUTH_START'); 464 this.editRegistrationForm(this.registerBlock); 465 this.phoneNumber.focus(); 466 } 467 } 468 }, 469 470 startTimer: function(counter) 471 { 472 this.timerId = setInterval( 473 BX.delegate(function() 474 { 475 counter--; 476 localStorage.setItem('SMS_AUTH_TIMER', counter); 477 this.containerCounter.textContent = counter; 478 if(counter < 1) 479 { 480 this.activatePhoneAuth(); 481 clearInterval(this.timerId); 482 } 483 484 }, this), 485 1000 486 ); 487 }, 488 489 /*activatePhoneAuth: function () { 490 if (!this.result.SMS_AUTH) 491 return; 492 493 new BX.PhoneAuth({ 494 containerId: 'bx_register_resend', 495 errorContainerId: 'bx_register_error', 496 interval: 60, 497 data: { 498 signedData: this.result.SMS_AUTH.SIGNED_DATA 499 }, 500 onError: function (response) { 501 var errorDiv = BX('bx_register_error'); 502 var errorNode = BX.findChildByClassName(errorDiv, 'errortext'); 503 errorNode.innerHTML = ''; 504 505 for (var i = 0; i < response.errors.length; i++) { 506 errorNode.innerHTML = errorNode.innerHTML + BX.util.htmlspecialchars(response.errors[i].message) + '<br>'; 507 } 508 509 errorDiv.style.display = ''; 510 } 511 }); 512 },*/ 513 514 getData: function (action, actionData) { 515 var data = { 516 order: this.getAllFormData(), 517 sessid: BX.bitrix_sessid(), 518 via_ajax: 'Y', 519 SITE_ID: this.siteId, 520 signedParamsString: this.signedParamsString 521 }; 522 523 data[this.params.ACTION_VARIABLE] = action; 524 525 if (action === 'enterCoupon' || action === 'removeCoupon') 526 data.coupon = actionData; 527 528 return data; 529 }, 530 531 hideError: function () { 532 this.alertDanger.style.display = 'none'; 533 this.alertDanger.innerHTML = ''; 534 }, 535 536 showError: function (message) { 537 this.alertDanger.innerHTML = message; 538 this.alertDanger.style.display = ''; 539 }, 540 541 confirmSmsCode: function () { 542 // Ðа мобилÑнÑÑ Ð²Ð²Ð¾Ð´ поÑледней ÑиÑÑÑ (и авÑоподÑÑановка кода из SMS) даÑÑ 543 // неÑколÑко ÑобÑÑий bxchange подÑÑд â без Ñлага код ÑÑ Ð¾Ð´Ð¸Ð» дваждÑ, 544 // ÑеÑÐ²ÐµÑ Ð°Ð²ÑоÑизовал оба Ñаза, а в Mindbox пÑÐ¸Ñ Ð¾Ð´Ð¸Ð» дÑÐ±Ð»Ñ AuthorizeCustomer. 545 // ÐоÑле ÑÑпеÑного Ð²Ñ Ð¾Ð´Ð° Ñлаг не ÑбÑаÑÑваем: ÑÑÑаниÑа вÑÑ Ñавно пеÑезагÑÑзиÑÑÑ. 546 if (this.smsCodeSending) { 547 return; 548 } 549 if (this.codeNumber.value.replace(/[^\d]/g, '').length == 6) { 550 this.smsCodeSending = true; 551 BX.ajax.runAction('bitrix66:reg.events.get', { 552 data: {
553 code: this.codeNumber.value, 554 signed: this.result.SMS_AUTH.SIGNED_DATA, 555 phone: localStorage.getItem('PHONE_NUMBER'), 556 sessid: BX.bitrix_sessid(), 557 subscribeAd: (this.checkAd && this.checkAd.checked) ? 'Y' : 'N' //пеÑедаÑа подпиÑки mindbox, не ÑдалÑÑÑ! 558 } 559 }).then(BX.delegate(function (response) { 560 var result = response.data; 561 if (result.user.ID > 0) { 562 this.registerBlock.remove(); 563 clearInterval(this.timerId); 564 localStorage.removeItem('SMS_AUTH_DATA'); 565 localStorage.removeItem('PHONE_NUMBER'); 566 localStorage.removeItem('SMS_AUTH_TIMER'); 567 localStorage.removeItem('SMS_AUTH_START'); 568 this.editAuthorizationForm(result.user.NAME); 569 setTimeout(function () { 570 location.reload(); 571 }, 2000); 572 }else{ 573 this.smsCodeSending = false; 574 this.codeNumber.value = ''; 575 if (result.SMS_AUTH.MESSAGE) { 576 this.showError(result.SMS_AUTH.MESSAGE); 577 } 578 } 579 }, this), BX.delegate(function (response) { 580 this.smsCodeSending = false; 581 }, this)); 582 } 583 }, 584 585 yandexCaptcha: function () { 586 let scriptTag = document.createElement('script'); 587 scriptTag.setAttribute('src', 'https://smartcaptcha.yandexcloud.net/captcha.js?render=onload&onload=yaCaptcha'); 588 scriptTag.setAttribute('defer', 'defer'); 589 document.body.appendChild(scriptTag); 590 }, 591 592 doRegister: function () { 593 if (this.phoneNumber.value.replace(/[^\d]/g, '').length >= 11 && this.phoneNumber.value.replace(/[^\d]/g, '')[1] == 9) { 594 var data = { 595 phone: this.phoneNumber.value, 596 sessid: BX.bitrix_sessid(), 597 captcha: BX('captcha-container').querySelector('input[name="smart-token"]').value 598 }; 599 BX.ajax.runAction('bitrix66:reg.events.set', { 600 data: data 601 }).then(BX.delegate(function (response) { 602 var result = response.data; 603 if (result.SMS_AUTH.TYPE === "OK") { 604 this.result = result; 605 this.editRegistrationForm(this.registerBlock); 606 this.codeNumber.focus(); 607 } else { 608 this.phoneNumber.value = ''; 609 if (result.SMS_AUTH.MESSAGE) { 610 this.showError(result.SMS_AUTH.MESSAGE); 611 } 612 } 613 }, this), function (response) { 614 //BX.adjust(this.phoneButton, { props: { disabled: false } }); 615 }); 616 }else{ 617 this.yandexCaptcha(); 618 this.showError('Ðведен невеÑнÑй Ð½Ð¾Ð¼ÐµÑ ÑелеÑона.'); 619 } 620 }, 621} 622 623function yaCaptcha() { 624 if (window.smartCaptcha) { 625 let test = window.smartCaptcha.render(BX('captcha-container'), { 626 'id': 'onlineFashion', 627 sitekey: 'ysc1_gH5Gbbso1AQ9Xh1ofqKWDBZhZTooGWvqA3BbloVN9f5dd56a', 628 hl: 'ru', 629 callback: function () { 630 BX.registerAjax.doRegister(); 631 } 632 }); 633 }else{ 634 BX.registerAjax.showError('ÐÑклÑÑиÑе VPN'); 635 } 636} 637/* End */ 638; 639; /* Start:"a:4:{s:4:"full";s:64:"/local/templates/bitrix66/plug/swiper/swiper.js?1789634012148932";s:6:"source";s:47:"/local/templates/bitrix66/plug/swiper/swiper.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/ 640/** 641 * Swiper 11.0.6 642 * Most modern mobile touch slider and framework with hardware accelerated transitions 643 * https://swiperjs.com 644 * 645 * Copyright 2014-2024 Vladimir Kharlampidi 646 * 647 * Released under the MIT License 648 * 649 * Released on: February 5, 2024 650 */
vendor: 148,630 bytes, lines 651-652
651 652var Swiper=function(){"use strict";function e(e){return null!==e&&"object"==typeof e&&"constructor"in e&&e.constructor===Object}function t(s,a){void 0===s&&(s={}),void 0===a&&(a={}),Object.keys(a).forEach((i=>{void 0===s[i]?s[i]=a[i]:e(a[i])&&e(s[i])&&Object.keys(a[i]).length>0&&t(s[i],a[i])}))}const s={body:{},addEventListener(){},removeEventListener(){},activeElement:{blur(){},nodeName:""},querySelector:()=>null,querySelectorAll:()=>[],getElementById:()=>null,createEvent:()=>({initEvent(){}}),createElement:()=>({children:[],childNodes:[],style:{},setAttribute(){},getElementsByTagName:()=>[]}),createElementNS:()=>({}),importNode:()=>null,location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""}};function a(){const e="undefined"!=typeof document?document:{};return t(e,s),e}const i={document:s,navigator:{userAgent:""},location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""},history:{replaceState(){},pushState(){},go(){},back(){}},CustomEvent:function(){return this},addEventListener(){},removeEventListener(){},getComputedStyle:()=>({getPropertyValue:()=>""}),Image(){},Date(){},screen:{},setTimeout(){},clearTimeout(){},matchMedia:()=>({}),requestAnimationFrame:e=>"undefined"==typeof setTimeout?(e(),null):setTimeout(e,0),cancelAnimationFrame(e){"undefined"!=typeof setTimeout&&clearTimeout(e)}};function r(){const e="undefined"!=typeof window?window:{};return t(e,i),e}function n(e){return void 0===e&&(e=""),e.trim().split(" ").filter((e=>!!e.trim()))}function l(e,t){return void 0===t&&(t=0),setTimeout(e,t)}function o(){return Date.now()}function d(e,t){void 0===t&&(t="x");const s=r();let a,i,n;const l=function(e){const t=r();let s;return t.getComputedStyle&&(s=t.getComputedStyle(e,null)),!s&&e.currentStyle&&(s=e.currentStyle),s||(s=e.style),s}(e);return s.WebKitCSSMatrix?(i=l.transform||l.webkitTransform,i.split(",").length>6&&(i=i.split(", ").map((e=>e.replace(",","."))).join(", ")),n=new s.WebKitCSSMatrix("none"===i?"":i)):(n=l.MozTransform||l.OTransform||l.MsTransform||l.msTransform||l.transform||l.getPropertyValue("transform").replace("translate(","matrix(1, 0, 0, 1,"),a=n.toString().split(",")),"x"===t&&(i=s.WebKitCSSMatrix?n.m41:16===a.length?parseFloat(a[12]):parseFloat(a[4])),"y"===t&&(i=s.WebKitCSSMatrix?n.m42:16===a.length?parseFloat(a[13]):parseFloat(a[5])),i||0}function c(e){return"object"==typeof e&&null!==e&&e.constructor&&"Object"===Object.prototype.toString.call(e).slice(8,-1)}function p(){const e=Object(arguments.length<=0?void 0:arguments[0]),t=["__proto__","constructor","prototype"];for(let a=1;a<arguments.length;a+=1){const i=a<0||arguments.length<=a?void 0:arguments[a];if(null!=i&&(s=i,!("undefined"!=typeof window&&void 0!==window.HTMLElement?s instanceof HTMLElement:s&&(1===s.nodeType||11===s.nodeType)))){const s=Object.keys(Object(i)).filter((e=>t.indexOf(e)<0));for(let t=0,a=s.length;t<a;t+=1){const a=s[t],r=Object.getOwnPropertyDescriptor(i,a);void 0!==r&&r.enumerable&&(c(e[a])&&c(i[a])?i[a].__swiper__?e[a]=i[a]:p(e[a],i[a]):!c(e[a])&&c(i[a])?(e[a]={},i[a].__swiper__?e[a]=i[a]:p(e[a],i[a])):e[a]=i[a])}}}var s;return e}function u(e,t,s){e.style.setProperty(t,s)}function m(e){let{swiper:t,targetPosition:s,side:a}=e;const i=r(),n=-t.translate;let l,o=null;const d=t.params.speed;t.wrapperEl.style.scrollSnapType="none",i.cancelAnimationFrame(t.cssModeFrameID);const c=s>n?"next":"prev",p=(e,t)=>"next"===c&&e>=t||"prev"===c&&e<=t,u=()=>{l=(new Date).getTime(),null===o&&(o=l);const e=Math.max(Math.min((l-o)/d,1),0),r=.5-Math.cos(e*Math.PI)/2;let c=n+r*(s-n);if(p(c,s)&&(c=s),t.wrapperEl.scrollTo({[a]:c}),p(c,s))return t.wrapperEl.style.overflow="hidden",t.wrapperEl.style.scrollSnapType="",setTimeout((()=>{t.wrapperEl.style.overflow="",t.wrapperEl.scrollTo({[a]:c})})),void i.cancelAnimationFrame(t.cssModeFrameID);t.cssModeFrameID=i.requestAnimationFrame(u)};u()}function h(e){return e.querySelector(".swiper-slide-transform")||e.shadowRoot&&e.shadowRoot.querySelector(".swiper-slide-transform")||e}function f(e,t){return void 0===t&&(t=""),[...e.children].filter((e=>e.matches(t)))}function g(e){try{return void console.warn(e)}catch(e){}}function v(e,t){void 0===t&&(t=[]);const s=document.createElement(e);return s.classList.add(...Array.isArray(t)?t:n(t)),s}function w(e){const t=r(),s=a(),i=e.getBoundingClientRect(),n=s.body,l=e.clientTop||n.clientTop||0,o=e.clientLeft||n.clientLeft||0,d=e===t?t.scrollY:e.scrollTop,c=e===t?t.scrollX:e.scrollLeft;return{top:i.top+d-l,left:i.left+c-o}}function b(e,t){return r().getComputedStyle(e,null).getPropertyValue(t)}function y(e){let t,s=e;if(s){for(t=0;null!==(s=s.previousSibling);)1===s.nodeType&&(t+=1);return t}}function E(e,t){const s=[];let a=e.parentElement;for(;a;)t?a.matches(t)&&s.push(a):s.push(a),a=a.parentElement;return s}function x(e,t){t&&e.addEventListener("transitionend",(function s(a){a.target===e&&(t.call(e,a),e.removeEventListener("transitionend",s))}))}function S(e,t,s){const a=r();return s?e["width"===t?"offsetWidth":"offsetHeight"]+parseFloat(a.getComputedStyle(e,null).getPropertyValue("width"===t?"margin-right":"margin-top"))+parseFloat(a.getComputedStyle(e,null).getPropertyValue("width"===t?"margin-left":"margin-bottom")):e.offsetWidth}function T(e){return(Array.isArray(e)?e:[e]).filter((e=>!!e))}let M,C,P;function L(){return M||(M=function(){const e=r(),t=a();return{smoothScroll:t.documentElement&&t.documentElement.style&&"scrollBehavior"in t.documentElement.style,touch:!!("ontouchstart"in e||e.DocumentTouch&&t instanceof e.DocumentTouch)}}()),M}function I(e){return void 0===e&&(e={}),C||(C=function(e){let{userAgent:t}=void 0===e?{}:e;const s=L(),a=r(),i=a.navigator.platform,n=t||a.navigator.userAgent,l={ios:!1,android:!1},o=a.screen.width,d=a.screen.height,c=n.match(/(Android);?[\s\/]+([\d.]+)?/);let p=n.match(/(iPad).*OS\s([\d_]+)/);const u=n.match(/(iPod)(.*OS\s([\d_]+))?/),m=!p&&n.match(/(iPhone\sOS|iOS)\s([\d_]+)/),h="Win32"===i;let f="MacIntel"===i;return!p&&f&&s.touch&&["1024x1366","1366x1024","834x1194","1194x834","834x1112","1112x834","768x1024","1024x768","820x1180","1180x820","810x1080","1080x810"].indexOf(`${o}x${d}`)>=0&&(p=n.match(/(Version)\/([\d.]+)/),p||(p=[0,1,"13_0_0"]),f=!1),c&&!h&&(l.os="android",l.android=!0),(p||m||u)&&(l.os="ios",l.ios=!0),l}(e)),C}function A(){return P||(P=function(){const e=r(),t=I();let s=!1;function a(){const t=e.navigator.userAgent.toLowerCase();return t.indexOf("safari")>=0&&t.indexOf("chrome")<0&&t.indexOf("android")<0}if(a()){const t=String(e.navigator.userAgent);if(t.includes("Version/")){const[e,a]=t.split("Version/")[1].split(" ")[0].split(".").map((e=>Number(e)));s=e<16||16===e&&a<2}}const i=/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(e.navigator.userAgent),n=a();return{isSafari:s||n,needPerspectiveFix:s,need3dFix:n||i&&t.ios,isWebView:i}}()),P}var z={on(e,t,s){const a=this;if(!a.eventsListeners||a.destroyed)return a;if("function"!=typeof t)return a;const i=s?"unshift":"push";return e.split(" ").forEach((e=>{a.eventsListeners[e]||(a.eventsListeners[e]=[]),a.eventsListeners[e][i](t)})),a},once(e,t,s){const a=this;if(!a.eventsListeners||a.destroyed)return a;if("function"!=typeof t)return a;function i(){a.off(e,i),i.__emitterProxy&&delete i.__emitterProxy;for(var s=arguments.length,r=new Array(s),n=0;n<s;n++)r[n]=arguments[n];t.apply(a,r)}return i.__emitterProxy=t,a.on(e,i,s)},onAny(e,t){const s=this;if(!s.eventsListeners||s.destroyed)return s;if("function"!=typeof e)return s;const a=t?"unshift":"push";return s.eventsAnyListeners.indexOf(e)<0&&s.eventsAnyListeners[a](e),s},offAny(e){const t=this;if(!t.eventsListeners||t.destroyed)return t;if(!t.eventsAnyListeners)return t;const s=t.eventsAnyListeners.indexOf(e);return s>=0&&t.eventsAnyListeners.splice(s,1),t},off(e,t){const s=this;return!s.eventsListeners||s.destroyed?s:s.eventsListeners?(e.split(" ").forEach((e=>{void 0===t?s.eventsListeners[e]=[]:s.eventsListeners[e]&&s.eventsListeners[e].forEach(((a,i)=>{(a===t||a.__emitterProxy&&a.__emitterProxy===t)&&s.eventsListeners[e].splice(i,1)}))})),s):s},emit(){const e=this;if(!e.eventsListeners||e.destroyed)return e;if(!e.eventsListeners)return e;let t,s,a;for(var i=arguments.length,r=new Array(i),n=0;n<i;n++)r[n]=arguments[n];"string"==typeof r[0]||Array.isArray(r[0])?(t=r[0],s=r.slice(1,r.length),a=e):(t=r[0].events,s=r[0].data,a=r[0].context||e),s.unshift(a);return(Array.isArray(t)?t:t.split(" ")).forEach((t=>{e.eventsAnyListeners&&e.eventsAnyListeners.length&&e.eventsAnyListeners.forEach((e=>{e.apply(a,[t,...s])})),e.eventsListeners&&e.eventsListeners[t]&&e.eventsListeners[t].forEach((e=>{e.apply(a,s)}))})),e}};const $=(e,t)=>{if(!e||e.destroyed||!e.params)return;const s=t.closest(e.isElement?"swiper-slide":`.${e.params.slideClass}`);if(s){let t=s.querySelector(`.${e.params.lazyPreloaderClass}`);!t&&e.isElement&&(s.shadowRoot?t=s.shadowRoot.querySelector(`.${e.params.lazyPreloaderClass}`):requestAnimationFrame((()=>{s.shadowRoot&&(t=s.shadowRoot.querySelector(`.${e.params.lazyPreloaderClass}`),t&&t.remove())}))),t&&t.remove()}},k=(e,t)=>{if(!e.slides[t])return;const s=e.slides[t].querySelector('[loading="lazy"]');s&&s.removeAttribute("loading")},O=e=>{if(!e||e.destroyed||!e.params)return;let t=e.params.lazyPreloadPrevNext;const s=e.slides.length;if(!s||!t||t<0)return;t=Math.min(t,s);const a="auto"===e.params.slidesPerView?e.slidesPerViewDynamic():Math.ceil(e.params.slidesPerView),i=e.activeIndex;if(e.params.grid&&e.params.grid.rows>1){const s=i,r=[s-t];return r.push(...Array.from({length:t}).map(((e,t)=>s+a+t))),void e.slides.forEach(((t,s)=>{r.includes(t.column)&&k(e,s)}))}const r=i+a-1;if(e.params.rewind||e.params.loop)for(let a=i-t;a<=r+t;a+=1){const t=(a%s+s)%s;(t<i||t>r)&&k(e,t)}else for(let a=Math.max(i-t,0);a<=Math.min(r+t,s-1);a+=1)a!==i&&(a>r||a<i)&&k(e,a)};var D={updateSize:function(){const e=this;let t,s;const a=e.el;t=void 0!==e.params.width&&null!==e.params.width?e.params.width:a.clientWidth,s=void 0!==e.params.height&&null!==e.params.height?e.params.height:a.clientHeight,0===t&&e.isHorizontal()||0===s&&e.isVertical()||(t=t-parseInt(b(a,"padding-left")||0,10)-parseInt(b(a,"padding-right")||0,10),s=s-parseInt(b(a,"padding-top")||0,10)-parseInt(b(a,"padding-bottom")||0,10),Number.isNaN(t)&&(t=0),Number.isNaN(s)&&(s=0),Object.assign(e,{width:t,height:s,size:e.isHorizontal()?t:s}))},updateSlides:function(){const e=this;function t(t,s){return parseFloat(t.getPropertyValue(e.getDirectionLabel(s))||0)}const s=e.params,{wrapperEl:a,slidesEl:i,size:r,rtlTranslate:n,wrongRTL:l}=e,o=e.virtual&&s.virtual.enabled,d=o?e.virtual.slides.length:e.slides.length,c=f(i,`.${e.params.slideClass}, swiper-slide`),p=o?e.virtual.slides.length:c.length;let m=[];const h=[],g=[];let v=s.slidesOffsetBefore;"function"==typeof v&&(v=s.slidesOffsetBefore.call(e));let w=s.slidesOffsetAfter;"function"==typeof w&&(w=s.slidesOffsetAfter.call(e));const y=e.snapGrid.length,E=e.slidesGrid.length;let x=s.spaceBetween,T=-v,M=0,C=0;if(void 0===r)return;"string"==typeof x&&x.indexOf("%")>=0?x=parseFloat(x.replace("%",""))/100*r:"string"==typeof x&&(x=parseFloat(x)),e.virtualSize=-x,c.forEach((e=>{n?e.style.marginLeft="":e.style.marginRight="",e.style.marginBottom="",e.style.marginTop=""})),s.centeredSlides&&s.cssMode&&(u(a,"--swiper-centered-offset-before",""),u(a,"--swiper-centered-offset-after",""));const P=s.grid&&s.grid.rows>1&&e.grid;let L;P?e.grid.initSlides(c):e.grid&&e.grid.unsetSlides();const I="auto"===s.slidesPerView&&s.breakpoints&&Object.keys(s.breakpoints).filter((e=>void 0!==s.breakpoints[e].slidesPerView)).length>0;for(let a=0;a<p;a+=1){let i;if(L=0,c[a]&&(i=c[a]),P&&e.grid.updateSlide(a,i,c),!c[a]||"none"!==b(i,"display")){if("auto"===s.slidesPerView){I&&(c[a].style[e.getDirectionLabel("width")]="");const r=getComputedStyle(i),n=i.style.transform,l=i.style.webkitTransform;if(n&&(i.style.transform="none"),l&&(i.style.webkitTransform="none"),s.roundLengths)L=e.isHorizontal()?S(i,"width",!0):S(i,"height",!0);else{const e=t(r,"width"),s=t(r,"padding-left"),a=t(r,"padding-right"),n=t(r,"margin-left"),l=t(r,"margin-right"),o=r.getPropertyValue("box-sizing");if(o&&"border-box"===o)L=e+n+l;else{const{clientWidth:t,offsetWidth:r}=i;L=e+s+a+n+l+(r-t)}}n&&(i.style.transform=n),l&&(i.style.webkitTransform=l),s.roundLengths&&(L=Math.floor(L))}else L=(r-(s.slidesPerView-1)*x)/s.slidesPerView,s.roundLengths&&(L=Math.floor(L)),c[a]&&(c[a].style[e.getDirectionLabel("width")]=`${L}px`);c[a]&&(c[a].swiperSlideSize=L),g.push(L),s.centeredSlides?(T=T+L/2+M/2+x,0===M&&0!==a&&(T=T-r/2-x),0===a&&(T=T-r/2-x),Math.abs(T)<.001&&(T=0),s.roundLengths&&(T=Math.floor(T)),C%s.slidesPerGroup==0&&m.push(T),h.push(T)):(s.roundLengths&&(T=Math.floor(T)),(C-Math.min(e.params.slidesPerGroupSkip,C))%e.params.slidesPerGroup==0&&m.push(T),h.push(T),T=T+L+x),e.virtualSize+=L+x,M=L,C+=1}}if(e.virtualSize=Math.max(e.virtualSize,r)+w,n&&l&&("slide"===s.effect||"coverflow"===s.effect)&&(a.style.width=`${e.virtualSize+x}px`),s.setWrapperSize&&(a.style[e.getDirectionLabel("width")]=`${e.virtualSize+x}px`),P&&e.grid.updateWrapperSize(L,m),!s.centeredSlides){const t=[];for(let a=0;a<m.length;a+=1){let i=m[a];s.roundLengths&&(i=Math.floor(i)),m[a]<=e.virtualSize-r&&t.push(i)}m=t,Math.floor(e.virtualSize-r)-Math.floor(m[m.length-1])>1&&m.push(e.virtualSize-r)}if(o&&s.loop){const t=g[0]+x;if(s.slidesPerGroup>1){const a=Math.ceil((e.virtual.slidesBefore+e.virtual.slidesAfter)/s.slidesPerGroup),i=t*s.slidesPerGroup;for(let e=0;e<a;e+=1)m.push(m[m.length-1]+i)}for(let a=0;a<e.virtual.slidesBefore+e.virtual.slidesAfter;a+=1)1===s.slidesPerGroup&&m.push(m[m.length-1]+t),h.push(h[h.length-1]+t),e.virtualSize+=t}if(0===m.length&&(m=[0]),0!==x){const t=e.isHorizontal()&&n?"marginLeft":e.getDirectionLabel("marginRight");c.filter(((e,t)=>!(s.cssMode&&!s.loop)||t!==c.length-1)).forEach((e=>{e.style[t]=`${x}px`}))}if(s.centeredSlides&&s.centeredSlidesBounds){let e=0;g.forEach((t=>{e+=t+(x||0)})),e-=x;const t=e-r;m=m.map((e=>e<=0?-v:e>t?t+w:e))}if(s.centerInsufficientSlides){let e=0;if(g.forEach((t=>{e+=t+(x||0)})),e-=x,e<r){const t=(r-e)/2;m.forEach(((e,s)=>{m[s]=e-t})),h.forEach(((e,s)=>{h[s]=e+t}))}}if(Object.assign(e,{slides:c,snapGrid:m,slidesGrid:h,slidesSizesGrid:g}),s.centeredSlides&&s.cssMode&&!s.centeredSlidesBounds){u(a,"--swiper-centered-offset-before",-m[0]+"px"),u(a,"--swiper-centered-offset-after",e.size/2-g[g.length-1]/2+"px");const t=-e.snapGrid[0],s=-e.slidesGrid[0];e.snapGrid=e.snapGrid.map((e=>e+t)),e.slidesGrid=e.slidesGrid.map((e=>e+s))}if(p!==d&&e.emit("slidesLengthChange"),m.length!==y&&(e.params.watchOverflow&&e.checkOverflow(),e.emit("snapGridLengthChange")),h.length!==E&&e.emit("slidesGridLengthChange"),s.watchSlidesProgress&&e.updateSlidesOffset(),e.emit("slidesUpdated"),!(o||s.cssMode||"slide"!==s.effect&&"fade"!==s.effect)){const t=`${s.containerModifierClass}backface-hidden`,a=e.el.classList.contains(t);p<=s.maxBackfaceHiddenSlides?a||e.el.classList.add(t):a&&e.el.classList.remove(t)}},updateAutoHeight:function(e){const t=this,s=[],a=t.virtual&&t.params.virtual.enabled;let i,r=0;"number"==typeof e?t.setTransition(e):!0===e&&t.setTransition(t.params.speed);const n=e=>a?t.slides[t.getSlideIndexByData(e)]:t.slides[e];if("auto"!==t.params.slidesPerView&&t.params.slidesPerView>1)if(t.params.centeredSlides)(t.visibleSlides||[]).forEach((e=>{s.push(e)}));else for(i=0;i<Math.ceil(t.params.slidesPerView);i+=1){const e=t.activeIndex+i;if(e>t.slides.length&&!a)break;s.push(n(e))}else s.push(n(t.activeIndex));for(i=0;i<s.length;i+=1)if(void 0!==s[i]){const e=s[i].offsetHeight;r=e>r?e:r}(r||0===r)&&(t.wrapperEl.style.height=`${r}px`)},updateSlidesOffset:function(){const e=this,t=e.slides,s=e.isElement?e.isHorizontal()?e.wrapperEl.offsetLeft:e.wrapperEl.offsetTop:0;for(let a=0;a<t.length;a+=1)t[a].swiperSlideOffset=(e.isHorizontal()?t[a].offsetLeft:t[a].offsetTop)-s-e.cssOverflowAdjustment()},updateSlidesProgress:function(e){void 0===e&&(e=this&&this.translate||0);const t=this,s=t.params,{slides:a,rtlTranslate:i,snapGrid:r}=t;if(0===a.length)return;void 0===a[0].swiperSlideOffset&&t.updateSlidesOffset();let n=-e;i&&(n=e),a.forEach((e=>{e.classList.remove(s.slideVisibleClass,s.slideFullyVisibleClass)})),t.visibleSlidesIndexes=[],t.visibleSlides=[];let l=s.spaceBetween;"string"==typeof l&&l.indexOf("%")>=0?l=parseFloat(l.replace("%",""))/100*t.size:"string"==typeof l&&(l=parseFloat(l));for(let e=0;e<a.length;e+=1){const o=a[e];let d=o.swiperSlideOffset;s.cssMode&&s.centeredSlides&&(d-=a[0].swiperSlideOffset);const c=(n+(s.centeredSlides?t.minTranslate():0)-d)/(o.swiperSlideSize+l),p=(n-r[0]+(s.centeredSlides?t.minTranslate():0)-d)/(o.swiperSlideSize+l),u=-(n-d),m=u+t.slidesSizesGrid[e],h=u>=0&&u<=t.size-t.slidesSizesGrid[e];(u>=0&&u<t.size-1||m>1&&m<=t.size||u<=0&&m>=t.size)&&(t.visibleSlides.push(o),t.visibleSlidesIndexes.push(e),a[e].classList.add(s.slideVisibleClass)),h&&a[e].classList.add(s.slideFullyVisibleClass),o.progress=i?-c:c,o.originalProgress=i?-p:p}},updateProgress:function(e){const t=this;if(void 0===e){const s=t.rtlTranslate?-1:1;e=t&&t.translate&&t.translate*s||0}const s=t.params,a=t.maxTranslate()-t.minTranslate();let{progress:i,isBeginning:r,isEnd:n,progressLoop:l}=t;const o=r,d=n;if(0===a)i=0,r=!0,n=!0;else{i=(e-t.minTranslate())/a;const s=Math.abs(e-t.minTranslate())<1,l=Math.abs(e-t.maxTranslate())<1;r=s||i<=0,n=l||i>=1,s&&(i=0),l&&(i=1)}if(s.loop){const s=t.getSlideIndexByData(0),a=t.getSlideIndexByData(t.slides.length-1),i=t.slidesGrid[s],r=t.slidesGrid[a],n=t.slidesGrid[t.slidesGrid.length-1],o=Math.abs(e);l=o>=i?(o-i)/n:(o+n-r)/n,l>1&&(l-=1)}Object.assign(t,{progress:i,progressLoop:l,isBeginning:r,isEnd:n}),(s.watchSlidesProgress||s.centeredSlides&&s.autoHeight)&&t.updateSlidesProgress(e),r&&!o&&t.emit("reachBeginning toEdge"),n&&!d&&t.emit("reachEnd toEdge"),(o&&!r||d&&!n)&&t.emit("fromEdge"),t.emit("progress",i)},updateSlidesClasses:function(){const e=this,{slides:t,params:s,slidesEl:a,activeIndex:i}=e,r=e.virtual&&s.virtual.enabled,n=e.grid&&s.grid&&s.grid.rows>1,l=e=>f(a,`.${s.slideClass}${e}, swiper-slide${e}`)[0];let o,d,c;if(t.forEach((e=>{e.classList.remove(s.slideActiveClass,s.slideNextClass,s.slidePrevClass)})),r)if(s.loop){let t=i-e.virtual.slidesBefore;t<0&&(t=e.virtual.slides.length+t),t>=e.virtual.slides.length&&(t-=e.virtual.slides.length),o=l(`[data-swiper-slide-index="${t}"]`)}else o=l(`[data-swiper-slide-index="${i}"]`);else n?(o=t.filter((e=>e.column===i))[0],c=t.filter((e=>e.column===i+1))[0],d=t.filter((e=>e.column===i-1))[0]):o=t[i];o&&(o.classList.add(s.slideActiveClass),n?(c&&c.classList.add(s.slideNextClass),d&&d.classList.add(s.slidePrevClass)):(c=function(e,t){const s=[];for(;e.nextElementSibling;){const a=e.nextElementSibling;t?a.matches(t)&&s.push(a):s.push(a),e=a}return s}(o,`.${s.slideClass}, swiper-slide`)[0],s.loop&&!c&&(c=t[0]),c&&c.classList.add(s.slideNextClass),d=function(e,t){const s=[];for(;e.previousElementSibling;){const a=e.previousElementSibling;t?a.matches(t)&&s.push(a):s.push(a),e=a}return s}(o,`.${s.slideClass}, swiper-slide`)[0],s.loop&&0===!d&&(d=t[t.length-1]),d&&d.classList.add(s.slidePrevClass))),e.emitSlidesClasses()},updateActiveIndex:function(e){const t=this,s=t.rtlTranslate?t.translate:-t.translate,{snapGrid:a,params:i,activeIndex:r,realIndex:n,snapIndex:l}=t;let o,d=e;const c=e=>{let s=e-t.virtual.slidesBefore;return s<0&&(s=t.virtual.slides.length+s),s>=t.virtual.slides.length&&(s-=t.virtual.slides.length),s};if(void 0===d&&(d=function(e){const{slidesGrid:t,params:s}=e,a=e.rtlTranslate?e.translate:-e.translate;let i;for(let e=0;e<t.length;e+=1)void 0!==t[e+1]?a>=t[e]&&a<t[e+1]-(t[e+1]-t[e])/2?i=e:a>=t[e]&&a<t[e+1]&&(i=e+1):a>=t[e]&&(i=e);return s.normalizeSlideIndex&&(i<0||void 0===i)&&(i=0),i}(t)),a.indexOf(s)>=0)o=a.indexOf(s);else{const e=Math.min(i.slidesPerGroupSkip,d);o=e+Math.floor((d-e)/i.slidesPerGroup)}if(o>=a.length&&(o=a.length-1),d===r&&!t.params.loop)return void(o!==l&&(t.snapIndex=o,t.emit("snapIndexChange")));if(d===r&&t.params.loop&&t.virtual&&t.params.virtual.enabled)return void(t.realIndex=c(d));const p=t.grid&&i.grid&&i.grid.rows>1;let u;if(t.virtual&&i.virtual.enabled&&i.loop)u=c(d);else if(p){const e=t.slides.filter((e=>e.column===d))[0];let s=parseInt(e.getAttribute("data-swiper-slide-index"),10);Number.isNaN(s)&&(s=Math.max(t.slides.indexOf(e),0)),u=Math.floor(s/i.grid.rows)}else if(t.slides[d]){const e=t.slides[d].getAttribute("data-swiper-slide-index");u=e?parseInt(e,10):d}else u=d;Object.assign(t,{previousSnapIndex:l,snapIndex:o,previousRealIndex:n,realIndex:u,previousIndex:r,activeIndex:d}),t.initialized&&O(t),t.emit("activeIndexChange"),t.emit("snapIndexChange"),(t.initialized||t.params.runCallbacksOnInit)&&(n!==u&&t.emit("realIndexChange"),t.emit("slideChange"))},updateClickedSlide:function(e,t){const s=this,a=s.params;let i=e.closest(`.${a.slideClass}, swiper-slide`);!i&&s.isElement&&t&&t.length>1&&t.includes(e)&&[...t.slice(t.indexOf(e)+1,t.length)].forEach((e=>{!i&&e.matches&&e.matches(`.${a.slideClass}, swiper-slide`)&&(i=e)}));let r,n=!1;if(i)for(let e=0;e<s.slides.length;e+=1)if(s.slides[e]===i){n=!0,r=e;break}if(!i||!n)return s.clickedSlide=void 0,void(s.clickedIndex=void 0);s.clickedSlide=i,s.virtual&&s.params.virtual.enabled?s.clickedIndex=parseInt(i.getAttribute("data-swiper-slide-index"),10):s.clickedIndex=r,a.slideToClickedSlide&&void 0!==s.clickedIndex&&s.clickedIndex!==s.activeIndex&&s.slideToClickedSlide()}};var G={getTranslate:function(e){void 0===e&&(e=this.isHorizontal()?"x":"y");const{params:t,rtlTranslate:s,translate:a,wrapperEl:i}=this;if(t.virtualTranslate)return s?-a:a;if(t.cssMode)return a;let r=d(i,e);return r+=this.cssOverflowAdjustment(),s&&(r=-r),r||0},setTranslate:function(e,t){const s=this,{rtlTranslate:a,params:i,wrapperEl:r,progress:n}=s;let l,o=0,d=0;s.isHorizontal()?o=a?-e:e:d=e,i.roundLengths&&(o=Math.floor(o),d=Math.floor(d)),s.previousTranslate=s.translate,s.translate=s.isHorizontal()?o:d,i.cssMode?r[s.isHorizontal()?"scrollLeft":"scrollTop"]=s.isHorizontal()?-o:-d:i.virtualTranslate||(s.isHorizontal()?o-=s.cssOverflowAdjustment():d-=s.cssOverflowAdjustment(),r.style.transform=`translate3d(${o}px, ${d}px, 0px)`);const c=s.maxTranslate()-s.minTranslate();l=0===c?0:(e-s.minTranslate())/c,l!==n&&s.updateProgress(e),s.emit("setTranslate",s.translate,t)},minTranslate:function(){return-this.snapGrid[0]},maxTranslate:function(){return-this.snapGrid[this.snapGrid.length-1]},translateTo:function(e,t,s,a,i){void 0===e&&(e=0),void 0===t&&(t=this.params.speed),void 0===s&&(s=!0),void 0===a&&(a=!0);const r=this,{params:n,wrapperEl:l}=r;if(r.animating&&n.preventInteractionOnTransition)return!1;const o=r.minTranslate(),d=r.maxTranslate();let c;if(c=a&&e>o?o:a&&e<d?d:e,r.updateProgress(c),n.cssMode){const e=r.isHorizontal();if(0===t)l[e?"scrollLeft":"scrollTop"]=-c;else{if(!r.support.smoothScroll)return m({swiper:r,targetPosition:-c,side:e?"left":"top"}),!0;l.scrollTo({[e?"left":"top"]:-c,behavior:"smooth"})}return!0}return 0===t?(r.setTransition(0),r.setTranslate(c),s&&(r.emit("beforeTransitionStart",t,i),r.emit("transitionEnd"))):(r.setTransition(t),r.setTranslate(c),s&&(r.emit("beforeTransitionStart",t,i),r.emit("transitionStart")),r.animating||(r.animating=!0,r.onTranslateToWrapperTransitionEnd||(r.onTranslateToWrapperTransitionEnd=function(e){r&&!r.destroyed&&e.target===this&&(r.wrapperEl.removeEventListener("transitionend",r.onTranslateToWrapperTransitionEnd),r.onTranslateToWrapperTransitionEnd=null,delete r.onTranslateToWrapperTransitionEnd,s&&r.emit("transitionEnd"))}),r.wrapperEl.addEventListener("transitionend",r.onTranslateToWrapperTransitionEnd))),!0}};function N(e){let{swiper:t,runCallbacks:s,direction:a,step:i}=e;const{activeIndex:r,previousIndex:n}=t;let l=a;if(l||(l=r>n?"next":r<n?"prev":"reset"),t.emit(`transition${i}`),s&&r!==n){if("reset"===l)return void t.emit(`slideResetTransition${i}`);t.emit(`slideChangeTransition${i}`),"next"===l?t.emit(`slideNextTransition${i}`):t.emit(`slidePrevTransition${i}`)}}var H={slideTo:function(e,t,s,a,i){void 0===e&&(e=0),void 0===t&&(t=this.params.speed),void 0===s&&(s=!0),"string"==typeof e&&(e=parseInt(e,10));const r=this;let n=e;n<0&&(n=0);const{params:l,snapGrid:o,slidesGrid:d,previousIndex:c,activeIndex:p,rtlTranslate:u,wrapperEl:h,enabled:f}=r;if(r.animating&&l.preventInteractionOnTransition||!f&&!a&&!i||r.destroyed)return!1;const g=Math.min(r.params.slidesPerGroupSkip,n);let v=g+Math.floor((n-g)/r.params.slidesPerGroup);v>=o.length&&(v=o.length-1);const w=-o[v];if(l.normalizeSlideIndex)for(let e=0;e<d.length;e+=1){const t=-Math.floor(100*w),s=Math.floor(100*d[e]),a=Math.floor(100*d[e+1]);void 0!==d[e+1]?t>=s&&t<a-(a-s)/2?n=e:t>=s&&t<a&&(n=e+1):t>=s&&(n=e)}if(r.initialized&&n!==p){if(!r.allowSlideNext&&(u?w>r.translate&&w>r.minTranslate():w<r.translate&&w<r.minTranslate()))return!1;if(!r.allowSlidePrev&&w>r.translate&&w>r.maxTranslate()&&(p||0)!==n)return!1}let b;if(n!==(c||0)&&s&&r.emit("beforeSlideChangeStart"),r.updateProgress(w),b=n>p?"next":n<p?"prev":"reset",u&&-w===r.translate||!u&&w===r.translate)return r.updateActiveIndex(n),l.autoHeight&&r.updateAutoHeight(),r.updateSlidesClasses(),"slide"!==l.effect&&r.setTranslate(w),"reset"!==b&&(r.transitionStart(s,b),r.transitionEnd(s,b)),!1;if(l.cssMode){const e=r.isHorizontal(),s=u?w:-w;if(0===t){const t=r.virtual&&r.params.virtual.enabled;t&&(r.wrapperEl.style.scrollSnapType="none",r._immediateVirtual=!0),t&&!r._cssModeVirtualInitialSet&&r.params.initialSlide>0?(r._cssModeVirtualInitialSet=!0,requestAnimationFrame((()=>{h[e?"scrollLeft":"scrollTop"]=s}))):h[e?"scrollLeft":"scrollTop"]=s,t&&requestAnimationFrame((()=>{r.wrapperEl.style.scrollSnapType="",r._immediateVirtual=!1}))}else{if(!r.support.smoothScroll)return m({swiper:r,targetPosition:s,side:e?"left":"top"}),!0;h.scrollTo({[e?"left":"top"]:s,behavior:"smooth"})}return!0}return r.setTransition(t),r.setTranslate(w),r.updateActiveIndex(n),r.updateSlidesClasses(),r.emit("beforeTransitionStart",t,a),r.transitionStart(s,b),0===t?r.transitionEnd(s,b):r.animating||(r.animating=!0,r.onSlideToWrapperTransitionEnd||(r.onSlideToWrapperTransitionEnd=function(e){r&&!r.destroyed&&e.target===this&&(r.wrapperEl.removeEventListener("transitionend",r.onSlideToWrapperTransitionEnd),r.onSlideToWrapperTransitionEnd=null,delete r.onSlideToWrapperTransitionEnd,r.transitionEnd(s,b))}),r.wrapperEl.addEventListener("transitionend",r.onSlideToWrapperTransitionEnd)),!0},slideToLoop:function(e,t,s,a){if(void 0===e&&(e=0),void 0===t&&(t=this.params.speed),void 0===s&&(s=!0),"string"==typeof e){e=parseInt(e,10)}const i=this;if(i.destroyed)return;const r=i.grid&&i.params.grid&&i.params.grid.rows>1;let n=e;if(i.params.loop)if(i.virtual&&i.params.virtual.enabled)n+=i.virtual.slidesBefore;else{let e;if(r){const t=n*i.params.grid.rows;e=i.slides.filter((e=>1*e.getAttribute("data-swiper-slide-index")===t))[0].column}else e=i.getSlideIndexByData(n);const t=r?Math.ceil(i.slides.length/i.params.grid.rows):i.slides.length,{centeredSlides:s}=i.params;let a=i.params.slidesPerView;"auto"===a?a=i.slidesPerViewDynamic():(a=Math.ceil(parseFloat(i.params.slidesPerView,10)),s&&a%2==0&&(a+=1));let l=t-e<a;if(s&&(l=l||e<Math.ceil(a/2)),l){const a=s?e<i.activeIndex?"prev":"next":e-i.activeIndex-1<i.params.slidesPerView?"next":"prev";i.loopFix({direction:a,slideTo:!0,activeSlideIndex:"next"===a?e+1:e-t+1,slideRealIndex:"next"===a?i.realIndex:void 0})}if(r){const e=n*i.params.grid.rows;n=i.slides.filter((t=>1*t.getAttribute("data-swiper-slide-index")===e))[0].column}else n=i.getSlideIndexByData(n)}return requestAnimationFrame((()=>{i.slideTo(n,t,s,a)})),i},slideNext:function(e,t,s){void 0===e&&(e=this.params.speed),void 0===t&&(t=!0);const a=this,{enabled:i,params:r,animating:n}=a;if(!i||a.destroyed)return a;let l=r.slidesPerGroup;"auto"===r.slidesPerView&&1===r.slidesPerGroup&&r.slidesPerGroupAuto&&(l=Math.max(a.slidesPerViewDynamic("current",!0),1));const o=a.activeIndex<r.slidesPerGroupSkip?1:l,d=a.virtual&&r.virtual.enabled;if(r.loop){if(n&&!d&&r.loopPreventsSliding)return!1;if(a.loopFix({direction:"next"}),a._clientLeft=a.wrapperEl.clientLeft,a.activeIndex===a.slides.length-1&&r.cssMode)return requestAnimationFrame((()=>{a.slideTo(a.activeIndex+o,e,t,s)})),!0}return r.rewind&&a.isEnd?a.slideTo(0,e,t,s):a.slideTo(a.activeIndex+o,e,t,s)},slidePrev:function(e,t,s){void 0===e&&(e=this.params.speed),void 0===t&&(t=!0);const a=this,{params:i,snapGrid:r,slidesGrid:n,rtlTranslate:l,enabled:o,animating:d}=a;if(!o||a.destroyed)return a;const c=a.virtual&&i.virtual.enabled;if(i.loop){if(d&&!c&&i.loopPreventsSliding)return!1;a.loopFix({direction:"prev"}),a._clientLeft=a.wrapperEl.clientLeft}function p(e){return e<0?-Math.floor(Math.abs(e)):Math.floor(e)}const u=p(l?a.translate:-a.translate),m=r.map((e=>p(e)));let h=r[m.indexOf(u)-1];if(void 0===h&&i.cssMode){let e;r.forEach(((t,s)=>{u>=t&&(e=s)})),void 0!==e&&(h=r[e>0?e-1:e])}let f=0;if(void 0!==h&&(f=n.indexOf(h),f<0&&(f=a.activeIndex-1),"auto"===i.slidesPerView&&1===i.slidesPerGroup&&i.slidesPerGroupAuto&&(f=f-a.slidesPerViewDynamic("previous",!0)+1,f=Math.max(f,0))),i.rewind&&a.isBeginning){const i=a.params.virtual&&a.params.virtual.enabled&&a.virtual?a.virtual.slides.length-1:a.slides.length-1;return a.slideTo(i,e,t,s)}return i.loop&&0===a.activeIndex&&i.cssMode?(requestAnimationFrame((()=>{a.slideTo(f,e,t,s)})),!0):a.slideTo(f,e,t,s)},slideReset:function(e,t,s){void 0===e&&(e=this.params.speed),void 0===t&&(t=!0);const a=this;if(!a.destroyed)return a.slideTo(a.activeIndex,e,t,s)},slideToClosest:function(e,t,s,a){void 0===e&&(e=this.params.speed),void 0===t&&(t=!0),void 0===a&&(a=.5);const i=this;if(i.destroyed)return;let r=i.activeIndex;const n=Math.min(i.params.slidesPerGroupSkip,r),l=n+Math.floor((r-n)/i.params.slidesPerGroup),o=i.rtlTranslate?i.translate:-i.translate;if(o>=i.snapGrid[l]){const e=i.snapGrid[l];o-e>(i.snapGrid[l+1]-e)*a&&(r+=i.params.slidesPerGroup)}else{const e=i.snapGrid[l-1];o-e<=(i.snapGrid[l]-e)*a&&(r-=i.params.slidesPerGroup)}return r=Math.max(r,0),r=Math.min(r,i.slidesGrid.length-1),i.slideTo(r,e,t,s)},slideToClickedSlide:function(){const e=this;if(e.destroyed)return;const{params:t,slidesEl:s}=e,a="auto"===t.slidesPerView?e.slidesPerViewDynamic():t.slidesPerView;let i,r=e.clickedIndex;const n=e.isElement?"swiper-slide":`.${t.slideClass}`;if(t.loop){if(e.animating)return;i=parseInt(e.clickedSlide.getAttribute("data-swiper-slide-index"),10),t.centeredSlides?r<e.loopedSlides-a/2||r>e.slides.length-e.loopedSlides+a/2?(e.loopFix(),r=e.getSlideIndex(f(s,`${n}[data-swiper-slide-index="${i}"]`)[0]),l((()=>{e.slideTo(r)}))):e.slideTo(r):r>e.slides.length-a?(e.loopFix(),r=e.getSlideIndex(f(s,`${n}[data-swiper-slide-index="${i}"]`)[0]),l((()=>{e.slideTo(r)}))):e.slideTo(r)}else e.slideTo(r)}};var X={loopCreate:function(e){const t=this,{params:s,slidesEl:a}=t;if(!s.loop||t.virtual&&t.params.virtual.enabled)return;const i=()=>{f(a,`.${s.slideClass}, swiper-slide`).forEach(((e,t)=>{e.setAttribute("data-swiper-slide-index",t)}))},r=t.grid&&s.grid&&s.grid.rows>1,n=s.slidesPerGroup*(r?s.grid.rows:1),l=t.slides.length%n!=0,o=r&&t.slides.length%s.grid.rows!=0,d=e=>{for(let a=0;a<e;a+=1){const e=t.isElement?v("swiper-slide",[s.slideBlankClass]):v("div",[s.slideClass,s.slideBlankClass]);t.slidesEl.append(e)}};if(l){if(s.loopAddBlankSlides){d(n-t.slides.length%n),t.recalcSlides(),t.updateSlides()}else g("Swiper Loop Warning: The number of slides is not even to slidesPerGroup, loop mode may not function properly. You need to add more slides (or make duplicates, or empty slides)");i()}else if(o){if(s.loopAddBlankSlides){d(s.grid.rows-t.slides.length%s.grid.rows),t.recalcSlides(),t.updateSlides()}else g("Swiper Loop Warning: The number of slides is not even to grid.rows, loop mode may not function properly. You need to add more slides (or make duplicates, or empty slides)");i()}else i();t.loopFix({slideRealIndex:e,direction:s.centeredSlides?void 0:"next"})},loopFix:function(e){let{slideRealIndex:t,slideTo:s=!0,direction:a,setTranslate:i,activeSlideIndex:r,byController:n,byMousewheel:l}=void 0===e?{}:e;const o=this;if(!o.params.loop)return;o.emit("beforeLoopFix");const{slides:d,allowSlidePrev:c,allowSlideNext:p,slidesEl:u,params:m}=o,{centeredSlides:h}=m;if(o.allowSlidePrev=!0,o.allowSlideNext=!0,o.virtual&&m.virtual.enabled)return s&&(m.centeredSlides||0!==o.snapIndex?m.centeredSlides&&o.snapIndex<m.slidesPerView?o.slideTo(o.virtual.slides.length+o.snapIndex,0,!1,!0):o.snapIndex===o.snapGrid.length-1&&o.slideTo(o.virtual.slidesBefore,0,!1,!0):o.slideTo(o.virtual.slides.length,0,!1,!0)),o.allowSlidePrev=c,o.allowSlideNext=p,void o.emit("loopFix");let f=m.slidesPerView;"auto"===f?f=o.slidesPerViewDynamic():(f=Math.ceil(parseFloat(m.slidesPerView,10)),h&&f%2==0&&(f+=1));const v=m.slidesPerGroupAuto?f:m.slidesPerGroup;let w=v;w%v!=0&&(w+=v-w%v),w+=m.loopAdditionalSlides,o.loopedSlides=w;const b=o.grid&&m.grid&&m.grid.rows>1;d.length<f+w?g("Swiper Loop Warning: The number of slides is not enough for loop mode, it will be disabled and not function properly. You need to add more slides (or make duplicates) or lower the values of slidesPerView and slidesPerGroup parameters"):b&&"row"===m.grid.fill&&g("Swiper Loop Warning: Loop mode is not compatible with grid.fill = `row`");const y=[],E=[];let x=o.activeIndex;void 0===r?r=o.getSlideIndex(d.filter((e=>e.classList.contains(m.slideActiveClass)))[0]):x=r;const S="next"===a||!a,T="prev"===a||!a;let M=0,C=0;const P=b?Math.ceil(d.length/m.grid.rows):d.length,L=(b?d[r].column:r)+(h&&void 0===i?-f/2+.5:0);if(L<w){M=Math.max(w-L,v);for(let e=0;e<w-L;e+=1){const t=e-Math.floor(e/P)*P;if(b){const e=P-t-1;for(let t=d.length-1;t>=0;t-=1)d[t].column===e&&y.push(t)}else y.push(P-t-1)}}else if(L+f>P-w){C=Math.max(L-(P-2*w),v);for(let e=0;e<C;e+=1){const t=e-Math.floor(e/P)*P;b?d.forEach(((e,s)=>{e.column===t&&E.push(s)})):E.push(t)}}if(o.__preventObserver__=!0,requestAnimationFrame((()=>{o.__preventObserver__=!1})),T&&y.forEach((e=>{d[e].swiperLoopMoveDOM=!0,u.prepend(d[e]),d[e].swiperLoopMoveDOM=!1})),S&&E.forEach((e=>{d[e].swiperLoopMoveDOM=!0,u.append(d[e]),d[e].swiperLoopMoveDOM=!1})),o.recalcSlides(),"auto"===m.slidesPerView?o.updateSlides():b&&(y.length>0&&T||E.length>0&&S)&&o.slides.forEach(((e,t)=>{o.grid.updateSlide(t,e,o.slides)})),m.watchSlidesProgress&&o.updateSlidesOffset(),s)if(y.length>0&&T){if(void 0===t){const e=o.slidesGrid[x],t=o.slidesGrid[x+M]-e;l?o.setTranslate(o.translate-t):(o.slideTo(x+M,0,!1,!0),i&&(o.touchEventsData.startTranslate=o.touchEventsData.startTranslate-t,o.touchEventsData.currentTranslate=o.touchEventsData.currentTranslate-t))}else if(i){const e=b?y.length/m.grid.rows:y.length;o.slideTo(o.activeIndex+e,0,!1,!0),o.touchEventsData.currentTranslate=o.translate}}else if(E.length>0&&S)if(void 0===t){const e=o.slidesGrid[x],t=o.slidesGrid[x-C]-e;l?o.setTranslate(o.translate-t):(o.slideTo(x-C,0,!1,!0),i&&(o.touchEventsData.startTranslate=o.touchEventsData.startTranslate-t,o.touchEventsData.currentTranslate=o.touchEventsData.currentTranslate-t))}else{const e=b?E.length/m.grid.rows:E.length;o.slideTo(o.activeIndex-e,0,!1,!0)}if(o.allowSlidePrev=c,o.allowSlideNext=p,o.controller&&o.controller.control&&!n){const e={slideRealIndex:t,direction:a,setTranslate:i,activeSlideIndex:r,byController:!0};Array.isArray(o.controller.control)?o.controller.control.forEach((t=>{!t.destroyed&&t.params.loop&&t.loopFix({...e,slideTo:t.params.slidesPerView===m.slidesPerView&&s})})):o.controller.control instanceof o.constructor&&o.controller.control.params.loop&&o.controller.control.loopFix({...e,slideTo:o.controller.control.params.slidesPerView===m.slidesPerView&&s})}o.emit("loopFix")},loopDestroy:function(){const e=this,{params:t,slidesEl:s}=e;if(!t.loop||e.virtual&&e.params.virtual.enabled)return;e.recalcSlides();const a=[];e.slides.forEach((e=>{const t=void 0===e.swiperSlideIndex?1*e.getAttribute("data-swiper-slide-index"):e.swiperSlideIndex;a[t]=e})),e.slides.forEach((e=>{e.removeAttribute("data-swiper-slide-index")})),a.forEach((e=>{s.append(e)})),e.recalcSlides(),e.slideTo(e.realIndex,0)}};function Y(e,t,s){const a=r(),{params:i}=e,n=i.edgeSwipeDetection,l=i.edgeSwipeThreshold;return!n||!(s<=l||s>=a.innerWidth-l)||"prevent"===n&&(t.preventDefault(),!0)}function B(e){const t=this,s=a();let i=e;i.originalEvent&&(i=i.originalEvent);const n=t.touchEventsData;if("pointerdown"===i.type){if(null!==n.pointerId&&n.pointerId!==i.pointerId)return;n.pointerId=i.pointerId}else"touchstart"===i.type&&1===i.targetTouches.length&&(n.touchId=i.targetTouches[0].identifier);if("touchstart"===i.type)return void Y(t,i,i.targetTouches[0].pageX);const{params:l,touches:d,enabled:c}=t;if(!c)return;if(!l.simulateTouch&&"mouse"===i.pointerType)return;if(t.animating&&l.preventInteractionOnTransition)return;!t.animating&&l.cssMode&&l.loop&&t.loopFix();let p=i.target;if("wrapper"===l.touchEventsTarget&&!t.wrapperEl.contains(p))return;if("which"in i&&3===i.which)return;if("button"in i&&i.button>0)return;if(n.isTouched&&n.isMoved)return;const u=!!l.noSwipingClass&&""!==l.noSwipingClass,m=i.composedPath?i.composedPath():i.path;u&&i.target&&i.target.shadowRoot&&m&&(p=m[0]);const h=l.noSwipingSelector?l.noSwipingSelector:`.${l.noSwipingClass}`,f=!(!i.target||!i.target.shadowRoot);if(l.noSwiping&&(f?function(e,t){return void 0===t&&(t=this),function t(s){if(!s||s===a()||s===r())return null;s.assignedSlot&&(s=s.assignedSlot);const i=s.closest(e);return i||s.getRootNode?i||t(s.getRootNode().host):null}(t)}(h,p):p.closest(h)))return void(t.allowClick=!0);if(l.swipeHandler&&!p.closest(l.swipeHandler))return;d.currentX=i.pageX,d.currentY=i.pageY;const g=d.currentX,v=d.currentY;if(!Y(t,i,g))return;Object.assign(n,{isTouched:!0,isMoved:!1,allowTouchCallbacks:!0,isScrolling:void 0,startMoving:void 0}),d.startX=g,d.startY=v,n.touchStartTime=o(),t.allowClick=!0,t.updateSize(),t.swipeDirection=void 0,l.threshold>0&&(n.allowThresholdMove=!1);let w=!0;p.matches(n.focusableElements)&&(w=!1,"SELECT"===p.nodeName&&(n.isTouched=!1)),s.activeElement&&s.activeElement.matches(n.focusableElements)&&s.activeElement!==p&&s.activeElement.blur();const b=w&&t.allowTouchMove&&l.touchStartPreventDefault;!l.touchStartForcePreventDefault&&!b||p.isContentEditable||i.preventDefault(),l.freeMode&&l.freeMode.enabled&&t.freeMode&&t.animating&&!l.cssMode&&t.freeMode.onTouchStart(),t.emit("touchStart",i)}function R(e){const t=a(),s=this,i=s.touchEventsData,{params:r,touches:n,rtlTranslate:l,enabled:d}=s;if(!d)return;if(!r.simulateTouch&&"mouse"===e.pointerType)return;let c,p=e;if(p.originalEvent&&(p=p.originalEvent),"pointermove"===p.type){if(null!==i.touchId)return;if(p.pointerId!==i.pointerId)return}if("touchmove"===p.type){if(c=[...p.changedTouches].filter((e=>e.identifier===i.touchId))[0],!c||c.identifier!==i.touchId)return}else c=p;if(!i.isTouched)return void(i.startMoving&&i.isScrolling&&s.emit("touchMoveOpposite",p));const u=c.pageX,m=c.pageY;if(p.preventedByNestedSwiper)return n.startX=u,void(n.startY=m);if(!s.allowTouchMove)return p.target.matches(i.focusableElements)||(s.allowClick=!1),void(i.isTouched&&(Object.assign(n,{startX:u,startY:m,currentX:u,currentY:m}),i.touchStartTime=o()));if(r.touchReleaseOnEdges&&!r.loop)if(s.isVertical()){if(m<n.startY&&s.translate<=s.maxTranslate()||m>n.startY&&s.translate>=s.minTranslate())return i.isTouched=!1,void(i.isMoved=!1)}else if(u<n.startX&&s.translate<=s.maxTranslate()||u>n.startX&&s.translate>=s.minTranslate())return;if(t.activeElement&&p.target===t.activeElement&&p.target.matches(i.focusableElements))return i.isMoved=!0,void(s.allowClick=!1);i.allowTouchCallbacks&&s.emit("touchMove",p),n.previousX=n.currentX,n.previousY=n.currentY,n.currentX=u,n.currentY=m;const h=n.currentX-n.startX,f=n.currentY-n.startY;if(s.params.threshold&&Math.sqrt(h**2+f**2)<s.params.threshold)return;if(void 0===i.isScrolling){let e;s.isHorizontal()&&n.currentY===n.startY||s.isVertical()&&n.currentX===n.startX?i.isScrolling=!1:h*h+f*f>=25&&(e=180*Math.atan2(Math.abs(f),Math.abs(h))/Math.PI,i.isScrolling=s.isHorizontal()?e>r.touchAngle:90-e>r.touchAngle)}if(i.isScrolling&&s.emit("touchMoveOpposite",p),void 0===i.startMoving&&(n.currentX===n.startX&&n.currentY===n.startY||(i.startMoving=!0)),i.isScrolling)return void(i.isTouched=!1);if(!i.startMoving)return;s.allowClick=!1,!r.cssMode&&p.cancelable&&p.preventDefault(),r.touchMoveStopPropagation&&!r.nested&&p.stopPropagation();let g=s.isHorizontal()?h:f,v=s.isHorizontal()?n.currentX-n.previousX:n.currentY-n.previousY;r.oneWayMovement&&(g=Math.abs(g)*(l?1:-1),v=Math.abs(v)*(l?1:-1)),n.diff=g,g*=r.touchRatio,l&&(g=-g,v=-v);const w=s.touchesDirection;s.swipeDirection=g>0?"prev":"next",s.touchesDirection=v>0?"prev":"next";const b=s.params.loop&&!r.cssMode,y="next"===s.touchesDirection&&s.allowSlideNext||"prev"===s.touchesDirection&&s.allowSlidePrev;if(!i.isMoved){if(b&&y&&s.loopFix({direction:s.swipeDirection}),i.startTranslate=s.getTranslate(),s.setTransition(0),s.animating){const e=new window.CustomEvent("transitionend",{bubbles:!0,cancelable:!0});s.wrapperEl.dispatchEvent(e)}i.allowMomentumBounce=!1,!r.grabCursor||!0!==s.allowSlideNext&&!0!==s.allowSlidePrev||s.setGrabCursor(!0),s.emit("sliderFirstMove",p)}if((new Date).getTime(),i.isMoved&&i.allowThresholdMove&&w!==s.touchesDirection&&b&&y&&Math.abs(g)>=1)return Object.assign(n,{startX:u,startY:m,currentX:u,currentY:m,startTranslate:i.currentTranslate}),i.loopSwapReset=!0,void(i.startTranslate=i.currentTranslate);s.emit("sliderMove",p),i.isMoved=!0,i.currentTranslate=g+i.startTranslate;let E=!0,x=r.resistanceRatio;if(r.touchReleaseOnEdges&&(x=0),g>0?(b&&y&&i.allowThresholdMove&&i.currentTranslate>(r.centeredSlides?s.minTranslate()-s.slidesSizesGrid[s.activeIndex+1]:s.minTranslate())&&s.loopFix({direction:"prev",setTranslate:!0,activeSlideIndex:0}),i.currentTranslate>s.minTranslate()&&(E=!1,r.resistance&&(i.currentTranslate=s.minTranslate()-1+(-s.minTranslate()+i.startTranslate+g)**x))):g<0&&(b&&y&&i.allowThresholdMove&&i.currentTranslate<(r.centeredSlides?s.maxTranslate()+s.slidesSizesGrid[s.slidesSizesGrid.length-1]:s.maxTranslate())&&s.loopFix({direction:"next",setTranslate:!0,activeSlideIndex:s.slides.length-("auto"===r.slidesPerView?s.slidesPerViewDynamic():Math.ceil(parseFloat(r.slidesPerView,10)))}),i.currentTranslate<s.maxTranslate()&&(E=!1,r.resistance&&(i.currentTranslate=s.maxTranslate()+1-(s.maxTranslate()-i.startTranslate-g)**x))),E&&(p.preventedByNestedSwiper=!0),!s.allowSlideNext&&"next"===s.swipeDirection&&i.currentTranslate<i.startTranslate&&(i.currentTranslate=i.startTranslate),!s.allowSlidePrev&&"prev"===s.swipeDirection&&i.currentTranslate>i.startTranslate&&(i.currentTranslate=i.startTranslate),s.allowSlidePrev||s.allowSlideNext||(i.currentTranslate=i.startTranslate),r.threshold>0){if(!(Math.abs(g)>r.threshold||i.allowThresholdMove))return void(i.currentTranslate=i.startTranslate);if(!i.allowThresholdMove)return i.allowThresholdMove=!0,n.startX=n.currentX,n.startY=n.currentY,i.currentTranslate=i.startTranslate,void(n.diff=s.isHorizontal()?n.currentX-n.startX:n.currentY-n.startY)}r.followFinger&&!r.cssMode&&((r.freeMode&&r.freeMode.enabled&&s.freeMode||r.watchSlidesProgress)&&(s.updateActiveIndex(),s.updateSlidesClasses()),r.freeMode&&r.freeMode.enabled&&s.freeMode&&s.freeMode.onTouchMove(),s.updateProgress(i.currentTranslate),s.setTranslate(i.currentTranslate))}function F(e){const t=this,s=t.touchEventsData;let a,i=e;i.originalEvent&&(i=i.originalEvent);if("touchend"===i.type||"touchcancel"===i.type){if(a=[...i.changedTouches].filter((e=>e.identifier===s.touchId))[0],!a||a.identifier!==s.touchId)return}else{if(null!==s.touchId)return;if(i.pointerId!==s.pointerId)return;a=i}if(["pointercancel","pointerout","pointerleave","contextmenu"].includes(i.type)){if(!(["pointercancel","contextmenu"].includes(i.type)&&(t.browser.isSafari||t.browser.isWebView)))return}s.pointerId=null,s.touchId=null;const{params:r,touches:n,rtlTranslate:d,slidesGrid:c,enabled:p}=t;if(!p)return;if(!r.simulateTouch&&"mouse"===i.pointerType)return;if(s.allowTouchCallbacks&&t.emit("touchEnd",i),s.allowTouchCallbacks=!1,!s.isTouched)return s.isMoved&&r.grabCursor&&t.setGrabCursor(!1),s.isMoved=!1,void(s.startMoving=!1);r.grabCursor&&s.isMoved&&s.isTouched&&(!0===t.allowSlideNext||!0===t.allowSlidePrev)&&t.setGrabCursor(!1);const u=o(),m=u-s.touchStartTime;if(t.allowClick){const e=i.path||i.composedPath&&i.composedPath();t.updateClickedSlide(e&&e[0]||i.target,e),t.emit("tap click",i),m<300&&u-s.lastClickTime<300&&t.emit("doubleTap doubleClick",i)}if(s.lastClickTime=o(),l((()=>{t.destroyed||(t.allowClick=!0)})),!s.isTouched||!s.isMoved||!t.swipeDirection||0===n.diff&&!s.loopSwapReset||s.currentTranslate===s.startTranslate&&!s.loopSwapReset)return s.isTouched=!1,s.isMoved=!1,void(s.startMoving=!1);let h;if(s.isTouched=!1,s.isMoved=!1,s.startMoving=!1,h=r.followFinger?d?t.translate:-t.translate:-s.currentTranslate,r.cssMode)return;if(r.freeMode&&r.freeMode.enabled)return void t.freeMode.onTouchEnd({currentPos:h});const f=h>=-t.maxTranslate()&&!t.params.loop;let g=0,v=t.slidesSizesGrid[0];for(let e=0;e<c.length;e+=e<r.slidesPerGroupSkip?1:r.slidesPerGroup){const t=e<r.slidesPerGroupSkip-1?1:r.slidesPerGroup;void 0!==c[e+t]?(f||h>=c[e]&&h<c[e+t])&&(g=e,v=c[e+t]-c[e]):(f||h>=c[e])&&(g=e,v=c[c.length-1]-c[c.length-2])}let w=null,b=null;r.rewind&&(t.isBeginning?b=r.virtual&&r.virtual.enabled&&t.virtual?t.virtual.slides.length-1:t.slides.length-1:t.isEnd&&(w=0));const y=(h-c[g])/v,E=g<r.slidesPerGroupSkip-1?1:r.slidesPerGroup;if(m>r.longSwipesMs){if(!r.longSwipes)return void t.slideTo(t.activeIndex);"next"===t.swipeDirection&&(y>=r.longSwipesRatio?t.slideTo(r.rewind&&t.isEnd?w:g+E):t.slideTo(g)),"prev"===t.swipeDirection&&(y>1-r.longSwipesRatio?t.slideTo(g+E):null!==b&&y<0&&Math.abs(y)>r.longSwipesRatio?t.slideTo(b):t.slideTo(g))}else{if(!r.shortSwipes)return void t.slideTo(t.activeIndex);t.navigation&&(i.target===t.navigation.nextEl||i.target===t.navigation.prevEl)?i.target===t.navigation.nextEl?t.slideTo(g+E):t.slideTo(g):("next"===t.swipeDirection&&t.slideTo(null!==w?w:g+E),"prev"===t.swipeDirection&&t.slideTo(null!==b?b:g))}}function q(){const e=this,{params:t,el:s}=e;if(s&&0===s.offsetWidth)return;t.breakpoints&&e.setBreakpoint();const{allowSlideNext:a,allowSlidePrev:i,snapGrid:r}=e,n=e.virtual&&e.params.virtual.enabled;e.allowSlideNext=!0,e.allowSlidePrev=!0,e.updateSize(),e.updateSlides(),e.updateSlidesClasses();const l=n&&t.loop;!("auto"===t.slidesPerView||t.slidesPerView>1)||!e.isEnd||e.isBeginning||e.params.centeredSlides||l?e.params.loop&&!n?e.slideToLoop(e.realIndex,0,!1,!0):e.slideTo(e.activeIndex,0,!1,!0):e.slideTo(e.slides.length-1,0,!1,!0),e.autoplay&&e.autoplay.running&&e.autoplay.paused&&(clearTimeout(e.autoplay.resizeTimeout),e.autoplay.resizeTimeout=setTimeout((()=>{e.autoplay&&e.autoplay.running&&e.autoplay.paused&&e.autoplay.resume()}),500)),e.allowSlidePrev=i,e.allowSlideNext=a,e.params.watchOverflow&&r!==e.snapGrid&&e.checkOverflow()}function V(e){const t=this;t.enabled&&(t.allowClick||(t.params.preventClicks&&e.preventDefault(),t.params.preventClicksPropagation&&t.animating&&(e.stopPropagation(),e.stopImmediatePropagation())))}function _(){const e=this,{wrapperEl:t,rtlTranslate:s,enabled:a}=e;if(!a)return;let i;e.previousTranslate=e.translate,e.isHorizontal()?e.translate=-t.scrollLeft:e.translate=-t.scrollTop,0===e.translate&&(e.translate=0),e.updateActiveIndex(),e.updateSlidesClasses();const r=e.maxTranslate()-e.minTranslate();i=0===r?0:(e.translate-e.minTranslate())/r,i!==e.progress&&e.updateProgress(s?-e.translate:e.translate),e.emit("setTranslate",e.translate,!1)}function j(e){const t=this;$(t,e.target),t.params.cssMode||"auto"!==t.params.slidesPerView&&!t.params.autoHeight||t.update()}function W(){const e=this;e.documentTouchHandlerProceeded||(e.documentTouchHandlerProceeded=!0,e.params.touchReleaseOnEdges&&(e.el.style.touchAction="auto"))}const U=(e,t)=>{const s=a(),{params:i,el:r,wrapperEl:n,device:l}=e,o=!!i.nested,d="on"===t?"addEventListener":"removeEventListener",c=t;s[d]("touchstart",e.onDocumentTouchStart,{passive:!1,capture:o}),r[d]("touchstart",e.onTouchStart,{passive:!1}),r[d]("pointerdown",e.onTouchStart,{passive:!1}),s[d]("touchmove",e.onTouchMove,{passive:!1,capture:o}),s[d]("pointermove",e.onTouchMove,{passive:!1,capture:o}),s[d]("touchend",e.onTouchEnd,{passive:!0}),s[d]("pointerup",e.onTouchEnd,{passive:!0}),s[d]("pointercancel",e.onTouchEnd,{passive:!0}),s[d]("touchcancel",e.onTouchEnd,{passive:!0}),s[d]("pointerout",e.onTouchEnd,{passive:!0}),s[d]("pointerleave",e.onTouchEnd,{passive:!0}),s[d]("contextmenu",e.onTouchEnd,{passive:!0}),(i.preventClicks||i.preventClicksPropagation)&&r[d]("click",e.onClick,!0),i.cssMode&&n[d]("scroll",e.onScroll),i.updateOnWindowResize?e[c](l.ios||l.android?"resize orientationchange observerUpdate":"resize observerUpdate",q,!0):e[c]("observerUpdate",q,!0),r[d]("load",e.onLoad,{capture:!0})};const K=(e,t)=>e.grid&&t.grid&&t.grid.rows>1;var Z={init:!0,direction:"horizontal",oneWayMovement:!1,swiperElementNodeName:"SWIPER-CONTAINER",touchEventsTarget:"wrapper",initialSlide:0,speed:300,cssMode:!1,updateOnWindowResize:!0,resizeObserver:!0,nested:!1,createElements:!1,eventsPrefix:"swiper",enabled:!0,focusableElements:"input, select, option, textarea, button, video, label",width:null,height:null,preventInteractionOnTransition:!1,userAgent:null,url:null,edgeSwipeDetection:!1,edgeSwipeThreshold:20,autoHeight:!1,setWrapperSize:!1,virtualTranslate:!1,effect:"slide",breakpoints:void 0,breakpointsBase:"window",spaceBetween:0,slidesPerView:1,slidesPerGroup:1,slidesPerGroupSkip:0,slidesPerGroupAuto:!1,centeredSlides:!1,centeredSlidesBounds:!1,slidesOffsetBefore:0,slidesOffsetAfter:0,normalizeSlideIndex:!0,centerInsufficientSlides:!1,watchOverflow:!0,roundLengths:!1,touchRatio:1,touchAngle:45,simulateTouch:!0,shortSwipes:!0,longSwipes:!0,longSwipesRatio:.5,longSwipesMs:300,followFinger:!0,allowTouchMove:!0,threshold:5,touchMoveStopPropagation:!1,touchStartPreventDefault:!0,touchStartForcePreventDefault:!1,touchReleaseOnEdges:!1,uniqueNavElements:!0,resistance:!0,resistanceRatio:.85,watchSlidesProgress:!1,grabCursor:!1,preventClicks:!0,preventClicksPropagation:!0,slideToClickedSlide:!1,loop:!1,loopAddBlankSlides:!0,loopAdditionalSlides:0,loopPreventsSliding:!0,rewind:!1,allowSlidePrev:!0,allowSlideNext:!0,swipeHandler:null,noSwiping:!0,noSwipingClass:"swiper-no-swiping",noSwipingSelector:null,passiveListeners:!0,maxBackfaceHiddenSlides:10,containerModifierClass:"swiper-",slideClass:"swiper-slide",slideBlankClass:"swiper-slide-blank",slideActiveClass:"swiper-slide-active",slideVisibleClass:"swiper-slide-visible",slideFullyVisibleClass:"swiper-slide-fully-visible",slideNextClass:"swiper-slide-next",slidePrevClass:"swiper-slide-prev",wrapperClass:"swiper-wrapper",lazyPreloaderClass:"swiper-lazy-preloader",lazyPreloadPrevNext:0,runCallbacksOnInit:!0,_emitClasses:!1};function Q(e,t){return function(s){void 0===s&&(s={});const a=Object.keys(s)[0],i=s[a];"object"==typeof i&&null!==i?(!0===e[a]&&(e[a]={enabled:!0}),"navigation"===a&&e[a]&&e[a].enabled&&!e[a].prevEl&&!e[a].nextEl&&(e[a].auto=!0),["pagination","scrollbar"].indexOf(a)>=0&&e[a]&&e[a].enabled&&!e[a].el&&(e[a].auto=!0),a in e&&"enabled"in i?("object"!=typeof e[a]||"enabled"in e[a]||(e[a].enabled=!0),e[a]||(e[a]={enabled:!1}),p(t,s)):p(t,s)):p(t,s)}}const J={eventsEmitter:z,update:D,translate:G,transition:{setTransition:function(e,t){const s=this;s.params.cssMode||(s.wrapperEl.style.transitionDuration=`${e}ms`,s.wrapperEl.style.transitionDelay=0===e?"0ms":""),s.emit("setTransition",e,t)},transitionStart:function(e,t){void 0===e&&(e=!0);const s=this,{params:a}=s;a.cssMode||(a.autoHeight&&s.updateAutoHeight(),N({swiper:s,runCallbacks:e,direction:t,step:"Start"}))},transitionEnd:function(e,t){void 0===e&&(e=!0);const s=this,{params:a}=s;s.animating=!1,a.cssMode||(s.setTransition(0),N({swiper:s,runCallbacks:e,direction:t,step:"End"}))}},slide:H,loop:X,grabCursor:{setGrabCursor:function(e){const t=this;if(!t.params.simulateTouch||t.params.watchOverflow&&t.isLocked||t.params.cssMode)return;const s="container"===t.params.touchEventsTarget?t.el:t.wrapperEl;t.isElement&&(t.__preventObserver__=!0),s.style.cursor="move",s.style.cursor=e?"grabbing":"grab",t.isElement&&requestAnimationFrame((()=>{t.__preventObserver__=!1}))},unsetGrabCursor:function(){const e=this;e.params.watchOverflow&&e.isLocked||e.params.cssMode||(e.isElement&&(e.__preventObserver__=!0),e["container"===e.params.touchEventsTarget?"el":"wrapperEl"].style.cursor="",e.isElement&&requestAnimationFrame((()=>{e.__preventObserver__=!1})))}},events:{attachEvents:function(){const e=this,{params:t}=e;e.onTouchStart=B.bind(e),e.onTouchMove=R.bind(e),e.onTouchEnd=F.bind(e),e.onDocumentTouchStart=W.bind(e),t.cssMode&&(e.onScroll=_.bind(e)),e.onClick=V.bind(e),e.onLoad=j.bind(e),U(e,"on")},detachEvents:function(){U(this,"off")}},breakpoints:{setBreakpoint:function(){const e=this,{realIndex:t,initialized:s,params:a,el:i}=e,r=a.breakpoints;if(!r||r&&0===Object.keys(r).length)return;const n=e.getBreakpoint(r,e.params.breakpointsBase,e.el);if(!n||e.currentBreakpoint===n)return;const l=(n in r?r[n]:void 0)||e.originalParams,o=K(e,a),d=K(e,l),c=a.enabled;o&&!d?(i.classList.remove(`${a.containerModifierClass}grid`,`${a.containerModifierClass}grid-column`),e.emitContainerClasses()):!o&&d&&(i.classList.add(`${a.containerModifierClass}grid`),(l.grid.fill&&"column"===l.grid.fill||!l.grid.fill&&"column"===a.grid.fill)&&i.classList.add(`${a.containerModifierClass}grid-column`),e.emitContainerClasses()),["navigation","pagination","scrollbar"].forEach((t=>{if(void 0===l[t])return;const s=a[t]&&a[t].enabled,i=l[t]&&l[t].enabled;s&&!i&&e[t].disable(),!s&&i&&e[t].enable()}));const u=l.direction&&l.direction!==a.direction,m=a.loop&&(l.slidesPerView!==a.slidesPerView||u),h=a.loop;u&&s&&e.changeDirection(),p(e.params,l);const f=e.params.enabled,g=e.params.loop;Object.assign(e,{allowTouchMove:e.params.allowTouchMove,allowSlideNext:e.params.allowSlideNext,allowSlidePrev:e.params.allowSlidePrev}),c&&!f?e.disable():!c&&f&&e.enable(),e.currentBreakpoint=n,e.emit("_beforeBreakpoint",l),s&&(m?(e.loopDestroy(),e.loopCreate(t),e.updateSlides()):!h&&g?(e.loopCreate(t),e.updateSlides()):h&&!g&&e.loopDestroy()),e.emit("breakpoint",l)},getBreakpoint:function(e,t,s){if(void 0===t&&(t="window"),!e||"container"===t&&!s)return;let a=!1;const i=r(),n="window"===t?i.innerHeight:s.clientHeight,l=Object.keys(e).map((e=>{if("string"==typeof e&&0===e.indexOf("@")){const t=parseFloat(e.substr(1));return{value:n*t,point:e}}return{value:e,point:e}}));l.sort(((e,t)=>parseInt(e.value,10)-parseInt(t.value,10)));for(let e=0;e<l.length;e+=1){const{point:r,value:n}=l[e];"window"===t?i.matchMedia(`(min-width: ${n}px)`).matches&&(a=r):n<=s.clientWidth&&(a=r)}return a||"max"}},checkOverflow:{checkOverflow:function(){const e=this,{isLocked:t,params:s}=e,{slidesOffsetBefore:a}=s;if(a){const t=e.slides.length-1,s=e.slidesGrid[t]+e.slidesSizesGrid[t]+2*a;e.isLocked=e.size>s}else e.isLocked=1===e.snapGrid.length;!0===s.allowSlideNext&&(e.allowSlideNext=!e.isLocked),!0===s.allowSlidePrev&&(e.allowSlidePrev=!e.isLocked),t&&t!==e.isLocked&&(e.isEnd=!1),t!==e.isLocked&&e.emit(e.isLocked?"lock":"unlock")}},classes:{addClasses:function(){const e=this,{classNames:t,params:s,rtl:a,el:i,device:r}=e,n=function(e,t){const s=[];return e.forEach((e=>{"object"==typeof e?Object.keys(e).forEach((a=>{e[a]&&s.push(t+a)})):"string"==typeof e&&s.push(t+e)})),s}(["initialized",s.direction,{"free-mode":e.params.freeMode&&s.freeMode.enabled},{autoheight:s.autoHeight},{rtl:a},{grid:s.grid&&s.grid.rows>1},{"grid-column":s.grid&&s.grid.rows>1&&"column"===s.grid.fill},{android:r.android},{ios:r.ios},{"css-mode":s.cssMode},{centered:s.cssMode&&s.centeredSlides},{"watch-progress":s.watchSlidesProgress}],s.containerModifierClass);t.push(...n),i.classList.add(...t),e.emitContainerClasses()},removeClasses:function(){const{el:e,classNames:t}=this;e.classList.remove(...t),this.emitContainerClasses()}}},ee={};class te{constructor(){let e,t;for(var s=arguments.length,i=new Array(s),r=0;r<s;r++)i[r]=arguments[r];1===i.length&&i[0].constructor&&"Object"===Object.prototype.toString.call(i[0]).slice(8,-1)?t=i[0]:[e,t]=i,t||(t={}),t=p({},t),e&&!t.el&&(t.el=e);const n=a();if(t.el&&"string"==typeof t.el&&n.querySelectorAll(t.el).length>1){const e=[];return n.querySelectorAll(t.el).forEach((s=>{const a=p({},t,{el:s});e.push(new te(a))})),e}const l=this;l.__swiper__=!0,l.support=L(),l.device=I({userAgent:t.userAgent}),l.browser=A(),l.eventsListeners={},l.eventsAnyListeners=[],l.modules=[...l.__modules__],t.modules&&Array.isArray(t.modules)&&l.modules.push(...t.modules);const o={};l.modules.forEach((e=>{e({params:t,swiper:l,extendParams:Q(t,o),on:l.on.bind(l),once:l.once.bind(l),off:l.off.bind(l),emit:l.emit.bind(l)})}));const d=p({},Z,o);return l.params=p({},d,ee,t),l.originalParams=p({},l.params),l.passedParams=p({},t),l.params&&l.params.on&&Object.keys(l.params.on).forEach((e=>{l.on(e,l.params.on[e])})),l.params&&l.params.onAny&&l.onAny(l.params.onAny),Object.assign(l,{enabled:l.params.enabled,el:e,classNames:[],slides:[],slidesGrid:[],snapGrid:[],slidesSizesGrid:[],isHorizontal:()=>"horizontal"===l.params.direction,isVertical:()=>"vertical"===l.params.direction,activeIndex:0,realIndex:0,isBeginning:!0,isEnd:!1,translate:0,previousTranslate:0,progress:0,velocity:0,animating:!1,cssOverflowAdjustment(){return Math.trunc(this.translate/2**23)*2**23},allowSlideNext:l.params.allowSlideNext,allowSlidePrev:l.params.allowSlidePrev,touchEventsData:{isTouched:void 0,isMoved:void 0,allowTouchCallbacks:void 0,touchStartTime:void 0,isScrolling:void 0,currentTranslate:void 0,startTranslate:void 0,allowThresholdMove:void 0,focusableElements:l.params.focusableElements,lastClickTime:0,clickTimeout:void 0,velocities:[],allowMomentumBounce:void 0,startMoving:void 0,pointerId:null,touchId:null},allowClick:!0,allowTouchMove:l.params.allowTouchMove,touches:{startX:0,startY:0,currentX:0,currentY:0,diff:0},imagesToLoad:[],imagesLoaded:0}),l.emit("_swiper"),l.params.init&&l.init(),l}getDirectionLabel(e){return this.isHorizontal()?e:{width:"height","margin-top":"margin-left","margin-bottom ":"margin-right","margin-left":"margin-top","margin-right":"margin-bottom","padding-left":"padding-top","padding-right":"padding-bottom",marginRight:"marginBottom"}[e]}getSlideIndex(e){const{slidesEl:t,params:s}=this,a=y(f(t,`.${s.slideClass}, swiper-slide`)[0]);return y(e)-a}getSlideIndexByData(e){return this.getSlideIndex(this.slides.filter((t=>1*t.getAttribute("data-swiper-slide-index")===e))[0])}recalcSlides(){const{slidesEl:e,params:t}=this;this.slides=f(e,`.${t.slideClass}, swiper-slide`)}enable(){const e=this;e.enabled||(e.enabled=!0,e.params.grabCursor&&e.setGrabCursor(),e.emit("enable"))}disable(){const e=this;e.enabled&&(e.enabled=!1,e.params.grabCursor&&e.unsetGrabCursor(),e.emit("disable"))}setProgress(e,t){const s=this;e=Math.min(Math.max(e,0),1);const a=s.minTranslate(),i=(s.maxTranslate()-a)*e+a;s.translateTo(i,void 0===t?0:t),s.updateActiveIndex(),s.updateSlidesClasses()}emitContainerClasses(){const e=this;if(!e.params._emitClasses||!e.el)return;const t=e.el.className.split(" ").filter((t=>0===t.indexOf("swiper")||0===t.indexOf(e.params.containerModifierClass)));e.emit("_containerClasses",t.join(" "))}getSlideClasses(e){const t=this;return t.destroyed?"":e.className.split(" ").filter((e=>0===e.indexOf("swiper-slide")||0===e.indexOf(t.params.slideClass))).join(" ")}emitSlidesClasses(){const e=this;if(!e.params._emitClasses||!e.el)return;const t=[];e.slides.forEach((s=>{const a=e.getSlideClasses(s);t.push({slideEl:s,classNames:a}),e.emit("_slideClass",s,a)})),e.emit("_slideClasses",t)}slidesPerViewDynamic(e,t){void 0===e&&(e="current"),void 0===t&&(t=!1);const{params:s,slides:a,slidesGrid:i,slidesSizesGrid:r,size:n,activeIndex:l}=this;let o=1;if("number"==typeof s.slidesPerView)return s.slidesPerView;if(s.centeredSlides){let e,t=a[l]?Math.ceil(a[l].swiperSlideSize):0;for(let s=l+1;s<a.length;s+=1)a[s]&&!e&&(t+=Math.ceil(a[s].swiperSlideSize),o+=1,t>n&&(e=!0));for(let s=l-1;s>=0;s-=1)a[s]&&!e&&(t+=a[s].swiperSlideSize,o+=1,t>n&&(e=!0))}else if("current"===e)for(let e=l+1;e<a.length;e+=1){(t?i[e]+r[e]-i[l]<n:i[e]-i[l]<n)&&(o+=1)}else for(let e=l-1;e>=0;e-=1){i[l]-i[e]<n&&(o+=1)}return o}update(){const e=this;if(!e||e.destroyed)return;const{snapGrid:t,params:s}=e;function a(){const t=e.rtlTranslate?-1*e.translate:e.translate,s=Math.min(Math.max(t,e.maxTranslate()),e.minTranslate());e.setTranslate(s),e.updateActiveIndex(),e.updateSlidesClasses()}let i;if(s.breakpoints&&e.setBreakpoint(),[...e.el.querySelectorAll('[loading="lazy"]')].forEach((t=>{t.complete&&$(e,t)})),e.updateSize(),e.updateSlides(),e.updateProgress(),e.updateSlidesClasses(),s.freeMode&&s.freeMode.enabled&&!s.cssMode)a(),s.autoHeight&&e.updateAutoHeight();else{if(("auto"===s.slidesPerView||s.slidesPerView>1)&&e.isEnd&&!s.centeredSlides){const t=e.virtual&&s.virtual.enabled?e.virtual.slides:e.slides;i=e.slideTo(t.length-1,0,!1,!0)}else i=e.slideTo(e.activeIndex,0,!1,!0);i||a()}s.watchOverflow&&t!==e.snapGrid&&e.checkOverflow(),e.emit("update")}changeDirection(e,t){void 0===t&&(t=!0);const s=this,a=s.params.direction;return e||(e="horizontal"===a?"vertical":"horizontal"),e===a||"horizontal"!==e&&"vertical"!==e||(s.el.classList.remove(`${s.params.containerModifierClass}${a}`),s.el.classList.add(`${s.params.containerModifierClass}${e}`),s.emitContainerClasses(),s.params.direction=e,s.slides.forEach((t=>{"vertical"===e?t.style.width="":t.style.height=""})),s.emit("changeDirection"),t&&s.update()),s}changeLanguageDirection(e){const t=this;t.rtl&&"rtl"===e||!t.rtl&&"ltr"===e||(t.rtl="rtl"===e,t.rtlTranslate="horizontal"===t.params.direction&&t.rtl,t.rtl?(t.el.classList.add(`${t.params.containerModifierClass}rtl`),t.el.dir="rtl"):(t.el.classList.remove(`${t.params.containerModifierClass}rtl`),t.el.dir="ltr"),t.update())}mount(e){const t=this;if(t.mounted)return!0;let s=e||t.params.el;if("string"==typeof s&&(s=document.querySelector(s)),!s)return!1;s.swiper=t,s.parentNode&&s.parentNode.host&&s.parentNode.host.nodeName===t.params.swiperElementNodeName.toUpperCase()&&(t.isElement=!0);const a=()=>`.${(t.params.wrapperClass||"").trim().split(" ").join(".")}`;let i=(()=>{if(s&&s.shadowRoot&&s.shadowRoot.querySelector){return s.shadowRoot.querySelector(a())}return f(s,a())[0]})();return!i&&t.params.createElements&&(i=v("div",t.params.wrapperClass),s.append(i),f(s,`.${t.params.slideClass}`).forEach((e=>{i.append(e)}))),Object.assign(t,{el:s,wrapperEl:i,slidesEl:t.isElement&&!s.parentNode.host.slideSlots?s.parentNode.host:i,hostEl:t.isElement?s.parentNode.host:s,mounted:!0,rtl:"rtl"===s.dir.toLowerCase()||"rtl"===b(s,"direction"),rtlTranslate:"horizontal"===t.params.direction&&("rtl"===s.dir.toLowerCase()||"rtl"===b(s,"direction")),wrongRTL:"-webkit-box"===b(i,"display")}),!0}init(e){const t=this;if(t.initialized)return t;if(!1===t.mount(e))return t;t.emit("beforeInit"),t.params.breakpoints&&t.setBreakpoint(),t.addClasses(),t.updateSize(),t.updateSlides(),t.params.watchOverflow&&t.checkOverflow(),t.params.grabCursor&&t.enabled&&t.setGrabCursor(),t.params.loop&&t.virtual&&t.params.virtual.enabled?t.slideTo(t.params.initialSlide+t.virtual.slidesBefore,0,t.params.runCallbacksOnInit,!1,!0):t.slideTo(t.params.initialSlide,0,t.params.runCallbacksOnInit,!1,!0),t.params.loop&&t.loopCreate(),t.attachEvents();const s=[...t.el.querySelectorAll('[loading="lazy"]')];return t.isElement&&s.push(...t.hostEl.querySelectorAll('[loading="lazy"]')),s.forEach((e=>{e.complete?$(t,e):e.addEventListener("load",(e=>{$(t,e.target)}))})),O(t),t.initialized=!0,O(t),t.emit("init"),t.emit("afterInit"),t}destroy(e,t){void 0===e&&(e=!0),void 0===t&&(t=!0);const s=this,{params:a,el:i,wrapperEl:r,slides:n}=s;return void 0===s.params||s.destroyed||(s.emit("beforeDestroy"),s.initialized=!1,s.detachEvents(),a.loop&&s.loopDestroy(),t&&(s.removeClasses(),i.removeAttribute("style"),r.removeAttribute("style"),n&&n.length&&n.forEach((e=>{e.classList.remove(a.slideVisibleClass,a.slideFullyVisibleClass,a.slideActiveClass,a.slideNextClass,a.slidePrevClass),e.removeAttribute("style"),e.removeAttribute("data-swiper-slide-index")}))),s.emit("destroy"),Object.keys(s.eventsListeners).forEach((e=>{s.off(e)})),!1!==e&&(s.el.swiper=null,function(e){const t=e;Object.keys(t).forEach((e=>{try{t[e]=null}catch(e){}try{delete t[e]}catch(e){}}))}(s)),s.destroyed=!0),null}static extendDefaults(e){p(ee,e)}static get extendedDefaults(){return ee}static get defaults(){return Z}static installModule(e){te.prototype.__modules__||(te.prototype.__modules__=[]);const t=te.prototype.__modules__;"function"==typeof e&&t.indexOf(e)<0&&t.push(e)}static use(e){return Array.isArray(e)?(e.forEach((e=>te.installModule(e))),te):(te.installModule(e),te)}}function se(e,t,s,a){return e.params.createElements&&Object.keys(a).forEach((i=>{if(!s[i]&&!0===s.auto){let r=f(e.el,`.${a[i]}`)[0];r||(r=v("div",a[i]),r.className=a[i],e.el.append(r)),s[i]=r,t[i]=r}})),s}function ae(e){return void 0===e&&(e=""),`.${e.trim().replace(/([\.:!+\/])/g,"\\$1").replace(/ /g,".")}`}function ie(e){const t=this,{params:s,slidesEl:a}=t;s.loop&&t.loopDestroy();const i=e=>{if("string"==typeof e){const t=document.createElement("div");t.innerHTML=e,a.append(t.children[0]),t.innerHTML=""}else a.append(e)};if("object"==typeof e&&"length"in e)for(let t=0;t<e.length;t+=1)e[t]&&i(e[t]);else i(e);t.recalcSlides(),s.loop&&t.loopCreate(),s.observer&&!t.isElement||t.update()}function re(e){const t=this,{params:s,activeIndex:a,slidesEl:i}=t;s.loop&&t.loopDestroy();let r=a+1;const n=e=>{if("string"==typeof e){const t=document.createElement("div");t.innerHTML=e,i.prepend(t.children[0]),t.innerHTML=""}else i.prepend(e)};if("object"==typeof e&&"length"in e){for(let t=0;t<e.length;t+=1)e[t]&&n(e[t]);r=a+e.length}else n(e);t.recalcSlides(),s.loop&&t.loopCreate(),s.observer&&!t.isElement||t.update(),t.slideTo(r,0,!1)}function ne(e,t){const s=this,{params:a,activeIndex:i,slidesEl:r}=s;let n=i;a.loop&&(n-=s.loopedSlides,s.loopDestroy(),s.recalcSlides());const l=s.slides.length;if(e<=0)return void s.prependSlide(t);if(e>=l)return void s.appendSlide(t);let o=n>e?n+1:n;const d=[];for(let t=l-1;t>=e;t-=1){const e=s.slides[t];e.remove(),d.unshift(e)}if("object"==typeof t&&"length"in t){for(let e=0;e<t.length;e+=1)t[e]&&r.append(t[e]);o=n>e?n+t.length:n}else r.append(t);for(let e=0;e<d.length;e+=1)r.append(d[e]);s.recalcSlides(),a.loop&&s.loopCreate(),a.observer&&!s.isElement||s.update(),a.loop?s.slideTo(o+s.loopedSlides,0,!1):s.slideTo(o,0,!1)}function le(e){const t=this,{params:s,activeIndex:a}=t;let i=a;s.loop&&(i-=t.loopedSlides,t.loopDestroy());let r,n=i;if("object"==typeof e&&"length"in e){for(let s=0;s<e.length;s+=1)r=e[s],t.slides[r]&&t.slides[r].remove(),r<n&&(n-=1);n=Math.max(n,0)}else r=e,t.slides[r]&&t.slides[r].remove(),r<n&&(n-=1),n=Math.max(n,0);t.recalcSlides(),s.loop&&t.loopCreate(),s.observer&&!t.isElement||t.update(),s.loop?t.slideTo(n+t.loopedSlides,0,!1):t.slideTo(n,0,!1)}function oe(){const e=this,t=[];for(let s=0;s<e.slides.length;s+=1)t.push(s);e.removeSlide(t)}function de(e){const{effect:t,swiper:s,on:a,setTranslate:i,setTransition:r,overwriteParams:n,perspective:l,recreateShadows:o,getEffectParams:d}=e;let c;a("beforeInit",(()=>{if(s.params.effect!==t)return;s.classNames.push(`${s.params.containerModifierClass}${t}`),l&&l()&&s.classNames.push(`${s.params.containerModifierClass}3d`);const e=n?n():{};Object.assign(s.params,e),Object.assign(s.originalParams,e)})),a("setTranslate",(()=>{s.params.effect===t&&i()})),a("setTransition",((e,a)=>{s.params.effect===t&&r(a)})),a("transitionEnd",(()=>{if(s.params.effect===t&&o){if(!d||!d().slideShadows)return;s.slides.forEach((e=>{e.querySelectorAll(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").forEach((e=>e.remove()))})),o()}})),a("virtualUpdate",(()=>{s.params.effect===t&&(s.slides.length||(c=!0),requestAnimationFrame((()=>{c&&s.slides&&s.slides.length&&(i(),c=!1)})))}))}function ce(e,t){const s=h(t);return s!==t&&(s.style.backfaceVisibility="hidden",s.style["-webkit-backface-visibility"]="hidden"),s}function pe(e){let{swiper:t,duration:s,transformElements:a,allSlides:i}=e;const{activeIndex:r}=t;if(t.params.virtualTranslate&&0!==s){let e,s=!1;e=i?a:a.filter((e=>{const s=e.classList.contains("swiper-slide-transform")?(e=>{if(!e.parentElement)return t.slides.filter((t=>t.shadowRoot&&t.shadowRoot===e.parentNode))[0];return e.parentElement})(e):e;return t.getSlideIndex(s)===r})),e.forEach((e=>{x(e,(()=>{if(s)return;if(!t||t.destroyed)return;s=!0,t.animating=!1;const e=new window.CustomEvent("transitionend",{bubbles:!0,cancelable:!0});t.wrapperEl.dispatchEvent(e)}))}))}}function ue(e,t,s){const a=`swiper-slide-shadow${s?`-${s}`:""}${e?` swiper-slide-shadow-${e}`:""}`,i=h(t);let r=i.querySelector(`.${a.split(" ").join(".")}`);return r||(r=v("div",a.split(" ")),i.append(r)),r}Object.keys(J).forEach((e=>{Object.keys(J[e]).forEach((t=>{te.prototype[t]=J[e][t]}))})),te.use([function(e){let{swiper:t,on:s,emit:a}=e;const i=r();let n=null,l=null;const o=()=>{t&&!t.destroyed&&t.initialized&&(a("beforeResize"),a("resize"))},d=()=>{t&&!t.destroyed&&t.initialized&&a("orientationchange")};s("init",(()=>{t.params.resizeObserver&&void 0!==i.ResizeObserver?t&&!t.destroyed&&t.initialized&&(n=new ResizeObserver((e=>{l=i.requestAnimationFrame((()=>{const{width:s,height:a}=t;let i=s,r=a;e.forEach((e=>{let{contentBoxSize:s,contentRect:a,target:n}=e;n&&n!==t.el||(i=a?a.width:(s[0]||s).inlineSize,r=a?a.height:(s[0]||s).blockSize)})),i===s&&r===a||o()}))})),n.observe(t.el)):(i.addEventListener("resize",o),i.addEventListener("orientationchange",d))})),s("destroy",(()=>{l&&i.cancelAnimationFrame(l),n&&n.unobserve&&t.el&&(n.unobserve(t.el),n=null),i.removeEventListener("resize",o),i.removeEventListener("orientationchange",d)}))},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;const n=[],l=r(),o=function(e,s){void 0===s&&(s={});const a=new(l.MutationObserver||l.WebkitMutationObserver)((e=>{if(t.__preventObserver__)return;if(1===e.length)return void i("observerUpdate",e[0]);const s=function(){i("observerUpdate",e[0])};l.requestAnimationFrame?l.requestAnimationFrame(s):l.setTimeout(s,0)}));a.observe(e,{attributes:void 0===s.attributes||s.attributes,childList:void 0===s.childList||s.childList,characterData:void 0===s.characterData||s.characterData}),n.push(a)};s({observer:!1,observeParents:!1,observeSlideChildren:!1}),a("init",(()=>{if(t.params.observer){if(t.params.observeParents){const e=E(t.hostEl);for(let t=0;t<e.length;t+=1)o(e[t])}o(t.hostEl,{childList:t.params.observeSlideChildren}),o(t.wrapperEl,{attributes:!1})}})),a("destroy",(()=>{n.forEach((e=>{e.disconnect()})),n.splice(0,n.length)}))}]);const me=[function(e){let t,{swiper:s,extendParams:i,on:r,emit:n}=e;i({virtual:{enabled:!1,slides:[],cache:!0,renderSlide:null,renderExternal:null,renderExternalUpdate:!0,addSlidesBefore:0,addSlidesAfter:0}});const l=a();s.virtual={cache:{},from:void 0,to:void 0,slides:[],offset:0,slidesGrid:[]};const o=l.createElement("div");function d(e,t){const a=s.params.virtual;if(a.cache&&s.virtual.cache[t])return s.virtual.cache[t];let i;return a.renderSlide?(i=a.renderSlide.call(s,e,t),"string"==typeof i&&(o.innerHTML=i,i=o.children[0])):i=s.isElement?v("swiper-slide"):v("div",s.params.slideClass),i.setAttribute("data-swiper-slide-index",t),a.renderSlide||(i.innerHTML=e),a.cache&&(s.virtual.cache[t]=i),i}function c(e){const{slidesPerView:t,slidesPerGroup:a,centeredSlides:i,loop:r}=s.params,{addSlidesBefore:l,addSlidesAfter:o}=s.params.virtual,{from:c,to:p,slides:u,slidesGrid:m,offset:h}=s.virtual;s.params.cssMode||s.updateActiveIndex();const g=s.activeIndex||0;let v,w,b;v=s.rtlTranslate?"right":s.isHorizontal()?"left":"top",i?(w=Math.floor(t/2)+a+o,b=Math.floor(t/2)+a+l):(w=t+(a-1)+o,b=(r?t:a)+l);let y=g-b,E=g+w;r||(y=Math.max(y,0),E=Math.min(E,u.length-1));let x=(s.slidesGrid[y]||0)-(s.slidesGrid[0]||0);function S(){s.updateSlides(),s.updateProgress(),s.updateSlidesClasses(),n("virtualUpdate")}if(r&&g>=b?(y-=b,i||(x+=s.slidesGrid[0])):r&&g<b&&(y=-b,i&&(x+=s.slidesGrid[0])),Object.assign(s.virtual,{from:y,to:E,offset:x,slidesGrid:s.slidesGrid,slidesBefore:b,slidesAfter:w}),c===y&&p===E&&!e)return s.slidesGrid!==m&&x!==h&&s.slides.forEach((e=>{e.style[v]=x-Math.abs(s.cssOverflowAdjustment())+"px"})),s.updateProgress(),void n("virtualUpdate");if(s.params.virtual.renderExternal)return s.params.virtual.renderExternal.call(s,{offset:x,from:y,to:E,slides:function(){const e=[];for(let t=y;t<=E;t+=1)e.push(u[t]);return e}()}),void(s.params.virtual.renderExternalUpdate?S():n("virtualUpdate"));const T=[],M=[],C=e=>{let t=e;return e<0?t=u.length+e:t>=u.length&&(t-=u.length),t};if(e)s.slides.filter((e=>e.matches(`.${s.params.slideClass}, swiper-slide`))).forEach((e=>{e.remove()}));else for(let e=c;e<=p;e+=1)if(e<y||e>E){const t=C(e);s.slides.filter((e=>e.matches(`.${s.params.slideClass}[data-swiper-slide-index="${t}"], swiper-slide[data-swiper-slide-index="${t}"]`))).forEach((e=>{e.remove()}))}const P=r?-u.length:0,L=r?2*u.length:u.length;for(let t=P;t<L;t+=1)if(t>=y&&t<=E){const s=C(t);void 0===p||e?M.push(s):(t>p&&M.push(s),t<c&&T.push(s))}if(M.forEach((e=>{s.slidesEl.append(d(u[e],e))})),r)for(let e=T.length-1;e>=0;e-=1){const t=T[e];s.slidesEl.prepend(d(u[t],t))}else T.sort(((e,t)=>t-e)),T.forEach((e=>{s.slidesEl.prepend(d(u[e],e))}));f(s.slidesEl,".swiper-slide, swiper-slide").forEach((e=>{e.style[v]=x-Math.abs(s.cssOverflowAdjustment())+"px"})),S()}r("beforeInit",(()=>{if(!s.params.virtual.enabled)return;let e;if(void 0===s.passedParams.virtual.slides){const t=[...s.slidesEl.children].filter((e=>e.matches(`.${s.params.slideClass}, swiper-slide`)));t&&t.length&&(s.virtual.slides=[...t],e=!0,t.forEach(((e,t)=>{e.setAttribute("data-swiper-slide-index",t),s.virtual.cache[t]=e,e.remove()})))}e||(s.virtual.slides=s.params.virtual.slides),s.classNames.push(`${s.params.containerModifierClass}virtual`),s.params.watchSlidesProgress=!0,s.originalParams.watchSlidesProgress=!0,c()})),r("setTranslate",(()=>{s.params.virtual.enabled&&(s.params.cssMode&&!s._immediateVirtual?(clearTimeout(t),t=setTimeout((()=>{c()}),100)):c())})),r("init update resize",(()=>{s.params.virtual.enabled&&s.params.cssMode&&u(s.wrapperEl,"--swiper-virtual-size",`${s.virtualSize}px`)})),Object.assign(s.virtual,{appendSlide:function(e){if("object"==typeof e&&"length"in e)for(let t=0;t<e.length;t+=1)e[t]&&s.virtual.slides.push(e[t]);else s.virtual.slides.push(e);c(!0)},prependSlide:function(e){const t=s.activeIndex;let a=t+1,i=1;if(Array.isArray(e)){for(let t=0;t<e.length;t+=1)e[t]&&s.virtual.slides.unshift(e[t]);a=t+e.length,i=e.length}else s.virtual.slides.unshift(e);if(s.params.virtual.cache){const e=s.virtual.cache,t={};Object.keys(e).forEach((s=>{const a=e[s],r=a.getAttribute("data-swiper-slide-index");r&&a.setAttribute("data-swiper-slide-index",parseInt(r,10)+i),t[parseInt(s,10)+i]=a})),s.virtual.cache=t}c(!0),s.slideTo(a,0)},removeSlide:function(e){if(null==e)return;let t=s.activeIndex;if(Array.isArray(e))for(let a=e.length-1;a>=0;a-=1)s.params.virtual.cache&&(delete s.virtual.cache[e[a]],Object.keys(s.virtual.cache).forEach((t=>{t>e&&(s.virtual.cache[t-1]=s.virtual.cache[t],s.virtual.cache[t-1].setAttribute("data-swiper-slide-index",t-1),delete s.virtual.cache[t])}))),s.virtual.slides.splice(e[a],1),e[a]<t&&(t-=1),t=Math.max(t,0);else s.params.virtual.cache&&(delete s.virtual.cache[e],Object.keys(s.virtual.cache).forEach((t=>{t>e&&(s.virtual.cache[t-1]=s.virtual.cache[t],s.virtual.cache[t-1].setAttribute("data-swiper-slide-index",t-1),delete s.virtual.cache[t])}))),s.virtual.slides.splice(e,1),e<t&&(t-=1),t=Math.max(t,0);c(!0),s.slideTo(t,0)},removeAllSlides:function(){s.virtual.slides=[],s.params.virtual.cache&&(s.virtual.cache={}),c(!0),s.slideTo(0,0)},update:c})},function(e){let{swiper:t,extendParams:s,on:i,emit:n}=e;const l=a(),o=r();function d(e){if(!t.enabled)return;const{rtlTranslate:s}=t;let a=e;a.originalEvent&&(a=a.originalEvent);const i=a.keyCode||a.charCode,r=t.params.keyboard.pageUpDown,d=r&&33===i,c=r&&34===i,p=37===i,u=39===i,m=38===i,h=40===i;if(!t.allowSlideNext&&(t.isHorizontal()&&u||t.isVertical()&&h||c))return!1;if(!t.allowSlidePrev&&(t.isHorizontal()&&p||t.isVertical()&&m||d))return!1;if(!(a.shiftKey||a.altKey||a.ctrlKey||a.metaKey||l.activeElement&&l.activeElement.nodeName&&("input"===l.activeElement.nodeName.toLowerCase()||"textarea"===l.activeElement.nodeName.toLowerCase()))){if(t.params.keyboard.onlyInViewport&&(d||c||p||u||m||h)){let e=!1;if(E(t.el,`.${t.params.slideClass}, swiper-slide`).length>0&&0===E(t.el,`.${t.params.slideActiveClass}`).length)return;const a=t.el,i=a.clientWidth,r=a.clientHeight,n=o.innerWidth,l=o.innerHeight,d=w(a);s&&(d.left-=a.scrollLeft);const c=[[d.left,d.top],[d.left+i,d.top],[d.left,d.top+r],[d.left+i,d.top+r]];for(let t=0;t<c.length;t+=1){const s=c[t];if(s[0]>=0&&s[0]<=n&&s[1]>=0&&s[1]<=l){if(0===s[0]&&0===s[1])continue;e=!0}}if(!e)return}t.isHorizontal()?((d||c||p||u)&&(a.preventDefault?a.preventDefault():a.returnValue=!1),((c||u)&&!s||(d||p)&&s)&&t.slideNext(),((d||p)&&!s||(c||u)&&s)&&t.slidePrev()):((d||c||m||h)&&(a.preventDefault?a.preventDefault():a.returnValue=!1),(c||h)&&t.slideNext(),(d||m)&&t.slidePrev()),n("keyPress",i)}}function c(){t.keyboard.enabled||(l.addEventListener("keydown",d),t.keyboard.enabled=!0)}function p(){t.keyboard.enabled&&(l.removeEventListener("keydown",d),t.keyboard.enabled=!1)}t.keyboard={enabled:!1},s({keyboard:{enabled:!1,onlyInViewport:!0,pageUpDown:!0}}),i("init",(()=>{t.params.keyboard.enabled&&c()})),i("destroy",(()=>{t.keyboard.enabled&&p()})),Object.assign(t.keyboard,{enable:c,disable:p})},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;const n=r();let d;s({mousewheel:{enabled:!1,releaseOnEdges:!1,invert:!1,forceToAxis:!1,sensitivity:1,eventsTarget:"container",thresholdDelta:null,thresholdTime:null,noMousewheelClass:"swiper-no-mousewheel"}}),t.mousewheel={enabled:!1};let c,p=o();const u=[];function m(){t.enabled&&(t.mouseEntered=!0)}function h(){t.enabled&&(t.mouseEntered=!1)}function f(e){return!(t.params.mousewheel.thresholdDelta&&e.delta<t.params.mousewheel.thresholdDelta)&&(!(t.params.mousewheel.thresholdTime&&o()-p<t.params.mousewheel.thresholdTime)&&(e.delta>=6&&o()-p<60||(e.direction<0?t.isEnd&&!t.params.loop||t.animating||(t.slideNext(),i("scroll",e.raw)):t.isBeginning&&!t.params.loop||t.animating||(t.slidePrev(),i("scroll",e.raw)),p=(new n.Date).getTime(),!1)))}function g(e){let s=e,a=!0;if(!t.enabled)return;if(e.target.closest(`.${t.params.mousewheel.noMousewheelClass}`))return;const r=t.params.mousewheel;t.params.cssMode&&s.preventDefault();let n=t.el;"container"!==t.params.mousewheel.eventsTarget&&(n=document.querySelector(t.params.mousewheel.eventsTarget));const p=n&&n.contains(s.target);if(!t.mouseEntered&&!p&&!r.releaseOnEdges)return!0;s.originalEvent&&(s=s.originalEvent);let m=0;const h=t.rtlTranslate?-1:1,g=function(e){let t=0,s=0,a=0,i=0;return"detail"in e&&(s=e.detail),"wheelDelta"in e&&(s=-e.wheelDelta/120),"wheelDeltaY"in e&&(s=-e.wheelDeltaY/120),"wheelDeltaX"in e&&(t=-e.wheelDeltaX/120),"axis"in e&&e.axis===e.HORIZONTAL_AXIS&&(t=s,s=0),a=10*t,i=10*s,"deltaY"in e&&(i=e.deltaY),"deltaX"in e&&(a=e.deltaX),e.shiftKey&&!a&&(a=i,i=0),(a||i)&&e.deltaMode&&(1===e.deltaMode?(a*=40,i*=40):(a*=800,i*=800)),a&&!t&&(t=a<1?-1:1),i&&!s&&(s=i<1?-1:1),{spinX:t,spinY:s,pixelX:a,pixelY:i}}(s);if(r.forceToAxis)if(t.isHorizontal()){if(!(Math.abs(g.pixelX)>Math.abs(g.pixelY)))return!0;m=-g.pixelX*h}else{if(!(Math.abs(g.pixelY)>Math.abs(g.pixelX)))return!0;m=-g.pixelY}else m=Math.abs(g.pixelX)>Math.abs(g.pixelY)?-g.pixelX*h:-g.pixelY;if(0===m)return!0;r.invert&&(m=-m);let v=t.getTranslate()+m*r.sensitivity;if(v>=t.minTranslate()&&(v=t.minTranslate()),v<=t.maxTranslate()&&(v=t.maxTranslate()),a=!!t.params.loop||!(v===t.minTranslate()||v===t.maxTranslate()),a&&t.params.nested&&s.stopPropagation(),t.params.freeMode&&t.params.freeMode.enabled){const e={time:o(),delta:Math.abs(m),direction:Math.sign(m)},a=c&&e.time<c.time+500&&e.delta<=c.delta&&e.direction===c.direction;if(!a){c=void 0;let n=t.getTranslate()+m*r.sensitivity;const o=t.isBeginning,p=t.isEnd;if(n>=t.minTranslate()&&(n=t.minTranslate()),n<=t.maxTranslate()&&(n=t.maxTranslate()),t.setTransition(0),t.setTranslate(n),t.updateProgress(),t.updateActiveIndex(),t.updateSlidesClasses(),(!o&&t.isBeginning||!p&&t.isEnd)&&t.updateSlidesClasses(),t.params.loop&&t.loopFix({direction:e.direction<0?"next":"prev",byMousewheel:!0}),t.params.freeMode.sticky){clearTimeout(d),d=void 0,u.length>=15&&u.shift();const s=u.length?u[u.length-1]:void 0,a=u[0];if(u.push(e),s&&(e.delta>s.delta||e.direction!==s.direction))u.splice(0);else if(u.length>=15&&e.time-a.time<500&&a.delta-e.delta>=1&&e.delta<=6){const s=m>0?.8:.2;c=e,u.splice(0),d=l((()=>{t.slideToClosest(t.params.speed,!0,void 0,s)}),0)}d||(d=l((()=>{c=e,u.splice(0),t.slideToClosest(t.params.speed,!0,void 0,.5)}),500))}if(a||i("scroll",s),t.params.autoplay&&t.params.autoplayDisableOnInteraction&&t.autoplay.stop(),r.releaseOnEdges&&(n===t.minTranslate()||n===t.maxTranslate()))return!0}}else{const s={time:o(),delta:Math.abs(m),direction:Math.sign(m),raw:e};u.length>=2&&u.shift();const a=u.length?u[u.length-1]:void 0;if(u.push(s),a?(s.direction!==a.direction||s.delta>a.delta||s.time>a.time+150)&&f(s):f(s),function(e){const s=t.params.mousewheel;if(e.direction<0){if(t.isEnd&&!t.params.loop&&s.releaseOnEdges)return!0}else if(t.isBeginning&&!t.params.loop&&s.releaseOnEdges)return!0;return!1}(s))return!0}return s.preventDefault?s.preventDefault():s.returnValue=!1,!1}function v(e){let s=t.el;"container"!==t.params.mousewheel.eventsTarget&&(s=document.querySelector(t.params.mousewheel.eventsTarget)),s[e]("mouseenter",m),s[e]("mouseleave",h),s[e]("wheel",g)}function w(){return t.params.cssMode?(t.wrapperEl.removeEventListener("wheel",g),!0):!t.mousewheel.enabled&&(v("addEventListener"),t.mousewheel.enabled=!0,!0)}function b(){return t.params.cssMode?(t.wrapperEl.addEventListener(event,g),!0):!!t.mousewheel.enabled&&(v("removeEventListener"),t.mousewheel.enabled=!1,!0)}a("init",(()=>{!t.params.mousewheel.enabled&&t.params.cssMode&&b(),t.params.mousewheel.enabled&&w()})),a("destroy",(()=>{t.params.cssMode&&w(),t.mousewheel.enabled&&b()})),Object.assign(t.mousewheel,{enable:w,disable:b})},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;function r(e){let s;return e&&"string"==typeof e&&t.isElement&&(s=t.el.querySelector(e),s)?s:(e&&("string"==typeof e&&(s=[...document.querySelectorAll(e)]),t.params.uniqueNavElements&&"string"==typeof e&&s.length>1&&1===t.el.querySelectorAll(e).length&&(s=t.el.querySelector(e))),e&&!s?e:s)}function n(e,s){const a=t.params.navigation;(e=T(e)).forEach((e=>{e&&(e.classList[s?"add":"remove"](...a.disabledClass.split(" ")),"BUTTON"===e.tagName&&(e.disabled=s),t.params.watchOverflow&&t.enabled&&e.classList[t.isLocked?"add":"remove"](a.lockClass))}))}function l(){const{nextEl:e,prevEl:s}=t.navigation;if(t.params.loop)return n(s,!1),void n(e,!1);n(s,t.isBeginning&&!t.params.rewind),n(e,t.isEnd&&!t.params.rewind)}function o(e){e.preventDefault(),(!t.isBeginning||t.params.loop||t.params.rewind)&&(t.slidePrev(),i("navigationPrev"))}function d(e){e.preventDefault(),(!t.isEnd||t.params.loop||t.params.rewind)&&(t.slideNext(),i("navigationNext"))}function c(){const e=t.params.navigation;if(t.params.navigation=se(t,t.originalParams.navigation,t.params.navigation,{nextEl:"swiper-button-next",prevEl:"swiper-button-prev"}),!e.nextEl&&!e.prevEl)return;let s=r(e.nextEl),a=r(e.prevEl);Object.assign(t.navigation,{nextEl:s,prevEl:a}),s=T(s),a=T(a);const i=(s,a)=>{s&&s.addEventListener("click","next"===a?d:o),!t.enabled&&s&&s.classList.add(...e.lockClass.split(" "))};s.forEach((e=>i(e,"next"))),a.forEach((e=>i(e,"prev")))}function p(){let{nextEl:e,prevEl:s}=t.navigation;e=T(e),s=T(s);const a=(e,s)=>{e.removeEventListener("click","next"===s?d:o),e.classList.remove(...t.params.navigation.disabledClass.split(" "))};e.forEach((e=>a(e,"next"))),s.forEach((e=>a(e,"prev")))}s({navigation:{nextEl:null,prevEl:null,hideOnClick:!1,disabledClass:"swiper-button-disabled",hiddenClass:"swiper-button-hidden",lockClass:"swiper-button-lock",navigationDisabledClass:"swiper-navigation-disabled"}}),t.navigation={nextEl:null,prevEl:null},a("init",(()=>{!1===t.params.navigation.enabled?u():(c(),l())})),a("toEdge fromEdge lock unlock",(()=>{l()})),a("destroy",(()=>{p()})),a("enable disable",(()=>{let{nextEl:e,prevEl:s}=t.navigation;e=T(e),s=T(s),t.enabled?l():[...e,...s].filter((e=>!!e)).forEach((e=>e.classList.add(t.params.navigation.lockClass)))})),a("click",((e,s)=>{let{nextEl:a,prevEl:r}=t.navigation;a=T(a),r=T(r);const n=s.target;if(t.params.navigation.hideOnClick&&!r.includes(n)&&!a.includes(n)){if(t.pagination&&t.params.pagination&&t.params.pagination.clickable&&(t.pagination.el===n||t.pagination.el.contains(n)))return;let e;a.length?e=a[0].classList.contains(t.params.navigation.hiddenClass):r.length&&(e=r[0].classList.contains(t.params.navigation.hiddenClass)),i(!0===e?"navigationShow":"navigationHide"),[...a,...r].filter((e=>!!e)).forEach((e=>e.classList.toggle(t.params.navigation.hiddenClass)))}}));const u=()=>{t.el.classList.add(...t.params.navigation.navigationDisabledClass.split(" ")),p()};Object.assign(t.navigation,{enable:()=>{t.el.classList.remove(...t.params.navigation.navigationDisabledClass.split(" ")),c(),l()},disable:u,update:l,init:c,destroy:p})},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;const r="swiper-pagination";let n;s({pagination:{el:null,bulletElement:"span",clickable:!1,hideOnClick:!1,renderBullet:null,renderProgressbar:null,renderFraction:null,renderCustom:null,progressbarOpposite:!1,type:"bullets",dynamicBullets:!1,dynamicMainBullets:1,formatFractionCurrent:e=>e,formatFractionTotal:e=>e,bulletClass:`${r}-bullet`,bulletActiveClass:`${r}-bullet-active`,modifierClass:`${r}-`,currentClass:`${r}-current`,totalClass:`${r}-total`,hiddenClass:`${r}-hidden`,progressbarFillClass:`${r}-progressbar-fill`,progressbarOppositeClass:`${r}-progressbar-opposite`,clickableClass:`${r}-clickable`,lockClass:`${r}-lock`,horizontalClass:`${r}-horizontal`,verticalClass:`${r}-vertical`,paginationDisabledClass:`${r}-disabled`}}),t.pagination={el:null,bullets:[]};let l=0;function o(){return!t.params.pagination.el||!t.pagination.el||Array.isArray(t.pagination.el)&&0===t.pagination.el.length}function d(e,s){const{bulletActiveClass:a}=t.params.pagination;e&&(e=e[("prev"===s?"previous":"next")+"ElementSibling"])&&(e.classList.add(`${a}-${s}`),(e=e[("prev"===s?"previous":"next")+"ElementSibling"])&&e.classList.add(`${a}-${s}-${s}`))}function c(e){const s=e.target.closest(ae(t.params.pagination.bulletClass));if(!s)return;e.preventDefault();const a=y(s)*t.params.slidesPerGroup;if(t.params.loop){if(t.realIndex===a)return;t.slideToLoop(a)}else t.slideTo(a)}function p(){const e=t.rtl,s=t.params.pagination;if(o())return;let a,r,c=t.pagination.el;c=T(c);const p=t.virtual&&t.params.virtual.enabled?t.virtual.slides.length:t.slides.length,u=t.params.loop?Math.ceil(p/t.params.slidesPerGroup):t.snapGrid.length;if(t.params.loop?(r=t.previousRealIndex||0,a=t.params.slidesPerGroup>1?Math.floor(t.realIndex/t.params.slidesPerGroup):t.realIndex):void 0!==t.snapIndex?(a=t.snapIndex,r=t.previousSnapIndex):(r=t.previousIndex||0,a=t.activeIndex||0),"bullets"===s.type&&t.pagination.bullets&&t.pagination.bullets.length>0){const i=t.pagination.bullets;let o,p,u;if(s.dynamicBullets&&(n=S(i[0],t.isHorizontal()?"width":"height",!0),c.forEach((e=>{e.style[t.isHorizontal()?"width":"height"]=n*(s.dynamicMainBullets+4)+"px"})),s.dynamicMainBullets>1&&void 0!==r&&(l+=a-(r||0),l>s.dynamicMainBullets-1?l=s.dynamicMainBullets-1:l<0&&(l=0)),o=Math.max(a-l,0),p=o+(Math.min(i.length,s.dynamicMainBullets)-1),u=(p+o)/2),i.forEach((e=>{const t=[...["","-next","-next-next","-prev","-prev-prev","-main"].map((e=>`${s.bulletActiveClass}${e}`))].map((e=>"string"==typeof e&&e.includes(" ")?e.split(" "):e)).flat();e.classList.remove(...t)})),c.length>1)i.forEach((e=>{const i=y(e);i===a?e.classList.add(...s.bulletActiveClass.split(" ")):t.isElement&&e.setAttribute("part","bullet"),s.dynamicBullets&&(i>=o&&i<=p&&e.classList.add(...`${s.bulletActiveClass}-main`.split(" ")),i===o&&d(e,"prev"),i===p&&d(e,"next"))}));else{const e=i[a];if(e&&e.classList.add(...s.bulletActiveClass.split(" ")),t.isElement&&i.forEach(((e,t)=>{e.setAttribute("part",t===a?"bullet-active":"bullet")})),s.dynamicBullets){const e=i[o],t=i[p];for(let e=o;e<=p;e+=1)i[e]&&i[e].classList.add(...`${s.bulletActiveClass}-main`.split(" "));d(e,"prev"),d(t,"next")}}if(s.dynamicBullets){const a=Math.min(i.length,s.dynamicMainBullets+4),r=(n*a-n)/2-u*n,l=e?"right":"left";i.forEach((e=>{e.style[t.isHorizontal()?l:"top"]=`${r}px`}))}}c.forEach(((e,r)=>{if("fraction"===s.type&&(e.querySelectorAll(ae(s.currentClass)).forEach((e=>{e.textContent=s.formatFractionCurrent(a+1)})),e.querySelectorAll(ae(s.totalClass)).forEach((e=>{e.textContent=s.formatFractionTotal(u)}))),"progressbar"===s.type){let i;i=s.progressbarOpposite?t.isHorizontal()?"vertical":"horizontal":t.isHorizontal()?"horizontal":"vertical";const r=(a+1)/u;let n=1,l=1;"horizontal"===i?n=r:l=r,e.querySelectorAll(ae(s.progressbarFillClass)).forEach((e=>{e.style.transform=`translate3d(0,0,0) scaleX(${n}) scaleY(${l})`,e.style.transitionDuration=`${t.params.speed}ms`}))}"custom"===s.type&&s.renderCustom?(e.innerHTML=s.renderCustom(t,a+1,u),0===r&&i("paginationRender",e)):(0===r&&i("paginationRender",e),i("paginationUpdate",e)),t.params.watchOverflow&&t.enabled&&e.classList[t.isLocked?"add":"remove"](s.lockClass)}))}function u(){const e=t.params.pagination;if(o())return;const s=t.virtual&&t.params.virtual.enabled?t.virtual.slides.length:t.grid&&t.params.grid.rows>1?t.slides.length/Math.ceil(t.params.grid.rows):t.slides.length;let a=t.pagination.el;a=T(a);let r="";if("bullets"===e.type){let a=t.params.loop?Math.ceil(s/t.params.slidesPerGroup):t.snapGrid.length;t.params.freeMode&&t.params.freeMode.enabled&&a>s&&(a=s);for(let s=0;s<a;s+=1)e.renderBullet?r+=e.renderBullet.call(t,s,e.bulletClass):r+=`<${e.bulletElement} ${t.isElement?'part="bullet"':""} class="${e.bulletClass}"></${e.bulletElement}>`}"fraction"===e.type&&(r=e.renderFraction?e.renderFraction.call(t,e.currentClass,e.totalClass):`<span class="${e.currentClass}"></span> / <span class="${e.totalClass}"></span>`),"progressbar"===e.type&&(r=e.renderProgressbar?e.renderProgressbar.call(t,e.progressbarFillClass):`<span class="${e.progressbarFillClass}"></span>`),t.pagination.bullets=[],a.forEach((s=>{"custom"!==e.type&&(s.innerHTML=r||""),"bullets"===e.type&&t.pagination.bullets.push(...s.querySelectorAll(ae(e.bulletClass)))})),"custom"!==e.type&&i("paginationRender",a[0])}function m(){t.params.pagination=se(t,t.originalParams.pagination,t.params.pagination,{el:"swiper-pagination"});const e=t.params.pagination;if(!e.el)return;let s;"string"==typeof e.el&&t.isElement&&(s=t.el.querySelector(e.el)),s||"string"!=typeof e.el||(s=[...document.querySelectorAll(e.el)]),s||(s=e.el),s&&0!==s.length&&(t.params.uniqueNavElements&&"string"==typeof e.el&&Array.isArray(s)&&s.length>1&&(s=[...t.el.querySelectorAll(e.el)],s.length>1&&(s=s.filter((e=>E(e,".swiper")[0]===t.el))[0])),Array.isArray(s)&&1===s.length&&(s=s[0]),Object.assign(t.pagination,{el:s}),s=T(s),s.forEach((s=>{"bullets"===e.type&&e.clickable&&s.classList.add(...(e.clickableClass||"").split(" ")),s.classList.add(e.modifierClass+e.type),s.classList.add(t.isHorizontal()?e.horizontalClass:e.verticalClass),"bullets"===e.type&&e.dynamicBullets&&(s.classList.add(`${e.modifierClass}${e.type}-dynamic`),l=0,e.dynamicMainBullets<1&&(e.dynamicMainBullets=1)),"progressbar"===e.type&&e.progressbarOpposite&&s.classList.add(e.progressbarOppositeClass),e.clickable&&s.addEventListener("click",c),t.enabled||s.classList.add(e.lockClass)})))}function h(){const e=t.params.pagination;if(o())return;let s=t.pagination.el;s&&(s=T(s),s.forEach((s=>{s.classList.remove(e.hiddenClass),s.classList.remove(e.modifierClass+e.type),s.classList.remove(t.isHorizontal()?e.horizontalClass:e.verticalClass),e.clickable&&(s.classList.remove(...(e.clickableClass||"").split(" ")),s.removeEventListener("click",c))}))),t.pagination.bullets&&t.pagination.bullets.forEach((t=>t.classList.remove(...e.bulletActiveClass.split(" "))))}a("changeDirection",(()=>{if(!t.pagination||!t.pagination.el)return;const e=t.params.pagination;let{el:s}=t.pagination;s=T(s),s.forEach((s=>{s.classList.remove(e.horizontalClass,e.verticalClass),s.classList.add(t.isHorizontal()?e.horizontalClass:e.verticalClass)}))})),a("init",(()=>{!1===t.params.pagination.enabled?f():(m(),u(),p())})),a("activeIndexChange",(()=>{void 0===t.snapIndex&&p()})),a("snapIndexChange",(()=>{p()})),a("snapGridLengthChange",(()=>{u(),p()})),a("destroy",(()=>{h()})),a("enable disable",(()=>{let{el:e}=t.pagination;e&&(e=T(e),e.forEach((e=>e.classList[t.enabled?"remove":"add"](t.params.pagination.lockClass))))})),a("lock unlock",(()=>{p()})),a("click",((e,s)=>{const a=s.target,r=T(t.pagination.el);if(t.params.pagination.el&&t.params.pagination.hideOnClick&&r&&r.length>0&&!a.classList.contains(t.params.pagination.bulletClass)){if(t.navigation&&(t.navigation.nextEl&&a===t.navigation.nextEl||t.navigation.prevEl&&a===t.navigation.prevEl))return;const e=r[0].classList.contains(t.params.pagination.hiddenClass);i(!0===e?"paginationShow":"paginationHide"),r.forEach((e=>e.classList.toggle(t.params.pagination.hiddenClass)))}}));const f=()=>{t.el.classList.add(t.params.pagination.paginationDisabledClass);let{el:e}=t.pagination;e&&(e=T(e),e.forEach((e=>e.classList.add(t.params.pagination.paginationDisabledClass)))),h()};Object.assign(t.pagination,{enable:()=>{t.el.classList.remove(t.params.pagination.paginationDisabledClass);let{el:e}=t.pagination;e&&(e=T(e),e.forEach((e=>e.classList.remove(t.params.pagination.paginationDisabledClass)))),m(),u(),p()},disable:f,render:u,update:p,init:m,destroy:h})},function(e){let{swiper:t,extendParams:s,on:i,emit:r}=e;const o=a();let d,c,p,u,m=!1,h=null,f=null;function g(){if(!t.params.scrollbar.el||!t.scrollbar.el)return;const{scrollbar:e,rtlTranslate:s}=t,{dragEl:a,el:i}=e,r=t.params.scrollbar,n=t.params.loop?t.progressLoop:t.progress;let l=c,o=(p-c)*n;s?(o=-o,o>0?(l=c-o,o=0):-o+c>p&&(l=p+o)):o<0?(l=c+o,o=0):o+c>p&&(l=p-o),t.isHorizontal()?(a.style.transform=`translate3d(${o}px, 0, 0)`,a.style.width=`${l}px`):(a.style.transform=`translate3d(0px, ${o}px, 0)`,a.style.height=`${l}px`),r.hide&&(clearTimeout(h),i.style.opacity=1,h=setTimeout((()=>{i.style.opacity=0,i.style.transitionDuration="400ms"}),1e3))}function b(){if(!t.params.scrollbar.el||!t.scrollbar.el)return;const{scrollbar:e}=t,{dragEl:s,el:a}=e;s.style.width="",s.style.height="",p=t.isHorizontal()?a.offsetWidth:a.offsetHeight,u=t.size/(t.virtualSize+t.params.slidesOffsetBefore-(t.params.centeredSlides?t.snapGrid[0]:0)),c="auto"===t.params.scrollbar.dragSize?p*u:parseInt(t.params.scrollbar.dragSize,10),t.isHorizontal()?s.style.width=`${c}px`:s.style.height=`${c}px`,a.style.display=u>=1?"none":"",t.params.scrollbar.hide&&(a.style.opacity=0),t.params.watchOverflow&&t.enabled&&e.el.classList[t.isLocked?"add":"remove"](t.params.scrollbar.lockClass)}function y(e){return t.isHorizontal()?e.clientX:e.clientY}function E(e){const{scrollbar:s,rtlTranslate:a}=t,{el:i}=s;let r;r=(y(e)-w(i)[t.isHorizontal()?"left":"top"]-(null!==d?d:c/2))/(p-c),r=Math.max(Math.min(r,1),0),a&&(r=1-r);const n=t.minTranslate()+(t.maxTranslate()-t.minTranslate())*r;t.updateProgress(n),t.setTranslate(n),t.updateActiveIndex(),t.updateSlidesClasses()}function x(e){const s=t.params.scrollbar,{scrollbar:a,wrapperEl:i}=t,{el:n,dragEl:l}=a;m=!0,d=e.target===l?y(e)-e.target.getBoundingClientRect()[t.isHorizontal()?"left":"top"]:null,e.preventDefault(),e.stopPropagation(),i.style.transitionDuration="100ms",l.style.transitionDuration="100ms",E(e),clearTimeout(f),n.style.transitionDuration="0ms",s.hide&&(n.style.opacity=1),t.params.cssMode&&(t.wrapperEl.style["scroll-snap-type"]="none"),r("scrollbarDragStart",e)}function S(e){const{scrollbar:s,wrapperEl:a}=t,{el:i,dragEl:n}=s;m&&(e.preventDefault?e.preventDefault():e.returnValue=!1,E(e),a.style.transitionDuration="0ms",i.style.transitionDuration="0ms",n.style.transitionDuration="0ms",r("scrollbarDragMove",e))}function M(e){const s=t.params.scrollbar,{scrollbar:a,wrapperEl:i}=t,{el:n}=a;m&&(m=!1,t.params.cssMode&&(t.wrapperEl.style["scroll-snap-type"]="",i.style.transitionDuration=""),s.hide&&(clearTimeout(f),f=l((()=>{n.style.opacity=0,n.style.transitionDuration="400ms"}),1e3)),r("scrollbarDragEnd",e),s.snapOnRelease&&t.slideToClosest())}function C(e){const{scrollbar:s,params:a}=t,i=s.el;if(!i)return;const r=i,n=!!a.passiveListeners&&{passive:!1,capture:!1},l=!!a.passiveListeners&&{passive:!0,capture:!1};if(!r)return;const d="on"===e?"addEventListener":"removeEventListener";r[d]("pointerdown",x,n),o[d]("pointermove",S,n),o[d]("pointerup",M,l)}function P(){const{scrollbar:e,el:s}=t;t.params.scrollbar=se(t,t.originalParams.scrollbar,t.params.scrollbar,{el:"swiper-scrollbar"});const a=t.params.scrollbar;if(!a.el)return;let i,r;if("string"==typeof a.el&&t.isElement&&(i=t.el.querySelector(a.el)),i||"string"!=typeof a.el)i||(i=a.el);else if(i=o.querySelectorAll(a.el),!i.length)return;t.params.uniqueNavElements&&"string"==typeof a.el&&i.length>1&&1===s.querySelectorAll(a.el).length&&(i=s.querySelector(a.el)),i.length>0&&(i=i[0]),i.classList.add(t.isHorizontal()?a.horizontalClass:a.verticalClass),i&&(r=i.querySelector(ae(t.params.scrollbar.dragClass)),r||(r=v("div",t.params.scrollbar.dragClass),i.append(r))),Object.assign(e,{el:i,dragEl:r}),a.draggable&&t.params.scrollbar.el&&t.scrollbar.el&&C("on"),i&&i.classList[t.enabled?"remove":"add"](...n(t.params.scrollbar.lockClass))}function L(){const e=t.params.scrollbar,s=t.scrollbar.el;s&&s.classList.remove(...n(t.isHorizontal()?e.horizontalClass:e.verticalClass)),t.params.scrollbar.el&&t.scrollbar.el&&C("off")}s({scrollbar:{el:null,dragSize:"auto",hide:!1,draggable:!1,snapOnRelease:!0,lockClass:"swiper-scrollbar-lock",dragClass:"swiper-scrollbar-drag",scrollbarDisabledClass:"swiper-scrollbar-disabled",horizontalClass:"swiper-scrollbar-horizontal",verticalClass:"swiper-scrollbar-vertical"}}),t.scrollbar={el:null,dragEl:null},i("changeDirection",(()=>{if(!t.scrollbar||!t.scrollbar.el)return;const e=t.params.scrollbar;let{el:s}=t.scrollbar;s=T(s),s.forEach((s=>{s.classList.remove(e.horizontalClass,e.verticalClass),s.classList.add(t.isHorizontal()?e.horizontalClass:e.verticalClass)}))})),i("init",(()=>{!1===t.params.scrollbar.enabled?I():(P(),b(),g())})),i("update resize observerUpdate lock unlock changeDirection",(()=>{b()})),i("setTranslate",(()=>{g()})),i("setTransition",((e,s)=>{!function(e){t.params.scrollbar.el&&t.scrollbar.el&&(t.scrollbar.dragEl.style.transitionDuration=`${e}ms`)}(s)})),i("enable disable",(()=>{const{el:e}=t.scrollbar;e&&e.classList[t.enabled?"remove":"add"](...n(t.params.scrollbar.lockClass))})),i("destroy",(()=>{L()}));const I=()=>{t.el.classList.add(...n(t.params.scrollbar.scrollbarDisabledClass)),t.scrollbar.el&&t.scrollbar.el.classList.add(...n(t.params.scrollbar.scrollbarDisabledClass)),L()};Object.assign(t.scrollbar,{enable:()=>{t.el.classList.remove(...n(t.params.scrollbar.scrollbarDisabledClass)),t.scrollbar.el&&t.scrollbar.el.classList.remove(...n(t.params.scrollbar.scrollbarDisabledClass)),P(),b(),g()},disable:I,updateSize:b,setTranslate:g,init:P,destroy:L})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({parallax:{enabled:!1}});const i="[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]",r=(e,s)=>{const{rtl:a}=t,i=a?-1:1,r=e.getAttribute("data-swiper-parallax")||"0";let n=e.getAttribute("data-swiper-parallax-x"),l=e.getAttribute("data-swiper-parallax-y");const o=e.getAttribute("data-swiper-parallax-scale"),d=e.getAttribute("data-swiper-parallax-opacity"),c=e.getAttribute("data-swiper-parallax-rotate");if(n||l?(n=n||"0",l=l||"0"):t.isHorizontal()?(n=r,l="0"):(l=r,n="0"),n=n.indexOf("%")>=0?parseInt(n,10)*s*i+"%":n*s*i+"px",l=l.indexOf("%")>=0?parseInt(l,10)*s+"%":l*s+"px",null!=d){const t=d-(d-1)*(1-Math.abs(s));e.style.opacity=t}let p=`translate3d(${n}, ${l}, 0px)`;if(null!=o){p+=` scale(${o-(o-1)*(1-Math.abs(s))})`}if(c&&null!=c){p+=` rotate(${c*s*-1}deg)`}e.style.transform=p},n=()=>{const{el:e,slides:s,progress:a,snapGrid:n,isElement:l}=t,o=f(e,i);t.isElement&&o.push(...f(t.hostEl,i)),o.forEach((e=>{r(e,a)})),s.forEach(((e,s)=>{let l=e.progress;t.params.slidesPerGroup>1&&"auto"!==t.params.slidesPerView&&(l+=Math.ceil(s/2)-a*(n.length-1)),l=Math.min(Math.max(l,-1),1),e.querySelectorAll(`${i}, [data-swiper-parallax-rotate]`).forEach((e=>{r(e,l)}))}))};a("beforeInit",(()=>{t.params.parallax.enabled&&(t.params.watchSlidesProgress=!0,t.originalParams.watchSlidesProgress=!0)})),a("init",(()=>{t.params.parallax.enabled&&n()})),a("setTranslate",(()=>{t.params.parallax.enabled&&n()})),a("setTransition",((e,s)=>{t.params.parallax.enabled&&function(e){void 0===e&&(e=t.params.speed);const{el:s,hostEl:a}=t,r=[...s.querySelectorAll(i)];t.isElement&&r.push(...a.querySelectorAll(i)),r.forEach((t=>{let s=parseInt(t.getAttribute("data-swiper-parallax-duration"),10)||e;0===e&&(s=0),t.style.transitionDuration=`${s}ms`}))}(s)}))},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;const n=r();s({zoom:{enabled:!1,maxRatio:3,minRatio:1,toggle:!0,containerClass:"swiper-zoom-container",zoomedSlideClass:"swiper-slide-zoomed"}}),t.zoom={enabled:!1};let l,o,c=1,p=!1;const u=[],m={originX:0,originY:0,slideEl:void 0,slideWidth:void 0,slideHeight:void 0,imageEl:void 0,imageWrapEl:void 0,maxRatio:3},h={isTouched:void 0,isMoved:void 0,currentX:void 0,currentY:void 0,minX:void 0,minY:void 0,maxX:void 0,maxY:void 0,width:void 0,height:void 0,startX:void 0,startY:void 0,touchesStart:{},touchesCurrent:{}},g={x:void 0,y:void 0,prevPositionX:void 0,prevPositionY:void 0,prevTime:void 0};let v=1;function b(){if(u.length<2)return 1;const e=u[0].pageX,t=u[0].pageY,s=u[1].pageX,a=u[1].pageY;return Math.sqrt((s-e)**2+(a-t)**2)}function y(e){const s=t.isElement?"swiper-slide":`.${t.params.slideClass}`;return!!e.target.matches(s)||t.slides.filter((t=>t.contains(e.target))).length>0}function x(e){if("mouse"===e.pointerType&&u.splice(0,u.length),!y(e))return;const s=t.params.zoom;if(l=!1,o=!1,u.push(e),!(u.length<2)){if(l=!0,m.scaleStart=b(),!m.slideEl){m.slideEl=e.target.closest(`.${t.params.slideClass}, swiper-slide`),m.slideEl||(m.slideEl=t.slides[t.activeIndex]);let a=m.slideEl.querySelector(`.${s.containerClass}`);if(a&&(a=a.querySelectorAll("picture, img, svg, canvas, .swiper-zoom-target")[0]),m.imageEl=a,m.imageWrapEl=a?E(m.imageEl,`.${s.containerClass}`)[0]:void 0,!m.imageWrapEl)return void(m.imageEl=void 0);m.maxRatio=m.imageWrapEl.getAttribute("data-swiper-zoom")||s.maxRatio}if(m.imageEl){const[e,t]=function(){if(u.length<2)return{x:null,y:null};const e=m.imageEl.getBoundingClientRect();return[(u[0].pageX+(u[1].pageX-u[0].pageX)/2-e.x-n.scrollX)/c,(u[0].pageY+(u[1].pageY-u[0].pageY)/2-e.y-n.scrollY)/c]}();m.originX=e,m.originY=t,m.imageEl.style.transitionDuration="0ms"}p=!0}}function S(e){if(!y(e))return;const s=t.params.zoom,a=t.zoom,i=u.findIndex((t=>t.pointerId===e.pointerId));i>=0&&(u[i]=e),u.length<2||(o=!0,m.scaleMove=b(),m.imageEl&&(a.scale=m.scaleMove/m.scaleStart*c,a.scale>m.maxRatio&&(a.scale=m.maxRatio-1+(a.scale-m.maxRatio+1)**.5),a.scale<s.minRatio&&(a.scale=s.minRatio+1-(s.minRatio-a.scale+1)**.5),m.imageEl.style.transform=`translate3d(0,0,0) scale(${a.scale})`))}function T(e){if(!y(e))return;if("mouse"===e.pointerType&&"pointerout"===e.type)return;const s=t.params.zoom,a=t.zoom,i=u.findIndex((t=>t.pointerId===e.pointerId));i>=0&&u.splice(i,1),l&&o&&(l=!1,o=!1,m.imageEl&&(a.scale=Math.max(Math.min(a.scale,m.maxRatio),s.minRatio),m.imageEl.style.transitionDuration=`${t.params.speed}ms`,m.imageEl.style.transform=`translate3d(0,0,0) scale(${a.scale})`,c=a.scale,p=!1,a.scale>1&&m.slideEl?m.slideEl.classList.add(`${s.zoomedSlideClass}`):a.scale<=1&&m.slideEl&&m.slideEl.classList.remove(`${s.zoomedSlideClass}`),1===a.scale&&(m.originX=0,m.originY=0,m.slideEl=void 0)))}function M(e){if(!y(e)||!function(e){const s=`.${t.params.zoom.containerClass}`;return!!e.target.matches(s)||[...t.hostEl.querySelectorAll(s)].filter((t=>t.contains(e.target))).length>0}(e))return;const s=t.zoom;if(!m.imageEl)return;if(!h.isTouched||!m.slideEl)return;h.isMoved||(h.width=m.imageEl.offsetWidth,h.height=m.imageEl.offsetHeight,h.startX=d(m.imageWrapEl,"x")||0,h.startY=d(m.imageWrapEl,"y")||0,m.slideWidth=m.slideEl.offsetWidth,m.slideHeight=m.slideEl.offsetHeight,m.imageWrapEl.style.transitionDuration="0ms");const a=h.width*s.scale,i=h.height*s.scale;if(a<m.slideWidth&&i<m.slideHeight)return;h.minX=Math.min(m.slideWidth/2-a/2,0),h.maxX=-h.minX,h.minY=Math.min(m.slideHeight/2-i/2,0),h.maxY=-h.minY,h.touchesCurrent.x=u.length>0?u[0].pageX:e.pageX,h.touchesCurrent.y=u.length>0?u[0].pageY:e.pageY;if(Math.max(Math.abs(h.touchesCurrent.x-h.touchesStart.x),Math.abs(h.touchesCurrent.y-h.touchesStart.y))>5&&(t.allowClick=!1),!h.isMoved&&!p){if(t.isHorizontal()&&(Math.floor(h.minX)===Math.floor(h.startX)&&h.touchesCurrent.x<h.touchesStart.x||Math.floor(h.maxX)===Math.floor(h.startX)&&h.touchesCurrent.x>h.touchesStart.x))return void(h.isTouched=!1);if(!t.isHorizontal()&&(Math.floor(h.minY)===Math.floor(h.startY)&&h.touchesCurrent.y<h.touchesStart.y||Math.floor(h.maxY)===Math.floor(h.startY)&&h.touchesCurrent.y>h.touchesStart.y))return void(h.isTouched=!1)}e.cancelable&&e.preventDefault(),e.stopPropagation(),h.isMoved=!0;const r=(s.scale-c)/(m.maxRatio-t.params.zoom.minRatio),{originX:n,originY:l}=m;h.currentX=h.touchesCurrent.x-h.touchesStart.x+h.startX+r*(h.width-2*n),h.currentY=h.touchesCurrent.y-h.touchesStart.y+h.startY+r*(h.height-2*l),h.currentX<h.minX&&(h.currentX=h.minX+1-(h.minX-h.currentX+1)**.8),h.currentX>h.maxX&&(h.currentX=h.maxX-1+(h.currentX-h.maxX+1)**.8),h.currentY<h.minY&&(h.currentY=h.minY+1-(h.minY-h.currentY+1)**.8),h.currentY>h.maxY&&(h.currentY=h.maxY-1+(h.currentY-h.maxY+1)**.8),g.prevPositionX||(g.prevPositionX=h.touchesCurrent.x),g.prevPositionY||(g.prevPositionY=h.touchesCurrent.y),g.prevTime||(g.prevTime=Date.now()),g.x=(h.touchesCurrent.x-g.prevPositionX)/(Date.now()-g.prevTime)/2,g.y=(h.touchesCurrent.y-g.prevPositionY)/(Date.now()-g.prevTime)/2,Math.abs(h.touchesCurrent.x-g.prevPositionX)<2&&(g.x=0),Math.abs(h.touchesCurrent.y-g.prevPositionY)<2&&(g.y=0),g.prevPositionX=h.touchesCurrent.x,g.prevPositionY=h.touchesCurrent.y,g.prevTime=Date.now(),m.imageWrapEl.style.transform=`translate3d(${h.currentX}px, ${h.currentY}px,0)`}function C(){const e=t.zoom;m.slideEl&&t.activeIndex!==t.slides.indexOf(m.slideEl)&&(m.imageEl&&(m.imageEl.style.transform="translate3d(0,0,0) scale(1)"),m.imageWrapEl&&(m.imageWrapEl.style.transform="translate3d(0,0,0)"),m.slideEl.classList.remove(`${t.params.zoom.zoomedSlideClass}`),e.scale=1,c=1,m.slideEl=void 0,m.imageEl=void 0,m.imageWrapEl=void 0,m.originX=0,m.originY=0)}function P(e){const s=t.zoom,a=t.params.zoom;if(!m.slideEl){e&&e.target&&(m.slideEl=e.target.closest(`.${t.params.slideClass}, swiper-slide`)),m.slideEl||(t.params.virtual&&t.params.virtual.enabled&&t.virtual?m.slideEl=f(t.slidesEl,`.${t.params.slideActiveClass}`)[0]:m.slideEl=t.slides[t.activeIndex]);let s=m.slideEl.querySelector(`.${a.containerClass}`);s&&(s=s.querySelectorAll("picture, img, svg, canvas, .swiper-zoom-target")[0]),m.imageEl=s,m.imageWrapEl=s?E(m.imageEl,`.${a.containerClass}`)[0]:void 0}if(!m.imageEl||!m.imageWrapEl)return;let i,r,l,o,d,p,u,g,v,b,y,x,S,T,M,C,P,L;t.params.cssMode&&(t.wrapperEl.style.overflow="hidden",t.wrapperEl.style.touchAction="none"),m.slideEl.classList.add(`${a.zoomedSlideClass}`),void 0===h.touchesStart.x&&e?(i=e.pageX,r=e.pageY):(i=h.touchesStart.x,r=h.touchesStart.y);const I="number"==typeof e?e:null;1===c&&I&&(i=void 0,r=void 0),s.scale=I||m.imageWrapEl.getAttribute("data-swiper-zoom")||a.maxRatio,c=I||m.imageWrapEl.getAttribute("data-swiper-zoom")||a.maxRatio,!e||1===c&&I?(u=0,g=0):(P=m.slideEl.offsetWidth,L=m.slideEl.offsetHeight,l=w(m.slideEl).left+n.scrollX,o=w(m.slideEl).top+n.scrollY,d=l+P/2-i,p=o+L/2-r,v=m.imageEl.offsetWidth,b=m.imageEl.offsetHeight,y=v*s.scale,x=b*s.scale,S=Math.min(P/2-y/2,0),T=Math.min(L/2-x/2,0),M=-S,C=-T,u=d*s.scale,g=p*s.scale,u<S&&(u=S),u>M&&(u=M),g<T&&(g=T),g>C&&(g=C)),I&&1===s.scale&&(m.originX=0,m.originY=0),m.imageWrapEl.style.transitionDuration="300ms",m.imageWrapEl.style.transform=`translate3d(${u}px, ${g}px,0)`,m.imageEl.style.transitionDuration="300ms",m.imageEl.style.transform=`translate3d(0,0,0) scale(${s.scale})`}function L(){const e=t.zoom,s=t.params.zoom;if(!m.slideEl){t.params.virtual&&t.params.virtual.enabled&&t.virtual?m.slideEl=f(t.slidesEl,`.${t.params.slideActiveClass}`)[0]:m.slideEl=t.slides[t.activeIndex];let e=m.slideEl.querySelector(`.${s.containerClass}`);e&&(e=e.querySelectorAll("picture, img, svg, canvas, .swiper-zoom-target")[0]),m.imageEl=e,m.imageWrapEl=e?E(m.imageEl,`.${s.containerClass}`)[0]:void 0}m.imageEl&&m.imageWrapEl&&(t.params.cssMode&&(t.wrapperEl.style.overflow="",t.wrapperEl.style.touchAction=""),e.scale=1,c=1,m.imageWrapEl.style.transitionDuration="300ms",m.imageWrapEl.style.transform="translate3d(0,0,0)",m.imageEl.style.transitionDuration="300ms",m.imageEl.style.transform="translate3d(0,0,0) scale(1)",m.slideEl.classList.remove(`${s.zoomedSlideClass}`),m.slideEl=void 0,m.originX=0,m.originY=0)}function I(e){const s=t.zoom;s.scale&&1!==s.scale?L():P(e)}function A(){return{passiveListener:!!t.params.passiveListeners&&{passive:!0,capture:!1},activeListenerWithCapture:!t.params.passiveListeners||{passive:!1,capture:!0}}}function z(){const e=t.zoom;if(e.enabled)return;e.enabled=!0;const{passiveListener:s,activeListenerWithCapture:a}=A();t.wrapperEl.addEventListener("pointerdown",x,s),t.wrapperEl.addEventListener("pointermove",S,a),["pointerup","pointercancel","pointerout"].forEach((e=>{t.wrapperEl.addEventListener(e,T,s)})),t.wrapperEl.addEventListener("pointermove",M,a)}function $(){const e=t.zoom;if(!e.enabled)return;e.enabled=!1;const{passiveListener:s,activeListenerWithCapture:a}=A();t.wrapperEl.removeEventListener("pointerdown",x,s),t.wrapperEl.removeEventListener("pointermove",S,a),["pointerup","pointercancel","pointerout"].forEach((e=>{t.wrapperEl.removeEventListener(e,T,s)})),t.wrapperEl.removeEventListener("pointermove",M,a)}Object.defineProperty(t.zoom,"scale",{get:()=>v,set(e){if(v!==e){const t=m.imageEl,s=m.slideEl;i("zoomChange",e,t,s)}v=e}}),a("init",(()=>{t.params.zoom.enabled&&z()})),a("destroy",(()=>{$()})),a("touchStart",((e,s)=>{t.zoom.enabled&&function(e){const s=t.device;if(!m.imageEl)return;if(h.isTouched)return;s.android&&e.cancelable&&e.preventDefault(),h.isTouched=!0;const a=u.length>0?u[0]:e;h.touchesStart.x=a.pageX,h.touchesStart.y=a.pageY}(s)})),a("touchEnd",((e,s)=>{t.zoom.enabled&&function(){const e=t.zoom;if(!m.imageEl)return;if(!h.isTouched||!h.isMoved)return h.isTouched=!1,void(h.isMoved=!1);h.isTouched=!1,h.isMoved=!1;let s=300,a=300;const i=g.x*s,r=h.currentX+i,n=g.y*a,l=h.currentY+n;0!==g.x&&(s=Math.abs((r-h.currentX)/g.x)),0!==g.y&&(a=Math.abs((l-h.currentY)/g.y));const o=Math.max(s,a);h.currentX=r,h.currentY=l;const d=h.width*e.scale,c=h.height*e.scale;h.minX=Math.min(m.slideWidth/2-d/2,0),h.maxX=-h.minX,h.minY=Math.min(m.slideHeight/2-c/2,0),h.maxY=-h.minY,h.currentX=Math.max(Math.min(h.currentX,h.maxX),h.minX),h.currentY=Math.max(Math.min(h.currentY,h.maxY),h.minY),m.imageWrapEl.style.transitionDuration=`${o}ms`,m.imageWrapEl.style.transform=`translate3d(${h.currentX}px, ${h.currentY}px,0)`}()})),a("doubleTap",((e,s)=>{!t.animating&&t.params.zoom.enabled&&t.zoom.enabled&&t.params.zoom.toggle&&I(s)})),a("transitionEnd",(()=>{t.zoom.enabled&&t.params.zoom.enabled&&C()})),a("slideChange",(()=>{t.zoom.enabled&&t.params.zoom.enabled&&t.params.cssMode&&C()})),Object.assign(t.zoom,{enable:z,disable:$,in:P,out:L,toggle:I})},function(e){let{swiper:t,extendParams:s,on:a}=e;function i(e,t){const s=function(){let e,t,s;return(a,i)=>{for(t=-1,e=a.length;e-t>1;)s=e+t>>1,a[s]<=i?t=s:e=s;return e}}();let a,i;return this.x=e,this.y=t,this.lastIndex=e.length-1,this.interpolate=function(e){return e?(i=s(this.x,e),a=i-1,(e-this.x[a])*(this.y[i]-this.y[a])/(this.x[i]-this.x[a])+this.y[a]):0},this}function r(){t.controller.control&&t.controller.spline&&(t.controller.spline=void 0,delete t.controller.spline)}s({controller:{control:void 0,inverse:!1,by:"slide"}}),t.controller={control:void 0},a("beforeInit",(()=>{if("undefined"!=typeof window&&("string"==typeof t.params.controller.control||t.params.controller.control instanceof HTMLElement)){const e=document.querySelector(t.params.controller.control);if(e&&e.swiper)t.controller.control=e.swiper;else if(e){const s=a=>{t.controller.control=a.detail[0],t.update(),e.removeEventListener("init",s)};e.addEventListener("init",s)}}else t.controller.control=t.params.controller.control})),a("update",(()=>{r()})),a("resize",(()=>{r()})),a("observerUpdate",(()=>{r()})),a("setTranslate",((e,s,a)=>{t.controller.control&&!t.controller.control.destroyed&&t.controller.setTranslate(s,a)})),a("setTransition",((e,s,a)=>{t.controller.control&&!t.controller.control.destroyed&&t.controller.setTransition(s,a)})),Object.assign(t.controller,{setTranslate:function(e,s){const a=t.controller.control;let r,n;const l=t.constructor;function o(e){if(e.destroyed)return;const s=t.rtlTranslate?-t.translate:t.translate;"slide"===t.params.controller.by&&(!function(e){t.controller.spline=t.params.loop?new i(t.slidesGrid,e.slidesGrid):new i(t.snapGrid,e.snapGrid)}(e),n=-t.controller.spline.interpolate(-s)),n&&"container"!==t.params.controller.by||(r=(e.maxTranslate()-e.minTranslate())/(t.maxTranslate()-t.minTranslate()),!Number.isNaN(r)&&Number.isFinite(r)||(r=1),n=(s-t.minTranslate())*r+e.minTranslate()),t.params.controller.inverse&&(n=e.maxTranslate()-n),e.updateProgress(n),e.setTranslate(n,t),e.updateActiveIndex(),e.updateSlidesClasses()}if(Array.isArray(a))for(let e=0;e<a.length;e+=1)a[e]!==s&&a[e]instanceof l&&o(a[e]);else a instanceof l&&s!==a&&o(a)},setTransition:function(e,s){const a=t.constructor,i=t.controller.control;let r;function n(s){s.destroyed||(s.setTransition(e,t),0!==e&&(s.transitionStart(),s.params.autoHeight&&l((()=>{s.updateAutoHeight()})),x(s.wrapperEl,(()=>{i&&s.transitionEnd()}))))}if(Array.isArray(i))for(r=0;r<i.length;r+=1)i[r]!==s&&i[r]instanceof a&&n(i[r]);else i instanceof a&&s!==i&&n(i)}})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({a11y:{enabled:!0,notificationClass:"swiper-notification",prevSlideMessage:"Previous slide",nextSlideMessage:"Next slide",firstSlideMessage:"This is the first slide",lastSlideMessage:"This is the last slide",paginationBulletMessage:"Go to slide {{index}}",slideLabelMessage:"{{index}} / {{slidesLength}}",containerMessage:null,containerRoleDescriptionMessage:null,itemRoleDescriptionMessage:null,slideRole:"group",id:null}}),t.a11y={clicked:!1};let i=null;function r(e){const t=i;0!==t.length&&(t.innerHTML="",t.innerHTML=e)}function n(e){(e=T(e)).forEach((e=>{e.setAttribute("tabIndex","0")}))}function l(e){(e=T(e)).forEach((e=>{e.setAttribute("tabIndex","-1")}))}function o(e,t){(e=T(e)).forEach((e=>{e.setAttribute("role",t)}))}function d(e,t){(e=T(e)).forEach((e=>{e.setAttribute("aria-roledescription",t)}))}function c(e,t){(e=T(e)).forEach((e=>{e.setAttribute("aria-label",t)}))}function p(e){(e=T(e)).forEach((e=>{e.setAttribute("aria-disabled",!0)}))}function u(e){(e=T(e)).forEach((e=>{e.setAttribute("aria-disabled",!1)}))}function m(e){if(13!==e.keyCode&&32!==e.keyCode)return;const s=t.params.a11y,a=e.target;t.pagination&&t.pagination.el&&(a===t.pagination.el||t.pagination.el.contains(e.target))&&!e.target.matches(ae(t.params.pagination.bulletClass))||(t.navigation&&t.navigation.nextEl&&a===t.navigation.nextEl&&(t.isEnd&&!t.params.loop||t.slideNext(),t.isEnd?r(s.lastSlideMessage):r(s.nextSlideMessage)),t.navigation&&t.navigation.prevEl&&a===t.navigation.prevEl&&(t.isBeginning&&!t.params.loop||t.slidePrev(),t.isBeginning?r(s.firstSlideMessage):r(s.prevSlideMessage)),t.pagination&&a.matches(ae(t.params.pagination.bulletClass))&&a.click())}function h(){return t.pagination&&t.pagination.bullets&&t.pagination.bullets.length}function f(){return h()&&t.params.pagination.clickable}const g=(e,t,s)=>{n(e),"BUTTON"!==e.tagName&&(o(e,"button"),e.addEventListener("keydown",m)),c(e,s),function(e,t){(e=T(e)).forEach((e=>{e.setAttribute("aria-controls",t)}))}(e,t)},w=()=>{t.a11y.clicked=!0},b=()=>{requestAnimationFrame((()=>{requestAnimationFrame((()=>{t.destroyed||(t.a11y.clicked=!1)}))}))},E=e=>{if(t.a11y.clicked)return;const s=e.target.closest(`.${t.params.slideClass}, swiper-slide`);if(!s||!t.slides.includes(s))return;const a=t.slides.indexOf(s)===t.activeIndex,i=t.params.watchSlidesProgress&&t.visibleSlides&&t.visibleSlides.includes(s);a||i||e.sourceCapabilities&&e.sourceCapabilities.firesTouchEvents||(t.isHorizontal()?t.el.scrollLeft=0:t.el.scrollTop=0,t.slideTo(t.slides.indexOf(s),0))},x=()=>{const e=t.params.a11y;e.itemRoleDescriptionMessage&&d(t.slides,e.itemRoleDescriptionMessage),e.slideRole&&o(t.slides,e.slideRole);const s=t.slides.length;e.slideLabelMessage&&t.slides.forEach(((a,i)=>{const r=t.params.loop?parseInt(a.getAttribute("data-swiper-slide-index"),10):i;c(a,e.slideLabelMessage.replace(/\{\{index\}\}/,r+1).replace(/\{\{slidesLength\}\}/,s))}))},S=()=>{const e=t.params.a11y;t.el.append(i);const s=t.el;e.containerRoleDescriptionMessage&&d(s,e.containerRoleDescriptionMessage),e.containerMessage&&c(s,e.containerMessage);const a=t.wrapperEl,r=e.id||a.getAttribute("id")||`swiper-wrapper-${n=16,void 0===n&&(n=16),"x".repeat(n).replace(/x/g,(()=>Math.round(16*Math.random()).toString(16)))}`;var n;const l=t.params.autoplay&&t.params.autoplay.enabled?"off":"polite";var o;o=r,T(a).forEach((e=>{e.setAttribute("id",o)})),function(e,t){(e=T(e)).forEach((e=>{e.setAttribute("aria-live",t)}))}(a,l),x();let{nextEl:p,prevEl:u}=t.navigation?t.navigation:{};if(p=T(p),u=T(u),p&&p.forEach((t=>g(t,r,e.nextSlideMessage))),u&&u.forEach((t=>g(t,r,e.prevSlideMessage))),f()){T(t.pagination.el).forEach((e=>{e.addEventListener("keydown",m)}))}t.el.addEventListener("focus",E,!0),t.el.addEventListener("pointerdown",w,!0),t.el.addEventListener("pointerup",b,!0)};a("beforeInit",(()=>{i=v("span",t.params.a11y.notificationClass),i.setAttribute("aria-live","assertive"),i.setAttribute("aria-atomic","true")})),a("afterInit",(()=>{t.params.a11y.enabled&&S()})),a("slidesLengthChange snapGridLengthChange slidesGridLengthChange",(()=>{t.params.a11y.enabled&&x()})),a("fromEdge toEdge afterInit lock unlock",(()=>{t.params.a11y.enabled&&function(){if(t.params.loop||t.params.rewind||!t.navigation)return;const{nextEl:e,prevEl:s}=t.navigation;s&&(t.isBeginning?(p(s),l(s)):(u(s),n(s))),e&&(t.isEnd?(p(e),l(e)):(u(e),n(e)))}()})),a("paginationUpdate",(()=>{t.params.a11y.enabled&&function(){const e=t.params.a11y;h()&&t.pagination.bullets.forEach((s=>{t.params.pagination.clickable&&(n(s),t.params.pagination.renderBullet||(o(s,"button"),c(s,e.paginationBulletMessage.replace(/\{\{index\}\}/,y(s)+1)))),s.matches(ae(t.params.pagination.bulletActiveClass))?s.setAttribute("aria-current","true"):s.removeAttribute("aria-current")}))}()})),a("destroy",(()=>{t.params.a11y.enabled&&function(){i&&i.remove();let{nextEl:e,prevEl:s}=t.navigation?t.navigation:{};e=T(e),s=T(s),e&&e.forEach((e=>e.removeEventListener("keydown",m))),s&&s.forEach((e=>e.removeEventListener("keydown",m))),f()&&T(t.pagination.el).forEach((e=>{e.removeEventListener("keydown",m)}));t.el.removeEventListener("focus",E,!0),t.el.removeEventListener("pointerdown",w,!0),t.el.removeEventListener("pointerup",b,!0)}()}))},function(e){let{swiper:t,extendParams:s,on:a}=e;s({history:{enabled:!1,root:"",replaceState:!1,key:"slides",keepQuery:!1}});let i=!1,n={};const l=e=>e.toString().replace(/\s+/g,"-").replace(/[^\w-]+/g,"").replace(/--+/g,"-").replace(/^-+/,"").replace(/-+$/,""),o=e=>{const t=r();let s;s=e?new URL(e):t.location;const a=s.pathname.slice(1).split("/").filter((e=>""!==e)),i=a.length;return{key:a[i-2],value:a[i-1]}},d=(e,s)=>{const a=r();if(!i||!t.params.history.enabled)return;let n;n=t.params.url?new URL(t.params.url):a.location;const o=t.slides[s];let d=l(o.getAttribute("data-history"));if(t.params.history.root.length>0){let s=t.params.history.root;"/"===s[s.length-1]&&(s=s.slice(0,s.length-1)),d=`${s}/${e?`${e}/`:""}${d}`}else n.pathname.includes(e)||(d=`${e?`${e}/`:""}${d}`);t.params.history.keepQuery&&(d+=n.search);const c=a.history.state;c&&c.value===d||(t.params.history.replaceState?a.history.replaceState({value:d},null,d):a.history.pushState({value:d},null,d))},c=(e,s,a)=>{if(s)for(let i=0,r=t.slides.length;i<r;i+=1){const r=t.slides[i];if(l(r.getAttribute("data-history"))===s){const s=t.getSlideIndex(r);t.slideTo(s,e,a)}}else t.slideTo(0,e,a)},p=()=>{n=o(t.params.url),c(t.params.speed,n.value,!1)};a("init",(()=>{t.params.history.enabled&&(()=>{const e=r();if(t.params.history){if(!e.history||!e.history.pushState)return t.params.history.enabled=!1,void(t.params.hashNavigation.enabled=!0);i=!0,n=o(t.params.url),n.key||n.value?(c(0,n.value,t.params.runCallbacksOnInit),t.params.history.replaceState||e.addEventListener("popstate",p)):t.params.history.replaceState||e.addEventListener("popstate",p)}})()})),a("destroy",(()=>{t.params.history.enabled&&(()=>{const e=r();t.params.history.replaceState||e.removeEventListener("popstate",p)})()})),a("transitionEnd _freeModeNoMomentumRelease",(()=>{i&&d(t.params.history.key,t.activeIndex)})),a("slideChange",(()=>{i&&t.params.cssMode&&d(t.params.history.key,t.activeIndex)}))},function(e){let{swiper:t,extendParams:s,emit:i,on:n}=e,l=!1;const o=a(),d=r();s({hashNavigation:{enabled:!1,replaceState:!1,watchState:!1,getSlideIndex(e,s){if(t.virtual&&t.params.virtual.enabled){const e=t.slides.filter((e=>e.getAttribute("data-hash")===s))[0];if(!e)return 0;return parseInt(e.getAttribute("data-swiper-slide-index"),10)}return t.getSlideIndex(f(t.slidesEl,`.${t.params.slideClass}[data-hash="${s}"], swiper-slide[data-hash="${s}"]`)[0])}}});const c=()=>{i("hashChange");const e=o.location.hash.replace("#",""),s=t.virtual&&t.params.virtual.enabled?t.slidesEl.querySelector(`[data-swiper-slide-index="${t.activeIndex}"]`):t.slides[t.activeIndex];if(e!==(s?s.getAttribute("data-hash"):"")){const s=t.params.hashNavigation.getSlideIndex(t,e);if(void 0===s||Number.isNaN(s))return;t.slideTo(s)}},p=()=>{if(!l||!t.params.hashNavigation.enabled)return;const e=t.virtual&&t.params.virtual.enabled?t.slidesEl.querySelector(`[data-swiper-slide-index="${t.activeIndex}"]`):t.slides[t.activeIndex],s=e?e.getAttribute("data-hash")||e.getAttribute("data-history"):"";t.params.hashNavigation.replaceState&&d.history&&d.history.replaceState?(d.history.replaceState(null,null,`#${s}`||""),i("hashSet")):(o.location.hash=s||"",i("hashSet"))};n("init",(()=>{t.params.hashNavigation.enabled&&(()=>{if(!t.params.hashNavigation.enabled||t.params.history&&t.params.history.enabled)return;l=!0;const e=o.location.hash.replace("#","");if(e){const s=0,a=t.params.hashNavigation.getSlideIndex(t,e);t.slideTo(a||0,s,t.params.runCallbacksOnInit,!0)}t.params.hashNavigation.watchState&&d.addEventListener("hashchange",c)})()})),n("destroy",(()=>{t.params.hashNavigation.enabled&&t.params.hashNavigation.watchState&&d.removeEventListener("hashchange",c)})),n("transitionEnd _freeModeNoMomentumRelease",(()=>{l&&p()})),n("slideChange",(()=>{l&&t.params.cssMode&&p()}))},function(e){let t,s,{swiper:i,extendParams:r,on:n,emit:l,params:o}=e;i.autoplay={running:!1,paused:!1,timeLeft:0},r({autoplay:{enabled:!1,delay:3e3,waitForTransition:!0,disableOnInteraction:!1,stopOnLastSlide:!1,reverseDirection:!1,pauseOnMouseEnter:!1}});let d,c,p,u,m,h,f,g,v=o&&o.autoplay?o.autoplay.delay:3e3,w=o&&o.autoplay?o.autoplay.delay:3e3,b=(new Date).getTime();function y(e){i&&!i.destroyed&&i.wrapperEl&&e.target===i.wrapperEl&&(i.wrapperEl.removeEventListener("transitionend",y),g||C())}const E=()=>{if(i.destroyed||!i.autoplay.running)return;i.autoplay.paused?c=!0:c&&(w=d,c=!1);const e=i.autoplay.paused?d:b+w-(new Date).getTime();i.autoplay.timeLeft=e,l("autoplayTimeLeft",e,e/v),s=requestAnimationFrame((()=>{E()}))},x=e=>{if(i.destroyed||!i.autoplay.running)return;cancelAnimationFrame(s),E();let a=void 0===e?i.params.autoplay.delay:e;v=i.params.autoplay.delay,w=i.params.autoplay.delay;const r=(()=>{let e;if(e=i.virtual&&i.params.virtual.enabled?i.slides.filter((e=>e.classList.contains("swiper-slide-active")))[0]:i.slides[i.activeIndex],!e)return;return parseInt(e.getAttribute("data-swiper-autoplay"),10)})();!Number.isNaN(r)&&r>0&&void 0===e&&(a=r,v=r,w=r),d=a;const n=i.params.speed,o=()=>{i&&!i.destroyed&&(i.params.autoplay.reverseDirection?!i.isBeginning||i.params.loop||i.params.rewind?(i.slidePrev(n,!0,!0),l("autoplay")):i.params.autoplay.stopOnLastSlide||(i.slideTo(i.slides.length-1,n,!0,!0),l("autoplay")):!i.isEnd||i.params.loop||i.params.rewind?(i.slideNext(n,!0,!0),l("autoplay")):i.params.autoplay.stopOnLastSlide||(i.slideTo(0,n,!0,!0),l("autoplay")),i.params.cssMode&&(b=(new Date).getTime(),requestAnimationFrame((()=>{x()}))))};return a>0?(clearTimeout(t),t=setTimeout((()=>{o()}),a)):requestAnimationFrame((()=>{o()})),a},S=()=>{b=(new Date).getTime(),i.autoplay.running=!0,x(),l("autoplayStart")},T=()=>{i.autoplay.running=!1,clearTimeout(t),cancelAnimationFrame(s),l("autoplayStop")},M=(e,s)=>{if(i.destroyed||!i.autoplay.running)return;clearTimeout(t),e||(f=!0);const a=()=>{l("autoplayPause"),i.params.autoplay.waitForTransition?i.wrapperEl.addEventListener("transitionend",y):C()};if(i.autoplay.paused=!0,s)return h&&(d=i.params.autoplay.delay),h=!1,void a();const r=d||i.params.autoplay.delay;d=r-((new Date).getTime()-b),i.isEnd&&d<0&&!i.params.loop||(d<0&&(d=0),a())},C=()=>{i.isEnd&&d<0&&!i.params.loop||i.destroyed||!i.autoplay.running||(b=(new Date).getTime(),f?(f=!1,x(d)):x(),i.autoplay.paused=!1,l("autoplayResume"))},P=()=>{if(i.destroyed||!i.autoplay.running)return;const e=a();"hidden"===e.visibilityState&&(f=!0,M(!0)),"visible"===e.visibilityState&&C()},L=e=>{"mouse"===e.pointerType&&(f=!0,g=!0,i.animating||i.autoplay.paused||M(!0))},I=e=>{"mouse"===e.pointerType&&(g=!1,i.autoplay.paused&&C())};n("init",(()=>{i.params.autoplay.enabled&&(i.params.autoplay.pauseOnMouseEnter&&(i.el.addEventListener("pointerenter",L),i.el.addEventListener("pointerleave",I)),a().addEventListener("visibilitychange",P),S())})),n("destroy",(()=>{i.el.removeEventListener("pointerenter",L),i.el.removeEventListener("pointerleave",I),a().removeEventListener("visibilitychange",P),i.autoplay.running&&T()})),n("_freeModeStaticRelease",(()=>{(u||f)&&C()})),n("_freeModeNoMomentumRelease",(()=>{i.params.autoplay.disableOnInteraction?T():M(!0,!0)})),n("beforeTransitionStart",((e,t,s)=>{!i.destroyed&&i.autoplay.running&&(s||!i.params.autoplay.disableOnInteraction?M(!0,!0):T())})),n("sliderFirstMove",(()=>{!i.destroyed&&i.autoplay.running&&(i.params.autoplay.disableOnInteraction?T():(p=!0,u=!1,f=!1,m=setTimeout((()=>{f=!0,u=!0,M(!0)}),200)))})),n("touchEnd",(()=>{if(!i.destroyed&&i.autoplay.running&&p){if(clearTimeout(m),clearTimeout(t),i.params.autoplay.disableOnInteraction)return u=!1,void(p=!1);u&&i.params.cssMode&&C(),u=!1,p=!1}})),n("slideChange",(()=>{!i.destroyed&&i.autoplay.running&&(h=!0)})),Object.assign(i.autoplay,{start:S,stop:T,pause:M,resume:C})},function(e){let{swiper:t,extendParams:s,on:i}=e;s({thumbs:{swiper:null,multipleActiveThumbs:!0,autoScrollOffset:0,slideThumbActiveClass:"swiper-slide-thumb-active",thumbsContainerClass:"swiper-thumbs"}});let r=!1,n=!1;function l(){const e=t.thumbs.swiper;if(!e||e.destroyed)return;const s=e.clickedIndex,a=e.clickedSlide;if(a&&a.classList.contains(t.params.thumbs.slideThumbActiveClass))return;if(null==s)return;let i;i=e.params.loop?parseInt(e.clickedSlide.getAttribute("data-swiper-slide-index"),10):s,t.params.loop?t.slideToLoop(i):t.slideTo(i)}function o(){const{thumbs:e}=t.params;if(r)return!1;r=!0;const s=t.constructor;if(e.swiper instanceof s)t.thumbs.swiper=e.swiper,Object.assign(t.thumbs.swiper.originalParams,{watchSlidesProgress:!0,slideToClickedSlide:!1}),Object.assign(t.thumbs.swiper.params,{watchSlidesProgress:!0,slideToClickedSlide:!1}),t.thumbs.swiper.update();else if(c(e.swiper)){const a=Object.assign({},e.swiper);Object.assign(a,{watchSlidesProgress:!0,slideToClickedSlide:!1}),t.thumbs.swiper=new s(a),n=!0}return t.thumbs.swiper.el.classList.add(t.params.thumbs.thumbsContainerClass),t.thumbs.swiper.on("tap",l),!0}function d(e){const s=t.thumbs.swiper;if(!s||s.destroyed)return;const a="auto"===s.params.slidesPerView?s.slidesPerViewDynamic():s.params.slidesPerView;let i=1;const r=t.params.thumbs.slideThumbActiveClass;if(t.params.slidesPerView>1&&!t.params.centeredSlides&&(i=t.params.slidesPerView),t.params.thumbs.multipleActiveThumbs||(i=1),i=Math.floor(i),s.slides.forEach((e=>e.classList.remove(r))),s.params.loop||s.params.virtual&&s.params.virtual.enabled)for(let e=0;e<i;e+=1)f(s.slidesEl,`[data-swiper-slide-index="${t.realIndex+e}"]`).forEach((e=>{e.classList.add(r)}));else for(let e=0;e<i;e+=1)s.slides[t.realIndex+e]&&s.slides[t.realIndex+e].classList.add(r);const n=t.params.thumbs.autoScrollOffset,l=n&&!s.params.loop;if(t.realIndex!==s.realIndex||l){const i=s.activeIndex;let r,o;if(s.params.loop){const e=s.slides.filter((e=>e.getAttribute("data-swiper-slide-index")===`${t.realIndex}`))[0];r=s.slides.indexOf(e),o=t.activeIndex>t.previousIndex?"next":"prev"}else r=t.realIndex,o=r>t.previousIndex?"next":"prev";l&&(r+="next"===o?n:-1*n),s.visibleSlidesIndexes&&s.visibleSlidesIndexes.indexOf(r)<0&&(s.params.centeredSlides?r=r>i?r-Math.floor(a/2)+1:r+Math.floor(a/2)-1:r>i&&s.params.slidesPerGroup,s.slideTo(r,e?0:void 0))}}t.thumbs={swiper:null},i("beforeInit",(()=>{const{thumbs:e}=t.params;if(e&&e.swiper)if("string"==typeof e.swiper||e.swiper instanceof HTMLElement){const s=a(),i=()=>{const a="string"==typeof e.swiper?s.querySelector(e.swiper):e.swiper;if(a&&a.swiper)e.swiper=a.swiper,o(),d(!0);else if(a){const s=i=>{e.swiper=i.detail[0],a.removeEventListener("init",s),o(),d(!0),e.swiper.update(),t.update()};a.addEventListener("init",s)}return a},r=()=>{if(t.destroyed)return;i()||requestAnimationFrame(r)};requestAnimationFrame(r)}else o(),d(!0)})),i("slideChange update resize observerUpdate",(()=>{d()})),i("setTransition",((e,s)=>{const a=t.thumbs.swiper;a&&!a.destroyed&&a.setTransition(s)})),i("beforeDestroy",(()=>{const e=t.thumbs.swiper;e&&!e.destroyed&&n&&e.destroy()})),Object.assign(t.thumbs,{init:o,update:d})},function(e){let{swiper:t,extendParams:s,emit:a,once:i}=e;s({freeMode:{enabled:!1,momentum:!0,momentumRatio:1,momentumBounce:!0,momentumBounceRatio:1,momentumVelocityRatio:1,sticky:!1,minimumVelocity:.02}}),Object.assign(t,{freeMode:{onTouchStart:function(){if(t.params.cssMode)return;const e=t.getTranslate();t.setTranslate(e),t.setTransition(0),t.touchEventsData.velocities.length=0,t.freeMode.onTouchEnd({currentPos:t.rtl?t.translate:-t.translate})},onTouchMove:function(){if(t.params.cssMode)return;const{touchEventsData:e,touches:s}=t;0===e.velocities.length&&e.velocities.push({position:s[t.isHorizontal()?"startX":"startY"],time:e.touchStartTime}),e.velocities.push({position:s[t.isHorizontal()?"currentX":"currentY"],time:o()})},onTouchEnd:function(e){let{currentPos:s}=e;if(t.params.cssMode)return;const{params:r,wrapperEl:n,rtlTranslate:l,snapGrid:d,touchEventsData:c}=t,p=o()-c.touchStartTime;if(s<-t.minTranslate())t.slideTo(t.activeIndex);else if(s>-t.maxTranslate())t.slides.length<d.length?t.slideTo(d.length-1):t.slideTo(t.slides.length-1);else{if(r.freeMode.momentum){if(c.velocities.length>1){const e=c.velocities.pop(),s=c.velocities.pop(),a=e.position-s.position,i=e.time-s.time;t.velocity=a/i,t.velocity/=2,Math.abs(t.velocity)<r.freeMode.minimumVelocity&&(t.velocity=0),(i>150||o()-e.time>300)&&(t.velocity=0)}else t.velocity=0;t.velocity*=r.freeMode.momentumVelocityRatio,c.velocities.length=0;let e=1e3*r.freeMode.momentumRatio;const s=t.velocity*e;let p=t.translate+s;l&&(p=-p);let u,m=!1;const h=20*Math.abs(t.velocity)*r.freeMode.momentumBounceRatio;let f;if(p<t.maxTranslate())r.freeMode.momentumBounce?(p+t.maxTranslate()<-h&&(p=t.maxTranslate()-h),u=t.maxTranslate(),m=!0,c.allowMomentumBounce=!0):p=t.maxTranslate(),r.loop&&r.centeredSlides&&(f=!0);else if(p>t.minTranslate())r.freeMode.momentumBounce?(p-t.minTranslate()>h&&(p=t.minTranslate()+h),u=t.minTranslate(),m=!0,c.allowMomentumBounce=!0):p=t.minTranslate(),r.loop&&r.centeredSlides&&(f=!0);else if(r.freeMode.sticky){let e;for(let t=0;t<d.length;t+=1)if(d[t]>-p){e=t;break}p=Math.abs(d[e]-p)<Math.abs(d[e-1]-p)||"next"===t.swipeDirection?d[e]:d[e-1],p=-p}if(f&&i("transitionEnd",(()=>{t.loopFix()})),0!==t.velocity){if(e=l?Math.abs((-p-t.translate)/t.velocity):Math.abs((p-t.translate)/t.velocity),r.freeMode.sticky){const s=Math.abs((l?-p:p)-t.translate),a=t.slidesSizesGrid[t.activeIndex];e=s<a?r.speed:s<2*a?1.5*r.speed:2.5*r.speed}}else if(r.freeMode.sticky)return void t.slideToClosest();r.freeMode.momentumBounce&&m?(t.updateProgress(u),t.setTransition(e),t.setTranslate(p),t.transitionStart(!0,t.swipeDirection),t.animating=!0,x(n,(()=>{t&&!t.destroyed&&c.allowMomentumBounce&&(a("momentumBounce"),t.setTransition(r.speed),setTimeout((()=>{t.setTranslate(u),x(n,(()=>{t&&!t.destroyed&&t.transitionEnd()}))}),0))}))):t.velocity?(a("_freeModeNoMomentumRelease"),t.updateProgress(p),t.setTransition(e),t.setTranslate(p),t.transitionStart(!0,t.swipeDirection),t.animating||(t.animating=!0,x(n,(()=>{t&&!t.destroyed&&t.transitionEnd()})))):t.updateProgress(p),t.updateActiveIndex(),t.updateSlidesClasses()}else{if(r.freeMode.sticky)return void t.slideToClosest();r.freeMode&&a("_freeModeNoMomentumRelease")}(!r.freeMode.momentum||p>=r.longSwipesMs)&&(a("_freeModeStaticRelease"),t.updateProgress(),t.updateActiveIndex(),t.updateSlidesClasses())}}}})},function(e){let t,s,a,i,{swiper:r,extendParams:n,on:l}=e;n({grid:{rows:1,fill:"column"}});const o=()=>{let e=r.params.spaceBetween;return"string"==typeof e&&e.indexOf("%")>=0?e=parseFloat(e.replace("%",""))/100*r.size:"string"==typeof e&&(e=parseFloat(e)),e};l("init",(()=>{i=r.params.grid&&r.params.grid.rows>1})),l("update",(()=>{const{params:e,el:t}=r,s=e.grid&&e.grid.rows>1;i&&!s?(t.classList.remove(`${e.containerModifierClass}grid`,`${e.containerModifierClass}grid-column`),a=1,r.emitContainerClasses()):!i&&s&&(t.classList.add(`${e.containerModifierClass}grid`),"column"===e.grid.fill&&t.classList.add(`${e.containerModifierClass}grid-column`),r.emitContainerClasses()),i=s})),r.grid={initSlides:e=>{const{slidesPerView:i}=r.params,{rows:n,fill:l}=r.params.grid,o=r.virtual&&r.params.virtual.enabled?r.virtual.slides.length:e.length;a=Math.floor(o/n),t=Math.floor(o/n)===o/n?o:Math.ceil(o/n)*n,"auto"!==i&&"row"===l&&(t=Math.max(t,i*n)),s=t/n},unsetSlides:()=>{r.slides&&r.slides.forEach((e=>{e.swiperSlideGridSet&&(e.style.height="",e.style[r.getDirectionLabel("margin-top")]="")}))},updateSlide:(e,i,n)=>{const{slidesPerGroup:l}=r.params,d=o(),{rows:c,fill:p}=r.params.grid,u=r.virtual&&r.params.virtual.enabled?r.virtual.slides.length:n.length;let m,h,f;if("row"===p&&l>1){const s=Math.floor(e/(l*c)),a=e-c*l*s,r=0===s?l:Math.min(Math.ceil((u-s*c*l)/c),l);f=Math.floor(a/r),h=a-f*r+s*l,m=h+f*t/c,i.style.order=m}else"column"===p?(h=Math.floor(e/c),f=e-h*c,(h>a||h===a&&f===c-1)&&(f+=1,f>=c&&(f=0,h+=1))):(f=Math.floor(e/s),h=e-f*s);i.row=f,i.column=h,i.style.height=`calc((100% - ${(c-1)*d}px) / ${c})`,i.style[r.getDirectionLabel("margin-top")]=0!==f?d&&`${d}px`:"",i.swiperSlideGridSet=!0},updateWrapperSize:(e,s)=>{const{centeredSlides:a,roundLengths:i}=r.params,n=o(),{rows:l}=r.params.grid;if(r.virtualSize=(e+n)*t,r.virtualSize=Math.ceil(r.virtualSize/l)-n,r.params.cssMode||(r.wrapperEl.style[r.getDirectionLabel("width")]=`${r.virtualSize+n}px`),a){const e=[];for(let t=0;t<s.length;t+=1){let a=s[t];i&&(a=Math.floor(a)),s[t]<r.virtualSize+s[0]&&e.push(a)}s.splice(0,s.length),s.push(...e)}}}},function(e){let{swiper:t}=e;Object.assign(t,{appendSlide:ie.bind(t),prependSlide:re.bind(t),addSlide:ne.bind(t),removeSlide:le.bind(t),removeAllSlides:oe.bind(t)})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({fadeEffect:{crossFade:!1}}),de({effect:"fade",swiper:t,on:a,setTranslate:()=>{const{slides:e}=t;t.params.fadeEffect;for(let s=0;s<e.length;s+=1){const e=t.slides[s];let a=-e.swiperSlideOffset;t.params.virtualTranslate||(a-=t.translate);let i=0;t.isHorizontal()||(i=a,a=0);const r=t.params.fadeEffect.crossFade?Math.max(1-Math.abs(e.progress),0):1+Math.min(Math.max(e.progress,-1),0),n=ce(0,e);n.style.opacity=r,n.style.transform=`translate3d(${a}px, ${i}px, 0px)`}},setTransition:e=>{const s=t.slides.map((e=>h(e)));s.forEach((t=>{t.style.transitionDuration=`${e}ms`})),pe({swiper:t,duration:e,transformElements:s,allSlides:!0})},overwriteParams:()=>({slidesPerView:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!t.params.cssMode})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({cubeEffect:{slideShadows:!0,shadow:!0,shadowOffset:20,shadowScale:.94}});const i=(e,t,s)=>{let a=s?e.querySelector(".swiper-slide-shadow-left"):e.querySelector(".swiper-slide-shadow-top"),i=s?e.querySelector(".swiper-slide-shadow-right"):e.querySelector(".swiper-slide-shadow-bottom");a||(a=v("div",("swiper-slide-shadow-cube swiper-slide-shadow-"+(s?"left":"top")).split(" ")),e.append(a)),i||(i=v("div",("swiper-slide-shadow-cube swiper-slide-shadow-"+(s?"right":"bottom")).split(" ")),e.append(i)),a&&(a.style.opacity=Math.max(-t,0)),i&&(i.style.opacity=Math.max(t,0))};de({effect:"cube",swiper:t,on:a,setTranslate:()=>{const{el:e,wrapperEl:s,slides:a,width:r,height:n,rtlTranslate:l,size:o,browser:d}=t,c=t.params.cubeEffect,p=t.isHorizontal(),u=t.virtual&&t.params.virtual.enabled;let m,h=0;c.shadow&&(p?(m=t.wrapperEl.querySelector(".swiper-cube-shadow"),m||(m=v("div","swiper-cube-shadow"),t.wrapperEl.append(m)),m.style.height=`${r}px`):(m=e.querySelector(".swiper-cube-shadow"),m||(m=v("div","swiper-cube-shadow"),e.append(m))));for(let e=0;e<a.length;e+=1){const s=a[e];let r=e;u&&(r=parseInt(s.getAttribute("data-swiper-slide-index"),10));let n=90*r,d=Math.floor(n/360);l&&(n=-n,d=Math.floor(-n/360));const m=Math.max(Math.min(s.progress,1),-1);let f=0,g=0,v=0;r%4==0?(f=4*-d*o,v=0):(r-1)%4==0?(f=0,v=4*-d*o):(r-2)%4==0?(f=o+4*d*o,v=o):(r-3)%4==0&&(f=-o,v=3*o+4*o*d),l&&(f=-f),p||(g=f,f=0);const w=`rotateX(${p?0:-n}deg) rotateY(${p?n:0}deg) translate3d(${f}px, ${g}px, ${v}px)`;m<=1&&m>-1&&(h=90*r+90*m,l&&(h=90*-r-90*m),t.browser&&t.browser.need3dFix&&Math.abs(h)/90%2==1&&(h+=.001)),s.style.transform=w,c.slideShadows&&i(s,m,p)}if(s.style.transformOrigin=`50% 50% -${o/2}px`,s.style["-webkit-transform-origin"]=`50% 50% -${o/2}px`,c.shadow)if(p)m.style.transform=`translate3d(0px, ${r/2+c.shadowOffset}px, ${-r/2}px) rotateX(89.99deg) rotateZ(0deg) scale(${c.shadowScale})`;else{const e=Math.abs(h)-90*Math.floor(Math.abs(h)/90),t=1.5-(Math.sin(2*e*Math.PI/360)/2+Math.cos(2*e*Math.PI/360)/2),s=c.shadowScale,a=c.shadowScale/t,i=c.shadowOffset;m.style.transform=`scale3d(${s}, 1, ${a}) translate3d(0px, ${n/2+i}px, ${-n/2/a}px) rotateX(-89.99deg)`}const f=(d.isSafari||d.isWebView)&&d.needPerspectiveFix?-o/2:0;s.style.transform=`translate3d(0px,0,${f}px) rotateX(${t.isHorizontal()?0:h}deg) rotateY(${t.isHorizontal()?-h:0}deg)`,s.style.setProperty("--swiper-cube-translate-z",`${f}px`)},setTransition:e=>{const{el:s,slides:a}=t;if(a.forEach((t=>{t.style.transitionDuration=`${e}ms`,t.querySelectorAll(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").forEach((t=>{t.style.transitionDuration=`${e}ms`}))})),t.params.cubeEffect.shadow&&!t.isHorizontal()){const t=s.querySelector(".swiper-cube-shadow");t&&(t.style.transitionDuration=`${e}ms`)}},recreateShadows:()=>{const e=t.isHorizontal();t.slides.forEach((t=>{const s=Math.max(Math.min(t.progress,1),-1);i(t,s,e)}))},getEffectParams:()=>t.params.cubeEffect,perspective:()=>!0,overwriteParams:()=>({slidesPerView:1,slidesPerGroup:1,watchSlidesProgress:!0,resistanceRatio:0,spaceBetween:0,centeredSlides:!1,virtualTranslate:!0})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({flipEffect:{slideShadows:!0,limitRotation:!0}});const i=(e,s)=>{let a=t.isHorizontal()?e.querySelector(".swiper-slide-shadow-left"):e.querySelector(".swiper-slide-shadow-top"),i=t.isHorizontal()?e.querySelector(".swiper-slide-shadow-right"):e.querySelector(".swiper-slide-shadow-bottom");a||(a=ue("flip",e,t.isHorizontal()?"left":"top")),i||(i=ue("flip",e,t.isHorizontal()?"right":"bottom")),a&&(a.style.opacity=Math.max(-s,0)),i&&(i.style.opacity=Math.max(s,0))};de({effect:"flip",swiper:t,on:a,setTranslate:()=>{const{slides:e,rtlTranslate:s}=t,a=t.params.flipEffect;for(let r=0;r<e.length;r+=1){const n=e[r];let l=n.progress;t.params.flipEffect.limitRotation&&(l=Math.max(Math.min(n.progress,1),-1));const o=n.swiperSlideOffset;let d=-180*l,c=0,p=t.params.cssMode?-o-t.translate:-o,u=0;t.isHorizontal()?s&&(d=-d):(u=p,p=0,c=-d,d=0),t.browser&&t.browser.need3dFix&&(Math.abs(d)/90%2==1&&(d+=.001),Math.abs(c)/90%2==1&&(c+=.001)),n.style.zIndex=-Math.abs(Math.round(l))+e.length,a.slideShadows&&i(n,l);const m=`translate3d(${p}px, ${u}px, 0px) rotateX(${c}deg) rotateY(${d}deg)`;ce(0,n).style.transform=m}},setTransition:e=>{const s=t.slides.map((e=>h(e)));s.forEach((t=>{t.style.transitionDuration=`${e}ms`,t.querySelectorAll(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").forEach((t=>{t.style.transitionDuration=`${e}ms`}))})),pe({swiper:t,duration:e,transformElements:s})},recreateShadows:()=>{t.params.flipEffect,t.slides.forEach((e=>{let s=e.progress;t.params.flipEffect.limitRotation&&(s=Math.max(Math.min(e.progress,1),-1)),i(e,s)}))},getEffectParams:()=>t.params.flipEffect,perspective:()=>!0,overwriteParams:()=>({slidesPerView:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!t.params.cssMode})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({coverflowEffect:{rotate:50,stretch:0,depth:100,scale:1,modifier:1,slideShadows:!0}}),de({effect:"coverflow",swiper:t,on:a,setTranslate:()=>{const{width:e,height:s,slides:a,slidesSizesGrid:i}=t,r=t.params.coverflowEffect,n=t.isHorizontal(),l=t.translate,o=n?e/2-l:s/2-l,d=n?r.rotate:-r.rotate,c=r.depth;for(let e=0,s=a.length;e<s;e+=1){const s=a[e],l=i[e],p=(o-s.swiperSlideOffset-l/2)/l,u="function"==typeof r.modifier?r.modifier(p):p*r.modifier;let m=n?d*u:0,h=n?0:d*u,f=-c*Math.abs(u),g=r.stretch;"string"==typeof g&&-1!==g.indexOf("%")&&(g=parseFloat(r.stretch)/100*l);let v=n?0:g*u,w=n?g*u:0,b=1-(1-r.scale)*Math.abs(u);Math.abs(w)<.001&&(w=0),Math.abs(v)<.001&&(v=0),Math.abs(f)<.001&&(f=0),Math.abs(m)<.001&&(m=0),Math.abs(h)<.001&&(h=0),Math.abs(b)<.001&&(b=0),t.browser&&t.browser.need3dFix&&(Math.abs(m)/90%2==1&&(m+=.001),Math.abs(h)/90%2==1&&(h+=.001));const y=`translate3d(${w}px,${v}px,${f}px) rotateX(${h}deg) rotateY(${m}deg) scale(${b})`;if(ce(0,s).style.transform=y,s.style.zIndex=1-Math.abs(Math.round(u)),r.slideShadows){let e=n?s.querySelector(".swiper-slide-shadow-left"):s.querySelector(".swiper-slide-shadow-top"),t=n?s.querySelector(".swiper-slide-shadow-right"):s.querySelector(".swiper-slide-shadow-bottom");e||(e=ue("coverflow",s,n?"left":"top")),t||(t=ue("coverflow",s,n?"right":"bottom")),e&&(e.style.opacity=u>0?u:0),t&&(t.style.opacity=-u>0?-u:0)}}},setTransition:e=>{t.slides.map((e=>h(e))).forEach((t=>{t.style.transitionDuration=`${e}ms`,t.querySelectorAll(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").forEach((t=>{t.style.transitionDuration=`${e}ms`}))}))},perspective:()=>!0,overwriteParams:()=>({watchSlidesProgress:!0})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({creativeEffect:{limitProgress:1,shadowPerProgress:!1,progressMultiplier:1,perspective:!0,prev:{translate:[0,0,0],rotate:[0,0,0],opacity:1,scale:1},next:{translate:[0,0,0],rotate:[0,0,0],opacity:1,scale:1}}});const i=e=>"string"==typeof e?e:`${e}px`;de({effect:"creative",swiper:t,on:a,setTranslate:()=>{const{slides:e,wrapperEl:s,slidesSizesGrid:a}=t,r=t.params.creativeEffect,{progressMultiplier:n}=r,l=t.params.centeredSlides;if(l){const e=a[0]/2-t.params.slidesOffsetBefore||0;s.style.transform=`translateX(calc(50% - ${e}px))`}for(let s=0;s<e.length;s+=1){const a=e[s],o=a.progress,d=Math.min(Math.max(a.progress,-r.limitProgress),r.limitProgress);let c=d;l||(c=Math.min(Math.max(a.originalProgress,-r.limitProgress),r.limitProgress));const p=a.swiperSlideOffset,u=[t.params.cssMode?-p-t.translate:-p,0,0],m=[0,0,0];let h=!1;t.isHorizontal()||(u[1]=u[0],u[0]=0);let f={translate:[0,0,0],rotate:[0,0,0],scale:1,opacity:1};d<0?(f=r.next,h=!0):d>0&&(f=r.prev,h=!0),u.forEach(((e,t)=>{u[t]=`calc(${e}px + (${i(f.translate[t])} * ${Math.abs(d*n)}))`})),m.forEach(((e,s)=>{let a=f.rotate[s]*Math.abs(d*n);t.browser&&t.browser.need3dFix&&Math.abs(a)/90%2==1&&(a+=.001),m[s]=a})),a.style.zIndex=-Math.abs(Math.round(o))+e.length;const g=u.join(", "),v=`rotateX(${m[0]}deg) rotateY(${m[1]}deg) rotateZ(${m[2]}deg)`,w=c<0?`scale(${1+(1-f.scale)*c*n})`:`scale(${1-(1-f.scale)*c*n})`,b=c<0?1+(1-f.opacity)*c*n:1-(1-f.opacity)*c*n,y=`translate3d(${g}) ${v} ${w}`;if(h&&f.shadow||!h){let e=a.querySelector(".swiper-slide-shadow");if(!e&&f.shadow&&(e=ue("creative",a)),e){const t=r.shadowPerProgress?d*(1/r.limitProgress):d;e.style.opacity=Math.min(Math.max(Math.abs(t),0),1)}}const E=ce(0,a);E.style.transform=y,E.style.opacity=b,f.origin&&(E.style.transformOrigin=f.origin)}},setTransition:e=>{const s=t.slides.map((e=>h(e)));s.forEach((t=>{t.style.transitionDuration=`${e}ms`,t.querySelectorAll(".swiper-slide-shadow").forEach((t=>{t.style.transitionDuration=`${e}ms`}))})),pe({swiper:t,duration:e,transformElements:s,allSlides:!0})},perspective:()=>t.params.creativeEffect.perspective,overwriteParams:()=>({watchSlidesProgress:!0,virtualTranslate:!t.params.cssMode})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({cardsEffect:{slideShadows:!0,rotate:!0,perSlideRotate:2,perSlideOffset:8}}),de({effect:"cards",swiper:t,on:a,setTranslate:()=>{const{slides:e,activeIndex:s,rtlTranslate:a}=t,i=t.params.cardsEffect,{startTranslate:r,isTouched:n}=t.touchEventsData,l=a?-t.translate:t.translate;for(let o=0;o<e.length;o+=1){const d=e[o],c=d.progress,p=Math.min(Math.max(c,-4),4);let u=d.swiperSlideOffset;t.params.centeredSlides&&!t.params.cssMode&&(t.wrapperEl.style.transform=`translateX(${t.minTranslate()}px)`),t.params.centeredSlides&&t.params.cssMode&&(u-=e[0].swiperSlideOffset);let m=t.params.cssMode?-u-t.translate:-u,h=0;const f=-100*Math.abs(p);let g=1,v=-i.perSlideRotate*p,w=i.perSlideOffset-.75*Math.abs(p);const b=t.virtual&&t.params.virtual.enabled?t.virtual.from+o:o,y=(b===s||b===s-1)&&p>0&&p<1&&(n||t.params.cssMode)&&l<r,E=(b===s||b===s+1)&&p<0&&p>-1&&(n||t.params.cssMode)&&l>r;if(y||E){const e=(1-Math.abs((Math.abs(p)-.5)/.5))**.5;v+=-28*p*e,g+=-.5*e,w+=96*e,h=-25*e*Math.abs(p)+"%"}if(m=p<0?`calc(${m}px ${a?"-":"+"} (${w*Math.abs(p)}%))`:p>0?`calc(${m}px ${a?"-":"+"} (-${w*Math.abs(p)}%))`:`${m}px`,!t.isHorizontal()){const e=h;h=m,m=e}const x=p<0?""+(1+(1-g)*p):""+(1-(1-g)*p),S=`\n translate3d(${m}, ${h}, ${f}px)\n rotateZ(${i.rotate?a?-v:v:0}deg)\n scale(${x})\n `;if(i.slideShadows){let e=d.querySelector(".swiper-slide-shadow");e||(e=ue("cards",d)),e&&(e.style.opacity=Math.min(Math.max((Math.abs(p)-.5)/.5,0),1))}d.style.zIndex=-Math.abs(Math.round(c))+e.length;ce(0,d).style.transform=S}},setTransition:e=>{const s=t.slides.map((e=>h(e)));s.forEach((t=>{t.style.transitionDuration=`${e}ms`,t.querySelectorAll(".swiper-slide-shadow").forEach((t=>{t.style.transitionDuration=`${e}ms`}))})),pe({swiper:t,duration:e,transformElements:s})},perspective:()=>!0,overwriteParams:()=>({watchSlidesProgress:!0,virtualTranslate:!t.params.cssMode})})}];return te.use(me),te}();
652 653//# sourceMappingURL=swiper-bundle.min.js.map 654/* End */ 655; 656; /* Start:"a:4:{s:4:"full";s:69:"/local/templates/bitrix66/plug/glightbox/glightbox.js?178963401277261";s:6:"source";s:53:"/local/templates/bitrix66/plug/glightbox/glightbox.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/ 657//https://github.com/biati-digital/glightbox 658(function (global, factory) { 659 typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : 660 typeof define === 'function' && define.amd ? define(factory) : 661 (global = global || self, global.GLightbox = factory()); 662}(this, function () { 'use strict'; 663 664 function _typeof(obj) { 665 if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { 666 _typeof = function (obj) { 667 return typeof obj; 668 }; 669 } else { 670 _typeof = function (obj) { 671 return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; 672 }; 673 } 674 675 return _typeof(obj); 676 } 677 678 function _classCallCheck(instance, Constructor) { 679 if (!(instance instanceof Constructor)) { 680 throw new TypeError("Cannot call a class as a function"); 681 } 682 } 683 684 function _defineProperties(target, props) { 685 for (var i = 0; i < props.length; i++) { 686 var descriptor = props[i]; 687 descriptor.enumerable = descriptor.enumerable || false; 688 descriptor.configurable = true; 689 if ("value" in descriptor) descriptor.writable = true; 690 Object.defineProperty(target, descriptor.key, descriptor); 691 } 692 } 693 694 function _createClass(Constructor, protoProps, staticProps) { 695 if (protoProps) _defineProperties(Constructor.prototype, protoProps); 696 if (staticProps) _defineProperties(Constructor, staticProps); 697 return Constructor; 698 } 699 700 function _toConsumableArray(arr) { 701 return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _nonIterableSpread(); 702 } 703 704 function _arrayWithoutHoles(arr) { 705 if (Array.isArray(arr)) { 706 for (var i = 0, arr2 = new Array(arr.length); i < arr.length; i++) arr2[i] = arr[i]; 707 708 return arr2; 709 } 710 } 711 712 function _iterableToArray(iter) { 713 if (Symbol.iterator in Object(iter) || Object.prototype.toString.call(iter) === "[object Arguments]") return Array.from(iter); 714 } 715 716 function _nonIterableSpread() { 717 throw new TypeError("Invalid attempt to spread non-iterable instance"); 718 } 719 720 function getLen(v) { 721 return Math.sqrt(v.x * v.x + v.y * v.y); 722 } 723 724 function dot(v1, v2) { 725 return v1.x * v2.x + v1.y * v2.y; 726 } 727 728 function getAngle(v1, v2) { 729 var mr = getLen(v1) * getLen(v2); 730 if (mr === 0) return 0; 731 var r = dot(v1, v2) / mr; 732 if (r > 1) r = 1; 733 return Math.acos(r); 734 } 735 736 function cross(v1, v2) { 737 return v1.x * v2.y - v2.x * v1.y; 738 } 739 740 function getRotateAngle(v1, v2) { 741 var angle = getAngle(v1, v2); 742 743 if (cross(v1, v2) > 0) { 744 angle *= -1; 745 } 746 747 return angle * 180 / Math.PI; 748 } 749 750 var EventsHandlerAdmin = function () { 751 function EventsHandlerAdmin(el) { 752 _classCallCheck(this, EventsHandlerAdmin); 753 754 this.handlers = []; 755 this.el = el; 756 } 757 758 _createClass(EventsHandlerAdmin, [{ 759 key: "add", 760 value: function add(handler) { 761 this.handlers.push(handler); 762 } 763 }, {
764 key: "del", 765 value: function del(handler) { 766 if (!handler) this.handlers = []; 767 768 for (var i = this.handlers.length; i >= 0; i--) { 769 if (this.handlers[i] === handler) { 770 this.handlers.splice(i, 1); 771 } 772 } 773 } 774 }, { 775 key: "dispatch", 776 value: function dispatch() { 777 for (var i = 0, len = this.handlers.length; i < len; i++) { 778 var handler = this.handlers[i]; 779 if (typeof handler === 'function') handler.apply(this.el, arguments); 780 } 781 } 782 }]); 783 784 return EventsHandlerAdmin; 785 }(); 786 787 function wrapFunc(el, handler) { 788 var EventshandlerAdmin = new EventsHandlerAdmin(el); 789 EventshandlerAdmin.add(handler); 790 return EventshandlerAdmin; 791 } 792 793 var TouchEvents = function () { 794 function TouchEvents(el, option) { 795 _classCallCheck(this, TouchEvents); 796 797 this.element = typeof el == 'string' ? document.querySelector(el) : el; 798 this.start = this.start.bind(this); 799 this.move = this.move.bind(this); 800 this.end = this.end.bind(this); 801 this.cancel = this.cancel.bind(this); 802 this.element.addEventListener("touchstart", this.start, false); 803 this.element.addEventListener("touchmove", this.move, false); 804 this.element.addEventListener("touchend", this.end, false); 805 this.element.addEventListener("touchcancel", this.cancel, false); 806 this.preV = { 807 x: null, 808 y: null 809 }; 810 this.pinchStartLen = null; 811 this.zoom = 1; 812 this.isDoubleTap = false; 813 814 var noop = function noop() {}; 815 816 this.rotate = wrapFunc(this.element, option.rotate || noop); 817 this.touchStart = wrapFunc(this.element, option.touchStart || noop); 818 this.multipointStart = wrapFunc(this.element, option.multipointStart || noop); 819 this.multipointEnd = wrapFunc(this.element, option.multipointEnd || noop); 820 this.pinch = wrapFunc(this.element, option.pinch || noop); 821 this.swipe = wrapFunc(this.element, option.swipe || noop); 822 this.tap = wrapFunc(this.element, option.tap || noop); 823 this.doubleTap = wrapFunc(this.element, option.doubleTap || noop); 824 this.longTap = wrapFunc(this.element, option.longTap || noop); 825 this.singleTap = wrapFunc(this.element, option.singleTap || noop); 826 this.pressMove = wrapFunc(this.element, option.pressMove || noop); 827 this.twoFingerPressMove = wrapFunc(this.element, option.twoFingerPressMove || noop); 828 this.touchMove = wrapFunc(this.element, option.touchMove || noop); 829 this.touchEnd = wrapFunc(this.element, option.touchEnd || noop); 830 this.touchCancel = wrapFunc(this.element, option.touchCancel || noop); 831 this._cancelAllHandler = this.cancelAll.bind(this); 832 window.addEventListener('scroll', this._cancelAllHandler); 833 this.delta = null; 834 this.last = null; 835 this.now = null; 836 this.tapTimeout = null; 837 this.singleTapTimeout = null; 838 this.longTapTimeout = null; 839 this.swipeTimeout = null; 840 this.x1 = this.x2 = this.y1 = this.y2 = null; 841 this.preTapPosition = { 842 x: null, 843 y: null 844 }; 845 } 846 847 _createClass(TouchEvents, [{ 848 key: "start", 849 value: function start(evt) { 850 if (!evt.touches) return; 851 this.now = Date.now(); 852 this.x1 = evt.touches[0].pageX; 853 this.y1 = evt.touches[0].pageY; 854 this.delta = this.now - (this.last || this.now); 855 this.touchStart.dispatch(evt, this.element); 856 857 if (this.preTapPosition.x !== null) { 858 this.isDoubleTap = this.delta > 0 && this.delta <= 250 && Math.abs(this.preTapPosition.x - this.x1) < 30 && Math.abs(this.preTapPosition.y - this.y1) < 30; 859 if (this.isDoubleTap) clearTimeout(this.singleTapTimeout); 860 } 861 862 this.preTapPosition.x = this.x1; 863 this.preTapPosition.y = this.y1; 864 this.last = this.now; 865 var preV = this.preV, 866 len = evt.touches.length; 867 868 if (len > 1) { 869 this._cancelLongTap(); 870 871 this._cancelSingleTap(); 872 873 var v = { 874 x: evt.touches[1].pageX - this.x1, 875 y: evt.touches[1].pageY - this.y1 876 }; 877 preV.x = v.x; 878 preV.y = v.y; 879 this.pinchStartLen = getLen(preV); 880 this.multipointStart.dispatch(evt, this.element); 881 } 882 883 this._preventTap = false;
vendor: 4,164 bytes, lines 884-1025
884 this.longTapTimeout = setTimeout(function () { 885 this.longTap.dispatch(evt, this.element); 886 this._preventTap = true; 887 }.bind(this), 750); 888 } 889 }, { 890 key: "move", 891 value: function move(evt) { 892 if (!evt.touches) return; 893 var preV = this.preV, 894 len = evt.touches.length, 895 currentX = evt.touches[0].pageX, 896 currentY = evt.touches[0].pageY; 897 this.isDoubleTap = false; 898 899 if (len > 1) { 900 var sCurrentX = evt.touches[1].pageX, 901 sCurrentY = evt.touches[1].pageY; 902 var v = { 903 x: evt.touches[1].pageX - currentX, 904 y: evt.touches[1].pageY - currentY 905 }; 906 907 if (preV.x !== null) { 908 if (this.pinchStartLen > 0) { 909 evt.zoom = getLen(v) / this.pinchStartLen; 910 this.pinch.dispatch(evt, this.element); 911 } 912 913 evt.angle = getRotateAngle(v, preV); 914 this.rotate.dispatch(evt, this.element); 915 } 916 917 preV.x = v.x; 918 preV.y = v.y; 919 920 if (this.x2 !== null && this.sx2 !== null) { 921 evt.deltaX = (currentX - this.x2 + sCurrentX - this.sx2) / 2; 922 evt.deltaY = (currentY - this.y2 + sCurrentY - this.sy2) / 2; 923 } else { 924 evt.deltaX = 0; 925 evt.deltaY = 0; 926 } 927 928 this.twoFingerPressMove.dispatch(evt, this.element); 929 this.sx2 = sCurrentX; 930 this.sy2 = sCurrentY; 931 } else { 932 if (this.x2 !== null) { 933 evt.deltaX = currentX - this.x2; 934 evt.deltaY = currentY - this.y2; 935 var movedX = Math.abs(this.x1 - this.x2), 936 movedY = Math.abs(this.y1 - this.y2); 937 938 if (movedX > 10 || movedY > 10) { 939 this._preventTap = true; 940 } 941 } else { 942 evt.deltaX = 0; 943 evt.deltaY = 0; 944 } 945 946 this.pressMove.dispatch(evt, this.element); 947 } 948 949 this.touchMove.dispatch(evt, this.element); 950 951 this._cancelLongTap(); 952 953 this.x2 = currentX; 954 this.y2 = currentY; 955 956 if (len > 1) { 957 evt.preventDefault(); 958 } 959 } 960 }, { 961 key: "end", 962 value: function end(evt) { 963 if (!evt.changedTouches) return; 964 965 this._cancelLongTap(); 966 967 var self = this; 968 969 if (evt.touches.length < 2) { 970 this.multipointEnd.dispatch(evt, this.element); 971 this.sx2 = this.sy2 = null; 972 } 973 974 if (this.x2 && Math.abs(this.x1 - this.x2) > 30 || this.y2 && Math.abs(this.y1 - this.y2) > 30) { 975 evt.direction = this._swipeDirection(this.x1, this.x2, this.y1, this.y2); 976 this.swipeTimeout = setTimeout(function () { 977 self.swipe.dispatch(evt, self.element); 978 }, 0); 979 } else { 980 this.tapTimeout = setTimeout(function () { 981 if (!self._preventTap) { 982 self.tap.dispatch(evt, self.element); 983 } 984 985 if (self.isDoubleTap) { 986 self.doubleTap.dispatch(evt, self.element); 987 self.isDoubleTap = false; 988 } 989 }, 0); 990 991 if (!self.isDoubleTap) { 992 self.singleTapTimeout = setTimeout(function () { 993 self.singleTap.dispatch(evt, self.element); 994 }, 250); 995 } 996 } 997 998 this.touchEnd.dispatch(evt, this.element); 999 this.preV.x = 0; 1000 this.preV.y = 0; 1001 this.zoom = 1; 1002 this.pinchStartLen = null; 1003 this.x1 = this.x2 = this.y1 = this.y2 = null; 1004 } 1005 }, { 1006 key: "cancelAll", 1007 value: function cancelAll() { 1008 this._preventTap = true; 1009 clearTimeout(this.singleTapTimeout); 1010 clearTimeout(this.tapTimeout); 1011 clearTimeout(this.longTapTimeout); 1012 clearTimeout(this.swipeTimeout); 1013 } 1014 }, { 1015 key: "cancel", 1016 value: function cancel(evt) { 1017 this.cancelAll(); 1018 this.touchCancel.dispatch(evt, this.element); 1019 } 1020 }, { 1021 key: "_cancelLongTap", 1022 value: function _cancelLongTap() { 1023 clearTimeout(this.longTapTimeout); 1024 } 1025 }, {
1026 key: "_cancelSingleTap", 1027 value: function _cancelSingleTap() { 1028 clearTimeout(this.singleTapTimeout); 1029 } 1030 }, { 1031 key: "_swipeDirection", 1032 value: function _swipeDirection(x1, x2, y1, y2) { 1033 return Math.abs(x1 - x2) >= Math.abs(y1 - y2) ? x1 - x2 > 0 ? 'Left' : 'Right' : y1 - y2 > 0 ? 'Up' : 'Down'; 1034 } 1035 }, { 1036 key: "on", 1037 value: function on(evt, handler) { 1038 if (this[evt]) { 1039 this[evt].add(handler); 1040 } 1041 } 1042 }, { 1043 key: "off", 1044 value: function off(evt, handler) { 1045 if (this[evt]) { 1046 this[evt].del(handler); 1047 } 1048 } 1049 }, { 1050 key: "destroy", 1051 value: function destroy() { 1052 if (this.singleTapTimeout) clearTimeout(this.singleTapTimeout); 1053 if (this.tapTimeout) clearTimeout(this.tapTimeout); 1054 if (this.longTapTimeout) clearTimeout(this.longTapTimeout); 1055 if (this.swipeTimeout) clearTimeout(this.swipeTimeout); 1056 this.element.removeEventListener("touchstart", this.start); 1057 this.element.removeEventListener("touchmove", this.move); 1058 this.element.removeEventListener("touchend", this.end); 1059 this.element.removeEventListener("touchcancel", this.cancel); 1060 this.rotate.del(); 1061 this.touchStart.del(); 1062 this.multipointStart.del(); 1063 this.multipointEnd.del(); 1064 this.pinch.del(); 1065 this.swipe.del(); 1066 this.tap.del(); 1067 this.doubleTap.del(); 1068 this.longTap.del(); 1069 this.singleTap.del(); 1070 this.pressMove.del(); 1071 this.twoFingerPressMove.del(); 1072 this.touchMove.del(); 1073 this.touchEnd.del(); 1074 this.touchCancel.del(); 1075 this.preV = this.pinchStartLen = this.zoom = this.isDoubleTap = this.delta = this.last = this.now = this.tapTimeout = this.singleTapTimeout = this.longTapTimeout = this.swipeTimeout = this.x1 = this.x2 = this.y1 = this.y2 = this.preTapPosition = this.rotate = this.touchStart = this.multipointStart = this.multipointEnd = this.pinch = this.swipe = this.tap = this.doubleTap = this.longTap = this.singleTap = this.pressMove = this.touchMove = this.touchEnd = this.touchCancel = this.twoFingerPressMove = null; 1076 window.removeEventListener('scroll', this._cancelAllHandler); 1077 return null; 1078 } 1079 }]); 1080 1081 return TouchEvents; 1082 }(); 1083 1084 var ZoomImages = function () { 1085 function ZoomImages(el, slide) { 1086 var _this = this; 1087 1088 var onclose = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null; 1089 1090 _classCallCheck(this, ZoomImages); 1091 1092 this.img = el; 1093 this.slide = slide; 1094 this.onclose = onclose; 1095 1096 if (this.img.setZoomEvents) { 1097 return false; 1098 } 1099 1100 this.active = false; 1101 this.zoomedIn = false; 1102 this.dragging = false; 1103 this.currentX = null; 1104 this.currentY = null; 1105 this.initialX = null; 1106 this.initialY = null; 1107 this.xOffset = 0; 1108 this.yOffset = 0; 1109 this.img.addEventListener('mousedown', function (e) { 1110 return _this.dragStart(e); 1111 }, false); 1112 this.img.addEventListener('mouseup', function (e) { 1113 return _this.dragEnd(e); 1114 }, false); 1115 this.img.addEventListener('mousemove', function (e) { 1116 return _this.drag(e); 1117 }, false); 1118 this.img.addEventListener('click', function (e) { 1119 if (!_this.zoomedIn) { 1120 return _this.zoomIn(); 1121 } 1122 1123 if (_this.zoomedIn && !_this.dragging) { 1124 _this.zoomOut(); 1125 } 1126 }, false); 1127 this.img.setZoomEvents = true; 1128 } 1129 1130 _createClass(ZoomImages, [{ 1131 key: "zoomIn", 1132 value: function zoomIn() { 1133 var winWidth = this.widowWidth(); 1134 1135 if (this.zoomedIn || winWidth <= 768) { 1136 return; 1137 } 1138 1139 var img = this.img; 1140 img.setAttribute('data-style', img.getAttribute('style')); 1141 img.style.maxWidth = img.naturalWidth + 'px'; 1142 img.style.maxHeight = img.naturalHeight + 'px'; 1143 1144 if (img.naturalWidth > winWidth) { 1145 var centerX = winWidth / 2 - img.naturalWidth / 2; 1146 this.setTranslate(this.img.parentNode, centerX, 0); 1147 } 1148 1149 this.slide.classList.add('zoomed'); 1150 this.zoomedIn = true; 1151 } 1152 }, {
1153 key: "zoomOut", 1154 value: function zoomOut() { 1155 this.img.parentNode.setAttribute('style', ''); 1156 this.img.setAttribute('style', this.img.getAttribute('data-style')); 1157 this.slide.classList.remove('zoomed'); 1158 this.zoomedIn = false; 1159 this.currentX = null; 1160 this.currentY = null; 1161 this.initialX = null; 1162 this.initialY = null; 1163 this.xOffset = 0; 1164 this.yOffset = 0; 1165 1166 if (this.onclose && typeof this.onclose == 'function') { 1167 this.onclose(); 1168 } 1169 } 1170 }, { 1171 key: "dragStart", 1172 value: function dragStart(e) { 1173 e.preventDefault(); 1174 1175 if (!this.zoomedIn) { 1176 this.active = false; 1177 return; 1178 } 1179 1180 if (e.type === "touchstart") { 1181 this.initialX = e.touches[0].clientX - this.xOffset; 1182 this.initialY = e.touches[0].clientY - this.yOffset; 1183 } else { 1184 this.initialX = e.clientX - this.xOffset; 1185 this.initialY = e.clientY - this.yOffset; 1186 } 1187 1188 if (e.target === this.img) { 1189 this.active = true; 1190 this.img.classList.add('dragging'); 1191 } 1192 } 1193 }, { 1194 key: "dragEnd", 1195 value: function dragEnd(e) { 1196 var _this2 = this; 1197 1198 e.preventDefault(); 1199 this.initialX = this.currentX; 1200 this.initialY = this.currentY; 1201 this.active = false; 1202 setTimeout(function () { 1203 _this2.dragging = false; 1204 _this2.img.isDragging = false; 1205 1206 _this2.img.classList.remove('dragging'); 1207 }, 100); 1208 } 1209 }, { 1210 key: "drag", 1211 value: function drag(e) { 1212 if (this.active) { 1213 e.preventDefault(); 1214 1215 if (e.type === 'touchmove') { 1216 this.currentX = e.touches[0].clientX - this.initialX; 1217 this.currentY = e.touches[0].clientY - this.initialY; 1218 } else { 1219 this.currentX = e.clientX - this.initialX; 1220 this.currentY = e.clientY - this.initialY; 1221 } 1222 1223 this.xOffset = this.currentX; 1224 this.yOffset = this.currentY; 1225 this.img.isDragging = true; 1226 this.dragging = true; 1227 this.setTranslate(this.img, this.currentX, this.currentY); 1228 } 1229 } 1230 }, { 1231 key: "onMove", 1232 value: function onMove(e) { 1233 if (!this.zoomedIn) { 1234 return; 1235 } 1236 1237 var xOffset = e.clientX - this.img.naturalWidth / 2; 1238 var yOffset = e.clientY - this.img.naturalHeight / 2; 1239 this.setTranslate(this.img, xOffset, yOffset); 1240 } 1241 }, { 1242 key: "setTranslate", 1243 value: function setTranslate(node, xPos, yPos) { 1244 node.style.transform = "translate3d(" + xPos + "px, " + yPos + "px, 0)"; 1245 } 1246 }, { 1247 key: "widowWidth", 1248 value: function widowWidth() { 1249 return window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth; 1250 } 1251 }]); 1252 1253 return ZoomImages; 1254 }(); 1255 1256 var isMobile = navigator.userAgent.match(/(iPad)|(iPhone)|(iPod)|(Android)|(PlayBook)|(BB10)|(BlackBerry)|(Opera Mini)|(IEMobile)|(webOS)|(MeeGo)/i); 1257 var isTouch = isMobile !== null || document.createTouch !== undefined || 'ontouchstart' in window || 'onmsgesturechange' in window || navigator.msMaxTouchPoints; 1258 var html = document.getElementsByTagName('html')[0]; 1259 var transitionEnd = whichTransitionEvent(); 1260 var animationEnd = whichAnimationEvent(); 1261 var uid = Date.now(); 1262 var videoPlayers = {}; 1263 var defaults = { 1264 selector: 'glightbox', 1265 elements: null, 1266 skin: 'clean', 1267 closeButton: true, 1268 startAt: null, 1269 autoplayVideos: true, 1270 descPosition: 'bottom', 1271 width: 900, 1272 height: 506, 1273 videosWidth: 960, 1274 beforeSlideChange: null, 1275 afterSlideChange: null, 1276 beforeSlideLoad: null, 1277 afterSlideLoad: null, 1278 onOpen: null, 1279 onClose: null, 1280 loopAtEnd: true, 1281 touchNavigation: true, 1282 keyboardNavigation: true, 1283 closeOnOutsideClick: true, 1284 plyr: { 1285 css: 'https://cdn.plyr.io/3.5.6/plyr.css', 1286 js: 'https://cdn.plyr.io/3.5.6/plyr.js', 1287 ratio: '16:9', 1288 config: { 1289 youtube: { 1290 noCookie: true, 1291 rel: 0, 1292 showinfo: 0, 1293 iv_load_policy: 3 1294 }, 1295 vimeo: { 1296 byline: false, 1297 portrait: false, 1298 title: false, 1299 transparent: false 1300 } 1301 } 1302 }, 1303 openEffect: 'zoomIn', 1304 closeEffect: 'zoomOut', 1305 slideEffect: 'slide', 1306 moreText: 'See more', 1307 moreLength: 60, 1308 lightboxHtml: '', 1309 cssEfects: { 1310 fade: { 1311 "in": 'fadeIn', 1312 out: 'fadeOut' 1313 }, 1314 zoom: { 1315 "in": 'zoomIn', 1316 out: 'zoomOut' 1317 }, 1318 slide: { 1319 "in": 'slideInRight', 1320 out: 'slideOutLeft' 1321 }, 1322 slide_back: { 1323 "in": 'slideInLeft', 1324 out: 'slideOutRight' 1325 } 1326 }, 1327 svg: { 1328 close: '<svg width="17px" height="18px">
1328<use xlink:href="/local/img/sprite.svg#close"></use></svg>', 1329 next: '<svg version="1.1" id="Capa_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 477.175 477.175" xml:space="preserve"> <g><path d="M360.731,229.075l-225.1-225.1c-5.3-5.3-13.8-5.3-19.1,0s-5.3,13.8,0,19.1l215.5,215.5l-215.5,215.5c-5.3,5.3-5.3,13.8,0,19.1c2.6,2.6,6.1,4,9.5,4c3.4,0,6.9-1.3,9.5-4l225.1-225.1C365.931,242.875,365.931,234.275,360.731,229.075z"/></g></svg>', 1330 prev: '<svg version="1.1" id="Capa_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 477.175 477.175" xml:space="preserve"><g><path d="M145.188,238.575l215.5-215.5c5.3-5.3,5.3-13.8,0-19.1s-13.8-5.3-19.1,0l-225.1,225.1c-5.3,5.3-5.3,13.8,0,19.1l225.1,225c2.6,2.6,6.1,4,9.5,4s6.9-1.3,9.5-4c5.3-5.3,5.3-13.8,0-19.1L145.188,238.575z"/></g></svg>' 1331 } 1332 }; 1333 var lightboxSlideHtml = "<div class=\"gslide\">\n <div class=\"gslide-inner-content\">\n <div class=\"ginner-container\">\n <div class=\"gslide-media\">\n </div>\n <div class=\"gslide-description\">\n <div class=\"gdesc-inner\">\n <h4 class=\"gslide-title\"></h4>\n <div class=\"gslide-desc\"></div>\n </div>\n </div>\n </div>\n </div>\n</div>"; 1334 defaults.slideHtml = lightboxSlideHtml; 1335 var lightboxHtml = "<div id=\"glightbox-body\" class=\"glightbox-container\">\n <div class=\"gloader visible\"></div>\n <div class=\"goverlay\"></div>\n <div class=\"gcontainer\">\n <div id=\"glightbox-slider\" class=\"gslider\"></div>\n <button class=\"gnext gbtn\" tabindex=\"0\">{nextSVG}</button>\n <button class=\"gprev gbtn\" tabindex=\"1\">{prevSVG}</button>\n <button class=\"gclose gbtn\" tabindex=\"2\">{closeSVG}</button>\n</div>\n</div>"; 1336 defaults.lightboxHtml = lightboxHtml; 1337 1338 function extend() { 1339 var extended = {}; 1340 var deep = false; 1341 var i = 0; 1342 var length = arguments.length; 1343 1344 if (Object.prototype.toString.call(arguments[0]) === '[object Boolean]') { 1345 deep = arguments[0]; 1346 i++; 1347 } 1348 1349 var merge = function merge(obj) { 1350 for (var prop in obj) { 1351 if (Object.prototype.hasOwnProperty.call(obj, prop)) { 1352 if (deep && Object.prototype.toString.call(obj[prop]) === '[object Object]') { 1353 extended[prop] = extend(true, extended[prop], obj[prop]); 1354 } else { 1355 extended[prop] = obj[prop]; 1356 } 1357 } 1358 } 1359 }; 1360 1361 for (; i < length; i++) { 1362 var obj = arguments[i]; 1363 merge(obj); 1364 } 1365 1366 return extended; 1367 } 1368 1369 var utils = { 1370 isFunction: function isFunction(f) { 1371 return typeof f === 'function'; 1372 }, 1373 isString: function isString(s) { 1374 return typeof s === 'string'; 1375 }, 1376 isNode: function isNode(el) { 1377 return !!(el && el.nodeType && el.nodeType == 1); 1378 }, 1379 isArray: function isArray(ar) { 1380 return Array.isArray(ar); 1381 }, 1382 isArrayLike: function isArrayLike(ar) { 1383 return ar && ar.length && isFinite(ar.length); 1384 }, 1385 isObject: function isObject(o) { 1386 var type = _typeof(o); 1387 1388 return type === 'object' && o != null && !utils.isFunction(o) && !utils.isArray(o); 1389 }, 1390 isNil: function isNil(o) { 1391 return o == null; 1392 }, 1393 has: function has(obj, key) { 1394 return obj !== null && hasOwnProperty.call(obj, key); 1395 }, 1396 size: function size(o) { 1397 if (utils.isObject(o)) { 1398 if (o.keys) { 1399 return o.keys().length; 1400 } 1401 1402 var l = 0; 1403 1404 for (var k in o) { 1405 if (utils.has(o, k)) { 1406 l++; 1407 } 1408 } 1409 1410 return l; 1411 } else { 1412 return o.length; 1413 } 1414 }, 1415 isNumber: function isNumber(n) { 1416 return !isNaN(parseFloat(n)) && isFinite(n); 1417 } 1418 }; 1419 1420 function each(collection, callback) { 1421 if (utils.isNode(collection) || collection === window || collection === document) { 1422 collection = [collection]; 1423 } 1424 1425 if (!utils.isArrayLike(collection) && !utils.isObject(collection)) { 1426 collection = [collection]; 1427 } 1428 1429 if (utils.size(collection) == 0) { 1430 return; 1431 } 1432 1433 if (utils.isArrayLike(collection) && !utils.isObject(collection)) { 1434 var l = collection.length, 1435 i = 0; 1436 1437 for (; i < l; i++) { 1438 if (callback.call(collection[i], collection[i], i, collection) === false) { 1439 break; 1440 } 1441 } 1442 } else if (utils.isObject(collection)) { 1443 for (var key in collection) { 1444 if (utils.has(collection, key)) { 1445 if (callback.call(collection[key], collection[key], key, collection) === false) { 1446 break; 1447 } 1448 } 1449 } 1450 } 1451 } 1452 1453 function getNodeEvents(node) { 1454 var name = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null; 1455 var fn = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null; 1456 var cache = node[uid] = node[uid] || []; 1457 var data = { 1458 all: cache, 1459 evt: null, 1460 found: null 1461 }; 1462 1463 if (name && fn && utils.size(cache) > 0) { 1464 each(cache, function (cl, i) { 1465 if (cl.eventName == name && cl.fn.toString() == fn.toString()) { 1466 data.found = true; 1467 data.evt = i; 1468 return false;
1469 } 1470 }); 1471 } 1472 1473 return data; 1474 } 1475 1476 function addEvent(eventName) { 1477 var _ref = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}, 1478 onElement = _ref.onElement, 1479 withCallback = _ref.withCallback, 1480 _ref$avoidDuplicate = _ref.avoidDuplicate, 1481 avoidDuplicate = _ref$avoidDuplicate === void 0 ? true : _ref$avoidDuplicate, 1482 _ref$once = _ref.once, 1483 once = _ref$once === void 0 ? false : _ref$once, 1484 _ref$useCapture = _ref.useCapture, 1485 useCapture = _ref$useCapture === void 0 ? false : _ref$useCapture; 1486 1487 var thisArg = arguments.length > 2 ? arguments[2] : undefined; 1488 var element = onElement || []; 1489 1490 if (utils.isString(element)) { 1491 element = document.querySelectorAll(element); 1492 } 1493 1494 function handler(event) { 1495 if (utils.isFunction(withCallback)) { 1496 withCallback.call(thisArg, event, this); 1497 } 1498 1499 if (once) { 1500 handler.destroy(); 1501 } 1502 } 1503 1504 handler.destroy = function () { 1505 each(element, function (el) { 1506 var events = getNodeEvents(el, eventName, handler); 1507 1508 if (events.found) { 1509 events.all.splice(events.evt, 1); 1510 } 1511 1512 if (el.removeEventListener) el.removeEventListener(eventName, handler, useCapture); 1513 }); 1514 }; 1515 1516 each(element, function (el) { 1517 var events = getNodeEvents(el, eventName, handler); 1518 1519 if (el.addEventListener && avoidDuplicate && !events.found || !avoidDuplicate) { 1520 el.addEventListener(eventName, handler, useCapture); 1521 events.all.push({ 1522 eventName: eventName, 1523 fn: handler 1524 }); 1525 } 1526 }); 1527 return handler; 1528 } 1529 1530 function addClass(node, name) { 1531 each(name.split(' '), function (cl) { 1532 return node.classList.add(cl); 1533 }); 1534 } 1535 1536 function removeClass(node, name) { 1537 each(name.split(' '), function (cl) { 1538 return node.classList.remove(cl); 1539 }); 1540 } 1541 1542 function hasClass(node, name) { 1543 return node.classList.contains(name); 1544 } 1545 1546 function whichAnimationEvent() { 1547 var t, 1548 el = document.createElement("fakeelement"); 1549 var animations = { 1550 animation: "animationend", 1551 OAnimation: "oAnimationEnd", 1552 MozAnimation: "animationend", 1553 WebkitAnimation: "webkitAnimationEnd" 1554 }; 1555 1556 for (t in animations) { 1557 if (el.style[t] !== undefined) { 1558 return animations[t]; 1559 } 1560 } 1561 } 1562 1563 function whichTransitionEvent() { 1564 var t, 1565 el = document.createElement("fakeelement"); 1566 var transitions = { 1567 transition: "transitionend", 1568 OTransition: "oTransitionEnd", 1569 MozTransition: "transitionend", 1570 WebkitTransition: "webkitTransitionEnd" 1571 }; 1572 1573 for (t in transitions) { 1574 if (el.style[t] !== undefined) { 1575 return transitions[t]; 1576 } 1577 } 1578 } 1579 1580 function animateElement(element) { 1581 var animation = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ''; 1582 var callback = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false; 1583 1584 if (!element || animation === '') { 1585 return false; 1586 } 1587 1588 if (animation == 'none') { 1589 if (utils.isFunction(callback)) callback(); 1590 return false; 1591 } 1592 1593 var animationNames = animation.split(' '); 1594 each(animationNames, function (name) { 1595 addClass(element, 'g' + name); 1596 }); 1597 addEvent(animationEnd, { 1598 onElement: element, 1599 avoidDuplicate: false, 1600 once: true, 1601 withCallback: function withCallback(event, target) { 1602 each(animationNames, function (name) { 1603 removeClass(target, 'g' + name); 1604 }); 1605 if (utils.isFunction(callback)) callback(); 1606 } 1607 }); 1608 } 1609 1610 function createHTML(htmlStr) { 1611 var frag = document.createDocumentFragment(), 1612 temp = document.createElement('div'); 1613 temp.innerHTML = htmlStr; 1614 1615 while (temp.firstChild) { 1616 frag.appendChild(temp.firstChild); 1617 } 1618 1619 return frag; 1620 } 1621 1622 function getClosest(elem, selector) { 1623 while (elem !== document.body) { 1624 elem = elem.parentElement; 1625 var matches = typeof elem.matches == 'function' ? elem.matches(selector) : elem.msMatchesSelector(selector); 1626 if (matches) return elem; 1627 } 1628 } 1629 1630 function show(element) { 1631 element.style.display = 'block'; 1632 } 1633 1634 function hide(element) { 1635 element.style.display = 'none'; 1636 } 1637 1638 function windowSize() { 1639 return { 1640 width: window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth, 1641 height: window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight 1642 }; 1643 } 1644 1645 function handleMediaFullScreen(event) { 1646 if (!hasClass(event.target, 'plyr--html5')) { 1647 return; 1648 } 1649 1650 var media = getClosest(event.target, '.gslide-media'); 1651 1652 if (event.type == 'enterfullscreen') { 1653 addClass(media, 'fullscreen'); 1654 } 1655 1656 if (event.type == 'exitfullscreen') { 1657 removeClass(media, 'fullscreen'); 1658 } 1659 } 1660 1661 var getSlideData = function getSlideData() { 1662 var element = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null; 1663 var settings = arguments.length > 1 ? arguments[1] : undefined; 1664 var data = { 1665 href: '', 1666 title: '', 1667 type: '', 1668 description: '', 1669 descPosition: settings.descPosition, 1670 effect: '', 1671 width: '', 1672 height: '', 1673 node: element 1674 }; 1675 1676 if (utils.isObject(element) && !utils.isNode(element)) { 1677 return extend(data, element); 1678 } 1679 1680 var url = ''; 1681 var config = element.getAttribute('data-glightbox'); 1682 var nodeType = element.nodeName.toLowerCase(); 1683 if (nodeType === 'a') url = element.href; 1684 if (nodeType === 'img') url = element.src; 1685 data.href = url; 1686 each(data, function (val, key) { 1687 if (utils.has(settings, key) && key !== 'width') { 1688 data[key] = settings[key]; 1689 } 1690 1691 var nodeData = element.dataset[key]; 1692 1693 if (!utils.isNil(nodeData)) { 1694 data[key] = nodeData; 1695 } 1696 }); 1697 1698 if (!data.type) { 1699 data.type = getSourceType(url); 1700 } 1701 1702 if (!utils.isNil(config)) { 1703 var cleanKeys = []; 1704 each(data, function (v, k) { 1705 cleanKeys.push(';\\s?' + k); 1706 }); 1707 cleanKeys = cleanKeys.join('\\s?:|'); 1708 1709 if (config.trim() !== '') { 1710 each(data, function (val, key) { 1711 var str = config; 1712 var match = '\s?' + key + '\s?:\s?(.*?)(' + cleanKeys + '\s?:|$)'; 1713 var regex = new RegExp(match); 1714 var matches = str.match(regex); 1715 1716 if (matches && matches.length && matches[1]) { 1717 var value = matches[1].trim().replace(/;\s*$/, ''); 1718 data[key] = value; 1719 } 1720 }); 1721 } 1722 } else { 1723 if (nodeType == 'a') { 1724 var title = element.title; 1725 if (!utils.isNil(title) && title !== '') data.title = title; 1726 } 1727 1728 if (nodeType == 'img') { 1729 var alt = element.alt; 1730 if (!utils.isNil(alt) && alt !== '') data.title = alt; 1731 } 1732 1733 var desc = element.getAttribute('data-description'); 1734 if (!utils.isNil(desc) && desc !== '') data.description = desc; 1735 } 1736 1737 if (data.description && data.description.substring(0, 1) == '.' && document.querySelector(data.description)) { 1738 data.description = document.querySelector(data.description).innerHTML; 1739 } else { 1740 var nodeDesc = element.querySelector('.glightbox-desc'); 1741 1742 if (nodeDesc) { 1743 data.description = nodeDesc.innerHTML; 1744 } 1745 } 1746 1747 var defaultWith = data.type == 'video' ? settings.videosWidth : settings.width; 1748 var defaultHeight = settings.height; 1749 data.width = utils.has(data, 'width') && data.width !== '' ? data.width : defaultWith; 1750 data.height = utils.has(data, 'height') && data.height !== '' ? data.height : defaultHeight; 1751 return data; 1752 }; 1753 1754 var setSlideContent = function setSlideContent() { 1755 var _this = this; 1756 1757 var slide = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null; 1758 var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; 1759 var callback = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
1760 1761 if (hasClass(slide, 'loaded')) { 1762 return false; 1763 } 1764 1765 if (utils.isFunction(this.settings.beforeSlideLoad)) { 1766 this.settings.beforeSlideLoad(slide, data); 1767 } 1768 1769 var type = data.type; 1770 var position = data.descPosition; 1771 var slideMedia = slide.querySelector('.gslide-media'); 1772 var slideTitle = slide.querySelector('.gslide-title'); 1773 var slideText = slide.querySelector('.gslide-desc'); 1774 var slideDesc = slide.querySelector('.gdesc-inner'); 1775 var finalCallback = callback; 1776 1777 if (utils.isFunction(this.settings.afterSlideLoad)) { 1778 finalCallback = function finalCallback() { 1779 if (utils.isFunction(callback)) { 1780 callback(); 1781 } 1782 1783 _this.settings.afterSlideLoad(slide, data); 1784 }; 1785 } 1786 1787 if (data.title == '' && data.description == '') { 1788 if (slideDesc) { 1789 slideDesc.parentNode.parentNode.removeChild(slideDesc.parentNode); 1790 } 1791 } else { 1792 if (slideTitle && data.title !== '') { 1793 slideTitle.innerHTML = data.title; 1794 } else { 1795 slideTitle.parentNode.removeChild(slideTitle); 1796 } 1797 1798 if (slideText && data.description !== '') { 1799 if (isMobile && this.settings.moreLength > 0) {
1800 data.smallDescription = slideShortDesc(data.description, this.settings.moreLength, this.settings.moreText); 1801 slideText.innerHTML = data.smallDescription; 1802 slideDescriptionEvents.apply(this, [slideText, data]); 1803 } else { 1804 slideText.innerHTML = data.description; 1805 } 1806 } else { 1807 slideText.parentNode.removeChild(slideText); 1808 } 1809 1810 addClass(slideMedia.parentNode, "desc-".concat(position)); 1811 addClass(slideDesc.parentNode, "description-".concat(position)); 1812 } 1813 1814 addClass(slideMedia, "gslide-".concat(type)); 1815 addClass(slide, 'loaded'); 1816 1817 if (type === 'video') { 1818 addClass(slideMedia.parentNode, "gvideo-container"); 1819 slideMedia.insertBefore(createHTML('<div class="gvideo-wrapper"></div>'), slideMedia.firstChild); 1820 setSlideVideo.apply(this, [slide, data, finalCallback]); 1821 return; 1822 } 1823 1824 if (type === 'external') { 1825 var iframe = createIframe({ 1826 url: data.href, 1827 width: data.width, 1828 height: data.height, 1829 callback: finalCallback 1830 }); 1831 slideMedia.parentNode.style.maxWidth = "".concat(data.width, "px"); 1832 slideMedia.appendChild(iframe); 1833 return; 1834 } 1835 1836 if (type === 'inline') { 1837 setInlineContent.apply(this, [slide, data, finalCallback]); 1838 return; 1839 } 1840 1841 if (type === 'image') { 1842 var img = new Image(); 1843 img.addEventListener('load', function () { 1844 if (!isMobile && img.naturalWidth > img.offsetWidth) { 1845 addClass(img, 'zoomable'); 1846 new ZoomImages(img, slide, function () { 1847 _this.resize(slide); 1848 }); 1849 } 1850 1851 if (utils.isFunction(finalCallback)) { 1852 finalCallback(); 1853 } 1854 }, false); 1855 img.src = data.href; 1856 slideMedia.insertBefore(img, slideMedia.firstChild); 1857 return; 1858 } 1859 1860 if (utils.isFunction(finalCallback)) finalCallback(); 1861 }; 1862 1863 function setSlideVideo(slide, data, callback) { 1864 var _this2 = this; 1865 1866 var videoID = 'gvideo' + data.index; 1867 var slideMedia = slide.querySelector('.gvideo-wrapper'); 1868 injectVideoApi(this.settings.plyr.css); 1869 var url = data.href; 1870 var protocol = location.protocol.replace(':', ''); 1871 var videoSource = ''; 1872 var embedID = ''; 1873 var customPlaceholder = false; 1874 1875 if (protocol == 'file') { 1876 protocol = 'http'; 1877 } 1878 1879 slideMedia.parentNode.style.maxWidth = "".concat(data.width, "px"); 1880 injectVideoApi(this.settings.plyr.js, 'Plyr', function () { 1881 if (url.match(/vimeo\.com\/([0-9]*)/)) { 1882 var vimeoID = /vimeo.*\/(\d+)/i.exec(url); 1883 videoSource = 'vimeo'; 1884 embedID = vimeoID[1]; 1885 } 1886 1887 if (url.match(/(youtube\.com|youtube-nocookie\.com)\/watch\?v=([a-zA-Z0-9\-_]+)/) || url.match(/youtu\.be\/([a-zA-Z0-9\-_]+)/) || url.match(/(youtube\.com|youtube-nocookie\.com)\/embed\/([a-zA-Z0-9\-_]+)/)) { 1888 var youtubeID = getYoutubeID(url); 1889 videoSource = 'youtube'; 1890 embedID = youtubeID; 1891 } 1892 1893 if (url.match(/\.(mp4|ogg|webm)$/) !== null) { 1894 videoSource = 'local'; 1895 1896 var _html = '<video id="' + videoID + '" '; 1897 1898 _html += "style=\"background:#000; max-width: ".concat(data.width, "px;\" "); 1899 _html += 'preload="metadata" '; 1900 //_html += 'autoplay="autoplay" '; 1901 _html += 'loop="loop" '; 1902 _html += 'x-webkit-airplay="allow" '; 1903 _html += 'webkit-playsinline="" '; 1904 _html += 'controls '; 1905 _html += 'class="gvideo-local">'; 1906 var format = url.toLowerCase().split('.').pop(); 1907 var sources = { 1908 'mp4': '', 1909 'ogg': '', 1910 'webm': '' 1911 }; 1912 sources[format] = url; 1913 1914 for (var key in sources) { 1915 if (sources.hasOwnProperty(key)) { 1916 var videoFile = sources[key]; 1917 1918 if (data.hasOwnProperty(key)) { 1919 videoFile = data[key]; 1920 } 1921 1922 if (videoFile !== '') { 1923 _html += "<source src=\"".concat(videoFile, "\" type=\"video/").concat(key, "\">"); 1924 } 1925 } 1926 } 1927 1928 _html += '</video>'; 1929 customPlaceholder = createHTML(_html); 1930 } 1931 1932 var placeholder = customPlaceholder ? customPlaceholder : createHTML("<div id=\"".concat(videoI
1932D, "\" data-plyr-provider=\"").concat(videoSource, "\" data-plyr-embed-id=\"").concat(embedID, "\"></div>")); 1933 addClass(slideMedia, "".concat(videoSource, "-video gvideo")); 1934 slideMedia.appendChild(placeholder); 1935 slideMedia.setAttribute('data-id', videoID); 1936 var playerConfig = utils.has(_this2.settings.plyr, 'config') ? _this2.settings.plyr.config : {}; 1937 var player = new Plyr('#' + videoID, playerConfig); 1938 player.on('ready', function (event) { 1939 var instance = event.detail.plyr; 1940 videoPlayers[videoID] = instance; 1941 1942 if (utils.isFunction(callback)) { 1943 callback(); 1944 } 1945 }); 1946 player.on('enterfullscreen', handleMediaFullScreen); 1947 player.on('exitfullscreen', handleMediaFullScreen); 1948 }); 1949 } 1950 1951 function createIframe(config) { 1952 var url = config.url, 1953 width = config.width, 1954 height = config.height, 1955 allow = config.allow, 1956 callback = config.callback, 1957 appendTo = config.appendTo; 1958 var iframe = document.createElement('iframe'); 1959 var winWidth = window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth; 1960 iframe.className = 'vimeo-video gvideo'; 1961 iframe.src = url; 1962 1963 if (height) { 1964 if (isMobile && winWidth < 767) { 1965 iframe.style.height = ''; 1966 } else { 1967 iframe.style.height = "".concat(height, "px"); 1968 } 1969 } 1970 1971 if (width) { 1972 iframe.style.width = "".concat(width, "px"); 1973 } 1974 1975 if (allow) { 1976 iframe.setAttribute('allow', allow); 1977 } 1978 1979 iframe.onload = function () { 1980 addClass(iframe, 'node-ready'); 1981 1982 if (utils.isFunction(callback)) { 1983 callback(); 1984 } 1985 }; 1986 1987 if (appendTo) { 1988 appendTo.appendChild(iframe); 1989 } 1990 1991 return iframe; 1992 } 1993 1994 function getYoutubeID(url) { 1995 var videoID = ''; 1996 url = url.replace(/(>|<)/gi, '').split(/(vi\/|v=|\/v\/|youtu\.be\/|\/embed\/)/); 1997 1998 if (url[2] !== undefined) { 1999 videoID = url[2].split(/[^0-9a-z_\-]/i); 2000 videoID = videoID[0]; 2001 } else { 2002 videoID = url; 2003 } 2004 2005 return videoID; 2006 } 2007 2008 function injectVideoApi(url, waitFor, callback) { 2009 if (utils.isNil(url)) { 2010 console.error('Inject videos api error'); 2011 return; 2012 } 2013 2014 if (utils.isFunction(waitFor)) { 2015 callback = waitFor; 2016 waitFor = false; 2017 } 2018 2019 var found; 2020 2021 if (url.indexOf('.css') !== -1) { 2022 found = document.querySelectorAll('link[href="' + url + '"]'); 2023 2024 if (found && found.length > 0) { 2025 if (utils.isFunction(callback)) callback(); 2026 return; 2027 } 2028 2029 var head = document.getElementsByTagName("head")[0]; 2030 var headStyles = head.querySelectorAll('link[rel="stylesheet"]'); 2031 var link = document.createElement('link'); 2032 link.rel = 'stylesheet'; 2033 link.type = 'text/css'; 2034 link.href = url; 2035 link.media = 'all'; 2036 2037 if (headStyles) { 2038 head.insertBefore(link, headStyles[0]); 2039 } else { 2040 head.appendChild(link); 2041 } 2042 2043 if (utils.isFunction(callback)) callback(); 2044 return; 2045 } 2046 2047 found = document.querySelectorAll('script[src="' + url + '"]'); 2048 2049 if (found && found.length > 0) { 2050 if (utils.isFunction(callback)) { 2051 if (utils.isString(waitFor)) { 2052 waitUntil(function () { 2053 return typeof window[waitFor] !== 'undefined'; 2054 }, function () { 2055 callback(); 2056 }); 2057 return false; 2058 } 2059 2060 callback(); 2061 } 2062 2063 return; 2064 } 2065 2066 var script = document.createElement('script'); 2067 script.type = 'text/javascript'; 2068 script.src = url; 2069 2070 script.onload = function () { 2071 if (utils.isFunction(callback)) { 2072 if (utils.isString(waitFor)) { 2073 waitUntil(function () { 2074 return typeof window[waitFor] !== 'undefined'; 2075 }, function () { 2076 callback(); 2077 }); 2078 return false; 2079 } 2080 2081 callback(); 2082 } 2083 }; 2084 2085 document.body.appendChild(script); 2086 return; 2087 } 2088 2089 function waitUntil(check, onComplete, delay, timeout) { 2090 if (check()) { 2091 onComplete(); 2092 return; 2093 } 2094 2095 if (!delay) delay = 100; 2096 var timeoutPointer; 2097 var intervalPointer = setInterval(function () { 2098 if (!check()) return; 2099 clearInterval(intervalPointer); 2100 if (timeoutPointer) clearTimeout(timeoutPointer); 2101 onComplete(); 2102 }, delay); 2103 if (timeout) timeoutPointer = setTimeout(function () { 2104 clearInterval(intervalPointer); 2105 }, timeout); 2106 } 2107 2108 function setInlineContent(slide, data, callback) { 2109 var _this3 = this; 2110 2111 var slideMedia = slide.querySelector('.gslide-media'); 2112 var hash = data.href.split('#').pop().trim(); 2113 var div = document.getElementById(hash); 2114 2115 if (!div) { 2116 return false;
2117 } 2118 2119 var cloned = div.cloneNode(true); 2120 cloned.style.height = utils.isNumber(data.height) ? "".concat(data.height, "px") : data.height; 2121 cloned.style.maxWidth = utils.isNumber(data.width) ? "".concat(data.width, "px") : data.width; 2122 addClass(cloned, 'ginlined-content'); 2123 slideMedia.appendChild(cloned); 2124 this.events['inlineclose' + hash] = addEvent('click', { 2125 onElement: slideMedia.querySelectorAll('.gtrigger-close'), 2126 withCallback: function withCallback(e) { 2127 e.preventDefault(); 2128 2129 _this3.close(); 2130 } 2131 }); 2132 2133 if (utils.isFunction(callback)) { 2134 callback(); 2135 } 2136 2137 return; 2138 } 2139 2140 var getSourceType = function getSourceType(url) { 2141 var origin = url; 2142 url = url.toLowerCase(); 2143 2144 if (url.match(/\.(jpeg|jpg|gif|png|apn|webp|svg)$/) !== null) { 2145 return 'image'; 2146 } 2147 2148 if (url.match(/(youtube\.com|youtube-nocookie\.com)\/watch\?v=([a-zA-Z0-9\-_]+)/) || url.match(/youtu\.be\/([a-zA-Z0-9\-_]+)/) || url.match(/(youtube\.com|youtube-nocookie\.com)\/embed\/([a-zA-Z0-9\-_]+)/)) { 2149 return 'video'; 2150 } 2151 2152 if (url.match(/vimeo\.com\/([0-9]*)/)) { 2153 return 'video'; 2154 } 2155 2156 if (url.match(/\.(mp4|ogg|webm)$/) !== null) { 2157 return 'video'; 2158 } 2159 2160 if (url.indexOf("#") > -1) { 2161 var hash = origin.split('#').pop(); 2162 2163 if (hash.trim() !== '') { 2164 return 'inline'; 2165 } 2166 } 2167 2168 if (url.includes("gajax=true")) { 2169 return 'ajax'; 2170 } 2171 2172 return 'external'; 2173 }; 2174 2175 function keyboardNavigation() { 2176 var _this4 = this; 2177 2178 if (this.events.hasOwnProperty('keyboard')) { 2179 return false; 2180 } 2181 2182 this.events['keyboard'] = addEvent('keydown', { 2183 onElement: window, 2184 withCallback: function withCallback(event, target) { 2185 event = event || window.event; 2186 var key = event.keyCode; 2187 2188 if (key == 9) { 2189 event.preventDefault(); 2190 var btns = document.querySelectorAll('.gbtn'); 2191 2192 if (!btns || btns.length <= 0) { 2193 return; 2194 } 2195 2196 var focused = _toConsumableArray(btns).filter(function (item) { 2197 return hasClass(item, 'focused'); 2198 }); 2199 2200 if (!focused.length) { 2201 var first = document.querySelector('.gbtn[tabindex="0"]'); 2202 2203 if (first) { 2204 first.focus(); 2205 addClass(first, 'focused'); 2206 } 2207 2208 return; 2209 } 2210 2211 btns.forEach(function (element) { 2212 return removeClass(element, 'focused'); 2213 }); 2214 var tabindex = focused[0].getAttribute('tabindex'); 2215 tabindex = tabindex ? tabindex : '0'; 2216 var newIndex = parseInt(tabindex) + 1; 2217 2218 if (newIndex > btns.length - 1) { 2219 newIndex = '0'; 2220 } 2221 2222 var next = document.querySelector(".gbtn[tabindex=\"".concat(newIndex, "\"]")); 2223 2224 if (next) { 2225 next.focus(); 2226 addClass(next, 'focused'); 2227 } 2228 } 2229 2230 if (key == 39) _this4.nextSlide(); 2231 if (key == 37) _this4.prevSlide(); 2232 if (key == 27) _this4.close(); 2233 } 2234 }); 2235 } 2236 2237 function touchNavigation() { 2238 var _this5 = this; 2239 2240 if (this.events.hasOwnProperty('touch')) { 2241 return false; 2242 } 2243 2244 var winSize = windowSize(); 2245 var winWidth = winSize.width; 2246 var winHeight = winSize.height; 2247 var process = false; 2248 var currentSlide = null; 2249 var media = null; 2250 var mediaImage = null; 2251 var doingMove = false; 2252 var initScale = 1; 2253 var maxScale = 4.5; 2254 var currentScale = 1; 2255 var doingZoom = false;
2256 var imageZoomed = false; 2257 var zoomedPosX = null; 2258 var zoomedPosY = null; 2259 var lastZoomedPosX = null; 2260 var lastZoomedPosY = null; 2261 var hDistance; 2262 var vDistance; 2263 var hDistancePercent = 0; 2264 var vDistancePercent = 0; 2265 var vSwipe = false; 2266 var hSwipe = false; 2267 var startCoords = {}; 2268 var endCoords = {}; 2269 var xDown = 0; 2270 var yDown = 0; 2271 var isInlined; 2272 var instance = this; 2273 var sliderWrapper = document.getElementById('glightbox-slider'); 2274 var overlay = document.querySelector('.goverlay'); 2275 var touchInstance = new TouchEvents(sliderWrapper, { 2276 touchStart: function touchStart(e) { 2277 if (hasClass(e.targetTouches[0].target, 'ginner-container')) { 2278 process = false; 2279 return false; 2280 } 2281 2282 process = true; 2283 endCoords = e.targetTouches[0]; 2284 startCoords.pageX = e.targetTouches[0].pageX; 2285 startCoords.pageY = e.targetTouches[0].pageY; 2286 xDown = e.targetTouches[0].clientX; 2287 yDown = e.targetTouches[0].clientY; 2288 currentSlide = instance.activeSlide; 2289 media = currentSlide.querySelector('.gslide-media'); 2290 isInlined = currentSlide.querySelector('.gslide-inline'); 2291 mediaImage = null; 2292 2293 if (hasClass(media, 'gslide-image')) { 2294 mediaImage = media.querySelector('img'); 2295 } 2296 2297 removeClass(overlay, 'greset'); 2298 }, 2299 touchMove: function touchMove(e) { 2300 if (!process) { 2301 return; 2302 } 2303 2304 endCoords = e.targetTouches[0]; 2305 2306 if (doingZoom || imageZoomed) { 2307 return; 2308 } 2309 2310 if (isInlined && isInlined.offsetHeight > winHeight) {
vendor: 3,086 bytes, lines 2311-2421
2311 var moved = startCoords.pageX - endCoords.pageX; 2312 2313 if (Math.abs(moved) <= 13) { 2314 return false; 2315 } 2316 } 2317 2318 doingMove = true; 2319 var xUp = e.targetTouches[0].clientX; 2320 var yUp = e.targetTouches[0].clientY; 2321 var xDiff = xDown - xUp; 2322 var yDiff = yDown - yUp; 2323 2324 if (Math.abs(xDiff) > Math.abs(yDiff)) { 2325 vSwipe = false; 2326 hSwipe = true; 2327 } else { 2328 hSwipe = false; 2329 vSwipe = true; 2330 } 2331 2332 hDistance = endCoords.pageX - startCoords.pageX; 2333 hDistancePercent = hDistance * 100 / winWidth; 2334 vDistance = endCoords.pageY - startCoords.pageY; 2335 vDistancePercent = vDistance * 100 / winHeight; 2336 var opacity; 2337 2338 if (vSwipe && mediaImage) { 2339 opacity = 1 - Math.abs(vDistance) / winHeight; 2340 overlay.style.opacity = opacity; 2341 } 2342 2343 if (hSwipe) { 2344 opacity = 1 - Math.abs(hDistance) / winWidth; 2345 media.style.opacity = opacity; 2346 } 2347 2348 if (!mediaImage) { 2349 return slideCSSTransform(media, "translate3d(".concat(hDistancePercent, "%, 0, 0)")); 2350 } 2351 2352 slideCSSTransform(media, "translate3d(".concat(hDistancePercent, "%, ").concat(vDistancePercent, "%, 0)")); 2353 }, 2354 touchEnd: function touchEnd() { 2355 if (!process) { 2356 return; 2357 } 2358 2359 doingMove = false; 2360 2361 if (imageZoomed || doingZoom) { 2362 lastZoomedPosX = zoomedPosX; 2363 lastZoomedPosY = zoomedPosY; 2364 return; 2365 } 2366 2367 var v = Math.abs(parseInt(vDistancePercent)); 2368 var h = Math.abs(parseInt(hDistancePercent)); 2369 2370 if (v > 35 && mediaImage) { 2371 _this5.close(); 2372 2373 return; 2374 } 2375 2376 if (v < 35 && h < 25) { 2377 addClass(overlay, 'greset'); 2378 overlay.style.opacity = 1; 2379 return resetSlideMove(media); 2380 } 2381 }, 2382 multipointEnd: function multipointEnd() { 2383 setTimeout(function () { 2384 doingZoom = false; 2385 }, 50); 2386 }, 2387 multipointStart: function multipointStart() { 2388 doingZoom = true; 2389 initScale = currentScale ? currentScale : 1; 2390 }, 2391 pinch: function pinch(evt) { 2392 if (!mediaImage || doingMove) { 2393 return false; 2394 } 2395 2396 doingZoom = true; 2397 mediaImage.scaleX = mediaImage.scaleY = initScale * evt.zoom; 2398 var scale = initScale * evt.zoom; 2399 imageZoomed = true; 2400 2401 if (scale <= 1) { 2402 imageZoomed = false; 2403 scale = 1; 2404 lastZoomedPosY = null; 2405 lastZoomedPosX = null; 2406 zoomedPosX = null; 2407 zoomedPosY = null; 2408 mediaImage.setAttribute('style', ''); 2409 return; 2410 } 2411 2412 if (scale > maxScale) { 2413 scale = maxScale; 2414 } 2415 2416 mediaImage.style.transform = "scale3d(".concat(scale, ", ").concat(scale, ", 1)"); 2417 currentScale = scale; 2418 }, 2419 pressMove: function pressMove(e) { 2420 if (imageZoomed && !doingZoom) { 2421 var mhDistance = endCoords.pageX
2421- startCoords.pageX; 2422 var mvDistance = endCoords.pageY - startCoords.pageY; 2423 2424 if (lastZoomedPosX) { 2425 mhDistance = mhDistance + lastZoomedPosX; 2426 } 2427 2428 if (lastZoomedPosY) { 2429 mvDistance = mvDistance + lastZoomedPosY; 2430 } 2431 2432 zoomedPosX = mhDistance; 2433 zoomedPosY = mvDistance; 2434 var style = "translate3d(".concat(mhDistance, "px, ").concat(mvDistance, "px, 0)"); 2435 2436 if (currentScale) { 2437 style += " scale3d(".concat(currentScale, ", ").concat(currentScale, ", 1)"); 2438 } 2439 2440 slideCSSTransform(mediaImage, style); 2441 } 2442 }, 2443 swipe: function swipe(evt) { 2444 if (imageZoomed) { 2445 return; 2446 } 2447 2448 if (doingZoom) { 2449 doingZoom = false; 2450 return; 2451 } 2452 2453 if (evt.direction == 'Left') { 2454 if (_this5.index == _this5.elements.length - 1) { 2455 return resetSlideMove(media); 2456 } 2457 2458 _this5.nextSlide(); 2459 } 2460 2461 if (evt.direction == 'Right') { 2462 if (_this5.index == 0) { 2463 return resetSlideMove(media); 2464 } 2465 2466 _this5.prevSlide(); 2467 } 2468 } 2469 }); 2470 this.events['touch'] = touchInstance; 2471 } 2472 2473 function slideCSSTransform(slide) { 2474 var translate = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ''; 2475 2476 if (translate == '') { 2477 slide.style.webkitTransform = ''; 2478 slide.style.MozTransform = ''; 2479 slide.style.msTransform = ''; 2480 slide.style.OTransform = ''; 2481 slide.style.transform = ''; 2482 return false; 2483 } 2484 2485 slide.style.webkitTransform = translate; 2486 slide.style.MozTransform = translate; 2487 slide.style.msTransform = translate; 2488 slide.style.OTransform = translate; 2489 slide.style.transform = translate; 2490 } 2491 2492 function resetSlideMove(slide) { 2493 var media = hasClass(slide, 'gslide-media') ? slide : slide.querySelector('.gslide-media'); 2494 var desc = slide.querySelector('.gslide-description'); 2495 addClass(media, 'greset'); 2496 slideCSSTransform(media, "translate3d(0, 0, 0)"); 2497 var animation = addEvent(transitionEnd, { 2498 onElement: media, 2499 once: true, 2500 withCallback: function withCallback(event, target) { 2501 removeClass(media, 'greset'); 2502 } 2503 }); 2504 media.style.opacity = ''; 2505 2506 if (desc) { 2507 desc.style.opacity = ''; 2508 } 2509 } 2510
2511 function slideShortDesc(string) { 2512 var n = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 50; 2513 var wordBoundary = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false; 2514 var useWordBoundary = wordBoundary; 2515 string = string.trim(); 2516 2517 if (string.length <= n) { 2518 return string; 2519 } 2520 2521 var subString = string.substr(0, n - 1); 2522 2523 if (!useWordBoundary) { 2524 return subString; 2525 } 2526 2527 return subString + '... <a href="#" class="desc-more">' + wordBoundary + '</a>'; 2528 } 2529 2530 function slideDescriptionEvents(desc, data) { 2531 var moreLink = desc.querySelector('.desc-more'); 2532 2533 if (!moreLink) { 2534 return false; 2535 } 2536 2537 addEvent('click', { 2538 onElement: moreLink, 2539 withCallback: function withCallback(event, target) { 2540 event.preventDefault(); 2541 var body = document.body; 2542 var desc = getClosest(target, '.gslide-desc'); 2543 2544 if (!desc) { 2545 return false; 2546 } 2547 2548 desc.innerHTML = data.description; 2549 addClass(body, 'gdesc-open'); 2550 var shortEvent = addEvent('click', { 2551 onElement: [body, getClosest(desc, '.gslide-description')], 2552 withCallback: function withCallback(event, target) { 2553 if (event.target.nodeName.toLowerCase() !== 'a') { 2554 removeClass(body, 'gdesc-open'); 2555 addClass(body, 'gdesc-closed'); 2556 desc.innerHTML = data.smallDescription; 2557 slideDescriptionEvents(desc, data); 2558 setTimeout(function () { 2559 removeClass(body, 'gdesc-closed'); 2560 }, 400); 2561 shortEvent.destroy(); 2562 } 2563 } 2564 }); 2565 } 2566 }); 2567 } 2568 2569 var GlightboxInit = function () { 2570 function GlightboxInit(options) { 2571 _classCallCheck(this, GlightboxInit); 2572 2573 this.settings = extend(defaults, options || {}); 2574 this.effectsClasses = this.getAnimationClasses(); 2575 this.slidesData = {}; 2576 } 2577 2578 _createClass(GlightboxInit, [{ 2579 key: "init", 2580 value: function init() { 2581 var _this6 = this; 2582 2583 this.baseEvents = addEvent('click', { 2584 onElement: ".".concat(this.settings.selector), 2585 withCallback: function withCallback(e, target) { 2586 e.preventDefault(); 2587 2588 _this6.open(target); 2589 } 2590 }); 2591 } 2592 }, { 2593 key: "open", 2594 value: function open() { 2595 var element = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null; 2596 this.elements = this.getElements(element); 2597 if (this.elements.length == 0) return false; 2598 this.activeSlide = null; 2599 this.prevActiveSlideIndex = null; 2600 this.prevActiveSlide = null; 2601 var index = this.settings.startAt; 2602 2603 if (element && utils.isNil(index)) { 2604 index = this.elements.indexOf(element); 2605 2606 if (index < 0) { 2607 index = 0; 2608 } 2609 } 2610 2611 if (utils.isNil(index)) { 2612 index = 0; 2613 } 2614 2615 this.build(); 2616 animateElement(this.overlay, this.settings.openEffect == 'none' ? 'none' : this.settings.cssEfects.fade["in"]); 2617 var body = document.body; 2618 body.style.width = "".concat(body.offsetWidth, "px"); 2619 addClass(body, 'glightbox-open'); 2620 addClass(html, 'glightbox-open'); 2621 2622 if (isMobile) { 2623 addClass(document.body, 'glightbox-mobile'); 2624 this.settings.slideEffect = 'slide'; 2625 } 2626 2627 this.showSlide(index, true); 2628 2629 if (this.elements.length == 1) { 2630 hide(this.prevButton); 2631 hide(this.nextButton); 2632 } else { 2633 show(this.prevButton); 2634 show(this.nextButton); 2635 } 2636 2637 this.lightboxOpen = true; 2638 2639 if (utils.isFunction(this.settings.onOpen)) { 2640 this.settings.onOpen(); 2641 } 2642 2643 if (isMobile && isTouch && this.settings.touchNavigation) { 2644 touchNavigation.apply(this); 2645 return false; 2646 } 2647 2648 if (this.settings.keyboardNavigation) { 2649 keyboardNavigation.apply(this); 2650 } 2651 } 2652 }, { 2653 key: "showSlide", 2654 value: function showSlide() { 2655 var _this7 = this; 2656 2657 var index = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0; 2658 var first = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
2659 show(this.loader); 2660 this.index = parseInt(index); 2661 var current = this.slidesContainer.querySelector('.current'); 2662 2663 if (current) { 2664 removeClass(current, 'current'); 2665 } 2666 2667 this.slideAnimateOut(); 2668 var slide = this.slidesContainer.querySelectorAll('.gslide')[index]; 2669 2670 if (hasClass(slide, 'loaded')) { 2671 this.slideAnimateIn(slide, first); 2672 hide(this.loader); 2673 } else { 2674 show(this.loader); 2675 var slideData = getSlideData(this.elements[index], this.settings); 2676 slideData.index = index; 2677 this.slidesData[index] = slideData; 2678 setSlideContent.apply(this, [slide, slideData, function () { 2679 hide(_this7.loader); 2680 2681 _this7.resize(); 2682 2683 _this7.slideAnimateIn(slide, first); 2684 }]); 2685 } 2686 2687 this.slideDescription = slide.querySelector('.gslide-description'); 2688 this.slideDescriptionContained = this.slideDescription && hasClass(this.slideDescription.parentNode, 'gslide-media'); 2689 this.preloadSlide(index + 1); 2690 this.preloadSlide(index - 1); 2691 removeClass(this.nextButton, 'disabled'); 2692 removeClass(this.prevButton, 'disabled'); 2693 2694 if (index === 0) { 2695 addClass(this.prevButton, 'disabled'); 2696 } else if (index === this.elements.length - 1 && this.settings.loopAtEnd !== true) { 2697 addClass(this.nextButton, 'disabled'); 2698 } 2699 2700 this.activeSlide = slide; 2701 } 2702 }, { 2703 key: "preloadSlide", 2704 value: function preloadSlide(index) { 2705 var _this8 = this; 2706 2707 if (index < 0 || index > this.elements.length) return false; 2708 if (utils.isNil(this.elements[index])) return false; 2709 var slide = this.slidesContainer.querySelectorAll('.gslide')[index]; 2710 2711 if (hasClass(slide, 'loaded')) { 2712 return false; 2713 } 2714 2715 var slideData = getSlideData(this.elements[index], this.settings); 2716 slideData.index = index; 2717 this.slidesData[index] = slideData; 2718 var type = slideData.sourcetype; 2719 2720 if (type == 'video' || type == 'external') { 2721 setTimeout(function () { 2722 setSlideContent.apply(_this8, [slide, slideData]); 2723 }, 200); 2724 } else { 2725 setSlideContent.apply(this, [slide, slideData]); 2726 } 2727 } 2728 }, { 2729 key: "prevSlide", 2730 value: function prevSlide() { 2731 var prev = this.index - 1; 2732 2733 if (prev < 0) { 2734 return false; 2735 } 2736 2737 this.goToSlide(prev); 2738 } 2739 }, { 2740 key: "nextSlide", 2741 value: function nextSlide() { 2742 var next = this.index + 1; 2743 if (next > this.elements.length) return false; 2744 this.goToSlide(next); 2745 } 2746 }, { 2747 key: "goToSlide", 2748 value: function goToSlide() { 2749 var index = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false; 2750 2751 if (index > -1) { 2752 this.prevActiveSlide = this.activeSlide; 2753 this.prevActiveSlideIndex = this.index; 2754 2755 if (index < this.elements.length) { 2756 this.showSlide(index); 2757 } else { 2758 if (this.settings.loopAtEnd === true) { 2759 index = 0; 2760 this.showSlide(index); 2761 } 2762 } 2763 } 2764 } 2765 }, { 2766 key: "slideAnimateIn", 2767 value: function slideAnimateIn(slide, first) { 2768 var _this9 = this; 2769 2770 var slideMedia = slide.querySelector('.gslide-media'); 2771 var slideDesc = slide.querySelector('.gslide-description'); 2772 var prevData = { 2773 index: this.prevActiveSlideIndex, 2774 slide: this.prevActiveSlide 2775 }; 2776 var nextData = { 2777 index: this.index, 2778 slide: this.activeSlide 2779 }; 2780 2781 if (slideMedia.offsetWidth > 0 && slideDesc) { 2782 hide(slideDesc); 2783 slideDesc.style.display = ''; 2784 } 2785 2786 removeClass(slide, this.effectsClasses); 2787 2788 if (first) { 2789 animateElement(slide, this.settings.openEffect, function () { 2790 if (!isMobile && _this9.settings.autoplayVideos) { 2791 _this9.playSlideVideo(slide); 2792 } 2793 2794 if (utils.isFunction(_this9.settings.afterSlideChange)) { 2795 _this9.settings.afterSlideChange.apply(_this9, [prevData, nextData]); 2796 } 2797 }); 2798 } else { 2799 var effect_name = this.settings.slideEffect; 2800 var animIn = effect_name !== 'none' ? this.settings.cssEfects[effect_name]["in"] : effect_name; 2801 2802 if (this.prevActiveSlideIndex > this.index) { 2803 if (this.settings.slideEffect == 'slide') { 2804 animIn = this.settings.cssEfects.slide_back["in"]; 2805 } 2806 } 2807 2808 animateElement(slide, animIn, function () { 2809 if (!isMobile && _this9.settings.autoplayVideos) { 2810 _this9.playSlideVideo(slide); 2811 } 2812 2813 if (utils.isFunction(_this9.settings.afterSlideChange)) { 2814 _this9.settings.afterSlideChange.apply(_this9, [prevData, nextData]); 2815 } 2816 }); 2817 } 2818 2819 setTimeout(function () { 2820 _this9.resize(slide); 2821 }, 100); 2822 addClass(slide, 'current'); 2823 } 2824 }, {
2825 key: "slideAnimateOut", 2826 value: function slideAnimateOut() { 2827 if (!this.prevActiveSlide) { 2828 return false; 2829 } 2830 2831 var prevSlide = this.prevActiveSlide; 2832 removeClass(prevSlide, this.effectsClasses); 2833 addClass(prevSlide, 'prev'); 2834 var animation = this.settings.slideEffect; 2835 var animOut = animation !== 'none' ? this.settings.cssEfects[animation].out : animation; 2836 this.stopSlideVideo(prevSlide); 2837 2838 if (utils.isFunction(this.settings.beforeSlideChange)) { 2839 this.settings.beforeSlideChange.apply(this, [{ 2840 index: this.prevActiveSlideIndex, 2841 slide: this.prevActiveSlide 2842 }, { 2843 index: this.index, 2844 slide: this.activeSlide 2845 }]); 2846 } 2847 2848 if (this.prevActiveSlideIndex > this.index && this.settings.slideEffect == 'slide') { 2849 animOut = this.settings.cssEfects.slide_back.out; 2850 } 2851 2852 animateElement(prevSlide, animOut, function () { 2853 var media = prevSlide.querySelector('.gslide-media'); 2854 var desc = prevSlide.querySelector('.gslide-description'); 2855 media.style.transform = ''; 2856 removeClass(media, 'greset'); 2857 media.style.opacity = ''; 2858 2859 if (desc) { 2860 desc.style.opacity = ''; 2861 } 2862 2863 removeClass(prevSlide, 'prev'); 2864 }); 2865 } 2866 }, { 2867 key: "stopSlideVideo", 2868 value: function stopSlideVideo(slide) { 2869 if (utils.isNumber(slide)) { 2870 slide = this.slidesContainer.querySelectorAll('.gslide')[slide]; 2871 } 2872 2873 var slideVideo = slide ? slide.querySelector('.gvideo') : null; 2874 2875 if (!slideVideo) { 2876 return false; 2877 } 2878 2879 var videoID = slideVideo.getAttribute('data-id'); 2880 2881 if (videoPlayers && utils.has(videoPlayers, videoID)) { 2882 var api = videoPlayers[videoID]; 2883 2884 if (api && api.play) { 2885 api.pause(); 2886 } 2887 } 2888 } 2889 }, { 2890 key: "playSlideVideo", 2891 value: function playSlideVideo(slide) { 2892 if (utils.isNumber(slide)) { 2893 slide = this.slidesContainer.querySelectorAll('.gslide')[slide]; 2894 } 2895 2896 var slideVideo = slide.querySelector('.gvideo'); 2897 2898 if (!slideVideo) { 2899 return false; 2900 } 2901 2902 var videoID = slideVideo.getAttribute('data-id'); 2903 2904 if (videoPlayers && utils.has(videoPlayers, videoID)) { 2905 var api = videoPlayers[videoID]; 2906 2907 if (api && api.play) { 2908 api.play(); 2909 } 2910 } 2911 } 2912 }, { 2913 key: "setElements", 2914 value: function setElements(elements) { 2915 this.settings.elements = elements; 2916 } 2917 }, { 2918 key: "getElements", 2919 value: function getElements() { 2920 var element = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null; 2921 this.elements = []; 2922 2923 if (!utils.isNil(this.settings.elements) && utils.isArray(this.settings.elements)) { 2924 return this.settings.elements; 2925 } 2926 2927 var nodes = false; 2928 2929 if (element !== null) { 2930 var gallery = element.getAttribute('data-gallery'); 2931 2932 if (gallery && gallery !== '') { 2933 nodes = document.querySelectorAll("[data-gallery=\"".concat(gallery, "\"]")); 2934 } 2935 } 2936 2937 if (nodes == false) { 2938 nodes = document.querySelectorAll(".".concat(this.settings.selector)); 2939 } 2940 2941 nodes = Array.prototype.slice.call(nodes); 2942 return nodes; 2943 } 2944 }, { 2945 key: "getActiveSlide", 2946 value: function getActiveSlide() { 2947 return this.slidesContainer.querySelectorAll('.gslide')[this.index]; 2948 } 2949 }, { 2950 key: "getActiveSlideIndex", 2951 value: function getActiveSlideIndex() { 2952 return this.index; 2953 } 2954 }, { 2955 key: "getAnimationClasses", 2956 value: function getAnimationClasses() { 2957 var effects = []; 2958 2959 for (var key in this.settings.cssEfects) { 2960 if (this.settings.cssEfects.hasOwnProperty(key)) { 2961 var effect = this.settings.cssEfects[key]; 2962 effects.push("g".concat(effect["in"])); 2963 effects.push("g".concat(effect.out)); 2964 } 2965 } 2966 2967 return effects.join(' '); 2968 } 2969 }, {
2970 key: "build", 2971 value: function build() { 2972 var _this10 = this; 2973 2974 if (this.built) { 2975 return false; 2976 } 2977 2978 var nextSVG = utils.has(this.settings.svg, 'next') ? this.settings.svg.next : ''; 2979 var prevSVG = utils.has(this.settings.svg, 'prev') ? this.settings.svg.prev : ''; 2980 var closeSVG = utils.has(this.settings.svg, 'close') ? this.settings.svg.close : ''; 2981 var lightboxHTML = this.settings.lightboxHtml; 2982 lightboxHTML = lightboxHTML.replace(/{nextSVG}/g, nextSVG); 2983 lightboxHTML = lightboxHTML.replace(/{prevSVG}/g, prevSVG); 2984 lightboxHTML = lightboxHTML.replace(/{closeSVG}/g, closeSVG); 2985 lightboxHTML = createHTML(lightboxHTML); 2986 document.body.appendChild(lightboxHTML); 2987 var modal = document.getElementById('glightbox-body'); 2988 this.modal = modal; 2989 var closeButton = modal.querySelector('.gclose'); 2990 this.prevButton = modal.querySelector('.gprev'); 2991 this.nextButton = modal.querySelector('.gnext'); 2992 this.overlay = modal.querySelector('.goverlay'); 2993 this.loader = modal.querySelector('.gloader'); 2994 this.slidesContainer = document.getElementById('glightbox-slider'); 2995 this.events = {}; 2996 addClass(this.modal, 'glightbox-' + this.settings.skin); 2997 2998 if (this.settings.closeButton && closeButton) { 2999 this.events['close'] = addEvent('click', { 3000 onElement: closeButton, 3001 withCallback: function withCallback(e, target) { 3002 e.preventDefault(); 3003 3004 _this10.close(); 3005 } 3006 }); 3007 } 3008 3009 if (closeButton && !this.settings.closeButton) { 3010 closeButton.parentNode.removeChild(closeButton); 3011 } 3012 3013 if (this.nextButton) { 3014 this.events['next'] = addEvent('click', { 3015 onElement: this.nextButton, 3016 withCallback: function withCallback(e, target) { 3017 e.preventDefault(); 3018 3019 _this10.nextSlide(); 3020 } 3021 }); 3022 } 3023 3024 if (this.prevButton) { 3025 this.events['prev'] = addEvent('click', { 3026 onElement: this.prevButton, 3027 withCallback: function withCallback(e, target) { 3028 e.preventDefault(); 3029 3030 _this10.prevSlide(); 3031 } 3032 }); 3033 } 3034 3035 if (this.settings.closeOnOutsideClick) { 3036 this.events['outClose'] = addEvent('click', { 3037 onElement: modal, 3038 withCallback: function withCallback(e, target) { 3039 if (!hasClass(document.body, 'glightbox-mobile') && !getClosest(e.target, '.ginner-container')) { 3040 if (!getClosest(e.target, '.gbtn') && !hasClass(e.target, 'gnext') && !hasClass(e.target, 'gprev')) { 3041 _this10.close(); 3042 } 3043 } 3044 } 3045 }); 3046 } 3047 3048 each(this.elements, function () { 3049 var slide = createHTML(_this10.settings.slideHtml); 3050 3051 _this10.slidesContainer.appendChild(slide); 3052 }); 3053 3054 if (isTouch) { 3055 addClass(document.body, 'glightbox-touch'); 3056 } 3057 3058 this.events['resize'] = addEvent('resize', { 3059 onElement: window, 3060 withCallback: function withCallback() { 3061 _this10.resize(); 3062 } 3063 }); 3064 this.built = true; 3065 } 3066 }, { 3067 key: "resize", 3068 value: function resize() { 3069 var slide = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null; 3070 slide = !slide ? this.activeSlide : slide; 3071 document.body.style.width = ""; 3072 document.body.style.width = "".concat(document.body.offsetWidth, "px"); 3073 3074 if (!slide || hasClass(slide, 'zoomed')) { 3075 return; 3076 } 3077 3078 var winSize = windowSize(); 3079 var video = slide.querySelector('.gvideo-wrapper'); 3080 var image = slide.querySelector('.gslide-image'); 3081 var description = this.slideDescription; 3082 var winWidth = winSize.width; 3083 var winHeight = winSize.height; 3084 3085 if (winWidth <= 768) { 3086 addClass(document.body, 'glightbox-mobile'); 3087 } else { 3088 removeClass(document.body, 'glightbox-mobile'); 3089 } 3090 3091 if (!video && !image) { 3092 return; 3093 } 3094 3095 var descriptionResize = false;
3096 3097 if (description && (hasClass(description, 'description-bottom') || hasClass(description, 'description-top')) && !hasClass(description, 'gabsolute')) { 3098 descriptionResize = true; 3099 } 3100 3101 if (image) { 3102 if (winWidth <= 768) { 3103 var imgNode = image.querySelector('img'); 3104 imgNode.setAttribute('style', ''); 3105 } else if (descriptionResize) { 3106 var descHeight = description.offsetHeight; 3107 var maxWidth = this.slidesData[this.index].width; 3108 maxWidth = maxWidth <= winWidth ? maxWidth + 'px' : '100%'; 3109 3110 var _imgNode = image.querySelector('img'); 3111 3112 _imgNode.setAttribute('style', "max-height: calc(100vh - ".concat(descHeight, "px)")); 3113 3114 description.setAttribute('style', "max-width: ".concat(_imgNode.offsetWidth, "px;")); 3115 } 3116 } 3117 3118 if (video) { 3119 var videoRatio = this.settings.plyr.ratio.split(':'); 3120 var _maxWidth = this.slidesData[this.index].width; 3121 3122 var maxHeight = _maxWidth / (parseInt(videoRatio[0]) / parseInt(videoRatio[1])); 3123 3124 maxHeight = Math.floor(maxHeight); 3125 3126 if (descriptionResize) { 3127 winHeight = winHeight - description.offsetHeight; 3128 } 3129 3130 if (winHeight < maxHeight && winWidth > _maxWidth) { 3131 var vwidth = video.offsetWidth; 3132 var vheight = video.offsetHeight; 3133 var ratio = winHeight / vheight; 3134 var vsize = { 3135 width: vwidth * ratio, 3136 height: vheight * ratio 3137 }; 3138 video.parentNode.setAttribute('style', "max-width: ".concat(vsize.width, "px")); 3139 3140 if (descriptionResize) { 3141 description.setAttribute('style', "max-width: ".concat(vsize.width, "px;")); 3142 } 3143 } else { 3144 video.parentNode.style.maxWidth = "".concat(_maxWidth, "px"); 3145 3146 if (descriptionResize) { 3147 description.setAttribute('style', "max-width: ".concat(_maxWidth, "px;")); 3148 } 3149 } 3150 } 3151 } 3152 }, { 3153 key: "reload", 3154 value: function reload() { 3155 this.init(); 3156 } 3157 }, { 3158 key: "close", 3159 value: function close() { 3160 var _this11 = this; 3161 3162 if (this.closing) { 3163 return false; 3164 } 3165 3166 this.closing = true; 3167 this.stopSlideVideo(this.activeSlide); 3168 addClass(this.modal, 'glightbox-closing'); 3169 animateElement(this.overlay, this.settings.openEffect == 'none' ? 'none' : this.settings.cssEfects.fade.out); 3170 animateElement(this.activeSlide, this.settings.closeEffect, function () { 3171 _this11.activeSlide = null; 3172 _this11.prevActiveSlideIndex = null; 3173 _this11.prevActiveSlide = null; 3174 _this11.built = false; 3175 3176 if (_this11.events) { 3177 for (var key in _this11.events) { 3178 if (_this11.events.hasOwnProperty(key)) { 3179 _this11.events[key].destroy(); 3180 } 3181 } 3182 3183 _this11.events = null; 3184 } 3185 3186 var body = document.body; 3187 removeClass(html, 'glightbox-open'); 3188 removeClass(body, 'glightbox-open touching gdesc-open glightbox-touch glightbox-mobile'); 3189 body.style.width = ''; 3190 3191 _this11.modal.parentNode.removeChild(_this11.modal); 3192 3193 if (utils.isFunction(_this11.settings.onClose)) { 3194 _this11.settings.onClose(); 3195 } 3196 3197 _this11.closing = null; 3198 }); 3199 } 3200 }, { 3201 key: "destroy", 3202 value: function destroy() { 3203 this.close(); 3204 this.baseEvents.destroy(); 3205 } 3206 }]); 3207 3208 return GlightboxInit; 3209 }(); 3210 3211 function glightbox () { 3212 var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; 3213 var instance = new GlightboxInit(options); 3214 instance.init(); 3215 return instance; 3216 } 3217 3218 return glightbox; 3219 3220})); 3221 3222/* End */ 3223; 3224; /* Start:"a:4:{s:4:"full";s:53:"/local/templates/bitrix66/js/slick.js?178963401281472";s:6:"source";s:37:"/local/templates/bitrix66/js/slick.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/ 3225(function (factory) { 3226 "use strict"; 3227 if (typeof define === "function" && define.amd) { 3228 define(["jquery"], factory) 3229 } else if (typeof exports !== "undefined") { 3230 module.exports = factory(require("jquery")) 3231 } else { 3232 factory(jQuery) 3233 } 3234})(function ($) { 3235 "use strict"; 3236 var Slick = window.Slick || {}; 3237 Slick = function () { 3238 var instanceUid = 0; 3239 3240 function Slick(element, settings) { 3241 var _ = this, dataSettings; 3242 _.defaults = { 3243 accessibility: true, 3244 adaptiveHeight: false, 3245 appendArrows: $(element), 3246 appendDots: $(element),
vendor: 78,406 bytes, lines 3247-5048
3247 arrows: false, 3248 asNavFor: null, 3249 prevArrow: '<button class="slick-prev" aria-label="Previous" type="button">Previous</button>', 3250 nextArrow: '<button class="slick-next" aria-label="Next" type="button">Next</button>', 3251 autoplay: false, 3252 autoplaySpeed: 3e3, 3253 centerMode: false, 3254 centerPadding: false, 3255 cssEase: "ease", 3256 customPaging: function (slider, i) { 3257 return $('<button type="button" />').text(i + 1) 3258 }, 3259 dots: false, 3260 dotsClass: "slick-dots", 3261 draggable: true, 3262 easing: "linear", 3263 edgeFriction: .35, 3264 fade: false, 3265 focusOnSelect: false, 3266 focusOnChange: false, 3267 infinite: true, 3268 initialSlide: 0, 3269 lazyLoad: "ondemand", 3270 mobileFirst: false, 3271 pauseOnHover: true, 3272 pauseOnFocus: true, 3273 pauseOnDotsHover: false, 3274 respondTo: "window", 3275 responsive: null, 3276 rows: 1, 3277 rtl: false, 3278 slide: "", 3279 slidesPerRow: 1, 3280 slidesToShow: 1, 3281 slidesToScroll: 1, 3282 speed: 500, 3283 swipe: true, 3284 swipeToSlide: false, 3285 touchMove: true, 3286 touchThreshold: 5, 3287 useCSS: true, 3288 useTransform: true, 3289 variableWidth: true, 3290 vertical: false, 3291 verticalSwiping: false, 3292 waitForAnimate: true, 3293 zIndex: 1e3 3294 }; 3295 _.initials = { 3296 animating: false, 3297 dragging: false, 3298 autoPlayTimer: null, 3299 currentDirection: 0, 3300 currentLeft: null, 3301 currentSlide: 0, 3302 direction: 1, 3303 $dots: null, 3304 listWidth: null, 3305 listHeight: null, 3306 loadIndex: 0, 3307 $nextArrow: null, 3308 $prevArrow: null, 3309 scrolling: false, 3310 slideCount: null, 3311 slideWidth: null, 3312 $slideTrack: null, 3313 $slides: null, 3314 sliding: false, 3315 slideOffset: 0, 3316 swipeLeft: null, 3317 swiping: false, 3318 $list: null, 3319 touchObject: {}, 3320 transformsEnabled: false, 3321 unslicked: false 3322 }; 3323 $.extend(_, _.initials); 3324 _.activeBreakpoint = null; 3325 _.animType = null; 3326 _.animProp = null; 3327 _.breakpoints = []; 3328 _.breakpointSettings = []; 3329 _.cssTransitions = true; 3330 _.focussed = false; 3331 _.interrupted = false; 3332 _.hidden = "hidden"; 3333 _.paused = true; 3334 _.positionProp = null; 3335 _.respondTo = null; 3336 _.rowCount = 1; 3337 _.shouldClick = true; 3338 _.$slider = $(element); 3339 _.$slidesCache = null; 3340 _.transformType = null; 3341 _.transitionType = null; 3342 _.visibilityChange = "visibilitychange"; 3343 _.windowWidth = 0; 3344 _.windowTimer = null; 3345 dataSettings = $(element).data("slick") || {}; 3346 _.options = $.extend({}, _.defaults, settings, dataSettings); 3347 _.currentSlide = _.options.initialSlide; 3348 _.originalSettings = _.options; 3349 if (typeof document.mozHidden !== "undefined") { 3350 _.hidden = "mozHidden"; 3351 _.visibilityChange = "mozvisibilitychange" 3352 } else if (typeof document.webkitHidden !== "undefined") { 3353 _.hidden = "webkitHidden"; 3354 _.visibilityChange = "webkitvisibilitychange" 3355 } 3356 _.autoPlay = $.proxy(_.autoPlay, _); 3357 _.autoPlayClear = $.proxy(_.autoPlayClear, _); 3358 _.autoPlayIterator = $.proxy(_.autoPlayIterator, _); 3359 _.changeSlide = $.proxy(_.changeSlide, _); 3360 _.clickHandler = $.proxy(_.clickHandler, _); 3361 _.selectHandler = $.proxy(_.selectHandler, _); 3362 _.setPosition = $.proxy(_.setPosition, _); 3363 _.swipeHandler = $.proxy(_.swipeHandler, _); 3364 _.dragHandler = $.proxy(_.dragHandler, _); 3365 _.keyHandler = $.proxy(_.keyHandler, _); 3366 _.instanceUid = instanceUid++; 3367 _.htmlExpr = /^(?:\s*(<[\w\W]+>)[^>]*)$/; 3368 _.registerBreakpoints(); 3369 _.init(true) 3370 } 3371 3372 return Slick 3373 }(); 3374 Slick.prototype.activateADA = function () { 3375 var _ = this; 3376 _.$slideTrack.find(".slick-active").attr({"aria-hidden": "false"}).find("a, input, button, select").attr({tabindex: "0"}) 3377 }; 3378 Slick.prototype.addSlide = Slick.prototype.slickAdd = function (markup, index, addBefore) { 3379 var _ = this; 3380 if (typeof index === "boolean") { 3381 addBefore = index; 3382 index = null 3383 } else if (index < 0 || index >= _.slideCount) { 3384 return false 3385 } 3386 _.unload(); 3387 if (typeof index === "number") { 3388 if (index === 0 && _.$slides.length === 0) { 3389 $(markup).appendTo(_.$slideTrack) 3390 } else if (addBefore) { 3391 $(markup).insertBefore(_.$slides.eq(index)) 3392 } else { 3393 $(markup).insertAfter(_.$slides.eq(index)) 3394 } 3395 } else { 3396 if (addBefore === true) { 3397 $(markup).prependTo(_.$slideTrack) 3398 } else { 3399 $(markup).appendTo(_.$slideTrack) 3400 } 3401 } 3402 _.$slides = _.$slideTrack.children(this.options.slide); 3403 _.$slideTrack.children(this.options.slide).detach(); 3404 _.$slideTrack.append(_.$slides); 3405 _.$slides.each(function (index, element) { 3406 $(element).attr("data-slick-index", index) 3407 }); 3408 _.$slidesCache = _.$slides; 3409 _.reinit() 3410 }; 3411 Slick.prototype.animateHeight = function () { 3412 var _ = this; 3413 if (_.options.slidesToShow === 1 && _.options.adaptiveHeight === true && _.options.vertical === false) { 3414 var targetHeight = _.$slides.eq(_.currentSlide).outerHeight(true); 3415 _.$list.animate({height: targetHeight}, _.options.speed) 3416 } 3417 }; 3418 Slick.prototype.animateSlide = function (targetLeft, callback) { 3419 var animProps = {}, _ = this; 3420 _.animateHeight(); 3421 if (_.options.rtl === true && _.options.vertical === false) { 3422 targetLeft = -targetLeft 3423 } 3424 if (_.transformsEnabled === false) { 3425 if (_.options.vertical === false) { 3426 _.$slideTrack.animate({left: targetLeft}, _.options.speed, _.options.easing, callback) 3427 } else { 3428 _.$slideTrack.animate({top: targetLeft}, _.options.speed, _.options.easing, callback) 3429 } 3430 } else { 3431 if (_.cssTransitions === false) { 3432 if (_.options.rtl === true) { 3433 _.currentLeft = -_.currentLeft 3434 } 3435 $({animStart: _.currentLeft}).animate({animStart: targetLeft}, { 3436 duration: _.options.speed, 3437 easing: _.options.easing, 3438 step: function (now) { 3439 now = Math.ceil(now); 3440 if (_.options.vertical === false) { 3441 animProps[_.animType] = "translate(" + now + "px, 0px)"; 3442 _.$slideTrack.css(animProps) 3443 } else { 3444 animProps[_.animType] = "translate(0px," + now + "px)"; 3445 _.$slideTrack.css(animProps) 3446 } 3447 }, 3448 complete: function () { 3449 if (callback) { 3450 callback.call() 3451 } 3452 } 3453 }) 3454 } else { 3455 _.applyTransition(); 3456 targetLeft = Math.ceil(targetLeft); 3457 if (_.options.vertical === false) { 3458 animProps[_.animType] = "translate3d(" + targetLeft + "px, 0px, 0px)" 3459 } else { 3460 animProps[_.animType] = "translate3d(0px," + targetLeft + "px, 0px)" 3461 } 3462 _.$slideTrack.css(animProps); 3463 if (callback) { 3464 setTimeout(function () { 3465 _.disableTransition(); 3466 callback.call() 3467 }, _.options.speed) 3468 } 3469 } 3470 } 3471 }; 3472 Slick.prototype.getNavTarget = function () { 3473 var _ = this, asNavFor = _.options.asNavFor; 3474 if (asNavFor && asNavFor !== null) { 3475 asNavFor = $(asNavFor).not(_.$slider) 3476 } 3477 return asNavFor 3478 }; 3479 Slick.prototype.asNavFor = function (index) { 3480 var _ = this, asNavFor = _.getNavTarget(); 3481 if (asNavFor !== null && typeof asNavFor === "object") { 3482 asNavFor.each(function () { 3483 var target = $(this).slick("getSlick"); 3484 if (!target.unslicked) { 3485 target.slideHandler(index, true) 3486 } 3487 }) 3488 } 3489 }; 3490 Slick.prototype.applyTransition = function (slide) { 3491 var _ = this, transition = {}; 3492 if (_.options.fade === false) { 3493 transition[_.transitionType] = _.transformType + " " + _.options.speed + "ms " + _.options.cssEase 3494 } else { 3495 transition[_.transitionType] = "opacity " + _.options.speed + "ms " + _.options.cssEase 3496 } 3497 if (_.options.fade === false) { 3498 _.$slideTrack.css(transition) 3499 } else { 3500 _.$slides.eq(slide).css(transition) 3501 } 3502 }; 3503 Slick.prototype.autoPlay = function () { 3504 var _ = this; 3505 _.autoPlayClear(); 3506 if (_.slideCount > _.options.slidesToShow) { 3507 _.autoPlayTimer = setInterval(_.autoPlayIterator, _.options.autoplaySpeed) 3508 } 3509 }; 3510 Slick.prototype.autoPlayClear = function () { 3511 var _ = this; 3512 if (_.autoPlayTimer) { 3513 clearInterval(_.autoPlayTimer) 3514 } 3515 }; 3516 Slick.prototype.autoPlayIterator = function () { 3517 var _ = this, slideTo = _.currentSlide + _.options.slidesToScroll; 3518 if (!_.paused && !_.interrupted && !_.focussed) { 3519 if (_.options.infinite === false) { 3520 if (_.direction === 1 && _.currentSlide + 1 === _.slideCount - 1) { 3521 _.direction = 0 3522 } else if (_.direction === 0) { 3523 slideTo = _.currentSlide - _.options.slidesToScroll; 3524 if (_.currentSlide - 1 === 0) { 3525 _.direction = 1 3526 } 3527 } 3528 } 3529 _.slideHandler(slideTo) 3530 } 3531 }; 3532 Slick.prototype.buildArrows = function () { 3533 var _ = this; 3534 if (_.options.arrows === true) { 3535 _.$prevArrow = $(_.options.prevArrow).addClass("slick-arrow"); 3536 _.$nextArrow = $(_.options.nextArrow).addClass("slick-arrow"); 3537 if (_.slideCount > _.options.slidesToShow) { 3538 _.$prevArrow.removeClass("slick-hidden").removeAttr("aria-hidden tabindex"); 3539 _.$nextArrow.removeClass("slick-hidden").removeAttr("aria-hidden tabindex"); 3540 if (_.htmlExpr.test(_.options.prevArrow)) { 3541 _.$prevArrow.prependTo(_.options.appendArrows) 3542 } 3543 if (_.htmlExpr.test(_.options.nextArrow)) { 3544 _.$nextArrow.appendTo(_.options.appendArrows) 3545 } 3546 if (_.options.infinite !== true) { 3547 _.$prevArrow.addClass("slick-disabled").attr("aria-disabled", "true") 3548 } 3549 } else { 3550 _.$prevArrow.add(_.$nextArrow).addClass("slick-hidden").attr({"aria-disabled": "true", tabindex: "-1"}) 3551 } 3552 } 3553 }; 3554 Slick.prototype.buildDots = function () { 3555 var _ = this, i, dot; 3556 if (_.options.dots === true && _.slideCount > _.options.slidesToShow) { 3557 _.$slider.addClass("slick-dotted"); 3558 dot = $("<ul />").addClass(_.options.dotsClass); 3559 for (i = 0; i <= _.getDotCount(); i += 1) { 3560 dot.append($("<li />").append(_.options.customPaging.call(this, _, i))) 3561 } 3562 _.$dots = dot.appendTo(_.options.appendDots); 3563 _.$dots.find("li").first().addClass("slick-active") 3564 } 3565 }; 3566 Slick.prototype.buildOut = function () { 3567 var _ = this; 3568 _.$slides = _.$slider.children(_.options.slide + ":not(.slick-cloned)").addClass("slick-slide"); 3569 _.slideCount = _.$slides.length; 3570 _.$slides.each(function (index, element) { 3571 $(element).attr("data-slick-index", index).data("originalStyling", $(element).attr("style") || "") 3572 }); 3573 _.$slider.addClass("slick-slider"); 3574 _.$slideTrack = _.slideCount === 0 ? $('<div class="slick-track"/>').appendTo(_.$slider) : _.$slides.wrapAll('<div class="slick-track"/>').parent(); 3575 _.$list = _.$slideTrack.wrap('<div class="slick-list"/>').parent(); 3576 _.$slideTrack.css("opacity", 0); 3577 if (_.options.centerMode === true || _.options.swipeToSlide === true) { 3578 _.options.slidesToScroll = 1 3579 } 3580 $("img[data-lazy]", _.$slider).not("[src]").addClass("slick-loading"); 3581 _.setupInfinite(); 3582 _.buildArrows(); 3583 _.buildDots(); 3584 _.updateDots(); 3585 _.setSlideClasses(typeof _.currentSlide === "number" ? _.currentSlide : 0); 3586 if (_.options.draggable === true) { 3587 _.$list.addClass("draggable") 3588 } 3589 }; 3590 Slick.prototype.buildRows = function () { 3591 var _ = this, a, b, c, newSlides, numOfSlides, originalSlides, slidesPerSection; 3592 newSlides = document.createDocumentFragment(); 3593 originalSlides = _.$slider.children(); 3594 if (_.options.rows > 0) { 3595 slidesPerSection = _.options.slidesPerRow * _.options.rows; 3596 numOfSlides = Math.ceil(originalSlides.length / slidesPerSection); 3597 for (a = 0; a < numOfSlides; a++) { 3598 var slide = document.createElement("div"); 3599 for (b = 0; b < _.options.rows; b++) { 3600 var row = document.createElement("div"); 3601 for (c = 0; c < _.options.slidesPerRow; c++) { 3602 var target = a * slidesPerSection + (b * _.options.slidesPerRow + c); 3603 if (originalSlides.get(target)) { 3604 row.appendChild(originalSlides.get(target)) 3605 } 3606 } 3607 slide.appendChild(row) 3608 } 3609 newSlides.appendChild(slide) 3610 } 3611 _.$slider.empty().append(newSlides); 3612 _.$slider.children().children().children().css({ 3613 width: "auto", 3614 height: "100%", 3615 display: "inline-block" 3616 }) 3617 } 3618 }; 3619 Slick.prototype.checkResponsive = function (initial, forceUpdate) { 3620 var _ = this, breakpoint, targetBreakpoint, respondToWidth, triggerBreakpoint = false; 3621 var sliderWidth = _.$slider.width(); 3622 var windowWidth = window.innerWidth || $(window).width(); 3623 if (_.respondTo === "window") { 3624 respondToWidth = windowWidth 3625 } else if (_.respondTo === "slider") { 3626 respondToWidth = sliderWidth 3627 } else if (_.respondTo === "min") { 3628 respondToWidth = Math.min(windowWidth, sliderWidth) 3629 } 3630 if (_.options.responsive && _.options.responsive.length && _.options.responsive !== null) { 3631 targetBreakpoint = null; 3632 for (breakpoint in _.breakpoints) { 3633 if (_.breakpoints.hasOwnProperty(breakpoint)) { 3634 if (_.originalSettings.mobileFirst === false) { 3635 if (respondToWidth < _.breakpoints[breakpoint]) { 3636 targetBreakpoint = _.breakpoints[breakpoint] 3637 } 3638 } else { 3639 if (respondToWidth > _.breakpoints[breakpoint]) { 3640 targetBreakpoint = _.breakpoints[breakpoint] 3641 } 3642 } 3643 } 3644 } 3645 if (targetBreakpoint !== null) { 3646 if (_.activeBreakpoint !== null) { 3647 if (targetBreakpoint !== _.activeBreakpoint || forceUpdate) { 3648 _.activeBreakpoint = targetBreakpoint; 3649 if (_.breakpointSettings[targetBreakpoint] === "unslick") { 3650 _.unslick(targetBreakpoint) 3651 } else { 3652 _.options = $.extend({}, _.originalSettings, _.breakpointSettings[targetBreakpoint]); 3653 if (initial === true) { 3654 _.currentSlide = _.options.initialSlide 3655 } 3656 _.refresh(initial) 3657 } 3658 triggerBreakpoint = targetBreakpoint 3659 } 3660 } else { 3661 _.activeBreakpoint = targetBreakpoint; 3662 if (_.breakpointSettings[targetBreakpoint] === "unslick") { 3663 _.unslick(targetBreakpoint) 3664 } else { 3665 _.options = $.extend({}, _.originalSettings, _.breakpointSettings[targetBreakpoint]); 3666 if (initial === true) { 3667 _.currentSlide = _.options.initialSlide 3668 } 3669 _.refresh(initial) 3670 } 3671 triggerBreakpoint = targetBreakpoint 3672 } 3673 } else { 3674 if (_.activeBreakpoint !== null) { 3675 _.activeBreakpoint = null; 3676 _.options = _.originalSettings; 3677 if (initial === true) { 3678 _.currentSlide = _.options.initialSlide 3679 } 3680 _.refresh(initial); 3681 triggerBreakpoint = targetBreakpoint 3682 } 3683 } 3684 if (!initial && triggerBreakpoint !== false) { 3685 _.$slider.trigger("breakpoint", [_, triggerBreakpoint]) 3686 } 3687 } 3688 }; 3689 Slick.prototype.changeSlide = function (event, dontAnimate) { 3690 var _ = this, $target = $(event.currentTarget), indexOffset, slideOffset, unevenOffset; 3691 if ($target.is("a")) { 3692 event.preventDefault() 3693 } 3694 if (!$target.is("li")) { 3695 $target = $target.closest("li") 3696 } 3697 unevenOffset = _.slideCount % _.options.slidesToScroll !== 0; 3698 indexOffset = unevenOffset ? 0 : (_.slideCount - _.currentSlide) % _.options.slidesToScroll; 3699 switch (event.data.message) { 3700 case"previous": 3701 slideOffset = indexOffset === 0 ? _.options.slidesToScroll : _.options.slidesToShow - indexOffset; 3702 if (_.slideCount > _.options.slidesToShow) { 3703 _.slideHandler(_.currentSlide - slideOffset, false, dontAnimate) 3704 } 3705 break; 3706 case"next": 3707 slideOffset = indexOffset === 0 ? _.options.slidesToScroll : indexOffset; 3708 if (_.slideCount > _.options.slidesToShow) { 3709 _.slideHandler(_.currentSlide + slideOffset, false, dontAnimate) 3710 } 3711 break; 3712 case"index": 3713 var index = event.data.index === 0 ? 0 : event.data.index || $target.index() * _.options.slidesToScroll; 3714 _.slideHandler(_.checkNavigable(index), false, dontAnimate); 3715 $target.children().trigger("focus"); 3716 break; 3717 default: 3718 return 3719 } 3720 }; 3721 Slick.prototype.checkNavigable = function (index) { 3722 var _ = this, navigables, prevNavigable; 3723 navigables = _.getNavigableIndexes(); 3724 prevNavigable = 0; 3725 if (index > navigables[navigables.length - 1]) { 3726 index = navigables[navigables.length - 1] 3727 } else { 3728 for (var n in navigables) { 3729 if (index < navigables[n]) { 3730 index = prevNavigable; 3731 break 3732 } 3733 prevNavigable = navigables[n] 3734 } 3735 } 3736 return index 3737 }; 3738 Slick.prototype.cleanUpEvents = function () { 3739 var _ = this; 3740 if (_.options.dots && _.$dots !== null) { 3741 $("li", _.$dots).off("click.slick", _.changeSlide).off("mouseenter.slick", $.proxy(_.interrupt, _, true)).off("mouseleave.slick", $.proxy(_.interrupt, _, false)); 3742 if (_.options.accessibility === true) { 3743 _.$dots.off("keydown.slick", _.keyHandler) 3744 } 3745 } 3746 _.$slider.off("focus.slick blur.slick"); 3747 if (_.options.arrows === true && _.slideCount > _.options.slidesToShow) { 3748 _.$prevArrow && _.$prevArrow.off("click.slick", _.changeSlide); 3749 _.$nextArrow && _.$nextArrow.off("click.slick", _.changeSlide); 3750 if (_.options.accessibility === true) { 3751 _.$prevArrow && _.$prevArrow.off("keydown.slick", _.keyHandler); 3752 _.$nextArrow && _.$nextArrow.off("keydown.slick", _.keyHandler) 3753 } 3754 } 3755 _.$list.off("touchstart.slick mousedown.slick", _.swipeHandler); 3756 _.$list.off("touchmove.slick mousemove.slick", _.swipeHandler); 3757 _.$list.off("touchend.slick mouseup.slick", _.swipeHandler); 3758 _.$list.off("touchcancel.slick mouseleave.slick", _.swipeHandler); 3759 _.$list.off("click.slick", _.clickHandler); 3760 $(document).off(_.visibilityChange, _.visibility); 3761 _.cleanUpSlideEvents(); 3762 if (_.options.accessibility === true) { 3763 _.$list.off("keydown.slick", _.keyHandler) 3764 } 3765 if (_.options.focusOnSelect === true) { 3766 $(_.$slideTrack).children().off("click.slick", _.selectHandler) 3767 } 3768 $(window).off("orientationchange.slick.slick-" + _.instanceUid, _.orientationChange); 3769 $(window).off("resize.slick.slick-" + _.instanceUid, _.resize); 3770 $("[draggable!=true]", _.$slideTrack).off("dragstart", _.preventDefault); 3771 $(window).off("load.slick.slick-" + _.instanceUid, _.setPosition) 3772 }; 3773 Slick.prototype.cleanUpSlideEvents = function () { 3774 var _ = this; 3775 _.$list.off("mouseenter.slick", $.proxy(_.interrupt, _, true)); 3776 _.$list.off("mouseleave.slick", $.proxy(_.interrupt, _, false)) 3777 }; 3778 Slick.prototype.cleanUpRows = function () { 3779 var _ = this, originalSlides; 3780 if (_.options.rows > 0) { 3781 originalSlides = _.$slides.children().children(); 3782 originalSlides.removeAttr("style"); 3783 _.$slider.empty().append(originalSlides) 3784 } 3785 }; 3786 Slick.prototype.clickHandler = function (event) { 3787 var _ = this; 3788 if (_.shouldClick === false) { 3789 event.stopImmediatePropagation(); 3790 event.stopPropagation(); 3791 event.preventDefault() 3792 } 3793 }; 3794 Slick.prototype.destroy = function (refresh) { 3795 var _ = this; 3796 _.autoPlayClear(); 3797 _.touchObject = {}; 3798 _.cleanUpEvents(); 3799 $(".slick-cloned", _.$slider).detach(); 3800 if (_.$dots) { 3801 _.$dots.remove() 3802 } 3803 if (_.$prevArrow && _.$prevArrow.length) { 3804 _.$prevArrow.removeClass("slick-disabled slick-arrow slick-hidden").removeAttr("aria-hidden aria-disabled tabindex").css("display", ""); 3805 if (_.htmlExpr.test(_.options.prevArrow)) { 3806 _.$prevArrow.remove() 3807 } 3808 } 3809 if (_.$nextArrow && _.$nextArrow.length) { 3810 _.$nextArrow.removeClass("slick-disabled slick-arrow slick-hidden").removeAttr("aria-hidden aria-disabled tabindex").css("display", ""); 3811 if (_.htmlExpr.test(_.options.nextArrow)) { 3812 _.$nextArrow.remove() 3813 } 3814 } 3815 if (_.$slides) { 3816 _.$slides.removeClass("slick-slide slick-active slick-center slick-visible slick-current").removeAttr("aria-hidden").removeAttr("data-slick-index").each(function () { 3817 $(this).attr("style", $(this).data("originalStyling")) 3818 }); 3819 _.$slideTrack.children(this.options.slide).detach(); 3820 _.$slideTrack.detach(); 3821 _.$list.detach(); 3822 _.$slider.append(_.$slides) 3823 } 3824 _.cleanUpRows(); 3825 _.$slider.removeClass("slick-slider"); 3826 _.$slider.removeClass("slick-initialized"); 3827 _.$slider.removeClass("slick-dotted"); 3828 _.unslicked = true; 3829 if (!refresh) { 3830 _.$slider.trigger("destroy", [_]) 3831 } 3832 }; 3833 Slick.prototype.disableTransition = function (slide) { 3834 var _ = this, transition = {}; 3835 transition[_.transitionType] = ""; 3836 if (_.options.fade === false) { 3837 _.$slideTrack.css(transition) 3838 } else { 3839 _.$slides.eq(slide).css(transition) 3840 } 3841 }; 3842 Slick.prototype.fadeSlide = function (slideIndex, callback) { 3843 var _ = this; 3844 if (_.cssTransitions === false) { 3845 _.$slides.eq(slideIndex).css({zIndex: _.options.zIndex}); 3846 _.$slides.eq(slideIndex).animate({opacity: 1}, _.options.speed, _.options.easing, callback) 3847 } else { 3848 _.applyTransition(slideIndex); 3849 _.$slides.eq(slideIndex).css({opacity: 1, zIndex: _.options.zIndex}); 3850 if (callback) { 3851 setTimeout(function () { 3852 _.disableTransition(slideIndex); 3853 callback.call() 3854 }, _.options.speed) 3855 } 3856 } 3857 }; 3858 Slick.prototype.fadeSlideOut = function (slideIndex) { 3859 var _ = this; 3860 if (_.cssTransitions === false) { 3861 _.$slides.eq(slideIndex).animate({ 3862 opacity: 0, 3863 zIndex: _.options.zIndex - 2 3864 }, _.options.speed, _.options.easing) 3865 } else { 3866 _.applyTransition(slideIndex); 3867 _.$slides.eq(slideIndex).css({opacity: 0, zIndex: _.options.zIndex - 2}) 3868 } 3869 }; 3870 Slick.prototype.filterSlides = Slick.prototype.slickFilter = function (filter) { 3871 var _ = this; 3872 if (filter !== null) { 3873 _.$slidesCache = _.$slides; 3874 _.unload(); 3875 _.$slideTrack.children(this.options.slide).detach(); 3876 _.$slidesCache.filter(filter).appendTo(_.$slideTrack); 3877 _.reinit() 3878 } 3879 }; 3880 Slick.prototype.focusHandler = function () { 3881 var _ = this; 3882 _.$slider.off("focus.slick blur.slick").on("focus.slick", "*", function (event) { 3883 var $sf = $(this); 3884 setTimeout(function () { 3885 if (_.options.pauseOnFocus) { 3886 if ($sf.is(":focus")) { 3887 _.focussed = true; 3888 _.autoPlay() 3889 } 3890 } 3891 }, 0) 3892 }).on("blur.slick", "*", function (event) { 3893 var $sf = $(this); 3894 if (_.options.pauseOnFocus) { 3895 _.focussed = false; 3896 _.autoPlay() 3897 } 3898 }) 3899 }; 3900 Slick.prototype.getCurrent = Slick.prototype.slickCurrentSlide = function () { 3901 var _ = this; 3902 return _.currentSlide 3903 }; 3904 Slick.prototype.getDotCount = function () { 3905 var _ = this; 3906 var breakPoint = 0; 3907 var counter = 0; 3908 var pagerQty = 0; 3909 if (_.options.infinite === true) { 3910 if (_.slideCount <= _.options.slidesToShow) { 3911 ++pagerQty 3912 } else { 3913 while (breakPoint < _.slideCount) { 3914 ++pagerQty; 3915 breakPoint = counter + _.options.slidesToScroll; 3916 counter += _.options.slidesToScroll <= _.options.slidesToShow ? _.options.slidesToScroll : _.options.slidesToShow 3917 } 3918 } 3919 } else if (_.options.centerMode === true) { 3920 pagerQty = _.slideCount 3921 } else if (!_.options.asNavFor) { 3922 pagerQty = 1 + Math.ceil((_.slideCount - _.options.slidesToShow) / _.options.slidesToScroll) 3923 } else { 3924 while (breakPoint < _.slideCount) { 3925 ++pagerQty; 3926 breakPoint = counter + _.options.slidesToScroll; 3927 counter += _.options.slidesToScroll <= _.options.slidesToShow ? _.options.slidesToScroll : _.options.slidesToShow 3928 } 3929 } 3930 return pagerQty - 1 3931 }; 3932 Slick.prototype.getLeft = function (slideIndex) { 3933 var _ = this, targetLeft, verticalHeight, verticalOffset = 0, targetSlide, coef; 3934 _.slideOffset = 0; 3935 verticalHeight = _.$slides.first().outerHeight(true); 3936 if (_.options.infinite === true) { 3937 if (_.slideCount > _.options.slidesToShow) { 3938 _.slideOffset = _.slideWidth * _.options.slidesToShow * -1; 3939 coef = -1; 3940 if (_.options.vertical === true && _.options.centerMode === true) { 3941 if (_.options.slidesToShow === 2) { 3942 coef = -1.5 3943 } else if (_.options.slidesToShow === 1) { 3944 coef = -2 3945 } 3946 } 3947 verticalOffset = verticalHeight * _.options.slidesToShow * coef 3948 } 3949 if (_.slideCount % _.options.slidesToScroll !== 0) { 3950 if (slideIndex + _.options.slidesToScroll > _.slideCount && _.slideCount > _.options.slidesToShow) { 3951 if (slideIndex > _.slideCount) { 3952 _.slideOffset = (_.options.slidesToShow - (slideIndex - _.slideCount)) * _.slideWidth * -1; 3953 verticalOffset = (_.options.slidesToShow - (slideIndex - _.slideCount)) * verticalHeight * -1 3954 } else { 3955 _.slideOffset = _.slideCount % _.options.slidesToScroll * _.slideWidth * -1; 3956 verticalOffset = _.slideCount % _.options.slidesToScroll * verticalHeight * -1 3957 } 3958 } 3959 } 3960 } else { 3961 if (slideIndex + _.options.slidesToShow > _.slideCount) { 3962 _.slideOffset = (slideIndex + _.options.slidesToShow - _.slideCount) * _.slideWidth; 3963 verticalOffset = (slideIndex + _.options.slidesToShow - _.slideCount) * verticalHeight 3964 } 3965 } 3966 if (_.slideCount <= _.options.slidesToShow) { 3967 _.slideOffset = 0; 3968 verticalOffset = 0 3969 } 3970 if (_.options.centerMode === true && _.slideCount <= _.options.slidesToShow) { 3971 _.slideOffset = _.slideWidth * Math.floor(_.options.slidesToShow) / 2 - _.slideWidth * _.slideCount / 2 3972 } else if (_.options.centerMode === true && _.options.infinite === true) { 3973 _.slideOffset += _.slideWidth * Math.floor(_.options.slidesToShow / 2) - _.slideWidth 3974 } else if (_.options.centerMode === true) { 3975 _.slideOffset = 0; 3976 _.slideOffset += _.slideWidth * Math.floor(_.options.slidesToShow / 2) 3977 } 3978 if (_.options.vertical === false) { 3979 targetLeft = slideIndex * _.slideWidth * -1 + _.slideOffset 3980 } else { 3981 targetLeft = slideIndex * verticalHeight * -1 + verticalOffset 3982 } 3983 if (_.options.variableWidth === true) { 3984 if (_.slideCount <= _.options.slidesToShow || _.options.infinite === false) { 3985 targetSlide = _.$slideTrack.children(".slick-slide").eq(slideIndex) 3986 } else { 3987 targetSlide = _.$slideTrack.children(".slick-slide").eq(slideIndex + _.options.slidesToShow) 3988 } 3989 if (_.options.rtl === true) { 3990 if (targetSlide[0]) { 3991 targetLeft = (_.$slideTrack.width() - targetSlide[0].offsetLeft - targetSlide.width()) * -1 3992 } else { 3993 targetLeft = 0 3994 } 3995 } else { 3996 targetLeft = targetSlide[0] ? targetSlide[0].offsetLeft * -1 : 0 3997 } 3998 if (_.options.centerMode === true) { 3999 if (_.slideCount <= _.options.slidesToShow || _.options.infinite === false) { 4000 targetSlide = _.$slideTrack.children(".slick-slide").eq(slideIndex) 4001 } else { 4002 targetSlide = _.$slideTrack.children(".slick-slide").eq(slideIndex + _.options.slidesToShow + 1) 4003 } 4004 if (_.options.rtl === true) { 4005 if (targetSlide[0]) { 4006 targetLeft = (_.$slideTrack.width() - targetSlide[0].offsetLeft - targetSlide.width()) * -1 4007 } else { 4008 targetLeft = 0 4009 } 4010 } else { 4011 targetLeft = targetSlide[0] ? targetSlide[0].offsetLeft * -1 : 0 4012 } 4013 targetLeft += (_.$list.width() - targetSlide.outerWidth()) / 2 4014 } 4015 } 4016 return targetLeft 4017 }; 4018 Slick.prototype.getOption = Slick.prototype.slickGetOption = function (option) { 4019 var _ = this; 4020 return _.options[option] 4021 }; 4022 Slick.prototype.getNavigableIndexes = function () { 4023 var _ = this, breakPoint = 0, counter = 0, indexes = [], max; 4024 if (_.options.infinite === false) { 4025 max = _.slideCount 4026 } else { 4027 breakPoint = _.options.slidesToScroll * -1; 4028 counter = _.options.slidesToScroll * -1; 4029 max = _.slideCount * 2 4030 } 4031 while (breakPoint < max) { 4032 indexes.push(breakPoint); 4033 breakPoint = counter + _.options.slidesToScroll; 4034 counter += _.options.slidesToScroll <= _.options.slidesToShow ? _.options.slidesToScroll : _.options.slidesToShow 4035 } 4036 return indexes 4037 }; 4038 Slick.prototype.getSlick = function () { 4039 return this 4040 }; 4041 Slick.prototype.getSlideCount = function () { 4042 var _ = this, slidesTraversed, swipedSlide, swipeTarget, centerOffset; 4043 centerOffset = _.options.centerMode === true ? Math.floor(_.$list.width() / 2) : 0; 4044 swipeTarget = _.swipeLeft * -1 + centerOffset; 4045 if (_.options.swipeToSlide === true) { 4046 _.$slideTrack.find(".slick-slide").each(function (index, slide) { 4047 var slideOuterWidth, slideOffset, slideRightBoundary; 4048 slideOuterWidth = $(slide).outerWidth(); 4049 slideOffset = slide.offsetLeft; 4050 if (_.options.centerMode !== true) { 4051 slideOffset += slideOuterWidth / 2 4052 } 4053 slideRightBoundary = slideOffset + slideOuterWidth; 4054 if (swipeTarget < slideRightBoundary) { 4055 swipedSlide = slide; 4056 return false 4057 } 4058 }); 4059 slidesTraversed = Math.abs($(swipedSlide).attr("data-slick-index") - _.currentSlide) || 1; 4060 return slidesTraversed 4061 } else { 4062 return _.options.slidesToScroll 4063 } 4064 }; 4065 Slick.prototype.goTo = Slick.prototype.slickGoTo = function (slide, dontAnimate) { 4066 var _ = this; 4067 _.changeSlide({data: {message: "index", index: parseInt(slide)}}, dontAnimate) 4068 }; 4069 Slick.prototype.init = function (creation) { 4070 var _ = this; 4071 if (!$(_.$slider).hasClass("slick-initialized")) { 4072 $(_.$slider).addClass("slick-initialized"); 4073 _.buildRows(); 4074 _.buildOut(); 4075 _.setProps(); 4076 _.startLoad(); 4077 _.loadSlider(); 4078 _.initializeEvents(); 4079 _.updateArrows(); 4080 _.updateDots(); 4081 _.checkResponsive(true); 4082 _.focusHandler() 4083 } 4084 if (creation) { 4085 _.$slider.trigger("init", [_]) 4086 } 4087 /*if (_.options.accessibility === true) { 4088 _.initADA() 4089 }*/ 4090 if (_.options.autoplay) { 4091 _.paused = false; 4092 _.autoPlay() 4093 } 4094 }; 4095 Slick.prototype.initADA = function () { 4096 var _ = this, numDotGroups = Math.ceil(_.slideCount / _.options.slidesToShow), 4097 tabControlIndexes = _.getNavigableIndexes().filter(function (val) { 4098 return val >= 0 && val < _.slideCount 4099 }); 4100 _.$slides.add(_.$slideTrack.find(".slick-cloned")).attr({ 4101 "aria-hidden": "true", 4102 tabindex: "-1" 4103 }).find("a, input, button, select").attr({tabindex: "-1"}); 4104 if (_.$dots !== null) { 4105 _.$slides.not(_.$slideTrack.find(".slick-cloned")).each(function (i) { 4106 var slideControlIndex = tabControlIndexes.indexOf(i); 4107 $(this).attr({role: "tabpanel", id: "slick-slide" + _.instanceUid + i, tabindex: -1}); 4108 if (slideControlIndex !== -1) { 4109 var ariaButtonControl = "slick-slide-control" + _.instanceUid + slideControlIndex; 4110 if ($("#" + ariaButtonControl).length) { 4111 $(this).attr({"aria-describedby": ariaButtonControl}) 4112 } 4113 } 4114 }); 4115 _.$dots.attr("role", "tablist").find("li").each(function (i) { 4116 var mappedSlideIndex = tabControlIndexes[i]; 4117 $(this).attr({role: "presentation"}); 4118 $(this).find("button").first().attr({ 4119 role: "tab", 4120 id: "slick-slide-control" + _.instanceUid + i, 4121 "aria-controls": "slick-slide" + _.instanceUid + mappedSlideIndex, 4122 "aria-label": i + 1 + " of " + numDotGroups, 4123 "aria-selected": null, 4124 tabindex: "-1" 4125 }) 4126 }).eq(_.currentSlide).find("button").attr({"aria-selected": "true", tabindex: "0"}).end() 4127 } 4128 for (var i = _.currentSlide, max = i + _.options.slidesToShow; i < max; i++) { 4129 if (_.options.focusOnChange) { 4130 _.$slides.eq(i).attr({tabindex: "0"}) 4131 } else { 4132 _.$slides.eq(i).removeAttr("tabindex") 4133 } 4134 } 4135 _.activateADA() 4136 }; 4137 Slick.prototype.initArrowEvents = function () { 4138 var _ = this; 4139 if (_.options.arrows === true && _.slideCount > _.options.slidesToShow) { 4140 _.$prevArrow.off("click.slick").on("click.slick", {message: "previous"}, _.changeSlide); 4141 _.$nextArrow.off("click.slick").on("click.slick", {message: "next"}, _.changeSlide); 4142 if (_.options.accessibility === true) { 4143 _.$prevArrow.on("keydown.slick", _.keyHandler); 4144 _.$nextArrow.on("keydown.slick", _.keyHandler) 4145 } 4146 } 4147 }; 4148 Slick.prototype.initDotEvents = function () { 4149 var _ = this; 4150 if (_.options.dots === true && _.slideCount > _.options.slidesToShow) { 4151 $("li", _.$dots).on("click.slick", {message: "index"}, _.changeSlide); 4152 if (_.options.accessibility === true) { 4153 _.$dots.on("keydown.slick", _.keyHandler) 4154 } 4155 } 4156 if (_.options.dots === true && _.options.pauseOnDotsHover === true && _.slideCount > _.options.slidesToShow) { 4157 $("li", _.$dots).on("mouseenter.slick", $.proxy(_.interrupt, _, true)).on("mouseleave.slick", $.proxy(_.interrupt, _, false)) 4158 } 4159 }; 4160 Slick.prototype.initSlideEvents = function () { 4161 var _ = this; 4162 if (_.options.pauseOnHover) { 4163 _.$list.on("mouseenter.slick", $.proxy(_.interrupt, _, true)); 4164 _.$list.on("mouseleave.slick", $.proxy(_.interrupt, _, false)) 4165 } 4166 }; 4167 Slick.prototype.initializeEvents = function () { 4168 var _ = this; 4169 _.initArrowEvents(); 4170 _.initDotEvents(); 4171 _.initSlideEvents(); 4172 _.$list.on("touchstart.slick mousedown.slick", {action: "start"}, _.swipeHandler); 4173 _.$list.on("touchmove.slick mousemove.slick", {action: "move"}, _.swipeHandler); 4174 _.$list.on("touchend.slick mouseup.slick", {action: "end"}, _.swipeHandler); 4175 _.$list.on("touchcancel.slick mouseleave.slick", {action: "end"}, _.swipeHandler); 4176 _.$list.on("click.slick", _.clickHandler); 4177 $(document).on(_.visibilityChange, $.proxy(_.visibility, _)); 4178 if (_.options.accessibility === true) { 4179 _.$list.on("keydown.slick", _.keyHandler) 4180 } 4181 if (_.options.focusOnSelect === true) { 4182 $(_.$slideTrack).children().on("click.slick", _.selectHandler) 4183 } 4184 $(window).on("orientationchange.slick.slick-" + _.instanceUid, $.proxy(_.orientationChange, _)); 4185 $(window).on("resize.slick.slick-" + _.instanceUid, $.proxy(_.resize, _)); 4186 $("[draggable!=true]", _.$slideTrack).on("dragstart", _.preventDefault); 4187 $(window).on("load.slick.slick-" + _.instanceUid, _.setPosition); 4188 $(_.setPosition) 4189 }; 4190 Slick.prototype.initUI = function () { 4191 var _ = this; 4192 if (_.options.arrows === true && _.slideCount > _.options.slidesToShow) { 4193 _.$prevArrow.show(); 4194 _.$nextArrow.show() 4195 } 4196 if (_.options.dots === true && _.slideCount > _.options.slidesToShow) { 4197 _.$dots.show() 4198 } 4199 }; 4200 Slick.prototype.keyHandler = function (event) { 4201 var _ = this; 4202 if (!event.target.tagName.match("TEXTAREA|INPUT|SELECT")) { 4203 if (event.keyCode === 37 && _.options.accessibility === true) { 4204 _.changeSlide({data: {message: _.options.rtl === true ? "next" : "previous"}}) 4205 } else if (event.keyCode === 39 && _.options.accessibility === true) { 4206 _.changeSlide({data: {message: _.options.rtl === true ? "previous" : "next"}}) 4207 } 4208 } 4209 }; 4210 Slick.prototype.lazyLoad = function () { 4211 var _ = this, loadRange, cloneRange, rangeStart, rangeEnd; 4212 4213 function loadImages(imagesScope) { 4214 $("img[data-lazy]", imagesScope).each(function () { 4215 var image = $(this), imageSource = $(this).attr("data-lazy"), imageSrcSet = $(this).attr("data-srcset"), 4216 imageSizes = $(this).attr("data-sizes") || _.$slider.attr("data-sizes"), 4217 imageToLoad = document.createElement("img"); 4218 imageToLoad.onload = function () { 4219 image.animate({opacity: 0}, 100, function () { 4220 if (imageSrcSet) { 4221 image.attr("srcset", imageSrcSet); 4222 if (imageSizes) { 4223 image.attr("sizes", imageSizes) 4224 } 4225 } 4226 image.attr("src", imageSource).animate({opacity: 1}, 200, function () { 4227 image.removeAttr("data-lazy data-srcset data-sizes").removeClass("slick-loading") 4228 }); 4229 _.$slider.trigger("lazyLoaded", [_, image, imageSource]) 4230 }) 4231 }; 4232 imageToLoad.onerror = function () { 4233 image.removeAttr("data-lazy").removeClass("slick-loading").addClass("slick-lazyload-error"); 4234 _.$slider.trigger("lazyLoadError", [_, image, imageSource]) 4235 }; 4236 imageToLoad.src = imageSource 4237 }) 4238 } 4239 4240 if (_.options.centerMode === true) { 4241 if (_.options.infinite === true) { 4242 rangeStart = _.currentSlide + (_.options.slidesToShow / 2 + 1); 4243 rangeEnd = rangeStart + _.options.slidesToShow + 2 4244 } else { 4245 rangeStart = Math.max(0, _.currentSlide - (_.options.slidesToShow / 2 + 1)); 4246 rangeEnd = 2 + (_.options.slidesToShow / 2 + 1) + _.currentSlide 4247 } 4248 } else { 4249 rangeStart = _.options.infinite ? _.options.slidesToShow + _.currentSlide : _.currentSlide; 4250 rangeEnd = Math.ceil(rangeStart + _.options.slidesToShow); 4251 if (_.options.fade === true) { 4252 if (rangeStart > 0) rangeStart--; 4253 if (rangeEnd <= _.slideCount) rangeEnd++ 4254 } 4255 } 4256 loadRange = _.$slider.find(".slick-slide").slice(rangeStart, rangeEnd); 4257 if (_.options.lazyLoad === "anticipated") { 4258 var prevSlide = rangeStart - 1, nextSlide = rangeEnd, $slides = _.$slider.find(".slick-slide"); 4259 for (var i = 0; i < _.options.slidesToScroll; i++) { 4260 if (prevSlide < 0) prevSlide = _.slideCount - 1; 4261 loadRange = loadRange.add($slides.eq(prevSlide)); 4262 loadRange = loadRange.add($slides.eq(nextSlide)); 4263 prevSlide--; 4264 nextSlide++ 4265 } 4266 } 4267 loadImages(loadRange); 4268 if (_.slideCount <= _.options.slidesToShow) { 4269 cloneRange = _.$slider.find(".slick-slide"); 4270 loadImages(cloneRange) 4271 } else if (_.currentSlide >= _.slideCount - _.options.slidesToShow) { 4272 cloneRange = _.$slider.find(".slick-cloned").slice(0, _.options.slidesToShow); 4273 loadImages(cloneRange) 4274 } else if (_.currentSlide === 0) { 4275 cloneRange = _.$slider.find(".slick-cloned").slice(_.options.slidesToShow * -1); 4276 loadImages(cloneRange) 4277 } 4278 }; 4279 Slick.prototype.loadSlider = function () { 4280 var _ = this; 4281 _.setPosition(); 4282 _.$slideTrack.css({opacity: 1}); 4283 _.$slider.removeClass("slick-loading"); 4284 _.initUI(); 4285 if (_.options.lazyLoad === "progressive") { 4286 _.progressiveLazyLoad() 4287 } 4288 }; 4289 Slick.prototype.next = Slick.prototype.slickNext = function () { 4290 var _ = this; 4291 _.changeSlide({data: {message: "next"}}) 4292 }; 4293 Slick.prototype.orientationChange = function () { 4294 var _ = this; 4295 _.checkResponsive(); 4296 _.setPosition() 4297 }; 4298 Slick.prototype.pause = Slick.prototype.slickPause = function () { 4299 var _ = this; 4300 _.autoPlayClear(); 4301 _.paused = true 4302 }; 4303 Slick.prototype.play = Slick.prototype.slickPlay = function () { 4304 var _ = this; 4305 _.autoPlay(); 4306 _.options.autoplay = true; 4307 _.paused = false; 4308 _.focussed = false; 4309 _.interrupted = false 4310 }; 4311 Slick.prototype.postSlide = function (index) { 4312 var _ = this; 4313 if (!_.unslicked) { 4314 _.$slider.trigger("afterChange", [_, index]); 4315 _.animating = false; 4316 if (_.slideCount > _.options.slidesToShow) { 4317 _.setPosition() 4318 } 4319 _.swipeLeft = null; 4320 if (_.options.autoplay) { 4321 _.autoPlay() 4322 } 4323 /*if (_.options.accessibility === true) { 4324 _.initADA(); 4325 if (_.options.focusOnChange) { 4326 var $currentSlide = $(_.$slides.get(_.currentSlide)); 4327 $currentSlide.attr("tabindex", 0).focus() 4328 } 4329 }*/ 4330 } 4331 }; 4332 Slick.prototype.prev = Slick.prototype.slickPrev = function () { 4333 var _ = this; 4334 _.changeSlide({data: {message: "previous"}}) 4335 }; 4336 Slick.prototype.preventDefault = function (event) { 4337 event.preventDefault() 4338 }; 4339 Slick.prototype.progressiveLazyLoad = function (tryCount) { 4340 tryCount = tryCount || 1; 4341 var _ = this, $imgsToLoad = $("img[data-lazy]", _.$slider), image, imageSource, imageSrcSet, imageSizes, 4342 imageToLoad; 4343 if ($imgsToLoad.length) { 4344 image = $imgsToLoad.first(); 4345 imageSource = image.attr("data-lazy"); 4346 imageSrcSet = image.attr("data-srcset"); 4347 imageSizes = image.attr("data-sizes") || _.$slider.attr("data-sizes"); 4348 imageToLoad = document.createElement("img"); 4349 imageToLoad.onload = function () { 4350 if (imageSrcSet) { 4351 image.attr("srcset", imageSrcSet); 4352 if (imageSizes) { 4353 image.attr("sizes", imageSizes) 4354 } 4355 } 4356 image.attr("src", imageSource).removeAttr("data-lazy data-srcset data-sizes").removeClass("slick-loading"); 4357 if (_.options.adaptiveHeight === true) { 4358 _.setPosition() 4359 } 4360 _.$slider.trigger("lazyLoaded", [_, image, imageSource]); 4361 _.progressiveLazyLoad() 4362 }; 4363 imageToLoad.onerror = function () { 4364 if (tryCount < 3) { 4365 setTimeout(function () { 4366 _.progressiveLazyLoad(tryCount + 1) 4367 }, 500) 4368 } else { 4369 image.removeAttr("data-lazy").removeClass("slick-loading").addClass("slick-lazyload-error"); 4370 _.$slider.trigger("lazyLoadError", [_, image, imageSource]); 4371 _.progressiveLazyLoad() 4372 } 4373 }; 4374 imageToLoad.src = imageSource 4375 } else { 4376 _.$slider.trigger("allImagesLoaded", [_]) 4377 } 4378 }; 4379 Slick.prototype.refresh = function (initializing) { 4380 var _ = this, currentSlide, lastVisibleIndex; 4381 lastVisibleIndex = _.slideCount - _.options.slidesToShow; 4382 if (!_.options.infinite && _.currentSlide > lastVisibleIndex) { 4383 _.currentSlide = lastVisibleIndex 4384 } 4385 if (_.slideCount <= _.options.slidesToShow) { 4386 _.currentSlide = 0 4387 } 4388 currentSlide = _.currentSlide; 4389 _.destroy(true); 4390 $.extend(_, _.initials, {currentSlide: currentSlide}); 4391 _.init(); 4392 if (!initializing) { 4393 _.changeSlide({data: {message: "index", index: currentSlide}}, false) 4394 } 4395 }; 4396 Slick.prototype.registerBreakpoints = function () { 4397 var _ = this, breakpoint, currentBreakpoint, l, responsiveSettings = _.options.responsive || null; 4398 if ($.type(responsiveSettings) === "array" && responsiveSettings.length) { 4399 _.respondTo = _.options.respondTo || "window"; 4400 for (breakpoint in responsiveSettings) { 4401 l = _.breakpoints.length - 1; 4402 if (responsiveSettings.hasOwnProperty(breakpoint)) { 4403 currentBreakpoint = responsiveSettings[breakpoint].breakpoint; 4404 while (l >= 0) { 4405 if (_.breakpoints[l] && _.breakpoints[l] === currentBreakpoint) { 4406 _.breakpoints.splice(l, 1) 4407 } 4408 l-- 4409 } 4410 _.breakpoints.push(currentBreakpoint); 4411 _.breakpointSettings[currentBreakpoint] = responsiveSettings[breakpoint].settings 4412 } 4413 } 4414 _.breakpoints.sort(function (a, b) { 4415 return _.options.mobileFirst ? a - b : b - a 4416 }) 4417 } 4418 }; 4419 Slick.prototype.reinit = function () { 4420 var _ = this; 4421 _.$slides = _.$slideTrack.children(_.options.slide).addClass("slick-slide"); 4422 _.slideCount = _.$slides.length; 4423 if (_.currentSlide >= _.slideCount && _.currentSlide !== 0) { 4424 _.currentSlide = _.currentSlide - _.options.slidesToScroll 4425 } 4426 if (_.slideCount <= _.options.slidesToShow) { 4427 _.currentSlide = 0 4428 } 4429 _.registerBreakpoints(); 4430 _.setProps(); 4431 _.setupInfinite(); 4432 _.buildArrows(); 4433 _.updateArrows(); 4434 _.initArrowEvents(); 4435 _.buildDots(); 4436 _.updateDots(); 4437 _.initDotEvents(); 4438 _.cleanUpSlideEvents(); 4439 _.initSlideEvents(); 4440 _.checkResponsive(false, true); 4441 if (_.options.focusOnSelect === true) { 4442 $(_.$slideTrack).children().on("click.slick", _.selectHandler) 4443 } 4444 _.setSlideClasses(typeof _.currentSlide === "number" ? _.currentSlide : 0); 4445 _.setPosition(); 4446 _.focusHandler(); 4447 _.paused = !_.options.autoplay; 4448 _.autoPlay(); 4449 _.$slider.trigger("reInit", [_]) 4450 }; 4451 Slick.prototype.resize = function () { 4452 var _ = this; 4453 if ($(window).width() !== _.windowWidth) { 4454 clearTimeout(_.windowDelay); 4455 _.windowDelay = window.setTimeout(function () { 4456 _.windowWidth = $(window).width(); 4457 _.checkResponsive(); 4458 if (!_.unslicked) { 4459 _.setPosition() 4460 } 4461 }, 50) 4462 } 4463 }; 4464 Slick.prototype.removeSlide = Slick.prototype.slickRemove = function (index, removeBefore, removeAll) { 4465 var _ = this; 4466 if (typeof index === "boolean") { 4467 removeBefore = index; 4468 index = removeBefore === true ? 0 : _.slideCount - 1 4469 } else { 4470 index = removeBefore === true ? --index : index 4471 } 4472 if (_.slideCount < 1 || index < 0 || index > _.slideCount - 1) { 4473 return false 4474 } 4475 _.unload(); 4476 if (removeAll === true) { 4477 _.$slideTrack.children().remove() 4478 } else { 4479 _.$slideTrack.children(this.options.slide).eq(index).remove() 4480 } 4481 _.$slides = _.$slideTrack.children(this.options.slide); 4482 _.$slideTrack.children(this.options.slide).detach(); 4483 _.$slideTrack.append(_.$slides); 4484 _.$slidesCache = _.$slides; 4485 _.reinit() 4486 }; 4487 Slick.prototype.setCSS = function (position) { 4488 var _ = this, positionProps = {}, x, y; 4489 if (_.options.rtl === true) { 4490 position = -position 4491 } 4492 x = _.positionProp == "left" ? Math.ceil(position) + "px" : "0px"; 4493 y = _.positionProp == "top" ? Math.ceil(position) + "px" : "0px"; 4494 positionProps[_.positionProp] = position; 4495 if (_.transformsEnabled === false) { 4496 _.$slideTrack.css(positionProps) 4497 } else { 4498 positionProps = {}; 4499 if (_.cssTransitions === false) { 4500 positionProps[_.animType] = "translate(" + x + ", " + y + ")"; 4501 _.$slideTrack.css(positionProps) 4502 } else { 4503 positionProps[_.animType] = "translate3d(" + x + ", " + y + ", 0px)"; 4504 _.$slideTrack.css(positionProps) 4505 } 4506 } 4507 }; 4508 Slick.prototype.setDimensions = function () { 4509 var _ = this; 4510 if (_.options.vertical === false) { 4511 if (_.options.centerMode === true) { 4512 _.$list.css({padding: "0px " + _.options.centerPadding}) 4513 } 4514 } else { 4515 _.$list.height(_.$slides.first().outerHeight(true) * _.options.slidesToShow); 4516 if (_.options.centerMode === true) { 4517 _.$list.css({padding: _.options.centerPadding + " 0px"}) 4518 } 4519 } 4520 _.listWidth = _.$list.width(); 4521 _.listHeight = _.$list.height(); 4522 if (_.options.vertical === false && _.options.variableWidth === false) { 4523 _.slideWidth = Math.ceil(_.listWidth / _.options.slidesToShow); 4524 _.$slideTrack.width(Math.ceil(_.slideWidth * _.$slideTrack.children(".slick-slide").length)) 4525 } else if (_.options.variableWidth === true) { 4526 _.$slideTrack.width(5e3 * _.slideCount) 4527 } else { 4528 _.slideWidth = Math.ceil(_.listWidth); 4529 _.$slideTrack.height(Math.ceil(_.$slides.first().outerHeight(true) * _.$slideTrack.children(".slick-slide").length)) 4530 } 4531 var offset = _.$slides.first().outerWidth(true) - _.$slides.first().width(); 4532 if (_.options.variableWidth === false) { 4533 var offsetWidth = _.slideWidth - offset; 4534 var offsetHeight = offsetWidth * 1.33333333; 4535 _.$slideTrack.children(".slick-slide").width(offsetWidth).height(offsetHeight); 4536 } 4537 }; 4538 Slick.prototype.setFade = function () { 4539 var _ = this, targetLeft; 4540 _.$slides.each(function (index, element) { 4541 targetLeft = _.slideWidth * index * -1; 4542 if (_.options.rtl === true) { 4543 $(element).css({ 4544 position: "relative", 4545 right: targetLeft, 4546 top: 0, 4547 zIndex: _.options.zIndex - 2, 4548 opacity: 0 4549 }) 4550 } else { 4551 $(element).css({ 4552 position: "relative", 4553 left: targetLeft, 4554 top: 0, 4555 zIndex: _.options.zIndex - 2, 4556 opacity: 0 4557 }) 4558 } 4559 }); 4560 _.$slides.eq(_.currentSlide).css({zIndex: _.options.zIndex - 1, opacity: 1}) 4561 }; 4562 Slick.prototype.setHeight = function () { 4563 var _ = this; 4564 if (_.options.slidesToShow === 1 && _.options.adaptiveHeight === true && _.options.vertical === false) { 4565 var targetHeight = _.$slides.eq(_.currentSlide).outerHeight(true); 4566 _.$list.css("height", targetHeight) 4567 } 4568 }; 4569 Slick.prototype.setOption = Slick.prototype.slickSetOption = function () { 4570 var _ = this, l, item, option, value, refresh = false, type; 4571 if ($.type(arguments[0]) === "object") { 4572 option = arguments[0]; 4573 refresh = arguments[1]; 4574 type = "multiple" 4575 } else if ($.type(arguments[0]) === "string") { 4576 option = arguments[0]; 4577 value = arguments[1]; 4578 refresh = arguments[2]; 4579 if (arguments[0] === "responsive" && $.type(arguments[1]) === "array") { 4580 type = "responsive" 4581 } else if (typeof arguments[1] !== "undefined") { 4582 type = "single" 4583 } 4584 } 4585 if (type === "single") { 4586 _.options[option] = value 4587 } else if (type === "multiple") { 4588 $.each(option, function (opt, val) { 4589 _.options[opt] = val 4590 }) 4591 } else if (type === "responsive") { 4592 for (item in value) { 4593 if ($.type(_.options.responsive) !== "array") { 4594 _.options.responsive = [value[item]] 4595 } else { 4596 l = _.options.responsive.length - 1; 4597 while (l >= 0) { 4598 if (_.options.responsive[l].breakpoint === value[item].breakpoint) { 4599 _.options.responsive.splice(l, 1) 4600 } 4601 l-- 4602 } 4603 _.options.responsive.push(value[item]) 4604 } 4605 } 4606 } 4607 if (refresh) { 4608 _.unload(); 4609 _.reinit() 4610 } 4611 }; 4612 Slick.prototype.setPosition = function () { 4613 var _ = this; 4614 _.setDimensions(); 4615 _.setHeight(); 4616 if (_.options.fade === false) { 4617 _.setCSS(_.getLeft(_.currentSlide)) 4618 } else { 4619 _.setFade() 4620 } 4621 _.$slider.trigger("setPosition", [_]) 4622 }; 4623 Slick.prototype.setProps = function () { 4624 var _ = this, bodyStyle = document.body.style; 4625 _.positionProp = _.options.vertical === true ? "top" : "left"; 4626 if (_.positionProp === "top") { 4627 _.$slider.addClass("slick-vertical") 4628 } else { 4629 _.$slider.removeClass("slick-vertical") 4630 } 4631 if (bodyStyle.WebkitTransition !== undefined || bodyStyle.MozTransition !== undefined || bodyStyle.msTransition !== undefined) { 4632 if (_.options.useCSS === true) { 4633 _.cssTransitions = true 4634 } 4635 } 4636 if (_.options.fade) { 4637 if (typeof _.options.zIndex === "number") { 4638 if (_.options.zIndex < 3) { 4639 _.options.zIndex = 3 4640 } 4641 } else { 4642 _.options.zIndex = _.defaults.zIndex 4643 } 4644 } 4645 if (bodyStyle.OTransform !== undefined) { 4646 _.animType = "OTransform"; 4647 _.transformType = "-o-transform"; 4648 _.transitionType = "OTransition"; 4649 if (bodyStyle.perspectiveProperty === undefined && bodyStyle.webkitPerspective === undefined) _.animType = false 4650 } 4651 if (bodyStyle.MozTransform !== undefined) { 4652 _.animType = "MozTransform"; 4653 _.transformType = "-moz-transform"; 4654 _.transitionType = "MozTransition"; 4655 if (bodyStyle.perspectiveProperty === undefined && bodyStyle.MozPerspective === undefined) _.animType = false 4656 } 4657 if (bodyStyle.webkitTransform !== undefined) { 4658 _.animType = "webkitTransform"; 4659 _.transformType = "-webkit-transform"; 4660 _.transitionType = "webkitTransition"; 4661 if (bodyStyle.perspectiveProperty === undefined && bodyStyle.webkitPerspective === undefined) _.animType = false 4662 } 4663 if (bodyStyle.msTransform !== undefined) { 4664 _.animType = "msTransform"; 4665 _.transformType = "-ms-transform"; 4666 _.transitionType = "msTransition"; 4667 if (bodyStyle.msTransform === undefined) _.animType = false 4668 } 4669 if (bodyStyle.transform !== undefined && _.animType !== false) { 4670 _.animType = "transform"; 4671 _.transformType = "transform"; 4672 _.transitionType = "transition" 4673 } 4674 _.transformsEnabled = _.options.useTransform && (_.animType !== null && _.animType !== false) 4675 }; 4676 Slick.prototype.setSlideClasses = function (index) { 4677 var _ = this, centerOffset, allSlides, indexOffset, remainder; 4678 allSlides = _.$slider.find(".slick-slide").removeClass("slick-active slick-center slick-current").attr("aria-hidden", "true"); 4679 _.$slides.eq(index).addClass("slick-current"); 4680 if (_.options.centerMode === true) { 4681 var evenCoef = _.options.slidesToShow % 2 === 0 ? 1 : 0; 4682 centerOffset = Math.floor(_.options.slidesToShow / 2); 4683 if (_.options.infinite === true) { 4684 if (index >= centerOffset && index <= _.slideCount - 1 - centerOffset) { 4685 _.$slides.slice(index - centerOffset + evenCoef, index + centerOffset + 1).addClass("slick-active").attr("aria-hidden", "false") 4686 } else { 4687 indexOffset = _.options.slidesToShow + index; 4688 allSlides.slice(indexOffset - centerOffset + 1 + evenCoef, indexOffset + centerOffset + 2).addClass("slick-active").attr("aria-hidden", "false") 4689 } 4690 if (index === 0) { 4691 allSlides.eq(allSlides.length - 1 - _.options.slidesToShow).addClass("slick-center") 4692 } else if (index === _.slideCount - 1) { 4693 allSlides.eq(_.options.slidesToShow).addClass("slick-center") 4694 } 4695 } 4696 _.$slides.eq(index).addClass("slick-center") 4697 } else { 4698 if (index >= 0 && index <= _.slideCount - _.options.slidesToShow) { 4699 _.$slides.slice(index, index + _.options.slidesToShow).addClass("slick-active").attr("aria-hidden", "false") 4700 } else if (allSlides.length <= _.options.slidesToShow) { 4701 allSlides.addClass("slick-active").attr("aria-hidden", "false") 4702 } else { 4703 remainder = _.slideCount % _.options.slidesToShow; 4704 indexOffset = _.options.infinite === true ? _.options.slidesToShow + index : index; 4705 if (_.options.slidesToShow == _.options.slidesToScroll && _.slideCount - index < _.options.slidesToShow) { 4706 allSlides.slice(indexOffset - (_.options.slidesToShow - remainder), indexOffset + remainder).addClass("slick-active").attr("aria-hidden", "false") 4707 } else { 4708 allSlides.slice(indexOffset, indexOffset + _.options.slidesToShow).addClass("slick-active").attr("aria-hidden", "false") 4709 } 4710 } 4711 } 4712 if (_.options.lazyLoad === "ondemand" || _.options.lazyLoad === "anticipated") { 4713 _.lazyLoad() 4714 } 4715 }; 4716 Slick.prototype.setupInfinite = function () { 4717 var _ = this, i, slideIndex, infiniteCount; 4718 if (_.options.fade === true) { 4719 _.options.centerMode = false 4720 } 4721 if (_.options.infinite === true && _.options.fade === false) { 4722 slideIndex = null; 4723 if (_.slideCount > _.options.slidesToShow) { 4724 if (_.options.centerMode === true) { 4725 infiniteCount = _.options.slidesToShow + 1 4726 } else { 4727 infiniteCount = _.options.slidesToShow 4728 } 4729 for (i = _.slideCount; i > _.slideCount - infiniteCount; i -= 1) { 4730 slideIndex = i - 1; 4731 $(_.$slides[slideIndex]).clone(true).attr("id", "").attr("data-slick-index", slideIndex - _.slideCount).prependTo(_.$slideTrack).addClass("slick-cloned") 4732 } 4733 for (i = 0; i < infiniteCount + _.slideCount; i += 1) { 4734 slideIndex = i; 4735 $(_.$slides[slideIndex]).clone(true).attr("id", "").attr("data-slick-index", slideIndex + _.slideCount).appendTo(_.$slideTrack).addClass("slick-cloned") 4736 } 4737 _.$slideTrack.find(".slick-cloned").find("[id]").each(function () { 4738 $(this).attr("id", "") 4739 }) 4740 } 4741 } 4742 }; 4743 Slick.prototype.interrupt = function (toggle) { 4744 var _ = this; 4745 if (!toggle) { 4746 _.autoPlay() 4747 } 4748 _.interrupted = toggle 4749 }; 4750 Slick.prototype.selectHandler = function (event) { 4751 var _ = this; 4752 var targetElement = $(event.target).is(".slick-slide") ? $(event.target) : $(event.target).parents(".slick-slide"); 4753 var index = parseInt(targetElement.attr("data-slick-index")); 4754 if (!index) index = 0; 4755 if (_.slideCount <= _.options.slidesToShow) { 4756 _.slideHandler(index, false, true); 4757 return 4758 } 4759 _.slideHandler(index) 4760 }; 4761 Slick.prototype.slideHandler = function (index, sync, dontAnimate) { 4762 var targetSlide, animSlide, oldSlide, slideLeft, targetLeft = null, _ = this, navTarget; 4763 sync = sync || false; 4764 if (_.animating === true && _.options.waitForAnimate === true) { 4765 return 4766 } 4767 if (_.options.fade === true && _.currentSlide === index) { 4768 return 4769 } 4770 if (sync === false) { 4771 _.asNavFor(index) 4772 } 4773 targetSlide = index; 4774 targetLeft = _.getLeft(targetSlide); 4775 slideLeft = _.getLeft(_.currentSlide); 4776 _.currentLeft = _.swipeLeft === null ? slideLeft : _.swipeLeft; 4777 if (_.options.infinite === false && _.options.centerMode === false && (index < 0 || index > _.getDotCount() * _.options.slidesToScroll)) { 4778 if (_.options.fade === false) { 4779 targetSlide = _.currentSlide; 4780 if (dontAnimate !== true && _.slideCount > _.options.slidesToShow) { 4781 _.animateSlide(slideLeft, function () { 4782 _.postSlide(targetSlide) 4783 }) 4784 } else { 4785 _.postSlide(targetSlide) 4786 } 4787 } 4788 return 4789 } else if (_.options.infinite === false && _.options.centerMode === true && (index < 0 || index > _.slideCount - _.options.slidesToScroll)) { 4790 if (_.options.fade === false) { 4791 targetSlide = _.currentSlide; 4792 if (dontAnimate !== true && _.slideCount > _.options.slidesToShow) { 4793 _.animateSlide(slideLeft, function () { 4794 _.postSlide(targetSlide) 4795 }) 4796 } else { 4797 _.postSlide(targetSlide) 4798 } 4799 } 4800 return 4801 } 4802 if (_.options.autoplay) { 4803 clearInterval(_.autoPlayTimer) 4804 } 4805 if (targetSlide < 0) { 4806 if (_.slideCount % _.options.slidesToScroll !== 0) { 4807 animSlide = _.slideCount - _.slideCount % _.options.slidesToScroll 4808 } else { 4809 animSlide = _.slideCount + targetSlide 4810 } 4811 } else if (targetSlide >= _.slideCount) { 4812 if (_.slideCount % _.options.slidesToScroll !== 0) { 4813 animSlide = 0 4814 } else { 4815 animSlide = targetSlide - _.slideCount 4816 } 4817 } else { 4818 animSlide = targetSlide 4819 } 4820 _.animating = true; 4821 _.$slider.trigger("beforeChange", [_, _.currentSlide, animSlide]); 4822 oldSlide = _.currentSlide; 4823 _.currentSlide = animSlide; 4824 _.setSlideClasses(_.currentSlide); 4825 if (_.options.asNavFor) { 4826 navTarget = _.getNavTarget(); 4827 navTarget = navTarget.slick("getSlick"); 4828 if (navTarget.slideCount <= navTarget.options.slidesToShow) { 4829 navTarget.setSlideClasses(_.currentSlide) 4830 } 4831 } 4832 _.updateDots(); 4833 _.updateArrows(); 4834 if (_.options.fade === true) { 4835 if (dontAnimate !== true) { 4836 _.fadeSlideOut(oldSlide); 4837 _.fadeSlide(animSlide, function () { 4838 _.postSlide(animSlide) 4839 }) 4840 } else { 4841 _.postSlide(animSlide) 4842 } 4843 _.animateHeight(); 4844 return 4845 } 4846 if (dontAnimate !== true && _.slideCount > _.options.slidesToShow) { 4847 _.animateSlide(targetLeft, function () { 4848 _.postSlide(animSlide) 4849 }) 4850 } else { 4851 _.postSlide(animSlide) 4852 } 4853 }; 4854 Slick.prototype.startLoad = function () { 4855 var _ = this; 4856 if (_.options.arrows === true && _.slideCount > _.options.slidesToShow) { 4857 _.$prevArrow.hide(); 4858 _.$nextArrow.hide() 4859 } 4860 if (_.options.dots === true && _.slideCount > _.options.slidesToShow) { 4861 _.$dots.hide() 4862 } 4863 _.$slider.addClass("slick-loading") 4864 }; 4865 Slick.prototype.swipeDirection = function () { 4866 var xDist, yDist, r, swipeAngle, _ = this; 4867 xDist = _.touchObject.startX - _.touchObject.curX; 4868 yDist = _.touchObject.startY - _.touchObject.curY; 4869 r = Math.atan2(yDist, xDist); 4870 swipeAngle = Math.round(r * 180 / Math.PI); 4871 if (swipeAngle < 0) { 4872 swipeAngle = 360 - Math.abs(swipeAngle) 4873 } 4874 if (swipeAngle <= 45 && swipeAngle >= 0) { 4875 return _.options.rtl === false ? "left" : "right" 4876 } 4877 if (swipeAngle <= 360 && swipeAngle >= 315) { 4878 return _.options.rtl === false ? "left" : "right" 4879 } 4880 if (swipeAngle >= 135 && swipeAngle <= 225) { 4881 return _.options.rtl === false ? "right" : "left" 4882 } 4883 if (_.options.verticalSwiping === true) { 4884 if (swipeAngle >= 35 && swipeAngle <= 135) { 4885 return "down" 4886 } else { 4887 return "up" 4888 } 4889 } 4890 return "vertical" 4891 }; 4892 Slick.prototype.swipeEnd = function (event) { 4893 var _ = this, slideCount, direction; 4894 _.dragging = false; 4895 _.swiping = false; 4896 if (_.scrolling) { 4897 _.scrolling = false; 4898 return false 4899 } 4900 _.interrupted = false; 4901 _.shouldClick = _.touchObject.swipeLength > 10 ? false : true; 4902 if (_.touchObject.curX === undefined) { 4903 return false 4904 } 4905 if (_.touchObject.edgeHit === true) { 4906 _.$slider.trigger("edge", [_, _.swipeDirection()]) 4907 } 4908 if (_.touchObject.swipeLength >= _.touchObject.minSwipe) { 4909 direction = _.swipeDirection(); 4910 switch (direction) { 4911 case"left": 4912 case"down": 4913 slideCount = _.options.swipeToSlide ? _.checkNavigable(_.currentSlide + _.getSlideCount()) : _.currentSlide + _.getSlideCount(); 4914 _.currentDirection = 0; 4915 break; 4916 case"right": 4917 case"up": 4918 slideCount = _.options.swipeToSlide ? _.checkNavigable(_.currentSlide - _.getSlideCount()) : _.currentSlide - _.getSlideCount(); 4919 _.currentDirection = 1; 4920 break; 4921 default: 4922 } 4923 if (direction != "vertical") { 4924 _.slideHandler(slideCount); 4925 _.touchObject = {}; 4926 _.$slider.trigger("swipe", [_, direction]) 4927 } 4928 } else { 4929 if (_.touchObject.startX !== _.touchObject.curX) { 4930 _.slideHandler(_.currentSlide); 4931 _.touchObject = {} 4932 } 4933 } 4934 }; 4935 Slick.prototype.swipeHandler = function (event) { 4936 var _ = this; 4937 if (_.options.swipe === false || "ontouchend" in document && _.options.swipe === false) { 4938 return 4939 } else if (_.options.draggable === false && event.type.indexOf("mouse") !== -1) { 4940 return 4941 } 4942 _.touchObject.fingerCount = event.originalEvent && event.originalEvent.touches !== undefined ? event.originalEvent.touches.length : 1; 4943 _.touchObject.minSwipe = _.listWidth / _.options.touchThreshold; 4944 if (_.options.verticalSwiping === true) { 4945 _.touchObject.minSwipe = _.listHeight / _.options.touchThreshold 4946 } 4947 switch (event.data.action) { 4948 case"start": 4949 _.swipeStart(event); 4950 break; 4951 case"move": 4952 _.swipeMove(event); 4953 break; 4954 case"end": 4955 _.swipeEnd(event); 4956 break 4957 } 4958 }; 4959 Slick.prototype.swipeMove = function (event) { 4960 var _ = this, edgeWasHit = false, curLeft, swipeDirection, swipeLength, positionOffset, touches, 4961 verticalSwipeLength; 4962 touches = event.originalEvent !== undefined ? event.originalEvent.touches : null; 4963 if (!_.dragging || _.scrolling || touches && touches.length !== 1) { 4964 return false 4965 } 4966 curLeft = _.getLeft(_.currentSlide); 4967 _.touchObject.curX = touches !== undefined ? touches[0].pageX : event.clientX; 4968 _.touchObject.curY = touches !== undefined ? touches[0].pageY : event.clientY; 4969 _.touchObject.swipeLength = Math.round(Math.sqrt(Math.pow(_.touchObject.curX - _.touchObject.startX, 2))); 4970 verticalSwipeLength = Math.round(Math.sqrt(Math.pow(_.touchObject.curY - _.touchObject.startY, 2))); 4971 if (!_.options.verticalSwiping && !_.swiping && verticalSwipeLength > 4) { 4972 _.scrolling = true; 4973 return false 4974 } 4975 if (_.options.verticalSwiping === true) { 4976 _.touchObject.swipeLength = verticalSwipeLength 4977 } 4978 swipeDirection = _.swipeDirection(); 4979 if (event.originalEvent !== undefined && _.touchObject.swipeLength > 4) { 4980 _.swiping = true; 4981 event.preventDefault() 4982 } 4983 positionOffset = (_.options.rtl === false ? 1 : -1) * (_.touchObject.curX > _.touchObject.startX ? 1 : -1); 4984 if (_.options.verticalSwiping === true) { 4985 positionOffset = _.touchObject.curY > _.touchObject.startY ? 1 : -1 4986 } 4987 swipeLength = _.touchObject.swipeLength; 4988 _.touchObject.edgeHit = false; 4989 if (_.options.infinite === false) { 4990 if (_.currentSlide === 0 && swipeDirection === "right" || _.currentSlide >= _.getDotCount() && swipeDirection === "left") { 4991 swipeLength = _.touchObject.swipeLength * _.options.edgeFriction; 4992 _.touchObject.edgeHit = true 4993 } 4994 } 4995 if (_.options.vertical === false) { 4996 _.swipeLeft = curLeft + swipeLength * positionOffset 4997 } else { 4998 _.swipeLeft = curLeft + swipeLength * (_.$list.height() / _.listWidth) * positionOffset 4999 } 5000 if (_.options.verticalSwiping === true) { 5001 _.swipeLeft = curLeft + swipeLength * positionOffset 5002 } 5003 if (_.options.fade === true || _.options.touchMove === false) { 5004 return false 5005 } 5006 if (_.animating === true) { 5007 _.swipeLeft = null; 5008 return false 5009 } 5010 _.setCSS(_.swipeLeft) 5011 }; 5012 Slick.prototype.swipeStart = function (event) { 5013 var _ = this, touches; 5014 _.interrupted = true; 5015 if (_.touchObject.fingerCount !== 1 || _.slideCount <= _.options.slidesToShow) { 5016 _.touchObject = {}; 5017 return false 5018 } 5019 if (event.originalEvent !== undefined && event.originalEvent.touches !== undefined) { 5020 touches = event.originalEvent.touches[0] 5021 } 5022 _.touchObject.startX = _.touchObject.curX = touches !== undefined ? touches.pageX : event.clientX; 5023 _.touchObject.startY = _.touchObject.curY = touches !== undefined ? touches.pageY : event.clientY; 5024 _.dragging = true 5025 }; 5026 Slick.prototype.unfilterSlides = Slick.prototype.slickUnfilter = function () { 5027 var _ = this; 5028 if (_.$slidesCache !== null) { 5029 _.unload(); 5030 _.$slideTrack.children(this.options.slide).detach(); 5031 _.$slidesCache.appendTo(_.$slideTrack); 5032 _.reinit() 5033 } 5034 }; 5035 Slick.prototype.unload = function () { 5036 var _ = this; 5037 $(".slick-cloned", _.$slider).remove(); 5038 if (_.$dots) { 5039 _.$dots.remove() 5040 } 5041 if (_.$prevArrow && _.htmlExpr.test(_.options.prevArrow)) { 5042 _.$prevArrow.remove() 5043 } 5044 if (_.$nextArrow && _.htmlExpr.test(_.options.nextArrow)) { 5045 _.$nextArrow.remove() 5046 } 5047 _.$slides.removeClass("slick-slide slick-active slick-visible slick-current").attr("aria-hidden", "true").css("width", "") 5048 };
5049 Slick.prototype.unslick = function (fromBreakpoint) { 5050 var _ = this; 5051 _.$slider.trigger("unslick", [_, fromBreakpoint]); 5052 _.destroy() 5053 }; 5054 Slick.prototype.updateArrows = function () { 5055 var _ = this, centerOffset; 5056 centerOffset = Math.floor(_.options.slidesToShow / 2); 5057 if (_.options.arrows === true && _.slideCount > _.options.slidesToShow && !_.options.infinite) { 5058 _.$prevArrow.removeClass("slick-disabled").attr("aria-disabled", "false"); 5059 _.$nextArrow.removeClass("slick-disabled").attr("aria-disabled", "false"); 5060 if (_.currentSlide === 0) { 5061 _.$prevArrow.addClass("slick-disabled").attr("aria-disabled", "true"); 5062 _.$nextArrow.removeClass("slick-disabled").attr("aria-disabled", "false") 5063 } else if (_.currentSlide >= _.slideCount - _.options.slidesToShow && _.options.centerMode === false) { 5064 _.$nextArrow.addClass("slick-disabled").attr("aria-disabled", "true"); 5065 _.$prevArrow.removeClass("slick-disabled").attr("aria-disabled", "false") 5066 } else if (_.currentSlide >= _.slideCount - 1 && _.options.centerMode === true) { 5067 _.$nextArrow.addClass("slick-disabled").attr("aria-disabled", "true"); 5068 _.$prevArrow.removeClass("slick-disabled").attr("aria-disabled", "false") 5069 } 5070 } 5071 }; 5072 Slick.prototype.updateDots = function () { 5073 var _ = this; 5074 if (_.$dots !== null) { 5075 _.$dots.find("li").removeClass("slick-active").end(); 5076 _.$dots.find("li").eq(Math.floor(_.currentSlide / _.options.slidesToScroll)).addClass("slick-active") 5077 } 5078 }; 5079 Slick.prototype.visibility = function () { 5080 var _ = this; 5081 if (_.options.autoplay) { 5082 if (document[_.hidden]) { 5083 _.interrupted = true 5084 } else { 5085 _.interrupted = false 5086 } 5087 } 5088 }; 5089 $.fn.slick = function () { 5090 var _ = this, opt = arguments[0], args = Array.prototype.slice.call(arguments, 1), l = _.length, i, ret; 5091 for (i = 0; i < l; i++) { 5092 if (typeof opt == "object" || typeof opt == "undefined") _[i].slick = new Slick(_[i], opt); else ret = _[i].slick[opt].apply(_[i].slick, args); 5093 if (typeof ret != "undefined") return ret 5094 } 5095 return _ 5096 } 5097}); 5098/* End */ 5099; 5100; /* Start:"a:4:{s:4:"full";s:57:"/local/templates/bitrix66/js/lazysizes.js?178963401228678";s:6:"source";s:41:"/local/templates/bitrix66/js/lazysizes.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/ 5101(function(window, factory) { 5102 var lazySizes = factory(window, window.document, Date); 5103 window.lazySizes = lazySizes; 5104 if(typeof module == 'object' && module.exports){ 5105 module.exports = lazySizes; 5106 } 5107}(typeof window != 'undefined' ? 5108 window : {}, 5109 /** 5110 * @typedef { import("./types/global").LazySizesConfigPartial } LazySizesConfigPartial 5111 */ 5112 function l(window, document, Date) { // Pass in the window Date function also for SSR because the Date class can be lost 5113 'use strict'; 5114 /*jshint eqnull:true */ 5115 5116 var lazysizes, 5117 /** 5118 * @type { LazySizesConfigPartial } 5119 */ 5120 lazySizesCfg; 5121 5122 (function(){ 5123 var prop; 5124 5125 var lazySizesDefaults = { 5126 lazyClass: 'lazyload', 5127 loadedClass: 'lazyloaded', 5128 loadingClass: 'lazyloading', 5129 preloadClass: 'lazypreload', 5130 errorClass: 'lazyerror', 5131 //strictClass: 'lazystrict', 5132 autosizesClass: 'lazyautosizes', 5133 fastLoadedClass: 'ls-is-cached', 5134 iframeLoadMode: 0, 5135 srcAttr: 'data-src', 5136 srcsetAttr: 'data-srcset', 5137 sizesAttr: 'data-sizes', 5138 //preloadAfterLoad: false, 5139 minSize: 40, 5140 customMedia: {}, 5141 init: true, 5142 expFactor: 1.5, 5143 hFac: 0.8, 5144 loadMode: 2, 5145 loadHidden: true, 5146 ricTimeout: 0, 5147 throttleDelay: 125, 5148 }; 5149 5150 lazySizesCfg = window.lazySizesConfig || window.lazysizesConfig || {}; 5151 5152 for(prop in lazySizesDefaults){ 5153 if(!(prop in lazySizesCfg)){ 5154 lazySizesCfg[prop] = lazySizesDefaults[prop]; 5155 } 5156 } 5157 })(); 5158 5159 if (!document || !document.getElementsByClassName) { 5160 return { 5161 init: function () {}, 5162 /** 5163 * @type { LazySizesConfigPartial } 5164 */ 5165 cfg: lazySizesCfg, 5166 /** 5167 * @type { true } 5168 */ 5169 noSupport: true, 5170 }; 5171 } 5172 5173 var docElem = document.documentElement; 5174 5175 var supportPicture = window.HTMLPictureElement; 5176 5177 var _addEventListener = 'addEventListener'; 5178 5179 var _getAttribute = 'getAttribute'; 5180 5181 /** 5182 * Update to bind to window because 'this' becomes null during SSR 5183 * builds. 5184 */ 5185 var addEventListener = window[_addEventListener].bind(window); 5186 5187 var setTimeout = window.setTimeout; 5188 5189 var requestAnimationFrame = window.requestAnimationFrame || setTimeout; 5190 5191 var requestIdleCallback = window.requestIdleCallback; 5192 5193 var regPicture = /^picture$/i; 5194 5195 var loadEvents = ['load', 'error', 'lazyincluded', '_lazyloaded']; 5196 5197 var regClassCache = {}; 5198
vendor: 25,704 bytes, lines 5199-5917
5199 var forEach = Array.prototype.forEach; 5200 5201 /** 5202 * @param ele {Element} 5203 * @param cls {string} 5204 */ 5205 var hasClass = function(ele, cls) { 5206 if(!regClassCache[cls]){ 5207 regClassCache[cls] = new RegExp('(\\s|^)'+cls+'(\\s|$)'); 5208 } 5209 return regClassCache[cls].test(ele[_getAttribute]('class') || '') && regClassCache[cls]; 5210 }; 5211 5212 /** 5213 * @param ele {Element} 5214 * @param cls {string} 5215 */ 5216 var addClass = function(ele, cls) { 5217 if (!hasClass(ele, cls)){ 5218 ele.setAttribute('class', (ele[_getAttribute]('class') || '').trim() + ' ' + cls); 5219 } 5220 }; 5221 5222 /** 5223 * @param ele {Element} 5224 * @param cls {string} 5225 */ 5226 var removeClass = function(ele, cls) { 5227 var reg; 5228 if ((reg = hasClass(ele,cls))) { 5229 ele.setAttribute('class', (ele[_getAttribute]('class') || '').replace(reg, ' ')); 5230 } 5231 }; 5232 5233 var addRemoveLoadEvents = function(dom, fn, add){ 5234 var action = add ? _addEventListener : 'removeEventListener'; 5235 if(add){ 5236 addRemoveLoadEvents(dom, fn); 5237 } 5238 loadEvents.forEach(function(evt){ 5239 dom[action](evt, fn); 5240 }); 5241 }; 5242 5243 /** 5244 * @param elem { Element } 5245 * @param name { string } 5246 * @param detail { any } 5247 * @param noBubbles { boolean } 5248 * @param noCancelable { boolean } 5249 * @returns { CustomEvent } 5250 */ 5251 var triggerEvent = function(elem, name, detail, noBubbles, noCancelable){ 5252 var event = document.createEvent('Event'); 5253 5254 if(!detail){ 5255 detail = {}; 5256 } 5257 5258 detail.instance = lazysizes; 5259 5260 event.initEvent(name, !noBubbles, !noCancelable); 5261 5262 event.detail = detail; 5263 5264 elem.dispatchEvent(event); 5265 return event; 5266 }; 5267 5268 var updatePolyfill = function (el, full){ 5269 var polyfill; 5270 if( !supportPicture && ( polyfill = (window.picturefill || lazySizesCfg.pf) ) ){ 5271 if(full && full.src && !el[_getAttribute]('srcset')){ 5272 el.setAttribute('srcset', full.src); 5273 } 5274 polyfill({reevaluate: true, elements: [el]}); 5275 } else if(full && full.src){ 5276 el.src = full.src; 5277 } 5278 }; 5279 5280 var getCSS = function (elem, style){ 5281 return (getComputedStyle(elem, null) || {})[style]; 5282 }; 5283 5284 /** 5285 * 5286 * @param elem { Element } 5287 * @param parent { Element } 5288 * @param [width] {number} 5289 * @returns {number} 5290 */ 5291 var getWidth = function(elem, parent, width){ 5292 width = width || elem.offsetWidth; 5293 5294 while(width < lazySizesCfg.minSize && parent && !elem._lazysizesWidth){ 5295 width = parent.offsetWidth; 5296 parent = parent.parentNode; 5297 } 5298 5299 return width; 5300 }; 5301 5302 var rAF = (function(){ 5303 var running, waiting; 5304 var firstFns = []; 5305 var secondFns = []; 5306 var fns = firstFns; 5307 5308 var run = function(){ 5309 var runFns = fns; 5310 5311 fns = firstFns.length ? secondFns : firstFns; 5312 5313 running = true; 5314 waiting = false; 5315 5316 while(runFns.length){ 5317 runFns.shift()(); 5318 } 5319 5320 running = false; 5321 }; 5322 5323 var rafBatch = function(fn, queue){ 5324 if(running && !queue){ 5325 fn.apply(this, arguments); 5326 } else { 5327 fns.push(fn); 5328 5329 if(!waiting){ 5330 waiting = true; 5331 (document.hidden ? setTimeout : requestAnimationFrame)(run); 5332 } 5333 } 5334 }; 5335 5336 rafBatch._lsFlush = run; 5337 5338 return rafBatch; 5339 })(); 5340 5341 var rAFIt = function(fn, simple){ 5342 return simple ? 5343 function() { 5344 rAF(fn); 5345 } : 5346 function(){ 5347 var that = this; 5348 var args = arguments; 5349 rAF(function(){ 5350 fn.apply(that, args); 5351 }); 5352 } 5353 ; 5354 }; 5355 5356 var throttle = function(fn){ 5357 var running; 5358 var lastTime = 0; 5359 var gDelay = lazySizesCfg.throttleDelay; 5360 var rICTimeout = lazySizesCfg.ricTimeout; 5361 var run = function(){ 5362 running = false; 5363 lastTime = Date.now(); 5364 fn(); 5365 }; 5366 var idleCallback = requestIdleCallback && rICTimeout > 49 ? 5367 function(){ 5368 requestIdleCallback(run, {timeout: rICTimeout}); 5369 5370 if(rICTimeout !== lazySizesCfg.ricTimeout){ 5371 rICTimeout = lazySizesCfg.ricTimeout; 5372 } 5373 } : 5374 rAFIt(function(){ 5375 setTimeout(run); 5376 }, true) 5377 ; 5378 5379 return function(isPriority){ 5380 var delay; 5381 5382 if((isPriority = isPriority === true)){ 5383 rICTimeout = 33; 5384 } 5385 5386 if(running){ 5387 return; 5388 } 5389 5390 running = true; 5391 5392 delay = gDelay - (Date.now() - lastTime); 5393 5394 if(delay < 0){ 5395 delay = 0; 5396 } 5397 5398 if(isPriority || delay < 9){ 5399 idleCallback(); 5400 } else { 5401 setTimeout(idleCallback, delay); 5402 } 5403 }; 5404 }; 5405 5406 //based on http://modernjavascript.blogspot.de/2013/08/building-better-debounce.html 5407 var debounce = function(func) { 5408 var timeout, timestamp; 5409 var wait = 99; 5410 var run = function(){ 5411 timeout = null; 5412 func(); 5413 }; 5414 var later = function() { 5415 var last = Date.now() - timestamp; 5416 5417 if (last < wait) { 5418 setTimeout(later, wait - last); 5419 } else { 5420 (requestIdleCallback || run)(run); 5421 } 5422 }; 5423 5424 return function() { 5425 timestamp = Date.now(); 5426 5427 if (!timeout) { 5428 timeout = setTimeout(later, wait); 5429 } 5430 }; 5431 }; 5432 5433 var loader = (function(){ 5434 var preloadElems, isCompleted, resetPreloadingTimer, loadMode, started; 5435 5436 var eLvW, elvH, eLtop, eLleft, eLright, eLbottom, isBodyHidden; 5437 5438 var regImg = /^img$/i; 5439 var regIframe = /^iframe$/i; 5440 5441 var supportScroll = ('onscroll' in window) && !(/(gle|ing)bot/.test(navigator.userAgent)); 5442 5443 var shrinkExpand = 0; 5444 var currentExpand = 0; 5445 5446 var isLoading = 0; 5447 var lowRuns = -1; 5448 5449 var resetPreloading = function(e){ 5450 isLoading--; 5451 if(!e || isLoading < 0 || !e.target){ 5452 isLoading = 0; 5453 } 5454 }; 5455 5456 var isVisible = function (elem) { 5457 if (isBodyHidden == null) { 5458 isBodyHidden = getCSS(document.body, 'visibility') == 'hidden'; 5459 } 5460 5461 return isBodyHidden || !(getCSS(elem.parentNode, 'visibility') == 'hidden' && getCSS(elem, 'visibility') == 'hidden'); 5462 }; 5463 5464 var isNestedVisible = function(elem, elemExpand){ 5465 var outerRect; 5466 var parent = elem; 5467 var visible = isVisible(elem); 5468 5469 eLtop -= elemExpand; 5470 eLbottom += elemExpand; 5471 eLleft -= elemExpand; 5472 eLright += elemExpand; 5473 5474 while(visible && (parent = parent.offsetParent) && parent != document.body && parent != docElem){ 5475 visible = ((getCSS(parent, 'opacity') || 1) > 0); 5476 5477 if(visible && getCSS(parent, 'overflow') != 'visible'){ 5478 outerRect = parent.getBoundingClientRect(); 5479 visible = eLright > outerRect.left && 5480 eLleft < outerRect.right && 5481 eLbottom > outerRect.top - 1 && 5482 eLtop < outerRect.bottom + 1 5483 ; 5484 } 5485 } 5486 5487 return visible; 5488 }; 5489 5490 var checkElements = function() { 5491 var eLlen, i, rect, autoLoadElem, loadedSomething, elemExpand, elemNegativeExpand, elemExpandVal, 5492 beforeExpandVal, defaultExpand, preloadExpand, hFac; 5493 var lazyloadElems = lazysizes.elements; 5494 5495 if((loadMode = lazySizesCfg.loadMode) && isLoading < 8 && (eLlen = lazyloadElems.length)){ 5496 5497 i = 0; 5498 5499 lowRuns++; 5500 5501 for(; i < eLlen; i++){ 5502 5503 if(!lazyloadElems[i] || lazyloadElems[i]._lazyRace){continue;} 5504 5505 if(!supportScroll || (lazysizes.prematureUnveil && lazysizes.prematureUnveil(lazyloadElems[i]))){unveilElement(lazyloadElems[i]);continue;} 5506 5507 if(!(elemExpandVal = lazyloadElems[i][_getAttribute]('data-expand')) || !(elemExpand = elemExpandVal * 1)){ 5508 elemExpand = currentExpand; 5509 } 5510 5511 if (!defaultExpand) { 5512 defaultExpand = (!lazySizesCfg.expand || lazySizesCfg.expand < 1) ? 5513 docElem.clientHeight > 500 && docElem.clientWidth > 500 ? 500 : 370 : 5514 lazySizesCfg.expand; 5515 5516 lazysizes._defEx = defaultExpand; 5517 5518 preloadExpand = defaultExpand * lazySizesCfg.expFactor; 5519 hFac = lazySizesCfg.hFac; 5520 isBodyHidden = null; 5521 5522 if(currentExpand < preloadExpand && isLoading < 1 && lowRuns > 2 && loadMode > 2 && !document.hidden){ 5523 currentExpand = preloadExpand; 5524 lowRuns = 0; 5525 } else if(loadMode > 1 && lowRuns > 1 && isLoading < 6){ 5526 currentExpand = defaultExpand; 5527 } else { 5528 currentExpand = shrinkExpand; 5529 } 5530 } 5531 5532 if(beforeExpandVal !== elemExpand){ 5533 eLvW = innerWidth + (elemExpand * hFac); 5534 elvH = innerHeight + elemExpand; 5535 elemNegativeExpand = elemExpand * -1; 5536 beforeExpandVal = elemExpand; 5537 } 5538 5539 rect = lazyloadElems[i].getBoundingClientRect(); 5540 5541 if ((eLbottom = rect.bottom) >= elemNegativeExpand && 5542 (eLtop = rect.top) <= elvH && 5543 (eLright = rect.right) >= elemNegativeExpand * hFac && 5544 (eLleft = rect.left) <= eLvW && 5545 (eLbottom || eLright || eLleft || eLtop) && 5546 (lazySizesCfg.loadHidden || isVisible(lazyloadElems[i])) && 5547 ((isCompleted && isLoading < 3 && !elemExpandVal && (loadMode < 3 || lowRuns < 4)) || isNestedVisible(lazyloadElems[i], elemExpand))){ 5548 unveilElement(lazyloadElems[i]); 5549 loadedSomething = true; 5550 if(isLoading > 9){break;} 5551 } else if(!loadedSomething && isCompleted && !autoLoadElem && 5552 isLoading < 4 && lowRuns < 4 && loadMode > 2 && 5553 (preloadElems[0] || lazySizesCfg.preloadAfterLoad) && 5554 (preloadElems[0] || (!elemExpandVal && ((eLbottom || eLright || eLleft || eLtop) || lazyloadElems[i][_getAttribute](lazySizesCfg.sizesAttr) != 'auto')))){ 5555 autoLoadElem = preloadElems[0] || lazyloadElems[i]; 5556 } 5557 } 5558 5559 if(autoLoadElem && !loadedSomething){ 5560 unveilElement(autoLoadElem); 5561 } 5562 } 5563 }; 5564 5565 var throttledCheckElements = throttle(checkElements); 5566 5567 var switchLoadingClass = function(e){ 5568 var elem = e.target; 5569 5570 if (elem._lazyCache) { 5571 delete elem._lazyCache; 5572 return; 5573 } 5574 5575 resetPreloading(e); 5576 addClass(elem.parentElement, lazySizesCfg.loadedClass); 5577 removeClass(elem, lazySizesCfg.loadingClass); 5578 removeClass(elem, 'loading'); 5579 addRemoveLoadEvents(elem, rafSwitchLoadingClass); 5580 triggerEvent(elem, 'lazyloaded'); 5581 }; 5582 var rafedSwitchLoadingClass = rAFIt(switchLoadingClass); 5583 var rafSwitchLoadingClass = function(e){ 5584 rafedSwitchLoadingClass({target: e.target}); 5585 }; 5586 5587 var changeIframeSrc = function(elem, src){ 5588 var loadMode = elem.getAttribute('data-load-mode') || lazySizesCfg.iframeLoadMode; 5589 5590 // loadMode can be also a string! 5591 if (loadMode == 0) { 5592 elem.contentWindow.location.replace(src); 5593 } else if (loadMode == 1) { 5594 elem.src = src; 5595 } 5596 }; 5597 5598 var handleSources = function(source){ 5599 var customMedia; 5600 5601 var sourceSrcset = source[_getAttribute](lazySizesCfg.srcsetAttr); 5602 5603 if( (customMedia = lazySizesCfg.customMedia[source[_getAttribute]('data-media') || source[_getAttribute]('media')]) ){ 5604 source.setAttribute('media', customMedia); 5605 } 5606 5607 if(sourceSrcset){ 5608 source.setAttribute('srcset', sourceSrcset); 5609 } 5610 }; 5611 5612 var lazyUnveil = rAFIt(function (elem, detail, isAuto, sizes, isImg){ 5613 var src, srcset, parent, isPicture, event, firesLoad; 5614 5615 if(!(event = triggerEvent(elem, 'lazybeforeunveil', detail)).defaultPrevented){ 5616 5617 if(sizes){ 5618 if(isAuto){ 5619 addClass(elem, lazySizesCfg.autosizesClass); 5620 } else { 5621 elem.setAttribute('sizes', sizes); 5622 } 5623 } 5624 5625 srcset = elem[_getAttribute](lazySizesCfg.srcsetAttr); 5626 src = elem[_getAttribute](lazySizesCfg.srcAttr); 5627 5628 if(isImg) { 5629 parent = elem.parentNode; 5630 isPicture = parent && regPicture.test(parent.nodeName || ''); 5631 } 5632 5633 firesLoad = detail.firesLoad || (('src' in elem) && (srcset || src || isPicture)); 5634 5635 event = {target: elem}; 5636 5637 addClass(elem, lazySizesCfg.loadingClass); 5638 5639 if(firesLoad){ 5640 clearTimeout(resetPreloadingTimer); 5641 resetPreloadingTimer = setTimeout(resetPreloading, 2500); 5642 addRemoveLoadEvents(elem, rafSwitchLoadingClass, true); 5643 } 5644 5645 if(isPicture){ 5646 forEach.call(parent.getElementsByTagName('source'), handleSources); 5647 } 5648 5649 if(srcset){ 5650 elem.setAttribute('srcset', srcset); 5651 } else if(src && !isPicture){ 5652 if(regIframe.test(elem.nodeName)){ 5653 changeIframeSrc(elem, src); 5654 } else { 5655 elem.src = src; 5656 } 5657 } 5658 5659 if(isImg && (srcset || isPicture)){ 5660 updatePolyfill(elem, {src: src}); 5661 } 5662 } 5663 5664 if(elem._lazyRace){ 5665 delete elem._lazyRace; 5666 } 5667 removeClass(elem, lazySizesCfg.lazyClass); 5668 5669 rAF(function(){ 5670 // Part of this can be removed as soon as this fix is older: https://bugs.chromium.org/p/chromium/issues/detail?id=7731 (2015) 5671 var isLoaded = elem.complete && elem.naturalWidth > 1; 5672 5673 if( !firesLoad || isLoaded){ 5674 if (isLoaded) { 5675 addClass(elem, lazySizesCfg.fastLoadedClass); 5676 } 5677 switchLoadingClass(event); 5678 elem._lazyCache = true; 5679 setTimeout(function(){ 5680 if ('_lazyCache' in elem) { 5681 delete elem._lazyCache; 5682 } 5683 }, 9); 5684 } 5685 if (elem.loading == 'lazy') { 5686 isLoading--; 5687 } 5688 }, true); 5689 }); 5690 5691 /** 5692 * 5693 * @param elem { Element } 5694 */ 5695 var unveilElement = function (elem){ 5696 if (elem._lazyRace) {return;} 5697 var detail; 5698 5699 var isImg = regImg.test(elem.nodeName); 5700 5701 //allow using sizes="auto", but don't use. it's invalid. Use data-sizes="auto" or a valid value for sizes instead (i.e.: sizes="80vw") 5702 var sizes = isImg && (elem[_getAttribute](lazySizesCfg.sizesAttr) || elem[_getAttribute]('sizes')); 5703 var isAuto = sizes == 'auto'; 5704 5705 if( (isAuto || !isCompleted) && isImg && (elem[_getAttribute]('src') || elem.srcset) && !elem.complete && !hasClass(elem, lazySizesCfg.errorClass) && hasClass(elem, lazySizesCfg.lazyClass)){return;} 5706 5707 detail = triggerEvent(elem, 'lazyunveilread').detail; 5708 5709 if(isAuto){ 5710 autoSizer.updateElem(elem, true, elem.offsetWidth); 5711 } 5712 5713 elem._lazyRace = true; 5714 isLoading++; 5715 5716 lazyUnveil(elem, detail, isAuto, sizes, isImg); 5717 }; 5718 5719 var afterScroll = debounce(function(){ 5720 lazySizesCfg.loadMode = 3; 5721 throttledCheckElements(); 5722 }); 5723 5724 var altLoadmodeScrollListner = function(){ 5725 if(lazySizesCfg.loadMode == 3){ 5726 lazySizesCfg.loadMode = 2; 5727 } 5728 afterScroll(); 5729 }; 5730 5731 var onload = function(){ 5732 if(isCompleted){return;} 5733 if(Date.now() - started < 999){ 5734 setTimeout(onload, 999); 5735 return; 5736 } 5737 5738 5739 isCompleted = true; 5740 5741 lazySizesCfg.loadMode = 3; 5742 5743 throttledCheckElements(); 5744 5745 addEventListener('scroll', altLoadmodeScrollListner, true); 5746 }; 5747 5748 return { 5749 _: function(){ 5750 started = Date.now(); 5751 5752 lazysizes.elements = document.getElementsByClassName(lazySizesCfg.lazyClass); 5753 preloadElems = document.getElementsByClassName(lazySizesCfg.lazyClass + ' ' + lazySizesCfg.preloadClass); 5754 5755 addEventListener('scroll', throttledCheckElements, true); 5756 5757 addEventListener('resize', throttledCheckElements, true); 5758 5759 addEventListener('pageshow', function (e) { 5760 if (e.persisted) { 5761 var loadingElements = document.querySelectorAll('.' + lazySizesCfg.loadingClass); 5762 5763 if (loadingElements.length && loadingElements.forEach) { 5764 requestAnimationFrame(function () { 5765 loadingElements.forEach( function (img) { 5766 if (img.complete) { 5767 unveilElement(img); 5768 } 5769 }); 5770 }); 5771 } 5772 } 5773 }); 5774 5775 if(window.MutationObserver){ 5776 new MutationObserver( throttledCheckElements ).observe( docElem, {childList: true, subtree: true, attributes: true} ); 5777 } else { 5778 docElem[_addEventListener]('DOMNodeInserted', throttledCheckElements, true); 5779 docElem[_addEventListener]('DOMAttrModified', throttledCheckElements, true); 5780 setInterval(throttledCheckElements, 999); 5781 } 5782 5783 addEventListener('hashchange', throttledCheckElements, true); 5784 5785 //, 'fullscreenchange' 5786 ['focus', 'mouseover', 'click', 'load', 'transitionend', 'animationend'].forEach(function(name){ 5787 document[_addEventListener](name, throttledCheckElements, true); 5788 }); 5789 5790 if((/d$|^c/.test(document.readyState))){ 5791 onload(); 5792 } else { 5793 addEventListener('load', onload); 5794 document[_addEventListener]('DOMContentLoaded', throttledCheckElements); 5795 setTimeout(onload, 20000); 5796 } 5797 5798 if(lazysizes.elements.length){ 5799 checkElements(); 5800 rAF._lsFlush(); 5801 } else { 5802 throttledCheckElements(); 5803 } 5804 }, 5805 checkElems: throttledCheckElements, 5806 unveil: unveilElement, 5807 _aLSL: altLoadmodeScrollListner, 5808 }; 5809 })(); 5810 5811 5812 var autoSizer = (function(){ 5813 var autosizesElems; 5814 5815 var sizeElement = rAFIt(function(elem, parent, event, width){ 5816 var sources, i, len; 5817 elem._lazysizesWidth = width; 5818 width += 'px'; 5819 5820 elem.setAttribute('sizes', width); 5821 5822 if(regPicture.test(parent.nodeName || '')){ 5823 sources = parent.getElementsByTagName('source'); 5824 for(i = 0, len = sources.length; i < len; i++){ 5825 sources[i].setAttribute('sizes', width); 5826 } 5827 } 5828 5829 if(!event.detail.dataAttr){ 5830 updatePolyfill(elem, event.detail); 5831 } 5832 }); 5833 /** 5834 * 5835 * @param elem {Element} 5836 * @param dataAttr 5837 * @param [width] { number } 5838 */ 5839 var getSizeElement = function (elem, dataAttr, width){ 5840 var event; 5841 var parent = elem.parentNode; 5842 5843 if(parent){ 5844 width = getWidth(elem, parent, width); 5845 event = triggerEvent(elem, 'lazybeforesizes', {width: width, dataAttr: !!dataAttr}); 5846 5847 if(!event.defaultPrevented){ 5848 width = event.detail.width; 5849 5850 if(width && width !== elem._lazysizesWidth){ 5851 sizeElement(elem, parent, event, width); 5852 } 5853 } 5854 } 5855 }; 5856 5857 var updateElementsSizes = function(){ 5858 var i; 5859 var len = autosizesElems.length; 5860 if(len){ 5861 i = 0; 5862 5863 for(; i < len; i++){ 5864 getSizeElement(autosizesElems[i]); 5865 } 5866 } 5867 }; 5868 5869 var debouncedUpdateElementsSizes = debounce(updateElementsSizes); 5870 5871 return { 5872 _: function(){ 5873 autosizesElems = document.getElementsByClassName(lazySizesCfg.autosizesClass); 5874 addEventListener('resize', debouncedUpdateElementsSizes); 5875 }, 5876 checkElems: debouncedUpdateElementsSizes, 5877 updateElem: getSizeElement 5878 }; 5879 })(); 5880 5881 var init = function(){ 5882 if(!init.i && document.getElementsByClassName){ 5883 init.i = true; 5884 autoSizer._(); 5885 loader._(); 5886 } 5887 }; 5888 5889 setTimeout(function(){ 5890 if(lazySizesCfg.init){ 5891 init(); 5892 } 5893 }); 5894 5895 lazysizes = { 5896 /** 5897 * @type { LazySizesConfigPartial } 5898 */ 5899 cfg: lazySizesCfg, 5900 autoSizer: autoSizer, 5901 loader: loader, 5902 init: init, 5903 uP: updatePolyfill, 5904 aC: addClass, 5905 rC: removeClass, 5906 hC: hasClass, 5907 fire: triggerEvent, 5908 gW: getWidth, 5909 rAF: rAF, 5910 }; 5911 5912 return lazysizes; 5913 } 5914)); 5915/* End */ 5916; 5917; /* Start:"a:4:{s:4:"full";
5917s:54:"/local/templates/bitrix66/js/script.js?179130916510894";s:6:"source";s:38:"/local/templates/bitrix66/js/script.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/ 5918window.isFrameDataReceived = false; 5919 5920var swiperСontainer = {}; 5921 5922/*if(BX.SidePanel.Instance) { 5923 $(document).on('click', 'body.side-panel-disable-scrollbar .main-links .menu-toggler.active, html.side-panel-open body:not(.new-filter) .modal-mask', function () { 5924 $('html').removeClass('side-panel-check'); 5925 $('html').removeClass('side-panel-open'); 5926 BX.SidePanel.Instance.closeAll([immediately = false], function () {}); 5927 BX.SidePanel.Instance.getOpenSliders().forEach(function(side, i, arr) { 5928 if (!i) { 5929 5930 } 5931 side.close(); 5932 }); 5933 }); 5934 BX.SidePanel.Instance.bindAnchors({ 5935 rules: [ 5936 { 5937 condition: ["/pannier/", "/delay/", "/account/","/basket/","/find/","/looks/"], 5938 handler: function (event, link) { 5939 event.preventDefault(); 5940 BX.SidePanel.Instance.closeAll([immediately = false], function () {}); 5941 openSide(link.url); 5942 }, 5943 mobileFriendly : true, 5944 }, 5945 ] 5946 }); 5947}*/ 5948 5949/*function openSide(url) { 5950 /!*if(BX.SidePanel.Instance.getOpenSliders().length == 1) { 5951 $('html').addClass('side-panel-check'); 5952 }*!/ 5953 //$('body').removeClass('menu-mobile menu-mobile-fix mobile-filter noscroll'); 5954 BX.SidePanel.Instance.open(url, 5955 { 5956 animationDuration: 200, 5957 autoFocus: true, 5958 mobileFriendly: true, 5959 cacheable: false, 5960 allowChangeHistory: false, 5961 allowChangeTitle: true, 5962 label: { 5963 color: "#000000", 5964 bgColor: "#FFFFFF", 5965 opacity: 0 5966 }, 5967 width: 768, 5968 events: { 5969 onBeforeOpenComplete: function (event) { 5970 $('.modal-mask').addClass('active'); 5971 }, 5972 onOpenComplete: function (event) { 5973 5974 }, 5975 onLoad: function (event) { 5976 $('body').addClass('side-panel-open'); 5977 }, 5978 onBeforeCloseComplete: function (event) { 5979 $('body').removeClass('side-panel-open'); 5980 $('.modal-mask').removeClass('active'); 5981 }, 5982 onCloseComplete: function (event) { 5983 if (!BX.SidePanel.Instance.isOpen()) { 5984 5985 }else{ 5986 //BX.SidePanel.Instance.reload(); 5987 } 5988 }, 5989 onClose: function (event) { 5990 //window.basketCount(); 5991 }, 5992 }, 5993 } 5994 ); 5995}*/ 5996 5997 5998window.basketCount = function () { 5999 BX.ajax({ 6000 method: 'POST', 6001 url: '/local/ajax/basket.count.php', 6002 onsuccess: function (result) { 6003 var arResult = JSON.parse(result); 6004 for (var key in arResult) { 6005 if (BX(key)) { 6006 BX(key).innerHTML = arResult[key]; 6007 } 6008 } 6009 } 6010 }); 6011} 6012window.basketCount(); 6013 6014window.addEventListener("pageshow", function () { 6015 window.basketCount(); 6016}); 6017 6018/*function loadingShow() { 6019 $('#bx-loading').addClass('active'); 6020 window.parent.$('#bx-loading').addClass('active'); 6021} 6022function loadingHide() { 6023 $('#bx-loading').removeClass('active'); 6024 window.parent.$('#bx-loading').removeClass('active'); 6025} 6026if (window === window.top) { 6027 loadingHide(); 6028} 6029window.addEventListener("pageshow", function () { 6030 window.basketCount(); 6031 loadingHide(); 6032}); 6033$(window).on('beforeunload', function(e) { 6034 loadingShow(); 6035});*/ 6036/*BX.addCustomEvent('onAjaxSuccess', function() { 6037 loadingShow(); 6038});*/ 6039 6040 6041/*navigation.addEventListener('navigate', (e) => { 6042 e.preventDefault(); 6043 e.returnValue = 'ÐÑ ÑвеÑенÑ?'; 6044 console.log(e); 6045 console.log(e.destination.url); 6046});*/ 6047 6048if (!BX.message('USER_ID') && BX.getCookie('BITRIX_SM_PRIVACY_POLICY') != 'Y' && BX.getCookie('APP') != 'Y') { 6049 popupCookie = new BX.PopupWindow('cookie-assent', window.body, { 6050 content: 'ÐÑ Ð¸ÑполÑзÑем ÑÐ°Ð¹Ð»Ñ cookie Ð´Ð»Ñ ÑлÑÑÑÐµÐ½Ð¸Ñ ÑабоÑÑ ÑайÑа, пеÑÑонализаÑии и аналиÑики.<br /> ÐÑÑаваÑÑÑ Ð½Ð° ÑайÑе, Ð²Ñ ÑоглаÑаеÑеÑÑ Ñ <a href="/about/privacy-policy/" target="_blank">ÐолиÑикой конÑиденÑиалÑноÑÑи</a>.', 6051 autoHide: true, 6052 offsetTop: 0, 6053 offsetBottom: 1, 6054 offsetLeft: 0, 6055 offsetRight: 0, 6056 lightShadow: false, 6057 closeIcon: false, 6058 closeByEsc: true, 6059 buttons: [ 6060 new BX.PopupWindowButton({ 6061 text: "ÐÑинÑÑÑ", 6062 className: "btn btn-default btn-lg", 6063 events: { 6064 click: function(){ 6065 BX.setCookie('BITRIX_SM_PRIVACY_POLICY', 'Y', {expires: 30000000, path: '/'}); 6066 this.popupWindow.close(); 6067 } 6068 } 6069 }) 6070 ], 6071 overlay: { 6072 backgroundColor: 'black', opacity: '90' 6073 }, 6074 events: { 6075 onPopupShow: function() { 6076 6077 }, 6078 onPopupClose : function(){ 6079 6080 } 6081 } 6082 }); 6083 popupCookie.show(); 6084} 6085function normalizeQuery(query) { 6086 return String(query || '').replace(/\s+/g, ' ').trim(); 6087}
6088function add2basket(productId, delay = 'N', mode = 'ADD') { 6089 BX.ajax({ 6090 method: 'POST', 6091 url: '/local/ajax/add2basket.php', 6092 async: true, 6093 data: { 6094 PRODUCT_ID: productId, 6095 DELAY: delay, 6096 MODE: mode, 6097 }, 6098 onsuccess: function (result) { 6099 BX('bx_delay').innerHTML = '<div class="cart-count">'+result.delay+'</div>'; 6100 BX('bx_basket').innerHTML = '<div class="cart-count">'+result.basket+'</div>'; 6101 } 6102 }); 6103} 6104function reloadProduct() { 6105 var a = $('.wrapper > section > .container > div[id^="comp_"]'); 6106 if (a.length) { 6107 //$('.bx-composite-loading').show(); 6108 var s = window.parent.$('.wrapper > section > .container > div[id^="comp_"]').attr('id'); 6109 var bxAjaxContainer = s.split('_').pop(); 6110 var URL = location.pathname+'?bxajaxid='+bxAjaxContainer; 6111 BX.ajax({ 6112 url: BX.util.htmlspecialcharsback(URL), 6113 method: 'GET', 6114 dataType: 'html', 6115 timeout: 0, 6116 processData: true, 6117 emulateOnload: false, 6118 start: true, 6119 cache: true, 6120 scriptsRunFirst: false, 6121 onsuccess: function (data) { 6122 //$('.bx-composite-loading').hide(); 6123 //$('#bx_delay .cart-count, #bx_delay_mobile .cart-count').remove(); 6124 window.parent.$('#comp_'+bxAjaxContainer).html(data); 6125 }, 6126 onfailure: function () { 6127 //$('.bx-composite-loading').hide(); 6128 } 6129 }); 6130 } 6131} 6132function hideSort() { 6133 let merch = BX.getCookie('BITRIX_SM_MERCH'); 6134 if(merch == 'Y') { 6135 $('.sortB, .styleB').hide(); 6136 BX.setCookie('BITRIX_SM_MERCH', 'N', {expires: 100000000, path: '/'}); 6137 //document.cookie = "BITRIX_SM_MERCH=N; max-age=100000000; path=/;"; 6138 }else { 6139 $('.sortB, .styleB').show(); 6140 BX.setCookie('BITRIX_SM_MERCH', 'Y', {expires: 100000000, path: '/'}); 6141 //document.cookie = "BITRIX_SM_MERCH=Y; max-age=100000000; path=/;"; 6142 } 6143} 6144 6145BX.ready(function() { 6146 if (BX.getCookie('YMAM')) { 6147 var parameters = JSON.parse(BX.getCookie('YMAM')); 6148 ym("182246", 'firstPartyParams', parameters); 6149 } 6150}); 6151 6152if (typeof BX !== 'undefined') { 6153 BX.addCustomEvent('onFrameDataReceived', function () { 6154 window.isFrameDataReceived = true; 6155 }); 6156} 6157 6158 6159 6160var startLoader = true; 6161$(document).on('keyup', function(e){ 6162 startLoader = true; 6163}); 6164$(document).on('keydown', function(e){ 6165 if (event.keyCode === 120) { 6166 hideSort(); 6167 } 6168 if (event.keyCode === 17) { 6169 startLoader = false;
6170 } 6171}); 6172 6173document.addEventListener("DOMContentLoaded", function() { 6174 var lazyVideos = [].slice.call(document.querySelectorAll("video.lazy")); 6175 6176 if ("IntersectionObserver" in window) { 6177 var lazyVideoObserver = new IntersectionObserver(function(entries, observer) { 6178 entries.forEach(function(video) { 6179 if (video.isIntersecting) { 6180 for (var source in video.target.children) { 6181 var videoSource = video.target.children[source]; 6182 if (typeof videoSource.tagName === "string" && videoSource.tagName === "SOURCE") { 6183 videoSource.src = videoSource.dataset.src; 6184 } 6185 } 6186 6187 video.target.load(); 6188 video.target.classList.remove("lazy"); 6189 video.target.parentElement.classList.add("lazyloaded"); 6190 lazyVideoObserver.unobserve(video.target); 6191 } 6192 }); 6193 }); 6194 6195 lazyVideos.forEach(function(lazyVideo) { 6196 lazyVideoObserver.observe(lazyVideo); 6197 }); 6198 } 6199}); 6200 6201$(document).on('blur', '#title-search-input', function() { 6202 setTimeout(function () { 6203 if(!$('#title-search-input').is(":focus")) { 6204 $('#title-search').removeClass('active'); 6205 } 6206 }, 300); 6207}); 6208$(document).on('click', '#title-search .search-close', function(){ 6209 $('#title-search-input').focus(); 6210 if($('#title-search-input').val()) { 6211 $('#title-search-input').val(''); 6212 }else{ 6213 $('#title-search').removeClass('active'); 6214 } 6215}); 6216$(document).on('click', '#title-search .search-go', function(){ 6217 $('#title-search-input').focus(); 6218 if($('#title-search-input').val()) { 6219 $('#title-search-form').submit(); 6220 } 6221}); 6222 6223$(document).on('click', '#top', function () { 6224 $("html, body").animate({scrollTop: "0px"},{duration: 500,easing: "swing"}); 6225}); 6226$(document).on('click', '.menu-gender > *', function () { 6227 if($(this).hasClass('women')) { 6228 $(this).parent().removeClass('right'); 6229 }else if($(this).hasClass('men')) { 6230 $(this).parent().addClass('right'); 6231 }else{ 6232 $(this).parent().toggleClass('right'); 6233 } 6234}); 6235 6236/*$(document).on('click', '.cart-close, .modal-close, .filter-apply-btn, .go-to-shopping, .close-icon, .modal-mask, .filter-close', function () { 6237 $('.modal-container, .cart-container, .modal, .catalog-filters-mobile-container, .menu-toggler, .modal-mask, #search-modal').removeClass('active'); 6238 $('body').removeClass('mobile-filter menu-mobile noscroll menu-mobile-fix menu-cart'); 6239});*/ 6240 6241 6242 6243$(document).on('change', '.styleB input.inputStyle', function(){ 6244 var styles = []; 6245 $(this).closest('.styleB').find('input:checked').each(function(i, e){ 6246 styles.push(e.value) 6247 }); 6248 BX.ajax({ 6249 url: '/local/ajax/setStyleAdm.php', 6250 method: 'POST', 6251 data: { 6252 id: $(this).closest('.styleB').data('id'), 6253 styles: styles, 6254 }, 6255 onsuccess: function(result) {} 6256 }); 6257}); 6258$(document).on('keyup', '.formsort input[class^="sort_page"]', function(){ 6259 BX.ajax({ 6260 url: '/local/ajax/setSortPage.php', 6261 method: 'POST', 6262 data: { 6263 id: $(this).closest('.formsort').find('.sort_id').val(), 6264 page: $(this).closest('.formsort').find('.sort_page_id').val(), 6265 sort: $(this).closest('.formsort').find('.sort_page').val(), 6266 }, 6267 onsuccess: function(result) {} 6268 }); 6269}); 6270$(document).on('keyup', '.formsort input[class^="sort_group"]', function(){ 6271 BX.ajax({ 6272 url: '/local/ajax/setSortAdm.php', 6273 method: 'POST', 6274 data: { 6275 id: $(this).closest('.formsort').find('.sort_id').val(), 6276 group: $(this).closest('.formsort').find('.sort_group').val(), 6277 group2: $(this).closest('.formsort').find('.sort_group2').val(), 6278 group3: $(this).closest('.formsort').find('.sort_group3').val(), 6279 group4: $(this).closest('.formsort').find('.sort_group4').val(), 6280 group5: $(this).closest('.formsort').find('.sort_group5').val(), 6281 }, 6282 onsuccess: function(result) {} 6283 }); 6284}); 6285$(document).on('click', '.catalog-filters:not(.catalog-filters-all) .submenu .b-checkbox__label, .filter-reset-btn', function() { 6286 $('.bx-composite-loading').show(); 6287 $('.catalog-filters > .catalog-filter .b-checkbox__label').removeClass('active'); 6288 $(this).addClass('active'); 6289 $("html, body").animate({scrollTop: "0px"},{duration: 500,easing: "swing"}); 6290}); 6291/*$(document).on('click', '#bx-panel-expander', function(e){ 6292 e.preventDefault(); 6293});*/ 6294/* 6295$(document).on('click', '.catalog-filters-mobile', function(){
6296 $('.catalog-filters, .modal-mask').addClass('active'); 6297 let body = $('body'); 6298 body.addClass('mobile-filter noscroll'); 6299});*/ 6300 6301/* End */ 6302; 6303; /* Start:"a:4:{s:4:"full";s:52:"/local/templates/bitrix66/js/events.js?1791309165290";s:6:"source";s:38:"/local/templates/bitrix66/js/events.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/ 6304BX.bind(BX('mask'), 'click', function() { 6305 document.body.removeAttribute('class'); 6306}); 6307BX.bindDelegate(document.body, 'click', {className: 'close'}, function() { 6308 document.body.removeAttribute('class'); 6309}); 6310 6311window.addEventListener('storage', function(e) { 6312 console.log(e.key); 6313}); 6314/* End */ 6315; 6316; /* Start:"a:4:{s:4:"full";s:76:"/local/components/bitrix66/header/templates/bitrix66/script.js?1791358811984";s:6:"source";s:62:"/local/components/bitrix66/header/templates/bitrix66/script.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/ 6317BX.bind(BX('back'), 'click', function () { 6318 if (BX.hasClass(document.body, 'menu-app')) { 6319 let level_1 = BX('menu-app').querySelector('nav > .item > .submenu > .item.active'); 6320 if (level_1) { 6321 BX.removeClass(level_1, 'active'); 6322 BX.removeClass(document.body, 'menu-app-sub'); 6323 }else if (!level_1) { 6324 let level_0 = BX('menu-app').querySelector('nav > .item.active'); 6325 if (level_0) { 6326 BX.removeClass(level_0, 'active'); 6327 BX.removeClass(document.body, 'menu-app'); 6328 } 6329 } 6330 }else{ 6331 history.back(); 6332 } 6333}); 6334BX.bind(BX('bx_search'), 'click', function () { 6335 BX.addClass(document.body, 'mask search-open'); 6336}); 6337BX.bind(BX('scrollable'), 'scroll', function () { 6338 if (document.getElementById('scrollable').scrollTop > 50) { 6339 BX.addClass(document.documentElement, 'header'); 6340 }else{ 6341 BX.removeClass(document.documentElement, 'header'); 6342 } 6343}); 6344/* End */ 6345; 6346; /* Start:"a:4:{s:4:"full";s:64:"/local/templates/bitrix66/plug/sidebar/sidebar.js?17913091651207";s:6:"source";s:49:"/local/templates/bitrix66/plug/sidebar/sidebar.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/ 6347BX.sidebarAjax = { 6348 init: function () 6349 { 6350 BX.bindDelegate(document, 'click', {attrs: 'sidebar'}, BX.proxy(this.click, this)); 6351 }, 6352 close: function () 6353 { 6354 document.body.removeAttribute('class'); 6355 }, 6356 create: function (src) 6357 { 6358 this.sidebar = BX.create('div', { 6359 attrs: { 6360 id: 'sidebar' 6361 }, 6362 }); 6363 this.iframe = BX.create('iframe', { 6364 attrs: { 6365 src: src 6366 }, 6367 events: { 6368 load: BX.delegate(this.load, this) 6369 } 6370 }); 6371 this.sidebar.prepend(this.iframe); 6372 document.body.append(this.sidebar); 6373 BX.addClass(document.body, 'mask'); 6374 }, 6375 load: function () 6376 { 6377 let target = BX.proxy_context; 6378 let iframe = target.contentWindow; 6379 //BX.removeClass(this.sidebar, 'loader'); 6380 BX.addClass(document.body, 'sidebar'); 6381 6382 BX.bind(iframe.document.querySelector('#close'), 'click', BX.proxy(this.close, this)); 6383 }, 6384 click: function (e) 6385 { 6386 let self = e.target; 6387 let src = self.getAttribute('sidebar'); 6388 if (src) this.create(src); 6389 } 6390} 6391BX.sidebarAjax.init(); 6392/* End */ 6393; 6394; /* Start:"a:4:{s:4:"full";s:78:"/local/components/bitrix66/menu.top/templates/bitrix66/script.js?1791349815753";s:6:"source";s:64:"/local/components/bitrix66/menu.top/templates/bitrix66/script.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/ 6395BX.bindDelegate(BX('menu-top'), 'click', {tag: 'a'}, function(e) { 6396 document.body.removeAttribute('class'); 6397}); 6398BX.bindDelegate(BX('menu-top'), 'click', {className: 'down-menu'}, function(e) { 6399 e.preventDefault(); 6400 let self = e.target; 6401 let parent = BX.findParent(self); 6402 let active = (BX.hasClass(document.body, 'menu-desktop') && BX.hasClass(parent, 'active')); 6403 let items = BX('menu-top').querySelectorAll('nav > .item'); 6404 items.forEach(function (item) { 6405 BX.removeClass(item, 'active'); 6406 }); 6407 if (active) { 6408 document.body.removeAttribute('class'); 6409 BX.removeClass(parent, 'active'); 6410 } else { 6411 BX.addClass(document.body, 'mask menu-desktop'); 6412 BX.addClass(parent, 'active'); 6413 } 6414}); 6415/* End */ 6416; 6417; /* Start:"a:4:{s:4:"full";s:79:"/local/components/bitrix66/menu.app/templates/bitrix66/script.
6417js?17914365624404";s:6:"source";s:64:"/local/components/bitrix66/menu.app/templates/bitrix66/script.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/ 6418(function() { 6419 'use strict'; 6420 6421 if (!!window.JCMenuAppComponent) 6422 return; 6423 6424 window.JCMenuAppComponent = function () { //BroadcastChannel обмен даннÑми Ð¼ÐµÐ¶Ð´Ñ Ð²ÐºÐ»Ð°Ð´ÐºÐ°Ð¼Ð¸ 6425 if (this._initialized) return; 6426 this._initialized = true; 6427 6428 this.tab = sessionStorage.getItem('app-menu') || 'mobile-nav-home'; 6429 sessionStorage.setItem('app-menu', this.tab); 6430 6431 /*if (!window.name) window.name = 'mobile-nav-home' 6432 this.tab = window.name; 6433 this.href = window.location.origin + (!window.location.search && window.location.pathname == '/' ? '' : window.location.pathname) + window.location.search; 6434 sessionStorage.setItem(this.tab, this.href);*/ 6435 6436 /*window.addEventListener('beforeunload', () => { 6437 sessionStorage.removeItem(this.tab); 6438 });*/ 6439 6440 this.urlStart = 'url-start'; 6441 this.href = window.location.origin + (!window.location.search && window.location.pathname == '/' ? '' : window.location.pathname) + window.location.search; 6442 if (!sessionStorage.getItem(this.urlStart)) { 6443 sessionStorage.setItem(this.urlStart, this.href); 6444 } 6445 6446 BX.bindDelegate(BX('mobile-nav'), 'click', {tagName: 'a'}, BX.proxy(this.click, this)); 6447 6448 //this.href = window.location.origin + window.location.pathname; 6449 6450 if (this.href != sessionStorage.getItem(this.urlStart)) { 6451 BX.addClass(BX('back'), 'active'); 6452 } 6453 BX.addClass(BX(this.tab), 'active'); 6454 6455 //this.menu(); 6456 } 6457 window.JCMenuAppComponent.prototype = 6458 { 6459 menu: function () 6460 { 6461 BX.ajax.runAction('bitrix66:app.Menu.tabs', { 6462 data: {} 6463 }).then(BX.delegate(function (response) { 6464 const self = this 6465 response.data.forEach(function (menu) { 6466 let item = BX.create('a', { 6467 attrs: { 6468 id: 'mobile-nav-'+menu.key, 6469 className: 'mobile-bottom-nav__item', 6470 href: menu.initialUrl 6471 }, 6472 dataset: { 6473 6474 }, 6475 events: { 6476 click: BX.delegate(self.click, this) 6477 }, 6478 children: [ 6479 BX.create('img', { 6480 attrs: { 6481 src: menu.icon.url, 6482 } 6483 }), 6484 BX.create('span', { 6485 attrs: { 6486 className: 'mobile-bottom-nav__label' 6487 }, 6488 html: menu.title 6489 }) 6490 ] 6491 }); 6492 BX('mobile-nav').append(item); 6493 /*if (self.tab == 'mobile-nav-'+menu.key && self.href != menu.initialUrl) { 6494 BX.addClass(BX('back'), 'active'); 6495 }*/ 6496 }); 6497 if (BX(this.tab).href != window.location.href) { 6498 BX.addClass(BX('back'), 'active'); 6499 } 6500 BX.addClass(BX(this.tab), 'active'); 6501 BX.removeClass(BX('mobile-nav'), 'load'); 6502 }, this), function (response) { 6503 console.log(response); 6504 }); 6505 }, 6506 click: function (e) 6507 { 6508 e.preventDefault(); 6509 6510 let self = e.target; 6511 6512 let id = self.getAttribute('id'); 6513 6514 //let href = (BX.hasClass(this, 'active') || !sessionStorage.getItem(id) ? this.dataset.href : sessionStorage.getItem(id)); 6515 6516 sessionStorage.setItem('app-menu', id); 6517 sessionStorage.setItem(this.urlStart, self.href); 6518 6519 window.location.href = self.href; 6520 //window.open(href+(window.name == id ? '' : '#'), id); 6521 }, 6522 } 6523})(); 6524/* End */ 6525; 6526; /* Start:"a:4:{s:4:"full";s:79:"/local/components/bitrix66/preloader/templates/bitrix66/script.
6526js?1791309165360";s:6:"source";s:65:"/local/components/bitrix66/preloader/templates/bitrix66/script.js";s:3:"min";s:0:"";s:3:"map";s:0:"";}"*/ 6527var beforeunload = true; 6528window.addEventListener("pageshow", function () { 6529 BX.removeClass(BX('bx-loading'), 'active'); 6530}); 6531window.addEventListener("beforeunload", function () { 6532 document.body.removeAttribute('class'); 6533 if (beforeunload === true) { 6534 BX.addClass(BX('bx-loading'), 'active'); 6535 } 6536}); 6537BX.removeClass(BX('bx-loading'), 'active'); 6538/* End */ 6539;; /* /local/modules/bitrix66.reg/js/script.js?179134981524436*/ 6540; /* /local/templates/bitrix66/plug/swiper/swiper.js?1789634012148932*/ 6541; /* /local/templates/bitrix66/plug/glightbox/glightbox.js?178963401277261*/ 6542; /* /local/templates/bitrix66/js/slick.js?178963401281472*/ 6543; /* /local/templates/bitrix66/js/lazysizes.js?178963401228678*/ 6544; /* /local/templates/bitrix66/js/script.js?179130916510894*/ 6545; /* /local/templates/bitrix66/js/events.js?1791309165290*/ 6546; /* /local/components/bitrix66/header/templates/bitrix66/script.js?1791358811984*/ 6547; /* /local/templates/bitrix66/plug/sidebar/sidebar.js?17913091651207*/ 6548; /* /local/components/bitrix66/menu.top/templates/bitrix66/script.js?1791349815753*/ 6549; /* /local/components/bitrix66/menu.app/templates/bitrix66/script.js?17914365624404*/ 6550; /* /local/components/bitrix66/preloader/templates/bitrix66/script.js?1791309165360*/
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.