@streamlayer/react 1.21.3 → 1.22.1
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/lib/app/masters.d.ts +2 -5
- package/lib/app/pause-ad.d.ts +1 -10
- package/lib/app/useStreamLayerApp.d.ts +1 -23
- package/lib/cjs/Question.js +1 -0
- package/lib/cjs/advertisement.js +40 -40
- package/lib/cjs/analytics.js +1 -0
- package/lib/cjs/auth.js +1 -1
- package/lib/cjs/bet-pack.js +1 -1
- package/lib/cjs/gamification-feature.js +1 -1
- package/lib/cjs/hooks-B0Qttldg.js +1 -0
- package/lib/cjs/index-DSi8Qgfs.js +1 -0
- package/lib/cjs/index.js +1 -1
- package/lib/cjs/index10.js +1 -0
- package/lib/cjs/index11.js +4 -0
- package/lib/cjs/index12.js +1 -0
- package/lib/cjs/index13.js +1 -0
- package/lib/cjs/index14.js +1 -0
- package/lib/cjs/index15.js +1 -0
- package/lib/cjs/index16.js +5 -0
- package/lib/cjs/index2.js +1 -5
- package/lib/cjs/index3.js +1 -0
- package/lib/cjs/index4.js +5 -0
- package/lib/cjs/index5.js +1 -0
- package/lib/cjs/index6.js +1 -0
- package/lib/cjs/index7.js +5 -0
- package/lib/cjs/index8.js +1 -0
- package/lib/cjs/index9.js +1 -0
- package/lib/cjs/insight.js +1 -1
- package/lib/cjs/masters.js +1 -1
- package/lib/cjs/masters2.js +6 -6
- package/lib/cjs/notification.js +1 -1
- package/lib/cjs/pause-ad.js +1 -1
- package/lib/cjs/points.js +1 -1
- package/lib/cjs/sl-types.js +15 -0
- package/lib/cjs/storage.js +1 -0
- package/lib/cjs/theme.js +17 -0
- package/lib/cjs/useStreamLayerApp.js +1 -1
- package/lib/cjs/useStreamLayerApp2.js +17 -16
- package/lib/cjs/utils.js +47 -0
- package/lib/cjs/vast-client.min.js +1 -0
- package/lib/classic/app/masters.d.ts +2 -5
- package/lib/classic/app/pause-ad.d.ts +1 -10
- package/lib/classic/app/useStreamLayerApp.d.ts +1 -23
- package/lib/classic/cjs/Question.js +1 -0
- package/lib/classic/cjs/advertisement.js +40 -40
- package/lib/classic/cjs/analytics.js +1 -0
- package/lib/classic/cjs/auth.js +1 -1
- package/lib/classic/cjs/bet-pack.js +4 -4
- package/lib/classic/cjs/gamification-feature.js +1 -1
- package/lib/classic/cjs/hooks-B0Qttldg.js +1 -0
- package/lib/classic/cjs/index-DSi8Qgfs.js +1 -0
- package/lib/classic/cjs/index.js +1 -1
- package/lib/classic/cjs/index10.js +1 -0
- package/lib/classic/cjs/index11.js +1 -0
- package/lib/classic/cjs/index12.js +1 -0
- package/lib/classic/cjs/index13.js +4 -0
- package/lib/classic/cjs/index2.js +5 -0
- package/lib/classic/cjs/index3.js +1 -0
- package/lib/classic/cjs/index4.js +1 -0
- package/lib/classic/cjs/index5.js +1 -0
- package/lib/classic/cjs/index6.js +5 -0
- package/lib/classic/cjs/index7.js +1 -0
- package/lib/classic/cjs/index8.js +1 -0
- package/lib/classic/cjs/index9.js +1 -0
- package/lib/classic/cjs/insight.js +1 -1
- package/lib/classic/cjs/notification.js +1 -1
- package/lib/classic/cjs/notification2.js +1 -0
- package/lib/classic/cjs/pause-ad.js +1 -1
- package/lib/classic/cjs/points.js +1 -1
- package/lib/classic/cjs/sl-types.js +15 -0
- package/lib/classic/cjs/useStreamLayerApp.js +1 -1
- package/lib/classic/cjs/useStreamLayerApp2.js +17 -16
- package/lib/classic/cjs/utils.js +47 -0
- package/lib/classic/cjs/vast-client.min.js +1 -0
- package/lib/classic/es/Question.js +392 -0
- package/lib/classic/es/advertisement.js +10375 -10374
- package/lib/classic/es/analytics.js +28 -0
- package/lib/classic/es/auth.js +4 -4
- package/lib/classic/es/bet-pack.js +55 -51
- package/lib/classic/es/gamification-feature.js +1 -1
- package/lib/classic/es/hooks-B0Qttldg.js +98 -0
- package/lib/classic/es/index-DSi8Qgfs.js +65 -0
- package/lib/classic/es/index.js +14 -15
- package/lib/classic/es/index10.js +87 -0
- package/lib/classic/es/index11.js +2355 -0
- package/lib/classic/es/index12.js +183 -0
- package/lib/classic/es/index13.js +835 -0
- package/lib/classic/es/index2.js +2621 -0
- package/lib/classic/es/index3.js +64 -0
- package/lib/classic/es/index4.js +19 -0
- package/lib/classic/es/index5.js +285 -0
- package/lib/classic/es/{index-l-eyvmpL.js → index6.js} +937 -937
- package/lib/classic/es/index7.js +7 -0
- package/lib/classic/es/index8.js +11 -0
- package/lib/classic/es/index9.js +319 -0
- package/lib/classic/es/insight.js +31 -32
- package/lib/classic/es/notification.js +7 -1006
- package/lib/classic/es/notification2.js +1117 -0
- package/lib/classic/es/pause-ad.js +139 -138
- package/lib/classic/es/points.js +39 -38
- package/lib/classic/es/sl-types.js +258 -0
- package/lib/classic/es/useStreamLayerApp.js +1 -2
- package/lib/classic/es/useStreamLayerApp2.js +4798 -2735
- package/lib/classic/es/utils.js +76 -0
- package/lib/{es/vast-client.min-B0NUra1B.js → classic/es/vast-client.min.js} +338 -338
- package/lib/classic/index.d.ts +5 -13
- package/lib/classic/masters.d.ts +1 -1
- package/lib/dist/cjs/index.js +1 -1
- package/lib/dist/cjs/masters.js +34 -33
- package/lib/dist/es/index.js +2 -2
- package/lib/dist/es/masters.js +10563 -8870
- package/lib/dist/index.d.ts +1332 -0
- package/lib/dist/style.css +1 -1
- package/lib/es/Question.js +136 -0
- package/lib/es/advertisement.js +10375 -10374
- package/lib/es/analytics.js +28 -0
- package/lib/es/auth.js +4 -4
- package/lib/es/bet-pack.js +7 -6
- package/lib/es/gamification-feature.js +1 -1
- package/lib/es/hooks-B0Qttldg.js +98 -0
- package/lib/es/index-DSi8Qgfs.js +65 -0
- package/lib/es/index.js +13 -14
- package/lib/es/index10.js +267 -0
- package/lib/es/index11.js +835 -0
- package/lib/es/index12.js +183 -0
- package/lib/es/index13.js +319 -0
- package/lib/es/index14.js +87 -0
- package/lib/es/index15.js +2355 -0
- package/lib/es/index16.js +1254 -0
- package/lib/es/index2.js +1349 -3364
- package/lib/es/index3.js +64 -0
- package/lib/es/index4.js +3418 -0
- package/lib/es/index5.js +19 -0
- package/lib/es/index6.js +285 -0
- package/lib/es/{index-l-eyvmpL.js → index7.js} +937 -937
- package/lib/es/index8.js +7 -0
- package/lib/es/index9.js +11 -0
- package/lib/es/insight.js +31 -32
- package/lib/es/masters.js +6 -5
- package/lib/es/masters2.js +189 -176
- package/lib/es/notification.js +141 -136
- package/lib/es/pause-ad.js +140 -139
- package/lib/es/points.js +40 -38
- package/lib/es/sl-types.js +277 -0
- package/lib/es/storage.js +113 -0
- package/lib/es/theme.js +47 -0
- package/lib/es/useStreamLayerApp.js +1 -2
- package/lib/es/useStreamLayerApp2.js +4798 -2735
- package/lib/es/utils.js +76 -0
- package/lib/{classic/es/vast-client.min-B0NUra1B.js → es/vast-client.min.js} +338 -338
- package/lib/index.d.ts +5 -13
- package/lib/masters.d.ts +1 -1
- package/lib/style.css +1 -1
- package/package.json +16 -51
- package/lib/app/event.d.ts +0 -6
- package/lib/app/provider.d.ts +0 -49
- package/lib/cjs/index-l-eyvmpL.js +0 -5
- package/lib/cjs/provider.js +0 -84
- package/lib/cjs/vast-client.min-B0NUra1B.js +0 -1
- package/lib/classic/app/event.d.ts +0 -6
- package/lib/classic/app/provider.d.ts +0 -49
- package/lib/classic/cjs/index-l-eyvmpL.js +0 -5
- package/lib/classic/cjs/provider.js +0 -68
- package/lib/classic/cjs/vast-client.min-B0NUra1B.js +0 -1
- package/lib/classic/es/provider.js +0 -7619
- package/lib/dist/cjs/gamification-feature2.js +0 -1
- package/lib/dist/es/gamification-feature2.js +0 -285
- package/lib/es/provider.js +0 -7695
package/lib/es/index2.js
CHANGED
|
@@ -1,3415 +1,1400 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
import {
|
|
5
|
-
import
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
},
|
|
37
|
-
createEvent() {
|
|
38
|
-
return {
|
|
39
|
-
initEvent() {
|
|
40
|
-
}
|
|
41
|
-
};
|
|
42
|
-
},
|
|
43
|
-
createElement() {
|
|
44
|
-
return {
|
|
45
|
-
children: [],
|
|
46
|
-
childNodes: [],
|
|
47
|
-
style: {},
|
|
48
|
-
setAttribute() {
|
|
49
|
-
},
|
|
50
|
-
getElementsByTagName() {
|
|
51
|
-
return [];
|
|
52
|
-
}
|
|
53
|
-
};
|
|
54
|
-
},
|
|
55
|
-
createElementNS() {
|
|
56
|
-
return {};
|
|
57
|
-
},
|
|
58
|
-
importNode() {
|
|
59
|
-
return null;
|
|
60
|
-
},
|
|
61
|
-
location: {
|
|
62
|
-
hash: "",
|
|
63
|
-
host: "",
|
|
64
|
-
hostname: "",
|
|
65
|
-
href: "",
|
|
66
|
-
origin: "",
|
|
67
|
-
pathname: "",
|
|
68
|
-
protocol: "",
|
|
69
|
-
search: ""
|
|
70
|
-
}
|
|
71
|
-
};
|
|
72
|
-
function K() {
|
|
73
|
-
const t = typeof document < "u" ? document : {};
|
|
74
|
-
return Oe(t, We), t;
|
|
75
|
-
}
|
|
76
|
-
const Et = {
|
|
77
|
-
document: We,
|
|
78
|
-
navigator: {
|
|
79
|
-
userAgent: ""
|
|
80
|
-
},
|
|
81
|
-
location: {
|
|
82
|
-
hash: "",
|
|
83
|
-
host: "",
|
|
84
|
-
hostname: "",
|
|
85
|
-
href: "",
|
|
86
|
-
origin: "",
|
|
87
|
-
pathname: "",
|
|
88
|
-
protocol: "",
|
|
89
|
-
search: ""
|
|
90
|
-
},
|
|
91
|
-
history: {
|
|
92
|
-
replaceState() {
|
|
93
|
-
},
|
|
94
|
-
pushState() {
|
|
95
|
-
},
|
|
96
|
-
go() {
|
|
97
|
-
},
|
|
98
|
-
back() {
|
|
99
|
-
}
|
|
100
|
-
},
|
|
101
|
-
CustomEvent: function() {
|
|
102
|
-
return this;
|
|
103
|
-
},
|
|
104
|
-
addEventListener() {
|
|
105
|
-
},
|
|
106
|
-
removeEventListener() {
|
|
107
|
-
},
|
|
108
|
-
getComputedStyle() {
|
|
109
|
-
return {
|
|
110
|
-
getPropertyValue() {
|
|
111
|
-
return "";
|
|
112
|
-
}
|
|
113
|
-
};
|
|
114
|
-
},
|
|
115
|
-
Image() {
|
|
116
|
-
},
|
|
117
|
-
Date() {
|
|
118
|
-
},
|
|
119
|
-
screen: {},
|
|
120
|
-
setTimeout() {
|
|
121
|
-
},
|
|
122
|
-
clearTimeout() {
|
|
123
|
-
},
|
|
124
|
-
matchMedia() {
|
|
125
|
-
return {};
|
|
126
|
-
},
|
|
127
|
-
requestAnimationFrame(t) {
|
|
128
|
-
return typeof setTimeout > "u" ? (t(), null) : setTimeout(t, 0);
|
|
129
|
-
},
|
|
130
|
-
cancelAnimationFrame(t) {
|
|
131
|
-
typeof setTimeout > "u" || clearTimeout(t);
|
|
132
|
-
}
|
|
133
|
-
};
|
|
134
|
-
function N() {
|
|
135
|
-
const t = typeof window < "u" ? window : {};
|
|
136
|
-
return Oe(t, Et), t;
|
|
137
|
-
}
|
|
138
|
-
function xt(t) {
|
|
139
|
-
return t === void 0 && (t = ""), t.trim().split(" ").filter((e) => !!e.trim());
|
|
140
|
-
}
|
|
141
|
-
function Tt(t) {
|
|
142
|
-
const e = t;
|
|
143
|
-
Object.keys(e).forEach((s) => {
|
|
144
|
-
try {
|
|
145
|
-
e[s] = null;
|
|
146
|
-
} catch {
|
|
147
|
-
}
|
|
148
|
-
try {
|
|
149
|
-
delete e[s];
|
|
150
|
-
} catch {
|
|
151
|
-
}
|
|
152
|
-
});
|
|
153
|
-
}
|
|
154
|
-
function xe(t, e) {
|
|
155
|
-
return e === void 0 && (e = 0), setTimeout(t, e);
|
|
156
|
-
}
|
|
157
|
-
function le() {
|
|
158
|
-
return Date.now();
|
|
159
|
-
}
|
|
160
|
-
function Ct(t) {
|
|
161
|
-
const e = N();
|
|
162
|
-
let s;
|
|
163
|
-
return e.getComputedStyle && (s = e.getComputedStyle(t, null)), !s && t.currentStyle && (s = t.currentStyle), s || (s = t.style), s;
|
|
164
|
-
}
|
|
165
|
-
function Pt(t, e) {
|
|
166
|
-
e === void 0 && (e = "x");
|
|
167
|
-
const s = N();
|
|
168
|
-
let r, n, i;
|
|
169
|
-
const l = Ct(t);
|
|
170
|
-
return s.WebKitCSSMatrix ? (n = l.transform || l.webkitTransform, n.split(",").length > 6 && (n = n.split(", ").map((a) => a.replace(",", ".")).join(", ")), i = new s.WebKitCSSMatrix(n === "none" ? "" : n)) : (i = l.MozTransform || l.OTransform || l.MsTransform || l.msTransform || l.transform || l.getPropertyValue("transform").replace("translate(", "matrix(1, 0, 0, 1,"), r = i.toString().split(",")), e === "x" && (s.WebKitCSSMatrix ? n = i.m41 : r.length === 16 ? n = parseFloat(r[12]) : n = parseFloat(r[4])), e === "y" && (s.WebKitCSSMatrix ? n = i.m42 : r.length === 16 ? n = parseFloat(r[13]) : n = parseFloat(r[5])), n || 0;
|
|
171
|
-
}
|
|
172
|
-
function se(t) {
|
|
173
|
-
return typeof t == "object" && t !== null && t.constructor && Object.prototype.toString.call(t).slice(8, -1) === "Object";
|
|
174
|
-
}
|
|
175
|
-
function Mt(t) {
|
|
176
|
-
return typeof window < "u" && typeof window.HTMLElement < "u" ? t instanceof HTMLElement : t && (t.nodeType === 1 || t.nodeType === 11);
|
|
177
|
-
}
|
|
178
|
-
function B() {
|
|
179
|
-
const t = Object(arguments.length <= 0 ? void 0 : arguments[0]), e = ["__proto__", "constructor", "prototype"];
|
|
180
|
-
for (let s = 1; s < arguments.length; s += 1) {
|
|
181
|
-
const r = s < 0 || arguments.length <= s ? void 0 : arguments[s];
|
|
182
|
-
if (r != null && !Mt(r)) {
|
|
183
|
-
const n = Object.keys(Object(r)).filter((i) => e.indexOf(i) < 0);
|
|
184
|
-
for (let i = 0, l = n.length; i < l; i += 1) {
|
|
185
|
-
const a = n[i], o = Object.getOwnPropertyDescriptor(r, a);
|
|
186
|
-
o !== void 0 && o.enumerable && (se(t[a]) && se(r[a]) ? r[a].__swiper__ ? t[a] = r[a] : B(t[a], r[a]) : !se(t[a]) && se(r[a]) ? (t[a] = {}, r[a].__swiper__ ? t[a] = r[a] : B(t[a], r[a])) : t[a] = r[a]);
|
|
187
|
-
}
|
|
188
|
-
}
|
|
189
|
-
}
|
|
190
|
-
return t;
|
|
191
|
-
}
|
|
192
|
-
function re(t, e, s) {
|
|
193
|
-
t.style.setProperty(e, s);
|
|
194
|
-
}
|
|
195
|
-
function Ye(t) {
|
|
196
|
-
let {
|
|
197
|
-
swiper: e,
|
|
198
|
-
targetPosition: s,
|
|
199
|
-
side: r
|
|
200
|
-
} = t;
|
|
201
|
-
const n = N(), i = -e.translate;
|
|
202
|
-
let l = null, a;
|
|
203
|
-
const o = e.params.speed;
|
|
204
|
-
e.wrapperEl.style.scrollSnapType = "none", n.cancelAnimationFrame(e.cssModeFrameID);
|
|
205
|
-
const c = s > i ? "next" : "prev", d = (f, g) => c === "next" && f >= g || c === "prev" && f <= g, u = () => {
|
|
206
|
-
a = (/* @__PURE__ */ new Date()).getTime(), l === null && (l = a);
|
|
207
|
-
const f = Math.max(Math.min((a - l) / o, 1), 0), g = 0.5 - Math.cos(f * Math.PI) / 2;
|
|
208
|
-
let h = i + g * (s - i);
|
|
209
|
-
if (d(h, s) && (h = s), e.wrapperEl.scrollTo({
|
|
210
|
-
[r]: h
|
|
211
|
-
}), d(h, s)) {
|
|
212
|
-
e.wrapperEl.style.overflow = "hidden", e.wrapperEl.style.scrollSnapType = "", setTimeout(() => {
|
|
213
|
-
e.wrapperEl.style.overflow = "", e.wrapperEl.scrollTo({
|
|
214
|
-
[r]: h
|
|
215
|
-
});
|
|
216
|
-
}), n.cancelAnimationFrame(e.cssModeFrameID);
|
|
217
|
-
return;
|
|
218
|
-
}
|
|
219
|
-
e.cssModeFrameID = n.requestAnimationFrame(u);
|
|
220
|
-
};
|
|
221
|
-
u();
|
|
222
|
-
}
|
|
223
|
-
function H(t, e) {
|
|
224
|
-
e === void 0 && (e = "");
|
|
225
|
-
const s = N(), r = [...t.children];
|
|
226
|
-
return s.HTMLSlotElement && t instanceof HTMLSlotElement && r.push(...t.assignedElements()), e ? r.filter((n) => n.matches(e)) : r;
|
|
227
|
-
}
|
|
228
|
-
function kt(t, e) {
|
|
229
|
-
const s = [e];
|
|
230
|
-
for (; s.length > 0; ) {
|
|
231
|
-
const r = s.shift();
|
|
232
|
-
if (t === r)
|
|
233
|
-
return !0;
|
|
234
|
-
s.push(...r.children, ...r.shadowRoot ? r.shadowRoot.children : [], ...r.assignedElements ? r.assignedElements() : []);
|
|
235
|
-
}
|
|
236
|
-
}
|
|
237
|
-
function It(t, e) {
|
|
238
|
-
const s = N();
|
|
239
|
-
let r = e.contains(t);
|
|
240
|
-
return !r && s.HTMLSlotElement && e instanceof HTMLSlotElement && (r = [...e.assignedElements()].includes(t), r || (r = kt(t, e))), r;
|
|
241
|
-
}
|
|
242
|
-
function oe(t) {
|
|
243
|
-
try {
|
|
244
|
-
console.warn(t);
|
|
245
|
-
return;
|
|
246
|
-
} catch {
|
|
247
|
-
}
|
|
248
|
-
}
|
|
249
|
-
function de(t, e) {
|
|
250
|
-
e === void 0 && (e = []);
|
|
251
|
-
const s = document.createElement(t);
|
|
252
|
-
return s.classList.add(...Array.isArray(e) ? e : xt(e)), s;
|
|
253
|
-
}
|
|
254
|
-
function Lt(t, e) {
|
|
255
|
-
const s = [];
|
|
256
|
-
for (; t.previousElementSibling; ) {
|
|
257
|
-
const r = t.previousElementSibling;
|
|
258
|
-
e ? r.matches(e) && s.push(r) : s.push(r), t = r;
|
|
259
|
-
}
|
|
260
|
-
return s;
|
|
261
|
-
}
|
|
262
|
-
function At(t, e) {
|
|
263
|
-
const s = [];
|
|
264
|
-
for (; t.nextElementSibling; ) {
|
|
265
|
-
const r = t.nextElementSibling;
|
|
266
|
-
e ? r.matches(e) && s.push(r) : s.push(r), t = r;
|
|
267
|
-
}
|
|
268
|
-
return s;
|
|
269
|
-
}
|
|
270
|
-
function Y(t, e) {
|
|
271
|
-
return N().getComputedStyle(t, null).getPropertyValue(e);
|
|
272
|
-
}
|
|
273
|
-
function ce(t) {
|
|
274
|
-
let e = t, s;
|
|
275
|
-
if (e) {
|
|
276
|
-
for (s = 0; (e = e.previousSibling) !== null; )
|
|
277
|
-
e.nodeType === 1 && (s += 1);
|
|
278
|
-
return s;
|
|
279
|
-
}
|
|
280
|
-
}
|
|
281
|
-
function Xe(t, e) {
|
|
282
|
-
const s = [];
|
|
283
|
-
let r = t.parentElement;
|
|
284
|
-
for (; r; )
|
|
285
|
-
e ? r.matches(e) && s.push(r) : s.push(r), r = r.parentElement;
|
|
286
|
-
return s;
|
|
287
|
-
}
|
|
288
|
-
function Te(t, e, s) {
|
|
289
|
-
const r = N();
|
|
290
|
-
return t[e === "width" ? "offsetWidth" : "offsetHeight"] + parseFloat(r.getComputedStyle(t, null).getPropertyValue(e === "width" ? "margin-right" : "margin-top")) + parseFloat(r.getComputedStyle(t, null).getPropertyValue(e === "width" ? "margin-left" : "margin-bottom"));
|
|
291
|
-
}
|
|
292
|
-
function R(t) {
|
|
293
|
-
return (Array.isArray(t) ? t : [t]).filter((e) => !!e);
|
|
294
|
-
}
|
|
295
|
-
let fe;
|
|
296
|
-
function Ot() {
|
|
297
|
-
const t = N(), e = K();
|
|
298
|
-
return {
|
|
299
|
-
smoothScroll: e.documentElement && e.documentElement.style && "scrollBehavior" in e.documentElement.style,
|
|
300
|
-
touch: !!("ontouchstart" in t || t.DocumentTouch && e instanceof t.DocumentTouch)
|
|
301
|
-
};
|
|
302
|
-
}
|
|
303
|
-
function Ue() {
|
|
304
|
-
return fe || (fe = Ot()), fe;
|
|
305
|
-
}
|
|
306
|
-
let he;
|
|
307
|
-
function zt(t) {
|
|
308
|
-
let {
|
|
309
|
-
userAgent: e
|
|
310
|
-
} = t === void 0 ? {} : t;
|
|
311
|
-
const s = Ue(), r = N(), n = r.navigator.platform, i = e || r.navigator.userAgent, l = {
|
|
312
|
-
ios: !1,
|
|
313
|
-
android: !1
|
|
314
|
-
}, a = r.screen.width, o = r.screen.height, c = i.match(/(Android);?[\s\/]+([\d.]+)?/);
|
|
315
|
-
let d = i.match(/(iPad).*OS\s([\d_]+)/);
|
|
316
|
-
const u = i.match(/(iPod)(.*OS\s([\d_]+))?/), f = !d && i.match(/(iPhone\sOS|iOS)\s([\d_]+)/), g = n === "Win32";
|
|
317
|
-
let h = n === "MacIntel";
|
|
318
|
-
const b = ["1024x1366", "1366x1024", "834x1194", "1194x834", "834x1112", "1112x834", "768x1024", "1024x768", "820x1180", "1180x820", "810x1080", "1080x810"];
|
|
319
|
-
return !d && h && s.touch && b.indexOf(`${a}x${o}`) >= 0 && (d = i.match(/(Version)\/([\d.]+)/), d || (d = [0, 1, "13_0_0"]), h = !1), c && !g && (l.os = "android", l.android = !0), (d || f || u) && (l.os = "ios", l.ios = !0), l;
|
|
320
|
-
}
|
|
321
|
-
function Qe(t) {
|
|
322
|
-
return t === void 0 && (t = {}), he || (he = zt(t)), he;
|
|
323
|
-
}
|
|
324
|
-
let ge;
|
|
325
|
-
function _t() {
|
|
326
|
-
const t = N(), e = Qe();
|
|
327
|
-
let s = !1;
|
|
328
|
-
function r() {
|
|
329
|
-
const a = t.navigator.userAgent.toLowerCase();
|
|
330
|
-
return a.indexOf("safari") >= 0 && a.indexOf("chrome") < 0 && a.indexOf("android") < 0;
|
|
331
|
-
}
|
|
332
|
-
if (r()) {
|
|
333
|
-
const a = String(t.navigator.userAgent);
|
|
334
|
-
if (a.includes("Version/")) {
|
|
335
|
-
const [o, c] = a.split("Version/")[1].split(" ")[0].split(".").map((d) => Number(d));
|
|
336
|
-
s = o < 16 || o === 16 && c < 2;
|
|
337
|
-
}
|
|
338
|
-
}
|
|
339
|
-
const n = /(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(t.navigator.userAgent), i = r(), l = i || n && e.ios;
|
|
340
|
-
return {
|
|
341
|
-
isSafari: s || i,
|
|
342
|
-
needPerspectiveFix: s,
|
|
343
|
-
need3dFix: l,
|
|
344
|
-
isWebView: n
|
|
345
|
-
};
|
|
346
|
-
}
|
|
347
|
-
function Ke() {
|
|
348
|
-
return ge || (ge = _t()), ge;
|
|
349
|
-
}
|
|
350
|
-
function $t(t) {
|
|
351
|
-
let {
|
|
352
|
-
swiper: e,
|
|
353
|
-
on: s,
|
|
354
|
-
emit: r
|
|
355
|
-
} = t;
|
|
356
|
-
const n = N();
|
|
357
|
-
let i = null, l = null;
|
|
358
|
-
const a = () => {
|
|
359
|
-
!e || e.destroyed || !e.initialized || (r("beforeResize"), r("resize"));
|
|
360
|
-
}, o = () => {
|
|
361
|
-
!e || e.destroyed || !e.initialized || (i = new ResizeObserver((u) => {
|
|
362
|
-
l = n.requestAnimationFrame(() => {
|
|
363
|
-
const {
|
|
364
|
-
width: f,
|
|
365
|
-
height: g
|
|
366
|
-
} = e;
|
|
367
|
-
let h = f, b = g;
|
|
368
|
-
u.forEach((M) => {
|
|
369
|
-
let {
|
|
370
|
-
contentBoxSize: w,
|
|
371
|
-
contentRect: p,
|
|
372
|
-
target: m
|
|
373
|
-
} = M;
|
|
374
|
-
m && m !== e.el || (h = p ? p.width : (w[0] || w).inlineSize, b = p ? p.height : (w[0] || w).blockSize);
|
|
375
|
-
}), (h !== f || b !== g) && a();
|
|
376
|
-
});
|
|
377
|
-
}), i.observe(e.el));
|
|
378
|
-
}, c = () => {
|
|
379
|
-
l && n.cancelAnimationFrame(l), i && i.unobserve && e.el && (i.unobserve(e.el), i = null);
|
|
380
|
-
}, d = () => {
|
|
381
|
-
!e || e.destroyed || !e.initialized || r("orientationchange");
|
|
382
|
-
};
|
|
383
|
-
s("init", () => {
|
|
384
|
-
if (e.params.resizeObserver && typeof n.ResizeObserver < "u") {
|
|
385
|
-
o();
|
|
386
|
-
return;
|
|
387
|
-
}
|
|
388
|
-
n.addEventListener("resize", a), n.addEventListener("orientationchange", d);
|
|
389
|
-
}), s("destroy", () => {
|
|
390
|
-
c(), n.removeEventListener("resize", a), n.removeEventListener("orientationchange", d);
|
|
391
|
-
});
|
|
392
|
-
}
|
|
393
|
-
function Gt(t) {
|
|
394
|
-
let {
|
|
395
|
-
swiper: e,
|
|
396
|
-
extendParams: s,
|
|
397
|
-
on: r,
|
|
398
|
-
emit: n
|
|
399
|
-
} = t;
|
|
400
|
-
const i = [], l = N(), a = function(d, u) {
|
|
401
|
-
u === void 0 && (u = {});
|
|
402
|
-
const f = l.MutationObserver || l.WebkitMutationObserver, g = new f((h) => {
|
|
403
|
-
if (e.__preventObserver__) return;
|
|
404
|
-
if (h.length === 1) {
|
|
405
|
-
n("observerUpdate", h[0]);
|
|
406
|
-
return;
|
|
407
|
-
}
|
|
408
|
-
const b = function() {
|
|
409
|
-
n("observerUpdate", h[0]);
|
|
410
|
-
};
|
|
411
|
-
l.requestAnimationFrame ? l.requestAnimationFrame(b) : l.setTimeout(b, 0);
|
|
412
|
-
});
|
|
413
|
-
g.observe(d, {
|
|
414
|
-
attributes: typeof u.attributes > "u" ? !0 : u.attributes,
|
|
415
|
-
childList: e.isElement || (typeof u.childList > "u" ? !0 : u).childList,
|
|
416
|
-
characterData: typeof u.characterData > "u" ? !0 : u.characterData
|
|
417
|
-
}), i.push(g);
|
|
418
|
-
}, o = () => {
|
|
419
|
-
if (e.params.observer) {
|
|
420
|
-
if (e.params.observeParents) {
|
|
421
|
-
const d = Xe(e.hostEl);
|
|
422
|
-
for (let u = 0; u < d.length; u += 1)
|
|
423
|
-
a(d[u]);
|
|
424
|
-
}
|
|
425
|
-
a(e.hostEl, {
|
|
426
|
-
childList: e.params.observeSlideChildren
|
|
427
|
-
}), a(e.wrapperEl, {
|
|
428
|
-
attributes: !1
|
|
429
|
-
});
|
|
430
|
-
}
|
|
431
|
-
}, c = () => {
|
|
432
|
-
i.forEach((d) => {
|
|
433
|
-
d.disconnect();
|
|
434
|
-
}), i.splice(0, i.length);
|
|
435
|
-
};
|
|
436
|
-
s({
|
|
437
|
-
observer: !1,
|
|
438
|
-
observeParents: !1,
|
|
439
|
-
observeSlideChildren: !1
|
|
440
|
-
}), r("init", o), r("destroy", c);
|
|
441
|
-
}
|
|
442
|
-
var Nt = {
|
|
443
|
-
on(t, e, s) {
|
|
444
|
-
const r = this;
|
|
445
|
-
if (!r.eventsListeners || r.destroyed || typeof e != "function") return r;
|
|
446
|
-
const n = s ? "unshift" : "push";
|
|
447
|
-
return t.split(" ").forEach((i) => {
|
|
448
|
-
r.eventsListeners[i] || (r.eventsListeners[i] = []), r.eventsListeners[i][n](e);
|
|
449
|
-
}), r;
|
|
450
|
-
},
|
|
451
|
-
once(t, e, s) {
|
|
452
|
-
const r = this;
|
|
453
|
-
if (!r.eventsListeners || r.destroyed || typeof e != "function") return r;
|
|
454
|
-
function n() {
|
|
455
|
-
r.off(t, n), n.__emitterProxy && delete n.__emitterProxy;
|
|
456
|
-
for (var i = arguments.length, l = new Array(i), a = 0; a < i; a++)
|
|
457
|
-
l[a] = arguments[a];
|
|
458
|
-
e.apply(r, l);
|
|
459
|
-
}
|
|
460
|
-
return n.__emitterProxy = e, r.on(t, n, s);
|
|
461
|
-
},
|
|
462
|
-
onAny(t, e) {
|
|
463
|
-
const s = this;
|
|
464
|
-
if (!s.eventsListeners || s.destroyed || typeof t != "function") return s;
|
|
465
|
-
const r = e ? "unshift" : "push";
|
|
466
|
-
return s.eventsAnyListeners.indexOf(t) < 0 && s.eventsAnyListeners[r](t), s;
|
|
467
|
-
},
|
|
468
|
-
offAny(t) {
|
|
469
|
-
const e = this;
|
|
470
|
-
if (!e.eventsListeners || e.destroyed || !e.eventsAnyListeners) return e;
|
|
471
|
-
const s = e.eventsAnyListeners.indexOf(t);
|
|
472
|
-
return s >= 0 && e.eventsAnyListeners.splice(s, 1), e;
|
|
473
|
-
},
|
|
474
|
-
off(t, e) {
|
|
475
|
-
const s = this;
|
|
476
|
-
return !s.eventsListeners || s.destroyed || !s.eventsListeners || t.split(" ").forEach((r) => {
|
|
477
|
-
typeof e > "u" ? s.eventsListeners[r] = [] : s.eventsListeners[r] && s.eventsListeners[r].forEach((n, i) => {
|
|
478
|
-
(n === e || n.__emitterProxy && n.__emitterProxy === e) && s.eventsListeners[r].splice(i, 1);
|
|
479
|
-
});
|
|
480
|
-
}), s;
|
|
481
|
-
},
|
|
482
|
-
emit() {
|
|
483
|
-
const t = this;
|
|
484
|
-
if (!t.eventsListeners || t.destroyed || !t.eventsListeners) return t;
|
|
485
|
-
let e, s, r;
|
|
486
|
-
for (var n = arguments.length, i = new Array(n), l = 0; l < n; l++)
|
|
487
|
-
i[l] = arguments[l];
|
|
488
|
-
return typeof i[0] == "string" || Array.isArray(i[0]) ? (e = i[0], s = i.slice(1, i.length), r = t) : (e = i[0].events, s = i[0].data, r = i[0].context || t), s.unshift(r), (Array.isArray(e) ? e : e.split(" ")).forEach((a) => {
|
|
489
|
-
t.eventsAnyListeners && t.eventsAnyListeners.length && t.eventsAnyListeners.forEach((o) => {
|
|
490
|
-
o.apply(r, [a, ...s]);
|
|
491
|
-
}), t.eventsListeners && t.eventsListeners[a] && t.eventsListeners[a].forEach((o) => {
|
|
492
|
-
o.apply(r, s);
|
|
493
|
-
});
|
|
494
|
-
}), t;
|
|
495
|
-
}
|
|
496
|
-
};
|
|
497
|
-
function Bt() {
|
|
498
|
-
const t = this;
|
|
499
|
-
let e, s;
|
|
500
|
-
const r = t.el;
|
|
501
|
-
typeof t.params.width < "u" && t.params.width !== null ? e = t.params.width : e = r.clientWidth, typeof t.params.height < "u" && t.params.height !== null ? s = t.params.height : s = r.clientHeight, !(e === 0 && t.isHorizontal() || s === 0 && t.isVertical()) && (e = e - parseInt(Y(r, "padding-left") || 0, 10) - parseInt(Y(r, "padding-right") || 0, 10), s = s - parseInt(Y(r, "padding-top") || 0, 10) - parseInt(Y(r, "padding-bottom") || 0, 10), Number.isNaN(e) && (e = 0), Number.isNaN(s) && (s = 0), Object.assign(t, {
|
|
502
|
-
width: e,
|
|
503
|
-
height: s,
|
|
504
|
-
size: t.isHorizontal() ? e : s
|
|
505
|
-
}));
|
|
506
|
-
}
|
|
507
|
-
function Dt() {
|
|
508
|
-
const t = this;
|
|
509
|
-
function e(E, x) {
|
|
510
|
-
return parseFloat(E.getPropertyValue(t.getDirectionLabel(x)) || 0);
|
|
511
|
-
}
|
|
512
|
-
const s = t.params, {
|
|
513
|
-
wrapperEl: r,
|
|
514
|
-
slidesEl: n,
|
|
515
|
-
size: i,
|
|
516
|
-
rtlTranslate: l,
|
|
517
|
-
wrongRTL: a
|
|
518
|
-
} = t, o = t.virtual && s.virtual.enabled, c = o ? t.virtual.slides.length : t.slides.length, d = H(n, `.${t.params.slideClass}, swiper-slide`), u = o ? t.virtual.slides.length : d.length;
|
|
519
|
-
let f = [];
|
|
520
|
-
const g = [], h = [];
|
|
521
|
-
let b = s.slidesOffsetBefore;
|
|
522
|
-
typeof b == "function" && (b = s.slidesOffsetBefore.call(t));
|
|
523
|
-
let M = s.slidesOffsetAfter;
|
|
524
|
-
typeof M == "function" && (M = s.slidesOffsetAfter.call(t));
|
|
525
|
-
const w = t.snapGrid.length, p = t.slidesGrid.length;
|
|
526
|
-
let m = s.spaceBetween, v = -b, y = 0, T = 0;
|
|
527
|
-
if (typeof i > "u")
|
|
528
|
-
return;
|
|
529
|
-
typeof m == "string" && m.indexOf("%") >= 0 ? m = parseFloat(m.replace("%", "")) / 100 * i : typeof m == "string" && (m = parseFloat(m)), t.virtualSize = -m, d.forEach((E) => {
|
|
530
|
-
l ? E.style.marginLeft = "" : E.style.marginRight = "", E.style.marginBottom = "", E.style.marginTop = "";
|
|
531
|
-
}), s.centeredSlides && s.cssMode && (re(r, "--swiper-centered-offset-before", ""), re(r, "--swiper-centered-offset-after", ""));
|
|
532
|
-
const A = s.grid && s.grid.rows > 1 && t.grid;
|
|
533
|
-
A ? t.grid.initSlides(d) : t.grid && t.grid.unsetSlides();
|
|
534
|
-
let I;
|
|
535
|
-
const S = s.slidesPerView === "auto" && s.breakpoints && Object.keys(s.breakpoints).filter((E) => typeof s.breakpoints[E].slidesPerView < "u").length > 0;
|
|
536
|
-
for (let E = 0; E < u; E += 1) {
|
|
537
|
-
I = 0;
|
|
538
|
-
let x;
|
|
539
|
-
if (d[E] && (x = d[E]), A && t.grid.updateSlide(E, x, d), !(d[E] && Y(x, "display") === "none")) {
|
|
540
|
-
if (s.slidesPerView === "auto") {
|
|
541
|
-
S && (d[E].style[t.getDirectionLabel("width")] = "");
|
|
542
|
-
const k = getComputedStyle(x), L = x.style.transform, O = x.style.webkitTransform;
|
|
543
|
-
if (L && (x.style.transform = "none"), O && (x.style.webkitTransform = "none"), s.roundLengths)
|
|
544
|
-
I = t.isHorizontal() ? Te(x, "width") : Te(x, "height");
|
|
545
|
-
else {
|
|
546
|
-
const C = e(k, "width"), z = e(k, "padding-left"), U = e(k, "padding-right"), j = e(k, "margin-left"), G = e(k, "margin-right"), V = k.getPropertyValue("box-sizing");
|
|
547
|
-
if (V && V === "border-box")
|
|
548
|
-
I = C + j + G;
|
|
549
|
-
else {
|
|
550
|
-
const {
|
|
551
|
-
clientWidth: ut,
|
|
552
|
-
offsetWidth: mt
|
|
553
|
-
} = x;
|
|
554
|
-
I = C + z + U + j + G + (mt - ut);
|
|
555
|
-
}
|
|
556
|
-
}
|
|
557
|
-
L && (x.style.transform = L), O && (x.style.webkitTransform = O), s.roundLengths && (I = Math.floor(I));
|
|
558
|
-
} else
|
|
559
|
-
I = (i - (s.slidesPerView - 1) * m) / s.slidesPerView, s.roundLengths && (I = Math.floor(I)), d[E] && (d[E].style[t.getDirectionLabel("width")] = `${I}px`);
|
|
560
|
-
d[E] && (d[E].swiperSlideSize = I), h.push(I), s.centeredSlides ? (v = v + I / 2 + y / 2 + m, y === 0 && E !== 0 && (v = v - i / 2 - m), E === 0 && (v = v - i / 2 - m), Math.abs(v) < 1 / 1e3 && (v = 0), s.roundLengths && (v = Math.floor(v)), T % s.slidesPerGroup === 0 && f.push(v), g.push(v)) : (s.roundLengths && (v = Math.floor(v)), (T - Math.min(t.params.slidesPerGroupSkip, T)) % t.params.slidesPerGroup === 0 && f.push(v), g.push(v), v = v + I + m), t.virtualSize += I + m, y = I, T += 1;
|
|
561
|
-
}
|
|
562
|
-
}
|
|
563
|
-
if (t.virtualSize = Math.max(t.virtualSize, i) + M, l && a && (s.effect === "slide" || s.effect === "coverflow") && (r.style.width = `${t.virtualSize + m}px`), s.setWrapperSize && (r.style[t.getDirectionLabel("width")] = `${t.virtualSize + m}px`), A && t.grid.updateWrapperSize(I, f), !s.centeredSlides) {
|
|
564
|
-
const E = [];
|
|
565
|
-
for (let x = 0; x < f.length; x += 1) {
|
|
566
|
-
let k = f[x];
|
|
567
|
-
s.roundLengths && (k = Math.floor(k)), f[x] <= t.virtualSize - i && E.push(k);
|
|
568
|
-
}
|
|
569
|
-
f = E, Math.floor(t.virtualSize - i) - Math.floor(f[f.length - 1]) > 1 && f.push(t.virtualSize - i);
|
|
570
|
-
}
|
|
571
|
-
if (o && s.loop) {
|
|
572
|
-
const E = h[0] + m;
|
|
573
|
-
if (s.slidesPerGroup > 1) {
|
|
574
|
-
const x = Math.ceil((t.virtual.slidesBefore + t.virtual.slidesAfter) / s.slidesPerGroup), k = E * s.slidesPerGroup;
|
|
575
|
-
for (let L = 0; L < x; L += 1)
|
|
576
|
-
f.push(f[f.length - 1] + k);
|
|
577
|
-
}
|
|
578
|
-
for (let x = 0; x < t.virtual.slidesBefore + t.virtual.slidesAfter; x += 1)
|
|
579
|
-
s.slidesPerGroup === 1 && f.push(f[f.length - 1] + E), g.push(g[g.length - 1] + E), t.virtualSize += E;
|
|
580
|
-
}
|
|
581
|
-
if (f.length === 0 && (f = [0]), m !== 0) {
|
|
582
|
-
const E = t.isHorizontal() && l ? "marginLeft" : t.getDirectionLabel("marginRight");
|
|
583
|
-
d.filter((x, k) => !s.cssMode || s.loop ? !0 : k !== d.length - 1).forEach((x) => {
|
|
584
|
-
x.style[E] = `${m}px`;
|
|
585
|
-
});
|
|
586
|
-
}
|
|
587
|
-
if (s.centeredSlides && s.centeredSlidesBounds) {
|
|
588
|
-
let E = 0;
|
|
589
|
-
h.forEach((k) => {
|
|
590
|
-
E += k + (m || 0);
|
|
591
|
-
}), E -= m;
|
|
592
|
-
const x = E > i ? E - i : 0;
|
|
593
|
-
f = f.map((k) => k <= 0 ? -b : k > x ? x + M : k);
|
|
594
|
-
}
|
|
595
|
-
if (s.centerInsufficientSlides) {
|
|
596
|
-
let E = 0;
|
|
597
|
-
h.forEach((k) => {
|
|
598
|
-
E += k + (m || 0);
|
|
599
|
-
}), E -= m;
|
|
600
|
-
const x = (s.slidesOffsetBefore || 0) + (s.slidesOffsetAfter || 0);
|
|
601
|
-
if (E + x < i) {
|
|
602
|
-
const k = (i - E - x) / 2;
|
|
603
|
-
f.forEach((L, O) => {
|
|
604
|
-
f[O] = L - k;
|
|
605
|
-
}), g.forEach((L, O) => {
|
|
606
|
-
g[O] = L + k;
|
|
607
|
-
});
|
|
608
|
-
}
|
|
609
|
-
}
|
|
610
|
-
if (Object.assign(t, {
|
|
611
|
-
slides: d,
|
|
612
|
-
snapGrid: f,
|
|
613
|
-
slidesGrid: g,
|
|
614
|
-
slidesSizesGrid: h
|
|
615
|
-
}), s.centeredSlides && s.cssMode && !s.centeredSlidesBounds) {
|
|
616
|
-
re(r, "--swiper-centered-offset-before", `${-f[0]}px`), re(r, "--swiper-centered-offset-after", `${t.size / 2 - h[h.length - 1] / 2}px`);
|
|
617
|
-
const E = -t.snapGrid[0], x = -t.slidesGrid[0];
|
|
618
|
-
t.snapGrid = t.snapGrid.map((k) => k + E), t.slidesGrid = t.slidesGrid.map((k) => k + x);
|
|
619
|
-
}
|
|
620
|
-
if (u !== c && t.emit("slidesLengthChange"), f.length !== w && (t.params.watchOverflow && t.checkOverflow(), t.emit("snapGridLengthChange")), g.length !== p && t.emit("slidesGridLengthChange"), s.watchSlidesProgress && t.updateSlidesOffset(), t.emit("slidesUpdated"), !o && !s.cssMode && (s.effect === "slide" || s.effect === "fade")) {
|
|
621
|
-
const E = `${s.containerModifierClass}backface-hidden`, x = t.el.classList.contains(E);
|
|
622
|
-
u <= s.maxBackfaceHiddenSlides ? x || t.el.classList.add(E) : x && t.el.classList.remove(E);
|
|
623
|
-
}
|
|
624
|
-
}
|
|
625
|
-
function Ft(t) {
|
|
626
|
-
const e = this, s = [], r = e.virtual && e.params.virtual.enabled;
|
|
627
|
-
let n = 0, i;
|
|
628
|
-
typeof t == "number" ? e.setTransition(t) : t === !0 && e.setTransition(e.params.speed);
|
|
629
|
-
const l = (a) => r ? e.slides[e.getSlideIndexByData(a)] : e.slides[a];
|
|
630
|
-
if (e.params.slidesPerView !== "auto" && e.params.slidesPerView > 1)
|
|
631
|
-
if (e.params.centeredSlides)
|
|
632
|
-
(e.visibleSlides || []).forEach((a) => {
|
|
633
|
-
s.push(a);
|
|
634
|
-
});
|
|
635
|
-
else
|
|
636
|
-
for (i = 0; i < Math.ceil(e.params.slidesPerView); i += 1) {
|
|
637
|
-
const a = e.activeIndex + i;
|
|
638
|
-
if (a > e.slides.length && !r) break;
|
|
639
|
-
s.push(l(a));
|
|
640
|
-
}
|
|
641
|
-
else
|
|
642
|
-
s.push(l(e.activeIndex));
|
|
643
|
-
for (i = 0; i < s.length; i += 1)
|
|
644
|
-
if (typeof s[i] < "u") {
|
|
645
|
-
const a = s[i].offsetHeight;
|
|
646
|
-
n = a > n ? a : n;
|
|
647
|
-
}
|
|
648
|
-
(n || n === 0) && (e.wrapperEl.style.height = `${n}px`);
|
|
649
|
-
}
|
|
650
|
-
function jt() {
|
|
651
|
-
const t = this, e = t.slides, s = t.isElement ? t.isHorizontal() ? t.wrapperEl.offsetLeft : t.wrapperEl.offsetTop : 0;
|
|
652
|
-
for (let r = 0; r < e.length; r += 1)
|
|
653
|
-
e[r].swiperSlideOffset = (t.isHorizontal() ? e[r].offsetLeft : e[r].offsetTop) - s - t.cssOverflowAdjustment();
|
|
654
|
-
}
|
|
655
|
-
const $e = (t, e, s) => {
|
|
656
|
-
e && !t.classList.contains(s) ? t.classList.add(s) : !e && t.classList.contains(s) && t.classList.remove(s);
|
|
657
|
-
};
|
|
658
|
-
function Vt(t) {
|
|
659
|
-
t === void 0 && (t = this && this.translate || 0);
|
|
660
|
-
const e = this, s = e.params, {
|
|
661
|
-
slides: r,
|
|
662
|
-
rtlTranslate: n,
|
|
663
|
-
snapGrid: i
|
|
664
|
-
} = e;
|
|
665
|
-
if (r.length === 0) return;
|
|
666
|
-
typeof r[0].swiperSlideOffset > "u" && e.updateSlidesOffset();
|
|
667
|
-
let l = -t;
|
|
668
|
-
n && (l = t), e.visibleSlidesIndexes = [], e.visibleSlides = [];
|
|
669
|
-
let a = s.spaceBetween;
|
|
670
|
-
typeof a == "string" && a.indexOf("%") >= 0 ? a = parseFloat(a.replace("%", "")) / 100 * e.size : typeof a == "string" && (a = parseFloat(a));
|
|
671
|
-
for (let o = 0; o < r.length; o += 1) {
|
|
672
|
-
const c = r[o];
|
|
673
|
-
let d = c.swiperSlideOffset;
|
|
674
|
-
s.cssMode && s.centeredSlides && (d -= r[0].swiperSlideOffset);
|
|
675
|
-
const u = (l + (s.centeredSlides ? e.minTranslate() : 0) - d) / (c.swiperSlideSize + a), f = (l - i[0] + (s.centeredSlides ? e.minTranslate() : 0) - d) / (c.swiperSlideSize + a), g = -(l - d), h = g + e.slidesSizesGrid[o], b = g >= 0 && g <= e.size - e.slidesSizesGrid[o], M = g >= 0 && g < e.size - 1 || h > 1 && h <= e.size || g <= 0 && h >= e.size;
|
|
676
|
-
M && (e.visibleSlides.push(c), e.visibleSlidesIndexes.push(o)), $e(c, M, s.slideVisibleClass), $e(c, b, s.slideFullyVisibleClass), c.progress = n ? -u : u, c.originalProgress = n ? -f : f;
|
|
677
|
-
}
|
|
678
|
-
}
|
|
679
|
-
function Ht(t) {
|
|
680
|
-
const e = this;
|
|
681
|
-
if (typeof t > "u") {
|
|
682
|
-
const d = e.rtlTranslate ? -1 : 1;
|
|
683
|
-
t = e && e.translate && e.translate * d || 0;
|
|
684
|
-
}
|
|
685
|
-
const s = e.params, r = e.maxTranslate() - e.minTranslate();
|
|
686
|
-
let {
|
|
687
|
-
progress: n,
|
|
688
|
-
isBeginning: i,
|
|
689
|
-
isEnd: l,
|
|
690
|
-
progressLoop: a
|
|
691
|
-
} = e;
|
|
692
|
-
const o = i, c = l;
|
|
693
|
-
if (r === 0)
|
|
694
|
-
n = 0, i = !0, l = !0;
|
|
695
|
-
else {
|
|
696
|
-
n = (t - e.minTranslate()) / r;
|
|
697
|
-
const d = Math.abs(t - e.minTranslate()) < 1, u = Math.abs(t - e.maxTranslate()) < 1;
|
|
698
|
-
i = d || n <= 0, l = u || n >= 1, d && (n = 0), u && (n = 1);
|
|
699
|
-
}
|
|
700
|
-
if (s.loop) {
|
|
701
|
-
const d = e.getSlideIndexByData(0), u = e.getSlideIndexByData(e.slides.length - 1), f = e.slidesGrid[d], g = e.slidesGrid[u], h = e.slidesGrid[e.slidesGrid.length - 1], b = Math.abs(t);
|
|
702
|
-
b >= f ? a = (b - f) / h : a = (b + h - g) / h, a > 1 && (a -= 1);
|
|
703
|
-
}
|
|
704
|
-
Object.assign(e, {
|
|
705
|
-
progress: n,
|
|
706
|
-
progressLoop: a,
|
|
707
|
-
isBeginning: i,
|
|
708
|
-
isEnd: l
|
|
709
|
-
}), (s.watchSlidesProgress || s.centeredSlides && s.autoHeight) && e.updateSlidesProgress(t), i && !o && e.emit("reachBeginning toEdge"), l && !c && e.emit("reachEnd toEdge"), (o && !i || c && !l) && e.emit("fromEdge"), e.emit("progress", n);
|
|
710
|
-
}
|
|
711
|
-
const ve = (t, e, s) => {
|
|
712
|
-
e && !t.classList.contains(s) ? t.classList.add(s) : !e && t.classList.contains(s) && t.classList.remove(s);
|
|
713
|
-
};
|
|
714
|
-
function Rt() {
|
|
715
|
-
const t = this, {
|
|
716
|
-
slides: e,
|
|
717
|
-
params: s,
|
|
718
|
-
slidesEl: r,
|
|
719
|
-
activeIndex: n
|
|
720
|
-
} = t, i = t.virtual && s.virtual.enabled, l = t.grid && s.grid && s.grid.rows > 1, a = (u) => H(r, `.${s.slideClass}${u}, swiper-slide${u}`)[0];
|
|
721
|
-
let o, c, d;
|
|
722
|
-
if (i)
|
|
723
|
-
if (s.loop) {
|
|
724
|
-
let u = n - t.virtual.slidesBefore;
|
|
725
|
-
u < 0 && (u = t.virtual.slides.length + u), u >= t.virtual.slides.length && (u -= t.virtual.slides.length), o = a(`[data-swiper-slide-index="${u}"]`);
|
|
726
|
-
} else
|
|
727
|
-
o = a(`[data-swiper-slide-index="${n}"]`);
|
|
728
|
-
else
|
|
729
|
-
l ? (o = e.find((u) => u.column === n), d = e.find((u) => u.column === n + 1), c = e.find((u) => u.column === n - 1)) : o = e[n];
|
|
730
|
-
o && (l || (d = At(o, `.${s.slideClass}, swiper-slide`)[0], s.loop && !d && (d = e[0]), c = Lt(o, `.${s.slideClass}, swiper-slide`)[0], s.loop && !c === 0 && (c = e[e.length - 1]))), e.forEach((u) => {
|
|
731
|
-
ve(u, u === o, s.slideActiveClass), ve(u, u === d, s.slideNextClass), ve(u, u === c, s.slidePrevClass);
|
|
732
|
-
}), t.emitSlidesClasses();
|
|
733
|
-
}
|
|
734
|
-
const ne = (t, e) => {
|
|
735
|
-
if (!t || t.destroyed || !t.params) return;
|
|
736
|
-
const s = () => t.isElement ? "swiper-slide" : `.${t.params.slideClass}`, r = e.closest(s());
|
|
737
|
-
if (r) {
|
|
738
|
-
let n = r.querySelector(`.${t.params.lazyPreloaderClass}`);
|
|
739
|
-
!n && t.isElement && (r.shadowRoot ? n = r.shadowRoot.querySelector(`.${t.params.lazyPreloaderClass}`) : requestAnimationFrame(() => {
|
|
740
|
-
r.shadowRoot && (n = r.shadowRoot.querySelector(`.${t.params.lazyPreloaderClass}`), n && n.remove());
|
|
741
|
-
})), n && n.remove();
|
|
742
|
-
}
|
|
743
|
-
}, we = (t, e) => {
|
|
744
|
-
if (!t.slides[e]) return;
|
|
745
|
-
const s = t.slides[e].querySelector('[loading="lazy"]');
|
|
746
|
-
s && s.removeAttribute("loading");
|
|
747
|
-
}, Ce = (t) => {
|
|
748
|
-
if (!t || t.destroyed || !t.params) return;
|
|
749
|
-
let e = t.params.lazyPreloadPrevNext;
|
|
750
|
-
const s = t.slides.length;
|
|
751
|
-
if (!s || !e || e < 0) return;
|
|
752
|
-
e = Math.min(e, s);
|
|
753
|
-
const r = t.params.slidesPerView === "auto" ? t.slidesPerViewDynamic() : Math.ceil(t.params.slidesPerView), n = t.activeIndex;
|
|
754
|
-
if (t.params.grid && t.params.grid.rows > 1) {
|
|
755
|
-
const l = n, a = [l - e];
|
|
756
|
-
a.push(...Array.from({
|
|
757
|
-
length: e
|
|
758
|
-
}).map((o, c) => l + r + c)), t.slides.forEach((o, c) => {
|
|
759
|
-
a.includes(o.column) && we(t, c);
|
|
760
|
-
});
|
|
761
|
-
return;
|
|
762
|
-
}
|
|
763
|
-
const i = n + r - 1;
|
|
764
|
-
if (t.params.rewind || t.params.loop)
|
|
765
|
-
for (let l = n - e; l <= i + e; l += 1) {
|
|
766
|
-
const a = (l % s + s) % s;
|
|
767
|
-
(a < n || a > i) && we(t, a);
|
|
768
|
-
}
|
|
769
|
-
else
|
|
770
|
-
for (let l = Math.max(n - e, 0); l <= Math.min(i + e, s - 1); l += 1)
|
|
771
|
-
l !== n && (l > i || l < n) && we(t, l);
|
|
772
|
-
};
|
|
773
|
-
function qt(t) {
|
|
774
|
-
const {
|
|
775
|
-
slidesGrid: e,
|
|
776
|
-
params: s
|
|
777
|
-
} = t, r = t.rtlTranslate ? t.translate : -t.translate;
|
|
778
|
-
let n;
|
|
779
|
-
for (let i = 0; i < e.length; i += 1)
|
|
780
|
-
typeof e[i + 1] < "u" ? r >= e[i] && r < e[i + 1] - (e[i + 1] - e[i]) / 2 ? n = i : r >= e[i] && r < e[i + 1] && (n = i + 1) : r >= e[i] && (n = i);
|
|
781
|
-
return s.normalizeSlideIndex && (n < 0 || typeof n > "u") && (n = 0), n;
|
|
782
|
-
}
|
|
783
|
-
function Wt(t) {
|
|
784
|
-
const e = this, s = e.rtlTranslate ? e.translate : -e.translate, {
|
|
785
|
-
snapGrid: r,
|
|
786
|
-
params: n,
|
|
787
|
-
activeIndex: i,
|
|
788
|
-
realIndex: l,
|
|
789
|
-
snapIndex: a
|
|
790
|
-
} = e;
|
|
791
|
-
let o = t, c;
|
|
792
|
-
const d = (g) => {
|
|
793
|
-
let h = g - e.virtual.slidesBefore;
|
|
794
|
-
return h < 0 && (h = e.virtual.slides.length + h), h >= e.virtual.slides.length && (h -= e.virtual.slides.length), h;
|
|
795
|
-
};
|
|
796
|
-
if (typeof o > "u" && (o = qt(e)), r.indexOf(s) >= 0)
|
|
797
|
-
c = r.indexOf(s);
|
|
798
|
-
else {
|
|
799
|
-
const g = Math.min(n.slidesPerGroupSkip, o);
|
|
800
|
-
c = g + Math.floor((o - g) / n.slidesPerGroup);
|
|
801
|
-
}
|
|
802
|
-
if (c >= r.length && (c = r.length - 1), o === i && !e.params.loop) {
|
|
803
|
-
c !== a && (e.snapIndex = c, e.emit("snapIndexChange"));
|
|
804
|
-
return;
|
|
805
|
-
}
|
|
806
|
-
if (o === i && e.params.loop && e.virtual && e.params.virtual.enabled) {
|
|
807
|
-
e.realIndex = d(o);
|
|
808
|
-
return;
|
|
809
|
-
}
|
|
810
|
-
const u = e.grid && n.grid && n.grid.rows > 1;
|
|
811
|
-
let f;
|
|
812
|
-
if (e.virtual && n.virtual.enabled && n.loop)
|
|
813
|
-
f = d(o);
|
|
814
|
-
else if (u) {
|
|
815
|
-
const g = e.slides.find((b) => b.column === o);
|
|
816
|
-
let h = parseInt(g.getAttribute("data-swiper-slide-index"), 10);
|
|
817
|
-
Number.isNaN(h) && (h = Math.max(e.slides.indexOf(g), 0)), f = Math.floor(h / n.grid.rows);
|
|
818
|
-
} else if (e.slides[o]) {
|
|
819
|
-
const g = e.slides[o].getAttribute("data-swiper-slide-index");
|
|
820
|
-
g ? f = parseInt(g, 10) : f = o;
|
|
821
|
-
} else
|
|
822
|
-
f = o;
|
|
823
|
-
Object.assign(e, {
|
|
824
|
-
previousSnapIndex: a,
|
|
825
|
-
snapIndex: c,
|
|
826
|
-
previousRealIndex: l,
|
|
827
|
-
realIndex: f,
|
|
828
|
-
previousIndex: i,
|
|
829
|
-
activeIndex: o
|
|
830
|
-
}), e.initialized && Ce(e), e.emit("activeIndexChange"), e.emit("snapIndexChange"), (e.initialized || e.params.runCallbacksOnInit) && (l !== f && e.emit("realIndexChange"), e.emit("slideChange"));
|
|
831
|
-
}
|
|
832
|
-
function Yt(t, e) {
|
|
833
|
-
const s = this, r = s.params;
|
|
834
|
-
let n = t.closest(`.${r.slideClass}, swiper-slide`);
|
|
835
|
-
!n && s.isElement && e && e.length > 1 && e.includes(t) && [...e.slice(e.indexOf(t) + 1, e.length)].forEach((a) => {
|
|
836
|
-
!n && a.matches && a.matches(`.${r.slideClass}, swiper-slide`) && (n = a);
|
|
837
|
-
});
|
|
838
|
-
let i = !1, l;
|
|
839
|
-
if (n) {
|
|
840
|
-
for (let a = 0; a < s.slides.length; a += 1)
|
|
841
|
-
if (s.slides[a] === n) {
|
|
842
|
-
i = !0, l = a;
|
|
843
|
-
break;
|
|
844
|
-
}
|
|
845
|
-
}
|
|
846
|
-
if (n && i)
|
|
847
|
-
s.clickedSlide = n, s.virtual && s.params.virtual.enabled ? s.clickedIndex = parseInt(n.getAttribute("data-swiper-slide-index"), 10) : s.clickedIndex = l;
|
|
848
|
-
else {
|
|
849
|
-
s.clickedSlide = void 0, s.clickedIndex = void 0;
|
|
850
|
-
return;
|
|
851
|
-
}
|
|
852
|
-
r.slideToClickedSlide && s.clickedIndex !== void 0 && s.clickedIndex !== s.activeIndex && s.slideToClickedSlide();
|
|
853
|
-
}
|
|
854
|
-
var Xt = {
|
|
855
|
-
updateSize: Bt,
|
|
856
|
-
updateSlides: Dt,
|
|
857
|
-
updateAutoHeight: Ft,
|
|
858
|
-
updateSlidesOffset: jt,
|
|
859
|
-
updateSlidesProgress: Vt,
|
|
860
|
-
updateProgress: Ht,
|
|
861
|
-
updateSlidesClasses: Rt,
|
|
862
|
-
updateActiveIndex: Wt,
|
|
863
|
-
updateClickedSlide: Yt
|
|
864
|
-
};
|
|
865
|
-
function Ut(t) {
|
|
866
|
-
t === void 0 && (t = this.isHorizontal() ? "x" : "y");
|
|
867
|
-
const e = this, {
|
|
868
|
-
params: s,
|
|
869
|
-
rtlTranslate: r,
|
|
870
|
-
translate: n,
|
|
871
|
-
wrapperEl: i
|
|
872
|
-
} = e;
|
|
873
|
-
if (s.virtualTranslate)
|
|
874
|
-
return r ? -n : n;
|
|
875
|
-
if (s.cssMode)
|
|
876
|
-
return n;
|
|
877
|
-
let l = Pt(i, t);
|
|
878
|
-
return l += e.cssOverflowAdjustment(), r && (l = -l), l || 0;
|
|
879
|
-
}
|
|
880
|
-
function Qt(t, e) {
|
|
881
|
-
const s = this, {
|
|
882
|
-
rtlTranslate: r,
|
|
883
|
-
params: n,
|
|
884
|
-
wrapperEl: i,
|
|
885
|
-
progress: l
|
|
886
|
-
} = s;
|
|
887
|
-
let a = 0, o = 0;
|
|
888
|
-
const c = 0;
|
|
889
|
-
s.isHorizontal() ? a = r ? -t : t : o = t, n.roundLengths && (a = Math.floor(a), o = Math.floor(o)), s.previousTranslate = s.translate, s.translate = s.isHorizontal() ? a : o, n.cssMode ? i[s.isHorizontal() ? "scrollLeft" : "scrollTop"] = s.isHorizontal() ? -a : -o : n.virtualTranslate || (s.isHorizontal() ? a -= s.cssOverflowAdjustment() : o -= s.cssOverflowAdjustment(), i.style.transform = `translate3d(${a}px, ${o}px, ${c}px)`);
|
|
890
|
-
let d;
|
|
891
|
-
const u = s.maxTranslate() - s.minTranslate();
|
|
892
|
-
u === 0 ? d = 0 : d = (t - s.minTranslate()) / u, d !== l && s.updateProgress(t), s.emit("setTranslate", s.translate, e);
|
|
893
|
-
}
|
|
894
|
-
function Kt() {
|
|
895
|
-
return -this.snapGrid[0];
|
|
896
|
-
}
|
|
897
|
-
function Jt() {
|
|
898
|
-
return -this.snapGrid[this.snapGrid.length - 1];
|
|
899
|
-
}
|
|
900
|
-
function Zt(t, e, s, r, n) {
|
|
901
|
-
t === void 0 && (t = 0), e === void 0 && (e = this.params.speed), s === void 0 && (s = !0), r === void 0 && (r = !0);
|
|
902
|
-
const i = this, {
|
|
903
|
-
params: l,
|
|
904
|
-
wrapperEl: a
|
|
905
|
-
} = i;
|
|
906
|
-
if (i.animating && l.preventInteractionOnTransition)
|
|
907
|
-
return !1;
|
|
908
|
-
const o = i.minTranslate(), c = i.maxTranslate();
|
|
909
|
-
let d;
|
|
910
|
-
if (r && t > o ? d = o : r && t < c ? d = c : d = t, i.updateProgress(d), l.cssMode) {
|
|
911
|
-
const u = i.isHorizontal();
|
|
912
|
-
if (e === 0)
|
|
913
|
-
a[u ? "scrollLeft" : "scrollTop"] = -d;
|
|
914
|
-
else {
|
|
915
|
-
if (!i.support.smoothScroll)
|
|
916
|
-
return Ye({
|
|
917
|
-
swiper: i,
|
|
918
|
-
targetPosition: -d,
|
|
919
|
-
side: u ? "left" : "top"
|
|
920
|
-
}), !0;
|
|
921
|
-
a.scrollTo({
|
|
922
|
-
[u ? "left" : "top"]: -d,
|
|
923
|
-
behavior: "smooth"
|
|
924
|
-
});
|
|
925
|
-
}
|
|
926
|
-
return !0;
|
|
927
|
-
}
|
|
928
|
-
return e === 0 ? (i.setTransition(0), i.setTranslate(d), s && (i.emit("beforeTransitionStart", e, n), i.emit("transitionEnd"))) : (i.setTransition(e), i.setTranslate(d), s && (i.emit("beforeTransitionStart", e, n), i.emit("transitionStart")), i.animating || (i.animating = !0, i.onTranslateToWrapperTransitionEnd || (i.onTranslateToWrapperTransitionEnd = function(u) {
|
|
929
|
-
!i || i.destroyed || u.target === this && (i.wrapperEl.removeEventListener("transitionend", i.onTranslateToWrapperTransitionEnd), i.onTranslateToWrapperTransitionEnd = null, delete i.onTranslateToWrapperTransitionEnd, i.animating = !1, s && i.emit("transitionEnd"));
|
|
930
|
-
}), i.wrapperEl.addEventListener("transitionend", i.onTranslateToWrapperTransitionEnd))), !0;
|
|
931
|
-
}
|
|
932
|
-
var es = {
|
|
933
|
-
getTranslate: Ut,
|
|
934
|
-
setTranslate: Qt,
|
|
935
|
-
minTranslate: Kt,
|
|
936
|
-
maxTranslate: Jt,
|
|
937
|
-
translateTo: Zt
|
|
938
|
-
};
|
|
939
|
-
function ts(t, e) {
|
|
940
|
-
const s = this;
|
|
941
|
-
s.params.cssMode || (s.wrapperEl.style.transitionDuration = `${t}ms`, s.wrapperEl.style.transitionDelay = t === 0 ? "0ms" : ""), s.emit("setTransition", t, e);
|
|
942
|
-
}
|
|
943
|
-
function Je(t) {
|
|
944
|
-
let {
|
|
945
|
-
swiper: e,
|
|
946
|
-
runCallbacks: s,
|
|
947
|
-
direction: r,
|
|
948
|
-
step: n
|
|
949
|
-
} = t;
|
|
950
|
-
const {
|
|
951
|
-
activeIndex: i,
|
|
952
|
-
previousIndex: l
|
|
953
|
-
} = e;
|
|
954
|
-
let a = r;
|
|
955
|
-
if (a || (i > l ? a = "next" : i < l ? a = "prev" : a = "reset"), e.emit(`transition${n}`), s && i !== l) {
|
|
956
|
-
if (a === "reset") {
|
|
957
|
-
e.emit(`slideResetTransition${n}`);
|
|
958
|
-
return;
|
|
959
|
-
}
|
|
960
|
-
e.emit(`slideChangeTransition${n}`), a === "next" ? e.emit(`slideNextTransition${n}`) : e.emit(`slidePrevTransition${n}`);
|
|
961
|
-
}
|
|
962
|
-
}
|
|
963
|
-
function ss(t, e) {
|
|
964
|
-
t === void 0 && (t = !0);
|
|
965
|
-
const s = this, {
|
|
966
|
-
params: r
|
|
967
|
-
} = s;
|
|
968
|
-
r.cssMode || (r.autoHeight && s.updateAutoHeight(), Je({
|
|
969
|
-
swiper: s,
|
|
970
|
-
runCallbacks: t,
|
|
971
|
-
direction: e,
|
|
972
|
-
step: "Start"
|
|
973
|
-
}));
|
|
974
|
-
}
|
|
975
|
-
function rs(t, e) {
|
|
976
|
-
t === void 0 && (t = !0);
|
|
977
|
-
const s = this, {
|
|
978
|
-
params: r
|
|
979
|
-
} = s;
|
|
980
|
-
s.animating = !1, !r.cssMode && (s.setTransition(0), Je({
|
|
981
|
-
swiper: s,
|
|
982
|
-
runCallbacks: t,
|
|
983
|
-
direction: e,
|
|
984
|
-
step: "End"
|
|
985
|
-
}));
|
|
986
|
-
}
|
|
987
|
-
var is = {
|
|
988
|
-
setTransition: ts,
|
|
989
|
-
transitionStart: ss,
|
|
990
|
-
transitionEnd: rs
|
|
991
|
-
};
|
|
992
|
-
function ns(t, e, s, r, n) {
|
|
993
|
-
t === void 0 && (t = 0), s === void 0 && (s = !0), typeof t == "string" && (t = parseInt(t, 10));
|
|
994
|
-
const i = this;
|
|
995
|
-
let l = t;
|
|
996
|
-
l < 0 && (l = 0);
|
|
997
|
-
const {
|
|
998
|
-
params: a,
|
|
999
|
-
snapGrid: o,
|
|
1000
|
-
slidesGrid: c,
|
|
1001
|
-
previousIndex: d,
|
|
1002
|
-
activeIndex: u,
|
|
1003
|
-
rtlTranslate: f,
|
|
1004
|
-
wrapperEl: g,
|
|
1005
|
-
enabled: h
|
|
1006
|
-
} = i;
|
|
1007
|
-
if (!h && !r && !n || i.destroyed || i.animating && a.preventInteractionOnTransition)
|
|
1008
|
-
return !1;
|
|
1009
|
-
typeof e > "u" && (e = i.params.speed);
|
|
1010
|
-
const b = Math.min(i.params.slidesPerGroupSkip, l);
|
|
1011
|
-
let M = b + Math.floor((l - b) / i.params.slidesPerGroup);
|
|
1012
|
-
M >= o.length && (M = o.length - 1);
|
|
1013
|
-
const w = -o[M];
|
|
1014
|
-
if (a.normalizeSlideIndex)
|
|
1015
|
-
for (let y = 0; y < c.length; y += 1) {
|
|
1016
|
-
const T = -Math.floor(w * 100), A = Math.floor(c[y] * 100), I = Math.floor(c[y + 1] * 100);
|
|
1017
|
-
typeof c[y + 1] < "u" ? T >= A && T < I - (I - A) / 2 ? l = y : T >= A && T < I && (l = y + 1) : T >= A && (l = y);
|
|
1018
|
-
}
|
|
1019
|
-
if (i.initialized && l !== u && (!i.allowSlideNext && (f ? w > i.translate && w > i.minTranslate() : w < i.translate && w < i.minTranslate()) || !i.allowSlidePrev && w > i.translate && w > i.maxTranslate() && (u || 0) !== l))
|
|
1020
|
-
return !1;
|
|
1021
|
-
l !== (d || 0) && s && i.emit("beforeSlideChangeStart"), i.updateProgress(w);
|
|
1022
|
-
let p;
|
|
1023
|
-
l > u ? p = "next" : l < u ? p = "prev" : p = "reset";
|
|
1024
|
-
const m = i.virtual && i.params.virtual.enabled;
|
|
1025
|
-
if (!(m && n) && (f && -w === i.translate || !f && w === i.translate))
|
|
1026
|
-
return i.updateActiveIndex(l), a.autoHeight && i.updateAutoHeight(), i.updateSlidesClasses(), a.effect !== "slide" && i.setTranslate(w), p !== "reset" && (i.transitionStart(s, p), i.transitionEnd(s, p)), !1;
|
|
1027
|
-
if (a.cssMode) {
|
|
1028
|
-
const y = i.isHorizontal(), T = f ? w : -w;
|
|
1029
|
-
if (e === 0)
|
|
1030
|
-
m && (i.wrapperEl.style.scrollSnapType = "none", i._immediateVirtual = !0), m && !i._cssModeVirtualInitialSet && i.params.initialSlide > 0 ? (i._cssModeVirtualInitialSet = !0, requestAnimationFrame(() => {
|
|
1031
|
-
g[y ? "scrollLeft" : "scrollTop"] = T;
|
|
1032
|
-
})) : g[y ? "scrollLeft" : "scrollTop"] = T, m && requestAnimationFrame(() => {
|
|
1033
|
-
i.wrapperEl.style.scrollSnapType = "", i._immediateVirtual = !1;
|
|
1034
|
-
});
|
|
1035
|
-
else {
|
|
1036
|
-
if (!i.support.smoothScroll)
|
|
1037
|
-
return Ye({
|
|
1038
|
-
swiper: i,
|
|
1039
|
-
targetPosition: T,
|
|
1040
|
-
side: y ? "left" : "top"
|
|
1041
|
-
}), !0;
|
|
1042
|
-
g.scrollTo({
|
|
1043
|
-
[y ? "left" : "top"]: T,
|
|
1044
|
-
behavior: "smooth"
|
|
1045
|
-
});
|
|
1046
|
-
}
|
|
1047
|
-
return !0;
|
|
1048
|
-
}
|
|
1049
|
-
const v = Ke().isSafari;
|
|
1050
|
-
return m && !n && v && i.isElement && i.virtual.update(!1, !1, l), i.setTransition(e), i.setTranslate(w), i.updateActiveIndex(l), i.updateSlidesClasses(), i.emit("beforeTransitionStart", e, r), i.transitionStart(s, p), e === 0 ? i.transitionEnd(s, p) : i.animating || (i.animating = !0, i.onSlideToWrapperTransitionEnd || (i.onSlideToWrapperTransitionEnd = function(y) {
|
|
1051
|
-
!i || i.destroyed || y.target === this && (i.wrapperEl.removeEventListener("transitionend", i.onSlideToWrapperTransitionEnd), i.onSlideToWrapperTransitionEnd = null, delete i.onSlideToWrapperTransitionEnd, i.transitionEnd(s, p));
|
|
1052
|
-
}), i.wrapperEl.addEventListener("transitionend", i.onSlideToWrapperTransitionEnd)), !0;
|
|
1053
|
-
}
|
|
1054
|
-
function as(t, e, s, r) {
|
|
1055
|
-
t === void 0 && (t = 0), s === void 0 && (s = !0), typeof t == "string" && (t = parseInt(t, 10));
|
|
1056
|
-
const n = this;
|
|
1057
|
-
if (n.destroyed) return;
|
|
1058
|
-
typeof e > "u" && (e = n.params.speed);
|
|
1059
|
-
const i = n.grid && n.params.grid && n.params.grid.rows > 1;
|
|
1060
|
-
let l = t;
|
|
1061
|
-
if (n.params.loop)
|
|
1062
|
-
if (n.virtual && n.params.virtual.enabled)
|
|
1063
|
-
l = l + n.virtual.slidesBefore;
|
|
1064
|
-
else {
|
|
1065
|
-
let a;
|
|
1066
|
-
if (i) {
|
|
1067
|
-
const f = l * n.params.grid.rows;
|
|
1068
|
-
a = n.slides.find((g) => g.getAttribute("data-swiper-slide-index") * 1 === f).column;
|
|
1069
|
-
} else
|
|
1070
|
-
a = n.getSlideIndexByData(l);
|
|
1071
|
-
const o = i ? Math.ceil(n.slides.length / n.params.grid.rows) : n.slides.length, {
|
|
1072
|
-
centeredSlides: c
|
|
1073
|
-
} = n.params;
|
|
1074
|
-
let d = n.params.slidesPerView;
|
|
1075
|
-
d === "auto" ? d = n.slidesPerViewDynamic() : (d = Math.ceil(parseFloat(n.params.slidesPerView, 10)), c && d % 2 === 0 && (d = d + 1));
|
|
1076
|
-
let u = o - a < d;
|
|
1077
|
-
if (c && (u = u || a < Math.ceil(d / 2)), r && c && n.params.slidesPerView !== "auto" && !i && (u = !1), u) {
|
|
1078
|
-
const f = c ? a < n.activeIndex ? "prev" : "next" : a - n.activeIndex - 1 < n.params.slidesPerView ? "next" : "prev";
|
|
1079
|
-
n.loopFix({
|
|
1080
|
-
direction: f,
|
|
1081
|
-
slideTo: !0,
|
|
1082
|
-
activeSlideIndex: f === "next" ? a + 1 : a - o + 1,
|
|
1083
|
-
slideRealIndex: f === "next" ? n.realIndex : void 0
|
|
1084
|
-
});
|
|
1085
|
-
}
|
|
1086
|
-
if (i) {
|
|
1087
|
-
const f = l * n.params.grid.rows;
|
|
1088
|
-
l = n.slides.find((g) => g.getAttribute("data-swiper-slide-index") * 1 === f).column;
|
|
1089
|
-
} else
|
|
1090
|
-
l = n.getSlideIndexByData(l);
|
|
1091
|
-
}
|
|
1092
|
-
return requestAnimationFrame(() => {
|
|
1093
|
-
n.slideTo(l, e, s, r);
|
|
1094
|
-
}), n;
|
|
1095
|
-
}
|
|
1096
|
-
function ls(t, e, s) {
|
|
1097
|
-
e === void 0 && (e = !0);
|
|
1098
|
-
const r = this, {
|
|
1099
|
-
enabled: n,
|
|
1100
|
-
params: i,
|
|
1101
|
-
animating: l
|
|
1102
|
-
} = r;
|
|
1103
|
-
if (!n || r.destroyed) return r;
|
|
1104
|
-
typeof t > "u" && (t = r.params.speed);
|
|
1105
|
-
let a = i.slidesPerGroup;
|
|
1106
|
-
i.slidesPerView === "auto" && i.slidesPerGroup === 1 && i.slidesPerGroupAuto && (a = Math.max(r.slidesPerViewDynamic("current", !0), 1));
|
|
1107
|
-
const o = r.activeIndex < i.slidesPerGroupSkip ? 1 : a, c = r.virtual && i.virtual.enabled;
|
|
1108
|
-
if (i.loop) {
|
|
1109
|
-
if (l && !c && i.loopPreventsSliding) return !1;
|
|
1110
|
-
if (r.loopFix({
|
|
1111
|
-
direction: "next"
|
|
1112
|
-
}), r._clientLeft = r.wrapperEl.clientLeft, r.activeIndex === r.slides.length - 1 && i.cssMode)
|
|
1113
|
-
return requestAnimationFrame(() => {
|
|
1114
|
-
r.slideTo(r.activeIndex + o, t, e, s);
|
|
1115
|
-
}), !0;
|
|
1116
|
-
}
|
|
1117
|
-
return i.rewind && r.isEnd ? r.slideTo(0, t, e, s) : r.slideTo(r.activeIndex + o, t, e, s);
|
|
1118
|
-
}
|
|
1119
|
-
function os(t, e, s) {
|
|
1120
|
-
e === void 0 && (e = !0);
|
|
1121
|
-
const r = this, {
|
|
1122
|
-
params: n,
|
|
1123
|
-
snapGrid: i,
|
|
1124
|
-
slidesGrid: l,
|
|
1125
|
-
rtlTranslate: a,
|
|
1126
|
-
enabled: o,
|
|
1127
|
-
animating: c
|
|
1128
|
-
} = r;
|
|
1129
|
-
if (!o || r.destroyed) return r;
|
|
1130
|
-
typeof t > "u" && (t = r.params.speed);
|
|
1131
|
-
const d = r.virtual && n.virtual.enabled;
|
|
1132
|
-
if (n.loop) {
|
|
1133
|
-
if (c && !d && n.loopPreventsSliding) return !1;
|
|
1134
|
-
r.loopFix({
|
|
1135
|
-
direction: "prev"
|
|
1136
|
-
}), r._clientLeft = r.wrapperEl.clientLeft;
|
|
1137
|
-
}
|
|
1138
|
-
const u = a ? r.translate : -r.translate;
|
|
1139
|
-
function f(p) {
|
|
1140
|
-
return p < 0 ? -Math.floor(Math.abs(p)) : Math.floor(p);
|
|
1141
|
-
}
|
|
1142
|
-
const g = f(u), h = i.map((p) => f(p)), b = n.freeMode && n.freeMode.enabled;
|
|
1143
|
-
let M = i[h.indexOf(g) - 1];
|
|
1144
|
-
if (typeof M > "u" && (n.cssMode || b)) {
|
|
1145
|
-
let p;
|
|
1146
|
-
i.forEach((m, v) => {
|
|
1147
|
-
g >= m && (p = v);
|
|
1148
|
-
}), typeof p < "u" && (M = b ? i[p] : i[p > 0 ? p - 1 : p]);
|
|
1149
|
-
}
|
|
1150
|
-
let w = 0;
|
|
1151
|
-
if (typeof M < "u" && (w = l.indexOf(M), w < 0 && (w = r.activeIndex - 1), n.slidesPerView === "auto" && n.slidesPerGroup === 1 && n.slidesPerGroupAuto && (w = w - r.slidesPerViewDynamic("previous", !0) + 1, w = Math.max(w, 0))), n.rewind && r.isBeginning) {
|
|
1152
|
-
const p = r.params.virtual && r.params.virtual.enabled && r.virtual ? r.virtual.slides.length - 1 : r.slides.length - 1;
|
|
1153
|
-
return r.slideTo(p, t, e, s);
|
|
1154
|
-
} else if (n.loop && r.activeIndex === 0 && n.cssMode)
|
|
1155
|
-
return requestAnimationFrame(() => {
|
|
1156
|
-
r.slideTo(w, t, e, s);
|
|
1157
|
-
}), !0;
|
|
1158
|
-
return r.slideTo(w, t, e, s);
|
|
1159
|
-
}
|
|
1160
|
-
function ds(t, e, s) {
|
|
1161
|
-
e === void 0 && (e = !0);
|
|
1162
|
-
const r = this;
|
|
1163
|
-
if (!r.destroyed)
|
|
1164
|
-
return typeof t > "u" && (t = r.params.speed), r.slideTo(r.activeIndex, t, e, s);
|
|
1165
|
-
}
|
|
1166
|
-
function cs(t, e, s, r) {
|
|
1167
|
-
e === void 0 && (e = !0), r === void 0 && (r = 0.5);
|
|
1168
|
-
const n = this;
|
|
1169
|
-
if (n.destroyed) return;
|
|
1170
|
-
typeof t > "u" && (t = n.params.speed);
|
|
1171
|
-
let i = n.activeIndex;
|
|
1172
|
-
const l = Math.min(n.params.slidesPerGroupSkip, i), a = l + Math.floor((i - l) / n.params.slidesPerGroup), o = n.rtlTranslate ? n.translate : -n.translate;
|
|
1173
|
-
if (o >= n.snapGrid[a]) {
|
|
1174
|
-
const c = n.snapGrid[a], d = n.snapGrid[a + 1];
|
|
1175
|
-
o - c > (d - c) * r && (i += n.params.slidesPerGroup);
|
|
1176
|
-
} else {
|
|
1177
|
-
const c = n.snapGrid[a - 1], d = n.snapGrid[a];
|
|
1178
|
-
o - c <= (d - c) * r && (i -= n.params.slidesPerGroup);
|
|
1179
|
-
}
|
|
1180
|
-
return i = Math.max(i, 0), i = Math.min(i, n.slidesGrid.length - 1), n.slideTo(i, t, e, s);
|
|
1181
|
-
}
|
|
1182
|
-
function ps() {
|
|
1183
|
-
const t = this;
|
|
1184
|
-
if (t.destroyed) return;
|
|
1185
|
-
const {
|
|
1186
|
-
params: e,
|
|
1187
|
-
slidesEl: s
|
|
1188
|
-
} = t, r = e.slidesPerView === "auto" ? t.slidesPerViewDynamic() : e.slidesPerView;
|
|
1189
|
-
let n = t.clickedIndex, i;
|
|
1190
|
-
const l = t.isElement ? "swiper-slide" : `.${e.slideClass}`;
|
|
1191
|
-
if (e.loop) {
|
|
1192
|
-
if (t.animating) return;
|
|
1193
|
-
i = parseInt(t.clickedSlide.getAttribute("data-swiper-slide-index"), 10), e.centeredSlides ? n < t.loopedSlides - r / 2 || n > t.slides.length - t.loopedSlides + r / 2 ? (t.loopFix(), n = t.getSlideIndex(H(s, `${l}[data-swiper-slide-index="${i}"]`)[0]), xe(() => {
|
|
1194
|
-
t.slideTo(n);
|
|
1195
|
-
})) : t.slideTo(n) : n > t.slides.length - r ? (t.loopFix(), n = t.getSlideIndex(H(s, `${l}[data-swiper-slide-index="${i}"]`)[0]), xe(() => {
|
|
1196
|
-
t.slideTo(n);
|
|
1197
|
-
})) : t.slideTo(n);
|
|
1198
|
-
} else
|
|
1199
|
-
t.slideTo(n);
|
|
1200
|
-
}
|
|
1201
|
-
var us = {
|
|
1202
|
-
slideTo: ns,
|
|
1203
|
-
slideToLoop: as,
|
|
1204
|
-
slideNext: ls,
|
|
1205
|
-
slidePrev: os,
|
|
1206
|
-
slideReset: ds,
|
|
1207
|
-
slideToClosest: cs,
|
|
1208
|
-
slideToClickedSlide: ps
|
|
1209
|
-
};
|
|
1210
|
-
function ms(t, e) {
|
|
1211
|
-
const s = this, {
|
|
1212
|
-
params: r,
|
|
1213
|
-
slidesEl: n
|
|
1214
|
-
} = s;
|
|
1215
|
-
if (!r.loop || s.virtual && s.params.virtual.enabled) return;
|
|
1216
|
-
const i = () => {
|
|
1217
|
-
H(n, `.${r.slideClass}, swiper-slide`).forEach((u, f) => {
|
|
1218
|
-
u.setAttribute("data-swiper-slide-index", f);
|
|
1219
|
-
});
|
|
1220
|
-
}, l = s.grid && r.grid && r.grid.rows > 1, a = r.slidesPerGroup * (l ? r.grid.rows : 1), o = s.slides.length % a !== 0, c = l && s.slides.length % r.grid.rows !== 0, d = (u) => {
|
|
1221
|
-
for (let f = 0; f < u; f += 1) {
|
|
1222
|
-
const g = s.isElement ? de("swiper-slide", [r.slideBlankClass]) : de("div", [r.slideClass, r.slideBlankClass]);
|
|
1223
|
-
s.slidesEl.append(g);
|
|
1224
|
-
}
|
|
1225
|
-
};
|
|
1226
|
-
if (o) {
|
|
1227
|
-
if (r.loopAddBlankSlides) {
|
|
1228
|
-
const u = a - s.slides.length % a;
|
|
1229
|
-
d(u), s.recalcSlides(), s.updateSlides();
|
|
1230
|
-
} else
|
|
1231
|
-
oe("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)");
|
|
1232
|
-
i();
|
|
1233
|
-
} else if (c) {
|
|
1234
|
-
if (r.loopAddBlankSlides) {
|
|
1235
|
-
const u = r.grid.rows - s.slides.length % r.grid.rows;
|
|
1236
|
-
d(u), s.recalcSlides(), s.updateSlides();
|
|
1237
|
-
} else
|
|
1238
|
-
oe("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)");
|
|
1239
|
-
i();
|
|
1240
|
-
} else
|
|
1241
|
-
i();
|
|
1242
|
-
s.loopFix({
|
|
1243
|
-
slideRealIndex: t,
|
|
1244
|
-
direction: r.centeredSlides ? void 0 : "next",
|
|
1245
|
-
initial: e
|
|
1246
|
-
});
|
|
1247
|
-
}
|
|
1248
|
-
function fs(t) {
|
|
1249
|
-
let {
|
|
1250
|
-
slideRealIndex: e,
|
|
1251
|
-
slideTo: s = !0,
|
|
1252
|
-
direction: r,
|
|
1253
|
-
setTranslate: n,
|
|
1254
|
-
activeSlideIndex: i,
|
|
1255
|
-
initial: l,
|
|
1256
|
-
byController: a,
|
|
1257
|
-
byMousewheel: o
|
|
1258
|
-
} = t === void 0 ? {} : t;
|
|
1259
|
-
const c = this;
|
|
1260
|
-
if (!c.params.loop) return;
|
|
1261
|
-
c.emit("beforeLoopFix");
|
|
1262
|
-
const {
|
|
1263
|
-
slides: d,
|
|
1264
|
-
allowSlidePrev: u,
|
|
1265
|
-
allowSlideNext: f,
|
|
1266
|
-
slidesEl: g,
|
|
1267
|
-
params: h
|
|
1268
|
-
} = c, {
|
|
1269
|
-
centeredSlides: b,
|
|
1270
|
-
initialSlide: M
|
|
1271
|
-
} = h;
|
|
1272
|
-
if (c.allowSlidePrev = !0, c.allowSlideNext = !0, c.virtual && h.virtual.enabled) {
|
|
1273
|
-
s && (!h.centeredSlides && c.snapIndex === 0 ? c.slideTo(c.virtual.slides.length, 0, !1, !0) : h.centeredSlides && c.snapIndex < h.slidesPerView ? c.slideTo(c.virtual.slides.length + c.snapIndex, 0, !1, !0) : c.snapIndex === c.snapGrid.length - 1 && c.slideTo(c.virtual.slidesBefore, 0, !1, !0)), c.allowSlidePrev = u, c.allowSlideNext = f, c.emit("loopFix");
|
|
1274
|
-
return;
|
|
1275
|
-
}
|
|
1276
|
-
let w = h.slidesPerView;
|
|
1277
|
-
w === "auto" ? w = c.slidesPerViewDynamic() : (w = Math.ceil(parseFloat(h.slidesPerView, 10)), b && w % 2 === 0 && (w = w + 1));
|
|
1278
|
-
const p = h.slidesPerGroupAuto ? w : h.slidesPerGroup;
|
|
1279
|
-
let m = p;
|
|
1280
|
-
m % p !== 0 && (m += p - m % p), m += h.loopAdditionalSlides, c.loopedSlides = m;
|
|
1281
|
-
const v = c.grid && h.grid && h.grid.rows > 1;
|
|
1282
|
-
d.length < w + m || c.params.effect === "cards" && d.length < w + m * 2 ? oe("Swiper Loop Warning: The number of slides is not enough for loop mode, it will be disabled or not function properly. You need to add more slides (or make duplicates) or lower the values of slidesPerView and slidesPerGroup parameters") : v && h.grid.fill === "row" && oe("Swiper Loop Warning: Loop mode is not compatible with grid.fill = `row`");
|
|
1283
|
-
const y = [], T = [], A = v ? Math.ceil(d.length / h.grid.rows) : d.length, I = l && A - M < w && !b;
|
|
1284
|
-
let S = I ? M : c.activeIndex;
|
|
1285
|
-
typeof i > "u" ? i = c.getSlideIndex(d.find((C) => C.classList.contains(h.slideActiveClass))) : S = i;
|
|
1286
|
-
const E = r === "next" || !r, x = r === "prev" || !r;
|
|
1287
|
-
let k = 0, L = 0;
|
|
1288
|
-
const O = (v ? d[i].column : i) + (b && typeof n > "u" ? -w / 2 + 0.5 : 0);
|
|
1289
|
-
if (O < m) {
|
|
1290
|
-
k = Math.max(m - O, p);
|
|
1291
|
-
for (let C = 0; C < m - O; C += 1) {
|
|
1292
|
-
const z = C - Math.floor(C / A) * A;
|
|
1293
|
-
if (v) {
|
|
1294
|
-
const U = A - z - 1;
|
|
1295
|
-
for (let j = d.length - 1; j >= 0; j -= 1)
|
|
1296
|
-
d[j].column === U && y.push(j);
|
|
1297
|
-
} else
|
|
1298
|
-
y.push(A - z - 1);
|
|
1299
|
-
}
|
|
1300
|
-
} else if (O + w > A - m) {
|
|
1301
|
-
L = Math.max(O - (A - m * 2), p), I && (L = Math.max(L, w - A + M + 1));
|
|
1302
|
-
for (let C = 0; C < L; C += 1) {
|
|
1303
|
-
const z = C - Math.floor(C / A) * A;
|
|
1304
|
-
v ? d.forEach((U, j) => {
|
|
1305
|
-
U.column === z && T.push(j);
|
|
1306
|
-
}) : T.push(z);
|
|
1307
|
-
}
|
|
1308
|
-
}
|
|
1309
|
-
if (c.__preventObserver__ = !0, requestAnimationFrame(() => {
|
|
1310
|
-
c.__preventObserver__ = !1;
|
|
1311
|
-
}), c.params.effect === "cards" && d.length < w + m * 2 && (T.includes(i) && T.splice(T.indexOf(i), 1), y.includes(i) && y.splice(y.indexOf(i), 1)), x && y.forEach((C) => {
|
|
1312
|
-
d[C].swiperLoopMoveDOM = !0, g.prepend(d[C]), d[C].swiperLoopMoveDOM = !1;
|
|
1313
|
-
}), E && T.forEach((C) => {
|
|
1314
|
-
d[C].swiperLoopMoveDOM = !0, g.append(d[C]), d[C].swiperLoopMoveDOM = !1;
|
|
1315
|
-
}), c.recalcSlides(), h.slidesPerView === "auto" ? c.updateSlides() : v && (y.length > 0 && x || T.length > 0 && E) && c.slides.forEach((C, z) => {
|
|
1316
|
-
c.grid.updateSlide(z, C, c.slides);
|
|
1317
|
-
}), h.watchSlidesProgress && c.updateSlidesOffset(), s) {
|
|
1318
|
-
if (y.length > 0 && x) {
|
|
1319
|
-
if (typeof e > "u") {
|
|
1320
|
-
const C = c.slidesGrid[S], z = c.slidesGrid[S + k] - C;
|
|
1321
|
-
o ? c.setTranslate(c.translate - z) : (c.slideTo(S + Math.ceil(k), 0, !1, !0), n && (c.touchEventsData.startTranslate = c.touchEventsData.startTranslate - z, c.touchEventsData.currentTranslate = c.touchEventsData.currentTranslate - z));
|
|
1322
|
-
} else if (n) {
|
|
1323
|
-
const C = v ? y.length / h.grid.rows : y.length;
|
|
1324
|
-
c.slideTo(c.activeIndex + C, 0, !1, !0), c.touchEventsData.currentTranslate = c.translate;
|
|
1325
|
-
}
|
|
1326
|
-
} else if (T.length > 0 && E)
|
|
1327
|
-
if (typeof e > "u") {
|
|
1328
|
-
const C = c.slidesGrid[S], z = c.slidesGrid[S - L] - C;
|
|
1329
|
-
o ? c.setTranslate(c.translate - z) : (c.slideTo(S - L, 0, !1, !0), n && (c.touchEventsData.startTranslate = c.touchEventsData.startTranslate - z, c.touchEventsData.currentTranslate = c.touchEventsData.currentTranslate - z));
|
|
1330
|
-
} else {
|
|
1331
|
-
const C = v ? T.length / h.grid.rows : T.length;
|
|
1332
|
-
c.slideTo(c.activeIndex - C, 0, !1, !0);
|
|
1333
|
-
}
|
|
1334
|
-
}
|
|
1335
|
-
if (c.allowSlidePrev = u, c.allowSlideNext = f, c.controller && c.controller.control && !a) {
|
|
1336
|
-
const C = {
|
|
1337
|
-
slideRealIndex: e,
|
|
1338
|
-
direction: r,
|
|
1339
|
-
setTranslate: n,
|
|
1340
|
-
activeSlideIndex: i,
|
|
1341
|
-
byController: !0
|
|
1342
|
-
};
|
|
1343
|
-
Array.isArray(c.controller.control) ? c.controller.control.forEach((z) => {
|
|
1344
|
-
!z.destroyed && z.params.loop && z.loopFix({
|
|
1345
|
-
...C,
|
|
1346
|
-
slideTo: z.params.slidesPerView === h.slidesPerView ? s : !1
|
|
1347
|
-
});
|
|
1348
|
-
}) : c.controller.control instanceof c.constructor && c.controller.control.params.loop && c.controller.control.loopFix({
|
|
1349
|
-
...C,
|
|
1350
|
-
slideTo: c.controller.control.params.slidesPerView === h.slidesPerView ? s : !1
|
|
1351
|
-
});
|
|
1352
|
-
}
|
|
1353
|
-
c.emit("loopFix");
|
|
1354
|
-
}
|
|
1355
|
-
function hs() {
|
|
1356
|
-
const t = this, {
|
|
1357
|
-
params: e,
|
|
1358
|
-
slidesEl: s
|
|
1359
|
-
} = t;
|
|
1360
|
-
if (!e.loop || !s || t.virtual && t.params.virtual.enabled) return;
|
|
1361
|
-
t.recalcSlides();
|
|
1362
|
-
const r = [];
|
|
1363
|
-
t.slides.forEach((n) => {
|
|
1364
|
-
const i = typeof n.swiperSlideIndex > "u" ? n.getAttribute("data-swiper-slide-index") * 1 : n.swiperSlideIndex;
|
|
1365
|
-
r[i] = n;
|
|
1366
|
-
}), t.slides.forEach((n) => {
|
|
1367
|
-
n.removeAttribute("data-swiper-slide-index");
|
|
1368
|
-
}), r.forEach((n) => {
|
|
1369
|
-
s.append(n);
|
|
1370
|
-
}), t.recalcSlides(), t.slideTo(t.realIndex, 0);
|
|
1371
|
-
}
|
|
1372
|
-
var gs = {
|
|
1373
|
-
loopCreate: ms,
|
|
1374
|
-
loopFix: fs,
|
|
1375
|
-
loopDestroy: hs
|
|
1376
|
-
};
|
|
1377
|
-
function vs(t) {
|
|
1378
|
-
const e = this;
|
|
1379
|
-
if (!e.params.simulateTouch || e.params.watchOverflow && e.isLocked || e.params.cssMode) return;
|
|
1380
|
-
const s = e.params.touchEventsTarget === "container" ? e.el : e.wrapperEl;
|
|
1381
|
-
e.isElement && (e.__preventObserver__ = !0), s.style.cursor = "move", s.style.cursor = t ? "grabbing" : "grab", e.isElement && requestAnimationFrame(() => {
|
|
1382
|
-
e.__preventObserver__ = !1;
|
|
1383
|
-
});
|
|
1384
|
-
}
|
|
1385
|
-
function ws() {
|
|
1386
|
-
const t = this;
|
|
1387
|
-
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(() => {
|
|
1388
|
-
t.__preventObserver__ = !1;
|
|
1389
|
-
}));
|
|
1390
|
-
}
|
|
1391
|
-
var bs = {
|
|
1392
|
-
setGrabCursor: vs,
|
|
1393
|
-
unsetGrabCursor: ws
|
|
1394
|
-
};
|
|
1395
|
-
function ys(t, e) {
|
|
1396
|
-
e === void 0 && (e = this);
|
|
1397
|
-
function s(r) {
|
|
1398
|
-
if (!r || r === K() || r === N()) return null;
|
|
1399
|
-
r.assignedSlot && (r = r.assignedSlot);
|
|
1400
|
-
const n = r.closest(t);
|
|
1401
|
-
return !n && !r.getRootNode ? null : n || s(r.getRootNode().host);
|
|
1402
|
-
}
|
|
1403
|
-
return s(e);
|
|
1404
|
-
}
|
|
1405
|
-
function Ge(t, e, s) {
|
|
1406
|
-
const r = N(), {
|
|
1407
|
-
params: n
|
|
1408
|
-
} = t, i = n.edgeSwipeDetection, l = n.edgeSwipeThreshold;
|
|
1409
|
-
return i && (s <= l || s >= r.innerWidth - l) ? i === "prevent" ? (e.preventDefault(), !0) : !1 : !0;
|
|
1410
|
-
}
|
|
1411
|
-
function Ss(t) {
|
|
1412
|
-
const e = this, s = K();
|
|
1413
|
-
let r = t;
|
|
1414
|
-
r.originalEvent && (r = r.originalEvent);
|
|
1415
|
-
const n = e.touchEventsData;
|
|
1416
|
-
if (r.type === "pointerdown") {
|
|
1417
|
-
if (n.pointerId !== null && n.pointerId !== r.pointerId)
|
|
1418
|
-
return;
|
|
1419
|
-
n.pointerId = r.pointerId;
|
|
1420
|
-
} else r.type === "touchstart" && r.targetTouches.length === 1 && (n.touchId = r.targetTouches[0].identifier);
|
|
1421
|
-
if (r.type === "touchstart") {
|
|
1422
|
-
Ge(e, r, r.targetTouches[0].pageX);
|
|
1423
|
-
return;
|
|
1424
|
-
}
|
|
1425
|
-
const {
|
|
1426
|
-
params: i,
|
|
1427
|
-
touches: l,
|
|
1428
|
-
enabled: a
|
|
1429
|
-
} = e;
|
|
1430
|
-
if (!a || !i.simulateTouch && r.pointerType === "mouse" || e.animating && i.preventInteractionOnTransition)
|
|
1431
|
-
return;
|
|
1432
|
-
!e.animating && i.cssMode && i.loop && e.loopFix();
|
|
1433
|
-
let o = r.target;
|
|
1434
|
-
if (i.touchEventsTarget === "wrapper" && !It(o, e.wrapperEl) || "which" in r && r.which === 3 || "button" in r && r.button > 0 || n.isTouched && n.isMoved) return;
|
|
1435
|
-
const c = !!i.noSwipingClass && i.noSwipingClass !== "", d = r.composedPath ? r.composedPath() : r.path;
|
|
1436
|
-
c && r.target && r.target.shadowRoot && d && (o = d[0]);
|
|
1437
|
-
const u = i.noSwipingSelector ? i.noSwipingSelector : `.${i.noSwipingClass}`, f = !!(r.target && r.target.shadowRoot);
|
|
1438
|
-
if (i.noSwiping && (f ? ys(u, o) : o.closest(u))) {
|
|
1439
|
-
e.allowClick = !0;
|
|
1440
|
-
return;
|
|
1441
|
-
}
|
|
1442
|
-
if (i.swipeHandler && !o.closest(i.swipeHandler))
|
|
1443
|
-
return;
|
|
1444
|
-
l.currentX = r.pageX, l.currentY = r.pageY;
|
|
1445
|
-
const g = l.currentX, h = l.currentY;
|
|
1446
|
-
if (!Ge(e, r, g))
|
|
1447
|
-
return;
|
|
1448
|
-
Object.assign(n, {
|
|
1449
|
-
isTouched: !0,
|
|
1450
|
-
isMoved: !1,
|
|
1451
|
-
allowTouchCallbacks: !0,
|
|
1452
|
-
isScrolling: void 0,
|
|
1453
|
-
startMoving: void 0
|
|
1454
|
-
}), l.startX = g, l.startY = h, n.touchStartTime = le(), e.allowClick = !0, e.updateSize(), e.swipeDirection = void 0, i.threshold > 0 && (n.allowThresholdMove = !1);
|
|
1455
|
-
let b = !0;
|
|
1456
|
-
o.matches(n.focusableElements) && (b = !1, o.nodeName === "SELECT" && (n.isTouched = !1)), s.activeElement && s.activeElement.matches(n.focusableElements) && s.activeElement !== o && (r.pointerType === "mouse" || r.pointerType !== "mouse" && !o.matches(n.focusableElements)) && s.activeElement.blur();
|
|
1457
|
-
const M = b && e.allowTouchMove && i.touchStartPreventDefault;
|
|
1458
|
-
(i.touchStartForcePreventDefault || M) && !o.isContentEditable && r.preventDefault(), i.freeMode && i.freeMode.enabled && e.freeMode && e.animating && !i.cssMode && e.freeMode.onTouchStart(), e.emit("touchStart", r);
|
|
1459
|
-
}
|
|
1460
|
-
function Es(t) {
|
|
1461
|
-
const e = K(), s = this, r = s.touchEventsData, {
|
|
1462
|
-
params: n,
|
|
1463
|
-
touches: i,
|
|
1464
|
-
rtlTranslate: l,
|
|
1465
|
-
enabled: a
|
|
1466
|
-
} = s;
|
|
1467
|
-
if (!a || !n.simulateTouch && t.pointerType === "mouse") return;
|
|
1468
|
-
let o = t;
|
|
1469
|
-
if (o.originalEvent && (o = o.originalEvent), o.type === "pointermove" && (r.touchId !== null || o.pointerId !== r.pointerId))
|
|
1470
|
-
return;
|
|
1471
|
-
let c;
|
|
1472
|
-
if (o.type === "touchmove") {
|
|
1473
|
-
if (c = [...o.changedTouches].find((T) => T.identifier === r.touchId), !c || c.identifier !== r.touchId) return;
|
|
1474
|
-
} else
|
|
1475
|
-
c = o;
|
|
1476
|
-
if (!r.isTouched) {
|
|
1477
|
-
r.startMoving && r.isScrolling && s.emit("touchMoveOpposite", o);
|
|
1478
|
-
return;
|
|
1479
|
-
}
|
|
1480
|
-
const d = c.pageX, u = c.pageY;
|
|
1481
|
-
if (o.preventedByNestedSwiper) {
|
|
1482
|
-
i.startX = d, i.startY = u;
|
|
1483
|
-
return;
|
|
1484
|
-
}
|
|
1485
|
-
if (!s.allowTouchMove) {
|
|
1486
|
-
o.target.matches(r.focusableElements) || (s.allowClick = !1), r.isTouched && (Object.assign(i, {
|
|
1487
|
-
startX: d,
|
|
1488
|
-
startY: u,
|
|
1489
|
-
currentX: d,
|
|
1490
|
-
currentY: u
|
|
1491
|
-
}), r.touchStartTime = le());
|
|
1492
|
-
return;
|
|
1493
|
-
}
|
|
1494
|
-
if (n.touchReleaseOnEdges && !n.loop) {
|
|
1495
|
-
if (s.isVertical()) {
|
|
1496
|
-
if (u < i.startY && s.translate <= s.maxTranslate() || u > i.startY && s.translate >= s.minTranslate()) {
|
|
1497
|
-
r.isTouched = !1, r.isMoved = !1;
|
|
1498
|
-
return;
|
|
1499
|
-
}
|
|
1500
|
-
} else if (l && (d > i.startX && -s.translate <= s.maxTranslate() || d < i.startX && -s.translate >= s.minTranslate()) || !l && (d < i.startX && s.translate <= s.maxTranslate() || d > i.startX && s.translate >= s.minTranslate()))
|
|
1501
|
-
return;
|
|
1502
|
-
}
|
|
1503
|
-
if (e.activeElement && e.activeElement.matches(r.focusableElements) && e.activeElement !== o.target && o.pointerType !== "mouse" && e.activeElement.blur(), e.activeElement && o.target === e.activeElement && o.target.matches(r.focusableElements)) {
|
|
1504
|
-
r.isMoved = !0, s.allowClick = !1;
|
|
1505
|
-
return;
|
|
1506
|
-
}
|
|
1507
|
-
r.allowTouchCallbacks && s.emit("touchMove", o), i.previousX = i.currentX, i.previousY = i.currentY, i.currentX = d, i.currentY = u;
|
|
1508
|
-
const f = i.currentX - i.startX, g = i.currentY - i.startY;
|
|
1509
|
-
if (s.params.threshold && Math.sqrt(f ** 2 + g ** 2) < s.params.threshold) return;
|
|
1510
|
-
if (typeof r.isScrolling > "u") {
|
|
1511
|
-
let T;
|
|
1512
|
-
s.isHorizontal() && i.currentY === i.startY || s.isVertical() && i.currentX === i.startX ? r.isScrolling = !1 : f * f + g * g >= 25 && (T = Math.atan2(Math.abs(g), Math.abs(f)) * 180 / Math.PI, r.isScrolling = s.isHorizontal() ? T > n.touchAngle : 90 - T > n.touchAngle);
|
|
1513
|
-
}
|
|
1514
|
-
if (r.isScrolling && s.emit("touchMoveOpposite", o), typeof r.startMoving > "u" && (i.currentX !== i.startX || i.currentY !== i.startY) && (r.startMoving = !0), r.isScrolling || o.type === "touchmove" && r.preventTouchMoveFromPointerMove) {
|
|
1515
|
-
r.isTouched = !1;
|
|
1516
|
-
return;
|
|
1517
|
-
}
|
|
1518
|
-
if (!r.startMoving)
|
|
1519
|
-
return;
|
|
1520
|
-
s.allowClick = !1, !n.cssMode && o.cancelable && o.preventDefault(), n.touchMoveStopPropagation && !n.nested && o.stopPropagation();
|
|
1521
|
-
let h = s.isHorizontal() ? f : g, b = s.isHorizontal() ? i.currentX - i.previousX : i.currentY - i.previousY;
|
|
1522
|
-
n.oneWayMovement && (h = Math.abs(h) * (l ? 1 : -1), b = Math.abs(b) * (l ? 1 : -1)), i.diff = h, h *= n.touchRatio, l && (h = -h, b = -b);
|
|
1523
|
-
const M = s.touchesDirection;
|
|
1524
|
-
s.swipeDirection = h > 0 ? "prev" : "next", s.touchesDirection = b > 0 ? "prev" : "next";
|
|
1525
|
-
const w = s.params.loop && !n.cssMode, p = s.touchesDirection === "next" && s.allowSlideNext || s.touchesDirection === "prev" && s.allowSlidePrev;
|
|
1526
|
-
if (!r.isMoved) {
|
|
1527
|
-
if (w && p && s.loopFix({
|
|
1528
|
-
direction: s.swipeDirection
|
|
1529
|
-
}), r.startTranslate = s.getTranslate(), s.setTransition(0), s.animating) {
|
|
1530
|
-
const T = new window.CustomEvent("transitionend", {
|
|
1531
|
-
bubbles: !0,
|
|
1532
|
-
cancelable: !0,
|
|
1533
|
-
detail: {
|
|
1534
|
-
bySwiperTouchMove: !0
|
|
1535
|
-
}
|
|
1536
|
-
});
|
|
1537
|
-
s.wrapperEl.dispatchEvent(T);
|
|
1538
|
-
}
|
|
1539
|
-
r.allowMomentumBounce = !1, n.grabCursor && (s.allowSlideNext === !0 || s.allowSlidePrev === !0) && s.setGrabCursor(!0), s.emit("sliderFirstMove", o);
|
|
1540
|
-
}
|
|
1541
|
-
let m;
|
|
1542
|
-
if ((/* @__PURE__ */ new Date()).getTime(), n._loopSwapReset !== !1 && r.isMoved && r.allowThresholdMove && M !== s.touchesDirection && w && p && Math.abs(h) >= 1) {
|
|
1543
|
-
Object.assign(i, {
|
|
1544
|
-
startX: d,
|
|
1545
|
-
startY: u,
|
|
1546
|
-
currentX: d,
|
|
1547
|
-
currentY: u,
|
|
1548
|
-
startTranslate: r.currentTranslate
|
|
1549
|
-
}), r.loopSwapReset = !0, r.startTranslate = r.currentTranslate;
|
|
1550
|
-
return;
|
|
1551
|
-
}
|
|
1552
|
-
s.emit("sliderMove", o), r.isMoved = !0, r.currentTranslate = h + r.startTranslate;
|
|
1553
|
-
let v = !0, y = n.resistanceRatio;
|
|
1554
|
-
if (n.touchReleaseOnEdges && (y = 0), h > 0 ? (w && p && !m && r.allowThresholdMove && r.currentTranslate > (n.centeredSlides ? s.minTranslate() - s.slidesSizesGrid[s.activeIndex + 1] - (n.slidesPerView !== "auto" && s.slides.length - n.slidesPerView >= 2 ? s.slidesSizesGrid[s.activeIndex + 1] + s.params.spaceBetween : 0) - s.params.spaceBetween : s.minTranslate()) && s.loopFix({
|
|
1555
|
-
direction: "prev",
|
|
1556
|
-
setTranslate: !0,
|
|
1557
|
-
activeSlideIndex: 0
|
|
1558
|
-
}), r.currentTranslate > s.minTranslate() && (v = !1, n.resistance && (r.currentTranslate = s.minTranslate() - 1 + (-s.minTranslate() + r.startTranslate + h) ** y))) : h < 0 && (w && p && !m && r.allowThresholdMove && r.currentTranslate < (n.centeredSlides ? s.maxTranslate() + s.slidesSizesGrid[s.slidesSizesGrid.length - 1] + s.params.spaceBetween + (n.slidesPerView !== "auto" && s.slides.length - n.slidesPerView >= 2 ? s.slidesSizesGrid[s.slidesSizesGrid.length - 1] + s.params.spaceBetween : 0) : s.maxTranslate()) && s.loopFix({
|
|
1559
|
-
direction: "next",
|
|
1560
|
-
setTranslate: !0,
|
|
1561
|
-
activeSlideIndex: s.slides.length - (n.slidesPerView === "auto" ? s.slidesPerViewDynamic() : Math.ceil(parseFloat(n.slidesPerView, 10)))
|
|
1562
|
-
}), r.currentTranslate < s.maxTranslate() && (v = !1, n.resistance && (r.currentTranslate = s.maxTranslate() + 1 - (s.maxTranslate() - r.startTranslate - h) ** y))), v && (o.preventedByNestedSwiper = !0), !s.allowSlideNext && s.swipeDirection === "next" && r.currentTranslate < r.startTranslate && (r.currentTranslate = r.startTranslate), !s.allowSlidePrev && s.swipeDirection === "prev" && r.currentTranslate > r.startTranslate && (r.currentTranslate = r.startTranslate), !s.allowSlidePrev && !s.allowSlideNext && (r.currentTranslate = r.startTranslate), n.threshold > 0)
|
|
1563
|
-
if (Math.abs(h) > n.threshold || r.allowThresholdMove) {
|
|
1564
|
-
if (!r.allowThresholdMove) {
|
|
1565
|
-
r.allowThresholdMove = !0, i.startX = i.currentX, i.startY = i.currentY, r.currentTranslate = r.startTranslate, i.diff = s.isHorizontal() ? i.currentX - i.startX : i.currentY - i.startY;
|
|
1566
|
-
return;
|
|
1567
|
-
}
|
|
1568
|
-
} else {
|
|
1569
|
-
r.currentTranslate = r.startTranslate;
|
|
1570
|
-
return;
|
|
1571
|
-
}
|
|
1572
|
-
!n.followFinger || n.cssMode || ((n.freeMode && n.freeMode.enabled && s.freeMode || n.watchSlidesProgress) && (s.updateActiveIndex(), s.updateSlidesClasses()), n.freeMode && n.freeMode.enabled && s.freeMode && s.freeMode.onTouchMove(), s.updateProgress(r.currentTranslate), s.setTranslate(r.currentTranslate));
|
|
1573
|
-
}
|
|
1574
|
-
function xs(t) {
|
|
1575
|
-
const e = this, s = e.touchEventsData;
|
|
1576
|
-
let r = t;
|
|
1577
|
-
r.originalEvent && (r = r.originalEvent);
|
|
1578
|
-
let n;
|
|
1579
|
-
if (r.type === "touchend" || r.type === "touchcancel") {
|
|
1580
|
-
if (n = [...r.changedTouches].find((v) => v.identifier === s.touchId), !n || n.identifier !== s.touchId) return;
|
|
1581
|
-
} else {
|
|
1582
|
-
if (s.touchId !== null || r.pointerId !== s.pointerId) return;
|
|
1583
|
-
n = r;
|
|
1584
|
-
}
|
|
1585
|
-
if (["pointercancel", "pointerout", "pointerleave", "contextmenu"].includes(r.type) && !(["pointercancel", "contextmenu"].includes(r.type) && (e.browser.isSafari || e.browser.isWebView)))
|
|
1586
|
-
return;
|
|
1587
|
-
s.pointerId = null, s.touchId = null;
|
|
1588
|
-
const {
|
|
1589
|
-
params: i,
|
|
1590
|
-
touches: l,
|
|
1591
|
-
rtlTranslate: a,
|
|
1592
|
-
slidesGrid: o,
|
|
1593
|
-
enabled: c
|
|
1594
|
-
} = e;
|
|
1595
|
-
if (!c || !i.simulateTouch && r.pointerType === "mouse") return;
|
|
1596
|
-
if (s.allowTouchCallbacks && e.emit("touchEnd", r), s.allowTouchCallbacks = !1, !s.isTouched) {
|
|
1597
|
-
s.isMoved && i.grabCursor && e.setGrabCursor(!1), s.isMoved = !1, s.startMoving = !1;
|
|
1598
|
-
return;
|
|
1599
|
-
}
|
|
1600
|
-
i.grabCursor && s.isMoved && s.isTouched && (e.allowSlideNext === !0 || e.allowSlidePrev === !0) && e.setGrabCursor(!1);
|
|
1601
|
-
const d = le(), u = d - s.touchStartTime;
|
|
1602
|
-
if (e.allowClick) {
|
|
1603
|
-
const v = r.path || r.composedPath && r.composedPath();
|
|
1604
|
-
e.updateClickedSlide(v && v[0] || r.target, v), e.emit("tap click", r), u < 300 && d - s.lastClickTime < 300 && e.emit("doubleTap doubleClick", r);
|
|
1605
|
-
}
|
|
1606
|
-
if (s.lastClickTime = le(), xe(() => {
|
|
1607
|
-
e.destroyed || (e.allowClick = !0);
|
|
1608
|
-
}), !s.isTouched || !s.isMoved || !e.swipeDirection || l.diff === 0 && !s.loopSwapReset || s.currentTranslate === s.startTranslate && !s.loopSwapReset) {
|
|
1609
|
-
s.isTouched = !1, s.isMoved = !1, s.startMoving = !1;
|
|
1610
|
-
return;
|
|
1611
|
-
}
|
|
1612
|
-
s.isTouched = !1, s.isMoved = !1, s.startMoving = !1;
|
|
1613
|
-
let f;
|
|
1614
|
-
if (i.followFinger ? f = a ? e.translate : -e.translate : f = -s.currentTranslate, i.cssMode)
|
|
1615
|
-
return;
|
|
1616
|
-
if (i.freeMode && i.freeMode.enabled) {
|
|
1617
|
-
e.freeMode.onTouchEnd({
|
|
1618
|
-
currentPos: f
|
|
1619
|
-
});
|
|
1620
|
-
return;
|
|
1621
|
-
}
|
|
1622
|
-
const g = f >= -e.maxTranslate() && !e.params.loop;
|
|
1623
|
-
let h = 0, b = e.slidesSizesGrid[0];
|
|
1624
|
-
for (let v = 0; v < o.length; v += v < i.slidesPerGroupSkip ? 1 : i.slidesPerGroup) {
|
|
1625
|
-
const y = v < i.slidesPerGroupSkip - 1 ? 1 : i.slidesPerGroup;
|
|
1626
|
-
typeof o[v + y] < "u" ? (g || f >= o[v] && f < o[v + y]) && (h = v, b = o[v + y] - o[v]) : (g || f >= o[v]) && (h = v, b = o[o.length - 1] - o[o.length - 2]);
|
|
1627
|
-
}
|
|
1628
|
-
let M = null, w = null;
|
|
1629
|
-
i.rewind && (e.isBeginning ? w = i.virtual && i.virtual.enabled && e.virtual ? e.virtual.slides.length - 1 : e.slides.length - 1 : e.isEnd && (M = 0));
|
|
1630
|
-
const p = (f - o[h]) / b, m = h < i.slidesPerGroupSkip - 1 ? 1 : i.slidesPerGroup;
|
|
1631
|
-
if (u > i.longSwipesMs) {
|
|
1632
|
-
if (!i.longSwipes) {
|
|
1633
|
-
e.slideTo(e.activeIndex);
|
|
1634
|
-
return;
|
|
1635
|
-
}
|
|
1636
|
-
e.swipeDirection === "next" && (p >= i.longSwipesRatio ? e.slideTo(i.rewind && e.isEnd ? M : h + m) : e.slideTo(h)), e.swipeDirection === "prev" && (p > 1 - i.longSwipesRatio ? e.slideTo(h + m) : w !== null && p < 0 && Math.abs(p) > i.longSwipesRatio ? e.slideTo(w) : e.slideTo(h));
|
|
1637
|
-
} else {
|
|
1638
|
-
if (!i.shortSwipes) {
|
|
1639
|
-
e.slideTo(e.activeIndex);
|
|
1640
|
-
return;
|
|
1641
|
-
}
|
|
1642
|
-
e.navigation && (r.target === e.navigation.nextEl || r.target === e.navigation.prevEl) ? r.target === e.navigation.nextEl ? e.slideTo(h + m) : e.slideTo(h) : (e.swipeDirection === "next" && e.slideTo(M !== null ? M : h + m), e.swipeDirection === "prev" && e.slideTo(w !== null ? w : h));
|
|
1643
|
-
}
|
|
1644
|
-
}
|
|
1645
|
-
function Ne() {
|
|
1646
|
-
const t = this, {
|
|
1647
|
-
params: e,
|
|
1648
|
-
el: s
|
|
1649
|
-
} = t;
|
|
1650
|
-
if (s && s.offsetWidth === 0) return;
|
|
1651
|
-
e.breakpoints && t.setBreakpoint();
|
|
1652
|
-
const {
|
|
1653
|
-
allowSlideNext: r,
|
|
1654
|
-
allowSlidePrev: n,
|
|
1655
|
-
snapGrid: i
|
|
1656
|
-
} = t, l = t.virtual && t.params.virtual.enabled;
|
|
1657
|
-
t.allowSlideNext = !0, t.allowSlidePrev = !0, t.updateSize(), t.updateSlides(), t.updateSlidesClasses();
|
|
1658
|
-
const a = l && e.loop;
|
|
1659
|
-
(e.slidesPerView === "auto" || e.slidesPerView > 1) && t.isEnd && !t.isBeginning && !t.params.centeredSlides && !a ? 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(() => {
|
|
1660
|
-
t.autoplay && t.autoplay.running && t.autoplay.paused && t.autoplay.resume();
|
|
1661
|
-
}, 500)), t.allowSlidePrev = n, t.allowSlideNext = r, t.params.watchOverflow && i !== t.snapGrid && t.checkOverflow();
|
|
1662
|
-
}
|
|
1663
|
-
function Ts(t) {
|
|
1664
|
-
const e = this;
|
|
1665
|
-
e.enabled && (e.allowClick || (e.params.preventClicks && t.preventDefault(), e.params.preventClicksPropagation && e.animating && (t.stopPropagation(), t.stopImmediatePropagation())));
|
|
1666
|
-
}
|
|
1667
|
-
function Cs() {
|
|
1668
|
-
const t = this, {
|
|
1669
|
-
wrapperEl: e,
|
|
1670
|
-
rtlTranslate: s,
|
|
1671
|
-
enabled: r
|
|
1672
|
-
} = t;
|
|
1673
|
-
if (!r) return;
|
|
1674
|
-
t.previousTranslate = t.translate, t.isHorizontal() ? t.translate = -e.scrollLeft : t.translate = -e.scrollTop, t.translate === 0 && (t.translate = 0), t.updateActiveIndex(), t.updateSlidesClasses();
|
|
1675
|
-
let n;
|
|
1676
|
-
const i = t.maxTranslate() - t.minTranslate();
|
|
1677
|
-
i === 0 ? n = 0 : n = (t.translate - t.minTranslate()) / i, n !== t.progress && t.updateProgress(s ? -t.translate : t.translate), t.emit("setTranslate", t.translate, !1);
|
|
1678
|
-
}
|
|
1679
|
-
function Ps(t) {
|
|
1680
|
-
const e = this;
|
|
1681
|
-
ne(e, t.target), !(e.params.cssMode || e.params.slidesPerView !== "auto" && !e.params.autoHeight) && e.update();
|
|
1682
|
-
}
|
|
1683
|
-
function Ms() {
|
|
1684
|
-
const t = this;
|
|
1685
|
-
t.documentTouchHandlerProceeded || (t.documentTouchHandlerProceeded = !0, t.params.touchReleaseOnEdges && (t.el.style.touchAction = "auto"));
|
|
1686
|
-
}
|
|
1687
|
-
const Ze = (t, e) => {
|
|
1688
|
-
const s = K(), {
|
|
1689
|
-
params: r,
|
|
1690
|
-
el: n,
|
|
1691
|
-
wrapperEl: i,
|
|
1692
|
-
device: l
|
|
1693
|
-
} = t, a = !!r.nested, o = e === "on" ? "addEventListener" : "removeEventListener", c = e;
|
|
1694
|
-
!n || typeof n == "string" || (s[o]("touchstart", t.onDocumentTouchStart, {
|
|
1695
|
-
passive: !1,
|
|
1696
|
-
capture: a
|
|
1697
|
-
}), n[o]("touchstart", t.onTouchStart, {
|
|
1698
|
-
passive: !1
|
|
1699
|
-
}), n[o]("pointerdown", t.onTouchStart, {
|
|
1700
|
-
passive: !1
|
|
1701
|
-
}), s[o]("touchmove", t.onTouchMove, {
|
|
1702
|
-
passive: !1,
|
|
1703
|
-
capture: a
|
|
1704
|
-
}), s[o]("pointermove", t.onTouchMove, {
|
|
1705
|
-
passive: !1,
|
|
1706
|
-
capture: a
|
|
1707
|
-
}), s[o]("touchend", t.onTouchEnd, {
|
|
1708
|
-
passive: !0
|
|
1709
|
-
}), s[o]("pointerup", t.onTouchEnd, {
|
|
1710
|
-
passive: !0
|
|
1711
|
-
}), s[o]("pointercancel", t.onTouchEnd, {
|
|
1712
|
-
passive: !0
|
|
1713
|
-
}), s[o]("touchcancel", t.onTouchEnd, {
|
|
1714
|
-
passive: !0
|
|
1715
|
-
}), s[o]("pointerout", t.onTouchEnd, {
|
|
1716
|
-
passive: !0
|
|
1717
|
-
}), s[o]("pointerleave", t.onTouchEnd, {
|
|
1718
|
-
passive: !0
|
|
1719
|
-
}), s[o]("contextmenu", t.onTouchEnd, {
|
|
1720
|
-
passive: !0
|
|
1721
|
-
}), (r.preventClicks || r.preventClicksPropagation) && n[o]("click", t.onClick, !0), r.cssMode && i[o]("scroll", t.onScroll), r.updateOnWindowResize ? t[c](l.ios || l.android ? "resize orientationchange observerUpdate" : "resize observerUpdate", Ne, !0) : t[c]("observerUpdate", Ne, !0), n[o]("load", t.onLoad, {
|
|
1722
|
-
capture: !0
|
|
1723
|
-
}));
|
|
1724
|
-
};
|
|
1725
|
-
function ks() {
|
|
1726
|
-
const t = this, {
|
|
1727
|
-
params: e
|
|
1728
|
-
} = t;
|
|
1729
|
-
t.onTouchStart = Ss.bind(t), t.onTouchMove = Es.bind(t), t.onTouchEnd = xs.bind(t), t.onDocumentTouchStart = Ms.bind(t), e.cssMode && (t.onScroll = Cs.bind(t)), t.onClick = Ts.bind(t), t.onLoad = Ps.bind(t), Ze(t, "on");
|
|
1730
|
-
}
|
|
1731
|
-
function Is() {
|
|
1732
|
-
Ze(this, "off");
|
|
1733
|
-
}
|
|
1734
|
-
var Ls = {
|
|
1735
|
-
attachEvents: ks,
|
|
1736
|
-
detachEvents: Is
|
|
1737
|
-
};
|
|
1738
|
-
const Be = (t, e) => t.grid && e.grid && e.grid.rows > 1;
|
|
1739
|
-
function As() {
|
|
1740
|
-
const t = this, {
|
|
1741
|
-
realIndex: e,
|
|
1742
|
-
initialized: s,
|
|
1743
|
-
params: r,
|
|
1744
|
-
el: n
|
|
1745
|
-
} = t, i = r.breakpoints;
|
|
1746
|
-
if (!i || i && Object.keys(i).length === 0) return;
|
|
1747
|
-
const l = K(), a = r.breakpointsBase === "window" || !r.breakpointsBase ? r.breakpointsBase : "container", o = ["window", "container"].includes(r.breakpointsBase) || !r.breakpointsBase ? t.el : l.querySelector(r.breakpointsBase), c = t.getBreakpoint(i, a, o);
|
|
1748
|
-
if (!c || t.currentBreakpoint === c) return;
|
|
1749
|
-
const d = (c in i ? i[c] : void 0) || t.originalParams, u = Be(t, r), f = Be(t, d), g = t.params.grabCursor, h = d.grabCursor, b = r.enabled;
|
|
1750
|
-
u && !f ? (n.classList.remove(`${r.containerModifierClass}grid`, `${r.containerModifierClass}grid-column`), t.emitContainerClasses()) : !u && f && (n.classList.add(`${r.containerModifierClass}grid`), (d.grid.fill && d.grid.fill === "column" || !d.grid.fill && r.grid.fill === "column") && n.classList.add(`${r.containerModifierClass}grid-column`), t.emitContainerClasses()), g && !h ? t.unsetGrabCursor() : !g && h && t.setGrabCursor(), ["navigation", "pagination", "scrollbar"].forEach((y) => {
|
|
1751
|
-
if (typeof d[y] > "u") return;
|
|
1752
|
-
const T = r[y] && r[y].enabled, A = d[y] && d[y].enabled;
|
|
1753
|
-
T && !A && t[y].disable(), !T && A && t[y].enable();
|
|
1754
|
-
});
|
|
1755
|
-
const M = d.direction && d.direction !== r.direction, w = r.loop && (d.slidesPerView !== r.slidesPerView || M), p = r.loop;
|
|
1756
|
-
M && s && t.changeDirection(), B(t.params, d);
|
|
1757
|
-
const m = t.params.enabled, v = t.params.loop;
|
|
1758
|
-
Object.assign(t, {
|
|
1759
|
-
allowTouchMove: t.params.allowTouchMove,
|
|
1760
|
-
allowSlideNext: t.params.allowSlideNext,
|
|
1761
|
-
allowSlidePrev: t.params.allowSlidePrev
|
|
1762
|
-
}), b && !m ? t.disable() : !b && m && t.enable(), t.currentBreakpoint = c, t.emit("_beforeBreakpoint", d), s && (w ? (t.loopDestroy(), t.loopCreate(e), t.updateSlides()) : !p && v ? (t.loopCreate(e), t.updateSlides()) : p && !v && t.loopDestroy()), t.emit("breakpoint", d);
|
|
1763
|
-
}
|
|
1764
|
-
function Os(t, e, s) {
|
|
1765
|
-
if (e === void 0 && (e = "window"), !t || e === "container" && !s) return;
|
|
1766
|
-
let r = !1;
|
|
1767
|
-
const n = N(), i = e === "window" ? n.innerHeight : s.clientHeight, l = Object.keys(t).map((a) => {
|
|
1768
|
-
if (typeof a == "string" && a.indexOf("@") === 0) {
|
|
1769
|
-
const o = parseFloat(a.substr(1));
|
|
1770
|
-
return {
|
|
1771
|
-
value: i * o,
|
|
1772
|
-
point: a
|
|
1773
|
-
};
|
|
1774
|
-
}
|
|
1775
|
-
return {
|
|
1776
|
-
value: a,
|
|
1777
|
-
point: a
|
|
1778
|
-
};
|
|
1779
|
-
});
|
|
1780
|
-
l.sort((a, o) => parseInt(a.value, 10) - parseInt(o.value, 10));
|
|
1781
|
-
for (let a = 0; a < l.length; a += 1) {
|
|
1782
|
-
const {
|
|
1783
|
-
point: o,
|
|
1784
|
-
value: c
|
|
1785
|
-
} = l[a];
|
|
1786
|
-
e === "window" ? n.matchMedia(`(min-width: ${c}px)`).matches && (r = o) : c <= s.clientWidth && (r = o);
|
|
1787
|
-
}
|
|
1788
|
-
return r || "max";
|
|
1789
|
-
}
|
|
1790
|
-
var zs = {
|
|
1791
|
-
setBreakpoint: As,
|
|
1792
|
-
getBreakpoint: Os
|
|
1793
|
-
};
|
|
1794
|
-
function _s(t, e) {
|
|
1795
|
-
const s = [];
|
|
1796
|
-
return t.forEach((r) => {
|
|
1797
|
-
typeof r == "object" ? Object.keys(r).forEach((n) => {
|
|
1798
|
-
r[n] && s.push(e + n);
|
|
1799
|
-
}) : typeof r == "string" && s.push(e + r);
|
|
1800
|
-
}), s;
|
|
1801
|
-
}
|
|
1802
|
-
function $s() {
|
|
1803
|
-
const t = this, {
|
|
1804
|
-
classNames: e,
|
|
1805
|
-
params: s,
|
|
1806
|
-
rtl: r,
|
|
1807
|
-
el: n,
|
|
1808
|
-
device: i
|
|
1809
|
-
} = t, l = _s(["initialized", s.direction, {
|
|
1810
|
-
"free-mode": t.params.freeMode && s.freeMode.enabled
|
|
1811
|
-
}, {
|
|
1812
|
-
autoheight: s.autoHeight
|
|
1813
|
-
}, {
|
|
1814
|
-
rtl: r
|
|
1815
|
-
}, {
|
|
1816
|
-
grid: s.grid && s.grid.rows > 1
|
|
1817
|
-
}, {
|
|
1818
|
-
"grid-column": s.grid && s.grid.rows > 1 && s.grid.fill === "column"
|
|
1819
|
-
}, {
|
|
1820
|
-
android: i.android
|
|
1821
|
-
}, {
|
|
1822
|
-
ios: i.ios
|
|
1823
|
-
}, {
|
|
1824
|
-
"css-mode": s.cssMode
|
|
1825
|
-
}, {
|
|
1826
|
-
centered: s.cssMode && s.centeredSlides
|
|
1827
|
-
}, {
|
|
1828
|
-
"watch-progress": s.watchSlidesProgress
|
|
1829
|
-
}], s.containerModifierClass);
|
|
1830
|
-
e.push(...l), n.classList.add(...e), t.emitContainerClasses();
|
|
1831
|
-
}
|
|
1832
|
-
function Gs() {
|
|
1833
|
-
const t = this, {
|
|
1834
|
-
el: e,
|
|
1835
|
-
classNames: s
|
|
1836
|
-
} = t;
|
|
1837
|
-
!e || typeof e == "string" || (e.classList.remove(...s), t.emitContainerClasses());
|
|
1838
|
-
}
|
|
1839
|
-
var Ns = {
|
|
1840
|
-
addClasses: $s,
|
|
1841
|
-
removeClasses: Gs
|
|
1842
|
-
};
|
|
1843
|
-
function Bs() {
|
|
1844
|
-
const t = this, {
|
|
1845
|
-
isLocked: e,
|
|
1846
|
-
params: s
|
|
1847
|
-
} = t, {
|
|
1848
|
-
slidesOffsetBefore: r
|
|
1849
|
-
} = s;
|
|
1850
|
-
if (r) {
|
|
1851
|
-
const n = t.slides.length - 1, i = t.slidesGrid[n] + t.slidesSizesGrid[n] + r * 2;
|
|
1852
|
-
t.isLocked = t.size > i;
|
|
1853
|
-
} else
|
|
1854
|
-
t.isLocked = t.snapGrid.length === 1;
|
|
1855
|
-
s.allowSlideNext === !0 && (t.allowSlideNext = !t.isLocked), s.allowSlidePrev === !0 && (t.allowSlidePrev = !t.isLocked), e && e !== t.isLocked && (t.isEnd = !1), e !== t.isLocked && t.emit(t.isLocked ? "lock" : "unlock");
|
|
1856
|
-
}
|
|
1857
|
-
var Ds = {
|
|
1858
|
-
checkOverflow: Bs
|
|
1859
|
-
}, Pe = {
|
|
1860
|
-
init: !0,
|
|
1861
|
-
direction: "horizontal",
|
|
1862
|
-
oneWayMovement: !1,
|
|
1863
|
-
swiperElementNodeName: "SWIPER-CONTAINER",
|
|
1864
|
-
touchEventsTarget: "wrapper",
|
|
1865
|
-
initialSlide: 0,
|
|
1866
|
-
speed: 300,
|
|
1867
|
-
cssMode: !1,
|
|
1868
|
-
updateOnWindowResize: !0,
|
|
1869
|
-
resizeObserver: !0,
|
|
1870
|
-
nested: !1,
|
|
1871
|
-
createElements: !1,
|
|
1872
|
-
eventsPrefix: "swiper",
|
|
1873
|
-
enabled: !0,
|
|
1874
|
-
focusableElements: "input, select, option, textarea, button, video, label",
|
|
1875
|
-
// Overrides
|
|
1876
|
-
width: null,
|
|
1877
|
-
height: null,
|
|
1878
|
-
//
|
|
1879
|
-
preventInteractionOnTransition: !1,
|
|
1880
|
-
// ssr
|
|
1881
|
-
userAgent: null,
|
|
1882
|
-
url: null,
|
|
1883
|
-
// To support iOS's swipe-to-go-back gesture (when being used in-app).
|
|
1884
|
-
edgeSwipeDetection: !1,
|
|
1885
|
-
edgeSwipeThreshold: 20,
|
|
1886
|
-
// Autoheight
|
|
1887
|
-
autoHeight: !1,
|
|
1888
|
-
// Set wrapper width
|
|
1889
|
-
setWrapperSize: !1,
|
|
1890
|
-
// Virtual Translate
|
|
1891
|
-
virtualTranslate: !1,
|
|
1892
|
-
// Effects
|
|
1893
|
-
effect: "slide",
|
|
1894
|
-
// 'slide' or 'fade' or 'cube' or 'coverflow' or 'flip'
|
|
1895
|
-
// Breakpoints
|
|
1896
|
-
breakpoints: void 0,
|
|
1897
|
-
breakpointsBase: "window",
|
|
1898
|
-
// Slides grid
|
|
1899
|
-
spaceBetween: 0,
|
|
1900
|
-
slidesPerView: 1,
|
|
1901
|
-
slidesPerGroup: 1,
|
|
1902
|
-
slidesPerGroupSkip: 0,
|
|
1903
|
-
slidesPerGroupAuto: !1,
|
|
1904
|
-
centeredSlides: !1,
|
|
1905
|
-
centeredSlidesBounds: !1,
|
|
1906
|
-
slidesOffsetBefore: 0,
|
|
1907
|
-
// in px
|
|
1908
|
-
slidesOffsetAfter: 0,
|
|
1909
|
-
// in px
|
|
1910
|
-
normalizeSlideIndex: !0,
|
|
1911
|
-
centerInsufficientSlides: !1,
|
|
1912
|
-
// Disable swiper and hide navigation when container not overflow
|
|
1913
|
-
watchOverflow: !0,
|
|
1914
|
-
// Round length
|
|
1915
|
-
roundLengths: !1,
|
|
1916
|
-
// Touches
|
|
1917
|
-
touchRatio: 1,
|
|
1918
|
-
touchAngle: 45,
|
|
1919
|
-
simulateTouch: !0,
|
|
1920
|
-
shortSwipes: !0,
|
|
1921
|
-
longSwipes: !0,
|
|
1922
|
-
longSwipesRatio: 0.5,
|
|
1923
|
-
longSwipesMs: 300,
|
|
1924
|
-
followFinger: !0,
|
|
1925
|
-
allowTouchMove: !0,
|
|
1926
|
-
threshold: 5,
|
|
1927
|
-
touchMoveStopPropagation: !1,
|
|
1928
|
-
touchStartPreventDefault: !0,
|
|
1929
|
-
touchStartForcePreventDefault: !1,
|
|
1930
|
-
touchReleaseOnEdges: !1,
|
|
1931
|
-
// Unique Navigation Elements
|
|
1932
|
-
uniqueNavElements: !0,
|
|
1933
|
-
// Resistance
|
|
1934
|
-
resistance: !0,
|
|
1935
|
-
resistanceRatio: 0.85,
|
|
1936
|
-
// Progress
|
|
1937
|
-
watchSlidesProgress: !1,
|
|
1938
|
-
// Cursor
|
|
1939
|
-
grabCursor: !1,
|
|
1940
|
-
// Clicks
|
|
1941
|
-
preventClicks: !0,
|
|
1942
|
-
preventClicksPropagation: !0,
|
|
1943
|
-
slideToClickedSlide: !1,
|
|
1944
|
-
// loop
|
|
1945
|
-
loop: !1,
|
|
1946
|
-
loopAddBlankSlides: !0,
|
|
1947
|
-
loopAdditionalSlides: 0,
|
|
1948
|
-
loopPreventsSliding: !0,
|
|
1949
|
-
// rewind
|
|
1950
|
-
rewind: !1,
|
|
1951
|
-
// Swiping/no swiping
|
|
1952
|
-
allowSlidePrev: !0,
|
|
1953
|
-
allowSlideNext: !0,
|
|
1954
|
-
swipeHandler: null,
|
|
1955
|
-
// '.swipe-handler',
|
|
1956
|
-
noSwiping: !0,
|
|
1957
|
-
noSwipingClass: "swiper-no-swiping",
|
|
1958
|
-
noSwipingSelector: null,
|
|
1959
|
-
// Passive Listeners
|
|
1960
|
-
passiveListeners: !0,
|
|
1961
|
-
maxBackfaceHiddenSlides: 10,
|
|
1962
|
-
// NS
|
|
1963
|
-
containerModifierClass: "swiper-",
|
|
1964
|
-
// NEW
|
|
1965
|
-
slideClass: "swiper-slide",
|
|
1966
|
-
slideBlankClass: "swiper-slide-blank",
|
|
1967
|
-
slideActiveClass: "swiper-slide-active",
|
|
1968
|
-
slideVisibleClass: "swiper-slide-visible",
|
|
1969
|
-
slideFullyVisibleClass: "swiper-slide-fully-visible",
|
|
1970
|
-
slideNextClass: "swiper-slide-next",
|
|
1971
|
-
slidePrevClass: "swiper-slide-prev",
|
|
1972
|
-
wrapperClass: "swiper-wrapper",
|
|
1973
|
-
lazyPreloaderClass: "swiper-lazy-preloader",
|
|
1974
|
-
lazyPreloadPrevNext: 0,
|
|
1975
|
-
// Callbacks
|
|
1976
|
-
runCallbacksOnInit: !0,
|
|
1977
|
-
// Internals
|
|
1978
|
-
_emitClasses: !1
|
|
1979
|
-
};
|
|
1980
|
-
function Fs(t, e) {
|
|
1981
|
-
return function(s) {
|
|
1982
|
-
s === void 0 && (s = {});
|
|
1983
|
-
const r = Object.keys(s)[0], n = s[r];
|
|
1984
|
-
if (typeof n != "object" || n === null) {
|
|
1985
|
-
B(e, s);
|
|
1986
|
-
return;
|
|
1987
|
-
}
|
|
1988
|
-
if (t[r] === !0 && (t[r] = {
|
|
1989
|
-
enabled: !0
|
|
1990
|
-
}), r === "navigation" && t[r] && t[r].enabled && !t[r].prevEl && !t[r].nextEl && (t[r].auto = !0), ["pagination", "scrollbar"].indexOf(r) >= 0 && t[r] && t[r].enabled && !t[r].el && (t[r].auto = !0), !(r in t && "enabled" in n)) {
|
|
1991
|
-
B(e, s);
|
|
1992
|
-
return;
|
|
1993
|
-
}
|
|
1994
|
-
typeof t[r] == "object" && !("enabled" in t[r]) && (t[r].enabled = !0), t[r] || (t[r] = {
|
|
1995
|
-
enabled: !1
|
|
1996
|
-
}), B(e, s);
|
|
1997
|
-
};
|
|
1998
|
-
}
|
|
1999
|
-
const be = {
|
|
2000
|
-
eventsEmitter: Nt,
|
|
2001
|
-
update: Xt,
|
|
2002
|
-
translate: es,
|
|
2003
|
-
transition: is,
|
|
2004
|
-
slide: us,
|
|
2005
|
-
loop: gs,
|
|
2006
|
-
grabCursor: bs,
|
|
2007
|
-
events: Ls,
|
|
2008
|
-
breakpoints: zs,
|
|
2009
|
-
checkOverflow: Ds,
|
|
2010
|
-
classes: Ns
|
|
2011
|
-
}, ye = {};
|
|
2012
|
-
let ze = class q {
|
|
2013
|
-
constructor() {
|
|
2014
|
-
let e, s;
|
|
2015
|
-
for (var r = arguments.length, n = new Array(r), i = 0; i < r; i++)
|
|
2016
|
-
n[i] = arguments[i];
|
|
2017
|
-
n.length === 1 && n[0].constructor && Object.prototype.toString.call(n[0]).slice(8, -1) === "Object" ? s = n[0] : [e, s] = n, s || (s = {}), s = B({}, s), e && !s.el && (s.el = e);
|
|
2018
|
-
const l = K();
|
|
2019
|
-
if (s.el && typeof s.el == "string" && l.querySelectorAll(s.el).length > 1) {
|
|
2020
|
-
const d = [];
|
|
2021
|
-
return l.querySelectorAll(s.el).forEach((u) => {
|
|
2022
|
-
const f = B({}, s, {
|
|
2023
|
-
el: u
|
|
2024
|
-
});
|
|
2025
|
-
d.push(new q(f));
|
|
2026
|
-
}), d;
|
|
1
|
+
var Ce = Object.defineProperty;
|
|
2
|
+
var Ee = (e, t, n) => t in e ? Ce(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
|
+
var k = (e, t, n) => Ee(e, typeof t != "symbol" ? t + "" : t, n);
|
|
4
|
+
import { useState as S, useEffect as y, useRef as L, PureComponent as Re, useCallback as j, lazy as xe, useMemo as C, Suspense as Le, forwardRef as be, useLayoutEffect as Te, useContext as Y } from "react";
|
|
5
|
+
import { c as Z, F as De, z as Oe, Y as X } from "./hooks-B0Qttldg.js";
|
|
6
|
+
import { jsx as i, jsxs as f, Fragment as T } from "react/jsx-runtime";
|
|
7
|
+
import { I as _e, S as N, f as x, h as ee, Q as w } from "./useStreamLayerApp2.js";
|
|
8
|
+
import { h as Me } from "./index8.js";
|
|
9
|
+
import { A as O, u as v, s as u, b as Ue, c as E, a as P } from "./sl-types.js";
|
|
10
|
+
import { l as Be, a as Fe, m as ze, d as Pe, n as Ve, C as qe, S as je, b as Ke, f as W, p as Qe, c as We } from "./index11.js";
|
|
11
|
+
import { M as Ge, a as He, k as Je, z as ke, c as ye, T as Ne, I as Ye, t as Ze, f as Xe, w as te, D as et, p as tt } from "./index16.js";
|
|
12
|
+
import K from "lodash.throttle";
|
|
13
|
+
import { i as Se } from "./index-DSi8Qgfs.js";
|
|
14
|
+
import { f as nt, b as st, A as ot } from "./analytics.js";
|
|
15
|
+
import { m as F } from "./theme.js";
|
|
16
|
+
import { F as it, c as U, e as at } from "./index3.js";
|
|
17
|
+
import "nanostores";
|
|
18
|
+
import { p as G, h as rt, e as lt } from "./Question.js";
|
|
19
|
+
import { y as dt } from "./index10.js";
|
|
20
|
+
import { B as D } from "./index6.js";
|
|
21
|
+
import ct from "react-infinite-scroller";
|
|
22
|
+
import { I as pt, s as ut, e as mt } from "./index12.js";
|
|
23
|
+
import "uuid";
|
|
24
|
+
import "@nanostores/query";
|
|
25
|
+
import "./storage.js";
|
|
26
|
+
import { createPortal as ht } from "react-dom";
|
|
27
|
+
import "./notification.js";
|
|
28
|
+
const ne = Object.keys(O), se = () => {
|
|
29
|
+
const e = window.innerWidth;
|
|
30
|
+
let t = "sm";
|
|
31
|
+
for (let n = ne.length - 1; n > 0; n--) {
|
|
32
|
+
const o = ne[n];
|
|
33
|
+
if (!(e < O[o]) && e >= O[o]) {
|
|
34
|
+
t = o;
|
|
35
|
+
break;
|
|
2027
36
|
}
|
|
2028
|
-
const a = this;
|
|
2029
|
-
a.__swiper__ = !0, a.support = Ue(), a.device = Qe({
|
|
2030
|
-
userAgent: s.userAgent
|
|
2031
|
-
}), a.browser = Ke(), a.eventsListeners = {}, a.eventsAnyListeners = [], a.modules = [...a.__modules__], s.modules && Array.isArray(s.modules) && a.modules.push(...s.modules);
|
|
2032
|
-
const o = {};
|
|
2033
|
-
a.modules.forEach((d) => {
|
|
2034
|
-
d({
|
|
2035
|
-
params: s,
|
|
2036
|
-
swiper: a,
|
|
2037
|
-
extendParams: Fs(s, o),
|
|
2038
|
-
on: a.on.bind(a),
|
|
2039
|
-
once: a.once.bind(a),
|
|
2040
|
-
off: a.off.bind(a),
|
|
2041
|
-
emit: a.emit.bind(a)
|
|
2042
|
-
});
|
|
2043
|
-
});
|
|
2044
|
-
const c = B({}, Pe, o);
|
|
2045
|
-
return a.params = B({}, c, ye, s), a.originalParams = B({}, a.params), a.passedParams = B({}, s), a.params && a.params.on && Object.keys(a.params.on).forEach((d) => {
|
|
2046
|
-
a.on(d, a.params.on[d]);
|
|
2047
|
-
}), a.params && a.params.onAny && a.onAny(a.params.onAny), Object.assign(a, {
|
|
2048
|
-
enabled: a.params.enabled,
|
|
2049
|
-
el: e,
|
|
2050
|
-
// Classes
|
|
2051
|
-
classNames: [],
|
|
2052
|
-
// Slides
|
|
2053
|
-
slides: [],
|
|
2054
|
-
slidesGrid: [],
|
|
2055
|
-
snapGrid: [],
|
|
2056
|
-
slidesSizesGrid: [],
|
|
2057
|
-
// isDirection
|
|
2058
|
-
isHorizontal() {
|
|
2059
|
-
return a.params.direction === "horizontal";
|
|
2060
|
-
},
|
|
2061
|
-
isVertical() {
|
|
2062
|
-
return a.params.direction === "vertical";
|
|
2063
|
-
},
|
|
2064
|
-
// Indexes
|
|
2065
|
-
activeIndex: 0,
|
|
2066
|
-
realIndex: 0,
|
|
2067
|
-
//
|
|
2068
|
-
isBeginning: !0,
|
|
2069
|
-
isEnd: !1,
|
|
2070
|
-
// Props
|
|
2071
|
-
translate: 0,
|
|
2072
|
-
previousTranslate: 0,
|
|
2073
|
-
progress: 0,
|
|
2074
|
-
velocity: 0,
|
|
2075
|
-
animating: !1,
|
|
2076
|
-
cssOverflowAdjustment() {
|
|
2077
|
-
return Math.trunc(this.translate / 2 ** 23) * 2 ** 23;
|
|
2078
|
-
},
|
|
2079
|
-
// Locks
|
|
2080
|
-
allowSlideNext: a.params.allowSlideNext,
|
|
2081
|
-
allowSlidePrev: a.params.allowSlidePrev,
|
|
2082
|
-
// Touch Events
|
|
2083
|
-
touchEventsData: {
|
|
2084
|
-
isTouched: void 0,
|
|
2085
|
-
isMoved: void 0,
|
|
2086
|
-
allowTouchCallbacks: void 0,
|
|
2087
|
-
touchStartTime: void 0,
|
|
2088
|
-
isScrolling: void 0,
|
|
2089
|
-
currentTranslate: void 0,
|
|
2090
|
-
startTranslate: void 0,
|
|
2091
|
-
allowThresholdMove: void 0,
|
|
2092
|
-
// Form elements to match
|
|
2093
|
-
focusableElements: a.params.focusableElements,
|
|
2094
|
-
// Last click time
|
|
2095
|
-
lastClickTime: 0,
|
|
2096
|
-
clickTimeout: void 0,
|
|
2097
|
-
// Velocities
|
|
2098
|
-
velocities: [],
|
|
2099
|
-
allowMomentumBounce: void 0,
|
|
2100
|
-
startMoving: void 0,
|
|
2101
|
-
pointerId: null,
|
|
2102
|
-
touchId: null
|
|
2103
|
-
},
|
|
2104
|
-
// Clicks
|
|
2105
|
-
allowClick: !0,
|
|
2106
|
-
// Touches
|
|
2107
|
-
allowTouchMove: a.params.allowTouchMove,
|
|
2108
|
-
touches: {
|
|
2109
|
-
startX: 0,
|
|
2110
|
-
startY: 0,
|
|
2111
|
-
currentX: 0,
|
|
2112
|
-
currentY: 0,
|
|
2113
|
-
diff: 0
|
|
2114
|
-
},
|
|
2115
|
-
// Images
|
|
2116
|
-
imagesToLoad: [],
|
|
2117
|
-
imagesLoaded: 0
|
|
2118
|
-
}), a.emit("_swiper"), a.params.init && a.init(), a;
|
|
2119
|
-
}
|
|
2120
|
-
getDirectionLabel(e) {
|
|
2121
|
-
return this.isHorizontal() ? e : {
|
|
2122
|
-
width: "height",
|
|
2123
|
-
"margin-top": "margin-left",
|
|
2124
|
-
"margin-bottom ": "margin-right",
|
|
2125
|
-
"margin-left": "margin-top",
|
|
2126
|
-
"margin-right": "margin-bottom",
|
|
2127
|
-
"padding-left": "padding-top",
|
|
2128
|
-
"padding-right": "padding-bottom",
|
|
2129
|
-
marginRight: "marginBottom"
|
|
2130
|
-
}[e];
|
|
2131
|
-
}
|
|
2132
|
-
getSlideIndex(e) {
|
|
2133
|
-
const {
|
|
2134
|
-
slidesEl: s,
|
|
2135
|
-
params: r
|
|
2136
|
-
} = this, n = H(s, `.${r.slideClass}, swiper-slide`), i = ce(n[0]);
|
|
2137
|
-
return ce(e) - i;
|
|
2138
|
-
}
|
|
2139
|
-
getSlideIndexByData(e) {
|
|
2140
|
-
return this.getSlideIndex(this.slides.find((s) => s.getAttribute("data-swiper-slide-index") * 1 === e));
|
|
2141
|
-
}
|
|
2142
|
-
recalcSlides() {
|
|
2143
|
-
const e = this, {
|
|
2144
|
-
slidesEl: s,
|
|
2145
|
-
params: r
|
|
2146
|
-
} = e;
|
|
2147
|
-
e.slides = H(s, `.${r.slideClass}, swiper-slide`);
|
|
2148
|
-
}
|
|
2149
|
-
enable() {
|
|
2150
|
-
const e = this;
|
|
2151
|
-
e.enabled || (e.enabled = !0, e.params.grabCursor && e.setGrabCursor(), e.emit("enable"));
|
|
2152
|
-
}
|
|
2153
|
-
disable() {
|
|
2154
|
-
const e = this;
|
|
2155
|
-
e.enabled && (e.enabled = !1, e.params.grabCursor && e.unsetGrabCursor(), e.emit("disable"));
|
|
2156
|
-
}
|
|
2157
|
-
setProgress(e, s) {
|
|
2158
|
-
const r = this;
|
|
2159
|
-
e = Math.min(Math.max(e, 0), 1);
|
|
2160
|
-
const n = r.minTranslate(), i = (r.maxTranslate() - n) * e + n;
|
|
2161
|
-
r.translateTo(i, typeof s > "u" ? 0 : s), r.updateActiveIndex(), r.updateSlidesClasses();
|
|
2162
|
-
}
|
|
2163
|
-
emitContainerClasses() {
|
|
2164
|
-
const e = this;
|
|
2165
|
-
if (!e.params._emitClasses || !e.el) return;
|
|
2166
|
-
const s = e.el.className.split(" ").filter((r) => r.indexOf("swiper") === 0 || r.indexOf(e.params.containerModifierClass) === 0);
|
|
2167
|
-
e.emit("_containerClasses", s.join(" "));
|
|
2168
|
-
}
|
|
2169
|
-
getSlideClasses(e) {
|
|
2170
|
-
const s = this;
|
|
2171
|
-
return s.destroyed ? "" : e.className.split(" ").filter((r) => r.indexOf("swiper-slide") === 0 || r.indexOf(s.params.slideClass) === 0).join(" ");
|
|
2172
37
|
}
|
|
2173
|
-
|
|
2174
|
-
|
|
2175
|
-
|
|
2176
|
-
const s = [];
|
|
2177
|
-
e.slides.forEach((r) => {
|
|
2178
|
-
const n = e.getSlideClasses(r);
|
|
2179
|
-
s.push({
|
|
2180
|
-
slideEl: r,
|
|
2181
|
-
classNames: n
|
|
2182
|
-
}), e.emit("_slideClass", r, n);
|
|
2183
|
-
}), e.emit("_slideClasses", s);
|
|
2184
|
-
}
|
|
2185
|
-
slidesPerViewDynamic(e, s) {
|
|
2186
|
-
e === void 0 && (e = "current"), s === void 0 && (s = !1);
|
|
2187
|
-
const r = this, {
|
|
2188
|
-
params: n,
|
|
2189
|
-
slides: i,
|
|
2190
|
-
slidesGrid: l,
|
|
2191
|
-
slidesSizesGrid: a,
|
|
2192
|
-
size: o,
|
|
2193
|
-
activeIndex: c
|
|
2194
|
-
} = r;
|
|
2195
|
-
let d = 1;
|
|
2196
|
-
if (typeof n.slidesPerView == "number") return n.slidesPerView;
|
|
2197
|
-
if (n.centeredSlides) {
|
|
2198
|
-
let u = i[c] ? Math.ceil(i[c].swiperSlideSize) : 0, f;
|
|
2199
|
-
for (let g = c + 1; g < i.length; g += 1)
|
|
2200
|
-
i[g] && !f && (u += Math.ceil(i[g].swiperSlideSize), d += 1, u > o && (f = !0));
|
|
2201
|
-
for (let g = c - 1; g >= 0; g -= 1)
|
|
2202
|
-
i[g] && !f && (u += i[g].swiperSlideSize, d += 1, u > o && (f = !0));
|
|
2203
|
-
} else if (e === "current")
|
|
2204
|
-
for (let u = c + 1; u < i.length; u += 1)
|
|
2205
|
-
(s ? l[u] + a[u] - l[c] < o : l[u] - l[c] < o) && (d += 1);
|
|
2206
|
-
else
|
|
2207
|
-
for (let u = c - 1; u >= 0; u -= 1)
|
|
2208
|
-
l[c] - l[u] < o && (d += 1);
|
|
2209
|
-
return d;
|
|
2210
|
-
}
|
|
2211
|
-
update() {
|
|
2212
|
-
const e = this;
|
|
2213
|
-
if (!e || e.destroyed) return;
|
|
2214
|
-
const {
|
|
2215
|
-
snapGrid: s,
|
|
2216
|
-
params: r
|
|
2217
|
-
} = e;
|
|
2218
|
-
r.breakpoints && e.setBreakpoint(), [...e.el.querySelectorAll('[loading="lazy"]')].forEach((l) => {
|
|
2219
|
-
l.complete && ne(e, l);
|
|
2220
|
-
}), e.updateSize(), e.updateSlides(), e.updateProgress(), e.updateSlidesClasses();
|
|
2221
|
-
function n() {
|
|
2222
|
-
const l = e.rtlTranslate ? e.translate * -1 : e.translate, a = Math.min(Math.max(l, e.maxTranslate()), e.minTranslate());
|
|
2223
|
-
e.setTranslate(a), e.updateActiveIndex(), e.updateSlidesClasses();
|
|
2224
|
-
}
|
|
2225
|
-
let i;
|
|
2226
|
-
if (r.freeMode && r.freeMode.enabled && !r.cssMode)
|
|
2227
|
-
n(), r.autoHeight && e.updateAutoHeight();
|
|
2228
|
-
else {
|
|
2229
|
-
if ((r.slidesPerView === "auto" || r.slidesPerView > 1) && e.isEnd && !r.centeredSlides) {
|
|
2230
|
-
const l = e.virtual && r.virtual.enabled ? e.virtual.slides : e.slides;
|
|
2231
|
-
i = e.slideTo(l.length - 1, 0, !1, !0);
|
|
2232
|
-
} else
|
|
2233
|
-
i = e.slideTo(e.activeIndex, 0, !1, !0);
|
|
2234
|
-
i || n();
|
|
2235
|
-
}
|
|
2236
|
-
r.watchOverflow && s !== e.snapGrid && e.checkOverflow(), e.emit("update");
|
|
2237
|
-
}
|
|
2238
|
-
changeDirection(e, s) {
|
|
2239
|
-
s === void 0 && (s = !0);
|
|
2240
|
-
const r = this, n = r.params.direction;
|
|
2241
|
-
return e || (e = n === "horizontal" ? "vertical" : "horizontal"), e === n || e !== "horizontal" && e !== "vertical" || (r.el.classList.remove(`${r.params.containerModifierClass}${n}`), r.el.classList.add(`${r.params.containerModifierClass}${e}`), r.emitContainerClasses(), r.params.direction = e, r.slides.forEach((i) => {
|
|
2242
|
-
e === "vertical" ? i.style.width = "" : i.style.height = "";
|
|
2243
|
-
}), r.emit("changeDirection"), s && r.update()), r;
|
|
2244
|
-
}
|
|
2245
|
-
changeLanguageDirection(e) {
|
|
2246
|
-
const s = this;
|
|
2247
|
-
s.rtl && e === "rtl" || !s.rtl && e === "ltr" || (s.rtl = e === "rtl", s.rtlTranslate = s.params.direction === "horizontal" && s.rtl, s.rtl ? (s.el.classList.add(`${s.params.containerModifierClass}rtl`), s.el.dir = "rtl") : (s.el.classList.remove(`${s.params.containerModifierClass}rtl`), s.el.dir = "ltr"), s.update());
|
|
2248
|
-
}
|
|
2249
|
-
mount(e) {
|
|
2250
|
-
const s = this;
|
|
2251
|
-
if (s.mounted) return !0;
|
|
2252
|
-
let r = e || s.params.el;
|
|
2253
|
-
if (typeof r == "string" && (r = document.querySelector(r)), !r)
|
|
2254
|
-
return !1;
|
|
2255
|
-
r.swiper = s, r.parentNode && r.parentNode.host && r.parentNode.host.nodeName === s.params.swiperElementNodeName.toUpperCase() && (s.isElement = !0);
|
|
2256
|
-
const n = () => `.${(s.params.wrapperClass || "").trim().split(" ").join(".")}`;
|
|
2257
|
-
let i = r && r.shadowRoot && r.shadowRoot.querySelector ? r.shadowRoot.querySelector(n()) : H(r, n())[0];
|
|
2258
|
-
return !i && s.params.createElements && (i = de("div", s.params.wrapperClass), r.append(i), H(r, `.${s.params.slideClass}`).forEach((l) => {
|
|
2259
|
-
i.append(l);
|
|
2260
|
-
})), Object.assign(s, {
|
|
2261
|
-
el: r,
|
|
2262
|
-
wrapperEl: i,
|
|
2263
|
-
slidesEl: s.isElement && !r.parentNode.host.slideSlots ? r.parentNode.host : i,
|
|
2264
|
-
hostEl: s.isElement ? r.parentNode.host : r,
|
|
2265
|
-
mounted: !0,
|
|
2266
|
-
// RTL
|
|
2267
|
-
rtl: r.dir.toLowerCase() === "rtl" || Y(r, "direction") === "rtl",
|
|
2268
|
-
rtlTranslate: s.params.direction === "horizontal" && (r.dir.toLowerCase() === "rtl" || Y(r, "direction") === "rtl"),
|
|
2269
|
-
wrongRTL: Y(i, "display") === "-webkit-box"
|
|
2270
|
-
}), !0;
|
|
2271
|
-
}
|
|
2272
|
-
init(e) {
|
|
2273
|
-
const s = this;
|
|
2274
|
-
if (s.initialized || s.mount(e) === !1) return s;
|
|
2275
|
-
s.emit("beforeInit"), s.params.breakpoints && s.setBreakpoint(), s.addClasses(), s.updateSize(), s.updateSlides(), s.params.watchOverflow && s.checkOverflow(), s.params.grabCursor && s.enabled && s.setGrabCursor(), s.params.loop && s.virtual && s.params.virtual.enabled ? s.slideTo(s.params.initialSlide + s.virtual.slidesBefore, 0, s.params.runCallbacksOnInit, !1, !0) : s.slideTo(s.params.initialSlide, 0, s.params.runCallbacksOnInit, !1, !0), s.params.loop && s.loopCreate(void 0, !0), s.attachEvents();
|
|
2276
|
-
const r = [...s.el.querySelectorAll('[loading="lazy"]')];
|
|
2277
|
-
return s.isElement && r.push(...s.hostEl.querySelectorAll('[loading="lazy"]')), r.forEach((n) => {
|
|
2278
|
-
n.complete ? ne(s, n) : n.addEventListener("load", (i) => {
|
|
2279
|
-
ne(s, i.target);
|
|
2280
|
-
});
|
|
2281
|
-
}), Ce(s), s.initialized = !0, Ce(s), s.emit("init"), s.emit("afterInit"), s;
|
|
2282
|
-
}
|
|
2283
|
-
destroy(e, s) {
|
|
2284
|
-
e === void 0 && (e = !0), s === void 0 && (s = !0);
|
|
2285
|
-
const r = this, {
|
|
2286
|
-
params: n,
|
|
2287
|
-
el: i,
|
|
2288
|
-
wrapperEl: l,
|
|
2289
|
-
slides: a
|
|
2290
|
-
} = r;
|
|
2291
|
-
return typeof r.params > "u" || r.destroyed || (r.emit("beforeDestroy"), r.initialized = !1, r.detachEvents(), n.loop && r.loopDestroy(), s && (r.removeClasses(), i && typeof i != "string" && i.removeAttribute("style"), l && l.removeAttribute("style"), a && a.length && a.forEach((o) => {
|
|
2292
|
-
o.classList.remove(n.slideVisibleClass, n.slideFullyVisibleClass, n.slideActiveClass, n.slideNextClass, n.slidePrevClass), o.removeAttribute("style"), o.removeAttribute("data-swiper-slide-index");
|
|
2293
|
-
})), r.emit("destroy"), Object.keys(r.eventsListeners).forEach((o) => {
|
|
2294
|
-
r.off(o);
|
|
2295
|
-
}), e !== !1 && (r.el && typeof r.el != "string" && (r.el.swiper = null), Tt(r)), r.destroyed = !0), null;
|
|
2296
|
-
}
|
|
2297
|
-
static extendDefaults(e) {
|
|
2298
|
-
B(ye, e);
|
|
2299
|
-
}
|
|
2300
|
-
static get extendedDefaults() {
|
|
2301
|
-
return ye;
|
|
2302
|
-
}
|
|
2303
|
-
static get defaults() {
|
|
2304
|
-
return Pe;
|
|
2305
|
-
}
|
|
2306
|
-
static installModule(e) {
|
|
2307
|
-
q.prototype.__modules__ || (q.prototype.__modules__ = []);
|
|
2308
|
-
const s = q.prototype.__modules__;
|
|
2309
|
-
typeof e == "function" && s.indexOf(e) < 0 && s.push(e);
|
|
2310
|
-
}
|
|
2311
|
-
static use(e) {
|
|
2312
|
-
return Array.isArray(e) ? (e.forEach((s) => q.installModule(s)), q) : (q.installModule(e), q);
|
|
2313
|
-
}
|
|
2314
|
-
};
|
|
2315
|
-
Object.keys(be).forEach((t) => {
|
|
2316
|
-
Object.keys(be[t]).forEach((e) => {
|
|
2317
|
-
ze.prototype[e] = be[t][e];
|
|
2318
|
-
});
|
|
2319
|
-
});
|
|
2320
|
-
ze.use([$t, Gt]);
|
|
2321
|
-
const et = [
|
|
2322
|
-
"eventsPrefix",
|
|
2323
|
-
"injectStyles",
|
|
2324
|
-
"injectStylesUrls",
|
|
2325
|
-
"modules",
|
|
2326
|
-
"init",
|
|
2327
|
-
"_direction",
|
|
2328
|
-
"oneWayMovement",
|
|
2329
|
-
"swiperElementNodeName",
|
|
2330
|
-
"touchEventsTarget",
|
|
2331
|
-
"initialSlide",
|
|
2332
|
-
"_speed",
|
|
2333
|
-
"cssMode",
|
|
2334
|
-
"updateOnWindowResize",
|
|
2335
|
-
"resizeObserver",
|
|
2336
|
-
"nested",
|
|
2337
|
-
"focusableElements",
|
|
2338
|
-
"_enabled",
|
|
2339
|
-
"_width",
|
|
2340
|
-
"_height",
|
|
2341
|
-
"preventInteractionOnTransition",
|
|
2342
|
-
"userAgent",
|
|
2343
|
-
"url",
|
|
2344
|
-
"_edgeSwipeDetection",
|
|
2345
|
-
"_edgeSwipeThreshold",
|
|
2346
|
-
"_freeMode",
|
|
2347
|
-
"_autoHeight",
|
|
2348
|
-
"setWrapperSize",
|
|
2349
|
-
"virtualTranslate",
|
|
2350
|
-
"_effect",
|
|
2351
|
-
"breakpoints",
|
|
2352
|
-
"breakpointsBase",
|
|
2353
|
-
"_spaceBetween",
|
|
2354
|
-
"_slidesPerView",
|
|
2355
|
-
"maxBackfaceHiddenSlides",
|
|
2356
|
-
"_grid",
|
|
2357
|
-
"_slidesPerGroup",
|
|
2358
|
-
"_slidesPerGroupSkip",
|
|
2359
|
-
"_slidesPerGroupAuto",
|
|
2360
|
-
"_centeredSlides",
|
|
2361
|
-
"_centeredSlidesBounds",
|
|
2362
|
-
"_slidesOffsetBefore",
|
|
2363
|
-
"_slidesOffsetAfter",
|
|
2364
|
-
"normalizeSlideIndex",
|
|
2365
|
-
"_centerInsufficientSlides",
|
|
2366
|
-
"_watchOverflow",
|
|
2367
|
-
"roundLengths",
|
|
2368
|
-
"touchRatio",
|
|
2369
|
-
"touchAngle",
|
|
2370
|
-
"simulateTouch",
|
|
2371
|
-
"_shortSwipes",
|
|
2372
|
-
"_longSwipes",
|
|
2373
|
-
"longSwipesRatio",
|
|
2374
|
-
"longSwipesMs",
|
|
2375
|
-
"_followFinger",
|
|
2376
|
-
"allowTouchMove",
|
|
2377
|
-
"_threshold",
|
|
2378
|
-
"touchMoveStopPropagation",
|
|
2379
|
-
"touchStartPreventDefault",
|
|
2380
|
-
"touchStartForcePreventDefault",
|
|
2381
|
-
"touchReleaseOnEdges",
|
|
2382
|
-
"uniqueNavElements",
|
|
2383
|
-
"_resistance",
|
|
2384
|
-
"_resistanceRatio",
|
|
2385
|
-
"_watchSlidesProgress",
|
|
2386
|
-
"_grabCursor",
|
|
2387
|
-
"preventClicks",
|
|
2388
|
-
"preventClicksPropagation",
|
|
2389
|
-
"_slideToClickedSlide",
|
|
2390
|
-
"_loop",
|
|
2391
|
-
"loopAdditionalSlides",
|
|
2392
|
-
"loopAddBlankSlides",
|
|
2393
|
-
"loopPreventsSliding",
|
|
2394
|
-
"_rewind",
|
|
2395
|
-
"_allowSlidePrev",
|
|
2396
|
-
"_allowSlideNext",
|
|
2397
|
-
"_swipeHandler",
|
|
2398
|
-
"_noSwiping",
|
|
2399
|
-
"noSwipingClass",
|
|
2400
|
-
"noSwipingSelector",
|
|
2401
|
-
"passiveListeners",
|
|
2402
|
-
"containerModifierClass",
|
|
2403
|
-
"slideClass",
|
|
2404
|
-
"slideActiveClass",
|
|
2405
|
-
"slideVisibleClass",
|
|
2406
|
-
"slideFullyVisibleClass",
|
|
2407
|
-
"slideNextClass",
|
|
2408
|
-
"slidePrevClass",
|
|
2409
|
-
"slideBlankClass",
|
|
2410
|
-
"wrapperClass",
|
|
2411
|
-
"lazyPreloaderClass",
|
|
2412
|
-
"lazyPreloadPrevNext",
|
|
2413
|
-
"runCallbacksOnInit",
|
|
2414
|
-
"observer",
|
|
2415
|
-
"observeParents",
|
|
2416
|
-
"observeSlideChildren",
|
|
2417
|
-
// modules
|
|
2418
|
-
"a11y",
|
|
2419
|
-
"_autoplay",
|
|
2420
|
-
"_controller",
|
|
2421
|
-
"coverflowEffect",
|
|
2422
|
-
"cubeEffect",
|
|
2423
|
-
"fadeEffect",
|
|
2424
|
-
"flipEffect",
|
|
2425
|
-
"creativeEffect",
|
|
2426
|
-
"cardsEffect",
|
|
2427
|
-
"hashNavigation",
|
|
2428
|
-
"history",
|
|
2429
|
-
"keyboard",
|
|
2430
|
-
"mousewheel",
|
|
2431
|
-
"_navigation",
|
|
2432
|
-
"_pagination",
|
|
2433
|
-
"parallax",
|
|
2434
|
-
"_scrollbar",
|
|
2435
|
-
"_thumbs",
|
|
2436
|
-
"virtual",
|
|
2437
|
-
"zoom",
|
|
2438
|
-
"control"
|
|
2439
|
-
];
|
|
2440
|
-
function Q(t) {
|
|
2441
|
-
return typeof t == "object" && t !== null && t.constructor && Object.prototype.toString.call(t).slice(8, -1) === "Object" && !t.__swiper__;
|
|
2442
|
-
}
|
|
2443
|
-
function J(t, e) {
|
|
2444
|
-
const s = ["__proto__", "constructor", "prototype"];
|
|
2445
|
-
Object.keys(e).filter((r) => s.indexOf(r) < 0).forEach((r) => {
|
|
2446
|
-
typeof t[r] > "u" ? t[r] = e[r] : Q(e[r]) && Q(t[r]) && Object.keys(e[r]).length > 0 ? e[r].__swiper__ ? t[r] = e[r] : J(t[r], e[r]) : t[r] = e[r];
|
|
2447
|
-
});
|
|
2448
|
-
}
|
|
2449
|
-
function tt(t) {
|
|
2450
|
-
return t === void 0 && (t = {}), t.navigation && typeof t.navigation.nextEl > "u" && typeof t.navigation.prevEl > "u";
|
|
2451
|
-
}
|
|
2452
|
-
function st(t) {
|
|
2453
|
-
return t === void 0 && (t = {}), t.pagination && typeof t.pagination.el > "u";
|
|
2454
|
-
}
|
|
2455
|
-
function rt(t) {
|
|
2456
|
-
return t === void 0 && (t = {}), t.scrollbar && typeof t.scrollbar.el > "u";
|
|
2457
|
-
}
|
|
2458
|
-
function it(t) {
|
|
2459
|
-
t === void 0 && (t = "");
|
|
2460
|
-
const e = t.split(" ").map((r) => r.trim()).filter((r) => !!r), s = [];
|
|
2461
|
-
return e.forEach((r) => {
|
|
2462
|
-
s.indexOf(r) < 0 && s.push(r);
|
|
2463
|
-
}), s.join(" ");
|
|
2464
|
-
}
|
|
2465
|
-
function js(t) {
|
|
2466
|
-
return t === void 0 && (t = ""), t ? t.includes("swiper-wrapper") ? t : `swiper-wrapper ${t}` : "swiper-wrapper";
|
|
2467
|
-
}
|
|
2468
|
-
function Vs(t) {
|
|
2469
|
-
let {
|
|
2470
|
-
swiper: e,
|
|
2471
|
-
slides: s,
|
|
2472
|
-
passedParams: r,
|
|
2473
|
-
changedParams: n,
|
|
2474
|
-
nextEl: i,
|
|
2475
|
-
prevEl: l,
|
|
2476
|
-
scrollbarEl: a,
|
|
2477
|
-
paginationEl: o
|
|
2478
|
-
} = t;
|
|
2479
|
-
const c = n.filter((S) => S !== "children" && S !== "direction" && S !== "wrapperClass"), {
|
|
2480
|
-
params: d,
|
|
2481
|
-
pagination: u,
|
|
2482
|
-
navigation: f,
|
|
2483
|
-
scrollbar: g,
|
|
2484
|
-
virtual: h,
|
|
2485
|
-
thumbs: b
|
|
2486
|
-
} = e;
|
|
2487
|
-
let M, w, p, m, v, y, T, A;
|
|
2488
|
-
n.includes("thumbs") && r.thumbs && r.thumbs.swiper && !r.thumbs.swiper.destroyed && d.thumbs && (!d.thumbs.swiper || d.thumbs.swiper.destroyed) && (M = !0), n.includes("controller") && r.controller && r.controller.control && d.controller && !d.controller.control && (w = !0), n.includes("pagination") && r.pagination && (r.pagination.el || o) && (d.pagination || d.pagination === !1) && u && !u.el && (p = !0), n.includes("scrollbar") && r.scrollbar && (r.scrollbar.el || a) && (d.scrollbar || d.scrollbar === !1) && g && !g.el && (m = !0), n.includes("navigation") && r.navigation && (r.navigation.prevEl || l) && (r.navigation.nextEl || i) && (d.navigation || d.navigation === !1) && f && !f.prevEl && !f.nextEl && (v = !0);
|
|
2489
|
-
const I = (S) => {
|
|
2490
|
-
e[S] && (e[S].destroy(), S === "navigation" ? (e.isElement && (e[S].prevEl.remove(), e[S].nextEl.remove()), d[S].prevEl = void 0, d[S].nextEl = void 0, e[S].prevEl = void 0, e[S].nextEl = void 0) : (e.isElement && e[S].el.remove(), d[S].el = void 0, e[S].el = void 0));
|
|
2491
|
-
};
|
|
2492
|
-
n.includes("loop") && e.isElement && (d.loop && !r.loop ? y = !0 : !d.loop && r.loop ? T = !0 : A = !0), c.forEach((S) => {
|
|
2493
|
-
if (Q(d[S]) && Q(r[S]))
|
|
2494
|
-
Object.assign(d[S], r[S]), (S === "navigation" || S === "pagination" || S === "scrollbar") && "enabled" in r[S] && !r[S].enabled && I(S);
|
|
2495
|
-
else {
|
|
2496
|
-
const E = r[S];
|
|
2497
|
-
(E === !0 || E === !1) && (S === "navigation" || S === "pagination" || S === "scrollbar") ? E === !1 && I(S) : d[S] = r[S];
|
|
2498
|
-
}
|
|
2499
|
-
}), c.includes("controller") && !w && e.controller && e.controller.control && d.controller && d.controller.control && (e.controller.control = d.controller.control), n.includes("children") && s && h && d.virtual.enabled ? (h.slides = s, h.update(!0)) : n.includes("virtual") && h && d.virtual.enabled && (s && (h.slides = s), h.update(!0)), n.includes("children") && s && d.loop && (A = !0), M && b.init() && b.update(!0), w && (e.controller.control = d.controller.control), p && (e.isElement && (!o || typeof o == "string") && (o = document.createElement("div"), o.classList.add("swiper-pagination"), o.part.add("pagination"), e.el.appendChild(o)), o && (d.pagination.el = o), u.init(), u.render(), u.update()), m && (e.isElement && (!a || typeof a == "string") && (a = document.createElement("div"), a.classList.add("swiper-scrollbar"), a.part.add("scrollbar"), e.el.appendChild(a)), a && (d.scrollbar.el = a), g.init(), g.updateSize(), g.setTranslate()), v && (e.isElement && ((!i || typeof i == "string") && (i = document.createElement("div"), i.classList.add("swiper-button-next"), i.innerHTML = e.hostEl.constructor.nextButtonSvg, i.part.add("button-next"), e.el.appendChild(i)), (!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))), i && (d.navigation.nextEl = i), l && (d.navigation.prevEl = l), f.init(), f.update()), n.includes("allowSlideNext") && (e.allowSlideNext = r.allowSlideNext), n.includes("allowSlidePrev") && (e.allowSlidePrev = r.allowSlidePrev), n.includes("direction") && e.changeDirection(r.direction, !1), (y || A) && e.loopDestroy(), (T || A) && e.loopCreate(), e.update();
|
|
2500
|
-
}
|
|
2501
|
-
function Hs(t, e) {
|
|
2502
|
-
t === void 0 && (t = {}), e === void 0 && (e = !0);
|
|
2503
|
-
const s = {
|
|
2504
|
-
on: {}
|
|
2505
|
-
}, r = {}, n = {};
|
|
2506
|
-
J(s, Pe), s._emitClasses = !0, s.init = !1;
|
|
2507
|
-
const i = {}, l = et.map((o) => o.replace(/_/, "")), a = Object.assign({}, t);
|
|
2508
|
-
return Object.keys(a).forEach((o) => {
|
|
2509
|
-
typeof t[o] > "u" || (l.indexOf(o) >= 0 ? Q(t[o]) ? (s[o] = {}, n[o] = {}, J(s[o], t[o]), J(n[o], t[o])) : (s[o] = t[o], n[o] = t[o]) : o.search(/on[A-Z]/) === 0 && typeof t[o] == "function" ? e ? r[`${o[2].toLowerCase()}${o.substr(3)}`] = t[o] : s.on[`${o[2].toLowerCase()}${o.substr(3)}`] = t[o] : i[o] = t[o]);
|
|
2510
|
-
}), ["navigation", "pagination", "scrollbar"].forEach((o) => {
|
|
2511
|
-
s[o] === !0 && (s[o] = {}), s[o] === !1 && delete s[o];
|
|
2512
|
-
}), {
|
|
2513
|
-
params: s,
|
|
2514
|
-
passedParams: n,
|
|
2515
|
-
rest: i,
|
|
2516
|
-
events: r
|
|
2517
|
-
};
|
|
2518
|
-
}
|
|
2519
|
-
function Rs(t, e) {
|
|
2520
|
-
let {
|
|
2521
|
-
el: s,
|
|
2522
|
-
nextEl: r,
|
|
2523
|
-
prevEl: n,
|
|
2524
|
-
paginationEl: i,
|
|
2525
|
-
scrollbarEl: l,
|
|
2526
|
-
swiper: a
|
|
2527
|
-
} = t;
|
|
2528
|
-
tt(e) && r && n && (a.params.navigation.nextEl = r, a.originalParams.navigation.nextEl = r, a.params.navigation.prevEl = n, a.originalParams.navigation.prevEl = n), st(e) && i && (a.params.pagination.el = i, a.originalParams.pagination.el = i), rt(e) && l && (a.params.scrollbar.el = l, a.originalParams.scrollbar.el = l), a.init(s);
|
|
2529
|
-
}
|
|
2530
|
-
function qs(t, e, s, r, n) {
|
|
2531
|
-
const i = [];
|
|
2532
|
-
if (!e) return i;
|
|
2533
|
-
const l = (a) => {
|
|
2534
|
-
i.indexOf(a) < 0 && i.push(a);
|
|
2535
|
-
};
|
|
2536
|
-
if (s && r) {
|
|
2537
|
-
const a = r.map(n), o = s.map(n);
|
|
2538
|
-
a.join("") !== o.join("") && l("children"), r.length !== s.length && l("children");
|
|
2539
|
-
}
|
|
2540
|
-
return et.filter((a) => a[0] === "_").map((a) => a.replace(/_/, "")).forEach((a) => {
|
|
2541
|
-
if (a in t && a in e)
|
|
2542
|
-
if (Q(t[a]) && Q(e[a])) {
|
|
2543
|
-
const o = Object.keys(t[a]), c = Object.keys(e[a]);
|
|
2544
|
-
o.length !== c.length ? l(a) : (o.forEach((d) => {
|
|
2545
|
-
t[a][d] !== e[a][d] && l(a);
|
|
2546
|
-
}), c.forEach((d) => {
|
|
2547
|
-
t[a][d] !== e[a][d] && l(a);
|
|
2548
|
-
}));
|
|
2549
|
-
} else t[a] !== e[a] && l(a);
|
|
2550
|
-
}), i;
|
|
2551
|
-
}
|
|
2552
|
-
const Ws = (t) => {
|
|
2553
|
-
!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());
|
|
2554
|
-
};
|
|
2555
|
-
function pe() {
|
|
2556
|
-
return pe = Object.assign ? Object.assign.bind() : function(t) {
|
|
2557
|
-
for (var e = 1; e < arguments.length; e++) {
|
|
2558
|
-
var s = arguments[e];
|
|
2559
|
-
for (var r in s)
|
|
2560
|
-
Object.prototype.hasOwnProperty.call(s, r) && (t[r] = s[r]);
|
|
2561
|
-
}
|
|
2562
|
-
return t;
|
|
2563
|
-
}, pe.apply(this, arguments);
|
|
2564
|
-
}
|
|
2565
|
-
function nt(t) {
|
|
2566
|
-
return t.type && t.type.displayName && t.type.displayName.includes("SwiperSlide");
|
|
2567
|
-
}
|
|
2568
|
-
function at(t) {
|
|
2569
|
-
const e = [];
|
|
2570
|
-
return $.Children.toArray(t).forEach((s) => {
|
|
2571
|
-
nt(s) ? e.push(s) : s.props && s.props.children && at(s.props.children).forEach((r) => e.push(r));
|
|
2572
|
-
}), e;
|
|
2573
|
-
}
|
|
2574
|
-
function Ys(t) {
|
|
2575
|
-
const e = [], s = {
|
|
2576
|
-
"container-start": [],
|
|
2577
|
-
"container-end": [],
|
|
2578
|
-
"wrapper-start": [],
|
|
2579
|
-
"wrapper-end": []
|
|
2580
|
-
};
|
|
2581
|
-
return $.Children.toArray(t).forEach((r) => {
|
|
2582
|
-
if (nt(r))
|
|
2583
|
-
e.push(r);
|
|
2584
|
-
else if (r.props && r.props.slot && s[r.props.slot])
|
|
2585
|
-
s[r.props.slot].push(r);
|
|
2586
|
-
else if (r.props && r.props.children) {
|
|
2587
|
-
const n = at(r.props.children);
|
|
2588
|
-
n.length > 0 ? n.forEach((i) => e.push(i)) : s["container-end"].push(r);
|
|
2589
|
-
} else
|
|
2590
|
-
s["container-end"].push(r);
|
|
2591
|
-
}), {
|
|
2592
|
-
slides: e,
|
|
2593
|
-
slots: s
|
|
38
|
+
return {
|
|
39
|
+
name: t,
|
|
40
|
+
size: O[t]
|
|
2594
41
|
};
|
|
2595
|
-
}
|
|
2596
|
-
|
|
2597
|
-
|
|
2598
|
-
|
|
2599
|
-
|
|
2600
|
-
|
|
2601
|
-
|
|
2602
|
-
|
|
2603
|
-
} : {
|
|
2604
|
-
top: `${s.offset}px`
|
|
2605
|
-
}, {
|
|
2606
|
-
from: i,
|
|
2607
|
-
to: l
|
|
2608
|
-
} = s, a = t.params.loop ? -e.length : 0, o = t.params.loop ? e.length * 2 : e.length, c = [];
|
|
2609
|
-
for (let d = a; d < o; d += 1)
|
|
2610
|
-
d >= i && d <= l && c.push(e[r(d)]);
|
|
2611
|
-
return c.map((d, u) => /* @__PURE__ */ $.cloneElement(d, {
|
|
2612
|
-
swiper: t,
|
|
2613
|
-
style: n,
|
|
2614
|
-
key: d.props.virtualIndex || d.key || `slide-${u}`
|
|
42
|
+
}, oe = (e) => {
|
|
43
|
+
var t;
|
|
44
|
+
return (((t = e.current) == null ? void 0 : t.getBoundingClientRect().y) || 0) < -68;
|
|
45
|
+
}, V = () => window.matchMedia("(orientation: landscape)").matches, vt = (e) => {
|
|
46
|
+
const [t] = S(() => Se({
|
|
47
|
+
screen: se(),
|
|
48
|
+
sdkInView: oe(e),
|
|
49
|
+
sdkInDesktopView: V()
|
|
2615
50
|
}));
|
|
2616
|
-
|
|
2617
|
-
|
|
2618
|
-
|
|
2619
|
-
}
|
|
2620
|
-
const
|
|
2621
|
-
|
|
2622
|
-
|
|
2623
|
-
|
|
2624
|
-
|
|
2625
|
-
children: i,
|
|
2626
|
-
onSwiper: l,
|
|
2627
|
-
...a
|
|
2628
|
-
} = t === void 0 ? {} : t, o = !1;
|
|
2629
|
-
const [c, d] = W("swiper"), [u, f] = W(null), [g, h] = W(!1), b = D(!1), M = D(null), w = D(null), p = D(null), m = D(null), v = D(null), y = D(null), T = D(null), A = D(null), {
|
|
2630
|
-
params: I,
|
|
2631
|
-
passedParams: S,
|
|
2632
|
-
rest: E,
|
|
2633
|
-
events: x
|
|
2634
|
-
} = Hs(a), {
|
|
2635
|
-
slides: k,
|
|
2636
|
-
slots: L
|
|
2637
|
-
} = Ys(i), O = () => {
|
|
2638
|
-
h(!g);
|
|
2639
|
-
};
|
|
2640
|
-
Object.assign(I.on, {
|
|
2641
|
-
_containerClasses(G, V) {
|
|
2642
|
-
d(V);
|
|
2643
|
-
}
|
|
2644
|
-
});
|
|
2645
|
-
const C = () => {
|
|
2646
|
-
Object.assign(I.on, x), o = !0;
|
|
2647
|
-
const G = {
|
|
2648
|
-
...I
|
|
51
|
+
return y(() => {
|
|
52
|
+
const n = K(() => {
|
|
53
|
+
t.setKey("sdkInView", oe(e));
|
|
54
|
+
}, 200), o = K(() => {
|
|
55
|
+
const s = se();
|
|
56
|
+
t.setKey("screen", s), t.setKey("sdkInDesktopView", V());
|
|
57
|
+
}, 200);
|
|
58
|
+
return window.addEventListener("scroll", n), window.addEventListener("resize", o), () => {
|
|
59
|
+
window.removeEventListener("scroll", n), window.removeEventListener("resize", o);
|
|
2649
60
|
};
|
|
2650
|
-
|
|
2651
|
-
|
|
2652
|
-
|
|
2653
|
-
|
|
2654
|
-
|
|
2655
|
-
|
|
2656
|
-
|
|
2657
|
-
|
|
2658
|
-
|
|
2659
|
-
|
|
2660
|
-
|
|
2661
|
-
|
|
2662
|
-
|
|
2663
|
-
|
|
2664
|
-
|
|
2665
|
-
|
|
2666
|
-
|
|
2667
|
-
|
|
2668
|
-
|
|
2669
|
-
});
|
|
2670
|
-
};
|
|
2671
|
-
X(() => () => {
|
|
2672
|
-
w.current && w.current.off("_beforeBreakpoint", O);
|
|
2673
|
-
}), X(() => {
|
|
2674
|
-
!b.current && w.current && (w.current.emitSlidesClasses(), b.current = !0);
|
|
2675
|
-
}), ee(() => {
|
|
2676
|
-
if (e && (e.current = M.current), !!M.current)
|
|
2677
|
-
return w.current.destroyed && C(), Rs({
|
|
2678
|
-
el: M.current,
|
|
2679
|
-
nextEl: v.current,
|
|
2680
|
-
prevEl: y.current,
|
|
2681
|
-
paginationEl: T.current,
|
|
2682
|
-
scrollbarEl: A.current,
|
|
2683
|
-
swiper: w.current
|
|
2684
|
-
}, I), l && !w.current.destroyed && l(w.current), () => {
|
|
2685
|
-
w.current && !w.current.destroyed && w.current.destroy(!0, !1);
|
|
61
|
+
}, [t, e]), [t];
|
|
62
|
+
}, H = (e, t, n) => {
|
|
63
|
+
const o = t >= O.lg && t < O.xl ? 75 : 52;
|
|
64
|
+
e.current && window.scrollTo({
|
|
65
|
+
top: e.current.offsetTop - o,
|
|
66
|
+
...n
|
|
67
|
+
});
|
|
68
|
+
}, ft = 15, gt = (e, t) => {
|
|
69
|
+
const n = L(null), o = L(0), [s] = S(
|
|
70
|
+
Se({
|
|
71
|
+
scrollPosition: 0,
|
|
72
|
+
tabsShown: !0,
|
|
73
|
+
scrollDirection: "forward"
|
|
74
|
+
})
|
|
75
|
+
), r = v(t);
|
|
76
|
+
return y(() => {
|
|
77
|
+
const l = V() ? n.current : window;
|
|
78
|
+
if (!l)
|
|
79
|
+
return () => {
|
|
2686
80
|
};
|
|
2687
|
-
|
|
2688
|
-
|
|
2689
|
-
|
|
2690
|
-
|
|
2691
|
-
|
|
2692
|
-
|
|
2693
|
-
|
|
2694
|
-
|
|
2695
|
-
|
|
2696
|
-
|
|
2697
|
-
|
|
2698
|
-
|
|
2699
|
-
|
|
2700
|
-
|
|
81
|
+
const d = K((a) => {
|
|
82
|
+
var c;
|
|
83
|
+
const m = a.target;
|
|
84
|
+
if (!m)
|
|
85
|
+
return;
|
|
86
|
+
let p = 0;
|
|
87
|
+
V() ? p = m.scrollTop : p = ((c = e.current) == null ? void 0 : c.getBoundingClientRect().y) || 0;
|
|
88
|
+
const h = o.current - p;
|
|
89
|
+
if (ft > Math.abs(h))
|
|
90
|
+
return;
|
|
91
|
+
const g = o.current < p ? "forward" : "backward";
|
|
92
|
+
o.current = p, s.set({
|
|
93
|
+
scrollPosition: Math.round(p),
|
|
94
|
+
scrollDirection: g,
|
|
95
|
+
tabsShown: s.get().tabsShown
|
|
96
|
+
});
|
|
97
|
+
}, 200);
|
|
98
|
+
return l.addEventListener("scroll", d), () => {
|
|
99
|
+
l.removeEventListener("scroll", d);
|
|
2701
100
|
};
|
|
2702
|
-
}
|
|
2703
|
-
|
|
2704
|
-
|
|
2705
|
-
|
|
2706
|
-
|
|
2707
|
-
|
|
2708
|
-
|
|
2709
|
-
|
|
101
|
+
}, [s, e, r.screen]), [n, s];
|
|
102
|
+
}, q = /* @__PURE__ */ u("div")({
|
|
103
|
+
name: "LoadingContainer",
|
|
104
|
+
class: "lclc0ej",
|
|
105
|
+
propsAsIs: !1
|
|
106
|
+
}), It = ({
|
|
107
|
+
feature: e,
|
|
108
|
+
sdk: t,
|
|
109
|
+
children: n,
|
|
110
|
+
className: o,
|
|
111
|
+
noWait: s
|
|
112
|
+
}) => {
|
|
113
|
+
const r = v(e.status), l = v(t.sdkStore.slStreamId);
|
|
114
|
+
if (!s) {
|
|
115
|
+
if (l != null && l.loading && !l.data)
|
|
116
|
+
return /* @__PURE__ */ i(q, {
|
|
117
|
+
className: o,
|
|
118
|
+
children: "Event is loading..."
|
|
119
|
+
});
|
|
120
|
+
if (!(l != null && l.data))
|
|
121
|
+
return /* @__PURE__ */ i(q, {
|
|
122
|
+
className: o,
|
|
123
|
+
children: "Event is forbidden..."
|
|
124
|
+
});
|
|
125
|
+
if (r !== it.Ready)
|
|
126
|
+
return /* @__PURE__ */ i(q, {
|
|
127
|
+
className: o,
|
|
128
|
+
children: "Wait feature..."
|
|
129
|
+
});
|
|
2710
130
|
}
|
|
2711
|
-
return
|
|
2712
|
-
|
|
2713
|
-
|
|
2714
|
-
|
|
2715
|
-
|
|
2716
|
-
|
|
2717
|
-
|
|
2718
|
-
|
|
2719
|
-
|
|
2720
|
-
|
|
2721
|
-
|
|
2722
|
-
|
|
2723
|
-
|
|
2724
|
-
|
|
2725
|
-
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
ref: T,
|
|
2729
|
-
className: "swiper-pagination"
|
|
2730
|
-
}), L["container-end"]));
|
|
131
|
+
return n;
|
|
132
|
+
}, bt = /* @__PURE__ */ u("div")({
|
|
133
|
+
name: "Container",
|
|
134
|
+
class: "c115qtkr",
|
|
135
|
+
propsAsIs: !1
|
|
136
|
+
}), kt = /* @__PURE__ */ u("div")({
|
|
137
|
+
name: "STabs",
|
|
138
|
+
class: "sxnslc8",
|
|
139
|
+
propsAsIs: !1
|
|
140
|
+
}), yt = /* @__PURE__ */ u("button")({
|
|
141
|
+
name: "Button",
|
|
142
|
+
class: "b1umzux0",
|
|
143
|
+
propsAsIs: !1
|
|
144
|
+
}), Nt = /* @__PURE__ */ u("span")({
|
|
145
|
+
name: "Title",
|
|
146
|
+
class: "tspsaas",
|
|
147
|
+
propsAsIs: !1
|
|
2731
148
|
});
|
|
2732
|
-
|
|
2733
|
-
const
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
|
|
2737
|
-
|
|
2738
|
-
|
|
2739
|
-
|
|
2740
|
-
|
|
2741
|
-
|
|
2742
|
-
|
|
2743
|
-
|
|
2744
|
-
|
|
2745
|
-
|
|
2746
|
-
|
|
2747
|
-
y === u.current && g(T);
|
|
2748
|
-
}
|
|
2749
|
-
ee(() => {
|
|
2750
|
-
if (typeof c < "u" && (u.current.swiperSlideIndex = c), e && (e.current = u.current), !(!u.current || !i)) {
|
|
2751
|
-
if (i.destroyed) {
|
|
2752
|
-
f !== "swiper-slide" && g("swiper-slide");
|
|
2753
|
-
return;
|
|
2754
|
-
}
|
|
2755
|
-
return i.on("_slideClass", M), () => {
|
|
2756
|
-
i && i.off("_slideClass", M);
|
|
2757
|
-
};
|
|
149
|
+
var M = /* @__PURE__ */ ((e) => (e.HOME = "home", e.LEADERBOARD = "leaderboard", e))(M || {});
|
|
150
|
+
const ie = ({ title: e, active: t, onClick: n }) => /* @__PURE__ */ i(yt, { "data-a": "intr", onClick: n, "data-selected": t, children: /* @__PURE__ */ i(Nt, { "data-a": "intr", children: e }) }), St = ({ activePage: e = "home", toggleActivePage: t }) => /* @__PURE__ */ i(bt, { children: /* @__PURE__ */ f(kt, { "data-position": e === "home" ? "left" : "right", children: [
|
|
151
|
+
/* @__PURE__ */ i(ie, { title: "Home", active: e === "home", onClick: () => t(
|
|
152
|
+
"home"
|
|
153
|
+
/* HOME */
|
|
154
|
+
) }),
|
|
155
|
+
/* @__PURE__ */ i(
|
|
156
|
+
ie,
|
|
157
|
+
{
|
|
158
|
+
title: "Friends",
|
|
159
|
+
active: e === "leaderboard",
|
|
160
|
+
onClick: () => t(
|
|
161
|
+
"leaderboard"
|
|
162
|
+
/* LEADERBOARD */
|
|
163
|
+
)
|
|
2758
164
|
}
|
|
2759
|
-
|
|
2760
|
-
|
|
2761
|
-
|
|
2762
|
-
|
|
2763
|
-
isActive: f.indexOf("swiper-slide-active") >= 0,
|
|
2764
|
-
isVisible: f.indexOf("swiper-slide-visible") >= 0,
|
|
2765
|
-
isPrev: f.indexOf("swiper-slide-prev") >= 0,
|
|
2766
|
-
isNext: f.indexOf("swiper-slide-next") >= 0
|
|
2767
|
-
}, p = () => typeof r == "function" ? r(w) : r, m = () => {
|
|
2768
|
-
b(!0);
|
|
2769
|
-
};
|
|
2770
|
-
return /* @__PURE__ */ $.createElement(s, pe({
|
|
2771
|
-
ref: u,
|
|
2772
|
-
className: it(`${f}${n ? ` ${n}` : ""}`),
|
|
2773
|
-
"data-swiper-slide-index": o,
|
|
2774
|
-
onLoad: m
|
|
2775
|
-
}, d), l && /* @__PURE__ */ $.createElement(De.Provider, {
|
|
2776
|
-
value: w
|
|
2777
|
-
}, /* @__PURE__ */ $.createElement("div", {
|
|
2778
|
-
className: "swiper-zoom-container",
|
|
2779
|
-
"data-swiper-zoom": typeof l == "number" ? l : void 0
|
|
2780
|
-
}, p(), a && !h && /* @__PURE__ */ $.createElement("div", {
|
|
2781
|
-
className: "swiper-lazy-preloader"
|
|
2782
|
-
}))), !l && /* @__PURE__ */ $.createElement(De.Provider, {
|
|
2783
|
-
value: w
|
|
2784
|
-
}, p(), a && !h && /* @__PURE__ */ $.createElement("div", {
|
|
2785
|
-
className: "swiper-lazy-preloader"
|
|
2786
|
-
})));
|
|
2787
|
-
});
|
|
2788
|
-
ae.displayName = "SwiperSlide";
|
|
2789
|
-
const Qs = () => lt, Ks = /* @__PURE__ */ _(Qs())({
|
|
2790
|
-
name: "Carousel",
|
|
2791
|
-
class: "c1f9jjsn",
|
|
2792
|
-
propsAsIs: !0
|
|
2793
|
-
}), Me = /* @__PURE__ */ _("div")({
|
|
2794
|
-
name: "ScreenWrap",
|
|
2795
|
-
class: "s25r51y",
|
|
165
|
+
)
|
|
166
|
+
] }) }), $t = /* @__PURE__ */ u("div")({
|
|
167
|
+
name: "Container",
|
|
168
|
+
class: "c1ux29ft",
|
|
2796
169
|
propsAsIs: !1
|
|
2797
|
-
}),
|
|
2798
|
-
name: "
|
|
2799
|
-
class: "
|
|
170
|
+
}), At = () => D, wt = /* @__PURE__ */ u(At())({
|
|
171
|
+
name: "FriendsIcon",
|
|
172
|
+
class: "f10ncfg2",
|
|
2800
173
|
propsAsIs: !0
|
|
2801
|
-
}),
|
|
2802
|
-
|
|
2803
|
-
|
|
2804
|
-
|
|
2805
|
-
|
|
2806
|
-
|
|
2807
|
-
|
|
2808
|
-
}), dt = /* @__PURE__ */ _("div")({
|
|
2809
|
-
name: "ScreenTextBlock",
|
|
2810
|
-
class: "s11xps29",
|
|
174
|
+
}), Ct = /* @__PURE__ */ u("div")({
|
|
175
|
+
name: "Content",
|
|
176
|
+
class: "c1yc07bd",
|
|
177
|
+
propsAsIs: !1
|
|
178
|
+
}), Et = /* @__PURE__ */ u("div")({
|
|
179
|
+
name: "Title",
|
|
180
|
+
class: "tj6cq7w",
|
|
2811
181
|
propsAsIs: !1
|
|
2812
|
-
}),
|
|
2813
|
-
name: "
|
|
2814
|
-
class: "
|
|
182
|
+
}), Rt = /* @__PURE__ */ u("div")({
|
|
183
|
+
name: "Description",
|
|
184
|
+
class: "d1ag78xo",
|
|
2815
185
|
propsAsIs: !1
|
|
2816
|
-
}),
|
|
2817
|
-
name: "
|
|
2818
|
-
class: "
|
|
186
|
+
}), xt = () => D, Lt = /* @__PURE__ */ u(xt())({
|
|
187
|
+
name: "ArrowInviteIcon",
|
|
188
|
+
class: "awohrz6",
|
|
189
|
+
propsAsIs: !0
|
|
190
|
+
}), Tt = ({ title: e, description: t, onClick: n, className: o }) => {
|
|
191
|
+
const [s] = nt({
|
|
192
|
+
type: "invitation",
|
|
193
|
+
action: "sent",
|
|
194
|
+
payload: {
|
|
195
|
+
from: _e.TITLE_CARD
|
|
196
|
+
}
|
|
197
|
+
});
|
|
198
|
+
return /* @__PURE__ */ f($t, { "data-a": "intr", onClick: s(n), className: o, children: [
|
|
199
|
+
/* @__PURE__ */ i(wt, { name: "icon-friends" }),
|
|
200
|
+
/* @__PURE__ */ f(Ct, { children: [
|
|
201
|
+
/* @__PURE__ */ i(Et, { children: e }),
|
|
202
|
+
/* @__PURE__ */ i(Rt, { children: t })
|
|
203
|
+
] }),
|
|
204
|
+
/* @__PURE__ */ i(Lt, { name: "icon-copy" })
|
|
205
|
+
] });
|
|
206
|
+
};
|
|
207
|
+
function Dt(e) {
|
|
208
|
+
var t = e.lastRenderedStartIndex, n = e.lastRenderedStopIndex, o = e.startIndex, s = e.stopIndex;
|
|
209
|
+
return !(o > n || s < t);
|
|
210
|
+
}
|
|
211
|
+
function Ot(e) {
|
|
212
|
+
for (var t = e.isItemLoaded, n = e.itemCount, o = e.minimumBatchSize, s = e.startIndex, r = e.stopIndex, l = [], d = null, a = null, c = s; c <= r; c++) {
|
|
213
|
+
var m = t(c);
|
|
214
|
+
m ? a !== null && (l.push(d, a), d = a = null) : (a = c, d === null && (d = c));
|
|
215
|
+
}
|
|
216
|
+
if (a !== null) {
|
|
217
|
+
for (var p = Math.min(Math.max(a, d + o - 1), n - 1), h = a + 1; h <= p && !t(h); h++)
|
|
218
|
+
a = h;
|
|
219
|
+
l.push(d, a);
|
|
220
|
+
}
|
|
221
|
+
if (l.length)
|
|
222
|
+
for (; l[1] - l[0] + 1 < o && l[0] > 0; ) {
|
|
223
|
+
var g = l[0] - 1;
|
|
224
|
+
if (!t(g))
|
|
225
|
+
l[0] = g;
|
|
226
|
+
else
|
|
227
|
+
break;
|
|
228
|
+
}
|
|
229
|
+
return l;
|
|
230
|
+
}
|
|
231
|
+
var _t = function(e, t) {
|
|
232
|
+
if (!(e instanceof t))
|
|
233
|
+
throw new TypeError("Cannot call a class as a function");
|
|
234
|
+
}, Mt = /* @__PURE__ */ function() {
|
|
235
|
+
function e(t, n) {
|
|
236
|
+
for (var o = 0; o < n.length; o++) {
|
|
237
|
+
var s = n[o];
|
|
238
|
+
s.enumerable = s.enumerable || !1, s.configurable = !0, "value" in s && (s.writable = !0), Object.defineProperty(t, s.key, s);
|
|
239
|
+
}
|
|
240
|
+
}
|
|
241
|
+
return function(t, n, o) {
|
|
242
|
+
return n && e(t.prototype, n), o && e(t, o), t;
|
|
243
|
+
};
|
|
244
|
+
}(), Ut = function(e, t) {
|
|
245
|
+
if (typeof t != "function" && t !== null)
|
|
246
|
+
throw new TypeError("Super expression must either be null or a function, not " + typeof t);
|
|
247
|
+
e.prototype = Object.create(t && t.prototype, {
|
|
248
|
+
constructor: {
|
|
249
|
+
value: e,
|
|
250
|
+
enumerable: !1,
|
|
251
|
+
writable: !0,
|
|
252
|
+
configurable: !0
|
|
253
|
+
}
|
|
254
|
+
}), t && (Object.setPrototypeOf ? Object.setPrototypeOf(e, t) : e.__proto__ = t);
|
|
255
|
+
}, ae = function(e, t) {
|
|
256
|
+
if (!e)
|
|
257
|
+
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
258
|
+
return t && (typeof t == "object" || typeof t == "function") ? t : e;
|
|
259
|
+
};
|
|
260
|
+
(function(e) {
|
|
261
|
+
Ut(t, e);
|
|
262
|
+
function t() {
|
|
263
|
+
var n, o, s, r;
|
|
264
|
+
_t(this, t);
|
|
265
|
+
for (var l = arguments.length, d = Array(l), a = 0; a < l; a++)
|
|
266
|
+
d[a] = arguments[a];
|
|
267
|
+
return r = (o = (s = ae(this, (n = t.__proto__ || Object.getPrototypeOf(t)).call.apply(n, [this].concat(d))), s), s._lastRenderedStartIndex = -1, s._lastRenderedStopIndex = -1, s._memoizedUnloadedRanges = [], s._onItemsRendered = function(c) {
|
|
268
|
+
var m = c.visibleStartIndex, p = c.visibleStopIndex;
|
|
269
|
+
s._lastRenderedStartIndex = m, s._lastRenderedStopIndex = p, s._ensureRowsLoaded(m, p);
|
|
270
|
+
}, s._setRef = function(c) {
|
|
271
|
+
s._listRef = c;
|
|
272
|
+
}, o), ae(s, r);
|
|
273
|
+
}
|
|
274
|
+
return Mt(t, [{
|
|
275
|
+
key: "resetloadMoreItemsCache",
|
|
276
|
+
value: function() {
|
|
277
|
+
var o = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : !1;
|
|
278
|
+
this._memoizedUnloadedRanges = [], o && this._ensureRowsLoaded(this._lastRenderedStartIndex, this._lastRenderedStopIndex);
|
|
279
|
+
}
|
|
280
|
+
}, {
|
|
281
|
+
key: "componentDidMount",
|
|
282
|
+
value: function() {
|
|
283
|
+
}
|
|
284
|
+
}, {
|
|
285
|
+
key: "render",
|
|
286
|
+
value: function() {
|
|
287
|
+
var o = this.props.children;
|
|
288
|
+
return o({
|
|
289
|
+
onItemsRendered: this._onItemsRendered,
|
|
290
|
+
ref: this._setRef
|
|
291
|
+
});
|
|
292
|
+
}
|
|
293
|
+
}, {
|
|
294
|
+
key: "_ensureRowsLoaded",
|
|
295
|
+
value: function(o, s) {
|
|
296
|
+
var r = this.props, l = r.isItemLoaded, d = r.itemCount, a = r.minimumBatchSize, c = a === void 0 ? 10 : a, m = r.threshold, p = m === void 0 ? 15 : m, h = Ot({
|
|
297
|
+
isItemLoaded: l,
|
|
298
|
+
itemCount: d,
|
|
299
|
+
minimumBatchSize: c,
|
|
300
|
+
startIndex: Math.max(0, o - p),
|
|
301
|
+
stopIndex: Math.min(d - 1, s + p)
|
|
302
|
+
});
|
|
303
|
+
(this._memoizedUnloadedRanges.length !== h.length || this._memoizedUnloadedRanges.some(function(g, b) {
|
|
304
|
+
return h[b] !== g;
|
|
305
|
+
})) && (this._memoizedUnloadedRanges = h, this._loadUnloadedRanges(h));
|
|
306
|
+
}
|
|
307
|
+
}, {
|
|
308
|
+
key: "_loadUnloadedRanges",
|
|
309
|
+
value: function(o) {
|
|
310
|
+
for (var s = this, r = this.props.loadMoreItems || this.props.loadMoreRows, l = function(c) {
|
|
311
|
+
var m = o[c], p = o[c + 1], h = r(m, p);
|
|
312
|
+
h != null && h.then(function() {
|
|
313
|
+
if (Dt({
|
|
314
|
+
lastRenderedStartIndex: s._lastRenderedStartIndex,
|
|
315
|
+
lastRenderedStopIndex: s._lastRenderedStopIndex,
|
|
316
|
+
startIndex: m,
|
|
317
|
+
stopIndex: p
|
|
318
|
+
})) {
|
|
319
|
+
if (s._listRef == null)
|
|
320
|
+
return;
|
|
321
|
+
typeof s._listRef.resetAfterIndex == "function" ? s._listRef.resetAfterIndex(m, !0) : (typeof s._listRef._getItemStyleCache == "function" && s._listRef._getItemStyleCache(-1), s._listRef.forceUpdate());
|
|
322
|
+
}
|
|
323
|
+
});
|
|
324
|
+
}, d = 0; d < o.length; d += 2)
|
|
325
|
+
l(d);
|
|
326
|
+
}
|
|
327
|
+
}]), t;
|
|
328
|
+
})(Re);
|
|
329
|
+
const Bt = /* @__PURE__ */ u("div")({
|
|
330
|
+
name: "Container",
|
|
331
|
+
class: "culdu4a",
|
|
2819
332
|
propsAsIs: !1
|
|
2820
|
-
}),
|
|
2821
|
-
name: "
|
|
2822
|
-
class: "
|
|
333
|
+
}), Ft = /* @__PURE__ */ u("div")({
|
|
334
|
+
name: "Position",
|
|
335
|
+
class: "pwf8e69",
|
|
2823
336
|
propsAsIs: !1
|
|
2824
|
-
}),
|
|
2825
|
-
name: "
|
|
2826
|
-
class: "
|
|
337
|
+
}), zt = /* @__PURE__ */ u("img")({
|
|
338
|
+
name: "Avatar",
|
|
339
|
+
class: "atf4yh4",
|
|
2827
340
|
propsAsIs: !1
|
|
2828
|
-
}),
|
|
2829
|
-
name: "
|
|
2830
|
-
class: "
|
|
341
|
+
}), Pt = /* @__PURE__ */ u("div")({
|
|
342
|
+
name: "AvatarPlaceholder",
|
|
343
|
+
class: "a1dg29ja",
|
|
2831
344
|
propsAsIs: !1
|
|
2832
|
-
}),
|
|
2833
|
-
name: "
|
|
2834
|
-
class: "
|
|
345
|
+
}), Vt = /* @__PURE__ */ u("div")({
|
|
346
|
+
name: "Content",
|
|
347
|
+
class: "c10a68rc",
|
|
2835
348
|
propsAsIs: !1
|
|
2836
|
-
}),
|
|
2837
|
-
name: "
|
|
2838
|
-
class: "
|
|
2839
|
-
propsAsIs: !0
|
|
2840
|
-
}), Ie = ({ actionFn: t, description: e, className: s, onEvent: r }) => (X(() => {
|
|
2841
|
-
r({ type: "slBetPackReady" });
|
|
2842
|
-
}, [r]), /* @__PURE__ */ F(er, { className: s, children: [
|
|
2843
|
-
/* @__PURE__ */ P(tr, { children: "Something went wrong." }),
|
|
2844
|
-
/* @__PURE__ */ P(sr, { children: e }),
|
|
2845
|
-
/* @__PURE__ */ P(ir, { onClick: t, children: "Try again" })
|
|
2846
|
-
] })), nr = /* @__PURE__ */ _("div")({
|
|
2847
|
-
name: "ScreenContainerBox",
|
|
2848
|
-
class: "s28ooi9",
|
|
349
|
+
}), qt = /* @__PURE__ */ u("div")({
|
|
350
|
+
name: "NameContainer",
|
|
351
|
+
class: "nc4kck5",
|
|
2849
352
|
propsAsIs: !1
|
|
2850
|
-
}),
|
|
2851
|
-
name: "
|
|
2852
|
-
class: "
|
|
353
|
+
}), jt = /* @__PURE__ */ u("span")({
|
|
354
|
+
name: "Name",
|
|
355
|
+
class: "njsrqgr",
|
|
2853
356
|
propsAsIs: !1
|
|
2854
|
-
}),
|
|
2855
|
-
name: "
|
|
2856
|
-
class: "
|
|
357
|
+
}), Kt = () => D, Qt = /* @__PURE__ */ u(Kt())({
|
|
358
|
+
name: "CurrentUserBadge",
|
|
359
|
+
class: "c17uc4zr",
|
|
2857
360
|
propsAsIs: !0
|
|
2858
|
-
}),
|
|
2859
|
-
|
|
2860
|
-
|
|
2861
|
-
|
|
2862
|
-
|
|
2863
|
-
|
|
2864
|
-
|
|
2865
|
-
|
|
2866
|
-
|
|
2867
|
-
|
|
2868
|
-
|
|
2869
|
-
/* @__PURE__ */
|
|
2870
|
-
|
|
2871
|
-
{
|
|
2872
|
-
|
|
2873
|
-
|
|
2874
|
-
|
|
2875
|
-
|
|
2876
|
-
|
|
2877
|
-
);
|
|
2878
|
-
},
|
|
2879
|
-
style: { marginTop: "auto " },
|
|
2880
|
-
children: "Continue"
|
|
2881
|
-
}
|
|
2882
|
-
)
|
|
2883
|
-
] }) }, "end") : /* @__PURE__ */ P(me, { height: e, children: /* @__PURE__ */ F(Me, { children: [
|
|
2884
|
-
/* @__PURE__ */ P(ar, { src: "https://cdn.streamlayer.io/assets/sdk-web/onboarding-steps/bet_pack_end_screen.png" }),
|
|
2885
|
-
/* @__PURE__ */ P(ke, { children: "Look for more live match insights, predictions and more." }),
|
|
2886
|
-
/* @__PURE__ */ P(ue, { "data-a": "intr", onClick: () => t({ type: "slOpenGameCenter" }), children: "Open Game Center" })
|
|
2887
|
-
] }) }, "end");
|
|
2888
|
-
}, cr = /* @__PURE__ */ _("div")({
|
|
361
|
+
}), Wt = ({
|
|
362
|
+
friendsRank: e,
|
|
363
|
+
avatar: t,
|
|
364
|
+
name: n,
|
|
365
|
+
userId: o,
|
|
366
|
+
points: s,
|
|
367
|
+
isCurrentUser: r,
|
|
368
|
+
style: l
|
|
369
|
+
}) => /* @__PURE__ */ f(Bt, { "data-name": o, style: l, children: [
|
|
370
|
+
/* @__PURE__ */ i(Ft, { children: e || 0 }),
|
|
371
|
+
/* @__PURE__ */ f(Vt, { children: [
|
|
372
|
+
t ? /* @__PURE__ */ i(zt, { alt: "leaderboard-item-avatar", src: t }) : /* @__PURE__ */ i(Pt, { children: pt(n || "") }),
|
|
373
|
+
/* @__PURE__ */ f(qt, { children: [
|
|
374
|
+
/* @__PURE__ */ i(jt, { children: n || "" }),
|
|
375
|
+
r && /* @__PURE__ */ i(Qt, { name: "icon-star" })
|
|
376
|
+
] })
|
|
377
|
+
] }),
|
|
378
|
+
/* @__PURE__ */ i("div", { children: ut(s) })
|
|
379
|
+
] }), Gt = /* @__PURE__ */ u("div")({
|
|
2889
380
|
name: "Container",
|
|
2890
|
-
class: "
|
|
2891
|
-
propsAsIs: !1
|
|
2892
|
-
}), Le = ({
|
|
2893
|
-
className: t
|
|
2894
|
-
}) => /* @__PURE__ */ P(cr, {
|
|
2895
|
-
className: t,
|
|
2896
|
-
children: /* @__PURE__ */ P(ft, {})
|
|
2897
|
-
}), pr = ({ question: t, vote: e }) => t ? /* @__PURE__ */ P(ht, { close: () => {
|
|
2898
|
-
}, openedQuestion: t, vote: e, isLoading: !1, isEarlyPrediction: !0 }) : null, ur = /* @__PURE__ */ _("span")({
|
|
2899
|
-
name: "NextButton",
|
|
2900
|
-
class: "n991vvm",
|
|
381
|
+
class: "c16btbfp",
|
|
2901
382
|
propsAsIs: !1
|
|
2902
|
-
}),
|
|
2903
|
-
|
|
2904
|
-
|
|
2905
|
-
|
|
2906
|
-
|
|
2907
|
-
|
|
2908
|
-
|
|
383
|
+
}), Ht = ({
|
|
384
|
+
items: e,
|
|
385
|
+
currentUserId: t,
|
|
386
|
+
openItemDetail: n,
|
|
387
|
+
fetchMore: o,
|
|
388
|
+
scrollNode: s,
|
|
389
|
+
hasMore: r
|
|
390
|
+
}) => {
|
|
391
|
+
const l = j((d) => {
|
|
392
|
+
const a = d.target.getAttribute("data-name");
|
|
393
|
+
a && n(a);
|
|
394
|
+
}, [n]);
|
|
395
|
+
return /* @__PURE__ */ i(ct, {
|
|
396
|
+
loadMore: o,
|
|
397
|
+
initialLoad: !1,
|
|
398
|
+
hasMore: r,
|
|
399
|
+
useWindow: !1,
|
|
400
|
+
getScrollParent: () => s.current,
|
|
401
|
+
children: /* @__PURE__ */ i(Gt, {
|
|
402
|
+
"data-a": "intr",
|
|
403
|
+
onClick: l,
|
|
404
|
+
children: e.map((d) => /* @__PURE__ */ i(Wt, {
|
|
405
|
+
...d,
|
|
406
|
+
isCurrentUser: !!t && t === d.userId
|
|
407
|
+
}, d.userId))
|
|
408
|
+
})
|
|
409
|
+
});
|
|
410
|
+
}, Jt = /* @__PURE__ */ u("div")({
|
|
411
|
+
name: "InviteFriendsContainer",
|
|
412
|
+
class: "i1c9dygq",
|
|
2909
413
|
propsAsIs: !1
|
|
2910
|
-
}),
|
|
2911
|
-
|
|
2912
|
-
|
|
414
|
+
}), Yt = ({
|
|
415
|
+
deepLink: e
|
|
416
|
+
}) => /* @__PURE__ */ i(Jt, {
|
|
417
|
+
children: /* @__PURE__ */ i(Ge, {
|
|
418
|
+
inviteLink: e,
|
|
419
|
+
inviteCardTitle: "It’s More Fun With Friends",
|
|
420
|
+
inviteCardSubtext: "Invite and compete against your friends for the top spot on the leaderboard."
|
|
421
|
+
})
|
|
422
|
+
}), Zt = /* @__PURE__ */ u("div")({
|
|
423
|
+
name: "InviteLinkContainer",
|
|
424
|
+
class: "i1odbhm4",
|
|
2913
425
|
propsAsIs: !1
|
|
2914
|
-
}),
|
|
2915
|
-
|
|
2916
|
-
|
|
2917
|
-
|
|
2918
|
-
|
|
2919
|
-
|
|
2920
|
-
|
|
2921
|
-
|
|
2922
|
-
|
|
2923
|
-
|
|
2924
|
-
|
|
2925
|
-
|
|
2926
|
-
|
|
2927
|
-
|
|
2928
|
-
|
|
2929
|
-
|
|
2930
|
-
|
|
2931
|
-
|
|
2932
|
-
|
|
2933
|
-
|
|
2934
|
-
|
|
2935
|
-
|
|
2936
|
-
|
|
2937
|
-
|
|
2938
|
-
|
|
2939
|
-
|
|
2940
|
-
|
|
2941
|
-
|
|
2942
|
-
|
|
2943
|
-
|
|
2944
|
-
|
|
2945
|
-
|
|
2946
|
-
|
|
2947
|
-
}
|
|
2948
|
-
|
|
2949
|
-
|
|
2950
|
-
|
|
2951
|
-
|
|
2952
|
-
|
|
2953
|
-
|
|
2954
|
-
|
|
2955
|
-
|
|
2956
|
-
|
|
2957
|
-
|
|
2958
|
-
|
|
2959
|
-
|
|
2960
|
-
|
|
2961
|
-
|
|
2962
|
-
|
|
2963
|
-
|
|
2964
|
-
|
|
2965
|
-
|
|
2966
|
-
|
|
2967
|
-
type: "bullets",
|
|
2968
|
-
// 'bullets' or 'progressbar' or 'fraction' or 'custom'
|
|
2969
|
-
dynamicBullets: !1,
|
|
2970
|
-
dynamicMainBullets: 1,
|
|
2971
|
-
formatFractionCurrent: (p) => p,
|
|
2972
|
-
formatFractionTotal: (p) => p,
|
|
2973
|
-
bulletClass: `${i}-bullet`,
|
|
2974
|
-
bulletActiveClass: `${i}-bullet-active`,
|
|
2975
|
-
modifierClass: `${i}-`,
|
|
2976
|
-
currentClass: `${i}-current`,
|
|
2977
|
-
totalClass: `${i}-total`,
|
|
2978
|
-
hiddenClass: `${i}-hidden`,
|
|
2979
|
-
progressbarFillClass: `${i}-progressbar-fill`,
|
|
2980
|
-
progressbarOppositeClass: `${i}-progressbar-opposite`,
|
|
2981
|
-
clickableClass: `${i}-clickable`,
|
|
2982
|
-
lockClass: `${i}-lock`,
|
|
2983
|
-
horizontalClass: `${i}-horizontal`,
|
|
2984
|
-
verticalClass: `${i}-vertical`,
|
|
2985
|
-
paginationDisabledClass: `${i}-disabled`
|
|
2986
|
-
}
|
|
2987
|
-
}), e.pagination = {
|
|
2988
|
-
el: null,
|
|
2989
|
-
bullets: []
|
|
2990
|
-
};
|
|
2991
|
-
let l, a = 0;
|
|
2992
|
-
function o() {
|
|
2993
|
-
return !e.params.pagination.el || !e.pagination.el || Array.isArray(e.pagination.el) && e.pagination.el.length === 0;
|
|
2994
|
-
}
|
|
2995
|
-
function c(p, m) {
|
|
2996
|
-
const {
|
|
2997
|
-
bulletActiveClass: v
|
|
2998
|
-
} = e.params.pagination;
|
|
2999
|
-
p && (p = p[`${m === "prev" ? "previous" : "next"}ElementSibling`], p && (p.classList.add(`${v}-${m}`), p = p[`${m === "prev" ? "previous" : "next"}ElementSibling`], p && p.classList.add(`${v}-${m}-${m}`)));
|
|
3000
|
-
}
|
|
3001
|
-
function d(p, m, v) {
|
|
3002
|
-
if (p = p % v, m = m % v, m === p + 1)
|
|
3003
|
-
return "next";
|
|
3004
|
-
if (m === p - 1)
|
|
3005
|
-
return "previous";
|
|
3006
|
-
}
|
|
3007
|
-
function u(p) {
|
|
3008
|
-
const m = p.target.closest(Z(e.params.pagination.bulletClass));
|
|
3009
|
-
if (!m)
|
|
3010
|
-
return;
|
|
3011
|
-
p.preventDefault();
|
|
3012
|
-
const v = ce(m) * e.params.slidesPerGroup;
|
|
3013
|
-
if (e.params.loop) {
|
|
3014
|
-
if (e.realIndex === v) return;
|
|
3015
|
-
const y = d(e.realIndex, v, e.slides.length);
|
|
3016
|
-
y === "next" ? e.slideNext() : y === "previous" ? e.slidePrev() : e.slideToLoop(v);
|
|
3017
|
-
} else
|
|
3018
|
-
e.slideTo(v);
|
|
3019
|
-
}
|
|
3020
|
-
function f() {
|
|
3021
|
-
const p = e.rtl, m = e.params.pagination;
|
|
3022
|
-
if (o()) return;
|
|
3023
|
-
let v = e.pagination.el;
|
|
3024
|
-
v = R(v);
|
|
3025
|
-
let y, T;
|
|
3026
|
-
const A = e.virtual && e.params.virtual.enabled ? e.virtual.slides.length : e.slides.length, I = e.params.loop ? Math.ceil(A / e.params.slidesPerGroup) : e.snapGrid.length;
|
|
3027
|
-
if (e.params.loop ? (T = e.previousRealIndex || 0, y = e.params.slidesPerGroup > 1 ? Math.floor(e.realIndex / e.params.slidesPerGroup) : e.realIndex) : typeof e.snapIndex < "u" ? (y = e.snapIndex, T = e.previousSnapIndex) : (T = e.previousIndex || 0, y = e.activeIndex || 0), m.type === "bullets" && e.pagination.bullets && e.pagination.bullets.length > 0) {
|
|
3028
|
-
const S = e.pagination.bullets;
|
|
3029
|
-
let E, x, k;
|
|
3030
|
-
if (m.dynamicBullets && (l = Te(S[0], e.isHorizontal() ? "width" : "height"), v.forEach((L) => {
|
|
3031
|
-
L.style[e.isHorizontal() ? "width" : "height"] = `${l * (m.dynamicMainBullets + 4)}px`;
|
|
3032
|
-
}), m.dynamicMainBullets > 1 && T !== void 0 && (a += y - (T || 0), a > m.dynamicMainBullets - 1 ? a = m.dynamicMainBullets - 1 : a < 0 && (a = 0)), E = Math.max(y - a, 0), x = E + (Math.min(S.length, m.dynamicMainBullets) - 1), k = (x + E) / 2), S.forEach((L) => {
|
|
3033
|
-
const O = [...["", "-next", "-next-next", "-prev", "-prev-prev", "-main"].map((C) => `${m.bulletActiveClass}${C}`)].map((C) => typeof C == "string" && C.includes(" ") ? C.split(" ") : C).flat();
|
|
3034
|
-
L.classList.remove(...O);
|
|
3035
|
-
}), v.length > 1)
|
|
3036
|
-
S.forEach((L) => {
|
|
3037
|
-
const O = ce(L);
|
|
3038
|
-
O === y ? L.classList.add(...m.bulletActiveClass.split(" ")) : e.isElement && L.setAttribute("part", "bullet"), m.dynamicBullets && (O >= E && O <= x && L.classList.add(...`${m.bulletActiveClass}-main`.split(" ")), O === E && c(L, "prev"), O === x && c(L, "next"));
|
|
3039
|
-
});
|
|
3040
|
-
else {
|
|
3041
|
-
const L = S[y];
|
|
3042
|
-
if (L && L.classList.add(...m.bulletActiveClass.split(" ")), e.isElement && S.forEach((O, C) => {
|
|
3043
|
-
O.setAttribute("part", C === y ? "bullet-active" : "bullet");
|
|
3044
|
-
}), m.dynamicBullets) {
|
|
3045
|
-
const O = S[E], C = S[x];
|
|
3046
|
-
for (let z = E; z <= x; z += 1)
|
|
3047
|
-
S[z] && S[z].classList.add(...`${m.bulletActiveClass}-main`.split(" "));
|
|
3048
|
-
c(O, "prev"), c(C, "next");
|
|
3049
|
-
}
|
|
3050
|
-
}
|
|
3051
|
-
if (m.dynamicBullets) {
|
|
3052
|
-
const L = Math.min(S.length, m.dynamicMainBullets + 4), O = (l * L - l) / 2 - k * l, C = p ? "right" : "left";
|
|
3053
|
-
S.forEach((z) => {
|
|
3054
|
-
z.style[e.isHorizontal() ? C : "top"] = `${O}px`;
|
|
3055
|
-
});
|
|
3056
|
-
}
|
|
3057
|
-
}
|
|
3058
|
-
v.forEach((S, E) => {
|
|
3059
|
-
if (m.type === "fraction" && (S.querySelectorAll(Z(m.currentClass)).forEach((x) => {
|
|
3060
|
-
x.textContent = m.formatFractionCurrent(y + 1);
|
|
3061
|
-
}), S.querySelectorAll(Z(m.totalClass)).forEach((x) => {
|
|
3062
|
-
x.textContent = m.formatFractionTotal(I);
|
|
3063
|
-
})), m.type === "progressbar") {
|
|
3064
|
-
let x;
|
|
3065
|
-
m.progressbarOpposite ? x = e.isHorizontal() ? "vertical" : "horizontal" : x = e.isHorizontal() ? "horizontal" : "vertical";
|
|
3066
|
-
const k = (y + 1) / I;
|
|
3067
|
-
let L = 1, O = 1;
|
|
3068
|
-
x === "horizontal" ? L = k : O = k, S.querySelectorAll(Z(m.progressbarFillClass)).forEach((C) => {
|
|
3069
|
-
C.style.transform = `translate3d(0,0,0) scaleX(${L}) scaleY(${O})`, C.style.transitionDuration = `${e.params.speed}ms`;
|
|
3070
|
-
});
|
|
3071
|
-
}
|
|
3072
|
-
m.type === "custom" && m.renderCustom ? (S.innerHTML = m.renderCustom(e, y + 1, I), E === 0 && n("paginationRender", S)) : (E === 0 && n("paginationRender", S), n("paginationUpdate", S)), e.params.watchOverflow && e.enabled && S.classList[e.isLocked ? "add" : "remove"](m.lockClass);
|
|
3073
|
-
});
|
|
3074
|
-
}
|
|
3075
|
-
function g() {
|
|
3076
|
-
const p = e.params.pagination;
|
|
3077
|
-
if (o()) return;
|
|
3078
|
-
const m = e.virtual && e.params.virtual.enabled ? e.virtual.slides.length : e.grid && e.params.grid.rows > 1 ? e.slides.length / Math.ceil(e.params.grid.rows) : e.slides.length;
|
|
3079
|
-
let v = e.pagination.el;
|
|
3080
|
-
v = R(v);
|
|
3081
|
-
let y = "";
|
|
3082
|
-
if (p.type === "bullets") {
|
|
3083
|
-
let T = e.params.loop ? Math.ceil(m / e.params.slidesPerGroup) : e.snapGrid.length;
|
|
3084
|
-
e.params.freeMode && e.params.freeMode.enabled && T > m && (T = m);
|
|
3085
|
-
for (let A = 0; A < T; A += 1)
|
|
3086
|
-
p.renderBullet ? y += p.renderBullet.call(e, A, p.bulletClass) : y += `<${p.bulletElement} ${e.isElement ? 'part="bullet"' : ""} class="${p.bulletClass}"></${p.bulletElement}>`;
|
|
3087
|
-
}
|
|
3088
|
-
p.type === "fraction" && (p.renderFraction ? y = p.renderFraction.call(e, p.currentClass, p.totalClass) : y = `<span class="${p.currentClass}"></span> / <span class="${p.totalClass}"></span>`), p.type === "progressbar" && (p.renderProgressbar ? y = p.renderProgressbar.call(e, p.progressbarFillClass) : y = `<span class="${p.progressbarFillClass}"></span>`), e.pagination.bullets = [], v.forEach((T) => {
|
|
3089
|
-
p.type !== "custom" && (T.innerHTML = y || ""), p.type === "bullets" && e.pagination.bullets.push(...T.querySelectorAll(Z(p.bulletClass)));
|
|
3090
|
-
}), p.type !== "custom" && n("paginationRender", v[0]);
|
|
3091
|
-
}
|
|
3092
|
-
function h() {
|
|
3093
|
-
e.params.pagination = wr(e, e.originalParams.pagination, e.params.pagination, {
|
|
3094
|
-
el: "swiper-pagination"
|
|
426
|
+
}), Xt = ({
|
|
427
|
+
gamification: e,
|
|
428
|
+
scrollNode: t,
|
|
429
|
+
scrollStore: n,
|
|
430
|
+
leaderboardList: o
|
|
431
|
+
}) => {
|
|
432
|
+
const s = L(null), {
|
|
433
|
+
data: r,
|
|
434
|
+
hasMore: l,
|
|
435
|
+
loading: d,
|
|
436
|
+
key: a
|
|
437
|
+
} = v(o.$store), {
|
|
438
|
+
data: c
|
|
439
|
+
} = v(e.deepLink.$store), [m, p] = He(s);
|
|
440
|
+
return !r.length && !d ? /* @__PURE__ */ i(Yt, {
|
|
441
|
+
deepLink: c
|
|
442
|
+
}) : /* @__PURE__ */ f(T, {
|
|
443
|
+
children: [/* @__PURE__ */ i(Ht, {
|
|
444
|
+
items: r,
|
|
445
|
+
scrollNode: t,
|
|
446
|
+
scrollStore: n,
|
|
447
|
+
fetchMore: o.fetchMore,
|
|
448
|
+
hasMore: l,
|
|
449
|
+
openItemDetail: e.openUser,
|
|
450
|
+
currentUserId: e.currentUserId.get()
|
|
451
|
+
}, a), c && /* @__PURE__ */ i(Zt, {
|
|
452
|
+
ref: s,
|
|
453
|
+
children: /* @__PURE__ */ i(Tt, {
|
|
454
|
+
"data-a": "intr",
|
|
455
|
+
onClick: () => m(c),
|
|
456
|
+
title: "Invite Friends",
|
|
457
|
+
description: "Challenge them now!"
|
|
458
|
+
})
|
|
459
|
+
}), p]
|
|
460
|
+
});
|
|
461
|
+
}, en = ({
|
|
462
|
+
gamification: e,
|
|
463
|
+
scrollNode: t,
|
|
464
|
+
scrollStore: n
|
|
465
|
+
}) => e.leaderboardList ? /* @__PURE__ */ i(Xt, {
|
|
466
|
+
leaderboardList: e.leaderboardList,
|
|
467
|
+
gamification: e,
|
|
468
|
+
scrollNode: t,
|
|
469
|
+
scrollStore: n
|
|
470
|
+
}) : null, tn = ({ store: e, openQuestion: t }) => {
|
|
471
|
+
const { sdk: n } = G(), o = v(e);
|
|
472
|
+
return /* @__PURE__ */ i(Je, { openQuestion: t, questions: o.data, controlVideo: n == null ? void 0 : n.controlVideoPlayer });
|
|
473
|
+
}, nn = ({ userSummary: e }) => {
|
|
474
|
+
var t;
|
|
475
|
+
const [n, o] = S(void 0);
|
|
476
|
+
return y(() => {
|
|
477
|
+
const s = e.$store.subscribe((r) => {
|
|
478
|
+
r && o(r);
|
|
3095
479
|
});
|
|
3096
|
-
|
|
3097
|
-
|
|
3098
|
-
|
|
3099
|
-
|
|
3100
|
-
|
|
3101
|
-
|
|
3102
|
-
|
|
3103
|
-
|
|
3104
|
-
|
|
3105
|
-
function b() {
|
|
3106
|
-
const p = e.params.pagination;
|
|
3107
|
-
if (o()) return;
|
|
3108
|
-
let m = e.pagination.el;
|
|
3109
|
-
m && (m = R(m), m.forEach((v) => {
|
|
3110
|
-
v.classList.remove(p.hiddenClass), v.classList.remove(p.modifierClass + p.type), v.classList.remove(e.isHorizontal() ? p.horizontalClass : p.verticalClass), p.clickable && (v.classList.remove(...(p.clickableClass || "").split(" ")), v.removeEventListener("click", u));
|
|
3111
|
-
})), e.pagination.bullets && e.pagination.bullets.forEach((v) => v.classList.remove(...p.bulletActiveClass.split(" ")));
|
|
3112
|
-
}
|
|
3113
|
-
r("changeDirection", () => {
|
|
3114
|
-
if (!e.pagination || !e.pagination.el) return;
|
|
3115
|
-
const p = e.params.pagination;
|
|
3116
|
-
let {
|
|
3117
|
-
el: m
|
|
3118
|
-
} = e.pagination;
|
|
3119
|
-
m = R(m), m.forEach((v) => {
|
|
3120
|
-
v.classList.remove(p.horizontalClass, p.verticalClass), v.classList.add(e.isHorizontal() ? p.horizontalClass : p.verticalClass);
|
|
480
|
+
return () => {
|
|
481
|
+
s();
|
|
482
|
+
};
|
|
483
|
+
}, [e]), /* @__PURE__ */ i(ke, { loading: !(n != null && n.summary), ...n == null ? void 0 : n.summary, successRate: (t = n == null ? void 0 : n.percentage) == null ? void 0 : t.correct });
|
|
484
|
+
}, sn = ({ gamification: e, className: t, scrollStore: n, scrollNode: o, appNode: s, style: r, responsiveStore: l }) => {
|
|
485
|
+
const { tabsShown: d } = v(n, { keys: ["tabsShown"] }), a = v(e.friendsTabEnabled), [c, m] = S(M.HOME), [, p] = Ue(), { sdkInDesktopView: h, screen: g } = v(l, { keys: ["sdkInDesktopView"] }), b = (I) => {
|
|
486
|
+
p(() => {
|
|
487
|
+
var B;
|
|
488
|
+
m(I), h === !1 && (((B = s.current) == null ? void 0 : B.getBoundingClientRect().y) || 0) < 0 && H(s, g.size, { behavior: "instant" });
|
|
3121
489
|
});
|
|
3122
|
-
}), r("init", () => {
|
|
3123
|
-
e.params.pagination.enabled === !1 ? w() : (h(), g(), f());
|
|
3124
|
-
}), r("activeIndexChange", () => {
|
|
3125
|
-
typeof e.snapIndex > "u" && f();
|
|
3126
|
-
}), r("snapIndexChange", () => {
|
|
3127
|
-
f();
|
|
3128
|
-
}), r("snapGridLengthChange", () => {
|
|
3129
|
-
g(), f();
|
|
3130
|
-
}), r("destroy", () => {
|
|
3131
|
-
b();
|
|
3132
|
-
}), r("enable disable", () => {
|
|
3133
|
-
let {
|
|
3134
|
-
el: p
|
|
3135
|
-
} = e.pagination;
|
|
3136
|
-
p && (p = R(p), p.forEach((m) => m.classList[e.enabled ? "remove" : "add"](e.params.pagination.lockClass)));
|
|
3137
|
-
}), r("lock unlock", () => {
|
|
3138
|
-
f();
|
|
3139
|
-
}), r("click", (p, m) => {
|
|
3140
|
-
const v = m.target, y = R(e.pagination.el);
|
|
3141
|
-
if (e.params.pagination.el && e.params.pagination.hideOnClick && y && y.length > 0 && !v.classList.contains(e.params.pagination.bulletClass)) {
|
|
3142
|
-
if (e.navigation && (e.navigation.nextEl && v === e.navigation.nextEl || e.navigation.prevEl && v === e.navigation.prevEl)) return;
|
|
3143
|
-
const T = y[0].classList.contains(e.params.pagination.hiddenClass);
|
|
3144
|
-
n(T === !0 ? "paginationShow" : "paginationHide"), y.forEach((A) => A.classList.toggle(e.params.pagination.hiddenClass));
|
|
3145
|
-
}
|
|
3146
|
-
});
|
|
3147
|
-
const M = () => {
|
|
3148
|
-
e.el.classList.remove(e.params.pagination.paginationDisabledClass);
|
|
3149
|
-
let {
|
|
3150
|
-
el: p
|
|
3151
|
-
} = e.pagination;
|
|
3152
|
-
p && (p = R(p), p.forEach((m) => m.classList.remove(e.params.pagination.paginationDisabledClass))), h(), g(), f();
|
|
3153
|
-
}, w = () => {
|
|
3154
|
-
e.el.classList.add(e.params.pagination.paginationDisabledClass);
|
|
3155
|
-
let {
|
|
3156
|
-
el: p
|
|
3157
|
-
} = e.pagination;
|
|
3158
|
-
p && (p = R(p), p.forEach((m) => m.classList.add(e.params.pagination.paginationDisabledClass))), b();
|
|
3159
490
|
};
|
|
3160
|
-
|
|
3161
|
-
|
|
3162
|
-
|
|
3163
|
-
render: g,
|
|
3164
|
-
update: f,
|
|
3165
|
-
init: h,
|
|
3166
|
-
destroy: b
|
|
3167
|
-
});
|
|
3168
|
-
}
|
|
3169
|
-
const yr = ({ data: t, gamification: e, onEvent: s, swipeable: r, autoplay: n }) => {
|
|
3170
|
-
const i = D(), l = D(), { listOfQuestions: a, countQuestionsAvailable: o } = He(() => {
|
|
3171
|
-
const g = t ? Object.values(t) : [];
|
|
3172
|
-
return {
|
|
3173
|
-
listOfQuestions: g,
|
|
3174
|
-
countQuestionsAvailable: g.filter(({ marketClosed: h }) => !h).length
|
|
3175
|
-
};
|
|
3176
|
-
}, [t]), c = Re(
|
|
3177
|
-
async (g, h) => {
|
|
3178
|
-
try {
|
|
3179
|
-
await e.betPackVote(g, h), s({
|
|
3180
|
-
type: "slVoted",
|
|
3181
|
-
payload: {
|
|
3182
|
-
questionId: g,
|
|
3183
|
-
answerId: h
|
|
3184
|
-
}
|
|
3185
|
-
});
|
|
3186
|
-
} finally {
|
|
3187
|
-
i.current && clearTimeout(i.current), n && (i.current = setTimeout(() => {
|
|
3188
|
-
var b;
|
|
3189
|
-
(b = l.current) == null || b.slideNext();
|
|
3190
|
-
}, 2e3));
|
|
3191
|
-
}
|
|
3192
|
-
},
|
|
3193
|
-
[e, s, n]
|
|
3194
|
-
);
|
|
3195
|
-
X(() => (s({
|
|
3196
|
-
type: "slBetPackReady",
|
|
3197
|
-
payload: {
|
|
3198
|
-
next: () => {
|
|
3199
|
-
var g;
|
|
3200
|
-
return (g = l.current) == null ? void 0 : g.slideNext();
|
|
3201
|
-
},
|
|
3202
|
-
prev: () => {
|
|
3203
|
-
var g;
|
|
3204
|
-
return (g = l.current) == null ? void 0 : g.slidePrev();
|
|
3205
|
-
},
|
|
3206
|
-
current: 0,
|
|
3207
|
-
canNext: !0,
|
|
3208
|
-
canPrev: !1
|
|
3209
|
-
}
|
|
3210
|
-
}), () => {
|
|
3211
|
-
i.current && clearTimeout(i.current);
|
|
3212
|
-
}), [s]);
|
|
3213
|
-
const d = (g) => {
|
|
3214
|
-
var h;
|
|
3215
|
-
const b = g.realIndex;
|
|
3216
|
-
if (s({
|
|
3217
|
-
type: "slBetPackChangeCard",
|
|
3218
|
-
payload: {
|
|
3219
|
-
current: b,
|
|
3220
|
-
canNext: b < Object.keys(t).length + 1,
|
|
3221
|
-
canPrev: b >= 1
|
|
3222
|
-
}
|
|
3223
|
-
}), b !== 0 && b !== Object.keys(t).length + 1 && (h = a[b - 1]) != null && h.id) {
|
|
3224
|
-
e.openQuestion(a[b - 1].id, {
|
|
3225
|
-
openedFrom: "bet-pack",
|
|
3226
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
3227
|
-
// @ts-expect-error
|
|
3228
|
-
attributes: {
|
|
3229
|
-
id: a[b - 1].id,
|
|
3230
|
-
type: a[b - 1].type,
|
|
3231
|
-
status: a[b - 1].status,
|
|
3232
|
-
attributes: {
|
|
3233
|
-
case: void 0
|
|
3234
|
-
}
|
|
3235
|
-
}
|
|
3236
|
-
});
|
|
491
|
+
y(() => n.subscribe((I) => {
|
|
492
|
+
if (I.scrollPosition === 0) {
|
|
493
|
+
n.setKey("tabsShown", !0);
|
|
3237
494
|
return;
|
|
3238
495
|
}
|
|
3239
|
-
|
|
3240
|
-
}, [
|
|
3241
|
-
|
|
3242
|
-
|
|
3243
|
-
|
|
3244
|
-
|
|
3245
|
-
|
|
3246
|
-
|
|
3247
|
-
|
|
3248
|
-
|
|
3249
|
-
|
|
3250
|
-
|
|
3251
|
-
|
|
3252
|
-
|
|
3253
|
-
|
|
3254
|
-
|
|
3255
|
-
|
|
3256
|
-
|
|
3257
|
-
|
|
3258
|
-
|
|
3259
|
-
|
|
3260
|
-
|
|
3261
|
-
|
|
3262
|
-
|
|
3263
|
-
|
|
3264
|
-
|
|
3265
|
-
|
|
3266
|
-
|
|
3267
|
-
|
|
3268
|
-
|
|
3269
|
-
|
|
3270
|
-
|
|
3271
|
-
|
|
3272
|
-
|
|
3273
|
-
|
|
3274
|
-
|
|
3275
|
-
|
|
3276
|
-
|
|
3277
|
-
|
|
3278
|
-
|
|
3279
|
-
|
|
3280
|
-
|
|
3281
|
-
|
|
3282
|
-
|
|
3283
|
-
|
|
3284
|
-
|
|
3285
|
-
|
|
3286
|
-
|
|
3287
|
-
|
|
3288
|
-
|
|
3289
|
-
|
|
3290
|
-
|
|
3291
|
-
|
|
496
|
+
l.get().sdkInDesktopView ? n.setKey("tabsShown", I.scrollDirection === "backward") : n.setKey("tabsShown", I.scrollDirection === "forward");
|
|
497
|
+
}), [n, l]), y(() => {
|
|
498
|
+
a || m(M.HOME);
|
|
499
|
+
}, [a]);
|
|
500
|
+
let $ = "0px";
|
|
501
|
+
return h ? $ = d ? "0px" : "calc(0px - var(--header-height))" : $ = d ? "var(--header-height)" : "0px", /* @__PURE__ */ f(Be, { className: E(t, "SL-Tabs", "sl-hide-on-modal"), style: r, children: [
|
|
502
|
+
a && /* @__PURE__ */ i(
|
|
503
|
+
Fe,
|
|
504
|
+
{
|
|
505
|
+
style: {
|
|
506
|
+
top: $
|
|
507
|
+
},
|
|
508
|
+
children: /* @__PURE__ */ i(St, { activePage: c, toggleActivePage: b })
|
|
509
|
+
}
|
|
510
|
+
),
|
|
511
|
+
c === M.HOME && /* @__PURE__ */ f(T, { children: [
|
|
512
|
+
/* @__PURE__ */ i(ze, { children: /* @__PURE__ */ i(Pe, { children: /* @__PURE__ */ i(nn, { userSummary: e.userSummary }) }) }),
|
|
513
|
+
/* @__PURE__ */ i(Ve, { style: { flex: 1 }, children: /* @__PURE__ */ i(tn, { openQuestion: e.openQuestion, store: e.feedList.getStore() }) })
|
|
514
|
+
] }),
|
|
515
|
+
c === M.LEADERBOARD && /* @__PURE__ */ i(qe, { children: /* @__PURE__ */ i(en, { scrollStore: n, scrollNode: o, gamification: e }) })
|
|
516
|
+
] });
|
|
517
|
+
}, on = () => W, re = /* @__PURE__ */ u(on())({
|
|
518
|
+
name: "OpenedContainer",
|
|
519
|
+
class: "ouvguos",
|
|
520
|
+
propsAsIs: !0
|
|
521
|
+
}), le = "t1eu4lbg", an = /* @__PURE__ */ u("div")({
|
|
522
|
+
name: "UserContainer",
|
|
523
|
+
class: "uuv2xqo",
|
|
524
|
+
propsAsIs: !1
|
|
525
|
+
}), rn = ({
|
|
526
|
+
correct: e,
|
|
527
|
+
incorrect: t
|
|
528
|
+
}) => {
|
|
529
|
+
const n = e + t;
|
|
530
|
+
return n === 0 ? 0 : Math.round(e / n * 100);
|
|
531
|
+
}, zs = ({
|
|
532
|
+
gamification: e,
|
|
533
|
+
scrollStore: t,
|
|
534
|
+
className: n,
|
|
535
|
+
appNode: o,
|
|
536
|
+
scrollNode: s,
|
|
537
|
+
responsiveStore: r
|
|
538
|
+
}) => /* @__PURE__ */ i(sn, {
|
|
539
|
+
appNode: o,
|
|
540
|
+
scrollStore: t,
|
|
541
|
+
scrollNode: s,
|
|
542
|
+
className: n,
|
|
543
|
+
gamification: e,
|
|
544
|
+
responsiveStore: r
|
|
545
|
+
}), ln = ({
|
|
546
|
+
gamification: e,
|
|
547
|
+
muted: t,
|
|
548
|
+
sdk: n,
|
|
549
|
+
className: o,
|
|
550
|
+
appNode: s,
|
|
551
|
+
responsiveStore: r
|
|
552
|
+
}) => {
|
|
553
|
+
const {
|
|
554
|
+
topNavigation: l
|
|
555
|
+
} = G(), d = v(e.openedQuestionId), a = v(e.openedQuestion.$store), c = v(e.openedUser || ye(void 0)), {
|
|
556
|
+
sdkInDesktopView: m
|
|
557
|
+
} = v(r, {
|
|
558
|
+
keys: ["sdkInDesktopView"]
|
|
559
|
+
}), {
|
|
560
|
+
hiding: p,
|
|
561
|
+
onAnimationEnd: h
|
|
562
|
+
} = je();
|
|
563
|
+
if (!d && !c)
|
|
564
|
+
return null;
|
|
565
|
+
const g = a ? /* @__PURE__ */ i(re, {
|
|
566
|
+
className: E(o, !l && le),
|
|
567
|
+
hiding: p,
|
|
568
|
+
onAnimationEnd: h,
|
|
569
|
+
children: /* @__PURE__ */ i(rt, {
|
|
570
|
+
muted: t,
|
|
571
|
+
sdk: n,
|
|
572
|
+
gamification: e
|
|
573
|
+
})
|
|
574
|
+
}) : c ? /* @__PURE__ */ i(re, {
|
|
575
|
+
className: E(o, !l && le),
|
|
576
|
+
hiding: p,
|
|
577
|
+
onAnimationEnd: h,
|
|
578
|
+
children: /* @__PURE__ */ f(an, {
|
|
579
|
+
children: [/* @__PURE__ */ i(dt, {
|
|
580
|
+
label: "Friend's Rank",
|
|
581
|
+
close: e.closeUser
|
|
582
|
+
}), /* @__PURE__ */ i(Ke, {
|
|
583
|
+
children: /* @__PURE__ */ i(ke, {
|
|
584
|
+
...c,
|
|
585
|
+
successRate: rn(c)
|
|
586
|
+
})
|
|
587
|
+
})]
|
|
588
|
+
})
|
|
589
|
+
}) : null;
|
|
590
|
+
return /* @__PURE__ */ i(Ne, {
|
|
591
|
+
container: s,
|
|
592
|
+
useContainer: !m,
|
|
593
|
+
children: g
|
|
594
|
+
});
|
|
595
|
+
}, dn = xe(() => import("./gamification-feature.js")), cn = ({ sdk: e, feature: t, className: n, scrollStore: o, appNode: s, scrollNode: r, responsiveStore: l }) => {
|
|
596
|
+
const d = C(() => t && t.featureConfig.get().type === N.GAMES ? /* @__PURE__ */ i(It, { className: n, sdk: e, feature: t, children: /* @__PURE__ */ i(
|
|
597
|
+
dn,
|
|
3292
598
|
{
|
|
3293
|
-
|
|
3294
|
-
|
|
3295
|
-
|
|
3296
|
-
|
|
599
|
+
appNode: s,
|
|
600
|
+
scrollStore: o,
|
|
601
|
+
scrollNode: r,
|
|
602
|
+
className: n,
|
|
603
|
+
responsiveStore: l,
|
|
604
|
+
gamification: t
|
|
3297
605
|
}
|
|
3298
|
-
) :
|
|
3299
|
-
|
|
606
|
+
) }) : null, [e, t, n, l, o, r, s]);
|
|
607
|
+
return /* @__PURE__ */ i(
|
|
608
|
+
Le,
|
|
3300
609
|
{
|
|
3301
|
-
|
|
3302
|
-
|
|
3303
|
-
onEvent: n,
|
|
3304
|
-
swipeable: r,
|
|
3305
|
-
autoplay: e,
|
|
3306
|
-
overlay: s
|
|
610
|
+
fallback: /* @__PURE__ */ i("div", { style: { display: "flex", alignItems: "center", justifyContent: "center", width: "100%", height: "100%" }, children: "page loading..." }),
|
|
611
|
+
children: d
|
|
3307
612
|
}
|
|
3308
613
|
);
|
|
3309
|
-
},
|
|
3310
|
-
|
|
3311
|
-
|
|
614
|
+
}, pn = ({ feature: e, sdk: t, muted: n, className: o, appNode: s, responsiveStore: r }) => e && e.featureConfig.get().type === N.GAMES ? /* @__PURE__ */ i(
|
|
615
|
+
ln,
|
|
616
|
+
{
|
|
617
|
+
className: o,
|
|
618
|
+
appNode: s,
|
|
619
|
+
muted: n,
|
|
620
|
+
sdk: t,
|
|
621
|
+
responsiveStore: r,
|
|
622
|
+
gamification: e
|
|
623
|
+
}
|
|
624
|
+
) : null;
|
|
625
|
+
window.dispatchEvent(new CustomEvent("grpc_devtools_loaded"));
|
|
626
|
+
function un(e) {
|
|
627
|
+
return e instanceof DOMException && // everything except Firefox
|
|
628
|
+
(e.code === 22 || // Firefox
|
|
629
|
+
e.code === 1014 || // test name field too, because code might not be present
|
|
630
|
+
// everything except Firefox
|
|
631
|
+
e.name === "QuotaExceededError" || // Firefox
|
|
632
|
+
e.name === "NS_ERROR_DOM_QUOTA_REACHED");
|
|
633
|
+
}
|
|
634
|
+
class mn {
|
|
635
|
+
constructor(t = "main", n = window.localStorage) {
|
|
636
|
+
k(this, "delimiter", ":");
|
|
637
|
+
k(this, "prefix");
|
|
638
|
+
k(this, "storage");
|
|
639
|
+
k(this, "clear", () => {
|
|
640
|
+
for (const t in window.localStorage)
|
|
641
|
+
t.startsWith(this.prefix) && this.storage.removeItem(t);
|
|
642
|
+
});
|
|
643
|
+
k(this, "generateKey", (t) => `${this.prefix}${this.delimiter}${t.join(this.delimiter)}`);
|
|
644
|
+
k(this, "write", (...t) => {
|
|
645
|
+
const n = t.pop() || "", o = this.generateKey(t);
|
|
646
|
+
try {
|
|
647
|
+
this.storage.setItem(o, n);
|
|
648
|
+
} catch (s) {
|
|
649
|
+
un(s) && this.storage === window.sessionStorage && (window.sessionStorage.removeItem("slstreamlogs"), this.storage.setItem(o, n));
|
|
650
|
+
}
|
|
651
|
+
});
|
|
652
|
+
k(this, "read", (...t) => {
|
|
653
|
+
const n = this.storage.getItem(this.generateKey(t));
|
|
654
|
+
return n === null ? void 0 : n;
|
|
655
|
+
});
|
|
656
|
+
k(this, "remove", (...t) => {
|
|
657
|
+
this.storage.removeItem(this.generateKey(t));
|
|
658
|
+
});
|
|
659
|
+
this.prefix = `sl-sdk${this.delimiter}${t}`, this.storage = n;
|
|
660
|
+
}
|
|
661
|
+
}
|
|
662
|
+
var de;
|
|
663
|
+
(function(e) {
|
|
664
|
+
e.Init = "init", e.Ready = "ready", e.Connecting = "connecting", e.Connected = "connected", e.Disconnected = "disconnected", e.Failed = "failed", e.Reconnect = "reconnect", e.Reconnecting = "reconnecting";
|
|
665
|
+
})(de || (de = {}));
|
|
666
|
+
U("grpc:stream");
|
|
667
|
+
x.Unknown, x.Internal, x.DeadlineExceeded, x.ResourceExhausted, x.FailedPrecondition, x.Unavailable, x.DataLoss;
|
|
668
|
+
U("grpc:retry");
|
|
669
|
+
ee(10, { description: "Number of attempts to retry" }), ee(3e4, { description: "Max delay between retries in milliseconds" });
|
|
670
|
+
var A;
|
|
671
|
+
(function(e) {
|
|
672
|
+
e.SCHEMA = "schema", e.EXTERNAL_TOKEN = "eToken", e.TOKEN = "token";
|
|
673
|
+
})(A || (A = {}));
|
|
674
|
+
class hn extends mn {
|
|
675
|
+
constructor() {
|
|
676
|
+
super("user");
|
|
677
|
+
// Schema
|
|
678
|
+
k(this, "setSchema", (n) => {
|
|
679
|
+
this.write(A.SCHEMA, n);
|
|
680
|
+
});
|
|
681
|
+
k(this, "getSchema", () => this.read(A.SCHEMA));
|
|
682
|
+
// Token
|
|
683
|
+
k(this, "setToken", (n) => {
|
|
684
|
+
this.write(A.TOKEN, n);
|
|
685
|
+
});
|
|
686
|
+
k(this, "getToken", () => this.read(A.TOKEN));
|
|
687
|
+
// External Token
|
|
688
|
+
k(this, "setExternalToken", (n) => {
|
|
689
|
+
this.write(A.EXTERNAL_TOKEN, n);
|
|
690
|
+
});
|
|
691
|
+
k(this, "getExternalToken", () => this.read(A.EXTERNAL_TOKEN));
|
|
692
|
+
k(this, "removeToken", () => {
|
|
693
|
+
this.remove(A.TOKEN);
|
|
694
|
+
});
|
|
695
|
+
}
|
|
696
|
+
}
|
|
697
|
+
var ce;
|
|
698
|
+
(function(e) {
|
|
699
|
+
e.DISABLED = "disabled", e.INITIALIZATION = "initialization", e.READY = "ready", e.FAILED = "failed", e.SUSPENDED = "suspended";
|
|
700
|
+
})(ce || (ce = {}));
|
|
701
|
+
var pe;
|
|
702
|
+
(function(e) {
|
|
703
|
+
e.SHOWED = "showed", e.EVENT = "ev";
|
|
704
|
+
})(pe || (pe = {}));
|
|
705
|
+
var ue;
|
|
706
|
+
(function(e) {
|
|
707
|
+
e.ONBOARDING = "onboarding", e.ONBOARDING_IO = "onboarding_io", e.QUESTION_RECEIVED = "q-received", e.QUESTION_OPENED = "q-opened";
|
|
708
|
+
})(ue || (ue = {}));
|
|
709
|
+
var me;
|
|
710
|
+
(function(e) {
|
|
711
|
+
e.ALLOWED = "allowed", e.DISALLOWED = "disallowed";
|
|
712
|
+
})(me || (me = {}));
|
|
713
|
+
var he;
|
|
714
|
+
(function(e) {
|
|
715
|
+
e.UNKNOWN = "unknown", e.ALREADY_VOTED = "already_voted";
|
|
716
|
+
})(he || (he = {}));
|
|
717
|
+
U("deep_link");
|
|
718
|
+
U("bypass");
|
|
719
|
+
new hn();
|
|
720
|
+
U("video_player");
|
|
721
|
+
w.FACTOID + "", w.POLL + "", w.TRIVIA + "", w.PREDICTION + "", w.TWEET + "";
|
|
722
|
+
var ve;
|
|
723
|
+
(function(e) {
|
|
724
|
+
e.Unset = "unset", e.Required = "required", e.Optional = "optional", e.Completed = "completed", e.Disabled = "disabled", e.Unavailable = "unavailable";
|
|
725
|
+
})(ve || (ve = {}));
|
|
726
|
+
w.POLL, w.PREDICTION, w.TRIVIA;
|
|
727
|
+
const vn = {
|
|
728
|
+
[N.GAMES]: !0
|
|
729
|
+
}, fn = /* @__PURE__ */ u("div")({
|
|
730
|
+
name: "Buttons",
|
|
731
|
+
class: "b5o8qbl",
|
|
732
|
+
propsAsIs: !1
|
|
733
|
+
}), gn = ({
|
|
734
|
+
children: e,
|
|
735
|
+
className: t
|
|
736
|
+
}) => /* @__PURE__ */ i(fn, {
|
|
737
|
+
className: t,
|
|
738
|
+
children: e
|
|
739
|
+
}), $e = /* @__PURE__ */ u("div")({
|
|
740
|
+
name: "Navigation",
|
|
741
|
+
class: "n6tbwuy",
|
|
742
|
+
propsAsIs: !1
|
|
743
|
+
}), In = () => gn, fe = /* @__PURE__ */ u(In())({
|
|
744
|
+
name: "NavigationItems",
|
|
745
|
+
class: "n1up4z7v",
|
|
746
|
+
propsAsIs: !0
|
|
747
|
+
}), bn = /* @__PURE__ */ u("button")({
|
|
748
|
+
name: "SButton",
|
|
749
|
+
class: "sxxa0c",
|
|
3312
750
|
propsAsIs: !1
|
|
3313
|
-
}),
|
|
3314
|
-
|
|
3315
|
-
|
|
3316
|
-
|
|
3317
|
-
},
|
|
3318
|
-
|
|
3319
|
-
|
|
751
|
+
}), kn = /* @__PURE__ */ u("span")({
|
|
752
|
+
name: "ButtonIcon",
|
|
753
|
+
class: "b193dcyu",
|
|
754
|
+
propsAsIs: !1
|
|
755
|
+
}), yn = /* @__PURE__ */ u("span")({
|
|
756
|
+
name: "ButtonLabel",
|
|
757
|
+
class: "b40tuix",
|
|
758
|
+
propsAsIs: !1
|
|
759
|
+
}), Nn = "s14xk0af", Sn = "ha3mg7c", $n = "h103yr45", z = ({ disabled: e, active: t, onClick: n, label: o, icon: s, id: r }) => /* @__PURE__ */ i(
|
|
760
|
+
bn,
|
|
761
|
+
{
|
|
762
|
+
onClick: n,
|
|
763
|
+
"data-a": "intr",
|
|
764
|
+
disabled: e,
|
|
765
|
+
className: E(
|
|
766
|
+
t && Nn,
|
|
767
|
+
!t && (r === "channels" || r === "featuredGroups") && Sn,
|
|
768
|
+
!t && r === "leaderboard" && $n
|
|
769
|
+
),
|
|
770
|
+
children: /* @__PURE__ */ f(T, { children: [
|
|
771
|
+
s && /* @__PURE__ */ i(kn, { children: s }),
|
|
772
|
+
/* @__PURE__ */ i(yn, { children: o })
|
|
773
|
+
] })
|
|
774
|
+
}
|
|
775
|
+
), An = () => D, wn = /* @__PURE__ */ u(An())({
|
|
776
|
+
name: "ButtonIcon",
|
|
777
|
+
class: "b11wpe79",
|
|
778
|
+
propsAsIs: !0
|
|
779
|
+
}), Cn = /* @__PURE__ */ u("div")({
|
|
3320
780
|
name: "Container",
|
|
3321
|
-
class: "
|
|
781
|
+
class: "calnblm",
|
|
3322
782
|
propsAsIs: !1
|
|
3323
|
-
}),
|
|
3324
|
-
name: "
|
|
3325
|
-
class: "
|
|
783
|
+
}), En = /* @__PURE__ */ u("div")({
|
|
784
|
+
name: "Title",
|
|
785
|
+
class: "t1438p52",
|
|
3326
786
|
propsAsIs: !1
|
|
3327
|
-
}),
|
|
3328
|
-
name: "
|
|
3329
|
-
class: "
|
|
787
|
+
}), Rn = /* @__PURE__ */ u("div")({
|
|
788
|
+
name: "CloseIconWrap",
|
|
789
|
+
class: "c17srj38",
|
|
790
|
+
propsAsIs: !1
|
|
791
|
+
}), xn = () => D, Ln = /* @__PURE__ */ u(xn())({
|
|
792
|
+
name: "CloseIcon",
|
|
793
|
+
class: "clqia8k",
|
|
3330
794
|
propsAsIs: !0
|
|
3331
|
-
}),
|
|
3332
|
-
name: "
|
|
3333
|
-
class: "
|
|
795
|
+
}), Tn = () => D, Dn = /* @__PURE__ */ u(Tn())({
|
|
796
|
+
name: "DashboardIcon",
|
|
797
|
+
class: "df5w958",
|
|
3334
798
|
propsAsIs: !0
|
|
3335
|
-
}),
|
|
3336
|
-
|
|
3337
|
-
|
|
799
|
+
}), On = "h12x6aiv", _n = be(({
|
|
800
|
+
sdk: e,
|
|
801
|
+
className: t
|
|
802
|
+
}, n) => {
|
|
803
|
+
const o = () => {
|
|
804
|
+
e.closeFeature();
|
|
805
|
+
};
|
|
806
|
+
return /* @__PURE__ */ f($e, {
|
|
807
|
+
className: E(t, On),
|
|
808
|
+
children: [/* @__PURE__ */ f(Cn, {
|
|
809
|
+
children: [/* @__PURE__ */ f(En, {
|
|
810
|
+
children: [/* @__PURE__ */ i(Dn, {
|
|
811
|
+
name: "dashboard"
|
|
812
|
+
}), "Dashboard"]
|
|
813
|
+
}), /* @__PURE__ */ i(Rn, {
|
|
814
|
+
"data-a": "intr",
|
|
815
|
+
onClick: o,
|
|
816
|
+
children: /* @__PURE__ */ i(Ln, {
|
|
817
|
+
name: "icon-cross"
|
|
818
|
+
})
|
|
819
|
+
})]
|
|
820
|
+
}), /* @__PURE__ */ i("div", {
|
|
821
|
+
ref: n
|
|
822
|
+
})]
|
|
823
|
+
});
|
|
824
|
+
}), Mn = be(({
|
|
825
|
+
sdk: e,
|
|
826
|
+
className: t
|
|
827
|
+
}, n) => {
|
|
828
|
+
const o = v(e.sdkStore.organizationSettings), s = v(e.sdkStore.streamSettings), r = v(e.getActiveFeature()), l = C(() => {
|
|
829
|
+
const a = (s == null ? void 0 : s.data) || (o == null ? void 0 : o.data);
|
|
830
|
+
return a != null && a.overlays ? a.overlays : [];
|
|
831
|
+
}, [o, s]), d = C(() => [...l.filter(({
|
|
832
|
+
enableSdkButton: a,
|
|
833
|
+
type: c
|
|
834
|
+
}) => c === N.GAMES || a).map((a) => ({
|
|
835
|
+
id: a.type,
|
|
836
|
+
onClick: () => e.openFeature(a.type),
|
|
837
|
+
disabled: !(a.type in vn),
|
|
838
|
+
label: a.name,
|
|
839
|
+
icon: /* @__PURE__ */ i("img", {
|
|
840
|
+
src: a.icon,
|
|
841
|
+
alt: ""
|
|
842
|
+
}),
|
|
843
|
+
/** multiplied by 10 to add the ability to insert custom buttons between our buttons */
|
|
844
|
+
position: a.position * 10
|
|
845
|
+
}))].sort((a, c) => a.position - c.position), [l, e]);
|
|
846
|
+
return /* @__PURE__ */ f($e, {
|
|
847
|
+
className: t,
|
|
848
|
+
children: [d.length !== 0 && /* @__PURE__ */ i(fe, {
|
|
849
|
+
children: [/* @__PURE__ */ i(z, {
|
|
850
|
+
id: "Channels",
|
|
851
|
+
onClick: () => e.closeFeature(),
|
|
852
|
+
label: "Channels",
|
|
853
|
+
active: r === 0
|
|
854
|
+
}, "Channels"), ...d.map((a) => a.id === N.GAMES ? /* @__PURE__ */ i(z, {
|
|
855
|
+
...a,
|
|
856
|
+
active: a.id === r,
|
|
857
|
+
label: "StreamLayer +",
|
|
858
|
+
id: "featuredGroups",
|
|
859
|
+
icon: /* @__PURE__ */ i(wn, {
|
|
860
|
+
name: "icon-btn-feature-groups",
|
|
861
|
+
"data-selected": a.id === r
|
|
862
|
+
})
|
|
863
|
+
}, a.id) : /* @__PURE__ */ i(z, {
|
|
864
|
+
...a,
|
|
865
|
+
icon: void 0,
|
|
866
|
+
active: a.id === r
|
|
867
|
+
}, a.id))]
|
|
868
|
+
}), !d.length && /* @__PURE__ */ i(fe, {
|
|
869
|
+
children: [/* @__PURE__ */ i(z, {
|
|
870
|
+
id: "empty",
|
|
871
|
+
label: "No Features...",
|
|
872
|
+
active: !1,
|
|
873
|
+
disabled: !0
|
|
874
|
+
}, "empty")]
|
|
875
|
+
}), /* @__PURE__ */ i("div", {
|
|
876
|
+
ref: n
|
|
877
|
+
})]
|
|
878
|
+
});
|
|
879
|
+
}), Un = /* @__PURE__ */ u("div")({
|
|
880
|
+
name: "Container",
|
|
881
|
+
class: "c1qjj4d4",
|
|
3338
882
|
propsAsIs: !1
|
|
3339
|
-
}),
|
|
3340
|
-
name: "
|
|
3341
|
-
class: "
|
|
883
|
+
}), Bn = /* @__PURE__ */ u("div")({
|
|
884
|
+
name: "CloseIconWrap",
|
|
885
|
+
class: "c1lg6b8a",
|
|
3342
886
|
propsAsIs: !1
|
|
3343
|
-
}),
|
|
3344
|
-
name: "
|
|
3345
|
-
class: "
|
|
887
|
+
}), Fn = () => D, zn = /* @__PURE__ */ u(Fn())({
|
|
888
|
+
name: "CloseIcon",
|
|
889
|
+
class: "c159el66",
|
|
890
|
+
propsAsIs: !0
|
|
891
|
+
}), Pn = /* @__PURE__ */ u("div")({
|
|
892
|
+
name: "Title",
|
|
893
|
+
class: "t16xmufv",
|
|
3346
894
|
propsAsIs: !1
|
|
3347
|
-
}),
|
|
3348
|
-
name: "
|
|
3349
|
-
class: "
|
|
895
|
+
}), Vn = /* @__PURE__ */ u("img")({
|
|
896
|
+
name: "SponsorLogo",
|
|
897
|
+
class: "s83lc21",
|
|
3350
898
|
propsAsIs: !1
|
|
3351
|
-
}),
|
|
3352
|
-
name: "
|
|
3353
|
-
class: "
|
|
899
|
+
}), qn = /* @__PURE__ */ u("div")({
|
|
900
|
+
name: "PresentsTitle",
|
|
901
|
+
class: "p1p7igia",
|
|
3354
902
|
propsAsIs: !1
|
|
3355
|
-
}),
|
|
3356
|
-
|
|
3357
|
-
|
|
3358
|
-
|
|
3359
|
-
|
|
3360
|
-
|
|
3361
|
-
|
|
3362
|
-
|
|
3363
|
-
|
|
3364
|
-
|
|
3365
|
-
|
|
3366
|
-
|
|
3367
|
-
|
|
3368
|
-
|
|
3369
|
-
|
|
3370
|
-
|
|
3371
|
-
|
|
3372
|
-
|
|
3373
|
-
|
|
3374
|
-
return X(() => () => {
|
|
3375
|
-
var c;
|
|
3376
|
-
const d = t.getFeature(qe.GAMES);
|
|
3377
|
-
d && ((c = d.betPack) == null || c.off());
|
|
3378
|
-
}, [t]), /* @__PURE__ */ F(Pr, { ref: r, children: [
|
|
3379
|
-
/* @__PURE__ */ F(Ar, { children: [
|
|
3380
|
-
/* @__PURE__ */ F(Or, { children: [
|
|
3381
|
-
/* @__PURE__ */ P(te, { name: "fgIcon" }),
|
|
3382
|
-
"Featured Groups+"
|
|
3383
|
-
] }),
|
|
3384
|
-
/* @__PURE__ */ P(Mr, { "data-a": "intr", onClick: s, children: /* @__PURE__ */ P(te, { name: "icon-close-btn-gray" }) })
|
|
903
|
+
}), jn = /* @__PURE__ */ u("div")({
|
|
904
|
+
name: "Subtitle",
|
|
905
|
+
class: "s1eftsbu",
|
|
906
|
+
propsAsIs: !1
|
|
907
|
+
}), Kn = /* @__PURE__ */ u("div")({
|
|
908
|
+
name: "Description",
|
|
909
|
+
class: "d8uezec",
|
|
910
|
+
propsAsIs: !1
|
|
911
|
+
}), Qn = /* @__PURE__ */ u("button")({
|
|
912
|
+
name: "ActionButton",
|
|
913
|
+
class: "a1h1bk90",
|
|
914
|
+
propsAsIs: !1
|
|
915
|
+
}), ge = ({ close: e, action: t, onboarding: n }) => {
|
|
916
|
+
var o, s, r, l, d, a, c, m;
|
|
917
|
+
return /* @__PURE__ */ f(Un, { children: [
|
|
918
|
+
/* @__PURE__ */ i(Bn, { "data-a": "intr", onClick: e, children: /* @__PURE__ */ i(zn, { name: "icon-cross" }) }),
|
|
919
|
+
((s = (o = n == null ? void 0 : n.titleCard) == null ? void 0 : o.media) == null ? void 0 : s.sponsorLogo) && /* @__PURE__ */ f(Pn, { children: [
|
|
920
|
+
/* @__PURE__ */ i(Vn, { alt: "sponsor-logo", src: (l = (r = n == null ? void 0 : n.titleCard) == null ? void 0 : r.media) == null ? void 0 : l.sponsorLogo }),
|
|
921
|
+
/* @__PURE__ */ i(qn, { children: "PRESENTS" })
|
|
3385
922
|
] }),
|
|
3386
|
-
|
|
3387
|
-
/* @__PURE__ */
|
|
3388
|
-
|
|
3389
|
-
/* @__PURE__ */ P(je, { "data-a": "intr", onClick: n == null ? void 0 : n.next, disabled: !(l != null && l.canNext), children: /* @__PURE__ */ P(Lr, { "data-a": "intr", name: "iconArrowPrev", className: Ee((l == null ? void 0 : l.canNext) && Fe) }) })
|
|
3390
|
-
] })
|
|
923
|
+
((d = n == null ? void 0 : n.titleCard) == null ? void 0 : d.title) && /* @__PURE__ */ i(jn, { children: (a = n == null ? void 0 : n.titleCard) == null ? void 0 : a.title }),
|
|
924
|
+
((c = n == null ? void 0 : n.titleCard) == null ? void 0 : c.subtitle) && /* @__PURE__ */ i(Kn, { children: (m = n == null ? void 0 : n.titleCard) == null ? void 0 : m.subtitle }),
|
|
925
|
+
/* @__PURE__ */ i(Qn, { "data-a": "intr", onClick: t, children: "Play Now" })
|
|
3391
926
|
] });
|
|
3392
|
-
}
|
|
3393
|
-
|
|
3394
|
-
|
|
3395
|
-
|
|
3396
|
-
|
|
3397
|
-
|
|
3398
|
-
|
|
3399
|
-
|
|
3400
|
-
|
|
3401
|
-
|
|
3402
|
-
|
|
3403
|
-
|
|
3404
|
-
|
|
3405
|
-
|
|
3406
|
-
|
|
3407
|
-
|
|
3408
|
-
|
|
3409
|
-
|
|
3410
|
-
|
|
3411
|
-
|
|
927
|
+
}, Q = [{
|
|
928
|
+
graphicSrc: "https://cdn.streamlayer.io/assets/sdk-web/onboarding-steps/dark/step_1.png",
|
|
929
|
+
tagline: "",
|
|
930
|
+
headline: /* @__PURE__ */ f(T, {
|
|
931
|
+
children: ["Welcome to ", /* @__PURE__ */ i("br", {}), " Live Challenge"]
|
|
932
|
+
})
|
|
933
|
+
}, {
|
|
934
|
+
graphicSrc: "https://cdn.streamlayer.io/assets/sdk-web/onboarding-steps/dark/step_2.png",
|
|
935
|
+
headline: "Live insights, polls, trivia and predictions."
|
|
936
|
+
}, {
|
|
937
|
+
graphicSrc: "https://cdn.streamlayer.io/assets/sdk-web/onboarding-steps/dark/step_3.png",
|
|
938
|
+
headline: "Win points and play against friends."
|
|
939
|
+
}], Wn = /* @__PURE__ */ u("div")({
|
|
940
|
+
name: "OnboardingContainer",
|
|
941
|
+
class: "o1xni1kr",
|
|
942
|
+
propsAsIs: !1
|
|
943
|
+
}), Gn = () => W, Hn = /* @__PURE__ */ u(Gn())({
|
|
944
|
+
name: "OnboardingNotificationContainer",
|
|
945
|
+
class: "o1vnouv7",
|
|
946
|
+
propsAsIs: !0
|
|
947
|
+
}), Ie = /* @__PURE__ */ u("div")({
|
|
948
|
+
name: "InnerContainer",
|
|
949
|
+
class: "i59uefw",
|
|
950
|
+
propsAsIs: !1
|
|
951
|
+
}), Jn = /* @__PURE__ */ u("div")({
|
|
952
|
+
name: "OnboardingOverlap",
|
|
953
|
+
class: "ovnr8ov",
|
|
954
|
+
propsAsIs: !1
|
|
955
|
+
}), Yn = ({
|
|
956
|
+
deepLink: e,
|
|
957
|
+
onboardingOpts: t,
|
|
958
|
+
notification: n,
|
|
959
|
+
gamification: o,
|
|
960
|
+
loading: s,
|
|
961
|
+
sdk: r,
|
|
962
|
+
throttled: l
|
|
963
|
+
}) => {
|
|
964
|
+
var d, a, c, m, p, h, g;
|
|
965
|
+
const b = v(o.friends ? o.friends.getStore() : ye({
|
|
966
|
+
data: []
|
|
967
|
+
})), [$, I] = S(void 0), B = C(() => {
|
|
968
|
+
var R, _;
|
|
969
|
+
const J = r.getInviter();
|
|
970
|
+
return J ? (_ = (R = b.data) == null ? void 0 : R.find(({
|
|
971
|
+
slId: we
|
|
972
|
+
}) => we === J)) == null ? void 0 : _.name : "";
|
|
973
|
+
}, [b.data, r]);
|
|
974
|
+
return y(() => {
|
|
975
|
+
const R = e.$store.subscribe((_) => {
|
|
976
|
+
_ && I(_.data);
|
|
977
|
+
});
|
|
978
|
+
return () => {
|
|
979
|
+
R();
|
|
980
|
+
};
|
|
981
|
+
}, [e.$store]), /* @__PURE__ */ f(Wn, {
|
|
982
|
+
children: [/* @__PURE__ */ i(Ze, {
|
|
983
|
+
loading: s,
|
|
984
|
+
rules: [{
|
|
985
|
+
label: "Answer as many questions as you like.",
|
|
986
|
+
icon: "icon-btn-feature-groups"
|
|
987
|
+
}, {
|
|
988
|
+
label: "Win points for each correct trivia or prediction answer.",
|
|
989
|
+
icon: "icon-thumb-up"
|
|
990
|
+
}, {
|
|
991
|
+
label: "Top the leader board and best your friends.",
|
|
992
|
+
icon: "icon-trophy"
|
|
993
|
+
}],
|
|
994
|
+
rulesBtnLabel: (d = t.rules) == null ? void 0 : d.buttonLabel,
|
|
995
|
+
rulesTitle: (a = t.rules) == null ? void 0 : a.heading,
|
|
996
|
+
termsTitle: "Terms and Conditions",
|
|
997
|
+
termsText: (c = t.rules) == null ? void 0 : c.terms,
|
|
998
|
+
steps: Q,
|
|
999
|
+
primaryColor: (m = t.inviteCard) == null ? void 0 : m.iconColor,
|
|
1000
|
+
inviteLink: $,
|
|
1001
|
+
inviteCardTitle: (p = t.inviteCard) == null ? void 0 : p.heading,
|
|
1002
|
+
inviteCardSubtext: (h = t.inviteCard) == null ? void 0 : h.subtext,
|
|
1003
|
+
inviteCardBtnLabel: (g = t.inviteCard) == null ? void 0 : g.buttonLabel,
|
|
1004
|
+
onClose: () => {
|
|
1005
|
+
var R;
|
|
1006
|
+
(R = n.close) == null || R.call(n);
|
|
1007
|
+
},
|
|
1008
|
+
gamification: o,
|
|
1009
|
+
sdk: r,
|
|
1010
|
+
inviterName: B
|
|
1011
|
+
}), l && /* @__PURE__ */ i(Jn, {})]
|
|
1012
|
+
});
|
|
1013
|
+
}, Zn = ({
|
|
1014
|
+
sdk: e,
|
|
1015
|
+
notification: t,
|
|
1016
|
+
saveHeight: n,
|
|
1017
|
+
style: o,
|
|
1018
|
+
appNode: s,
|
|
1019
|
+
sdkInDesktopView: r,
|
|
1020
|
+
responsiveStore: l
|
|
1021
|
+
}) => {
|
|
1022
|
+
const d = L(null), a = t.data.onboarding, [c, m] = S(a == null ? void 0 : a.instantOpen), p = e.getFeature(N.GAMES), h = C(() => Q == null ? void 0 : Q.map(({
|
|
1023
|
+
graphicSrc: I
|
|
1024
|
+
}) => I), []), {
|
|
1025
|
+
screen: g
|
|
1026
|
+
} = v(l, {
|
|
1027
|
+
keys: ["screen"]
|
|
1028
|
+
});
|
|
1029
|
+
Te(() => {
|
|
1030
|
+
var I;
|
|
1031
|
+
n(((I = d.current) == null ? void 0 : I.getBoundingClientRect().height) || 0);
|
|
1032
|
+
}, [n]);
|
|
1033
|
+
const {
|
|
1034
|
+
loading: b,
|
|
1035
|
+
throttled: $
|
|
1036
|
+
} = Ye(h);
|
|
1037
|
+
return c && p && a && s.current ? /* @__PURE__ */ i(Ne, {
|
|
1038
|
+
container: s,
|
|
1039
|
+
useContainer: !r,
|
|
1040
|
+
children: /* @__PURE__ */ i(Yn, {
|
|
1041
|
+
throttled: $,
|
|
1042
|
+
notification: t,
|
|
1043
|
+
setOpened: m,
|
|
1044
|
+
gamification: p,
|
|
1045
|
+
onboardingOpts: a,
|
|
1046
|
+
deepLink: p.deepLink,
|
|
1047
|
+
loading: b,
|
|
1048
|
+
renderToNode: s,
|
|
1049
|
+
sdk: e
|
|
1050
|
+
})
|
|
1051
|
+
}) : /* @__PURE__ */ f(T, {
|
|
1052
|
+
children: [/* @__PURE__ */ i(Ie, {
|
|
1053
|
+
ref: d,
|
|
1054
|
+
style: {
|
|
1055
|
+
position: "absolute",
|
|
1056
|
+
visibility: "hidden"
|
|
1057
|
+
},
|
|
1058
|
+
children: /* @__PURE__ */ i(ge, {
|
|
1059
|
+
close: () => {
|
|
1060
|
+
},
|
|
1061
|
+
action: () => {
|
|
1062
|
+
},
|
|
1063
|
+
onboarding: a
|
|
1064
|
+
})
|
|
1065
|
+
}), /* @__PURE__ */ i(Hn, {
|
|
1066
|
+
style: o,
|
|
1067
|
+
hiding: t.hiding,
|
|
1068
|
+
children: /* @__PURE__ */ i(Ie, {
|
|
1069
|
+
children: /* @__PURE__ */ i(ge, {
|
|
1070
|
+
close: t.close,
|
|
1071
|
+
action: () => {
|
|
1072
|
+
var I;
|
|
1073
|
+
m(!0), (((I = s.current) == null ? void 0 : I.getBoundingClientRect().y) || 0) < 0 && H(s, g.size, {
|
|
1074
|
+
behavior: "smooth"
|
|
1075
|
+
});
|
|
1076
|
+
},
|
|
1077
|
+
onboarding: a
|
|
1078
|
+
})
|
|
1079
|
+
})
|
|
1080
|
+
})]
|
|
1081
|
+
});
|
|
1082
|
+
}, Xn = () => W, es = /* @__PURE__ */ u(Xn())({
|
|
1083
|
+
name: "Container",
|
|
1084
|
+
class: "c8ol1ve",
|
|
1085
|
+
propsAsIs: !0
|
|
1086
|
+
}), Ae = /* @__PURE__ */ u("div")({
|
|
1087
|
+
name: "InnerContainer",
|
|
1088
|
+
class: "iqfywam",
|
|
1089
|
+
propsAsIs: !1
|
|
1090
|
+
}), ts = () => Ae, ns = /* @__PURE__ */ u(ts())({
|
|
1091
|
+
name: "HiddenContainer",
|
|
1092
|
+
class: "hokmtod",
|
|
1093
|
+
propsAsIs: !0
|
|
1094
|
+
}), ss = /* @__PURE__ */ u("div")({
|
|
1095
|
+
name: "NotificationRefreshing",
|
|
1096
|
+
class: "n192d1q8",
|
|
1097
|
+
propsAsIs: !1
|
|
1098
|
+
}), os = () => Xe, is = /* @__PURE__ */ u(os())({
|
|
1099
|
+
name: "Pill",
|
|
1100
|
+
class: "p1lha68t",
|
|
1101
|
+
propsAsIs: !0
|
|
1102
|
+
}), as = (e) => {
|
|
1103
|
+
const [t, n] = S(0), o = L(null), s = C(() => new ResizeObserver((d) => {
|
|
1104
|
+
window.requestAnimationFrame(() => {
|
|
1105
|
+
var a;
|
|
1106
|
+
if (Array.isArray(d)) {
|
|
1107
|
+
for (const c of d)
|
|
1108
|
+
if (c.contentBoxSize) {
|
|
1109
|
+
const m = (a = o.current) == null ? void 0 : a.getBoundingClientRect();
|
|
1110
|
+
m && n(m.height);
|
|
1111
|
+
}
|
|
1112
|
+
}
|
|
1113
|
+
});
|
|
1114
|
+
}), []), r = j((d) => {
|
|
1115
|
+
o.current = d;
|
|
1116
|
+
}, []), l = j((d) => {
|
|
1117
|
+
n(d);
|
|
1118
|
+
}, []);
|
|
1119
|
+
return y(() => {
|
|
1120
|
+
const d = o.current;
|
|
1121
|
+
return d ? (s.observe(d), () => {
|
|
1122
|
+
s.unobserve(d);
|
|
1123
|
+
}) : () => {
|
|
1124
|
+
};
|
|
1125
|
+
}, [e]), y(() => () => {
|
|
1126
|
+
s.disconnect();
|
|
1127
|
+
}), [r, t, l];
|
|
1128
|
+
}, rs = ({
|
|
1129
|
+
sdk: e,
|
|
1130
|
+
notification: t,
|
|
1131
|
+
appNode: n,
|
|
1132
|
+
responsiveStore: o,
|
|
1133
|
+
hasActiveFeature: s
|
|
1134
|
+
}) => {
|
|
1135
|
+
var r, l;
|
|
1136
|
+
const {
|
|
1137
|
+
sdkInDesktopView: d
|
|
1138
|
+
} = v(o, {
|
|
1139
|
+
keys: ["sdkInDesktopView"]
|
|
1140
|
+
}), {
|
|
1141
|
+
sdk: a
|
|
1142
|
+
} = G(), [c, m, p] = as(t.id);
|
|
1143
|
+
let h = m;
|
|
1144
|
+
return s || (h = "auto"), t.type === P.QUESTION ? /* @__PURE__ */ f(T, {
|
|
1145
|
+
children: [/* @__PURE__ */ i(ns, {
|
|
1146
|
+
ref: c,
|
|
1147
|
+
children: /* @__PURE__ */ i(te, {
|
|
1148
|
+
...t
|
|
1149
|
+
})
|
|
1150
|
+
}), /* @__PURE__ */ f(es, {
|
|
1151
|
+
style: {
|
|
1152
|
+
height: t.hiding ? 0 : h
|
|
1153
|
+
},
|
|
1154
|
+
hiding: t.hiding,
|
|
1155
|
+
children: [/* @__PURE__ */ i(Ae, {
|
|
1156
|
+
style: {
|
|
1157
|
+
height: "100%"
|
|
1158
|
+
},
|
|
1159
|
+
children: /* @__PURE__ */ i(te, {
|
|
1160
|
+
...t,
|
|
1161
|
+
controlVideo: a == null ? void 0 : a.controlVideoPlayer
|
|
1162
|
+
})
|
|
1163
|
+
}), /* @__PURE__ */ i(ss, {}, t.id)]
|
|
1164
|
+
})]
|
|
1165
|
+
}) : t.type === P.QUESTION_RESOLVED && (l = (r = t.data) == null ? void 0 : r.question) != null && l.predictionResult ? /* @__PURE__ */ i(et, {
|
|
1166
|
+
style: {
|
|
1167
|
+
height: t.hiding ? 0 : m
|
|
1168
|
+
},
|
|
1169
|
+
saveHeight: p,
|
|
1170
|
+
close: t.close,
|
|
1171
|
+
hiding: t.hiding,
|
|
1172
|
+
...t.data.question
|
|
1173
|
+
}) : t.type === P.ONBOARDING ? /* @__PURE__ */ i(Zn, {
|
|
1174
|
+
style: {
|
|
1175
|
+
height: t.hiding ? 0 : h
|
|
1176
|
+
},
|
|
1177
|
+
saveHeight: p,
|
|
1178
|
+
sdk: e,
|
|
1179
|
+
notification: t,
|
|
1180
|
+
sdkInDesktopView: d,
|
|
1181
|
+
appNode: n,
|
|
1182
|
+
responsiveStore: o
|
|
1183
|
+
}) : null;
|
|
1184
|
+
}, ls = "p7vfi6t", ds = ({
|
|
1185
|
+
pill: e,
|
|
1186
|
+
setPill: t,
|
|
1187
|
+
appNode: n,
|
|
1188
|
+
headerNode: o,
|
|
1189
|
+
scrollNode: s,
|
|
1190
|
+
responsiveStore: r,
|
|
1191
|
+
scrollStore: l
|
|
1192
|
+
}) => {
|
|
1193
|
+
var d, a;
|
|
1194
|
+
const {
|
|
1195
|
+
screen: c
|
|
1196
|
+
} = v(r, {
|
|
1197
|
+
keys: ["screen"]
|
|
1198
|
+
}), {
|
|
1199
|
+
tabsShown: m,
|
|
1200
|
+
scrollPosition: p
|
|
1201
|
+
} = v(l, {
|
|
1202
|
+
keys: ["tabsShown", "scrollPosition"]
|
|
1203
|
+
});
|
|
1204
|
+
y(() => {
|
|
1205
|
+
r.get().sdkInDesktopView ? p < 50 && t(null) : p > -50 && t(null);
|
|
1206
|
+
}, [p, r, t]);
|
|
1207
|
+
const h = r.get().sdkInDesktopView ? n : o;
|
|
1208
|
+
return !e || !h.current ? null : ht(/* @__PURE__ */ i(is, {
|
|
1209
|
+
title: e.type === P.QUESTION_RESOLVED ? "Prediction result" : `New ${((a = mt[(d = e.data) == null ? void 0 : d.questionType]) == null ? void 0 : a.label) || "notification"}`,
|
|
1210
|
+
"data-a": "intr",
|
|
1211
|
+
onClick: () => {
|
|
1212
|
+
var g;
|
|
1213
|
+
r.get().sdkInDesktopView ? (g = s.current) == null || g.scrollTo({
|
|
1214
|
+
top: 0,
|
|
1215
|
+
behavior: "smooth"
|
|
1216
|
+
}) : H(n, c.size, {
|
|
1217
|
+
behavior: "smooth"
|
|
1218
|
+
}), t(null);
|
|
1219
|
+
},
|
|
1220
|
+
className: E(m && ls, "sl-pill-button")
|
|
1221
|
+
}), h.current);
|
|
1222
|
+
}, cs = ({
|
|
1223
|
+
sdk: e,
|
|
1224
|
+
headerNode: t,
|
|
1225
|
+
scrollNode: n,
|
|
1226
|
+
responsiveStore: o,
|
|
1227
|
+
appNode: s,
|
|
1228
|
+
scrollStore: r,
|
|
1229
|
+
hasActiveFeature: l
|
|
1230
|
+
}) => {
|
|
1231
|
+
const [d] = S(e.getNotificationsStore()), a = v(d), [c, m] = S(null), p = C(() => e.getActiveNotification(), [e, a]);
|
|
1232
|
+
return y(() => {
|
|
1233
|
+
p && at.emit("notification", {
|
|
1234
|
+
action: "rendered",
|
|
1235
|
+
payload: {
|
|
1236
|
+
questionId: p.data.questionId,
|
|
1237
|
+
questionType: p.data.questionType
|
|
1238
|
+
}
|
|
1239
|
+
});
|
|
1240
|
+
}, [p]), y(() => {
|
|
1241
|
+
const {
|
|
1242
|
+
sdkInDesktopView: h,
|
|
1243
|
+
sdkInView: g
|
|
1244
|
+
} = o.get();
|
|
1245
|
+
p && (h || g) && (!h && g && m(p), h && window.requestAnimationFrame(() => {
|
|
1246
|
+
r.get().scrollPosition !== 0 && m(p);
|
|
1247
|
+
}));
|
|
1248
|
+
}, [p]), y(() => {
|
|
1249
|
+
p || m(null);
|
|
1250
|
+
}, [p]), /* @__PURE__ */ f(T, {
|
|
1251
|
+
children: [!c && p && /* @__PURE__ */ i(rs, {
|
|
1252
|
+
appNode: s,
|
|
1253
|
+
sdk: e,
|
|
1254
|
+
hasActiveFeature: l,
|
|
1255
|
+
notification: p,
|
|
1256
|
+
responsiveStore: o
|
|
1257
|
+
}), c && /* @__PURE__ */ i(ds, {
|
|
1258
|
+
pill: c,
|
|
1259
|
+
setPill: m,
|
|
1260
|
+
appNode: s,
|
|
1261
|
+
notification: p,
|
|
1262
|
+
headerNode: t,
|
|
1263
|
+
scrollNode: n,
|
|
1264
|
+
scrollStore: r,
|
|
1265
|
+
responsiveStore: o
|
|
1266
|
+
})]
|
|
1267
|
+
});
|
|
1268
|
+
}, ps = (e) => {
|
|
1269
|
+
const t = v(e.status), n = v(e.sdkStore.slStreamId), o = v(e.userId()), s = v(e.getActiveFeature()), r = t === "ready" && !!n.data;
|
|
1270
|
+
return y(() => {
|
|
1271
|
+
const l = e.getFeature(N.GAMES);
|
|
1272
|
+
l && s !== N.GAMES && (l.closeQuestion(), l.closeUser()), l == null || l.openedQuestionId.subscribe((d) => {
|
|
1273
|
+
d && s !== N.GAMES && e.openFeature(N.GAMES);
|
|
1274
|
+
});
|
|
1275
|
+
}, [s, e]), {
|
|
1276
|
+
sdkReady: r,
|
|
1277
|
+
activeFeature: s,
|
|
1278
|
+
isLogged: !!o
|
|
1279
|
+
};
|
|
1280
|
+
}, us = ({
|
|
1281
|
+
sdk: e,
|
|
1282
|
+
className: t,
|
|
1283
|
+
scrollStore: n,
|
|
1284
|
+
appNode: o,
|
|
1285
|
+
scrollNode: s,
|
|
1286
|
+
responsiveStore: r
|
|
1287
|
+
}) => {
|
|
1288
|
+
const [, l] = tt(e);
|
|
1289
|
+
return /* @__PURE__ */ i(cn, {
|
|
1290
|
+
className: t,
|
|
1291
|
+
scrollNode: s,
|
|
1292
|
+
appNode: o,
|
|
1293
|
+
scrollStore: n,
|
|
1294
|
+
feature: l,
|
|
1295
|
+
responsiveStore: r,
|
|
1296
|
+
sdk: e
|
|
1297
|
+
});
|
|
1298
|
+
}, ms = ({
|
|
1299
|
+
sdk: e,
|
|
1300
|
+
muted: t,
|
|
1301
|
+
className: n,
|
|
1302
|
+
appNode: o,
|
|
1303
|
+
responsiveStore: s
|
|
1304
|
+
}) => {
|
|
1305
|
+
const r = v(e.featuresList.getStore());
|
|
1306
|
+
return r ? Array.from(r, (l) => {
|
|
1307
|
+
const d = e.getFeature(l);
|
|
1308
|
+
return d ? /* @__PURE__ */ i(pn, {
|
|
1309
|
+
className: n,
|
|
1310
|
+
muted: t,
|
|
1311
|
+
appNode: o,
|
|
1312
|
+
feature: d,
|
|
1313
|
+
responsiveStore: s,
|
|
1314
|
+
sdk: e
|
|
1315
|
+
}, l) : null;
|
|
1316
|
+
}) : null;
|
|
1317
|
+
}, hs = ({
|
|
1318
|
+
sdk: e,
|
|
1319
|
+
muted: t,
|
|
1320
|
+
topNavigation: n
|
|
1321
|
+
}) => {
|
|
1322
|
+
const [o, s] = S(!0), r = L(null), l = v(e.uiState), d = L(null), [a] = vt(r), [c, m] = gt(r, a), {
|
|
1323
|
+
sdkReady: p,
|
|
1324
|
+
activeFeature: h,
|
|
1325
|
+
isLogged: g
|
|
1326
|
+
} = ps(e), b = !!p;
|
|
1327
|
+
st(r, {
|
|
1328
|
+
enabled: b,
|
|
1329
|
+
event: "click",
|
|
1330
|
+
listener: ot
|
|
1331
|
+
});
|
|
1332
|
+
const $ = C(() => ({
|
|
1333
|
+
sdk: e,
|
|
1334
|
+
topNavigation: n
|
|
1335
|
+
}), [e, n]);
|
|
1336
|
+
return y(() => {
|
|
1337
|
+
import("./gamification-feature.js");
|
|
1338
|
+
}, []), /* @__PURE__ */ i(lt.Provider, {
|
|
1339
|
+
value: $,
|
|
1340
|
+
children: /* @__PURE__ */ f(Qe, {
|
|
1341
|
+
ref: (I) => {
|
|
1342
|
+
r.current = I, s(!!I);
|
|
1343
|
+
},
|
|
1344
|
+
className: n ? "" : "c10llmat",
|
|
1345
|
+
children: [b && n && l.app && /* @__PURE__ */ i(Mn, {
|
|
1346
|
+
className: E(F, "sl-hide-on-modal"),
|
|
1347
|
+
sdk: e,
|
|
1348
|
+
ref: d
|
|
1349
|
+
}), b && !n && !!h && l.app && /* @__PURE__ */ i(_n, {
|
|
1350
|
+
className: E(F, "sl-hide-on-modal"),
|
|
1351
|
+
sdk: e,
|
|
1352
|
+
ref: d
|
|
1353
|
+
}), /* @__PURE__ */ f(We, {
|
|
1354
|
+
className: "sl-hide-on-modal",
|
|
1355
|
+
ref: c,
|
|
1356
|
+
"data-nav": (!!h && b).toString(),
|
|
1357
|
+
children: [b && l.app && /* @__PURE__ */ i(cs, {
|
|
1358
|
+
sdk: e,
|
|
1359
|
+
scrollNode: c,
|
|
1360
|
+
headerNode: d,
|
|
1361
|
+
appNode: r,
|
|
1362
|
+
scrollStore: m,
|
|
1363
|
+
responsiveStore: a,
|
|
1364
|
+
hasActiveFeature: !!h
|
|
1365
|
+
}), b && l.app && /* @__PURE__ */ i(us, {
|
|
1366
|
+
scrollStore: m,
|
|
1367
|
+
responsiveStore: a,
|
|
1368
|
+
scrollNode: c,
|
|
1369
|
+
appNode: r,
|
|
1370
|
+
className: F,
|
|
1371
|
+
sdk: e
|
|
1372
|
+
}), b && o && /* @__PURE__ */ i(ms, {
|
|
1373
|
+
muted: t,
|
|
1374
|
+
responsiveStore: a,
|
|
1375
|
+
appNode: r,
|
|
1376
|
+
className: F,
|
|
1377
|
+
sdk: e
|
|
1378
|
+
})]
|
|
1379
|
+
}), b && !g && o && l.app && /* @__PURE__ */ i("div", {
|
|
1380
|
+
style: {
|
|
1381
|
+
display: "flex",
|
|
1382
|
+
alignItems: "center",
|
|
1383
|
+
justifyContent: "center",
|
|
1384
|
+
width: "100%",
|
|
1385
|
+
height: "100%"
|
|
1386
|
+
},
|
|
1387
|
+
children: "You are not logged in."
|
|
1388
|
+
})]
|
|
1389
|
+
})
|
|
1390
|
+
});
|
|
1391
|
+
}, Ps = ({ event: e, topNavigation: t, theme: n, muted: o, withSidebarNotification: s = !0 }) => {
|
|
1392
|
+
const { sdk: r, status: l } = Y(Z), d = De(), a = Oe(), { event: c } = Y(Z);
|
|
1393
|
+
if (l === X.UNSET)
|
|
1394
|
+
throw new Error("Wrap app in `StreamLayerProvider`");
|
|
1395
|
+
return l === X.CONNECTED ? /* @__PURE__ */ i("div", { className: "StreamLayerSDK", children: "wait" }) : r === null ? /* @__PURE__ */ i("div", { className: "StreamLayerSDK", children: "sdk not initialized" }) : !d.app && !d.appNotification && !d.appSidebar || !d.app && !d.appSidebar && d.appNotification && !s ? null : /* @__PURE__ */ i("div", { className: "StreamLayerSDK", children: /* @__PURE__ */ i(Me, { customTheme: n ?? a.theme, themeMode: a.themeMode, children: /* @__PURE__ */ i(hs, { sdk: r, muted: o, event: (c == null ? void 0 : c.current) || e, topNavigation: t }) }) });
|
|
1396
|
+
};
|
|
3412
1397
|
export {
|
|
3413
|
-
|
|
3414
|
-
|
|
1398
|
+
zs as B,
|
|
1399
|
+
Ps as b
|
|
3415
1400
|
};
|