mimir-ui-kit 1.39.4 → 1.40.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/PromoSlider.css +1 -0
- package/dist/assets/Tag.css +1 -1
- package/dist/components/Chip/Chip.d.ts +5 -1
- package/dist/components/Chip/index.d.ts +1 -1
- package/dist/components/PromoSlider/PromoSlider.d.ts +59 -0
- package/dist/components/PromoSlider/PromoSlider.js +320 -0
- package/dist/components/PromoSlider/index.d.ts +1 -0
- package/dist/components/PromoSlider/index.js +4 -0
- package/dist/components/Slider/Slider.js +113 -2993
- package/dist/components/Tag/Tag.d.ts +1 -1
- package/dist/components/Tag/Tag.js +29 -28
- package/dist/components/Tag/constants.d.ts +1 -0
- package/dist/components/Tag/constants.js +2 -2
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +6 -4
- package/dist/index.js +43 -41
- package/dist/swiper-react-BvAw14a4.js +2901 -0
- package/package.json +1 -1
@@ -0,0 +1,2901 @@
|
|
1
|
+
import G, { useContext as $e, forwardRef as Pe, useState as X, useRef as F, useEffect as ce, useLayoutEffect as He, createContext as Me } from "react";
|
2
|
+
function ve(t) {
|
3
|
+
return t !== null && typeof t == "object" && "constructor" in t && t.constructor === Object;
|
4
|
+
}
|
5
|
+
function he(t, e) {
|
6
|
+
t === void 0 && (t = {}), e === void 0 && (e = {}), Object.keys(e).forEach((i) => {
|
7
|
+
typeof t[i] > "u" ? t[i] = e[i] : ve(e[i]) && ve(t[i]) && Object.keys(e[i]).length > 0 && he(t[i], e[i]);
|
8
|
+
});
|
9
|
+
}
|
10
|
+
const Ce = {
|
11
|
+
body: {},
|
12
|
+
addEventListener() {
|
13
|
+
},
|
14
|
+
removeEventListener() {
|
15
|
+
},
|
16
|
+
activeElement: {
|
17
|
+
blur() {
|
18
|
+
},
|
19
|
+
nodeName: ""
|
20
|
+
},
|
21
|
+
querySelector() {
|
22
|
+
return null;
|
23
|
+
},
|
24
|
+
querySelectorAll() {
|
25
|
+
return [];
|
26
|
+
},
|
27
|
+
getElementById() {
|
28
|
+
return null;
|
29
|
+
},
|
30
|
+
createEvent() {
|
31
|
+
return {
|
32
|
+
initEvent() {
|
33
|
+
}
|
34
|
+
};
|
35
|
+
},
|
36
|
+
createElement() {
|
37
|
+
return {
|
38
|
+
children: [],
|
39
|
+
childNodes: [],
|
40
|
+
style: {},
|
41
|
+
setAttribute() {
|
42
|
+
},
|
43
|
+
getElementsByTagName() {
|
44
|
+
return [];
|
45
|
+
}
|
46
|
+
};
|
47
|
+
},
|
48
|
+
createElementNS() {
|
49
|
+
return {};
|
50
|
+
},
|
51
|
+
importNode() {
|
52
|
+
return null;
|
53
|
+
},
|
54
|
+
location: {
|
55
|
+
hash: "",
|
56
|
+
host: "",
|
57
|
+
hostname: "",
|
58
|
+
href: "",
|
59
|
+
origin: "",
|
60
|
+
pathname: "",
|
61
|
+
protocol: "",
|
62
|
+
search: ""
|
63
|
+
}
|
64
|
+
};
|
65
|
+
function R() {
|
66
|
+
const t = typeof document < "u" ? document : {};
|
67
|
+
return he(t, Ce), t;
|
68
|
+
}
|
69
|
+
const ke = {
|
70
|
+
document: Ce,
|
71
|
+
navigator: {
|
72
|
+
userAgent: ""
|
73
|
+
},
|
74
|
+
location: {
|
75
|
+
hash: "",
|
76
|
+
host: "",
|
77
|
+
hostname: "",
|
78
|
+
href: "",
|
79
|
+
origin: "",
|
80
|
+
pathname: "",
|
81
|
+
protocol: "",
|
82
|
+
search: ""
|
83
|
+
},
|
84
|
+
history: {
|
85
|
+
replaceState() {
|
86
|
+
},
|
87
|
+
pushState() {
|
88
|
+
},
|
89
|
+
go() {
|
90
|
+
},
|
91
|
+
back() {
|
92
|
+
}
|
93
|
+
},
|
94
|
+
CustomEvent: function() {
|
95
|
+
return this;
|
96
|
+
},
|
97
|
+
addEventListener() {
|
98
|
+
},
|
99
|
+
removeEventListener() {
|
100
|
+
},
|
101
|
+
getComputedStyle() {
|
102
|
+
return {
|
103
|
+
getPropertyValue() {
|
104
|
+
return "";
|
105
|
+
}
|
106
|
+
};
|
107
|
+
},
|
108
|
+
Image() {
|
109
|
+
},
|
110
|
+
Date() {
|
111
|
+
},
|
112
|
+
screen: {},
|
113
|
+
setTimeout() {
|
114
|
+
},
|
115
|
+
clearTimeout() {
|
116
|
+
},
|
117
|
+
matchMedia() {
|
118
|
+
return {};
|
119
|
+
},
|
120
|
+
requestAnimationFrame(t) {
|
121
|
+
return typeof setTimeout > "u" ? (t(), null) : setTimeout(t, 0);
|
122
|
+
},
|
123
|
+
cancelAnimationFrame(t) {
|
124
|
+
typeof setTimeout > "u" || clearTimeout(t);
|
125
|
+
}
|
126
|
+
};
|
127
|
+
function V() {
|
128
|
+
const t = typeof window < "u" ? window : {};
|
129
|
+
return he(t, ke), t;
|
130
|
+
}
|
131
|
+
function We(t) {
|
132
|
+
return t === void 0 && (t = ""), t.trim().split(" ").filter((e) => !!e.trim());
|
133
|
+
}
|
134
|
+
function je(t) {
|
135
|
+
const e = t;
|
136
|
+
Object.keys(e).forEach((i) => {
|
137
|
+
try {
|
138
|
+
e[i] = null;
|
139
|
+
} catch {
|
140
|
+
}
|
141
|
+
try {
|
142
|
+
delete e[i];
|
143
|
+
} catch {
|
144
|
+
}
|
145
|
+
});
|
146
|
+
}
|
147
|
+
function ue(t, e) {
|
148
|
+
return e === void 0 && (e = 0), setTimeout(t, e);
|
149
|
+
}
|
150
|
+
function ee() {
|
151
|
+
return Date.now();
|
152
|
+
}
|
153
|
+
function qe(t) {
|
154
|
+
const e = V();
|
155
|
+
let i;
|
156
|
+
return e.getComputedStyle && (i = e.getComputedStyle(t, null)), !i && t.currentStyle && (i = t.currentStyle), i || (i = t.style), i;
|
157
|
+
}
|
158
|
+
function Ye(t, e) {
|
159
|
+
e === void 0 && (e = "x");
|
160
|
+
const i = V();
|
161
|
+
let s, n, r;
|
162
|
+
const l = qe(t);
|
163
|
+
return i.WebKitCSSMatrix ? (n = l.transform || l.webkitTransform, n.split(",").length > 6 && (n = n.split(", ").map((o) => o.replace(",", ".")).join(", ")), r = new i.WebKitCSSMatrix(n === "none" ? "" : n)) : (r = l.MozTransform || l.OTransform || l.MsTransform || l.msTransform || l.transform || l.getPropertyValue("transform").replace("translate(", "matrix(1, 0, 0, 1,"), s = r.toString().split(",")), e === "x" && (i.WebKitCSSMatrix ? n = r.m41 : s.length === 16 ? n = parseFloat(s[12]) : n = parseFloat(s[4])), e === "y" && (i.WebKitCSSMatrix ? n = r.m42 : s.length === 16 ? n = parseFloat(s[13]) : n = parseFloat(s[5])), n || 0;
|
164
|
+
}
|
165
|
+
function Z(t) {
|
166
|
+
return typeof t == "object" && t !== null && t.constructor && Object.prototype.toString.call(t).slice(8, -1) === "Object";
|
167
|
+
}
|
168
|
+
function Xe(t) {
|
169
|
+
return typeof window < "u" && typeof window.HTMLElement < "u" ? t instanceof HTMLElement : t && (t.nodeType === 1 || t.nodeType === 11);
|
170
|
+
}
|
171
|
+
function N() {
|
172
|
+
const t = Object(arguments.length <= 0 ? void 0 : arguments[0]), e = ["__proto__", "constructor", "prototype"];
|
173
|
+
for (let i = 1; i < arguments.length; i += 1) {
|
174
|
+
const s = i < 0 || arguments.length <= i ? void 0 : arguments[i];
|
175
|
+
if (s != null && !Xe(s)) {
|
176
|
+
const n = Object.keys(Object(s)).filter((r) => e.indexOf(r) < 0);
|
177
|
+
for (let r = 0, l = n.length; r < l; r += 1) {
|
178
|
+
const o = n[r], a = Object.getOwnPropertyDescriptor(s, o);
|
179
|
+
a !== void 0 && a.enumerable && (Z(t[o]) && Z(s[o]) ? s[o].__swiper__ ? t[o] = s[o] : N(t[o], s[o]) : !Z(t[o]) && Z(s[o]) ? (t[o] = {}, s[o].__swiper__ ? t[o] = s[o] : N(t[o], s[o])) : t[o] = s[o]);
|
180
|
+
}
|
181
|
+
}
|
182
|
+
}
|
183
|
+
return t;
|
184
|
+
}
|
185
|
+
function J(t, e, i) {
|
186
|
+
t.style.setProperty(e, i);
|
187
|
+
}
|
188
|
+
function Ie(t) {
|
189
|
+
let {
|
190
|
+
swiper: e,
|
191
|
+
targetPosition: i,
|
192
|
+
side: s
|
193
|
+
} = t;
|
194
|
+
const n = V(), r = -e.translate;
|
195
|
+
let l = null, o;
|
196
|
+
const a = e.params.speed;
|
197
|
+
e.wrapperEl.style.scrollSnapType = "none", n.cancelAnimationFrame(e.cssModeFrameID);
|
198
|
+
const u = i > r ? "next" : "prev", d = (p, f) => u === "next" && p >= f || u === "prev" && p <= f, c = () => {
|
199
|
+
o = (/* @__PURE__ */ new Date()).getTime(), l === null && (l = o);
|
200
|
+
const p = Math.max(Math.min((o - l) / a, 1), 0), f = 0.5 - Math.cos(p * Math.PI) / 2;
|
201
|
+
let h = r + f * (i - r);
|
202
|
+
if (d(h, i) && (h = i), e.wrapperEl.scrollTo({
|
203
|
+
[s]: h
|
204
|
+
}), d(h, i)) {
|
205
|
+
e.wrapperEl.style.overflow = "hidden", e.wrapperEl.style.scrollSnapType = "", setTimeout(() => {
|
206
|
+
e.wrapperEl.style.overflow = "", e.wrapperEl.scrollTo({
|
207
|
+
[s]: h
|
208
|
+
});
|
209
|
+
}), n.cancelAnimationFrame(e.cssModeFrameID);
|
210
|
+
return;
|
211
|
+
}
|
212
|
+
e.cssModeFrameID = n.requestAnimationFrame(c);
|
213
|
+
};
|
214
|
+
c();
|
215
|
+
}
|
216
|
+
function H(t, e) {
|
217
|
+
return e === void 0 && (e = ""), [...t.children].filter((i) => i.matches(e));
|
218
|
+
}
|
219
|
+
function te(t) {
|
220
|
+
try {
|
221
|
+
console.warn(t);
|
222
|
+
return;
|
223
|
+
} catch {
|
224
|
+
}
|
225
|
+
}
|
226
|
+
function fe(t, e) {
|
227
|
+
e === void 0 && (e = []);
|
228
|
+
const i = document.createElement(t);
|
229
|
+
return i.classList.add(...Array.isArray(e) ? e : We(e)), i;
|
230
|
+
}
|
231
|
+
function Si(t) {
|
232
|
+
const e = V(), i = R(), s = t.getBoundingClientRect(), n = i.body, r = t.clientTop || n.clientTop || 0, l = t.clientLeft || n.clientLeft || 0, o = t === e ? e.scrollY : t.scrollTop, a = t === e ? e.scrollX : t.scrollLeft;
|
233
|
+
return {
|
234
|
+
top: s.top + o - r,
|
235
|
+
left: s.left + a - l
|
236
|
+
};
|
237
|
+
}
|
238
|
+
function Ke(t, e) {
|
239
|
+
const i = [];
|
240
|
+
for (; t.previousElementSibling; ) {
|
241
|
+
const s = t.previousElementSibling;
|
242
|
+
e ? s.matches(e) && i.push(s) : i.push(s), t = s;
|
243
|
+
}
|
244
|
+
return i;
|
245
|
+
}
|
246
|
+
function Ue(t, e) {
|
247
|
+
const i = [];
|
248
|
+
for (; t.nextElementSibling; ) {
|
249
|
+
const s = t.nextElementSibling;
|
250
|
+
e ? s.matches(e) && i.push(s) : i.push(s), t = s;
|
251
|
+
}
|
252
|
+
return i;
|
253
|
+
}
|
254
|
+
function k(t, e) {
|
255
|
+
return V().getComputedStyle(t, null).getPropertyValue(e);
|
256
|
+
}
|
257
|
+
function we(t) {
|
258
|
+
let e = t, i;
|
259
|
+
if (e) {
|
260
|
+
for (i = 0; (e = e.previousSibling) !== null; )
|
261
|
+
e.nodeType === 1 && (i += 1);
|
262
|
+
return i;
|
263
|
+
}
|
264
|
+
}
|
265
|
+
function Ze(t, e) {
|
266
|
+
const i = [];
|
267
|
+
let s = t.parentElement;
|
268
|
+
for (; s; )
|
269
|
+
e ? s.matches(e) && i.push(s) : i.push(s), s = s.parentElement;
|
270
|
+
return i;
|
271
|
+
}
|
272
|
+
function Se(t, e, i) {
|
273
|
+
const s = V();
|
274
|
+
return t[e === "width" ? "offsetWidth" : "offsetHeight"] + parseFloat(s.getComputedStyle(t, null).getPropertyValue(e === "width" ? "margin-right" : "margin-top")) + parseFloat(s.getComputedStyle(t, null).getPropertyValue(e === "width" ? "margin-left" : "margin-bottom"));
|
275
|
+
}
|
276
|
+
function Ti(t) {
|
277
|
+
let {
|
278
|
+
swiper: e,
|
279
|
+
extendParams: i,
|
280
|
+
on: s,
|
281
|
+
emit: n,
|
282
|
+
params: r
|
283
|
+
} = t;
|
284
|
+
e.autoplay = {
|
285
|
+
running: !1,
|
286
|
+
paused: !1,
|
287
|
+
timeLeft: 0
|
288
|
+
}, i({
|
289
|
+
autoplay: {
|
290
|
+
enabled: !1,
|
291
|
+
delay: 3e3,
|
292
|
+
waitForTransition: !0,
|
293
|
+
disableOnInteraction: !1,
|
294
|
+
stopOnLastSlide: !1,
|
295
|
+
reverseDirection: !1,
|
296
|
+
pauseOnMouseEnter: !1
|
297
|
+
}
|
298
|
+
});
|
299
|
+
let l, o, a = r && r.autoplay ? r.autoplay.delay : 3e3, u = r && r.autoplay ? r.autoplay.delay : 3e3, d, c = (/* @__PURE__ */ new Date()).getTime(), p, f, h, v, y, m, b;
|
300
|
+
function g(L) {
|
301
|
+
!e || e.destroyed || !e.wrapperEl || L.target === e.wrapperEl && (e.wrapperEl.removeEventListener("transitionend", g), !(b || L.detail && L.detail.bySwiperTouchMove) && w());
|
302
|
+
}
|
303
|
+
const S = () => {
|
304
|
+
if (e.destroyed || !e.autoplay.running) return;
|
305
|
+
e.autoplay.paused ? p = !0 : p && (u = d, p = !1);
|
306
|
+
const L = e.autoplay.paused ? d : c + u - (/* @__PURE__ */ new Date()).getTime();
|
307
|
+
e.autoplay.timeLeft = L, n("autoplayTimeLeft", L, L / a), o = requestAnimationFrame(() => {
|
308
|
+
S();
|
309
|
+
});
|
310
|
+
}, T = () => {
|
311
|
+
let L;
|
312
|
+
return e.virtual && e.params.virtual.enabled ? L = e.slides.filter((A) => A.classList.contains("swiper-slide-active"))[0] : L = e.slides[e.activeIndex], L ? parseInt(L.getAttribute("data-swiper-autoplay"), 10) : void 0;
|
313
|
+
}, I = (L) => {
|
314
|
+
if (e.destroyed || !e.autoplay.running) return;
|
315
|
+
cancelAnimationFrame(o), S();
|
316
|
+
let z = typeof L > "u" ? e.params.autoplay.delay : L;
|
317
|
+
a = e.params.autoplay.delay, u = e.params.autoplay.delay;
|
318
|
+
const A = T();
|
319
|
+
!Number.isNaN(A) && A > 0 && typeof L > "u" && (z = A, a = A, u = A), d = z;
|
320
|
+
const W = e.params.speed, U = () => {
|
321
|
+
!e || e.destroyed || (e.params.autoplay.reverseDirection ? !e.isBeginning || e.params.loop || e.params.rewind ? (e.slidePrev(W, !0, !0), n("autoplay")) : e.params.autoplay.stopOnLastSlide || (e.slideTo(e.slides.length - 1, W, !0, !0), n("autoplay")) : !e.isEnd || e.params.loop || e.params.rewind ? (e.slideNext(W, !0, !0), n("autoplay")) : e.params.autoplay.stopOnLastSlide || (e.slideTo(0, W, !0, !0), n("autoplay")), e.params.cssMode && (c = (/* @__PURE__ */ new Date()).getTime(), requestAnimationFrame(() => {
|
322
|
+
I();
|
323
|
+
})));
|
324
|
+
};
|
325
|
+
return z > 0 ? (clearTimeout(l), l = setTimeout(() => {
|
326
|
+
U();
|
327
|
+
}, z)) : requestAnimationFrame(() => {
|
328
|
+
U();
|
329
|
+
}), z;
|
330
|
+
}, _ = () => {
|
331
|
+
c = (/* @__PURE__ */ new Date()).getTime(), e.autoplay.running = !0, I(), n("autoplayStart");
|
332
|
+
}, C = () => {
|
333
|
+
e.autoplay.running = !1, clearTimeout(l), cancelAnimationFrame(o), n("autoplayStop");
|
334
|
+
}, x = (L, z) => {
|
335
|
+
if (e.destroyed || !e.autoplay.running) return;
|
336
|
+
clearTimeout(l), L || (m = !0);
|
337
|
+
const A = () => {
|
338
|
+
n("autoplayPause"), e.params.autoplay.waitForTransition ? e.wrapperEl.addEventListener("transitionend", g) : w();
|
339
|
+
};
|
340
|
+
if (e.autoplay.paused = !0, z) {
|
341
|
+
y && (d = e.params.autoplay.delay), y = !1, A();
|
342
|
+
return;
|
343
|
+
}
|
344
|
+
d = (d || e.params.autoplay.delay) - ((/* @__PURE__ */ new Date()).getTime() - c), !(e.isEnd && d < 0 && !e.params.loop) && (d < 0 && (d = 0), A());
|
345
|
+
}, w = () => {
|
346
|
+
e.isEnd && d < 0 && !e.params.loop || e.destroyed || !e.autoplay.running || (c = (/* @__PURE__ */ new Date()).getTime(), m ? (m = !1, I(d)) : I(), e.autoplay.paused = !1, n("autoplayResume"));
|
347
|
+
}, E = () => {
|
348
|
+
if (e.destroyed || !e.autoplay.running) return;
|
349
|
+
const L = R();
|
350
|
+
L.visibilityState === "hidden" && (m = !0, x(!0)), L.visibilityState === "visible" && w();
|
351
|
+
}, M = (L) => {
|
352
|
+
L.pointerType === "mouse" && (m = !0, b = !0, !(e.animating || e.autoplay.paused) && x(!0));
|
353
|
+
}, P = (L) => {
|
354
|
+
L.pointerType === "mouse" && (b = !1, e.autoplay.paused && w());
|
355
|
+
}, O = () => {
|
356
|
+
e.params.autoplay.pauseOnMouseEnter && (e.el.addEventListener("pointerenter", M), e.el.addEventListener("pointerleave", P));
|
357
|
+
}, D = () => {
|
358
|
+
e.el && typeof e.el != "string" && (e.el.removeEventListener("pointerenter", M), e.el.removeEventListener("pointerleave", P));
|
359
|
+
}, B = () => {
|
360
|
+
R().addEventListener("visibilitychange", E);
|
361
|
+
}, Y = () => {
|
362
|
+
R().removeEventListener("visibilitychange", E);
|
363
|
+
};
|
364
|
+
s("init", () => {
|
365
|
+
e.params.autoplay.enabled && (O(), B(), _());
|
366
|
+
}), s("destroy", () => {
|
367
|
+
D(), Y(), e.autoplay.running && C();
|
368
|
+
}), s("_freeModeStaticRelease", () => {
|
369
|
+
(h || m) && w();
|
370
|
+
}), s("_freeModeNoMomentumRelease", () => {
|
371
|
+
e.params.autoplay.disableOnInteraction ? C() : x(!0, !0);
|
372
|
+
}), s("beforeTransitionStart", (L, z, A) => {
|
373
|
+
e.destroyed || !e.autoplay.running || (A || !e.params.autoplay.disableOnInteraction ? x(!0, !0) : C());
|
374
|
+
}), s("sliderFirstMove", () => {
|
375
|
+
if (!(e.destroyed || !e.autoplay.running)) {
|
376
|
+
if (e.params.autoplay.disableOnInteraction) {
|
377
|
+
C();
|
378
|
+
return;
|
379
|
+
}
|
380
|
+
f = !0, h = !1, m = !1, v = setTimeout(() => {
|
381
|
+
m = !0, h = !0, x(!0);
|
382
|
+
}, 200);
|
383
|
+
}
|
384
|
+
}), s("touchEnd", () => {
|
385
|
+
if (!(e.destroyed || !e.autoplay.running || !f)) {
|
386
|
+
if (clearTimeout(v), clearTimeout(l), e.params.autoplay.disableOnInteraction) {
|
387
|
+
h = !1, f = !1;
|
388
|
+
return;
|
389
|
+
}
|
390
|
+
h && e.params.cssMode && w(), h = !1, f = !1;
|
391
|
+
}
|
392
|
+
}), s("slideChange", () => {
|
393
|
+
e.destroyed || !e.autoplay.running || (y = !0);
|
394
|
+
}), Object.assign(e.autoplay, {
|
395
|
+
start: _,
|
396
|
+
stop: C,
|
397
|
+
pause: x,
|
398
|
+
resume: w
|
399
|
+
});
|
400
|
+
}
|
401
|
+
let se;
|
402
|
+
function Je() {
|
403
|
+
const t = V(), e = R();
|
404
|
+
return {
|
405
|
+
smoothScroll: e.documentElement && e.documentElement.style && "scrollBehavior" in e.documentElement.style,
|
406
|
+
touch: !!("ontouchstart" in t || t.DocumentTouch && e instanceof t.DocumentTouch)
|
407
|
+
};
|
408
|
+
}
|
409
|
+
function Le() {
|
410
|
+
return se || (se = Je()), se;
|
411
|
+
}
|
412
|
+
let re;
|
413
|
+
function Qe(t) {
|
414
|
+
let {
|
415
|
+
userAgent: e
|
416
|
+
} = t === void 0 ? {} : t;
|
417
|
+
const i = Le(), s = V(), n = s.navigator.platform, r = e || s.navigator.userAgent, l = {
|
418
|
+
ios: !1,
|
419
|
+
android: !1
|
420
|
+
}, o = s.screen.width, a = s.screen.height, u = r.match(/(Android);?[\s\/]+([\d.]+)?/);
|
421
|
+
let d = r.match(/(iPad).*OS\s([\d_]+)/);
|
422
|
+
const c = r.match(/(iPod)(.*OS\s([\d_]+))?/), p = !d && r.match(/(iPhone\sOS|iOS)\s([\d_]+)/), f = n === "Win32";
|
423
|
+
let h = n === "MacIntel";
|
424
|
+
const v = ["1024x1366", "1366x1024", "834x1194", "1194x834", "834x1112", "1112x834", "768x1024", "1024x768", "820x1180", "1180x820", "810x1080", "1080x810"];
|
425
|
+
return !d && h && i.touch && v.indexOf(`${o}x${a}`) >= 0 && (d = r.match(/(Version)\/([\d.]+)/), d || (d = [0, 1, "13_0_0"]), h = !1), u && !f && (l.os = "android", l.android = !0), (d || p || c) && (l.os = "ios", l.ios = !0), l;
|
426
|
+
}
|
427
|
+
function Oe(t) {
|
428
|
+
return t === void 0 && (t = {}), re || (re = Qe(t)), re;
|
429
|
+
}
|
430
|
+
let ne;
|
431
|
+
function et() {
|
432
|
+
const t = V(), e = Oe();
|
433
|
+
let i = !1;
|
434
|
+
function s() {
|
435
|
+
const o = t.navigator.userAgent.toLowerCase();
|
436
|
+
return o.indexOf("safari") >= 0 && o.indexOf("chrome") < 0 && o.indexOf("android") < 0;
|
437
|
+
}
|
438
|
+
if (s()) {
|
439
|
+
const o = String(t.navigator.userAgent);
|
440
|
+
if (o.includes("Version/")) {
|
441
|
+
const [a, u] = o.split("Version/")[1].split(" ")[0].split(".").map((d) => Number(d));
|
442
|
+
i = a < 16 || a === 16 && u < 2;
|
443
|
+
}
|
444
|
+
}
|
445
|
+
const n = /(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(t.navigator.userAgent), r = s(), l = r || n && e.ios;
|
446
|
+
return {
|
447
|
+
isSafari: i || r,
|
448
|
+
needPerspectiveFix: i,
|
449
|
+
need3dFix: l,
|
450
|
+
isWebView: n
|
451
|
+
};
|
452
|
+
}
|
453
|
+
function tt() {
|
454
|
+
return ne || (ne = et()), ne;
|
455
|
+
}
|
456
|
+
function it(t) {
|
457
|
+
let {
|
458
|
+
swiper: e,
|
459
|
+
on: i,
|
460
|
+
emit: s
|
461
|
+
} = t;
|
462
|
+
const n = V();
|
463
|
+
let r = null, l = null;
|
464
|
+
const o = () => {
|
465
|
+
!e || e.destroyed || !e.initialized || (s("beforeResize"), s("resize"));
|
466
|
+
}, a = () => {
|
467
|
+
!e || e.destroyed || !e.initialized || (r = new ResizeObserver((c) => {
|
468
|
+
l = n.requestAnimationFrame(() => {
|
469
|
+
const {
|
470
|
+
width: p,
|
471
|
+
height: f
|
472
|
+
} = e;
|
473
|
+
let h = p, v = f;
|
474
|
+
c.forEach((y) => {
|
475
|
+
let {
|
476
|
+
contentBoxSize: m,
|
477
|
+
contentRect: b,
|
478
|
+
target: g
|
479
|
+
} = y;
|
480
|
+
g && g !== e.el || (h = b ? b.width : (m[0] || m).inlineSize, v = b ? b.height : (m[0] || m).blockSize);
|
481
|
+
}), (h !== p || v !== f) && o();
|
482
|
+
});
|
483
|
+
}), r.observe(e.el));
|
484
|
+
}, u = () => {
|
485
|
+
l && n.cancelAnimationFrame(l), r && r.unobserve && e.el && (r.unobserve(e.el), r = null);
|
486
|
+
}, d = () => {
|
487
|
+
!e || e.destroyed || !e.initialized || s("orientationchange");
|
488
|
+
};
|
489
|
+
i("init", () => {
|
490
|
+
if (e.params.resizeObserver && typeof n.ResizeObserver < "u") {
|
491
|
+
a();
|
492
|
+
return;
|
493
|
+
}
|
494
|
+
n.addEventListener("resize", o), n.addEventListener("orientationchange", d);
|
495
|
+
}), i("destroy", () => {
|
496
|
+
u(), n.removeEventListener("resize", o), n.removeEventListener("orientationchange", d);
|
497
|
+
});
|
498
|
+
}
|
499
|
+
function st(t) {
|
500
|
+
let {
|
501
|
+
swiper: e,
|
502
|
+
extendParams: i,
|
503
|
+
on: s,
|
504
|
+
emit: n
|
505
|
+
} = t;
|
506
|
+
const r = [], l = V(), o = function(d, c) {
|
507
|
+
c === void 0 && (c = {});
|
508
|
+
const p = l.MutationObserver || l.WebkitMutationObserver, f = new p((h) => {
|
509
|
+
if (e.__preventObserver__) return;
|
510
|
+
if (h.length === 1) {
|
511
|
+
n("observerUpdate", h[0]);
|
512
|
+
return;
|
513
|
+
}
|
514
|
+
const v = function() {
|
515
|
+
n("observerUpdate", h[0]);
|
516
|
+
};
|
517
|
+
l.requestAnimationFrame ? l.requestAnimationFrame(v) : l.setTimeout(v, 0);
|
518
|
+
});
|
519
|
+
f.observe(d, {
|
520
|
+
attributes: typeof c.attributes > "u" ? !0 : c.attributes,
|
521
|
+
childList: e.isElement || (typeof c.childList > "u" ? !0 : c).childList,
|
522
|
+
characterData: typeof c.characterData > "u" ? !0 : c.characterData
|
523
|
+
}), r.push(f);
|
524
|
+
}, a = () => {
|
525
|
+
if (e.params.observer) {
|
526
|
+
if (e.params.observeParents) {
|
527
|
+
const d = Ze(e.hostEl);
|
528
|
+
for (let c = 0; c < d.length; c += 1)
|
529
|
+
o(d[c]);
|
530
|
+
}
|
531
|
+
o(e.hostEl, {
|
532
|
+
childList: e.params.observeSlideChildren
|
533
|
+
}), o(e.wrapperEl, {
|
534
|
+
attributes: !1
|
535
|
+
});
|
536
|
+
}
|
537
|
+
}, u = () => {
|
538
|
+
r.forEach((d) => {
|
539
|
+
d.disconnect();
|
540
|
+
}), r.splice(0, r.length);
|
541
|
+
};
|
542
|
+
i({
|
543
|
+
observer: !1,
|
544
|
+
observeParents: !1,
|
545
|
+
observeSlideChildren: !1
|
546
|
+
}), s("init", a), s("destroy", u);
|
547
|
+
}
|
548
|
+
var rt = {
|
549
|
+
on(t, e, i) {
|
550
|
+
const s = this;
|
551
|
+
if (!s.eventsListeners || s.destroyed || typeof e != "function") return s;
|
552
|
+
const n = i ? "unshift" : "push";
|
553
|
+
return t.split(" ").forEach((r) => {
|
554
|
+
s.eventsListeners[r] || (s.eventsListeners[r] = []), s.eventsListeners[r][n](e);
|
555
|
+
}), s;
|
556
|
+
},
|
557
|
+
once(t, e, i) {
|
558
|
+
const s = this;
|
559
|
+
if (!s.eventsListeners || s.destroyed || typeof e != "function") return s;
|
560
|
+
function n() {
|
561
|
+
s.off(t, n), n.__emitterProxy && delete n.__emitterProxy;
|
562
|
+
for (var r = arguments.length, l = new Array(r), o = 0; o < r; o++)
|
563
|
+
l[o] = arguments[o];
|
564
|
+
e.apply(s, l);
|
565
|
+
}
|
566
|
+
return n.__emitterProxy = e, s.on(t, n, i);
|
567
|
+
},
|
568
|
+
onAny(t, e) {
|
569
|
+
const i = this;
|
570
|
+
if (!i.eventsListeners || i.destroyed || typeof t != "function") return i;
|
571
|
+
const s = e ? "unshift" : "push";
|
572
|
+
return i.eventsAnyListeners.indexOf(t) < 0 && i.eventsAnyListeners[s](t), i;
|
573
|
+
},
|
574
|
+
offAny(t) {
|
575
|
+
const e = this;
|
576
|
+
if (!e.eventsListeners || e.destroyed || !e.eventsAnyListeners) return e;
|
577
|
+
const i = e.eventsAnyListeners.indexOf(t);
|
578
|
+
return i >= 0 && e.eventsAnyListeners.splice(i, 1), e;
|
579
|
+
},
|
580
|
+
off(t, e) {
|
581
|
+
const i = this;
|
582
|
+
return !i.eventsListeners || i.destroyed || !i.eventsListeners || t.split(" ").forEach((s) => {
|
583
|
+
typeof e > "u" ? i.eventsListeners[s] = [] : i.eventsListeners[s] && i.eventsListeners[s].forEach((n, r) => {
|
584
|
+
(n === e || n.__emitterProxy && n.__emitterProxy === e) && i.eventsListeners[s].splice(r, 1);
|
585
|
+
});
|
586
|
+
}), i;
|
587
|
+
},
|
588
|
+
emit() {
|
589
|
+
const t = this;
|
590
|
+
if (!t.eventsListeners || t.destroyed || !t.eventsListeners) return t;
|
591
|
+
let e, i, s;
|
592
|
+
for (var n = arguments.length, r = new Array(n), l = 0; l < n; l++)
|
593
|
+
r[l] = arguments[l];
|
594
|
+
return typeof r[0] == "string" || Array.isArray(r[0]) ? (e = r[0], i = r.slice(1, r.length), s = t) : (e = r[0].events, i = r[0].data, s = r[0].context || t), i.unshift(s), (Array.isArray(e) ? e : e.split(" ")).forEach((a) => {
|
595
|
+
t.eventsAnyListeners && t.eventsAnyListeners.length && t.eventsAnyListeners.forEach((u) => {
|
596
|
+
u.apply(s, [a, ...i]);
|
597
|
+
}), t.eventsListeners && t.eventsListeners[a] && t.eventsListeners[a].forEach((u) => {
|
598
|
+
u.apply(s, i);
|
599
|
+
});
|
600
|
+
}), t;
|
601
|
+
}
|
602
|
+
};
|
603
|
+
function nt() {
|
604
|
+
const t = this;
|
605
|
+
let e, i;
|
606
|
+
const s = t.el;
|
607
|
+
typeof t.params.width < "u" && t.params.width !== null ? e = t.params.width : e = s.clientWidth, typeof t.params.height < "u" && t.params.height !== null ? i = t.params.height : i = s.clientHeight, !(e === 0 && t.isHorizontal() || i === 0 && t.isVertical()) && (e = e - parseInt(k(s, "padding-left") || 0, 10) - parseInt(k(s, "padding-right") || 0, 10), i = i - parseInt(k(s, "padding-top") || 0, 10) - parseInt(k(s, "padding-bottom") || 0, 10), Number.isNaN(e) && (e = 0), Number.isNaN(i) && (i = 0), Object.assign(t, {
|
608
|
+
width: e,
|
609
|
+
height: i,
|
610
|
+
size: t.isHorizontal() ? e : i
|
611
|
+
}));
|
612
|
+
}
|
613
|
+
function at() {
|
614
|
+
const t = this;
|
615
|
+
function e(w, E) {
|
616
|
+
return parseFloat(w.getPropertyValue(t.getDirectionLabel(E)) || 0);
|
617
|
+
}
|
618
|
+
const i = t.params, {
|
619
|
+
wrapperEl: s,
|
620
|
+
slidesEl: n,
|
621
|
+
size: r,
|
622
|
+
rtlTranslate: l,
|
623
|
+
wrongRTL: o
|
624
|
+
} = t, a = t.virtual && i.virtual.enabled, u = a ? t.virtual.slides.length : t.slides.length, d = H(n, `.${t.params.slideClass}, swiper-slide`), c = a ? t.virtual.slides.length : d.length;
|
625
|
+
let p = [];
|
626
|
+
const f = [], h = [];
|
627
|
+
let v = i.slidesOffsetBefore;
|
628
|
+
typeof v == "function" && (v = i.slidesOffsetBefore.call(t));
|
629
|
+
let y = i.slidesOffsetAfter;
|
630
|
+
typeof y == "function" && (y = i.slidesOffsetAfter.call(t));
|
631
|
+
const m = t.snapGrid.length, b = t.slidesGrid.length;
|
632
|
+
let g = i.spaceBetween, S = -v, T = 0, I = 0;
|
633
|
+
if (typeof r > "u")
|
634
|
+
return;
|
635
|
+
typeof g == "string" && g.indexOf("%") >= 0 ? g = parseFloat(g.replace("%", "")) / 100 * r : typeof g == "string" && (g = parseFloat(g)), t.virtualSize = -g, d.forEach((w) => {
|
636
|
+
l ? w.style.marginLeft = "" : w.style.marginRight = "", w.style.marginBottom = "", w.style.marginTop = "";
|
637
|
+
}), i.centeredSlides && i.cssMode && (J(s, "--swiper-centered-offset-before", ""), J(s, "--swiper-centered-offset-after", ""));
|
638
|
+
const _ = i.grid && i.grid.rows > 1 && t.grid;
|
639
|
+
_ ? t.grid.initSlides(d) : t.grid && t.grid.unsetSlides();
|
640
|
+
let C;
|
641
|
+
const x = i.slidesPerView === "auto" && i.breakpoints && Object.keys(i.breakpoints).filter((w) => typeof i.breakpoints[w].slidesPerView < "u").length > 0;
|
642
|
+
for (let w = 0; w < c; w += 1) {
|
643
|
+
C = 0;
|
644
|
+
let E;
|
645
|
+
if (d[w] && (E = d[w]), _ && t.grid.updateSlide(w, E, d), !(d[w] && k(E, "display") === "none")) {
|
646
|
+
if (i.slidesPerView === "auto") {
|
647
|
+
x && (d[w].style[t.getDirectionLabel("width")] = "");
|
648
|
+
const M = getComputedStyle(E), P = E.style.transform, O = E.style.webkitTransform;
|
649
|
+
if (P && (E.style.transform = "none"), O && (E.style.webkitTransform = "none"), i.roundLengths)
|
650
|
+
C = t.isHorizontal() ? Se(E, "width") : Se(E, "height");
|
651
|
+
else {
|
652
|
+
const D = e(M, "width"), B = e(M, "padding-left"), Y = e(M, "padding-right"), L = e(M, "margin-left"), z = e(M, "margin-right"), A = M.getPropertyValue("box-sizing");
|
653
|
+
if (A && A === "border-box")
|
654
|
+
C = D + L + z;
|
655
|
+
else {
|
656
|
+
const {
|
657
|
+
clientWidth: W,
|
658
|
+
offsetWidth: U
|
659
|
+
} = E;
|
660
|
+
C = D + B + Y + L + z + (U - W);
|
661
|
+
}
|
662
|
+
}
|
663
|
+
P && (E.style.transform = P), O && (E.style.webkitTransform = O), i.roundLengths && (C = Math.floor(C));
|
664
|
+
} else
|
665
|
+
C = (r - (i.slidesPerView - 1) * g) / i.slidesPerView, i.roundLengths && (C = Math.floor(C)), d[w] && (d[w].style[t.getDirectionLabel("width")] = `${C}px`);
|
666
|
+
d[w] && (d[w].swiperSlideSize = C), h.push(C), i.centeredSlides ? (S = S + C / 2 + T / 2 + g, T === 0 && w !== 0 && (S = S - r / 2 - g), w === 0 && (S = S - r / 2 - g), Math.abs(S) < 1 / 1e3 && (S = 0), i.roundLengths && (S = Math.floor(S)), I % i.slidesPerGroup === 0 && p.push(S), f.push(S)) : (i.roundLengths && (S = Math.floor(S)), (I - Math.min(t.params.slidesPerGroupSkip, I)) % t.params.slidesPerGroup === 0 && p.push(S), f.push(S), S = S + C + g), t.virtualSize += C + g, T = C, I += 1;
|
667
|
+
}
|
668
|
+
}
|
669
|
+
if (t.virtualSize = Math.max(t.virtualSize, r) + y, l && o && (i.effect === "slide" || i.effect === "coverflow") && (s.style.width = `${t.virtualSize + g}px`), i.setWrapperSize && (s.style[t.getDirectionLabel("width")] = `${t.virtualSize + g}px`), _ && t.grid.updateWrapperSize(C, p), !i.centeredSlides) {
|
670
|
+
const w = [];
|
671
|
+
for (let E = 0; E < p.length; E += 1) {
|
672
|
+
let M = p[E];
|
673
|
+
i.roundLengths && (M = Math.floor(M)), p[E] <= t.virtualSize - r && w.push(M);
|
674
|
+
}
|
675
|
+
p = w, Math.floor(t.virtualSize - r) - Math.floor(p[p.length - 1]) > 1 && p.push(t.virtualSize - r);
|
676
|
+
}
|
677
|
+
if (a && i.loop) {
|
678
|
+
const w = h[0] + g;
|
679
|
+
if (i.slidesPerGroup > 1) {
|
680
|
+
const E = Math.ceil((t.virtual.slidesBefore + t.virtual.slidesAfter) / i.slidesPerGroup), M = w * i.slidesPerGroup;
|
681
|
+
for (let P = 0; P < E; P += 1)
|
682
|
+
p.push(p[p.length - 1] + M);
|
683
|
+
}
|
684
|
+
for (let E = 0; E < t.virtual.slidesBefore + t.virtual.slidesAfter; E += 1)
|
685
|
+
i.slidesPerGroup === 1 && p.push(p[p.length - 1] + w), f.push(f[f.length - 1] + w), t.virtualSize += w;
|
686
|
+
}
|
687
|
+
if (p.length === 0 && (p = [0]), g !== 0) {
|
688
|
+
const w = t.isHorizontal() && l ? "marginLeft" : t.getDirectionLabel("marginRight");
|
689
|
+
d.filter((E, M) => !i.cssMode || i.loop ? !0 : M !== d.length - 1).forEach((E) => {
|
690
|
+
E.style[w] = `${g}px`;
|
691
|
+
});
|
692
|
+
}
|
693
|
+
if (i.centeredSlides && i.centeredSlidesBounds) {
|
694
|
+
let w = 0;
|
695
|
+
h.forEach((M) => {
|
696
|
+
w += M + (g || 0);
|
697
|
+
}), w -= g;
|
698
|
+
const E = w - r;
|
699
|
+
p = p.map((M) => M <= 0 ? -v : M > E ? E + y : M);
|
700
|
+
}
|
701
|
+
if (i.centerInsufficientSlides) {
|
702
|
+
let w = 0;
|
703
|
+
h.forEach((M) => {
|
704
|
+
w += M + (g || 0);
|
705
|
+
}), w -= g;
|
706
|
+
const E = (i.slidesOffsetBefore || 0) + (i.slidesOffsetAfter || 0);
|
707
|
+
if (w + E < r) {
|
708
|
+
const M = (r - w - E) / 2;
|
709
|
+
p.forEach((P, O) => {
|
710
|
+
p[O] = P - M;
|
711
|
+
}), f.forEach((P, O) => {
|
712
|
+
f[O] = P + M;
|
713
|
+
});
|
714
|
+
}
|
715
|
+
}
|
716
|
+
if (Object.assign(t, {
|
717
|
+
slides: d,
|
718
|
+
snapGrid: p,
|
719
|
+
slidesGrid: f,
|
720
|
+
slidesSizesGrid: h
|
721
|
+
}), i.centeredSlides && i.cssMode && !i.centeredSlidesBounds) {
|
722
|
+
J(s, "--swiper-centered-offset-before", `${-p[0]}px`), J(s, "--swiper-centered-offset-after", `${t.size / 2 - h[h.length - 1] / 2}px`);
|
723
|
+
const w = -t.snapGrid[0], E = -t.slidesGrid[0];
|
724
|
+
t.snapGrid = t.snapGrid.map((M) => M + w), t.slidesGrid = t.slidesGrid.map((M) => M + E);
|
725
|
+
}
|
726
|
+
if (c !== u && t.emit("slidesLengthChange"), p.length !== m && (t.params.watchOverflow && t.checkOverflow(), t.emit("snapGridLengthChange")), f.length !== b && t.emit("slidesGridLengthChange"), i.watchSlidesProgress && t.updateSlidesOffset(), t.emit("slidesUpdated"), !a && !i.cssMode && (i.effect === "slide" || i.effect === "fade")) {
|
727
|
+
const w = `${i.containerModifierClass}backface-hidden`, E = t.el.classList.contains(w);
|
728
|
+
c <= i.maxBackfaceHiddenSlides ? E || t.el.classList.add(w) : E && t.el.classList.remove(w);
|
729
|
+
}
|
730
|
+
}
|
731
|
+
function lt(t) {
|
732
|
+
const e = this, i = [], s = e.virtual && e.params.virtual.enabled;
|
733
|
+
let n = 0, r;
|
734
|
+
typeof t == "number" ? e.setTransition(t) : t === !0 && e.setTransition(e.params.speed);
|
735
|
+
const l = (o) => s ? e.slides[e.getSlideIndexByData(o)] : e.slides[o];
|
736
|
+
if (e.params.slidesPerView !== "auto" && e.params.slidesPerView > 1)
|
737
|
+
if (e.params.centeredSlides)
|
738
|
+
(e.visibleSlides || []).forEach((o) => {
|
739
|
+
i.push(o);
|
740
|
+
});
|
741
|
+
else
|
742
|
+
for (r = 0; r < Math.ceil(e.params.slidesPerView); r += 1) {
|
743
|
+
const o = e.activeIndex + r;
|
744
|
+
if (o > e.slides.length && !s) break;
|
745
|
+
i.push(l(o));
|
746
|
+
}
|
747
|
+
else
|
748
|
+
i.push(l(e.activeIndex));
|
749
|
+
for (r = 0; r < i.length; r += 1)
|
750
|
+
if (typeof i[r] < "u") {
|
751
|
+
const o = i[r].offsetHeight;
|
752
|
+
n = o > n ? o : n;
|
753
|
+
}
|
754
|
+
(n || n === 0) && (e.wrapperEl.style.height = `${n}px`);
|
755
|
+
}
|
756
|
+
function ot() {
|
757
|
+
const t = this, e = t.slides, i = t.isElement ? t.isHorizontal() ? t.wrapperEl.offsetLeft : t.wrapperEl.offsetTop : 0;
|
758
|
+
for (let s = 0; s < e.length; s += 1)
|
759
|
+
e[s].swiperSlideOffset = (t.isHorizontal() ? e[s].offsetLeft : e[s].offsetTop) - i - t.cssOverflowAdjustment();
|
760
|
+
}
|
761
|
+
const Te = (t, e, i) => {
|
762
|
+
e && !t.classList.contains(i) ? t.classList.add(i) : !e && t.classList.contains(i) && t.classList.remove(i);
|
763
|
+
};
|
764
|
+
function dt(t) {
|
765
|
+
t === void 0 && (t = this && this.translate || 0);
|
766
|
+
const e = this, i = e.params, {
|
767
|
+
slides: s,
|
768
|
+
rtlTranslate: n,
|
769
|
+
snapGrid: r
|
770
|
+
} = e;
|
771
|
+
if (s.length === 0) return;
|
772
|
+
typeof s[0].swiperSlideOffset > "u" && e.updateSlidesOffset();
|
773
|
+
let l = -t;
|
774
|
+
n && (l = t), e.visibleSlidesIndexes = [], e.visibleSlides = [];
|
775
|
+
let o = i.spaceBetween;
|
776
|
+
typeof o == "string" && o.indexOf("%") >= 0 ? o = parseFloat(o.replace("%", "")) / 100 * e.size : typeof o == "string" && (o = parseFloat(o));
|
777
|
+
for (let a = 0; a < s.length; a += 1) {
|
778
|
+
const u = s[a];
|
779
|
+
let d = u.swiperSlideOffset;
|
780
|
+
i.cssMode && i.centeredSlides && (d -= s[0].swiperSlideOffset);
|
781
|
+
const c = (l + (i.centeredSlides ? e.minTranslate() : 0) - d) / (u.swiperSlideSize + o), p = (l - r[0] + (i.centeredSlides ? e.minTranslate() : 0) - d) / (u.swiperSlideSize + o), f = -(l - d), h = f + e.slidesSizesGrid[a], v = f >= 0 && f <= e.size - e.slidesSizesGrid[a], y = f >= 0 && f < e.size - 1 || h > 1 && h <= e.size || f <= 0 && h >= e.size;
|
782
|
+
y && (e.visibleSlides.push(u), e.visibleSlidesIndexes.push(a)), Te(u, y, i.slideVisibleClass), Te(u, v, i.slideFullyVisibleClass), u.progress = n ? -c : c, u.originalProgress = n ? -p : p;
|
783
|
+
}
|
784
|
+
}
|
785
|
+
function ct(t) {
|
786
|
+
const e = this;
|
787
|
+
if (typeof t > "u") {
|
788
|
+
const d = e.rtlTranslate ? -1 : 1;
|
789
|
+
t = e && e.translate && e.translate * d || 0;
|
790
|
+
}
|
791
|
+
const i = e.params, s = e.maxTranslate() - e.minTranslate();
|
792
|
+
let {
|
793
|
+
progress: n,
|
794
|
+
isBeginning: r,
|
795
|
+
isEnd: l,
|
796
|
+
progressLoop: o
|
797
|
+
} = e;
|
798
|
+
const a = r, u = l;
|
799
|
+
if (s === 0)
|
800
|
+
n = 0, r = !0, l = !0;
|
801
|
+
else {
|
802
|
+
n = (t - e.minTranslate()) / s;
|
803
|
+
const d = Math.abs(t - e.minTranslate()) < 1, c = Math.abs(t - e.maxTranslate()) < 1;
|
804
|
+
r = d || n <= 0, l = c || n >= 1, d && (n = 0), c && (n = 1);
|
805
|
+
}
|
806
|
+
if (i.loop) {
|
807
|
+
const d = e.getSlideIndexByData(0), c = e.getSlideIndexByData(e.slides.length - 1), p = e.slidesGrid[d], f = e.slidesGrid[c], h = e.slidesGrid[e.slidesGrid.length - 1], v = Math.abs(t);
|
808
|
+
v >= p ? o = (v - p) / h : o = (v + h - f) / h, o > 1 && (o -= 1);
|
809
|
+
}
|
810
|
+
Object.assign(e, {
|
811
|
+
progress: n,
|
812
|
+
progressLoop: o,
|
813
|
+
isBeginning: r,
|
814
|
+
isEnd: l
|
815
|
+
}), (i.watchSlidesProgress || i.centeredSlides && i.autoHeight) && e.updateSlidesProgress(t), r && !a && e.emit("reachBeginning toEdge"), l && !u && e.emit("reachEnd toEdge"), (a && !r || u && !l) && e.emit("fromEdge"), e.emit("progress", n);
|
816
|
+
}
|
817
|
+
const ae = (t, e, i) => {
|
818
|
+
e && !t.classList.contains(i) ? t.classList.add(i) : !e && t.classList.contains(i) && t.classList.remove(i);
|
819
|
+
};
|
820
|
+
function ut() {
|
821
|
+
const t = this, {
|
822
|
+
slides: e,
|
823
|
+
params: i,
|
824
|
+
slidesEl: s,
|
825
|
+
activeIndex: n
|
826
|
+
} = t, r = t.virtual && i.virtual.enabled, l = t.grid && i.grid && i.grid.rows > 1, o = (c) => H(s, `.${i.slideClass}${c}, swiper-slide${c}`)[0];
|
827
|
+
let a, u, d;
|
828
|
+
if (r)
|
829
|
+
if (i.loop) {
|
830
|
+
let c = n - t.virtual.slidesBefore;
|
831
|
+
c < 0 && (c = t.virtual.slides.length + c), c >= t.virtual.slides.length && (c -= t.virtual.slides.length), a = o(`[data-swiper-slide-index="${c}"]`);
|
832
|
+
} else
|
833
|
+
a = o(`[data-swiper-slide-index="${n}"]`);
|
834
|
+
else
|
835
|
+
l ? (a = e.filter((c) => c.column === n)[0], d = e.filter((c) => c.column === n + 1)[0], u = e.filter((c) => c.column === n - 1)[0]) : a = e[n];
|
836
|
+
a && (l || (d = Ue(a, `.${i.slideClass}, swiper-slide`)[0], i.loop && !d && (d = e[0]), u = Ke(a, `.${i.slideClass}, swiper-slide`)[0], i.loop && !u === 0 && (u = e[e.length - 1]))), e.forEach((c) => {
|
837
|
+
ae(c, c === a, i.slideActiveClass), ae(c, c === d, i.slideNextClass), ae(c, c === u, i.slidePrevClass);
|
838
|
+
}), t.emitSlidesClasses();
|
839
|
+
}
|
840
|
+
const Q = (t, e) => {
|
841
|
+
if (!t || t.destroyed || !t.params) return;
|
842
|
+
const i = () => t.isElement ? "swiper-slide" : `.${t.params.slideClass}`, s = e.closest(i());
|
843
|
+
if (s) {
|
844
|
+
let n = s.querySelector(`.${t.params.lazyPreloaderClass}`);
|
845
|
+
!n && t.isElement && (s.shadowRoot ? n = s.shadowRoot.querySelector(`.${t.params.lazyPreloaderClass}`) : requestAnimationFrame(() => {
|
846
|
+
s.shadowRoot && (n = s.shadowRoot.querySelector(`.${t.params.lazyPreloaderClass}`), n && n.remove());
|
847
|
+
})), n && n.remove();
|
848
|
+
}
|
849
|
+
}, le = (t, e) => {
|
850
|
+
if (!t.slides[e]) return;
|
851
|
+
const i = t.slides[e].querySelector('[loading="lazy"]');
|
852
|
+
i && i.removeAttribute("loading");
|
853
|
+
}, pe = (t) => {
|
854
|
+
if (!t || t.destroyed || !t.params) return;
|
855
|
+
let e = t.params.lazyPreloadPrevNext;
|
856
|
+
const i = t.slides.length;
|
857
|
+
if (!i || !e || e < 0) return;
|
858
|
+
e = Math.min(e, i);
|
859
|
+
const s = t.params.slidesPerView === "auto" ? t.slidesPerViewDynamic() : Math.ceil(t.params.slidesPerView), n = t.activeIndex;
|
860
|
+
if (t.params.grid && t.params.grid.rows > 1) {
|
861
|
+
const l = n, o = [l - e];
|
862
|
+
o.push(...Array.from({
|
863
|
+
length: e
|
864
|
+
}).map((a, u) => l + s + u)), t.slides.forEach((a, u) => {
|
865
|
+
o.includes(a.column) && le(t, u);
|
866
|
+
});
|
867
|
+
return;
|
868
|
+
}
|
869
|
+
const r = n + s - 1;
|
870
|
+
if (t.params.rewind || t.params.loop)
|
871
|
+
for (let l = n - e; l <= r + e; l += 1) {
|
872
|
+
const o = (l % i + i) % i;
|
873
|
+
(o < n || o > r) && le(t, o);
|
874
|
+
}
|
875
|
+
else
|
876
|
+
for (let l = Math.max(n - e, 0); l <= Math.min(r + e, i - 1); l += 1)
|
877
|
+
l !== n && (l > r || l < n) && le(t, l);
|
878
|
+
};
|
879
|
+
function ft(t) {
|
880
|
+
const {
|
881
|
+
slidesGrid: e,
|
882
|
+
params: i
|
883
|
+
} = t, s = t.rtlTranslate ? t.translate : -t.translate;
|
884
|
+
let n;
|
885
|
+
for (let r = 0; r < e.length; r += 1)
|
886
|
+
typeof e[r + 1] < "u" ? s >= e[r] && s < e[r + 1] - (e[r + 1] - e[r]) / 2 ? n = r : s >= e[r] && s < e[r + 1] && (n = r + 1) : s >= e[r] && (n = r);
|
887
|
+
return i.normalizeSlideIndex && (n < 0 || typeof n > "u") && (n = 0), n;
|
888
|
+
}
|
889
|
+
function pt(t) {
|
890
|
+
const e = this, i = e.rtlTranslate ? e.translate : -e.translate, {
|
891
|
+
snapGrid: s,
|
892
|
+
params: n,
|
893
|
+
activeIndex: r,
|
894
|
+
realIndex: l,
|
895
|
+
snapIndex: o
|
896
|
+
} = e;
|
897
|
+
let a = t, u;
|
898
|
+
const d = (f) => {
|
899
|
+
let h = f - e.virtual.slidesBefore;
|
900
|
+
return h < 0 && (h = e.virtual.slides.length + h), h >= e.virtual.slides.length && (h -= e.virtual.slides.length), h;
|
901
|
+
};
|
902
|
+
if (typeof a > "u" && (a = ft(e)), s.indexOf(i) >= 0)
|
903
|
+
u = s.indexOf(i);
|
904
|
+
else {
|
905
|
+
const f = Math.min(n.slidesPerGroupSkip, a);
|
906
|
+
u = f + Math.floor((a - f) / n.slidesPerGroup);
|
907
|
+
}
|
908
|
+
if (u >= s.length && (u = s.length - 1), a === r && !e.params.loop) {
|
909
|
+
u !== o && (e.snapIndex = u, e.emit("snapIndexChange"));
|
910
|
+
return;
|
911
|
+
}
|
912
|
+
if (a === r && e.params.loop && e.virtual && e.params.virtual.enabled) {
|
913
|
+
e.realIndex = d(a);
|
914
|
+
return;
|
915
|
+
}
|
916
|
+
const c = e.grid && n.grid && n.grid.rows > 1;
|
917
|
+
let p;
|
918
|
+
if (e.virtual && n.virtual.enabled && n.loop)
|
919
|
+
p = d(a);
|
920
|
+
else if (c) {
|
921
|
+
const f = e.slides.filter((v) => v.column === a)[0];
|
922
|
+
let h = parseInt(f.getAttribute("data-swiper-slide-index"), 10);
|
923
|
+
Number.isNaN(h) && (h = Math.max(e.slides.indexOf(f), 0)), p = Math.floor(h / n.grid.rows);
|
924
|
+
} else if (e.slides[a]) {
|
925
|
+
const f = e.slides[a].getAttribute("data-swiper-slide-index");
|
926
|
+
f ? p = parseInt(f, 10) : p = a;
|
927
|
+
} else
|
928
|
+
p = a;
|
929
|
+
Object.assign(e, {
|
930
|
+
previousSnapIndex: o,
|
931
|
+
snapIndex: u,
|
932
|
+
previousRealIndex: l,
|
933
|
+
realIndex: p,
|
934
|
+
previousIndex: r,
|
935
|
+
activeIndex: a
|
936
|
+
}), e.initialized && pe(e), e.emit("activeIndexChange"), e.emit("snapIndexChange"), (e.initialized || e.params.runCallbacksOnInit) && (l !== p && e.emit("realIndexChange"), e.emit("slideChange"));
|
937
|
+
}
|
938
|
+
function mt(t, e) {
|
939
|
+
const i = this, s = i.params;
|
940
|
+
let n = t.closest(`.${s.slideClass}, swiper-slide`);
|
941
|
+
!n && i.isElement && e && e.length > 1 && e.includes(t) && [...e.slice(e.indexOf(t) + 1, e.length)].forEach((o) => {
|
942
|
+
!n && o.matches && o.matches(`.${s.slideClass}, swiper-slide`) && (n = o);
|
943
|
+
});
|
944
|
+
let r = !1, l;
|
945
|
+
if (n) {
|
946
|
+
for (let o = 0; o < i.slides.length; o += 1)
|
947
|
+
if (i.slides[o] === n) {
|
948
|
+
r = !0, l = o;
|
949
|
+
break;
|
950
|
+
}
|
951
|
+
}
|
952
|
+
if (n && r)
|
953
|
+
i.clickedSlide = n, i.virtual && i.params.virtual.enabled ? i.clickedIndex = parseInt(n.getAttribute("data-swiper-slide-index"), 10) : i.clickedIndex = l;
|
954
|
+
else {
|
955
|
+
i.clickedSlide = void 0, i.clickedIndex = void 0;
|
956
|
+
return;
|
957
|
+
}
|
958
|
+
s.slideToClickedSlide && i.clickedIndex !== void 0 && i.clickedIndex !== i.activeIndex && i.slideToClickedSlide();
|
959
|
+
}
|
960
|
+
var ht = {
|
961
|
+
updateSize: nt,
|
962
|
+
updateSlides: at,
|
963
|
+
updateAutoHeight: lt,
|
964
|
+
updateSlidesOffset: ot,
|
965
|
+
updateSlidesProgress: dt,
|
966
|
+
updateProgress: ct,
|
967
|
+
updateSlidesClasses: ut,
|
968
|
+
updateActiveIndex: pt,
|
969
|
+
updateClickedSlide: mt
|
970
|
+
};
|
971
|
+
function gt(t) {
|
972
|
+
t === void 0 && (t = this.isHorizontal() ? "x" : "y");
|
973
|
+
const e = this, {
|
974
|
+
params: i,
|
975
|
+
rtlTranslate: s,
|
976
|
+
translate: n,
|
977
|
+
wrapperEl: r
|
978
|
+
} = e;
|
979
|
+
if (i.virtualTranslate)
|
980
|
+
return s ? -n : n;
|
981
|
+
if (i.cssMode)
|
982
|
+
return n;
|
983
|
+
let l = Ye(r, t);
|
984
|
+
return l += e.cssOverflowAdjustment(), s && (l = -l), l || 0;
|
985
|
+
}
|
986
|
+
function vt(t, e) {
|
987
|
+
const i = this, {
|
988
|
+
rtlTranslate: s,
|
989
|
+
params: n,
|
990
|
+
wrapperEl: r,
|
991
|
+
progress: l
|
992
|
+
} = i;
|
993
|
+
let o = 0, a = 0;
|
994
|
+
const u = 0;
|
995
|
+
i.isHorizontal() ? o = s ? -t : t : a = t, n.roundLengths && (o = Math.floor(o), a = Math.floor(a)), i.previousTranslate = i.translate, i.translate = i.isHorizontal() ? o : a, n.cssMode ? r[i.isHorizontal() ? "scrollLeft" : "scrollTop"] = i.isHorizontal() ? -o : -a : n.virtualTranslate || (i.isHorizontal() ? o -= i.cssOverflowAdjustment() : a -= i.cssOverflowAdjustment(), r.style.transform = `translate3d(${o}px, ${a}px, ${u}px)`);
|
996
|
+
let d;
|
997
|
+
const c = i.maxTranslate() - i.minTranslate();
|
998
|
+
c === 0 ? d = 0 : d = (t - i.minTranslate()) / c, d !== l && i.updateProgress(t), i.emit("setTranslate", i.translate, e);
|
999
|
+
}
|
1000
|
+
function wt() {
|
1001
|
+
return -this.snapGrid[0];
|
1002
|
+
}
|
1003
|
+
function St() {
|
1004
|
+
return -this.snapGrid[this.snapGrid.length - 1];
|
1005
|
+
}
|
1006
|
+
function Tt(t, e, i, s, n) {
|
1007
|
+
t === void 0 && (t = 0), e === void 0 && (e = this.params.speed), i === void 0 && (i = !0), s === void 0 && (s = !0);
|
1008
|
+
const r = this, {
|
1009
|
+
params: l,
|
1010
|
+
wrapperEl: o
|
1011
|
+
} = r;
|
1012
|
+
if (r.animating && l.preventInteractionOnTransition)
|
1013
|
+
return !1;
|
1014
|
+
const a = r.minTranslate(), u = r.maxTranslate();
|
1015
|
+
let d;
|
1016
|
+
if (s && t > a ? d = a : s && t < u ? d = u : d = t, r.updateProgress(d), l.cssMode) {
|
1017
|
+
const c = r.isHorizontal();
|
1018
|
+
if (e === 0)
|
1019
|
+
o[c ? "scrollLeft" : "scrollTop"] = -d;
|
1020
|
+
else {
|
1021
|
+
if (!r.support.smoothScroll)
|
1022
|
+
return Ie({
|
1023
|
+
swiper: r,
|
1024
|
+
targetPosition: -d,
|
1025
|
+
side: c ? "left" : "top"
|
1026
|
+
}), !0;
|
1027
|
+
o.scrollTo({
|
1028
|
+
[c ? "left" : "top"]: -d,
|
1029
|
+
behavior: "smooth"
|
1030
|
+
});
|
1031
|
+
}
|
1032
|
+
return !0;
|
1033
|
+
}
|
1034
|
+
return e === 0 ? (r.setTransition(0), r.setTranslate(d), i && (r.emit("beforeTransitionStart", e, n), r.emit("transitionEnd"))) : (r.setTransition(e), r.setTranslate(d), i && (r.emit("beforeTransitionStart", e, n), r.emit("transitionStart")), r.animating || (r.animating = !0, r.onTranslateToWrapperTransitionEnd || (r.onTranslateToWrapperTransitionEnd = function(p) {
|
1035
|
+
!r || r.destroyed || p.target === this && (r.wrapperEl.removeEventListener("transitionend", r.onTranslateToWrapperTransitionEnd), r.onTranslateToWrapperTransitionEnd = null, delete r.onTranslateToWrapperTransitionEnd, r.animating = !1, i && r.emit("transitionEnd"));
|
1036
|
+
}), r.wrapperEl.addEventListener("transitionend", r.onTranslateToWrapperTransitionEnd))), !0;
|
1037
|
+
}
|
1038
|
+
var yt = {
|
1039
|
+
getTranslate: gt,
|
1040
|
+
setTranslate: vt,
|
1041
|
+
minTranslate: wt,
|
1042
|
+
maxTranslate: St,
|
1043
|
+
translateTo: Tt
|
1044
|
+
};
|
1045
|
+
function bt(t, e) {
|
1046
|
+
const i = this;
|
1047
|
+
i.params.cssMode || (i.wrapperEl.style.transitionDuration = `${t}ms`, i.wrapperEl.style.transitionDelay = t === 0 ? "0ms" : ""), i.emit("setTransition", t, e);
|
1048
|
+
}
|
1049
|
+
function ze(t) {
|
1050
|
+
let {
|
1051
|
+
swiper: e,
|
1052
|
+
runCallbacks: i,
|
1053
|
+
direction: s,
|
1054
|
+
step: n
|
1055
|
+
} = t;
|
1056
|
+
const {
|
1057
|
+
activeIndex: r,
|
1058
|
+
previousIndex: l
|
1059
|
+
} = e;
|
1060
|
+
let o = s;
|
1061
|
+
if (o || (r > l ? o = "next" : r < l ? o = "prev" : o = "reset"), e.emit(`transition${n}`), i && r !== l) {
|
1062
|
+
if (o === "reset") {
|
1063
|
+
e.emit(`slideResetTransition${n}`);
|
1064
|
+
return;
|
1065
|
+
}
|
1066
|
+
e.emit(`slideChangeTransition${n}`), o === "next" ? e.emit(`slideNextTransition${n}`) : e.emit(`slidePrevTransition${n}`);
|
1067
|
+
}
|
1068
|
+
}
|
1069
|
+
function xt(t, e) {
|
1070
|
+
t === void 0 && (t = !0);
|
1071
|
+
const i = this, {
|
1072
|
+
params: s
|
1073
|
+
} = i;
|
1074
|
+
s.cssMode || (s.autoHeight && i.updateAutoHeight(), ze({
|
1075
|
+
swiper: i,
|
1076
|
+
runCallbacks: t,
|
1077
|
+
direction: e,
|
1078
|
+
step: "Start"
|
1079
|
+
}));
|
1080
|
+
}
|
1081
|
+
function Et(t, e) {
|
1082
|
+
t === void 0 && (t = !0);
|
1083
|
+
const i = this, {
|
1084
|
+
params: s
|
1085
|
+
} = i;
|
1086
|
+
i.animating = !1, !s.cssMode && (i.setTransition(0), ze({
|
1087
|
+
swiper: i,
|
1088
|
+
runCallbacks: t,
|
1089
|
+
direction: e,
|
1090
|
+
step: "End"
|
1091
|
+
}));
|
1092
|
+
}
|
1093
|
+
var Pt = {
|
1094
|
+
setTransition: bt,
|
1095
|
+
transitionStart: xt,
|
1096
|
+
transitionEnd: Et
|
1097
|
+
};
|
1098
|
+
function Mt(t, e, i, s, n) {
|
1099
|
+
t === void 0 && (t = 0), i === void 0 && (i = !0), typeof t == "string" && (t = parseInt(t, 10));
|
1100
|
+
const r = this;
|
1101
|
+
let l = t;
|
1102
|
+
l < 0 && (l = 0);
|
1103
|
+
const {
|
1104
|
+
params: o,
|
1105
|
+
snapGrid: a,
|
1106
|
+
slidesGrid: u,
|
1107
|
+
previousIndex: d,
|
1108
|
+
activeIndex: c,
|
1109
|
+
rtlTranslate: p,
|
1110
|
+
wrapperEl: f,
|
1111
|
+
enabled: h
|
1112
|
+
} = r;
|
1113
|
+
if (!h && !s && !n || r.destroyed || r.animating && o.preventInteractionOnTransition)
|
1114
|
+
return !1;
|
1115
|
+
typeof e > "u" && (e = r.params.speed);
|
1116
|
+
const v = Math.min(r.params.slidesPerGroupSkip, l);
|
1117
|
+
let y = v + Math.floor((l - v) / r.params.slidesPerGroup);
|
1118
|
+
y >= a.length && (y = a.length - 1);
|
1119
|
+
const m = -a[y];
|
1120
|
+
if (o.normalizeSlideIndex)
|
1121
|
+
for (let g = 0; g < u.length; g += 1) {
|
1122
|
+
const S = -Math.floor(m * 100), T = Math.floor(u[g] * 100), I = Math.floor(u[g + 1] * 100);
|
1123
|
+
typeof u[g + 1] < "u" ? S >= T && S < I - (I - T) / 2 ? l = g : S >= T && S < I && (l = g + 1) : S >= T && (l = g);
|
1124
|
+
}
|
1125
|
+
if (r.initialized && l !== c && (!r.allowSlideNext && (p ? m > r.translate && m > r.minTranslate() : m < r.translate && m < r.minTranslate()) || !r.allowSlidePrev && m > r.translate && m > r.maxTranslate() && (c || 0) !== l))
|
1126
|
+
return !1;
|
1127
|
+
l !== (d || 0) && i && r.emit("beforeSlideChangeStart"), r.updateProgress(m);
|
1128
|
+
let b;
|
1129
|
+
if (l > c ? b = "next" : l < c ? b = "prev" : b = "reset", p && -m === r.translate || !p && m === r.translate)
|
1130
|
+
return r.updateActiveIndex(l), o.autoHeight && r.updateAutoHeight(), r.updateSlidesClasses(), o.effect !== "slide" && r.setTranslate(m), b !== "reset" && (r.transitionStart(i, b), r.transitionEnd(i, b)), !1;
|
1131
|
+
if (o.cssMode) {
|
1132
|
+
const g = r.isHorizontal(), S = p ? m : -m;
|
1133
|
+
if (e === 0) {
|
1134
|
+
const T = r.virtual && r.params.virtual.enabled;
|
1135
|
+
T && (r.wrapperEl.style.scrollSnapType = "none", r._immediateVirtual = !0), T && !r._cssModeVirtualInitialSet && r.params.initialSlide > 0 ? (r._cssModeVirtualInitialSet = !0, requestAnimationFrame(() => {
|
1136
|
+
f[g ? "scrollLeft" : "scrollTop"] = S;
|
1137
|
+
})) : f[g ? "scrollLeft" : "scrollTop"] = S, T && requestAnimationFrame(() => {
|
1138
|
+
r.wrapperEl.style.scrollSnapType = "", r._immediateVirtual = !1;
|
1139
|
+
});
|
1140
|
+
} else {
|
1141
|
+
if (!r.support.smoothScroll)
|
1142
|
+
return Ie({
|
1143
|
+
swiper: r,
|
1144
|
+
targetPosition: S,
|
1145
|
+
side: g ? "left" : "top"
|
1146
|
+
}), !0;
|
1147
|
+
f.scrollTo({
|
1148
|
+
[g ? "left" : "top"]: S,
|
1149
|
+
behavior: "smooth"
|
1150
|
+
});
|
1151
|
+
}
|
1152
|
+
return !0;
|
1153
|
+
}
|
1154
|
+
return r.setTransition(e), r.setTranslate(m), r.updateActiveIndex(l), r.updateSlidesClasses(), r.emit("beforeTransitionStart", e, s), r.transitionStart(i, b), e === 0 ? r.transitionEnd(i, b) : r.animating || (r.animating = !0, r.onSlideToWrapperTransitionEnd || (r.onSlideToWrapperTransitionEnd = function(S) {
|
1155
|
+
!r || r.destroyed || S.target === this && (r.wrapperEl.removeEventListener("transitionend", r.onSlideToWrapperTransitionEnd), r.onSlideToWrapperTransitionEnd = null, delete r.onSlideToWrapperTransitionEnd, r.transitionEnd(i, b));
|
1156
|
+
}), r.wrapperEl.addEventListener("transitionend", r.onSlideToWrapperTransitionEnd)), !0;
|
1157
|
+
}
|
1158
|
+
function Ct(t, e, i, s) {
|
1159
|
+
t === void 0 && (t = 0), i === void 0 && (i = !0), typeof t == "string" && (t = parseInt(t, 10));
|
1160
|
+
const n = this;
|
1161
|
+
if (n.destroyed) return;
|
1162
|
+
typeof e > "u" && (e = n.params.speed);
|
1163
|
+
const r = n.grid && n.params.grid && n.params.grid.rows > 1;
|
1164
|
+
let l = t;
|
1165
|
+
if (n.params.loop)
|
1166
|
+
if (n.virtual && n.params.virtual.enabled)
|
1167
|
+
l = l + n.virtual.slidesBefore;
|
1168
|
+
else {
|
1169
|
+
let o;
|
1170
|
+
if (r) {
|
1171
|
+
const p = l * n.params.grid.rows;
|
1172
|
+
o = n.slides.filter((f) => f.getAttribute("data-swiper-slide-index") * 1 === p)[0].column;
|
1173
|
+
} else
|
1174
|
+
o = n.getSlideIndexByData(l);
|
1175
|
+
const a = r ? Math.ceil(n.slides.length / n.params.grid.rows) : n.slides.length, {
|
1176
|
+
centeredSlides: u
|
1177
|
+
} = n.params;
|
1178
|
+
let d = n.params.slidesPerView;
|
1179
|
+
d === "auto" ? d = n.slidesPerViewDynamic() : (d = Math.ceil(parseFloat(n.params.slidesPerView, 10)), u && d % 2 === 0 && (d = d + 1));
|
1180
|
+
let c = a - o < d;
|
1181
|
+
if (u && (c = c || o < Math.ceil(d / 2)), s && u && n.params.slidesPerView !== "auto" && !r && (c = !1), c) {
|
1182
|
+
const p = u ? o < n.activeIndex ? "prev" : "next" : o - n.activeIndex - 1 < n.params.slidesPerView ? "next" : "prev";
|
1183
|
+
n.loopFix({
|
1184
|
+
direction: p,
|
1185
|
+
slideTo: !0,
|
1186
|
+
activeSlideIndex: p === "next" ? o + 1 : o - a + 1,
|
1187
|
+
slideRealIndex: p === "next" ? n.realIndex : void 0
|
1188
|
+
});
|
1189
|
+
}
|
1190
|
+
if (r) {
|
1191
|
+
const p = l * n.params.grid.rows;
|
1192
|
+
l = n.slides.filter((f) => f.getAttribute("data-swiper-slide-index") * 1 === p)[0].column;
|
1193
|
+
} else
|
1194
|
+
l = n.getSlideIndexByData(l);
|
1195
|
+
}
|
1196
|
+
return requestAnimationFrame(() => {
|
1197
|
+
n.slideTo(l, e, i, s);
|
1198
|
+
}), n;
|
1199
|
+
}
|
1200
|
+
function It(t, e, i) {
|
1201
|
+
e === void 0 && (e = !0);
|
1202
|
+
const s = this, {
|
1203
|
+
enabled: n,
|
1204
|
+
params: r,
|
1205
|
+
animating: l
|
1206
|
+
} = s;
|
1207
|
+
if (!n || s.destroyed) return s;
|
1208
|
+
typeof t > "u" && (t = s.params.speed);
|
1209
|
+
let o = r.slidesPerGroup;
|
1210
|
+
r.slidesPerView === "auto" && r.slidesPerGroup === 1 && r.slidesPerGroupAuto && (o = Math.max(s.slidesPerViewDynamic("current", !0), 1));
|
1211
|
+
const a = s.activeIndex < r.slidesPerGroupSkip ? 1 : o, u = s.virtual && r.virtual.enabled;
|
1212
|
+
if (r.loop) {
|
1213
|
+
if (l && !u && r.loopPreventsSliding) return !1;
|
1214
|
+
if (s.loopFix({
|
1215
|
+
direction: "next"
|
1216
|
+
}), s._clientLeft = s.wrapperEl.clientLeft, s.activeIndex === s.slides.length - 1 && r.cssMode)
|
1217
|
+
return requestAnimationFrame(() => {
|
1218
|
+
s.slideTo(s.activeIndex + a, t, e, i);
|
1219
|
+
}), !0;
|
1220
|
+
}
|
1221
|
+
return r.rewind && s.isEnd ? s.slideTo(0, t, e, i) : s.slideTo(s.activeIndex + a, t, e, i);
|
1222
|
+
}
|
1223
|
+
function Lt(t, e, i) {
|
1224
|
+
e === void 0 && (e = !0);
|
1225
|
+
const s = this, {
|
1226
|
+
params: n,
|
1227
|
+
snapGrid: r,
|
1228
|
+
slidesGrid: l,
|
1229
|
+
rtlTranslate: o,
|
1230
|
+
enabled: a,
|
1231
|
+
animating: u
|
1232
|
+
} = s;
|
1233
|
+
if (!a || s.destroyed) return s;
|
1234
|
+
typeof t > "u" && (t = s.params.speed);
|
1235
|
+
const d = s.virtual && n.virtual.enabled;
|
1236
|
+
if (n.loop) {
|
1237
|
+
if (u && !d && n.loopPreventsSliding) return !1;
|
1238
|
+
s.loopFix({
|
1239
|
+
direction: "prev"
|
1240
|
+
}), s._clientLeft = s.wrapperEl.clientLeft;
|
1241
|
+
}
|
1242
|
+
const c = o ? s.translate : -s.translate;
|
1243
|
+
function p(m) {
|
1244
|
+
return m < 0 ? -Math.floor(Math.abs(m)) : Math.floor(m);
|
1245
|
+
}
|
1246
|
+
const f = p(c), h = r.map((m) => p(m));
|
1247
|
+
let v = r[h.indexOf(f) - 1];
|
1248
|
+
if (typeof v > "u" && n.cssMode) {
|
1249
|
+
let m;
|
1250
|
+
r.forEach((b, g) => {
|
1251
|
+
f >= b && (m = g);
|
1252
|
+
}), typeof m < "u" && (v = r[m > 0 ? m - 1 : m]);
|
1253
|
+
}
|
1254
|
+
let y = 0;
|
1255
|
+
if (typeof v < "u" && (y = l.indexOf(v), y < 0 && (y = s.activeIndex - 1), n.slidesPerView === "auto" && n.slidesPerGroup === 1 && n.slidesPerGroupAuto && (y = y - s.slidesPerViewDynamic("previous", !0) + 1, y = Math.max(y, 0))), n.rewind && s.isBeginning) {
|
1256
|
+
const m = s.params.virtual && s.params.virtual.enabled && s.virtual ? s.virtual.slides.length - 1 : s.slides.length - 1;
|
1257
|
+
return s.slideTo(m, t, e, i);
|
1258
|
+
} else if (n.loop && s.activeIndex === 0 && n.cssMode)
|
1259
|
+
return requestAnimationFrame(() => {
|
1260
|
+
s.slideTo(y, t, e, i);
|
1261
|
+
}), !0;
|
1262
|
+
return s.slideTo(y, t, e, i);
|
1263
|
+
}
|
1264
|
+
function Ot(t, e, i) {
|
1265
|
+
e === void 0 && (e = !0);
|
1266
|
+
const s = this;
|
1267
|
+
if (!s.destroyed)
|
1268
|
+
return typeof t > "u" && (t = s.params.speed), s.slideTo(s.activeIndex, t, e, i);
|
1269
|
+
}
|
1270
|
+
function zt(t, e, i, s) {
|
1271
|
+
e === void 0 && (e = !0), s === void 0 && (s = 0.5);
|
1272
|
+
const n = this;
|
1273
|
+
if (n.destroyed) return;
|
1274
|
+
typeof t > "u" && (t = n.params.speed);
|
1275
|
+
let r = n.activeIndex;
|
1276
|
+
const l = Math.min(n.params.slidesPerGroupSkip, r), o = l + Math.floor((r - l) / n.params.slidesPerGroup), a = n.rtlTranslate ? n.translate : -n.translate;
|
1277
|
+
if (a >= n.snapGrid[o]) {
|
1278
|
+
const u = n.snapGrid[o], d = n.snapGrid[o + 1];
|
1279
|
+
a - u > (d - u) * s && (r += n.params.slidesPerGroup);
|
1280
|
+
} else {
|
1281
|
+
const u = n.snapGrid[o - 1], d = n.snapGrid[o];
|
1282
|
+
a - u <= (d - u) * s && (r -= n.params.slidesPerGroup);
|
1283
|
+
}
|
1284
|
+
return r = Math.max(r, 0), r = Math.min(r, n.slidesGrid.length - 1), n.slideTo(r, t, e, i);
|
1285
|
+
}
|
1286
|
+
function At() {
|
1287
|
+
const t = this;
|
1288
|
+
if (t.destroyed) return;
|
1289
|
+
const {
|
1290
|
+
params: e,
|
1291
|
+
slidesEl: i
|
1292
|
+
} = t, s = e.slidesPerView === "auto" ? t.slidesPerViewDynamic() : e.slidesPerView;
|
1293
|
+
let n = t.clickedIndex, r;
|
1294
|
+
const l = t.isElement ? "swiper-slide" : `.${e.slideClass}`;
|
1295
|
+
if (e.loop) {
|
1296
|
+
if (t.animating) return;
|
1297
|
+
r = parseInt(t.clickedSlide.getAttribute("data-swiper-slide-index"), 10), e.centeredSlides ? n < t.loopedSlides - s / 2 || n > t.slides.length - t.loopedSlides + s / 2 ? (t.loopFix(), n = t.getSlideIndex(H(i, `${l}[data-swiper-slide-index="${r}"]`)[0]), ue(() => {
|
1298
|
+
t.slideTo(n);
|
1299
|
+
})) : t.slideTo(n) : n > t.slides.length - s ? (t.loopFix(), n = t.getSlideIndex(H(i, `${l}[data-swiper-slide-index="${r}"]`)[0]), ue(() => {
|
1300
|
+
t.slideTo(n);
|
1301
|
+
})) : t.slideTo(n);
|
1302
|
+
} else
|
1303
|
+
t.slideTo(n);
|
1304
|
+
}
|
1305
|
+
var _t = {
|
1306
|
+
slideTo: Mt,
|
1307
|
+
slideToLoop: Ct,
|
1308
|
+
slideNext: It,
|
1309
|
+
slidePrev: Lt,
|
1310
|
+
slideReset: Ot,
|
1311
|
+
slideToClosest: zt,
|
1312
|
+
slideToClickedSlide: At
|
1313
|
+
};
|
1314
|
+
function Dt(t) {
|
1315
|
+
const e = this, {
|
1316
|
+
params: i,
|
1317
|
+
slidesEl: s
|
1318
|
+
} = e;
|
1319
|
+
if (!i.loop || e.virtual && e.params.virtual.enabled) return;
|
1320
|
+
const n = () => {
|
1321
|
+
H(s, `.${i.slideClass}, swiper-slide`).forEach((c, p) => {
|
1322
|
+
c.setAttribute("data-swiper-slide-index", p);
|
1323
|
+
});
|
1324
|
+
}, r = e.grid && i.grid && i.grid.rows > 1, l = i.slidesPerGroup * (r ? i.grid.rows : 1), o = e.slides.length % l !== 0, a = r && e.slides.length % i.grid.rows !== 0, u = (d) => {
|
1325
|
+
for (let c = 0; c < d; c += 1) {
|
1326
|
+
const p = e.isElement ? fe("swiper-slide", [i.slideBlankClass]) : fe("div", [i.slideClass, i.slideBlankClass]);
|
1327
|
+
e.slidesEl.append(p);
|
1328
|
+
}
|
1329
|
+
};
|
1330
|
+
if (o) {
|
1331
|
+
if (i.loopAddBlankSlides) {
|
1332
|
+
const d = l - e.slides.length % l;
|
1333
|
+
u(d), e.recalcSlides(), e.updateSlides();
|
1334
|
+
} else
|
1335
|
+
te("Swiper Loop Warning: The number of slides is not even to slidesPerGroup, loop mode may not function properly. You need to add more slides (or make duplicates, or empty slides)");
|
1336
|
+
n();
|
1337
|
+
} else if (a) {
|
1338
|
+
if (i.loopAddBlankSlides) {
|
1339
|
+
const d = i.grid.rows - e.slides.length % i.grid.rows;
|
1340
|
+
u(d), e.recalcSlides(), e.updateSlides();
|
1341
|
+
} else
|
1342
|
+
te("Swiper Loop Warning: The number of slides is not even to grid.rows, loop mode may not function properly. You need to add more slides (or make duplicates, or empty slides)");
|
1343
|
+
n();
|
1344
|
+
} else
|
1345
|
+
n();
|
1346
|
+
e.loopFix({
|
1347
|
+
slideRealIndex: t,
|
1348
|
+
direction: i.centeredSlides ? void 0 : "next"
|
1349
|
+
});
|
1350
|
+
}
|
1351
|
+
function Gt(t) {
|
1352
|
+
let {
|
1353
|
+
slideRealIndex: e,
|
1354
|
+
slideTo: i = !0,
|
1355
|
+
direction: s,
|
1356
|
+
setTranslate: n,
|
1357
|
+
activeSlideIndex: r,
|
1358
|
+
byController: l,
|
1359
|
+
byMousewheel: o
|
1360
|
+
} = t === void 0 ? {} : t;
|
1361
|
+
const a = this;
|
1362
|
+
if (!a.params.loop) return;
|
1363
|
+
a.emit("beforeLoopFix");
|
1364
|
+
const {
|
1365
|
+
slides: u,
|
1366
|
+
allowSlidePrev: d,
|
1367
|
+
allowSlideNext: c,
|
1368
|
+
slidesEl: p,
|
1369
|
+
params: f
|
1370
|
+
} = a, {
|
1371
|
+
centeredSlides: h
|
1372
|
+
} = f;
|
1373
|
+
if (a.allowSlidePrev = !0, a.allowSlideNext = !0, a.virtual && f.virtual.enabled) {
|
1374
|
+
i && (!f.centeredSlides && a.snapIndex === 0 ? a.slideTo(a.virtual.slides.length, 0, !1, !0) : f.centeredSlides && a.snapIndex < f.slidesPerView ? a.slideTo(a.virtual.slides.length + a.snapIndex, 0, !1, !0) : a.snapIndex === a.snapGrid.length - 1 && a.slideTo(a.virtual.slidesBefore, 0, !1, !0)), a.allowSlidePrev = d, a.allowSlideNext = c, a.emit("loopFix");
|
1375
|
+
return;
|
1376
|
+
}
|
1377
|
+
let v = f.slidesPerView;
|
1378
|
+
v === "auto" ? v = a.slidesPerViewDynamic() : (v = Math.ceil(parseFloat(f.slidesPerView, 10)), h && v % 2 === 0 && (v = v + 1));
|
1379
|
+
const y = f.slidesPerGroupAuto ? v : f.slidesPerGroup;
|
1380
|
+
let m = y;
|
1381
|
+
m % y !== 0 && (m += y - m % y), m += f.loopAdditionalSlides, a.loopedSlides = m;
|
1382
|
+
const b = a.grid && f.grid && f.grid.rows > 1;
|
1383
|
+
u.length < v + m ? te("Swiper Loop Warning: The number of slides is not enough for loop mode, it will be disabled and not function properly. You need to add more slides (or make duplicates) or lower the values of slidesPerView and slidesPerGroup parameters") : b && f.grid.fill === "row" && te("Swiper Loop Warning: Loop mode is not compatible with grid.fill = `row`");
|
1384
|
+
const g = [], S = [];
|
1385
|
+
let T = a.activeIndex;
|
1386
|
+
typeof r > "u" ? r = a.getSlideIndex(u.filter((P) => P.classList.contains(f.slideActiveClass))[0]) : T = r;
|
1387
|
+
const I = s === "next" || !s, _ = s === "prev" || !s;
|
1388
|
+
let C = 0, x = 0;
|
1389
|
+
const w = b ? Math.ceil(u.length / f.grid.rows) : u.length, M = (b ? u[r].column : r) + (h && typeof n > "u" ? -v / 2 + 0.5 : 0);
|
1390
|
+
if (M < m) {
|
1391
|
+
C = Math.max(m - M, y);
|
1392
|
+
for (let P = 0; P < m - M; P += 1) {
|
1393
|
+
const O = P - Math.floor(P / w) * w;
|
1394
|
+
if (b) {
|
1395
|
+
const D = w - O - 1;
|
1396
|
+
for (let B = u.length - 1; B >= 0; B -= 1)
|
1397
|
+
u[B].column === D && g.push(B);
|
1398
|
+
} else
|
1399
|
+
g.push(w - O - 1);
|
1400
|
+
}
|
1401
|
+
} else if (M + v > w - m) {
|
1402
|
+
x = Math.max(M - (w - m * 2), y);
|
1403
|
+
for (let P = 0; P < x; P += 1) {
|
1404
|
+
const O = P - Math.floor(P / w) * w;
|
1405
|
+
b ? u.forEach((D, B) => {
|
1406
|
+
D.column === O && S.push(B);
|
1407
|
+
}) : S.push(O);
|
1408
|
+
}
|
1409
|
+
}
|
1410
|
+
if (a.__preventObserver__ = !0, requestAnimationFrame(() => {
|
1411
|
+
a.__preventObserver__ = !1;
|
1412
|
+
}), _ && g.forEach((P) => {
|
1413
|
+
u[P].swiperLoopMoveDOM = !0, p.prepend(u[P]), u[P].swiperLoopMoveDOM = !1;
|
1414
|
+
}), I && S.forEach((P) => {
|
1415
|
+
u[P].swiperLoopMoveDOM = !0, p.append(u[P]), u[P].swiperLoopMoveDOM = !1;
|
1416
|
+
}), a.recalcSlides(), f.slidesPerView === "auto" ? a.updateSlides() : b && (g.length > 0 && _ || S.length > 0 && I) && a.slides.forEach((P, O) => {
|
1417
|
+
a.grid.updateSlide(O, P, a.slides);
|
1418
|
+
}), f.watchSlidesProgress && a.updateSlidesOffset(), i) {
|
1419
|
+
if (g.length > 0 && _) {
|
1420
|
+
if (typeof e > "u") {
|
1421
|
+
const P = a.slidesGrid[T], D = a.slidesGrid[T + C] - P;
|
1422
|
+
o ? a.setTranslate(a.translate - D) : (a.slideTo(T + Math.ceil(C), 0, !1, !0), n && (a.touchEventsData.startTranslate = a.touchEventsData.startTranslate - D, a.touchEventsData.currentTranslate = a.touchEventsData.currentTranslate - D));
|
1423
|
+
} else if (n) {
|
1424
|
+
const P = b ? g.length / f.grid.rows : g.length;
|
1425
|
+
a.slideTo(a.activeIndex + P, 0, !1, !0), a.touchEventsData.currentTranslate = a.translate;
|
1426
|
+
}
|
1427
|
+
} else if (S.length > 0 && I)
|
1428
|
+
if (typeof e > "u") {
|
1429
|
+
const P = a.slidesGrid[T], D = a.slidesGrid[T - x] - P;
|
1430
|
+
o ? a.setTranslate(a.translate - D) : (a.slideTo(T - x, 0, !1, !0), n && (a.touchEventsData.startTranslate = a.touchEventsData.startTranslate - D, a.touchEventsData.currentTranslate = a.touchEventsData.currentTranslate - D));
|
1431
|
+
} else {
|
1432
|
+
const P = b ? S.length / f.grid.rows : S.length;
|
1433
|
+
a.slideTo(a.activeIndex - P, 0, !1, !0);
|
1434
|
+
}
|
1435
|
+
}
|
1436
|
+
if (a.allowSlidePrev = d, a.allowSlideNext = c, a.controller && a.controller.control && !l) {
|
1437
|
+
const P = {
|
1438
|
+
slideRealIndex: e,
|
1439
|
+
direction: s,
|
1440
|
+
setTranslate: n,
|
1441
|
+
activeSlideIndex: r,
|
1442
|
+
byController: !0
|
1443
|
+
};
|
1444
|
+
Array.isArray(a.controller.control) ? a.controller.control.forEach((O) => {
|
1445
|
+
!O.destroyed && O.params.loop && O.loopFix({
|
1446
|
+
...P,
|
1447
|
+
slideTo: O.params.slidesPerView === f.slidesPerView ? i : !1
|
1448
|
+
});
|
1449
|
+
}) : a.controller.control instanceof a.constructor && a.controller.control.params.loop && a.controller.control.loopFix({
|
1450
|
+
...P,
|
1451
|
+
slideTo: a.controller.control.params.slidesPerView === f.slidesPerView ? i : !1
|
1452
|
+
});
|
1453
|
+
}
|
1454
|
+
a.emit("loopFix");
|
1455
|
+
}
|
1456
|
+
function Vt() {
|
1457
|
+
const t = this, {
|
1458
|
+
params: e,
|
1459
|
+
slidesEl: i
|
1460
|
+
} = t;
|
1461
|
+
if (!e.loop || t.virtual && t.params.virtual.enabled) return;
|
1462
|
+
t.recalcSlides();
|
1463
|
+
const s = [];
|
1464
|
+
t.slides.forEach((n) => {
|
1465
|
+
const r = typeof n.swiperSlideIndex > "u" ? n.getAttribute("data-swiper-slide-index") * 1 : n.swiperSlideIndex;
|
1466
|
+
s[r] = n;
|
1467
|
+
}), t.slides.forEach((n) => {
|
1468
|
+
n.removeAttribute("data-swiper-slide-index");
|
1469
|
+
}), s.forEach((n) => {
|
1470
|
+
i.append(n);
|
1471
|
+
}), t.recalcSlides(), t.slideTo(t.realIndex, 0);
|
1472
|
+
}
|
1473
|
+
var Nt = {
|
1474
|
+
loopCreate: Dt,
|
1475
|
+
loopFix: Gt,
|
1476
|
+
loopDestroy: Vt
|
1477
|
+
};
|
1478
|
+
function Bt(t) {
|
1479
|
+
const e = this;
|
1480
|
+
if (!e.params.simulateTouch || e.params.watchOverflow && e.isLocked || e.params.cssMode) return;
|
1481
|
+
const i = e.params.touchEventsTarget === "container" ? e.el : e.wrapperEl;
|
1482
|
+
e.isElement && (e.__preventObserver__ = !0), i.style.cursor = "move", i.style.cursor = t ? "grabbing" : "grab", e.isElement && requestAnimationFrame(() => {
|
1483
|
+
e.__preventObserver__ = !1;
|
1484
|
+
});
|
1485
|
+
}
|
1486
|
+
function Ft() {
|
1487
|
+
const t = this;
|
1488
|
+
t.params.watchOverflow && t.isLocked || t.params.cssMode || (t.isElement && (t.__preventObserver__ = !0), t[t.params.touchEventsTarget === "container" ? "el" : "wrapperEl"].style.cursor = "", t.isElement && requestAnimationFrame(() => {
|
1489
|
+
t.__preventObserver__ = !1;
|
1490
|
+
}));
|
1491
|
+
}
|
1492
|
+
var Rt = {
|
1493
|
+
setGrabCursor: Bt,
|
1494
|
+
unsetGrabCursor: Ft
|
1495
|
+
};
|
1496
|
+
function $t(t, e) {
|
1497
|
+
e === void 0 && (e = this);
|
1498
|
+
function i(s) {
|
1499
|
+
if (!s || s === R() || s === V()) return null;
|
1500
|
+
s.assignedSlot && (s = s.assignedSlot);
|
1501
|
+
const n = s.closest(t);
|
1502
|
+
return !n && !s.getRootNode ? null : n || i(s.getRootNode().host);
|
1503
|
+
}
|
1504
|
+
return i(e);
|
1505
|
+
}
|
1506
|
+
function ye(t, e, i) {
|
1507
|
+
const s = V(), {
|
1508
|
+
params: n
|
1509
|
+
} = t, r = n.edgeSwipeDetection, l = n.edgeSwipeThreshold;
|
1510
|
+
return r && (i <= l || i >= s.innerWidth - l) ? r === "prevent" ? (e.preventDefault(), !0) : !1 : !0;
|
1511
|
+
}
|
1512
|
+
function Ht(t) {
|
1513
|
+
const e = this, i = R();
|
1514
|
+
let s = t;
|
1515
|
+
s.originalEvent && (s = s.originalEvent);
|
1516
|
+
const n = e.touchEventsData;
|
1517
|
+
if (s.type === "pointerdown") {
|
1518
|
+
if (n.pointerId !== null && n.pointerId !== s.pointerId)
|
1519
|
+
return;
|
1520
|
+
n.pointerId = s.pointerId;
|
1521
|
+
} else s.type === "touchstart" && s.targetTouches.length === 1 && (n.touchId = s.targetTouches[0].identifier);
|
1522
|
+
if (s.type === "touchstart") {
|
1523
|
+
ye(e, s, s.targetTouches[0].pageX);
|
1524
|
+
return;
|
1525
|
+
}
|
1526
|
+
const {
|
1527
|
+
params: r,
|
1528
|
+
touches: l,
|
1529
|
+
enabled: o
|
1530
|
+
} = e;
|
1531
|
+
if (!o || !r.simulateTouch && s.pointerType === "mouse" || e.animating && r.preventInteractionOnTransition)
|
1532
|
+
return;
|
1533
|
+
!e.animating && r.cssMode && r.loop && e.loopFix();
|
1534
|
+
let a = s.target;
|
1535
|
+
if (r.touchEventsTarget === "wrapper" && !e.wrapperEl.contains(a) || "which" in s && s.which === 3 || "button" in s && s.button > 0 || n.isTouched && n.isMoved) return;
|
1536
|
+
const u = !!r.noSwipingClass && r.noSwipingClass !== "", d = s.composedPath ? s.composedPath() : s.path;
|
1537
|
+
u && s.target && s.target.shadowRoot && d && (a = d[0]);
|
1538
|
+
const c = r.noSwipingSelector ? r.noSwipingSelector : `.${r.noSwipingClass}`, p = !!(s.target && s.target.shadowRoot);
|
1539
|
+
if (r.noSwiping && (p ? $t(c, a) : a.closest(c))) {
|
1540
|
+
e.allowClick = !0;
|
1541
|
+
return;
|
1542
|
+
}
|
1543
|
+
if (r.swipeHandler && !a.closest(r.swipeHandler))
|
1544
|
+
return;
|
1545
|
+
l.currentX = s.pageX, l.currentY = s.pageY;
|
1546
|
+
const f = l.currentX, h = l.currentY;
|
1547
|
+
if (!ye(e, s, f))
|
1548
|
+
return;
|
1549
|
+
Object.assign(n, {
|
1550
|
+
isTouched: !0,
|
1551
|
+
isMoved: !1,
|
1552
|
+
allowTouchCallbacks: !0,
|
1553
|
+
isScrolling: void 0,
|
1554
|
+
startMoving: void 0
|
1555
|
+
}), l.startX = f, l.startY = h, n.touchStartTime = ee(), e.allowClick = !0, e.updateSize(), e.swipeDirection = void 0, r.threshold > 0 && (n.allowThresholdMove = !1);
|
1556
|
+
let v = !0;
|
1557
|
+
a.matches(n.focusableElements) && (v = !1, a.nodeName === "SELECT" && (n.isTouched = !1)), i.activeElement && i.activeElement.matches(n.focusableElements) && i.activeElement !== a && i.activeElement.blur();
|
1558
|
+
const y = v && e.allowTouchMove && r.touchStartPreventDefault;
|
1559
|
+
(r.touchStartForcePreventDefault || y) && !a.isContentEditable && s.preventDefault(), r.freeMode && r.freeMode.enabled && e.freeMode && e.animating && !r.cssMode && e.freeMode.onTouchStart(), e.emit("touchStart", s);
|
1560
|
+
}
|
1561
|
+
function kt(t) {
|
1562
|
+
const e = R(), i = this, s = i.touchEventsData, {
|
1563
|
+
params: n,
|
1564
|
+
touches: r,
|
1565
|
+
rtlTranslate: l,
|
1566
|
+
enabled: o
|
1567
|
+
} = i;
|
1568
|
+
if (!o || !n.simulateTouch && t.pointerType === "mouse") return;
|
1569
|
+
let a = t;
|
1570
|
+
if (a.originalEvent && (a = a.originalEvent), a.type === "pointermove" && (s.touchId !== null || a.pointerId !== s.pointerId))
|
1571
|
+
return;
|
1572
|
+
let u;
|
1573
|
+
if (a.type === "touchmove") {
|
1574
|
+
if (u = [...a.changedTouches].filter((I) => I.identifier === s.touchId)[0], !u || u.identifier !== s.touchId) return;
|
1575
|
+
} else
|
1576
|
+
u = a;
|
1577
|
+
if (!s.isTouched) {
|
1578
|
+
s.startMoving && s.isScrolling && i.emit("touchMoveOpposite", a);
|
1579
|
+
return;
|
1580
|
+
}
|
1581
|
+
const d = u.pageX, c = u.pageY;
|
1582
|
+
if (a.preventedByNestedSwiper) {
|
1583
|
+
r.startX = d, r.startY = c;
|
1584
|
+
return;
|
1585
|
+
}
|
1586
|
+
if (!i.allowTouchMove) {
|
1587
|
+
a.target.matches(s.focusableElements) || (i.allowClick = !1), s.isTouched && (Object.assign(r, {
|
1588
|
+
startX: d,
|
1589
|
+
startY: c,
|
1590
|
+
currentX: d,
|
1591
|
+
currentY: c
|
1592
|
+
}), s.touchStartTime = ee());
|
1593
|
+
return;
|
1594
|
+
}
|
1595
|
+
if (n.touchReleaseOnEdges && !n.loop) {
|
1596
|
+
if (i.isVertical()) {
|
1597
|
+
if (c < r.startY && i.translate <= i.maxTranslate() || c > r.startY && i.translate >= i.minTranslate()) {
|
1598
|
+
s.isTouched = !1, s.isMoved = !1;
|
1599
|
+
return;
|
1600
|
+
}
|
1601
|
+
} else if (d < r.startX && i.translate <= i.maxTranslate() || d > r.startX && i.translate >= i.minTranslate())
|
1602
|
+
return;
|
1603
|
+
}
|
1604
|
+
if (e.activeElement && a.target === e.activeElement && a.target.matches(s.focusableElements)) {
|
1605
|
+
s.isMoved = !0, i.allowClick = !1;
|
1606
|
+
return;
|
1607
|
+
}
|
1608
|
+
s.allowTouchCallbacks && i.emit("touchMove", a), r.previousX = r.currentX, r.previousY = r.currentY, r.currentX = d, r.currentY = c;
|
1609
|
+
const p = r.currentX - r.startX, f = r.currentY - r.startY;
|
1610
|
+
if (i.params.threshold && Math.sqrt(p ** 2 + f ** 2) < i.params.threshold) return;
|
1611
|
+
if (typeof s.isScrolling > "u") {
|
1612
|
+
let I;
|
1613
|
+
i.isHorizontal() && r.currentY === r.startY || i.isVertical() && r.currentX === r.startX ? s.isScrolling = !1 : p * p + f * f >= 25 && (I = Math.atan2(Math.abs(f), Math.abs(p)) * 180 / Math.PI, s.isScrolling = i.isHorizontal() ? I > n.touchAngle : 90 - I > n.touchAngle);
|
1614
|
+
}
|
1615
|
+
if (s.isScrolling && i.emit("touchMoveOpposite", a), typeof s.startMoving > "u" && (r.currentX !== r.startX || r.currentY !== r.startY) && (s.startMoving = !0), s.isScrolling || a.type === "touchmove" && s.preventTouchMoveFromPointerMove) {
|
1616
|
+
s.isTouched = !1;
|
1617
|
+
return;
|
1618
|
+
}
|
1619
|
+
if (!s.startMoving)
|
1620
|
+
return;
|
1621
|
+
i.allowClick = !1, !n.cssMode && a.cancelable && a.preventDefault(), n.touchMoveStopPropagation && !n.nested && a.stopPropagation();
|
1622
|
+
let h = i.isHorizontal() ? p : f, v = i.isHorizontal() ? r.currentX - r.previousX : r.currentY - r.previousY;
|
1623
|
+
n.oneWayMovement && (h = Math.abs(h) * (l ? 1 : -1), v = Math.abs(v) * (l ? 1 : -1)), r.diff = h, h *= n.touchRatio, l && (h = -h, v = -v);
|
1624
|
+
const y = i.touchesDirection;
|
1625
|
+
i.swipeDirection = h > 0 ? "prev" : "next", i.touchesDirection = v > 0 ? "prev" : "next";
|
1626
|
+
const m = i.params.loop && !n.cssMode, b = i.touchesDirection === "next" && i.allowSlideNext || i.touchesDirection === "prev" && i.allowSlidePrev;
|
1627
|
+
if (!s.isMoved) {
|
1628
|
+
if (m && b && i.loopFix({
|
1629
|
+
direction: i.swipeDirection
|
1630
|
+
}), s.startTranslate = i.getTranslate(), i.setTransition(0), i.animating) {
|
1631
|
+
const I = new window.CustomEvent("transitionend", {
|
1632
|
+
bubbles: !0,
|
1633
|
+
cancelable: !0,
|
1634
|
+
detail: {
|
1635
|
+
bySwiperTouchMove: !0
|
1636
|
+
}
|
1637
|
+
});
|
1638
|
+
i.wrapperEl.dispatchEvent(I);
|
1639
|
+
}
|
1640
|
+
s.allowMomentumBounce = !1, n.grabCursor && (i.allowSlideNext === !0 || i.allowSlidePrev === !0) && i.setGrabCursor(!0), i.emit("sliderFirstMove", a);
|
1641
|
+
}
|
1642
|
+
let g;
|
1643
|
+
if ((/* @__PURE__ */ new Date()).getTime(), s.isMoved && s.allowThresholdMove && y !== i.touchesDirection && m && b && Math.abs(h) >= 1) {
|
1644
|
+
Object.assign(r, {
|
1645
|
+
startX: d,
|
1646
|
+
startY: c,
|
1647
|
+
currentX: d,
|
1648
|
+
currentY: c,
|
1649
|
+
startTranslate: s.currentTranslate
|
1650
|
+
}), s.loopSwapReset = !0, s.startTranslate = s.currentTranslate;
|
1651
|
+
return;
|
1652
|
+
}
|
1653
|
+
i.emit("sliderMove", a), s.isMoved = !0, s.currentTranslate = h + s.startTranslate;
|
1654
|
+
let S = !0, T = n.resistanceRatio;
|
1655
|
+
if (n.touchReleaseOnEdges && (T = 0), h > 0 ? (m && b && !g && s.allowThresholdMove && s.currentTranslate > (n.centeredSlides ? i.minTranslate() - i.slidesSizesGrid[i.activeIndex + 1] : i.minTranslate()) && i.loopFix({
|
1656
|
+
direction: "prev",
|
1657
|
+
setTranslate: !0,
|
1658
|
+
activeSlideIndex: 0
|
1659
|
+
}), s.currentTranslate > i.minTranslate() && (S = !1, n.resistance && (s.currentTranslate = i.minTranslate() - 1 + (-i.minTranslate() + s.startTranslate + h) ** T))) : h < 0 && (m && b && !g && s.allowThresholdMove && s.currentTranslate < (n.centeredSlides ? i.maxTranslate() + i.slidesSizesGrid[i.slidesSizesGrid.length - 1] : i.maxTranslate()) && i.loopFix({
|
1660
|
+
direction: "next",
|
1661
|
+
setTranslate: !0,
|
1662
|
+
activeSlideIndex: i.slides.length - (n.slidesPerView === "auto" ? i.slidesPerViewDynamic() : Math.ceil(parseFloat(n.slidesPerView, 10)))
|
1663
|
+
}), s.currentTranslate < i.maxTranslate() && (S = !1, n.resistance && (s.currentTranslate = i.maxTranslate() + 1 - (i.maxTranslate() - s.startTranslate - h) ** T))), S && (a.preventedByNestedSwiper = !0), !i.allowSlideNext && i.swipeDirection === "next" && s.currentTranslate < s.startTranslate && (s.currentTranslate = s.startTranslate), !i.allowSlidePrev && i.swipeDirection === "prev" && s.currentTranslate > s.startTranslate && (s.currentTranslate = s.startTranslate), !i.allowSlidePrev && !i.allowSlideNext && (s.currentTranslate = s.startTranslate), n.threshold > 0)
|
1664
|
+
if (Math.abs(h) > n.threshold || s.allowThresholdMove) {
|
1665
|
+
if (!s.allowThresholdMove) {
|
1666
|
+
s.allowThresholdMove = !0, r.startX = r.currentX, r.startY = r.currentY, s.currentTranslate = s.startTranslate, r.diff = i.isHorizontal() ? r.currentX - r.startX : r.currentY - r.startY;
|
1667
|
+
return;
|
1668
|
+
}
|
1669
|
+
} else {
|
1670
|
+
s.currentTranslate = s.startTranslate;
|
1671
|
+
return;
|
1672
|
+
}
|
1673
|
+
!n.followFinger || n.cssMode || ((n.freeMode && n.freeMode.enabled && i.freeMode || n.watchSlidesProgress) && (i.updateActiveIndex(), i.updateSlidesClasses()), n.freeMode && n.freeMode.enabled && i.freeMode && i.freeMode.onTouchMove(), i.updateProgress(s.currentTranslate), i.setTranslate(s.currentTranslate));
|
1674
|
+
}
|
1675
|
+
function Wt(t) {
|
1676
|
+
const e = this, i = e.touchEventsData;
|
1677
|
+
let s = t;
|
1678
|
+
s.originalEvent && (s = s.originalEvent);
|
1679
|
+
let n;
|
1680
|
+
if (s.type === "touchend" || s.type === "touchcancel") {
|
1681
|
+
if (n = [...s.changedTouches].filter((T) => T.identifier === i.touchId)[0], !n || n.identifier !== i.touchId) return;
|
1682
|
+
} else {
|
1683
|
+
if (i.touchId !== null || s.pointerId !== i.pointerId) return;
|
1684
|
+
n = s;
|
1685
|
+
}
|
1686
|
+
if (["pointercancel", "pointerout", "pointerleave", "contextmenu"].includes(s.type) && !(["pointercancel", "contextmenu"].includes(s.type) && (e.browser.isSafari || e.browser.isWebView)))
|
1687
|
+
return;
|
1688
|
+
i.pointerId = null, i.touchId = null;
|
1689
|
+
const {
|
1690
|
+
params: l,
|
1691
|
+
touches: o,
|
1692
|
+
rtlTranslate: a,
|
1693
|
+
slidesGrid: u,
|
1694
|
+
enabled: d
|
1695
|
+
} = e;
|
1696
|
+
if (!d || !l.simulateTouch && s.pointerType === "mouse") return;
|
1697
|
+
if (i.allowTouchCallbacks && e.emit("touchEnd", s), i.allowTouchCallbacks = !1, !i.isTouched) {
|
1698
|
+
i.isMoved && l.grabCursor && e.setGrabCursor(!1), i.isMoved = !1, i.startMoving = !1;
|
1699
|
+
return;
|
1700
|
+
}
|
1701
|
+
l.grabCursor && i.isMoved && i.isTouched && (e.allowSlideNext === !0 || e.allowSlidePrev === !0) && e.setGrabCursor(!1);
|
1702
|
+
const c = ee(), p = c - i.touchStartTime;
|
1703
|
+
if (e.allowClick) {
|
1704
|
+
const T = s.path || s.composedPath && s.composedPath();
|
1705
|
+
e.updateClickedSlide(T && T[0] || s.target, T), e.emit("tap click", s), p < 300 && c - i.lastClickTime < 300 && e.emit("doubleTap doubleClick", s);
|
1706
|
+
}
|
1707
|
+
if (i.lastClickTime = ee(), ue(() => {
|
1708
|
+
e.destroyed || (e.allowClick = !0);
|
1709
|
+
}), !i.isTouched || !i.isMoved || !e.swipeDirection || o.diff === 0 && !i.loopSwapReset || i.currentTranslate === i.startTranslate && !i.loopSwapReset) {
|
1710
|
+
i.isTouched = !1, i.isMoved = !1, i.startMoving = !1;
|
1711
|
+
return;
|
1712
|
+
}
|
1713
|
+
i.isTouched = !1, i.isMoved = !1, i.startMoving = !1;
|
1714
|
+
let f;
|
1715
|
+
if (l.followFinger ? f = a ? e.translate : -e.translate : f = -i.currentTranslate, l.cssMode)
|
1716
|
+
return;
|
1717
|
+
if (l.freeMode && l.freeMode.enabled) {
|
1718
|
+
e.freeMode.onTouchEnd({
|
1719
|
+
currentPos: f
|
1720
|
+
});
|
1721
|
+
return;
|
1722
|
+
}
|
1723
|
+
const h = f >= -e.maxTranslate() && !e.params.loop;
|
1724
|
+
let v = 0, y = e.slidesSizesGrid[0];
|
1725
|
+
for (let T = 0; T < u.length; T += T < l.slidesPerGroupSkip ? 1 : l.slidesPerGroup) {
|
1726
|
+
const I = T < l.slidesPerGroupSkip - 1 ? 1 : l.slidesPerGroup;
|
1727
|
+
typeof u[T + I] < "u" ? (h || f >= u[T] && f < u[T + I]) && (v = T, y = u[T + I] - u[T]) : (h || f >= u[T]) && (v = T, y = u[u.length - 1] - u[u.length - 2]);
|
1728
|
+
}
|
1729
|
+
let m = null, b = null;
|
1730
|
+
l.rewind && (e.isBeginning ? b = l.virtual && l.virtual.enabled && e.virtual ? e.virtual.slides.length - 1 : e.slides.length - 1 : e.isEnd && (m = 0));
|
1731
|
+
const g = (f - u[v]) / y, S = v < l.slidesPerGroupSkip - 1 ? 1 : l.slidesPerGroup;
|
1732
|
+
if (p > l.longSwipesMs) {
|
1733
|
+
if (!l.longSwipes) {
|
1734
|
+
e.slideTo(e.activeIndex);
|
1735
|
+
return;
|
1736
|
+
}
|
1737
|
+
e.swipeDirection === "next" && (g >= l.longSwipesRatio ? e.slideTo(l.rewind && e.isEnd ? m : v + S) : e.slideTo(v)), e.swipeDirection === "prev" && (g > 1 - l.longSwipesRatio ? e.slideTo(v + S) : b !== null && g < 0 && Math.abs(g) > l.longSwipesRatio ? e.slideTo(b) : e.slideTo(v));
|
1738
|
+
} else {
|
1739
|
+
if (!l.shortSwipes) {
|
1740
|
+
e.slideTo(e.activeIndex);
|
1741
|
+
return;
|
1742
|
+
}
|
1743
|
+
e.navigation && (s.target === e.navigation.nextEl || s.target === e.navigation.prevEl) ? s.target === e.navigation.nextEl ? e.slideTo(v + S) : e.slideTo(v) : (e.swipeDirection === "next" && e.slideTo(m !== null ? m : v + S), e.swipeDirection === "prev" && e.slideTo(b !== null ? b : v));
|
1744
|
+
}
|
1745
|
+
}
|
1746
|
+
function be() {
|
1747
|
+
const t = this, {
|
1748
|
+
params: e,
|
1749
|
+
el: i
|
1750
|
+
} = t;
|
1751
|
+
if (i && i.offsetWidth === 0) return;
|
1752
|
+
e.breakpoints && t.setBreakpoint();
|
1753
|
+
const {
|
1754
|
+
allowSlideNext: s,
|
1755
|
+
allowSlidePrev: n,
|
1756
|
+
snapGrid: r
|
1757
|
+
} = t, l = t.virtual && t.params.virtual.enabled;
|
1758
|
+
t.allowSlideNext = !0, t.allowSlidePrev = !0, t.updateSize(), t.updateSlides(), t.updateSlidesClasses();
|
1759
|
+
const o = l && e.loop;
|
1760
|
+
(e.slidesPerView === "auto" || e.slidesPerView > 1) && t.isEnd && !t.isBeginning && !t.params.centeredSlides && !o ? t.slideTo(t.slides.length - 1, 0, !1, !0) : t.params.loop && !l ? t.slideToLoop(t.realIndex, 0, !1, !0) : t.slideTo(t.activeIndex, 0, !1, !0), t.autoplay && t.autoplay.running && t.autoplay.paused && (clearTimeout(t.autoplay.resizeTimeout), t.autoplay.resizeTimeout = setTimeout(() => {
|
1761
|
+
t.autoplay && t.autoplay.running && t.autoplay.paused && t.autoplay.resume();
|
1762
|
+
}, 500)), t.allowSlidePrev = n, t.allowSlideNext = s, t.params.watchOverflow && r !== t.snapGrid && t.checkOverflow();
|
1763
|
+
}
|
1764
|
+
function jt(t) {
|
1765
|
+
const e = this;
|
1766
|
+
e.enabled && (e.allowClick || (e.params.preventClicks && t.preventDefault(), e.params.preventClicksPropagation && e.animating && (t.stopPropagation(), t.stopImmediatePropagation())));
|
1767
|
+
}
|
1768
|
+
function qt() {
|
1769
|
+
const t = this, {
|
1770
|
+
wrapperEl: e,
|
1771
|
+
rtlTranslate: i,
|
1772
|
+
enabled: s
|
1773
|
+
} = t;
|
1774
|
+
if (!s) return;
|
1775
|
+
t.previousTranslate = t.translate, t.isHorizontal() ? t.translate = -e.scrollLeft : t.translate = -e.scrollTop, t.translate === 0 && (t.translate = 0), t.updateActiveIndex(), t.updateSlidesClasses();
|
1776
|
+
let n;
|
1777
|
+
const r = t.maxTranslate() - t.minTranslate();
|
1778
|
+
r === 0 ? n = 0 : n = (t.translate - t.minTranslate()) / r, n !== t.progress && t.updateProgress(i ? -t.translate : t.translate), t.emit("setTranslate", t.translate, !1);
|
1779
|
+
}
|
1780
|
+
function Yt(t) {
|
1781
|
+
const e = this;
|
1782
|
+
Q(e, t.target), !(e.params.cssMode || e.params.slidesPerView !== "auto" && !e.params.autoHeight) && e.update();
|
1783
|
+
}
|
1784
|
+
function Xt() {
|
1785
|
+
const t = this;
|
1786
|
+
t.documentTouchHandlerProceeded || (t.documentTouchHandlerProceeded = !0, t.params.touchReleaseOnEdges && (t.el.style.touchAction = "auto"));
|
1787
|
+
}
|
1788
|
+
const Ae = (t, e) => {
|
1789
|
+
const i = R(), {
|
1790
|
+
params: s,
|
1791
|
+
el: n,
|
1792
|
+
wrapperEl: r,
|
1793
|
+
device: l
|
1794
|
+
} = t, o = !!s.nested, a = e === "on" ? "addEventListener" : "removeEventListener", u = e;
|
1795
|
+
!n || typeof n == "string" || (i[a]("touchstart", t.onDocumentTouchStart, {
|
1796
|
+
passive: !1,
|
1797
|
+
capture: o
|
1798
|
+
}), n[a]("touchstart", t.onTouchStart, {
|
1799
|
+
passive: !1
|
1800
|
+
}), n[a]("pointerdown", t.onTouchStart, {
|
1801
|
+
passive: !1
|
1802
|
+
}), i[a]("touchmove", t.onTouchMove, {
|
1803
|
+
passive: !1,
|
1804
|
+
capture: o
|
1805
|
+
}), i[a]("pointermove", t.onTouchMove, {
|
1806
|
+
passive: !1,
|
1807
|
+
capture: o
|
1808
|
+
}), i[a]("touchend", t.onTouchEnd, {
|
1809
|
+
passive: !0
|
1810
|
+
}), i[a]("pointerup", t.onTouchEnd, {
|
1811
|
+
passive: !0
|
1812
|
+
}), i[a]("pointercancel", t.onTouchEnd, {
|
1813
|
+
passive: !0
|
1814
|
+
}), i[a]("touchcancel", t.onTouchEnd, {
|
1815
|
+
passive: !0
|
1816
|
+
}), i[a]("pointerout", t.onTouchEnd, {
|
1817
|
+
passive: !0
|
1818
|
+
}), i[a]("pointerleave", t.onTouchEnd, {
|
1819
|
+
passive: !0
|
1820
|
+
}), i[a]("contextmenu", t.onTouchEnd, {
|
1821
|
+
passive: !0
|
1822
|
+
}), (s.preventClicks || s.preventClicksPropagation) && n[a]("click", t.onClick, !0), s.cssMode && r[a]("scroll", t.onScroll), s.updateOnWindowResize ? t[u](l.ios || l.android ? "resize orientationchange observerUpdate" : "resize observerUpdate", be, !0) : t[u]("observerUpdate", be, !0), n[a]("load", t.onLoad, {
|
1823
|
+
capture: !0
|
1824
|
+
}));
|
1825
|
+
};
|
1826
|
+
function Kt() {
|
1827
|
+
const t = this, {
|
1828
|
+
params: e
|
1829
|
+
} = t;
|
1830
|
+
t.onTouchStart = Ht.bind(t), t.onTouchMove = kt.bind(t), t.onTouchEnd = Wt.bind(t), t.onDocumentTouchStart = Xt.bind(t), e.cssMode && (t.onScroll = qt.bind(t)), t.onClick = jt.bind(t), t.onLoad = Yt.bind(t), Ae(t, "on");
|
1831
|
+
}
|
1832
|
+
function Ut() {
|
1833
|
+
Ae(this, "off");
|
1834
|
+
}
|
1835
|
+
var Zt = {
|
1836
|
+
attachEvents: Kt,
|
1837
|
+
detachEvents: Ut
|
1838
|
+
};
|
1839
|
+
const xe = (t, e) => t.grid && e.grid && e.grid.rows > 1;
|
1840
|
+
function Jt() {
|
1841
|
+
const t = this, {
|
1842
|
+
realIndex: e,
|
1843
|
+
initialized: i,
|
1844
|
+
params: s,
|
1845
|
+
el: n
|
1846
|
+
} = t, r = s.breakpoints;
|
1847
|
+
if (!r || r && Object.keys(r).length === 0) return;
|
1848
|
+
const l = t.getBreakpoint(r, t.params.breakpointsBase, t.el);
|
1849
|
+
if (!l || t.currentBreakpoint === l) return;
|
1850
|
+
const a = (l in r ? r[l] : void 0) || t.originalParams, u = xe(t, s), d = xe(t, a), c = t.params.grabCursor, p = a.grabCursor, f = s.enabled;
|
1851
|
+
u && !d ? (n.classList.remove(`${s.containerModifierClass}grid`, `${s.containerModifierClass}grid-column`), t.emitContainerClasses()) : !u && d && (n.classList.add(`${s.containerModifierClass}grid`), (a.grid.fill && a.grid.fill === "column" || !a.grid.fill && s.grid.fill === "column") && n.classList.add(`${s.containerModifierClass}grid-column`), t.emitContainerClasses()), c && !p ? t.unsetGrabCursor() : !c && p && t.setGrabCursor(), ["navigation", "pagination", "scrollbar"].forEach((g) => {
|
1852
|
+
if (typeof a[g] > "u") return;
|
1853
|
+
const S = s[g] && s[g].enabled, T = a[g] && a[g].enabled;
|
1854
|
+
S && !T && t[g].disable(), !S && T && t[g].enable();
|
1855
|
+
});
|
1856
|
+
const h = a.direction && a.direction !== s.direction, v = s.loop && (a.slidesPerView !== s.slidesPerView || h), y = s.loop;
|
1857
|
+
h && i && t.changeDirection(), N(t.params, a);
|
1858
|
+
const m = t.params.enabled, b = t.params.loop;
|
1859
|
+
Object.assign(t, {
|
1860
|
+
allowTouchMove: t.params.allowTouchMove,
|
1861
|
+
allowSlideNext: t.params.allowSlideNext,
|
1862
|
+
allowSlidePrev: t.params.allowSlidePrev
|
1863
|
+
}), f && !m ? t.disable() : !f && m && t.enable(), t.currentBreakpoint = l, t.emit("_beforeBreakpoint", a), i && (v ? (t.loopDestroy(), t.loopCreate(e), t.updateSlides()) : !y && b ? (t.loopCreate(e), t.updateSlides()) : y && !b && t.loopDestroy()), t.emit("breakpoint", a);
|
1864
|
+
}
|
1865
|
+
function Qt(t, e, i) {
|
1866
|
+
if (e === void 0 && (e = "window"), !t || e === "container" && !i) return;
|
1867
|
+
let s = !1;
|
1868
|
+
const n = V(), r = e === "window" ? n.innerHeight : i.clientHeight, l = Object.keys(t).map((o) => {
|
1869
|
+
if (typeof o == "string" && o.indexOf("@") === 0) {
|
1870
|
+
const a = parseFloat(o.substr(1));
|
1871
|
+
return {
|
1872
|
+
value: r * a,
|
1873
|
+
point: o
|
1874
|
+
};
|
1875
|
+
}
|
1876
|
+
return {
|
1877
|
+
value: o,
|
1878
|
+
point: o
|
1879
|
+
};
|
1880
|
+
});
|
1881
|
+
l.sort((o, a) => parseInt(o.value, 10) - parseInt(a.value, 10));
|
1882
|
+
for (let o = 0; o < l.length; o += 1) {
|
1883
|
+
const {
|
1884
|
+
point: a,
|
1885
|
+
value: u
|
1886
|
+
} = l[o];
|
1887
|
+
e === "window" ? n.matchMedia(`(min-width: ${u}px)`).matches && (s = a) : u <= i.clientWidth && (s = a);
|
1888
|
+
}
|
1889
|
+
return s || "max";
|
1890
|
+
}
|
1891
|
+
var ei = {
|
1892
|
+
setBreakpoint: Jt,
|
1893
|
+
getBreakpoint: Qt
|
1894
|
+
};
|
1895
|
+
function ti(t, e) {
|
1896
|
+
const i = [];
|
1897
|
+
return t.forEach((s) => {
|
1898
|
+
typeof s == "object" ? Object.keys(s).forEach((n) => {
|
1899
|
+
s[n] && i.push(e + n);
|
1900
|
+
}) : typeof s == "string" && i.push(e + s);
|
1901
|
+
}), i;
|
1902
|
+
}
|
1903
|
+
function ii() {
|
1904
|
+
const t = this, {
|
1905
|
+
classNames: e,
|
1906
|
+
params: i,
|
1907
|
+
rtl: s,
|
1908
|
+
el: n,
|
1909
|
+
device: r
|
1910
|
+
} = t, l = ti(["initialized", i.direction, {
|
1911
|
+
"free-mode": t.params.freeMode && i.freeMode.enabled
|
1912
|
+
}, {
|
1913
|
+
autoheight: i.autoHeight
|
1914
|
+
}, {
|
1915
|
+
rtl: s
|
1916
|
+
}, {
|
1917
|
+
grid: i.grid && i.grid.rows > 1
|
1918
|
+
}, {
|
1919
|
+
"grid-column": i.grid && i.grid.rows > 1 && i.grid.fill === "column"
|
1920
|
+
}, {
|
1921
|
+
android: r.android
|
1922
|
+
}, {
|
1923
|
+
ios: r.ios
|
1924
|
+
}, {
|
1925
|
+
"css-mode": i.cssMode
|
1926
|
+
}, {
|
1927
|
+
centered: i.cssMode && i.centeredSlides
|
1928
|
+
}, {
|
1929
|
+
"watch-progress": i.watchSlidesProgress
|
1930
|
+
}], i.containerModifierClass);
|
1931
|
+
e.push(...l), n.classList.add(...e), t.emitContainerClasses();
|
1932
|
+
}
|
1933
|
+
function si() {
|
1934
|
+
const t = this, {
|
1935
|
+
el: e,
|
1936
|
+
classNames: i
|
1937
|
+
} = t;
|
1938
|
+
!e || typeof e == "string" || (e.classList.remove(...i), t.emitContainerClasses());
|
1939
|
+
}
|
1940
|
+
var ri = {
|
1941
|
+
addClasses: ii,
|
1942
|
+
removeClasses: si
|
1943
|
+
};
|
1944
|
+
function ni() {
|
1945
|
+
const t = this, {
|
1946
|
+
isLocked: e,
|
1947
|
+
params: i
|
1948
|
+
} = t, {
|
1949
|
+
slidesOffsetBefore: s
|
1950
|
+
} = i;
|
1951
|
+
if (s) {
|
1952
|
+
const n = t.slides.length - 1, r = t.slidesGrid[n] + t.slidesSizesGrid[n] + s * 2;
|
1953
|
+
t.isLocked = t.size > r;
|
1954
|
+
} else
|
1955
|
+
t.isLocked = t.snapGrid.length === 1;
|
1956
|
+
i.allowSlideNext === !0 && (t.allowSlideNext = !t.isLocked), i.allowSlidePrev === !0 && (t.allowSlidePrev = !t.isLocked), e && e !== t.isLocked && (t.isEnd = !1), e !== t.isLocked && t.emit(t.isLocked ? "lock" : "unlock");
|
1957
|
+
}
|
1958
|
+
var ai = {
|
1959
|
+
checkOverflow: ni
|
1960
|
+
}, me = {
|
1961
|
+
init: !0,
|
1962
|
+
direction: "horizontal",
|
1963
|
+
oneWayMovement: !1,
|
1964
|
+
swiperElementNodeName: "SWIPER-CONTAINER",
|
1965
|
+
touchEventsTarget: "wrapper",
|
1966
|
+
initialSlide: 0,
|
1967
|
+
speed: 300,
|
1968
|
+
cssMode: !1,
|
1969
|
+
updateOnWindowResize: !0,
|
1970
|
+
resizeObserver: !0,
|
1971
|
+
nested: !1,
|
1972
|
+
createElements: !1,
|
1973
|
+
eventsPrefix: "swiper",
|
1974
|
+
enabled: !0,
|
1975
|
+
focusableElements: "input, select, option, textarea, button, video, label",
|
1976
|
+
// Overrides
|
1977
|
+
width: null,
|
1978
|
+
height: null,
|
1979
|
+
//
|
1980
|
+
preventInteractionOnTransition: !1,
|
1981
|
+
// ssr
|
1982
|
+
userAgent: null,
|
1983
|
+
url: null,
|
1984
|
+
// To support iOS's swipe-to-go-back gesture (when being used in-app).
|
1985
|
+
edgeSwipeDetection: !1,
|
1986
|
+
edgeSwipeThreshold: 20,
|
1987
|
+
// Autoheight
|
1988
|
+
autoHeight: !1,
|
1989
|
+
// Set wrapper width
|
1990
|
+
setWrapperSize: !1,
|
1991
|
+
// Virtual Translate
|
1992
|
+
virtualTranslate: !1,
|
1993
|
+
// Effects
|
1994
|
+
effect: "slide",
|
1995
|
+
// 'slide' or 'fade' or 'cube' or 'coverflow' or 'flip'
|
1996
|
+
// Breakpoints
|
1997
|
+
breakpoints: void 0,
|
1998
|
+
breakpointsBase: "window",
|
1999
|
+
// Slides grid
|
2000
|
+
spaceBetween: 0,
|
2001
|
+
slidesPerView: 1,
|
2002
|
+
slidesPerGroup: 1,
|
2003
|
+
slidesPerGroupSkip: 0,
|
2004
|
+
slidesPerGroupAuto: !1,
|
2005
|
+
centeredSlides: !1,
|
2006
|
+
centeredSlidesBounds: !1,
|
2007
|
+
slidesOffsetBefore: 0,
|
2008
|
+
// in px
|
2009
|
+
slidesOffsetAfter: 0,
|
2010
|
+
// in px
|
2011
|
+
normalizeSlideIndex: !0,
|
2012
|
+
centerInsufficientSlides: !1,
|
2013
|
+
// Disable swiper and hide navigation when container not overflow
|
2014
|
+
watchOverflow: !0,
|
2015
|
+
// Round length
|
2016
|
+
roundLengths: !1,
|
2017
|
+
// Touches
|
2018
|
+
touchRatio: 1,
|
2019
|
+
touchAngle: 45,
|
2020
|
+
simulateTouch: !0,
|
2021
|
+
shortSwipes: !0,
|
2022
|
+
longSwipes: !0,
|
2023
|
+
longSwipesRatio: 0.5,
|
2024
|
+
longSwipesMs: 300,
|
2025
|
+
followFinger: !0,
|
2026
|
+
allowTouchMove: !0,
|
2027
|
+
threshold: 5,
|
2028
|
+
touchMoveStopPropagation: !1,
|
2029
|
+
touchStartPreventDefault: !0,
|
2030
|
+
touchStartForcePreventDefault: !1,
|
2031
|
+
touchReleaseOnEdges: !1,
|
2032
|
+
// Unique Navigation Elements
|
2033
|
+
uniqueNavElements: !0,
|
2034
|
+
// Resistance
|
2035
|
+
resistance: !0,
|
2036
|
+
resistanceRatio: 0.85,
|
2037
|
+
// Progress
|
2038
|
+
watchSlidesProgress: !1,
|
2039
|
+
// Cursor
|
2040
|
+
grabCursor: !1,
|
2041
|
+
// Clicks
|
2042
|
+
preventClicks: !0,
|
2043
|
+
preventClicksPropagation: !0,
|
2044
|
+
slideToClickedSlide: !1,
|
2045
|
+
// loop
|
2046
|
+
loop: !1,
|
2047
|
+
loopAddBlankSlides: !0,
|
2048
|
+
loopAdditionalSlides: 0,
|
2049
|
+
loopPreventsSliding: !0,
|
2050
|
+
// rewind
|
2051
|
+
rewind: !1,
|
2052
|
+
// Swiping/no swiping
|
2053
|
+
allowSlidePrev: !0,
|
2054
|
+
allowSlideNext: !0,
|
2055
|
+
swipeHandler: null,
|
2056
|
+
// '.swipe-handler',
|
2057
|
+
noSwiping: !0,
|
2058
|
+
noSwipingClass: "swiper-no-swiping",
|
2059
|
+
noSwipingSelector: null,
|
2060
|
+
// Passive Listeners
|
2061
|
+
passiveListeners: !0,
|
2062
|
+
maxBackfaceHiddenSlides: 10,
|
2063
|
+
// NS
|
2064
|
+
containerModifierClass: "swiper-",
|
2065
|
+
// NEW
|
2066
|
+
slideClass: "swiper-slide",
|
2067
|
+
slideBlankClass: "swiper-slide-blank",
|
2068
|
+
slideActiveClass: "swiper-slide-active",
|
2069
|
+
slideVisibleClass: "swiper-slide-visible",
|
2070
|
+
slideFullyVisibleClass: "swiper-slide-fully-visible",
|
2071
|
+
slideNextClass: "swiper-slide-next",
|
2072
|
+
slidePrevClass: "swiper-slide-prev",
|
2073
|
+
wrapperClass: "swiper-wrapper",
|
2074
|
+
lazyPreloaderClass: "swiper-lazy-preloader",
|
2075
|
+
lazyPreloadPrevNext: 0,
|
2076
|
+
// Callbacks
|
2077
|
+
runCallbacksOnInit: !0,
|
2078
|
+
// Internals
|
2079
|
+
_emitClasses: !1
|
2080
|
+
};
|
2081
|
+
function li(t, e) {
|
2082
|
+
return function(s) {
|
2083
|
+
s === void 0 && (s = {});
|
2084
|
+
const n = Object.keys(s)[0], r = s[n];
|
2085
|
+
if (typeof r != "object" || r === null) {
|
2086
|
+
N(e, s);
|
2087
|
+
return;
|
2088
|
+
}
|
2089
|
+
if (t[n] === !0 && (t[n] = {
|
2090
|
+
enabled: !0
|
2091
|
+
}), n === "navigation" && t[n] && t[n].enabled && !t[n].prevEl && !t[n].nextEl && (t[n].auto = !0), ["pagination", "scrollbar"].indexOf(n) >= 0 && t[n] && t[n].enabled && !t[n].el && (t[n].auto = !0), !(n in t && "enabled" in r)) {
|
2092
|
+
N(e, s);
|
2093
|
+
return;
|
2094
|
+
}
|
2095
|
+
typeof t[n] == "object" && !("enabled" in t[n]) && (t[n].enabled = !0), t[n] || (t[n] = {
|
2096
|
+
enabled: !1
|
2097
|
+
}), N(e, s);
|
2098
|
+
};
|
2099
|
+
}
|
2100
|
+
const oe = {
|
2101
|
+
eventsEmitter: rt,
|
2102
|
+
update: ht,
|
2103
|
+
translate: yt,
|
2104
|
+
transition: Pt,
|
2105
|
+
slide: _t,
|
2106
|
+
loop: Nt,
|
2107
|
+
grabCursor: Rt,
|
2108
|
+
events: Zt,
|
2109
|
+
breakpoints: ei,
|
2110
|
+
checkOverflow: ai,
|
2111
|
+
classes: ri
|
2112
|
+
}, de = {};
|
2113
|
+
let ge = class $ {
|
2114
|
+
constructor() {
|
2115
|
+
let e, i;
|
2116
|
+
for (var s = arguments.length, n = new Array(s), r = 0; r < s; r++)
|
2117
|
+
n[r] = arguments[r];
|
2118
|
+
n.length === 1 && n[0].constructor && Object.prototype.toString.call(n[0]).slice(8, -1) === "Object" ? i = n[0] : [e, i] = n, i || (i = {}), i = N({}, i), e && !i.el && (i.el = e);
|
2119
|
+
const l = R();
|
2120
|
+
if (i.el && typeof i.el == "string" && l.querySelectorAll(i.el).length > 1) {
|
2121
|
+
const d = [];
|
2122
|
+
return l.querySelectorAll(i.el).forEach((c) => {
|
2123
|
+
const p = N({}, i, {
|
2124
|
+
el: c
|
2125
|
+
});
|
2126
|
+
d.push(new $(p));
|
2127
|
+
}), d;
|
2128
|
+
}
|
2129
|
+
const o = this;
|
2130
|
+
o.__swiper__ = !0, o.support = Le(), o.device = Oe({
|
2131
|
+
userAgent: i.userAgent
|
2132
|
+
}), o.browser = tt(), o.eventsListeners = {}, o.eventsAnyListeners = [], o.modules = [...o.__modules__], i.modules && Array.isArray(i.modules) && o.modules.push(...i.modules);
|
2133
|
+
const a = {};
|
2134
|
+
o.modules.forEach((d) => {
|
2135
|
+
d({
|
2136
|
+
params: i,
|
2137
|
+
swiper: o,
|
2138
|
+
extendParams: li(i, a),
|
2139
|
+
on: o.on.bind(o),
|
2140
|
+
once: o.once.bind(o),
|
2141
|
+
off: o.off.bind(o),
|
2142
|
+
emit: o.emit.bind(o)
|
2143
|
+
});
|
2144
|
+
});
|
2145
|
+
const u = N({}, me, a);
|
2146
|
+
return o.params = N({}, u, de, i), o.originalParams = N({}, o.params), o.passedParams = N({}, i), o.params && o.params.on && Object.keys(o.params.on).forEach((d) => {
|
2147
|
+
o.on(d, o.params.on[d]);
|
2148
|
+
}), o.params && o.params.onAny && o.onAny(o.params.onAny), Object.assign(o, {
|
2149
|
+
enabled: o.params.enabled,
|
2150
|
+
el: e,
|
2151
|
+
// Classes
|
2152
|
+
classNames: [],
|
2153
|
+
// Slides
|
2154
|
+
slides: [],
|
2155
|
+
slidesGrid: [],
|
2156
|
+
snapGrid: [],
|
2157
|
+
slidesSizesGrid: [],
|
2158
|
+
// isDirection
|
2159
|
+
isHorizontal() {
|
2160
|
+
return o.params.direction === "horizontal";
|
2161
|
+
},
|
2162
|
+
isVertical() {
|
2163
|
+
return o.params.direction === "vertical";
|
2164
|
+
},
|
2165
|
+
// Indexes
|
2166
|
+
activeIndex: 0,
|
2167
|
+
realIndex: 0,
|
2168
|
+
//
|
2169
|
+
isBeginning: !0,
|
2170
|
+
isEnd: !1,
|
2171
|
+
// Props
|
2172
|
+
translate: 0,
|
2173
|
+
previousTranslate: 0,
|
2174
|
+
progress: 0,
|
2175
|
+
velocity: 0,
|
2176
|
+
animating: !1,
|
2177
|
+
cssOverflowAdjustment() {
|
2178
|
+
return Math.trunc(this.translate / 2 ** 23) * 2 ** 23;
|
2179
|
+
},
|
2180
|
+
// Locks
|
2181
|
+
allowSlideNext: o.params.allowSlideNext,
|
2182
|
+
allowSlidePrev: o.params.allowSlidePrev,
|
2183
|
+
// Touch Events
|
2184
|
+
touchEventsData: {
|
2185
|
+
isTouched: void 0,
|
2186
|
+
isMoved: void 0,
|
2187
|
+
allowTouchCallbacks: void 0,
|
2188
|
+
touchStartTime: void 0,
|
2189
|
+
isScrolling: void 0,
|
2190
|
+
currentTranslate: void 0,
|
2191
|
+
startTranslate: void 0,
|
2192
|
+
allowThresholdMove: void 0,
|
2193
|
+
// Form elements to match
|
2194
|
+
focusableElements: o.params.focusableElements,
|
2195
|
+
// Last click time
|
2196
|
+
lastClickTime: 0,
|
2197
|
+
clickTimeout: void 0,
|
2198
|
+
// Velocities
|
2199
|
+
velocities: [],
|
2200
|
+
allowMomentumBounce: void 0,
|
2201
|
+
startMoving: void 0,
|
2202
|
+
pointerId: null,
|
2203
|
+
touchId: null
|
2204
|
+
},
|
2205
|
+
// Clicks
|
2206
|
+
allowClick: !0,
|
2207
|
+
// Touches
|
2208
|
+
allowTouchMove: o.params.allowTouchMove,
|
2209
|
+
touches: {
|
2210
|
+
startX: 0,
|
2211
|
+
startY: 0,
|
2212
|
+
currentX: 0,
|
2213
|
+
currentY: 0,
|
2214
|
+
diff: 0
|
2215
|
+
},
|
2216
|
+
// Images
|
2217
|
+
imagesToLoad: [],
|
2218
|
+
imagesLoaded: 0
|
2219
|
+
}), o.emit("_swiper"), o.params.init && o.init(), o;
|
2220
|
+
}
|
2221
|
+
getDirectionLabel(e) {
|
2222
|
+
return this.isHorizontal() ? e : {
|
2223
|
+
width: "height",
|
2224
|
+
"margin-top": "margin-left",
|
2225
|
+
"margin-bottom ": "margin-right",
|
2226
|
+
"margin-left": "margin-top",
|
2227
|
+
"margin-right": "margin-bottom",
|
2228
|
+
"padding-left": "padding-top",
|
2229
|
+
"padding-right": "padding-bottom",
|
2230
|
+
marginRight: "marginBottom"
|
2231
|
+
}[e];
|
2232
|
+
}
|
2233
|
+
getSlideIndex(e) {
|
2234
|
+
const {
|
2235
|
+
slidesEl: i,
|
2236
|
+
params: s
|
2237
|
+
} = this, n = H(i, `.${s.slideClass}, swiper-slide`), r = we(n[0]);
|
2238
|
+
return we(e) - r;
|
2239
|
+
}
|
2240
|
+
getSlideIndexByData(e) {
|
2241
|
+
return this.getSlideIndex(this.slides.filter((i) => i.getAttribute("data-swiper-slide-index") * 1 === e)[0]);
|
2242
|
+
}
|
2243
|
+
recalcSlides() {
|
2244
|
+
const e = this, {
|
2245
|
+
slidesEl: i,
|
2246
|
+
params: s
|
2247
|
+
} = e;
|
2248
|
+
e.slides = H(i, `.${s.slideClass}, swiper-slide`);
|
2249
|
+
}
|
2250
|
+
enable() {
|
2251
|
+
const e = this;
|
2252
|
+
e.enabled || (e.enabled = !0, e.params.grabCursor && e.setGrabCursor(), e.emit("enable"));
|
2253
|
+
}
|
2254
|
+
disable() {
|
2255
|
+
const e = this;
|
2256
|
+
e.enabled && (e.enabled = !1, e.params.grabCursor && e.unsetGrabCursor(), e.emit("disable"));
|
2257
|
+
}
|
2258
|
+
setProgress(e, i) {
|
2259
|
+
const s = this;
|
2260
|
+
e = Math.min(Math.max(e, 0), 1);
|
2261
|
+
const n = s.minTranslate(), l = (s.maxTranslate() - n) * e + n;
|
2262
|
+
s.translateTo(l, typeof i > "u" ? 0 : i), s.updateActiveIndex(), s.updateSlidesClasses();
|
2263
|
+
}
|
2264
|
+
emitContainerClasses() {
|
2265
|
+
const e = this;
|
2266
|
+
if (!e.params._emitClasses || !e.el) return;
|
2267
|
+
const i = e.el.className.split(" ").filter((s) => s.indexOf("swiper") === 0 || s.indexOf(e.params.containerModifierClass) === 0);
|
2268
|
+
e.emit("_containerClasses", i.join(" "));
|
2269
|
+
}
|
2270
|
+
getSlideClasses(e) {
|
2271
|
+
const i = this;
|
2272
|
+
return i.destroyed ? "" : e.className.split(" ").filter((s) => s.indexOf("swiper-slide") === 0 || s.indexOf(i.params.slideClass) === 0).join(" ");
|
2273
|
+
}
|
2274
|
+
emitSlidesClasses() {
|
2275
|
+
const e = this;
|
2276
|
+
if (!e.params._emitClasses || !e.el) return;
|
2277
|
+
const i = [];
|
2278
|
+
e.slides.forEach((s) => {
|
2279
|
+
const n = e.getSlideClasses(s);
|
2280
|
+
i.push({
|
2281
|
+
slideEl: s,
|
2282
|
+
classNames: n
|
2283
|
+
}), e.emit("_slideClass", s, n);
|
2284
|
+
}), e.emit("_slideClasses", i);
|
2285
|
+
}
|
2286
|
+
slidesPerViewDynamic(e, i) {
|
2287
|
+
e === void 0 && (e = "current"), i === void 0 && (i = !1);
|
2288
|
+
const s = this, {
|
2289
|
+
params: n,
|
2290
|
+
slides: r,
|
2291
|
+
slidesGrid: l,
|
2292
|
+
slidesSizesGrid: o,
|
2293
|
+
size: a,
|
2294
|
+
activeIndex: u
|
2295
|
+
} = s;
|
2296
|
+
let d = 1;
|
2297
|
+
if (typeof n.slidesPerView == "number") return n.slidesPerView;
|
2298
|
+
if (n.centeredSlides) {
|
2299
|
+
let c = r[u] ? Math.ceil(r[u].swiperSlideSize) : 0, p;
|
2300
|
+
for (let f = u + 1; f < r.length; f += 1)
|
2301
|
+
r[f] && !p && (c += Math.ceil(r[f].swiperSlideSize), d += 1, c > a && (p = !0));
|
2302
|
+
for (let f = u - 1; f >= 0; f -= 1)
|
2303
|
+
r[f] && !p && (c += r[f].swiperSlideSize, d += 1, c > a && (p = !0));
|
2304
|
+
} else if (e === "current")
|
2305
|
+
for (let c = u + 1; c < r.length; c += 1)
|
2306
|
+
(i ? l[c] + o[c] - l[u] < a : l[c] - l[u] < a) && (d += 1);
|
2307
|
+
else
|
2308
|
+
for (let c = u - 1; c >= 0; c -= 1)
|
2309
|
+
l[u] - l[c] < a && (d += 1);
|
2310
|
+
return d;
|
2311
|
+
}
|
2312
|
+
update() {
|
2313
|
+
const e = this;
|
2314
|
+
if (!e || e.destroyed) return;
|
2315
|
+
const {
|
2316
|
+
snapGrid: i,
|
2317
|
+
params: s
|
2318
|
+
} = e;
|
2319
|
+
s.breakpoints && e.setBreakpoint(), [...e.el.querySelectorAll('[loading="lazy"]')].forEach((l) => {
|
2320
|
+
l.complete && Q(e, l);
|
2321
|
+
}), e.updateSize(), e.updateSlides(), e.updateProgress(), e.updateSlidesClasses();
|
2322
|
+
function n() {
|
2323
|
+
const l = e.rtlTranslate ? e.translate * -1 : e.translate, o = Math.min(Math.max(l, e.maxTranslate()), e.minTranslate());
|
2324
|
+
e.setTranslate(o), e.updateActiveIndex(), e.updateSlidesClasses();
|
2325
|
+
}
|
2326
|
+
let r;
|
2327
|
+
if (s.freeMode && s.freeMode.enabled && !s.cssMode)
|
2328
|
+
n(), s.autoHeight && e.updateAutoHeight();
|
2329
|
+
else {
|
2330
|
+
if ((s.slidesPerView === "auto" || s.slidesPerView > 1) && e.isEnd && !s.centeredSlides) {
|
2331
|
+
const l = e.virtual && s.virtual.enabled ? e.virtual.slides : e.slides;
|
2332
|
+
r = e.slideTo(l.length - 1, 0, !1, !0);
|
2333
|
+
} else
|
2334
|
+
r = e.slideTo(e.activeIndex, 0, !1, !0);
|
2335
|
+
r || n();
|
2336
|
+
}
|
2337
|
+
s.watchOverflow && i !== e.snapGrid && e.checkOverflow(), e.emit("update");
|
2338
|
+
}
|
2339
|
+
changeDirection(e, i) {
|
2340
|
+
i === void 0 && (i = !0);
|
2341
|
+
const s = this, n = s.params.direction;
|
2342
|
+
return e || (e = n === "horizontal" ? "vertical" : "horizontal"), e === n || e !== "horizontal" && e !== "vertical" || (s.el.classList.remove(`${s.params.containerModifierClass}${n}`), s.el.classList.add(`${s.params.containerModifierClass}${e}`), s.emitContainerClasses(), s.params.direction = e, s.slides.forEach((r) => {
|
2343
|
+
e === "vertical" ? r.style.width = "" : r.style.height = "";
|
2344
|
+
}), s.emit("changeDirection"), i && s.update()), s;
|
2345
|
+
}
|
2346
|
+
changeLanguageDirection(e) {
|
2347
|
+
const i = this;
|
2348
|
+
i.rtl && e === "rtl" || !i.rtl && e === "ltr" || (i.rtl = e === "rtl", i.rtlTranslate = i.params.direction === "horizontal" && i.rtl, i.rtl ? (i.el.classList.add(`${i.params.containerModifierClass}rtl`), i.el.dir = "rtl") : (i.el.classList.remove(`${i.params.containerModifierClass}rtl`), i.el.dir = "ltr"), i.update());
|
2349
|
+
}
|
2350
|
+
mount(e) {
|
2351
|
+
const i = this;
|
2352
|
+
if (i.mounted) return !0;
|
2353
|
+
let s = e || i.params.el;
|
2354
|
+
if (typeof s == "string" && (s = document.querySelector(s)), !s)
|
2355
|
+
return !1;
|
2356
|
+
s.swiper = i, s.parentNode && s.parentNode.host && s.parentNode.host.nodeName === i.params.swiperElementNodeName.toUpperCase() && (i.isElement = !0);
|
2357
|
+
const n = () => `.${(i.params.wrapperClass || "").trim().split(" ").join(".")}`;
|
2358
|
+
let l = s && s.shadowRoot && s.shadowRoot.querySelector ? s.shadowRoot.querySelector(n()) : H(s, n())[0];
|
2359
|
+
return !l && i.params.createElements && (l = fe("div", i.params.wrapperClass), s.append(l), H(s, `.${i.params.slideClass}`).forEach((o) => {
|
2360
|
+
l.append(o);
|
2361
|
+
})), Object.assign(i, {
|
2362
|
+
el: s,
|
2363
|
+
wrapperEl: l,
|
2364
|
+
slidesEl: i.isElement && !s.parentNode.host.slideSlots ? s.parentNode.host : l,
|
2365
|
+
hostEl: i.isElement ? s.parentNode.host : s,
|
2366
|
+
mounted: !0,
|
2367
|
+
// RTL
|
2368
|
+
rtl: s.dir.toLowerCase() === "rtl" || k(s, "direction") === "rtl",
|
2369
|
+
rtlTranslate: i.params.direction === "horizontal" && (s.dir.toLowerCase() === "rtl" || k(s, "direction") === "rtl"),
|
2370
|
+
wrongRTL: k(l, "display") === "-webkit-box"
|
2371
|
+
}), !0;
|
2372
|
+
}
|
2373
|
+
init(e) {
|
2374
|
+
const i = this;
|
2375
|
+
if (i.initialized || i.mount(e) === !1) return i;
|
2376
|
+
i.emit("beforeInit"), i.params.breakpoints && i.setBreakpoint(), i.addClasses(), i.updateSize(), i.updateSlides(), i.params.watchOverflow && i.checkOverflow(), i.params.grabCursor && i.enabled && i.setGrabCursor(), i.params.loop && i.virtual && i.params.virtual.enabled ? i.slideTo(i.params.initialSlide + i.virtual.slidesBefore, 0, i.params.runCallbacksOnInit, !1, !0) : i.slideTo(i.params.initialSlide, 0, i.params.runCallbacksOnInit, !1, !0), i.params.loop && i.loopCreate(), i.attachEvents();
|
2377
|
+
const n = [...i.el.querySelectorAll('[loading="lazy"]')];
|
2378
|
+
return i.isElement && n.push(...i.hostEl.querySelectorAll('[loading="lazy"]')), n.forEach((r) => {
|
2379
|
+
r.complete ? Q(i, r) : r.addEventListener("load", (l) => {
|
2380
|
+
Q(i, l.target);
|
2381
|
+
});
|
2382
|
+
}), pe(i), i.initialized = !0, pe(i), i.emit("init"), i.emit("afterInit"), i;
|
2383
|
+
}
|
2384
|
+
destroy(e, i) {
|
2385
|
+
e === void 0 && (e = !0), i === void 0 && (i = !0);
|
2386
|
+
const s = this, {
|
2387
|
+
params: n,
|
2388
|
+
el: r,
|
2389
|
+
wrapperEl: l,
|
2390
|
+
slides: o
|
2391
|
+
} = s;
|
2392
|
+
return typeof s.params > "u" || s.destroyed || (s.emit("beforeDestroy"), s.initialized = !1, s.detachEvents(), n.loop && s.loopDestroy(), i && (s.removeClasses(), r && typeof r != "string" && r.removeAttribute("style"), l && l.removeAttribute("style"), o && o.length && o.forEach((a) => {
|
2393
|
+
a.classList.remove(n.slideVisibleClass, n.slideFullyVisibleClass, n.slideActiveClass, n.slideNextClass, n.slidePrevClass), a.removeAttribute("style"), a.removeAttribute("data-swiper-slide-index");
|
2394
|
+
})), s.emit("destroy"), Object.keys(s.eventsListeners).forEach((a) => {
|
2395
|
+
s.off(a);
|
2396
|
+
}), e !== !1 && (s.el && typeof s.el != "string" && (s.el.swiper = null), je(s)), s.destroyed = !0), null;
|
2397
|
+
}
|
2398
|
+
static extendDefaults(e) {
|
2399
|
+
N(de, e);
|
2400
|
+
}
|
2401
|
+
static get extendedDefaults() {
|
2402
|
+
return de;
|
2403
|
+
}
|
2404
|
+
static get defaults() {
|
2405
|
+
return me;
|
2406
|
+
}
|
2407
|
+
static installModule(e) {
|
2408
|
+
$.prototype.__modules__ || ($.prototype.__modules__ = []);
|
2409
|
+
const i = $.prototype.__modules__;
|
2410
|
+
typeof e == "function" && i.indexOf(e) < 0 && i.push(e);
|
2411
|
+
}
|
2412
|
+
static use(e) {
|
2413
|
+
return Array.isArray(e) ? (e.forEach((i) => $.installModule(i)), $) : ($.installModule(e), $);
|
2414
|
+
}
|
2415
|
+
};
|
2416
|
+
Object.keys(oe).forEach((t) => {
|
2417
|
+
Object.keys(oe[t]).forEach((e) => {
|
2418
|
+
ge.prototype[e] = oe[t][e];
|
2419
|
+
});
|
2420
|
+
});
|
2421
|
+
ge.use([it, st]);
|
2422
|
+
const _e = [
|
2423
|
+
"eventsPrefix",
|
2424
|
+
"injectStyles",
|
2425
|
+
"injectStylesUrls",
|
2426
|
+
"modules",
|
2427
|
+
"init",
|
2428
|
+
"_direction",
|
2429
|
+
"oneWayMovement",
|
2430
|
+
"swiperElementNodeName",
|
2431
|
+
"touchEventsTarget",
|
2432
|
+
"initialSlide",
|
2433
|
+
"_speed",
|
2434
|
+
"cssMode",
|
2435
|
+
"updateOnWindowResize",
|
2436
|
+
"resizeObserver",
|
2437
|
+
"nested",
|
2438
|
+
"focusableElements",
|
2439
|
+
"_enabled",
|
2440
|
+
"_width",
|
2441
|
+
"_height",
|
2442
|
+
"preventInteractionOnTransition",
|
2443
|
+
"userAgent",
|
2444
|
+
"url",
|
2445
|
+
"_edgeSwipeDetection",
|
2446
|
+
"_edgeSwipeThreshold",
|
2447
|
+
"_freeMode",
|
2448
|
+
"_autoHeight",
|
2449
|
+
"setWrapperSize",
|
2450
|
+
"virtualTranslate",
|
2451
|
+
"_effect",
|
2452
|
+
"breakpoints",
|
2453
|
+
"breakpointsBase",
|
2454
|
+
"_spaceBetween",
|
2455
|
+
"_slidesPerView",
|
2456
|
+
"maxBackfaceHiddenSlides",
|
2457
|
+
"_grid",
|
2458
|
+
"_slidesPerGroup",
|
2459
|
+
"_slidesPerGroupSkip",
|
2460
|
+
"_slidesPerGroupAuto",
|
2461
|
+
"_centeredSlides",
|
2462
|
+
"_centeredSlidesBounds",
|
2463
|
+
"_slidesOffsetBefore",
|
2464
|
+
"_slidesOffsetAfter",
|
2465
|
+
"normalizeSlideIndex",
|
2466
|
+
"_centerInsufficientSlides",
|
2467
|
+
"_watchOverflow",
|
2468
|
+
"roundLengths",
|
2469
|
+
"touchRatio",
|
2470
|
+
"touchAngle",
|
2471
|
+
"simulateTouch",
|
2472
|
+
"_shortSwipes",
|
2473
|
+
"_longSwipes",
|
2474
|
+
"longSwipesRatio",
|
2475
|
+
"longSwipesMs",
|
2476
|
+
"_followFinger",
|
2477
|
+
"allowTouchMove",
|
2478
|
+
"_threshold",
|
2479
|
+
"touchMoveStopPropagation",
|
2480
|
+
"touchStartPreventDefault",
|
2481
|
+
"touchStartForcePreventDefault",
|
2482
|
+
"touchReleaseOnEdges",
|
2483
|
+
"uniqueNavElements",
|
2484
|
+
"_resistance",
|
2485
|
+
"_resistanceRatio",
|
2486
|
+
"_watchSlidesProgress",
|
2487
|
+
"_grabCursor",
|
2488
|
+
"preventClicks",
|
2489
|
+
"preventClicksPropagation",
|
2490
|
+
"_slideToClickedSlide",
|
2491
|
+
"_loop",
|
2492
|
+
"loopAdditionalSlides",
|
2493
|
+
"loopAddBlankSlides",
|
2494
|
+
"loopPreventsSliding",
|
2495
|
+
"_rewind",
|
2496
|
+
"_allowSlidePrev",
|
2497
|
+
"_allowSlideNext",
|
2498
|
+
"_swipeHandler",
|
2499
|
+
"_noSwiping",
|
2500
|
+
"noSwipingClass",
|
2501
|
+
"noSwipingSelector",
|
2502
|
+
"passiveListeners",
|
2503
|
+
"containerModifierClass",
|
2504
|
+
"slideClass",
|
2505
|
+
"slideActiveClass",
|
2506
|
+
"slideVisibleClass",
|
2507
|
+
"slideFullyVisibleClass",
|
2508
|
+
"slideNextClass",
|
2509
|
+
"slidePrevClass",
|
2510
|
+
"slideBlankClass",
|
2511
|
+
"wrapperClass",
|
2512
|
+
"lazyPreloaderClass",
|
2513
|
+
"lazyPreloadPrevNext",
|
2514
|
+
"runCallbacksOnInit",
|
2515
|
+
"observer",
|
2516
|
+
"observeParents",
|
2517
|
+
"observeSlideChildren",
|
2518
|
+
// modules
|
2519
|
+
"a11y",
|
2520
|
+
"_autoplay",
|
2521
|
+
"_controller",
|
2522
|
+
"coverflowEffect",
|
2523
|
+
"cubeEffect",
|
2524
|
+
"fadeEffect",
|
2525
|
+
"flipEffect",
|
2526
|
+
"creativeEffect",
|
2527
|
+
"cardsEffect",
|
2528
|
+
"hashNavigation",
|
2529
|
+
"history",
|
2530
|
+
"keyboard",
|
2531
|
+
"mousewheel",
|
2532
|
+
"_navigation",
|
2533
|
+
"_pagination",
|
2534
|
+
"parallax",
|
2535
|
+
"_scrollbar",
|
2536
|
+
"_thumbs",
|
2537
|
+
"virtual",
|
2538
|
+
"zoom",
|
2539
|
+
"control"
|
2540
|
+
];
|
2541
|
+
function j(t) {
|
2542
|
+
return typeof t == "object" && t !== null && t.constructor && Object.prototype.toString.call(t).slice(8, -1) === "Object" && !t.__swiper__;
|
2543
|
+
}
|
2544
|
+
function q(t, e) {
|
2545
|
+
const i = ["__proto__", "constructor", "prototype"];
|
2546
|
+
Object.keys(e).filter((s) => i.indexOf(s) < 0).forEach((s) => {
|
2547
|
+
typeof t[s] > "u" ? t[s] = e[s] : j(e[s]) && j(t[s]) && Object.keys(e[s]).length > 0 ? e[s].__swiper__ ? t[s] = e[s] : q(t[s], e[s]) : t[s] = e[s];
|
2548
|
+
});
|
2549
|
+
}
|
2550
|
+
function De(t) {
|
2551
|
+
return t === void 0 && (t = {}), t.navigation && typeof t.navigation.nextEl > "u" && typeof t.navigation.prevEl > "u";
|
2552
|
+
}
|
2553
|
+
function Ge(t) {
|
2554
|
+
return t === void 0 && (t = {}), t.pagination && typeof t.pagination.el > "u";
|
2555
|
+
}
|
2556
|
+
function Ve(t) {
|
2557
|
+
return t === void 0 && (t = {}), t.scrollbar && typeof t.scrollbar.el > "u";
|
2558
|
+
}
|
2559
|
+
function Ne(t) {
|
2560
|
+
t === void 0 && (t = "");
|
2561
|
+
const e = t.split(" ").map((s) => s.trim()).filter((s) => !!s), i = [];
|
2562
|
+
return e.forEach((s) => {
|
2563
|
+
i.indexOf(s) < 0 && i.push(s);
|
2564
|
+
}), i.join(" ");
|
2565
|
+
}
|
2566
|
+
function oi(t) {
|
2567
|
+
return t === void 0 && (t = ""), t ? t.includes("swiper-wrapper") ? t : `swiper-wrapper ${t}` : "swiper-wrapper";
|
2568
|
+
}
|
2569
|
+
function di(t) {
|
2570
|
+
let {
|
2571
|
+
swiper: e,
|
2572
|
+
slides: i,
|
2573
|
+
passedParams: s,
|
2574
|
+
changedParams: n,
|
2575
|
+
nextEl: r,
|
2576
|
+
prevEl: l,
|
2577
|
+
scrollbarEl: o,
|
2578
|
+
paginationEl: a
|
2579
|
+
} = t;
|
2580
|
+
const u = n.filter((x) => x !== "children" && x !== "direction" && x !== "wrapperClass"), {
|
2581
|
+
params: d,
|
2582
|
+
pagination: c,
|
2583
|
+
navigation: p,
|
2584
|
+
scrollbar: f,
|
2585
|
+
virtual: h,
|
2586
|
+
thumbs: v
|
2587
|
+
} = e;
|
2588
|
+
let y, m, b, g, S, T, I, _;
|
2589
|
+
n.includes("thumbs") && s.thumbs && s.thumbs.swiper && d.thumbs && !d.thumbs.swiper && (y = !0), n.includes("controller") && s.controller && s.controller.control && d.controller && !d.controller.control && (m = !0), n.includes("pagination") && s.pagination && (s.pagination.el || a) && (d.pagination || d.pagination === !1) && c && !c.el && (b = !0), n.includes("scrollbar") && s.scrollbar && (s.scrollbar.el || o) && (d.scrollbar || d.scrollbar === !1) && f && !f.el && (g = !0), n.includes("navigation") && s.navigation && (s.navigation.prevEl || l) && (s.navigation.nextEl || r) && (d.navigation || d.navigation === !1) && p && !p.prevEl && !p.nextEl && (S = !0);
|
2590
|
+
const C = (x) => {
|
2591
|
+
e[x] && (e[x].destroy(), x === "navigation" ? (e.isElement && (e[x].prevEl.remove(), e[x].nextEl.remove()), d[x].prevEl = void 0, d[x].nextEl = void 0, e[x].prevEl = void 0, e[x].nextEl = void 0) : (e.isElement && e[x].el.remove(), d[x].el = void 0, e[x].el = void 0));
|
2592
|
+
};
|
2593
|
+
n.includes("loop") && e.isElement && (d.loop && !s.loop ? T = !0 : !d.loop && s.loop ? I = !0 : _ = !0), u.forEach((x) => {
|
2594
|
+
if (j(d[x]) && j(s[x]))
|
2595
|
+
Object.assign(d[x], s[x]), (x === "navigation" || x === "pagination" || x === "scrollbar") && "enabled" in s[x] && !s[x].enabled && C(x);
|
2596
|
+
else {
|
2597
|
+
const w = s[x];
|
2598
|
+
(w === !0 || w === !1) && (x === "navigation" || x === "pagination" || x === "scrollbar") ? w === !1 && C(x) : d[x] = s[x];
|
2599
|
+
}
|
2600
|
+
}), u.includes("controller") && !m && e.controller && e.controller.control && d.controller && d.controller.control && (e.controller.control = d.controller.control), n.includes("children") && i && h && d.virtual.enabled ? (h.slides = i, h.update(!0)) : n.includes("virtual") && h && d.virtual.enabled && (i && (h.slides = i), h.update(!0)), n.includes("children") && i && d.loop && (_ = !0), y && v.init() && v.update(!0), m && (e.controller.control = d.controller.control), b && (e.isElement && (!a || typeof a == "string") && (a = document.createElement("div"), a.classList.add("swiper-pagination"), a.part.add("pagination"), e.el.appendChild(a)), a && (d.pagination.el = a), c.init(), c.render(), c.update()), g && (e.isElement && (!o || typeof o == "string") && (o = document.createElement("div"), o.classList.add("swiper-scrollbar"), o.part.add("scrollbar"), e.el.appendChild(o)), o && (d.scrollbar.el = o), f.init(), f.updateSize(), f.setTranslate()), S && (e.isElement && ((!r || typeof r == "string") && (r = document.createElement("div"), r.classList.add("swiper-button-next"), r.innerHTML = e.hostEl.constructor.nextButtonSvg, r.part.add("button-next"), e.el.appendChild(r)), (!l || typeof l == "string") && (l = document.createElement("div"), l.classList.add("swiper-button-prev"), l.innerHTML = e.hostEl.constructor.prevButtonSvg, l.part.add("button-prev"), e.el.appendChild(l))), r && (d.navigation.nextEl = r), l && (d.navigation.prevEl = l), p.init(), p.update()), n.includes("allowSlideNext") && (e.allowSlideNext = s.allowSlideNext), n.includes("allowSlidePrev") && (e.allowSlidePrev = s.allowSlidePrev), n.includes("direction") && e.changeDirection(s.direction, !1), (T || _) && e.loopDestroy(), (I || _) && e.loopCreate(), e.update();
|
2601
|
+
}
|
2602
|
+
function ci(t, e) {
|
2603
|
+
t === void 0 && (t = {}), e === void 0 && (e = !0);
|
2604
|
+
const i = {
|
2605
|
+
on: {}
|
2606
|
+
}, s = {}, n = {};
|
2607
|
+
q(i, me), i._emitClasses = !0, i.init = !1;
|
2608
|
+
const r = {}, l = _e.map((a) => a.replace(/_/, "")), o = Object.assign({}, t);
|
2609
|
+
return Object.keys(o).forEach((a) => {
|
2610
|
+
typeof t[a] > "u" || (l.indexOf(a) >= 0 ? j(t[a]) ? (i[a] = {}, n[a] = {}, q(i[a], t[a]), q(n[a], t[a])) : (i[a] = t[a], n[a] = t[a]) : a.search(/on[A-Z]/) === 0 && typeof t[a] == "function" ? e ? s[`${a[2].toLowerCase()}${a.substr(3)}`] = t[a] : i.on[`${a[2].toLowerCase()}${a.substr(3)}`] = t[a] : r[a] = t[a]);
|
2611
|
+
}), ["navigation", "pagination", "scrollbar"].forEach((a) => {
|
2612
|
+
i[a] === !0 && (i[a] = {}), i[a] === !1 && delete i[a];
|
2613
|
+
}), {
|
2614
|
+
params: i,
|
2615
|
+
passedParams: n,
|
2616
|
+
rest: r,
|
2617
|
+
events: s
|
2618
|
+
};
|
2619
|
+
}
|
2620
|
+
function ui(t, e) {
|
2621
|
+
let {
|
2622
|
+
el: i,
|
2623
|
+
nextEl: s,
|
2624
|
+
prevEl: n,
|
2625
|
+
paginationEl: r,
|
2626
|
+
scrollbarEl: l,
|
2627
|
+
swiper: o
|
2628
|
+
} = t;
|
2629
|
+
De(e) && s && n && (o.params.navigation.nextEl = s, o.originalParams.navigation.nextEl = s, o.params.navigation.prevEl = n, o.originalParams.navigation.prevEl = n), Ge(e) && r && (o.params.pagination.el = r, o.originalParams.pagination.el = r), Ve(e) && l && (o.params.scrollbar.el = l, o.originalParams.scrollbar.el = l), o.init(i);
|
2630
|
+
}
|
2631
|
+
function fi(t, e, i, s, n) {
|
2632
|
+
const r = [];
|
2633
|
+
if (!e) return r;
|
2634
|
+
const l = (a) => {
|
2635
|
+
r.indexOf(a) < 0 && r.push(a);
|
2636
|
+
};
|
2637
|
+
if (i && s) {
|
2638
|
+
const a = s.map(n), u = i.map(n);
|
2639
|
+
a.join("") !== u.join("") && l("children"), s.length !== i.length && l("children");
|
2640
|
+
}
|
2641
|
+
return _e.filter((a) => a[0] === "_").map((a) => a.replace(/_/, "")).forEach((a) => {
|
2642
|
+
if (a in t && a in e)
|
2643
|
+
if (j(t[a]) && j(e[a])) {
|
2644
|
+
const u = Object.keys(t[a]), d = Object.keys(e[a]);
|
2645
|
+
u.length !== d.length ? l(a) : (u.forEach((c) => {
|
2646
|
+
t[a][c] !== e[a][c] && l(a);
|
2647
|
+
}), d.forEach((c) => {
|
2648
|
+
t[a][c] !== e[a][c] && l(a);
|
2649
|
+
}));
|
2650
|
+
} else t[a] !== e[a] && l(a);
|
2651
|
+
}), r;
|
2652
|
+
}
|
2653
|
+
const pi = (t) => {
|
2654
|
+
!t || t.destroyed || !t.params.virtual || t.params.virtual && !t.params.virtual.enabled || (t.updateSlides(), t.updateProgress(), t.updateSlidesClasses(), t.parallax && t.params.parallax && t.params.parallax.enabled && t.parallax.setTranslate());
|
2655
|
+
};
|
2656
|
+
function ie() {
|
2657
|
+
return ie = Object.assign ? Object.assign.bind() : function(t) {
|
2658
|
+
for (var e = 1; e < arguments.length; e++) {
|
2659
|
+
var i = arguments[e];
|
2660
|
+
for (var s in i)
|
2661
|
+
Object.prototype.hasOwnProperty.call(i, s) && (t[s] = i[s]);
|
2662
|
+
}
|
2663
|
+
return t;
|
2664
|
+
}, ie.apply(this, arguments);
|
2665
|
+
}
|
2666
|
+
function Be(t) {
|
2667
|
+
return t.type && t.type.displayName && t.type.displayName.includes("SwiperSlide");
|
2668
|
+
}
|
2669
|
+
function Fe(t) {
|
2670
|
+
const e = [];
|
2671
|
+
return G.Children.toArray(t).forEach((i) => {
|
2672
|
+
Be(i) ? e.push(i) : i.props && i.props.children && Fe(i.props.children).forEach((s) => e.push(s));
|
2673
|
+
}), e;
|
2674
|
+
}
|
2675
|
+
function mi(t) {
|
2676
|
+
const e = [], i = {
|
2677
|
+
"container-start": [],
|
2678
|
+
"container-end": [],
|
2679
|
+
"wrapper-start": [],
|
2680
|
+
"wrapper-end": []
|
2681
|
+
};
|
2682
|
+
return G.Children.toArray(t).forEach((s) => {
|
2683
|
+
if (Be(s))
|
2684
|
+
e.push(s);
|
2685
|
+
else if (s.props && s.props.slot && i[s.props.slot])
|
2686
|
+
i[s.props.slot].push(s);
|
2687
|
+
else if (s.props && s.props.children) {
|
2688
|
+
const n = Fe(s.props.children);
|
2689
|
+
n.length > 0 ? n.forEach((r) => e.push(r)) : i["container-end"].push(s);
|
2690
|
+
} else
|
2691
|
+
i["container-end"].push(s);
|
2692
|
+
}), {
|
2693
|
+
slides: e,
|
2694
|
+
slots: i
|
2695
|
+
};
|
2696
|
+
}
|
2697
|
+
function hi(t, e, i) {
|
2698
|
+
if (!i) return null;
|
2699
|
+
const s = (d) => {
|
2700
|
+
let c = d;
|
2701
|
+
return d < 0 ? c = e.length + d : c >= e.length && (c = c - e.length), c;
|
2702
|
+
}, n = t.isHorizontal() ? {
|
2703
|
+
[t.rtlTranslate ? "right" : "left"]: `${i.offset}px`
|
2704
|
+
} : {
|
2705
|
+
top: `${i.offset}px`
|
2706
|
+
}, {
|
2707
|
+
from: r,
|
2708
|
+
to: l
|
2709
|
+
} = i, o = t.params.loop ? -e.length : 0, a = t.params.loop ? e.length * 2 : e.length, u = [];
|
2710
|
+
for (let d = o; d < a; d += 1)
|
2711
|
+
d >= r && d <= l && u.push(e[s(d)]);
|
2712
|
+
return u.map((d, c) => /* @__PURE__ */ G.cloneElement(d, {
|
2713
|
+
swiper: t,
|
2714
|
+
style: n,
|
2715
|
+
key: d.props.virtualIndex || d.key || `slide-${c}`
|
2716
|
+
}));
|
2717
|
+
}
|
2718
|
+
function K(t, e) {
|
2719
|
+
return typeof window > "u" ? ce(t, e) : He(t, e);
|
2720
|
+
}
|
2721
|
+
const Ee = /* @__PURE__ */ Me(null), Re = /* @__PURE__ */ Me(null), yi = () => $e(Re), gi = /* @__PURE__ */ Pe(function(t, e) {
|
2722
|
+
let {
|
2723
|
+
className: i,
|
2724
|
+
tag: s = "div",
|
2725
|
+
wrapperTag: n = "div",
|
2726
|
+
children: r,
|
2727
|
+
onSwiper: l,
|
2728
|
+
...o
|
2729
|
+
} = t === void 0 ? {} : t, a = !1;
|
2730
|
+
const [u, d] = X("swiper"), [c, p] = X(null), [f, h] = X(!1), v = F(!1), y = F(null), m = F(null), b = F(null), g = F(null), S = F(null), T = F(null), I = F(null), _ = F(null), {
|
2731
|
+
params: C,
|
2732
|
+
passedParams: x,
|
2733
|
+
rest: w,
|
2734
|
+
events: E
|
2735
|
+
} = ci(o), {
|
2736
|
+
slides: M,
|
2737
|
+
slots: P
|
2738
|
+
} = mi(r), O = () => {
|
2739
|
+
h(!f);
|
2740
|
+
};
|
2741
|
+
Object.assign(C.on, {
|
2742
|
+
_containerClasses(z, A) {
|
2743
|
+
d(A);
|
2744
|
+
}
|
2745
|
+
});
|
2746
|
+
const D = () => {
|
2747
|
+
Object.assign(C.on, E), a = !0;
|
2748
|
+
const z = {
|
2749
|
+
...C
|
2750
|
+
};
|
2751
|
+
if (delete z.wrapperClass, m.current = new ge(z), m.current.virtual && m.current.params.virtual.enabled) {
|
2752
|
+
m.current.virtual.slides = M;
|
2753
|
+
const A = {
|
2754
|
+
cache: !1,
|
2755
|
+
slides: M,
|
2756
|
+
renderExternal: p,
|
2757
|
+
renderExternalUpdate: !1
|
2758
|
+
};
|
2759
|
+
q(m.current.params.virtual, A), q(m.current.originalParams.virtual, A);
|
2760
|
+
}
|
2761
|
+
};
|
2762
|
+
y.current || D(), m.current && m.current.on("_beforeBreakpoint", O);
|
2763
|
+
const B = () => {
|
2764
|
+
a || !E || !m.current || Object.keys(E).forEach((z) => {
|
2765
|
+
m.current.on(z, E[z]);
|
2766
|
+
});
|
2767
|
+
}, Y = () => {
|
2768
|
+
!E || !m.current || Object.keys(E).forEach((z) => {
|
2769
|
+
m.current.off(z, E[z]);
|
2770
|
+
});
|
2771
|
+
};
|
2772
|
+
ce(() => () => {
|
2773
|
+
m.current && m.current.off("_beforeBreakpoint", O);
|
2774
|
+
}), ce(() => {
|
2775
|
+
!v.current && m.current && (m.current.emitSlidesClasses(), v.current = !0);
|
2776
|
+
}), K(() => {
|
2777
|
+
if (e && (e.current = y.current), !!y.current)
|
2778
|
+
return m.current.destroyed && D(), ui({
|
2779
|
+
el: y.current,
|
2780
|
+
nextEl: S.current,
|
2781
|
+
prevEl: T.current,
|
2782
|
+
paginationEl: I.current,
|
2783
|
+
scrollbarEl: _.current,
|
2784
|
+
swiper: m.current
|
2785
|
+
}, C), l && !m.current.destroyed && l(m.current), () => {
|
2786
|
+
m.current && !m.current.destroyed && m.current.destroy(!0, !1);
|
2787
|
+
};
|
2788
|
+
}, []), K(() => {
|
2789
|
+
B();
|
2790
|
+
const z = fi(x, b.current, M, g.current, (A) => A.key);
|
2791
|
+
return b.current = x, g.current = M, z.length && m.current && !m.current.destroyed && di({
|
2792
|
+
swiper: m.current,
|
2793
|
+
slides: M,
|
2794
|
+
passedParams: x,
|
2795
|
+
changedParams: z,
|
2796
|
+
nextEl: S.current,
|
2797
|
+
prevEl: T.current,
|
2798
|
+
scrollbarEl: _.current,
|
2799
|
+
paginationEl: I.current
|
2800
|
+
}), () => {
|
2801
|
+
Y();
|
2802
|
+
};
|
2803
|
+
}), K(() => {
|
2804
|
+
pi(m.current);
|
2805
|
+
}, [c]);
|
2806
|
+
function L() {
|
2807
|
+
return C.virtual ? hi(m.current, M, c) : M.map((z, A) => /* @__PURE__ */ G.cloneElement(z, {
|
2808
|
+
swiper: m.current,
|
2809
|
+
swiperSlideIndex: A
|
2810
|
+
}));
|
2811
|
+
}
|
2812
|
+
return /* @__PURE__ */ G.createElement(s, ie({
|
2813
|
+
ref: y,
|
2814
|
+
className: Ne(`${u}${i ? ` ${i}` : ""}`)
|
2815
|
+
}, w), /* @__PURE__ */ G.createElement(Re.Provider, {
|
2816
|
+
value: m.current
|
2817
|
+
}, P["container-start"], /* @__PURE__ */ G.createElement(n, {
|
2818
|
+
className: oi(C.wrapperClass)
|
2819
|
+
}, P["wrapper-start"], L(), P["wrapper-end"]), De(C) && /* @__PURE__ */ G.createElement(G.Fragment, null, /* @__PURE__ */ G.createElement("div", {
|
2820
|
+
ref: T,
|
2821
|
+
className: "swiper-button-prev"
|
2822
|
+
}), /* @__PURE__ */ G.createElement("div", {
|
2823
|
+
ref: S,
|
2824
|
+
className: "swiper-button-next"
|
2825
|
+
})), Ve(C) && /* @__PURE__ */ G.createElement("div", {
|
2826
|
+
ref: _,
|
2827
|
+
className: "swiper-scrollbar"
|
2828
|
+
}), Ge(C) && /* @__PURE__ */ G.createElement("div", {
|
2829
|
+
ref: I,
|
2830
|
+
className: "swiper-pagination"
|
2831
|
+
}), P["container-end"]));
|
2832
|
+
});
|
2833
|
+
gi.displayName = "Swiper";
|
2834
|
+
const vi = /* @__PURE__ */ Pe(function(t, e) {
|
2835
|
+
let {
|
2836
|
+
tag: i = "div",
|
2837
|
+
children: s,
|
2838
|
+
className: n = "",
|
2839
|
+
swiper: r,
|
2840
|
+
zoom: l,
|
2841
|
+
lazy: o,
|
2842
|
+
virtualIndex: a,
|
2843
|
+
swiperSlideIndex: u,
|
2844
|
+
...d
|
2845
|
+
} = t === void 0 ? {} : t;
|
2846
|
+
const c = F(null), [p, f] = X("swiper-slide"), [h, v] = X(!1);
|
2847
|
+
function y(S, T, I) {
|
2848
|
+
T === c.current && f(I);
|
2849
|
+
}
|
2850
|
+
K(() => {
|
2851
|
+
if (typeof u < "u" && (c.current.swiperSlideIndex = u), e && (e.current = c.current), !(!c.current || !r)) {
|
2852
|
+
if (r.destroyed) {
|
2853
|
+
p !== "swiper-slide" && f("swiper-slide");
|
2854
|
+
return;
|
2855
|
+
}
|
2856
|
+
return r.on("_slideClass", y), () => {
|
2857
|
+
r && r.off("_slideClass", y);
|
2858
|
+
};
|
2859
|
+
}
|
2860
|
+
}), K(() => {
|
2861
|
+
r && c.current && !r.destroyed && f(r.getSlideClasses(c.current));
|
2862
|
+
}, [r]);
|
2863
|
+
const m = {
|
2864
|
+
isActive: p.indexOf("swiper-slide-active") >= 0,
|
2865
|
+
isVisible: p.indexOf("swiper-slide-visible") >= 0,
|
2866
|
+
isPrev: p.indexOf("swiper-slide-prev") >= 0,
|
2867
|
+
isNext: p.indexOf("swiper-slide-next") >= 0
|
2868
|
+
}, b = () => typeof s == "function" ? s(m) : s, g = () => {
|
2869
|
+
v(!0);
|
2870
|
+
};
|
2871
|
+
return /* @__PURE__ */ G.createElement(i, ie({
|
2872
|
+
ref: c,
|
2873
|
+
className: Ne(`${p}${n ? ` ${n}` : ""}`),
|
2874
|
+
"data-swiper-slide-index": a,
|
2875
|
+
onLoad: g
|
2876
|
+
}, d), l && /* @__PURE__ */ G.createElement(Ee.Provider, {
|
2877
|
+
value: m
|
2878
|
+
}, /* @__PURE__ */ G.createElement("div", {
|
2879
|
+
className: "swiper-zoom-container",
|
2880
|
+
"data-swiper-zoom": typeof l == "number" ? l : void 0
|
2881
|
+
}, b(), o && !h && /* @__PURE__ */ G.createElement("div", {
|
2882
|
+
className: "swiper-lazy-preloader"
|
2883
|
+
}))), !l && /* @__PURE__ */ G.createElement(Ee.Provider, {
|
2884
|
+
value: m
|
2885
|
+
}, b(), o && !h && /* @__PURE__ */ G.createElement("div", {
|
2886
|
+
className: "swiper-lazy-preloader"
|
2887
|
+
})));
|
2888
|
+
});
|
2889
|
+
vi.displayName = "SwiperSlide";
|
2890
|
+
export {
|
2891
|
+
Ti as A,
|
2892
|
+
gi as S,
|
2893
|
+
vi as a,
|
2894
|
+
V as b,
|
2895
|
+
Si as c,
|
2896
|
+
ee as d,
|
2897
|
+
Ze as e,
|
2898
|
+
R as g,
|
2899
|
+
ue as n,
|
2900
|
+
yi as u
|
2901
|
+
};
|