@streamlayer/react 0.31.6 → 0.31.7
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/gamification-feature.js +1 -1
- package/lib/dist/cjs/gamification-feature.js +1 -1
- package/lib/dist/cjs/masters.js +14 -14
- package/lib/dist/es/gamification-feature.js +268 -267
- package/lib/dist/es/masters.js +754 -754
- package/lib/dist/style.css +1 -1
- package/lib/es/gamification-feature.js +345 -344
- package/lib/style.css +1 -1
- package/package.json +4 -4
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { s as a, n as j, Q as x, o as Se, a as
|
|
3
|
-
import
|
|
1
|
+
import { jsxs as f, jsx as r, Fragment as $ } from "react/jsx-runtime";
|
|
2
|
+
import { s as a, n as j, Q as x, o as Se, a as U, b as R, d as Ye, E as L, r as ie, w as We, u as w, A as Ve, O as Fe, P as W, c as ee, e as Be, f as He } from "./masters.js";
|
|
3
|
+
import Q, { useRef as C, useState as P, useCallback as _, useEffect as Ge, useLayoutEffect as Ze, useMemo as B, createElement as Z, PureComponent as ze } from "react";
|
|
4
4
|
const Je = /* @__PURE__ */ a("div")({
|
|
5
5
|
name: "Container",
|
|
6
6
|
class: "c1vwopgc",
|
|
@@ -27,8 +27,8 @@ const Je = /* @__PURE__ */ a("div")({
|
|
|
27
27
|
propsAsIs: !0
|
|
28
28
|
}), xe = ({ type: e, close: t, label: n }) => {
|
|
29
29
|
const i = e ? Se[e] : { label: n, iconName: void 0 };
|
|
30
|
-
return /* @__PURE__ */
|
|
31
|
-
/* @__PURE__ */
|
|
30
|
+
return /* @__PURE__ */ f(Je, { children: [
|
|
31
|
+
/* @__PURE__ */ f(Ke, { children: [
|
|
32
32
|
(i == null ? void 0 : i.iconName) && /* @__PURE__ */ r(
|
|
33
33
|
et,
|
|
34
34
|
{
|
|
@@ -60,7 +60,7 @@ const Je = /* @__PURE__ */ a("div")({
|
|
|
60
60
|
name: "Indicator",
|
|
61
61
|
class: "i1fbnvpb",
|
|
62
62
|
propsAsIs: !1
|
|
63
|
-
}), le = ({ indicator: e, title: t }) => /* @__PURE__ */
|
|
63
|
+
}), le = ({ indicator: e, title: t }) => /* @__PURE__ */ f(lt, { children: [
|
|
64
64
|
/* @__PURE__ */ r(ct, { children: t }),
|
|
65
65
|
/* @__PURE__ */ r(dt, { children: e })
|
|
66
66
|
] }), ut = /* @__PURE__ */ a("div")({
|
|
@@ -75,7 +75,7 @@ const Je = /* @__PURE__ */ a("div")({
|
|
|
75
75
|
name: "Title",
|
|
76
76
|
class: "t8s05oq",
|
|
77
77
|
propsAsIs: !1
|
|
78
|
-
}), V = ({ indicator: e, title: t }) => /* @__PURE__ */
|
|
78
|
+
}), V = ({ indicator: e, title: t }) => /* @__PURE__ */ f(ut, { children: [
|
|
79
79
|
/* @__PURE__ */ r(pt, { children: e }),
|
|
80
80
|
/* @__PURE__ */ r(mt, { children: t })
|
|
81
81
|
] }), ht = /* @__PURE__ */ a("div")({
|
|
@@ -94,11 +94,11 @@ const Je = /* @__PURE__ */ a("div")({
|
|
|
94
94
|
name: "User",
|
|
95
95
|
class: "u1g7arbm",
|
|
96
96
|
propsAsIs: !1
|
|
97
|
-
}),
|
|
97
|
+
}), vt = /* @__PURE__ */ a("img")({
|
|
98
98
|
name: "Avatar",
|
|
99
99
|
class: "a1ldeata",
|
|
100
100
|
propsAsIs: !1
|
|
101
|
-
}),
|
|
101
|
+
}), Mt = /* @__PURE__ */ a("div")({
|
|
102
102
|
name: "UserInfo",
|
|
103
103
|
class: "u10d4koz",
|
|
104
104
|
propsAsIs: !1
|
|
@@ -155,43 +155,43 @@ const Je = /* @__PURE__ */ a("div")({
|
|
|
155
155
|
streak: c,
|
|
156
156
|
correct: l,
|
|
157
157
|
incorrect: m,
|
|
158
|
-
inTop:
|
|
159
|
-
successRate:
|
|
160
|
-
}) => /* @__PURE__ */
|
|
161
|
-
/* @__PURE__ */ r(It, { children: /* @__PURE__ */
|
|
162
|
-
/* @__PURE__ */
|
|
163
|
-
e && /* @__PURE__ */ r(
|
|
158
|
+
inTop: d,
|
|
159
|
+
successRate: h
|
|
160
|
+
}) => /* @__PURE__ */ f(ht, { children: [
|
|
161
|
+
/* @__PURE__ */ r(It, { children: /* @__PURE__ */ f(gt, { children: [
|
|
162
|
+
/* @__PURE__ */ f(kt, { children: [
|
|
163
|
+
e && /* @__PURE__ */ r(vt, { alt: "avatar", src: e }),
|
|
164
164
|
!e && /* @__PURE__ */ r(Ot, { children: je(t || "") })
|
|
165
165
|
] }),
|
|
166
|
-
/* @__PURE__ */
|
|
166
|
+
/* @__PURE__ */ f(Mt, { children: [
|
|
167
167
|
/* @__PURE__ */ r(yt, { children: t }),
|
|
168
|
-
/* @__PURE__ */
|
|
169
|
-
/* @__PURE__ */
|
|
168
|
+
/* @__PURE__ */ f(Nt, { children: [
|
|
169
|
+
/* @__PURE__ */ f(At, { children: [
|
|
170
170
|
/* @__PURE__ */ r(Tt, { alt: "rank-icon", src: wt }),
|
|
171
|
-
/* @__PURE__ */
|
|
171
|
+
/* @__PURE__ */ f(Dt, { children: [
|
|
172
172
|
Oe(n),
|
|
173
173
|
/* @__PURE__ */ r(St, { children: "PTS" })
|
|
174
174
|
] })
|
|
175
175
|
] }),
|
|
176
176
|
/* @__PURE__ */ r(zt, {}),
|
|
177
|
-
/* @__PURE__ */
|
|
177
|
+
/* @__PURE__ */ f("div", { children: [
|
|
178
178
|
"TOP ",
|
|
179
|
-
|
|
179
|
+
d || 0,
|
|
180
180
|
"%"
|
|
181
181
|
] })
|
|
182
182
|
] })
|
|
183
183
|
] })
|
|
184
184
|
] }) }),
|
|
185
|
-
/* @__PURE__ */
|
|
186
|
-
/* @__PURE__ */
|
|
185
|
+
/* @__PURE__ */ f(ft, { children: [
|
|
186
|
+
/* @__PURE__ */ f(xt, { children: [
|
|
187
187
|
/* @__PURE__ */ r(le, { indicator: i || 0, title: "Friends rank" }),
|
|
188
188
|
/* @__PURE__ */ r(le, { indicator: s || 0, title: "Global rank" })
|
|
189
189
|
] }),
|
|
190
|
-
/* @__PURE__ */
|
|
190
|
+
/* @__PURE__ */ f(jt, { children: [
|
|
191
191
|
/* @__PURE__ */ r(V, { indicator: c || 0, title: "Win streak" }),
|
|
192
192
|
/* @__PURE__ */ r(V, { indicator: l || 0, title: "Correct" }),
|
|
193
193
|
/* @__PURE__ */ r(V, { indicator: m || 0, title: "Incorrect" }),
|
|
194
|
-
/* @__PURE__ */ r(V, { indicator: `${
|
|
194
|
+
/* @__PURE__ */ r(V, { indicator: `${h || 0}%`, title: "Succ. rate" })
|
|
195
195
|
] })
|
|
196
196
|
] })
|
|
197
197
|
] }), Ct = /* @__PURE__ */ a("div")({
|
|
@@ -206,11 +206,11 @@ const Je = /* @__PURE__ */ a("div")({
|
|
|
206
206
|
name: "Description",
|
|
207
207
|
class: "dlaj9xp",
|
|
208
208
|
propsAsIs: !1
|
|
209
|
-
}),
|
|
209
|
+
}), Lt = ({ title: e, description: t }) => /* @__PURE__ */ f(Ct, { children: [
|
|
210
210
|
/* @__PURE__ */ r(j, { name: "icon-check-circle" }),
|
|
211
211
|
/* @__PURE__ */ r(bt, { children: e }),
|
|
212
212
|
/* @__PURE__ */ r($t, { children: t })
|
|
213
|
-
] }),
|
|
213
|
+
] }), Et = /* @__PURE__ */ a("div")({
|
|
214
214
|
name: "Container",
|
|
215
215
|
class: "c16sbdnm",
|
|
216
216
|
propsAsIs: !1
|
|
@@ -247,26 +247,26 @@ const Je = /* @__PURE__ */ a("div")({
|
|
|
247
247
|
questionStatus: c
|
|
248
248
|
}) => {
|
|
249
249
|
const l = n && (i === x.TRIVIA || i === x.PREDICTION);
|
|
250
|
-
if (!l && c !==
|
|
250
|
+
if (!l && c !== U.RESOLVED)
|
|
251
251
|
return null;
|
|
252
|
-
const m = i === x.PREDICTION && !s,
|
|
253
|
-
return /* @__PURE__ */
|
|
254
|
-
c ===
|
|
252
|
+
const m = i === x.PREDICTION && !s, d = t ? "correct" : "incorrect", h = t ? e.correctFeedback : e.incorrectFeedback;
|
|
253
|
+
return /* @__PURE__ */ f(Et, { "data-isPrediction": m, children: [
|
|
254
|
+
c === U.RESOLVED && i === x.TRIVIA && !n && /* @__PURE__ */ f($, { children: [
|
|
255
255
|
/* @__PURE__ */ r(ce, { children: /* @__PURE__ */ r(j, { name: "questionExpired" }) }),
|
|
256
|
-
/* @__PURE__ */
|
|
256
|
+
/* @__PURE__ */ f("div", { children: [
|
|
257
257
|
/* @__PURE__ */ r(de, { children: /* @__PURE__ */ r(J, { children: "Question Expired" }) }),
|
|
258
258
|
/* @__PURE__ */ r(Pt, { children: "You can still answer to see if you're correct, but no points are awarded for expired questions." })
|
|
259
259
|
] })
|
|
260
260
|
] }),
|
|
261
|
-
l && m && /* @__PURE__ */
|
|
261
|
+
l && m && /* @__PURE__ */ f($, { children: [
|
|
262
262
|
/* @__PURE__ */ r(Qt, { name: "icon-prediction" }),
|
|
263
263
|
/* @__PURE__ */ r(J, { children: "Stay tuned to see if your prediction was correct." })
|
|
264
264
|
] }),
|
|
265
|
-
l && s && /* @__PURE__ */
|
|
266
|
-
/* @__PURE__ */ r(ce, { "data-feedbackType":
|
|
267
|
-
/* @__PURE__ */ r("div", { children: /* @__PURE__ */
|
|
268
|
-
/* @__PURE__ */ r(Ut, { "data-feedbackType":
|
|
269
|
-
/* @__PURE__ */ r(J, { children:
|
|
265
|
+
l && s && /* @__PURE__ */ f($, { children: [
|
|
266
|
+
/* @__PURE__ */ r(ce, { "data-feedbackType": d, children: /* @__PURE__ */ r(j, { name: d }) }),
|
|
267
|
+
/* @__PURE__ */ r("div", { children: /* @__PURE__ */ f(de, { children: [
|
|
268
|
+
/* @__PURE__ */ r(Ut, { "data-feedbackType": d, children: h == null ? void 0 : h.title }),
|
|
269
|
+
/* @__PURE__ */ r(J, { children: h == null ? void 0 : h.description })
|
|
270
270
|
] }) })
|
|
271
271
|
] })
|
|
272
272
|
] });
|
|
@@ -335,11 +335,11 @@ const Je = /* @__PURE__ */ a("div")({
|
|
|
335
335
|
class: "cu9kmlb",
|
|
336
336
|
propsAsIs: !0
|
|
337
337
|
}), ue = {
|
|
338
|
-
[
|
|
339
|
-
[
|
|
340
|
-
[
|
|
341
|
-
[
|
|
342
|
-
[
|
|
338
|
+
[R.CENTERED]: (e) => /* @__PURE__ */ r(Kt, { alt: "option-icon", src: e }),
|
|
339
|
+
[R.TRANSPARENT]: (e) => /* @__PURE__ */ r(Gt, { children: /* @__PURE__ */ r(Zt, { style: { backgroundImage: `url(${e})` } }) }),
|
|
340
|
+
[R.ROUNDED]: (e) => /* @__PURE__ */ r(en, { alt: "option-icon", src: e }),
|
|
341
|
+
[R.NONE]: () => null,
|
|
342
|
+
[R.UNSET]: () => null
|
|
343
343
|
}, an = ({ questionType: e, hasCorrectAnswer: t, correct: n, youVoted: i, questionVoted: s }) => {
|
|
344
344
|
if (e === x.POLL && i)
|
|
345
345
|
return "correct";
|
|
@@ -356,7 +356,7 @@ const Je = /* @__PURE__ */ a("div")({
|
|
|
356
356
|
correct: n,
|
|
357
357
|
hasCorrectAnswer: i,
|
|
358
358
|
questionStatus: s
|
|
359
|
-
}) => e === x.TRIVIA ? t && n : e === x.PREDICTION ? t && n && i || s ===
|
|
359
|
+
}) => e === x.TRIVIA ? t && n : e === x.PREDICTION ? t && n && i || s === U.RESOLVED && n : !1, cn = (e) => {
|
|
360
360
|
var t;
|
|
361
361
|
const {
|
|
362
362
|
// option props
|
|
@@ -367,30 +367,30 @@ const Je = /* @__PURE__ */ a("div")({
|
|
|
367
367
|
// extra props
|
|
368
368
|
onVote: l,
|
|
369
369
|
youSelected: m,
|
|
370
|
-
questionVoted:
|
|
370
|
+
questionVoted: d,
|
|
371
371
|
// ToDo: Figure out why imageMode is not in the response, and delete default value
|
|
372
|
-
imageMode:
|
|
372
|
+
imageMode: h,
|
|
373
373
|
answerTimeExpired: T,
|
|
374
|
-
questionStatus:
|
|
374
|
+
questionStatus: M,
|
|
375
375
|
isLoading: g,
|
|
376
376
|
questionType: A,
|
|
377
377
|
correct: D,
|
|
378
378
|
hasCorrectAnswer: o
|
|
379
|
-
} = e,
|
|
380
|
-
return /* @__PURE__ */
|
|
379
|
+
} = e, u = an(e), p = ln({ questionType: A, questionVoted: d, correct: D, hasCorrectAnswer: o, questionStatus: M }), I = d || M === U.RESOLVED && A === x.PREDICTION;
|
|
380
|
+
return /* @__PURE__ */ f(
|
|
381
381
|
Ft,
|
|
382
382
|
{
|
|
383
383
|
value: n,
|
|
384
384
|
"data-selected": m,
|
|
385
|
-
"data-answerState":
|
|
386
|
-
disabled:
|
|
385
|
+
"data-answerState": u,
|
|
386
|
+
disabled: d || g || T,
|
|
387
387
|
onClick: l,
|
|
388
388
|
children: [
|
|
389
|
-
|
|
390
|
-
/* @__PURE__ */
|
|
391
|
-
i &&
|
|
389
|
+
I && /* @__PURE__ */ r(Bt, { "data-answerState": u, style: { width: `${c}%` } }),
|
|
390
|
+
/* @__PURE__ */ f(Ht, { children: [
|
|
391
|
+
i && h && ((t = ue[h]) == null ? void 0 : t.call(ue, i)),
|
|
392
392
|
/* @__PURE__ */ r(tn, { children: s }),
|
|
393
|
-
|
|
393
|
+
I && /* @__PURE__ */ f(nn, { children: [
|
|
394
394
|
p && /* @__PURE__ */ r(on, { name: "selected" }),
|
|
395
395
|
/* @__PURE__ */ r(sn, { children: /* @__PURE__ */ r(Ye, { value: c, suffix: "%" }) })
|
|
396
396
|
] })
|
|
@@ -400,33 +400,33 @@ const Je = /* @__PURE__ */ a("div")({
|
|
|
400
400
|
);
|
|
401
401
|
};
|
|
402
402
|
var pe = typeof window > "u" ? Ge : Ze, dn = ({ isPlaying: e, duration: t, startAt: n = 0, updateInterval: i = 0, onComplete: s, onUpdate: c }) => {
|
|
403
|
-
let [l, m] =
|
|
404
|
-
let
|
|
403
|
+
let [l, m] = P(n), d = C(0), h = C(n), T = C(n * -1e3), M = C(null), g = C(null), A = C(null), D = (p) => {
|
|
404
|
+
let I = p / 1e3;
|
|
405
405
|
if (g.current === null) {
|
|
406
|
-
g.current =
|
|
406
|
+
g.current = I, M.current = requestAnimationFrame(D);
|
|
407
407
|
return;
|
|
408
408
|
}
|
|
409
|
-
let
|
|
410
|
-
g.current =
|
|
411
|
-
let y =
|
|
412
|
-
m(z ? t : y), z || (
|
|
409
|
+
let v = I - g.current, N = d.current + v;
|
|
410
|
+
g.current = I, d.current = N;
|
|
411
|
+
let y = h.current + (i === 0 ? N : (N / i | 0) * i), S = h.current + N, z = typeof t == "number" && S >= t;
|
|
412
|
+
m(z ? t : y), z || (M.current = requestAnimationFrame(D));
|
|
413
413
|
}, o = () => {
|
|
414
|
-
|
|
415
|
-
},
|
|
416
|
-
o(),
|
|
417
|
-
let
|
|
418
|
-
|
|
414
|
+
M.current && cancelAnimationFrame(M.current), A.current && clearTimeout(A.current), g.current = null;
|
|
415
|
+
}, u = _((p) => {
|
|
416
|
+
o(), d.current = 0;
|
|
417
|
+
let I = typeof p == "number" ? p : n;
|
|
418
|
+
h.current = I, m(I), e && (M.current = requestAnimationFrame(D));
|
|
419
419
|
}, [e, n]);
|
|
420
420
|
return pe(() => {
|
|
421
421
|
if (c == null || c(l), t && l >= t) {
|
|
422
422
|
T.current += t * 1e3;
|
|
423
|
-
let { shouldRepeat: p = !1, delay:
|
|
424
|
-
p && (A.current = setTimeout(() =>
|
|
423
|
+
let { shouldRepeat: p = !1, delay: I = 0, newStartAt: v } = (s == null ? void 0 : s(T.current / 1e3)) || {};
|
|
424
|
+
p && (A.current = setTimeout(() => u(v), I * 1e3));
|
|
425
425
|
}
|
|
426
|
-
}, [l, t]), pe(() => (e && (
|
|
426
|
+
}, [l, t]), pe(() => (e && (M.current = requestAnimationFrame(D)), o), [e, t, i]), { elapsedTime: l, reset: u };
|
|
427
427
|
}, un = (e, t, n) => {
|
|
428
|
-
let i = e / 2, s = t / 2, c = i - s, l = 2 * c, m = n === "clockwise" ? "1,0" : "0,1",
|
|
429
|
-
return { path: `m ${i},${s} a ${c},${c} 0 ${m} 0,${l} a ${c},${c} 0 ${m} 0,-${l}`, pathLength:
|
|
428
|
+
let i = e / 2, s = t / 2, c = i - s, l = 2 * c, m = n === "clockwise" ? "1,0" : "0,1", d = 2 * Math.PI * c;
|
|
429
|
+
return { path: `m ${i},${s} a ${c},${c} 0 ${m} 0,${l} a ${c},${c} 0 ${m} 0,-${l}`, pathLength: d };
|
|
430
430
|
}, me = (e, t) => e === 0 || e === t ? 0 : typeof t == "number" ? e - t : 0, pn = (e) => ({ position: "relative", width: e, height: e }), mn = { display: "flex", justifyContent: "center", alignItems: "center", position: "absolute", left: 0, top: 0, width: "100%", height: "100%" }, Ce = (e, t, n, i, s) => {
|
|
431
431
|
if (i === 0)
|
|
432
432
|
return t;
|
|
@@ -445,41 +445,41 @@ var pe = typeof window > "u" ? Ge : Ze, dn = ({ isPlaying: e, duration: t, start
|
|
|
445
445
|
return i[0];
|
|
446
446
|
if (!c)
|
|
447
447
|
return i[l];
|
|
448
|
-
let m = s[l] - t,
|
|
449
|
-
return `rgb(${
|
|
448
|
+
let m = s[l] - t, d = s[l] - s[l + 1], h = he(i[l]), T = he(i[l + 1]), M = !!e.isGrowing;
|
|
449
|
+
return `rgb(${h.map((g, A) => Ce(m, g, T[A] - g, d, M) | 0).join(",")})`;
|
|
450
450
|
}, In = (e) => {
|
|
451
|
-
let { duration: t, initialRemainingTime: n, updateInterval: i, size: s = 180, strokeWidth: c = 12, trailStrokeWidth: l, isPlaying: m = !1, isGrowing:
|
|
452
|
-
let
|
|
453
|
-
|
|
454
|
-
} : void 0, onComplete: typeof T == "function" ? (
|
|
455
|
-
var
|
|
456
|
-
let { shouldRepeat: N, delay: y, newInitialRemainingTime: S } = (
|
|
451
|
+
let { duration: t, initialRemainingTime: n, updateInterval: i, size: s = 180, strokeWidth: c = 12, trailStrokeWidth: l, isPlaying: m = !1, isGrowing: d = !1, rotation: h = "clockwise", onComplete: T, onUpdate: M } = e, g = C(), A = Math.max(c, l ?? 0), { path: D, pathLength: o } = un(s, A, h), { elapsedTime: u } = dn({ isPlaying: m, duration: t, startAt: me(t, n), updateInterval: i, onUpdate: typeof M == "function" ? (I) => {
|
|
452
|
+
let v = Math.ceil(t - I);
|
|
453
|
+
v !== g.current && (g.current = v, M(v));
|
|
454
|
+
} : void 0, onComplete: typeof T == "function" ? (I) => {
|
|
455
|
+
var v;
|
|
456
|
+
let { shouldRepeat: N, delay: y, newInitialRemainingTime: S } = (v = T(I)) != null ? v : {};
|
|
457
457
|
if (N)
|
|
458
458
|
return { shouldRepeat: N, delay: y, newStartAt: me(t, S) };
|
|
459
|
-
} : void 0 }), p = t -
|
|
460
|
-
return { elapsedTime:
|
|
459
|
+
} : void 0 }), p = t - u;
|
|
460
|
+
return { elapsedTime: u, path: D, pathLength: o, remainingTime: Math.ceil(p), rotation: h, size: s, stroke: hn(e, p), strokeDashoffset: Ce(u, 0, o, t, d), strokeWidth: c };
|
|
461
461
|
}, be = (e) => {
|
|
462
|
-
let { children: t, strokeLinecap: n, trailColor: i, trailStrokeWidth: s } = e, { path: c, pathLength: l, stroke: m, strokeDashoffset:
|
|
463
|
-
return
|
|
462
|
+
let { children: t, strokeLinecap: n, trailColor: i, trailStrokeWidth: s } = e, { path: c, pathLength: l, stroke: m, strokeDashoffset: d, remainingTime: h, elapsedTime: T, size: M, strokeWidth: g } = In(e);
|
|
463
|
+
return Q.createElement("div", { style: pn(M) }, Q.createElement("svg", { viewBox: `0 0 ${M} ${M}`, width: M, height: M, xmlns: "http://www.w3.org/2000/svg" }, Q.createElement("path", { d: c, fill: "none", stroke: i ?? "#d9d9d9", strokeWidth: s ?? g }), Q.createElement("path", { d: c, fill: "none", stroke: m, strokeLinecap: n ?? "round", strokeWidth: g, strokeDasharray: l, strokeDashoffset: d })), typeof t == "function" && Q.createElement("div", { style: mn }, t({ remainingTime: h, elapsedTime: T, color: m })));
|
|
464
464
|
};
|
|
465
465
|
be.displayName = "CountdownCircleTimer";
|
|
466
|
-
const fn = [
|
|
466
|
+
const fn = [L.PRIMARY_GREEN1, L.SECONDARY_RED1, L.SECONDARY_RED1], gn = [10, 10, 0], vn = /* @__PURE__ */ a("div")({
|
|
467
467
|
name: "RemainingTime",
|
|
468
468
|
class: "r165427",
|
|
469
469
|
propsAsIs: !1
|
|
470
|
-
}),
|
|
470
|
+
}), Mn = L.SECONDARY_GREEN6, Ie = L.SECONDARY_RED3, yn = L.NEUTRALS_GRAY3, Nn = ({
|
|
471
471
|
isPlaying: e = !0,
|
|
472
472
|
duration: t = 30,
|
|
473
473
|
onTimerExpired: n
|
|
474
474
|
}) => {
|
|
475
|
-
const [i, s] =
|
|
476
|
-
remainingTime:
|
|
477
|
-
}) => /* @__PURE__ */ r(
|
|
478
|
-
children:
|
|
475
|
+
const [i, s] = P(t > 10 ? Mn : Ie), c = ({
|
|
476
|
+
remainingTime: d
|
|
477
|
+
}) => /* @__PURE__ */ r(vn, {
|
|
478
|
+
children: d
|
|
479
479
|
}), l = _(() => {
|
|
480
480
|
n == null || n(), s(yn);
|
|
481
|
-
}, [n, s]), m = _((
|
|
482
|
-
|
|
481
|
+
}, [n, s]), m = _((d) => {
|
|
482
|
+
d === 10 && s(Ie);
|
|
483
483
|
}, [s]);
|
|
484
484
|
return /* @__PURE__ */ r(be, {
|
|
485
485
|
isPlaying: e,
|
|
@@ -530,60 +530,60 @@ const fn = [E.PRIMARY_GREEN1, E.SECONDARY_RED1, E.SECONDARY_RED1], gn = [10, 10,
|
|
|
530
530
|
questionType: s,
|
|
531
531
|
timerDuration: c,
|
|
532
532
|
onTimerExpired: l
|
|
533
|
-
}) => /* @__PURE__ */
|
|
534
|
-
/* @__PURE__ */
|
|
533
|
+
}) => /* @__PURE__ */ f(Tn, { children: [
|
|
534
|
+
/* @__PURE__ */ f(An, { children: [
|
|
535
535
|
e && /* @__PURE__ */ r(Dn, { children: e }),
|
|
536
|
-
t !== void 0 && s !== x.POLL && /* @__PURE__ */
|
|
536
|
+
t !== void 0 && s !== x.POLL && /* @__PURE__ */ f($, { children: [
|
|
537
537
|
/* @__PURE__ */ r(zn, { name: "icon-trophy" }),
|
|
538
|
-
/* @__PURE__ */
|
|
538
|
+
/* @__PURE__ */ f(xn, { children: [
|
|
539
539
|
/* @__PURE__ */ r(jn, { children: t }),
|
|
540
540
|
/* @__PURE__ */ r(On, { children: "PTS" })
|
|
541
541
|
] })
|
|
542
542
|
] })
|
|
543
543
|
] }),
|
|
544
544
|
i && /* @__PURE__ */ r(Nn, { isPlaying: n, onTimerExpired: l, duration: c })
|
|
545
|
-
] }), wn = ({ openedQuestion: e,
|
|
546
|
-
var
|
|
547
|
-
const
|
|
545
|
+
] }), wn = ({ openedQuestion: e, isLoading: t, vote: n, close: i }) => {
|
|
546
|
+
var s, c;
|
|
547
|
+
const l = e.subject, m = e.type, d = (s = e.options) == null ? void 0 : s.options, [h, T] = P(!1), [M, g] = P(""), A = e == null ? void 0 : e.id, D = _(
|
|
548
548
|
async (N) => {
|
|
549
549
|
if (A) {
|
|
550
550
|
const y = N.currentTarget.value;
|
|
551
|
-
g(y),
|
|
551
|
+
g(y), await n(A, y);
|
|
552
552
|
}
|
|
553
553
|
},
|
|
554
|
-
[A, g,
|
|
554
|
+
[A, g, n]
|
|
555
555
|
), o = _(() => {
|
|
556
|
-
|
|
557
|
-
}, [
|
|
556
|
+
T(!0), setTimeout(i, 3e3);
|
|
557
|
+
}, [i]), u = B(
|
|
558
558
|
() => e == null ? void 0 : e.answers.find((N) => N.youVoted === !0),
|
|
559
559
|
[e]
|
|
560
560
|
), p = B(
|
|
561
561
|
() => !!(e != null && e.answers.find((N) => N.correct === !0)),
|
|
562
562
|
[e]
|
|
563
|
-
),
|
|
563
|
+
), I = B(() => e ? e.answers.map((N) => {
|
|
564
564
|
var y;
|
|
565
565
|
return {
|
|
566
566
|
...N,
|
|
567
|
-
questionVoted: !!
|
|
568
|
-
youSelected:
|
|
569
|
-
isLoading:
|
|
567
|
+
questionVoted: !!u,
|
|
568
|
+
youSelected: M === N.id,
|
|
569
|
+
isLoading: t,
|
|
570
570
|
hasCorrectAnswer: p,
|
|
571
571
|
questionType: e.type,
|
|
572
|
-
answerTimeExpired:
|
|
572
|
+
answerTimeExpired: h,
|
|
573
573
|
questionStatus: e.status,
|
|
574
574
|
imageMode: (y = e.appearance) == null ? void 0 : y.images,
|
|
575
575
|
// ToDo: Figure out why imageMode is not in the response
|
|
576
576
|
onVote: D
|
|
577
577
|
};
|
|
578
|
-
}) : [], [p,
|
|
579
|
-
return /* @__PURE__ */ r(ie, { "data-question-header": "true", children: /* @__PURE__ */ r(qt, { children: /* @__PURE__ */
|
|
580
|
-
|
|
578
|
+
}) : [], [p, h, t, e, u, D, M]), v = d && (d.case === "trivia" || d.case === "prediction") ? d.value : void 0;
|
|
579
|
+
return /* @__PURE__ */ r(ie, { "data-question-header": "true", children: /* @__PURE__ */ r(qt, { children: /* @__PURE__ */ f(Yt, { children: [
|
|
580
|
+
v && /* @__PURE__ */ r(
|
|
581
581
|
_t,
|
|
582
582
|
{
|
|
583
|
-
feedbackMessages:
|
|
584
|
-
questionVoted: !!
|
|
585
|
-
questionVotedCorrectly:
|
|
586
|
-
questionType:
|
|
583
|
+
feedbackMessages: v,
|
|
584
|
+
questionVoted: !!u,
|
|
585
|
+
questionVotedCorrectly: u == null ? void 0 : u.correct,
|
|
586
|
+
questionType: m,
|
|
587
587
|
hasCorrectAnswer: p,
|
|
588
588
|
questionStatus: e.status
|
|
589
589
|
}
|
|
@@ -591,24 +591,24 @@ const fn = [E.PRIMARY_GREEN1, E.SECONDARY_RED1, E.SECONDARY_RED1], gn = [10, 10,
|
|
|
591
591
|
e.type !== x.PREDICTION && /* @__PURE__ */ r(
|
|
592
592
|
kn,
|
|
593
593
|
{
|
|
594
|
-
title:
|
|
595
|
-
points:
|
|
594
|
+
title: h ? "Time expired" : e.type === x.POLL ? "Time remaining" : "To win",
|
|
595
|
+
points: h ? void 0 : 100,
|
|
596
596
|
onTimerExpired: o,
|
|
597
597
|
questionType: e.type,
|
|
598
|
-
isTimer: !
|
|
599
|
-
isPlayingTimer: !
|
|
600
|
-
timerDuration:
|
|
598
|
+
isTimer: !t,
|
|
599
|
+
isPlayingTimer: !u,
|
|
600
|
+
timerDuration: u ? 0 : Number(((c = e == null ? void 0 : e.appearance) == null ? void 0 : c.autoHideInterval) || "30")
|
|
601
601
|
}
|
|
602
602
|
),
|
|
603
|
-
|
|
604
|
-
|
|
603
|
+
h ? /* @__PURE__ */ r(
|
|
604
|
+
Lt,
|
|
605
605
|
{
|
|
606
606
|
title: "More to come...",
|
|
607
607
|
description: "Watch for additional enhanced stream interactive experience."
|
|
608
608
|
}
|
|
609
|
-
) : /* @__PURE__ */
|
|
610
|
-
/* @__PURE__ */ r(Wt, { "data-isPrediction": e.type === x.PREDICTION, children:
|
|
611
|
-
/* @__PURE__ */ r(Vt, { children:
|
|
609
|
+
) : /* @__PURE__ */ f($, { children: [
|
|
610
|
+
/* @__PURE__ */ r(Wt, { "data-isPrediction": e.type === x.PREDICTION, children: l }),
|
|
611
|
+
/* @__PURE__ */ r(Vt, { children: I.map((N) => /* @__PURE__ */ r(cn, { ...N }, N.id)) })
|
|
612
612
|
] })
|
|
613
613
|
] }) }) });
|
|
614
614
|
}, Cn = /* @__PURE__ */ a("div")({
|
|
@@ -623,11 +623,11 @@ const fn = [E.PRIMARY_GREEN1, E.SECONDARY_RED1, E.SECONDARY_RED1], gn = [10, 10,
|
|
|
623
623
|
name: "Title",
|
|
624
624
|
class: "t5et2jt",
|
|
625
625
|
propsAsIs: !1
|
|
626
|
-
}),
|
|
626
|
+
}), Ln = /* @__PURE__ */ a("div")({
|
|
627
627
|
name: "Description",
|
|
628
628
|
class: "d1i2kpk2",
|
|
629
629
|
propsAsIs: !1
|
|
630
|
-
}),
|
|
630
|
+
}), En = /* @__PURE__ */ a("div")({
|
|
631
631
|
name: "DateWrap",
|
|
632
632
|
class: "dd3lh3p",
|
|
633
633
|
propsAsIs: !1
|
|
@@ -647,17 +647,17 @@ const fn = [E.PRIMARY_GREEN1, E.SECONDARY_RED1, E.SECONDARY_RED1], gn = [10, 10,
|
|
|
647
647
|
}
|
|
648
648
|
return null;
|
|
649
649
|
}, [e]), c = (i == null ? void 0 : i.image) || t;
|
|
650
|
-
return /* @__PURE__ */
|
|
651
|
-
s && /* @__PURE__ */
|
|
650
|
+
return /* @__PURE__ */ f(Cn, { children: [
|
|
651
|
+
s && /* @__PURE__ */ f(En, { children: [
|
|
652
652
|
s.date,
|
|
653
653
|
" · ",
|
|
654
654
|
s.time
|
|
655
655
|
] }),
|
|
656
656
|
(i == null ? void 0 : i.video) && /* @__PURE__ */ r(We, { source: i.video.url, poster: i.video.thumbnailUrl }),
|
|
657
657
|
c && /* @__PURE__ */ r(Rn, { src: c }),
|
|
658
|
-
/* @__PURE__ */
|
|
658
|
+
/* @__PURE__ */ f(bn, { children: [
|
|
659
659
|
/* @__PURE__ */ r($n, { children: (i == null ? void 0 : i.heading) || n }),
|
|
660
|
-
/* @__PURE__ */ r(
|
|
660
|
+
/* @__PURE__ */ r(Ln, { children: i == null ? void 0 : i.body })
|
|
661
661
|
] })
|
|
662
662
|
] });
|
|
663
663
|
}, Qn = /* @__PURE__ */ a("div")({
|
|
@@ -668,9 +668,9 @@ const fn = [E.PRIMARY_GREEN1, E.SECONDARY_RED1, E.SECONDARY_RED1], gn = [10, 10,
|
|
|
668
668
|
name: "WebLinkBtn",
|
|
669
669
|
class: "w19zie3h",
|
|
670
670
|
propsAsIs: !1
|
|
671
|
-
}), Pn = ({ instantView: e, ...t }) => /* @__PURE__ */
|
|
671
|
+
}), Pn = ({ instantView: e, ...t }) => /* @__PURE__ */ f(Qn, { children: [
|
|
672
672
|
/* @__PURE__ */ r($e, { instantView: e, ...t }),
|
|
673
|
-
(e == null ? void 0 : e.webLink) && /* @__PURE__ */
|
|
673
|
+
(e == null ? void 0 : e.webLink) && /* @__PURE__ */ f(Un, { href: e == null ? void 0 : e.webLink.url, target: "_blank", children: [
|
|
674
674
|
"Explore more of the Masters History",
|
|
675
675
|
/* @__PURE__ */ r(j, { name: "icon-external-link" })
|
|
676
676
|
] })
|
|
@@ -695,10 +695,11 @@ const fn = [E.PRIMARY_GREEN1, E.SECONDARY_RED1, E.SECONDARY_RED1], gn = [10, 10,
|
|
|
695
695
|
loading: i,
|
|
696
696
|
data: s
|
|
697
697
|
} = e;
|
|
698
|
-
return
|
|
698
|
+
return s ? /* @__PURE__ */ r(wn, {
|
|
699
699
|
vote: t,
|
|
700
700
|
close: n,
|
|
701
|
-
openedQuestion: s
|
|
701
|
+
openedQuestion: s,
|
|
702
|
+
isLoading: !!i
|
|
702
703
|
}) : null;
|
|
703
704
|
}, Wn = ({
|
|
704
705
|
gamification: e
|
|
@@ -708,7 +709,7 @@ const fn = [E.PRIMARY_GREEN1, E.SECONDARY_RED1, E.SECONDARY_RED1], gn = [10, 10,
|
|
|
708
709
|
if (!n)
|
|
709
710
|
return null;
|
|
710
711
|
const s = n.type;
|
|
711
|
-
return /* @__PURE__ */
|
|
712
|
+
return /* @__PURE__ */ f(_n, {
|
|
712
713
|
children: [/* @__PURE__ */ r(xe, {
|
|
713
714
|
close: e.closeQuestion,
|
|
714
715
|
type: ((t = n.attributes) == null ? void 0 : t.type) || x.UNSET
|
|
@@ -738,7 +739,7 @@ const fn = [E.PRIMARY_GREEN1, E.SECONDARY_RED1, E.SECONDARY_RED1], gn = [10, 10,
|
|
|
738
739
|
propsAsIs: !1
|
|
739
740
|
});
|
|
740
741
|
var H = /* @__PURE__ */ ((e) => (e.HOME = "home", e.LEADERBOARD = "leaderboard", e))(H || {});
|
|
741
|
-
const fe = ({ title: e, active: t, onClick: n }) => /* @__PURE__ */ r(Bn, { onClick: n, "data-selected": t, children: /* @__PURE__ */ r(Hn, { children: e }) }), Gn = ({ activePage: e = "home", toggleActivePage: t }) => /* @__PURE__ */ r(Vn, { children: /* @__PURE__ */
|
|
742
|
+
const fe = ({ title: e, active: t, onClick: n }) => /* @__PURE__ */ r(Bn, { onClick: n, "data-selected": t, children: /* @__PURE__ */ r(Hn, { children: e }) }), Gn = ({ activePage: e = "home", toggleActivePage: t }) => /* @__PURE__ */ r(Vn, { children: /* @__PURE__ */ f(Fn, { "data-position": e === "home" ? "left" : "right", children: [
|
|
742
743
|
/* @__PURE__ */ r(fe, { title: "Home", active: e === "home", onClick: () => t(
|
|
743
744
|
"home"
|
|
744
745
|
/* HOME */
|
|
@@ -778,11 +779,11 @@ function ne(e, t) {
|
|
|
778
779
|
function Zn(e, t) {
|
|
779
780
|
e.prototype = Object.create(t.prototype), e.prototype.constructor = e, ne(e, t);
|
|
780
781
|
}
|
|
781
|
-
var
|
|
782
|
+
var ve = Number.isNaN || function(t) {
|
|
782
783
|
return typeof t == "number" && t !== t;
|
|
783
784
|
};
|
|
784
785
|
function Jn(e, t) {
|
|
785
|
-
return !!(e === t ||
|
|
786
|
+
return !!(e === t || ve(e) && ve(t));
|
|
786
787
|
}
|
|
787
788
|
function Kn(e, t) {
|
|
788
789
|
if (e.length !== t.length)
|
|
@@ -796,13 +797,13 @@ function K(e, t) {
|
|
|
796
797
|
t === void 0 && (t = Kn);
|
|
797
798
|
var n, i = [], s, c = !1;
|
|
798
799
|
function l() {
|
|
799
|
-
for (var m = [],
|
|
800
|
-
m[
|
|
800
|
+
for (var m = [], d = 0; d < arguments.length; d++)
|
|
801
|
+
m[d] = arguments[d];
|
|
801
802
|
return c && n === this && t(m, i) || (s = e.apply(this, m), c = !0, n = this, i = m), s;
|
|
802
803
|
}
|
|
803
804
|
return l;
|
|
804
805
|
}
|
|
805
|
-
var Xn = typeof performance == "object" && typeof performance.now == "function",
|
|
806
|
+
var Xn = typeof performance == "object" && typeof performance.now == "function", Me = Xn ? function() {
|
|
806
807
|
return performance.now();
|
|
807
808
|
} : function() {
|
|
808
809
|
return Date.now();
|
|
@@ -811,9 +812,9 @@ function ye(e) {
|
|
|
811
812
|
cancelAnimationFrame(e.id);
|
|
812
813
|
}
|
|
813
814
|
function ei(e, t) {
|
|
814
|
-
var n =
|
|
815
|
+
var n = Me();
|
|
815
816
|
function i() {
|
|
816
|
-
|
|
817
|
+
Me() - n >= t ? e.call(null) : s.id = requestAnimationFrame(i);
|
|
817
818
|
}
|
|
818
819
|
var s = {
|
|
819
820
|
id: requestAnimationFrame(i)
|
|
@@ -842,37 +843,37 @@ var ti = 150, ni = function(t, n) {
|
|
|
842
843
|
return t;
|
|
843
844
|
};
|
|
844
845
|
function ii(e) {
|
|
845
|
-
var t, n = e.getItemOffset, i = e.getEstimatedTotalSize, s = e.getItemSize, c = e.getOffsetForIndexAndAlignment, l = e.getStartIndexForOffset, m = e.getStopIndexForStartIndex,
|
|
846
|
-
return t = /* @__PURE__ */ function(
|
|
847
|
-
Zn(g,
|
|
846
|
+
var t, n = e.getItemOffset, i = e.getEstimatedTotalSize, s = e.getItemSize, c = e.getOffsetForIndexAndAlignment, l = e.getStartIndexForOffset, m = e.getStopIndexForStartIndex, d = e.initInstanceProps, h = e.shouldResetStyleCacheOnItemSizeChange, T = e.validateProps;
|
|
847
|
+
return t = /* @__PURE__ */ function(M) {
|
|
848
|
+
Zn(g, M);
|
|
848
849
|
function g(D) {
|
|
849
850
|
var o;
|
|
850
|
-
return o =
|
|
851
|
+
return o = M.call(this, D) || this, o._instanceProps = d(o.props, ge(o)), o._outerRef = void 0, o._resetIsScrollingTimeoutId = null, o.state = {
|
|
851
852
|
instance: ge(o),
|
|
852
853
|
isScrolling: !1,
|
|
853
854
|
scrollDirection: "forward",
|
|
854
855
|
scrollOffset: typeof o.props.initialScrollOffset == "number" ? o.props.initialScrollOffset : 0,
|
|
855
856
|
scrollUpdateWasRequested: !1
|
|
856
|
-
}, o._callOnItemsRendered = void 0, o._callOnItemsRendered = K(function(
|
|
857
|
+
}, o._callOnItemsRendered = void 0, o._callOnItemsRendered = K(function(u, p, I, v) {
|
|
857
858
|
return o.props.onItemsRendered({
|
|
858
|
-
overscanStartIndex:
|
|
859
|
+
overscanStartIndex: u,
|
|
859
860
|
overscanStopIndex: p,
|
|
860
|
-
visibleStartIndex:
|
|
861
|
-
visibleStopIndex:
|
|
861
|
+
visibleStartIndex: I,
|
|
862
|
+
visibleStopIndex: v
|
|
862
863
|
});
|
|
863
|
-
}), o._callOnScroll = void 0, o._callOnScroll = K(function(
|
|
864
|
+
}), o._callOnScroll = void 0, o._callOnScroll = K(function(u, p, I) {
|
|
864
865
|
return o.props.onScroll({
|
|
865
|
-
scrollDirection:
|
|
866
|
+
scrollDirection: u,
|
|
866
867
|
scrollOffset: p,
|
|
867
|
-
scrollUpdateWasRequested:
|
|
868
|
+
scrollUpdateWasRequested: I
|
|
868
869
|
});
|
|
869
|
-
}), o._getItemStyle = void 0, o._getItemStyle = function(
|
|
870
|
-
var p = o.props,
|
|
871
|
-
if (y.hasOwnProperty(
|
|
872
|
-
S = y[
|
|
870
|
+
}), o._getItemStyle = void 0, o._getItemStyle = function(u) {
|
|
871
|
+
var p = o.props, I = p.direction, v = p.itemSize, N = p.layout, y = o._getItemStyleCache(h && v, h && N, h && I), S;
|
|
872
|
+
if (y.hasOwnProperty(u))
|
|
873
|
+
S = y[u];
|
|
873
874
|
else {
|
|
874
|
-
var z = n(o.props,
|
|
875
|
-
y[
|
|
875
|
+
var z = n(o.props, u, o._instanceProps), O = s(o.props, u, o._instanceProps), k = I === "horizontal" || N === "horizontal", q = I === "rtl", Y = k ? z : 0;
|
|
876
|
+
y[u] = S = {
|
|
876
877
|
position: "absolute",
|
|
877
878
|
left: q ? void 0 : Y,
|
|
878
879
|
right: q ? Y : void 0,
|
|
@@ -882,36 +883,36 @@ function ii(e) {
|
|
|
882
883
|
};
|
|
883
884
|
}
|
|
884
885
|
return S;
|
|
885
|
-
}, o._getItemStyleCache = void 0, o._getItemStyleCache = K(function(
|
|
886
|
+
}, o._getItemStyleCache = void 0, o._getItemStyleCache = K(function(u, p, I) {
|
|
886
887
|
return {};
|
|
887
|
-
}), o._onScrollHorizontal = function(
|
|
888
|
-
var p =
|
|
888
|
+
}), o._onScrollHorizontal = function(u) {
|
|
889
|
+
var p = u.currentTarget, I = p.clientWidth, v = p.scrollLeft, N = p.scrollWidth;
|
|
889
890
|
o.setState(function(y) {
|
|
890
|
-
if (y.scrollOffset ===
|
|
891
|
+
if (y.scrollOffset === v)
|
|
891
892
|
return null;
|
|
892
|
-
var S = o.props.direction, z =
|
|
893
|
+
var S = o.props.direction, z = v;
|
|
893
894
|
if (S === "rtl")
|
|
894
895
|
switch (Te()) {
|
|
895
896
|
case "negative":
|
|
896
|
-
z = -
|
|
897
|
+
z = -v;
|
|
897
898
|
break;
|
|
898
899
|
case "positive-descending":
|
|
899
|
-
z = N -
|
|
900
|
+
z = N - I - v;
|
|
900
901
|
break;
|
|
901
902
|
}
|
|
902
|
-
return z = Math.max(0, Math.min(z, N -
|
|
903
|
+
return z = Math.max(0, Math.min(z, N - I)), {
|
|
903
904
|
isScrolling: !0,
|
|
904
|
-
scrollDirection: y.scrollOffset <
|
|
905
|
+
scrollDirection: y.scrollOffset < v ? "forward" : "backward",
|
|
905
906
|
scrollOffset: z,
|
|
906
907
|
scrollUpdateWasRequested: !1
|
|
907
908
|
};
|
|
908
909
|
}, o._resetIsScrollingDebounced);
|
|
909
|
-
}, o._onScrollVertical = function(
|
|
910
|
-
var p =
|
|
910
|
+
}, o._onScrollVertical = function(u) {
|
|
911
|
+
var p = u.currentTarget, I = p.clientHeight, v = p.scrollHeight, N = p.scrollTop;
|
|
911
912
|
o.setState(function(y) {
|
|
912
913
|
if (y.scrollOffset === N)
|
|
913
914
|
return null;
|
|
914
|
-
var S = Math.max(0, Math.min(N,
|
|
915
|
+
var S = Math.max(0, Math.min(N, v - I));
|
|
915
916
|
return {
|
|
916
917
|
isScrolling: !0,
|
|
917
918
|
scrollDirection: y.scrollOffset < S ? "forward" : "backward",
|
|
@@ -919,9 +920,9 @@ function ii(e) {
|
|
|
919
920
|
scrollUpdateWasRequested: !1
|
|
920
921
|
};
|
|
921
922
|
}, o._resetIsScrollingDebounced);
|
|
922
|
-
}, o._outerRefSetter = function(
|
|
923
|
+
}, o._outerRefSetter = function(u) {
|
|
923
924
|
var p = o.props.outerRef;
|
|
924
|
-
o._outerRef =
|
|
925
|
+
o._outerRef = u, typeof p == "function" ? p(u) : p != null && typeof p == "object" && p.hasOwnProperty("current") && (p.current = u);
|
|
925
926
|
}, o._resetIsScrollingDebounced = function() {
|
|
926
927
|
o._resetIsScrollingTimeoutId !== null && ye(o._resetIsScrollingTimeoutId), o._resetIsScrollingTimeoutId = ei(o._resetIsScrolling, ti);
|
|
927
928
|
}, o._resetIsScrolling = function() {
|
|
@@ -932,85 +933,85 @@ function ii(e) {
|
|
|
932
933
|
});
|
|
933
934
|
}, o;
|
|
934
935
|
}
|
|
935
|
-
g.getDerivedStateFromProps = function(o,
|
|
936
|
-
return si(o,
|
|
936
|
+
g.getDerivedStateFromProps = function(o, u) {
|
|
937
|
+
return si(o, u), T(o), null;
|
|
937
938
|
};
|
|
938
939
|
var A = g.prototype;
|
|
939
940
|
return A.scrollTo = function(o) {
|
|
940
|
-
o = Math.max(0, o), this.setState(function(
|
|
941
|
-
return
|
|
942
|
-
scrollDirection:
|
|
941
|
+
o = Math.max(0, o), this.setState(function(u) {
|
|
942
|
+
return u.scrollOffset === o ? null : {
|
|
943
|
+
scrollDirection: u.scrollOffset < o ? "forward" : "backward",
|
|
943
944
|
scrollOffset: o,
|
|
944
945
|
scrollUpdateWasRequested: !0
|
|
945
946
|
};
|
|
946
947
|
}, this._resetIsScrollingDebounced);
|
|
947
|
-
}, A.scrollToItem = function(o,
|
|
948
|
-
|
|
949
|
-
var p = this.props,
|
|
950
|
-
o = Math.max(0, Math.min(o,
|
|
948
|
+
}, A.scrollToItem = function(o, u) {
|
|
949
|
+
u === void 0 && (u = "auto");
|
|
950
|
+
var p = this.props, I = p.itemCount, v = p.layout, N = this.state.scrollOffset;
|
|
951
|
+
o = Math.max(0, Math.min(o, I - 1));
|
|
951
952
|
var y = 0;
|
|
952
953
|
if (this._outerRef) {
|
|
953
954
|
var S = this._outerRef;
|
|
954
|
-
|
|
955
|
+
v === "vertical" ? y = S.scrollWidth > S.clientWidth ? Ne() : 0 : y = S.scrollHeight > S.clientHeight ? Ne() : 0;
|
|
955
956
|
}
|
|
956
|
-
this.scrollTo(c(this.props, o,
|
|
957
|
+
this.scrollTo(c(this.props, o, u, N, this._instanceProps, y));
|
|
957
958
|
}, A.componentDidMount = function() {
|
|
958
|
-
var o = this.props,
|
|
959
|
+
var o = this.props, u = o.direction, p = o.initialScrollOffset, I = o.layout;
|
|
959
960
|
if (typeof p == "number" && this._outerRef != null) {
|
|
960
|
-
var
|
|
961
|
-
|
|
961
|
+
var v = this._outerRef;
|
|
962
|
+
u === "horizontal" || I === "horizontal" ? v.scrollLeft = p : v.scrollTop = p;
|
|
962
963
|
}
|
|
963
964
|
this._callPropsCallbacks();
|
|
964
965
|
}, A.componentDidUpdate = function() {
|
|
965
|
-
var o = this.props,
|
|
966
|
+
var o = this.props, u = o.direction, p = o.layout, I = this.state, v = I.scrollOffset, N = I.scrollUpdateWasRequested;
|
|
966
967
|
if (N && this._outerRef != null) {
|
|
967
968
|
var y = this._outerRef;
|
|
968
|
-
if (
|
|
969
|
-
if (
|
|
969
|
+
if (u === "horizontal" || p === "horizontal")
|
|
970
|
+
if (u === "rtl")
|
|
970
971
|
switch (Te()) {
|
|
971
972
|
case "negative":
|
|
972
|
-
y.scrollLeft = -
|
|
973
|
+
y.scrollLeft = -v;
|
|
973
974
|
break;
|
|
974
975
|
case "positive-ascending":
|
|
975
|
-
y.scrollLeft =
|
|
976
|
+
y.scrollLeft = v;
|
|
976
977
|
break;
|
|
977
978
|
default:
|
|
978
979
|
var S = y.clientWidth, z = y.scrollWidth;
|
|
979
|
-
y.scrollLeft = z - S -
|
|
980
|
+
y.scrollLeft = z - S - v;
|
|
980
981
|
break;
|
|
981
982
|
}
|
|
982
983
|
else
|
|
983
|
-
y.scrollLeft =
|
|
984
|
+
y.scrollLeft = v;
|
|
984
985
|
else
|
|
985
|
-
y.scrollTop =
|
|
986
|
+
y.scrollTop = v;
|
|
986
987
|
}
|
|
987
988
|
this._callPropsCallbacks();
|
|
988
989
|
}, A.componentWillUnmount = function() {
|
|
989
990
|
this._resetIsScrollingTimeoutId !== null && ye(this._resetIsScrollingTimeoutId);
|
|
990
991
|
}, A.render = function() {
|
|
991
|
-
var o = this.props,
|
|
992
|
+
var o = this.props, u = o.children, p = o.className, I = o.direction, v = o.height, N = o.innerRef, y = o.innerElementType, S = o.innerTagName, z = o.itemCount, O = o.itemData, k = o.itemKey, q = k === void 0 ? ni : k, Y = o.layout, Le = o.outerElementType, Ee = o.outerTagName, Re = o.style, Qe = o.useIsScrolling, Ue = o.width, se = this.state.isScrolling, G = I === "horizontal" || Y === "horizontal", Pe = G ? this._onScrollHorizontal : this._onScrollVertical, re = this._getRangeToRender(), _e = re[0], qe = re[1], oe = [];
|
|
992
993
|
if (z > 0)
|
|
993
|
-
for (var
|
|
994
|
-
oe.push(Z(
|
|
994
|
+
for (var E = _e; E <= qe; E++)
|
|
995
|
+
oe.push(Z(u, {
|
|
995
996
|
data: O,
|
|
996
|
-
key: q(
|
|
997
|
-
index:
|
|
997
|
+
key: q(E, O),
|
|
998
|
+
index: E,
|
|
998
999
|
isScrolling: Qe ? se : void 0,
|
|
999
|
-
style: this._getItemStyle(
|
|
1000
|
+
style: this._getItemStyle(E)
|
|
1000
1001
|
}));
|
|
1001
1002
|
var ae = i(this.props, this._instanceProps);
|
|
1002
|
-
return Z(
|
|
1003
|
+
return Z(Le || Ee || "div", {
|
|
1003
1004
|
className: p,
|
|
1004
1005
|
onScroll: Pe,
|
|
1005
1006
|
ref: this._outerRefSetter,
|
|
1006
1007
|
style: te({
|
|
1007
1008
|
position: "relative",
|
|
1008
|
-
height:
|
|
1009
|
+
height: v,
|
|
1009
1010
|
width: Ue,
|
|
1010
1011
|
overflow: "auto",
|
|
1011
1012
|
WebkitOverflowScrolling: "touch",
|
|
1012
1013
|
willChange: "transform",
|
|
1013
|
-
direction:
|
|
1014
|
+
direction: I
|
|
1014
1015
|
}, Re)
|
|
1015
1016
|
}, Z(y || S || "div", {
|
|
1016
1017
|
children: oe,
|
|
@@ -1025,8 +1026,8 @@ function ii(e) {
|
|
|
1025
1026
|
if (typeof this.props.onItemsRendered == "function") {
|
|
1026
1027
|
var o = this.props.itemCount;
|
|
1027
1028
|
if (o > 0) {
|
|
1028
|
-
var
|
|
1029
|
-
this._callOnItemsRendered(p,
|
|
1029
|
+
var u = this._getRangeToRender(), p = u[0], I = u[1], v = u[2], N = u[3];
|
|
1030
|
+
this._callOnItemsRendered(p, I, v, N);
|
|
1030
1031
|
}
|
|
1031
1032
|
}
|
|
1032
1033
|
if (typeof this.props.onScroll == "function") {
|
|
@@ -1034,11 +1035,11 @@ function ii(e) {
|
|
|
1034
1035
|
this._callOnScroll(S, z, O);
|
|
1035
1036
|
}
|
|
1036
1037
|
}, A._getRangeToRender = function() {
|
|
1037
|
-
var o = this.props,
|
|
1038
|
-
if (
|
|
1038
|
+
var o = this.props, u = o.itemCount, p = o.overscanCount, I = this.state, v = I.isScrolling, N = I.scrollDirection, y = I.scrollOffset;
|
|
1039
|
+
if (u === 0)
|
|
1039
1040
|
return [0, 0, 0, 0];
|
|
1040
|
-
var S = l(this.props, y, this._instanceProps), z = m(this.props, S, y, this._instanceProps), O = !
|
|
1041
|
-
return [Math.max(0, S - O), Math.max(0, Math.min(
|
|
1041
|
+
var S = l(this.props, y, this._instanceProps), z = m(this.props, S, y, this._instanceProps), O = !v || N === "backward" ? Math.max(1, p) : 1, k = !v || N === "forward" ? Math.max(1, p) : 1;
|
|
1042
|
+
return [Math.max(0, S - O), Math.max(0, Math.min(u - 1, z + k)), S, z];
|
|
1042
1043
|
}, g;
|
|
1043
1044
|
}(ze), t.defaultProps = {
|
|
1044
1045
|
direction: "ltr",
|
|
@@ -1064,19 +1065,19 @@ var si = function(t, n) {
|
|
|
1064
1065
|
return i * n;
|
|
1065
1066
|
},
|
|
1066
1067
|
getOffsetForIndexAndAlignment: function(t, n, i, s, c, l) {
|
|
1067
|
-
var m = t.direction,
|
|
1068
|
-
switch (i === "smart" && (s >= p - D && s <=
|
|
1068
|
+
var m = t.direction, d = t.height, h = t.itemCount, T = t.itemSize, M = t.layout, g = t.width, A = m === "horizontal" || M === "horizontal", D = A ? g : d, o = Math.max(0, h * T - D), u = Math.min(o, n * T), p = Math.max(0, n * T - D + T + l);
|
|
1069
|
+
switch (i === "smart" && (s >= p - D && s <= u + D ? i = "auto" : i = "center"), i) {
|
|
1069
1070
|
case "start":
|
|
1070
|
-
return
|
|
1071
|
+
return u;
|
|
1071
1072
|
case "end":
|
|
1072
1073
|
return p;
|
|
1073
1074
|
case "center": {
|
|
1074
|
-
var
|
|
1075
|
-
return
|
|
1075
|
+
var I = Math.round(p + (u - p) / 2);
|
|
1076
|
+
return I < Math.ceil(D / 2) ? 0 : I > o + Math.floor(D / 2) ? o : I;
|
|
1076
1077
|
}
|
|
1077
1078
|
case "auto":
|
|
1078
1079
|
default:
|
|
1079
|
-
return s >= p && s <=
|
|
1080
|
+
return s >= p && s <= u ? s : s < p ? p : u;
|
|
1080
1081
|
}
|
|
1081
1082
|
},
|
|
1082
1083
|
getStartIndexForOffset: function(t, n) {
|
|
@@ -1084,7 +1085,7 @@ var si = function(t, n) {
|
|
|
1084
1085
|
return Math.max(0, Math.min(i - 1, Math.floor(n / s)));
|
|
1085
1086
|
},
|
|
1086
1087
|
getStopIndexForStartIndex: function(t, n, i) {
|
|
1087
|
-
var s = t.direction, c = t.height, l = t.itemCount, m = t.itemSize,
|
|
1088
|
+
var s = t.direction, c = t.height, l = t.itemCount, m = t.itemSize, d = t.layout, h = t.width, T = s === "horizontal" || d === "horizontal", M = n * m, g = T ? h : c, A = Math.ceil((g + i - M) / m);
|
|
1088
1089
|
return Math.max(0, Math.min(
|
|
1089
1090
|
l - 1,
|
|
1090
1091
|
n + A - 1
|
|
@@ -1103,14 +1104,14 @@ function oi(e) {
|
|
|
1103
1104
|
return !(i > n || s < t);
|
|
1104
1105
|
}
|
|
1105
1106
|
function ai(e) {
|
|
1106
|
-
for (var t = e.isItemLoaded, n = e.itemCount, i = e.minimumBatchSize, s = e.startIndex, c = e.stopIndex, l = [], m = null,
|
|
1107
|
-
var T = t(
|
|
1108
|
-
T ?
|
|
1107
|
+
for (var t = e.isItemLoaded, n = e.itemCount, i = e.minimumBatchSize, s = e.startIndex, c = e.stopIndex, l = [], m = null, d = null, h = s; h <= c; h++) {
|
|
1108
|
+
var T = t(h);
|
|
1109
|
+
T ? d !== null && (l.push(m, d), m = d = null) : (d = h, m === null && (m = h));
|
|
1109
1110
|
}
|
|
1110
|
-
if (
|
|
1111
|
-
for (var
|
|
1112
|
-
|
|
1113
|
-
l.push(m,
|
|
1111
|
+
if (d !== null) {
|
|
1112
|
+
for (var M = Math.min(Math.max(d, m + i - 1), n - 1), g = d + 1; g <= M && !t(g); g++)
|
|
1113
|
+
d = g;
|
|
1114
|
+
l.push(m, d);
|
|
1114
1115
|
}
|
|
1115
1116
|
if (l.length)
|
|
1116
1117
|
for (; l[1] - l[0] + 1 < i && l[0] > 0; ) {
|
|
@@ -1155,13 +1156,13 @@ var li = function(e, t) {
|
|
|
1155
1156
|
function t() {
|
|
1156
1157
|
var n, i, s, c;
|
|
1157
1158
|
li(this, t);
|
|
1158
|
-
for (var l = arguments.length, m = Array(l),
|
|
1159
|
-
m[
|
|
1160
|
-
return c = (i = (s = Ae(this, (n = t.__proto__ || Object.getPrototypeOf(t)).call.apply(n, [this].concat(m))), s), s._lastRenderedStartIndex = -1, s._lastRenderedStopIndex = -1, s._memoizedUnloadedRanges = [], s._onItemsRendered = function(
|
|
1161
|
-
var T =
|
|
1162
|
-
s._lastRenderedStartIndex = T, s._lastRenderedStopIndex =
|
|
1163
|
-
}, s._setRef = function(
|
|
1164
|
-
s._listRef =
|
|
1159
|
+
for (var l = arguments.length, m = Array(l), d = 0; d < l; d++)
|
|
1160
|
+
m[d] = arguments[d];
|
|
1161
|
+
return c = (i = (s = Ae(this, (n = t.__proto__ || Object.getPrototypeOf(t)).call.apply(n, [this].concat(m))), s), s._lastRenderedStartIndex = -1, s._lastRenderedStopIndex = -1, s._memoizedUnloadedRanges = [], s._onItemsRendered = function(h) {
|
|
1162
|
+
var T = h.visibleStartIndex, M = h.visibleStopIndex;
|
|
1163
|
+
s._lastRenderedStartIndex = T, s._lastRenderedStopIndex = M, s._ensureRowsLoaded(T, M);
|
|
1164
|
+
}, s._setRef = function(h) {
|
|
1165
|
+
s._listRef = h;
|
|
1165
1166
|
}, i), Ae(s, c);
|
|
1166
1167
|
}
|
|
1167
1168
|
return ci(t, [{
|
|
@@ -1186,12 +1187,12 @@ var li = function(e, t) {
|
|
|
1186
1187
|
}, {
|
|
1187
1188
|
key: "_ensureRowsLoaded",
|
|
1188
1189
|
value: function(i, s) {
|
|
1189
|
-
var c = this.props, l = c.isItemLoaded, m = c.itemCount,
|
|
1190
|
+
var c = this.props, l = c.isItemLoaded, m = c.itemCount, d = c.minimumBatchSize, h = d === void 0 ? 10 : d, T = c.threshold, M = T === void 0 ? 15 : T, g = ai({
|
|
1190
1191
|
isItemLoaded: l,
|
|
1191
1192
|
itemCount: m,
|
|
1192
|
-
minimumBatchSize:
|
|
1193
|
-
startIndex: Math.max(0, i -
|
|
1194
|
-
stopIndex: Math.min(m - 1, s +
|
|
1193
|
+
minimumBatchSize: h,
|
|
1194
|
+
startIndex: Math.max(0, i - M),
|
|
1195
|
+
stopIndex: Math.min(m - 1, s + M)
|
|
1195
1196
|
});
|
|
1196
1197
|
(this._memoizedUnloadedRanges.length !== g.length || this._memoizedUnloadedRanges.some(function(A, D) {
|
|
1197
1198
|
return g[D] !== A;
|
|
@@ -1200,14 +1201,14 @@ var li = function(e, t) {
|
|
|
1200
1201
|
}, {
|
|
1201
1202
|
key: "_loadUnloadedRanges",
|
|
1202
1203
|
value: function(i) {
|
|
1203
|
-
for (var s = this, c = this.props.loadMoreItems || this.props.loadMoreRows, l = function(
|
|
1204
|
-
var T = i[
|
|
1204
|
+
for (var s = this, c = this.props.loadMoreItems || this.props.loadMoreRows, l = function(h) {
|
|
1205
|
+
var T = i[h], M = i[h + 1], g = c(T, M);
|
|
1205
1206
|
g != null && g.then(function() {
|
|
1206
1207
|
if (oi({
|
|
1207
1208
|
lastRenderedStartIndex: s._lastRenderedStartIndex,
|
|
1208
1209
|
lastRenderedStopIndex: s._lastRenderedStopIndex,
|
|
1209
1210
|
startIndex: T,
|
|
1210
|
-
stopIndex:
|
|
1211
|
+
stopIndex: M
|
|
1211
1212
|
})) {
|
|
1212
1213
|
if (s._listRef == null)
|
|
1213
1214
|
return;
|
|
@@ -1243,11 +1244,11 @@ const pi = /* @__PURE__ */ a("div")({
|
|
|
1243
1244
|
name: "NameContainer",
|
|
1244
1245
|
class: "nc4kck5",
|
|
1245
1246
|
propsAsIs: !1
|
|
1246
|
-
}),
|
|
1247
|
+
}), vi = /* @__PURE__ */ a("span")({
|
|
1247
1248
|
name: "Name",
|
|
1248
1249
|
class: "njsrqgr",
|
|
1249
1250
|
propsAsIs: !1
|
|
1250
|
-
}),
|
|
1251
|
+
}), Mi = () => j, yi = /* @__PURE__ */ a(Mi())({
|
|
1251
1252
|
name: "CurrentUserBadge",
|
|
1252
1253
|
class: "c17uc4zr",
|
|
1253
1254
|
propsAsIs: !0
|
|
@@ -1259,12 +1260,12 @@ const pi = /* @__PURE__ */ a("div")({
|
|
|
1259
1260
|
isCurrentUser: s,
|
|
1260
1261
|
openItemDetail: c,
|
|
1261
1262
|
style: l
|
|
1262
|
-
}) => /* @__PURE__ */
|
|
1263
|
+
}) => /* @__PURE__ */ f(pi, { onClick: c, style: l, children: [
|
|
1263
1264
|
/* @__PURE__ */ r(mi, { children: e || 0 }),
|
|
1264
|
-
/* @__PURE__ */
|
|
1265
|
+
/* @__PURE__ */ f(fi, { children: [
|
|
1265
1266
|
t ? /* @__PURE__ */ r(hi, { alt: "leaderboard-item-avatar", src: t }) : /* @__PURE__ */ r(Ii, { children: je(n || "") }),
|
|
1266
|
-
/* @__PURE__ */
|
|
1267
|
-
/* @__PURE__ */ r(
|
|
1267
|
+
/* @__PURE__ */ f(gi, { children: [
|
|
1268
|
+
/* @__PURE__ */ r(vi, { children: n || "" }),
|
|
1268
1269
|
s && /* @__PURE__ */ r(yi, { name: "icon-star" })
|
|
1269
1270
|
] })
|
|
1270
1271
|
] }),
|
|
@@ -1293,15 +1294,15 @@ const pi = /* @__PURE__ */ a("div")({
|
|
|
1293
1294
|
itemCount: e.length,
|
|
1294
1295
|
width: s,
|
|
1295
1296
|
height: c,
|
|
1296
|
-
children: ({ index:
|
|
1297
|
+
children: ({ index: d, style: h }) => /* @__PURE__ */ r(
|
|
1297
1298
|
Ni,
|
|
1298
1299
|
{
|
|
1299
|
-
style: { ...
|
|
1300
|
-
...e[
|
|
1301
|
-
openItemDetail: () => n(e[
|
|
1302
|
-
isCurrentUser: !!t && t === e[
|
|
1300
|
+
style: { ...h, maxHeight: 48 },
|
|
1301
|
+
...e[d],
|
|
1302
|
+
openItemDetail: () => n(e[d].userId),
|
|
1303
|
+
isCurrentUser: !!t && t === e[d].userId
|
|
1303
1304
|
},
|
|
1304
|
-
e[
|
|
1305
|
+
e[d].userId
|
|
1305
1306
|
)
|
|
1306
1307
|
}
|
|
1307
1308
|
) })
|
|
@@ -1371,11 +1372,11 @@ const pi = /* @__PURE__ */ a("div")({
|
|
|
1371
1372
|
name: "QuestionContent",
|
|
1372
1373
|
class: "q1uz5j1g",
|
|
1373
1374
|
propsAsIs: !1
|
|
1374
|
-
}),
|
|
1375
|
+
}), Li = /* @__PURE__ */ a("button")({
|
|
1375
1376
|
name: "PlayButton",
|
|
1376
1377
|
class: "p1pba9p1",
|
|
1377
1378
|
propsAsIs: !1
|
|
1378
|
-
}),
|
|
1379
|
+
}), Ei = {
|
|
1379
1380
|
[W.LOST]: /* @__PURE__ */ r(F, { name: "incorrectVoted" }),
|
|
1380
1381
|
[W.WON]: /* @__PURE__ */ r(F, { name: "icon-check" }),
|
|
1381
1382
|
[W.UNSET]: /* @__PURE__ */ r(F, { name: "icon-arrow" }),
|
|
@@ -1389,10 +1390,10 @@ const pi = /* @__PURE__ */ a("div")({
|
|
|
1389
1390
|
openQuestion: c,
|
|
1390
1391
|
status: l
|
|
1391
1392
|
}) => {
|
|
1392
|
-
const m = Se[t],
|
|
1393
|
-
return m ? /* @__PURE__ */
|
|
1394
|
-
/* @__PURE__ */
|
|
1395
|
-
/* @__PURE__ */
|
|
1393
|
+
const m = Se[t], d = Ei[l];
|
|
1394
|
+
return m ? /* @__PURE__ */ f(zi, { onClick: () => c == null ? void 0 : c(e), children: [
|
|
1395
|
+
/* @__PURE__ */ f($i, { children: [
|
|
1396
|
+
/* @__PURE__ */ f(xi, { children: [
|
|
1396
1397
|
/* @__PURE__ */ r(
|
|
1397
1398
|
Ci,
|
|
1398
1399
|
{
|
|
@@ -1401,14 +1402,14 @@ const pi = /* @__PURE__ */ a("div")({
|
|
|
1401
1402
|
name: m.iconName
|
|
1402
1403
|
}
|
|
1403
1404
|
),
|
|
1404
|
-
/* @__PURE__ */
|
|
1405
|
+
/* @__PURE__ */ f(bi, { children: [
|
|
1405
1406
|
m.label,
|
|
1406
|
-
t === x.TRIVIA && n ===
|
|
1407
|
+
t === x.TRIVIA && n === U.RESOLVED && " • Expired"
|
|
1407
1408
|
] })
|
|
1408
1409
|
] }),
|
|
1409
1410
|
/* @__PURE__ */ r(ji, { children: i || "" })
|
|
1410
1411
|
] }),
|
|
1411
|
-
/* @__PURE__ */ r(Oi, { children: s ? /* @__PURE__ */ r(
|
|
1412
|
+
/* @__PURE__ */ r(Oi, { children: s ? /* @__PURE__ */ r(Li, { children: "Play" }) : d })
|
|
1412
1413
|
] }) : null;
|
|
1413
1414
|
}, Qi = /* @__PURE__ */ a("div")({
|
|
1414
1415
|
name: "Container",
|
|
@@ -1422,7 +1423,7 @@ const pi = /* @__PURE__ */ a("div")({
|
|
|
1422
1423
|
openInsight: e,
|
|
1423
1424
|
questionId: t,
|
|
1424
1425
|
...n
|
|
1425
|
-
}) => /* @__PURE__ */
|
|
1426
|
+
}) => /* @__PURE__ */ f(Qi, { children: [
|
|
1426
1427
|
/* @__PURE__ */ r($e, { questionId: t, ...n }),
|
|
1427
1428
|
e && /* @__PURE__ */ r(Ui, { onClick: () => e(t), children: "View Insight" })
|
|
1428
1429
|
] }), _i = /* @__PURE__ */ a("div")({
|
|
@@ -1450,8 +1451,8 @@ const pi = /* @__PURE__ */ a("div")({
|
|
|
1450
1451
|
}, Vi = ({
|
|
1451
1452
|
gamification: e
|
|
1452
1453
|
}) => {
|
|
1453
|
-
const [t, n] =
|
|
1454
|
-
return /* @__PURE__ */
|
|
1454
|
+
const [t, n] = P(H.HOME);
|
|
1455
|
+
return /* @__PURE__ */ f("div", {
|
|
1455
1456
|
style: {
|
|
1456
1457
|
height: "100%",
|
|
1457
1458
|
display: "flex",
|
|
@@ -1466,7 +1467,7 @@ const pi = /* @__PURE__ */ a("div")({
|
|
|
1466
1467
|
activePage: t,
|
|
1467
1468
|
toggleActivePage: n
|
|
1468
1469
|
})
|
|
1469
|
-
}), t === H.HOME && /* @__PURE__ */
|
|
1470
|
+
}), t === H.HOME && /* @__PURE__ */ f(ie, {
|
|
1470
1471
|
children: [/* @__PURE__ */ r(ee, {
|
|
1471
1472
|
style: {
|
|
1472
1473
|
paddingTop: "12px"
|
|
@@ -1506,7 +1507,7 @@ const pi = /* @__PURE__ */ a("div")({
|
|
|
1506
1507
|
className: t
|
|
1507
1508
|
}) => {
|
|
1508
1509
|
const n = w(e.openedQuestion.$store), i = w(e.openedUser);
|
|
1509
|
-
return /* @__PURE__ */
|
|
1510
|
+
return /* @__PURE__ */ f($, {
|
|
1510
1511
|
children: [n && /* @__PURE__ */ r(De, {
|
|
1511
1512
|
className: t,
|
|
1512
1513
|
children: /* @__PURE__ */ r(Wn, {
|
|
@@ -1514,7 +1515,7 @@ const pi = /* @__PURE__ */ a("div")({
|
|
|
1514
1515
|
})
|
|
1515
1516
|
}), i && /* @__PURE__ */ r(De, {
|
|
1516
1517
|
className: t,
|
|
1517
|
-
children: /* @__PURE__ */
|
|
1518
|
+
children: /* @__PURE__ */ f(Bi, {
|
|
1518
1519
|
children: [/* @__PURE__ */ r(xe, {
|
|
1519
1520
|
label: "Friend's Rank",
|
|
1520
1521
|
close: e.closeUser
|