1(() => { 2 "use strict"; 3 const e = {}; 4 function t() { 5 if (location.hash) return location.hash.replace("#", ""); 6 } 7 let s = (e, t = 500, s = 0) => { 8 e.classList.contains("_slide") || 9 (e.classList.add("_slide"), 10 (e.style.transitionProperty = "height, margin, padding"), 11 (e.style.transitionDuration = t + "ms"), 12 (e.style.height = `${e.offsetHeight}px`), 13 e.offsetHeight, 14 (e.style.overflow = "hidden"), 15 (e.style.height = s ? `${s}px` : "0px"), 16 (e.style.paddingTop = 0), 17 (e.style.paddingBottom = 0), 18 (e.style.marginTop = 0), 19 (e.style.marginBottom = 0), 20 window.setTimeout(() => { 21 (e.hidden = !s), 22 !s && e.style.removeProperty("height"), 23 e.style.removeProperty("padding-top"), 24 e.style.removeProperty("padding-bottom"), 25 e.style.removeProperty("margin-top"), 26 e.style.removeProperty("margin-bottom"), 27 !s && e.style.removeProperty("overflow"), 28 e.style.removeProperty("transition-duration"), 29 e.style.removeProperty("transition-property"), 30 e.classList.remove("_slide"), 31 document.dispatchEvent(new CustomEvent("slideUpDone", { detail: { target: e } })); 32 }, t)); 33 }, 34 i = (e, t = 500, s = 0) => { 35 if (!e.classList.contains("_slide")) { 36 e.classList.add("_slide"), (e.hidden = !e.hidden && null), s && e.style.removeProperty("height"); 37 let i = e.offsetHeight; 38 (e.style.overflow = "hidden"), 39 (e.style.height = s ? `${s}px` : "0px"), 40 (e.style.paddingTop = 0), 41 (e.style.paddingBottom = 0), 42 (e.style.marginTop = 0), 43 (e.style.marginBottom = 0), 44 e.offsetHeight, 45 (e.style.transitionProperty = "height, margin, padding"), 46 (e.style.transitionDuration = t + "ms"), 47 (e.style.height = i + "px"), 48 e.style.removeProperty("padding-top"), 49 e.style.removeProperty("padding-bottom"), 50 e.style.removeProperty("margin-top"), 51 e.style.removeProperty("margin-bottom"), 52 window.setTimeout(() => { 53 e.style.removeProperty("height"), 54 e.style.removeProperty("overflow"), 55 e.style.removeProperty("transition-duration"), 56 e.style.removeProperty("transition-property"), 57 e.classList.remove("_slide"), 58 document.dispatchEvent(new CustomEvent("slideDownDone", { detail: { target: e } })); 59 }, t); 60 } 61 }, 62 n = !0, 63 r = (e = 500) => { 64 let t = document.querySelector("body"); 65 if (n) { 66 let s = document.querySelectorAll("[data-lp]"); 67 setTimeout(() => { 68 for (let e = 0; e < s.length; e++) { 69 s[e].style.paddingRight = "0px"; 70 } 71 (t.style.paddingRight = "0px"), document.documentElement.classList.remove("lock"); 72 }, e), 73 (n = !1), 74 setTimeout(function () { 75 n = !0; 76 }, e); 77 } 78 }, 79 o = (e = 500) => { 80 let t = document.querySelector("body"); 81 if (n) { 82 let s = document.querySelectorAll("[data-lp]"); 83 for (let e = 0; e < s.length; e++) { 84 s[e].style.paddingRight = window.innerWidth - document.querySelector(".wrapper").offsetWidth + "px"; 85 } 86 (t.style.paddingRight = window.innerWidth - document.querySelector(".wrapper").offsetWidth + "px"), 87 document.documentElement.classList.add("lock"),
88 (n = !1), 89 setTimeout(function () { 90 n = !0; 91 }, e); 92 } 93 }; 94 function a(e) { 95 setTimeout(() => { 96 window.FLS && console.log(e); 97 }, 0); 98 } 99 function l(e, t) { 100 const s = Array.from(e).filter(function (e, s, i) { 101 if (e.dataset[t]) return e.dataset[t].split(",")[0]; 102 }); 103 if (s.length) { 104 const e = []; 105 s.forEach((s) => { 106 const i = {}, 107 n = s.dataset[t].split(","); 108 (i.value = n[0]), (i.type = n[1] ? n[1].trim() : "max"), (i.item = s), e.push(i); 109 }); 110 let i = e.map(function (e) { 111 return "(" + e.type + "-width: " + e.value + "px)," + e.value + "," + e.type; 112 }); 113 i = (function (e) { 114 return e.filter(function (e, t, s) { 115 return s.indexOf(e) === t; 116 }); 117 })(i); 118 const n = []; 119 if (i.length) 120 return ( 121 i.forEach((t) => { 122 const s = t.split(","), 123 i = s[1], 124 r = s[2], 125 o = window.matchMedia(s[0]), 126 a = e.filter(function (e) { 127 if (e.value === i && e.type === r) return !0; 128 }); 129 n.push({ itemsArray: a, matchMedia: o }); 130 }), 131 n 132 ); 133 } 134 } 135 e.popup = new (class { 136 constructor(e) { 137 let t = { 138 logging: !0, 139 init: !0, 140 attributeOpenButton: "data-popup", 141 attributeCloseButton: "data-close", 142 fixElementSelector: "[data-lp]", 143 youtubeAttribute: "data-popup-youtube", 144 youtubePlaceAttribute: "data-popup-youtube-place", 145 setAutoplayYoutube: !0, 146 classes: { popup: "popup", popupContent: "popup__content", popupActive: "popup_show", bodyActive: "popup-show" }, 147 focusCatch: !0, 148 closeEsc: !0, 149 bodyLock: !0, 150 hashSettings: { location: !0, goHash: !0 }, 151 on: { beforeOpen: function () {}, afterOpen: function () {}, beforeClose: function () {}, afterClose: function () {} }, 152 }; 153 this.youTubeCode, 154 (this.isOpen = !1), 155 (this.targetOpen = { selector: !1, element: !1 }), 156 (this.previousOpen = { selector: !1, element: !1 }), 157 (this.lastClosed = { selector: !1, element: !1 }), 158 (this._dataValue = !1), 159 (this.hash = !1), 160 (this._reopen = !1), 161 (this._selectorOpen = !1), 162 (this.lastFocusEl = !1), 163 (this._focusEl = [ 164 "a[href]", 165 'input:not([disabled]):not([type="hidden"]):not([aria-hidden])', 166 "button:not([disabled]):not([aria-hidden])", 167 "select:not([disabled]):not([aria-hidden])", 168 "textarea:not([disabled]):not([aria-hidden])", 169 "area[href]", 170 "iframe", 171 "object", 172 "embed", 173 "[contenteditable]", 174 '[tabindex]:not([tabindex^="-"])', 175 ]), 176 (this.options = { ...t, ...e, classes: { ...t.classes, ...e?.classes }, hashSettings: { ...t.hashSettings, ...e?.hashSettings }, on: { ...t.on, ...e?.on } }), 177 (this.bodyLock = !1), 178 this.options.init && this.initPopups(); 179 } 180 initPopups() { 181 this.popupLogging("ÐÑоÑнÑлÑÑ"), this.eventsPopup(); 182 } 183 eventsPopup() { 184 document.addEventListener( 185 "click", 186 function (e) { 187 const t = e.target.closest(`[${this.options.attributeOpenButton}]`); 188 if (t) 189 return ( 190 e.preventDefault(), 191 (this._dataValue = t.getAttribute(this.options.attributeOpenButton) ? t.getAttribute(this.options.attributeOpenButton) : "error"), 192 (this.youTubeCode = t.getAttribute(this.options.youtubeAttribute) ? t.getAttribute(this.options.youtubeAttribute) : null),
193 "error" !== this._dataValue 194 ? (this.isOpen || (this.lastFocusEl = t), (this.targetOpen.selector = `${this._dataValue}`), (this._selectorOpen = !0), void this.open()) 195 : void this.popupLogging(`Ðй ой, не заполнен аÑÑибÑÑ Ñ ${t.classList}`) 196 ); 197 return e.target.closest(`[${this.options.attributeCloseButton}]`) || (!e.target.closest(`.${this.options.classes.popupContent}`) && this.isOpen) ? (e.preventDefault(), void this.close()) : void 0; 198 }.bind(this) 199 ), 200 document.addEventListener( 201 "keydown", 202 function (e) { 203 if (this.options.closeEsc && 27 == e.which && "Escape" === e.code && this.isOpen) return e.preventDefault(), void this.close(); 204 this.options.focusCatch && 9 == e.which && this.isOpen && this._focusCatch(e); 205 }.bind(this) 206 ), 207 this.options.hashSettings.goHash && 208 (window.addEventListener( 209 "hashchange", 210 function () { 211 window.location.hash ? this._openToHash() : this.close(this.targetOpen.selector); 212 }.bind(this) 213 ), 214 window.addEventListener( 215 "load", 216 function () { 217 window.location.hash && this._openToHash(); 218 }.bind(this) 219 )); 220 } 221 open(e) { 222 if (n) 223 if ( 224 ((this.bodyLock = !!document.documentElement.classList.contains("lock")), 225 e && "string" == typeof e && "" !== e.trim() && ((this.targetOpen.selector = e), (this._selectorOpen = !0)), 226 this.isOpen && ((this._reopen = !0), this.close()), 227 this._selectorOpen || (this.targetOpen.selector = this.lastClosed.selector), 228 this._reopen || (this.previousActiveElement = document.activeElement), 229 (this.targetOpen.element = document.querySelector(this.targetOpen.selector)), 230 this.targetOpen.element) 231 ) { 232 if (this.youTubeCode) { 233 const e = `https://www.youtube.com/embed/${this.youTubeCode}?rel=0&showinfo=0&autoplay=1`, 234 t = document.createElement("iframe"); 235 t.setAttribute("allowfullscreen", ""); 236 const s = this.options.setAutoplayYoutube ? "autoplay;" : ""; 237 if ((t.setAttribute("allow", `${s}; encrypted-media`), t.setAttribute("src", e), !this.targetOpen.element.querySelector(`[${this.options.youtubePlaceAttribute}]`))) { 238 this.targetOpen.element.querySelector(".popup__text").setAttribute(`${this.options.youtubePlaceAttribute}`, ""); 239 } 240 this.targetOpen.element.querySelector(`[${this.options.youtubePlaceAttribute}]`).appendChild(t); 241 } 242 this.options.hashSettings.location && (this._getHash(), this._setHash()), 243 this.options.on.beforeOpen(this), 244 document.dispatchEvent(new CustomEvent("beforePopupOpen", { detail: { popup: this } })), 245 this.targetOpen.element.classList.add(this.options.classes.popupActive), 246 document.documentElement.classList.add(this.options.classes.bodyActive), 247 this._reopen ? (this._reopen = !1) : !this.bodyLock && o(), 248 this.targetOpen.element.setAttribute("aria-hidden", "false"), 249 (this.previousOpen.selector = this.targetOpen.selector), 250 (this.previousOpen.element = this.targetOpen.element), 251 (this._selectorOpen = !1), 252 (this.isOpen = !0), 253 setTimeout(() => { 254 this._focusTrap(); 255 }, 50), 256 this.options.on.afterOpen(this), 257 document.dispatchEvent(new CustomEvent("afterPopupOpen", { detail: { popup: this } })), 258 this.popupLogging("ÐÑкÑÑл попап"); 259 } else this.popupLogging("Ðй ой, Ñакого попапа неÑ.ÐÑовеÑÑÑе коÑÑекÑноÑÑÑ Ð²Ð²Ð¾Ð´Ð°. "); 260 } 261 close(e) { 262 e && "string" == typeof e && "" !== e.trim() && (this.previousOpen.selector = e), 263 this.isOpen && 264 n && 265 (this.options.on.beforeClose(this), 266 document.dispatchEvent(new CustomEvent("beforePopupClose", { detail: { popup: this } })), 267 this.youTubeCode && this.targetOpen.element.querySelector(`[${this.options.youtubePlaceAttribute}]`) && (this.targetOpen.element.querySelector(`[${this.options.youtubePlaceAttribute}]`).innerHTML = ""), 268 this.previousOpen.element.classList.remove(this.options.classes.popupActive), 269 this.previousOpen.element.setAttribute("aria-hidden", "true"), 270 this._reopen || (document.documentElement.classList.remove(this.options.classes.bodyActive), !this.bodyLock && r(), (this.isOpen = !1)), 271 this._removeHash(), 272 this._selectorOpen && ((this.lastClosed.selector = this.previousOpen.selector), (this.lastClosed.element = this.previousOpen.element)), 273 this.options.on.afterClose(this), 274 document.dispatchEvent(new CustomEvent("afterPopupClose", { detail: { popup: this } })), 275 setTimeout(() => { 276 this._focusTrap(); 277 }, 50), 278 this.popupLogging("ÐакÑÑл попап")); 279 } 280 _getHash() { 281 this.options.hashSettings.location && (this.hash = this.targetOpen.selector.includes("#") ? this.targetOpen.selector : this.targetOpen.selector.replace(".", "#")); 282 } 283 _openToHash() { 284 let e = document.querySelector(`.${window.location.hash.replace("#", "")}`) ? `.${window.location.hash.replace("#", "")}` : document.querySelector(`${window.location.hash}`) ? `${window.location.hash}` : null; 285 (document.querySelector(`[${this.options.attributeOpenButton} = "${e}"]`) 286 ? document.querySelector(`[${this.options.attributeOpenButton} = "${e}"]`) 287 : document.querySelector(`[${this.options.attributeOpenButton} = "${e.replace(".", "#")}"]`)) && 288 e && 289 this.open(e); 290 } 291 _setHash() { 292 history.pushState("", "", this.hash); 293 } 294 _removeHash() { 295 history.pushState("", "", window.location.href.split("#")[0]); 296 } 297 _focusCatch(e) { 298 const t = this.targetOpen.element.querySelectorAll(this._focusEl), 299 s = Array.prototype.slice.call(t), 300 i = s.indexOf(document.activeElement); 301 e.shiftKey && 0 === i && (s[s.length - 1].focus(), e.preventDefault()), e.shiftKey || i !== s.length - 1 || (s[0].focus(), e.preventDefault()); 302 } 303 _focusTrap() { 304 const e = this.previousOpen.element.querySelectorAll(this._focusEl); 305 !this.isOpen && this.lastFocusEl ? this.lastFocusEl.focus() : e[0].focus(); 306 } 307 popupLogging(e) { 308 this.options.logging && a(`[ÐопапоÑ]: ${e}`); 309 } 310 })({});
311 let c = (e, t = !1, s = 500, i = 0) => { 312 const n = document.querySelector(e); 313 if (n) { 314 let o = "", 315 l = 0; 316 t && ((o = "header.header"), (l = document.querySelector(o).offsetHeight)); 317 let c = { speedAsDuration: !0, speed: s, header: o, offset: i, easing: "easeOutQuad" }; 318 if ((document.documentElement.classList.contains("menu-open") && (r(), document.documentElement.classList.remove("menu-open")), "undefined" != typeof SmoothScroll)) new SmoothScroll().animateScroll(n, "", c); 319 else { 320 let e = n.getBoundingClientRect().top + scrollY; 321 (e = l ? e - l : e), (e = i ? e - i : e), window.scrollTo({ top: e, behavior: "smooth" }); 322 } 323 a(`[gotoBlock]: Ð®Ñ ÑÑ...едем к ${e}`); 324 } else a(`[gotoBlock]: Ðй ой..Такого блока Ð½ÐµÑ Ð½Ð° ÑÑÑаниÑе: ${e}`); 325 }; 326 function d(e) { 327 return null !== e && "object" == typeof e && "constructor" in e && e.constructor === Object; 328 } 329 function p(e = {}, t = {}) { 330 Object.keys(t).forEach((s) => { 331 void 0 === e[s] ? (e[s] = t[s]) : d(t[s]) && d(e[s]) && Object.keys(t[s]).length > 0 && p(e[s], t[s]); 332 }); 333 } 334 const u = { 335 body: {}, 336 addEventListener() {}, 337 removeEventListener() {}, 338 activeElement: { blur() {}, nodeName: "" }, 339 querySelector: () => null, 340 querySelectorAll: () => [], 341 getElementById: () => null, 342 createEvent: () => ({ initEvent() {} }), 343 createElement: () => ({ children: [], childNodes: [], style: {}, setAttribute() {}, getElementsByTagName: () => [] }), 344 createElementNS: () => ({}), 345 importNode: () => null, 346 location: { hash: "", host: "", hostname: "", href: "", origin: "", pathname: "", protocol: "", search: "" }, 347 }; 348 function h() { 349 const e = "undefined" != typeof document ? document : {}; 350 return p(e, u), e; 351 } 352 const m = { 353 document: u, 354 navigator: { userAgent: "" }, 355 location: { hash: "", host: "", hostname: "", href: "", origin: "", pathname: "", protocol: "", search: "" }, 356 history: { replaceState() {}, pushState() {}, go() {}, back() {} }, 357 CustomEvent: function () { 358 return this; 359 }, 360 addEventListener() {}, 361 removeEventListener() {}, 362 getComputedStyle: () => ({ getPropertyValue: () => "" }), 363 Image() {}, 364 Date() {}, 365 screen: {}, 366 setTimeout() {}, 367 clearTimeout() {}, 368 matchMedia: () => ({}), 369 requestAnimationFrame: (e) => ("undefined" == typeof setTimeout ? (e(), null) : setTimeout(e, 0)), 370 cancelAnimationFrame(e) { 371 "undefined" != typeof setTimeout && clearTimeout(e); 372 }, 373 }; 374 function f() { 375 const e = "undefined" != typeof window ? window : {}; 376 return p(e, m), e; 377 } 378 class g extends Array { 379 constructor(e) { 380 "number" == typeof e 381 ? super(e) 382 : (super(...(e || [])), 383 (function (e) { 384 const t = e.__proto__; 385 Object.defineProperty(e, "__proto__", { 386 get: () => t, 387 set(e) { 388 t.__proto__ = e; 389 }, 390 }); 391 })(this)); 392 } 393 } 394 function v(e = []) { 395 const t = []; 396 return ( 397 e.forEach((e) => { 398 Array.isArray(e) ? t.push(...v(e)) : t.push(e); 399 }), 400 t 401 ); 402 } 403 function b(e, t) { 404 return Array.prototype.filter.call(e, t); 405 } 406 function y(e, t) { 407 const s = f(), 408 i = h(); 409 let n = []; 410 if (!t && e instanceof g) return e; 411 if (!e) return new g(n); 412 if ("string" == typeof e) { 413 const s = e.trim(); 414 if (s.indexOf("<") >= 0 && s.indexOf(">") >= 0) { 415 let e = "div"; 416 0 === s.indexOf("<li") && (e = "ul"), 417 0 === s.indexOf("<tr") && (e = "tbody"), 418 (0 !== s.indexOf("<td") && 0 !== s.indexOf("<th")) || (e = "tr"), 419 0 === s.indexOf("<tbody") && (e = "table"), 420 0 === s.indexOf("<option") && (e = "select"); 421 const t = i.createElement(e); 422 t.innerHTML = s; 423 for (let e = 0; e < t.childNodes.length; e += 1) n.push(t.childNodes[e]); 424 } else 425 n = (function (e, t) { 426 if ("string" != typeof e) return [e]; 427 const s = [], 428 i = t.querySelectorAll(e); 429 for (let e = 0; e < i.length; e += 1) s.push(i[e]); 430 return s; 431 })(e.trim(), t || i); 432 } else if (e.nodeType || e === s || e === i) n.push(e); 433 else if (Array.isArray(e)) { 434 if (e instanceof g) return e; 435 n = e; 436 } 437 return new g( 438 (function (e) { 439 const t = []; 440 for (let s = 0; s < e.length; s += 1) -1 === t.indexOf(e[s]) && t.push(e[s]); 441 return t; 442 })(n) 443 ); 444 } 445 y.fn = g.prototype; 446 const w = "resize scroll".split(" "); 447 function S(e) { 448 return function (...t) { 449 if (void 0 === t[0]) { 450 for (let t = 0; t < this.length; t += 1) w.indexOf(e) < 0 && (e in this[t] ? this[t][e]() : y(this[t]).trigger(e)); 451 return this; 452 } 453 return this.on(e, ...t); 454 }; 455 } 456 S("click"), 457 S("blur"), 458 S("focus"), 459 S("focusin"), 460 S("focusout"), 461 S("keyup"), 462 S("keydown"), 463 S("keypress"), 464 S("submit"), 465 S("change"), 466 S("mousedown"), 467 S("mousemove"), 468 S("mouseup"), 469 S("mouseenter"), 470 S("mouseleave"), 471 S("mouseout"), 472 S("mouseover"), 473 S("touchstart"), 474 S("touchend"), 475 S("touchmove"), 476 S("resize"), 477 S("scroll"); 478 const C = { 479 addClass: function (...e) { 480 const t = v(e.map((e) => e.split(" "))); 481 return ( 482 this.forEach((e) => { 483 e.classList.add(...t); 484 }), 485 this 486 ); 487 }, 488 removeClass: function (...e) { 489 const t = v(e.map((e) => e.split(" "))); 490 return ( 491 this.forEach((e) => { 492 e.classList.remove(...t); 493 }), 494 this 495 ); 496 }, 497 hasClass: function (...e) { 498 const t = v(e.map((e) => e.split(" "))); 499 return b(this, (e) => t.filter((t) => e.classList.contains(t)).length > 0).length > 0; 500 }, 501 toggleClass: function (...e) { 502 const t = v(e.map((e) => e.split(" "))); 503 this.forEach((e) => { 504 t.forEach((t) => { 505 e.classList.toggle(t); 506 }); 507 }); 508 }, 509 attr: function (e, t) { 510 if (1 === arguments.length && "string" == typeof e) return this[0] ? this[0].getAttribute(e) : void 0; 511 for (let s = 0; s < this.length; s += 1) 512 if (2 === arguments.length) this[s].setAttribute(e, t); 513 else for (const t in e) (this[s][t] = e[t]), this[s].setAttribute(t, e[t]); 514 return this; 515 }, 516 removeAttr: function (e) { 517 for (let t = 0; t < this.length; t += 1) this[t].removeAttribute(e); 518 return this; 519 }, 520 transform: function (e) { 521 for (let t = 0; t < this.length; t += 1) this[t].style.transform = e; 522 return this; 523 }, 524 transition: function (e) { 525 for (let t = 0; t < this.length; t += 1) this[t].style.transitionDuration = "string" != typeof e ? `${e}ms` : e; 526 return this; 527 }, 528 on: function (...e) { 529 let [t, s, i, n] = e; 530 function r(e) { 531 const t = e.target; 532 if (!t) return; 533 const n = e.target.dom7EventData || []; 534 if ((n.indexOf(e) < 0 && n.unshift(e), y(t).is(s))) i.apply(t, n); 535 else { 536 const e = y(t).parents(); 537 for (let t = 0; t < e.length; t += 1) y(e[t]).is(s) && i.apply(e[t], n); 538 } 539 } 540 function o(e) { 541 const t = (e && e.target && e.target.dom7EventData) || []; 542 t.indexOf(e) < 0 && t.unshift(e), i.apply(this, t); 543 } 544 "function" == typeof e[1] && (([t, i, n] = e), (s = void 0)), n || (n = !1); 545 const a = t.split(" "); 546 let l; 547 for (let e = 0; e < this.length; e += 1) { 548 const t = this[e]; 549 if (s) 550 for (l = 0; l < a.length; l += 1) { 551 const e = a[l]; 552 t.dom7LiveListeners || (t.dom7LiveListeners = {}), t.dom7LiveListeners[e] || (t.dom7LiveListeners[e] = []), t.dom7LiveListeners[e].push({ listener: i, proxyListener: r }), t.addEventListener(e, r, n); 553 } 554 else 555 for (l = 0; l < a.length; l += 1) { 556 const e = a[l]; 557 t.dom7Listeners || (t.dom7Listeners = {}), t.dom7Listeners[e] || (t.dom7Listeners[e] = []), t.dom7Listeners[e].push({ listener: i, proxyListener: o }), t.addEventListener(e, o, n); 558 } 559 } 560 return this; 561 }, 562 off: function (...e) { 563 let [t, s, i, n] = e; 564 "function" == typeof e[1] && (([t, i, n] = e), (s = void 0)), n || (n = !1); 565 const r = t.split(" "); 566 for (let e = 0; e < r.length; e += 1) { 567 const t = r[e]; 568 for (let e = 0; e < this.length; e += 1) { 569 const r = this[e]; 570 let o; 571 if ((!s && r.dom7Listeners ? (o = r.dom7Listeners[t]) : s && r.dom7LiveListeners && (o = r.dom7LiveListeners[t]), o && o.length)) 572 for (let e = o.length - 1; e >= 0; e -= 1) { 573 const s = o[e]; 574 (i && s.listener === i) || (i && s.listener && s.listener.dom7proxy && s.listener.dom7proxy === i) 575 ? (r.removeEventListener(t, s.proxyListener, n), o.splice(e, 1)) 576 : i || (r.removeEventListener(t, s.proxyListener, n), o.splice(e, 1)); 577 } 578 } 579 } 580 return this; 581 }, 582 trigger: function (...e) { 583 const t = f(), 584 s = e[0].split(" "), 585 i = e[1]; 586 for (let n = 0; n < s.length; n += 1) { 587 const r = s[n]; 588 for (let s = 0; s < this.length; s += 1) { 589 const n = this[s]; 590 if (t.CustomEvent) { 591 const s = new t.CustomEvent(r, { detail: i, bubbles: !0, cancelable: !0 }); 592 (n.dom7EventData = e.filter((e, t) => t > 0)), n.dispatchEvent(s), (n.dom7EventData = []), delete n.dom7EventData; 593 } 594 } 595 } 596 return this; 597 }, 598 transitionEnd: function (e) { 599 const t = this; 600 return ( 601 e && 602 t.on("transitionend", function s(i) { 603 i.target === this && (e.call(this, i), t.off("transitionend", s)); 604 }), 605 this 606 ); 607 }, 608 outerWidth: function (e) { 609 if (this.length > 0) { 610 if (e) { 611 const e = this.styles(); 612 return this[0].offsetWidth + parseFloat(e.getPropertyValue("margin-right")) + parseFloat(e.getPropertyValue("margin-left")); 613 } 614 return this[0].offsetWidth; 615 } 616 return null; 617 }, 618 outerHeight: function (e) { 619 if (this.length > 0) { 620 if (e) { 621 const e = this.styles(); 622 return this[0].offsetHeight + parseFloat(e.getPropertyValue("margin-top")) + parseFloat(e.getPropertyValue("margin-bottom")); 623 } 624 return this[0].offsetHeight; 625 } 626 return null; 627 }, 628 styles: function () { 629 const e = f(); 630 return this[0] ? e.getComputedStyle(this[0], null) : {}; 631 }, 632 offset: function () { 633 if (this.length > 0) { 634 const e = f(), 635 t = h(), 636 s = this[0], 637 i = s.getBoundingClientRect(), 638 n = t.body, 639 r = s.clientTop || n.clientTop || 0, 640 o = s.clientLeft || n.clientLeft || 0, 641 a = s === e ? e.scrollY : s.scrollTop, 642 l = s === e ? e.scrollX : s.scrollLeft; 643 return { top: i.top + a - r, left: i.left + l - o }; 644 } 645 return null; 646 }, 647 css: function (e, t) { 648 const s = f(); 649 let i; 650 if (1 === arguments.length) { 651 if ("string" != typeof e) { 652 for (i = 0; i < this.length; i += 1) for (const t in e) this[i].style[t] = e[t]; 653 return this; 654 } 655 if (this[0]) return s.getComputedStyle(this[0], null).getPropertyValue(e); 656 } 657 if (2 === arguments.length && "string" == typeof e) { 658 for (i = 0; i < this.length; i += 1) this[i].style[e] = t; 659 return this; 660 } 661 return this; 662 }, 663 each: function (e) { 664 return e 665 ? (this.forEach((t, s) => { 666 e.apply(t, [t, s]); 667 }), 668 this) 669 : this; 670 }, 671 html: function (e) { 672 if (void 0 === e) return this[0] ? this[0].innerHTML : null; 673 for (let t = 0; t < this.length; t += 1) this[t].innerHTML = e; 674 return this; 675 }, 676 text: function (e) { 677 if (void 0 === e) return this[0] ? this[0].textContent.trim() : null; 678 for (let t = 0; t < this.length; t += 1) this[t].textContent = e; 679 return this; 680 }, 681 is: function (e) { 682 const t = f(), 683 s = h(), 684 i = this[0]; 685 let n, r; 686 if (!i || void 0 === e) return !1; 687 if ("string" == typeof e) { 688 if (i.matches) return i.matches(e); 689 if (i.webkitMatchesSelector) return i.webkitMatchesSelector(e); 690 if (i.msMatchesSelector) return i.msMatchesSelector(e); 691 for (n = y(e), r = 0; r < n.length; r += 1) if (n[r] === i) return !0; 692 return !1; 693 } 694 if (e === s) return i === s; 695 if (e === t) return i === t; 696 if (e.nodeType || e instanceof g) {
697 for (n = e.nodeType ? [e] : e, r = 0; r < n.length; r += 1) if (n[r] === i) return !0; 698 return !1; 699 } 700 return !1; 701 }, 702 index: function () { 703 let e, 704 t = this[0]; 705 if (t) { 706 for (e = 0; null !== (t = t.previousSibling); ) 1 === t.nodeType && (e += 1); 707 return e; 708 } 709 }, 710 eq: function (e) { 711 if (void 0 === e) return this; 712 const t = this.length; 713 if (e > t - 1) return y([]); 714 if (e < 0) { 715 const s = t + e; 716 return y(s < 0 ? [] : [this[s]]); 717 } 718 return y([this[e]]); 719 }, 720 append: function (...e) { 721 let t; 722 const s = h(); 723 for (let i = 0; i < e.length; i += 1) { 724 t = e[i]; 725 for (let e = 0; e < this.length; e += 1) 726 if ("string" == typeof t) { 727 const i = s.createElement("div"); 728 for (i.innerHTML = t; i.firstChild; ) this[e].appendChild(i.firstChild); 729 } else if (t instanceof g) for (let s = 0; s < t.length; s += 1) this[e].appendChild(t[s]); 730 else this[e].appendChild(t); 731 } 732 return this; 733 }, 734 prepend: function (e) { 735 const t = h(); 736 let s, i; 737 for (s = 0; s < this.length; s += 1) 738 if ("string" == typeof e) { 739 const n = t.createElement("div"); 740 for (n.innerHTML = e, i = n.childNodes.length - 1; i >= 0; i -= 1) this[s].insertBefore(n.childNodes[i], this[s].childNodes[0]); 741 } else if (e instanceof g) for (i = 0; i < e.length; i += 1) this[s].insertBefore(e[i], this[s].childNodes[0]); 742 else this[s].insertBefore(e, this[s].childNodes[0]); 743 return this; 744 }, 745 next: function (e) { 746 return this.length > 0 ? (e ? (this[0].nextElementSibling && y(this[0].nextElementSibling).is(e) ? y([this[0].nextElementSibling]) : y([])) : this[0].nextElementSibling ? y([this[0].nextElementSibling]) : y([])) : y([]); 747 }, 748 nextAll: function (e) { 749 const t = []; 750 let s = this[0]; 751 if (!s) return y([]); 752 for (; s.nextElementSibling; ) { 753 const i = s.nextElementSibling; 754 e ? y(i).is(e) && t.push(i) : t.push(i), (s = i); 755 } 756 return y(t); 757 }, 758 prev: function (e) { 759 if (this.length > 0) { 760 const t = this[0]; 761 return e ? (t.previousElementSibling && y(t.previousElementSibling).is(e) ? y([t.previousElementSibling]) : y([])) : t.previousElementSibling ? y([t.previousElementSibling]) : y([]); 762 } 763 return y([]); 764 }, 765 prevAll: function (e) { 766 const t = []; 767 let s = this[0]; 768 if (!s) return y([]); 769 for (; s.previousElementSibling; ) { 770 const i = s.previousElementSibling; 771 e ? y(i).is(e) && t.push(i) : t.push(i), (s = i); 772 } 773 return y(t); 774 }, 775 parent: function (e) { 776 const t = []; 777 for (let s = 0; s < this.length; s += 1) null !== this[s].parentNode && (e ? y(this[s].parentNode).is(e) && t.push(this[s].parentNode) : t.push(this[s].parentNode)); 778 return y(t); 779 }, 780 parents: function (e) { 781 const t = []; 782 for (let s = 0; s < this.length; s += 1) { 783 let i = this[s].parentNode; 784 for (; i; ) e ? y(i).is(e) && t.push(i) : t.push(i), (i = i.parentNode); 785 } 786 return y(t); 787 }, 788 closest: function (e) { 789 let t = this; 790 return void 0 === e ? y([]) : (t.is(e) || (t = t.parents(e).eq(0)), t); 791 }, 792 find: function (e) { 793 const t = []; 794 for (let s = 0; s < this.length; s += 1) { 795 const i = this[s].querySelectorAll(e); 796 for (let e = 0; e < i.length; e += 1) t.push(i[e]); 797 } 798 return y(t); 799 }, 800 children: function (e) { 801 const t = []; 802 for (let s = 0; s < this.length; s += 1) { 803 const i = this[s].children; 804 for (let s = 0; s < i.length; s += 1) (e && !y(i[s]).is(e)) || t.push(i[s]); 805 } 806 return y(t); 807 }, 808 filter: function (e) { 809 return y(b(this, e)); 810 }, 811 remove: function () { 812 for (let e = 0; e < this.length; e += 1) this[e].parentNode && this[e].parentNode.removeChild(this[e]); 813 return this; 814 }, 815 };
816 Object.keys(C).forEach((e) => { 817 Object.defineProperty(y.fn, e, { value: C[e], writable: !0 }); 818 }); 819 const T = y; 820 function E(e, t = 0) { 821 return setTimeout(e, t); 822 } 823 function _() { 824 return Date.now(); 825 } 826 function x(e, t = "x") { 827 const s = f(); 828 let i, n, r; 829 const o = (function (e) { 830 const t = f(); 831 let s; 832 return t.getComputedStyle && (s = t.getComputedStyle(e, null)), !s && e.currentStyle && (s = e.currentStyle), s || (s = e.style), s; 833 })(e); 834 return ( 835 s.WebKitCSSMatrix 836 ? ((n = o.transform || o.webkitTransform), 837 n.split(",").length > 6 && 838 (n = n 839 .split(", ") 840 .map((e) => e.replace(",", ".")) 841 .join(", ")), 842 (r = new s.WebKitCSSMatrix("none" === n ? "" : n))) 843 : ((r = o.MozTransform || o.OTransform || o.MsTransform || o.msTransform || o.transform || o.getPropertyValue("transform").replace("translate(", "matrix(1, 0, 0, 1,")), (i = r.toString().split(","))), 844 "x" === t && (n = s.WebKitCSSMatrix ? r.m41 : 16 === i.length ? parseFloat(i[12]) : parseFloat(i[4])), 845 "y" === t && (n = s.WebKitCSSMatrix ? r.m42 : 16 === i.length ? parseFloat(i[13]) : parseFloat(i[5])), 846 n || 0 847 ); 848 } 849 function L(e) { 850 return "object" == typeof e && null !== e && e.constructor && "Object" === Object.prototype.toString.call(e).slice(8, -1); 851 } 852 function k(...e) { 853 const t = Object(e[0]), 854 s = ["__proto__", "constructor", "prototype"]; 855 for (let n = 1; n < e.length; n += 1) { 856 const r = e[n]; 857 if (null != r && ((i = r), !("undefined" != typeof window && void 0 !== window.HTMLElement ? i instanceof HTMLElement : i && (1 === i.nodeType || 11 === i.nodeType)))) { 858 const e = Object.keys(Object(r)).filter((e) => s.indexOf(e) < 0); 859 for (let s = 0, i = e.length; s < i; s += 1) { 860 const i = e[s], 861 n = Object.getOwnPropertyDescriptor(r, i); 862 void 0 !== n && n.enumerable && (L(t[i]) && L(r[i]) ? (r[i].__swiper__ ? (t[i] = r[i]) : k(t[i], r[i])) : !L(t[i]) && L(r[i]) ? ((t[i] = {}), r[i].__swiper__ ? (t[i] = r[i]) : k(t[i], r[i])) : (t[i] = r[i])); 863 } 864 } 865 } 866 var i; 867 return t; 868 } 869 function $(e, t, s) { 870 e.style.setProperty(t, s); 871 } 872 function P({ swiper: e, targetPosition: t, side: s }) { 873 const i = f(), 874 n = -e.translate; 875 let r, 876 o = null; 877 const a = e.params.speed; 878 (e.wrapperEl.style.scrollSnapType = "none"), i.cancelAnimationFrame(e.cssModeFrameID); 879 const l = t > n ? "next" : "prev", 880 c = (e, t) => ("next" === l && e >= t) || ("prev" === l && e <= t), 881 d = () => { 882 (r = new Date().getTime()), null === o && (o = r); 883 const l = Math.max(Math.min((r - o) / a, 1), 0), 884 p = 0.5 - Math.cos(l * Math.PI) / 2; 885 let u = n + p * (t - n); 886 if ((c(u, t) && (u = t), e.wrapperEl.scrollTo({ [s]: u }), c(u, t))) 887 return ( 888 (e.wrapperEl.style.overflow = "hidden"), 889 (e.wrapperEl.style.scrollSnapType = ""), 890 setTimeout(() => { 891 (e.wrapperEl.style.overflow = ""), e.wrapperEl.scrollTo({ [s]: u }); 892 }), 893 void i.cancelAnimationFrame(e.cssModeFrameID) 894 ); 895 e.cssModeFrameID = i.requestAnimationFrame(d); 896 }; 897 d(); 898 } 899 let M, A, O; 900 function q() { 901 return ( 902 M || 903 (M = (function () { 904 const e = f(), 905 t = h(); 906 return { 907 smoothScroll: t.documentElement && "scrollBehavior" in t.documentElement.style, 908 touch: !!("ontouchstart" in e || (e.DocumentTouch && t instanceof e.DocumentTouch)), 909 passiveListener: (function () { 910 let t = !1; 911 try { 912 const s = Object.defineProperty({}, "passive", { 913 get() { 914 t = !0; 915 }, 916 }); 917 e.addEventListener("testPassiveListener", null, s); 918 } catch (e) {} 919 return t; 920 })(), 921 gestures: "ongesturestart" in e, 922 }; 923 })()), 924 M 925 ); 926 } 927 function I(e = {}) { 928 return ( 929 A || 930 (A = (function ({ userAgent: e } = {}) { 931 const t = q(), 932 s = f(), 933 i = s.navigator.platform, 934 n = e || s.navigator.userAgent, 935 r = { ios: !1, android: !1 }, 936 o = s.screen.width, 937 a = s.screen.height, 938 l = n.match(/(Android);?[\s\/]+([\d.]+)?/); 939 let c = n.match(/(iPad).*OS\s([\d_]+)/); 940 const d = n.match(/(iPod)(.*OS\s([\d_]+))?/), 941 p = !c && n.match(/(iPhone\sOS|iOS)\s([\d_]+)/), 942 u = "Win32" === i; 943 let h = "MacIntel" === i; 944 return ( 945 !c && 946 h && 947 t.touch && 948 ["1024x1366", "1366x1024", "834x1194", "1194x834", "834x1112", "1112x834", "768x1024", "1024x768", "820x1180", "1180x820", "810x1080", "1080x810"].indexOf(`${o}x${a}`) >= 0 && 949 ((c = n.match(/(Version)\/([\d.]+)/)), c || (c = [0, 1, "13_0_0"]), (h = !1)), 950 l && !u && ((r.os = "android"), (r.android = !0)), 951 (c || p || d) && ((r.os = "ios"), (r.ios = !0)), 952 r 953 ); 954 })(e)), 955 A 956 ); 957 } 958 function D() { 959 return ( 960 O || 961 (O = (function () { 962 const e = f(); 963 return { 964 isSafari: (function () { 965 const t = e.navigator.userAgent.toLowerCase(); 966 return t.indexOf("safari") >= 0 && t.indexOf("chrome") < 0 && t.indexOf("android") < 0; 967 })(),
968 isWebView: /(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(e.navigator.userAgent), 969 }; 970 })()), 971 O 972 ); 973 } 974 const z = { 975 on(e, t, s) { 976 const i = this; 977 if (!i.eventsListeners || i.destroyed) return i; 978 if ("function" != typeof t) return i; 979 const n = s ? "unshift" : "push"; 980 return ( 981 e.split(" ").forEach((e) => { 982 i.eventsListeners[e] || (i.eventsListeners[e] = []), i.eventsListeners[e][n](t); 983 }), 984 i 985 ); 986 }, 987 once(e, t, s) { 988 const i = this; 989 if (!i.eventsListeners || i.destroyed) return i; 990 if ("function" != typeof t) return i; 991 function n(...s) { 992 i.off(e, n), n.__emitterProxy && delete n.__emitterProxy, t.apply(i, s); 993 } 994 return (n.__emitterProxy = t), i.on(e, n, s); 995 }, 996 onAny(e, t) { 997 const s = this; 998 if (!s.eventsListeners || s.destroyed) return s; 999 if ("function" != typeof e) return s; 1000 const i = t ? "unshift" : "push"; 1001 return s.eventsAnyListeners.indexOf(e) < 0 && s.eventsAnyListeners[i](e), s; 1002 }, 1003 offAny(e) { 1004 const t = this; 1005 if (!t.eventsListeners || t.destroyed) return t; 1006 if (!t.eventsAnyListeners) return t; 1007 const s = t.eventsAnyListeners.indexOf(e); 1008 return s >= 0 && t.eventsAnyListeners.splice(s, 1), t; 1009 }, 1010 off(e, t) { 1011 const s = this; 1012 return !s.eventsListeners || s.destroyed 1013 ? s 1014 : s.eventsListeners 1015 ? (e.split(" ").forEach((e) => { 1016 void 0 === t 1017 ? (s.eventsListeners[e] = []) 1018 : s.eventsListeners[e] && 1019 s.eventsListeners[e].forEach((i, n) => { 1020 (i === t || (i.__emitterProxy && i.__emitterProxy === t)) && s.eventsListeners[e].splice(n, 1); 1021 }); 1022 }), 1023 s) 1024 : s; 1025 }, 1026 emit(...e) { 1027 const t = this; 1028 if (!t.eventsListeners || t.destroyed) return t; 1029 if (!t.eventsListeners) return t; 1030 let s, i, n; 1031 "string" == typeof e[0] || Array.isArray(e[0]) ? ((s = e[0]), (i = e.slice(1, e.length)), (n = t)) : ((s = e[0].events), (i = e[0].data), (n = e[0].context || t)), i.unshift(n); 1032 return ( 1033 (Array.isArray(s) ? s : s.split(" ")).forEach((e) => { 1034 t.eventsAnyListeners && 1035 t.eventsAnyListeners.length && 1036 t.eventsAnyListeners.forEach((t) => { 1037 t.apply(n, [e, ...i]); 1038 }), 1039 t.eventsListeners && 1040 t.eventsListeners[e] && 1041 t.eventsListeners[e].forEach((e) => { 1042 e.apply(n, i); 1043 }); 1044 }), 1045 t 1046 ); 1047 }, 1048 }; 1049 const B = { 1050 updateSize: function () { 1051 const e = this; 1052 let t, s; 1053 const i = e.$el; 1054 (t = void 0 !== e.params.width && null !== e.params.width ? e.params.width : i[0].clientWidth), 1055 (s = void 0 !== e.params.height && null !== e.params.height ? e.params.height : i[0].clientHeight), 1056 (0 === t && e.isHorizontal()) || 1057 (0 === s && e.isVertical()) || 1058 ((t = t - parseInt(i.css("padding-left") || 0, 10) - parseInt(i.css("padding-right") || 0, 10)), 1059 (s = s - parseInt(i.css("padding-top") || 0, 10) - parseInt(i.css("padding-bottom") || 0, 10)), 1060 Number.isNaN(t) && (t = 0), 1061 Number.isNaN(s) && (s = 0), 1062 Object.assign(e, { width: t, height: s, size: e.isHorizontal() ? t : s })); 1063 }, 1064 updateSlides: function () { 1065 const e = this; 1066 function t(t) { 1067 return e.isHorizontal() 1068 ? t 1069 : { 1070 width: "height", 1071 "margin-top": "margin-left", 1072 "margin-bottom ": "margin-right", 1073 "margin-left": "margin-top", 1074 "margin-right": "margin-bottom", 1075 "padding-left": "padding-top", 1076 "padding-right": "padding-bottom", 1077 marginRight: "marginBottom", 1078 }[t]; 1079 } 1080 function s(e, s) { 1081 return parseFloat(e.getPropertyValue(t(s)) || 0); 1082 } 1083 const i = e.params, 1084 { $wrapperEl: n, size: r, rtlTranslate: o, wrongRTL: a } = e, 1085 l = e.virtual && i.virtual.enabled, 1086 c = l ? e.virtual.slides.length : e.slides.length, 1087 d = n.children(`.${e.params.slideClass}`), 1088 p = l ? e.virtual.slides.length : d.length; 1089 let u = []; 1090 const h = [], 1091 m = []; 1092 let f = i.slidesOffsetBefore; 1093 "function" == typeof f && (f = i.slidesOffsetBefore.call(e)); 1094 let g = i.slidesOffsetAfter; 1095 "function" == typeof g && (g = i.slidesOffsetAfter.call(e)); 1096 const v = e.snapGrid.length, 1097 b = e.slidesGrid.length; 1098 let y = i.spaceBetween, 1099 w = -f, 1100 S = 0, 1101 C = 0; 1102 if (void 0 === r) return; 1103 "string" == typeof y && y.indexOf("%") >= 0 && (y = (parseFloat(y.replace("%", "")) / 100) * r), 1104 (e.virtualSize = -y), 1105 o ? d.css({ marginLeft: "", marginBottom: "", marginTop: "" }) : d.css({ marginRight: "", marginBottom: "", marginTop: "" }), 1106 i.centeredSlides && i.cssMode && ($(e.wrapperEl, "--swiper-centered-offset-before", ""), $(e.wrapperEl, "--swiper-centered-offset-after", "")); 1107 const T = i.grid && i.grid.rows > 1 && e.grid; 1108 let E; 1109 T && e.grid.initSlides(p); 1110 const _ = "auto" === i.slidesPerView && i.breakpoints && Object.keys(i.breakpoints).filter((e) => void 0 !== i.breakpoints[e].slidesPerView).length > 0; 1111 for (let n = 0; n < p; n += 1) { 1112 E = 0; 1113 const o = d.eq(n); 1114 if ((T && e.grid.updateSlide(n, o, p, t), "none" !== o.css("display"))) { 1115 if ("auto" === i.slidesPerView) { 1116 _ && (d[n].style[t("width")] = ""); 1117 const r = getComputedStyle(o[0]), 1118 a = o[0].style.transform, 1119 l = o[0].style.webkitTransform; 1120 if ((a && (o[0].style.transform = "none"), l && (o[0].style.webkitTransform = "none"), i.roundLengths)) E = e.isHorizontal() ? o.outerWidth(!0) : o.outerHeight(!0); 1121 else { 1122 const e = s(r, "width"), 1123 t = s(r, "padding-left"), 1124 i = s(r, "padding-right"), 1125 n = s(r, "margin-left"), 1126 a = s(r, "margin-right"), 1127 l = r.getPropertyValue("box-sizing");
1128 if (l && "border-box" === l) E = e + n + a; 1129 else { 1130 const { clientWidth: s, offsetWidth: r } = o[0]; 1131 E = e + t + i + n + a + (r - s); 1132 } 1133 } 1134 a && (o[0].style.transform = a), l && (o[0].style.webkitTransform = l), i.roundLengths && (E = Math.floor(E)); 1135 } else (E = (r - (i.slidesPerView - 1) * y) / i.slidesPerView), i.roundLengths && (E = Math.floor(E)), d[n] && (d[n].style[t("width")] = `${E}px`); 1136 d[n] && (d[n].swiperSlideSize = E), 1137 m.push(E), 1138 i.centeredSlides 1139 ? ((w = w + E / 2 + S / 2 + y), 1140 0 === S && 0 !== n && (w = w - r / 2 - y), 1141 0 === n && (w = w - r / 2 - y), 1142 Math.abs(w) < 0.001 && (w = 0), 1143 i.roundLengths && (w = Math.floor(w)), 1144 C % i.slidesPerGroup == 0 && u.push(w), 1145 h.push(w)) 1146 : (i.roundLengths && (w = Math.floor(w)), (C - Math.min(e.params.slidesPerGroupSkip, C)) % e.params.slidesPerGroup == 0 && u.push(w), h.push(w), (w = w + E + y)), 1147 (e.virtualSize += E + y), 1148 (S = E), 1149 (C += 1); 1150 } 1151 } 1152 if ( 1153 ((e.virtualSize = Math.max(e.virtualSize, r) + g), 1154 o && a && ("slide" === i.effect || "coverflow" === i.effect) && n.css({ width: `${e.virtualSize + i.spaceBetween}px` }), 1155 i.setWrapperSize && n.css({ [t("width")]: `${e.virtualSize + i.spaceBetween}px` }), 1156 T && e.grid.updateWrapperSize(E, u, t), 1157 !i.centeredSlides) 1158 ) { 1159 const t = []; 1160 for (let s = 0; s < u.length; s += 1) { 1161 let n = u[s]; 1162 i.roundLengths && (n = Math.floor(n)), u[s] <= e.virtualSize - r && t.push(n); 1163 } 1164 (u = t), Math.floor(e.virtualSize - r) - Math.floor(u[u.length - 1]) > 1 && u.push(e.virtualSize - r); 1165 } 1166 if ((0 === u.length && (u = [0]), 0 !== i.spaceBetween)) { 1167 const s = e.isHorizontal() && o ? "marginLeft" : t("marginRight"); 1168 d.filter((e, t) => !i.cssMode || t !== d.length - 1).css({ [s]: `${y}px` }); 1169 } 1170 if (i.centeredSlides && i.centeredSlidesBounds) { 1171 let e = 0; 1172 m.forEach((t) => { 1173 e += t + (i.spaceBetween ? i.spaceBetween : 0); 1174 }), 1175 (e -= i.spaceBetween); 1176 const t = e - r; 1177 u = u.map((e) => (e < 0 ? -f : e > t ? t + g : e)); 1178 } 1179 if (i.centerInsufficientSlides) { 1180 let e = 0; 1181 if ( 1182 (m.forEach((t) => { 1183 e += t + (i.spaceBetween ? i.spaceBetween : 0); 1184 }), 1185 (e -= i.spaceBetween), 1186 e < r) 1187 ) { 1188 const t = (r - e) / 2; 1189 u.forEach((e, s) => { 1190 u[s] = e - t; 1191 }), 1192 h.forEach((e, s) => { 1193 h[s] = e + t; 1194 }); 1195 } 1196 } 1197 if ((Object.assign(e, { slides: d, snapGrid: u, slidesGrid: h, slidesSizesGrid: m }), i.centeredSlides && i.cssMode && !i.centeredSlidesBounds)) { 1198 $(e.wrapperEl, "--swiper-centered-offset-before", -u[0] + "px"), $(e.wrapperEl, "--swiper-centered-offset-after", e.size / 2 - m[m.length - 1] / 2 + "px"); 1199 const t = -e.snapGrid[0], 1200 s = -e.slidesGrid[0]; 1201 (e.snapGrid = e.snapGrid.map((e) => e + t)), (e.slidesGrid = e.slidesGrid.map((e) => e + s)); 1202 } 1203 if ( 1204 (p !== c && e.emit("slidesLengthChange"), 1205 u.length !== v && (e.params.watchOverflow && e.checkOverflow(), e.emit("snapGridLengthChange")), 1206 h.length !== b && e.emit("slidesGridLengthChange"), 1207 i.watchSlidesProgress && e.updateSlidesOffset(), 1208 !(l || i.cssMode || ("slide" !== i.effect && "fade" !== i.effect))) 1209 ) { 1210 const t = `${i.containerModifierClass}backface-hidden`, 1211 s = e.$el.hasClass(t); 1212 p <= i.maxBackfaceHiddenSlides ? s || e.$el.addClass(t) : s && e.$el.removeClass(t); 1213 } 1214 }, 1215 updateAutoHeight: function (e) { 1216 const t = this, 1217 s = [], 1218 i = t.virtual && t.params.virtual.enabled; 1219 let n, 1220 r = 0; 1221 "number" == typeof e ? t.setTransition(e) : !0 === e && t.setTransition(t.params.speed); 1222 const o = (e) => (i ? t.slides.filter((t) => parseInt(t.getAttribute("data-swiper-slide-index"), 10) === e)[0] : t.slides.eq(e)[0]); 1223 if ("auto" !== t.params.slidesPerView && t.params.slidesPerView > 1) 1224 if (t.params.centeredSlides) 1225 (t.visibleSlides || T([])).each((e) => { 1226 s.push(e); 1227 }); 1228 else 1229 for (n = 0;
1229 n < Math.ceil(t.params.slidesPerView); n += 1) { 1230 const e = t.activeIndex + n; 1231 if (e > t.slides.length && !i) break; 1232 s.push(o(e)); 1233 } 1234 else s.push(o(t.activeIndex)); 1235 for (n = 0; n < s.length; n += 1) 1236 if (void 0 !== s[n]) { 1237 const e = s[n].offsetHeight; 1238 r = e > r ? e : r; 1239 } 1240 (r || 0 === r) && t.$wrapperEl.css("height", `${r}px`); 1241 }, 1242 updateSlidesOffset: function () { 1243 const e = this, 1244 t = e.slides; 1245 for (let s = 0; s < t.length; s += 1) t[s].swiperSlideOffset = e.isHorizontal() ? t[s].offsetLeft : t[s].offsetTop; 1246 }, 1247 updateSlidesProgress: function (e = (this && this.translate) || 0) { 1248 const t = this, 1249 s = t.params, 1250 { slides: i, rtlTranslate: n, snapGrid: r } = t; 1251 if (0 === i.length) return; 1252 void 0 === i[0].swiperSlideOffset && t.updateSlidesOffset(); 1253 let o = -e; 1254 n && (o = e), i.removeClass(s.slideVisibleClass), (t.visibleSlidesIndexes = []), (t.visibleSlides = []); 1255 for (let e = 0; e < i.length; e += 1) { 1256 const a = i[e]; 1257 let l = a.swiperSlideOffset; 1258 s.cssMode && s.centeredSlides && (l -= i[0].swiperSlideOffset); 1259 const c = (o + (s.centeredSlides ? t.minTranslate() : 0) - l) / (a.swiperSlideSize + s.spaceBetween), 1260 d = (o - r[0] + (s.centeredSlides ? t.minTranslate() : 0) - l) / (a.swiperSlideSize + s.spaceBetween), 1261 p = -(o - l), 1262 u = p + t.slidesSizesGrid[e]; 1263 ((p >= 0 && p < t.size - 1) || (u > 1 && u <= t.size) || (p <= 0 && u >= t.size)) && (t.visibleSlides.push(a), t.visibleSlidesIndexes.push(e), i.eq(e).addClass(s.slideVisibleClass)), 1264 (a.progress = n ? -c : c), 1265 (a.originalProgress = n ? -d : d); 1266 } 1267 t.visibleSlides = T(t.visibleSlides); 1268 }, 1269 updateProgress: function (e) { 1270 const t = this; 1271 if (void 0 === e) { 1272 const s = t.rtlTranslate ? -1 : 1; 1273 e = (t && t.translate && t.translate * s) || 0; 1274 } 1275 const s = t.params, 1276 i = t.maxTranslate() - t.minTranslate(); 1277 let { progress: n, isBeginning: r, isEnd: o } = t; 1278 const a = r, 1279 l = o; 1280 0 === i ? ((n = 0), (r = !0), (o = !0)) : ((n = (e - t.minTranslate()) / i), (r = n <= 0), (o = n >= 1)), 1281 Object.assign(t, { progress: n, isBeginning: r, isEnd: o }), 1282 (s.watchSlidesProgress || (s.centeredSlides && s.autoHeight)) && t.updateSlidesProgress(e), 1283 r && !a && t.emit("reachBeginning toEdge"), 1284 o && !l && t.emit("reachEnd toEdge"), 1285 ((a && !r) || (l && !o)) && t.emit("fromEdge"), 1286 t.emit("progress", n); 1287 }, 1288 updateSlidesClasses: function () { 1289 const e = this, 1290 { slides: t, params: s, $wrapperEl: i, activeIndex: n, realIndex: r } = e, 1291 o = e.virtual && s.virtual.enabled; 1292 let a; 1293 t.removeClass(`${s.slideActiveClass} ${s.slideNextClass} ${s.slidePrevClass} ${s.slideDuplicateActiveClass} ${s.slideDuplicateNextClass} ${s.slideDuplicatePrevClass}`), 1294 (a = o ? e.$wrapperEl.find(`.${s.slideClass}[data-swiper-slide-index="${n}"]`) : t.eq(n)), 1295 a.addClass(s.slideActiveClass), 1296 s.loop && 1297 (a.hasClass(s.slideDuplicateClass) 1298 ? i.children(`.${s.slideClass}:not(.${s.slideDuplicateClass})[data-swiper-slide-index="${r}"]`).addClass(s.slideDuplicateActiveClass) 1299 : i.children(`.${s.slideClass}.${s.slideDuplicateClass}[data-swiper-slide-index="${r}"]`).addClass(s.slideDuplicateActiveClass)); 1300 let l = a.nextAll(`.${s.slideClass}`).eq(0).addClass(s.slideNextClass); 1301 s.loop && 0 === l.length && ((l = t.eq(0)), l.addClass(s.slideNextClass)); 1302 let c = a.prevAll(`.${s.slideClass}`).eq(0).addClass(s.slidePrevClass); 1303 s.loop && 0 === c.length && ((c = t.eq(-1)), c.addClass(s.slidePrevClass)), 1304 s.loop && 1305 (l.hasClass(s.slideDuplicateClass) 1306 ? i.children(`.${s.slideClass}:not(.${s.slideDuplicateClass})[data-swiper-slide-index="${l.attr("data-swiper-slide-index")}"]`).addClass(s.slideDuplicateNextClass) 1307 : i.children(`.${s.slideClass}.${s.slideDuplicateClass}[data-swiper-slide-index="${l.attr("data-swiper-slide-index")}"]`).addClass(s.slideDuplicateNextClass), 1308 c.hasClass(s.slideDuplicateClass) 1309 ? i.children(`.${s.slideClass}:not(.${s.slideDuplicateClass})[data-swiper-slide-index="${c.attr("data-swiper-slide-index")}"]`).addClass(s.slideDuplicatePrevClass) 1310 : i.children(`.${s.slideClass}.${s.slideDuplicateClass}[data-swiper-slide-index="${c.attr("data-swiper-slide-index")}"]`).addClass(s.slideDuplicatePrevClass)), 1311 e.emitSlidesClasses(); 1312 }, 1313 updateActiveIndex: function (e) { 1314 const t = this, 1315 s = t.rtlTranslate ? t.translate : -t.translate, 1316 { slidesGrid: i, snapGrid: n, params: r, activeIndex: o, realIndex: a, snapIndex: l } = t; 1317 let c, 1318 d = e; 1319 if (void 0 === d) { 1320 for (let e = 0; e < i.length; e += 1) void 0 !== i[e + 1] ? (s >= i[e] && s < i[e + 1] - (i[e + 1] - i[e]) / 2 ? (d = e) : s >= i[e] && s < i[e + 1] && (d = e + 1)) : s >= i[e] && (d = e);
1321 r.normalizeSlideIndex && (d < 0 || void 0 === d) && (d = 0); 1322 } 1323 if (n.indexOf(s) >= 0) c = n.indexOf(s); 1324 else { 1325 const e = Math.min(r.slidesPerGroupSkip, d); 1326 c = e + Math.floor((d - e) / r.slidesPerGroup); 1327 } 1328 if ((c >= n.length && (c = n.length - 1), d === o)) return void (c !== l && ((t.snapIndex = c), t.emit("snapIndexChange"))); 1329 const p = parseInt(t.slides.eq(d).attr("data-swiper-slide-index") || d, 10); 1330 Object.assign(t, { snapIndex: c, realIndex: p, previousIndex: o, activeIndex: d }), 1331 t.emit("activeIndexChange"), 1332 t.emit("snapIndexChange"), 1333 a !== p && t.emit("realIndexChange"), 1334 (t.initialized || t.params.runCallbacksOnInit) && t.emit("slideChange"); 1335 }, 1336 updateClickedSlide: function (e) { 1337 const t = this, 1338 s = t.params, 1339 i = T(e).closest(`.${s.slideClass}`)[0]; 1340 let n, 1341 r = !1; 1342 if (i) 1343 for (let e = 0; e < t.slides.length; e += 1) 1344 if (t.slides[e] === i) { 1345 (r = !0), (n = e); 1346 break; 1347 } 1348 if (!i || !r) return (t.clickedSlide = void 0), void (t.clickedIndex = void 0); 1349 (t.clickedSlide = i), 1350 t.virtual && t.params.virtual.enabled ? (t.clickedIndex = parseInt(T(i).attr("data-swiper-slide-index"), 10)) : (t.clickedIndex = n), 1351 s.slideToClickedSlide && void 0 !== t.clickedIndex && t.clickedIndex !== t.activeIndex && t.slideToClickedSlide(); 1352 }, 1353 }; 1354 const H = { 1355 getTranslate: function (e = this.isHorizontal() ? "x" : "y") { 1356 const { params: t, rtlTranslate: s, translate: i, $wrapperEl: n } = this; 1357 if (t.virtualTranslate) return s ? -i : i; 1358 if (t.cssMode) return i; 1359 let r = x(n[0], e); 1360 return s && (r = -r), r || 0; 1361 }, 1362 setTranslate: function (e, t) { 1363 const s = this, 1364 { rtlTranslate: i, params: n, $wrapperEl: r, wrapperEl: o, progress: a } = s; 1365 let l, 1366 c = 0, 1367 d = 0; 1368 s.isHorizontal() ? (c = i ? -e : e) : (d = e), 1369 n.roundLengths && ((c = Math.floor(c)), (d = Math.floor(d))), 1370 n.cssMode ? (o[s.isHorizontal() ? "scrollLeft" : "scrollTop"] = s.isHorizontal() ? -c : -d) : n.virtualTranslate || r.transform(`translate3d(${c}px, ${d}px, 0px)`), 1371 (s.previousTranslate = s.translate), 1372 (s.translate = s.isHorizontal() ? c : d); 1373 const p = s.maxTranslate() - s.minTranslate(); 1374 (l = 0 === p ? 0 : (e - s.minTranslate()) / p), l !== a && s.updateProgress(e), s.emit("setTranslate", s.translate, t); 1375 }, 1376 minTranslate: function () { 1377 return -this.snapGrid[0]; 1378 }, 1379 maxTranslate: function () { 1380 return -this.snapGrid[this.snapGrid.length - 1]; 1381 }, 1382 translateTo: function (e = 0, t = this.params.speed, s = !0, i = !0, n) { 1383 const r = this, 1384 { params: o, wrapperEl: a } = r; 1385 if (r.animating && o.preventInteractionOnTransition) return !1; 1386 const l = r.minTranslate(), 1387 c = r.maxTranslate(); 1388 let d; 1389 if (((d = i && e > l ? l : i && e < c ? c : e), r.updateProgress(d), o.cssMode)) { 1390 const e = r.isHorizontal(); 1391 if (0 === t) a[e ? "scrollLeft" : "scrollTop"] = -d; 1392 else { 1393 if (!r.support.smoothScroll) return P({ swiper: r, targetPosition: -d, side: e ? "left" : "top" }), !0; 1394 a.scrollTo({ [e ? "left" : "top"]: -d, behavior: "smooth" }); 1395 } 1396 return !0; 1397 } 1398 return ( 1399 0 === t 1400 ? (r.setTransition(0), r.setTranslate(d), s && (r.emit("beforeTransitionStart", t, n), r.emit("transitionEnd"))) 1401 : (r.setTransition(t), 1402 r.setTranslate(d), 1403 s && (r.emit("beforeTransitionStart", t, n), r.emit("transitionStart")), 1404 r.animating || 1405 ((r.animating = !0), 1406 r.onTranslateToWrapperTransitionEnd || 1407 (r.onTranslateToWrapperTransitionEnd = function (e) { 1408 r && 1409 !r.destroyed && 1410 e.target === this && 1411 (r.$wrapperEl[0].removeEventListener("transitionend", r.onTranslateToWrapperTransitionEnd), 1412 r.$wrapperEl[0].removeEventListener("webkitTransitionEnd", r.onTranslateToWrapperTransitionEnd), 1413 (r.onTranslateToWrapperTransitionEnd = null),
1414 delete r.onTranslateToWrapperTransitionEnd, 1415 s && r.emit("transitionEnd")); 1416 }), 1417 r.$wrapperEl[0].addEventListener("transitionend", r.onTranslateToWrapperTransitionEnd), 1418 r.$wrapperEl[0].addEventListener("webkitTransitionEnd", r.onTranslateToWrapperTransitionEnd))), 1419 !0 1420 ); 1421 }, 1422 }; 1423 function G({ swiper: e, runCallbacks: t, direction: s, step: i }) { 1424 const { activeIndex: n, previousIndex: r } = e; 1425 let o = s; 1426 if ((o || (o = n > r ? "next" : n < r ? "prev" : "reset"), e.emit(`transition${i}`), t && n !== r)) { 1427 if ("reset" === o) return void e.emit(`slideResetTransition${i}`); 1428 e.emit(`slideChangeTransition${i}`), "next" === o ? e.emit(`slideNextTransition${i}`) : e.emit(`slidePrevTransition${i}`); 1429 } 1430 } 1431 const N = { 1432 slideTo: function (e = 0, t = this.params.speed, s = !0, i, n) { 1433 if ("number" != typeof e && "string" != typeof e) throw new Error(`The 'index' argument cannot have type other than 'number' or 'string'. [${typeof e}] given.`); 1434 if ("string" == typeof e) { 1435 const t = parseInt(e, 10); 1436 if (!isFinite(t)) throw new Error(`The passed-in 'index' (string) couldn't be converted to 'number'. [${e}] given.`); 1437 e = t; 1438 } 1439 const r = this; 1440 let o = e; 1441 o < 0 && (o = 0); 1442 const { params: a, snapGrid: l, slidesGrid: c, previousIndex: d, activeIndex: p, rtlTranslate: u, wrapperEl: h, enabled: m } = r; 1443 if ((r.animating && a.preventInteractionOnTransition) || (!m && !i && !n)) return !1; 1444 const f = Math.min(r.params.slidesPerGroupSkip, o); 1445 let g = f + Math.floor((o - f) / r.params.slidesPerGroup); 1446 g >= l.length && (g = l.length - 1); 1447 const v = -l[g]; 1448 if (a.normalizeSlideIndex) 1449 for (let e = 0; e < c.length; e += 1) { 1450 const t = -Math.floor(100 * v), 1451 s = Math.floor(100 * c[e]), 1452 i = Math.floor(100 * c[e + 1]); 1453 void 0 !== c[e + 1] ? (t >= s && t < i - (i - s) / 2 ? (o = e) : t >= s && t < i && (o = e + 1)) : t >= s && (o = e); 1454 } 1455 if (r.initialized && o !== p) { 1456 if (!r.allowSlideNext && v < r.translate && v < r.minTranslate()) return !1; 1457 if (!r.allowSlidePrev && v > r.translate && v > r.maxTranslate() && (p || 0) !== o) return !1; 1458 } 1459 let b; 1460 if ((o !== (d || 0) && s && r.emit("beforeSlideChangeStart"), r.updateProgress(v), (b = o > p ? "next" : o < p ? "prev" : "reset"), (u && -v === r.translate) || (!u && v === r.translate))) 1461 return r.updateActiveIndex(o), a.autoHeight && r.updateAutoHeight(), r.updateSlidesClasses(), "slide" !== a.effect && r.setTranslate(v), "reset" !== b && (r.transitionStart(s, b), r.transitionEnd(s, b)), !1; 1462 if (a.cssMode) { 1463 const e = r.isHorizontal(), 1464 s = u ? v : -v; 1465 if (0 === t) { 1466 const t = r.virtual && r.params.virtual.enabled; 1467 t && ((r.wrapperEl.style.scrollSnapType = "none"), (r._immediateVirtual = !0)), 1468 (h[e ? "scrollLeft" : "scrollTop"] = s), 1469 t && 1470 requestAnimationFrame(() => { 1471 (r.wrapperEl.style.scrollSnapType = ""), (r._swiperImmediateVirtual = !1); 1472 }); 1473 } else { 1474 if (!r.support.smoothScroll) return P({ swiper: r, targetPosition: s, side: e ? "left" : "top" }), !0; 1475 h.scrollTo({ [e ? "left" : "top"]: s, behavior: "smooth" }); 1476 } 1477 return !0; 1478 } 1479 return ( 1480 r.setTransition(t), 1481 r.setTranslate(v), 1482 r.updateActiveIndex(o), 1483 r.updateSlidesClasses(), 1484 r.emit("beforeTransitionStart", t, i), 1485 r.transitionStart(s, b), 1486 0 === t 1487 ? r.transitionEnd(s, b) 1488 : r.animating || 1489 ((r.animating = !0), 1490 r.onSlideToWrapperTransitionEnd || 1491 (r.onSlideToWrapperTransitionEnd = function (e) { 1492 r && 1493 !r.destroyed && 1494 e.target === this && 1495 (r.$wrapperEl[0].removeEventListener("transitionend", r.onSlideToWrapperTransitionEnd), 1496 r.$wrapperEl[0].removeEventListener("webkitTransitionEnd", r.onSlideToWrapperTransitionEnd), 1497 (r.onSlideToWrapperTransitionEnd = null),
1498 delete r.onSlideToWrapperTransitionEnd, 1499 r.transitionEnd(s, b)); 1500 }), 1501 r.$wrapperEl[0].addEventListener("transitionend", r.onSlideToWrapperTransitionEnd), 1502 r.$wrapperEl[0].addEventListener("webkitTransitionEnd", r.onSlideToWrapperTransitionEnd)), 1503 !0 1504 ); 1505 }, 1506 slideToLoop: function (e = 0, t = this.params.speed, s = !0, i) { 1507 if ("string" == typeof e) { 1508 const t = parseInt(e, 10); 1509 if (!isFinite(t)) throw new Error(`The passed-in 'index' (string) couldn't be converted to 'number'. [${e}] given.`); 1510 e = t; 1511 } 1512 const n = this; 1513 let r = e; 1514 return n.params.loop && (r += n.loopedSlides), n.slideTo(r, t, s, i); 1515 }, 1516 slideNext: function (e = this.params.speed, t = !0, s) { 1517 const i = this, 1518 { animating: n, enabled: r, params: o } = i; 1519 if (!r) return i; 1520 let a = o.slidesPerGroup; 1521 "auto" === o.slidesPerView && 1 === o.slidesPerGroup && o.slidesPerGroupAuto && (a = Math.max(i.slidesPerViewDynamic("current", !0), 1)); 1522 const l = i.activeIndex < o.slidesPerGroupSkip ? 1 : a; 1523 if (o.loop) { 1524 if (n && o.loopPreventsSlide) return !1; 1525 i.loopFix(), (i._clientLeft = i.$wrapperEl[0].clientLeft); 1526 } 1527 return o.rewind && i.isEnd ? i.slideTo(0, e, t, s) : i.slideTo(i.activeIndex + l, e, t, s); 1528 }, 1529 slidePrev: function (e = this.params.speed, t = !0, s) { 1530 const i = this, 1531 { params: n, animating: r, snapGrid: o, slidesGrid: a, rtlTranslate: l, enabled: c } = i; 1532 if (!c) return i; 1533 if (n.loop) { 1534 if (r && n.loopPreventsSlide) return !1; 1535 i.loopFix(), (i._clientLeft = i.$wrapperEl[0].clientLeft); 1536 } 1537 function d(e) { 1538 return e < 0 ? -Math.floor(Math.abs(e)) : Math.floor(e); 1539 } 1540 const p = d(l ? i.translate : -i.translate), 1541 u = o.map((e) => d(e)); 1542 let h = o[u.indexOf(p) - 1]; 1543 if (void 0 === h && n.cssMode) { 1544 let e; 1545 o.forEach((t, s) => { 1546 p >= t && (e = s); 1547 }), 1548 void 0 !== e && (h = o[e > 0 ? e - 1 : e]); 1549 } 1550 let m = 0; 1551 if ( 1552 (void 0 !== h && 1553 ((m = a.indexOf(h)), m < 0 && (m = i.activeIndex - 1), "auto" === n.slidesPerView && 1 === n.slidesPerGroup && n.slidesPerGroupAuto && ((m = m - i.slidesPerViewDynamic("previous", !0) + 1), (m = Math.max(m, 0)))), 1554 n.rewind && i.isBeginning) 1555 ) { 1556 const n = i.params.virtual && i.params.virtual.enabled && i.virtual ? i.virtual.slides.length - 1 : i.slides.length - 1; 1557 return i.slideTo(n, e, t, s); 1558 } 1559 return i.slideTo(m, e, t, s); 1560 }, 1561 slideReset: function (e = this.params.speed, t = !0, s) { 1562 return this.slideTo(this.activeIndex, e, t, s); 1563 }, 1564 slideToClosest: function (e = this.params.speed, t = !0, s, i = 0.5) { 1565 const n = this; 1566 let r = n.activeIndex; 1567 const o = Math.min(n.params.slidesPerGroupSkip, r), 1568 a = o + Math.floor((r - o) / n.params.slidesPerGroup), 1569 l = n.rtlTranslate ? n.translate : -n.translate; 1570 if (l >= n.snapGrid[a]) { 1571 const e = n.snapGrid[a]; 1572 l - e > (n.snapGrid[a + 1] - e) * i && (r += n.params.slidesPerGroup); 1573 } else { 1574 const e = n.snapGrid[a - 1]; 1575 l - e <= (n.snapGrid[a] - e) * i && (r -= n.params.slidesPerGroup); 1576 } 1577 return (r = Math.max(r, 0)), (r = Math.min(r, n.slidesGrid.length - 1)), n.slideTo(r, e, t, s); 1578 }, 1579 slideToClickedSlide: function () { 1580 const e = this, 1581 { params: t, $wrapperEl: s } = e, 1582 i = "auto" === t.slidesPerView ? e.slidesPerViewDynamic() : t.slidesPerView; 1583 let n, 1584 r = e.clickedIndex; 1585 if (t.loop) { 1586 if (e.animating) return; 1587 (n = parseInt(T(e.clickedSlide).attr("data-swiper-slide-index"), 10)), 1588 t.centeredSlides 1589 ? r < e.loopedSlides - i / 2 || r > e.slides.length - e.loopedSlides + i / 2 1590 ? (e.loopFix(), 1591 (r = s.children(`.${t.slideClass}[data-swiper-slide-index="${n}"]:not(.${t.slideDuplicateClass})`).eq(0).index()), 1592 E(() => { 1593 e.slideTo(r); 1594 })) 1595 : e.slideTo(r) 1596 : r > e.slides.length - i 1597 ? (e.loopFix(), 1598 (r = s.children(`.${t.slideClass}[data-swiper-slide-index="${n}"]:not(.${t.slideDuplicateClass})`).eq(0).index()), 1599 E(() => { 1600 e.slideTo(r); 1601 })) 1602 : e.slideTo(r); 1603 } else e.slideTo(r); 1604 }, 1605 }; 1606 const j = { 1607 loopCreate: function () { 1608 const e = this, 1609 t = h(), 1610 { params: s, $wrapperEl: i } = e, 1611 n = i.children().length > 0 ? T(i.children()[0].parentNode) : i; 1612 n.children(`.${s.slideClass}.${s.slideDuplicateClass}`).remove(); 1613 let r = n.children(`.${s.slideClass}`); 1614 if (s.loopFillGroupWithBlank) { 1615 const e = s.slidesPerGroup - (r.length % s.slidesPerGroup); 1616 if (e !== s.slidesPerGroup) { 1617 for (let i = 0; i < e; i += 1) { 1618 const e = T(t.createElement("div")).addClass(`${s.slideClass} ${s.slideBlankClass}`); 1619 n.append(e); 1620 } 1621 r = n.children(`.${s.slideClass}`); 1622 } 1623 } 1624 "auto" !== s.slidesPerView || s.loopedSlides || (s.loopedSlides = r.length), 1625 (e.loopedSlides = Math.ceil(parseFloat(s.loopedSlides || s.slidesPerView, 10))), 1626 (e.loopedSlides += s.loopAdditionalSlides), 1627 e.loopedSlides > r.length && e.params.loopedSlidesLimit && (e.loopedSlides = r.length); 1628 const o = [], 1629 a = []; 1630 r.each((e, t) => { 1631 T(e).attr("data-swiper-slide-index", t); 1632 }); 1633 for (let t = 0; t < e.loopedSlides; t += 1) { 1634 const e = t - Math.floor(t / r.length) * r.length; 1635 a.push(r.eq(e)[0]), o.unshift(r.eq(r.length - e - 1)[0]); 1636 } 1637 for (let e = 0; e < a.length; e += 1) n.append(T(a[e].cloneNode(!0)).addClass(s.slideDuplicateClass)); 1638 for (let e = o.length - 1; e >= 0; e -= 1) n.prepend(T(o[e].cloneNode(!0)).addClass(s.slideDuplicateClass)); 1639 }, 1640 loopFix: function () { 1641 const e = this; 1642 e.emit("beforeLoopFix"); 1643 const { activeIndex: t, slides: s, loopedSlides: i, allowSlidePrev: n, allowSlideNext: r, snapGrid: o, rtlTranslate: a } = e; 1644 let l; 1645 (e.allowSlidePrev = !0), (e.allowSlideNext = !0); 1646 const c = -o[t] - e.getTranslate(); 1647 if (t < i) { 1648 (l = s.length - 3 * i + t), (l += i); 1649 e.slideTo(l, 0, !1, !0) && 0 !== c && e.setTranslate((a ? -e.translate : e.translate) - c); 1650 } else if (t >= s.length - i) { 1651 (l = -s.length + t + i), (l += i); 1652 e.slideTo(l, 0, !1, !0) && 0 !== c && e.setTranslate((a ? -e.translate : e.translate) - c); 1653 } 1654 (e.allowSlidePrev = n), (e.allowSlideNext = r), e.emit("loopFix"); 1655 }, 1656 loopDestroy: function () { 1657 const { $wrapperEl: e, params: t, slides: s } = this; 1658 e.children(`.${t.slideClass}.${t.slideDuplicateClass},.${t.slideClass}.${t.slideBlankClass}`).remove(), s.removeAttr("data-swiper-slide-index"); 1659 }, 1660 }; 1661 function F(e) { 1662 const t = this, 1663 s = h(), 1664 i = f(), 1665 n = t.touchEventsData, 1666 { params: r, touches: o, enabled: a } = t; 1667 if (!a) return; 1668 if (t.animating && r.preventInteractionOnTransition) return; 1669 !t.animating && r.cssMode && r.loop && t.loopFix(); 1670 let l = e; 1671 l.originalEvent && (l = l.originalEvent); 1672 let c = T(l.target); 1673 if ("wrapper" === r.touchEventsTarget && !c.closest(t.wrapperEl).length) return; 1674 if (((n.isTouchEvent = "touchstart" === l.type), !n.isTouchEvent && "which" in l && 3 === l.which)) return; 1675 if (!n.isTouchEvent && "button" in l && l.button > 0) return; 1676 if (n.isTouched && n.isMoved) return; 1677 const d = !!r.noSwipingClass && "" !== r.noSwipingClass, 1678 p = e.composedPath ? e.composedPath() : e.path; 1679 d && l.target && l.target.shadowRoot && p && (c = T(p[0])); 1680 const u = r.noSwipingSelector ? r.noSwipingSelector : `.${r.noSwipingClass}`, 1681 m = !(!l.target || !l.target.shadowRoot); 1682 if (
1683 r.noSwiping && 1684 (m 1685 ? (function (e, t = this) { 1686 return (function t(s) { 1687 if (!s || s === h() || s === f()) return null; 1688 s.assignedSlot && (s = s.assignedSlot); 1689 const i = s.closest(e); 1690 return i || s.getRootNode ? i || t(s.getRootNode().host) : null; 1691 })(t); 1692 })(u, c[0]) 1693 : c.closest(u)[0]) 1694 ) 1695 return void (t.allowClick = !0); 1696 if (r.swipeHandler && !c.closest(r.swipeHandler)[0]) return; 1697 (o.currentX = "touchstart" === l.type ? l.targetTouches[0].pageX : l.pageX), (o.currentY = "touchstart" === l.type ? l.targetTouches[0].pageY : l.pageY); 1698 const g = o.currentX, 1699 v = o.currentY, 1700 b = r.edgeSwipeDetection || r.iOSEdgeSwipeDetection, 1701 y = r.edgeSwipeThreshold || r.iOSEdgeSwipeThreshold; 1702 if (b && (g <= y || g >= i.innerWidth - y)) { 1703 if ("prevent" !== b) return; 1704 e.preventDefault(); 1705 } 1706 if ( 1707 (Object.assign(n, { isTouched: !0, isMoved: !1, allowTouchCallbacks: !0, isScrolling: void 0, startMoving: void 0 }), 1708 (o.startX = g), 1709 (o.startY = v), 1710 (n.touchStartTime = _()), 1711 (t.allowClick = !0), 1712 t.updateSize(), 1713 (t.swipeDirection = void 0), 1714 r.threshold > 0 && (n.allowThresholdMove = !1), 1715 "touchstart" !== l.type) 1716 ) { 1717 let e = !0; 1718 c.is(n.focusableElements) && ((e = !1), "SELECT" === c[0].nodeName && (n.isTouched = !1)), s.activeElement && T(s.activeElement).is(n.focusableElements) && s.activeElement !== c[0] && s.activeElement.blur(); 1719 const i = e && t.allowTouchMove && r.touchStartPreventDefault; 1720 (!r.touchStartForcePreventDefault && !i) || c[0].isContentEditable || l.preventDefault(); 1721 } 1722 t.params.freeMode && t.params.freeMode.enabled && t.freeMode && t.animating && !r.cssMode && t.freeMode.onTouchStart(), t.emit("touchStart", l); 1723 } 1724 function V(e) { 1725 const t = h(), 1726 s = this, 1727 i = s.touchEventsData, 1728 { params: n, touches: r, rtlTranslate: o, enabled: a } = s; 1729 if (!a) return; 1730 let l = e; 1731 if ((l.originalEvent && (l = l.originalEvent), !i.isTouched)) return void (i.startMoving && i.isScrolling && s.emit("touchMoveOpposite", l)); 1732 if (i.isTouchEvent && "touchmove" !== l.type) return; 1733 const c = "touchmove" === l.type && l.targetTouches && (l.targetTouches[0] || l.changedTouches[0]), 1734 d = "touchmove" === l.type ? c.pageX : l.pageX, 1735 p = "touchmove" === l.type ? c.pageY : l.pageY; 1736 if (l.preventedByNestedSwiper) return (r.startX = d), void (r.startY = p); 1737 if (!s.allowTouchMove) return T(l.target).is(i.focusableElements) || (s.allowClick = !1), void (i.isTouched && (Object.assign(r, { startX: d, startY: p, currentX: d, currentY: p }), (i.touchStartTime = _()))); 1738 if (i.isTouchEvent && n.touchReleaseOnEdges && !n.loop) 1739 if (s.isVertical()) { 1740 if ((p < r.startY && s.translate <= s.maxTranslate()) || (p > r.startY && s.translate >= s.minTranslate())) return (i.isTouched = !1), void (i.isMoved = !1); 1741 } else if ((d < r.startX && s.translate <= s.maxTranslate()) || (d > r.startX && s.translate >= s.minTranslate())) return; 1742 if (i.isTouchEvent && t.activeElement && l.target === t.activeElement && T(l.target).is(i.focusableElements)) return (i.isMoved = !0), void (s.allowClick = !1); 1743 if ((i.allowTouchCallbacks && s.emit("touchMove", l), l.targetTouches && l.targetTouches.length > 1)) return; 1744 (r.currentX = d), (r.currentY = p); 1745 const u = r.currentX - r.startX, 1746 m = r.currentY - r.startY; 1747 if (s.params.threshold && Math.sqrt(u ** 2 + m ** 2) < s.params.threshold) return; 1748 if (void 0 === i.isScrolling) { 1749 let e; 1750 (s.isHorizontal() && r.currentY === r.startY) || (s.isVertical() && r.currentX === r.startX) 1751 ? (i.isScrolling = !1) 1752 : u * u + m * m >= 25 && ((e = (180 * Math.atan2(Math.abs(m), Math.abs(u))) / Math.PI), (i.isScrolling = s.isHorizontal() ? e > n.touchAngle : 90 - e > n.touchAngle)); 1753 } 1754 if ((i.isScrolling && s.emit("touchMoveOpposite", l), void 0 === i.startMoving && ((r.currentX === r.startX && r.currentY === r.startY) || (i.startMoving = !0)), i.isScrolling)) return void (i.isTouched = !1); 1755 if (!i.startMoving) return; 1756 (s.allowClick = !1), 1757 !n.cssMode && l.cancelable && l.preventDefault(), 1758 n.touchMoveStopPropagation && !n.nested && l.stopPropagation(), 1759 i.isMoved || 1760 (n.loop && !n.cssMode && s.loopFix(), 1761 (i.startTranslate = s.getTranslate()), 1762 s.setTransition(0), 1763 s.animating && s.$wrapperEl.trigger("webkitTransitionEnd transitionend"), 1764 (i.allowMomentumBounce = !1), 1765 !n.grabCursor || (!0 !== s.allowSlideNext && !0 !== s.allowSlidePrev) || s.setGrabCursor(!0), 1766 s.emit("sliderFirstMove", l)), 1767 s.emit("sliderMove", l),
1768 (i.isMoved = !0); 1769 let f = s.isHorizontal() ? u : m; 1770 (r.diff = f), (f *= n.touchRatio), o && (f = -f), (s.swipeDirection = f > 0 ? "prev" : "next"), (i.currentTranslate = f + i.startTranslate); 1771 let g = !0, 1772 v = n.resistanceRatio; 1773 if ( 1774 (n.touchReleaseOnEdges && (v = 0), 1775 f > 0 && i.currentTranslate > s.minTranslate() 1776 ? ((g = !1), n.resistance && (i.currentTranslate = s.minTranslate() - 1 + (-s.minTranslate() + i.startTranslate + f) ** v)) 1777 : f < 0 && i.currentTranslate < s.maxTranslate() && ((g = !1), n.resistance && (i.currentTranslate = s.maxTranslate() + 1 - (s.maxTranslate() - i.startTranslate - f) ** v)), 1778 g && (l.preventedByNestedSwiper = !0), 1779 !s.allowSlideNext && "next" === s.swipeDirection && i.currentTranslate < i.startTranslate && (i.currentTranslate = i.startTranslate), 1780 !s.allowSlidePrev && "prev" === s.swipeDirection && i.currentTranslate > i.startTranslate && (i.currentTranslate = i.startTranslate), 1781 s.allowSlidePrev || s.allowSlideNext || (i.currentTranslate = i.startTranslate), 1782 n.threshold > 0) 1783 ) { 1784 if (!(Math.abs(f) > n.threshold || i.allowThresholdMove)) return void (i.currentTranslate = i.startTranslate); 1785 if (!i.allowThresholdMove) 1786 return (i.allowThresholdMove = !0), (r.startX = r.currentX), (r.startY = r.currentY), (i.currentTranslate = i.startTranslate), void (r.diff = s.isHorizontal() ? r.currentX - r.startX : r.currentY - r.startY); 1787 } 1788 n.followFinger && 1789 !n.cssMode && 1790 (((n.freeMode && n.freeMode.enabled && s.freeMode) || n.watchSlidesProgress) && (s.updateActiveIndex(), s.updateSlidesClasses()), 1791 s.params.freeMode && n.freeMode.enabled && s.freeMode && s.freeMode.onTouchMove(), 1792 s.updateProgress(i.currentTranslate), 1793 s.setTranslate(i.currentTranslate)); 1794 } 1795 function W(e) { 1796 const t = this, 1797 s = t.touchEventsData, 1798 { params: i, touches: n, rtlTranslate: r, slidesGrid: o, enabled: a } = t; 1799 if (!a) return; 1800 let l = e; 1801 if ((l.originalEvent && (l = l.originalEvent), s.allowTouchCallbacks && t.emit("touchEnd", l), (s.allowTouchCallbacks = !1), !s.isTouched)) 1802 return s.isMoved && i.grabCursor && t.setGrabCursor(!1), (s.isMoved = !1), void (s.startMoving = !1); 1803 i.grabCursor && s.isMoved && s.isTouched && (!0 === t.allowSlideNext || !0 === t.allowSlidePrev) && t.setGrabCursor(!1); 1804 const c = _(), 1805 d = c - s.touchStartTime; 1806 if (t.allowClick) { 1807 const e = l.path || (l.composedPath && l.composedPath()); 1808 t.updateClickedSlide((e && e[0]) || l.target), t.emit("tap click", l), d < 300 && c - s.lastClickTime < 300 && t.emit("doubleTap doubleClick", l); 1809 } 1810 if ( 1811 ((s.lastClickTime = _()), 1812 E(() => { 1813 t.destroyed || (t.allowClick = !0); 1814 }), 1815 !s.isTouched || !s.isMoved || !t.swipeDirection || 0 === n.diff || s.currentTranslate === s.startTranslate) 1816 ) 1817 return (s.isTouched = !1), (s.isMoved = !1), void (s.startMoving = !1); 1818 let p; 1819 if (((s.isTouched = !1), (s.isMoved = !1), (s.startMoving = !1), (p = i.followFinger ? (r ? t.translate : -t.translate) : -s.currentTranslate), i.cssMode)) return; 1820 if (t.params.freeMode && i.freeMode.enabled) return void t.freeMode.onTouchEnd({ currentPos: p }); 1821 let u = 0, 1822 h = t.slidesSizesGrid[0]; 1823 for (let e = 0; e < o.length; e += e < i.slidesPerGroupSkip ? 1 : i.slidesPerGroup) { 1824 const t = e < i.slidesPerGroupSkip - 1 ? 1 : i.slidesPerGroup; 1825 void 0 !== o[e + t] ? p >= o[e] && p < o[e + t] && ((u = e), (h = o[e + t] - o[e])) : p >= o[e] && ((u = e), (h = o[o.length - 1] - o[o.length - 2])); 1826 } 1827 let m = null, 1828 f = null; 1829 i.rewind && (t.isBeginning ? (f = t.params.virtual && t.params.virtual.enabled && t.virtual ? t.virtual.slides.length - 1 : t.slides.length - 1) : t.isEnd && (m = 0)); 1830 const g = (p - o[u]) / h, 1831 v = u < i.slidesPerGroupSkip - 1 ? 1 : i.slidesPerGroup; 1832 if (d > i.longSwipesMs) { 1833 if (!i.longSwipes) return void t.slideTo(t.activeIndex); 1834 "next" === t.swipeDirection && (g >= i.longSwipesRatio ? t.slideTo(i.rewind && t.isEnd ? m : u + v) : t.slideTo(u)), 1835 "prev" === t.swipeDirection && (g > 1 - i.longSwipesRatio ? t.slideTo(u + v) : null !== f && g < 0 && Math.abs(g) > i.longSwipesRatio ? t.slideTo(f) : t.slideTo(u)); 1836 } else { 1837 if (!i.shortSwipes) return void t.slideTo(t.activeIndex); 1838 t.navigation && (l.target === t.navigation.nextEl || l.target === t.navigation.prevEl) 1839 ? l.target === t.navigation.nextEl 1840 ? t.slideTo(u + v) 1841 : t.slideTo(u) 1842 : ("next" === t.swipeDirection && t.slideTo(null !== m ? m : u + v), "prev" === t.swipeDirection && t.slideTo(null !== f ? f : u)); 1843 } 1844 } 1845 function R() { 1846 const e = this, 1847 { params: t, el: s } = e; 1848 if (s && 0 === s.offsetWidth) return; 1849 t.breakpoints && e.setBreakpoint(); 1850 const { allowSlideNext: i, allowSlidePrev: n, snapGrid: r } = e; 1851 (e.allowSlideNext = !0), 1852 (e.allowSlidePrev = !0), 1853 e.updateSize(), 1854 e.updateSlides(), 1855 e.updateSlidesClasses(), 1856 ("auto" === t.slidesPerView || t.slidesPerView > 1) && e.isEnd && !e.isBeginning && !e.params.centeredSlides ? e.slideTo(e.slides.length - 1, 0, !1, !0) : e.slideTo(e.activeIndex, 0, !1, !0), 1857 e.autoplay && e.autoplay.running && e.autoplay.paused && e.autoplay.run(), 1858 (e.allowSlidePrev = n), 1859 (e.allowSlideNext = i), 1860 e.params.watchOverflow && r !== e.snapGrid && e.checkOverflow(); 1861 } 1862 function Y(e) { 1863 const t = this; 1864 t.enabled && (t.allowClick || (t.params.preventClicks && e.preventDefault(), t.params.preventClicksPropagation && t.animating && (e.stopPropagation(), e.stopImmediatePropagation()))); 1865 } 1866 function X() { 1867 const e = this, 1868 { wrapperEl: t, rtlTranslate: s, enabled: i } = e; 1869 if (!i) return; 1870 let n;
1871 (e.previousTranslate = e.translate), e.isHorizontal() ? (e.translate = -t.scrollLeft) : (e.translate = -t.scrollTop), 0 === e.translate && (e.translate = 0), e.updateActiveIndex(), e.updateSlidesClasses(); 1872 const r = e.maxTranslate() - e.minTranslate(); 1873 (n = 0 === r ? 0 : (e.translate - e.minTranslate()) / r), n !== e.progress && e.updateProgress(s ? -e.translate : e.translate), e.emit("setTranslate", e.translate, !1); 1874 } 1875 let U = !1; 1876 function K() {} 1877 const Q = (e, t) => { 1878 const s = h(), 1879 { params: i, touchEvents: n, el: r, wrapperEl: o, device: a, support: l } = e, 1880 c = !!i.nested, 1881 d = "on" === t ? "addEventListener" : "removeEventListener", 1882 p = t; 1883 if (l.touch) { 1884 const t = !("touchstart" !== n.start || !l.passiveListener || !i.passiveListeners) && { passive: !0, capture: !1 }; 1885 r[d](n.start, e.onTouchStart, t), r[d](n.move, e.onTouchMove, l.passiveListener ? { passive: !1, capture: c } : c), r[d](n.end, e.onTouchEnd, t), n.cancel && r[d](n.cancel, e.onTouchEnd, t); 1886 } else r[d](n.start, e.onTouchStart, !1), s[d](n.move, e.onTouchMove, c), s[d](n.end, e.onTouchEnd, !1); 1887 (i.preventClicks || i.preventClicksPropagation) && r[d]("click", e.onClick, !0), 1888 i.cssMode && o[d]("scroll", e.onScroll), 1889 i.updateOnWindowResize ? e[p](a.ios || a.android ? "resize orientationchange observerUpdate" : "resize observerUpdate", R, !0) : e[p]("observerUpdate", R, !0); 1890 }; 1891 const J = { 1892 attachEvents: function () { 1893 const e = this, 1894 t = h(), 1895 { params: s, support: i } = e; 1896 (e.onTouchStart = F.bind(e)), 1897 (e.onTouchMove = V.bind(e)), 1898 (e.onTouchEnd = W.bind(e)), 1899 s.cssMode && (e.onScroll = X.bind(e)), 1900 (e.onClick = Y.bind(e)), 1901 i.touch && !U && (t.addEventListener("touchstart", K), (U = !0)), 1902 Q(e, "on"); 1903 }, 1904 detachEvents: function () { 1905 Q(this, "off"); 1906 }, 1907 }, 1908 Z = (e, t) => e.grid && t.grid && t.grid.rows > 1; 1909 const ee = { 1910 setBreakpoint: function () { 1911 const e = this, 1912 { activeIndex: t, initialized: s, loopedSlides: i = 0, params: n, $el: r } = e, 1913 o = n.breakpoints; 1914 if (!o || (o && 0 === Object.keys(o).length)) return;
1915 const a = e.getBreakpoint(o, e.params.breakpointsBase, e.el); 1916 if (!a || e.currentBreakpoint === a) return; 1917 const l = (a in o ? o[a] : void 0) || e.originalParams, 1918 c = Z(e, n), 1919 d = Z(e, l), 1920 p = n.enabled; 1921 c && !d 1922 ? (r.removeClass(`${n.containerModifierClass}grid ${n.containerModifierClass}grid-column`), e.emitContainerClasses()) 1923 : !c && 1924 d && 1925 (r.addClass(`${n.containerModifierClass}grid`), ((l.grid.fill && "column" === l.grid.fill) || (!l.grid.fill && "column" === n.grid.fill)) && r.addClass(`${n.containerModifierClass}grid-column`), e.emitContainerClasses()), 1926 ["navigation", "pagination", "scrollbar"].forEach((t) => { 1927 const s = n[t] && n[t].enabled, 1928 i = l[t] && l[t].enabled; 1929 s && !i && e[t].disable(), !s && i && e[t].enable(); 1930 }); 1931 const u = l.direction && l.direction !== n.direction, 1932 h = n.loop && (l.slidesPerView !== n.slidesPerView || u); 1933 u && s && e.changeDirection(), k(e.params, l); 1934 const m = e.params.enabled; 1935 Object.assign(e, { allowTouchMove: e.params.allowTouchMove, allowSlideNext: e.params.allowSlideNext, allowSlidePrev: e.params.allowSlidePrev }), 1936 p && !m ? e.disable() : !p && m && e.enable(), 1937 (e.currentBreakpoint = a), 1938 e.emit("_beforeBreakpoint", l), 1939 h && s && (e.loopDestroy(), e.loopCreate(), e.updateSlides(), e.slideTo(t - i + e.loopedSlides, 0, !1)), 1940 e.emit("breakpoint", l); 1941 }, 1942 getBreakpoint: function (e, t = "window", s) { 1943 if (!e || ("container" === t && !s)) return; 1944 let i = !1; 1945 const n = f(), 1946 r = "window" === t ? n.innerHeight : s.clientHeight, 1947 o = Object.keys(e).map((e) => { 1948 if ("string" == typeof e && 0 === e.indexOf("@")) { 1949 const t = parseFloat(e.substr(1)); 1950 return { value: r * t, point: e }; 1951 } 1952 return { value: e, point: e }; 1953 }); 1954 o.sort((e, t) => parseInt(e.value, 10) - parseInt(t.value, 10)); 1955 for (let e = 0; e < o.length; e += 1) { 1956 const { point: r, value: a } = o[e]; 1957 "window" === t ? n.matchMedia(`(min-width: ${a}px)`).matches && (i = r) : a <= s.clientWidth && (i = r); 1958 } 1959 return i || "max"; 1960 }, 1961 }; 1962 const te = { 1963 addClasses: function () { 1964 const e = this, 1965 { classNames: t, params: s, rtl: i, $el: n, device: r, support: o } = e, 1966 a = (function (e, t) { 1967 const s = []; 1968 return ( 1969 e.forEach((e) => { 1970 "object" == typeof e 1971 ? Object.keys(e).forEach((i) => { 1972 e[i] && s.push(t + i); 1973 }) 1974 : "string" == typeof e && s.push(t + e); 1975 }), 1976 s 1977 ); 1978 })( 1979 [ 1980 "initialized", 1981 s.direction, 1982 { "pointer-events": !o.touch }, 1983 { "free-mode": e.params.freeMode && s.freeMode.enabled }, 1984 { autoheight: s.autoHeight }, 1985 { rtl: i }, 1986 { grid: s.grid && s.grid.rows > 1 }, 1987 { "grid-column": s.grid && s.grid.rows > 1 && "column" === s.grid.fill }, 1988 { android: r.android }, 1989 { ios: r.ios }, 1990 { "css-mode": s.cssMode }, 1991 { centered: s.cssMode && s.centeredSlides }, 1992 { "watch-progress": s.watchSlidesProgress }, 1993 ], 1994 s.containerModifierClass 1995 ); 1996 t.push(...a), n.addClass([...t].join(" ")), e.emitContainerClasses(); 1997 }, 1998 removeClasses: function () { 1999 const { $el: e, classNames: t } = this; 2000 e.removeClass(t.join(" ")), this.emitContainerClasses(); 2001 }, 2002 }; 2003 const se = { 2004 init: !0, 2005 direction: "horizontal", 2006 touchEventsTarget: "wrapper", 2007 initialSlide: 0, 2008 speed: 300, 2009 cssMode: !1, 2010 updateOnWindowResize: !0, 2011 resizeObserver: !0, 2012 nested: !1, 2013 createElements: !1, 2014 enabled: !0, 2015 focusableElements: "input, select, option, textarea, button, video, label", 2016 width: null, 2017 height: null, 2018 preventInteractionOnTransition: !1, 2019 userAgent: null, 2020 url: null, 2021 edgeSwipeDetection: !1, 2022 edgeSwipeThreshold: 20, 2023 autoHeight: !1, 2024 setWrapperSize: !1, 2025 virtualTranslate: !1, 2026 effect: "slide", 2027 breakpoints: void 0, 2028 breakpointsBase: "window", 2029 spaceBetween: 0, 2030 slidesPerView: 1, 2031 slidesPerGroup: 1, 2032 slidesPerGroupSkip: 0, 2033 slidesPerGroupAuto: !1, 2034 centeredSlides: !1,
2035 centeredSlidesBounds: !1, 2036 slidesOffsetBefore: 0, 2037 slidesOffsetAfter: 0, 2038 normalizeSlideIndex: !0, 2039 centerInsufficientSlides: !1, 2040 watchOverflow: !0, 2041 roundLengths: !1, 2042 touchRatio: 1, 2043 touchAngle: 45, 2044 simulateTouch: !0, 2045 shortSwipes: !0, 2046 longSwipes: !0, 2047 longSwipesRatio: 0.5, 2048 longSwipesMs: 300, 2049 followFinger: !0, 2050 allowTouchMove: !0, 2051 threshold: 0, 2052 touchMoveStopPropagation: !1, 2053 touchStartPreventDefault: !0, 2054 touchStartForcePreventDefault: !1, 2055 touchReleaseOnEdges: !1, 2056 uniqueNavElements: !0, 2057 resistance: !0, 2058 resistanceRatio: 0.85, 2059 watchSlidesProgress: !1, 2060 grabCursor: !1, 2061 preventClicks: !0, 2062 preventClicksPropagation: !0, 2063 slideToClickedSlide: !1, 2064 preloadImages: !0, 2065 updateOnImagesReady: !0, 2066 loop: !1, 2067 loopAdditionalSlides: 0, 2068 loopedSlides: null, 2069 loopedSlidesLimit: !0, 2070 loopFillGroupWithBlank: !1, 2071 loopPreventsSlide: !0, 2072 rewind: !1, 2073 allowSlidePrev: !0, 2074 allowSlideNext: !0, 2075 swipeHandler: null, 2076 noSwiping: !0, 2077 noSwipingClass: "swiper-no-swiping", 2078 noSwipingSelector: null, 2079 passiveListeners: !0, 2080 maxBackfaceHiddenSlides: 10, 2081 containerModifierClass: "swiper-", 2082 slideClass: "swiper-slide", 2083 slideBlankClass: "swiper-slide-invisible-blank", 2084 slideActiveClass: "swiper-slide-active", 2085 slideDuplicateActiveClass: "swiper-slide-duplicate-active", 2086 slideVisibleClass: "swiper-slide-visible", 2087 slideDuplicateClass: "swiper-slide-duplicate", 2088 slideNextClass: "swiper-slide-next", 2089 slideDuplicateNextClass: "swiper-slide-duplicate-next", 2090 slidePrevClass: "swiper-slide-prev", 2091 slideDuplicatePrevClass: "swiper-slide-duplicate-prev", 2092 wrapperClass: "swiper-wrapper", 2093 runCallbacksOnInit: !0, 2094 _emitClasses: !1, 2095 }; 2096 function ie(e, t) { 2097 return function (s = {}) { 2098 const i = Object.keys(s)[0], 2099 n = s[i]; 2100 "object" == typeof n && null !== n 2101 ? (["navigation", "pagination", "scrollbar"].indexOf(i) >= 0 && !0 === e[i] && (e[i] = { auto: !0 }), 2102 i in e && "enabled" in n ? (!0 === e[i] && (e[i] = { enabled: !0 }), "object" != typeof e[i] || "enabled" in e[i] || (e[i].enabled = !0), e[i] || (e[i] = { enabled: !1 }), k(t, s)) : k(t, s)) 2103 : k(t, s); 2104 }; 2105 } 2106 const ne = { 2107 eventsEmitter: z, 2108 update: B, 2109 translate: H, 2110 transition: { 2111 setTransition: function (e, t) { 2112 const s = this; 2113 s.params.cssMode || s.$wrapperEl.transition(e), s.emit("setTransition", e, t); 2114 }, 2115 transitionStart: function (e = !0, t) { 2116 const s = this, 2117 { params: i } = s; 2118 i.cssMode || (i.autoHeight && s.updateAutoHeight(), G({ swiper: s, runCallbacks: e, direction: t, step: "Start" })); 2119 }, 2120 transitionEnd: function (e = !0, t) { 2121 const s = this, 2122 { params: i } = s; 2123 (s.animating = !1), i.cssMode || (s.setTransition(0), G({ swiper: s, runCallbacks: e, direction: t, step: "End" })); 2124 }, 2125 }, 2126 slide: N, 2127 loop: j, 2128 grabCursor: { 2129 setGrabCursor: function (e) { 2130 const t = this; 2131 if (t.support.touch || !t.params.simulateTouch || (t.params.watchOverflow && t.isLocked) || t.params.cssMode) return; 2132 const s = "container" === t.params.touchEventsTarget ? t.el : t.wrapperEl; 2133 (s.style.cursor = "move"), (s.style.cursor = e ? "grabbing" : "grab"); 2134 }, 2135 unsetGrabCursor: function () { 2136 const e = this; 2137 e.support.touch || (e.params.watchOverflow && e.isLocked) || e.params.cssMode || (e["container" === e.params.touchEventsTarget ? "el" : "wrapperEl"].style.cursor = ""); 2138 }, 2139 }, 2140 events: J, 2141 breakpoints: ee, 2142 checkOverflow: { 2143 checkOverflow: function () { 2144 const e = this, 2145 { isLocked: t, params: s } = e, 2146 { slidesOffsetBefore: i } = s; 2147 if (i) { 2148 const t = e.slides.length - 1, 2149 s = e.slidesGrid[t] + e.slidesSizesGrid[t] + 2 * i;
2150 e.isLocked = e.size > s; 2151 } else e.isLocked = 1 === e.snapGrid.length; 2152 !0 === s.allowSlideNext && (e.allowSlideNext = !e.isLocked), 2153 !0 === s.allowSlidePrev && (e.allowSlidePrev = !e.isLocked), 2154 t && t !== e.isLocked && (e.isEnd = !1), 2155 t !== e.isLocked && e.emit(e.isLocked ? "lock" : "unlock"); 2156 }, 2157 }, 2158 classes: te, 2159 images: { 2160 loadImage: function (e, t, s, i, n, r) { 2161 const o = f(); 2162 let a; 2163 function l() { 2164 r && r(); 2165 } 2166 T(e).parent("picture")[0] || (e.complete && n) ? l() : t ? ((a = new o.Image()), (a.onload = l), (a.onerror = l), i && (a.sizes = i), s && (a.srcset = s), t && (a.src = t)) : l(); 2167 }, 2168 preloadImages: function () { 2169 const e = this; 2170 function t() { 2171 null != e && e && !e.destroyed && (void 0 !== e.imagesLoaded && (e.imagesLoaded += 1), e.imagesLoaded === e.imagesToLoad.length && (e.params.updateOnImagesReady && e.update(), e.emit("imagesReady"))); 2172 } 2173 e.imagesToLoad = e.$el.find("img"); 2174 for (let s = 0; s < e.imagesToLoad.length; s += 1) { 2175 const i = e.imagesToLoad[s]; 2176 e.loadImage(i, i.currentSrc || i.getAttribute("src"), i.srcset || i.getAttribute("srcset"), i.sizes || i.getAttribute("sizes"), !0, t); 2177 } 2178 }, 2179 }, 2180 }, 2181 re = {}; 2182 class oe { 2183 constructor(...e) { 2184 let t, s; 2185 if ((1 === e.length && e[0].constructor && "Object" === Object.prototype.toString.call(e[0]).slice(8, -1) ? (s = e[0]) : ([t, s] = e), s || (s = {}), (s = k({}, s)), t && !s.el && (s.el = t), s.el && T(s.el).length > 1)) { 2186 const e = []; 2187 return ( 2188 T(s.el).each((t) => { 2189 const i = k({}, s, { el: t }); 2190 e.push(new oe(i)); 2191 }), 2192 e 2193 ); 2194 } 2195 const i = this; 2196 (i.__swiper__ = !0), 2197 (i.support = q()), 2198 (i.device = I({ userAgent: s.userAgent })), 2199 (i.browser = D()), 2200 (i.eventsListeners = {}), 2201 (i.eventsAnyListeners = []), 2202 (i.modules = [...i.__modules__]), 2203 s.modules && Array.isArray(s.modules) && i.modules.push(...s.modules); 2204 const n = {}; 2205 i.modules.forEach((e) => { 2206 e({ swiper: i, extendParams: ie(s, n), on: i.on.bind(i), once: i.once.bind(i), off: i.off.bind(i), emit: i.emit.bind(i) }); 2207 }); 2208 const r = k({}, se, n); 2209 return ( 2210 (i.params = k({}, r, re, s)), 2211 (i.originalParams = k({}, i.params)), 2212 (i.passedParams = k({}, s)), 2213 i.params && 2214 i.params.on &&
2215 Object.keys(i.params.on).forEach((e) => { 2216 i.on(e, i.params.on[e]); 2217 }), 2218 i.params && i.params.onAny && i.onAny(i.params.onAny), 2219 (i.$ = T), 2220 Object.assign(i, { 2221 enabled: i.params.enabled, 2222 el: t, 2223 classNames: [], 2224 slides: T(), 2225 slidesGrid: [], 2226 snapGrid: [], 2227 slidesSizesGrid: [], 2228 isHorizontal: () => "horizontal" === i.params.direction, 2229 isVertical: () => "vertical" === i.params.direction, 2230 activeIndex: 0, 2231 realIndex: 0, 2232 isBeginning: !0, 2233 isEnd: !1, 2234 translate: 0, 2235 previousTranslate: 0, 2236 progress: 0, 2237 velocity: 0, 2238 animating: !1, 2239 allowSlideNext: i.params.allowSlideNext, 2240 allowSlidePrev: i.params.allowSlidePrev, 2241 touchEvents: (function () { 2242 const e = ["touchstart", "touchmove", "touchend", "touchcancel"], 2243 t = ["pointerdown", "pointermove", "pointerup"]; 2244 return ( 2245 (i.touchEventsTouch = { start: e[0], move: e[1], end: e[2], cancel: e[3] }), 2246 (i.touchEventsDesktop = { start: t[0], move: t[1], end: t[2] }), 2247 i.support.touch || !i.params.simulateTouch ? i.touchEventsTouch : i.touchEventsDesktop 2248 ); 2249 })(), 2250 touchEventsData: { 2251 isTouched: void 0, 2252 isMoved: void 0, 2253 allowTouchCallbacks: void 0, 2254 touchStartTime: void 0, 2255 isScrolling: void 0, 2256 currentTranslate: void 0, 2257 startTranslate: void 0, 2258 allowThresholdMove: void 0, 2259 focusableElements: i.params.focusableElements, 2260 lastClickTime: _(), 2261 clickTimeout: void 0, 2262 velocities: [], 2263 allowMomentumBounce: void 0, 2264 isTouchEvent: void 0, 2265 startMoving: void 0, 2266 }, 2267 allowClick: !0, 2268 allowTouchMove: i.params.allowTouchMove, 2269 touches: { startX: 0, startY: 0, currentX: 0, currentY: 0, diff: 0 }, 2270 imagesToLoad: [], 2271 imagesLoaded: 0, 2272 }), 2273 i.emit("_swiper"), 2274 i.params.init && i.init(), 2275 i 2276 ); 2277 } 2278 enable() { 2279 const e = this; 2280 e.enabled || ((e.enabled = !0), e.params.grabCursor && e.setGrabCursor(), e.emit("enable")); 2281 } 2282 disable() { 2283 const e = this; 2284 e.enabled && ((e.enabled = !1), e.params.grabCursor && e.unsetGrabCursor(), e.emit("disable")); 2285 } 2286 setProgress(e, t) { 2287 const s = this; 2288 e = Math.min(Math.max(e, 0), 1); 2289 const i = s.minTranslate(), 2290 n = (s.maxTranslate() - i) * e + i; 2291 s.translateTo(n, void 0 === t ? 0 : t), s.updateActiveIndex(), s.updateSlidesClasses(); 2292 } 2293 emitContainerClasses() { 2294 const e = this; 2295 if (!e.params._emitClasses || !e.el) return; 2296 const t = e.el.className.split(" ").filter((t) => 0 === t.indexOf("swiper") || 0 === t.indexOf(e.params.containerModifierClass)); 2297 e.emit("_containerClasses", t.join(" ")); 2298 } 2299 getSlideClasses(e) { 2300 const t = this; 2301 return t.destroyed 2302 ? "" 2303 : e.className 2304 .split(" ") 2305 .filter((e) => 0 === e.indexOf("swiper-slide") || 0 === e.indexOf(t.params.slideClass)) 2306 .join(" "); 2307 } 2308 emitSlidesClasses() { 2309 const e = this; 2310 if (!e.params._emitClasses || !e.el) return; 2311 const t = []; 2312 e.slides.each((s) => { 2313 const i = e.getSlideClasses(s); 2314 t.push({ slideEl: s, classNames: i }), e.emit("_slideClass", s, i); 2315 }), 2316 e.emit("_slideClasses", t); 2317 } 2318 slidesPerViewDynamic(e = "current", t = !1) { 2319 const { params: s, slides: i, slidesGrid: n, slidesSizesGrid: r, size: o, activeIndex: a } = this; 2320 let l = 1; 2321 if (s.centeredSlides) { 2322 let e, 2323 t = i[a].swiperSlideSize; 2324 for (let s = a + 1; s < i.length; s += 1) i[s] && !e && ((t += i[s].swiperSlideSize), (l += 1), t > o && (e = !0)); 2325 for (let s = a - 1; s >= 0; s -= 1) i[s] && !e && ((t += i[s].swiperSlideSize), (l += 1), t > o && (e = !0)); 2326 } else if ("current" === e) 2327 for (let e = a + 1; e < i.length; e += 1) { 2328 (t ? n[e] + r[e] - n[a] < o : n[e] - n[a] < o) && (l += 1); 2329 } 2330 else 2331 for (let e = a - 1; e >= 0; e -= 1) {
2332 n[a] - n[e] < o && (l += 1); 2333 } 2334 return l; 2335 } 2336 update() { 2337 const e = this; 2338 if (!e || e.destroyed) return; 2339 const { snapGrid: t, params: s } = e; 2340 function i() { 2341 const t = e.rtlTranslate ? -1 * e.translate : e.translate, 2342 s = Math.min(Math.max(t, e.maxTranslate()), e.minTranslate()); 2343 e.setTranslate(s), e.updateActiveIndex(), e.updateSlidesClasses(); 2344 } 2345 let n; 2346 s.breakpoints && e.setBreakpoint(), 2347 e.updateSize(), 2348 e.updateSlides(), 2349 e.updateProgress(), 2350 e.updateSlidesClasses(), 2351 e.params.freeMode && e.params.freeMode.enabled 2352 ? (i(), e.params.autoHeight && e.updateAutoHeight()) 2353 : ((n = ("auto" === e.params.slidesPerView || e.params.slidesPerView > 1) && e.isEnd && !e.params.centeredSlides ? e.slideTo(e.slides.length - 1, 0, !1, !0) : e.slideTo(e.activeIndex, 0, !1, !0)), n || i()), 2354 s.watchOverflow && t !== e.snapGrid && e.checkOverflow(), 2355 e.emit("update"); 2356 } 2357 changeDirection(e, t = !0) { 2358 const s = this, 2359 i = s.params.direction; 2360 return ( 2361 e || (e = "horizontal" === i ? "vertical" : "horizontal"), 2362 e === i || 2363 ("horizontal" !== e && "vertical" !== e) || 2364 (s.$el.removeClass(`${s.params.containerModifierClass}${i}`).addClass(`${s.params.containerModifierClass}${e}`), 2365 s.emitContainerClasses(), 2366 (s.params.direction = e), 2367 s.slides.each((t) => { 2368 "vertical" === e ? (t.style.width = "") : (t.style.height = ""); 2369 }), 2370 s.emit("changeDirection"), 2371 t && s.update()), 2372 s 2373 ); 2374 } 2375 changeLanguageDirection(e) { 2376 const t = this; 2377 (t.rtl && "rtl" === e) || 2378 (!t.rtl && "ltr" === e) || 2379 ((t.rtl = "rtl" === e), 2380 (t.rtlTranslate = "horizontal" === t.params.direction && t.rtl), 2381 t.rtl ? (t.$el.addClass(`${t.params.containerModifierClass}rtl`), (t.el.dir = "rtl")) : (t.$el.removeClass(`${t.params.containerModifierClass}rtl`), (t.el.dir = "ltr")), 2382 t.update()); 2383 } 2384 mount(e) { 2385 const t = this; 2386 if (t.mounted) return !0; 2387 const s = T(e || t.params.el); 2388 if (!(e = s[0])) return !1; 2389 e.swiper = t; 2390 const i = () => `.${(t.params.wrapperClass || "").trim().split(" ").join(".")}`; 2391 let n = (() => { 2392 if (e && e.shadowRoot && e.shadowRoot.querySelector) { 2393 const t = T(e.shadowRoot.querySelector(i())); 2394 return (t.children = (e) => s.children(e)), t; 2395 } 2396 return s.children ? s.children(i()) : T(s).children(i()); 2397 })(); 2398 if (0 === n.length && t.params.createElements) { 2399 const e = h().createElement("div"); 2400 (n = T(e)), 2401 (e.className = t.params.wrapperClass), 2402 s.append(e), 2403 s.children(`.${t.params.slideClass}`).each((e) => { 2404 n.append(e); 2405 }); 2406 } 2407 return ( 2408 Object.assign(t, { 2409 $el: s, 2410 el: e, 2411 $wrapperEl: n, 2412 wrapperEl: n[0], 2413 mounted: !0, 2414 rtl: "rtl" === e.dir.toLowerCase() || "rtl" === s.css("direction"), 2415 rtlTranslate: "horizontal" === t.params.direction && ("rtl" === e.dir.toLowerCase() || "rtl" === s.css("direction")), 2416 wrongRTL: "-webkit-box" === n.css("display"), 2417 }), 2418 !0 2419 ); 2420 } 2421 init(e) { 2422 const t = this; 2423 if (t.initialized) return t; 2424 return ( 2425 !1 === t.mount(e) || 2426 (t.emit("beforeInit"), 2427 t.params.breakpoints && t.setBreakpoint(), 2428 t.addClasses(), 2429 t.params.loop && t.loopCreate(), 2430 t.updateSize(), 2431 t.updateSlides(), 2432 t.params.watchOverflow && t.checkOverflow(), 2433 t.params.grabCursor && t.enabled && t.setGrabCursor(
2433), 2434 t.params.preloadImages && t.preloadImages(), 2435 t.params.loop ? t.slideTo(t.params.initialSlide + t.loopedSlides, 0, t.params.runCallbacksOnInit, !1, !0) : t.slideTo(t.params.initialSlide, 0, t.params.runCallbacksOnInit, !1, !0), 2436 t.attachEvents(), 2437 (t.initialized = !0), 2438 t.emit("init"), 2439 t.emit("afterInit")), 2440 t 2441 ); 2442 } 2443 destroy(e = !0, t = !0) { 2444 const s = this, 2445 { params: i, $el: n, $wrapperEl: r, slides: o } = s; 2446 return ( 2447 void 0 === s.params || 2448 s.destroyed || 2449 (s.emit("beforeDestroy"), 2450 (s.initialized = !1), 2451 s.detachEvents(), 2452 i.loop && s.loopDestroy(), 2453 t && 2454 (s.removeClasses(), 2455 n.removeAttr("style"), 2456 r.removeAttr("style"), 2457 o && o.length && o.removeClass([i.slideVisibleClass, i.slideActiveClass, i.slideNextClass, i.slidePrevClass].join(" ")).removeAttr("style").removeAttr("data-swiper-slide-index")), 2458 s.emit("destroy"), 2459 Object.keys(s.eventsListeners).forEach((e) => { 2460 s.off(e); 2461 }), 2462 !1 !== e && 2463 ((s.$el[0].swiper = null), 2464 (function (e) { 2465 const t = e; 2466 Object.keys(t).forEach((e) => { 2467 try { 2468 t[e] = null; 2469 } catch (e) {} 2470 try { 2471 delete t[e]; 2472 } catch (e) {} 2473 }); 2474 })(s)), 2475 (s.destroyed = !0)), 2476 null 2477 ); 2478 } 2479 static extendDefaults(e) { 2480 k(re, e); 2481 } 2482 static get extendedDefaults() { 2483 return re; 2484 } 2485 static get defaults() { 2486 return se; 2487 } 2488 static installModule(e) { 2489 oe.prototype.__modules__ || (oe.prototype.__modules__ = []); 2490 const t = oe.prototype.__modules__; 2491 "function" == typeof e && t.indexOf(e) < 0 && t.push(e); 2492 } 2493 static use(e) { 2494 return Array.isArray(e) ? (e.forEach((e) => oe.installModule(e)), oe) : (oe.installModule(e), oe); 2495 } 2496 } 2497 Object.keys(ne).forEach((e) => {
2498 Object.keys(ne[e]).forEach((t) => { 2499 oe.prototype[t] = ne[e][t]; 2500 }); 2501 }), 2502 oe.use([ 2503 function ({ swiper: e, on: t, emit: s }) { 2504 const i = f(); 2505 let n = null, 2506 r = null; 2507 const o = () => { 2508 e && !e.destroyed && e.initialized && (s("beforeResize"), s("resize")); 2509 }, 2510 a = () => { 2511 e && !e.destroyed && e.initialized && s("orientationchange"); 2512 }; 2513 t("init", () => { 2514 e.params.resizeObserver && void 0 !== i.ResizeObserver 2515 ? e && 2516 !e.destroyed && 2517 e.initialized && 2518 ((n = new ResizeObserver((t) => { 2519 r = i.requestAnimationFrame(() => { 2520 const { width: s, height: i } = e; 2521 let n = s, 2522 r = i; 2523 t.forEach(({ contentBoxSize: t, contentRect: s, target: i }) => { 2524 (i && i !== e.el) || ((n = s ? s.width : (t[0] || t).inlineSize), (r = s ? s.height : (t[0] || t).blockSize)); 2525 }), 2526 (n === s && r === i) || o(); 2527 }); 2528 })), 2529 n.observe(e.el)) 2530 : (i.addEventListener("resize", o), i.addEventListener("orientationchange", a)); 2531 }), 2532 t("destroy", () => { 2533 r && i.cancelAnimationFrame(r), n && n.unobserve && e.el && (n.unobserve(e.el), (n = null)), i.removeEventListener("resize", o), i.removeEventListener("orientationchange", a); 2534 }); 2535 }, 2536 function ({ swiper: e, extendParams: t, on: s, emit: i }) { 2537 const n = [], 2538 r = f(), 2539 o = (e, t = {}) => { 2540 const s = new (r.MutationObserver || r.WebkitMutationObserver)((e) => { 2541 if (1 === e.length) return void i("observerUpdate", e[0]); 2542 const t = function () { 2543 i("observerUpdate", e[0]); 2544 }; 2545 r.requestAnimationFrame ? r.requestAnimationFrame(t) : r.setTimeout(t, 0); 2546 }); 2547 s.observe(e, { attributes: void 0 === t.attributes || t.attributes, childList: void 0 === t.childList || t.childList, characterData: void 0 === t.characterData || t.characterData }), n.push(s); 2548 }; 2549 t({ observer: !1, observeParents: !1, observeSlideChildren: !1 }), 2550 s("init", () => { 2551 if (e.params.observer) { 2552 if (e.params.observeParents) { 2553 const t = e.$el.parents(); 2554 for (let e = 0; e < t.length; e += 1) o(t[e]); 2555 } 2556 o(e.$el[0], { childList: e.params.observeSlideChildren }), o(e.$wrapperEl[0], { attributes: !1 }); 2557 } 2558 }), 2559 s("destroy", () => { 2560 n.forEach((e) => { 2561 e.disconnect(); 2562 }), 2563 n.splice(0, n.length); 2564 }); 2565 }, 2566 ]); 2567 const ae = oe; 2568 function le(e, t, s, i) { 2569 const n = h(); 2570 return ( 2571 e.params.createElements &&
2572 Object.keys(i).forEach((r) => { 2573 if (!s[r] && !0 === s.auto) { 2574 let o = e.$el.children(`.${i[r]}`)[0]; 2575 o || ((o = n.createElement("div")), (o.className = i[r]), e.$el.append(o)), (s[r] = o), (t[r] = o); 2576 } 2577 }), 2578 s 2579 ); 2580 } 2581 function ce({ swiper: e, extendParams: t, on: s, emit: i }) { 2582 function n(t) { 2583 let s; 2584 return t && ((s = T(t)), e.params.uniqueNavElements && "string" == typeof t && s.length > 1 && 1 === e.$el.find(t).length && (s = e.$el.find(t))), s; 2585 } 2586 function r(t, s) { 2587 const i = e.params.navigation; 2588 t && t.length > 0 && (t[s ? "addClass" : "removeClass"](i.disabledClass), t[0] && "BUTTON" === t[0].tagName && (t[0].disabled = s), e.params.watchOverflow && e.enabled && t[e.isLocked ? "addClass" : "removeClass"](i.lockClass)); 2589 } 2590 function o() { 2591 if (e.params.loop) return; 2592 const { $nextEl: t, $prevEl: s } = e.navigation; 2593 r(s, e.isBeginning && !e.params.rewind), r(t, e.isEnd && !e.params.rewind); 2594 } 2595 function a(t) { 2596 t.preventDefault(), (!e.isBeginning || e.params.loop || e.params.rewind) && (e.slidePrev(), i("navigationPrev")); 2597 } 2598 function l(t) { 2599 t.preventDefault(), (!e.isEnd || e.params.loop || e.params.rewind) && (e.slideNext(), i("navigationNext")); 2600 } 2601 function c() { 2602 const t = e.params.navigation; 2603 if (((e.params.navigation = le(e, e.originalParams.navigation, e.params.navigation, { nextEl: "swiper-button-next", prevEl: "swiper-button-prev" })), !t.nextEl && !t.prevEl)) return; 2604 const s = n(t.nextEl), 2605 i = n(t.prevEl); 2606 s && s.length > 0 && s.on("click", l), 2607 i && i.length > 0 && i.on("click", a), 2608 Object.assign(e.navigation, { $nextEl: s, nextEl: s && s[0], $prevEl: i, prevEl: i && i[0] }), 2609 e.enabled || (s && s.addClass(t.lockClass), i && i.addClass(t.lockClass)); 2610 } 2611 function d() { 2612 const { $nextEl: t, $prevEl: s } = e.navigation; 2613 t && t.length && (t.off("click", l), t.removeClass(e.params.navigation.disabledClass)), s && s.length && (s.off("click", a), s.removeClass(e.params.navigation.disabledClass)); 2614 } 2615 t({ 2616 navigation: { nextEl: null, prevEl: null, hideOnClick: !1, disabledClass: "swiper-button-disabled", hiddenClass: "swiper-button-hidden", lockClass: "swiper-button-lock", navigationDisabledClass: "swiper-navigation-disabled" }, 2617 }), 2618 (e.navigation = { nextEl: null, $nextEl: null, prevEl: null, $prevEl: null }), 2619 s("init", () => { 2620 !1 === e.params.navigation.enabled ? p() : (c(), o()); 2621 }), 2622 s("toEdge fromEdge lock unlock", () => { 2623 o(); 2624 }), 2625 s("destroy", () => { 2626 d(); 2627 }), 2628 s("enable disable", () => { 2629 const { $nextEl: t, $prevEl: s } = e.navigation; 2630 t && t[e.enabled ? "removeClass" : "addClass"](e.params.navigation.lockClass), s && s[e.enabled ? "removeClass" : "addClass"](e.params.navigation.lockClass); 2631 }), 2632 s("click", (t, s) => { 2633 const { $nextEl: n, $prevEl: r } = e.navigation, 2634 o = s.target; 2635 if (e.params.navigation.hideOnClick && !T(o).is(r) && !T(o).is(n)) { 2636 if (e.pagination && e.params.pagination && e.params.pagination.clickable && (e.pagination.el === o || e.pagination.el.contains(o))) return; 2637 let t; 2638 n ? (t = n.hasClass(e.params.navigation.hiddenClass)) : r && (t = r.hasClass(e.params.navigation.hiddenClass)), 2639 i(!0 === t ? "navigationShow" : "navigationHide"), 2640 n && n.toggleClass(e.params.navigation.hiddenClass), 2641 r && r.toggleClass(e.params.navigation.hiddenClass); 2642 } 2643 }); 2644 const p = () => { 2645 e.$el.addClass(e.params.navigation.navigationDisabledClass), d(); 2646 }; 2647 Object.assign(e.navigation, { 2648 enable: () => { 2649 e.$el.removeClass(e.params.navigation.navigationDisabledClass), c(), o(); 2650 }, 2651 disable: p, 2652 update: o, 2653 init: c, 2654 destroy: d, 2655 }); 2656 } 2657 function de(e = "") { 2658 return `.${e 2659 .trim() 2660 .replace(/([\.:!\/])/g, "\\$1") 2661 .replace(/ /g, ".")}`; 2662 } 2663 function pe({ swiper: e, extendParams: t, on: s, emit: i }) { 2664 const n = "swiper-pagination"; 2665 let r; 2666 t({ 2667 pagination: { 2668 el: null, 2669 bulletElement: "span", 2670 clickable: !1, 2671 hideOnClick: !1, 2672 renderBullet: null, 2673 renderProgressbar: null, 2674 renderFraction: null, 2675 renderCustom: null, 2676 progressbarOpposite: !1, 2677 type: "bullets", 2678 dynamicBullets: !1, 2679 dynamicMainBullets: 1, 2680 formatFractionCurrent: (e) => e, 2681 formatFractionTotal: (e) => e, 2682 bulletClass: `${n}-bullet`, 2683 bulletActiveClass: `${n}-bullet-active`, 2684 modifierClass: `${n}-`, 2685 currentClass: `${n}-current`, 2686 totalClass: `${n}-total`, 2687 hiddenClass: `${n}-hidden`, 2688 progressbarFillClass: `${n}-progressbar-fill`, 2689 progressbarOppositeClass: `${n}-progressbar-opposite`, 2690 clickableClass: `${n}-clickable`, 2691 lockClass: `${n}-lock`, 2692 horizontalClass: `${n}-horizontal`, 2693 verticalClass: `${n}-vertical`, 2694 paginationDisabledClass: `${n}-disabled`, 2695 }, 2696 }), 2697 (e.pagination = { el: null, $el: null, bullets: [] }); 2698 let o = 0; 2699 function a() { 2700 return !e.params.pagination.el || !e.pagination.el || !e.pagination.$el || 0 === e.pagination.$el.length; 2701 } 2702 function l(t, s) { 2703 const { bulletActiveClass: i } = e.params.pagination; 2704 t[s]().addClass(`${i}-${s}`)[s]().addClass(`${i}-${s}-${s}`); 2705 } 2706 function c() { 2707 const t = e.rtl, 2708 s = e.params.pagination; 2709 if (a()) return; 2710 const n = e.virtual && e.params.virtual.enabled ? e.virtual.slides.length : e.slides.length, 2711 c = e.pagination.$el; 2712 let d; 2713 const p = e.params.loop ? Math.ceil((n - 2 * e.loopedSlides) / e.params.slidesPerGroup) : e.snapGrid.length; 2714 if ( 2715 (e.params.loop 2716 ? ((d = Math.ceil((e.activeIndex - e.loopedSlides) / e.params.slidesPerGroup)), 2717 d > n - 1 - 2 * e.loopedSlides && (d -= n - 2 * e.loopedSlides), 2718 d > p - 1 && (d -= p), 2719 d < 0 && "bullets" !== e.params.paginationType && (d = p + d))
2720 : (d = void 0 !== e.snapIndex ? e.snapIndex : e.activeIndex || 0), 2721 "bullets" === s.type && e.pagination.bullets && e.pagination.bullets.length > 0) 2722 ) { 2723 const i = e.pagination.bullets; 2724 let n, a, p; 2725 if ( 2726 (s.dynamicBullets && 2727 ((r = i.eq(0)[e.isHorizontal() ? "outerWidth" : "outerHeight"](!0)), 2728 c.css(e.isHorizontal() ? "width" : "height", r * (s.dynamicMainBullets + 4) + "px"), 2729 s.dynamicMainBullets > 1 && void 0 !== e.previousIndex && ((o += d - (e.previousIndex - e.loopedSlides || 0)), o > s.dynamicMainBullets - 1 ? (o = s.dynamicMainBullets - 1) : o < 0 && (o = 0)), 2730 (n = Math.max(d - o, 0)), 2731 (a = n + (Math.min(i.length, s.dynamicMainBullets) - 1)), 2732 (p = (a + n) / 2)), 2733 i.removeClass(["", "-next", "-next-next", "-prev", "-prev-prev", "-main"].map((e) => `${s.bulletActiveClass}${e}`).join(" ")), 2734 c.length > 1) 2735 ) 2736 i.each((e) => { 2737 const t = T(e), 2738 i = t.index(); 2739 i === d && t.addClass(s.bulletActiveClass), s.dynamicBullets && (i >= n && i <= a && t.addClass(`${s.bulletActiveClass}-main`), i === n && l(t, "prev"), i === a && l(t, "next")); 2740 }); 2741 else { 2742 const t = i.eq(d), 2743 r = t.index(); 2744 if ((t.addClass(s.bulletActiveClass), s.dynamicBullets)) { 2745 const t = i.eq(n), 2746 o = i.eq(a); 2747 for (let e = n; e <= a; e += 1) i.eq(e).addClass(`${s.bulletActiveClass}-main`); 2748 if (e.params.loop) 2749 if (r >= i.length) { 2750 for (let e = s.dynamicMainBullets; e >= 0; e -= 1) i.eq(i.length - e).addClass(`${s.bulletActiveClass}-main`); 2751 i.eq(i.length - s.dynamicMainBullets - 1).addClass(`${s.bulletActiveClass}-prev`); 2752 } else l(t, "prev"), l(o, "next"); 2753 else l(t, "prev"), l(o, "next"); 2754 } 2755 } 2756 if (s.dynamicBullets) { 2757 const n = Math.min(i.length, s.dynamicMainBullets + 4), 2758 o = (r * n - r) / 2 - p * r, 2759 a = t ? "right" : "left"; 2760 i.css(e.isHorizontal() ? a : "top", `${o}px`); 2761 } 2762 } 2763 if (("fraction" === s.type && (c.find(de(s.currentClass)).text(s.formatFractionCurrent(d + 1)), c.find(de(s.totalClass)).text(s.formatFractionTotal(p))), "progressbar" === s.type)) { 2764 let t; 2765 t = s.progressbarOpposite ? (e.isHorizontal() ? "vertical" : "horizontal") : e.isHorizontal() ? "horizontal" : "vertical"; 2766 const i = (d + 1) / p; 2767 let n = 1, 2768 r = 1; 2769 "horizontal" === t ? (n = i) : (r = i), c.find(de(s.progressbarFillClass)).transform(`translate3d(0,0,0) scaleX(${n}) scaleY(${r})`).transition(e.params.speed); 2770 } 2771 "custom" === s.type && s.renderCustom ? (c.html(s.renderCustom(e, d + 1, p)), i("paginationRender", c[0])) : i("paginationUpdate", c[0]), 2772 e.params.watchOverflow && e.enabled && c[e.isLocked ? "addClass" : "removeClass"](s.lockClass); 2773 } 2774 function d() { 2775 const t = e.params.pagination; 2776 if (a()) return; 2777 const s = e.virtual && e.params.virtual.enabled ? e.virtual.slides.length : e.slides.length, 2778 n = e.pagination.$el; 2779 let r = ""; 2780 if ("bullets" === t.type) { 2781 let i = e.params.loop ? Math.ceil((s - 2 * e.loopedSlides) / e.params.slidesPerGroup) : e.snapGrid.length; 2782 e.params.freeMode && e.params.freeMode.enabled && !e.params.loop && i > s && (i = s); 2783 for (let s = 0; s < i; s += 1) t.renderBullet ? (r += t.renderBullet.call(e, s, t.bulletClass)) : (r += `<${t.bulletElement} class="${t.bulletClass}"></${t.bulletElement}>`); 2784 n.html(r), (e.pagination.bullets = n.find(de(t.bulletClass))); 2785 } 2786 "fraction" === t.type && ((r = t.renderFraction ? t.renderFraction.call(e, t.currentClass, t.totalClass) : `<span class="${t.currentClass}"></span> / <span class="${t.totalClass}"></span>`), n.html(r)), 2787 "progressbar" === t.type && ((r = t.renderProgressbar ? t.renderProgressbar.call(e, t.progressbarFillClass) : `<span class="${t.progressbarFillClass}"></span>`), n.html(r)), 2788 "custom" !== t.type && i("paginationRender", e.pagination.$el[0]); 2789 } 2790 function p() { 2791 e.params.pagination = le(e, e.originalParams.pagination, e.params.pagination, { el: "swiper-pagination" }); 2792 const t = e.params.pagination; 2793 if (!t.el) return; 2794 let s = T(t.el); 2795 0 !== s.length && 2796 (e.params.uniqueNavElements && "string" == typeof t.el && s.length > 1 && ((s = e.$el.find(t.el)), s.length > 1 && (s = s.filter((t) => T(t).parents(".swiper")[0] === e.el))), 2797 "bullets" === t.type && t.clickable && s.addClass(t.clickableClass), 2798 s.addClass(t.modifierClass + t.type), 2799 s.addClass(e.isHorizontal() ? t.horizontalClass : t.verticalClass), 2800 "bullets" === t.type && t.dynamicBullets && (s.addClass(`${t.modifierClass}${t.type}-dynamic`), (o = 0), t.dynamicMainBullets < 1 && (t.dynamicMainBullets = 1)), 2801 "progressbar" === t.type && t.progressbarOpposite && s.addClass(t.progressbarOppositeClass), 2802 t.clickable && 2803 s.on("click", de(t.bulletClass), function (t) { 2804 t.preventDefault(); 2805 let s = T(this).index() * e.params.slidesPerGroup; 2806 e.params.loop && (s += e.loopedSlides), e.slideTo(s); 2807 }), 2808 Object.assign(e.pagination, { $el: s, el: s[0] }), 2809 e.enabled || s.addClass(t.lockClass)); 2810 } 2811 function u() { 2812 const t = e.params.pagination; 2813 if (a()) return; 2814 const s = e.pagination.$el; 2815 s.removeClass(t.hiddenClass), 2816 s.removeClass(t.modifierClass + t.type), 2817 s.removeClass(e.isHorizontal() ? t.horizontalClass : t.verticalClass), 2818 e.pagination.bullets && e.pagination.bullets.removeClass && e.pagination.bullets.removeClass(t.bulletActiveClass), 2819 t.clickable && s.off("click", de(t.bulletClass)); 2820 } 2821 s("init", () => { 2822 !1 === e.params.pagination.enabled ? h() : (p(), d(), c()); 2823 }), 2824 s("activeIndexChange", () => {
2825 (e.params.loop || void 0 === e.snapIndex) && c(); 2826 }), 2827 s("snapIndexChange", () => { 2828 e.params.loop || c(); 2829 }), 2830 s("slidesLengthChange", () => { 2831 e.params.loop && (d(), c()); 2832 }), 2833 s("snapGridLengthChange", () => { 2834 e.params.loop || (d(), c()); 2835 }), 2836 s("destroy", () => { 2837 u(); 2838 }), 2839 s("enable disable", () => { 2840 const { $el: t } = e.pagination; 2841 t && t[e.enabled ? "removeClass" : "addClass"](e.params.pagination.lockClass); 2842 }), 2843 s("lock unlock", () => { 2844 c(); 2845 }), 2846 s("click", (t, s) => { 2847 const n = s.target, 2848 { $el: r } = e.pagination; 2849 if (e.params.pagination.el && e.params.pagination.hideOnClick && r && r.length > 0 && !T(n).hasClass(e.params.pagination.bulletClass)) { 2850 if (e.navigation && ((e.navigation.nextEl && n === e.navigation.nextEl) || (e.navigation.prevEl && n === e.navigation.prevEl))) return; 2851 const t = r.hasClass(e.params.pagination.hiddenClass); 2852 i(!0 === t ? "paginationShow" : "paginationHide"), r.toggleClass(e.params.pagination.hiddenClass); 2853 } 2854 }); 2855 const h = () => { 2856 e.$el.addClass(e.params.pagination.paginationDisabledClass), e.pagination.$el && e.pagination.$el.addClass(e.params.pagination.paginationDisabledClass), u(); 2857 }; 2858 Object.assign(e.pagination, { 2859 enable: () => { 2860 e.$el.removeClass(e.params.pagination.paginationDisabledClass), e.pagination.$el && e.pagination.$el.removeClass(e.params.pagination.paginationDisabledClass), p(), d(), c(); 2861 }, 2862 disable: h, 2863 render: d, 2864 update: c, 2865 init: p, 2866 destroy: u, 2867 }); 2868 } 2869 window.addEventListener("load", function (e) { 2870 document.querySelector(".slider-seminars__body") && 2871 new ae(".slider-seminars__body", { 2872 modules: [ce, pe], 2873 observer: !0, 2874 observeParents: !0, 2875 slidesPerView: "auto", 2876 spaceBetween: 80, 2877 autoHeight: !1, 2878 speed: 800, 2879 centeredSlides: !0, 2880 loop: !0, 2881 pagination: { el: ".swiper-pagination", clickable: !0 }, 2882 navigation: { prevEl: ".swiper-button-prev", nextEl: ".swiper-button-next" }, 2883 on: {}, 2884 }), 2885 document.querySelector(".slider-video__body") && 2886 new ae(".slider-video__body", { 2887 modules: [ce], 2888 observer: !0, 2889 observeParents: !0, 2890 slidesPerView: 1, 2891 spaceBetween: 0, 2892 autoHeight: !1, 2893 speed: 800, 2894 loop: !0, 2895 navigation: { prevEl: ".swiper-button-prev", nextEl: ".swiper-button-next" }, 2896 on: {}, 2897 }); 2898 }); 2899 let ue = !1; 2900 function he(e) { 2901 this.type = e; 2902 } 2903 setTimeout(() => { 2904 if (ue) { 2905 let e = new Event("windowScroll"); 2906 window.addEventListener("scroll", function (t) { 2907 document.dispatchEvent(e); 2908 }); 2909 } 2910 }, 0), 2911 (he.prototype.init = function () { 2912 const e = this; 2913 (this.оbjects = []), (this.daClassname = "_dynamic_adapt_"), (this.nodes = document.querySelectorAll("[data-da]")); 2914 for (let e = 0; e < this.nodes.length; e++) { 2915 const t = this.nodes[e], 2916 s = t.dataset.da.trim().split(","), 2917 i = {}; 2918 (i.element = t), 2919 (i.parent = t.parentNode), 2920 (i.destination = document.querySelector(s[0].trim())), 2921 (i.breakpoint = s[1] ? s[1].trim() : "767"), 2922 (i.place = s[2] ? s[2].trim() : "last"), 2923 (i.index = this.indexInParent(i.parent, i.element)), 2924 this.оbjects.push(i); 2925 } 2926 this.arraySort(this.оbjects), 2927 (this.mediaQueries = Array.prototype.map.call( 2928 this.оbjects, 2929 function (e) { 2930 return "(" + this.type + "-width: " + e.breakpoint + "px)," + e.breakpoint; 2931 }, 2932 this 2933 )), 2934 (this.mediaQueries = Array.prototype.filter.call(this.mediaQueries, function (e, t, s) { 2935 return Array.prototype.indexOf.call(s, e) === t; 2936 })); 2937 for (let t = 0; t < this.mediaQueries.length; t++) { 2938 const s = this.mediaQueries[t], 2939 i = String.prototype.split.call(s, ","), 2940 n = window.matchMedia(i[0]),
2941 r = i[1], 2942 o = Array.prototype.filter.call(this.оbjects, function (e) { 2943 return e.breakpoint === r; 2944 }); 2945 n.addListener(function () { 2946 e.mediaHandler(n, o); 2947 }), 2948 this.mediaHandler(n, o); 2949 } 2950 }), 2951 (he.prototype.mediaHandler = function (e, t) { 2952 if (e.matches) 2953 for (let e = 0; e < t.length; e++) { 2954 const s = t[e]; 2955 (s.index = this.indexInParent(s.parent, s.element)), this.moveTo(s.place, s.element, s.destination); 2956 } 2957 else 2958 for (let e = t.length - 1; e >= 0; e--) { 2959 const s = t[e]; 2960 s.element.classList.contains(this.daClassname) && this.moveBack(s.parent, s.element, s.index); 2961 } 2962 }), 2963 (he.prototype.moveTo = function (e, t, s) { 2964 t.classList.add(this.daClassname), 2965 "last" === e || e >= s.children.length ? s.insertAdjacentElement("beforeend", t) : "first" !== e ? s.children[e].insertAdjacentElement("beforebegin", t) : s.insertAdjacentElement("afterbegin", t); 2966 }), 2967 (he.prototype.moveBack = function (e, t, s) { 2968 t.classList.remove(this.daClassname), void 0 !== e.children[s] ? e.children[s].insertAdjacentElement("beforebegin", t) : e.insertAdjacentElement("beforeend", t); 2969 }), 2970 (he.prototype.indexInParent = function (e, t) { 2971 const s = Array.prototype.slice.call(e.children); 2972 return Array.prototype.indexOf.call(s, t); 2973 }), 2974 (he.prototype.arraySort = function (e) { 2975 "min" === this.type 2976 ? Array.prototype.sort.call(e, function (e, t) { 2977 return e.breakpoint === t.breakpoint ? (e.place === t.place ? 0 : "first" === e.place || "last" === t.place ? -1 : "last" === e.place || "first" === t.place ? 1 : e.place - t.place) : e.breakpoint - t.breakpoint; 2978 }) 2979 : Array.prototype.sort.call(e, function (e, t) { 2980 return e.breakpoint === t.breakpoint ? (e.place === t.place ? 0 : "first" === e.place || "last" === t.place ? 1 : "last" === e.place || "first" === t.place ? -1 : t.place - e.place) : t.breakpoint - e.breakpoint; 2981 }); 2982 }); 2983 if ((new he("max").init(), document.querySelector(".pagination__wrapper"))) { 2984 const ve = document.getElementById("pagination"), 2985 be = document.querySelector("button.next-page"), 2986 ye = document.querySelector("button.prev-page"), 2987 we = { truncate: !0, curPage: 1, numLinksTwoSide: 1, totalPages: 5 }; 2988 function Se() { 2989 const { totalPages: e, curPage: t, truncate: s, numLinksTwoSide: i } = we, 2990 n = i + 2; 2991 let r = "", 2992 o = "", 2993 a = '<li class="pg-item"><a class="pg-link">...</a></li>', 2994 l = 0; 2995 const c = t - i, 2996 d = t + i; 2997 let p = ""; 2998 for (let i = 1; i <= e; i++) 2999 (p = i === t ? "active" : ""), 3000 e >= 2 * n - 1 && s 3001 ? c > 3 && d < e - 3 + 1 3002 ? i >= c && i <= d && (o += Ce(i, p)) 3003 : (t < n && i <= n) || (t > e - n && i >= e - n + 1) || i === e || 1 === i 3004 ? (r += Ce(i, p)) 3005 : (l++, 1 === l && (r += a)) 3006 : (r += Ce(i, p)); 3007 o ? ((o = Ce(1) + a + o + a + Ce(e)), (ve.innerHTML = o)) : (ve.innerHTML = r); 3008 } 3009 function Ce(e, t = "") { 3010 return ` <li class="pg-item ${t}" data-page="${e}">\n <a class="pg-link" href="#">${e}</a>\n </li>`; 3011 } 3012 function Te(e) { 3013 e.classList.contains("prev-page") ? (we.curPage--, Ee(), (be.disabled = !1)) : e.classList.contains("next-page") && (we.curPage++, _e(), (ye.disabled = !1)), Se(); 3014 } 3015 function Ee() { 3016 1 === we.curPage ? (ye.disabled = !0) : (ye.disabled = !1); 3017 } 3018 function _e() { 3019 we.curPage === we.totalPages ? (be.disabled = !0) : (be.disabled = !1); 3020 } 3021 Se(), 3022 (ve.onclick = (e) => { 3023 if (e.target.dataset.page) { 3024 const t = parseInt(e.target.dataset.page, 10); 3025 (we.curPage = t), Se(), Ee(), _e(); 3026 } 3027 }), 3028 (document.querySelector(".pagination__wrapper").onclick = function (e) { 3029 Te(e.target); 3030 }); 3031 } 3032 function me(e) { 3033 e.forEach((e) => { 3034 e.classList.remove("_active"); 3035 }); 3036 } 3037 function fe() { 3038 document.querySelector("._submenu-open--active") && document.querySelector("._submenu-open--active").classList.remove("_submenu-open--active"), 3039 document.querySelector("._submenu-open") && document.querySelector("._submenu-open").classList.remove("_submenu-open"), 3040 document.querySelector("._submenu-child-open--active") && document.querySelector("._submenu-child-open--active").classList.remove("_submenu-child-open--active"), 3041 document.querySelector("._submenu-child-open") && document.querySelector("._submenu-child-open").classList.remove("_submenu-child-open"); 3042 } 3043 if ( 3044 (document.addEventListener("click", function (e) { 3045 const t = e.target; 3046 //console.log(t, '3046'); 3047 if (t.closest("[data-services]")) { 3048 const s = document.querySelector("[data-services-list]"); 3049 if (s) { 3050 const e = document.querySelector("._services--active"), 3051 i = document.querySelector("._services-open"); 3052 e && e !== t && (e.classList.remove("services-open--active"), i.classList.remove("services-open")), t.classList.toggle("_services--active"), s.classList.toggle("_services-open"), fe(); 3053 } else console.log("ÐÐµÑ Ñакого менÑ!"); 3054 e.preventDefault(); 3055 } 3056 if (t.closest("[data-parent]")) { 3057 const s = t.dataset.parent ? t.dataset.parent : null, 3058 i = document.querySelector(`[data-submenu="${s}"]`); 3059 if (i) { 3060 const e = document.querySelector("._submenu-open--active"), 3061 s = document.querySelector("._submenu-open"); 3062 e && e !== t && (e.classList.remove("_submenu-open--active"), s.classList.remove("_submenu-open")), 3063 t.classList.toggle("_submenu-open--active"), 3064 i.classList.toggle("_submenu-open"), 3065 document.querySelector("._submenu-child-open--active") && document.querySelector("._submenu-child-open--active").classList.remove("_submenu-child-open--active"), 3066 document.querySelector("._submenu-child-open") && document.querySelector("._submenu-child-open").classList.remove("_submenu-child-open"); 3067 } else console.log("ÐÐµÑ Ñакого менÑ!"); 3068 e.preventDefault(); 3069 } 3070 if (t.closest("[data-child]")) { 3071 const s = t.dataset.child ? t.dataset.child : null, 3072 i = document.querySelector(`[data-submenu-child="${s}"]`); 3073 if (i) { 3074 const e = document.querySelector("._submenu-child-open--active"), 3075 s = document.querySelector("._submenu-child-open"); 3076 e && e !== t && (e.classList.remove("_submenu-child-open--active"), s.classList.remove("_submenu-child-open")), t.classList.toggle("_submenu-child-open--active"), i.classList.toggle("_submenu-child-open"); 3077 } else console.log("ÐÐµÑ Ñакого менÑ!"); 3078 e.preventDefault(); 3079 } 3080 t.closest(".submenu-catalog") || 3081 t.closest("[data-services]") || 3082 (document.querySelector("._services--active") && document.querySelector("._services--active").classList.remove("_services--active"), 3083 document.querySelector("._services-open") && document.querySelector("._services-open").classList.remove("_services-open"), 3084 fe()); 3085 t.closest(".header__loc") && (document.querySelector(".header__submenu-loc").classList.toggle("_submenu-loc-open"), document.querySelector(".header__loc").classList.toggle("_submenu-loc-active"), e.preventDefault()); 3086 t.closest(".header__submenu-loc") || 3087 t.closest(".header__loc") || 3088 (document.querySelector(".header__submenu-loc") && document.querySelector(".header__submenu-loc").classList.remove("_submenu-loc-open"), 3089 document.querySelector(".header__loc") && document.querySelector(".header__loc").classList.remove("_submenu-loc-active")); 3090 t.closest("._services-back") && 3091 (document.querySelector("._services--active") && document.querySelector("._services--active").classList.remove("_services--active"), 3092 document.querySelector("._services-open") && document.querySelector("._services-open").classList.remove("_services-open")); 3093 t.closest("._submenu-one-back") && 3094 (document.querySelector("._submenu-open--active") && document.querySelector("._submenu-open--active").classList.remove("_submenu-open--active"), 3095 document.querySelector("._submenu-open") && document.querySelector("._submenu-open").classList.remove("_submenu-open")); 3096 t.closest("._submenu-two-back") && 3097 (document.querySelector("._submenu-child-open--active") && document.querySelector("._submenu-child-open--active").classList.remove("_submenu-child-open--active"), 3098 document.querySelector("._submenu-child-open") && document.querySelector("._submenu-child-open").classList.remove("_submenu-child-open")); 3099 if (t.closest(".menu-price__item")) { 3100 const t = e.target.textContent, 3101 s = document.querySelector(".price-hidden"); 3102 (document.querySelector("#price-title").innerHTML = t), (s.style.display = "block"); 3103 } 3104 if (t.closest(".menu-price__link")) { 3105 document.querySelectorAll(".menu-price__link").forEach((e) => { 3106 e.classList.remove("_active"); 3107 }), 3108 t.classList.add("_active"); 3109 } 3110 if (t.closest(".item-calc__material")) { 3111 const e = t.parentNode; 3112 me(document.querySelectorAll(".material-calc__list")), e.querySelector(".material-calc__list").classList.toggle("_active"); 3113 } 3114 if (t.closest(".item-calc__dop")) { 3115 const e = t.parentNode; 3116 me(document.querySelectorAll(".dop-calc__list")), e.querySelector(".dop-calc__list").classList.toggle("_active"); 3117 } 3118 if (t.closest(".item-calc__sale")) { 3119 const e = t.parentNode; 3120 me(document.querySelectorAll(".sale-calc__list")), e.querySelector(".sale-calc__list").classList.toggle("_active"); 3121 } 3122 if (!t.closest(".item-calc__material") && !t.closest(".material-calc__list")) { 3123 me(document.querySelectorAll(".material-calc__list")); 3124 } 3125 if (!t.closest(".item-calc__dop") && !t.closest(".dop-calc__list")) { 3126 me(document.querySelectorAll(".dop-calc__list")); 3127 } 3128 if (!t.closest(".item-calc__sale")) { 3129 me(document.querySelectorAll(".sale-calc__list")); 3130 } 3131 if (t.closest(".dop-calc__input")) { 3132 const e = +document.querySelectorAll(".dop-calc__input[type=checkbox]:checked").length, 3133 t = document.querySelector(".item-calc__dop"), 3134 appKoefs = document.querySelectorAll(".dop-calc__input[type=checkbox]:checked"); 3135 // console.log(e,'3135'); 3136 // console.log(t,'3136');
3137 //console.log(appKoefs,'3137'); 3138 switch (e) { 3139 case 1: 3140 t.innerHTML = `${e} ÑÑлÑга`; 3141 break; 3142 case 2: 3143 case 3: 3144 case 4: 3145 t.innerHTML = `${e} ÑÑлÑги`; 3146 break; 3147 default: 3148 t.innerHTML = `${e} ÑÑлÑг`; 3149 } 3150 t.style.color = "#111"; 3151 //t.dataset.appservicesKoef; 3152 calc(); 3153 } 3154 if (t.closest(".sale-calc__item")) { 3155 const e = t.dataset.sale, 3156 s = document.querySelector(".item-calc__sale"); 3157 (s.innerHTML = `${e} %`), (s.style.color = "#111"), (s.dataset.sale = e); 3158 calc(); 3159 } 3160 if (t.closest(".material-calc__input")) { 3161 const e = t.dataset.material, 3162 mKoef = t.dataset.materialKoef, 3163 s = document.querySelector(".item-calc__material"); 3164 (s.innerHTML = e), (s.style.color = "#111"), (s.dataset.materialKoef = mKoef); 3165 calc(); 3166 //console.log(mKoef,'3159'); 3167 } 3168 if (t.closest(".item-calc__menu")) { 3169 const s = document.querySelector(".calc-catalog__wrapper"); 3170 if (s) { 3171 const e = document.querySelector("._active"), 3172 i = document.querySelector("._open"); 3173 e && e !== t && (e.classList.remove("_active"), i.classList.remove("_open")), t.classList.toggle("_active"), s.classList.toggle("_open"), fe(); 3174 } else console.log("ÐÐµÑ Ñакого менÑ!"); 3175 e.preventDefault(); 3176 } 3177 t.closest(".item-calc__menu") || t.closest(".calc-catalog__wrapper") || (document.querySelector(".calc-catalog__wrapper") && document.querySelector(".calc-catalog__wrapper").classList.remove("_open")); 3178 if (t.closest(".calc-catalog__link")) { 3179 const s = t.dataset.parent ? t.dataset.parent : null, 3180 i = document.querySelector(`[data-subcalc="${s}"]`); 3181 3182 if (i) { 3183 const e = document.querySelector("._submenu-open--active"), 3184 s = document.querySelector("._submenu-open"); 3185 e && e !== t && (e.classList.remove("_submenu-open--active"), s.classList.remove("_submenu-open")), 3186 t.classList.toggle("_submenu-open--active"), 3187 i.classList.toggle("_submenu-open"), 3188 document.querySelector("._submenu-child-open--active") && document.querySelector("._submenu-child-open--active").classList.remove("_submenu-child-open--active"), 3189 document.querySelector("._submenu-child-open") && document.querySelector("._submenu-child-open").classList.remove("_submenu-child-open"); 3190 } else console.log("ÐÐµÑ Ñакого менÑ!"); 3191 e.preventDefault(); 3192 } 3193 if (t.closest(".table-price__label") && document.querySelector("[data-calc]")) { 3194 const e = t.dataset.furniture, 3195 p = t.dataset.menuPrice, 3196 s = document.querySelector(".item-calc__menu span"); 3197 (s.innerHTML = e), (s.style.color = "#111"), (s.dataset.menuPrice = p); 3198 // console.log(s, 3192); 3199 // console.log(e, 3193); 3200 //console.log(p, '3196'); 3201 calc(); 3202 } 3203 //console.log(price); 3204 if (t.closest("[data-tippy-content]")) { 3205 t.parentNode.querySelector(".tippy-box").classList.toggle("_active"); 3206 } 3207 if (!t.closest("[data-tippy-content]")) { 3208 me(document.querySelectorAll(".tippy-box")); 3209 } 3210 }), 3211 document.querySelector("[data-slide]")) 3212 ) { 3213 const xe = document.querySelectorAll("[data-slide]"),
3214 Le = document.querySelectorAll("[data-slider]"); 3215 for (let $e = 0; $e < xe.length; $e++) ke(xe[$e], Le[$e]); 3216 function ke(e, t) { 3217 t.addEventListener("input", (t) => { 3218 e.style.setProperty("--position", `${t.target.value}%`); 3219 }); 3220 } 3221 } 3222 /*if(document.querySelector("[data-items]")){let Pe=document.querySelector(".news-page__more");const Me=document.querySelector("[data-items]").dataset.items;Pe.addEventListener("click",(function(){let e=Me,t=document.querySelectorAll(".news-page__row._hidden");for(let s=0;s<e;s++){if(!t[s])return this.outerHTML="";t[s].classList.remove("_hidden")}}))}*/ function ge( 3223 e 3224 ) { 3225 let t = e.querySelector(".video__link"), 3226 s = e.querySelector(".video__media"), 3227 i = e.querySelector(".video__button"), 3228 n = (function (e) { 3229 let t = /https:\/\/i\.ytimg\.com\/vi\/([a-zA-Z0-9_-]+)\/sddefault\.jpg/i; 3230 return e.src.match(t)[1]; 3231 })(s); 3232 e.addEventListener("click", () => { 3233 let s = (function (e) { 3234 let t = document.createElement("iframe"); 3235 return ( 3236 t.setAttribute("allowfullscreen", ""), 3237 t.setAttribute("allow", "autoplay"), 3238 t.setAttribute( 3239 "src", 3240 (function (e) { 3241 return "https://www.youtube.com/embed/" + e + "?rel=0&showinfo=0&autoplay=1"; 3242 })(e) 3243 ), 3244 t.classList.add("video__media"), 3245 t 3246 ); 3247 })(n); 3248 t.remove(), i.remove(), e.appendChild(s); 3249 }), 3250 t.removeAttribute("href"), 3251 e.classList.add("video--enabled"); 3252 } 3253 !(function () { 3254 let e = document.querySelectorAll(".video-youtube"); 3255 for (let t = 0; t < e.length; t++) ge(e[t]); 3256 })(), 3257 (window.FLS = !1), 3258 (function (e) { 3259 let t = new Image(); 3260 (t.onload = t.onerror = function () { 3261 e(2 == t.height); 3262 }), 3263 (t.src = "data:image/webp;base64,UklGRjoAAABXRUJQVlA4IC4AAACyAgCdASoCAAIALmk0mk0iIiIiIgBoSygABc6WWgAA/veff/0PP8bA//LwYAAA"); 3264 })(function (e) { 3265 let t = !0 === e ? "webp" : "no-webp"; 3266 document.documentElement.classList.add(t); 3267 }), 3268 document.querySelector(".icon-menu") && 3269 document.addEventListener("click", function (e) { 3270 n && 3271 e.target.closest(".icon-menu") && 3272 (((e = 500) => { 3273 document.documentElement.classList.contains("lock") ? r(e) : o(e); 3274 })(), 3275 document.documentElement.classList.toggle("menu-open")); 3276 }), 3277 (function () { 3278 const e = document.querySelectorAll("[data-spollers]"); 3279 if (e.length > 0) { 3280 const t = Array.from(e).filter(function (e, t, s) { 3281 return !e.dataset.spollers.split(",")[0]; 3282 }); 3283 t.length && r(t); 3284 let n = l(e, "spollers"); 3285 function r(e, t = !1) { 3286 e.forEach((e) => { 3287 (e = t ? e.item : e), t.matches || !t ? (e.classList.add("_spoller-init"), o(e), e.addEventListener("click", a)) : (e.classList.remove("_spoller-init"), o(e, !1), e.removeEventListener("click", a)); 3288 }); 3289 } 3290 function o(e, t = !0) { 3291 let s = e.querySelectorAll("[data-spoller]"); 3292 s.length && 3293 ((s = Array.from(s).filter((t) => t.closest("[data-spollers]") === e)), 3294 s.forEach((e) => { 3295 t ? (e.removeAttribute("tabindex"), e.classList.contains("_spoller-active") || (e.nextElementSibling.hidden = !0)) : (e.setAttribute("tabindex", "-1"), (e.nextElementSibling.hidden = !1)); 3296 })); 3297 } 3298 function a(e) { 3299 const t = e.target; 3300 if (t.closest("[data-spoller]")) { 3301 const n = t.closest("[data-spoller]"), 3302 r = n.closest("[data-spollers]"), 3303 o = r.hasAttribute("data-one-spoller"), 3304 a = r.dataset.spollersSpeed ? parseInt(r.dataset.spollersSpeed) : 500; 3305 r.querySelectorAll("._slide").length || 3306 (o && !n.classList.contains("_spoller-active") && c(r), 3307 n.classList.toggle("_spoller-active"), 3308 ((e, t = 500) => { 3309 e.hidden ? i(e, t) : s(e, t); 3310 })(n.nextElementSibling, a)), 3311 e.preventDefault(); 3312 } 3313 } 3314 function c(e) { 3315 const t = e.querySelector("[data-spoller]._spoller-active"), 3316 i = e.dataset.spollersSpeed ? parseInt(e.dataset.spollersSpeed) : 500; 3317 t && !e.querySelectorAll("._slide").length && (t.classList.remove("_spoller-active"), s(t.nextElementSibling, i)); 3318 } 3319 n && 3320 n.length &&
3321 n.forEach((e) => { 3322 e.matchMedia.addEventListener("change", function () { 3323 r(e.itemsArray, e.matchMedia); 3324 }), 3325 r(e.itemsArray, e.matchMedia); 3326 }); 3327 const d = document.querySelectorAll("[data-spoller-close]"); 3328 d.length && 3329 document.addEventListener("click", function (e) { 3330 const t = e.target; 3331 (t.closest("[data-spollers]") && !t.closest(".menu-price__item")) || 3332 d.forEach((e) => { 3333 const t = e.closest("[data-spollers]"), 3334 i = t.dataset.spollersSpeed ? parseInt(t.dataset.spollersSpeed) : 500; 3335 e.classList.remove("_spoller-active"), s(e.nextElementSibling, i); 3336 }); 3337 }); 3338 } 3339 })(), 3340 document.addEventListener("click", function (e) { 3341 let t = e.target; 3342 if (t.closest(".quantity__button")) { 3343 let e = parseInt(t.closest(".quantity").querySelector("input").value); 3344 t.classList.contains("quantity__button_plus") ? e++ : (--e, e < 1 && (e = 1)), (t.closest(".quantity").querySelector("input").value = e); 3345 calc(); 3346 } 3347 }), 3348 (function () { 3349 const e = document.querySelectorAll(".rating"); 3350 e.length > 0 && 3351 (function () { 3352 let t, s; 3353 for (let t = 0; t < e.length; t++) { 3354 i(e[t]); 3355 } 3356 function i(e) { 3357 n(e), r(), e.classList.contains("rating_set") && o(e); 3358 } 3359 function n(e) { 3360 (t = e.querySelector(".rating__active")), (s = e.querySelector(".rating__value")); 3361 } 3362 function r(e = s.innerHTML) { 3363 const i = e / 0.05; 3364 t.style.width = `${i}%`; 3365 } 3366 function o(e) { 3367 const t = e.querySelectorAll(".rating__item"); 3368 for (let i = 0; i < t.length; i++) { 3369 const o = t[i]; 3370 o.addEventListener("mouseenter", function (t) { 3371 n(e), r(o.value); 3372 }), 3373 o.addEventListener("mouseleave", function (e) { 3374 r(); 3375 }), 3376 o.addEventListener("click", function (t) { 3377 n(e), e.dataset.ajax ? a(o.value, e) : ((s.innerHTML = i + 1), r()); 3378 }); 3379 } 3380 } 3381 async function a(e, t) { 3382 if (!t.classList.contains("rating_sending")) { 3383 t.classList.add("rating_sending"); 3384 let e = await fetch("rating.json", { method: "GET" }); 3385 if (e.ok) { 3386 const i = (await e.json()).newRating; 3387 (s.innerHTML = i), r(), t.classList.remove("rating_sending"); 3388 } else alert("ÐÑибка"), t.classList.remove("rating_sending"); 3389 } 3390 } 3391 })(); 3392 })(), 3393 (function () { 3394 function e(e) { 3395 if ("click" === e.type) { 3396 const t = e.target; 3397 if (t.closest("[data-goto]")) { 3398 const s = t.closest("[data-goto]"), 3399 i = s.dataset.goto ? s.dataset.goto : "", 3400 n = !!s.hasAttribute("data-goto-header"), 3401 r = s.dataset.gotoSpeed ? s.dataset.gotoSpeed : 500, 3402 o = s.dataset.gotoTop ? parseInt(s.dataset.gotoTop) : 0; 3403 c(i, n, r, o), e.preventDefault(); 3404 } 3405 } else if ("watcherCallback" === e.type && e.detail) { 3406 const t = e.detail.entry, 3407 s = t.target; 3408 if ("navigator" === s.dataset.watch) { 3409 document.querySelector("[data-goto]._navigator-active"); 3410 let e; 3411 if (s.id && document.querySelector(`[data-goto="#${s.id}"]`)) e = document.querySelector(`[data-goto="#${s.id}"]`); 3412 else if (s.classList.length) 3413 for (let t = 0; t < s.classList.length; t++) { 3414 const i = s.classList[t]; 3415 if (document.querySelector(`[data-goto=".${i}"]`)) { 3416 e = document.querySelector(`[data-goto=".${i}"]`); 3417 break; 3418 } 3419 } 3420 t.isIntersecting ? e && e.classList.add("_navigator-active") : e && e.classList.remove("_navigator-active"); 3421 } 3422 } 3423 } 3424 if ((document.addEventListener("click", e), document.addEventListener("watcherCallback", e), t())) { 3425 let e; 3426 document.querySelector(`#${t()}`) ? (e = `#${t()}`) : document.querySelector(`.${t()}`) && (e = `.${t()}`), e && c(e, !0, 500, 20); 3427 } 3428 })(); 3429})();
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.