@streamlayer/react 0.29.9 → 0.29.11
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/cjs/masters.js +1 -1
- package/lib/cjs/points.js +1 -1
- package/lib/dist/cjs/masters.js +1 -1
- package/lib/dist/es/masters.js +1 -1
- package/lib/dist/index-56687fbe.cjs +1 -0
- package/lib/dist/index-b7b397b9.js +1740 -0
- package/lib/dist/index.d.ts +2 -0
- package/lib/dist/{masters-63e8a172.js → masters-791400ce.js} +1044 -1028
- package/lib/dist/{masters-759c16c9.cjs → masters-8c3bc143.cjs} +6 -6
- package/lib/dist/style.css +8 -5
- package/lib/es/masters.js +2 -2
- package/lib/es/points.js +9 -9
- package/lib/index-60fabb42.cjs +6 -0
- package/lib/{index-616b0bcd.js → index-81810ce0.js} +100 -86
- package/lib/index-9a1075fa.cjs +1 -0
- package/lib/{index-8774a3f9.js → index-d3a5d095.js} +748 -711
- package/lib/{masters-8f8cf5ae.js → masters-a0c5967c.js} +45 -45
- package/lib/{masters-0649c872.cjs → masters-b0b09591.cjs} +1 -1
- package/lib/style.css +1 -1
- package/package.json +6 -6
- package/lib/dist/index-44ddc69c.js +0 -1703
- package/lib/dist/index-cf0d1d15.cjs +0 -1
- package/lib/index-3ce72dff.cjs +0 -6
- package/lib/index-b0206045.cjs +0 -1
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { jsxs as v, jsx as
|
|
2
|
-
import { s as g,
|
|
1
|
+
import { jsxs as v, jsx as h, Fragment as de } from "react/jsx-runtime";
|
|
2
|
+
import { s as g, i as Q } from "./index-81810ce0.js";
|
|
3
3
|
import { useStore as re } from "@nanostores/react";
|
|
4
|
-
import { o as Et, r as Tt, w as Wt, e as
|
|
5
|
-
import { useState as xe, useCallback as
|
|
4
|
+
import { o as Et, r as Tt, w as Wt, e as Ve, n as Vt, f as Ht } from "./masters-a0c5967c.js";
|
|
5
|
+
import { useState as xe, useCallback as be, useMemo as Se, Component as Gt, createElement as ze, PureComponent as vt } from "react";
|
|
6
6
|
import { QuestionType as q, QuestionStatus as we, QuestionImages as ue, PickHistoryStatus as Ne } from "@streamlayer/sdk-web-types";
|
|
7
7
|
import { o as Nt, i as _t, r as Zt, a as Jt, n as Kt } from "./common-2d2a3ba3.js";
|
|
8
8
|
import { CountdownCircleTimer as Xt } from "react-countdown-circle-timer";
|
|
9
|
-
import { E as
|
|
9
|
+
import { E as he } from "./index-0d23b24e.js";
|
|
10
10
|
import "@streamlayer/sdk-web-interfaces";
|
|
11
11
|
import "@streamlayer/sdk-web-notifications";
|
|
12
12
|
import "./es/useStreamLayerApp.js";
|
|
@@ -39,10 +39,10 @@ const er = () => Q, tr = () => Q, rr = /* @__PURE__ */ g("div")({
|
|
|
39
39
|
const c = i ? Et[i] : { label: a, iconName: void 0 };
|
|
40
40
|
return /* @__PURE__ */ v(rr, { children: [
|
|
41
41
|
/* @__PURE__ */ v(ir, { children: [
|
|
42
|
-
(c == null ? void 0 : c.iconName) && /* @__PURE__ */
|
|
43
|
-
(c == null ? void 0 : c.label) && /* @__PURE__ */
|
|
42
|
+
(c == null ? void 0 : c.iconName) && /* @__PURE__ */ h(nr, { name: c.iconName }),
|
|
43
|
+
(c == null ? void 0 : c.label) && /* @__PURE__ */ h(sr, { children: c.label })
|
|
44
44
|
] }),
|
|
45
|
-
/* @__PURE__ */
|
|
45
|
+
/* @__PURE__ */ h(or, { onClick: n, children: /* @__PURE__ */ h(ar, { name: "icon-cross" }) })
|
|
46
46
|
] });
|
|
47
47
|
};
|
|
48
48
|
const lr = /* @__PURE__ */ g("div")({
|
|
@@ -58,8 +58,8 @@ const lr = /* @__PURE__ */ g("div")({
|
|
|
58
58
|
class: "i1whkbqh",
|
|
59
59
|
propsAsIs: !1
|
|
60
60
|
}), ot = ({ indicator: i, title: n }) => /* @__PURE__ */ v(lr, { children: [
|
|
61
|
-
/* @__PURE__ */
|
|
62
|
-
/* @__PURE__ */
|
|
61
|
+
/* @__PURE__ */ h(cr, { children: n }),
|
|
62
|
+
/* @__PURE__ */ h(ur, { children: i })
|
|
63
63
|
] });
|
|
64
64
|
const dr = /* @__PURE__ */ g("div")({
|
|
65
65
|
name: "i",
|
|
@@ -74,8 +74,8 @@ const dr = /* @__PURE__ */ g("div")({
|
|
|
74
74
|
class: "nwzed99",
|
|
75
75
|
propsAsIs: !1
|
|
76
76
|
}), _e = ({ indicator: i, title: n }) => /* @__PURE__ */ v(dr, { children: [
|
|
77
|
-
/* @__PURE__ */
|
|
78
|
-
/* @__PURE__ */
|
|
77
|
+
/* @__PURE__ */ h(hr, { children: i }),
|
|
78
|
+
/* @__PURE__ */ h(pr, { children: n })
|
|
79
79
|
] });
|
|
80
80
|
const fr = /* @__PURE__ */ g("div")({
|
|
81
81
|
name: "o",
|
|
@@ -155,24 +155,24 @@ const fr = /* @__PURE__ */ g("div")({
|
|
|
155
155
|
correct: m,
|
|
156
156
|
incorrect: o,
|
|
157
157
|
inTop: y,
|
|
158
|
-
successRate:
|
|
158
|
+
successRate: E
|
|
159
159
|
}) => /* @__PURE__ */ v(fr, { children: [
|
|
160
|
-
/* @__PURE__ */
|
|
160
|
+
/* @__PURE__ */ h(mr, { children: /* @__PURE__ */ v(Ir, { children: [
|
|
161
161
|
/* @__PURE__ */ v(Dr, { children: [
|
|
162
|
-
i && /* @__PURE__ */
|
|
163
|
-
!i && /* @__PURE__ */
|
|
162
|
+
i && /* @__PURE__ */ h(yr, { alt: "avatar", src: i }),
|
|
163
|
+
!i && /* @__PURE__ */ h(zr, { children: Nt(n || "") })
|
|
164
164
|
] }),
|
|
165
165
|
/* @__PURE__ */ v(xr, { children: [
|
|
166
|
-
/* @__PURE__ */
|
|
166
|
+
/* @__PURE__ */ h(wr, { children: n }),
|
|
167
167
|
/* @__PURE__ */ v(Mr, { children: [
|
|
168
168
|
/* @__PURE__ */ v(Er, { children: [
|
|
169
|
-
/* @__PURE__ */
|
|
169
|
+
/* @__PURE__ */ h(Ar, { alt: "rank-icon", src: br }),
|
|
170
170
|
/* @__PURE__ */ v(Tr, { children: [
|
|
171
171
|
_t(a),
|
|
172
|
-
/* @__PURE__ */
|
|
172
|
+
/* @__PURE__ */ h(vr, { children: "PTS" })
|
|
173
173
|
] })
|
|
174
174
|
] }),
|
|
175
|
-
/* @__PURE__ */
|
|
175
|
+
/* @__PURE__ */ h(Nr, {}),
|
|
176
176
|
/* @__PURE__ */ v("div", { children: [
|
|
177
177
|
"TOP ",
|
|
178
178
|
y || 0,
|
|
@@ -183,22 +183,39 @@ const fr = /* @__PURE__ */ g("div")({
|
|
|
183
183
|
] }) }),
|
|
184
184
|
/* @__PURE__ */ v(gr, { children: [
|
|
185
185
|
/* @__PURE__ */ v(_r, { children: [
|
|
186
|
-
/* @__PURE__ */
|
|
187
|
-
/* @__PURE__ */
|
|
186
|
+
/* @__PURE__ */ h(ot, { indicator: c || 0, title: "Friends rank" }),
|
|
187
|
+
/* @__PURE__ */ h(ot, { indicator: u || 0, title: "Global rank" })
|
|
188
188
|
] }),
|
|
189
189
|
/* @__PURE__ */ v(Sr, { children: [
|
|
190
|
-
/* @__PURE__ */
|
|
191
|
-
/* @__PURE__ */
|
|
192
|
-
/* @__PURE__ */
|
|
193
|
-
/* @__PURE__ */
|
|
190
|
+
/* @__PURE__ */ h(_e, { indicator: I || 0, title: "Win streak" }),
|
|
191
|
+
/* @__PURE__ */ h(_e, { indicator: m || 0, title: "Correct" }),
|
|
192
|
+
/* @__PURE__ */ h(_e, { indicator: o || 0, title: "Incorrect" }),
|
|
193
|
+
/* @__PURE__ */ h(_e, { indicator: `${E || 0}%`, title: "Succ. rate" })
|
|
194
194
|
] })
|
|
195
195
|
] })
|
|
196
196
|
] });
|
|
197
|
-
const Or =
|
|
197
|
+
const Or = /* @__PURE__ */ g("div")({
|
|
198
|
+
name: "i",
|
|
199
|
+
class: "i1mbhc7z",
|
|
200
|
+
propsAsIs: !1
|
|
201
|
+
}), Lr = /* @__PURE__ */ g("div")({
|
|
202
|
+
name: "n",
|
|
203
|
+
class: "n1f9yefw",
|
|
204
|
+
propsAsIs: !1
|
|
205
|
+
}), kr = /* @__PURE__ */ g("div")({
|
|
206
|
+
name: "o",
|
|
207
|
+
class: "o1n7beii",
|
|
208
|
+
propsAsIs: !1
|
|
209
|
+
}), Br = ({ title: i, description: n }) => /* @__PURE__ */ v(Or, { children: [
|
|
210
|
+
/* @__PURE__ */ h(Q, { name: "icon-check-circle" }),
|
|
211
|
+
/* @__PURE__ */ h(Lr, { children: i }),
|
|
212
|
+
/* @__PURE__ */ h(kr, { children: n })
|
|
213
|
+
] });
|
|
214
|
+
const Cr = () => Q, Rr = /* @__PURE__ */ g("div")({
|
|
198
215
|
name: "c",
|
|
199
216
|
class: "ciyeb68",
|
|
200
217
|
propsAsIs: !1
|
|
201
|
-
}),
|
|
218
|
+
}), Ur = /* @__PURE__ */ g(Cr())({
|
|
202
219
|
name: "n",
|
|
203
220
|
class: "nfic4xc",
|
|
204
221
|
propsAsIs: !0
|
|
@@ -210,19 +227,19 @@ const Or = () => Q, Cr = /* @__PURE__ */ g("div")({
|
|
|
210
227
|
name: "p",
|
|
211
228
|
class: "p132yxcv",
|
|
212
229
|
propsAsIs: !1
|
|
213
|
-
}),
|
|
230
|
+
}), jr = /* @__PURE__ */ g("span")({
|
|
214
231
|
name: "l",
|
|
215
232
|
class: "l4a8aw",
|
|
216
233
|
propsAsIs: !1
|
|
217
|
-
}),
|
|
234
|
+
}), Fe = /* @__PURE__ */ g("span")({
|
|
218
235
|
name: "g",
|
|
219
236
|
class: "gzdx7pk",
|
|
220
237
|
propsAsIs: !1
|
|
221
|
-
}),
|
|
238
|
+
}), Fr = /* @__PURE__ */ g("div")({
|
|
222
239
|
name: "s",
|
|
223
240
|
class: "smnc4zm",
|
|
224
241
|
propsAsIs: !1
|
|
225
|
-
}),
|
|
242
|
+
}), $r = ({
|
|
226
243
|
feedbackMessages: i,
|
|
227
244
|
questionVotedCorrectly: n,
|
|
228
245
|
questionVoted: a,
|
|
@@ -233,62 +250,62 @@ const Or = () => Q, Cr = /* @__PURE__ */ g("div")({
|
|
|
233
250
|
const m = a && (c === q.TRIVIA || c === q.PREDICTION);
|
|
234
251
|
if (!m && I !== we.RESOLVED)
|
|
235
252
|
return null;
|
|
236
|
-
const o = c === q.PREDICTION && !u, y = n ? "correct" : "incorrect",
|
|
237
|
-
return /* @__PURE__ */ v(
|
|
238
|
-
I === we.RESOLVED && c === q.TRIVIA && !a && /* @__PURE__ */ v(
|
|
239
|
-
/* @__PURE__ */
|
|
253
|
+
const o = c === q.PREDICTION && !u, y = n ? "correct" : "incorrect", E = n ? i.correctFeedback : i.incorrectFeedback;
|
|
254
|
+
return /* @__PURE__ */ v(Rr, { "data-isPrediction": o, children: [
|
|
255
|
+
I === we.RESOLVED && c === q.TRIVIA && !a && /* @__PURE__ */ v(de, { children: [
|
|
256
|
+
/* @__PURE__ */ h(at, { children: /* @__PURE__ */ h(Q, { name: "questionExpired" }) }),
|
|
240
257
|
/* @__PURE__ */ v("div", { children: [
|
|
241
|
-
/* @__PURE__ */
|
|
242
|
-
/* @__PURE__ */
|
|
258
|
+
/* @__PURE__ */ h(lt, { children: /* @__PURE__ */ h(Fe, { children: "Question Expired" }) }),
|
|
259
|
+
/* @__PURE__ */ h(Fr, { children: "You can still answer to see if you're correct, but no points are awarded for expired questions." })
|
|
243
260
|
] })
|
|
244
261
|
] }),
|
|
245
|
-
m && o && /* @__PURE__ */ v(
|
|
246
|
-
/* @__PURE__ */
|
|
247
|
-
/* @__PURE__ */
|
|
262
|
+
m && o && /* @__PURE__ */ v(de, { children: [
|
|
263
|
+
/* @__PURE__ */ h(Ur, { name: "icon-prediction" }),
|
|
264
|
+
/* @__PURE__ */ h(Fe, { children: "Stay tuned to see if your prediction was correct." })
|
|
248
265
|
] }),
|
|
249
|
-
m && u && /* @__PURE__ */ v(
|
|
250
|
-
/* @__PURE__ */
|
|
251
|
-
/* @__PURE__ */
|
|
252
|
-
/* @__PURE__ */
|
|
253
|
-
/* @__PURE__ */
|
|
266
|
+
m && u && /* @__PURE__ */ v(de, { children: [
|
|
267
|
+
/* @__PURE__ */ h(at, { "data-feedbackType": y, children: /* @__PURE__ */ h(Q, { name: y }) }),
|
|
268
|
+
/* @__PURE__ */ h("div", { children: /* @__PURE__ */ v(lt, { children: [
|
|
269
|
+
/* @__PURE__ */ h(jr, { "data-feedbackType": y, children: E == null ? void 0 : E.title }),
|
|
270
|
+
/* @__PURE__ */ h(Fe, { children: E == null ? void 0 : E.description })
|
|
254
271
|
] }) })
|
|
255
272
|
] })
|
|
256
273
|
] });
|
|
257
274
|
};
|
|
258
|
-
const
|
|
275
|
+
const Qr = /* @__PURE__ */ g("div")({
|
|
259
276
|
name: "o",
|
|
260
277
|
class: "olc1eph",
|
|
261
278
|
propsAsIs: !1
|
|
262
|
-
}),
|
|
279
|
+
}), Pr = /* @__PURE__ */ g("div")({
|
|
263
280
|
name: "n",
|
|
264
281
|
class: "n1yoh29a",
|
|
265
282
|
propsAsIs: !1
|
|
266
|
-
}),
|
|
267
|
-
name: "
|
|
268
|
-
class: "
|
|
283
|
+
}), qr = /* @__PURE__ */ g("div")({
|
|
284
|
+
name: "e",
|
|
285
|
+
class: "ejkr5mb",
|
|
269
286
|
propsAsIs: !1
|
|
270
|
-
}),
|
|
271
|
-
name: "
|
|
272
|
-
class: "
|
|
287
|
+
}), Yr = /* @__PURE__ */ g("div")({
|
|
288
|
+
name: "p",
|
|
289
|
+
class: "p82wnnx",
|
|
273
290
|
propsAsIs: !1
|
|
274
291
|
});
|
|
275
|
-
const
|
|
292
|
+
const Wr = () => Dt, Vr = () => Dt, Hr = () => Q, Gr = /* @__PURE__ */ g("button")({
|
|
276
293
|
name: "c",
|
|
277
294
|
class: "cpm4u8k",
|
|
278
295
|
propsAsIs: !1
|
|
279
|
-
}),
|
|
296
|
+
}), Zr = /* @__PURE__ */ g("div")({
|
|
280
297
|
name: "l",
|
|
281
298
|
class: "lwfomc3",
|
|
282
299
|
propsAsIs: !1
|
|
283
|
-
}),
|
|
300
|
+
}), Jr = /* @__PURE__ */ g("span")({
|
|
284
301
|
name: "d",
|
|
285
302
|
class: "dmltvg2",
|
|
286
303
|
propsAsIs: !1
|
|
287
|
-
}),
|
|
304
|
+
}), Kr = /* @__PURE__ */ g("div")({
|
|
288
305
|
name: "s",
|
|
289
306
|
class: "stfjpqz",
|
|
290
307
|
propsAsIs: !1
|
|
291
|
-
}),
|
|
308
|
+
}), Xr = /* @__PURE__ */ g("div")({
|
|
292
309
|
name: "p",
|
|
293
310
|
class: "p198m24r",
|
|
294
311
|
propsAsIs: !1
|
|
@@ -296,37 +313,37 @@ const Qr = () => Dt, Pr = () => Dt, qr = () => Q, Yr = /* @__PURE__ */ g("button
|
|
|
296
313
|
name: "r",
|
|
297
314
|
class: "rbq5eu7",
|
|
298
315
|
propsAsIs: !1
|
|
299
|
-
}),
|
|
316
|
+
}), ei = /* @__PURE__ */ g(Wr())({
|
|
300
317
|
name: "g",
|
|
301
318
|
class: "g1iv6oeb",
|
|
302
319
|
propsAsIs: !0
|
|
303
|
-
}),
|
|
320
|
+
}), ti = /* @__PURE__ */ g(Vr())({
|
|
304
321
|
name: "h",
|
|
305
322
|
class: "h1qtxlqc",
|
|
306
323
|
propsAsIs: !0
|
|
307
|
-
}),
|
|
324
|
+
}), ri = /* @__PURE__ */ g("span")({
|
|
308
325
|
name: "u",
|
|
309
326
|
class: "udm736q",
|
|
310
327
|
propsAsIs: !1
|
|
311
|
-
}),
|
|
328
|
+
}), ii = /* @__PURE__ */ g("span")({
|
|
312
329
|
name: "b",
|
|
313
330
|
class: "b1da34tx",
|
|
314
331
|
propsAsIs: !1
|
|
315
|
-
}),
|
|
332
|
+
}), ni = /* @__PURE__ */ g("span")({
|
|
316
333
|
name: "x",
|
|
317
334
|
class: "x1dqwq83",
|
|
318
335
|
propsAsIs: !1
|
|
319
|
-
}),
|
|
336
|
+
}), si = /* @__PURE__ */ g(Hr())({
|
|
320
337
|
name: "v",
|
|
321
338
|
class: "v10s9my2",
|
|
322
339
|
propsAsIs: !0
|
|
323
340
|
}), ct = {
|
|
324
|
-
[ue.CENTERED]: (i) => /* @__PURE__ */
|
|
325
|
-
[ue.TRANSPARENT]: (i) => /* @__PURE__ */
|
|
326
|
-
[ue.ROUNDED]: (i) => /* @__PURE__ */
|
|
341
|
+
[ue.CENTERED]: (i) => /* @__PURE__ */ h(ei, { alt: "option-icon", src: i }),
|
|
342
|
+
[ue.TRANSPARENT]: (i) => /* @__PURE__ */ h(Kr, { children: /* @__PURE__ */ h(Xr, { style: { backgroundImage: `url(${i})` } }) }),
|
|
343
|
+
[ue.ROUNDED]: (i) => /* @__PURE__ */ h(ti, { alt: "option-icon", src: i }),
|
|
327
344
|
[ue.NONE]: () => null,
|
|
328
345
|
[ue.UNSET]: () => null
|
|
329
|
-
},
|
|
346
|
+
}, oi = ({ questionType: i, hasCorrectAnswer: n, correct: a, youVoted: c, questionVoted: u }) => {
|
|
330
347
|
if (i === q.POLL && c)
|
|
331
348
|
return "correct";
|
|
332
349
|
if (i === q.PREDICTION) {
|
|
@@ -336,13 +353,13 @@ const Qr = () => Dt, Pr = () => Dt, qr = () => Q, Yr = /* @__PURE__ */ g("button
|
|
|
336
353
|
return "correct";
|
|
337
354
|
}
|
|
338
355
|
return i === q.TRIVIA && u ? c ? a ? "correct" : "incorrect" : a ? "correct" : "unset" : "unset";
|
|
339
|
-
},
|
|
356
|
+
}, ai = ({
|
|
340
357
|
questionType: i,
|
|
341
358
|
questionVoted: n,
|
|
342
359
|
correct: a,
|
|
343
360
|
hasCorrectAnswer: c,
|
|
344
361
|
questionStatus: u
|
|
345
|
-
}) => i === q.TRIVIA ? n && a : i === q.PREDICTION ? n && a && c || u === we.RESOLVED && a : !1,
|
|
362
|
+
}) => i === q.TRIVIA ? n && a : i === q.PREDICTION ? n && a && c || u === we.RESOLVED && a : !1, li = (i) => {
|
|
346
363
|
var n;
|
|
347
364
|
const {
|
|
348
365
|
// option props
|
|
@@ -355,30 +372,30 @@ const Qr = () => Dt, Pr = () => Dt, qr = () => Q, Yr = /* @__PURE__ */ g("button
|
|
|
355
372
|
youSelected: o,
|
|
356
373
|
questionVoted: y,
|
|
357
374
|
// ToDo: Figure out why imageMode is not in the response, and delete default value
|
|
358
|
-
imageMode:
|
|
359
|
-
answerTimeExpired:
|
|
375
|
+
imageMode: E = ue.ROUNDED,
|
|
376
|
+
answerTimeExpired: N,
|
|
360
377
|
questionStatus: S,
|
|
361
|
-
isLoading:
|
|
362
|
-
questionType:
|
|
363
|
-
correct:
|
|
364
|
-
hasCorrectAnswer:
|
|
365
|
-
} = i, M =
|
|
378
|
+
isLoading: w,
|
|
379
|
+
questionType: T,
|
|
380
|
+
correct: _,
|
|
381
|
+
hasCorrectAnswer: p
|
|
382
|
+
} = i, M = oi(i), x = ai({ questionType: T, questionVoted: y, correct: _, hasCorrectAnswer: p, questionStatus: S }), A = y || S === we.RESOLVED && T === q.PREDICTION;
|
|
366
383
|
return /* @__PURE__ */ v(
|
|
367
|
-
|
|
384
|
+
Gr,
|
|
368
385
|
{
|
|
369
386
|
value: a,
|
|
370
387
|
"data-selected": o,
|
|
371
388
|
"data-answerState": M,
|
|
372
|
-
disabled: y ||
|
|
389
|
+
disabled: y || w || N,
|
|
373
390
|
onClick: m,
|
|
374
391
|
children: [
|
|
375
|
-
A && /* @__PURE__ */
|
|
376
|
-
/* @__PURE__ */ v(
|
|
377
|
-
c && ((n = ct[
|
|
378
|
-
/* @__PURE__ */
|
|
379
|
-
A && /* @__PURE__ */ v(
|
|
380
|
-
|
|
381
|
-
/* @__PURE__ */ v(
|
|
392
|
+
A && /* @__PURE__ */ h(Zr, { "data-answerState": M, style: { width: `${I}%` } }),
|
|
393
|
+
/* @__PURE__ */ v(Jr, { children: [
|
|
394
|
+
c && ((n = ct[E]) == null ? void 0 : n.call(ct, c)),
|
|
395
|
+
/* @__PURE__ */ h(ri, { children: u }),
|
|
396
|
+
A && /* @__PURE__ */ v(ii, { children: [
|
|
397
|
+
x && /* @__PURE__ */ h(si, { name: "selected" }),
|
|
398
|
+
/* @__PURE__ */ v(ni, { children: [
|
|
382
399
|
I,
|
|
383
400
|
"%"
|
|
384
401
|
] })
|
|
@@ -388,29 +405,29 @@ const Qr = () => Dt, Pr = () => Dt, qr = () => Q, Yr = /* @__PURE__ */ g("button
|
|
|
388
405
|
}
|
|
389
406
|
);
|
|
390
407
|
};
|
|
391
|
-
const
|
|
408
|
+
const ci = [he.PRIMARY_GREEN1, he.SECONDARY_RED1, he.SECONDARY_RED1], ui = [10, 10, 0], di = /* @__PURE__ */ g("div")({
|
|
392
409
|
name: "A",
|
|
393
410
|
class: "a1f928zy",
|
|
394
411
|
propsAsIs: !1
|
|
395
|
-
}),
|
|
412
|
+
}), hi = he.SECONDARY_GREEN6, ut = he.SECONDARY_RED3, pi = he.NEUTRALS_GRAY3, fi = ({
|
|
396
413
|
isPlaying: i = !0,
|
|
397
414
|
duration: n = 30,
|
|
398
415
|
onTimerExpired: a
|
|
399
416
|
}) => {
|
|
400
|
-
const [c, u] = xe(n > 10 ?
|
|
417
|
+
const [c, u] = xe(n > 10 ? hi : ut), I = ({
|
|
401
418
|
remainingTime: y
|
|
402
|
-
}) => /* @__PURE__ */
|
|
419
|
+
}) => /* @__PURE__ */ h(di, {
|
|
403
420
|
children: y
|
|
404
|
-
}), m =
|
|
405
|
-
a == null || a(), u(
|
|
406
|
-
}, [a, u]), o =
|
|
421
|
+
}), m = be(() => {
|
|
422
|
+
a == null || a(), u(pi);
|
|
423
|
+
}, [a, u]), o = be((y) => {
|
|
407
424
|
y === 10 && u(ut);
|
|
408
425
|
}, [u]);
|
|
409
|
-
return /* @__PURE__ */
|
|
426
|
+
return /* @__PURE__ */ h(Xt, {
|
|
410
427
|
isPlaying: i,
|
|
411
428
|
duration: n,
|
|
412
|
-
colors:
|
|
413
|
-
colorsTime:
|
|
429
|
+
colors: ci,
|
|
430
|
+
colorsTime: ui,
|
|
414
431
|
size: 32,
|
|
415
432
|
strokeWidth: 2,
|
|
416
433
|
trailStrokeWidth: 2,
|
|
@@ -420,116 +437,126 @@ const si = [de.PRIMARY_GREEN1, de.SECONDARY_RED1, de.SECONDARY_RED1], oi = [10,
|
|
|
420
437
|
children: I
|
|
421
438
|
});
|
|
422
439
|
};
|
|
423
|
-
const
|
|
440
|
+
const mi = () => Q, gi = /* @__PURE__ */ g("div")({
|
|
424
441
|
name: "a",
|
|
425
442
|
class: "a1r7f3z4",
|
|
426
443
|
propsAsIs: !1
|
|
427
|
-
}),
|
|
444
|
+
}), Ii = /* @__PURE__ */ g("div")({
|
|
428
445
|
name: "s",
|
|
429
446
|
class: "sblndl",
|
|
430
447
|
propsAsIs: !1
|
|
431
|
-
}),
|
|
448
|
+
}), yi = /* @__PURE__ */ g("div")({
|
|
432
449
|
name: "l",
|
|
433
450
|
class: "l7ka1tv",
|
|
434
451
|
propsAsIs: !1
|
|
435
|
-
}),
|
|
452
|
+
}), xi = /* @__PURE__ */ g(mi())({
|
|
436
453
|
name: "p",
|
|
437
454
|
class: "p1edlxt3",
|
|
438
455
|
propsAsIs: !0
|
|
439
|
-
}),
|
|
456
|
+
}), wi = /* @__PURE__ */ g("div")({
|
|
440
457
|
name: "g",
|
|
441
458
|
class: "ghm08u2",
|
|
442
459
|
propsAsIs: !1
|
|
443
|
-
}),
|
|
460
|
+
}), Mi = /* @__PURE__ */ g("span")({
|
|
444
461
|
name: "c",
|
|
445
462
|
class: "c12nsh46",
|
|
446
463
|
propsAsIs: !1
|
|
447
|
-
}),
|
|
464
|
+
}), Ai = /* @__PURE__ */ g("span")({
|
|
448
465
|
name: "d",
|
|
449
466
|
class: "dlr9eoc",
|
|
450
467
|
propsAsIs: !1
|
|
451
|
-
}),
|
|
452
|
-
/* @__PURE__ */ v(
|
|
453
|
-
i && /* @__PURE__ */
|
|
454
|
-
n !== void 0 && /* @__PURE__ */ v(
|
|
455
|
-
/* @__PURE__ */
|
|
456
|
-
/* @__PURE__ */ v(
|
|
457
|
-
/* @__PURE__ */
|
|
458
|
-
/* @__PURE__ */
|
|
468
|
+
}), Ei = ({ title: i, points: n, isPlayingTimer: a, isTimer: c, onTimerExpired: u }) => /* @__PURE__ */ v(gi, { children: [
|
|
469
|
+
/* @__PURE__ */ v(Ii, { children: [
|
|
470
|
+
i && /* @__PURE__ */ h(yi, { children: i }),
|
|
471
|
+
n !== void 0 && /* @__PURE__ */ v(de, { children: [
|
|
472
|
+
/* @__PURE__ */ h(xi, { name: "icon-trophy" }),
|
|
473
|
+
/* @__PURE__ */ v(wi, { children: [
|
|
474
|
+
/* @__PURE__ */ h(Mi, { children: n }),
|
|
475
|
+
/* @__PURE__ */ h(Ai, { children: "PTS" })
|
|
459
476
|
] })
|
|
460
477
|
] })
|
|
461
478
|
] }),
|
|
462
|
-
c && /* @__PURE__ */
|
|
463
|
-
] }),
|
|
464
|
-
var
|
|
465
|
-
const
|
|
466
|
-
async (
|
|
467
|
-
if (
|
|
468
|
-
const
|
|
469
|
-
|
|
479
|
+
c && /* @__PURE__ */ h(fi, { isPlaying: a, onTimerExpired: u })
|
|
480
|
+
] }), Ti = ({ openedQuestion: i, vote: n, close: a }) => {
|
|
481
|
+
var c;
|
|
482
|
+
const u = i.subject, I = i.type, m = (c = i.options) == null ? void 0 : c.options, [o, y] = xe(!1), [E, N] = xe(!1), [S, w] = xe(""), T = i == null ? void 0 : i.id, _ = be(
|
|
483
|
+
async (b) => {
|
|
484
|
+
if (T) {
|
|
485
|
+
const D = b.currentTarget.value;
|
|
486
|
+
w(D), N(!0), await n(T, D), N(!1);
|
|
470
487
|
}
|
|
471
488
|
},
|
|
472
|
-
[
|
|
473
|
-
),
|
|
474
|
-
()
|
|
489
|
+
[T, w, n]
|
|
490
|
+
), p = be(() => {
|
|
491
|
+
y(!0), setTimeout(a, 3e3);
|
|
492
|
+
}, [a]), M = Se(
|
|
493
|
+
() => i == null ? void 0 : i.answers.find((b) => b.youVoted === !0),
|
|
475
494
|
[i]
|
|
476
|
-
),
|
|
477
|
-
() => !!(i != null && i.answers.find((
|
|
495
|
+
), x = Se(
|
|
496
|
+
() => !!(i != null && i.answers.find((b) => b.correct === !0)),
|
|
478
497
|
[i]
|
|
479
|
-
),
|
|
480
|
-
...
|
|
481
|
-
questionVoted: !!
|
|
482
|
-
youSelected:
|
|
483
|
-
isLoading:
|
|
484
|
-
hasCorrectAnswer:
|
|
498
|
+
), A = Se(() => i ? i.answers.map((b) => ({
|
|
499
|
+
...b,
|
|
500
|
+
questionVoted: !!M,
|
|
501
|
+
youSelected: S === b.id,
|
|
502
|
+
isLoading: E,
|
|
503
|
+
hasCorrectAnswer: x,
|
|
485
504
|
questionType: i.type,
|
|
486
|
-
answerTimeExpired:
|
|
505
|
+
answerTimeExpired: o,
|
|
487
506
|
questionStatus: i.status,
|
|
488
507
|
// ToDo: Figure out why imageMode is not in the response
|
|
489
|
-
onVote:
|
|
490
|
-
})) : [], [
|
|
491
|
-
return /* @__PURE__ */
|
|
492
|
-
|
|
493
|
-
|
|
508
|
+
onVote: _
|
|
509
|
+
})) : [], [x, o, E, i, M, _, S]), z = m && (m.case === "trivia" || m.case === "prediction") ? m.value : void 0;
|
|
510
|
+
return /* @__PURE__ */ h(Tt, { "data-question-header": "true", children: /* @__PURE__ */ h(Qr, { children: /* @__PURE__ */ v(Pr, { children: [
|
|
511
|
+
z && /* @__PURE__ */ h(
|
|
512
|
+
$r,
|
|
494
513
|
{
|
|
495
|
-
feedbackMessages:
|
|
496
|
-
questionVoted: !!
|
|
497
|
-
questionVotedCorrectly:
|
|
498
|
-
questionType:
|
|
499
|
-
hasCorrectAnswer:
|
|
514
|
+
feedbackMessages: z,
|
|
515
|
+
questionVoted: !!M,
|
|
516
|
+
questionVotedCorrectly: M == null ? void 0 : M.correct,
|
|
517
|
+
questionType: I,
|
|
518
|
+
hasCorrectAnswer: x,
|
|
500
519
|
questionStatus: i.status
|
|
501
520
|
}
|
|
502
521
|
),
|
|
503
|
-
/* @__PURE__ */
|
|
504
|
-
|
|
522
|
+
/* @__PURE__ */ h(
|
|
523
|
+
Ei,
|
|
505
524
|
{
|
|
506
|
-
title:
|
|
507
|
-
points:
|
|
508
|
-
onTimerExpired:
|
|
525
|
+
title: o ? "Time expired" : "To win",
|
|
526
|
+
points: o ? void 0 : 100,
|
|
527
|
+
onTimerExpired: p,
|
|
509
528
|
isTimer: !0
|
|
510
529
|
}
|
|
511
530
|
),
|
|
512
|
-
/* @__PURE__ */
|
|
513
|
-
|
|
531
|
+
o ? /* @__PURE__ */ h(
|
|
532
|
+
Br,
|
|
533
|
+
{
|
|
534
|
+
title: "More to come...",
|
|
535
|
+
description: "Watch for additional enhanced stream interactive experience."
|
|
536
|
+
}
|
|
537
|
+
) : /* @__PURE__ */ v(de, { children: [
|
|
538
|
+
/* @__PURE__ */ h(qr, { children: u }),
|
|
539
|
+
/* @__PURE__ */ h(Yr, { children: A.map((b) => /* @__PURE__ */ h(li, { ...b }, b.id)) })
|
|
540
|
+
] })
|
|
514
541
|
] }) }) });
|
|
515
542
|
};
|
|
516
|
-
const
|
|
543
|
+
const vi = /* @__PURE__ */ g("div")({
|
|
517
544
|
name: "e",
|
|
518
545
|
class: "e1eio0mt",
|
|
519
546
|
propsAsIs: !1
|
|
520
|
-
}),
|
|
547
|
+
}), Ni = /* @__PURE__ */ g("div")({
|
|
521
548
|
name: "i",
|
|
522
549
|
class: "iigl87b",
|
|
523
550
|
propsAsIs: !1
|
|
524
|
-
}),
|
|
551
|
+
}), _i = /* @__PURE__ */ g("h3")({
|
|
525
552
|
name: "n",
|
|
526
553
|
class: "n1o2cwub",
|
|
527
554
|
propsAsIs: !1
|
|
528
|
-
}),
|
|
555
|
+
}), Si = /* @__PURE__ */ g("div")({
|
|
529
556
|
name: "r",
|
|
530
557
|
class: "r3uxe45",
|
|
531
558
|
propsAsIs: !1
|
|
532
|
-
}),
|
|
559
|
+
}), zi = /* @__PURE__ */ g("div")({
|
|
533
560
|
name: "l",
|
|
534
561
|
class: "lrqius",
|
|
535
562
|
propsAsIs: !1
|
|
@@ -545,59 +572,61 @@ const Mi = /* @__PURE__ */ g("div")({
|
|
|
545
572
|
}
|
|
546
573
|
return null;
|
|
547
574
|
}, [i]);
|
|
548
|
-
return /* @__PURE__ */ v(
|
|
549
|
-
c && /* @__PURE__ */ v(
|
|
575
|
+
return /* @__PURE__ */ v(vi, { children: [
|
|
576
|
+
c && /* @__PURE__ */ v(zi, { children: [
|
|
550
577
|
c.date,
|
|
551
578
|
" · ",
|
|
552
579
|
c.time
|
|
553
580
|
] }),
|
|
554
|
-
(a == null ? void 0 : a.video) && /* @__PURE__ */
|
|
555
|
-
/* @__PURE__ */ v(
|
|
556
|
-
/* @__PURE__ */
|
|
557
|
-
/* @__PURE__ */
|
|
581
|
+
(a == null ? void 0 : a.video) && /* @__PURE__ */ h(Wt, { source: a.video.url, poster: a.video.thumbnailUrl }),
|
|
582
|
+
/* @__PURE__ */ v(Ni, { children: [
|
|
583
|
+
/* @__PURE__ */ h(_i, { children: (a == null ? void 0 : a.heading) || n }),
|
|
584
|
+
/* @__PURE__ */ h(Si, { children: a == null ? void 0 : a.body })
|
|
558
585
|
] })
|
|
559
586
|
] });
|
|
560
587
|
};
|
|
561
|
-
const
|
|
588
|
+
const Di = /* @__PURE__ */ g("div")({
|
|
562
589
|
name: "o",
|
|
563
590
|
class: "o18unvw4",
|
|
564
591
|
propsAsIs: !1
|
|
565
|
-
}),
|
|
592
|
+
}), bi = /* @__PURE__ */ g("a")({
|
|
566
593
|
name: "n",
|
|
567
594
|
class: "ns0uvk8",
|
|
568
595
|
propsAsIs: !1
|
|
569
|
-
}),
|
|
570
|
-
/* @__PURE__ */
|
|
571
|
-
(i == null ? void 0 : i.webLink) && /* @__PURE__ */ v(
|
|
596
|
+
}), Oi = ({ instantView: i, ...n }) => /* @__PURE__ */ v(Di, { children: [
|
|
597
|
+
/* @__PURE__ */ h(bt, { instantView: i, ...n }),
|
|
598
|
+
(i == null ? void 0 : i.webLink) && /* @__PURE__ */ v(bi, { href: i == null ? void 0 : i.webLink.url, target: "_blank", children: [
|
|
572
599
|
"Explore more of the Masters History",
|
|
573
|
-
/* @__PURE__ */
|
|
600
|
+
/* @__PURE__ */ h(Q, { name: "icon-external-link" })
|
|
574
601
|
] })
|
|
575
602
|
] });
|
|
576
|
-
const
|
|
603
|
+
const Li = /* @__PURE__ */ g("div")({
|
|
577
604
|
name: "d",
|
|
578
605
|
class: "dk8r1eq",
|
|
579
606
|
propsAsIs: !1
|
|
580
|
-
}),
|
|
607
|
+
}), ki = ({
|
|
581
608
|
openedQuestion: i
|
|
582
609
|
}) => {
|
|
583
610
|
var n;
|
|
584
|
-
return ((n = i == null ? void 0 : i.attributes) == null ? void 0 : n.attributes.case) === "insight" ? /* @__PURE__ */
|
|
611
|
+
return ((n = i == null ? void 0 : i.attributes) == null ? void 0 : n.attributes.case) === "insight" ? /* @__PURE__ */ h(Oi, {
|
|
585
612
|
created: i.attributes.created,
|
|
586
613
|
...i.attributes.attributes.value
|
|
587
614
|
}) : null;
|
|
588
|
-
},
|
|
615
|
+
}, Bi = ({
|
|
589
616
|
extendedQuestion: i,
|
|
590
|
-
vote: n
|
|
617
|
+
vote: n,
|
|
618
|
+
close: a
|
|
591
619
|
}) => {
|
|
592
620
|
const {
|
|
593
|
-
loading:
|
|
594
|
-
data:
|
|
621
|
+
loading: c,
|
|
622
|
+
data: u
|
|
595
623
|
} = i;
|
|
596
|
-
return !
|
|
624
|
+
return !c && u ? /* @__PURE__ */ h(Ti, {
|
|
597
625
|
vote: n,
|
|
598
|
-
|
|
626
|
+
close: a,
|
|
627
|
+
openedQuestion: u
|
|
599
628
|
}) : null;
|
|
600
|
-
},
|
|
629
|
+
}, Ci = ({
|
|
601
630
|
gamification: i
|
|
602
631
|
}) => {
|
|
603
632
|
var n;
|
|
@@ -605,42 +634,43 @@ const zi = /* @__PURE__ */ g("div")({
|
|
|
605
634
|
if (!a)
|
|
606
635
|
return null;
|
|
607
636
|
const u = a.type;
|
|
608
|
-
return /* @__PURE__ */ v(
|
|
609
|
-
children: [/* @__PURE__ */
|
|
637
|
+
return /* @__PURE__ */ v(Li, {
|
|
638
|
+
children: [/* @__PURE__ */ h(St, {
|
|
610
639
|
close: i.closeQuestion,
|
|
611
640
|
type: ((n = a.attributes) == null ? void 0 : n.type) || q.UNSET
|
|
612
|
-
}), u === "question" && /* @__PURE__ */
|
|
641
|
+
}), u === "question" && /* @__PURE__ */ h(Bi, {
|
|
613
642
|
vote: i.submitAnswer,
|
|
643
|
+
close: i.closeQuestion,
|
|
614
644
|
extendedQuestion: c
|
|
615
|
-
}), u !== "question" && /* @__PURE__ */
|
|
645
|
+
}), u !== "question" && /* @__PURE__ */ h(ki, {
|
|
616
646
|
openedQuestion: a
|
|
617
647
|
})]
|
|
618
648
|
});
|
|
619
649
|
};
|
|
620
|
-
const
|
|
650
|
+
const Ri = /* @__PURE__ */ g("div")({
|
|
621
651
|
name: "t",
|
|
622
652
|
class: "tcim9sm",
|
|
623
653
|
propsAsIs: !1
|
|
624
|
-
}),
|
|
654
|
+
}), Ui = /* @__PURE__ */ g("div")({
|
|
625
655
|
name: "e",
|
|
626
656
|
class: "e8wco6o",
|
|
627
657
|
propsAsIs: !1
|
|
628
|
-
}),
|
|
658
|
+
}), ji = /* @__PURE__ */ g("button")({
|
|
629
659
|
name: "n",
|
|
630
660
|
class: "n1ardwzl",
|
|
631
661
|
propsAsIs: !1
|
|
632
|
-
}),
|
|
662
|
+
}), Fi = /* @__PURE__ */ g("span")({
|
|
633
663
|
name: "i",
|
|
634
664
|
class: "i1vk8ojx",
|
|
635
665
|
propsAsIs: !1
|
|
636
666
|
});
|
|
637
|
-
var
|
|
638
|
-
const dt = ({ title: i, active: n, onClick: a }) => /* @__PURE__ */
|
|
639
|
-
/* @__PURE__ */
|
|
667
|
+
var ye = /* @__PURE__ */ ((i) => (i.HOME = "home", i.LEADERBOARD = "leaderboard", i))(ye || {});
|
|
668
|
+
const dt = ({ title: i, active: n, onClick: a }) => /* @__PURE__ */ h(ji, { onClick: a, "data-selected": n, children: /* @__PURE__ */ h(Fi, { children: i }) }), $i = ({ activePage: i = "home", toggleActivePage: n }) => /* @__PURE__ */ h(Ri, { children: /* @__PURE__ */ v(Ui, { "data-position": i === "home" ? "left" : "right", children: [
|
|
669
|
+
/* @__PURE__ */ h(dt, { title: "Home", active: i === "home", onClick: () => n(
|
|
640
670
|
"home"
|
|
641
671
|
/* HOME */
|
|
642
672
|
) }),
|
|
643
|
-
/* @__PURE__ */
|
|
673
|
+
/* @__PURE__ */ h(
|
|
644
674
|
dt,
|
|
645
675
|
{
|
|
646
676
|
title: "Leader Board",
|
|
@@ -652,16 +682,16 @@ const dt = ({ title: i, active: n, onClick: a }) => /* @__PURE__ */ p(ki, { onCl
|
|
|
652
682
|
}
|
|
653
683
|
)
|
|
654
684
|
] }) });
|
|
655
|
-
var Ot = {},
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
var J = [], P = [],
|
|
660
|
-
for (var le = 0,
|
|
661
|
-
J[le] =
|
|
685
|
+
var Ot = {}, Lt = {}, Oe = {};
|
|
686
|
+
Oe.byteLength = qi;
|
|
687
|
+
Oe.toByteArray = Wi;
|
|
688
|
+
Oe.fromByteArray = Gi;
|
|
689
|
+
var J = [], P = [], Qi = typeof Uint8Array < "u" ? Uint8Array : Array, $e = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
|
|
690
|
+
for (var le = 0, Pi = $e.length; le < Pi; ++le)
|
|
691
|
+
J[le] = $e[le], P[$e.charCodeAt(le)] = le;
|
|
662
692
|
P["-".charCodeAt(0)] = 62;
|
|
663
693
|
P["_".charCodeAt(0)] = 63;
|
|
664
|
-
function
|
|
694
|
+
function kt(i) {
|
|
665
695
|
var n = i.length;
|
|
666
696
|
if (n % 4 > 0)
|
|
667
697
|
throw new Error("Invalid string. Length must be a multiple of 4");
|
|
@@ -670,30 +700,30 @@ function Lt(i) {
|
|
|
670
700
|
var c = a === n ? 0 : 4 - a % 4;
|
|
671
701
|
return [a, c];
|
|
672
702
|
}
|
|
673
|
-
function
|
|
674
|
-
var n =
|
|
703
|
+
function qi(i) {
|
|
704
|
+
var n = kt(i), a = n[0], c = n[1];
|
|
675
705
|
return (a + c) * 3 / 4 - c;
|
|
676
706
|
}
|
|
677
|
-
function
|
|
707
|
+
function Yi(i, n, a) {
|
|
678
708
|
return (n + a) * 3 / 4 - a;
|
|
679
709
|
}
|
|
680
|
-
function
|
|
681
|
-
var n, a =
|
|
710
|
+
function Wi(i) {
|
|
711
|
+
var n, a = kt(i), c = a[0], u = a[1], I = new Qi(Yi(i, c, u)), m = 0, o = u > 0 ? c - 4 : c, y;
|
|
682
712
|
for (y = 0; y < o; y += 4)
|
|
683
713
|
n = P[i.charCodeAt(y)] << 18 | P[i.charCodeAt(y + 1)] << 12 | P[i.charCodeAt(y + 2)] << 6 | P[i.charCodeAt(y + 3)], I[m++] = n >> 16 & 255, I[m++] = n >> 8 & 255, I[m++] = n & 255;
|
|
684
714
|
return u === 2 && (n = P[i.charCodeAt(y)] << 2 | P[i.charCodeAt(y + 1)] >> 4, I[m++] = n & 255), u === 1 && (n = P[i.charCodeAt(y)] << 10 | P[i.charCodeAt(y + 1)] << 4 | P[i.charCodeAt(y + 2)] >> 2, I[m++] = n >> 8 & 255, I[m++] = n & 255), I;
|
|
685
715
|
}
|
|
686
|
-
function
|
|
716
|
+
function Vi(i) {
|
|
687
717
|
return J[i >> 18 & 63] + J[i >> 12 & 63] + J[i >> 6 & 63] + J[i & 63];
|
|
688
718
|
}
|
|
689
|
-
function
|
|
719
|
+
function Hi(i, n, a) {
|
|
690
720
|
for (var c, u = [], I = n; I < a; I += 3)
|
|
691
|
-
c = (i[I] << 16 & 16711680) + (i[I + 1] << 8 & 65280) + (i[I + 2] & 255), u.push(
|
|
721
|
+
c = (i[I] << 16 & 16711680) + (i[I + 1] << 8 & 65280) + (i[I + 2] & 255), u.push(Vi(c));
|
|
692
722
|
return u.join("");
|
|
693
723
|
}
|
|
694
|
-
function
|
|
724
|
+
function Gi(i) {
|
|
695
725
|
for (var n, a = i.length, c = a % 3, u = [], I = 16383, m = 0, o = a - c; m < o; m += I)
|
|
696
|
-
u.push(
|
|
726
|
+
u.push(Hi(i, m, m + I > o ? o : m + I));
|
|
697
727
|
return c === 1 ? (n = i[a - 1], u.push(
|
|
698
728
|
J[n >> 2] + J[n << 4 & 63] + "=="
|
|
699
729
|
)) : c === 2 && (n = (i[a - 2] << 8) + i[a - 1], u.push(
|
|
@@ -703,27 +733,27 @@ function Yi(i) {
|
|
|
703
733
|
var et = {};
|
|
704
734
|
/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
705
735
|
et.read = function(i, n, a, c, u) {
|
|
706
|
-
var I, m, o = u * 8 - c - 1, y = (1 << o) - 1,
|
|
707
|
-
for (S +=
|
|
736
|
+
var I, m, o = u * 8 - c - 1, y = (1 << o) - 1, E = y >> 1, N = -7, S = a ? u - 1 : 0, w = a ? -1 : 1, T = i[n + S];
|
|
737
|
+
for (S += w, I = T & (1 << -N) - 1, T >>= -N, N += o; N > 0; I = I * 256 + i[n + S], S += w, N -= 8)
|
|
708
738
|
;
|
|
709
|
-
for (m = I & (1 << -
|
|
739
|
+
for (m = I & (1 << -N) - 1, I >>= -N, N += c; N > 0; m = m * 256 + i[n + S], S += w, N -= 8)
|
|
710
740
|
;
|
|
711
741
|
if (I === 0)
|
|
712
|
-
I = 1 -
|
|
742
|
+
I = 1 - E;
|
|
713
743
|
else {
|
|
714
744
|
if (I === y)
|
|
715
|
-
return m ? NaN : (
|
|
716
|
-
m = m + Math.pow(2, c), I = I -
|
|
745
|
+
return m ? NaN : (T ? -1 : 1) * (1 / 0);
|
|
746
|
+
m = m + Math.pow(2, c), I = I - E;
|
|
717
747
|
}
|
|
718
|
-
return (
|
|
748
|
+
return (T ? -1 : 1) * m * Math.pow(2, I - c);
|
|
719
749
|
};
|
|
720
750
|
et.write = function(i, n, a, c, u, I) {
|
|
721
|
-
var m, o, y,
|
|
722
|
-
for (n = Math.abs(n), isNaN(n) || n === 1 / 0 ? (o = isNaN(n) ? 1 : 0, m =
|
|
751
|
+
var m, o, y, E = I * 8 - u - 1, N = (1 << E) - 1, S = N >> 1, w = u === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0, T = c ? 0 : I - 1, _ = c ? 1 : -1, p = n < 0 || n === 0 && 1 / n < 0 ? 1 : 0;
|
|
752
|
+
for (n = Math.abs(n), isNaN(n) || n === 1 / 0 ? (o = isNaN(n) ? 1 : 0, m = N) : (m = Math.floor(Math.log(n) / Math.LN2), n * (y = Math.pow(2, -m)) < 1 && (m--, y *= 2), m + S >= 1 ? n += w / y : n += w * Math.pow(2, 1 - S), n * y >= 2 && (m++, y /= 2), m + S >= N ? (o = 0, m = N) : m + S >= 1 ? (o = (n * y - 1) * Math.pow(2, u), m = m + S) : (o = n * Math.pow(2, S - 1) * Math.pow(2, u), m = 0)); u >= 8; i[a + T] = o & 255, T += _, o /= 256, u -= 8)
|
|
723
753
|
;
|
|
724
|
-
for (m = m << u | o,
|
|
754
|
+
for (m = m << u | o, E += u; E > 0; i[a + T] = m & 255, T += _, m /= 256, E -= 8)
|
|
725
755
|
;
|
|
726
|
-
i[a +
|
|
756
|
+
i[a + T - _] |= p * 128;
|
|
727
757
|
};
|
|
728
758
|
/*!
|
|
729
759
|
* The buffer module from node.js, for the browser.
|
|
@@ -732,7 +762,7 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
732
762
|
* @license MIT
|
|
733
763
|
*/
|
|
734
764
|
(function(i) {
|
|
735
|
-
const n =
|
|
765
|
+
const n = Oe, a = et, c = typeof Symbol == "function" && typeof Symbol.for == "function" ? Symbol.for("nodejs.util.inspect.custom") : null;
|
|
736
766
|
i.Buffer = o, i.SlowBuffer = A, i.INSPECT_MAX_BYTES = 50;
|
|
737
767
|
const u = 2147483647;
|
|
738
768
|
i.kMaxLength = u, o.TYPED_ARRAY_SUPPORT = I(), !o.TYPED_ARRAY_SUPPORT && typeof console < "u" && typeof console.error == "function" && console.error(
|
|
@@ -780,15 +810,15 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
780
810
|
o.poolSize = 8192;
|
|
781
811
|
function y(r, e, t) {
|
|
782
812
|
if (typeof r == "string")
|
|
783
|
-
return
|
|
813
|
+
return w(r, e);
|
|
784
814
|
if (ArrayBuffer.isView(r))
|
|
785
|
-
return
|
|
815
|
+
return _(r);
|
|
786
816
|
if (r == null)
|
|
787
817
|
throw new TypeError(
|
|
788
818
|
"The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof r
|
|
789
819
|
);
|
|
790
820
|
if (H(r, ArrayBuffer) || r && H(r.buffer, ArrayBuffer) || typeof SharedArrayBuffer < "u" && (H(r, SharedArrayBuffer) || r && H(r.buffer, SharedArrayBuffer)))
|
|
791
|
-
return
|
|
821
|
+
return p(r, e, t);
|
|
792
822
|
if (typeof r == "number")
|
|
793
823
|
throw new TypeError(
|
|
794
824
|
'The "value" argument must not be of type number. Received type number'
|
|
@@ -808,27 +838,27 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
808
838
|
o.from = function(r, e, t) {
|
|
809
839
|
return y(r, e, t);
|
|
810
840
|
}, Object.setPrototypeOf(o.prototype, Uint8Array.prototype), Object.setPrototypeOf(o, Uint8Array);
|
|
811
|
-
function
|
|
841
|
+
function E(r) {
|
|
812
842
|
if (typeof r != "number")
|
|
813
843
|
throw new TypeError('"size" argument must be of type number');
|
|
814
844
|
if (r < 0)
|
|
815
845
|
throw new RangeError('The value "' + r + '" is invalid for option "size"');
|
|
816
846
|
}
|
|
817
|
-
function
|
|
818
|
-
return
|
|
847
|
+
function N(r, e, t) {
|
|
848
|
+
return E(r), r <= 0 ? m(r) : e !== void 0 ? typeof t == "string" ? m(r).fill(e, t) : m(r).fill(e) : m(r);
|
|
819
849
|
}
|
|
820
850
|
o.alloc = function(r, e, t) {
|
|
821
|
-
return
|
|
851
|
+
return N(r, e, t);
|
|
822
852
|
};
|
|
823
853
|
function S(r) {
|
|
824
|
-
return
|
|
854
|
+
return E(r), m(r < 0 ? 0 : x(r) | 0);
|
|
825
855
|
}
|
|
826
856
|
o.allocUnsafe = function(r) {
|
|
827
857
|
return S(r);
|
|
828
858
|
}, o.allocUnsafeSlow = function(r) {
|
|
829
859
|
return S(r);
|
|
830
860
|
};
|
|
831
|
-
function
|
|
861
|
+
function w(r, e) {
|
|
832
862
|
if ((typeof e != "string" || e === "") && (e = "utf8"), !o.isEncoding(e))
|
|
833
863
|
throw new TypeError("Unknown encoding: " + e);
|
|
834
864
|
const t = z(r, e) | 0;
|
|
@@ -836,20 +866,20 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
836
866
|
const l = s.write(r, e);
|
|
837
867
|
return l !== t && (s = s.slice(0, l)), s;
|
|
838
868
|
}
|
|
839
|
-
function
|
|
840
|
-
const e = r.length < 0 ? 0 :
|
|
869
|
+
function T(r) {
|
|
870
|
+
const e = r.length < 0 ? 0 : x(r.length) | 0, t = m(e);
|
|
841
871
|
for (let s = 0; s < e; s += 1)
|
|
842
872
|
t[s] = r[s] & 255;
|
|
843
873
|
return t;
|
|
844
874
|
}
|
|
845
|
-
function
|
|
875
|
+
function _(r) {
|
|
846
876
|
if (H(r, Uint8Array)) {
|
|
847
877
|
const e = new Uint8Array(r);
|
|
848
|
-
return
|
|
878
|
+
return p(e.buffer, e.byteOffset, e.byteLength);
|
|
849
879
|
}
|
|
850
|
-
return
|
|
880
|
+
return T(r);
|
|
851
881
|
}
|
|
852
|
-
function
|
|
882
|
+
function p(r, e, t) {
|
|
853
883
|
if (e < 0 || r.byteLength < e)
|
|
854
884
|
throw new RangeError('"offset" is outside of buffer bounds');
|
|
855
885
|
if (r.byteLength < e + (t || 0))
|
|
@@ -859,15 +889,15 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
859
889
|
}
|
|
860
890
|
function M(r) {
|
|
861
891
|
if (o.isBuffer(r)) {
|
|
862
|
-
const e =
|
|
892
|
+
const e = x(r.length) | 0, t = m(e);
|
|
863
893
|
return t.length === 0 || r.copy(t, 0, 0, e), t;
|
|
864
894
|
}
|
|
865
895
|
if (r.length !== void 0)
|
|
866
|
-
return typeof r.length != "number" || je(r.length) ? m(0) :
|
|
896
|
+
return typeof r.length != "number" || je(r.length) ? m(0) : T(r);
|
|
867
897
|
if (r.type === "Buffer" && Array.isArray(r.data))
|
|
868
|
-
return
|
|
898
|
+
return T(r.data);
|
|
869
899
|
}
|
|
870
|
-
function
|
|
900
|
+
function x(r) {
|
|
871
901
|
if (r >= u)
|
|
872
902
|
throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x" + u.toString(16) + " bytes");
|
|
873
903
|
return r | 0;
|
|
@@ -956,7 +986,7 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
956
986
|
return t;
|
|
957
987
|
case "utf8":
|
|
958
988
|
case "utf-8":
|
|
959
|
-
return
|
|
989
|
+
return Ue(r).length;
|
|
960
990
|
case "ucs2":
|
|
961
991
|
case "ucs-2":
|
|
962
992
|
case "utf16le":
|
|
@@ -968,19 +998,19 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
968
998
|
return st(r).length;
|
|
969
999
|
default:
|
|
970
1000
|
if (l)
|
|
971
|
-
return s ? -1 :
|
|
1001
|
+
return s ? -1 : Ue(r).length;
|
|
972
1002
|
e = ("" + e).toLowerCase(), l = !0;
|
|
973
1003
|
}
|
|
974
1004
|
}
|
|
975
1005
|
o.byteLength = z;
|
|
976
|
-
function
|
|
1006
|
+
function b(r, e, t) {
|
|
977
1007
|
let s = !1;
|
|
978
1008
|
if ((e === void 0 || e < 0) && (e = 0), e > this.length || ((t === void 0 || t > this.length) && (t = this.length), t <= 0) || (t >>>= 0, e >>>= 0, t <= e))
|
|
979
1009
|
return "";
|
|
980
1010
|
for (r || (r = "utf8"); ; )
|
|
981
1011
|
switch (r) {
|
|
982
1012
|
case "hex":
|
|
983
|
-
return
|
|
1013
|
+
return Ce(this, e, t);
|
|
984
1014
|
case "utf8":
|
|
985
1015
|
case "utf-8":
|
|
986
1016
|
return Me(this, e, t);
|
|
@@ -988,9 +1018,9 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
988
1018
|
return Ee(this, e, t);
|
|
989
1019
|
case "latin1":
|
|
990
1020
|
case "binary":
|
|
991
|
-
return
|
|
1021
|
+
return fe(this, e, t);
|
|
992
1022
|
case "base64":
|
|
993
|
-
return
|
|
1023
|
+
return ke(this, e, t);
|
|
994
1024
|
case "ucs2":
|
|
995
1025
|
case "ucs-2":
|
|
996
1026
|
case "utf16le":
|
|
@@ -1030,7 +1060,7 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1030
1060
|
return this;
|
|
1031
1061
|
}, o.prototype.toString = function() {
|
|
1032
1062
|
const e = this.length;
|
|
1033
|
-
return e === 0 ? "" : arguments.length === 0 ? Me(this, 0, e) :
|
|
1063
|
+
return e === 0 ? "" : arguments.length === 0 ? Me(this, 0, e) : b.apply(this, arguments);
|
|
1034
1064
|
}, o.prototype.toLocaleString = o.prototype.toString, o.prototype.equals = function(e) {
|
|
1035
1065
|
if (!o.isBuffer(e))
|
|
1036
1066
|
throw new TypeError("Argument must be a Buffer");
|
|
@@ -1054,16 +1084,16 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1054
1084
|
return 1;
|
|
1055
1085
|
if (t >>>= 0, s >>>= 0, l >>>= 0, d >>>= 0, this === e)
|
|
1056
1086
|
return 0;
|
|
1057
|
-
let f = d - l,
|
|
1058
|
-
const
|
|
1059
|
-
for (let
|
|
1060
|
-
if (
|
|
1061
|
-
f =
|
|
1087
|
+
let f = d - l, O = s - t;
|
|
1088
|
+
const C = Math.min(f, O), B = this.slice(l, d), R = e.slice(t, s);
|
|
1089
|
+
for (let L = 0; L < C; ++L)
|
|
1090
|
+
if (B[L] !== R[L]) {
|
|
1091
|
+
f = B[L], O = R[L];
|
|
1062
1092
|
break;
|
|
1063
1093
|
}
|
|
1064
|
-
return f <
|
|
1094
|
+
return f < O ? -1 : O < f ? 1 : 0;
|
|
1065
1095
|
};
|
|
1066
|
-
function
|
|
1096
|
+
function k(r, e, t, s, l) {
|
|
1067
1097
|
if (r.length === 0)
|
|
1068
1098
|
return -1;
|
|
1069
1099
|
if (typeof t == "string" ? (s = t, t = 0) : t > 2147483647 ? t = 2147483647 : t < -2147483648 && (t = -2147483648), t = +t, je(t) && (t = l ? 0 : r.length - 1), t < 0 && (t = r.length + t), t >= r.length) {
|
|
@@ -1076,49 +1106,49 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1076
1106
|
else
|
|
1077
1107
|
return -1;
|
|
1078
1108
|
if (typeof e == "string" && (e = o.from(e, s)), o.isBuffer(e))
|
|
1079
|
-
return e.length === 0 ? -1 :
|
|
1109
|
+
return e.length === 0 ? -1 : j(r, e, t, s, l);
|
|
1080
1110
|
if (typeof e == "number")
|
|
1081
|
-
return e = e & 255, typeof Uint8Array.prototype.indexOf == "function" ? l ? Uint8Array.prototype.indexOf.call(r, e, t) : Uint8Array.prototype.lastIndexOf.call(r, e, t) :
|
|
1111
|
+
return e = e & 255, typeof Uint8Array.prototype.indexOf == "function" ? l ? Uint8Array.prototype.indexOf.call(r, e, t) : Uint8Array.prototype.lastIndexOf.call(r, e, t) : j(r, [e], t, s, l);
|
|
1082
1112
|
throw new TypeError("val must be string, number or Buffer");
|
|
1083
1113
|
}
|
|
1084
|
-
function
|
|
1085
|
-
let d = 1, f = r.length,
|
|
1114
|
+
function j(r, e, t, s, l) {
|
|
1115
|
+
let d = 1, f = r.length, O = e.length;
|
|
1086
1116
|
if (s !== void 0 && (s = String(s).toLowerCase(), s === "ucs2" || s === "ucs-2" || s === "utf16le" || s === "utf-16le")) {
|
|
1087
1117
|
if (r.length < 2 || e.length < 2)
|
|
1088
1118
|
return -1;
|
|
1089
|
-
d = 2, f /= 2,
|
|
1119
|
+
d = 2, f /= 2, O /= 2, t /= 2;
|
|
1090
1120
|
}
|
|
1091
|
-
function
|
|
1092
|
-
return d === 1 ? R[
|
|
1121
|
+
function C(R, L) {
|
|
1122
|
+
return d === 1 ? R[L] : R.readUInt16BE(L * d);
|
|
1093
1123
|
}
|
|
1094
|
-
let
|
|
1124
|
+
let B;
|
|
1095
1125
|
if (l) {
|
|
1096
1126
|
let R = -1;
|
|
1097
|
-
for (
|
|
1098
|
-
if (
|
|
1099
|
-
if (R === -1 && (R =
|
|
1127
|
+
for (B = t; B < f; B++)
|
|
1128
|
+
if (C(r, B) === C(e, R === -1 ? 0 : B - R)) {
|
|
1129
|
+
if (R === -1 && (R = B), B - R + 1 === O)
|
|
1100
1130
|
return R * d;
|
|
1101
1131
|
} else
|
|
1102
|
-
R !== -1 && (
|
|
1132
|
+
R !== -1 && (B -= B - R), R = -1;
|
|
1103
1133
|
} else
|
|
1104
|
-
for (t +
|
|
1134
|
+
for (t + O > f && (t = f - O), B = t; B >= 0; B--) {
|
|
1105
1135
|
let R = !0;
|
|
1106
|
-
for (let
|
|
1107
|
-
if (
|
|
1136
|
+
for (let L = 0; L < O; L++)
|
|
1137
|
+
if (C(r, B + L) !== C(e, L)) {
|
|
1108
1138
|
R = !1;
|
|
1109
1139
|
break;
|
|
1110
1140
|
}
|
|
1111
1141
|
if (R)
|
|
1112
|
-
return
|
|
1142
|
+
return B;
|
|
1113
1143
|
}
|
|
1114
1144
|
return -1;
|
|
1115
1145
|
}
|
|
1116
1146
|
o.prototype.includes = function(e, t, s) {
|
|
1117
1147
|
return this.indexOf(e, t, s) !== -1;
|
|
1118
1148
|
}, o.prototype.indexOf = function(e, t, s) {
|
|
1119
|
-
return
|
|
1149
|
+
return k(this, e, t, s, !0);
|
|
1120
1150
|
}, o.prototype.lastIndexOf = function(e, t, s) {
|
|
1121
|
-
return
|
|
1151
|
+
return k(this, e, t, s, !1);
|
|
1122
1152
|
};
|
|
1123
1153
|
function W(r, e, t, s) {
|
|
1124
1154
|
t = Number(t) || 0;
|
|
@@ -1128,15 +1158,15 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1128
1158
|
s > d / 2 && (s = d / 2);
|
|
1129
1159
|
let f;
|
|
1130
1160
|
for (f = 0; f < s; ++f) {
|
|
1131
|
-
const
|
|
1132
|
-
if (je(
|
|
1161
|
+
const O = parseInt(e.substr(f * 2, 2), 16);
|
|
1162
|
+
if (je(O))
|
|
1133
1163
|
return f;
|
|
1134
|
-
r[t + f] =
|
|
1164
|
+
r[t + f] = O;
|
|
1135
1165
|
}
|
|
1136
1166
|
return f;
|
|
1137
1167
|
}
|
|
1138
1168
|
function V(r, e, t, s) {
|
|
1139
|
-
return ve(
|
|
1169
|
+
return ve(Ue(e, r.length - t), r, t, s);
|
|
1140
1170
|
}
|
|
1141
1171
|
function ne(r, e, t, s) {
|
|
1142
1172
|
return ve(Qt(e), r, t, s);
|
|
@@ -1144,7 +1174,7 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1144
1174
|
function se(r, e, t, s) {
|
|
1145
1175
|
return ve(st(e), r, t, s);
|
|
1146
1176
|
}
|
|
1147
|
-
function
|
|
1177
|
+
function Le(r, e, t, s) {
|
|
1148
1178
|
return ve(Pt(e, r.length - t), r, t, s);
|
|
1149
1179
|
}
|
|
1150
1180
|
o.prototype.write = function(e, t, s, l) {
|
|
@@ -1180,7 +1210,7 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1180
1210
|
case "ucs-2":
|
|
1181
1211
|
case "utf16le":
|
|
1182
1212
|
case "utf-16le":
|
|
1183
|
-
return
|
|
1213
|
+
return Le(this, e, t, s);
|
|
1184
1214
|
default:
|
|
1185
1215
|
if (f)
|
|
1186
1216
|
throw new TypeError("Unknown encoding: " + l);
|
|
@@ -1192,7 +1222,7 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1192
1222
|
data: Array.prototype.slice.call(this._arr || this, 0)
|
|
1193
1223
|
};
|
|
1194
1224
|
};
|
|
1195
|
-
function
|
|
1225
|
+
function ke(r, e, t) {
|
|
1196
1226
|
return e === 0 && t === r.length ? n.fromByteArray(r) : n.fromByteArray(r.slice(e, t));
|
|
1197
1227
|
}
|
|
1198
1228
|
function Me(r, e, t) {
|
|
@@ -1201,29 +1231,29 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1201
1231
|
let l = e;
|
|
1202
1232
|
for (; l < t; ) {
|
|
1203
1233
|
const d = r[l];
|
|
1204
|
-
let f = null,
|
|
1205
|
-
if (l +
|
|
1206
|
-
let
|
|
1207
|
-
switch (
|
|
1234
|
+
let f = null, O = d > 239 ? 4 : d > 223 ? 3 : d > 191 ? 2 : 1;
|
|
1235
|
+
if (l + O <= t) {
|
|
1236
|
+
let C, B, R, L;
|
|
1237
|
+
switch (O) {
|
|
1208
1238
|
case 1:
|
|
1209
1239
|
d < 128 && (f = d);
|
|
1210
1240
|
break;
|
|
1211
1241
|
case 2:
|
|
1212
|
-
|
|
1242
|
+
C = r[l + 1], (C & 192) === 128 && (L = (d & 31) << 6 | C & 63, L > 127 && (f = L));
|
|
1213
1243
|
break;
|
|
1214
1244
|
case 3:
|
|
1215
|
-
|
|
1245
|
+
C = r[l + 1], B = r[l + 2], (C & 192) === 128 && (B & 192) === 128 && (L = (d & 15) << 12 | (C & 63) << 6 | B & 63, L > 2047 && (L < 55296 || L > 57343) && (f = L));
|
|
1216
1246
|
break;
|
|
1217
1247
|
case 4:
|
|
1218
|
-
|
|
1248
|
+
C = r[l + 1], B = r[l + 2], R = r[l + 3], (C & 192) === 128 && (B & 192) === 128 && (R & 192) === 128 && (L = (d & 15) << 18 | (C & 63) << 12 | (B & 63) << 6 | R & 63, L > 65535 && L < 1114112 && (f = L));
|
|
1219
1249
|
}
|
|
1220
1250
|
}
|
|
1221
|
-
f === null ? (f = 65533,
|
|
1251
|
+
f === null ? (f = 65533, O = 1) : f > 65535 && (f -= 65536, s.push(f >>> 10 & 1023 | 55296), f = 56320 | f & 1023), s.push(f), l += O;
|
|
1222
1252
|
}
|
|
1223
|
-
return
|
|
1253
|
+
return Be(s);
|
|
1224
1254
|
}
|
|
1225
1255
|
const Ae = 4096;
|
|
1226
|
-
function
|
|
1256
|
+
function Be(r) {
|
|
1227
1257
|
const e = r.length;
|
|
1228
1258
|
if (e <= Ae)
|
|
1229
1259
|
return String.fromCharCode.apply(String, r);
|
|
@@ -1242,14 +1272,14 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1242
1272
|
s += String.fromCharCode(r[l] & 127);
|
|
1243
1273
|
return s;
|
|
1244
1274
|
}
|
|
1245
|
-
function
|
|
1275
|
+
function fe(r, e, t) {
|
|
1246
1276
|
let s = "";
|
|
1247
1277
|
t = Math.min(r.length, t);
|
|
1248
1278
|
for (let l = e; l < t; ++l)
|
|
1249
1279
|
s += String.fromCharCode(r[l]);
|
|
1250
1280
|
return s;
|
|
1251
1281
|
}
|
|
1252
|
-
function
|
|
1282
|
+
function Ce(r, e, t) {
|
|
1253
1283
|
const s = r.length;
|
|
1254
1284
|
(!e || e < 0) && (e = 0), (!t || t < 0 || t > s) && (t = s);
|
|
1255
1285
|
let l = "";
|
|
@@ -1301,13 +1331,13 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1301
1331
|
}, o.prototype.readBigUInt64LE = te(function(e) {
|
|
1302
1332
|
e = e >>> 0, ae(e, "offset");
|
|
1303
1333
|
const t = this[e], s = this[e + 7];
|
|
1304
|
-
(t === void 0 || s === void 0) &&
|
|
1334
|
+
(t === void 0 || s === void 0) && Ie(e, this.length - 8);
|
|
1305
1335
|
const l = t + this[++e] * 2 ** 8 + this[++e] * 2 ** 16 + this[++e] * 2 ** 24, d = this[++e] + this[++e] * 2 ** 8 + this[++e] * 2 ** 16 + s * 2 ** 24;
|
|
1306
1336
|
return BigInt(l) + (BigInt(d) << BigInt(32));
|
|
1307
1337
|
}), o.prototype.readBigUInt64BE = te(function(e) {
|
|
1308
1338
|
e = e >>> 0, ae(e, "offset");
|
|
1309
1339
|
const t = this[e], s = this[e + 7];
|
|
1310
|
-
(t === void 0 || s === void 0) &&
|
|
1340
|
+
(t === void 0 || s === void 0) && Ie(e, this.length - 8);
|
|
1311
1341
|
const l = t * 2 ** 24 + this[++e] * 2 ** 16 + this[++e] * 2 ** 8 + this[++e], d = this[++e] * 2 ** 24 + this[++e] * 2 ** 16 + this[++e] * 2 ** 8 + s;
|
|
1312
1342
|
return (BigInt(l) << BigInt(32)) + BigInt(d);
|
|
1313
1343
|
}), o.prototype.readIntLE = function(e, t, s) {
|
|
@@ -1339,13 +1369,13 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1339
1369
|
}, o.prototype.readBigInt64LE = te(function(e) {
|
|
1340
1370
|
e = e >>> 0, ae(e, "offset");
|
|
1341
1371
|
const t = this[e], s = this[e + 7];
|
|
1342
|
-
(t === void 0 || s === void 0) &&
|
|
1372
|
+
(t === void 0 || s === void 0) && Ie(e, this.length - 8);
|
|
1343
1373
|
const l = this[e + 4] + this[e + 5] * 2 ** 8 + this[e + 6] * 2 ** 16 + (s << 24);
|
|
1344
1374
|
return (BigInt(l) << BigInt(32)) + BigInt(t + this[++e] * 2 ** 8 + this[++e] * 2 ** 16 + this[++e] * 2 ** 24);
|
|
1345
1375
|
}), o.prototype.readBigInt64BE = te(function(e) {
|
|
1346
1376
|
e = e >>> 0, ae(e, "offset");
|
|
1347
1377
|
const t = this[e], s = this[e + 7];
|
|
1348
|
-
(t === void 0 || s === void 0) &&
|
|
1378
|
+
(t === void 0 || s === void 0) && Ie(e, this.length - 8);
|
|
1349
1379
|
const l = (t << 24) + // Overflow
|
|
1350
1380
|
this[++e] * 2 ** 16 + this[++e] * 2 ** 8 + this[++e];
|
|
1351
1381
|
return (BigInt(l) << BigInt(32)) + BigInt(this[++e] * 2 ** 24 + this[++e] * 2 ** 16 + this[++e] * 2 ** 8 + s);
|
|
@@ -1368,8 +1398,8 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1368
1398
|
}
|
|
1369
1399
|
o.prototype.writeUintLE = o.prototype.writeUIntLE = function(e, t, s, l) {
|
|
1370
1400
|
if (e = +e, t = t >>> 0, s = s >>> 0, !l) {
|
|
1371
|
-
const
|
|
1372
|
-
$(this, e, t, s,
|
|
1401
|
+
const O = Math.pow(2, 8 * s) - 1;
|
|
1402
|
+
$(this, e, t, s, O, 0);
|
|
1373
1403
|
}
|
|
1374
1404
|
let d = 1, f = 0;
|
|
1375
1405
|
for (this[t] = e & 255; ++f < s && (d *= 256); )
|
|
@@ -1377,8 +1407,8 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1377
1407
|
return t + s;
|
|
1378
1408
|
}, o.prototype.writeUintBE = o.prototype.writeUIntBE = function(e, t, s, l) {
|
|
1379
1409
|
if (e = +e, t = t >>> 0, s = s >>> 0, !l) {
|
|
1380
|
-
const
|
|
1381
|
-
$(this, e, t, s,
|
|
1410
|
+
const O = Math.pow(2, 8 * s) - 1;
|
|
1411
|
+
$(this, e, t, s, O, 0);
|
|
1382
1412
|
}
|
|
1383
1413
|
let d = s - 1, f = 1;
|
|
1384
1414
|
for (this[t + d] = e & 255; --d >= 0 && (f *= 256); )
|
|
@@ -1395,7 +1425,7 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1395
1425
|
}, o.prototype.writeUint32BE = o.prototype.writeUInt32BE = function(e, t, s) {
|
|
1396
1426
|
return e = +e, t = t >>> 0, s || $(this, e, t, 4, 4294967295, 0), this[t] = e >>> 24, this[t + 1] = e >>> 16, this[t + 2] = e >>> 8, this[t + 3] = e & 255, t + 4;
|
|
1397
1427
|
};
|
|
1398
|
-
function
|
|
1428
|
+
function me(r, e, t, s, l) {
|
|
1399
1429
|
nt(e, s, l, r, t, 7);
|
|
1400
1430
|
let d = Number(e & BigInt(4294967295));
|
|
1401
1431
|
r[t++] = d, d = d >> 8, r[t++] = d, d = d >> 8, r[t++] = d, d = d >> 8, r[t++] = d;
|
|
@@ -1410,26 +1440,26 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1410
1440
|
return r[t + 3] = f, f = f >> 8, r[t + 2] = f, f = f >> 8, r[t + 1] = f, f = f >> 8, r[t] = f, t + 8;
|
|
1411
1441
|
}
|
|
1412
1442
|
o.prototype.writeBigUInt64LE = te(function(e, t = 0) {
|
|
1413
|
-
return
|
|
1443
|
+
return me(this, e, t, BigInt(0), BigInt("0xffffffffffffffff"));
|
|
1414
1444
|
}), o.prototype.writeBigUInt64BE = te(function(e, t = 0) {
|
|
1415
1445
|
return ee(this, e, t, BigInt(0), BigInt("0xffffffffffffffff"));
|
|
1416
1446
|
}), o.prototype.writeIntLE = function(e, t, s, l) {
|
|
1417
1447
|
if (e = +e, t = t >>> 0, !l) {
|
|
1418
|
-
const
|
|
1419
|
-
$(this, e, t, s,
|
|
1448
|
+
const C = Math.pow(2, 8 * s - 1);
|
|
1449
|
+
$(this, e, t, s, C - 1, -C);
|
|
1420
1450
|
}
|
|
1421
|
-
let d = 0, f = 1,
|
|
1451
|
+
let d = 0, f = 1, O = 0;
|
|
1422
1452
|
for (this[t] = e & 255; ++d < s && (f *= 256); )
|
|
1423
|
-
e < 0 &&
|
|
1453
|
+
e < 0 && O === 0 && this[t + d - 1] !== 0 && (O = 1), this[t + d] = (e / f >> 0) - O & 255;
|
|
1424
1454
|
return t + s;
|
|
1425
1455
|
}, o.prototype.writeIntBE = function(e, t, s, l) {
|
|
1426
1456
|
if (e = +e, t = t >>> 0, !l) {
|
|
1427
|
-
const
|
|
1428
|
-
$(this, e, t, s,
|
|
1457
|
+
const C = Math.pow(2, 8 * s - 1);
|
|
1458
|
+
$(this, e, t, s, C - 1, -C);
|
|
1429
1459
|
}
|
|
1430
|
-
let d = s - 1, f = 1,
|
|
1460
|
+
let d = s - 1, f = 1, O = 0;
|
|
1431
1461
|
for (this[t + d] = e & 255; --d >= 0 && (f *= 256); )
|
|
1432
|
-
e < 0 &&
|
|
1462
|
+
e < 0 && O === 0 && this[t + d + 1] !== 0 && (O = 1), this[t + d] = (e / f >> 0) - O & 255;
|
|
1433
1463
|
return t + s;
|
|
1434
1464
|
}, o.prototype.writeInt8 = function(e, t, s) {
|
|
1435
1465
|
return e = +e, t = t >>> 0, s || $(this, e, t, 1, 127, -128), e < 0 && (e = 255 + e + 1), this[t] = e & 255, t + 1;
|
|
@@ -1442,18 +1472,18 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1442
1472
|
}, o.prototype.writeInt32BE = function(e, t, s) {
|
|
1443
1473
|
return e = +e, t = t >>> 0, s || $(this, e, t, 4, 2147483647, -2147483648), e < 0 && (e = 4294967295 + e + 1), this[t] = e >>> 24, this[t + 1] = e >>> 16, this[t + 2] = e >>> 8, this[t + 3] = e & 255, t + 4;
|
|
1444
1474
|
}, o.prototype.writeBigInt64LE = te(function(e, t = 0) {
|
|
1445
|
-
return
|
|
1475
|
+
return me(this, e, t, -BigInt("0x8000000000000000"), BigInt("0x7fffffffffffffff"));
|
|
1446
1476
|
}), o.prototype.writeBigInt64BE = te(function(e, t = 0) {
|
|
1447
1477
|
return ee(this, e, t, -BigInt("0x8000000000000000"), BigInt("0x7fffffffffffffff"));
|
|
1448
1478
|
});
|
|
1449
|
-
function
|
|
1479
|
+
function ge(r, e, t, s, l, d) {
|
|
1450
1480
|
if (t + s > r.length)
|
|
1451
1481
|
throw new RangeError("Index out of range");
|
|
1452
1482
|
if (t < 0)
|
|
1453
1483
|
throw new RangeError("Index out of range");
|
|
1454
1484
|
}
|
|
1455
1485
|
function tt(r, e, t, s, l) {
|
|
1456
|
-
return e = +e, t = t >>> 0, l ||
|
|
1486
|
+
return e = +e, t = t >>> 0, l || ge(r, e, t, 4), a.write(r, e, t, s, 23, 4), t + 4;
|
|
1457
1487
|
}
|
|
1458
1488
|
o.prototype.writeFloatLE = function(e, t, s) {
|
|
1459
1489
|
return tt(this, e, t, !0, s);
|
|
@@ -1461,7 +1491,7 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1461
1491
|
return tt(this, e, t, !1, s);
|
|
1462
1492
|
};
|
|
1463
1493
|
function rt(r, e, t, s, l) {
|
|
1464
|
-
return e = +e, t = t >>> 0, l ||
|
|
1494
|
+
return e = +e, t = t >>> 0, l || ge(r, e, t, 8), a.write(r, e, t, s, 52, 8), t + 8;
|
|
1465
1495
|
}
|
|
1466
1496
|
o.prototype.writeDoubleLE = function(e, t, s) {
|
|
1467
1497
|
return rt(this, e, t, !0, s);
|
|
@@ -1507,16 +1537,16 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1507
1537
|
for (d = t; d < s; ++d)
|
|
1508
1538
|
this[d] = e;
|
|
1509
1539
|
else {
|
|
1510
|
-
const f = o.isBuffer(e) ? e : o.from(e, l),
|
|
1511
|
-
if (
|
|
1540
|
+
const f = o.isBuffer(e) ? e : o.from(e, l), O = f.length;
|
|
1541
|
+
if (O === 0)
|
|
1512
1542
|
throw new TypeError('The value "' + e + '" is invalid for argument "value"');
|
|
1513
1543
|
for (d = 0; d < s - t; ++d)
|
|
1514
|
-
this[d + t] = f[d %
|
|
1544
|
+
this[d + t] = f[d % O];
|
|
1515
1545
|
}
|
|
1516
1546
|
return this;
|
|
1517
1547
|
};
|
|
1518
1548
|
const oe = {};
|
|
1519
|
-
function
|
|
1549
|
+
function Re(r, e, t) {
|
|
1520
1550
|
oe[r] = class extends t {
|
|
1521
1551
|
constructor() {
|
|
1522
1552
|
super(), Object.defineProperty(this, "message", {
|
|
@@ -1541,19 +1571,19 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1541
1571
|
}
|
|
1542
1572
|
};
|
|
1543
1573
|
}
|
|
1544
|
-
|
|
1574
|
+
Re(
|
|
1545
1575
|
"ERR_BUFFER_OUT_OF_BOUNDS",
|
|
1546
1576
|
function(r) {
|
|
1547
1577
|
return r ? `${r} is outside of buffer bounds` : "Attempt to access memory outside buffer bounds";
|
|
1548
1578
|
},
|
|
1549
1579
|
RangeError
|
|
1550
|
-
),
|
|
1580
|
+
), Re(
|
|
1551
1581
|
"ERR_INVALID_ARG_TYPE",
|
|
1552
1582
|
function(r, e) {
|
|
1553
1583
|
return `The "${r}" argument must be of type number. Received type ${typeof e}`;
|
|
1554
1584
|
},
|
|
1555
1585
|
TypeError
|
|
1556
|
-
),
|
|
1586
|
+
), Re(
|
|
1557
1587
|
"ERR_OUT_OF_RANGE",
|
|
1558
1588
|
function(r, e, t) {
|
|
1559
1589
|
let s = `The value of "${r}" is out of range.`, l = t;
|
|
@@ -1568,22 +1598,22 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1568
1598
|
e = `_${r.slice(t - 3, t)}${e}`;
|
|
1569
1599
|
return `${r.slice(0, t)}${e}`;
|
|
1570
1600
|
}
|
|
1571
|
-
function
|
|
1572
|
-
ae(e, "offset"), (r[e] === void 0 || r[e + t] === void 0) &&
|
|
1601
|
+
function jt(r, e, t) {
|
|
1602
|
+
ae(e, "offset"), (r[e] === void 0 || r[e + t] === void 0) && Ie(e, r.length - (t + 1));
|
|
1573
1603
|
}
|
|
1574
1604
|
function nt(r, e, t, s, l, d) {
|
|
1575
1605
|
if (r > t || r < e) {
|
|
1576
1606
|
const f = typeof e == "bigint" ? "n" : "";
|
|
1577
|
-
let
|
|
1578
|
-
throw d > 3 ? e === 0 || e === BigInt(0) ?
|
|
1607
|
+
let O;
|
|
1608
|
+
throw d > 3 ? e === 0 || e === BigInt(0) ? O = `>= 0${f} and < 2${f} ** ${(d + 1) * 8}${f}` : O = `>= -(2${f} ** ${(d + 1) * 8 - 1}${f}) and < 2 ** ${(d + 1) * 8 - 1}${f}` : O = `>= ${e}${f} and <= ${t}${f}`, new oe.ERR_OUT_OF_RANGE("value", O, r);
|
|
1579
1609
|
}
|
|
1580
|
-
|
|
1610
|
+
jt(s, l, d);
|
|
1581
1611
|
}
|
|
1582
1612
|
function ae(r, e) {
|
|
1583
1613
|
if (typeof r != "number")
|
|
1584
1614
|
throw new oe.ERR_INVALID_ARG_TYPE(e, "number", r);
|
|
1585
1615
|
}
|
|
1586
|
-
function
|
|
1616
|
+
function Ie(r, e, t) {
|
|
1587
1617
|
throw Math.floor(r) !== r ? (ae(r, t), new oe.ERR_OUT_OF_RANGE(t || "offset", "an integer", r)) : e < 0 ? new oe.ERR_BUFFER_OUT_OF_BOUNDS() : new oe.ERR_OUT_OF_RANGE(
|
|
1588
1618
|
t || "offset",
|
|
1589
1619
|
`>= ${t ? 1 : 0} and <= ${e}`,
|
|
@@ -1598,7 +1628,7 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1598
1628
|
r = r + "=";
|
|
1599
1629
|
return r;
|
|
1600
1630
|
}
|
|
1601
|
-
function
|
|
1631
|
+
function Ue(r, e) {
|
|
1602
1632
|
e = e || 1 / 0;
|
|
1603
1633
|
let t;
|
|
1604
1634
|
const s = r.length;
|
|
@@ -1700,8 +1730,8 @@ et.write = function(i, n, a, c, u, I) {
|
|
|
1700
1730
|
function Yt() {
|
|
1701
1731
|
throw new Error("BigInt not supported");
|
|
1702
1732
|
}
|
|
1703
|
-
})(
|
|
1704
|
-
var
|
|
1733
|
+
})(Lt);
|
|
1734
|
+
var Bt = { exports: {} }, U = Bt.exports = {}, G, Z;
|
|
1705
1735
|
function He() {
|
|
1706
1736
|
throw new Error("setTimeout has not been defined");
|
|
1707
1737
|
}
|
|
@@ -1720,7 +1750,7 @@ function Ge() {
|
|
|
1720
1750
|
Z = Ge;
|
|
1721
1751
|
}
|
|
1722
1752
|
})();
|
|
1723
|
-
function
|
|
1753
|
+
function Ct(i) {
|
|
1724
1754
|
if (G === setTimeout)
|
|
1725
1755
|
return setTimeout(i, 0);
|
|
1726
1756
|
if ((G === He || !G) && setTimeout)
|
|
@@ -1735,7 +1765,7 @@ function Bt(i) {
|
|
|
1735
1765
|
}
|
|
1736
1766
|
}
|
|
1737
1767
|
}
|
|
1738
|
-
function
|
|
1768
|
+
function Zi(i) {
|
|
1739
1769
|
if (Z === clearTimeout)
|
|
1740
1770
|
return clearTimeout(i);
|
|
1741
1771
|
if ((Z === Ge || !Z) && clearTimeout)
|
|
@@ -1750,162 +1780,162 @@ function Wi(i) {
|
|
|
1750
1780
|
}
|
|
1751
1781
|
}
|
|
1752
1782
|
}
|
|
1753
|
-
var K = [],
|
|
1754
|
-
function
|
|
1755
|
-
!
|
|
1783
|
+
var K = [], pe = !1, ie, De = -1;
|
|
1784
|
+
function Ji() {
|
|
1785
|
+
!pe || !ie || (pe = !1, ie.length ? K = ie.concat(K) : De = -1, K.length && Rt());
|
|
1756
1786
|
}
|
|
1757
1787
|
function Rt() {
|
|
1758
|
-
if (!
|
|
1759
|
-
var i =
|
|
1760
|
-
|
|
1788
|
+
if (!pe) {
|
|
1789
|
+
var i = Ct(Ji);
|
|
1790
|
+
pe = !0;
|
|
1761
1791
|
for (var n = K.length; n; ) {
|
|
1762
1792
|
for (ie = K, K = []; ++De < n; )
|
|
1763
1793
|
ie && ie[De].run();
|
|
1764
1794
|
De = -1, n = K.length;
|
|
1765
1795
|
}
|
|
1766
|
-
ie = null,
|
|
1796
|
+
ie = null, pe = !1, Zi(i);
|
|
1767
1797
|
}
|
|
1768
1798
|
}
|
|
1769
|
-
|
|
1799
|
+
U.nextTick = function(i) {
|
|
1770
1800
|
var n = new Array(arguments.length - 1);
|
|
1771
1801
|
if (arguments.length > 1)
|
|
1772
1802
|
for (var a = 1; a < arguments.length; a++)
|
|
1773
1803
|
n[a - 1] = arguments[a];
|
|
1774
|
-
K.push(new
|
|
1804
|
+
K.push(new Ut(i, n)), K.length === 1 && !pe && Ct(Rt);
|
|
1775
1805
|
};
|
|
1776
|
-
function
|
|
1806
|
+
function Ut(i, n) {
|
|
1777
1807
|
this.fun = i, this.array = n;
|
|
1778
1808
|
}
|
|
1779
|
-
|
|
1809
|
+
Ut.prototype.run = function() {
|
|
1780
1810
|
this.fun.apply(null, this.array);
|
|
1781
1811
|
};
|
|
1782
|
-
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
1787
|
-
|
|
1812
|
+
U.title = "browser";
|
|
1813
|
+
U.browser = !0;
|
|
1814
|
+
U.env = {};
|
|
1815
|
+
U.argv = [];
|
|
1816
|
+
U.version = "";
|
|
1817
|
+
U.versions = {};
|
|
1788
1818
|
function X() {
|
|
1789
1819
|
}
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1820
|
+
U.on = X;
|
|
1821
|
+
U.addListener = X;
|
|
1822
|
+
U.once = X;
|
|
1823
|
+
U.off = X;
|
|
1824
|
+
U.removeListener = X;
|
|
1825
|
+
U.removeAllListeners = X;
|
|
1826
|
+
U.emit = X;
|
|
1827
|
+
U.prependListener = X;
|
|
1828
|
+
U.prependOnceListener = X;
|
|
1829
|
+
U.listeners = function(i) {
|
|
1800
1830
|
return [];
|
|
1801
1831
|
};
|
|
1802
|
-
|
|
1832
|
+
U.binding = function(i) {
|
|
1803
1833
|
throw new Error("process.binding is not supported");
|
|
1804
1834
|
};
|
|
1805
|
-
|
|
1835
|
+
U.cwd = function() {
|
|
1806
1836
|
return "/";
|
|
1807
1837
|
};
|
|
1808
|
-
|
|
1838
|
+
U.chdir = function(i) {
|
|
1809
1839
|
throw new Error("process.chdir is not supported");
|
|
1810
1840
|
};
|
|
1811
|
-
|
|
1841
|
+
U.umask = function() {
|
|
1812
1842
|
return 0;
|
|
1813
1843
|
};
|
|
1814
|
-
var
|
|
1844
|
+
var Ki = Bt.exports;
|
|
1815
1845
|
(function(i) {
|
|
1816
1846
|
Object.defineProperty(i, Symbol.toStringTag, { value: "Module" });
|
|
1817
|
-
const n =
|
|
1847
|
+
const n = Lt, a = Ki, c = (m) => m && m.__esModule ? m : { default: m }, u = c(a), I = globalThis || void 0 || self;
|
|
1818
1848
|
Object.defineProperty(i, "Buffer", { enumerable: !0, get: () => n.Buffer }), Object.defineProperty(i, "process", { enumerable: !0, get: () => u.default }), i.global = I;
|
|
1819
1849
|
})(Ot);
|
|
1820
1850
|
let Y;
|
|
1821
1851
|
typeof window < "u" ? Y = window : typeof self < "u" ? Y = self : Y = Ot.global;
|
|
1822
1852
|
let Ze = null, Je = null;
|
|
1823
|
-
const ht = 20,
|
|
1824
|
-
|
|
1853
|
+
const ht = 20, Qe = Y.clearTimeout, pt = Y.setTimeout, Pe = Y.cancelAnimationFrame || Y.mozCancelAnimationFrame || Y.webkitCancelAnimationFrame, ft = Y.requestAnimationFrame || Y.mozRequestAnimationFrame || Y.webkitRequestAnimationFrame;
|
|
1854
|
+
Pe == null || ft == null ? (Ze = Qe, Je = function(n) {
|
|
1825
1855
|
return pt(n, ht);
|
|
1826
1856
|
}) : (Ze = function([n, a]) {
|
|
1827
|
-
|
|
1857
|
+
Pe(n), Qe(a);
|
|
1828
1858
|
}, Je = function(n) {
|
|
1829
1859
|
const a = ft(function() {
|
|
1830
|
-
|
|
1860
|
+
Qe(c), n();
|
|
1831
1861
|
}), c = pt(function() {
|
|
1832
|
-
|
|
1862
|
+
Pe(a), n();
|
|
1833
1863
|
}, ht);
|
|
1834
1864
|
return [a, c];
|
|
1835
1865
|
});
|
|
1836
|
-
function
|
|
1866
|
+
function Xi(i) {
|
|
1837
1867
|
let n, a, c, u, I, m, o;
|
|
1838
1868
|
const y = typeof document < "u" && document.attachEvent;
|
|
1839
1869
|
if (!y) {
|
|
1840
|
-
m = function(
|
|
1841
|
-
const A =
|
|
1842
|
-
|
|
1843
|
-
}, I = function(
|
|
1844
|
-
return
|
|
1845
|
-
}, o = function(
|
|
1846
|
-
if (
|
|
1870
|
+
m = function(x) {
|
|
1871
|
+
const A = x.__resizeTriggers__, z = A.firstElementChild, b = A.lastElementChild, D = z.firstElementChild;
|
|
1872
|
+
b.scrollLeft = b.scrollWidth, b.scrollTop = b.scrollHeight, D.style.width = z.offsetWidth + 1 + "px", D.style.height = z.offsetHeight + 1 + "px", z.scrollLeft = z.scrollWidth, z.scrollTop = z.scrollHeight;
|
|
1873
|
+
}, I = function(x) {
|
|
1874
|
+
return x.offsetWidth !== x.__resizeLast__.width || x.offsetHeight !== x.__resizeLast__.height;
|
|
1875
|
+
}, o = function(x) {
|
|
1876
|
+
if (x.target.className && typeof x.target.className.indexOf == "function" && x.target.className.indexOf("contract-trigger") < 0 && x.target.className.indexOf("expand-trigger") < 0)
|
|
1847
1877
|
return;
|
|
1848
1878
|
const A = this;
|
|
1849
1879
|
m(this), this.__resizeRAF__ && Ze(this.__resizeRAF__), this.__resizeRAF__ = Je(function() {
|
|
1850
1880
|
I(A) && (A.__resizeLast__.width = A.offsetWidth, A.__resizeLast__.height = A.offsetHeight, A.__resizeListeners__.forEach(function(D) {
|
|
1851
|
-
D.call(A,
|
|
1881
|
+
D.call(A, x);
|
|
1852
1882
|
}));
|
|
1853
1883
|
});
|
|
1854
1884
|
};
|
|
1855
|
-
let
|
|
1885
|
+
let w = !1, T = "";
|
|
1856
1886
|
c = "animationstart";
|
|
1857
|
-
const
|
|
1858
|
-
let
|
|
1887
|
+
const _ = "Webkit Moz O ms".split(" ");
|
|
1888
|
+
let p = "webkitAnimationStart animationstart oAnimationStart MSAnimationStart".split(" "), M = "";
|
|
1859
1889
|
{
|
|
1860
|
-
const
|
|
1861
|
-
if (
|
|
1862
|
-
for (let A = 0; A <
|
|
1863
|
-
if (
|
|
1864
|
-
M =
|
|
1890
|
+
const x = document.createElement("fakeelement");
|
|
1891
|
+
if (x.style.animationName !== void 0 && (w = !0), w === !1) {
|
|
1892
|
+
for (let A = 0; A < _.length; A++)
|
|
1893
|
+
if (x.style[_[A] + "AnimationName"] !== void 0) {
|
|
1894
|
+
M = _[A], T = "-" + M.toLowerCase() + "-", c = p[A], w = !0;
|
|
1865
1895
|
break;
|
|
1866
1896
|
}
|
|
1867
1897
|
}
|
|
1868
1898
|
}
|
|
1869
|
-
a = "resizeanim", n = "@" +
|
|
1899
|
+
a = "resizeanim", n = "@" + T + "keyframes " + a + " { from { opacity: 0; } to { opacity: 0; } } ", u = T + "animation: 1ms " + a + "; ";
|
|
1870
1900
|
}
|
|
1871
|
-
const
|
|
1872
|
-
if (!
|
|
1873
|
-
const
|
|
1874
|
-
|
|
1901
|
+
const E = function(w) {
|
|
1902
|
+
if (!w.getElementById("detectElementResize")) {
|
|
1903
|
+
const T = (n || "") + ".resize-triggers { " + (u || "") + 'visibility: hidden; opacity: 0; } .resize-triggers, .resize-triggers > div, .contract-trigger:before { content: " "; display: block; position: absolute; top: 0; left: 0; height: 100%; width: 100%; overflow: hidden; z-index: -1; } .resize-triggers > div { background: #eee; overflow: auto; } .contract-trigger:before { width: 200%; height: 200%; }', _ = w.head || w.getElementsByTagName("head")[0], p = w.createElement("style");
|
|
1904
|
+
p.id = "detectElementResize", p.type = "text/css", i != null && p.setAttribute("nonce", i), p.styleSheet ? p.styleSheet.cssText = T : p.appendChild(w.createTextNode(T)), _.appendChild(p);
|
|
1875
1905
|
}
|
|
1876
1906
|
};
|
|
1877
1907
|
return {
|
|
1878
|
-
addResizeListener: function(
|
|
1908
|
+
addResizeListener: function(w, T) {
|
|
1879
1909
|
if (y)
|
|
1880
|
-
|
|
1910
|
+
w.attachEvent("onresize", T);
|
|
1881
1911
|
else {
|
|
1882
|
-
if (!
|
|
1883
|
-
const
|
|
1884
|
-
|
|
1885
|
-
const M =
|
|
1886
|
-
M.className = "expand-trigger", M.appendChild(
|
|
1887
|
-
const
|
|
1888
|
-
|
|
1889
|
-
z.animationName === a && m(
|
|
1890
|
-
},
|
|
1912
|
+
if (!w.__resizeTriggers__) {
|
|
1913
|
+
const _ = w.ownerDocument, p = Y.getComputedStyle(w);
|
|
1914
|
+
p && p.position === "static" && (w.style.position = "relative"), E(_), w.__resizeLast__ = {}, w.__resizeListeners__ = [], (w.__resizeTriggers__ = _.createElement("div")).className = "resize-triggers";
|
|
1915
|
+
const M = _.createElement("div");
|
|
1916
|
+
M.className = "expand-trigger", M.appendChild(_.createElement("div"));
|
|
1917
|
+
const x = _.createElement("div");
|
|
1918
|
+
x.className = "contract-trigger", w.__resizeTriggers__.appendChild(M), w.__resizeTriggers__.appendChild(x), w.appendChild(w.__resizeTriggers__), m(w), w.addEventListener("scroll", o, !0), c && (w.__resizeTriggers__.__animationListener__ = function(z) {
|
|
1919
|
+
z.animationName === a && m(w);
|
|
1920
|
+
}, w.__resizeTriggers__.addEventListener(c, w.__resizeTriggers__.__animationListener__));
|
|
1891
1921
|
}
|
|
1892
|
-
|
|
1922
|
+
w.__resizeListeners__.push(T);
|
|
1893
1923
|
}
|
|
1894
1924
|
},
|
|
1895
|
-
removeResizeListener: function(
|
|
1925
|
+
removeResizeListener: function(w, T) {
|
|
1896
1926
|
if (y)
|
|
1897
|
-
|
|
1898
|
-
else if (
|
|
1899
|
-
|
|
1927
|
+
w.detachEvent("onresize", T);
|
|
1928
|
+
else if (w.__resizeListeners__.splice(w.__resizeListeners__.indexOf(T), 1), !w.__resizeListeners__.length) {
|
|
1929
|
+
w.removeEventListener("scroll", o, !0), w.__resizeTriggers__.__animationListener__ && (w.__resizeTriggers__.removeEventListener(c, w.__resizeTriggers__.__animationListener__), w.__resizeTriggers__.__animationListener__ = null);
|
|
1900
1930
|
try {
|
|
1901
|
-
|
|
1931
|
+
w.__resizeTriggers__ = !w.removeChild(w.__resizeTriggers__);
|
|
1902
1932
|
} catch {
|
|
1903
1933
|
}
|
|
1904
1934
|
}
|
|
1905
1935
|
}
|
|
1906
1936
|
};
|
|
1907
1937
|
}
|
|
1908
|
-
class
|
|
1938
|
+
class en extends Gt {
|
|
1909
1939
|
constructor(...n) {
|
|
1910
1940
|
super(...n), this.state = {
|
|
1911
1941
|
height: this.props.defaultHeight || 0,
|
|
@@ -1921,15 +1951,15 @@ class Zi extends Gt {
|
|
|
1921
1951
|
} = this.props;
|
|
1922
1952
|
if (this._parentNode) {
|
|
1923
1953
|
var I, m, o, y;
|
|
1924
|
-
const
|
|
1925
|
-
(!a && (this.state.height !==
|
|
1926
|
-
height:
|
|
1954
|
+
const E = window.getComputedStyle(this._parentNode) || {}, N = parseFloat((I = E.paddingLeft) !== null && I !== void 0 ? I : "0"), S = parseFloat((m = E.paddingRight) !== null && m !== void 0 ? m : "0"), w = parseFloat((o = E.paddingTop) !== null && o !== void 0 ? o : "0"), T = parseFloat((y = E.paddingBottom) !== null && y !== void 0 ? y : "0"), _ = this._parentNode.getBoundingClientRect(), p = _.height - w - T, M = _.width - N - S, x = this._parentNode.offsetHeight - w - T, A = this._parentNode.offsetWidth - N - S;
|
|
1955
|
+
(!a && (this.state.height !== x || this.state.scaledHeight !== p) || !c && (this.state.width !== A || this.state.scaledWidth !== M)) && (this.setState({
|
|
1956
|
+
height: x,
|
|
1927
1957
|
width: A,
|
|
1928
|
-
scaledHeight:
|
|
1958
|
+
scaledHeight: p,
|
|
1929
1959
|
scaledWidth: M
|
|
1930
1960
|
}), typeof u == "function" && u({
|
|
1931
|
-
height:
|
|
1932
|
-
scaledHeight:
|
|
1961
|
+
height: x,
|
|
1962
|
+
scaledHeight: p,
|
|
1933
1963
|
scaledWidth: M,
|
|
1934
1964
|
width: A
|
|
1935
1965
|
}));
|
|
@@ -1944,7 +1974,7 @@ class Zi extends Gt {
|
|
|
1944
1974
|
} = this.props;
|
|
1945
1975
|
this._autoSizer && this._autoSizer.parentNode && this._autoSizer.parentNode.ownerDocument && this._autoSizer.parentNode.ownerDocument.defaultView && this._autoSizer.parentNode instanceof this._autoSizer.parentNode.ownerDocument.defaultView.HTMLElement && (this._parentNode = this._autoSizer.parentNode, this._parentNode != null && (typeof ResizeObserver < "u" ? (this._resizeObserver = new ResizeObserver(() => {
|
|
1946
1976
|
this._timeoutId = setTimeout(this._onResize, 0);
|
|
1947
|
-
}), this._resizeObserver.observe(this._parentNode)) : (this._detectElementResize =
|
|
1977
|
+
}), this._resizeObserver.observe(this._parentNode)) : (this._detectElementResize = Xi(n), this._detectElementResize.addResizeListener(this._parentNode, this._onResize)), this._onResize()));
|
|
1948
1978
|
}
|
|
1949
1979
|
componentWillUnmount() {
|
|
1950
1980
|
this._parentNode && (this._detectElementResize && this._detectElementResize.removeResizeListener(this._parentNode, this._onResize), this._timeoutId !== null && clearTimeout(this._timeoutId), this._resizeObserver && (this._resizeObserver.observe(this._parentNode), this._resizeObserver.disconnect()));
|
|
@@ -1959,25 +1989,25 @@ class Zi extends Gt {
|
|
|
1959
1989
|
nonce: m,
|
|
1960
1990
|
onResize: o,
|
|
1961
1991
|
style: y = {},
|
|
1962
|
-
tagName:
|
|
1963
|
-
...
|
|
1992
|
+
tagName: E = "div",
|
|
1993
|
+
...N
|
|
1964
1994
|
} = this.props, {
|
|
1965
1995
|
height: S,
|
|
1966
|
-
scaledHeight:
|
|
1967
|
-
scaledWidth:
|
|
1968
|
-
width:
|
|
1969
|
-
} = this.state,
|
|
1996
|
+
scaledHeight: w,
|
|
1997
|
+
scaledWidth: T,
|
|
1998
|
+
width: _
|
|
1999
|
+
} = this.state, p = {
|
|
1970
2000
|
overflow: "visible"
|
|
1971
2001
|
}, M = {};
|
|
1972
|
-
let
|
|
1973
|
-
return u || (S === 0 && (
|
|
2002
|
+
let x = !1;
|
|
2003
|
+
return u || (S === 0 && (x = !0), p.height = 0, M.height = S, M.scaledHeight = w), I || (_ === 0 && (x = !0), p.width = 0, M.width = _, M.scaledWidth = T), ze(E, {
|
|
1974
2004
|
ref: this._setRef,
|
|
1975
2005
|
style: {
|
|
1976
|
-
...
|
|
2006
|
+
...p,
|
|
1977
2007
|
...y
|
|
1978
2008
|
},
|
|
1979
|
-
...
|
|
1980
|
-
}, !
|
|
2009
|
+
...N
|
|
2010
|
+
}, !x && n(M));
|
|
1981
2011
|
}
|
|
1982
2012
|
}
|
|
1983
2013
|
function Ke() {
|
|
@@ -2000,25 +2030,25 @@ function Xe(i, n) {
|
|
|
2000
2030
|
return c.__proto__ = u, c;
|
|
2001
2031
|
}, Xe(i, n);
|
|
2002
2032
|
}
|
|
2003
|
-
function
|
|
2033
|
+
function tn(i, n) {
|
|
2004
2034
|
i.prototype = Object.create(n.prototype), i.prototype.constructor = i, Xe(i, n);
|
|
2005
2035
|
}
|
|
2006
2036
|
var gt = Number.isNaN || function(n) {
|
|
2007
2037
|
return typeof n == "number" && n !== n;
|
|
2008
2038
|
};
|
|
2009
|
-
function
|
|
2039
|
+
function rn(i, n) {
|
|
2010
2040
|
return !!(i === n || gt(i) && gt(n));
|
|
2011
2041
|
}
|
|
2012
|
-
function
|
|
2042
|
+
function nn(i, n) {
|
|
2013
2043
|
if (i.length !== n.length)
|
|
2014
2044
|
return !1;
|
|
2015
2045
|
for (var a = 0; a < i.length; a++)
|
|
2016
|
-
if (!
|
|
2046
|
+
if (!rn(i[a], n[a]))
|
|
2017
2047
|
return !1;
|
|
2018
2048
|
return !0;
|
|
2019
2049
|
}
|
|
2020
|
-
function
|
|
2021
|
-
n === void 0 && (n =
|
|
2050
|
+
function qe(i, n) {
|
|
2051
|
+
n === void 0 && (n = nn);
|
|
2022
2052
|
var a, c = [], u, I = !1;
|
|
2023
2053
|
function m() {
|
|
2024
2054
|
for (var o = [], y = 0; y < arguments.length; y++)
|
|
@@ -2027,7 +2057,7 @@ function Pe(i, n) {
|
|
|
2027
2057
|
}
|
|
2028
2058
|
return m;
|
|
2029
2059
|
}
|
|
2030
|
-
var
|
|
2060
|
+
var sn = typeof performance == "object" && typeof performance.now == "function", It = sn ? function() {
|
|
2031
2061
|
return performance.now();
|
|
2032
2062
|
} : function() {
|
|
2033
2063
|
return Date.now();
|
|
@@ -2035,7 +2065,7 @@ var en = typeof performance == "object" && typeof performance.now == "function",
|
|
|
2035
2065
|
function yt(i) {
|
|
2036
2066
|
cancelAnimationFrame(i.id);
|
|
2037
2067
|
}
|
|
2038
|
-
function
|
|
2068
|
+
function on(i, n) {
|
|
2039
2069
|
var a = It();
|
|
2040
2070
|
function c() {
|
|
2041
2071
|
It() - a >= n ? i.call(null) : u.id = requestAnimationFrame(c);
|
|
@@ -2045,13 +2075,13 @@ function tn(i, n) {
|
|
|
2045
2075
|
};
|
|
2046
2076
|
return u;
|
|
2047
2077
|
}
|
|
2048
|
-
var
|
|
2078
|
+
var Ye = -1;
|
|
2049
2079
|
function xt(i) {
|
|
2050
|
-
if (i === void 0 && (i = !1),
|
|
2080
|
+
if (i === void 0 && (i = !1), Ye === -1 || i) {
|
|
2051
2081
|
var n = document.createElement("div"), a = n.style;
|
|
2052
|
-
a.width = "50px", a.height = "50px", a.overflow = "scroll", document.body.appendChild(n),
|
|
2082
|
+
a.width = "50px", a.height = "50px", a.overflow = "scroll", document.body.appendChild(n), Ye = n.offsetWidth - n.clientWidth, document.body.removeChild(n);
|
|
2053
2083
|
}
|
|
2054
|
-
return
|
|
2084
|
+
return Ye;
|
|
2055
2085
|
}
|
|
2056
2086
|
var ce = null;
|
|
2057
2087
|
function wt(i) {
|
|
@@ -2063,134 +2093,134 @@ function wt(i) {
|
|
|
2063
2093
|
}
|
|
2064
2094
|
return ce;
|
|
2065
2095
|
}
|
|
2066
|
-
var
|
|
2096
|
+
var an = 150, ln = function(n, a) {
|
|
2067
2097
|
return n;
|
|
2068
2098
|
};
|
|
2069
|
-
function
|
|
2070
|
-
var n, a = i.getItemOffset, c = i.getEstimatedTotalSize, u = i.getItemSize, I = i.getOffsetForIndexAndAlignment, m = i.getStartIndexForOffset, o = i.getStopIndexForStartIndex, y = i.initInstanceProps,
|
|
2099
|
+
function cn(i) {
|
|
2100
|
+
var n, a = i.getItemOffset, c = i.getEstimatedTotalSize, u = i.getItemSize, I = i.getOffsetForIndexAndAlignment, m = i.getStartIndexForOffset, o = i.getStopIndexForStartIndex, y = i.initInstanceProps, E = i.shouldResetStyleCacheOnItemSizeChange, N = i.validateProps;
|
|
2071
2101
|
return n = /* @__PURE__ */ function(S) {
|
|
2072
|
-
|
|
2073
|
-
function
|
|
2074
|
-
var
|
|
2075
|
-
return
|
|
2076
|
-
instance: mt(
|
|
2102
|
+
tn(w, S);
|
|
2103
|
+
function w(_) {
|
|
2104
|
+
var p;
|
|
2105
|
+
return p = S.call(this, _) || this, p._instanceProps = y(p.props, mt(p)), p._outerRef = void 0, p._resetIsScrollingTimeoutId = null, p.state = {
|
|
2106
|
+
instance: mt(p),
|
|
2077
2107
|
isScrolling: !1,
|
|
2078
2108
|
scrollDirection: "forward",
|
|
2079
|
-
scrollOffset: typeof
|
|
2109
|
+
scrollOffset: typeof p.props.initialScrollOffset == "number" ? p.props.initialScrollOffset : 0,
|
|
2080
2110
|
scrollUpdateWasRequested: !1
|
|
2081
|
-
},
|
|
2082
|
-
return
|
|
2111
|
+
}, p._callOnItemsRendered = void 0, p._callOnItemsRendered = qe(function(M, x, A, z) {
|
|
2112
|
+
return p.props.onItemsRendered({
|
|
2083
2113
|
overscanStartIndex: M,
|
|
2084
|
-
overscanStopIndex:
|
|
2114
|
+
overscanStopIndex: x,
|
|
2085
2115
|
visibleStartIndex: A,
|
|
2086
2116
|
visibleStopIndex: z
|
|
2087
2117
|
});
|
|
2088
|
-
}),
|
|
2089
|
-
return
|
|
2118
|
+
}), p._callOnScroll = void 0, p._callOnScroll = qe(function(M, x, A) {
|
|
2119
|
+
return p.props.onScroll({
|
|
2090
2120
|
scrollDirection: M,
|
|
2091
|
-
scrollOffset:
|
|
2121
|
+
scrollOffset: x,
|
|
2092
2122
|
scrollUpdateWasRequested: A
|
|
2093
2123
|
});
|
|
2094
|
-
}),
|
|
2095
|
-
var
|
|
2124
|
+
}), p._getItemStyle = void 0, p._getItemStyle = function(M) {
|
|
2125
|
+
var x = p.props, A = x.direction, z = x.itemSize, b = x.layout, D = p._getItemStyleCache(E && z, E && b, E && A), k;
|
|
2096
2126
|
if (D.hasOwnProperty(M))
|
|
2097
|
-
|
|
2127
|
+
k = D[M];
|
|
2098
2128
|
else {
|
|
2099
|
-
var
|
|
2100
|
-
D[M] =
|
|
2129
|
+
var j = a(p.props, M, p._instanceProps), W = u(p.props, M, p._instanceProps), V = A === "horizontal" || b === "horizontal", ne = A === "rtl", se = V ? j : 0;
|
|
2130
|
+
D[M] = k = {
|
|
2101
2131
|
position: "absolute",
|
|
2102
2132
|
left: ne ? void 0 : se,
|
|
2103
2133
|
right: ne ? se : void 0,
|
|
2104
|
-
top: V ? 0 :
|
|
2134
|
+
top: V ? 0 : j,
|
|
2105
2135
|
height: V ? "100%" : W,
|
|
2106
2136
|
width: V ? W : "100%"
|
|
2107
2137
|
};
|
|
2108
2138
|
}
|
|
2109
|
-
return
|
|
2110
|
-
},
|
|
2139
|
+
return k;
|
|
2140
|
+
}, p._getItemStyleCache = void 0, p._getItemStyleCache = qe(function(M, x, A) {
|
|
2111
2141
|
return {};
|
|
2112
|
-
}),
|
|
2113
|
-
var
|
|
2114
|
-
|
|
2142
|
+
}), p._onScrollHorizontal = function(M) {
|
|
2143
|
+
var x = M.currentTarget, A = x.clientWidth, z = x.scrollLeft, b = x.scrollWidth;
|
|
2144
|
+
p.setState(function(D) {
|
|
2115
2145
|
if (D.scrollOffset === z)
|
|
2116
2146
|
return null;
|
|
2117
|
-
var
|
|
2118
|
-
if (
|
|
2147
|
+
var k = p.props.direction, j = z;
|
|
2148
|
+
if (k === "rtl")
|
|
2119
2149
|
switch (wt()) {
|
|
2120
2150
|
case "negative":
|
|
2121
|
-
|
|
2151
|
+
j = -z;
|
|
2122
2152
|
break;
|
|
2123
2153
|
case "positive-descending":
|
|
2124
|
-
|
|
2154
|
+
j = b - A - z;
|
|
2125
2155
|
break;
|
|
2126
2156
|
}
|
|
2127
|
-
return
|
|
2157
|
+
return j = Math.max(0, Math.min(j, b - A)), {
|
|
2128
2158
|
isScrolling: !0,
|
|
2129
2159
|
scrollDirection: D.scrollOffset < z ? "forward" : "backward",
|
|
2130
|
-
scrollOffset:
|
|
2160
|
+
scrollOffset: j,
|
|
2131
2161
|
scrollUpdateWasRequested: !1
|
|
2132
2162
|
};
|
|
2133
|
-
},
|
|
2134
|
-
},
|
|
2135
|
-
var
|
|
2136
|
-
|
|
2137
|
-
if (D.scrollOffset ===
|
|
2163
|
+
}, p._resetIsScrollingDebounced);
|
|
2164
|
+
}, p._onScrollVertical = function(M) {
|
|
2165
|
+
var x = M.currentTarget, A = x.clientHeight, z = x.scrollHeight, b = x.scrollTop;
|
|
2166
|
+
p.setState(function(D) {
|
|
2167
|
+
if (D.scrollOffset === b)
|
|
2138
2168
|
return null;
|
|
2139
|
-
var
|
|
2169
|
+
var k = Math.max(0, Math.min(b, z - A));
|
|
2140
2170
|
return {
|
|
2141
2171
|
isScrolling: !0,
|
|
2142
|
-
scrollDirection: D.scrollOffset <
|
|
2143
|
-
scrollOffset:
|
|
2172
|
+
scrollDirection: D.scrollOffset < k ? "forward" : "backward",
|
|
2173
|
+
scrollOffset: k,
|
|
2144
2174
|
scrollUpdateWasRequested: !1
|
|
2145
2175
|
};
|
|
2146
|
-
},
|
|
2147
|
-
},
|
|
2148
|
-
var
|
|
2149
|
-
|
|
2150
|
-
},
|
|
2151
|
-
|
|
2152
|
-
},
|
|
2153
|
-
|
|
2176
|
+
}, p._resetIsScrollingDebounced);
|
|
2177
|
+
}, p._outerRefSetter = function(M) {
|
|
2178
|
+
var x = p.props.outerRef;
|
|
2179
|
+
p._outerRef = M, typeof x == "function" ? x(M) : x != null && typeof x == "object" && x.hasOwnProperty("current") && (x.current = M);
|
|
2180
|
+
}, p._resetIsScrollingDebounced = function() {
|
|
2181
|
+
p._resetIsScrollingTimeoutId !== null && yt(p._resetIsScrollingTimeoutId), p._resetIsScrollingTimeoutId = on(p._resetIsScrolling, an);
|
|
2182
|
+
}, p._resetIsScrolling = function() {
|
|
2183
|
+
p._resetIsScrollingTimeoutId = null, p.setState({
|
|
2154
2184
|
isScrolling: !1
|
|
2155
2185
|
}, function() {
|
|
2156
|
-
|
|
2186
|
+
p._getItemStyleCache(-1, null);
|
|
2157
2187
|
});
|
|
2158
|
-
},
|
|
2188
|
+
}, p;
|
|
2159
2189
|
}
|
|
2160
|
-
|
|
2161
|
-
return
|
|
2190
|
+
w.getDerivedStateFromProps = function(p, M) {
|
|
2191
|
+
return un(p, M), N(p), null;
|
|
2162
2192
|
};
|
|
2163
|
-
var
|
|
2164
|
-
return
|
|
2165
|
-
|
|
2166
|
-
return M.scrollOffset ===
|
|
2167
|
-
scrollDirection: M.scrollOffset <
|
|
2168
|
-
scrollOffset:
|
|
2193
|
+
var T = w.prototype;
|
|
2194
|
+
return T.scrollTo = function(p) {
|
|
2195
|
+
p = Math.max(0, p), this.setState(function(M) {
|
|
2196
|
+
return M.scrollOffset === p ? null : {
|
|
2197
|
+
scrollDirection: M.scrollOffset < p ? "forward" : "backward",
|
|
2198
|
+
scrollOffset: p,
|
|
2169
2199
|
scrollUpdateWasRequested: !0
|
|
2170
2200
|
};
|
|
2171
2201
|
}, this._resetIsScrollingDebounced);
|
|
2172
|
-
},
|
|
2202
|
+
}, T.scrollToItem = function(p, M) {
|
|
2173
2203
|
M === void 0 && (M = "auto");
|
|
2174
|
-
var
|
|
2175
|
-
|
|
2204
|
+
var x = this.props, A = x.itemCount, z = x.layout, b = this.state.scrollOffset;
|
|
2205
|
+
p = Math.max(0, Math.min(p, A - 1));
|
|
2176
2206
|
var D = 0;
|
|
2177
2207
|
if (this._outerRef) {
|
|
2178
|
-
var
|
|
2179
|
-
z === "vertical" ? D =
|
|
2208
|
+
var k = this._outerRef;
|
|
2209
|
+
z === "vertical" ? D = k.scrollWidth > k.clientWidth ? xt() : 0 : D = k.scrollHeight > k.clientHeight ? xt() : 0;
|
|
2180
2210
|
}
|
|
2181
|
-
this.scrollTo(I(this.props,
|
|
2182
|
-
},
|
|
2183
|
-
var
|
|
2184
|
-
if (typeof
|
|
2211
|
+
this.scrollTo(I(this.props, p, M, b, this._instanceProps, D));
|
|
2212
|
+
}, T.componentDidMount = function() {
|
|
2213
|
+
var p = this.props, M = p.direction, x = p.initialScrollOffset, A = p.layout;
|
|
2214
|
+
if (typeof x == "number" && this._outerRef != null) {
|
|
2185
2215
|
var z = this._outerRef;
|
|
2186
|
-
M === "horizontal" || A === "horizontal" ? z.scrollLeft =
|
|
2216
|
+
M === "horizontal" || A === "horizontal" ? z.scrollLeft = x : z.scrollTop = x;
|
|
2187
2217
|
}
|
|
2188
2218
|
this._callPropsCallbacks();
|
|
2189
|
-
},
|
|
2190
|
-
var
|
|
2191
|
-
if (
|
|
2219
|
+
}, T.componentDidUpdate = function() {
|
|
2220
|
+
var p = this.props, M = p.direction, x = p.layout, A = this.state, z = A.scrollOffset, b = A.scrollUpdateWasRequested;
|
|
2221
|
+
if (b && this._outerRef != null) {
|
|
2192
2222
|
var D = this._outerRef;
|
|
2193
|
-
if (M === "horizontal" ||
|
|
2223
|
+
if (M === "horizontal" || x === "horizontal")
|
|
2194
2224
|
if (M === "rtl")
|
|
2195
2225
|
switch (wt()) {
|
|
2196
2226
|
case "negative":
|
|
@@ -2200,8 +2230,8 @@ function sn(i) {
|
|
|
2200
2230
|
D.scrollLeft = z;
|
|
2201
2231
|
break;
|
|
2202
2232
|
default:
|
|
2203
|
-
var
|
|
2204
|
-
D.scrollLeft =
|
|
2233
|
+
var k = D.clientWidth, j = D.scrollWidth;
|
|
2234
|
+
D.scrollLeft = j - k - z;
|
|
2205
2235
|
break;
|
|
2206
2236
|
}
|
|
2207
2237
|
else
|
|
@@ -2210,61 +2240,61 @@ function sn(i) {
|
|
|
2210
2240
|
D.scrollTop = z;
|
|
2211
2241
|
}
|
|
2212
2242
|
this._callPropsCallbacks();
|
|
2213
|
-
},
|
|
2243
|
+
}, T.componentWillUnmount = function() {
|
|
2214
2244
|
this._resetIsScrollingTimeoutId !== null && yt(this._resetIsScrollingTimeoutId);
|
|
2215
|
-
},
|
|
2216
|
-
var
|
|
2217
|
-
if (
|
|
2245
|
+
}, T.render = function() {
|
|
2246
|
+
var p = this.props, M = p.children, x = p.className, A = p.direction, z = p.height, b = p.innerRef, D = p.innerElementType, k = p.innerTagName, j = p.itemCount, W = p.itemData, V = p.itemKey, ne = V === void 0 ? ln : V, se = p.layout, Le = p.outerElementType, ke = p.outerTagName, Me = p.style, Ae = p.useIsScrolling, Be = p.width, Ee = this.state.isScrolling, fe = A === "horizontal" || se === "horizontal", Ce = fe ? this._onScrollHorizontal : this._onScrollVertical, Te = this._getRangeToRender(), F = Te[0], $ = Te[1], me = [];
|
|
2247
|
+
if (j > 0)
|
|
2218
2248
|
for (var ee = F; ee <= $; ee++)
|
|
2219
|
-
|
|
2249
|
+
me.push(ze(M, {
|
|
2220
2250
|
data: W,
|
|
2221
2251
|
key: ne(ee, W),
|
|
2222
2252
|
index: ee,
|
|
2223
2253
|
isScrolling: Ae ? Ee : void 0,
|
|
2224
2254
|
style: this._getItemStyle(ee)
|
|
2225
2255
|
}));
|
|
2226
|
-
var
|
|
2227
|
-
return ze(
|
|
2228
|
-
className:
|
|
2229
|
-
onScroll:
|
|
2256
|
+
var ge = c(this.props, this._instanceProps);
|
|
2257
|
+
return ze(Le || ke || "div", {
|
|
2258
|
+
className: x,
|
|
2259
|
+
onScroll: Ce,
|
|
2230
2260
|
ref: this._outerRefSetter,
|
|
2231
2261
|
style: Ke({
|
|
2232
2262
|
position: "relative",
|
|
2233
2263
|
height: z,
|
|
2234
|
-
width:
|
|
2264
|
+
width: Be,
|
|
2235
2265
|
overflow: "auto",
|
|
2236
2266
|
WebkitOverflowScrolling: "touch",
|
|
2237
2267
|
willChange: "transform",
|
|
2238
2268
|
direction: A
|
|
2239
2269
|
}, Me)
|
|
2240
|
-
}, ze(D ||
|
|
2241
|
-
children:
|
|
2242
|
-
ref:
|
|
2270
|
+
}, ze(D || k || "div", {
|
|
2271
|
+
children: me,
|
|
2272
|
+
ref: b,
|
|
2243
2273
|
style: {
|
|
2244
|
-
height:
|
|
2274
|
+
height: fe ? "100%" : ge,
|
|
2245
2275
|
pointerEvents: Ee ? "none" : void 0,
|
|
2246
|
-
width:
|
|
2276
|
+
width: fe ? ge : "100%"
|
|
2247
2277
|
}
|
|
2248
2278
|
}));
|
|
2249
|
-
},
|
|
2279
|
+
}, T._callPropsCallbacks = function() {
|
|
2250
2280
|
if (typeof this.props.onItemsRendered == "function") {
|
|
2251
|
-
var
|
|
2252
|
-
if (
|
|
2253
|
-
var M = this._getRangeToRender(),
|
|
2254
|
-
this._callOnItemsRendered(
|
|
2281
|
+
var p = this.props.itemCount;
|
|
2282
|
+
if (p > 0) {
|
|
2283
|
+
var M = this._getRangeToRender(), x = M[0], A = M[1], z = M[2], b = M[3];
|
|
2284
|
+
this._callOnItemsRendered(x, A, z, b);
|
|
2255
2285
|
}
|
|
2256
2286
|
}
|
|
2257
2287
|
if (typeof this.props.onScroll == "function") {
|
|
2258
|
-
var D = this.state,
|
|
2259
|
-
this._callOnScroll(
|
|
2288
|
+
var D = this.state, k = D.scrollDirection, j = D.scrollOffset, W = D.scrollUpdateWasRequested;
|
|
2289
|
+
this._callOnScroll(k, j, W);
|
|
2260
2290
|
}
|
|
2261
|
-
},
|
|
2262
|
-
var
|
|
2291
|
+
}, T._getRangeToRender = function() {
|
|
2292
|
+
var p = this.props, M = p.itemCount, x = p.overscanCount, A = this.state, z = A.isScrolling, b = A.scrollDirection, D = A.scrollOffset;
|
|
2263
2293
|
if (M === 0)
|
|
2264
2294
|
return [0, 0, 0, 0];
|
|
2265
|
-
var
|
|
2266
|
-
return [Math.max(0,
|
|
2267
|
-
},
|
|
2295
|
+
var k = m(this.props, D, this._instanceProps), j = o(this.props, k, D, this._instanceProps), W = !z || b === "backward" ? Math.max(1, x) : 1, V = !z || b === "forward" ? Math.max(1, x) : 1;
|
|
2296
|
+
return [Math.max(0, k - W), Math.max(0, Math.min(M - 1, j + V)), k, j];
|
|
2297
|
+
}, w;
|
|
2268
2298
|
}(vt), n.defaultProps = {
|
|
2269
2299
|
direction: "ltr",
|
|
2270
2300
|
itemData: void 0,
|
|
@@ -2273,9 +2303,9 @@ function sn(i) {
|
|
|
2273
2303
|
useIsScrolling: !1
|
|
2274
2304
|
}, n;
|
|
2275
2305
|
}
|
|
2276
|
-
var
|
|
2306
|
+
var un = function(n, a) {
|
|
2277
2307
|
n.children, n.direction, n.height, n.layout, n.innerTagName, n.outerTagName, n.width, a.instance;
|
|
2278
|
-
},
|
|
2308
|
+
}, dn = /* @__PURE__ */ cn({
|
|
2279
2309
|
getItemOffset: function(n, a) {
|
|
2280
2310
|
var c = n.itemSize;
|
|
2281
2311
|
return a * c;
|
|
@@ -2289,19 +2319,19 @@ var on = function(n, a) {
|
|
|
2289
2319
|
return c * a;
|
|
2290
2320
|
},
|
|
2291
2321
|
getOffsetForIndexAndAlignment: function(n, a, c, u, I, m) {
|
|
2292
|
-
var o = n.direction, y = n.height,
|
|
2293
|
-
switch (c === "smart" && (u >=
|
|
2322
|
+
var o = n.direction, y = n.height, E = n.itemCount, N = n.itemSize, S = n.layout, w = n.width, T = o === "horizontal" || S === "horizontal", _ = T ? w : y, p = Math.max(0, E * N - _), M = Math.min(p, a * N), x = Math.max(0, a * N - _ + N + m);
|
|
2323
|
+
switch (c === "smart" && (u >= x - _ && u <= M + _ ? c = "auto" : c = "center"), c) {
|
|
2294
2324
|
case "start":
|
|
2295
2325
|
return M;
|
|
2296
2326
|
case "end":
|
|
2297
|
-
return
|
|
2327
|
+
return x;
|
|
2298
2328
|
case "center": {
|
|
2299
|
-
var A = Math.round(
|
|
2300
|
-
return A < Math.ceil(
|
|
2329
|
+
var A = Math.round(x + (M - x) / 2);
|
|
2330
|
+
return A < Math.ceil(_ / 2) ? 0 : A > p + Math.floor(_ / 2) ? p : A;
|
|
2301
2331
|
}
|
|
2302
2332
|
case "auto":
|
|
2303
2333
|
default:
|
|
2304
|
-
return u >=
|
|
2334
|
+
return u >= x && u <= M ? u : u < x ? x : M;
|
|
2305
2335
|
}
|
|
2306
2336
|
},
|
|
2307
2337
|
getStartIndexForOffset: function(n, a) {
|
|
@@ -2309,10 +2339,10 @@ var on = function(n, a) {
|
|
|
2309
2339
|
return Math.max(0, Math.min(c - 1, Math.floor(a / u)));
|
|
2310
2340
|
},
|
|
2311
2341
|
getStopIndexForStartIndex: function(n, a, c) {
|
|
2312
|
-
var u = n.direction, I = n.height, m = n.itemCount, o = n.itemSize, y = n.layout,
|
|
2342
|
+
var u = n.direction, I = n.height, m = n.itemCount, o = n.itemSize, y = n.layout, E = n.width, N = u === "horizontal" || y === "horizontal", S = a * o, w = N ? E : I, T = Math.ceil((w + c - S) / o);
|
|
2313
2343
|
return Math.max(0, Math.min(
|
|
2314
2344
|
m - 1,
|
|
2315
|
-
a +
|
|
2345
|
+
a + T - 1
|
|
2316
2346
|
// -1 is because stop index is inclusive
|
|
2317
2347
|
));
|
|
2318
2348
|
},
|
|
@@ -2323,34 +2353,34 @@ var on = function(n, a) {
|
|
|
2323
2353
|
n.itemSize;
|
|
2324
2354
|
}
|
|
2325
2355
|
});
|
|
2326
|
-
function
|
|
2356
|
+
function hn(i) {
|
|
2327
2357
|
var n = i.lastRenderedStartIndex, a = i.lastRenderedStopIndex, c = i.startIndex, u = i.stopIndex;
|
|
2328
2358
|
return !(c > a || u < n);
|
|
2329
2359
|
}
|
|
2330
|
-
function
|
|
2331
|
-
for (var n = i.isItemLoaded, a = i.itemCount, c = i.minimumBatchSize, u = i.startIndex, I = i.stopIndex, m = [], o = null, y = null,
|
|
2332
|
-
var
|
|
2333
|
-
|
|
2360
|
+
function pn(i) {
|
|
2361
|
+
for (var n = i.isItemLoaded, a = i.itemCount, c = i.minimumBatchSize, u = i.startIndex, I = i.stopIndex, m = [], o = null, y = null, E = u; E <= I; E++) {
|
|
2362
|
+
var N = n(E);
|
|
2363
|
+
N ? y !== null && (m.push(o, y), o = y = null) : (y = E, o === null && (o = E));
|
|
2334
2364
|
}
|
|
2335
2365
|
if (y !== null) {
|
|
2336
|
-
for (var S = Math.min(Math.max(y, o + c - 1), a - 1),
|
|
2337
|
-
y =
|
|
2366
|
+
for (var S = Math.min(Math.max(y, o + c - 1), a - 1), w = y + 1; w <= S && !n(w); w++)
|
|
2367
|
+
y = w;
|
|
2338
2368
|
m.push(o, y);
|
|
2339
2369
|
}
|
|
2340
2370
|
if (m.length)
|
|
2341
2371
|
for (; m[1] - m[0] + 1 < c && m[0] > 0; ) {
|
|
2342
|
-
var
|
|
2343
|
-
if (!n(
|
|
2344
|
-
m[0] =
|
|
2372
|
+
var T = m[0] - 1;
|
|
2373
|
+
if (!n(T))
|
|
2374
|
+
m[0] = T;
|
|
2345
2375
|
else
|
|
2346
2376
|
break;
|
|
2347
2377
|
}
|
|
2348
2378
|
return m;
|
|
2349
2379
|
}
|
|
2350
|
-
var
|
|
2380
|
+
var fn = function(i, n) {
|
|
2351
2381
|
if (!(i instanceof n))
|
|
2352
2382
|
throw new TypeError("Cannot call a class as a function");
|
|
2353
|
-
},
|
|
2383
|
+
}, mn = function() {
|
|
2354
2384
|
function i(n, a) {
|
|
2355
2385
|
for (var c = 0; c < a.length; c++) {
|
|
2356
2386
|
var u = a[c];
|
|
@@ -2360,7 +2390,7 @@ var un = function(i, n) {
|
|
|
2360
2390
|
return function(n, a, c) {
|
|
2361
2391
|
return a && i(n.prototype, a), c && i(n, c), n;
|
|
2362
2392
|
};
|
|
2363
|
-
}(),
|
|
2393
|
+
}(), gn = function(i, n) {
|
|
2364
2394
|
if (typeof n != "function" && n !== null)
|
|
2365
2395
|
throw new TypeError("Super expression must either be null or a function, not " + typeof n);
|
|
2366
2396
|
i.prototype = Object.create(n && n.prototype, {
|
|
@@ -2375,21 +2405,21 @@ var un = function(i, n) {
|
|
|
2375
2405
|
if (!i)
|
|
2376
2406
|
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
2377
2407
|
return n && (typeof n == "object" || typeof n == "function") ? n : i;
|
|
2378
|
-
},
|
|
2379
|
-
|
|
2408
|
+
}, In = function(i) {
|
|
2409
|
+
gn(n, i);
|
|
2380
2410
|
function n() {
|
|
2381
2411
|
var a, c, u, I;
|
|
2382
|
-
|
|
2412
|
+
fn(this, n);
|
|
2383
2413
|
for (var m = arguments.length, o = Array(m), y = 0; y < m; y++)
|
|
2384
2414
|
o[y] = arguments[y];
|
|
2385
|
-
return I = (c = (u = Mt(this, (a = n.__proto__ || Object.getPrototypeOf(n)).call.apply(a, [this].concat(o))), u), u._lastRenderedStartIndex = -1, u._lastRenderedStopIndex = -1, u._memoizedUnloadedRanges = [], u._onItemsRendered = function(
|
|
2386
|
-
var
|
|
2387
|
-
u._lastRenderedStartIndex =
|
|
2388
|
-
}, u._setRef = function(
|
|
2389
|
-
u._listRef =
|
|
2415
|
+
return I = (c = (u = Mt(this, (a = n.__proto__ || Object.getPrototypeOf(n)).call.apply(a, [this].concat(o))), u), u._lastRenderedStartIndex = -1, u._lastRenderedStopIndex = -1, u._memoizedUnloadedRanges = [], u._onItemsRendered = function(E) {
|
|
2416
|
+
var N = E.visibleStartIndex, S = E.visibleStopIndex;
|
|
2417
|
+
u._lastRenderedStartIndex = N, u._lastRenderedStopIndex = S, u._ensureRowsLoaded(N, S);
|
|
2418
|
+
}, u._setRef = function(E) {
|
|
2419
|
+
u._listRef = E;
|
|
2390
2420
|
}, c), Mt(u, I);
|
|
2391
2421
|
}
|
|
2392
|
-
return
|
|
2422
|
+
return mn(n, [{
|
|
2393
2423
|
key: "resetloadMoreItemsCache",
|
|
2394
2424
|
value: function() {
|
|
2395
2425
|
var c = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : !1;
|
|
@@ -2411,32 +2441,32 @@ var un = function(i, n) {
|
|
|
2411
2441
|
}, {
|
|
2412
2442
|
key: "_ensureRowsLoaded",
|
|
2413
2443
|
value: function(c, u) {
|
|
2414
|
-
var I = this.props, m = I.isItemLoaded, o = I.itemCount, y = I.minimumBatchSize,
|
|
2444
|
+
var I = this.props, m = I.isItemLoaded, o = I.itemCount, y = I.minimumBatchSize, E = y === void 0 ? 10 : y, N = I.threshold, S = N === void 0 ? 15 : N, w = pn({
|
|
2415
2445
|
isItemLoaded: m,
|
|
2416
2446
|
itemCount: o,
|
|
2417
|
-
minimumBatchSize:
|
|
2447
|
+
minimumBatchSize: E,
|
|
2418
2448
|
startIndex: Math.max(0, c - S),
|
|
2419
2449
|
stopIndex: Math.min(o - 1, u + S)
|
|
2420
2450
|
});
|
|
2421
|
-
(this._memoizedUnloadedRanges.length !==
|
|
2422
|
-
return
|
|
2423
|
-
})) && (this._memoizedUnloadedRanges =
|
|
2451
|
+
(this._memoizedUnloadedRanges.length !== w.length || this._memoizedUnloadedRanges.some(function(T, _) {
|
|
2452
|
+
return w[_] !== T;
|
|
2453
|
+
})) && (this._memoizedUnloadedRanges = w, this._loadUnloadedRanges(w));
|
|
2424
2454
|
}
|
|
2425
2455
|
}, {
|
|
2426
2456
|
key: "_loadUnloadedRanges",
|
|
2427
2457
|
value: function(c) {
|
|
2428
|
-
for (var u = this, I = this.props.loadMoreItems || this.props.loadMoreRows, m = function(
|
|
2429
|
-
var
|
|
2430
|
-
|
|
2431
|
-
if (
|
|
2458
|
+
for (var u = this, I = this.props.loadMoreItems || this.props.loadMoreRows, m = function(E) {
|
|
2459
|
+
var N = c[E], S = c[E + 1], w = I(N, S);
|
|
2460
|
+
w != null && w.then(function() {
|
|
2461
|
+
if (hn({
|
|
2432
2462
|
lastRenderedStartIndex: u._lastRenderedStartIndex,
|
|
2433
2463
|
lastRenderedStopIndex: u._lastRenderedStopIndex,
|
|
2434
|
-
startIndex:
|
|
2464
|
+
startIndex: N,
|
|
2435
2465
|
stopIndex: S
|
|
2436
2466
|
})) {
|
|
2437
2467
|
if (u._listRef == null)
|
|
2438
2468
|
return;
|
|
2439
|
-
typeof u._listRef.resetAfterIndex == "function" ? u._listRef.resetAfterIndex(
|
|
2469
|
+
typeof u._listRef.resetAfterIndex == "function" ? u._listRef.resetAfterIndex(N, !0) : (typeof u._listRef._getItemStyleCache == "function" && u._listRef._getItemStyleCache(-1), u._listRef.forceUpdate());
|
|
2440
2470
|
}
|
|
2441
2471
|
});
|
|
2442
2472
|
}, o = 0; o < c.length; o += 2)
|
|
@@ -2444,39 +2474,39 @@ var un = function(i, n) {
|
|
|
2444
2474
|
}
|
|
2445
2475
|
}]), n;
|
|
2446
2476
|
}(vt);
|
|
2447
|
-
const
|
|
2477
|
+
const yn = () => Q, xn = /* @__PURE__ */ g("div")({
|
|
2448
2478
|
name: "a",
|
|
2449
2479
|
class: "a1w9zony",
|
|
2450
2480
|
propsAsIs: !1
|
|
2451
|
-
}),
|
|
2481
|
+
}), wn = /* @__PURE__ */ g("div")({
|
|
2452
2482
|
name: "l",
|
|
2453
2483
|
class: "l16qcfv8",
|
|
2454
2484
|
propsAsIs: !1
|
|
2455
|
-
}),
|
|
2485
|
+
}), Mn = /* @__PURE__ */ g("img")({
|
|
2456
2486
|
name: "p",
|
|
2457
2487
|
class: "p1gmcc5f",
|
|
2458
2488
|
propsAsIs: !1
|
|
2459
|
-
}),
|
|
2489
|
+
}), An = /* @__PURE__ */ g("div")({
|
|
2460
2490
|
name: "s",
|
|
2461
2491
|
class: "s1doddh0",
|
|
2462
2492
|
propsAsIs: !1
|
|
2463
|
-
}),
|
|
2493
|
+
}), En = /* @__PURE__ */ g("div")({
|
|
2464
2494
|
name: "c",
|
|
2465
2495
|
class: "c1js9xhe",
|
|
2466
2496
|
propsAsIs: !1
|
|
2467
|
-
}),
|
|
2497
|
+
}), Tn = /* @__PURE__ */ g("div")({
|
|
2468
2498
|
name: "d",
|
|
2469
2499
|
class: "d1tmnqsh",
|
|
2470
2500
|
propsAsIs: !1
|
|
2471
|
-
}),
|
|
2501
|
+
}), vn = /* @__PURE__ */ g("span")({
|
|
2472
2502
|
name: "g",
|
|
2473
2503
|
class: "gi9h87j",
|
|
2474
2504
|
propsAsIs: !1
|
|
2475
|
-
}),
|
|
2505
|
+
}), Nn = /* @__PURE__ */ g(yn())({
|
|
2476
2506
|
name: "x",
|
|
2477
2507
|
class: "x13mk3z6",
|
|
2478
2508
|
propsAsIs: !0
|
|
2479
|
-
}),
|
|
2509
|
+
}), _n = ({
|
|
2480
2510
|
rank: i,
|
|
2481
2511
|
avatar: n,
|
|
2482
2512
|
name: a,
|
|
@@ -2484,114 +2514,120 @@ const fn = () => Q, mn = /* @__PURE__ */ g("div")({
|
|
|
2484
2514
|
isCurrentUser: u,
|
|
2485
2515
|
openItemDetail: I,
|
|
2486
2516
|
style: m
|
|
2487
|
-
}) => /* @__PURE__ */ v(
|
|
2488
|
-
/* @__PURE__ */
|
|
2489
|
-
/* @__PURE__ */ v(
|
|
2490
|
-
n ? /* @__PURE__ */
|
|
2491
|
-
/* @__PURE__ */ v(
|
|
2492
|
-
/* @__PURE__ */
|
|
2493
|
-
u && /* @__PURE__ */
|
|
2517
|
+
}) => /* @__PURE__ */ v(xn, { onClick: I, style: m, children: [
|
|
2518
|
+
/* @__PURE__ */ h(wn, { children: i || 0 }),
|
|
2519
|
+
/* @__PURE__ */ v(En, { children: [
|
|
2520
|
+
n ? /* @__PURE__ */ h(Mn, { alt: "leaderboard-item-avatar", src: n }) : /* @__PURE__ */ h(An, { children: Nt(a || "") }),
|
|
2521
|
+
/* @__PURE__ */ v(Tn, { children: [
|
|
2522
|
+
/* @__PURE__ */ h(vn, { children: a || "" }),
|
|
2523
|
+
u && /* @__PURE__ */ h(Nn, { name: "icon-star" })
|
|
2494
2524
|
] })
|
|
2495
2525
|
] }),
|
|
2496
|
-
/* @__PURE__ */
|
|
2497
|
-
] }),
|
|
2498
|
-
|
|
2526
|
+
/* @__PURE__ */ h("div", { children: _t(c) })
|
|
2527
|
+
] }), Sn = ({
|
|
2528
|
+
items: i,
|
|
2529
|
+
currentUserId: n,
|
|
2530
|
+
openItemDetail: a,
|
|
2531
|
+
fetchMore: c
|
|
2532
|
+
}) => /* @__PURE__ */ h(en, { children: ({ width: u, height: I }) => /* @__PURE__ */ h(
|
|
2533
|
+
In,
|
|
2499
2534
|
{
|
|
2500
|
-
isItemLoaded: (
|
|
2535
|
+
isItemLoaded: (m) => m < i.length,
|
|
2501
2536
|
itemCount: i.length + 1,
|
|
2502
|
-
loadMoreItems:
|
|
2503
|
-
children: ({ onItemsRendered:
|
|
2504
|
-
|
|
2537
|
+
loadMoreItems: c,
|
|
2538
|
+
children: ({ onItemsRendered: m, ref: o }) => /* @__PURE__ */ h(
|
|
2539
|
+
dn,
|
|
2505
2540
|
{
|
|
2506
2541
|
itemSize: 56,
|
|
2507
|
-
onItemsRendered:
|
|
2508
|
-
ref:
|
|
2542
|
+
onItemsRendered: m,
|
|
2543
|
+
ref: o,
|
|
2509
2544
|
itemCount: i.length,
|
|
2510
|
-
width:
|
|
2511
|
-
height:
|
|
2512
|
-
children: ({ index:
|
|
2513
|
-
|
|
2545
|
+
width: u,
|
|
2546
|
+
height: I,
|
|
2547
|
+
children: ({ index: y, style: E }) => /* @__PURE__ */ h(
|
|
2548
|
+
_n,
|
|
2514
2549
|
{
|
|
2515
|
-
style: { ...
|
|
2516
|
-
...i[
|
|
2517
|
-
openItemDetail: () =>
|
|
2550
|
+
style: { ...E, maxHeight: 48 },
|
|
2551
|
+
...i[y],
|
|
2552
|
+
openItemDetail: () => a(i[y].userId),
|
|
2553
|
+
isCurrentUser: !!n && n === i[y].userId
|
|
2518
2554
|
},
|
|
2519
|
-
i[
|
|
2555
|
+
i[y].userId
|
|
2520
2556
|
)
|
|
2521
2557
|
}
|
|
2522
2558
|
)
|
|
2523
2559
|
}
|
|
2524
2560
|
) });
|
|
2525
|
-
const
|
|
2561
|
+
const zn = () => Q, Dn = () => Q, bn = /* @__PURE__ */ g("div")({
|
|
2526
2562
|
name: "a",
|
|
2527
2563
|
class: "ay8exst",
|
|
2528
2564
|
propsAsIs: !1
|
|
2529
|
-
}),
|
|
2565
|
+
}), On = /* @__PURE__ */ g("div")({
|
|
2530
2566
|
name: "l",
|
|
2531
2567
|
class: "l31riw0",
|
|
2532
2568
|
propsAsIs: !1
|
|
2533
|
-
}),
|
|
2569
|
+
}), Ln = /* @__PURE__ */ g(zn())({
|
|
2534
2570
|
name: "p",
|
|
2535
2571
|
class: "pcmm4w7",
|
|
2536
2572
|
propsAsIs: !0
|
|
2537
|
-
}),
|
|
2573
|
+
}), kn = /* @__PURE__ */ g("div")({
|
|
2538
2574
|
name: "c",
|
|
2539
2575
|
class: "cct922a",
|
|
2540
2576
|
propsAsIs: !1
|
|
2541
|
-
}),
|
|
2577
|
+
}), Bn = /* @__PURE__ */ g("div")({
|
|
2542
2578
|
name: "s",
|
|
2543
2579
|
class: "s12b7u74",
|
|
2544
2580
|
propsAsIs: !1
|
|
2545
|
-
}),
|
|
2581
|
+
}), Cn = /* @__PURE__ */ g("div")({
|
|
2546
2582
|
name: "x",
|
|
2547
2583
|
class: "x1896nrl",
|
|
2548
2584
|
propsAsIs: !1
|
|
2549
|
-
}),
|
|
2585
|
+
}), Rn = /* @__PURE__ */ g("div")({
|
|
2550
2586
|
name: "d",
|
|
2551
2587
|
class: "d1vnagog",
|
|
2552
2588
|
propsAsIs: !1
|
|
2553
|
-
}),
|
|
2589
|
+
}), Un = /* @__PURE__ */ g("div")({
|
|
2554
2590
|
name: "g",
|
|
2555
2591
|
class: "gznzzc2",
|
|
2556
2592
|
propsAsIs: !1
|
|
2557
|
-
}),
|
|
2593
|
+
}), jn = /* @__PURE__ */ g("span")({
|
|
2558
2594
|
name: "f",
|
|
2559
2595
|
class: "fnmvyxu",
|
|
2560
2596
|
propsAsIs: !1
|
|
2561
|
-
}),
|
|
2597
|
+
}), Fn = /* @__PURE__ */ g("span")({
|
|
2562
2598
|
name: "h",
|
|
2563
2599
|
class: "h1iubd2g",
|
|
2564
2600
|
propsAsIs: !1
|
|
2565
|
-
}),
|
|
2601
|
+
}), $n = /* @__PURE__ */ g(Dn())({
|
|
2566
2602
|
name: "m",
|
|
2567
2603
|
class: "mmvjfuo",
|
|
2568
2604
|
propsAsIs: !0
|
|
2569
|
-
}),
|
|
2605
|
+
}), Qn = /* @__PURE__ */ g("div")({
|
|
2570
2606
|
name: "v",
|
|
2571
2607
|
class: "v1oi1553",
|
|
2572
2608
|
propsAsIs: !1
|
|
2573
|
-
}),
|
|
2609
|
+
}), Pn = /* @__PURE__ */ g("a")({
|
|
2574
2610
|
name: "w",
|
|
2575
2611
|
class: "w1vwcogq",
|
|
2576
2612
|
propsAsIs: !1
|
|
2577
|
-
}),
|
|
2613
|
+
}), qn = /* @__PURE__ */ g("span")({
|
|
2578
2614
|
name: "u",
|
|
2579
2615
|
class: "utbqo0e",
|
|
2580
2616
|
propsAsIs: !1
|
|
2581
|
-
}),
|
|
2617
|
+
}), Yn = ({
|
|
2582
2618
|
inviteLink: i,
|
|
2583
2619
|
socialLinks: n,
|
|
2584
2620
|
inviteCardTitle: a,
|
|
2585
2621
|
inviteCardSubtext: c,
|
|
2586
2622
|
primaryColor: u,
|
|
2587
2623
|
className: I
|
|
2588
|
-
}) => /* @__PURE__ */ v(
|
|
2589
|
-
/* @__PURE__ */
|
|
2590
|
-
/* @__PURE__ */ v(
|
|
2591
|
-
/* @__PURE__ */
|
|
2592
|
-
/* @__PURE__ */
|
|
2624
|
+
}) => /* @__PURE__ */ v(bn, { className: I, children: [
|
|
2625
|
+
/* @__PURE__ */ h(On, { style: { backgroundColor: u }, children: /* @__PURE__ */ h(Ln, { name: "invite-game-icon" }) }),
|
|
2626
|
+
/* @__PURE__ */ v(kn, { children: [
|
|
2627
|
+
/* @__PURE__ */ h(Bn, { children: a || "" }),
|
|
2628
|
+
/* @__PURE__ */ h(Cn, { children: c || "" })
|
|
2593
2629
|
] }),
|
|
2594
|
-
i && /* @__PURE__ */ v(
|
|
2630
|
+
i && /* @__PURE__ */ v(Rn, { onClick: async () => {
|
|
2595
2631
|
if (i)
|
|
2596
2632
|
try {
|
|
2597
2633
|
await navigator.clipboard.writeText(i);
|
|
@@ -2599,20 +2635,20 @@ const vn = () => Q, Nn = () => Q, _n = /* @__PURE__ */ g("div")({
|
|
|
2599
2635
|
console.error("Unable to copy to clipboard", m);
|
|
2600
2636
|
}
|
|
2601
2637
|
}, children: [
|
|
2602
|
-
/* @__PURE__ */ v(
|
|
2603
|
-
/* @__PURE__ */
|
|
2604
|
-
/* @__PURE__ */
|
|
2638
|
+
/* @__PURE__ */ v(Un, { children: [
|
|
2639
|
+
/* @__PURE__ */ h(jn, { children: "Invite link" }),
|
|
2640
|
+
/* @__PURE__ */ h(Fn, { children: i })
|
|
2605
2641
|
] }),
|
|
2606
|
-
/* @__PURE__ */
|
|
2642
|
+
/* @__PURE__ */ h($n, { name: "icon-copy" })
|
|
2607
2643
|
] }),
|
|
2608
|
-
n && n.length > 0 && /* @__PURE__ */
|
|
2609
|
-
/* @__PURE__ */
|
|
2610
|
-
/* @__PURE__ */
|
|
2644
|
+
n && n.length > 0 && /* @__PURE__ */ h(Qn, { children: n.map(({ icon: m, link: o, label: y }) => /* @__PURE__ */ v(Pn, { href: o, target: "_blank", children: [
|
|
2645
|
+
/* @__PURE__ */ h(Q, { name: m }),
|
|
2646
|
+
/* @__PURE__ */ h(qn, { children: y })
|
|
2611
2647
|
] }, o)) })
|
|
2612
|
-
] }),
|
|
2648
|
+
] }), Wn = ({ deepLink: i }) => {
|
|
2613
2649
|
const { data: n } = re(i.$store);
|
|
2614
|
-
return /* @__PURE__ */
|
|
2615
|
-
|
|
2650
|
+
return /* @__PURE__ */ h(
|
|
2651
|
+
Yn,
|
|
2616
2652
|
{
|
|
2617
2653
|
inviteLink: n == null ? void 0 : n.url,
|
|
2618
2654
|
socialLinks: [
|
|
@@ -2631,64 +2667,65 @@ const vn = () => Q, Nn = () => Q, _n = /* @__PURE__ */ g("div")({
|
|
|
2631
2667
|
inviteCardSubtext: "Invite and compete against your friends for the top spot on the leaderboard."
|
|
2632
2668
|
}
|
|
2633
2669
|
);
|
|
2634
|
-
},
|
|
2670
|
+
}, Vn = ({ gamification: i }) => {
|
|
2635
2671
|
const { data: n } = re(i.leaderboardList.$store);
|
|
2636
|
-
return n != null && n.length ? /* @__PURE__ */
|
|
2637
|
-
|
|
2672
|
+
return n != null && n.length ? /* @__PURE__ */ h(
|
|
2673
|
+
Sn,
|
|
2638
2674
|
{
|
|
2639
2675
|
fetchMore: i.leaderboardList.fetchMore,
|
|
2640
2676
|
items: n,
|
|
2641
|
-
openItemDetail: i.openUser
|
|
2677
|
+
openItemDetail: i.openUser,
|
|
2678
|
+
currentUserId: i.currentUserId.get()
|
|
2642
2679
|
}
|
|
2643
|
-
) : /* @__PURE__ */
|
|
2680
|
+
) : /* @__PURE__ */ h(Wn, { deepLink: i.deepLink });
|
|
2644
2681
|
};
|
|
2645
|
-
const
|
|
2682
|
+
const Hn = /* @__PURE__ */ g("button")({
|
|
2646
2683
|
name: "a",
|
|
2647
2684
|
class: "akly9h2",
|
|
2648
2685
|
propsAsIs: !1
|
|
2649
|
-
}),
|
|
2686
|
+
}), Gn = /* @__PURE__ */ g("span")({
|
|
2650
2687
|
name: "e",
|
|
2651
2688
|
class: "eptoiz9",
|
|
2652
2689
|
propsAsIs: !1
|
|
2653
|
-
}),
|
|
2654
|
-
const
|
|
2690
|
+
}), Zn = ({ disabled: i, variant: n = "primary", onClick: a, children: c, ...u }) => /* @__PURE__ */ h(Hn, { onClick: a, disabled: i, "data-variant": n, ...u, children: /* @__PURE__ */ h(Gn, { children: c }) });
|
|
2691
|
+
const Jn = () => Q, Kn = () => Q, Xn = /* @__PURE__ */ g("div")({
|
|
2655
2692
|
name: "s",
|
|
2656
2693
|
class: "s1lblda3",
|
|
2657
2694
|
propsAsIs: !1
|
|
2658
|
-
}),
|
|
2695
|
+
}), es = /* @__PURE__ */ g("div")({
|
|
2659
2696
|
name: "a",
|
|
2660
2697
|
class: "ascvb2g",
|
|
2661
2698
|
propsAsIs: !1
|
|
2662
|
-
}),
|
|
2699
|
+
}), ts = /* @__PURE__ */ g("div")({
|
|
2663
2700
|
name: "p",
|
|
2664
2701
|
class: "p17rl8zy",
|
|
2665
2702
|
propsAsIs: !1
|
|
2666
|
-
}),
|
|
2703
|
+
}), rs = /* @__PURE__ */ g("div")({
|
|
2667
2704
|
name: "l",
|
|
2668
2705
|
class: "l1vvttbn",
|
|
2669
2706
|
propsAsIs: !1
|
|
2670
|
-
}),
|
|
2707
|
+
}), We = /* @__PURE__ */ g(Jn())({
|
|
2671
2708
|
name: "c",
|
|
2672
2709
|
class: "c6fk2ph",
|
|
2673
2710
|
propsAsIs: !0
|
|
2674
|
-
}),
|
|
2711
|
+
}), is = /* @__PURE__ */ g(Kn())({
|
|
2675
2712
|
name: "d",
|
|
2676
2713
|
class: "d1rdm136",
|
|
2677
2714
|
propsAsIs: !0
|
|
2678
|
-
}),
|
|
2715
|
+
}), ns = /* @__PURE__ */ g("div")({
|
|
2679
2716
|
name: "f",
|
|
2680
2717
|
class: "fwqnnel",
|
|
2681
2718
|
propsAsIs: !1
|
|
2682
|
-
}),
|
|
2719
|
+
}), ss = /* @__PURE__ */ g("div")({
|
|
2683
2720
|
name: "u",
|
|
2684
2721
|
class: "ucyxnlg",
|
|
2685
2722
|
propsAsIs: !1
|
|
2686
|
-
}),
|
|
2687
|
-
[Ne.LOST]: /* @__PURE__ */
|
|
2688
|
-
[Ne.WON]: /* @__PURE__ */
|
|
2723
|
+
}), os = {
|
|
2724
|
+
[Ne.LOST]: /* @__PURE__ */ h(We, { name: "icon-cross" }),
|
|
2725
|
+
[Ne.WON]: /* @__PURE__ */ h(We, { name: "icon-check" }),
|
|
2689
2726
|
[Ne.UNSET]: void 0,
|
|
2690
|
-
[Ne.DNP]: /* @__PURE__ */
|
|
2691
|
-
},
|
|
2727
|
+
[Ne.DNP]: /* @__PURE__ */ h(We, { name: "icon-arrow" })
|
|
2728
|
+
}, as = ({
|
|
2692
2729
|
questionId: i,
|
|
2693
2730
|
questionType: n,
|
|
2694
2731
|
questionStatus: a,
|
|
@@ -2697,118 +2734,118 @@ const Vn = () => Q, Hn = () => Q, Gn = /* @__PURE__ */ g("div")({
|
|
|
2697
2734
|
openQuestion: I,
|
|
2698
2735
|
status: m
|
|
2699
2736
|
}) => {
|
|
2700
|
-
const o = Et[n], y =
|
|
2701
|
-
return o ? /* @__PURE__ */ v(
|
|
2702
|
-
/* @__PURE__ */ v(
|
|
2703
|
-
/* @__PURE__ */ v(
|
|
2704
|
-
/* @__PURE__ */
|
|
2705
|
-
/* @__PURE__ */ v(
|
|
2737
|
+
const o = Et[n], y = os[m];
|
|
2738
|
+
return o ? /* @__PURE__ */ v(Xn, { onClick: () => I == null ? void 0 : I(i), children: [
|
|
2739
|
+
/* @__PURE__ */ v(ss, { children: [
|
|
2740
|
+
/* @__PURE__ */ v(es, { children: [
|
|
2741
|
+
/* @__PURE__ */ h(is, { name: o.iconName }),
|
|
2742
|
+
/* @__PURE__ */ v(ns, { children: [
|
|
2706
2743
|
o.label,
|
|
2707
2744
|
n === q.TRIVIA && a === we.RESOLVED && " • Expired"
|
|
2708
2745
|
] })
|
|
2709
2746
|
] }),
|
|
2710
|
-
/* @__PURE__ */
|
|
2747
|
+
/* @__PURE__ */ h(ts, { children: c || "" })
|
|
2711
2748
|
] }),
|
|
2712
|
-
/* @__PURE__ */
|
|
2749
|
+
/* @__PURE__ */ h(rs, { children: y || (u ? /* @__PURE__ */ h(Zn, { children: "Play" }) : null) })
|
|
2713
2750
|
] }) : null;
|
|
2714
2751
|
};
|
|
2715
|
-
const
|
|
2752
|
+
const ls = /* @__PURE__ */ g("div")({
|
|
2716
2753
|
name: "n",
|
|
2717
2754
|
class: "n1jcgove",
|
|
2718
2755
|
propsAsIs: !1
|
|
2719
|
-
}),
|
|
2756
|
+
}), cs = /* @__PURE__ */ g("button")({
|
|
2720
2757
|
name: "l",
|
|
2721
2758
|
class: "l1bwp7hh",
|
|
2722
2759
|
propsAsIs: !1
|
|
2723
|
-
}),
|
|
2760
|
+
}), us = ({
|
|
2724
2761
|
openInsight: i,
|
|
2725
2762
|
questionId: n,
|
|
2726
2763
|
...a
|
|
2727
|
-
}) => /* @__PURE__ */ v(
|
|
2728
|
-
/* @__PURE__ */
|
|
2729
|
-
i && /* @__PURE__ */
|
|
2764
|
+
}) => /* @__PURE__ */ v(ls, { children: [
|
|
2765
|
+
/* @__PURE__ */ h(bt, { questionId: n, ...a }),
|
|
2766
|
+
i && /* @__PURE__ */ h(cs, { onClick: () => i(n), children: "View Insight" })
|
|
2730
2767
|
] });
|
|
2731
|
-
const
|
|
2768
|
+
const ds = /* @__PURE__ */ g("div")({
|
|
2732
2769
|
name: "t",
|
|
2733
2770
|
class: "t19vr3p1",
|
|
2734
2771
|
propsAsIs: !1
|
|
2735
|
-
}),
|
|
2772
|
+
}), hs = ({ questions: i, openQuestion: n }) => /* @__PURE__ */ h(ds, { children: i == null ? void 0 : i.map((a) => {
|
|
2736
2773
|
var c, u;
|
|
2737
2774
|
if (a.type === "question" && ((c = a.attributes) == null ? void 0 : c.attributes.case) === "question") {
|
|
2738
2775
|
const I = a.attributes.attributes.value;
|
|
2739
|
-
return /* @__PURE__ */
|
|
2776
|
+
return /* @__PURE__ */ h(as, { openQuestion: n, ...I }, I.questionId);
|
|
2740
2777
|
}
|
|
2741
2778
|
if (a.type === "insight" && ((u = a.attributes) == null ? void 0 : u.attributes.case) === "insight") {
|
|
2742
2779
|
const I = a.attributes.attributes.value;
|
|
2743
|
-
return /* @__PURE__ */
|
|
2780
|
+
return /* @__PURE__ */ h(us, { openInsight: n, ...I }, I.questionId);
|
|
2744
2781
|
}
|
|
2745
2782
|
return null;
|
|
2746
|
-
}) }),
|
|
2783
|
+
}) }), ps = ({ store: i, openQuestion: n }) => {
|
|
2747
2784
|
const a = re(i);
|
|
2748
|
-
return a != null && a.data ? /* @__PURE__ */
|
|
2749
|
-
},
|
|
2785
|
+
return a != null && a.data ? /* @__PURE__ */ h(hs, { openQuestion: n, questions: a.data }) : /* @__PURE__ */ h("div", { children: "wait questions..." });
|
|
2786
|
+
}, fs = ({ userSummary: i }) => {
|
|
2750
2787
|
var n, a;
|
|
2751
2788
|
const c = re(i.getStore());
|
|
2752
|
-
return (n = c.data) != null && n.summary ? /* @__PURE__ */
|
|
2753
|
-
},
|
|
2754
|
-
const [n, a] = xe(
|
|
2789
|
+
return (n = c.data) != null && n.summary ? /* @__PURE__ */ h(zt, { ...c.data.summary, successRate: (a = c.data.percentage) == null ? void 0 : a.correct }) : /* @__PURE__ */ h("div", { children: "wait user..." });
|
|
2790
|
+
}, ms = ({ gamification: i }) => {
|
|
2791
|
+
const [n, a] = xe(ye.HOME);
|
|
2755
2792
|
return /* @__PURE__ */ v("div", { style: { height: "100%", display: "flex", flexDirection: "column" }, children: [
|
|
2756
|
-
/* @__PURE__ */ v(
|
|
2757
|
-
/* @__PURE__ */
|
|
2758
|
-
n ===
|
|
2793
|
+
/* @__PURE__ */ v(Ve, { children: [
|
|
2794
|
+
/* @__PURE__ */ h($i, { activePage: n, toggleActivePage: a }),
|
|
2795
|
+
n === ye.HOME && /* @__PURE__ */ h(fs, { userSummary: i.userSummary })
|
|
2759
2796
|
] }),
|
|
2760
|
-
n ===
|
|
2761
|
-
n ===
|
|
2797
|
+
n === ye.HOME && /* @__PURE__ */ h(Vt, { children: /* @__PURE__ */ h(ps, { openQuestion: i.openQuestion, store: i.feedList.getStore() }) }),
|
|
2798
|
+
n === ye.LEADERBOARD && /* @__PURE__ */ h(Ve, { style: { flex: "1 1 auto", paddingTop: 0, paddingBottom: 0 }, children: /* @__PURE__ */ h(Vn, { gamification: i }) })
|
|
2762
2799
|
] });
|
|
2763
2800
|
};
|
|
2764
|
-
const
|
|
2801
|
+
const gs = () => Ht, At = /* @__PURE__ */ g(gs())({
|
|
2765
2802
|
name: "n",
|
|
2766
2803
|
class: "n1ph66cs",
|
|
2767
2804
|
propsAsIs: !0
|
|
2768
|
-
}),
|
|
2805
|
+
}), Is = /* @__PURE__ */ g("div")({
|
|
2769
2806
|
name: "x",
|
|
2770
2807
|
class: "xorme7i",
|
|
2771
2808
|
propsAsIs: !1
|
|
2772
|
-
}),
|
|
2809
|
+
}), ys = ({
|
|
2773
2810
|
correct: i,
|
|
2774
2811
|
incorrect: n
|
|
2775
2812
|
}) => {
|
|
2776
2813
|
const a = i + n;
|
|
2777
2814
|
return a === 0 ? 0 : Math.round(i / a * 100);
|
|
2778
|
-
},
|
|
2815
|
+
}, Ls = ({
|
|
2779
2816
|
gamification: i,
|
|
2780
2817
|
className: n
|
|
2781
2818
|
}) => {
|
|
2782
2819
|
const a = re(i.openedQuestion.$store), c = re(i.openedUser);
|
|
2783
|
-
return /* @__PURE__ */ v(
|
|
2784
|
-
children: [a && /* @__PURE__ */
|
|
2820
|
+
return /* @__PURE__ */ v(de, {
|
|
2821
|
+
children: [a && /* @__PURE__ */ h(At, {
|
|
2785
2822
|
className: n,
|
|
2786
|
-
children: /* @__PURE__ */
|
|
2823
|
+
children: /* @__PURE__ */ h(Ci, {
|
|
2787
2824
|
gamification: i
|
|
2788
2825
|
})
|
|
2789
|
-
}), c && /* @__PURE__ */
|
|
2826
|
+
}), c && /* @__PURE__ */ h(At, {
|
|
2790
2827
|
className: n,
|
|
2791
|
-
children: /* @__PURE__ */ v(
|
|
2792
|
-
children: [/* @__PURE__ */
|
|
2828
|
+
children: /* @__PURE__ */ v(Is, {
|
|
2829
|
+
children: [/* @__PURE__ */ h(St, {
|
|
2793
2830
|
label: "Friend's Rank",
|
|
2794
2831
|
close: i.closeUser
|
|
2795
|
-
}), /* @__PURE__ */
|
|
2796
|
-
children: /* @__PURE__ */
|
|
2832
|
+
}), /* @__PURE__ */ h(Ve, {
|
|
2833
|
+
children: /* @__PURE__ */ h(zt, {
|
|
2797
2834
|
...c,
|
|
2798
|
-
successRate:
|
|
2835
|
+
successRate: ys(c)
|
|
2799
2836
|
})
|
|
2800
2837
|
})]
|
|
2801
2838
|
})
|
|
2802
|
-
}), /* @__PURE__ */
|
|
2839
|
+
}), /* @__PURE__ */ h(Tt, {
|
|
2803
2840
|
className: n,
|
|
2804
2841
|
"data-nav": "true",
|
|
2805
|
-
children: /* @__PURE__ */
|
|
2842
|
+
children: /* @__PURE__ */ h(ms, {
|
|
2806
2843
|
gamification: i
|
|
2807
2844
|
})
|
|
2808
2845
|
})]
|
|
2809
2846
|
});
|
|
2810
2847
|
};
|
|
2811
2848
|
export {
|
|
2812
|
-
|
|
2813
|
-
|
|
2849
|
+
Ls as GamificationOverlay,
|
|
2850
|
+
Ls as default
|
|
2814
2851
|
};
|