vendor: 16,334 bytes, lines 1-622
1/** 2 * Swiper 8.4.2 3 * Most modern mobile touch slider and framework with hardware accelerated transitions 4 * https://swiperjs.com 5 * 6 * Copyright 2014-2022 Vladimir Kharlampidi 7 * 8 * Released under the MIT License 9 * 10 * Released on: September 15, 2022 11 */ 12 13!(function (e, t) { 14 "object" == typeof exports && "undefined" != typeof module 15 ? (module.exports = t()) 16 : "function" == typeof define && define.amd 17 ? define(t) 18 : ((e = "undefined" != typeof globalThis ? globalThis : e || self).Swiper = 19 t()); 20})(this, function () { 21 "use strict"; 22 function e(e) { 23 return ( 24 null !== e && 25 "object" == typeof e && 26 "constructor" in e && 27 e.constructor === Object 28 ); 29 } 30 function t(s, a) { 31 void 0 === s && (s = {}), 32 void 0 === a && (a = {}), 33 Object.keys(a).forEach((i) => { 34 void 0 === s[i] 35 ? (s[i] = a[i]) 36 : e(a[i]) && e(s[i]) && Object.keys(a[i]).length > 0 && t(s[i], a[i]); 37 }); 38 } 39 const s = { 40 body: {}, 41 addEventListener() {}, 42 removeEventListener() {}, 43 activeElement: { blur() {}, nodeName: "" }, 44 querySelector: () => null, 45 querySelectorAll: () => [], 46 getElementById: () => null, 47 createEvent: () => ({ initEvent() {} }), 48 createElement: () => ({ 49 children: [], 50 childNodes: [], 51 style: {}, 52 setAttribute() {}, 53 getElementsByTagName: () => [], 54 }), 55 createElementNS: () => ({}), 56 importNode: () => null, 57 location: { 58 hash: "", 59 host: "", 60 hostname: "", 61 href: "", 62 origin: "", 63 pathname: "", 64 protocol: "", 65 search: "", 66 }, 67 }; 68 function a() { 69 const e = "undefined" != typeof document ? document : {}; 70 return t(e, s), e; 71 } 72 const i = { 73 document: s, 74 navigator: { userAgent: "" }, 75 location: { 76 hash: "", 77 host: "", 78 hostname: "", 79 href: "", 80 origin: "", 81 pathname: "", 82 protocol: "", 83 search: "", 84 }, 85 history: { replaceState() {}, pushState() {}, go() {}, back() {} }, 86 CustomEvent: function () { 87 return this; 88 }, 89 addEventListener() {}, 90 removeEventListener() {}, 91 getComputedStyle: () => ({ getPropertyValue: () => "" }), 92 Image() {}, 93 Date() {}, 94 screen: {}, 95 setTimeout() {}, 96 clearTimeout() {}, 97 matchMedia: () => ({}), 98 requestAnimationFrame: (e) => 99 "undefined" == typeof setTimeout ? (e(), null) : setTimeout(e, 0), 100 cancelAnimationFrame(e) { 101 "undefined" != typeof setTimeout && clearTimeout(e); 102 }, 103 }; 104 function r() { 105 const e = "undefined" != typeof window ? window : {}; 106 return t(e, i), e; 107 } 108 class n extends Array { 109 constructor(e) { 110 "number" == typeof e 111 ? super(e) 112 : (super(...(e || [])), 113 (function (e) { 114 const t = e.__proto__; 115 Object.defineProperty(e, "__proto__", { 116 get: () => t, 117 set(e) { 118 t.__proto__ = e; 119 }, 120 }); 121 })(this)); 122 } 123 } 124 function l(e) { 125 void 0 === e && (e = []); 126 const t = []; 127 return ( 128 e.forEach((e) => { 129 Array.isArray(e) ? t.push(...l(e)) : t.push(e); 130 }), 131 t 132 ); 133 } 134 function o(e, t) { 135 return Array.prototype.filter.call(e, t); 136 } 137 function d(e, t) { 138 const s = r(), 139 i = a(); 140 let l = []; 141 if (!t && e instanceof n) return e; 142 if (!e) return new n(l); 143 if ("string" == typeof e) { 144 const s = e.trim(); 145 if (s.indexOf("<") >= 0 && s.indexOf(">") >= 0) { 146 let e = "div"; 147 0 === s.indexOf("<li") && (e = "ul"), 148 0 === s.indexOf("<tr") && (e = "tbody"), 149 (0 !== s.indexOf("<td") && 0 !== s.indexOf("<th")) || (e = "tr"), 150 0 === s.indexOf("<tbody") && (e = "table"), 151 0 === s.indexOf("<option") && (e = "select"); 152 const t = i.createElement(e); 153 t.innerHTML = s; 154 for (let e = 0; e < t.childNodes.length; e += 1) 155 l.push(t.childNodes[e]); 156 } else 157 l = (function (e, t) { 158 if ("string" != typeof e) return [e]; 159 const s = [], 160 a = t.querySelectorAll(e); 161 for (let e = 0; e < a.length; e += 1) s.push(a[e]); 162 return s; 163 })(e.trim(), t || i); 164 } else if (e.nodeType || e === s || e === i) l.push(e); 165 else if (Array.isArray(e)) { 166 if (e instanceof n) return e; 167 l = e; 168 } 169 return new n( 170 (function (e) { 171 const t = []; 172 for (let s = 0; s < e.length; s += 1) 173 -1 === t.indexOf(e[s]) && t.push(e[s]); 174 return t; 175 })(l) 176 ); 177 } 178 d.fn = n.prototype; 179 const c = { 180 addClass: function () { 181 for (var e = arguments.length, t = new Array(e), s = 0; s < e; s++) 182 t[s] = arguments[s]; 183 const a = l(t.map((e) => e.split(" "))); 184 return ( 185 this.forEach((e) => { 186 e.classList.add(...a); 187 }), 188 this 189 ); 190 }, 191 removeClass: function () { 192 for (var e = arguments.length, t = new Array(e), s = 0; s < e; s++) 193 t[s] = arguments[s]; 194 const a = l(t.map((e) => e.split(" "))); 195 return ( 196 this.forEach((e) => { 197 e.classList.remove(...a); 198 }), 199 this 200 ); 201 }, 202 hasClass: function () { 203 for (var e = arguments.length, t = new Array(e), s = 0; s < e; s++) 204 t[s] = arguments[s]; 205 const a = l(t.map((e) => e.split(" "))); 206 return ( 207 o(this, (e) => a.filter((t) => e.classList.contains(t)).length > 0) 208 .length > 0 209 ); 210 }, 211 toggleClass: function () { 212 for (var e = arguments.length, t = new Array(e), s = 0; s < e; s++) 213 t[s] = arguments[s]; 214 const a = l(t.map((e) => e.split(" "))); 215 this.forEach((e) => { 216 a.forEach((t) => { 217 e.classList.toggle(t); 218 }); 219 }); 220 }, 221 attr: function (e, t) { 222 if (1 === arguments.length && "string" == typeof e) 223 return this[0] ? this[0].getAttribute(e) : void 0; 224 for (let s = 0; s < this.length; s += 1) 225 if (2 === arguments.length) this[s].setAttribute(e, t); 226 else 227 for (const t in e) (this[s][t] = e[t]), this[s].setAttribute(t, e[t]); 228 return this; 229 }, 230 removeAttr: function (e) { 231 for (let t = 0; t < this.length; t += 1) this[t].removeAttribute(e); 232 return this; 233 }, 234 transform: function (e) { 235 for (let t = 0; t < this.length; t += 1) this[t].style.transform = e; 236 return this; 237 }, 238 transition: function (e) { 239 for (let t = 0; t < this.length; t += 1) 240 this[t].style.transitionDuration = "string" != typeof e ? `${e}ms` : e; 241 return this; 242 }, 243 on: function () { 244 for (var e = arguments.length, t = new Array(e), s = 0; s < e; s++) 245 t[s] = arguments[s]; 246 let [a, i, r, n] = t; 247 function l(e) { 248 const t = e.target; 249 if (!t) return; 250 const s = e.target.dom7EventData || []; 251 if ((s.indexOf(e) < 0 && s.unshift(e), d(t).is(i))) r.apply(t, s); 252 else { 253 const e = d(t).parents(); 254 for (let t = 0; t < e.length; t += 1) 255 d(e[t]).is(i) && r.apply(e[t], s); 256 } 257 } 258 function o(e) { 259 const t = (e && e.target && e.target.dom7EventData) || []; 260 t.indexOf(e) < 0 && t.unshift(e), r.apply(this, t); 261 } 262 "function" == typeof t[1] && (([a, r, n] = t), (i = void 0)), 263 n || (n = !1); 264 const c = a.split(" "); 265 let p; 266 for (let e = 0; e < this.length; e += 1) { 267 const t = this[e]; 268 if (i) 269 for (p = 0; p < c.length; p += 1) { 270 const e = c[p]; 271 t.dom7LiveListeners || (t.dom7LiveListeners = {}), 272 t.dom7LiveListeners[e] || (t.dom7LiveListeners[e] = []), 273 t.dom7LiveListeners[e].push({ listener: r, proxyListener: l }), 274 t.addEventListener(e, l, n); 275 } 276 else 277 for (p = 0; p < c.length; p += 1) { 278 const e = c[p]; 279 t.dom7Listeners || (t.dom7Listeners = {}), 280 t.dom7Listeners[e] || (t.dom7Listeners[e] = []), 281 t.dom7Listeners[e].push({ listener: r, proxyListener: o }), 282 t.addEventListener(e, o, n); 283 } 284 } 285 return this; 286 }, 287 off: function () { 288 for (var e = arguments.length, t = new Array(e), s = 0; s < e; s++) 289 t[s] = arguments[s]; 290 let [a, i, r, n] = t; 291 "function" == typeof t[1] && (([a, r, n] = t), (i = void 0)), 292 n || (n = !1); 293 const l = a.split(" "); 294 for (let e = 0; e < l.length; e += 1) { 295 const t = l[e]; 296 for (let e = 0; e < this.length; e += 1) { 297 const s = this[e]; 298 let a; 299 if ( 300 (!i && s.dom7Listeners 301 ? (a = s.dom7Listeners[t]) 302 : i && s.dom7LiveListeners && (a = s.dom7LiveListeners[t]), 303 a && a.length) 304 ) 305 for (let e = a.length - 1; e >= 0; e -= 1) { 306 const i = a[e]; 307 (r && i.listener === r) || 308 (r && 309 i.listener && 310 i.listener.dom7proxy && 311 i.listener.dom7proxy === r) 312 ? (s.removeEventListener(t, i.proxyListener, n), a.splice(e, 1)) 313 : r || 314 (s.removeEventListener(t, i.proxyListener, n), 315 a.splice(e, 1)); 316 } 317 } 318 } 319 return this; 320 }, 321 trigger: function () { 322 const e = r(); 323 for (var t = arguments.length, s = new Array(t), a = 0; a < t; a++) 324 s[a] = arguments[a]; 325 const i = s[0].split(" "), 326 n = s[1]; 327 for (let t = 0; t < i.length; t += 1) { 328 const a = i[t]; 329 for (let t = 0; t < this.length; t += 1) { 330 const i = this[t]; 331 if (e.CustomEvent) { 332 const t = new e.CustomEvent(a, { 333 detail: n, 334 bubbles: !0, 335 cancelable: !0, 336 }); 337 (i.dom7EventData = s.filter((e, t) => t > 0)), 338 i.dispatchEvent(t), 339 (i.dom7EventData = []), 340 delete i.dom7EventData; 341 } 342 } 343 } 344 return this; 345 }, 346 transitionEnd: function (e) { 347 const t = this; 348 return ( 349 e && 350 t.on("transitionend", function s(a) { 351 a.target === this && (e.call(this, a), t.off("transitionend", s)); 352 }), 353 this 354 ); 355 }, 356 outerWidth: function (e) { 357 if (this.length > 0) { 358 if (e) { 359 const e = this.styles(); 360 return ( 361 this[0].offsetWidth + 362 parseFloat(e.getPropertyValue("margin-right")) + 363 parseFloat(e.getPropertyValue("margin-left")) 364 ); 365 } 366 return this[0].offsetWidth; 367 } 368 return null; 369 }, 370 outerHeight: function (e) { 371 if (this.length > 0) { 372 if (e) { 373 const e = this.styles(); 374 return ( 375 this[0].offsetHeight + 376 parseFloat(e.getPropertyValue("margin-top")) + 377 parseFloat(e.getPropertyValue("margin-bottom")) 378 ); 379 } 380 return this[0].offsetHeight; 381 } 382 return null; 383 }, 384 styles: function () { 385 const e = r(); 386 return this[0] ? e.getComputedStyle(this[0], null) : {}; 387 }, 388 offset: function () { 389 if (this.length > 0) { 390 const e = r(), 391 t = a(), 392 s = this[0], 393 i = s.getBoundingClientRect(), 394 n = t.body, 395 l = s.clientTop || n.clientTop || 0, 396 o = s.clientLeft || n.clientLeft || 0, 397 d = s === e ? e.scrollY : s.scrollTop, 398 c = s === e ? e.scrollX : s.scrollLeft; 399 return { top: i.top + d - l, left: i.left + c - o }; 400 } 401 return null; 402 }, 403 css: function (e, t) { 404 const s = r(); 405 let a; 406 if (1 === arguments.length) { 407 if ("string" != typeof e) { 408 for (a = 0; a < this.length; a += 1) 409 for (const t in e) this[a].style[t] = e[t]; 410 return this; 411 } 412 if (this[0]) 413 return s.getComputedStyle(this[0], null).getPropertyValue(e); 414 } 415 if (2 === arguments.length && "string" == typeof e) { 416 for (a = 0; a < this.length; a += 1) this[a].style[e] = t; 417 return this; 418 } 419 return this; 420 }, 421 each: function (e) { 422 return e 423 ? (this.forEach((t, s) => { 424 e.apply(t, [t, s]); 425 }), 426 this) 427 : this; 428 }, 429 html: function (e) { 430 if (void 0 === e) return this[0] ? this[0].innerHTML : null; 431 for (let t = 0; t < this.length; t += 1) this[t].innerHTML = e; 432 return this; 433 }, 434 text: function (e) { 435 if (void 0 === e) return this[0] ? this[0].textContent.trim() : null; 436 for (let t = 0; t < this.length; t += 1) this[t].textContent = e; 437 return this; 438 }, 439 is: function (e) { 440 const t = r(), 441 s = a(), 442 i = this[0]; 443 let l, o; 444 if (!i || void 0 === e) return !1; 445 if ("string" == typeof e) { 446 if (i.matches) return i.matches(e); 447 if (i.webkitMatchesSelector) return i.webkitMatchesSelector(e); 448 if (i.msMatchesSelector) return i.msMatchesSelector(e); 449 for (l = d(e), o = 0; o < l.length; o += 1) if (l[o] === i) return !0; 450 return !1; 451 } 452 if (e === s) return i === s; 453 if (e === t) return i === t; 454 if (e.nodeType || e instanceof n) { 455 for (l = e.nodeType ? [e] : e, o = 0; o < l.length; o += 1) 456 if (l[o] === i) return !0; 457 return !1; 458 } 459 return !1; 460 }, 461 index: function () { 462 let e, 463 t = this[0]; 464 if (t) { 465 for (e = 0; null !== (t = t.previousSibling); ) 466 1 === t.nodeType && (e += 1); 467 return e; 468 } 469 }, 470 eq: function (e) { 471 if (void 0 === e) return this; 472 const t = this.length; 473 if (e > t - 1) return d([]); 474 if (e < 0) { 475 const s = t + e; 476 return d(s < 0 ? [] : [this[s]]); 477 } 478 return d([this[e]]); 479 }, 480 append: function () { 481 let e; 482 const t = a(); 483 for (let s = 0; s < arguments.length; s += 1) { 484 e = s < 0 || arguments.length <= s ? void 0 : arguments[s]; 485 for (let s = 0; s < this.length; s += 1) 486 if ("string" == typeof e) { 487 const a = t.createElement("div"); 488 for (a.innerHTML = e; a.firstChild; ) 489 this[s].appendChild(a.firstChild); 490 } else if (e instanceof n) 491 for (let t = 0; t < e.length; t += 1) this[s].appendChild(e[t]); 492 else this[s].appendChild(e); 493 } 494 return this; 495 }, 496 prepend: function (e) { 497 const t = a(); 498 let s, i; 499 for (s = 0; s < this.length; s += 1) 500 if ("string" == typeof e) { 501 const a = t.createElement("div"); 502 for (a.innerHTML = e, i = a.childNodes.length - 1; i >= 0; i -= 1) 503 this[s].insertBefore(a.childNodes[i], this[s].childNodes[0]); 504 } else if (e instanceof n) 505 for (i = 0; i < e.length; i += 1) 506 this[s].insertBefore(e[i], this[s].childNodes[0]); 507 else this[s].insertBefore(e, this[s].childNodes[0]); 508 return this; 509 }, 510 next: function (e) { 511 return this.length > 0 512 ? e 513 ? this[0].nextElementSibling && d(this[0].nextElementSibling).is(e) 514 ? d([this[0].nextElementSibling]) 515 : d([]) 516 : this[0].nextElementSibling 517 ? d([this[0].nextElementSibling]) 518 : d([]) 519 : d([]); 520 }, 521 nextAll: function (e) { 522 const t = []; 523 let s = this[0]; 524 if (!s) return d([]); 525 for (; s.nextElementSibling; ) { 526 const a = s.nextElementSibling; 527 e ? d(a).is(e) && t.push(a) : t.push(a), (s = a); 528 } 529 return d(t); 530 }, 531 prev: function (e) { 532 if (this.length > 0) { 533 const t = this[0]; 534 return e 535 ? t.previousElementSibling && d(t.previousElementSibling).is(e) 536 ? d([t.previousElementSibling]) 537 : d([]) 538 : t.previousElementSibling 539 ? d([t.previousElementSibling]) 540 : d([]); 541 } 542 return d([]); 543 }, 544 prevAll: function (e) { 545 const t = []; 546 let s = this[0]; 547 if (!s) return d([]); 548 for (; s.previousElementSibling; ) { 549 const a = s.previousElementSibling; 550 e ? d(a).is(e) && t.push(a) : t.push(a), (s = a); 551 } 552 return d(t); 553 }, 554 parent: function (e) { 555 const t = []; 556 for (let s = 0; s < this.length; s += 1) 557 null !== this[s].parentNode && 558 (e 559 ? d(this[s].parentNode).is(e) && t.push(this[s].parentNode) 560 : t.push(this[s].parentNode)); 561 return d(t); 562 }, 563 parents: function (e) { 564 const t = []; 565 for (let s = 0; s < this.length; s += 1) { 566 let a = this[s].parentNode; 567 for (; a; ) e ? d(a).is(e) && t.push(a) : t.push(a), (a = a.parentNode); 568 } 569 return d(t); 570 }, 571 closest: function (e) { 572 let t = this; 573 return void 0 === e ? d([]) : (t.is(e) || (t = t.parents(e).eq(0)), t); 574 }, 575 find: function (e) { 576 const t = []; 577 for (let s = 0; s < this.length; s += 1) { 578 const a = this[s].querySelectorAll(e); 579 for (let e = 0; e < a.length; e += 1) t.push(a[e]); 580 } 581 return d(t); 582 }, 583 children: function (e) { 584 const t = []; 585 for (let s = 0; s < this.length; s += 1) { 586 const a = this[s].children; 587 for (let s = 0; s < a.length; s += 1) 588 (e && !d(a[s]).is(e)) || t.push(a[s]); 589 } 590 return d(t); 591 }, 592 filter: function (e) { 593 return d(o(this, e)); 594 }, 595 remove: function () { 596 for (let e = 0; e < this.length; e += 1) 597 this[e].parentNode && this[e].parentNode.removeChild(this[e]); 598 return this; 599 }, 600 }; 601 function p(e, t) { 602 return void 0 === t && (t = 0), setTimeout(e, t); 603 } 604 function u() { 605 return Date.now(); 606 } 607 function h(e, t) { 608 void 0 === t && (t = "x"); 609 const s = r(); 610 let a, i, n; 611 const l = (function (e) { 612 const t = r(); 613 let s; 614 return ( 615 t.getComputedStyle && (s = t.getComputedStyle(e, null)), 616 !s && e.currentStyle && (s = e.currentStyle), 617 s || (s = e.style), 618 s 619 ); 620 })(e); 621 return ( 622 s.WebKitCSSMatrix
623 ? ((i = l.transform || l.webkitTransform), 624 i.split(",").length > 6 && 625 (i = i 626 .split(", ") 627 .map((e) => e.replace(",", ".")) 628 .join(", ")), 629 (n = new s.WebKitCSSMatrix("none" === i ? "" : i))) 630 : ((n = 631 l.MozTransform || 632 l.OTransform || 633 l.MsTransform || 634 l.msTransform || 635 l.transform || 636 l 637 .getPropertyValue("transform") 638 .replace("translate(", "matrix(1, 0, 0, 1,")), 639 (a = n.toString().split(","))), 640 "x" === t && 641 (i = s.WebKitCSSMatrix 642 ? n.m41 643 : 16 === a.length 644 ? parseFloat(a[12]) 645 : parseFloat(a[4])), 646 "y" === t && 647 (i = s.WebKitCSSMatrix 648 ? n.m42 649 : 16 === a.length 650 ? parseFloat(a[13]) 651 : parseFloat(a[5])), 652 i || 0 653 ); 654 } 655 function m(e) { 656 return ( 657 "object" == typeof e && 658 null !== e && 659 e.constructor && 660 "Object" === Object.prototype.toString.call(e).slice(8, -1) 661 ); 662 } 663 function f(e) { 664 return "undefined" != typeof window && void 0 !== window.HTMLElement 665 ? e instanceof HTMLElement 666 : e && (1 === e.nodeType || 11 === e.nodeType); 667 } 668 function g() { 669 const e = Object(arguments.length <= 0 ? void 0 : arguments[0]), 670 t = ["__proto__", "constructor", "prototype"]; 671 for (let s = 1; s < arguments.length; s += 1) { 672 const a = s < 0 || arguments.length <= s ? void 0 : arguments[s]; 673 if (null != a && !f(a)) { 674 const s = Object.keys(Object(a)).filter((e) => t.indexOf(e) < 0); 675 for (let t = 0, i = s.length; t < i; t += 1) { 676 const i = s[t], 677 r = Object.getOwnPropertyDescriptor(a, i); 678 void 0 !== r && 679 r.enumerable && 680 (m(e[i]) && m(a[i]) 681 ? a[i].__swiper__ 682 ? (e[i] = a[i]) 683 : g(e[i], a[i]) 684 : !m(e[i]) && m(a[i]) 685 ? ((e[i] = {}), a[i].__swiper__ ? (e[i] = a[i]) : g(e[i], a[i])) 686 : (e[i] = a[i])); 687 } 688 } 689 } 690 return e; 691 } 692 function v(e, t, s) { 693 e.style.setProperty(t, s); 694 } 695 function w(e) { 696 let { swiper: t, targetPosition: s, side: a } = e; 697 const i = r(), 698 n = -t.translate; 699 let l, 700 o = null; 701 const d = t.params.speed; 702 (t.wrapperEl.style.scrollSnapType = "none"), 703 i.cancelAnimationFrame(t.cssModeFrameID); 704 const c = s > n ? "next" : "prev", 705 p = (e, t) => ("next" === c && e >= t) || ("prev" === c && e <= t), 706 u = () => { 707 (l = new Date().getTime()), null === o && (o = l); 708 const e = Math.max(Math.min((l - o) / d, 1), 0), 709 r = 0.5 - Math.cos(e * Math.PI) / 2; 710 let c = n + r * (s - n); 711 if ((p(c, s) && (c = s), t.wrapperEl.scrollTo({ [a]: c }), p(c, s))) 712 return ( 713 (t.wrapperEl.style.overflow = "hidden"), 714 (t.wrapperEl.style.scrollSnapType = ""), 715 setTimeout(() => { 716 (t.wrapperEl.style.overflow = ""), 717 t.wrapperEl.scrollTo({ [a]: c }); 718 }), 719 void i.cancelAnimationFrame(t.cssModeFrameID) 720 ); 721 t.cssModeFrameID = i.requestAnimationFrame(u); 722 }; 723 u(); 724 } 725 let b, x, y; 726 function E() { 727 return ( 728 b || 729 (b = (function () { 730 const e = r(), 731 t = a(); 732 return { 733 smoothScroll: 734 t.documentElement && "scrollBehavior" in t.documentElement.style, 735 touch: !!( 736 "ontouchstart" in e || 737 (e.DocumentTouch && t instanceof e.DocumentTouch) 738 ), 739 passiveListener: (function () { 740 let t = !1; 741 try { 742 const s = Object.defineProperty({}, "passive", { 743 get() { 744 t = !0; 745 }, 746 }); 747 e.addEventListener("testPassiveListener", null, s); 748 } catch (e) {} 749 return t; 750 })(), 751 gestures: "ongesturestart" in e, 752 }; 753 })()), 754 b 755 ); 756 } 757 function C(e) { 758 return ( 759 void 0 === e && (e = {}), 760 x || 761 (x = (function (e) { 762 let { userAgent: t } = void 0 === e ? {} : e; 763 const s = E(), 764 a = r(), 765 i = a.navigator.platform, 766 n = t || a.navigator.userAgent, 767 l = { ios: !1, android: !1 }, 768 o = a.screen.width, 769 d = a.screen.height, 770 c = n.match(/(Android);?[\s\/]+([\d.]+)?/); 771 let p = n.match(/(iPad).*OS\s([\d_]+)/); 772 const u = n.match(/(iPod)(.*OS\s([\d_]+))?/), 773 h = !p && n.match(/(iPhone\sOS|iOS)\s([\d_]+)/), 774 m = "Win32" === i; 775 let f = "MacIntel" === i; 776 return ( 777 !p && 778 f && 779 s.touch && 780 [ 781 "1024x1366", 782 "1366x1024", 783 "834x1194", 784 "1194x834", 785 "834x1112", 786 "1112x834", 787 "768x1024", 788 "1024x768", 789 "820x1180", 790 "1180x820", 791 "810x1080", 792 "1080x810", 793 ].indexOf(`${o}x${d}`) >= 0 && 794 ((p = n.match(/(Version)\/([\d.]+)/)), 795 p || (p = [0, 1, "13_0_0"]), 796 (f = !1)), 797 c && !m && ((l.os = "android"), (l.android = !0)), 798 (p || h || u) && ((l.os = "ios"), (l.ios = !0)), 799 l 800 ); 801 })(e)), 802 x 803 ); 804 } 805 function T() { 806 return ( 807 y || 808 (y = (function () { 809 const e = r(); 810 return { 811 isSafari: (function () { 812 const t = e.navigator.userAgent.toLowerCase(); 813 return ( 814 t.indexOf("safari") >= 0 && 815 t.indexOf("chrome") < 0 && 816 t.indexOf("android") < 0 817 ); 818 })(),
819 isWebView: /(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test( 820 e.navigator.userAgent 821 ), 822 }; 823 })()), 824 y 825 ); 826 } 827 Object.keys(c).forEach((e) => { 828 Object.defineProperty(d.fn, e, { value: c[e], writable: !0 }); 829 }); 830 var $ = { 831 on(e, t, s) { 832 const a = this; 833 if (!a.eventsListeners || a.destroyed) return a; 834 if ("function" != typeof t) return a; 835 const i = s ? "unshift" : "push"; 836 return ( 837 e.split(" ").forEach((e) => { 838 a.eventsListeners[e] || (a.eventsListeners[e] = []), 839 a.eventsListeners[e][i](t); 840 }), 841 a 842 ); 843 }, 844 once(e, t, s) { 845 const a = this; 846 if (!a.eventsListeners || a.destroyed) return a; 847 if ("function" != typeof t) return a; 848 function i() { 849 a.off(e, i), i.__emitterProxy && delete i.__emitterProxy; 850 for (var s = arguments.length, r = new Array(s), n = 0; n < s; n++) 851 r[n] = arguments[n]; 852 t.apply(a, r); 853 } 854 return (i.__emitterProxy = t), a.on(e, i, s); 855 }, 856 onAny(e, t) { 857 const s = this; 858 if (!s.eventsListeners || s.destroyed) return s; 859 if ("function" != typeof e) return s; 860 const a = t ? "unshift" : "push"; 861 return ( 862 s.eventsAnyListeners.indexOf(e) < 0 && s.eventsAnyListeners[a](e), s 863 ); 864 }, 865 offAny(e) { 866 const t = this; 867 if (!t.eventsListeners || t.destroyed) return t; 868 if (!t.eventsAnyListeners) return t; 869 const s = t.eventsAnyListeners.indexOf(e); 870 return s >= 0 && t.eventsAnyListeners.splice(s, 1), t; 871 }, 872 off(e, t) { 873 const s = this; 874 return !s.eventsListeners || s.destroyed 875 ? s 876 : s.eventsListeners 877 ? (e.split(" ").forEach((e) => { 878 void 0 === t 879 ? (s.eventsListeners[e] = []) 880 : s.eventsListeners[e] && 881 s.eventsListeners[e].forEach((a, i) => { 882 (a === t || (a.__emitterProxy && a.__emitterProxy === t)) && 883 s.eventsListeners[e].splice(i, 1); 884 }); 885 }), 886 s) 887 : s; 888 }, 889 emit() { 890 const e = this; 891 if (!e.eventsListeners || e.destroyed) return e; 892 if (!e.eventsListeners) return e; 893 let t, s, a; 894 for (var i = arguments.length, r = new Array(i), n = 0; n < i; n++) 895 r[n] = arguments[n]; 896 "string" == typeof r[0] || Array.isArray(r[0]) 897 ? ((t = r[0]), (s = r.slice(1, r.length)), (a = e)) 898 : ((t = r[0].events), (s = r[0].data), (a = r[0].context || e)), 899 s.unshift(a); 900 return ( 901 (Array.isArray(t) ? t : t.split(" ")).forEach((t) => { 902 e.eventsAnyListeners && 903 e.eventsAnyListeners.length && 904 e.eventsAnyListeners.forEach((e) => { 905 e.apply(a, [t, ...s]); 906 }), 907 e.eventsListeners && 908 e.eventsListeners[t] && 909 e.eventsListeners[t].forEach((e) => { 910 e.apply(a, s); 911 }); 912 }), 913 e 914 ); 915 }, 916 }; 917 var S = { 918 updateSize: function () { 919 const e = this; 920 let t, s; 921 const a = e.$el; 922 (t = 923 void 0 !== e.params.width && null !== e.params.width 924 ? e.params.width 925 : a[0].clientWidth), 926 (s = 927 void 0 !== e.params.height && null !== e.params.height 928 ? e.params.height 929 : a[0].clientHeight), 930 (0 === t && e.isHorizontal()) || 931 (0 === s && e.isVertical()) || 932 ((t = 933 t - 934 parseInt(a.css("padding-left") || 0, 10) - 935 parseInt(a.css("padding-right") || 0, 10)), 936 (s = 937 s - 938 parseInt(a.css("padding-top") || 0, 10) - 939 parseInt(a.css("padding-bottom") || 0, 10)), 940 Number.isNaN(t) && (t = 0), 941 Number.isNaN(s) && (s = 0), 942 Object.assign(e, { 943 width: t, 944 height: s, 945 size: e.isHorizontal() ? t : s, 946 })); 947 }, 948 updateSlides: function () { 949 const e = this; 950 function t(t) { 951 return e.isHorizontal() 952 ? t 953 : { 954 width: "height", 955 "margin-top": "margin-left", 956 "margin-bottom ": "margin-right", 957 "margin-left": "margin-top", 958 "margin-right": "margin-bottom", 959 "padding-left": "padding-top", 960 "padding-right": "padding-bottom", 961 marginRight: "marginBottom", 962 }[t]; 963 } 964 function s(e, s) { 965 return parseFloat(e.getPropertyValue(t(s)) || 0); 966 } 967 const a = e.params, 968 { $wrapperEl: i, size: r, rtlTranslate: n, wrongRTL: l } = e, 969 o = e.virtual && a.virtual.enabled, 970 d = o ? e.virtual.slides.length : e.slides.length, 971 c = i.children(`.${e.params.slideClass}`), 972 p = o ? e.virtual.slides.length : c.length; 973 let u = []; 974 const h = [], 975 m = []; 976 let f = a.slidesOffsetBefore; 977 "function" == typeof f && (f = a.slidesOffsetBefore.call(e)); 978 let g = a.slidesOffsetAfter; 979 "function" == typeof g && (g = a.slidesOffsetAfter.call(e)); 980 const w = e.snapGrid.length, 981 b = e.slidesGrid.length; 982 let x = a.spaceBetween, 983 y = -f, 984 E = 0, 985 C = 0; 986 if (void 0 === r) return; 987 "string" == typeof x && 988 x.indexOf("%") >= 0 && 989 (x = (parseFloat(x.replace("%", "")) / 100) * r), 990 (e.virtualSize = -x), 991 n 992 ? c.css({ marginLeft: "", marginBottom: "", marginTop: "" }) 993 : c.css({ marginRight: "", marginBottom: "", marginTop: "" }), 994 a.centeredSlides && 995 a.cssMode && 996 (v(e.wrapperEl, "--swiper-centered-offset-before", ""), 997 v(e.wrapperEl, "--swiper-centered-offset-after", "")); 998 const T = a.grid && a.grid.rows > 1 && e.grid; 999 let $; 1000 T && e.grid.initSlides(p); 1001 const S = 1002 "auto" === a.slidesPerView && 1003 a.breakpoints && 1004 Object.keys(a.breakpoints).filter( 1005 (e) => void 0 !== a.breakpoints[e].slidesPerView 1006 ).length > 0; 1007 for (let i = 0; i < p; i += 1) { 1008 $ = 0; 1009 const n = c.eq(i); 1010 if ( 1011 (T && e.grid.updateSlide(i, n, p, t), "none" !== n.css("display")) 1012 ) { 1013 if ("auto" === a.slidesPerView) { 1014 S && (c[i].style[t("width")] = ""); 1015 const r = getComputedStyle(n[0]), 1016 l = n[0].style.transform, 1017 o = n[0].style.webkitTransform; 1018 if ( 1019 (l && (n[0].style.transform = "none"), 1020 o && (n[0].style.webkitTransform = "none"), 1021 a.roundLengths) 1022 ) 1023 $ = e.isHorizontal() ? n.outerWidth(!0) : n.outerHeight(!0); 1024 else { 1025 const e = s(r, "width"), 1026 t = s(r, "padding-left"), 1027 a = s(r, "padding-right"), 1028 i = s(r, "margin-left"), 1029 l = s(r, "margin-right"), 1030 o = r.getPropertyValue("box-sizing"); 1031 if (o && "border-box" === o) $ = e + i + l; 1032 else {
1033 const { clientWidth: s, offsetWidth: r } = n[0]; 1034 $ = e + t + a + i + l + (r - s); 1035 } 1036 } 1037 l && (n[0].style.transform = l), 1038 o && (n[0].style.webkitTransform = o), 1039 a.roundLengths && ($ = Math.floor($)); 1040 } else 1041 ($ = (r - (a.slidesPerView - 1) * x) / a.slidesPerView), 1042 a.roundLengths && ($ = Math.floor($)), 1043 c[i] && (c[i].style[t("width")] = `${$}px`); 1044 c[i] && (c[i].swiperSlideSize = $), 1045 m.push($), 1046 a.centeredSlides 1047 ? ((y = y + $ / 2 + E / 2 + x), 1048 0 === E && 0 !== i && (y = y - r / 2 - x), 1049 0 === i && (y = y - r / 2 - x), 1050 Math.abs(y) < 0.001 && (y = 0), 1051 a.roundLengths && (y = Math.floor(y)), 1052 C % a.slidesPerGroup == 0 && u.push(y), 1053 h.push(y)) 1054 : (a.roundLengths && (y = Math.floor(y)), 1055 (C - Math.min(e.params.slidesPerGroupSkip, C)) % 1056 e.params.slidesPerGroup == 1057 0 && u.push(y), 1058 h.push(y), 1059 (y = y + $ + x)), 1060 (e.virtualSize += $ + x), 1061 (E = $), 1062 (C += 1); 1063 } 1064 } 1065 if ( 1066 ((e.virtualSize = Math.max(e.virtualSize, r) + g), 1067 n && 1068 l && 1069 ("slide" === a.effect || "coverflow" === a.effect) && 1070 i.css({ width: `${e.virtualSize + a.spaceBetween}px` }), 1071 a.setWrapperSize && 1072 i.css({ [t("width")]: `${e.virtualSize + a.spaceBetween}px` }), 1073 T && e.grid.updateWrapperSize($, u, t), 1074 !a.centeredSlides) 1075 ) { 1076 const t = []; 1077 for (let s = 0; s < u.length; s += 1) { 1078 let i = u[s]; 1079 a.roundLengths && (i = Math.floor(i)), 1080 u[s] <= e.virtualSize - r && t.push(i); 1081 } 1082 (u = t), 1083 Math.floor(e.virtualSize - r) - Math.floor(u[u.length - 1]) > 1 && 1084 u.push(e.virtualSize - r); 1085 } 1086 if ((0 === u.length && (u = [0]), 0 !== a.spaceBetween)) { 1087 const s = e.isHorizontal() && n ? "marginLeft" : t("marginRight"); 1088 c.filter((e, t) => !a.cssMode || t !== c.length - 1).css({ 1089 [s]: `${x}px`, 1090 }); 1091 }
1092 if (a.centeredSlides && a.centeredSlidesBounds) { 1093 let e = 0; 1094 m.forEach((t) => { 1095 e += t + (a.spaceBetween ? a.spaceBetween : 0); 1096 }), 1097 (e -= a.spaceBetween); 1098 const t = e - r; 1099 u = u.map((e) => (e < 0 ? -f : e > t ? t + g : e)); 1100 } 1101 if (a.centerInsufficientSlides) { 1102 let e = 0; 1103 if ( 1104 (m.forEach((t) => { 1105 e += t + (a.spaceBetween ? a.spaceBetween : 0); 1106 }), 1107 (e -= a.spaceBetween), 1108 e < r) 1109 ) { 1110 const t = (r - e) / 2; 1111 u.forEach((e, s) => { 1112 u[s] = e - t; 1113 }), 1114 h.forEach((e, s) => { 1115 h[s] = e + t; 1116 }); 1117 } 1118 } 1119 if ( 1120 (Object.assign(e, { 1121 slides: c, 1122 snapGrid: u, 1123 slidesGrid: h, 1124 slidesSizesGrid: m, 1125 }), 1126 a.centeredSlides && a.cssMode && !a.centeredSlidesBounds) 1127 ) { 1128 v(e.wrapperEl, "--swiper-centered-offset-before", -u[0] + "px"), 1129 v( 1130 e.wrapperEl, 1131 "--swiper-centered-offset-after", 1132 e.size / 2 - m[m.length - 1] / 2 + "px" 1133 ); 1134 const t = -e.snapGrid[0], 1135 s = -e.slidesGrid[0]; 1136 (e.snapGrid = e.snapGrid.map((e) => e + t)), 1137 (e.slidesGrid = e.slidesGrid.map((e) => e + s)); 1138 } 1139 if ( 1140 (p !== d && e.emit("slidesLengthChange"), 1141 u.length !== w && 1142 (e.params.watchOverflow && e.checkOverflow(), 1143 e.emit("snapGridLengthChange")), 1144 h.length !== b && e.emit("slidesGridLengthChange"), 1145 a.watchSlidesProgress && e.updateSlidesOffset(), 1146 !(o || a.cssMode || ("slide" !== a.effect && "fade" !== a.effect))) 1147 ) { 1148 const t = `${a.containerModifierClass}backface-hidden`, 1149 s = e.$el.hasClass(t); 1150 p <= a.maxBackfaceHiddenSlides 1151 ? s || e.$el.addClass(t) 1152 : s && e.$el.removeClass(t); 1153 } 1154 }, 1155 updateAutoHeight: function (e) { 1156 const t = this, 1157 s = [], 1158 a = t.virtual && t.params.virtual.enabled; 1159 let i, 1160 r = 0; 1161 "number" == typeof e 1162 ? t.setTransition(e) 1163 : !0 === e && t.setTransition(t.params.speed); 1164 const n = (e) => 1165 a 1166 ? t.slides.filter( 1167 (t) => 1168 parseInt(t.getAttribute("data-swiper-slide-index"), 10) === e 1169 )[0] 1170 : t.slides.eq(e)[0]; 1171 if ("auto" !== t.params.slidesPerView && t.params.slidesPerView > 1) 1172 if (t.params.centeredSlides) 1173 (t.visibleSlides || d([])).each((e) => { 1174 s.push(e); 1175 }); 1176 else 1177 for (i = 0; i < Math.ceil(t.params.slidesPerView); i += 1) { 1178 const e = t.activeIndex + i; 1179 if (e > t.slides.length && !a) break; 1180 s.push(n(e)); 1181 } 1182 else s.push(n(t.activeIndex)); 1183 for (i = 0; i < s.length; i += 1) 1184 if (void 0 !== s[i]) { 1185 const e = s[i].offsetHeight; 1186 r = e > r ? e : r; 1187 } 1188 (r || 0 === r) && t.$wrapperEl.css("height", `${r}px`); 1189 }, 1190 updateSlidesOffset: function () { 1191 const e = this, 1192 t = e.slides; 1193 for (let s = 0; s < t.length; s += 1) 1194 t[s].swiperSlideOffset = e.isHorizontal() 1195 ? t[s].offsetLeft 1196 : t[s].offsetTop; 1197 }, 1198 updateSlidesProgress: function (e) { 1199 void 0 === e && (e = (this && this.translate) || 0); 1200 const t = this, 1201 s = t.params, 1202 { slides: a, rtlTranslate: i, snapGrid: r } = t; 1203 if (0 === a.length) return; 1204 void 0 === a[0].swiperSlideOffset && t.updateSlidesOffset(); 1205 let n = -e; 1206 i && (n = e), 1207 a.removeClass(s.slideVisibleClass), 1208 (t.visibleSlidesIndexes = []), 1209 (t.visibleSlides = []); 1210 for (let e = 0; e < a.length; e += 1) { 1211 const l = a[e]; 1212 let o = l.swiperSlideOffset; 1213 s.cssMode && s.centeredSlides && (o -= a[0].swiperSlideOffset); 1214 const d = 1215 (n + (s.centeredSlides ? t.minTranslate() : 0) - o) / 1216 (l.swiperSlideSize + s.spaceBetween), 1217 c = 1218 (n - r[0] + (s.centeredSlides ? t.minTranslate() : 0) - o) / 1219 (l.swiperSlideSize + s.spaceBetween), 1220 p = -(n - o), 1221 u = p + t.slidesSizesGrid[e]; 1222 ((p >= 0 && p < t.size - 1) || 1223 (u > 1 && u <= t.size) || 1224 (p <= 0 && u >= t.size)) && 1225 (t.visibleSlides.push(l), 1226 t.visibleSlidesIndexes.push(e), 1227 a.eq(e).addClass(s.slideVisibleClass)), 1228 (l.progress = i ? -d : d), 1229 (l.originalProgress = i ? -c : c); 1230 } 1231 t.visibleSlides = d(t.visibleSlides); 1232 }, 1233 updateProgress: function (e) { 1234 const t = this; 1235 if (void 0 === e) { 1236 const s = t.rtlTranslate ? -1 : 1; 1237 e = (t && t.translate && t.translate * s) || 0; 1238 } 1239 const s = t.params, 1240 a = t.maxTranslate() - t.minTranslate(); 1241 let { progress: i, isBeginning: r, isEnd: n } = t;
1242 const l = r, 1243 o = n; 1244 0 === a 1245 ? ((i = 0), (r = !0), (n = !0)) 1246 : ((i = (e - t.minTranslate()) / a), (r = i <= 0), (n = i >= 1)), 1247 Object.assign(t, { progress: i, isBeginning: r, isEnd: n }), 1248 (s.watchSlidesProgress || (s.centeredSlides && s.autoHeight)) && 1249 t.updateSlidesProgress(e), 1250 r && !l && t.emit("reachBeginning toEdge"), 1251 n && !o && t.emit("reachEnd toEdge"), 1252 ((l && !r) || (o && !n)) && t.emit("fromEdge"), 1253 t.emit("progress", i); 1254 }, 1255 updateSlidesClasses: function () { 1256 const e = this, 1257 { 1258 slides: t, 1259 params: s, 1260 $wrapperEl: a, 1261 activeIndex: i, 1262 realIndex: r, 1263 } = e, 1264 n = e.virtual && s.virtual.enabled; 1265 let l; 1266 t.removeClass( 1267 `${s.slideActiveClass} ${s.slideNextClass} ${s.slidePrevClass} ${s.slideDuplicateActiveClass} ${s.slideDuplicateNextClass} ${s.slideDuplicatePrevClass}` 1268 ), 1269 (l = n 1270 ? e.$wrapperEl.find( 1271 `.${s.slideClass}[data-swiper-slide-index="${i}"]` 1272 ) 1273 : t.eq(i)), 1274 l.addClass(s.slideActiveClass), 1275 s.loop && 1276 (l.hasClass(s.slideDuplicateClass) 1277 ? a 1278 .children( 1279 `.${s.slideClass}:not(.${s.slideDuplicateClass})[data-swiper-slide-index="${r}"]` 1280 ) 1281 .addClass(s.slideDuplicateActiveClass) 1282 : a 1283 .children( 1284 `.${s.slideClass}.${s.slideDuplicateClass}[data-swiper-slide-index="${r}"]` 1285 ) 1286 .addClass(s.slideDuplicateActiveClass)); 1287 let o = l.nextAll(`.${s.slideClass}`).eq(0).addClass(s.slideNextClass); 1288 s.loop && 0 === o.length && ((o = t.eq(0)), o.addClass(s.slideNextClass)); 1289 let d = l.prevAll(`.${s.slideClass}`).eq(0).addClass(s.slidePrevClass); 1290 s.loop && 1291 0 === d.length && 1292 ((d = t.eq(-1)), d.addClass(s.slidePrevClass)), 1293 s.loop && 1294 (o.hasClass(s.slideDuplicateClass) 1295 ? a 1296 .children( 1297 `.${s.slideClass}:not(.${ 1298 s.slideDuplicateClass 1299 })[data-swiper-slide-index="${o.attr( 1300 "data-swiper-slide-index" 1301 )}"]` 1302 ) 1303 .addClass(s.slideDuplicateNextClass) 1304 : a 1305 .children( 1306 `.${s.slideClass}.${ 1307 s.slideDuplicateClass 1308 }[data-swiper-slide-index="${o.attr( 1309 "data-swiper-slide-index" 1310 )}"]` 1311 ) 1312 .addClass(s.slideDuplicateNextClass), 1313 d.hasClass(s.slideDuplicateClass) 1314 ? a 1315 .children( 1316 `.${s.slideClass}:not(.${ 1317 s.slideDuplicateClass 1318 })[data-swiper-slide-index="${d.attr( 1319 "data-swiper-slide-index" 1320 )}"]` 1321 ) 1322 .addClass(s.slideDuplicatePrevClass) 1323 : a 1324 .children( 1325 `.${s.slideClass}.${ 1326 s.slideDuplicateClass 1327 }[data-swiper-slide-index="${d.attr( 1328 "data-swiper-slide-index" 1329 )}"]` 1330 ) 1331 .addClass(s.slideDuplicatePrevClass)), 1332 e.emitSlidesClasses(); 1333 }, 1334 updateActiveIndex: function (e) { 1335 const t = this, 1336 s = t.rtlTranslate ? t.translate : -t.translate, 1337 { 1338 slidesGrid: a, 1339 snapGrid: i, 1340 params: r, 1341 activeIndex: n, 1342 realIndex: l, 1343 snapIndex: o, 1344 } = t; 1345 let d, 1346 c = e; 1347 if (void 0 === c) { 1348 for (let e = 0; e < a.length; e += 1) 1349 void 0 !== a[e + 1] 1350 ? s >= a[e] && s < a[e + 1] - (a[e + 1] - a[e]) / 2 1351 ? (c = e) 1352 : s >= a[e] && s < a[e + 1] && (c = e + 1) 1353 : s >= a[e] && (c = e); 1354 r.normalizeSlideIndex && (c < 0 || void 0 === c) && (c = 0); 1355 } 1356 if (i.indexOf(s) >= 0) d = i.indexOf(s); 1357 else { 1358 const e = Math.min(r.slidesPerGroupSkip, c); 1359 d = e + Math.floor((c - e) / r.slidesPerGroup); 1360 } 1361 if ((d >= i.length && (d = i.length - 1), c === n)) 1362 return void (d !== o && ((t.snapIndex = d), t.emit("snapIndexChange"))); 1363 const p = parseInt( 1364 t.slides.eq(c).attr("data-swiper-slide-index") || c, 1365 10 1366 ); 1367 Object.assign(t, { 1368 snapIndex: d, 1369 realIndex: p, 1370 previousIndex: n, 1371 activeIndex: c, 1372 }), 1373 t.emit("activeIndexChange"), 1374 t.emit("snapIndexChange"), 1375 l !== p && t.emit("realIndexChange"), 1376 (t.initialized || t.params.runCallbacksOnInit) && t.emit("slideChange"); 1377 }, 1378 updateClickedSlide: function (e) { 1379 const t = this, 1380 s = t.params, 1381 a = d(e).closest(`.${s.slideClass}`)[0]; 1382 let i, 1383 r = !1; 1384 if (a) 1385 for (let e = 0; e < t.slides.length; e += 1) 1386 if (t.slides[e] === a) { 1387 (r = !0), (i = e); 1388 break; 1389 } 1390 if (!a || !r) 1391 return (t.clickedSlide = void 0), void (t.clickedIndex = void 0); 1392 (t.clickedSlide = a), 1393 t.virtual && t.params.virtual.enabled 1394 ? (t.clickedIndex = parseInt( 1395 d(a).attr("data-swiper-slide-index"), 1396 10 1397 )) 1398 : (t.clickedIndex = i), 1399 s.slideToClickedSlide && 1400 void 0 !== t.clickedIndex && 1401 t.clickedIndex !== t.activeIndex && 1402 t.slideToClickedSlide(); 1403 }, 1404 }; 1405 var M = { 1406 getTranslate: function (e) { 1407 void 0 === e && (e = this.isHorizontal() ? "x" : "y"); 1408 const { params: t, rtlTranslate: s, translate: a, $wrapperEl: i } = this; 1409 if (t.virtualTranslate) return s ? -a : a; 1410 if (t.cssMode) return a; 1411 let r = h(i[0], e); 1412 return s && (r = -r), r || 0; 1413 }, 1414 setTranslate: function (e, t) { 1415 const s = this, 1416 { 1417 rtlTranslate: a, 1418 params: i, 1419 $wrapperEl: r, 1420 wrapperEl: n, 1421 progress: l, 1422 } = s; 1423 let o, 1424 d = 0, 1425 c = 0; 1426 s.isHorizontal() ? (d = a ? -e : e) : (c = e), 1427 i.roundLengths && ((d = Math.floor(d)), (c = Math.floor(c))), 1428 i.cssMode 1429 ? (n[s.isHorizontal() ? "scrollLeft" : "scrollTop"] = s.isHorizontal() 1430 ? -d 1431 : -c) 1432 : i.virtualTranslate || 1433 r.transform(`translate3d(${d}px, ${c}px, 0px)`), 1434 (s.previousTranslate = s.translate), 1435 (s.translate = s.isHorizontal() ? d : c); 1436 const p = s.maxTranslate() - s.minTranslate(); 1437 (o = 0 === p ? 0 : (e - s.minTranslate()) / p), 1438 o !== l && s.updateProgress(e), 1439 s.emit("setTranslate", s.translate, t); 1440 }, 1441 minTranslate: function () { 1442 return -this.snapGrid[0]; 1443 }, 1444 maxTranslate: function () { 1445 return -this.snapGrid[this.snapGrid.length - 1]; 1446 }, 1447 translateTo: function (e, t, s, a, i) { 1448 void 0 === e && (e = 0), 1449 void 0 === t && (t = this.params.speed), 1450 void 0 === s && (s = !0), 1451 void 0 === a && (a = !0); 1452 const r = this, 1453 { params: n, wrapperEl: l } = r; 1454 if (r.animating && n.preventInteractionOnTransition) return !1; 1455 const o = r.minTranslate(), 1456 d = r.maxTranslate(); 1457 let c; 1458 if ( 1459 ((c = a && e > o ? o : a && e < d ? d : e), 1460 r.updateProgress(c), 1461 n.cssMode) 1462 ) { 1463 const e = r.isHorizontal(); 1464 if (0 === t) l[e ? "scrollLeft" : "scrollTop"] = -c; 1465 else { 1466 if (!r.support.smoothScroll) 1467 return ( 1468 w({ swiper: r, targetPosition: -c, side: e ? "left" : "top" }), !0 1469 ); 1470 l.scrollTo({ [e ? "left" : "top"]: -c, behavior: "smooth" }); 1471 } 1472 return !0; 1473 } 1474 return ( 1475 0 === t 1476 ? (r.setTransition(0), 1477 r.setTranslate(c), 1478 s && 1479 (r.emit("beforeTransitionStart", t, i), r.emit("transitionEnd"))) 1480 : (r.setTransition(t), 1481 r.setTranslate(c), 1482 s && 1483 (r.emit("beforeTransitionStart", t, i), 1484 r.emit("transitionStart")), 1485 r.animating || 1486 ((r.animating = !0), 1487 r.onTranslateToWrapperTransitionEnd || 1488 (r.onTranslateToWrapperTransitionEnd = function (e) { 1489 r && 1490 !r.destroyed && 1491 e.target === this && 1492 (r.$wrapperEl[0].removeEventListener( 1493 "transitionend", 1494 r.onTranslateToWrapperTransitionEnd 1495 ), 1496 r.$wrapperEl[0].removeEventListener( 1497 "webkitTransitionEnd", 1498 r.onTranslateToWrapperTransitionEnd 1499 ), 1500 (r.onTranslateToWrapperTransitionEnd = null),
1501 delete r.onTranslateToWrapperTransitionEnd, 1502 s && r.emit("transitionEnd")); 1503 }), 1504 r.$wrapperEl[0].addEventListener( 1505 "transitionend", 1506 r.onTranslateToWrapperTransitionEnd 1507 ), 1508 r.$wrapperEl[0].addEventListener( 1509 "webkitTransitionEnd", 1510 r.onTranslateToWrapperTransitionEnd 1511 ))), 1512 !0 1513 ); 1514 }, 1515 }; 1516 function P(e) { 1517 let { swiper: t, runCallbacks: s, direction: a, step: i } = e; 1518 const { activeIndex: r, previousIndex: n } = t; 1519 let l = a; 1520 if ( 1521 (l || (l = r > n ? "next" : r < n ? "prev" : "reset"), 1522 t.emit(`transition${i}`), 1523 s && r !== n) 1524 ) { 1525 if ("reset" === l) return void t.emit(`slideResetTransition${i}`); 1526 t.emit(`slideChangeTransition${i}`), 1527 "next" === l 1528 ? t.emit(`slideNextTransition${i}`) 1529 : t.emit(`slidePrevTransition${i}`); 1530 } 1531 } 1532 var k = { 1533 slideTo: function (e, t, s, a, i) { 1534 if ( 1535 (void 0 === e && (e = 0), 1536 void 0 === t && (t = this.params.speed), 1537 void 0 === s && (s = !0), 1538 "number" != typeof e && "string" != typeof e) 1539 ) 1540 throw new Error( 1541 `The 'index' argument cannot have type other than 'number' or 'string'. [${typeof e}] given.` 1542 ); 1543 if ("string" == typeof e) { 1544 const t = parseInt(e, 10); 1545 if (!isFinite(t)) 1546 throw new Error( 1547 `The passed-in 'index' (string) couldn't be converted to 'number'. [${e}] given.` 1548 ); 1549 e = t; 1550 } 1551 const r = this; 1552 let n = e; 1553 n < 0 && (n = 0); 1554 const { 1555 params: l, 1556 snapGrid: o, 1557 slidesGrid: d, 1558 previousIndex: c, 1559 activeIndex: p, 1560 rtlTranslate: u, 1561 wrapperEl: h, 1562 enabled: m, 1563 } = r; 1564 if ((r.animating && l.preventInteractionOnTransition) || (!m && !a && !i)) 1565 return !1; 1566 const f = Math.min(r.params.slidesPerGroupSkip, n); 1567 let g = f + Math.floor((n - f) / r.params.slidesPerGroup); 1568 g >= o.length && (g = o.length - 1); 1569 const v = -o[g]; 1570 if (l.normalizeSlideIndex) 1571 for (let e = 0; e < d.length; e += 1) { 1572 const t = -Math.floor(100 * v), 1573 s = Math.floor(100 * d[e]), 1574 a = Math.floor(100 * d[e + 1]); 1575 void 0 !== d[e + 1] 1576 ? t >= s && t < a - (a - s) / 2 1577 ? (n = e) 1578 : t >= s && t < a && (n = e + 1) 1579 : t >= s && (n = e); 1580 } 1581 if (r.initialized && n !== p) { 1582 if (!r.allowSlideNext && v < r.translate && v < r.minTranslate()) 1583 return !1; 1584 if ( 1585 !r.allowSlidePrev && 1586 v > r.translate && 1587 v > r.maxTranslate() && 1588 (p || 0) !== n 1589 ) 1590 return !1; 1591 } 1592 let b; 1593 if ( 1594 (n !== (c || 0) && s && r.emit("beforeSlideChangeStart"), 1595 r.updateProgress(v), 1596 (b = n > p ? "next" : n < p ? "prev" : "reset"), 1597 (u && -v === r.translate) || (!u && v === r.translate)) 1598 ) 1599 return ( 1600 r.updateActiveIndex(n), 1601 l.autoHeight && r.updateAutoHeight(), 1602 r.updateSlidesClasses(), 1603 "slide" !== l.effect && r.setTranslate(v), 1604 "reset" !== b && (r.transitionStart(s, b), r.transitionEnd(s, b)), 1605 !1 1606 ); 1607 if (l.cssMode) { 1608 const e = r.isHorizontal(), 1609 s = u ? v : -v; 1610 if (0 === t) { 1611 const t = r.virtual && r.params.virtual.enabled; 1612 t && 1613 ((r.wrapperEl.style.scrollSnapType = "none"), 1614 (r._immediateVirtual = !0)), 1615 (h[e ? "scrollLeft" : "scrollTop"] = s), 1616 t && 1617 requestAnimationFrame(() => { 1618 (r.wrapperEl.style.scrollSnapType = ""), 1619 (r._swiperImmediateVirtual = !1); 1620 }); 1621 } else { 1622 if (!r.support.smoothScroll) 1623 return ( 1624 w({ swiper: r, targetPosition: s, side: e ? "left" : "top" }), !0 1625 ); 1626 h.scrollTo({ [e ? "left" : "top"]: s, behavior: "smooth" }); 1627 } 1628 return !0; 1629 } 1630 return ( 1631 r.setTransition(t), 1632 r.setTranslate(v), 1633 r.updateActiveIndex(n), 1634 r.updateSlidesClasses(), 1635 r.emit("beforeTransitionStart", t, a), 1636 r.transitionStart(s, b), 1637 0 === t 1638 ? r.transitionEnd(s, b) 1639 : r.animating || 1640 ((r.animating = !0), 1641 r.onSlideToWrapperTransitionEnd || 1642 (r.onSlideToWrapperTransitionEnd = function (e) { 1643 r && 1644 !r.destroyed && 1645 e.target === this && 1646 (r.$wrapperEl[0].removeEventListener( 1647 "transitionend", 1648 r.onSlideToWrapperTransitionEnd 1649 ), 1650 r.$wrapperEl[0].removeEventListener( 1651 "webkitTransitionEnd", 1652 r.onSlideToWrapperTransitionEnd 1653 ), 1654 (r.onSlideToWrapperTransitionEnd = null),
1655 delete r.onSlideToWrapperTransitionEnd, 1656 r.transitionEnd(s, b)); 1657 }), 1658 r.$wrapperEl[0].addEventListener( 1659 "transitionend", 1660 r.onSlideToWrapperTransitionEnd 1661 ), 1662 r.$wrapperEl[0].addEventListener( 1663 "webkitTransitionEnd", 1664 r.onSlideToWrapperTransitionEnd 1665 )), 1666 !0 1667 ); 1668 }, 1669 slideToLoop: function (e, t, s, a) { 1670 if ( 1671 (void 0 === e && (e = 0), 1672 void 0 === t && (t = this.params.speed), 1673 void 0 === s && (s = !0), 1674 "string" == typeof e) 1675 ) { 1676 const t = parseInt(e, 10); 1677 if (!isFinite(t)) 1678 throw new Error( 1679 `The passed-in 'index' (string) couldn't be converted to 'number'. [${e}] given.` 1680 ); 1681 e = t; 1682 } 1683 const i = this; 1684 let r = e; 1685 return i.params.loop && (r += i.loopedSlides), i.slideTo(r, t, s, a); 1686 }, 1687 slideNext: function (e, t, s) { 1688 void 0 === e && (e = this.params.speed), void 0 === t && (t = !0); 1689 const a = this, 1690 { animating: i, enabled: r, params: n } = a; 1691 if (!r) return a; 1692 let l = n.slidesPerGroup; 1693 "auto" === n.slidesPerView && 1694 1 === n.slidesPerGroup && 1695 n.slidesPerGroupAuto && 1696 (l = Math.max(a.slidesPerViewDynamic("current", !0), 1)); 1697 const o = a.activeIndex < n.slidesPerGroupSkip ? 1 : l; 1698 if (n.loop) { 1699 if (i && n.loopPreventsSlide) return !1; 1700 a.loopFix(), (a._clientLeft = a.$wrapperEl[0].clientLeft); 1701 } 1702 return n.rewind && a.isEnd 1703 ? a.slideTo(0, e, t, s) 1704 : a.slideTo(a.activeIndex + o, e, t, s); 1705 }, 1706 slidePrev: function (e, t, s) { 1707 void 0 === e && (e = this.params.speed), void 0 === t && (t = !0); 1708 const a = this, 1709 { 1710 params: i, 1711 animating: r, 1712 snapGrid: n, 1713 slidesGrid: l, 1714 rtlTranslate: o, 1715 enabled: d, 1716 } = a; 1717 if (!d) return a; 1718 if (i.loop) { 1719 if (r && i.loopPreventsSlide) return !1; 1720 a.loopFix(), (a._clientLeft = a.$wrapperEl[0].clientLeft); 1721 } 1722 function c(e) { 1723 return e < 0 ? -Math.floor(Math.abs(e)) : Math.floor(e); 1724 } 1725 const p = c(o ? a.translate : -a.translate), 1726 u = n.map((e) => c(e)); 1727 let h = n[u.indexOf(p) - 1]; 1728 if (void 0 === h && i.cssMode) { 1729 let e; 1730 n.forEach((t, s) => { 1731 p >= t && (e = s); 1732 }), 1733 void 0 !== e && (h = n[e > 0 ? e - 1 : e]); 1734 } 1735 let m = 0; 1736 if ( 1737 (void 0 !== h && 1738 ((m = l.indexOf(h)), 1739 m < 0 && (m = a.activeIndex - 1), 1740 "auto" === i.slidesPerView && 1741 1 === i.slidesPerGroup && 1742 i.slidesPerGroupAuto && 1743 ((m = m - a.slidesPerViewDynamic("previous", !0) + 1), 1744 (m = Math.max(m, 0)))), 1745 i.rewind && a.isBeginning) 1746 ) { 1747 const i = 1748 a.params.virtual && a.params.virtual.enabled && a.virtual 1749 ? a.virtual.slides.length - 1 1750 : a.slides.length - 1; 1751 return a.slideTo(i, e, t, s); 1752 } 1753 return a.slideTo(m, e, t, s); 1754 }, 1755 slideReset: function (e, t, s) { 1756 return ( 1757 void 0 === e && (e = this.params.speed), 1758 void 0 === t && (t = !0), 1759 this.slideTo(this.activeIndex, e, t, s) 1760 ); 1761 }, 1762 slideToClosest: function (e, t, s, a) { 1763 void 0 === e && (e = this.params.speed), 1764 void 0 === t && (t = !0), 1765 void 0 === a && (a = 0.5); 1766 const i = this; 1767 let r = i.activeIndex; 1768 const n = Math.min(i.params.slidesPerGroupSkip, r), 1769 l = n + Math.floor((r - n) / i.params.slidesPerGroup), 1770 o = i.rtlTranslate ? i.translate : -i.translate; 1771 if (o >= i.snapGrid[l]) { 1772 const e = i.snapGrid[l]; 1773 o - e > (i.snapGrid[l + 1] - e) * a && (r += i.params.slidesPerGroup); 1774 } else { 1775 const e = i.snapGrid[l - 1]; 1776 o - e <= (i.snapGrid[l] - e) * a && (r -= i.params.slidesPerGroup); 1777 } 1778 return ( 1779 (r = Math.max(r, 0)), 1780 (r = Math.min(r, i.slidesGrid.length - 1)), 1781 i.slideTo(r, e, t, s) 1782 ); 1783 }, 1784 slideToClickedSlide: function () { 1785 const e = this, 1786 { params: t, $wrapperEl: s } = e, 1787 a = 1788 "auto" === t.slidesPerView 1789 ? e.slidesPerViewDynamic() 1790 : t.slidesPerView; 1791 let i, 1792 r = e.clickedIndex; 1793 if (t.loop) { 1794 if (e.animating) return; 1795 (i = parseInt(d(e.clickedSlide).attr("data-swiper-slide-index"), 10)), 1796 t.centeredSlides 1797 ? r < e.loopedSlides - a / 2 || 1798 r > e.slides.length - e.loopedSlides + a / 2 1799 ? (e.loopFix(), 1800 (r = s 1801 .children( 1802 `.${t.slideClass}[data-swiper-slide-index="${i}"]:not(.${t.slideDuplicateClass})` 1803 ) 1804 .eq(0) 1805 .index()), 1806 p(() => { 1807 e.slideTo(r); 1808 })) 1809 : e.slideTo(r) 1810 : r > e.slides.length - a 1811 ? (e.loopFix(), 1812 (r = s 1813 .children( 1814 `.${t.slideClass}[data-swiper-slide-index="${i}"]:not(.${t.slideDuplicateClass})` 1815 ) 1816 .eq(0) 1817 .index()), 1818 p(() => { 1819 e.slideTo(r); 1820 })) 1821 : e.slideTo(r); 1822 } else e.slideTo(r); 1823 }, 1824 }; 1825 var z = { 1826 loopCreate: function () { 1827 const e = this, 1828 t = a(), 1829 { params: s, $wrapperEl: i } = e, 1830 r = i.children().length > 0 ? d(i.children()[0].parentNode) : i; 1831 r.children(`.${s.slideClass}.${s.slideDuplicateClass}`).remove(); 1832 let n = r.children(`.${s.slideClass}`); 1833 if (s.loopFillGroupWithBlank) { 1834 const e = s.slidesPerGroup - (n.length % s.slidesPerGroup); 1835 if (e !== s.slidesPerGroup) { 1836 for (let a = 0; a < e; a += 1) { 1837 const e = d(t.createElement("div")).addClass( 1838 `${s.slideClass} ${s.slideBlankClass}` 1839 ); 1840 r.append(e); 1841 } 1842 n = r.children(`.${s.slideClass}`); 1843 } 1844 } 1845 "auto" !== s.slidesPerView || 1846 s.loopedSlides || 1847 (s.loopedSlides = n.length), 1848 (e.loopedSlides = Math.ceil( 1849 parseFloat(s.loopedSlides || s.slidesPerView, 10) 1850 )), 1851 (e.loopedSlides += s.loopAdditionalSlides), 1852 e.loopedSlides > n.length && 1853 e.params.loopedSlidesLimit && 1854 (e.loopedSlides = n.length); 1855 const l = [], 1856 o = []; 1857 n.each((e, t) => { 1858 d(e).attr("data-swiper-slide-index", t); 1859 }); 1860 for (let t = 0; t < e.loopedSlides; t += 1) { 1861 const e = t - Math.floor(t / n.length) * n.length; 1862 o.push(n.eq(e)[0]), l.unshift(n.eq(n.length - e - 1)[0]); 1863 } 1864 for (let e = 0; e < o.length; e += 1) 1865 r.append(d(o[e].cloneNode(!0)).addClass(s.slideDuplicateClass)); 1866 for (let e = l.length - 1; e >= 0; e -= 1) 1867 r.prepend(d(l[e].cloneNode(!0)).addClass(s.slideDuplicateClass)); 1868 }, 1869 loopFix: function () { 1870 const e = this; 1871 e.emit("beforeLoopFix"); 1872 const { 1873 activeIndex: t, 1874 slides: s, 1875 loopedSlides: a, 1876 allowSlidePrev: i, 1877 allowSlideNext: r, 1878 snapGrid: n, 1879 rtlTranslate: l, 1880 } = e; 1881 let o; 1882 (e.allowSlidePrev = !0), (e.allowSlideNext = !0); 1883 const d = -n[t] - e.getTranslate(); 1884 if (t < a) {
1885 (o = s.length - 3 * a + t), (o += a); 1886 e.slideTo(o, 0, !1, !0) && 1887 0 !== d && 1888 e.setTranslate((l ? -e.translate : e.translate) - d); 1889 } else if (t >= s.length - a) { 1890 (o = -s.length + t + a), (o += a); 1891 e.slideTo(o, 0, !1, !0) && 1892 0 !== d && 1893 e.setTranslate((l ? -e.translate : e.translate) - d); 1894 } 1895 (e.allowSlidePrev = i), (e.allowSlideNext = r), e.emit("loopFix"); 1896 }, 1897 loopDestroy: function () { 1898 const { $wrapperEl: e, params: t, slides: s } = this; 1899 e 1900 .children( 1901 `.${t.slideClass}.${t.slideDuplicateClass},.${t.slideClass}.${t.slideBlankClass}` 1902 ) 1903 .remove(), 1904 s.removeAttr("data-swiper-slide-index"); 1905 }, 1906 }; 1907 function L(e) { 1908 const t = this, 1909 s = a(), 1910 i = r(), 1911 n = t.touchEventsData, 1912 { params: l, touches: o, enabled: c } = t; 1913 if (!c) return; 1914 if (t.animating && l.preventInteractionOnTransition) return; 1915 !t.animating && l.cssMode && l.loop && t.loopFix(); 1916 let p = e; 1917 p.originalEvent && (p = p.originalEvent); 1918 let h = d(p.target); 1919 if ("wrapper" === l.touchEventsTarget && !h.closest(t.wrapperEl).length) 1920 return; 1921 if ( 1922 ((n.isTouchEvent = "touchstart" === p.type), 1923 !n.isTouchEvent && "which" in p && 3 === p.which) 1924 ) 1925 return; 1926 if (!n.isTouchEvent && "button" in p && p.button > 0) return; 1927 if (n.isTouched && n.isMoved) return; 1928 const m = !!l.noSwipingClass && "" !== l.noSwipingClass, 1929 f = e.composedPath ? e.composedPath() : e.path; 1930 m && p.target && p.target.shadowRoot && f && (h = d(f[0])); 1931 const g = l.noSwipingSelector 1932 ? l.noSwipingSelector 1933 : `.${l.noSwipingClass}`, 1934 v = !(!p.target || !p.target.shadowRoot); 1935 if ( 1936 l.noSwiping && 1937 (v 1938 ? (function (e, t) { 1939 return ( 1940 void 0 === t && (t = this), 1941 (function t(s) { 1942 if (!s || s === a() || s === r()) return null; 1943 s.assignedSlot && (s = s.assignedSlot); 1944 const i = s.closest(e); 1945 return i || s.getRootNode ? i || t(s.getRootNode().host) : null; 1946 })(t) 1947 ); 1948 })(g, h[0]) 1949 : h.closest(g)[0]) 1950 ) 1951 return void (t.allowClick = !0); 1952 if (l.swipeHandler && !h.closest(l.swipeHandler)[0]) return; 1953 (o.currentX = "touchstart" === p.type ? p.targetTouches[0].pageX : p.pageX), 1954 (o.currentY = 1955 "touchstart" === p.type ? p.targetTouches[0].pageY : p.pageY); 1956 const w = o.currentX, 1957 b = o.currentY, 1958 x = l.edgeSwipeDetection || l.iOSEdgeSwipeDetection, 1959 y = l.edgeSwipeThreshold || l.iOSEdgeSwipeThreshold; 1960 if (x && (w <= y || w >= i.innerWidth - y)) { 1961 if ("prevent" !== x) return; 1962 e.preventDefault(); 1963 } 1964 if ( 1965 (Object.assign(n, { 1966 isTouched: !0, 1967 isMoved: !1, 1968 allowTouchCallbacks: !0, 1969 isScrolling: void 0, 1970 startMoving: void 0, 1971 }), 1972 (o.startX = w), 1973 (o.startY = b), 1974 (n.touchStartTime = u()), 1975 (t.allowClick = !0), 1976 t.updateSize(), 1977 (t.swipeDirection = void 0), 1978 l.threshold > 0 && (n.allowThresholdMove = !1), 1979 "touchstart" !== p.type) 1980 ) { 1981 let e = !0; 1982 h.is(n.focusableElements) && 1983 ((e = !1), "SELECT" === h[0].nodeName && (n.isTouched = !1)), 1984 s.activeElement && 1985 d(s.activeElement).is(n.focusableElements) && 1986 s.activeElement !== h[0] && 1987 s.activeElement.blur(); 1988 const a = e && t.allowTouchMove && l.touchStartPreventDefault; 1989 (!l.touchStartForcePreventDefault && !a) || 1990 h[0].isContentEditable || 1991 p.preventDefault(); 1992 } 1993 t.params.freeMode && 1994 t.params.freeMode.enabled && 1995 t.freeMode && 1996 t.animating && 1997 !l.cssMode && 1998 t.freeMode.onTouchStart(), 1999 t.emit("touchStart", p); 2000 } 2001 function O(e) { 2002 const t = a(), 2003 s = this, 2004 i = s.touchEventsData, 2005 { params: r, touches: n, rtlTranslate: l, enabled: o } = s; 2006 if (!o) return; 2007 let c = e; 2008 if ((c.originalEvent && (c = c.originalEvent), !i.isTouched)) 2009 return void ( 2010 i.startMoving && 2011 i.isScrolling && 2012 s.emit("touchMoveOpposite", c) 2013 ); 2014 if (i.isTouchEvent && "touchmove" !== c.type) return; 2015 const p = 2016 "touchmove" === c.type && 2017 c.targetTouches && 2018 (c.targetTouches[0] || c.changedTouches[0]), 2019 h = "touchmove" === c.type ? p.pageX : c.pageX, 2020 m = "touchmove" === c.type ? p.pageY : c.pageY; 2021 if (c.preventedByNestedSwiper) return (n.startX = h), void (n.startY = m); 2022 if (!s.allowTouchMove) 2023 return ( 2024 d(c.target).is(i.focusableElements) || (s.allowClick = !1), 2025 void ( 2026 i.isTouched && 2027 (Object.assign(n, { startX: h, startY: m, currentX: h, currentY: m }), 2028 (i.touchStartTime = u())) 2029 ) 2030 ); 2031 if (i.isTouchEvent && r.touchReleaseOnEdges && !r.loop) 2032 if (s.isVertical()) { 2033 if ( 2034 (m < n.startY && s.translate <= s.maxTranslate()) || 2035 (m > n.startY && s.translate >= s.minTranslate()) 2036 ) 2037 return (i.isTouched = !1), void (i.isMoved = !1); 2038 } else if ( 2039 (h < n.startX && s.translate <= s.maxTranslate()) || 2040 (h > n.startX && s.translate >= s.minTranslate()) 2041 ) 2042 return; 2043 if ( 2044 i.isTouchEvent && 2045 t.activeElement && 2046 c.target === t.activeElement && 2047 d(c.target).is(i.focusableElements) 2048 ) 2049 return (i.isMoved = !0), void (s.allowClick = !1); 2050 if ( 2051 (i.allowTouchCallbacks && s.emit("touchMove", c), 2052 c.targetTouches && c.targetTouches.length > 1) 2053 ) 2054 return; 2055 (n.currentX = h), (n.currentY = m); 2056 const f = n.currentX - n.startX, 2057 g = n.currentY - n.startY; 2058 if (s.params.threshold && Math.sqrt(f ** 2 + g ** 2) < s.params.threshold) 2059 return; 2060 if (void 0 === i.isScrolling) { 2061 let e; 2062 (s.isHorizontal() && n.currentY === n.startY) || 2063 (s.isVertical() && n.currentX === n.startX) 2064 ? (i.isScrolling = !1) 2065 : f * f + g * g >= 25 && 2066 ((e = (180 * Math.atan2(Math.abs(g), Math.abs(f))) / Math.PI), 2067 (i.isScrolling = s.isHorizontal() 2068 ? e > r.touchAngle 2069 : 90 - e > r.touchAngle)); 2070 } 2071 if ( 2072 (i.isScrolling && s.emit("touchMoveOpposite", c), 2073 void 0 === i.startMoving && 2074 ((n.currentX === n.startX && n.currentY === n.startY) || 2075 (i.startMoving = !0)), 2076 i.isScrolling) 2077 ) 2078 return void (i.isTouched = !1); 2079 if (!i.startMoving) return; 2080 (s.allowClick = !1), 2081 !r.cssMode && c.cancelable && c.preventDefault(), 2082 r.touchMoveStopPropagation && !r.nested && c.stopPropagation(), 2083 i.isMoved || 2084 (r.loop && !r.cssMode && s.loopFix(), 2085 (i.startTranslate = s.getTranslate()), 2086 s.setTransition(0), 2087 s.animating && 2088 s.$wrapperEl.trigger("webkitTransitionEnd transitionend"), 2089 (i.allowMomentumBounce = !1), 2090 !r.grabCursor || 2091 (!0 !== s.allowSlideNext && !0 !== s.allowSlidePrev) || 2092 s.setGrabCursor(!0), 2093 s.emit("sliderFirstMove", c)), 2094 s.emit("sliderMove", c), 2095 (i.isMoved = !0); 2096 let v = s.isHorizontal() ? f : g; 2097 (n.diff = v), 2098 (v *= r.touchRatio), 2099 l && (v = -v), 2100 (s.swipeDirection = v > 0 ? "prev" : "next"), 2101 (i.currentTranslate = v + i.startTranslate); 2102 let w = !0, 2103 b = r.resistanceRatio; 2104 if ( 2105 (r.touchReleaseOnEdges && (b = 0), 2106 v > 0 && i.currentTranslate > s.minTranslate() 2107 ? ((w = !1), 2108 r.resistance && 2109 (i.currentTranslate = 2110 s.minTranslate() - 2111 1 + 2112 (-s.minTranslate() + i.startTranslate + v) ** b)) 2113 : v < 0 && 2114 i.currentTranslate < s.maxTranslate() && 2115 ((w = !1), 2116 r.resistance && 2117 (i.currentTranslate = 2118 s.maxTranslate() + 2119 1 - 2120 (s.maxTranslate() - i.startTranslate - v) ** b)), 2121 w && (c.preventedByNestedSwiper = !0), 2122 !s.allowSlideNext && 2123 "next" === s.swipeDirection && 2124 i.currentTranslate < i.startTranslate && 2125 (i.currentTranslate = i.startTranslate), 2126 !s.allowSlidePrev && 2127 "prev" === s.swipeDirection && 2128 i.currentTranslate > i.startTranslate && 2129 (i.currentTranslate = i.startTranslate), 2130 s.allowSlidePrev || 2131 s.allowSlideNext || 2132 (i.currentTranslate = i.startTranslate), 2133 r.threshold > 0) 2134 ) { 2135 if (!(Math.abs(v) > r.threshold || i.allowThresholdMove)) 2136 return void (i.currentTranslate = i.startTranslate); 2137 if (!i.allowThresholdMove) 2138 return ( 2139 (i.allowThresholdMove = !0), 2140 (n.startX = n.currentX), 2141 (n.startY = n.currentY), 2142 (i.currentTranslate = i.startTranslate), 2143 void (n.diff = s.isHorizontal() 2144 ? n.currentX - n.startX 2145 : n.currentY - n.startY) 2146 ); 2147 } 2148 r.followFinger && 2149 !r.cssMode && 2150 (((r.freeMode && r.freeMode.enabled && s.freeMode) || 2151 r.watchSlidesProgress) && 2152 (s.updateActiveIndex(), s.updateSlidesClasses()), 2153 s.params.freeMode && 2154 r.freeMode.enabled && 2155 s.freeMode && 2156 s.freeMode.onTouchMove(), 2157 s.updateProgress(i.currentTranslate), 2158 s.setTranslate(i.currentTranslate)); 2159 } 2160 function I(e) { 2161 const t = this, 2162 s = t.touchEventsData, 2163 { params: a, touches: i, rtlTranslate: r, slidesGrid: n, enabled: l } = t; 2164 if (!l) return; 2165 let o = e; 2166 if ( 2167 (o.originalEvent && (o = o.originalEvent), 2168 s.allowTouchCallbacks && t.emit("touchEnd", o), 2169 (s.allowTouchCallbacks = !1), 2170 !s.isTouched) 2171 ) 2172 return ( 2173 s.isMoved && a.grabCursor && t.setGrabCursor(!1), 2174 (s.isMoved = !1), 2175 void (s.startMoving = !1) 2176 ); 2177 a.grabCursor && 2178 s.isMoved && 2179 s.isTouched && 2180 (!0 === t.allowSlideNext || !0 === t.allowSlidePrev) && 2181 t.setGrabCursor(!1); 2182 const d = u(), 2183 c = d - s.touchStartTime; 2184 if (t.allowClick) {
2185 const e = o.path || (o.composedPath && o.composedPath()); 2186 t.updateClickedSlide((e && e[0]) || o.target), 2187 t.emit("tap click", o), 2188 c < 300 && 2189 d - s.lastClickTime < 300 && 2190 t.emit("doubleTap doubleClick", o); 2191 } 2192 if ( 2193 ((s.lastClickTime = u()), 2194 p(() => { 2195 t.destroyed || (t.allowClick = !0); 2196 }), 2197 !s.isTouched || 2198 !s.isMoved || 2199 !t.swipeDirection || 2200 0 === i.diff || 2201 s.currentTranslate === s.startTranslate) 2202 ) 2203 return (s.isTouched = !1), (s.isMoved = !1), void (s.startMoving = !1); 2204 let h; 2205 if ( 2206 ((s.isTouched = !1), 2207 (s.isMoved = !1), 2208 (s.startMoving = !1), 2209 (h = a.followFinger 2210 ? r 2211 ? t.translate 2212 : -t.translate 2213 : -s.currentTranslate), 2214 a.cssMode) 2215 ) 2216 return; 2217 if (t.params.freeMode && a.freeMode.enabled) 2218 return void t.freeMode.onTouchEnd({ currentPos: h }); 2219 let m = 0, 2220 f = t.slidesSizesGrid[0]; 2221 for ( 2222 let e = 0; 2223 e < n.length; 2224 e += e < a.slidesPerGroupSkip ? 1 : a.slidesPerGroup 2225 ) { 2226 const t = e < a.slidesPerGroupSkip - 1 ? 1 : a.slidesPerGroup; 2227 void 0 !== n[e + t] 2228 ? h >= n[e] && h < n[e + t] && ((m = e), (f = n[e + t] - n[e])) 2229 : h >= n[e] && ((m = e), (f = n[n.length - 1] - n[n.length - 2])); 2230 } 2231 let g = null, 2232 v = null; 2233 a.rewind && 2234 (t.isBeginning 2235 ? (v = 2236 t.params.virtual && t.params.virtual.enabled && t.virtual 2237 ? t.virtual.slides.length - 1 2238 : t.slides.length - 1) 2239 : t.isEnd && (g = 0)); 2240 const w = (h - n[m]) / f, 2241 b = m < a.slidesPerGroupSkip - 1 ? 1 : a.slidesPerGroup; 2242 if (c > a.longSwipesMs) { 2243 if (!a.longSwipes) return void t.slideTo(t.activeIndex); 2244 "next" === t.swipeDirection && 2245 (w >= a.longSwipesRatio 2246 ? t.slideTo(a.rewind && t.isEnd ? g : m + b) 2247 : t.slideTo(m)), 2248 "prev" === t.swipeDirection && 2249 (w > 1 - a.longSwipesRatio 2250 ? t.slideTo(m + b) 2251 : null !== v && w < 0 && Math.abs(w) > a.longSwipesRatio 2252 ? t.slideTo(v) 2253 : t.slideTo(m)); 2254 } else { 2255 if (!a.shortSwipes) return void t.slideTo(t.activeIndex); 2256 t.navigation && 2257 (o.target === t.navigation.nextEl || o.target === t.navigation.prevEl) 2258 ? o.target === t.navigation.nextEl 2259 ? t.slideTo(m + b) 2260 : t.slideTo(m) 2261 : ("next" === t.swipeDirection && t.slideTo(null !== g ? g : m + b), 2262 "prev" === t.swipeDirection && t.slideTo(null !== v ? v : m)); 2263 } 2264 } 2265 function A() { 2266 const e = this, 2267 { params: t, el: s } = e; 2268 if (s && 0 === s.offsetWidth) return; 2269 t.breakpoints && e.setBreakpoint(); 2270 const { allowSlideNext: a, allowSlidePrev: i, snapGrid: r } = e; 2271 (e.allowSlideNext = !0), 2272 (e.allowSlidePrev = !0), 2273 e.updateSize(), 2274 e.updateSlides(), 2275 e.updateSlidesClasses(), 2276 ("auto" === t.slidesPerView || t.slidesPerView > 1) && 2277 e.isEnd && 2278 !e.isBeginning && 2279 !e.params.centeredSlides 2280 ? e.slideTo(e.slides.length - 1, 0, !1, !0) 2281 : e.slideTo(e.activeIndex, 0, !1, !0), 2282 e.autoplay && e.autoplay.running && e.autoplay.paused && e.autoplay.run(), 2283 (e.allowSlidePrev = i), 2284 (e.allowSlideNext = a), 2285 e.params.watchOverflow && r !== e.snapGrid && e.checkOverflow(); 2286 } 2287 function D(e) { 2288 const t = this; 2289 t.enabled && 2290 (t.allowClick || 2291 (t.params.preventClicks && e.preventDefault(), 2292 t.params.preventClicksPropagation && 2293 t.animating && 2294 (e.stopPropagation(), e.stopImmediatePropagation()))); 2295 } 2296 function G() { 2297 const e = this, 2298 { wrapperEl: t, rtlTranslate: s, enabled: a } = e; 2299 if (!a) return; 2300 let i; 2301 (e.previousTranslate = e.translate), 2302 e.isHorizontal() 2303 ? (e.translate = -t.scrollLeft) 2304 : (e.translate = -t.scrollTop), 2305 0 === e.translate && (e.translate = 0), 2306 e.updateActiveIndex(), 2307 e.updateSlidesClasses(); 2308 const r = e.maxTranslate() - e.minTranslate(); 2309 (i = 0 === r ? 0 : (e.translate - e.minTranslate()) / r), 2310 i !== e.progress && e.updateProgress(s ? -e.translate : e.translate), 2311 e.emit("setTranslate", e.translate, !1); 2312 } 2313 let N = !1; 2314 function B() {} 2315 const H = (e, t) => { 2316 const s = a(), 2317 { 2318 params: i, 2319 touchEvents: r, 2320 el: n, 2321 wrapperEl: l, 2322 device: o, 2323 support: d, 2324 } = e, 2325 c = !!i.nested, 2326 p = "on" === t ? "addEventListener" : "removeEventListener", 2327 u = t; 2328 if (d.touch) { 2329 const t = !( 2330 "touchstart" !== r.start || 2331 !d.passiveListener || 2332 !i.passiveListeners 2333 ) && { passive: !0, capture: !1 }; 2334 n[p](r.start, e.onTouchStart, t), 2335 n[p]( 2336 r.move, 2337 e.onTouchMove, 2338 d.passiveListener ? { passive: !1, capture: c } : c 2339 ), 2340 n[p](r.end, e.onTouchEnd, t), 2341 r.cancel && n[p](r.cancel, e.onTouchEnd, t); 2342 } else 2343 n[p](r.start, e.onTouchStart, !1), 2344 s[p](r.move, e.onTouchMove, c), 2345 s[p](r.end, e.onTouchEnd, !1); 2346 (i.preventClicks || i.preventClicksPropagation) && 2347 n[p]("click", e.onClick, !0), 2348 i.cssMode && l[p]("scroll", e.onScroll), 2349 i.updateOnWindowResize 2350 ? e[u]( 2351 o.ios || o.android 2352 ? "resize orientationchange observerUpdate" 2353 : "resize observerUpdate", 2354 A, 2355 !0 2356 ) 2357 : e[u]("observerUpdate", A, !0); 2358 }; 2359 var X = { 2360 attachEvents: function () { 2361 const e = this, 2362 t = a(), 2363 { params: s, support: i } = e; 2364 (e.onTouchStart = L.bind(e)), 2365 (e.onTouchMove = O.bind(e)), 2366 (e.onTouchEnd = I.bind(e)), 2367 s.cssMode && (e.onScroll = G.bind(e)), 2368 (e.onClick = D.bind(e)), 2369 i.touch && !N && (t.addEventListener("touchstart", B), (N = !0)), 2370 H(e, "on"); 2371 }, 2372 detachEvents: function () { 2373 H(this, "off"); 2374 }, 2375 }; 2376 const Y = (e, t) => e.grid && t.grid && t.grid.rows > 1; 2377 var R = { 2378 addClasses: function () { 2379 const e = this, 2380 { classNames: t, params: s, rtl: a, $el: i, device: r, support: n } = e, 2381 l = (function (e, t) { 2382 const s = []; 2383 return ( 2384 e.forEach((e) => { 2385 "object" == typeof e 2386 ? Object.keys(e).forEach((a) => { 2387 e[a] && s.push(t + a); 2388 }) 2389 : "string" == typeof e && s.push(t + e); 2390 }), 2391 s 2392 ); 2393 })( 2394 [ 2395 "initialized", 2396 s.direction, 2397 { "pointer-events": !n.touch }, 2398 { "free-mode": e.params.freeMode && s.freeMode.enabled }, 2399 { autoheight: s.autoHeight }, 2400 { rtl: a }, 2401 { grid: s.grid && s.grid.rows > 1 }, 2402 { 2403 "grid-column": 2404 s.grid && s.grid.rows > 1 && "column" === s.grid.fill, 2405 }, 2406 { android: r.android }, 2407 { ios: r.ios }, 2408 { "css-mode": s.cssMode }, 2409 { centered: s.cssMode && s.centeredSlides },
2410 { "watch-progress": s.watchSlidesProgress }, 2411 ], 2412 s.containerModifierClass 2413 ); 2414 t.push(...l), i.addClass([...t].join(" ")), e.emitContainerClasses(); 2415 }, 2416 removeClasses: function () { 2417 const { $el: e, classNames: t } = this; 2418 e.removeClass(t.join(" ")), this.emitContainerClasses(); 2419 }, 2420 }; 2421 var W = { 2422 init: !0, 2423 direction: "horizontal", 2424 touchEventsTarget: "wrapper", 2425 initialSlide: 0, 2426 speed: 300, 2427 cssMode: !1, 2428 updateOnWindowResize: !0, 2429 resizeObserver: !0, 2430 nested: !1, 2431 createElements: !1, 2432 enabled: !0, 2433 focusableElements: "input, select, option, textarea, button, video, label", 2434 width: null, 2435 height: null, 2436 preventInteractionOnTransition: !1, 2437 userAgent: null, 2438 url: null, 2439 edgeSwipeDetection: !1, 2440 edgeSwipeThreshold: 20, 2441 autoHeight: !1, 2442 setWrapperSize: !1, 2443 virtualTranslate: !1, 2444 effect: "slide", 2445 breakpoints: void 0, 2446 breakpointsBase: "window", 2447 spaceBetween: 0, 2448 slidesPerView: 1, 2449 slidesPerGroup: 1, 2450 slidesPerGroupSkip: 0, 2451 slidesPerGroupAuto: !1, 2452 centeredSlides: !1, 2453 centeredSlidesBounds: !1, 2454 slidesOffsetBefore: 0, 2455 slidesOffsetAfter: 0, 2456 normalizeSlideIndex: !0, 2457 centerInsufficientSlides: !1, 2458 watchOverflow: !0, 2459 roundLengths: !1, 2460 touchRatio: 1, 2461 touchAngle: 45, 2462 simulateTouch: !0, 2463 shortSwipes: !0, 2464 longSwipes: !0, 2465 longSwipesRatio: 0.5, 2466 longSwipesMs: 300, 2467 followFinger: !0, 2468 allowTouchMove: !0, 2469 threshold: 0, 2470 touchMoveStopPropagation: !1, 2471 touchStartPreventDefault: !0, 2472 touchStartForcePreventDefault: !1, 2473 touchReleaseOnEdges: !1, 2474 uniqueNavElements: !0, 2475 resistance: !0, 2476 resistanceRatio: 0.85, 2477 watchSlidesProgress: !1, 2478 grabCursor: !1, 2479 preventClicks: !0, 2480 preventClicksPropagation: !0, 2481 slideToClickedSlide: !1, 2482 preloadImages: !0, 2483 updateOnImagesReady: !0, 2484 loop: !1, 2485 loopAdditionalSlides: 0, 2486 loopedSlides: null, 2487 loopedSlidesLimit: !0, 2488 loopFillGroupWithBlank: !1, 2489 loopPreventsSlide: !0, 2490 rewind: !1, 2491 allowSlidePrev: !0, 2492 allowSlideNext: !0, 2493 swipeHandler: null, 2494 noSwiping: !0, 2495 noSwipingClass: "swiper-no-swiping", 2496 noSwipingSelector: null, 2497 passiveListeners: !0, 2498 maxBackfaceHiddenSlides: 10, 2499 containerModifierClass: "swiper-", 2500 slideClass: "swiper-slide", 2501 slideBlankClass: "swiper-slide-invisible-blank", 2502 slideActiveClass: "swiper-slide-active", 2503 slideDuplicateActiveClass: "swiper-slide-duplicate-active", 2504 slideVisibleClass: "swiper-slide-visible", 2505 slideDuplicateClass: "swiper-slide-duplicate", 2506 slideNextClass: "swiper-slide-next", 2507 slideDuplicateNextClass: "swiper-slide-duplicate-next", 2508 slidePrevClass: "swiper-slide-prev", 2509 slideDuplicatePrevClass: "swiper-slide-duplicate-prev", 2510 wrapperClass: "swiper-wrapper", 2511 runCallbacksOnInit: !0, 2512 _emitClasses: !1, 2513 }; 2514 function j(e, t) { 2515 return function (s) { 2516 void 0 === s && (s = {}); 2517 const a = Object.keys(s)[0], 2518 i = s[a]; 2519 "object" == typeof i && null !== i 2520 ? (["navigation", "pagination", "scrollbar"].indexOf(a) >= 0 && 2521 !0 === e[a] && 2522 (e[a] = { auto: !0 }), 2523 a in e && "enabled" in i 2524 ? (!0 === e[a] && (e[a] = { enabled: !0 }), 2525 "object" != typeof e[a] || 2526 "enabled" in e[a] || 2527 (e[a].enabled = !0), 2528 e[a] || (e[a] = { enabled: !1 }), 2529 g(t, s)) 2530 : g(t, s)) 2531 : g(t, s); 2532 }; 2533 } 2534 const q = { 2535 eventsEmitter: $, 2536 update: S, 2537 translate: M, 2538 transition: { 2539 setTransition: function (e, t) { 2540 const s = this; 2541 s.params.cssMode || s.$wrapperEl.transition(e), 2542 s.emit("setTransition", e, t); 2543 }, 2544 transitionStart: function (e, t) { 2545 void 0 === e && (e = !0); 2546 const s = this, 2547 { params: a } = s; 2548 a.cssMode || 2549 (a.autoHeight && s.updateAutoHeight(), 2550 P({ swiper: s, runCallbacks: e, direction: t, step: "Start" })); 2551 }, 2552 transitionEnd: function (e, t) { 2553 void 0 === e && (e = !0); 2554 const s = this, 2555 { params: a } = s; 2556 (s.animating = !1), 2557 a.cssMode || 2558 (s.setTransition(0), 2559 P({ swiper: s, runCallbacks: e, direction: t, step: "End" })); 2560 }, 2561 }, 2562 slide: k, 2563 loop: z, 2564 grabCursor: { 2565 setGrabCursor: function (e) { 2566 const t = this; 2567 if ( 2568 t.support.touch || 2569 !t.params.simulateTouch || 2570 (t.params.watchOverflow && t.isLocked) || 2571 t.params.cssMode 2572 ) 2573 return; 2574 const s = 2575 "container" === t.params.touchEventsTarget ? t.el : t.wrapperEl; 2576 (s.style.cursor = "move"), (s.style.cursor = e ? "grabbing" : "grab"); 2577 }, 2578 unsetGrabCursor: function () { 2579 const e = this; 2580 e.support.touch || 2581 (e.params.watchOverflow && e.isLocked) || 2582 e.params.cssMode || 2583 (e[ 2584 "container" === e.params.touchEventsTarget ? "el" : "wrapperEl" 2585 ].style.cursor = ""); 2586 }, 2587 }, 2588 events: X, 2589 breakpoints: { 2590 setBreakpoint: function () { 2591 const e = this, 2592 { 2593 activeIndex: t, 2594 initialized: s, 2595 loopedSlides: a = 0, 2596 params: i, 2597 $el: r, 2598 } = e, 2599 n = i.breakpoints; 2600 if (!n || (n && 0 === Object.keys(n).length)) return;
2601 const l = e.getBreakpoint(n, e.params.breakpointsBase, e.el); 2602 if (!l || e.currentBreakpoint === l) return; 2603 const o = (l in n ? n[l] : void 0) || e.originalParams, 2604 d = Y(e, i), 2605 c = Y(e, o), 2606 p = i.enabled; 2607 d && !c 2608 ? (r.removeClass( 2609 `${i.containerModifierClass}grid ${i.containerModifierClass}grid-column` 2610 ), 2611 e.emitContainerClasses()) 2612 : !d && 2613 c && 2614 (r.addClass(`${i.containerModifierClass}grid`), 2615 ((o.grid.fill && "column" === o.grid.fill) || 2616 (!o.grid.fill && "column" === i.grid.fill)) && 2617 r.addClass(`${i.containerModifierClass}grid-column`), 2618 e.emitContainerClasses()), 2619 ["navigation", "pagination", "scrollbar"].forEach((t) => { 2620 const s = i[t] && i[t].enabled, 2621 a = o[t] && o[t].enabled; 2622 s && !a && e[t].disable(), !s && a && e[t].enable(); 2623 }); 2624 const u = o.direction && o.direction !== i.direction, 2625 h = i.loop && (o.slidesPerView !== i.slidesPerView || u); 2626 u && s && e.changeDirection(), g(e.params, o); 2627 const m = e.params.enabled; 2628 Object.assign(e, { 2629 allowTouchMove: e.params.allowTouchMove, 2630 allowSlideNext: e.params.allowSlideNext, 2631 allowSlidePrev: e.params.allowSlidePrev, 2632 }), 2633 p && !m ? e.disable() : !p && m && e.enable(), 2634 (e.currentBreakpoint = l), 2635 e.emit("_beforeBreakpoint", o), 2636 h && 2637 s && 2638 (e.loopDestroy(), 2639 e.loopCreate(), 2640 e.updateSlides(), 2641 e.slideTo(t - a + e.loopedSlides, 0, !1)), 2642 e.emit("breakpoint", o); 2643 }, 2644 getBreakpoint: function (e, t, s) { 2645 if ((void 0 === t && (t = "window"), !e || ("container" === t && !s))) 2646 return; 2647 let a = !1; 2648 const i = r(), 2649 n = "window" === t ? i.innerHeight : s.clientHeight, 2650 l = Object.keys(e).map((e) => { 2651 if ("string" == typeof e && 0 === e.indexOf("@")) { 2652 const t = parseFloat(e.substr(1)); 2653 return { value: n * t, point: e }; 2654 } 2655 return { value: e, point: e }; 2656 }); 2657 l.sort((e, t) => parseInt(e.value, 10) - parseInt(t.value, 10)); 2658 for (let e = 0; e < l.length; e += 1) { 2659 const { point: r, value: n } = l[e]; 2660 "window" === t 2661 ? i.matchMedia(`(min-width: ${n}px)`).matches && (a = r) 2662 : n <= s.clientWidth && (a = r); 2663 } 2664 return a || "max"; 2665 }, 2666 }, 2667 checkOverflow: { 2668 checkOverflow: function () { 2669 const e = this, 2670 { isLocked: t, params: s } = e, 2671 { slidesOffsetBefore: a } = s; 2672 if (a) { 2673 const t = e.slides.length - 1, 2674 s = e.slidesGrid[t] + e.slidesSizesGrid[t] + 2 * a; 2675 e.isLocked = e.size > s; 2676 } else e.isLocked = 1 === e.snapGrid.length; 2677 !0 === s.allowSlideNext && (e.allowSlideNext = !e.isLocked), 2678 !0 === s.allowSlidePrev && (e.allowSlidePrev = !e.isLocked), 2679 t && t !== e.isLocked && (e.isEnd = !1), 2680 t !== e.isLocked && e.emit(e.isLocked ? "lock" : "unlock"); 2681 }, 2682 }, 2683 classes: R, 2684 images: { 2685 loadImage: function (e, t, s, a, i, n) { 2686 const l = r(); 2687 let o; 2688 function c() { 2689 n && n(); 2690 } 2691 d(e).parent("picture")[0] || (e.complete && i) 2692 ? c() 2693 : t 2694 ? ((o = new l.Image()), 2695 (o.onload = c), 2696 (o.onerror = c), 2697 a && (o.sizes = a), 2698 s && (o.srcset = s), 2699 t && (o.src = t)) 2700 : c(); 2701 }, 2702 preloadImages: function () { 2703 const e = this; 2704 function t() { 2705 null != e && 2706 e && 2707 !e.destroyed && 2708 (void 0 !== e.imagesLoaded && (e.imagesLoaded += 1), 2709 e.imagesLoaded === e.imagesToLoad.length && 2710 (e.params.updateOnImagesReady && e.update(), 2711 e.emit("imagesReady"))); 2712 } 2713 e.imagesToLoad = e.$el.find("img"); 2714 for (let s = 0; s < e.imagesToLoad.length; s += 1) { 2715 const a = e.imagesToLoad[s]; 2716 e.loadImage( 2717 a, 2718 a.currentSrc || a.getAttribute("src"), 2719 a.srcset || a.getAttribute("srcset"), 2720 a.sizes || a.getAttribute("sizes"), 2721 !0, 2722 t 2723 ); 2724 } 2725 }, 2726 }, 2727 }, 2728 _ = {}; 2729 class V { 2730 constructor() { 2731 let e, t; 2732 for (var s = arguments.length, a = new Array(s), i = 0; i < s; i++) 2733 a[i] = arguments[i]; 2734 if ( 2735 (1 === a.length && 2736 a[0].constructor && 2737 "Object" === Object.prototype.toString.call(a[0]).slice(8, -1) 2738 ? (t = a[0]) 2739 : ([e, t] = a), 2740 t || (t = {}), 2741 (t = g({}, t)), 2742 e && !t.el && (t.el = e), 2743 t.el && d(t.el).length > 1) 2744 ) { 2745 const e = []; 2746 return ( 2747 d(t.el).each((s) => { 2748 const a = g({}, t, { el: s }); 2749 e.push(new V(a)); 2750 }), 2751 e 2752 ); 2753 } 2754 const r = this; 2755 (r.__swiper__ = !0), 2756 (r.support = E()), 2757 (r.device = C({ userAgent: t.userAgent })),
2758 (r.browser = T()), 2759 (r.eventsListeners = {}), 2760 (r.eventsAnyListeners = []), 2761 (r.modules = [...r.__modules__]), 2762 t.modules && Array.isArray(t.modules) && r.modules.push(...t.modules); 2763 const n = {}; 2764 r.modules.forEach((e) => { 2765 e({ 2766 swiper: r, 2767 extendParams: j(t, n), 2768 on: r.on.bind(r), 2769 once: r.once.bind(r), 2770 off: r.off.bind(r), 2771 emit: r.emit.bind(r), 2772 }); 2773 }); 2774 const l = g({}, W, n); 2775 return ( 2776 (r.params = g({}, l, _, t)), 2777 (r.originalParams = g({}, r.params)), 2778 (r.passedParams = g({}, t)), 2779 r.params && 2780 r.params.on && 2781 Object.keys(r.params.on).forEach((e) => { 2782 r.on(e, r.params.on[e]); 2783 }), 2784 r.params && r.params.onAny && r.onAny(r.params.onAny), 2785 (r.$ = d), 2786 Object.assign(r, { 2787 enabled: r.params.enabled, 2788 el: e, 2789 classNames: [], 2790 slides: d(), 2791 slidesGrid: [], 2792 snapGrid: [], 2793 slidesSizesGrid: [], 2794 isHorizontal: () => "horizontal" === r.params.direction, 2795 isVertical: () => "vertical" === r.params.direction, 2796 activeIndex: 0, 2797 realIndex: 0, 2798 isBeginning: !0, 2799 isEnd: !1, 2800 translate: 0, 2801 previousTranslate: 0, 2802 progress: 0, 2803 velocity: 0, 2804 animating: !1, 2805 allowSlideNext: r.params.allowSlideNext, 2806 allowSlidePrev: r.params.allowSlidePrev, 2807 touchEvents: (function () { 2808 const e = ["touchstart", "touchmove", "touchend", "touchcancel"], 2809 t = ["pointerdown", "pointermove", "pointerup"]; 2810 return ( 2811 (r.touchEventsTouch = { 2812 start: e[0], 2813 move: e[1], 2814 end: e[2], 2815 cancel: e[3], 2816 }), 2817 (r.touchEventsDesktop = { start: t[0], move: t[1], end: t[2] }), 2818 r.support.touch || !r.params.simulateTouch 2819 ? r.touchEventsTouch 2820 : r.touchEventsDesktop 2821 ); 2822 })(), 2823 touchEventsData: { 2824 isTouched: void 0, 2825 isMoved: void 0, 2826 allowTouchCallbacks: void 0, 2827 touchStartTime: void 0, 2828 isScrolling: void 0, 2829 currentTranslate: void 0, 2830 startTranslate: void 0, 2831 allowThresholdMove: void 0, 2832 focusableElements: r.params.focusableElements, 2833 lastClickTime: u(), 2834 clickTimeout: void 0, 2835 velocities: [], 2836 allowMomentumBounce: void 0, 2837 isTouchEvent: void 0, 2838 startMoving: void 0, 2839 }, 2840 allowClick: !0, 2841 allowTouchMove: r.params.allowTouchMove, 2842 touches: { startX: 0, startY: 0, currentX: 0, currentY: 0, diff: 0 }, 2843 imagesToLoad: [], 2844 imagesLoaded: 0, 2845 }), 2846 r.emit("_swiper"), 2847 r.params.init && r.init(), 2848 r 2849 ); 2850 } 2851 enable() { 2852 const e = this; 2853 e.enabled || 2854 ((e.enabled = !0), 2855 e.params.grabCursor && e.setGrabCursor(), 2856 e.emit("enable")); 2857 } 2858 disable() { 2859 const e = this; 2860 e.enabled && 2861 ((e.enabled = !1), 2862 e.params.grabCursor && e.unsetGrabCursor(), 2863 e.emit("disable")); 2864 } 2865 setProgress(e, t) { 2866 const s = this; 2867 e = Math.min(Math.max(e, 0), 1); 2868 const a = s.minTranslate(), 2869 i = (s.maxTranslate() - a) * e + a; 2870 s.translateTo(i, void 0 === t ? 0 : t), 2871 s.updateActiveIndex(), 2872 s.updateSlidesClasses(); 2873 } 2874 emitContainerClasses() { 2875 const e = this; 2876 if (!e.params._emitClasses || !e.el) return; 2877 const t = e.el.className 2878 .split(" ") 2879 .filter( 2880 (t) => 2881 0 === t.indexOf("swiper") || 2882 0 === t.indexOf(e.params.containerModifierClass) 2883 ); 2884 e.emit("_containerClasses", t.join(" ")); 2885 } 2886 getSlideClasses(e) { 2887 const t = this; 2888 return t.destroyed 2889 ? "" 2890 : e.className 2891 .split(" ") 2892 .filter( 2893 (e) => 2894 0 === e.indexOf("swiper-slide") || 2895 0 === e.indexOf(t.params.slideClass) 2896 ) 2897 .join(" "); 2898 } 2899 emitSlidesClasses() { 2900 const e = this; 2901 if (!e.params._emitClasses || !e.el) return; 2902 const t = []; 2903 e.slides.each((s) => { 2904 const a = e.getSlideClasses(s); 2905 t.push({ slideEl: s, classNames: a }), e.emit("_slideClass", s, a); 2906 }), 2907 e.emit("_slideClasses", t); 2908 } 2909 slidesPerViewDynamic(e, t) { 2910 void 0 === e && (e = "current"), void 0 === t && (t = !1); 2911 const { 2912 params: s, 2913 slides: a, 2914 slidesGrid: i, 2915 slidesSizesGrid: r, 2916 size: n, 2917 activeIndex: l, 2918 } = this; 2919 let o = 1; 2920 if (s.centeredSlides) { 2921 let e, 2922 t = a[l].swiperSlideSize; 2923 for (let s = l + 1; s < a.length; s += 1) 2924 a[s] && 2925 !e && 2926 ((t += a[s].swiperSlideSize), (o += 1), t > n && (e = !0)); 2927 for (let s = l - 1; s >= 0; s -= 1) 2928 a[s] && 2929 !e && 2930 ((t += a[s].swiperSlideSize), (o += 1), t > n && (e = !0)); 2931 } else if ("current" === e) 2932 for (let e = l + 1; e < a.length; e += 1) { 2933 (t ? i[e] + r[e] - i[l] < n : i[e] - i[l] < n) && (o += 1); 2934 } 2935 else 2936 for (let e = l - 1; e >= 0; e -= 1) { 2937 i[l] - i[e] < n && (o += 1); 2938 } 2939 return o; 2940 } 2941 update() { 2942 const e = this; 2943 if (!e || e.destroyed) return; 2944 const { snapGrid: t, params: s } = e; 2945 function a() { 2946 const t = e.rtlTranslate ? -1 * e.translate : e.translate, 2947 s = Math.min(Math.max(t, e.maxTranslate()), e.minTranslate()); 2948 e.setTranslate(s), e.updateActiveIndex(), e.updateSlidesClasses(); 2949 } 2950 let i; 2951 s.breakpoints && e.setBreakpoint(), 2952 e.updateSize(), 2953 e.updateSlides(), 2954 e.updateProgress(), 2955 e.updateSlidesClasses(), 2956 e.params.freeMode && e.params.freeMode.enabled 2957 ? (a(), e.params.autoHeight && e.updateAutoHeight()) 2958 : ((i = 2959 ("auto" === e.params.slidesPerView || 2960 e.params.slidesPerView > 1) && 2961 e.isEnd && 2962 !e.params.centeredSlides 2963 ? e.slideTo(e.slides.length - 1, 0, !1, !0) 2964 : e.slideTo(e.activeIndex, 0, !1, !0)), 2965 i || a()), 2966 s.watchOverflow && t !== e.snapGrid && e.checkOverflow(), 2967 e.emit("update"); 2968 } 2969 changeDirection(e, t) { 2970 void 0 === t && (t = !0); 2971 const s = this, 2972 a = s.params.direction; 2973 return ( 2974 e || (e = "horizontal" === a ? "vertical" : "horizontal"), 2975 e === a || 2976 ("horizontal" !== e && "vertical" !== e) || 2977 (s.$el 2978 .removeClass(`${s.params.containerModifierClass}${a}`) 2979 .addClass(`${s.params.containerModifierClass}${e}`), 2980 s.emitContainerClasses(), 2981 (s.params.direction = e), 2982 s.slides.each((t) => { 2983 "vertical" === e ? (t.style.width = "") : (t.style.height = ""); 2984 }), 2985 s.emit("changeDirection"), 2986 t && s.update()), 2987 s 2988 ); 2989 } 2990 changeLanguageDirection(e) { 2991 const t = this; 2992 (t.rtl && "rtl" === e) || 2993 (!t.rtl && "ltr" === e) || 2994 ((t.rtl = "rtl" === e), 2995 (t.rtlTranslate = "horizontal" === t.params.direction && t.rtl), 2996 t.rtl 2997 ? (t.$el.addClass(`${t.params.containerModifierClass}rtl`), 2998 (t.el.dir = "rtl")) 2999 : (t.$el.removeClass(`${t.params.containerModifierClass}rtl`), 3000 (t.el.dir = "ltr")),
3001 t.update()); 3002 } 3003 mount(e) { 3004 const t = this; 3005 if (t.mounted) return !0; 3006 const s = d(e || t.params.el); 3007 if (!(e = s[0])) return !1; 3008 e.swiper = t; 3009 const i = () => 3010 `.${(t.params.wrapperClass || "").trim().split(" ").join(".")}`; 3011 let r = (() => { 3012 if (e && e.shadowRoot && e.shadowRoot.querySelector) { 3013 const t = d(e.shadowRoot.querySelector(i())); 3014 return (t.children = (e) => s.children(e)), t; 3015 } 3016 return s.children ? s.children(i()) : d(s).children(i()); 3017 })(); 3018 if (0 === r.length && t.params.createElements) { 3019 const e = a().createElement("div"); 3020 (r = d(e)), 3021 (e.className = t.params.wrapperClass), 3022 s.append(e), 3023 s.children(`.${t.params.slideClass}`).each((e) => { 3024 r.append(e); 3025 }); 3026 } 3027 return ( 3028 Object.assign(t, { 3029 $el: s, 3030 el: e, 3031 $wrapperEl: r, 3032 wrapperEl: r[0], 3033 mounted: !0, 3034 rtl: "rtl" === e.dir.toLowerCase() || "rtl" === s.css("direction"), 3035 rtlTranslate: 3036 "horizontal" === t.params.direction && 3037 ("rtl" === e.dir.toLowerCase() || "rtl" === s.css("direction")), 3038 wrongRTL: "-webkit-box" === r.css("display"), 3039 }), 3040 !0 3041 ); 3042 } 3043 init(e) { 3044 const t = this; 3045 if (t.initialized) return t; 3046 return ( 3047 !1 === t.mount(e) || 3048 (t.emit("beforeInit"), 3049 t.params.breakpoints && t.setBreakpoint(), 3050 t.addClasses(), 3051 t.params.loop && t.loopCreate(), 3052 t.updateSize(), 3053 t.updateSlides(), 3054 t.params.watchOverflow && t.checkOverflow(), 3055 t.params.grabCursor && t.enabled && t.setGrabCursor(), 3056 t.params.preloadImages && t.preloadImages(), 3057 t.params.loop 3058 ? t.slideTo( 3059 t.params.initialSlide + t.loopedSlides, 3060 0, 3061 t.params.runCallbacksOnInit, 3062 !1, 3063 !0 3064 ) 3065 : t.slideTo( 3066 t.params.initialSlide, 3067 0, 3068 t.params.runCallbacksOnInit, 3069 !1, 3070 !0 3071 ), 3072 t.attachEvents(), 3073 (t.initialized = !0), 3074 t.emit("init"), 3075 t.emit("afterInit")), 3076 t 3077 ); 3078 } 3079 destroy(e, t) { 3080 void 0 === e && (e = !0), void 0 === t && (t = !0); 3081 const s = this, 3082 { params: a, $el: i, $wrapperEl: r, slides: n } = s; 3083 return ( 3084 void 0 === s.params || 3085 s.destroyed || 3086 (s.emit("beforeDestroy"), 3087 (s.initialized = !1), 3088 s.detachEvents(), 3089 a.loop && s.loopDestroy(), 3090 t && 3091 (s.removeClasses(), 3092 i.removeAttr("style"), 3093 r.removeAttr("style"), 3094 n && 3095 n.length && 3096 n 3097 .removeClass( 3098 [ 3099 a.slideVisibleClass, 3100 a.slideActiveClass, 3101 a.slideNextClass, 3102 a.slidePrevClass, 3103 ].join(" ") 3104 ) 3105 .removeAttr("style") 3106 .removeAttr("data-swiper-slide-index")), 3107 s.emit("destroy"), 3108 Object.keys(s.eventsListeners).forEach((e) => { 3109 s.off(e); 3110 }), 3111 !1 !== e && 3112 ((s.$el[0].swiper = null), 3113 (function (e) { 3114 const t = e; 3115 Object.keys(t).forEach((e) => { 3116 try { 3117 t[e] = null; 3118 } catch (e) {} 3119 try { 3120 delete t[e]; 3121 } catch (e) {} 3122 }); 3123 })(s)), 3124 (s.destroyed = !0)), 3125 null 3126 ); 3127 } 3128 static extendDefaults(e) { 3129 g(_, e); 3130 } 3131 static get extendedDefaults() { 3132 return _; 3133 } 3134 static get defaults() { 3135 return W; 3136 } 3137 static installModule(e) { 3138 V.prototype.__modules__ || (V.prototype.__modules__ = []); 3139 const t = V.prototype.__modules__; 3140 "function" == typeof e && t.indexOf(e) < 0 && t.push(e); 3141 } 3142 static use(e) { 3143 return Array.isArray(e) 3144 ? (e.forEach((e) => V.installModule(e)), V) 3145 : (V.installModule(e), V); 3146 } 3147 } 3148 function F(e, t, s, i) { 3149 const r = a(); 3150 return ( 3151 e.params.createElements &&
3152 Object.keys(i).forEach((a) => { 3153 if (!s[a] && !0 === s.auto) { 3154 let n = e.$el.children(`.${i[a]}`)[0]; 3155 n || 3156 ((n = r.createElement("div")), 3157 (n.className = i[a]), 3158 e.$el.append(n)), 3159 (s[a] = n), 3160 (t[a] = n); 3161 } 3162 }), 3163 s 3164 ); 3165 } 3166 function U(e) { 3167 return ( 3168 void 0 === e && (e = ""), 3169 `.${e 3170 .trim() 3171 .replace(/([\.:!\/])/g, "\\$1") 3172 .replace(/ /g, ".")}` 3173 ); 3174 } 3175 function K(e) { 3176 const t = this, 3177 { $wrapperEl: s, params: a } = t; 3178 if ((a.loop && t.loopDestroy(), "object" == typeof e && "length" in e)) 3179 for (let t = 0; t < e.length; t += 1) e[t] && s.append(e[t]); 3180 else s.append(e); 3181 a.loop && t.loopCreate(), a.observer || t.update(); 3182 } 3183 function Z(e) { 3184 const t = this, 3185 { params: s, $wrapperEl: a, activeIndex: i } = t; 3186 s.loop && t.loopDestroy(); 3187 let r = i + 1; 3188 if ("object" == typeof e && "length" in e) { 3189 for (let t = 0; t < e.length; t += 1) e[t] && a.prepend(e[t]); 3190 r = i + e.length; 3191 } else a.prepend(e); 3192 s.loop && t.loopCreate(), s.observer || t.update(), t.slideTo(r, 0, !1); 3193 } 3194 function Q(e, t) { 3195 const s = this, 3196 { $wrapperEl: a, params: i, activeIndex: r } = s; 3197 let n = r; 3198 i.loop && 3199 ((n -= s.loopedSlides), 3200 s.loopDestroy(), 3201 (s.slides = a.children(`.${i.slideClass}`))); 3202 const l = s.slides.length; 3203 if (e <= 0) return void s.prependSlide(t); 3204 if (e >= l) return void s.appendSlide(t); 3205 let o = n > e ? n + 1 : n; 3206 const d = []; 3207 for (let t = l - 1; t >= e; t -= 1) { 3208 const e = s.slides.eq(t); 3209 e.remove(), d.unshift(e); 3210 } 3211 if ("object" == typeof t && "length" in t) { 3212 for (let e = 0; e < t.length; e += 1) t[e] && a.append(t[e]); 3213 o = n > e ? n + t.length : n; 3214 } else a.append(t); 3215 for (let e = 0; e < d.length; e += 1) a.append(d[e]); 3216 i.loop && s.loopCreate(), 3217 i.observer || s.update(), 3218 i.loop ? s.slideTo(o + s.loopedSlides, 0, !1) : s.slideTo(o, 0, !1); 3219 } 3220 function J(e) { 3221 const t = this, 3222 { params: s, $wrapperEl: a, activeIndex: i } = t; 3223 let r = i; 3224 s.loop && 3225 ((r -= t.loopedSlides), 3226 t.loopDestroy(), 3227 (t.slides = a.children(`.${s.slideClass}`))); 3228 let n, 3229 l = r; 3230 if ("object" == typeof e && "length" in e) { 3231 for (let s = 0; s < e.length; s += 1) 3232 (n = e[s]), t.slides[n] && t.slides.eq(n).remove(), n < l && (l -= 1); 3233 l = Math.max(l, 0); 3234 } else (n = e), t.slides[n] && t.slides.eq(n).remove(), n < l && (l -= 1), (l = Math.max(l, 0)); 3235 s.loop && t.loopCreate(), 3236 s.observer || t.update(), 3237 s.loop ? t.slideTo(l + t.loopedSlides, 0, !1) : t.slideTo(l, 0, !1); 3238 } 3239 function ee() { 3240 const e = this, 3241 t = []; 3242 for (let s = 0; s < e.slides.length; s += 1) t.push(s); 3243 e.removeSlide(t); 3244 } 3245 function te(e) { 3246 const { 3247 effect: t, 3248 swiper: s, 3249 on: a, 3250 setTranslate: i, 3251 setTransition: r, 3252 overwriteParams: n, 3253 perspective: l, 3254 recreateShadows: o, 3255 getEffectParams: d, 3256 } = e; 3257 let c; 3258 a("beforeInit", () => { 3259 if (s.params.effect !== t) return; 3260 s.classNames.push(`${s.params.containerModifierClass}${t}`), 3261 l && l() && s.classNames.push(`${s.params.containerModifierClass}3d`); 3262 const e = n ? n() : {}; 3263 Object.assign(s.params, e), Object.assign(s.originalParams, e); 3264 }), 3265 a("setTranslate", () => { 3266 s.params.effect === t && i(); 3267 }), 3268 a("setTransition", (e, a) => { 3269 s.params.effect === t && r(a); 3270 }), 3271 a("transitionEnd", () => { 3272 if (s.params.effect === t && o) { 3273 if (!d || !d().slideShadows) return; 3274 s.slides.each((e) => { 3275 s.$(e) 3276 .find( 3277 ".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left" 3278 ) 3279 .remove(); 3280 }), 3281 o(); 3282 } 3283 }), 3284 a("virtualUpdate", () => { 3285 s.params.effect === t && 3286 (s.slides.length || (c = !0), 3287 requestAnimationFrame(() => { 3288 c && s.slides && s.slides.length && (i(), (c = !1)); 3289 })); 3290 }); 3291 } 3292 function se(e, t) { 3293 return e.transformEl 3294 ? t 3295 .find(e.transformEl) 3296 .css({ 3297 "backface-visibility": "hidden", 3298 "-webkit-backface-visibility": "hidden", 3299 }) 3300 : t; 3301 } 3302 function ae(e) { 3303 let { swiper: t, duration: s, transformEl: a, allSlides: i } = e; 3304 const { slides: r, activeIndex: n, $wrapperEl: l } = t; 3305 if (t.params.virtualTranslate && 0 !== s) { 3306 let e, 3307 s = !1; 3308 (e = i ? (a ? r.find(a) : r) : a ? r.eq(n).find(a) : r.eq(n)), 3309 e.transitionEnd(() => { 3310 if (s) return; 3311 if (!t || t.destroyed) return; 3312 (s = !0), (t.animating = !1); 3313 const e = ["webkitTransitionEnd", "transitionend"]; 3314 for (let t = 0; t < e.length; t += 1) l.trigger(e[t]); 3315 }); 3316 } 3317 } 3318 function ie(e, t, s) { 3319 const a = "swiper-slide-shadow" + (s ? `-${s}` : ""), 3320 i = e.transformEl ? t.find(e.transformEl) : t; 3321 let r = i.children(`.${a}`); 3322 return ( 3323 r.length || 3324 ((r = d(`<div class="swiper-slide-shadow${s ? `-${s}` : ""}"></div>`)), 3325 i.append(r)), 3326 r 3327 ); 3328 } 3329 Object.keys(q).forEach((e) => {
3330 Object.keys(q[e]).forEach((t) => { 3331 V.prototype[t] = q[e][t]; 3332 }); 3333 }), 3334 V.use([ 3335 function (e) { 3336 let { swiper: t, on: s, emit: a } = e; 3337 const i = r(); 3338 let n = null, 3339 l = null; 3340 const o = () => { 3341 t && 3342 !t.destroyed && 3343 t.initialized && 3344 (a("beforeResize"), a("resize")); 3345 }, 3346 d = () => { 3347 t && !t.destroyed && t.initialized && a("orientationchange"); 3348 }; 3349 s("init", () => { 3350 t.params.resizeObserver && void 0 !== i.ResizeObserver 3351 ? t && 3352 !t.destroyed && 3353 t.initialized && 3354 ((n = new ResizeObserver((e) => { 3355 l = i.requestAnimationFrame(() => { 3356 const { width: s, height: a } = t; 3357 let i = s, 3358 r = a; 3359 e.forEach((e) => { 3360 let { contentBoxSize: s, contentRect: a, target: n } = e; 3361 (n && n !== t.el) || 3362 ((i = a ? a.width : (s[0] || s).inlineSize), 3363 (r = a ? a.height : (s[0] || s).blockSize)); 3364 }), 3365 (i === s && r === a) || o(); 3366 }); 3367 })), 3368 n.observe(t.el)) 3369 : (i.addEventListener("resize", o), 3370 i.addEventListener("orientationchange", d)); 3371 }), 3372 s("destroy", () => { 3373 l && i.cancelAnimationFrame(l), 3374 n && n.unobserve && t.el && (n.unobserve(t.el), (n = null)), 3375 i.removeEventListener("resize", o), 3376 i.removeEventListener("orientationchange", d); 3377 }); 3378 }, 3379 function (e) { 3380 let { swiper: t, extendParams: s, on: a, emit: i } = e; 3381 const n = [], 3382 l = r(), 3383 o = function (e, t) { 3384 void 0 === t && (t = {}); 3385 const s = new (l.MutationObserver || l.WebkitMutationObserver)( 3386 (e) => { 3387 if (1 === e.length) return void i("observerUpdate", e[0]); 3388 const t = function () { 3389 i("observerUpdate", e[0]); 3390 }; 3391 l.requestAnimationFrame 3392 ? l.requestAnimationFrame(t) 3393 : l.setTimeout(t, 0); 3394 } 3395 ); 3396 s.observe(e, { 3397 attributes: void 0 === t.attributes || t.attributes, 3398 childList: void 0 === t.childList || t.childList, 3399 characterData: void 0 === t.characterData || t.characterData, 3400 }), 3401 n.push(s); 3402 }; 3403 s({ observer: !1, observeParents: !1, observeSlideChildren: !1 }), 3404 a("init", () => { 3405 if (t.params.observer) { 3406 if (t.params.observeParents) { 3407 const e = t.$el.parents(); 3408 for (let t = 0; t < e.length; t += 1) o(e[t]); 3409 } 3410 o(t.$el[0], { childList: t.params.observeSlideChildren }), 3411 o(t.$wrapperEl[0], { attributes: !1 }); 3412 } 3413 }), 3414 a("destroy", () => {
3415 n.forEach((e) => { 3416 e.disconnect(); 3417 }), 3418 n.splice(0, n.length); 3419 }); 3420 }, 3421 ]); 3422 const re = [ 3423 function (e) { 3424 let t, 3425 { swiper: s, extendParams: a, on: i, emit: r } = e; 3426 function n(e, t) { 3427 const a = s.params.virtual; 3428 if (a.cache && s.virtual.cache[t]) return s.virtual.cache[t]; 3429 const i = a.renderSlide 3430 ? d(a.renderSlide.call(s, e, t)) 3431 : d( 3432 `<div class="${s.params.slideClass}" data-swiper-slide-index="${t}">${e}</div>` 3433 ); 3434 return ( 3435 i.attr("data-swiper-slide-index") || 3436 i.attr("data-swiper-slide-index", t), 3437 a.cache && (s.virtual.cache[t] = i), 3438 i 3439 ); 3440 } 3441 function l(e) { 3442 const { 3443 slidesPerView: t, 3444 slidesPerGroup: a, 3445 centeredSlides: i, 3446 } = s.params, 3447 { addSlidesBefore: l, addSlidesAfter: o } = s.params.virtual, 3448 { from: d, to: c, slides: p, slidesGrid: u, offset: h } = s.virtual; 3449 s.params.cssMode || s.updateActiveIndex(); 3450 const m = s.activeIndex || 0; 3451 let f, g, v; 3452 (f = s.rtlTranslate ? "right" : s.isHorizontal() ? "left" : "top"), 3453 i 3454 ? ((g = Math.floor(t / 2) + a + o), (v = Math.floor(t / 2) + a + l)) 3455 : ((g = t + (a - 1) + o), (v = a + l)); 3456 const w = Math.max((m || 0) - v, 0), 3457 b = Math.min((m || 0) + g, p.length - 1), 3458 x = (s.slidesGrid[w] || 0) - (s.slidesGrid[0] || 0); 3459 function y() { 3460 s.updateSlides(), 3461 s.updateProgress(), 3462 s.updateSlidesClasses(), 3463 s.lazy && s.params.lazy.enabled && s.lazy.load(), 3464 r("virtualUpdate"); 3465 } 3466 if ( 3467 (Object.assign(s.virtual, { 3468 from: w, 3469 to: b, 3470 offset: x, 3471 slidesGrid: s.slidesGrid, 3472 }), 3473 d === w && c === b && !e) 3474 ) 3475 return ( 3476 s.slidesGrid !== u && x !== h && s.slides.css(f, `${x}px`), 3477 s.updateProgress(), 3478 void r("virtualUpdate") 3479 ); 3480 if (s.params.virtual.renderExternal) 3481 return ( 3482 s.params.virtual.renderExternal.call(s, { 3483 offset: x, 3484 from: w, 3485 to: b, 3486 slides: (function () { 3487 const e = []; 3488 for (let t = w; t <= b; t += 1) e.push(p[t]); 3489 return e; 3490 })(), 3491 }), 3492 void (s.params.virtual.renderExternalUpdate 3493 ? y() 3494 : r("virtualUpdate")) 3495 ); 3496 const E = [], 3497 C = []; 3498 if (e) s.$wrapperEl.find(`.${s.params.slideClass}`).remove(); 3499 else 3500 for (let e = d; e <= c; e += 1) 3501 (e < w || e > b) && 3502 s.$wrapperEl 3503 .find(`.${s.params.slideClass}[data-swiper-slide-index="${e}"]`) 3504 .remove(); 3505 for (let t = 0; t < p.length; t += 1) 3506 t >= w && 3507 t <= b && 3508 (void 0 === c || e 3509 ? C.push(t) 3510 : (t > c && C.push(t), t < d && E.push(t))); 3511 C.forEach((e) => { 3512 s.$wrapperEl.append(n(p[e], e)); 3513 }), 3514 E.sort((e, t) => t - e).forEach((e) => { 3515 s.$wrapperEl.prepend(n(p[e], e)); 3516 }), 3517 s.$wrapperEl.children(".swiper-slide").css(f, `${x}px`), 3518 y(); 3519 } 3520 a({ 3521 virtual: { 3522 enabled: !1, 3523 slides: [], 3524 cache: !0, 3525 renderSlide: null, 3526 renderExternal: null, 3527 renderExternalUpdate: !0, 3528 addSlidesBefore: 0, 3529 addSlidesAfter: 0, 3530 }, 3531 }), 3532 (s.virtual = { 3533 cache: {}, 3534 from: void 0, 3535 to: void 0, 3536 slides: [], 3537 offset: 0, 3538 slidesGrid: [], 3539 }), 3540 i("beforeInit", () => { 3541 s.params.virtual.enabled && 3542 ((s.virtual.slides = s.params.virtual.slides), 3543 s.classNames.push(`${s.params.containerModifierClass}virtual`), 3544 (s.params.watchSlidesProgress = !0), 3545 (s.originalParams.watchSlidesProgress = !0), 3546 s.params.initialSlide || l()); 3547 }), 3548 i("setTranslate", () => { 3549 s.params.virtual.enabled && 3550 (s.params.cssMode && !s._immediateVirtual 3551 ? (clearTimeout(t), 3552 (t = setTimeout(() => { 3553 l(); 3554 }, 100))) 3555 : l()); 3556 }), 3557 i("init update resize", () => { 3558 s.params.virtual.enabled && 3559 s.params.cssMode && 3560 v(s.wrapperEl, "--swiper-virtual-size", `${s.virtualSize}px`); 3561 }), 3562 Object.assign(s.virtual, { 3563 appendSlide: function (e) { 3564 if ("object" == typeof e && "length" in e) 3565 for (let t = 0; t < e.length; t += 1) 3566 e[t] && s.virtual.slides.push(e[t]); 3567 else s.virtual.slides.push(e); 3568 l(!0); 3569 }, 3570 prependSlide: function (e) { 3571 const t = s.activeIndex; 3572 let a = t + 1, 3573 i = 1; 3574 if (Array.isArray(e)) { 3575 for (let t = 0; t < e.length; t += 1) 3576 e[t] && s.virtual.slides.unshift(e[t]); 3577 (a = t + e.length), (i = e.length); 3578 } else s.virtual.slides.unshift(e); 3579 if (s.params.virtual.cache) { 3580 const e = s.virtual.cache, 3581 t = {}; 3582 Object.keys(e).forEach((s) => { 3583 const a = e[s], 3584 r = a.attr("data-swiper-slide-index"); 3585 r && a.attr("data-swiper-slide-index", parseInt(r, 10) + i), 3586 (t[parseInt(s, 10) + i] = a); 3587 }), 3588 (s.virtual.cache = t); 3589 } 3590 l(!0), s.slideTo(a, 0); 3591 }, 3592 removeSlide: function (e) { 3593 if (null == e) return; 3594 let t = s.activeIndex; 3595 if (Array.isArray(e)) 3596 for (let a = e.length - 1; a >= 0; a -= 1) 3597 s.virtual.slides.splice(e[a], 1), 3598 s.params.virtual.cache && delete s.virtual.cache[e[a]], 3599 e[a] < t && (t -= 1), 3600 (t = Math.max(t, 0)); 3601 else 3602 s.virtual.slides.splice(e, 1), 3603 s.params.virtual.cache && delete s.virtual.cache[e], 3604 e < t && (t -= 1), 3605 (t = Math.max(t, 0)); 3606 l(!0), s.slideTo(t, 0); 3607 }, 3608 removeAllSlides: function () { 3609 (s.virtual.slides = []), 3610 s.params.virtual.cache && (s.virtual.cache = {}), 3611 l(!0), 3612 s.slideTo(0, 0); 3613 }, 3614 update: l, 3615 }); 3616 }, 3617 function (e) { 3618 let { swiper: t, extendParams: s, on: i, emit: n } = e; 3619 const l = a(), 3620 o = r(); 3621 function c(e) { 3622 if (!t.enabled) return; 3623 const { rtlTranslate: s } = t; 3624 let a = e; 3625 a.originalEvent && (a = a.originalEvent); 3626 const i = a.keyCode || a.charCode, 3627 r = t.params.keyboard.pageUpDown, 3628 d = r && 33 === i, 3629 c = r && 34 === i, 3630 p = 37 === i, 3631 u = 39 === i, 3632 h = 38 === i, 3633 m = 40 === i; 3634 if ( 3635 !t.allowSlideNext && 3636 ((t.isHorizontal() && u) || (t.isVertical() && m) || c) 3637 ) 3638 return !1; 3639 if ( 3640 !t.allowSlidePrev && 3641 ((t.isHorizontal() && p) || (t.isVertical() && h) || d) 3642 ) 3643 return !1; 3644 if ( 3645 !( 3646 a.shiftKey || 3647 a.altKey || 3648 a.ctrlKey || 3649 a.metaKey || 3650 (l.activeElement && 3651 l.activeElement.nodeName && 3652 ("input" === l.activeElement.nodeName.toLowerCase() || 3653 "textarea" === l.activeElement.nodeName.toLowerCase())) 3654 ) 3655 ) { 3656 if ( 3657 t.params.keyboard.onlyInViewport && 3658 (d || c || p || u || h || m) 3659 ) { 3660 let e = !1; 3661 if ( 3662 t.$el.parents(`.${t.params.slideClass}`).length > 0 && 3663 0 === t.$el.parents(`.${t.params.slideActiveClass}`).length 3664 ) 3665 return; 3666 const a = t.$el, 3667 i = a[0].clientWidth, 3668 r = a[0].clientHeight, 3669 n = o.innerWidth, 3670 l = o.innerHeight, 3671 d = t.$el.offset(); 3672 s && (d.left -= t.$el[0].scrollLeft); 3673 const c = [ 3674 [d.left, d.top], 3675 [d.left + i, d.top], 3676 [d.left, d.top + r], 3677 [d.left + i, d.top + r], 3678 ]; 3679 for (let t = 0; t < c.length; t += 1) { 3680 const s = c[t]; 3681 if (s[0] >= 0 && s[0] <= n && s[1] >= 0 && s[1] <= l) { 3682 if (0 === s[0] && 0 === s[1]) continue; 3683 e = !0; 3684 } 3685 } 3686 if (!e) return; 3687 } 3688 t.isHorizontal() 3689 ? ((d || c || p || u) && 3690 (a.preventDefault ? a.preventDefault() : (a.returnValue = !1)), 3691 (((c || u) && !s) || ((d || p) && s)) && t.slideNext(), 3692 (((d || p) && !s) || ((c || u) && s)) && t.slidePrev()) 3693 : ((d || c || h || m) && 3694 (a.preventDefault ? a.preventDefault() : (a.returnValue = !1)), 3695 (c || m) && t.slideNext(), 3696 (d || h) && t.slidePrev()), 3697 n("keyPress", i); 3698 } 3699 } 3700 function p() { 3701 t.keyboard.enabled || 3702 (d(l).on("keydown", c), (t.keyboard.enabled = !0)); 3703 } 3704 function u() { 3705 t.keyboard.enabled && 3706 (d(l).off("keydown", c), (t.keyboard.enabled = !1)); 3707 } 3708 (t.keyboard = { enabled: !1 }), 3709 s({ keyboard: { enabled: !1, onlyInViewport: !0, pageUpDown: !0 } }), 3710 i("init", () => { 3711 t.params.keyboard.enabled && p(); 3712 }), 3713 i("destroy", () => { 3714 t.keyboard.enabled && u(); 3715 }), 3716 Object.assign(t.keyboard, { enable: p, disable: u }); 3717 }, 3718 function (e) { 3719 let { swiper: t, extendParams: s, on: a, emit: i } = e; 3720 const n = r(); 3721 let l; 3722 s({ 3723 mousewheel: { 3724 enabled: !1, 3725 releaseOnEdges: !1, 3726 invert: !1, 3727 forceToAxis: !1, 3728 sensitivity: 1, 3729 eventsTarget: "container", 3730 thresholdDelta: null, 3731 thresholdTime: null, 3732 }, 3733 }), 3734 (t.mousewheel = { enabled: !1 }); 3735 let o, 3736 c = u(); 3737 const h = []; 3738 function m() { 3739 t.enabled && (t.mouseEntered = !0); 3740 } 3741 function f() { 3742 t.enabled && (t.mouseEntered = !1); 3743 } 3744 function g(e) { 3745 return ( 3746 !( 3747 t.params.mousewheel.thresholdDelta && 3748 e.delta < t.params.mousewheel.thresholdDelta 3749 ) && 3750 !( 3751 t.params.mousewheel.thresholdTime && 3752 u() - c < t.params.mousewheel.thresholdTime 3753 ) && 3754 ((e.delta >= 6 && u() - c < 60) || 3755 (e.direction < 0 3756 ? (t.isEnd && !t.params.loop) || 3757 t.animating || 3758 (t.slideNext(), i("scroll", e.raw)) 3759 : (t.isBeginning && !t.params.loop) || 3760 t.animating || 3761 (t.slidePrev(), i("scroll", e.raw)), 3762 (c = new n.Date().getTime()), 3763 !1)) 3764 ); 3765 } 3766 function v(e) { 3767 let s = e, 3768 a = !0; 3769 if (!t.enabled) return; 3770 const r = t.params.mousewheel; 3771 t.params.cssMode && s.preventDefault(); 3772 let n = t.$el; 3773 if ( 3774 ("container" !== t.params.mousewheel.eventsTarget && 3775 (n = d(t.params.mousewheel.eventsTarget)), 3776 !t.mouseEntered && !n[0].contains(s.target) && !r.releaseOnEdges) 3777 ) 3778 return !0; 3779 s.originalEvent && (s = s.originalEvent); 3780 let c = 0; 3781 const m = t.rtlTranslate ? -1 : 1, 3782 f = (function (e) { 3783 let t = 0, 3784 s = 0, 3785 a = 0, 3786 i = 0; 3787 return ( 3788 "detail" in e && (s = e.detail), 3789 "wheelDelta" in e && (s = -e.wheelDelta / 120), 3790 "wheelDeltaY" in e && (s = -e.wheelDeltaY / 120), 3791 "wheelDeltaX" in e && (t = -e.wheelDeltaX / 120), 3792 "axis" in e && e.axis === e.HORIZONTAL_AXIS && ((t = s), (s = 0)), 3793 (a = 10 * t), 3794 (i = 10 * s), 3795 "deltaY" in e && (i = e.deltaY), 3796 "deltaX" in e && (a = e.deltaX), 3797 e.shiftKey && !a && ((a = i), (i = 0)), 3798 (a || i) && 3799 e.deltaMode && 3800 (1 === e.deltaMode 3801 ? ((a *= 40), (i *= 40)) 3802 : ((a *= 800), (i *= 800))), 3803 a && !t && (t = a < 1 ? -1 : 1), 3804 i && !s && (s = i < 1 ? -1 : 1), 3805 { spinX: t, spinY: s, pixelX: a, pixelY: i } 3806 ); 3807 })(s); 3808 if (r.forceToAxis) 3809 if (t.isHorizontal()) { 3810 if (!(Math.abs(f.pixelX) > Math.abs(f.pixelY))) return !0; 3811 c = -f.pixelX * m; 3812 } else { 3813 if (!(Math.abs(f.pixelY) > Math.abs(f.pixelX))) return !0; 3814 c = -f.pixelY; 3815 } 3816 else 3817 c = 3818 Math.abs(f.pixelX) > Math.abs(f.pixelY) ? -f.pixelX * m : -f.pixelY; 3819 if (0 === c) return !0; 3820 r.invert && (c = -c); 3821 let v = t.getTranslate() + c * r.sensitivity; 3822 if ( 3823 (v >= t.minTranslate() && (v = t.minTranslate()), 3824 v <= t.maxTranslate() && (v = t.maxTranslate()), 3825 (a = 3826 !!t.params.loop || 3827 !(v === t.minTranslate() || v === t.maxTranslate())), 3828 a && t.params.nested && s.stopPropagation(), 3829 t.params.freeMode && t.params.freeMode.enabled) 3830 ) { 3831 const e = { time: u(), delta: Math.abs(c), direction: Math.sign(c) }, 3832 a = 3833 o && 3834 e.time < o.time + 500 && 3835 e.delta <= o.delta && 3836 e.direction === o.direction; 3837 if (!a) { 3838 (o = void 0), t.params.loop && t.loopFix(); 3839 let n = t.getTranslate() + c * r.sensitivity; 3840 const d = t.isBeginning, 3841 u = t.isEnd; 3842 if ( 3843 (n >= t.minTranslate() && (n = t.minTranslate()), 3844 n <= t.maxTranslate() && (n = t.maxTranslate()), 3845 t.setTransition(0), 3846 t.setTranslate(n), 3847 t.updateProgress(), 3848 t.updateActiveIndex(), 3849 t.updateSlidesClasses(), 3850 ((!d && t.isBeginning) || (!u && t.isEnd)) && 3851 t.updateSlidesClasses(), 3852 t.params.freeMode.sticky) 3853 ) { 3854 clearTimeout(l), (l = void 0), h.length >= 15 && h.shift(); 3855 const s = h.length ? h[h.length - 1] : void 0, 3856 a = h[0]; 3857 if ( 3858 (h.push(e), 3859 s && (e.delta > s.delta || e.direction !== s.direction)) 3860 ) 3861 h.splice(0); 3862 else if ( 3863 h.length >= 15 && 3864 e.time - a.time < 500 && 3865 a.delta - e.delta >= 1 && 3866 e.delta <= 6 3867 ) { 3868 const s = c > 0 ? 0.8 : 0.2; 3869 (o = e), 3870 h.splice(0), 3871 (l = p(() => { 3872 t.slideToClosest(t.params.speed, !0, void 0, s); 3873 }, 0)); 3874 } 3875 l || 3876 (l = p(() => { 3877 (o = e), 3878 h.splice(0), 3879 t.slideToClosest(t.params.speed, !0, void 0, 0.5); 3880 }, 500)); 3881 } 3882 if ( 3883 (a || i("scroll", s), 3884 t.params.autoplay && 3885 t.params.autoplayDisableOnInteraction && 3886 t.autoplay.stop(), 3887 n === t.minTranslate() || n === t.maxTranslate()) 3888 ) 3889 return !0; 3890 } 3891 } else { 3892 const s = { 3893 time: u(), 3894 delta: Math.abs(c), 3895 direction: Math.sign(c), 3896 raw: e, 3897 }; 3898 h.length >= 2 && h.shift(); 3899 const a = h.length ? h[h.length - 1] : void 0; 3900 if ( 3901 (h.push(s), 3902 a 3903 ? (s.direction !== a.direction || 3904 s.delta > a.delta || 3905 s.time > a.time + 150) && 3906 g(s) 3907 : g(s), 3908 (function (e) { 3909 const s = t.params.mousewheel; 3910 if (e.direction < 0) { 3911 if (t.isEnd && !t.params.loop && s.releaseOnEdges) return !0; 3912 } else if (t.isBeginning && !t.params.loop && s.releaseOnEdges) 3913 return !0; 3914 return !1; 3915 })(s)) 3916 ) 3917 return !0; 3918 } 3919 return s.preventDefault ? s.preventDefault() : (s.returnValue = !1), !1; 3920 } 3921 function w(e) { 3922 let s = t.$el; 3923 "container" !== t.params.mousewheel.eventsTarget && 3924 (s = d(t.params.mousewheel.eventsTarget)), 3925 s[e]("mouseenter", m), 3926 s[e]("mouseleave", f), 3927 s[e]("wheel", v); 3928 } 3929 function b() { 3930 return t.params.cssMode 3931 ? (t.wrapperEl.removeEventListener("wheel", v), !0) 3932 : !t.mousewheel.enabled && (w("on"), (t.mousewheel.enabled = !0), !0); 3933 } 3934 function x() { 3935 return t.params.cssMode 3936 ? (t.wrapperEl.addEventListener(event, v), !0) 3937 : !!t.mousewheel.enabled && 3938 (w("off"), (t.mousewheel.enabled = !1), !0); 3939 } 3940 a("init", () => { 3941 !t.params.mousewheel.enabled && t.params.cssMode && x(), 3942 t.params.mousewheel.enabled && b(); 3943 }), 3944 a("destroy", () => { 3945 t.params.cssMode && b(), t.mousewheel.enabled && x(); 3946 }), 3947 Object.assign(t.mousewheel, { enable: b, disable: x }); 3948 }, 3949 function (e) { 3950 let { swiper: t, extendParams: s, on: a, emit: i } = e; 3951 function r(e) { 3952 let s; 3953 return ( 3954 e && 3955 ((s = d(e)), 3956 t.params.uniqueNavElements && 3957 "string" == typeof e && 3958 s.length > 1 && 3959 1 === t.$el.find(e).length && 3960 (s = t.$el.find(e))), 3961 s 3962 ); 3963 } 3964 function n(e, s) { 3965 const a = t.params.navigation; 3966 e && 3967 e.length > 0 && 3968 (e[s ? "addClass" : "removeClass"](a.disabledClass), 3969 e[0] && "BUTTON" === e[0].tagName && (e[0].disabled = s), 3970 t.params.watchOverflow && 3971 t.enabled && 3972 e[t.isLocked ? "addClass" : "removeClass"](a.lockClass)); 3973 } 3974 function l() { 3975 if (t.params.loop) return; 3976 const { $nextEl: e, $prevEl: s } = t.navigation; 3977 n(s, t.isBeginning && !t.params.rewind), 3978 n(e, t.isEnd && !t.params.rewind); 3979 } 3980 function o(e) { 3981 e.preventDefault(), 3982 (!t.isBeginning || t.params.loop || t.params.rewind) && 3983 (t.slidePrev(), i("navigationPrev")); 3984 } 3985 function c(e) { 3986 e.preventDefault(), 3987 (!t.isEnd || t.params.loop || t.params.rewind) && 3988 (t.slideNext(), i("navigationNext")); 3989 } 3990 function p() { 3991 const e = t.params.nav
3991igation; 3992 if ( 3993 ((t.params.navigation = F( 3994 t, 3995 t.originalParams.navigation, 3996 t.params.navigation, 3997 { nextEl: "swiper-button-next", prevEl: "swiper-button-prev" } 3998 )), 3999 !e.nextEl && !e.prevEl) 4000 ) 4001 return; 4002 const s = r(e.nextEl), 4003 a = r(e.prevEl); 4004 s && s.length > 0 && s.on("click", c), 4005 a && a.length > 0 && a.on("click", o), 4006 Object.assign(t.navigation, { 4007 $nextEl: s, 4008 nextEl: s && s[0], 4009 $prevEl: a, 4010 prevEl: a && a[0], 4011 }), 4012 t.enabled || 4013 (s && s.addClass(e.lockClass), a && a.addClass(e.lockClass)); 4014 } 4015 function u() { 4016 const { $nextEl: e, $prevEl: s } = t.navigation; 4017 e && 4018 e.length && 4019 (e.off("click", c), e.removeClass(t.params.navigation.disabledClass)), 4020 s && 4021 s.length && 4022 (s.off("click", o), 4023 s.removeClass(t.params.navigation.disabledClass)); 4024 } 4025 s({ 4026 navigation: { 4027 nextEl: null, 4028 prevEl: null, 4029 hideOnClick: !1, 4030 disabledClass: "swiper-button-disabled", 4031 hiddenClass: "swiper-button-hidden", 4032 lockClass: "swiper-button-lock", 4033 navigationDisabledClass: "swiper-navigation-disabled", 4034 }, 4035 }), 4036 (t.navigation = { 4037 nextEl: null, 4038 $nextEl: null, 4039 prevEl: null, 4040 $prevEl: null, 4041 }), 4042 a("init", () => { 4043 !1 === t.params.navigation.enabled ? h() : (p(), l()); 4044 }), 4045 a("toEdge fromEdge lock unlock", () => { 4046 l(); 4047 }), 4048 a("destroy", () => { 4049 u(); 4050 }), 4051 a("enable disable", () => { 4052 const { $nextEl: e, $prevEl: s } = t.navigation; 4053 e && 4054 e[t.enabled ? "removeClass" : "addClass"]( 4055 t.params.navigation.lockClass 4056 ), 4057 s && 4058 s[t.enabled ? "removeClass" : "addClass"]( 4059 t.params.navigation.lockClass 4060 ); 4061 }), 4062 a("click", (e, s) => { 4063 const { $nextEl: a, $prevEl: r } = t.navigation, 4064 n = s.target; 4065 if (t.params.navigation.hideOnClick && !d(n).is(r) && !d(n).is(a)) { 4066 if ( 4067 t.pagination && 4068 t.params.pagination && 4069 t.params.pagination.clickable && 4070 (t.pagination.el === n || t.pagination.el.contains(n)) 4071 ) 4072 return; 4073 let e; 4074 a 4075 ? (e = a.hasClass(t.params.navigation.hiddenClass)) 4076 : r && (e = r.hasClass(t.params.navigation.hiddenClass)), 4077 i(!0 === e ? "navigationShow" : "navigationHide"), 4078 a && a.toggleClass(t.params.navigation.hiddenClass), 4079 r && r.toggleClass(t.params.navigation.hiddenClass); 4080 } 4081 }); 4082 const h = () => { 4083 t.$el.addClass(t.params.navigation.navigationDisabledClass), u(); 4084 }; 4085 Object.assign(t.navigation, { 4086 enable: () => { 4087 t.$el.removeClass(t.params.navigation.navigationDisabledClass), 4088 p(), 4089 l(); 4090 }, 4091 disable: h, 4092 update: l, 4093 init: p, 4094 destroy: u, 4095 }); 4096 }, 4097 function (e) { 4098 let { swiper: t, extendParams: s, on: a, emit: i } = e; 4099 const r = "swiper-pagination"; 4100 let n; 4101 s({ 4102 pagination: { 4103 el: null, 4104 bulletElement: "span", 4105 clickable: !1, 4106 hideOnClick: !1, 4107 renderBullet: null, 4108 renderProgressbar: null, 4109 renderFraction: null, 4110 renderCustom: null, 4111 progressbarOpposite: !1, 4112 type: "bullets", 4113 dynamicBullets: !1, 4114 dynamicMainBullets: 1, 4115 formatFractionCurrent: (e) => e, 4116 formatFractionTotal: (e) => e, 4117 bulletClass: `${r}-bullet`, 4118 bulletActiveClass: `${r}-bullet-active`, 4119 modifierClass: `${r}-`, 4120 currentClass: `${r}-current`, 4121 totalClass: `${r}-total`, 4122 hiddenClass: `${r}-hidden`, 4123 progressbarFillClass: `${r}-progressbar-fill`, 4124 progressbarOppositeClass: `${r}-progressbar-opposite`, 4125 clickableClass: `${r}-clickable`, 4126 lockClass: `${r}-lock`, 4127 horizontalClass: `${r}-horizontal`, 4128 verticalClass: `${r}-vertical`, 4129 paginationDisabledClass: `${r}-disabled`, 4130 }, 4131 }), 4132 (t.pagination = { el: null, $el: null, bullets: [] }); 4133 let l = 0; 4134 function o() { 4135 return ( 4136 !t.params.pagination.el || 4137 !t.pagination.el || 4138 !t.pagination.$el || 4139 0 === t.pagination.$el.length 4140 ); 4141 } 4142 function c(e, s) { 4143 const { bulletActiveClass: a } = t.params.pagination; 4144 e[s]().addClass(`${a}-${s}`)[s]().addClass(`${a}-${s}-${s}`); 4145 } 4146 function p() { 4147 const e = t.rtl, 4148 s = t.params.pagination; 4149 if (o()) return; 4150 const a = 4151 t.virtual && t.params.virtual.enabled 4152 ? t.virtual.slides.length 4153 : t.slides.length, 4154 r = t.pagination.$el; 4155 let p; 4156 const u = t.params.loop 4157 ? Math.ceil((a - 2 * t.loopedSlides) / t.params.slidesPerGroup) 4158 : t.snapGrid.length; 4159 if ( 4160 (t.params.loop 4161 ? ((p = Math.ceil( 4162 (t.activeIndex - t.loopedSlides) / t.params.slidesPerGroup 4163 )), 4164 p > a - 1 - 2 * t.loopedSlides && (p -= a - 2 * t.loopedSlides), 4165 p > u - 1 && (p -= u), 4166 p < 0 && "bullets" !== t.params.paginationType && (p = u + p)) 4167 : (p = void 0 !== t.snapIndex ? t.snapIndex : t.activeIndex || 0), 4168 "bullets" === s.type && 4169 t.pagination.bullets && 4170 t.pagination.bullets.length > 0) 4171 ) { 4172 const a = t.pagination.bullets; 4173 let i, o, u; 4174 if ( 4175 (s.dynamicBullets && 4176 ((n = a 4177 .eq(0) 4178 [t.isHorizontal() ? "outerWidth" : "outerHeight"](!0)), 4179 r.css( 4180 t.isHorizontal() ? "width" : "height", 4181 n * (s.dynamicMainBullets + 4) + "px" 4182 ), 4183 s.dynamicMainBullets > 1 && 4184 void 0 !== t.previousIndex && 4185 ((l += p - (t.previousIndex - t.loopedSlides || 0)), 4186 l > s.dynamicMainBullets - 1 4187 ? (l = s.dynamicMainBullets - 1) 4188 : l < 0 && (l = 0)), 4189 (i = Math.max(p - l, 0)), 4190 (o = i + (Math.min(a.length, s.dynamicMainBullets) - 1)), 4191 (u = (o + i) / 2)), 4192 a.removeClass( 4193 ["", "-next", "-next-next", "-prev", "-prev-prev", "-main"] 4194 .map((e) => `${s.bulletActiveClass}${e}`) 4195 .join(" ") 4196 ), 4197 r.length > 1) 4198 ) 4199 a.each((e) => { 4200 const t = d(e), 4201 a = t.index(); 4202 a === p && t.addClass(s.bulletActiveClass), 4203 s.dynamicBullets && 4204 (a >= i && 4205 a <= o && 4206 t.addClass(`${s.bulletActiveClass}-main`), 4207 a === i && c(t, "prev"), 4208 a === o && c(t, "next")); 4209 }); 4210 else { 4211 const e = a.eq(p), 4212 r = e.index(); 4213 if ((e.addClass(s.bulletActiveClass), s.dynamicBullets)) { 4214 const e = a.eq(i), 4215 n = a.eq(o); 4216 for (let e = i; e <= o; e += 1) 4217 a.eq(e).addClass(`${s.bulletActiveClass}-main`); 4218 if (t.params.loop) 4219 if (r >= a.length) { 4220 for (let e = s.dynamicMainBullets; e >= 0; e -= 1) 4221 a.eq(a.length - e).addClass(`${s.bulletActiveClass}-main`); 4222 a.eq(a.length - s.dynamicMainBullets - 1).addClass( 4223 `${s.bulletActiveClass}-prev` 4224 ); 4225 } else c(e, "prev"), c(n, "next"); 4226 else c(e, "prev"), c(n, "next"); 4227 } 4228 } 4229 if (s.dynamicBullets) { 4230 const i = Math.min(a.length, s.dynamicMainBullets + 4), 4231 r = (n * i - n) / 2 - u * n, 4232 l = e ? "right" : "left"; 4233 a.css(t.isHorizontal() ? l : "top", `${r}px`); 4234 } 4235 } 4236 if ( 4237 ("fraction" === s.type && 4238 (r.find(U(s.currentClass)).text(s.formatFractionCurrent(p + 1)), 4239 r.find(U(s.totalClass)).text(s.formatFractionTotal(u))), 4240 "progressbar" === s.type) 4241 ) { 4242 let e; 4243 e = s.progressbarOpposite 4244 ? t.isHorizontal() 4245 ? "vertical" 4246 : "horizontal" 4247 : t.isHorizontal() 4248 ? "horizontal" 4249 : "vertical"; 4250 const a = (p + 1) / u; 4251 let i = 1, 4252 n = 1; 4253 "horizontal" === e ? (i = a) : (n = a), 4254 r 4255 .find(U(s.progressbarFillClass))
4256 .transform(`translate3d(0,0,0) scaleX(${i}) scaleY(${n})`) 4257 .transition(t.params.speed); 4258 } 4259 "custom" === s.type && s.renderCustom 4260 ? (r.html(s.renderCustom(t, p + 1, u)), i("paginationRender", r[0])) 4261 : i("paginationUpdate", r[0]), 4262 t.params.watchOverflow && 4263 t.enabled && 4264 r[t.isLocked ? "addClass" : "removeClass"](s.lockClass); 4265 } 4266 function u() { 4267 const e = t.params.pagination; 4268 if (o()) return; 4269 const s = 4270 t.virtual && t.params.virtual.enabled 4271 ? t.virtual.slides.length 4272 : t.slides.length, 4273 a = t.pagination.$el; 4274 let r = ""; 4275 if ("bullets" === e.type) { 4276 let i = t.params.loop 4277 ? Math.ceil((s - 2 * t.loopedSlides) / t.params.slidesPerGroup) 4278 : t.snapGrid.length; 4279 t.params.freeMode && 4280 t.params.freeMode.enabled && 4281 !t.params.loop && 4282 i > s && 4283 (i = s); 4284 for (let s = 0; s < i; s += 1) 4285 e.renderBullet 4286 ? (r += e.renderBullet.call(t, s, e.bulletClass)) 4287 : (r += `<${e.bulletElement} class="${e.bulletClass}"></${e.bulletElement}>`); 4288 a.html(r), (t.pagination.bullets = a.find(U(e.bulletClass))); 4289 } 4290 "fraction" === e.type && 4291 ((r = e.renderFraction 4292 ? e.renderFraction.call(t, e.currentClass, e.totalClass) 4293 : `<span class="${e.currentClass}"></span> / <span class="${e.totalClass}"></span>`), 4294 a.html(r)), 4295 "progressbar" === e.type && 4296 ((r = e.renderProgressbar 4297 ? e.renderProgressbar.call(t, e.progressbarFillClass) 4298 : `<span class="${e.progressbarFillClass}"></span>`), 4299 a.html(r)), 4300 "custom" !== e.type && i("paginationRender", t.pagination.$el[0]); 4301 } 4302 function h() { 4303 t.params.pagination = F( 4304 t, 4305 t.originalParams.pagination, 4306 t.params.pagination, 4307 { el: "swiper-pagination" } 4308 ); 4309 const e = t.params.pagination; 4310 if (!e.el) return; 4311 let s = d(e.el); 4312 0 !== s.length && 4313 (t.params.uniqueNavElements && 4314 "string" == typeof e.el && 4315 s.length > 1 && 4316 ((s = t.$el.find(e.el)), 4317 s.length > 1 && 4318 (s = s.filter((e) => d(e).parents(".swiper")[0] === t.el))), 4319 "bullets" === e.type && e.clickable && s.addClass(e.clickableClass), 4320 s.addClass(e.modifierClass + e.type), 4321 s.addClass(t.isHorizontal() ? e.horizontalClass : e.verticalClass), 4322 "bullets" === e.type && 4323 e.dynamicBullets && 4324 (s.addClass(`${e.modifierClass}${e.type}-dynamic`), 4325 (l = 0), 4326 e.dynamicMainBullets < 1 && (e.dynamicMainBullets = 1)), 4327 "progressbar" === e.type && 4328 e.progressbarOpposite && 4329 s.addClass(e.progressbarOppositeClass), 4330 e.clickable && 4331 s.on("click", U(e.bulletClass), function (e) { 4332 e.preventDefault(); 4333 let s = d(this).index() * t.params.slidesPerGroup; 4334 t.params.loop && (s += t.loopedSlides), t.slideTo(s); 4335 }), 4336 Object.assign(t.pagination, { $el: s, el: s[0] }), 4337 t.enabled || s.addClass(e.lockClass)); 4338 } 4339 function m() { 4340 const e = t.params.pagination; 4341 if (o()) return; 4342 const s = t.pagination.$el; 4343 s.removeClass(e.hiddenClass), 4344 s.removeClass(e.modifierClass + e.type), 4345 s.removeClass(t.isHorizontal() ? e.horizontalClass : e.verticalClass), 4346 t.pagination.bullets && 4347 t.pagination.bullets.removeClass && 4348 t.pagination.bullets.removeClass(e.bulletActiveClass), 4349 e.clickable && s.off("click", U(e.bulletClass)); 4350 } 4351 a("init", () => { 4352 !1 === t.params.pagination.enabled ? f() : (h(), u(), p()); 4353 }), 4354 a("activeIndexChange", () => { 4355 (t.params.loop || void 0 === t.snapIndex) && p(); 4356 }), 4357 a("snapIndexChange", () => { 4358 t.params.loop || p(); 4359 }), 4360 a("slidesLengthChange", () => { 4361 t.params.loop && (u(), p()); 4362 }), 4363 a("snapGridLengthChange", () => { 4364 t.params.loop || (u(), p()); 4365 }), 4366 a("destroy", () => { 4367 m(); 4368 }), 4369 a("enable disable", () => { 4370 const { $el: e } = t.pagination; 4371 e && 4372 e[t.enabled ? "removeClass" : "addClass"]( 4373 t.params.pagination.lockClass 4374 ); 4375 }), 4376 a("lock unlock", () => { 4377 p(); 4378 }), 4379 a("click", (e, s) => { 4380 const a = s.target, 4381 { $el: r } = t.pagination; 4382 if ( 4383 t.params.pagination.el && 4384 t.params.pagination.hideOnClick && 4385 r && 4386 r.length > 0 && 4387 !d(a).hasClass(t.params.pagination.bulletClass) 4388 ) { 4389 if ( 4390 t.navigation && 4391 ((t.navigation.nextEl && a === t.navigation.nextEl) || 4392 (t.navigation.prevEl && a === t.navigation.prevEl)) 4393 ) 4394 return; 4395 const e = r.hasClass(t.params.pagination.hiddenClass); 4396 i(!0 === e ? "paginationShow" : "paginationHide"), 4397 r.toggleClass(t.params.pagination.hiddenClass); 4398 } 4399 }); 4400 const f = () => { 4401 t.$el.addClass(t.params.pagination.paginationDisabledClass), 4402 t.pagination.$el && 4403 t.pagination.$el.addClass( 4404 t.params.pagination.paginationDisabledClass 4405 ), 4406 m(); 4407 }; 4408 Object.assign(t.pagination, { 4409 enable: () => { 4410 t.$el.removeClass(t.params.pagination.paginationDisabledClass), 4411 t.pagination.$el && 4412 t.pagination.$el.removeClass( 4413 t.params.pagination.paginationDisabledClass 4414 ), 4415 h(), 4416 u(), 4417 p(); 4418 }, 4419 disable: f, 4420 render: u, 4421 update: p, 4422 init: h, 4423 destroy: m, 4424 }); 4425 }, 4426 function (e) { 4427 let { swiper: t, extendParams: s, on: i, emit: r }
4427 = e; 4428 const n = a(); 4429 let l, 4430 o, 4431 c, 4432 u, 4433 h = !1, 4434 m = null, 4435 f = null; 4436 function g() { 4437 if (!t.params.scrollbar.el || !t.scrollbar.el) return; 4438 const { scrollbar: e, rtlTranslate: s, progress: a } = t, 4439 { $dragEl: i, $el: r } = e, 4440 n = t.params.scrollbar; 4441 let l = o, 4442 d = (c - o) * a; 4443 s 4444 ? ((d = -d), 4445 d > 0 ? ((l = o - d), (d = 0)) : -d + o > c && (l = c + d)) 4446 : d < 0 4447 ? ((l = o + d), (d = 0)) 4448 : d + o > c && (l = c - d), 4449 t.isHorizontal() 4450 ? (i.transform(`translate3d(${d}px, 0, 0)`), 4451 (i[0].style.width = `${l}px`)) 4452 : (i.transform(`translate3d(0px, ${d}px, 0)`), 4453 (i[0].style.height = `${l}px`)), 4454 n.hide && 4455 (clearTimeout(m), 4456 (r[0].style.opacity = 1), 4457 (m = setTimeout(() => { 4458 (r[0].style.opacity = 0), r.transition(400); 4459 }, 1e3))); 4460 } 4461 function v() { 4462 if (!t.params.scrollbar.el || !t.scrollbar.el) return; 4463 const { scrollbar: e } = t, 4464 { $dragEl: s, $el: a } = e; 4465 (s[0].style.width = ""), 4466 (s[0].style.height = ""), 4467 (c = t.isHorizontal() ? a[0].offsetWidth : a[0].offsetHeight), 4468 (u = 4469 t.size / 4470 (t.virtualSize + 4471 t.params.slidesOffsetBefore - 4472 (t.params.centeredSlides ? t.snapGrid[0] : 0))), 4473 (o = 4474 "auto" === t.params.scrollbar.dragSize 4475 ? c * u 4476 : parseInt(t.params.scrollbar.dragSize, 10)), 4477 t.isHorizontal() 4478 ? (s[0].style.width = `${o}px`) 4479 : (s[0].style.height = `${o}px`), 4480 (a[0].style.display = u >= 1 ? "none" : ""), 4481 t.params.scrollbar.hide && (a[0].style.opacity = 0), 4482 t.params.watchOverflow && 4483 t.enabled && 4484 e.$el[t.isLocked ? "addClass" : "removeClass"]( 4485 t.params.scrollbar.lockClass 4486 ); 4487 } 4488 function w(e) { 4489 return t.isHorizontal() 4490 ? "touchstart" === e.type || "touchmove" === e.type 4491 ? e.targetTouches[0].clientX 4492 : e.clientX 4493 : "touchstart" === e.type || "touchmove" === e.type 4494 ? e.targetTouches[0].clientY 4495 : e.clientY; 4496 } 4497 function b(e) { 4498 const { scrollbar: s, rtlTranslate: a } = t, 4499 { $el: i } = s; 4500 let r; 4501 (r = 4502 (w(e) - 4503 i.offset()[t.isHorizontal() ? "left" : "top"] - 4504 (null !== l ? l : o / 2)) / 4505 (c - o)), 4506 (r = Math.max(Math.min(r, 1), 0)), 4507 a && (r = 1 - r); 4508 const n = t.minTranslate() + (t.maxTranslate() - t.minTranslate()) * r; 4509 t.updateProgress(n), 4510 t.setTranslate(n), 4511 t.updateActiveIndex(), 4512 t.updateSlidesClasses(); 4513 } 4514 function x(e) { 4515 const s = t.params.scrollbar, 4516 { scrollbar: a, $wrapperEl: i } = t, 4517 { $el: n, $dragEl: o } = a; 4518 (h = !0), 4519 (l = 4520 e.target === o[0] || e.target === o 4521 ? w(e) - 4522 e.target.getBoundingClientRect()[ 4523 t.isHorizontal() ? "left" : "top" 4524 ] 4525 : null), 4526 e.preventDefault(), 4527 e.stopPropagation(), 4528 i.transition(100), 4529 o.transition(100), 4530 b(e), 4531 clearTimeout(f), 4532 n.transition(0), 4533 s.hide && n.css("opacity", 1), 4534 t.params.cssMode && t.$wrapperEl.css("scroll-snap-type", "none"), 4535 r("scrollbarDragStart", e); 4536 } 4537 function y(e) { 4538 const { scrollbar: s, $wrapperEl: a } = t, 4539 { $el: i, $dragEl: n } = s; 4540 h && 4541 (e.preventDefault ? e.preventDefault() : (e.returnValue = !1), 4542 b(e), 4543 a.transition(0), 4544 i.transition(0), 4545 n.transition(0), 4546 r("scrollbarDragMove", e)); 4547 } 4548 function E(e) { 4549 const s = t.params.scrollbar, 4550 { scrollbar: a, $wrapperEl: i } = t, 4551 { $el: n } = a; 4552 h && 4553 ((h = !1), 4554 t.params.cssMode && 4555 (t.$wrapperEl.css("scroll-snap-type", ""), i.transition("")), 4556 s.hide && 4557 (clearTimeout(f), 4558 (f = p(() => { 4559 n.css("opacity", 0), n.transition(400); 4560 }, 1e3))), 4561 r("scrollbarDragEnd", e), 4562 s.snapOnRelease && t.slideToClosest()); 4563 } 4564 function C(e) { 4565 const { 4566 scrollbar: s, 4567 touchEventsTouch: a, 4568 touchEventsDesktop: i, 4569 params: r, 4570 support: l, 4571 } = t, 4572 o = s.$el; 4573 if (!o) return; 4574 const d = o[0], 4575 c = !(!l.passiveListener || !r.passiveListeners) && { 4576 passive: !1, 4577 capture: !1, 4578 }, 4579 p = !(!l.passiveListener || !r.passiveListeners) && { 4580 passive: !0, 4581 capture: !1, 4582 }; 4583 if (!d) return; 4584 const u = "on" === e ? "addEventListener" : "removeEventListener"; 4585 l.touch 4586 ? (d[u](a.start, x, c), d[u](a.move, y, c), d[u](a.end, E, p)) 4587 : (d[u](i.start, x, c), n[u](i.move, y, c), n[u](i.end, E, p)); 4588 } 4589 function T() { 4590 const { scrollbar: e, $el: s } = t; 4591 t.params.scrollbar = F( 4592 t, 4593 t.originalParams.scrollbar, 4594 t.params.scrollbar, 4595 { el: "swiper-scrollbar" } 4596 ); 4597 const a = t.params.scrollbar; 4598 if (!a.el) return; 4599 let i = d(a.el); 4600 t.params.uniqueNavElements && 4601 "string" == typeof a.el && 4602 i.length > 1 && 4603 1 === s.find(a.el).length && 4604 (i = s.find(a.el)), 4605 i.addClass(t.isHorizontal() ? a.horizontalClass : a.verticalClass); 4606 let r = i.find(`.${t.params.scrollbar.dragClass}`); 4607 0 === r.length && 4608 ((r = d(`<div class="${t.params.scrollbar.dragClass}"></div>`)), 4609 i.append(r)), 4610 Object.assign(e, { $el: i, el: i[0], $dragEl: r, dragEl: r[0] }), 4611 a.draggable && t.params.scrollbar.el && t.scrollbar.el && C("on"), 4612 i && 4613 i[t.enabled ? "removeClass" : "addClass"]( 4614 t.params.scrollbar.lockClass 4615 ); 4616 } 4617 function $() { 4618 const e = t.params.scrollbar, 4619 s = t.scrollbar.$el; 4620 s && 4621 s.removeClass(t.isHorizontal() ? e.horizontalClass : e.verticalClass), 4622 t.params.scrollbar.el && t.scrollbar.el && C("off"); 4623 } 4624 s({ 4625 scrollbar: { 4626 el: null, 4627 dragSize: "auto", 4628 hide: !1, 4629 draggable: !1, 4630 snapOnRelease: !0, 4631 lockClass: "swiper-scrollbar-lock", 4632 dragClass: "swiper-scrollbar-drag", 4633 scrollbarDisabledClass: "swiper-scrollbar-disabled", 4634 horizontalClass: "swiper-scrollbar-horizontal", 4635 verticalClass: "swiper-scrollbar-vertical", 4636 }, 4637 }), 4638 (t.scrollbar = { el: null, dragEl: null, $el: null, $dragEl: null }), 4639 i("init", () => { 4640 !1 === t.params.scrollbar.enabled ? S() : (T(), v(), g()); 4641 }), 4642 i("update resize observerUpdate lock unlock", () => { 4643 v(); 4644 }), 4645 i("setTranslate", () => { 4646 g(); 4647 }), 4648 i("setTransition", (e, s) => { 4649 !(function (e) { 4650 t.params.scrollbar.el && 4651 t.scrollbar.el && 4652 t.scrollbar.$dragEl.transition(e); 4653 })(s); 4654 }), 4655 i("enable disable", () => { 4656 const { $el: e } = t.scrollbar; 4657 e && 4658 e[t.enabled ? "removeClass" : "addClass"]( 4659 t.params.scrollbar.lockClass 4660 ); 4661 }), 4662 i("destroy", () => { 4663 $(); 4664 }); 4665 const S = () => { 4666 t.$el.addClass(t.params.scrollbar.scrollbarDisabledClass), 4667 t.scrollbar.$el && 4668 t.scrollbar.$el.addClass(t.params.scrollbar.scrollbarDisabledClass), 4669 $(); 4670 }; 4671 Object.assign(t.scrollbar, { 4672 enable: () => { 4673 t.$el.removeClass(t.params.scrollbar.scrollbarDisabledClass), 4674 t.scrollbar.$el && 4675 t.scrollbar.$el.removeClass( 4676 t.params.scrollbar.scrollbarDisabledClass 4677 ), 4678 T(), 4679 v(), 4680 g(); 4681 }, 4682 disable: S, 4683 updateSize: v, 4684 setTranslate: g, 4685 init: T, 4686 destroy: $, 4687 }); 4688 }, 4689 function (e) { 4690 let { swiper: t, extendParams: s, on: a } = e; 4691 s({ parallax: { enabled: !1 } }); 4692 const i = (e, s) => { 4693 const { rtl: a } = t, 4694 i = d(e), 4695 r = a ? -1 : 1, 4696 n = i.attr("data-swiper-parallax") || "0"; 4697 let l = i.attr("data-swiper-parallax-x"), 4698 o = i.attr("data-swiper-parallax-y"); 4699 const c = i.attr("data-swiper-parallax-scale"), 4700 p = i.attr("data-swiper-parallax-opacity"); 4701 if ( 4702 (l || o 4703 ? ((l = l || "0"), (o = o || "0")) 4704 : t.isHorizontal() 4705 ? ((l = n), (o = "0")) 4706 : ((o = n), (l = "0")), 4707 (l = 4708 l.indexOf("%") >= 0 4709 ? parseInt(l, 10) * s * r + "%" 4710 : l * s * r + "px"), 4711 (o = 4712 o.indexOf("%") >= 0 ? parseInt(o, 10) * s + "%" : o * s + "px"), 4713 null != p) 4714 ) { 4715 const e = p - (p - 1) * (1 - Math.abs(s)); 4716 i[0].style.opacity = e; 4717 } 4718 if (null == c) i.transform(`translate3d(${l}, ${o}, 0px)`); 4719 else { 4720 const e = c - (c - 1) * (1 - Math.abs(s)); 4721 i.transform(`translate3d(${l}, ${o}, 0px) scale(${e})`); 4722 } 4723 }, 4724 r = () => { 4725 const { $el: e, slides: s, progress: a, snapGrid: r } = t; 4726 e 4727 .children( 4728 "[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]" 4729 ) 4730 .each((e) => { 4731 i(e, a); 4732 }), 4733 s.each((e, s) => { 4734 let n = e.progress; 4735 t.params.slidesPerGroup > 1 && 4736 "auto" !== t.params.slidesPerView && 4737 (n += Math.ceil(s / 2) - a * (r.length - 1)), 4738 (n = Math.min(Math.max(n, -1), 1)), 4739 d(e) 4740 .find( 4741 "[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]" 4742 ) 4743 .each((e) => { 4744 i(e, n); 4745 }); 4746 }); 4747 }; 4748 a("beforeInit", () => { 4749 t.params.parallax.enabled && 4750 ((t.params.watchSlidesProgress = !0), 4751 (t.originalParams.watchSlidesProgress = !0)); 4752 }), 4753 a("init", () => { 4754 t.params.parallax.enabled && r(); 4755 }), 4756 a("setTranslate", () => { 4757 t.params.parallax.enabled && r(); 4758 }), 4759 a("setTransition", (e, s) => { 4760 t.params.parallax.enabled && 4761 (function (e) { 4762 void 0 === e && (e = t.params.speed); 4763 const { $el: s } = t; 4764 s.find( 4765 "[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]" 4766 ).each((t) => { 4767 const s = d(t); 4768 let a = 4769 parseInt(s.attr("data-swiper-parallax-duration"), 10) || e; 4770 0 === e && (a = 0), s.transition(a); 4771 }); 4772 })(s); 4773 }); 4774 }, 4775 function (e) { 4776 let { swiper: t, extendParams: s, on: a, emit: i } = e; 4777 const n = r(); 4778 s({ 4779 zoom: { 4780 enabled: !1, 4781 maxRatio: 3, 4782 minRatio: 1, 4783 toggle: !0, 4784 containerClass: "swiper-zoom-container", 4785 zoomedSlideClass: "swiper-slide-zoomed", 4786 }, 4787 }), 4788 (t.zoom = { enabled: !1 }); 4789 let l, 4790 o, 4791 c, 4792 p = 1, 4793 u = !1; 4794 const m = { 4795 $slideEl: void 0, 4796 slideWidth: void 0, 4797 slideHeight: void 0, 4798 $imageEl: void 0, 4799 $imageWrapEl: void 0, 4800 maxRatio: 3, 4801 }, 4802 f = { 4803 isTouched: void 0, 4804 isMoved: void 0, 4805 currentX: void 0, 4806 currentY: void 0, 4807 minX: void 0, 4808 minY: void 0, 4809 maxX: void 0, 4810 maxY: void 0, 4811 width: void 0, 4812 height: void 0, 4813 startX: void 0, 4814 startY: void 0, 4815 touchesStart: {}, 4816 touchesCurrent: {}, 4817 }, 4818 g = { 4819 x: void 0, 4820 y: void 0, 4821 prevPositionX: void 0, 4822 prevPositionY: void 0, 4823 prevTime: void 0, 4824 }; 4825 let v = 1; 4826 function w(e) { 4827 if (e.targetTouches.length < 2) return 1; 4828 const t = e.targetTouches[0].pageX, 4829 s = e.targetTouches[0].pageY, 4830 a = e.targetTouches[1].pageX, 4831 i = e.targetTouches[1].pageY; 4832 return Math.sqrt((a - t) ** 2 + (i - s) ** 2); 4833 } 4834 function b(e) { 4835 const s = t.support, 4836 a = t.params.zoom; 4837 if (((o = !1), (c = !1), !s.gestures)) { 4838 if ( 4839 "touchstart" !== e.type || 4840 ("touchstart" === e.type && e.targetTouches.length < 2) 4841 ) 4842 return; 4843 (o = !0), (m.scaleStart = w(e)); 4844 } 4845 (m.$slideEl && m.$slideEl.length) || 4846 ((m.$slideEl = d(e.target).closest(`.${t.params.slideClass}`)), 4847 0 === m.$slideEl.length && (m.$slideEl = t.slides.eq(t.activeIndex)), 4848 (m.$imageEl = m.$slideEl 4849 .find(`.${a.containerClass}`) 4850 .eq(0) 4851 .find("picture, img, svg, canvas, .swiper-zoom-target") 4852 .eq(0)), 4853 (m.$imageWrapEl = m.$imageEl.parent(`.${a.containerClass}`)), 4854 (m.maxRatio = m.$imageWrapEl.attr("data-swiper-zoom") || a.maxRatio), 4855 0 !== m.$imageWrapEl.length) 4856 ? (m.$imageEl && m.$imageEl.transition(0), (u = !0)) 4857 : (m.$imageEl = void 0); 4858 } 4859 function x(e) { 4860 const s = t.support, 4861 a = t.params.zoom, 4862 i = t.zoom; 4863 if (!s.gestures) { 4864 if ( 4865 "touchmove" !== e.type || 4866 ("touchmove" === e.type && e.targetTouches.length < 2) 4867 ) 4868 return; 4869 (c = !0), (m.scaleMove = w(e)); 4870 } 4871 m.$imageEl && 0 !== m.$imageEl.length 4872 ? (s.gestures 4873 ? (i.scale = e.scale * p) 4874 : (i.scale = (m.scaleMove / m.scaleStart) * p), 4875 i.scale > m.maxRatio && 4876 (i.scale = m.maxRatio - 1 + (i.scale - m.maxRatio + 1) ** 0.5), 4877 i.scale < a.minRatio && 4878 (i.scale = a.minRatio + 1 - (a.minRatio - i.scale + 1) ** 0.5),
4879 m.$imageEl.transform(`translate3d(0,0,0) scale(${i.scale})`)) 4880 : "gesturechange" === e.type && b(e); 4881 } 4882 function y(e) { 4883 const s = t.device, 4884 a = t.support, 4885 i = t.params.zoom, 4886 r = t.zoom; 4887 if (!a.gestures) { 4888 if (!o || !c) return; 4889 if ( 4890 "touchend" !== e.type || 4891 ("touchend" === e.type && e.changedTouches.length < 2 && !s.android) 4892 ) 4893 return; 4894 (o = !1), (c = !1); 4895 } 4896 m.$imageEl && 4897 0 !== m.$imageEl.length && 4898 ((r.scale = Math.max(Math.min(r.scale, m.maxRatio), i.minRatio)), 4899 m.$imageEl 4900 .transition(t.params.speed) 4901 .transform(`translate3d(0,0,0) scale(${r.scale})`), 4902 (p = r.scale), 4903 (u = !1), 4904 1 === r.scale && (m.$slideEl = void 0)); 4905 } 4906 function E(e) { 4907 const s = t.zoom; 4908 if (!m.$imageEl || 0 === m.$imageEl.length) return; 4909 if (((t.allowClick = !1), !f.isTouched || !m.$slideEl)) return; 4910 f.isMoved || 4911 ((f.width = m.$imageEl[0].offsetWidth), 4912 (f.height = m.$imageEl[0].offsetHeight), 4913 (f.startX = h(m.$imageWrapEl[0], "x") || 0), 4914 (f.startY = h(m.$imageWrapEl[0], "y") || 0), 4915 (m.slideWidth = m.$slideEl[0].offsetWidth), 4916 (m.slideHeight = m.$slideEl[0].offsetHeight), 4917 m.$imageWrapEl.transition(0)); 4918 const a = f.width * s.scale, 4919 i = f.height * s.scale; 4920 if (!(a < m.slideWidth && i < m.slideHeight)) { 4921 if ( 4922 ((f.minX = Math.min(m.slideWidth / 2 - a / 2, 0)), 4923 (f.maxX = -f.minX), 4924 (f.minY = Math.min(m.slideHeight / 2 - i / 2, 0)), 4925 (f.maxY = -f.minY), 4926 (f.touchesCurrent.x = 4927 "touchmove" === e.type ? e.targetTouches[0].pageX : e.pageX), 4928 (f.touchesCurrent.y = 4929 "touchmove" === e.type ? e.targetTouches[0].pageY : e.pageY), 4930 !f.isMoved && !u) 4931 ) { 4932 if ( 4933 t.isHorizontal() && 4934 ((Math.floor(f.minX) === Math.floor(f.startX) && 4935 f.touchesCurrent.x < f.touchesStart.x) || 4936 (Math.floor(f.maxX) === Math.floor(f.startX) && 4937 f.touchesCurrent.x > f.touchesStart.x)) 4938 ) 4939 return void (f.isTouched = !1); 4940 if ( 4941 !t.isHorizontal() && 4942 ((Math.floor(f.minY) === Math.floor(f.startY) && 4943 f.touchesCurrent.y < f.touchesStart.y) || 4944 (Math.floor(f.maxY) === Math.floor(f.startY) && 4945 f.touchesCurrent.y > f.touchesStart.y)) 4946 ) 4947 return void (f.isTouched = !1); 4948 } 4949 e.cancelable && e.preventDefault(), 4950 e.stopPropagation(), 4951 (f.isMoved = !0), 4952 (f.currentX = f.touchesCurrent.x - f.touchesStart.x + f.startX), 4953 (f.currentY = f.touchesCurrent.y - f.touchesStart.y + f.startY), 4954 f.currentX < f.minX && 4955 (f.currentX = f.minX + 1 - (f.minX - f.currentX + 1) ** 0.8), 4956 f.currentX > f.maxX && 4957 (f.currentX = f.maxX - 1 + (f.currentX - f.maxX + 1) ** 0.8), 4958 f.currentY < f.minY && 4959 (f.currentY = f.minY + 1 - (f.minY - f.currentY + 1) ** 0.8), 4960 f.currentY > f.maxY && 4961 (f.currentY = f.maxY - 1 + (f.currentY - f.maxY + 1) ** 0.8), 4962 g.prevPositionX || (g.prevPositionX = f.touchesCurrent.x), 4963 g.prevPositionY || (g.prevPositionY = f.touchesCurrent.y), 4964 g.prevTime || (g.prevTime = Date.now()), 4965 (g.x = 4966 (f.touchesCurrent.x - g.prevPositionX) / 4967 (Date.now() - g.prevTime) / 4968 2), 4969 (g.y = 4970 (f.touchesCurrent.y - g.prevPositionY) / 4971 (Date.now() - g.prevTime) / 4972 2), 4973 Math.abs(f.touchesCurrent.x - g.prevPositionX) < 2 && (g.x = 0), 4974 Math.abs(f.touchesCurrent.y - g.prevPositionY) < 2 && (g.y = 0), 4975 (g.prevPositionX = f.touchesCurrent.x), 4976 (g.prevPositionY = f.touchesCurrent.y), 4977 (g.prevTime = Date.now()), 4978 m.$imageWrapEl.transform( 4979 `translate3d(${f.currentX}px, ${f.currentY}px,0)` 4980 ); 4981 } 4982 } 4983 function C() { 4984 const e = t.zoom; 4985 m.$slideEl && 4986 t.previousIndex !== t.activeIndex && 4987 (m.$imageEl && m.$imageEl.transform("translate3d(0,0,0) scale(1)"), 4988 m.$imageWrapEl && m.$imageWrapEl.transform("translate3d(0,0,0)"), 4989 (e.scale = 1), 4990 (p = 1), 4991 (m.$slideEl = void 0), 4992 (m.$imageEl = void 0), 4993 (m.$imageWrapEl = void 0)); 4994 } 4995 function T(e) { 4996 const s = t.zoom, 4997 a = t.params.zoom; 4998 if ( 4999 (m.$slideEl || 5000 (e && 5001 e.target && 5002 (m.$slideEl = d(e.target).closest(`.${t.params.slideClass}`)), 5003 m.$slideEl || 5004 (t.params.virtual && t.params.virtual.enabled && t.virtual 5005 ? (m.$slideEl = t.$wrapperEl.children( 5006 `.${t.params.slideActiveClass}` 5007 )) 5008 : (m.$slideEl = t.slides.eq(t.activeIndex))), 5009 (m.$imageEl = m.$slideEl 5010 .find(`.${a.containerClass}`) 5011 .eq(0) 5012 .find("picture, img, svg, canvas, .swiper-zoom-target") 5013 .eq(0)), 5014 (m.$imageWrapEl = m.$imageEl.parent(`.${a.containerClass}`))), 5015 !m.$imageEl || 5016 0 === m.$imageEl.length || 5017 !m.$imageWrapEl || 5018 0 === m.$imageWrapEl.length) 5019 ) 5020 return; 5021 let i, r, l, o, c, u, h, g, v, w, b, x, y, E, C, T, $, S; 5022 t.params.cssMode && 5023 ((t.wrapperEl.style.overflow = "hidden"), 5024 (t.wrapperEl.style.touchAction = "none")), 5025 m.$slideEl.addClass(`${a.zoomedSlideClass}`), 5026 void 0 === f.touchesStart.x && e 5027 ? ((i = 5028 "touchend" === e.type ? e.changedTouches[0].pageX : e.pageX), 5029 (r = "touchend" === e.type ? e.changedTouches[0].pageY : e.pageY)) 5030 : ((i = f.touchesStart.x), (r = f.touchesStart.y)), 5031 (s.scale = m.$imageWrapEl.attr("data-swiper-zoom") || a.maxRatio), 5032 (p = m.$imageWrapEl.attr("data-swiper-zoom") || a.maxRatio), 5033 e 5034 ? (($ = m.$slideEl[0].offsetWidth), 5035 (S = m.$slideEl[0].offsetHeight), 5036 (l = m.$slideEl.offset().left + n.scrollX), 5037 (o = m.$slideEl.offset().top + n.scrollY), 5038 (c = l + $ / 2 - i), 5039 (u = o + S / 2 - r), 5040 (v = m.$imageEl[0].offsetWidth), 5041 (w = m.$imageEl[0].offsetHeight), 5042 (b = v * s.scale), 5043 (x = w * s.scale), 5044 (y = Math.min($ / 2 - b / 2, 0)), 5045 (E = Math.min(S / 2 - x / 2, 0)), 5046 (C = -y), 5047 (T = -E),
5048 (h = c * s.scale), 5049 (g = u * s.scale), 5050 h < y && (h = y), 5051 h > C && (h = C), 5052 g < E && (g = E), 5053 g > T && (g = T)) 5054 : ((h = 0), (g = 0)), 5055 m.$imageWrapEl 5056 .transition(300) 5057 .transform(`translate3d(${h}px, ${g}px,0)`), 5058 m.$imageEl 5059 .transition(300) 5060 .transform(`translate3d(0,0,0) scale(${s.scale})`); 5061 } 5062 function $() { 5063 const e = t.zoom, 5064 s = t.params.zoom; 5065 m.$slideEl || 5066 (t.params.virtual && t.params.virtual.enabled && t.virtual 5067 ? (m.$slideEl = t.$wrapperEl.children( 5068 `.${t.params.slideActiveClass}` 5069 )) 5070 : (m.$slideEl = t.slides.eq(t.activeIndex)), 5071 (m.$imageEl = m.$slideEl 5072 .find(`.${s.containerClass}`) 5073 .eq(0) 5074 .find("picture, img, svg, canvas, .swiper-zoom-target") 5075 .eq(0)), 5076 (m.$imageWrapEl = m.$imageEl.parent(`.${s.containerClass}`))), 5077 m.$imageEl && 5078 0 !== m.$imageEl.length && 5079 m.$imageWrapEl && 5080 0 !== m.$imageWrapEl.length && 5081 (t.params.cssMode && 5082 ((t.wrapperEl.style.overflow = ""), 5083 (t.wrapperEl.style.touchAction = "")), 5084 (e.scale = 1), 5085 (p = 1), 5086 m.$imageWrapEl.transition(300).transform("translate3d(0,0,0)"), 5087 m.$imageEl.transition(300).transform("translate3d(0,0,0) scale(1)"), 5088 m.$slideEl.removeClass(`${s.zoomedSlideClass}`), 5089 (m.$slideEl = void 0)); 5090 } 5091 function S(e) { 5092 const s = t.zoom; 5093 s.scale && 1 !== s.scale ? $() : T(e); 5094 } 5095 function M() { 5096 const e = t.support; 5097 return { 5098 passiveListener: !( 5099 "touchstart" !== t.touchEvents.start || 5100 !e.passiveListener || 5101 !t.params.passiveListeners 5102 ) && { passive: !0, capture: !1 }, 5103 activeListenerWithCapture: !e.passiveListener || { 5104 passive: !1, 5105 capture: !0, 5106 }, 5107 }; 5108 } 5109 function P() { 5110 return `.${t.params.slideClass}`; 5111 } 5112 function k(e) { 5113 const { passiveListener: s } = M(), 5114 a = P(); 5115 t.$wrapperEl[e]("gesturestart", a, b, s), 5116 t.$wrapperEl[e]("gesturechange", a, x, s), 5117 t.$wrapperEl[e]("gestureend", a, y, s); 5118 } 5119 function z() { 5120 l || ((l = !0), k("on")); 5121 } 5122 function L() { 5123 l && ((l = !1), k("off")); 5124 } 5125 function O() { 5126 const e = t.zoom; 5127 if (e.enabled) return; 5128 e.enabled = !0; 5129 const s = t.support, 5130 { passiveListener: a, activeListenerWithCapture: i } = M(), 5131 r = P(); 5132 s.gestures 5133 ? (t.$wrapperEl.on(t.touchEvents.start, z, a), 5134 t.$wrapperEl.on(t.touchEvents.end, L, a)) 5135 : "touchstart" === t.touchEvents.start && 5136 (t.$wrapperEl.on(t.touchEvents.start, r, b, a), 5137 t.$wrapperEl.on(t.touchEvents.move, r, x, i), 5138 t.$wrapperEl.on(t.touchEvents.end, r, y, a), 5139 t.touchEvents.cancel && 5140 t.$wrapperEl.on(t.touchEvents.cancel, r, y, a)), 5141 t.$wrapperEl.on( 5142 t.touchEvents.move, 5143 `.${t.params.zoom.containerClass}`, 5144 E, 5145 i 5146 ); 5147 } 5148 function I() { 5149 const e = t.zoom; 5150 if (!e.enabled) return; 5151 const s = t.support; 5152 e.enabled = !1; 5153 const { passiveListener: a, activeListenerWithCapture: i } = M(), 5154 r = P(); 5155 s.gestures 5156 ? (t.$wrapperEl.off(t.touchEvents.start, z, a), 5157 t.$wrapperEl.off(t.touchEvents.end, L, a)) 5158 : "touchstart" === t.touchEvents.start && 5159 (t.$wrapperEl.off(t.touchEvents.start, r, b, a), 5160 t.$wrapperEl.off(t.touchEvents.move, r, x, i), 5161 t.$wrapperEl.off(t.touchEvents.end, r, y, a), 5162 t.touchEvents.cancel && 5163 t.$wrapperEl.off(t.touchEvents.cancel, r, y, a)), 5164 t.$wrapperEl.off( 5165 t.touchEvents.move, 5166 `.${t.params.zoom.containerClass}`, 5167 E, 5168 i 5169 ); 5170 } 5171 Object.defineProperty(t.zoom, "scale", { 5172 get: () => v, 5173 set(e) { 5174 if (v !== e) { 5175 const t = m.$imageEl ? m.$imageEl[0] : void 0, 5176 s = m.$slideEl ? m.$slideEl[0] : void 0; 5177 i("zoomChange", e, t, s); 5178 } 5179 v = e; 5180 }, 5181 }), 5182 a("init", () => { 5183 t.params.zoom.enabled && O(); 5184 }), 5185 a("destroy", () => { 5186 I(); 5187 }), 5188 a("touchStart", (e, s) => { 5189 t.zoom.enabled && 5190 (function (e) { 5191 const s = t.device; 5192 m.$imageEl && 5193 0 !== m.$imageEl.length && 5194 (f.isTouched || 5195 (s.android && e.cancelable && e.preventDefault(), 5196 (f.isTouched = !0), 5197 (f.touchesStart.x = 5198 "touchstart" === e.type 5199 ? e.targetTouches[0].pageX 5200 : e.pageX), 5201 (f.touchesStart.y = 5202 "touchstart" === e.type 5203 ? e.targetTouches[0].pageY 5204 : e.pageY))); 5205 })(s); 5206 }), 5207 a("touchEnd", (e, s) => { 5208 t.zoom.enabled && 5209 (function () { 5210 const e = t.zoom; 5211 if (!m.$imageEl || 0 === m.$imageEl.length) return; 5212 if (!f.isTouched || !f.isMoved) 5213 return (f.isTouched = !1), void (f.isMoved = !1); 5214 (f.isTouched = !1), (f.isMoved = !1); 5215 let s = 300, 5216 a = 300; 5217 const i = g.x * s, 5218 r = f.currentX + i, 5219 n = g.y * a, 5220 l = f.currentY + n; 5221 0 !== g.x && (s = Math.abs((r - f.currentX) / g.x)), 5222 0 !== g.y && (a = Math.abs((l - f.currentY) / g.y)); 5223 const o = Math.max(s, a); 5224 (f.currentX = r), (f.currentY = l); 5225 const d = f.width * e.scale, 5226 c = f.height * e.scale; 5227 (f.minX = Math.min(m.slideWidth / 2 - d / 2, 0)), 5228 (f.maxX = -f.minX), 5229 (f.minY = Math.min(m.slideHeight / 2 - c / 2, 0)), 5230 (f.maxY = -f.minY), 5231 (f.currentX = Math.max(Math.min(f.currentX, f.maxX), f.minX)), 5232 (f.currentY = Math.max(Math.min(f.currentY, f.maxY), f.minY)), 5233 m.$imageWrapEl 5234 .transition(o) 5235 .transform(`translate3d(${f.currentX}px, ${f.currentY}px,0)`); 5236 })(); 5237 }), 5238 a("doubleTap", (e, s) => { 5239 !t.animating && 5240 t.params.zoom.enabled && 5241 t.zoom.enabled && 5242 t.params.zoom.toggle && 5243 S(s); 5244 }), 5245 a("transitionEnd", () => { 5246 t.zoom.enabled && t.params.zoom.enabled && C(); 5247 }), 5248 a("slideChange", () => { 5249 t.zoom.enabled && t.params.zoom.enabled && t.params.cssMode && C(); 5250 }), 5251 Object.assign(t.zoom, { 5252 enable: O, 5253 disable: I, 5254 in: T, 5255 out: $, 5256 toggle: S, 5257 }); 5258 }, 5259 function (e) { 5260 let { swiper: t, extendParams: s, on: a, emit: i } = e; 5261 s({ 5262 lazy: { 5263 checkInView: !1, 5264 enabled: !1, 5265 loadPrevNext: !1, 5266 loadPrevNextAmount: 1, 5267 loadOnTransitionStart: !1, 5268 scrollingElement: "", 5269 elementClass: "swiper-lazy", 5270 loadingClass: "swiper-lazy-loading", 5271 loadedClass: "swiper-lazy-loaded", 5272 preloaderClass: "swiper-lazy-preloader", 5273 }, 5274 }), 5275 (t.lazy = {}); 5276 let n = !1, 5277 l = !1; 5278 function o(e, s) { 5279 void 0 === s && (s = !0); 5280 const a = t.params.lazy; 5281 if (void 0 === e) return; 5282 if (0 === t.slides.length) return; 5283 const r = 5284 t.virtual && t.params.virtual.enabled 5285 ? t.$wrapperEl.children( 5286 `.${t.params.slideClass}[data-swiper-slide-index="${e}"]` 5287 ) 5288 : t.slides.eq(e), 5289 n = r.find( 5290 `.${a.elementClass}:not(.${a.loadedClass}):not(.${a.loadingClass})` 5291 ); 5292 !r.hasClass(a.elementClass) || 5293 r.hasClass(a.loadedClass) || 5294 r.hasClass(a.loadingClass) || 5295 n.push(r[0]), 5296 0 !== n.length && 5297 n.each((e) => { 5298 const n = d(e); 5299 n.addClass(a.loadingClass); 5300 const l = n.attr("data-background"), 5301 c = n.attr("data-src"), 5302 p = n.attr("data-srcset"), 5303 u = n.attr("data-sizes"), 5304 h = n.parent("picture"); 5305 t.loadImage(n[0], c || l, p, u, !1, () => { 5306 if (null != t && t && (!t || t.params) && !t.destroyed) { 5307 if ( 5308 (l 5309 ? (n.css("background-image", `url("${l}")`), 5310 n.removeAttr("data-background")) 5311 : (p && 5312 (n.attr("srcset", p), n.removeAttr("data-srcset")), 5313 u && (n.attr("sizes", u), n.removeAttr("data-sizes")), 5314 h.length && 5315 h.children("source").each((e) => { 5316 const t = d(e); 5317 t.attr("data-srcset") && 5318 (t.attr("srcset", t.attr("data-srcset")), 5319 t.removeAttr("data-srcset")); 5320 }), 5321 c && (n.attr("src", c), n.removeAttr("data-src"))), 5322 n.addClass(a.loadedClass).removeClass(a.loadingClass), 5323 r.find(`.${a.preloaderClass}`).remove(), 5324 t.params.loop && s) 5325 ) { 5326 const e = r.attr("data-swiper-slide-index"); 5327 if (r.hasClass(t.params.slideDuplicateClass)) { 5328 o( 5329 t.$wrapperEl 5330 .children( 5331 `[data-swiper-slide-index="${e}"]:not(.${t.params.slideDuplicateClass})` 5332 ) 5333 .index(), 5334 !1 5335 ); 5336 } else { 5337 o( 5338 t.$wrapperEl 5339 .children( 5340 `.${t.params.slideDuplicateClass}[data-swiper-slide-index="${e}"]` 5341 ) 5342 .index(), 5343 !1 5344 ); 5345 } 5346 } 5347 i("lazyImageReady", r[0], n[0]), 5348 t.params.autoHeight && t.updateAutoHeight(); 5349 } 5350 }), 5351 i("lazyImageLoad", r[0], n[0]); 5352 }); 5353 } 5354 function c() { 5355 const { $wrapperEl: e, params: s, slides: a, activeIndex: i } = t, 5356 r = t.virtual && s.virtual.enabled, 5357 n = s.lazy; 5358 let c = s.slidesPerView; 5359 function p(t) { 5360 if (r) { 5361 if ( 5362 e.children(`.${s.slideClass}[data-swiper-slide-index="${t}"]`) 5363 .length 5364 ) 5365 return !0; 5366 } else if (a[t]) return !0; 5367 return !1; 5368 } 5369 function u(e) { 5370 return r ? d(e).attr("data-swiper-slide-index") : d(e).index(); 5371 } 5372 if ( 5373 ("auto" === c && (c = 0), l || (l = !0), t.params.watchSlidesProgress) 5374 ) 5375 e.children(`.${s.slideVisibleClass}`).each((e) => { 5376 o(r ? d(e).attr("data-swiper-slide-index") : d(e).index()); 5377 }); 5378 else if (c > 1) for (let e = i; e < i + c; e += 1) p(e) && o(e); 5379 else o(i); 5380 if (n.loadPrevNext) 5381 if (c > 1 || (n.loadPrevNextAmount && n.loadPrevNextAmount > 1)) { 5382 const e = n.loadPrevNextAmount,
vendor: 1,237 bytes, lines 5383-5422
5383 t = Math.ceil(c), 5384 s = Math.min(i + t + Math.max(e, t), a.length), 5385 r = Math.max(i - Math.max(t, e), 0); 5386 for (let e = i + t; e < s; e += 1) p(e) && o(e); 5387 for (let e = r; e < i; e += 1) p(e) && o(e); 5388 } else { 5389 const t = e.children(`.${s.slideNextClass}`); 5390 t.length > 0 && o(u(t)); 5391 const a = e.children(`.${s.slidePrevClass}`); 5392 a.length > 0 && o(u(a)); 5393 } 5394 } 5395 function p() { 5396 const e = r(); 5397 if (!t || t.destroyed) return; 5398 const s = t.params.lazy.scrollingElement 5399 ? d(t.params.lazy.scrollingElement) 5400 : d(e), 5401 a = s[0] === e, 5402 i = a ? e.innerWidth : s[0].offsetWidth, 5403 l = a ? e.innerHeight : s[0].offsetHeight, 5404 o = t.$el.offset(), 5405 { rtlTranslate: u } = t; 5406 let h = !1; 5407 u && (o.left -= t.$el[0].scrollLeft); 5408 const m = [ 5409 [o.left, o.top], 5410 [o.left + t.width, o.top], 5411 [o.left, o.top + t.height], 5412 [o.left + t.width, o.top + t.height], 5413 ]; 5414 for (let e = 0; e < m.length; e += 1) { 5415 const t = m[e]; 5416 if (t[0] >= 0 && t[0] <= i && t[1] >= 0 && t[1] <= l) { 5417 if (0 === t[0] && 0 === t[1]) continue; 5418 h = !0; 5419 } 5420 } 5421 const f = !( 5422 "touchstart" !== t.touchEvents.start ||
5423 !t.support.passiveListener || 5424 !t.params.passiveListeners 5425 ) && { passive: !0, capture: !1 }; 5426 h 5427 ? (c(), s.off("scroll", p, f)) 5428 : n || ((n = !0), s.on("scroll", p, f)); 5429 } 5430 a("beforeInit", () => { 5431 t.params.lazy.enabled && 5432 t.params.preloadImages && 5433 (t.params.preloadImages = !1); 5434 }), 5435 a("init", () => { 5436 t.params.lazy.enabled && (t.params.lazy.checkInView ? p() : c()); 5437 }), 5438 a("scroll", () => { 5439 t.params.freeMode && 5440 t.params.freeMode.enabled && 5441 !t.params.freeMode.sticky && 5442 c(); 5443 }), 5444 a("scrollbarDragMove resize _freeModeNoMomentumRelease", () => { 5445 t.params.lazy.enabled && (t.params.lazy.checkInView ? p() : c()); 5446 }), 5447 a("transitionStart", () => { 5448 t.params.lazy.enabled && 5449 (t.params.lazy.loadOnTransitionStart || 5450 (!t.params.lazy.loadOnTransitionStart && !l)) && 5451 (t.params.lazy.checkInView ? p() : c()); 5452 }), 5453 a("transitionEnd", () => { 5454 t.params.lazy.enabled && 5455 !t.params.lazy.loadOnTransitionStart && 5456 (t.params.lazy.checkInView ? p() : c()); 5457 }), 5458 a("slideChange", () => { 5459 const { 5460 lazy: e, 5461 cssMode: s, 5462 watchSlidesProgress: a, 5463 touchReleaseOnEdges: i, 5464 resistanceRatio: r, 5465 } = t.params; 5466 e.enabled && (s || (a && (i || 0 === r))) && c(); 5467 }), 5468 a("destroy", () => { 5469 t.$el && 5470 t.$el 5471 .find(`.${t.params.lazy.loadingClass}`) 5472 .removeClass(t.params.lazy.loadingClass); 5473 }), 5474 Object.assign(t.lazy, { load: c, loadInSlide: o }); 5475 }, 5476 function (e) { 5477 let { swiper: t, extendParams: s, on: a } = e; 5478 function i(e, t) { 5479 const s = (function () { 5480 let e, t, s; 5481 return (a, i) => { 5482 for (t = -1, e = a.length; e - t > 1; ) 5483 (s = (e + t) >> 1), a[s] <= i ? (t = s) : (e = s); 5484 return e; 5485 }; 5486 })(); 5487 let a, i; 5488 return ( 5489 (this.x = e), 5490 (this.y = t), 5491 (this.lastIndex = e.length - 1), 5492 (this.interpolate = function (e) { 5493 return e 5494 ? ((i = s(this.x, e)), 5495 (a = i - 1), 5496 ((e - this.x[a]) * (this.y[i] - this.y[a])) / 5497 (this.x[i] - this.x[a]) + 5498 this.y[a]) 5499 : 0; 5500 }), 5501 this 5502 ); 5503 } 5504 function r() { 5505 t.controller.control && 5506 t.controller.spline && 5507 ((t.controller.spline = void 0), delete t.controller.spline); 5508 } 5509 s({ controller: { control: void 0, inverse: !1, by: "slide" } }), 5510 (t.controller = { control: void 0 }), 5511 a("beforeInit", () => { 5512 t.controller.control = t.params.controller.control; 5513 }), 5514 a("update", () => { 5515 r(); 5516 }), 5517 a("resize", () => { 5518 r(); 5519 }), 5520 a("observerUpdate", () => { 5521 r(); 5522 }), 5523 a("setTranslate", (e, s, a) => { 5524 t.controller.control && t.controller.setTranslate(s, a); 5525 }), 5526 a("setTransition", (e, s, a) => { 5527 t.controller.control && t.controller.setTransition(s, a); 5528 }), 5529 Object.assign(t.controller, { 5530 setTranslate: function (e, s) { 5531 const a = t.controller.control; 5532 let r, n; 5533 const l = t.constructor; 5534 function o(e) { 5535 const s = t.rtlTranslate ? -t.translate : t.translate; 5536 "slide" === t.params.controller.by && 5537 (!(function (e) { 5538 t.controller.spline || 5539 (t.controller.spline = t.params.loop 5540 ? new i(t.slidesGrid, e.slidesGrid) 5541 : new i(t.snapGrid, e.snapGrid)); 5542 })(e), 5543 (n = -t.controller.spline.interpolate(-s))), 5544 (n && "container" !== t.params.controller.by) || 5545 ((r = 5546 (e.maxTranslate() - e.minTranslate()) / 5547 (t.maxTranslate() - t.minTranslate())), 5548 (n = (s - t.minTranslate()) * r + e.minTranslate())), 5549 t.params.controller.inverse && (n = e.maxTranslate() - n), 5550 e.updateProgress(n), 5551 e.setTranslate(n, t), 5552 e.updateActiveIndex(), 5553 e.updateSlidesClasses(); 5554 } 5555 if (Array.isArray(a)) 5556 for (let e = 0; e < a.length; e += 1) 5557 a[e] !== s && a[e] instanceof l && o(a[e]); 5558 else a instanceof l && s !== a && o(a); 5559 }, 5560 setTransition: function (e, s) { 5561 const a = t.constructor, 5562 i = t.controller.control; 5563 let r; 5564 function n(s) { 5565 s.setTransition(e, t), 5566 0 !== e && 5567 (s.transitionStart(), 5568 s.params.autoHeight && 5569 p(() => { 5570 s.updateAutoHeight(); 5571 }), 5572 s.$wrapperEl.transitionEnd(() => { 5573 i && 5574 (s.params.loop && 5575 "slide" === t.params.controller.by && 5576 s.loopFix(), 5577 s.transitionEnd()); 5578 })); 5579 } 5580 if (Array.isArray(i)) 5581 for (r = 0; r < i.length; r += 1) 5582 i[r] !== s && i[r] instanceof a && n(i[r]); 5583 else i instanceof a && s !== i && n(i); 5584 }, 5585 }); 5586 }, 5587 function (e) { 5588 let { swiper: t, extendParams: s, on: a } = e; 5589 s({ 5590 a11y: { 5591 enabled: !0, 5592 notificationClass: "swiper-notification", 5593 prevSlideMessage: "Previous slide", 5594 nextSlideMessage: "Next slide", 5595 firstSlideMessage: "This is the first slide", 5596 lastSlideMessage: "This is the last slide", 5597 paginationBulletMessage: "Go to slide {{index}}", 5598 slideLabelMessage: "{{index}} / {{slidesLength}}", 5599 containerMessage: null, 5600 containerRoleDescriptionMessage: null, 5601 itemRoleDescriptionMessage: null, 5602 slideRole: "group", 5603 id: null, 5604 }, 5605 }), 5606 (t.a11y = { clicked: !1 }); 5607 let i = null; 5608 function r(e) { 5609 const t = i; 5610 0 !== t.length && (t.html(""), t.html(e)); 5611 } 5612 function n(e) { 5613 e.attr("tabIndex", "0"); 5614 } 5615 function l(e) { 5616 e.attr("tabIndex", "-1"); 5617 } 5618 function o(e, t) { 5619 e.attr("role", t); 5620 } 5621 function c(e, t) { 5622 e.attr("aria-roledescription", t); 5623 } 5624 function p(e, t) { 5625 e.attr("aria-label", t); 5626 } 5627 function u(e) { 5628 e.attr("aria-disabled", !0); 5629 } 5630 function h(e) { 5631 e.attr("aria-disabled", !1); 5632 } 5633 function m(e) { 5634 if (13 !== e.keyCode && 32 !== e.keyCode) return; 5635 const s = t.params.a11y, 5636 a = d(e.target); 5637 t.navigation && 5638 t.navigation.$nextEl && 5639 a.is(t.navigation.$nextEl) && 5640 ((t.isEnd && !t.params.loop) || t.slideNext(), 5641 t.isEnd ? r(s.lastSlideMessage) : r(s.nextSlideMessage)), 5642 t.navigation && 5643 t.navigation.$prevEl && 5644 a.is(t.navigation.$prevEl) && 5645 ((t.isBeginning && !t.params.loop) || t.slidePrev(), 5646 t.isBeginning ? r(s.firstSlideMessage) : r(s.prevSlideMessage)), 5647 t.pagination && 5648 a.is(U(t.params.pagination.bulletClass)) && 5649 a[0].click(); 5650 } 5651 function f() { 5652 return ( 5653 t.pagination && t.pagination.bullets && t.pagination.bullets.length 5654 ); 5655 } 5656 function g() { 5657 return f() && t.params.pagination.clickable; 5658 } 5659 const v = (e, t, s) => { 5660 n(e),
5661 "BUTTON" !== e[0].tagName && (o(e, "button"), e.on("keydown", m)), 5662 p(e, s), 5663 (function (e, t) { 5664 e.attr("aria-controls", t); 5665 })(e, t); 5666 }, 5667 w = () => { 5668 t.a11y.clicked = !0; 5669 }, 5670 b = () => { 5671 t.a11y.clicked = !1; 5672 }, 5673 x = (e) => { 5674 if (t.a11y.clicked) return; 5675 const s = e.target.closest(`.${t.params.slideClass}`); 5676 if (!s || !t.slides.includes(s)) return; 5677 const a = t.slides.indexOf(s) === t.activeIndex, 5678 i = 5679 t.params.watchSlidesProgress && 5680 t.visibleSlides && 5681 t.visibleSlides.includes(s); 5682 a || 5683 i || 5684 (t.isHorizontal() ? (t.el.scrollLeft = 0) : (t.el.scrollTop = 0), 5685 t.slideTo(t.slides.indexOf(s), 0)); 5686 }, 5687 y = () => { 5688 const e = t.params.a11y; 5689 e.itemRoleDescriptionMessage && 5690 c(d(t.slides), e.itemRoleDescriptionMessage), 5691 e.slideRole && o(d(t.slides), e.slideRole); 5692 const s = t.params.loop 5693 ? t.slides.filter( 5694 (e) => !e.classList.contains(t.params.slideDuplicateClass) 5695 ).length 5696 : t.slides.length; 5697 e.slideLabelMessage && 5698 t.slides.each((a, i) => { 5699 const r = d(a), 5700 n = t.params.loop 5701 ? parseInt(r.attr("data-swiper-slide-index"), 10) 5702 : i; 5703 p( 5704 r, 5705 e.slideLabelMessage 5706 .replace(/\{\{index\}\}/, n + 1) 5707 .replace(/\{\{slidesLength\}\}/, s) 5708 ); 5709 }); 5710 }, 5711 E = () => { 5712 const e = t.params.a11y; 5713 t.$el.append(i); 5714 const s = t.$el; 5715 e.containerRoleDescriptionMessage && 5716 c(s, e.containerRoleDescriptionMessage), 5717 e.containerMessage && p(s, e.containerMessage); 5718 const a = t.$wrapperEl, 5719 r = 5720 e.id || 5721 a.attr("id") || 5722 `swiper-wrapper-${ 5723 ((n = 16), 5724 void 0 === n && (n = 16), 5725 "x" 5726 .repeat(n) 5727 .replace(/x/g, () => 5728 Math.round(16 * Math.random()).toString(16) 5729 )) 5730 }`; 5731 var n; 5732 const l = 5733 t.params.autoplay && t.params.autoplay.enabled ? "off" : "polite"; 5734 var o; 5735 let d, u; 5736 (o = r), 5737 a.attr("id", o), 5738 (function (e, t) { 5739 e.attr("aria-live", t); 5740 })(a, l), 5741 y(), 5742 t.navigation && t.navigation.$nextEl && (d = t.navigation.$nextEl), 5743 t.navigation && t.navigation.$prevEl && (u = t.navigation.$prevEl), 5744 d && d.length && v(d, r, e.nextSlideMessage), 5745 u && u.length && v(u, r, e.prevSlideMessage), 5746 g() && 5747 t.pagination.$el.on( 5748 "keydown", 5749 U(t.params.pagination.bulletClass), 5750 m 5751 ), 5752 t.$el.on("focus", x, !0), 5753 t.$el.on("pointerdown", w, !0), 5754 t.$el.on("pointerup", b, !0); 5755 }; 5756 a("beforeInit", () => { 5757 i = d( 5758 `<span class="${t.params.a11y.notificationClass}" aria-live="assertive" aria-atomic="true"></span>` 5759 ); 5760 }), 5761 a("afterInit", () => { 5762 t.params.a11y.enabled && E(); 5763 }), 5764 a( 5765 "slidesLengthChange snapGridLengthChange slidesGridLengthChange", 5766 () => { 5767 t.params.a11y.enabled && y(); 5768 } 5769 ), 5770 a("fromEdge toEdge afterInit lock unlock", () => { 5771 t.params.a11y.enabled && 5772 (function () { 5773 if (t.params.loop || t.params.rewind || !t.navigation) return; 5774 const { $nextEl: e, $prevEl: s } = t.navigation; 5775 s && 5776 s.length > 0 && 5777 (t.isBeginning ? (u(s), l(s)) : (h(s), n(s))), 5778 e && e.length > 0 && (t.isEnd ? (u(e), l(e)) : (h(e), n(e))); 5779 })(); 5780 }), 5781 a("paginationUpdate", () => { 5782 t.params.a11y.enabled && 5783 (function () { 5784 const e = t.params.a11y; 5785 f() && 5786 t.pagination.bullets.each((s) => { 5787 const a = d(s); 5788 t.params.pagination.clickable && 5789 (n(a), 5790 t.params.pagination.renderBullet || 5791 (o(a, "button"), 5792 p( 5793 a, 5794 e.paginationBulletMessage.replace( 5795 /\{\{index\}\}/, 5796 a.index() + 1 5797 ) 5798 ))), 5799 a.is(`.${t.params.pagination.bulletActiveClass}`) 5800 ? a.attr("aria-current", "true") 5801 : a.removeAttr("aria-current"); 5802 }); 5803 })(); 5804 }), 5805 a("destroy", () => { 5806 t.params.a11y.enabled && 5807 (function () { 5808 let e, s; 5809 i && i.length > 0 && i.remove(), 5810 t.navigation && 5811 t.navigation.$nextEl && 5812 (e = t.navigation.$nextEl), 5813 t.navigation && 5814 t.navigation.$prevEl && 5815 (s = t.navigation.$prevEl), 5816 e && e.off("keydown", m), 5817 s && s.off("keydown", m), 5818 g() && 5819 t.pagination.$el.off( 5820 "keydown", 5821 U(t.params.pagination.bulletClass), 5822 m 5823 ), 5824 t.$el.off("focus", x, !0), 5825 t.$el.off("pointerdown", w, !0), 5826 t.$el.off("pointerup", b, !0); 5827 })(); 5828 }); 5829 }, 5830 function (e) { 5831 let { swiper: t, extendParams: s, on: a } = e; 5832 s({ 5833 history: { 5834 enabled: !1, 5835 root: "", 5836 replaceState: !1, 5837 key: "slides", 5838 keepQuery: !1, 5839 }, 5840 }); 5841 let i = !1, 5842 n = {}; 5843 const l = (e) => 5844 e 5845 .toString() 5846 .replace(/\s+/g, "-") 5847 .replace(/[^\w-]+/g, "") 5848 .replace(/--+/g, "-") 5849 .replace(/^-+/, "") 5850 .replace(/-+$/, ""), 5851 o = (e) => { 5852 const t = r(); 5853 let s; 5854 s = e ? new URL(e) : t.location; 5855 const a = s.pathname 5856 .slice(1) 5857 .split("/") 5858 .filter((e) => "" !== e), 5859 i = a.length; 5860 return { key: a[i - 2], value: a[i - 1] }; 5861 }, 5862 d = (e, s) => { 5863 const a = r(); 5864 if (!i || !t.params.history.enabled) return; 5865 let n; 5866 n = t.params.url ? new URL(t.params.url) : a.location; 5867 const o = t.slides.eq(s); 5868 let d = l(o.attr("data-history")); 5869 if (t.params.history.root.length > 0) { 5870 let s = t.params.history.root; 5871 "/" === s[s.length - 1] && (s = s.slice(0, s.length - 1)), 5872 (d = `${s}/${e}/${d}`); 5873 } else n.pathname.includes(e) || (d = `${e}/${d}
5873`); 5874 t.params.history.keepQuery && (d += n.search); 5875 const c = a.history.state; 5876 (c && c.value === d) || 5877 (t.params.history.replaceState 5878 ? a.history.replaceState({ value: d }, null, d) 5879 : a.history.pushState({ value: d }, null, d)); 5880 }, 5881 c = (e, s, a) => { 5882 if (s) 5883 for (let i = 0, r = t.slides.length; i < r; i += 1) { 5884 const r = t.slides.eq(i); 5885 if ( 5886 l(r.attr("data-history")) === s && 5887 !r.hasClass(t.params.slideDuplicateClass) 5888 ) { 5889 const s = r.index(); 5890 t.slideTo(s, e, a); 5891 } 5892 } 5893 else t.slideTo(0, e, a); 5894 }, 5895 p = () => { 5896 (n = o(t.params.url)), c(t.params.speed, n.value, !1); 5897 }; 5898 a("init", () => { 5899 t.params.history.enabled && 5900 (() => { 5901 const e = r(); 5902 if (t.params.history) { 5903 if (!e.history || !e.history.pushState) 5904 return ( 5905 (t.params.history.enabled = !1), 5906 void (t.params.hashNavigation.enabled = !0) 5907 ); 5908 (i = !0), 5909 (n = o(t.params.url)), 5910 (n.key || n.value) && 5911 (c(0, n.value, t.params.runCallbacksOnInit), 5912 t.params.history.replaceState || 5913 e.addEventListener("popstate", p)); 5914 } 5915 })(); 5916 }), 5917 a("destroy", () => { 5918 t.params.history.enabled && 5919 (() => { 5920 const e = r(); 5921 t.params.history.replaceState || 5922 e.removeEventListener("popstate", p); 5923 })(); 5924 }), 5925 a("transitionEnd _freeModeNoMomentumRelease", () => { 5926 i && d(t.params.history.key, t.activeIndex); 5927 }), 5928 a("slideChange", () => { 5929 i && t.params.cssMode && d(t.params.history.key, t.activeIndex); 5930 }); 5931 }, 5932 function (e) { 5933 let { swiper: t, extendParams: s, emit: i, on: n } = e, 5934 l = !1; 5935 const o = a(), 5936 c = r(); 5937 s({ hashNavigation: { enabled: !1, replaceState: !1, watchState: !1 } }); 5938 const p = () => { 5939 i("hashChange"); 5940 const e = o.location.hash.replace("#", ""); 5941 if (e !== t.slides.eq(t.activeIndex).attr("data-hash")) { 5942 const s = t.$wrapperEl 5943 .children(`.${t.params.slideClass}[data-hash="${e}"]`) 5944 .index(); 5945 if (void 0 === s) return; 5946 t.slideTo(s); 5947 } 5948 }, 5949 u = () => { 5950 if (l && t.params.hashNavigation.enabled) 5951 if ( 5952 t.params.hashNavigation.replaceState && 5953 c.history && 5954 c.history.replaceState 5955 ) 5956 c.history.replaceState( 5957 null, 5958 null, 5959 `#${t.slides.eq(t.activeIndex).attr("data-hash")}` || "" 5960 ), 5961 i("hashSet"); 5962 else { 5963 const e = t.slides.eq(t.activeIndex), 5964 s = e.attr("data-hash") || e.attr("data-history"); 5965 (o.location.hash = s || ""), i("hashSet"); 5966 } 5967 }; 5968 n("init", () => { 5969 t.params.hashNavigation.enabled && 5970 (() => { 5971 if ( 5972 !t.params.hashNavigation.enabled || 5973 (t.params.history && t.params.history.enabled) 5974 ) 5975 return; 5976 l = !0; 5977 const e = o.location.hash.replace("#", ""); 5978 if (e) { 5979 const s = 0; 5980 for (let a = 0, i = t.slides.length; a < i; a += 1) { 5981 const i = t.slides.eq(a); 5982 if ( 5983 (i.attr("data-hash") || i.attr("data-history")) === e && 5984 !i.hasClass(t.params.slideDuplicateClass) 5985 ) { 5986 const e = i.index(); 5987 t.slideTo(e, s, t.params.runCallbacksOnInit, !0); 5988 } 5989 } 5990 } 5991 t.params.hashNavigation.watchState && d(c).on("hashchange", p); 5992 })(); 5993 }), 5994 n("destroy", () => { 5995 t.params.hashNavigation.enabled && 5996 t.params.hashNavigation.watchState && 5997 d(c).off("hashchange", p); 5998 }), 5999 n("transitionEnd _freeModeNoMomentumRelease", () => { 6000 l && u(); 6001 }), 6002 n("slideChange", () => { 6003 l && t.params.cssMode && u(); 6004 }); 6005 }, 6006 function (e) { 6007 let t, 6008 { swiper: s, extendParams: i, on: r, emit: n } = e; 6009 function l() { 6010 if (!s.size) 6011 return (s.autoplay.running = !1), void (s.autoplay.paused = !1); 6012 const e = s.slides.eq(s.activeIndex); 6013 let a = s.params.autoplay.delay; 6014 e.attr("data-swiper-autoplay") && 6015 (a = e.attr("data-swiper-autoplay") || s.params.autoplay.delay), 6016 clearTimeout(t), 6017 (t = p(() => { 6018 let e; 6019 s.params.autoplay.reverseDirection 6020 ? s.params.loop 6021 ? (s.loopFix(), 6022 (e = s.slidePrev(s.params.speed, !0, !0)), 6023 n("autoplay")) 6024 : s.isBeginning 6025 ? s.params.autoplay.stopOnLastSlide 6026 ? d() 6027 : ((e = s.slideTo( 6028 s.slides.length - 1, 6029 s.params.speed, 6030 !0, 6031 !0 6032 )), 6033 n("autoplay")) 6034 : ((e = s.slidePrev(s.params.speed, !0, !0)), n("autoplay")) 6035 : s.params.loop 6036 ? (s.loopFix(), 6037 (e = s.slideNext(s.params.speed, !0, !0)), 6038 n("autoplay")) 6039 : s.isEnd 6040 ? s.params.autoplay.stopOnLastSlide 6041 ? d() 6042 : ((e = s.slideTo(0, s.params.speed, !0, !0)), n("autoplay")) 6043 : ((e = s.slideNext(s.params.speed, !0, !0)), n("autoplay")), 6044 ((s.params.cssMode && s.autoplay.running) || !1 === e) && l(); 6045 }, a)); 6046 } 6047 function o() { 6048 return ( 6049 void 0 === t && 6050 !s.autoplay.running && 6051 ((s.autoplay.running = !0), n("autoplayStart"), l(), !0) 6052 ); 6053 } 6054 function d() { 6055 return ( 6056 !!s.autoplay.running && 6057 void 0 !== t && 6058 (t && (clearTimeout(t), (t = void 0)), 6059 (s.autoplay.running = !1), 6060 n("autoplayStop"), 6061 !0) 6062 ); 6063 } 6064 function c(e) { 6065 s.autoplay.running && 6066 (s.autoplay.paused || 6067 (t && clearTimeout(t), 6068 (s.autoplay.paused = !0), 6069 0 !== e && s.params.autoplay.waitForTransition 6070 ? ["transitionend", "webkitTransitionEnd"].forEach((e) => { 6071 s.$wrapperEl[0].addEventListener(e, h); 6072 }) 6073 : ((s.autoplay.paused = !1), l()))); 6074 } 6075 function u() { 6076 const e = a(); 6077 "hidden" === e.visibilityState && s.autoplay.running && c(), 6078 "visible" === e.visibilityState && 6079 s.autoplay.paused && 6080 (l(), (s.autoplay.paused = !1)); 6081 } 6082 function h(e) { 6083 s && 6084 !s.destroyed && 6085 s.$wrapperEl && 6086 e.target === s.$wrapperEl[0] && 6087 (["transitionend", "webkitTransitionEnd"].forEach((e) => { 6088 s.$wrapperEl[0].removeEventListener(e, h); 6089 }), 6090 (s.autoplay.paused = !1), 6091 s.autoplay.running ? l() : d()); 6092 } 6093 function m() { 6094 s.params.autoplay.disableOnInteraction 6095 ? d() 6096 : (n("autoplayPause"), c()), 6097 ["transitionend", "webkitTransitionEnd"].forEach((e) => { 6098 s.$wrapperEl[0].removeEventListener(e, h); 6099 }); 6100 } 6101 function f() { 6102 s.params.autoplay.disableOnInteraction || 6103 ((s.autoplay.paused = !1), n("autoplayResume"), l()); 6104 } 6105 (s.autoplay = { running: !1, paused: !1 }), 6106 i({ 6107 autoplay: { 6108 enabled: !1, 6109 delay: 3e3, 6110 waitForTransition: !0, 6111 disableOnInteraction: !0, 6112 stopOnLastSlide: !1, 6113 reverseDirection: !1, 6114 pauseOnMouseEnter: !1, 6115 }, 6116 }), 6117 r("init", () => { 6118 if (s.params.autoplay.enabled) { 6119 o(); 6120 a().addEventListener("visibilitychange", u), 6121 s.params.autoplay.pauseOnMouseEnter && 6122 (s.$el.on("mouseenter", m), s.$el.on("mouseleave", f)); 6123 } 6124 }), 6125 r("beforeTransitionStart", (e, t, a) => { 6126 s.autoplay.running && 6127 (a || !s.params.autoplay.disableOnInteraction 6128 ? s.autoplay.pause(t) 6129 : d()); 6130 }), 6131 r("sliderFirstMove", () => { 6132 s.autoplay.running && 6133 (s.params.autoplay.disableOnInteraction ? d() : c()); 6134 }), 6135 r("touchEnd", () => { 6136 s.params.cssMode && 6137 s.autoplay.paused && 6138 !s.params.autoplay.disableOnInteraction && 6139 l(); 6140 }), 6141 r("destroy", () => { 6142 s.$el.off("mouseenter", m), 6143 s.$el.off("mouseleave", f), 6144 s.autoplay.running && d(); 6145 a().removeEventListener("visibilitychange", u); 6146 }), 6147 Object.assign(s.autoplay, { pause: c, run: l, start: o, stop: d }); 6148 }, 6149 function (e) { 6150 let { swiper: t, extendParams: s, on: a } = e; 6151 s({ 6152 thumbs: { 6153 swiper: null, 6154 multipleActiveThumbs: !0, 6155 autoScrollOffset: 0, 6156 slideThumbActiveClass: "swiper-slide-thumb-active", 6157 thumbsContainerClass: "swiper-thumbs", 6158 }, 6159 }); 6160 let i = !1, 6161 r = !1; 6162 function n() { 6163 const e = t.thumbs.swiper; 6164 if (!e || e.destroyed) return; 6165 const s = e.clickedIndex, 6166 a = e.clickedSlide;
6167 if (a && d(a).hasClass(t.params.thumbs.slideThumbActiveClass)) return; 6168 if (null == s) return; 6169 let i; 6170 if ( 6171 ((i = e.params.loop 6172 ? parseInt(d(e.clickedSlide).attr("data-swiper-slide-index"), 10) 6173 : s), 6174 t.params.loop) 6175 ) { 6176 let e = t.activeIndex; 6177 t.slides.eq(e).hasClass(t.params.slideDuplicateClass) && 6178 (t.loopFix(), 6179 (t._clientLeft = t.$wrapperEl[0].clientLeft), 6180 (e = t.activeIndex)); 6181 const s = t.slides 6182 .eq(e) 6183 .prevAll(`[data-swiper-slide-index="${i}"]`) 6184 .eq(0) 6185 .index(), 6186 a = t.slides 6187 .eq(e) 6188 .nextAll(`[data-swiper-slide-index="${i}"]`) 6189 .eq(0) 6190 .index(); 6191 i = void 0 === s ? a : void 0 === a ? s : a - e < e - s ? a : s; 6192 } 6193 t.slideTo(i); 6194 } 6195 function l() { 6196 const { thumbs: e } = t.params; 6197 if (i) return !1; 6198 i = !0; 6199 const s = t.constructor; 6200 if (e.swiper instanceof s) 6201 (t.thumbs.swiper = e.swiper), 6202 Object.assign(t.thumbs.swiper.originalParams, { 6203 watchSlidesProgress: !0, 6204 slideToClickedSlide: !1, 6205 }), 6206 Object.assign(t.thumbs.swiper.params, { 6207 watchSlidesProgress: !0, 6208 slideToClickedSlide: !1, 6209 }); 6210 else if (m(e.swiper)) { 6211 const a = Object.assign({}, e.swiper); 6212 Object.assign(a, { 6213 watchSlidesProgress: !0, 6214 slideToClickedSlide: !1, 6215 }), 6216 (t.thumbs.swiper = new s(a)), 6217 (r = !0); 6218 } 6219 return ( 6220 t.thumbs.swiper.$el.addClass(t.params.thumbs.thumbsContainerClass), 6221 t.thumbs.swiper.on("tap", n), 6222 !0 6223 ); 6224 } 6225 function o(e) { 6226 const s = t.thumbs.swiper; 6227 if (!s || s.destroyed) return; 6228 const a = 6229 "auto" === s.params.slidesPerView 6230 ? s.slidesPerViewDynamic() 6231 : s.params.slidesPerView; 6232 let i = 1; 6233 const r = t.params.thumbs.slideThumbActiveClass; 6234 if ( 6235 (t.params.slidesPerView > 1 && 6236 !t.params.centeredSlides && 6237 (i = t.params.slidesPerView), 6238 t.params.thumbs.multipleActiveThumbs || (i = 1), 6239 (i = Math.floor(i)), 6240 s.slides.removeClass(r), 6241 s.params.loop || (s.params.virtual && s.params.virtual.enabled)) 6242 ) 6243 for (let e = 0; e < i; e += 1) 6244 s.$wrapperEl 6245 .children(`[data-swiper-slide-index="${t.realIndex + e}"]`) 6246 .addClass(r); 6247 else 6248 for (let e = 0; e < i; e += 1) 6249 s.slides.eq(t.realIndex + e).addClass(r); 6250 const n = t.params.thumbs.autoScrollOffset, 6251 l = n && !s.params.loop; 6252 if (t.realIndex !== s.realIndex || l) { 6253 let i, 6254 r, 6255 o = s.activeIndex; 6256 if (s.params.loop) { 6257 s.slides.eq(o).hasClass(s.params.slideDuplicateClass) && 6258 (s.loopFix(), 6259 (s._clientLeft = s.$wrapperEl[0].clientLeft), 6260 (o = s.activeIndex)); 6261 const e = s.slides 6262 .eq(o) 6263 .prevAll(`[data-swiper-slide-index="${t.realIndex}"]`) 6264 .eq(0) 6265 .index(), 6266 a = s.slides 6267 .eq(o) 6268 .nextAll(`[data-swiper-slide-index="${t.realIndex}"]`) 6269 .eq(0) 6270 .index(); 6271 (i = 6272 void 0 === e 6273 ? a 6274 : void 0 === a 6275 ? e 6276 : a - o == o - e 6277 ? s.params.slidesPerGroup > 1 6278 ? a 6279 : o 6280 : a - o < o - e 6281 ? a 6282 : e), 6283 (r = t.activeIndex > t.previousIndex ? "next" : "prev"); 6284 } else (i = t.realIndex), (r = i > t.previousIndex ? "next" : "prev"); 6285 l && (i += "next" === r ? n : -1 * n), 6286 s.visibleSlidesIndexes && 6287 s.visibleSlidesIndexes.indexOf(i) < 0 && 6288 (s.params.centeredSlides 6289 ? (i = 6290 i > o 6291 ? i - Math.floor(a / 2) + 1 6292 : i + Math.floor(a / 2) - 1) 6293 : i > o && s.params.slidesPerGroup, 6294 s.slideTo(i, e ? 0 : void 0)); 6295 } 6296 } 6297 (t.thumbs = { swiper: null }), 6298 a("beforeInit", () => { 6299 const { thumbs: e } = t.params; 6300 e && e.swiper && (l(), o(!0)); 6301 }), 6302 a("slideChange update resize observerUpdate", () => { 6303 o(); 6304 }), 6305 a("setTransition", (e, s) => { 6306 const a = t.thumbs.swiper; 6307 a && !a.destroyed && a.setTransition(s); 6308 }), 6309 a("beforeDestroy", () => { 6310 const e = t.thumbs.swiper; 6311 e && !e.destroyed && r && e.destroy(); 6312 }), 6313 Object.assign(t.thumbs, { init: l, update: o }); 6314 }, 6315 function (e) { 6316 let { swiper: t, extendParams: s, emit: a, once: i } = e; 6317 s({ 6318 freeMode: { 6319 enabled: !1, 6320 momentum: !0, 6321 momentumRatio: 1, 6322 momentumBounce: !0, 6323 momentumBounceRatio: 1, 6324 momentumVelocityRatio: 1, 6325 sticky: !1, 6326 minimumVelocity: 0.02, 6327 }, 6328 }), 6329 Object.assign(t, { 6330 freeMode: { 6331 onTouchStart: function () { 6332 const e = t.getTranslate(); 6333 t.setTranslate(e), 6334 t.setTransition(0), 6335 (t.touchEventsData.velocities.length = 0), 6336 t.freeMode.onTouchEnd({ 6337 currentPos: t.rtl ? t.translate : -t.translate, 6338 }); 6339 }, 6340 onTouchMove: function () { 6341 const { touchEventsData: e, touches: s } = t; 6342 0 === e.velocities.length && 6343 e.velocities.push({ 6344 position: s[t.isHorizontal() ? "startX" : "startY"], 6345 time: e.touchStartTime, 6346 }), 6347 e.velocities.push({ 6348 position: s[t.isHorizontal() ? "currentX" : "currentY"], 6349 time: u(), 6350 }); 6351 }, 6352 onTouchEnd: function (e) { 6353 let { currentPos: s } = e; 6354 const { 6355 params: r, 6356 $wrapperEl: n, 6357 rtlTranslate: l, 6358 snapGrid: o, 6359 touchEventsData: d, 6360 } = t, 6361 c = u() - d.touchStartTime; 6362 if (s < -t.minTranslate()) t.slideTo(t.activeIndex); 6363 else if (s > -t.maxTranslate()) 6364 t.slides.length < o.length 6365 ? t.slideTo(o.length - 1) 6366 : t.slideTo(t.slides.length - 1); 6367 else { 6368 if (r.freeMode.momentum) { 6369 if (d.velocities.length > 1) { 6370 const e = d.velocities.pop(), 6371 s = d.velocities.pop(), 6372 a = e.position - s.position, 6373 i = e.time - s.time; 6374 (t.velocity = a / i), 6375 (t.velocity /= 2), 6376 Math.abs(t.velocity) < r.freeMode.minimumVelocity && 6377 (t.velocity = 0), 6378 (i > 150 || u() - e.time > 300) && (t.velocity = 0); 6379 } else t.velocity = 0; 6380 (t.velocity *= r.freeMode.momentumVelocityRatio), 6381 (d.velocities.length = 0); 6382 let e = 1e3 * r.freeMode.momentumRatio; 6383 const s = t.velocity * e;
6384 let c = t.translate + s; 6385 l && (c = -c); 6386 let p, 6387 h = !1; 6388 const m = 6389 20 * Math.abs(t.velocity) * r.freeMode.momentumBounceRatio; 6390 let f; 6391 if (c < t.maxTranslate()) 6392 r.freeMode.momentumBounce 6393 ? (c + t.maxTranslate() < -m && 6394 (c = t.maxTranslate() - m), 6395 (p = t.maxTranslate()), 6396 (h = !0), 6397 (d.allowMomentumBounce = !0)) 6398 : (c = t.maxTranslate()), 6399 r.loop && r.centeredSlides && (f = !0); 6400 else if (c > t.minTranslate()) 6401 r.freeMode.momentumBounce 6402 ? (c - t.minTranslate() > m && (c = t.minTranslate() + m), 6403 (p = t.minTranslate()), 6404 (h = !0), 6405 (d.allowMomentumBounce = !0)) 6406 : (c = t.minTranslate()), 6407 r.loop && r.centeredSlides && (f = !0); 6408 else if (r.freeMode.sticky) { 6409 let e; 6410 for (let t = 0; t < o.length; t += 1) 6411 if (o[t] > -c) { 6412 e = t; 6413 break; 6414 } 6415 (c = 6416 Math.abs(o[e] - c) < Math.abs(o[e - 1] - c) || 6417 "next" === t.swipeDirection 6418 ? o[e] 6419 : o[e - 1]), 6420 (c = -c); 6421 } 6422 if ( 6423 (f && 6424 i("transitionEnd", () => { 6425 t.loopFix(); 6426 }), 6427 0 !== t.velocity) 6428 ) { 6429 if ( 6430 ((e = l 6431 ? Math.abs((-c - t.translate) / t.velocity) 6432 : Math.abs((c - t.translate) / t.velocity)), 6433 r.freeMode.sticky) 6434 ) { 6435 const s = Math.abs((l ? -c : c) - t.translate), 6436 a = t.slidesSizesGrid[t.activeIndex]; 6437 e = 6438 s < a 6439 ? r.speed 6440 : s < 2 * a 6441 ? 1.5 * r.speed 6442 : 2.5 * r.speed; 6443 } 6444 } else if (r.freeMode.sticky) return void t.slideToClosest(); 6445 r.freeMode.momentumBounce && h 6446 ? (t.updateProgress(p), 6447 t.setTransition(e), 6448 t.setTranslate(c), 6449 t.transitionStart(!0, t.swipeDirection), 6450 (t.animating = !0), 6451 n.transitionEnd(() => { 6452 t && 6453 !t.destroyed && 6454 d.allowMomentumBounce && 6455 (a("momentumBounce"), 6456 t.setTransition(r.speed), 6457 setTimeout(() => { 6458 t.setTranslate(p), 6459 n.transitionEnd(() => { 6460 t && !t.destroyed && t.transitionEnd(); 6461 }); 6462 }, 0)); 6463 })) 6464 : t.velocity 6465 ? (a("_freeModeNoMomentumRelease"), 6466 t.updateProgress(c), 6467 t.setTransition(e), 6468 t.setTranslate(c), 6469 t.transitionStart(!0, t.swipeDirection), 6470 t.animating || 6471 ((t.animating = !0), 6472 n.transitionEnd(() => { 6473 t && !t.destroyed && t.transitionEnd(); 6474 }))) 6475 : t.updateProgress(c), 6476 t.updateActiveIndex(), 6477 t.updateSlidesClasses(); 6478 } else { 6479 if (r.freeMode.sticky) return void t.slideToClosest(); 6480 r.freeMode && a("_freeModeNoMomentumRelease"); 6481 } 6482 (!r.freeMode.momentum || c >= r.longSwipesMs) && 6483 (t.updateProgress(), 6484 t.updateActiveIndex(), 6485 t.updateSlidesClasses()); 6486 } 6487 }, 6488 }, 6489 }); 6490 }, 6491 function (e) { 6492 let t, 6493 s, 6494 a, 6495 { swiper: i, extendParams: r } = e; 6496 r({ grid: { rows: 1, fill: "column" } }), 6497 (i.grid = { 6498 initSlides: (e) => { 6499 const { slidesPerView: r } = i.params, 6500 { rows: n, fill: l } = i.params.grid; 6501 (s = t / n), 6502 (a = Math.floor(e / n)), 6503 (t = Math.floor(e / n) === e / n ? e : Math.ceil(e / n) * n), 6504 "auto" !== r && "row" === l && (t = Math.max(t, r * n)); 6505 }, 6506 updateSlide: (e, r, n, l) => { 6507 const { slidesPerGroup: o, spaceBetween: d } = i.params, 6508 { rows: c, fill: p } = i.params.grid; 6509 let u, h, m; 6510 if ("row" === p && o > 1) { 6511 const s = Math.floor(e / (o * c)), 6512 a = e - c * o * s, 6513 i = 0 === s ? o : Math.min(Math.ceil((n - s * c * o) / c), o); 6514 (m = Math.floor(a / i)), 6515 (h = a - m * i + s * o), 6516 (u = h + (m * t) / c),
6517 r.css({ "-webkit-order": u, order: u }); 6518 } else 6519 "column" === p 6520 ? ((h = Math.floor(e / c)), 6521 (m = e - h * c), 6522 (h > a || (h === a && m === c - 1)) && 6523 ((m += 1), m >= c && ((m = 0), (h += 1)))) 6524 : ((m = Math.floor(e / s)), (h = e - m * s)); 6525 r.css(l("margin-top"), 0 !== m ? d && `${d}px` : ""); 6526 }, 6527 updateWrapperSize: (e, s, a) => { 6528 const { 6529 spaceBetween: r, 6530 centeredSlides: n, 6531 roundLengths: l, 6532 } = i.params, 6533 { rows: o } = i.params.grid; 6534 if ( 6535 ((i.virtualSize = (e + r) * t), 6536 (i.virtualSize = Math.ceil(i.virtualSize / o) - r), 6537 i.$wrapperEl.css({ [a("width")]: `${i.virtualSize + r}px` }), 6538 n) 6539 ) { 6540 s.splice(0, s.length); 6541 const e = []; 6542 for (let t = 0; t < s.length; t += 1) { 6543 let a = s[t]; 6544 l && (a = Math.floor(a)), 6545 s[t] < i.virtualSize + s[0] && e.push(a); 6546 } 6547 s.push(...e); 6548 } 6549 }, 6550 }); 6551 }, 6552 function (e) { 6553 let { swiper: t } = e; 6554 Object.assign(t, { 6555 appendSlide: K.bind(t), 6556 prependSlide: Z.bind(t), 6557 addSlide: Q.bind(t), 6558 removeSlide: J.bind(t), 6559 removeAllSlides: ee.bind(t), 6560 }); 6561 }, 6562 function (e) { 6563 let { swiper: t, extendParams: s, on: a } = e; 6564 s({ fadeEffect: { crossFade: !1, transformEl: null } }), 6565 te({ 6566 effect: "fade", 6567 swiper: t, 6568 on: a, 6569 setTranslate: () => { 6570 const { slides: e } = t, 6571 s = t.params.fadeEffect; 6572 for (let a = 0; a < e.length; a += 1) { 6573 const e = t.slides.eq(a); 6574 let i = -e[0].swiperSlideOffset; 6575 t.params.virtualTranslate || (i -= t.translate); 6576 let r = 0; 6577 t.isHorizontal() || ((r = i), (i = 0)); 6578 const n = t.params.fadeEffect.crossFade 6579 ? Math.max(1 - Math.abs(e[0].progress), 0) 6580 : 1 + Math.min(Math.max(e[0].progress, -1), 0); 6581 se(s, e) 6582 .css({ opacity: n }) 6583 .transform(`translate3d(${i}px, ${r}px, 0px)`); 6584 } 6585 }, 6586 setTransition: (e) => { 6587 const { transformEl: s } = t.params.fadeEffect; 6588 (s ? t.slides.find(s) : t.slides).transition(e), 6589 ae({ swiper: t, duration: e, transformEl: s, allSlides: !0 }); 6590 }, 6591 overwriteParams: () => ({ 6592 slidesPerView: 1, 6593 slidesPerGroup: 1, 6594 watchSlidesProgress: !0, 6595 spaceBetween: 0, 6596 virtualTranslate: !t.params.cssMode, 6597 }), 6598 }); 6599 }, 6600 function (e) { 6601 let { swiper: t, extendParams: s, on: a } = e; 6602 s({ 6603 cubeEffect: { 6604 slideShadows: !0, 6605 shadow: !0, 6606 shadowOffset: 20, 6607 shadowScale: 0.94, 6608 }, 6609 }); 6610 const i = (e, t, s) => { 6611 let a = s 6612 ? e.find(".swiper-slide-shadow-left") 6613 : e.find(".swiper-slide-shadow-top"), 6614 i = s 6615 ? e.find(".swiper-slide-shadow-right") 6616 : e.find(".swiper-slide-shadow-bottom"); 6617 0 === a.length && 6618 ((a = d( 6619 `<div class="swiper-slide-shadow-${s ? "left" : "top"}"></div>` 6620 )), 6621 e.append(a)), 6622 0 === i.length && 6623 ((i = d( 6624 `<div class="swiper-slide-shadow-${ 6625 s ? "right" : "bottom" 6626 }"></div>` 6627 )), 6628 e.append(i)), 6629 a.length && (a[0].style.opacity = Math.max(-t, 0)), 6630 i.length && (i[0].style.opacity = Math.max(t, 0)); 6631 }; 6632 te({ 6633 effect: "cube", 6634 swiper: t, 6635 on: a, 6636 setTranslate: () => { 6637 const { 6638 $el: e, 6639 $wrapperEl: s, 6640 slides: a, 6641 width: r, 6642 height: n, 6643 rtlTranslate: l, 6644 size: o, 6645 browser: c, 6646 } = t, 6647 p = t.params.cubeEffect, 6648 u = t.isHorizontal(), 6649 h = t.virtual && t.params.virtual.enabled; 6650 let m, 6651 f = 0; 6652 p.shadow && 6653 (u 6654 ? ((m = s.find(".swiper-cube-shadow")), 6655 0 === m.length && 6656 ((m = d('<div class="swiper-cube-shadow"></div>')), 6657 s.append(m)), 6658 m.css({ height: `${r}px` })) 6659 : ((m = e.find(".swiper-cube-shadow")), 6660 0 === m.length && 6661 ((m = d('<div class="swiper-cube-shadow"></div>')), 6662 e.append(m)))); 6663 for (let e = 0; e < a.length; e += 1) { 6664 const t = a.eq(e); 6665 let s = e; 6666 h && (s = parseInt(t.attr("data-swiper-slide-index"), 10)); 6667 let r = 90 * s, 6668 n = Math.floor(r / 360); 6669 l && ((r = -r), (n = Math.floor(-r / 360))); 6670 const d = Math.max(Math.min(t[0].progress, 1), -1);
6671 let c = 0, 6672 m = 0, 6673 g = 0; 6674 s % 4 == 0 6675 ? ((c = 4 * -n * o), (g = 0)) 6676 : (s - 1) % 4 == 0 6677 ? ((c = 0), (g = 4 * -n * o)) 6678 : (s - 2) % 4 == 0 6679 ? ((c = o + 4 * n * o), (g = o)) 6680 : (s - 3) % 4 == 0 && ((c = -o), (g = 3 * o + 4 * o * n)), 6681 l && (c = -c), 6682 u || ((m = c), (c = 0)); 6683 const v = `rotateX(${u ? 0 : -r}deg) rotateY(${ 6684 u ? r : 0 6685 }deg) translate3d(${c}px, ${m}px, ${g}px)`; 6686 d <= 1 && 6687 d > -1 && 6688 ((f = 90 * s + 90 * d), l && (f = 90 * -s - 90 * d)), 6689 t.transform(v), 6690 p.slideShadows && i(t, d, u); 6691 } 6692 if ( 6693 (s.css({ 6694 "-webkit-transform-origin": `50% 50% -${o / 2}px`, 6695 "transform-origin": `50% 50% -${o / 2}px`, 6696 }), 6697 p.shadow) 6698 ) 6699 if (u) 6700 m.transform( 6701 `translate3d(0px, ${r / 2 + p.shadowOffset}px, ${ 6702 -r / 2 6703 }px) rotateX(90deg) rotateZ(0deg) scale(${p.shadowScale})` 6704 ); 6705 else { 6706 const e = Math.abs(f) - 90 * Math.floor(Math.abs(f) / 90), 6707 t = 6708 1.5 - 6709 (Math.sin((2 * e * Math.PI) / 360) / 2 + 6710 Math.cos((2 * e * Math.PI) / 360) / 2), 6711 s = p.shadowScale, 6712 a = p.shadowScale / t, 6713 i = p.shadowOffset; 6714 m.transform( 6715 `scale3d(${s}, 1, ${a}) translate3d(0px, ${n / 2 + i}px, ${ 6716 -n / 2 / a 6717 }px) rotateX(-90deg)` 6718 ); 6719 } 6720 const g = c.isSafari || c.isWebView ? -o / 2 : 0; 6721 s.transform( 6722 `translate3d(0px,0,${g}px) rotateX(${ 6723 t.isHorizontal() ? 0 : f 6724 }deg) rotateY(${t.isHorizontal() ? -f : 0}deg)` 6725 ), 6726 s[0].style.setProperty("--swiper-cube-translate-z", `${g}px`); 6727 }, 6728 setTransition: (e) => { 6729 const { $el: s, slides: a } = t; 6730 a 6731 .transition(e) 6732 .find( 6733 ".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left" 6734 ) 6735 .transition(e), 6736 t.params.cubeEffect.shadow && 6737 !t.isHorizontal() && 6738 s.find(".swiper-cube-shadow").transition(e); 6739 }, 6740 recreateShadows: () => { 6741 const e = t.isHorizontal(); 6742 t.slides.each((t) => { 6743 const s = Math.max(Math.min(t.progress, 1), -1); 6744 i(d(t), s, e); 6745 }); 6746 }, 6747 getEffectParams: () => t.params.cubeEffect, 6748 perspective: () => !0, 6749 overwriteParams: () => ({ 6750 slidesPerView: 1, 6751 slidesPerGroup: 1, 6752 watchSlidesProgress: !0, 6753 resistanceRatio: 0, 6754 spaceBetween: 0, 6755 centeredSlides: !1, 6756 virtualTranslate: !0, 6757 }), 6758 }); 6759 }, 6760 function (e) { 6761 let { swiper: t, extendParams: s, on: a } = e; 6762 s({ 6763 flipEffect: { slideShadows: !0, limitRotation: !0, transformEl: null }, 6764 }); 6765 const i = (e, s, a) => { 6766 let i = t.isHorizontal() 6767 ? e.find(".swiper-slide-shadow-left") 6768 : e.find(".swiper-slide-shadow-top"), 6769 r = t.isHorizontal() 6770 ? e.find(".swiper-slide-shadow-right") 6771 : e.find(".swiper-slide-shadow-bottom"); 6772 0 === i.length && (i = ie(a, e, t.isHorizontal() ? "left" : "top")), 6773 0 === r.length && 6774 (r = ie(a, e, t.isHorizontal() ? "right" : "bottom")), 6775 i.length && (i[0].style.opacity = Math.max(-s, 0)), 6776 r.length && (r[0].style.opacity = Math.max(s, 0)); 6777 }; 6778 te({ 6779 effect: "flip", 6780 swiper: t, 6781 on: a, 6782 setTranslate: () => { 6783 const { slides: e, rtlTranslate: s } = t, 6784 a = t.params.flipEffect; 6785 for (let r = 0; r < e.length; r += 1) { 6786 const n = e.eq(r); 6787 let l = n[0].progress; 6788 t.params.flipEffect.limitRotation && 6789 (l = Math.max(Math.min(n[0].progress, 1), -1)); 6790 const o = n[0].swiperSlideOffset; 6791 let d = -180 * l, 6792 c = 0, 6793 p = t.params.cssMode ? -o - t.translate : -o, 6794 u = 0; 6795 t.isHorizontal() 6796 ? s && (d = -d) 6797 : ((u = p), (p = 0), (c = -d), (d = 0)), 6798 (n[0].style.zIndex = -Math.abs(Math.round(l)) + e.length), 6799 a.slideShadows && i(n, l, a); 6800 const h = `translate3d(${p}px, ${u}px, 0px) rotateX(${c}deg) rotateY(${d}deg)`; 6801 se(a, n).transform(h); 6802 } 6803 }, 6804 setTransition: (e) => { 6805 const { transformEl: s } = t.params.flipEffect; 6806 (s ? t.slides.find(s) : t.slides) 6807 .transition(e) 6808 .find( 6809 ".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left" 6810 ) 6811 .transition(e), 6812 ae({ swiper: t, duration: e, transformEl: s }); 6813 }, 6814 recreateShadows: () => { 6815 const e = t.params.flipEffect; 6816 t.slides.each((s) => { 6817 const a = d(s); 6818 let r = a[0].progress; 6819 t.params.flipEffect.limitRotation && 6820 (r = Math.max(Math.min(s.progress, 1), -1)), 6821 i(a, r, e); 6822 }); 6823 }, 6824 getEffectParams: () => t.params.flipEffect, 6825 perspective: () => !0, 6826 overwriteParams: () => ({ 6827 slidesPerView: 1, 6828 slidesPerGroup: 1, 6829 watchSlidesProgress: !0, 6830 spaceBetween: 0, 6831 virtualTranslate: !t.params.cssMode, 6832 }), 6833 }); 6834 }, 6835 function (e) { 6836 let { swiper: t, extendParams: s, on: a } = e; 6837 s({ 6838 coverflowEffect: { 6839 rotate: 50, 6840 stretch: 0, 6841 depth: 100, 6842 scale: 1, 6843 modifier: 1, 6844 slideShadows: !0, 6845 transformEl: null, 6846 }, 6847 }), 6848 te({ 6849 effect: "coverflow", 6850 swiper: t, 6851 on: a, 6852 setTranslate: () => { 6853 const { width: e, height: s, slides: a, slidesSizesGrid: i } = t, 6854 r = t.params.coverflowEffect, 6855 n = t.isHorizontal(), 6856 l = t.translate, 6857 o = n ? e / 2 - l : s / 2 - l, 6858 d = n ? r.rotate : -r.rotate, 6859 c = r.depth; 6860 for (let e = 0, t = a.length; e < t; e += 1) { 6861 const t = a.eq(e), 6862 s = i[e], 6863 l = (o - t[0].swiperSlideOffset - s / 2) / s, 6864 p = 6865 "function" == typeof r.modifier 6866 ? r.modifier(l) 6867 : l * r.modifier; 6868 let u = n ? d * p : 0, 6869 h = n ? 0 : d * p, 6870 m = -c * Math.abs(p), 6871 f = r.stretch; 6872 "string" == typeof f && 6873 -1 !== f.indexOf("%") && 6874 (f = (parseFloat(r.stretch) / 100) * s); 6875 let g = n ? 0 : f * p, 6876 v = n ? f * p : 0, 6877 w = 1 - (1 - r.scale) * Math.abs(p); 6878 Math.abs(v) < 0.001 && (v = 0), 6879 Math.abs(g) < 0.001 && (g = 0), 6880 Math.abs(m) < 0.001 && (m = 0), 6881 Math.abs(u) < 0.001 && (u = 0), 6882 Math.abs(h) < 0.001 && (h = 0), 6883 Math.abs(w) < 0.001 && (w = 0); 6884 const b = `translate3d(${v}px,${g}px,${m}px) rotateX(${h}deg) rotateY(${u}deg) scale(${w})`; 6885 if ( 6886 (se(r, t).transform(b), 6887 (t[0].style.zIndex = 1 - Math.abs(Math.round(p))), 6888 r.slideShadows) 6889 ) { 6890 let e = n 6891 ? t.find(".swiper-slide-shadow-left") 6892 : t.find(".swiper-slide-shadow-top"), 6893 s = n 6894 ? t.find(".swiper-slide-shadow-right") 6895 : t.find(".swiper-slide-shadow-bottom"); 6896 0 === e.length && (e = ie(r, t, n ? "left" : "top")), 6897 0 === s.length && (s = ie(r, t, n ? "right" : "bottom")), 6898 e.length && (e[0].style.opacity = p > 0 ? p : 0), 6899 s.length && (s[0].style.opacity = -p > 0 ? -p : 0); 6900 } 6901 } 6902 }, 6903 setTransition: (e) => { 6904 const { transformEl: s } = t.params.coverflowEffect; 6905 (s ? t.slides.find(s) : t.slides) 6906 .transition(e) 6907 .find( 6908 ".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left" 6909 ) 6910 .transition(e); 6911 }, 6912 perspective: () => !0, 6913 overwriteParams: () => ({ watchSlidesProgress: !0 }), 6914 }); 6915 }, 6916 function (e) { 6917 let { swiper: t, extendParams: s, on: a } = e; 6918 s({ 6919 creativeEffect: { 6920 transformEl: null, 6921 limitProgress: 1, 6922 shadowPerProgress: !1, 6923 progressMultiplier: 1, 6924 perspective: !0, 6925 prev: { 6926 translate: [0, 0, 0], 6927 rotate: [0, 0, 0], 6928 opacity: 1, 6929 scale: 1, 6930 }, 6931 next: { 6932 translate: [0, 0, 0], 6933 rotate: [0, 0, 0], 6934 opacity: 1, 6935 scale: 1, 6936 }, 6937 }, 6938 }); 6939 const i = (e) => ("string" == typeof e ? e : `${e}px`); 6940 te({ 6941 effect: "creative", 6942 swiper: t, 6943 on: a, 6944 setTranslate: () => { 6945 const { slides: e, $wrapperEl: s, slidesSizesGrid: a } = t, 6946 r = t.params.creativeEffect, 6947 { progressMultiplier: n } = r, 6948 l = t.params.centeredSlides; 6949 if (l) { 6950 const e = a[0] / 2 - t.params.slidesOffsetBefore || 0; 6951 s.transform(`translateX(calc(50% - ${e}px))`); 6952 } 6953 for (let s = 0; s < e.length; s += 1) { 6954 const a = e.eq(s), 6955 o = a[0].progress, 6956 d = Math.min( 6957 Math.max(a[0].progress, -r.limitProgress), 6958 r.limitProgress 6959 );
6960 let c = d; 6961 l || 6962 (c = Math.min( 6963 Math.max(a[0].originalProgress, -r.limitProgress), 6964 r.limitProgress 6965 )); 6966 const p = a[0].swiperSlideOffset, 6967 u = [t.params.cssMode ? -p - t.translate : -p, 0, 0], 6968 h = [0, 0, 0]; 6969 let m = !1; 6970 t.isHorizontal() || ((u[1] = u[0]), (u[0] = 0)); 6971 let f = { 6972 translate: [0, 0, 0], 6973 rotate: [0, 0, 0], 6974 scale: 1, 6975 opacity: 1, 6976 }; 6977 d < 0 6978 ? ((f = r.next), (m = !0)) 6979 : d > 0 && ((f = r.prev), (m = !0)), 6980 u.forEach((e, t) => { 6981 u[t] = `calc(${e}px + (${i(f.translate[t])} * ${Math.abs( 6982 d * n 6983 )}))`; 6984 }), 6985 h.forEach((e, t) => { 6986 h[t] = f.rotate[t] * Math.abs(d * n); 6987 }), 6988 (a[0].style.zIndex = -Math.abs(Math.round(o)) + e.length); 6989 const g = u.join(", "), 6990 v = `rotateX(${h[0]}deg) rotateY(${h[1]}deg) rotateZ(${h[2]}deg)`, 6991 w = 6992 c < 0 6993 ? `scale(${1 + (1 - f.scale) * c * n})` 6994 : `scale(${1 - (1 - f.scale) * c * n})`, 6995 b = 6996 c < 0 6997 ? 1 + (1 - f.opacity) * c * n 6998 : 1 - (1 - f.opacity) * c * n, 6999 x = `translate3d(${g}) ${v} ${w}`; 7000 if ((m && f.shadow) || !m) { 7001 let e = a.children(".swiper-slide-shadow"); 7002 if ((0 === e.length && f.shadow && (e = ie(r, a)), e.length)) { 7003 const t = r.shadowPerProgress ? d * (1 / r.limitProgress) : d; 7004 e[0].style.opacity = Math.min(Math.max(Math.abs(t), 0), 1); 7005 } 7006 } 7007 const y = se(r, a); 7008 y.transform(x).css({ opacity: b }), 7009 f.origin && y.css("transform-origin", f.origin); 7010 } 7011 }, 7012 setTransition: (e) => { 7013 const { transformEl: s } = t.params.creativeEffect; 7014 (s ? t.slides.find(s) : t.slides) 7015 .transition(e) 7016 .find(".swiper-slide-shadow") 7017 .transition(e), 7018 ae({ swiper: t, duration: e, transformEl: s, allSlides: !0 }); 7019 }, 7020 perspective: () => t.params.creativeEffect.perspective, 7021 overwriteParams: () => ({ 7022 watchSlidesProgress: !0, 7023 virtualTranslate: !t.params.cssMode, 7024 }), 7025 }); 7026 }, 7027 function (e) { 7028 let { swiper: t, extendParams: s, on: a } = e; 7029 s({ 7030 cardsEffect: { 7031 slideShadows: !0, 7032 transformEl: null, 7033 rotate: !0, 7034 perSlideRotate: 2, 7035 perSlideOffset: 8, 7036 }, 7037 }), 7038 te({ 7039 effect: "cards", 7040 swiper: t, 7041 on: a, 7042 setTranslate: () => { 7043 const { slides: e, activeIndex: s } = t, 7044 a = t.params.cardsEffect, 7045 { startTranslate: i, isTouched: r } = t.touchEventsData, 7046 n = t.translate; 7047 for (let l = 0; l < e.length; l += 1) { 7048 const o = e.eq(l), 7049 d = o[0].progress, 7050 c = Math.min(Math.max(d, -4), 4); 7051 let p = o[0].swiperSlideOffset; 7052 t.params.centeredSlides && 7053 !t.params.cssMode && 7054 t.$wrapperEl.transform(`translateX(${t.minTranslate()}px)`), 7055 t.params.centeredSlides && 7056 t.params.cssMode && 7057 (p -= e[0].swiperSlideOffset); 7058 let u = t.params.cssMode ? -p - t.translate : -p, 7059 h = 0; 7060 const m = -100 * Math.abs(c); 7061 let f = 1, 7062 g = -a.perSlideRotate * c, 7063 v = a.perSlideOffset - 0.75 * Math.abs(c); 7064 const w = 7065 t.virtual && t.params.virtual.enabled 7066 ? t.virtual.from + l 7067 : l, 7068 b = 7069 (w === s || w === s - 1) && 7070 c > 0 && 7071 c < 1 && 7072 (r || t.params.cssMode) && 7073 n < i, 7074 x = 7075 (w === s || w === s + 1) && 7076 c < 0 && 7077 c > -1 && 7078 (r || t.params.cssMode) && 7079 n > i; 7080 if (b || x) { 7081 const e = (1 - Math.abs((Math.abs(c) - 0.5) / 0.5)) ** 0.5; 7082 (g += -28 * c * e), 7083 (f += -0.5 * e), 7084 (v += 96 * e), 7085 (h = -25 * e * Math.abs(c) + "%"); 7086 } 7087 if ( 7088 ((u = 7089 c < 0 7090 ? `calc(${u}px + (${v * Math.abs(c)}%))` 7091 : c > 0 7092 ? `calc(${u}px + (-${v * Math.abs(c)}%))` 7093 : `${u}px`), 7094 !t.isHorizontal()) 7095 ) { 7096 const e = h; 7097 (h = u), (u = e); 7098 } 7099 const y = c < 0 ? "" + (1 + (1 - f) * c) : "" + (1 - (1 - f) * c), 7100 E = `\n translate3d(${u}, ${h}, ${m}px)\n rotateZ(${ 7101 a.rotate ? g : 0 7102 }deg)\n scale(${y})\n `; 7103 if (a.slideShadows) { 7104 let e = o.find(".swiper-slide-shadow"); 7105 0 === e.length && (e = ie(a, o)), 7106 e.length && 7107 (e[0].style.opacity = Math.min( 7108 Math.max((Math.abs(c) - 0.5) / 0.5, 0), 7109 1 7110 )); 7111 } 7112 o[0].style.zIndex = -Math.abs(Math.round(d)) + e.length; 7113 se(a, o).transform(E); 7114 } 7115 }, 7116 setTransition: (e) => { 7117 const { transformEl: s } = t.params.cardsEffect; 7118 (s ? t.slides.find(s) : t.slides) 7119 .transition(e) 7120 .find(".swiper-slide-shadow") 7121 .transition(e), 7122 ae({ swiper: t, duration: e, transformEl: s }); 7123 }, 7124 perspective: () => !0, 7125 overwriteParams: () => ({ 7126 watchSlidesProgress: !0, 7127 virtualTranslate: !t.params.cssMode, 7128 }), 7129 }); 7130 }, 7131 ]; 7132 return V.use(re), V; 7133}); 7134//# sourceMappingURL=swiper-bundle.min.js.map
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.