@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.
@@ -1,6 +1,6 @@
1
- import { jsxs as I, 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 P, b as Q, d as Ye, E, 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 U, { useRef as C, useState as L, useCallback as _, useEffect as Ge, useLayoutEffect as Ze, useMemo as B, createElement as Z, PureComponent as ze } from "react";
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__ */ I(Je, { children: [
31
- /* @__PURE__ */ I(Ke, { children: [
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__ */ I(lt, { children: [
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__ */ I(ut, { children: [
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
- }), Mt = /* @__PURE__ */ a("img")({
97
+ }), vt = /* @__PURE__ */ a("img")({
98
98
  name: "Avatar",
99
99
  class: "a1ldeata",
100
100
  propsAsIs: !1
101
- }), vt = /* @__PURE__ */ a("div")({
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: u,
159
- successRate: f
160
- }) => /* @__PURE__ */ I(ht, { children: [
161
- /* @__PURE__ */ r(It, { children: /* @__PURE__ */ I(gt, { children: [
162
- /* @__PURE__ */ I(kt, { children: [
163
- e && /* @__PURE__ */ r(Mt, { alt: "avatar", src: e }),
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__ */ I(vt, { children: [
166
+ /* @__PURE__ */ f(Mt, { children: [
167
167
  /* @__PURE__ */ r(yt, { children: t }),
168
- /* @__PURE__ */ I(Nt, { children: [
169
- /* @__PURE__ */ I(At, { children: [
168
+ /* @__PURE__ */ f(Nt, { children: [
169
+ /* @__PURE__ */ f(At, { children: [
170
170
  /* @__PURE__ */ r(Tt, { alt: "rank-icon", src: wt }),
171
- /* @__PURE__ */ I(Dt, { children: [
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__ */ I("div", { children: [
177
+ /* @__PURE__ */ f("div", { children: [
178
178
  "TOP ",
179
- u || 0,
179
+ d || 0,
180
180
  "%"
181
181
  ] })
182
182
  ] })
183
183
  ] })
184
184
  ] }) }),
185
- /* @__PURE__ */ I(ft, { children: [
186
- /* @__PURE__ */ I(xt, { children: [
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__ */ I(jt, { children: [
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: `${f || 0}%`, title: "Succ. rate" })
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
- }), Et = ({ title: e, description: t }) => /* @__PURE__ */ I(Ct, { children: [
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
- ] }), Lt = /* @__PURE__ */ a("div")({
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 !== P.RESOLVED)
250
+ if (!l && c !== U.RESOLVED)
251
251
  return null;
252
- const m = i === x.PREDICTION && !s, u = t ? "correct" : "incorrect", f = t ? e.correctFeedback : e.incorrectFeedback;
253
- return /* @__PURE__ */ I(Lt, { "data-isPrediction": m, children: [
254
- c === P.RESOLVED && i === x.TRIVIA && !n && /* @__PURE__ */ I($, { children: [
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__ */ I("div", { children: [
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__ */ I($, { children: [
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__ */ I($, { children: [
266
- /* @__PURE__ */ r(ce, { "data-feedbackType": u, children: /* @__PURE__ */ r(j, { name: u }) }),
267
- /* @__PURE__ */ r("div", { children: /* @__PURE__ */ I(de, { children: [
268
- /* @__PURE__ */ r(Ut, { "data-feedbackType": u, children: f == null ? void 0 : f.title }),
269
- /* @__PURE__ */ r(J, { children: f == null ? void 0 : f.description })
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
- [Q.CENTERED]: (e) => /* @__PURE__ */ r(Kt, { alt: "option-icon", src: e }),
339
- [Q.TRANSPARENT]: (e) => /* @__PURE__ */ r(Gt, { children: /* @__PURE__ */ r(Zt, { style: { backgroundImage: `url(${e})` } }) }),
340
- [Q.ROUNDED]: (e) => /* @__PURE__ */ r(en, { alt: "option-icon", src: e }),
341
- [Q.NONE]: () => null,
342
- [Q.UNSET]: () => null
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 === P.RESOLVED && n : !1, cn = (e) => {
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: u,
370
+ questionVoted: d,
371
371
  // ToDo: Figure out why imageMode is not in the response, and delete default value
372
- imageMode: f,
372
+ imageMode: h,
373
373
  answerTimeExpired: T,
374
- questionStatus: v,
374
+ questionStatus: M,
375
375
  isLoading: g,
376
376
  questionType: A,
377
377
  correct: D,
378
378
  hasCorrectAnswer: o
379
- } = e, d = an(e), p = ln({ questionType: A, questionVoted: u, correct: D, hasCorrectAnswer: o, questionStatus: v }), h = u || v === P.RESOLVED && A === x.PREDICTION;
380
- return /* @__PURE__ */ I(
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": d,
386
- disabled: u || g || T,
385
+ "data-answerState": u,
386
+ disabled: d || g || T,
387
387
  onClick: l,
388
388
  children: [
389
- h && /* @__PURE__ */ r(Bt, { "data-answerState": d, style: { width: `${c}%` } }),
390
- /* @__PURE__ */ I(Ht, { children: [
391
- i && f && ((t = ue[f]) == null ? void 0 : t.call(ue, 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
- h && /* @__PURE__ */ I(nn, { children: [
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] = L(n), u = C(0), f = C(n), T = C(n * -1e3), v = C(null), g = C(null), A = C(null), D = (p) => {
404
- let h = p / 1e3;
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 = h, v.current = requestAnimationFrame(D);
406
+ g.current = I, M.current = requestAnimationFrame(D);
407
407
  return;
408
408
  }
409
- let M = h - g.current, N = u.current + M;
410
- g.current = h, u.current = N;
411
- let y = f.current + (i === 0 ? N : (N / i | 0) * i), S = f.current + N, z = typeof t == "number" && S >= t;
412
- m(z ? t : y), z || (v.current = requestAnimationFrame(D));
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
- v.current && cancelAnimationFrame(v.current), A.current && clearTimeout(A.current), g.current = null;
415
- }, d = _((p) => {
416
- o(), u.current = 0;
417
- let h = typeof p == "number" ? p : n;
418
- f.current = h, m(h), e && (v.current = requestAnimationFrame(D));
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: h = 0, newStartAt: M } = (s == null ? void 0 : s(T.current / 1e3)) || {};
424
- p && (A.current = setTimeout(() => d(M), h * 1e3));
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 && (v.current = requestAnimationFrame(D)), o), [e, t, i]), { elapsedTime: l, reset: d };
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", u = 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: u };
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, u = s[l] - s[l + 1], f = he(i[l]), T = he(i[l + 1]), v = !!e.isGrowing;
449
- return `rgb(${f.map((g, A) => Ce(m, g, T[A] - g, u, v) | 0).join(",")})`;
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: u = !1, rotation: f = "clockwise", onComplete: T, onUpdate: v } = e, g = C(), A = Math.max(c, l ?? 0), { path: D, pathLength: o } = un(s, A, f), { elapsedTime: d } = dn({ isPlaying: m, duration: t, startAt: me(t, n), updateInterval: i, onUpdate: typeof v == "function" ? (h) => {
452
- let M = Math.ceil(t - h);
453
- M !== g.current && (g.current = M, v(M));
454
- } : void 0, onComplete: typeof T == "function" ? (h) => {
455
- var M;
456
- let { shouldRepeat: N, delay: y, newInitialRemainingTime: S } = (M = T(h)) != null ? M : {};
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 - d;
460
- return { elapsedTime: d, path: D, pathLength: o, remainingTime: Math.ceil(p), rotation: f, size: s, stroke: hn(e, p), strokeDashoffset: Ce(d, 0, o, t, u), strokeWidth: c };
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: u, remainingTime: f, elapsedTime: T, size: v, strokeWidth: g } = In(e);
463
- return U.createElement("div", { style: pn(v) }, U.createElement("svg", { viewBox: `0 0 ${v} ${v}`, width: v, height: v, xmlns: "http://www.w3.org/2000/svg" }, U.createElement("path", { d: c, fill: "none", stroke: i ?? "#d9d9d9", strokeWidth: s ?? g }), U.createElement("path", { d: c, fill: "none", stroke: m, strokeLinecap: n ?? "round", strokeWidth: g, strokeDasharray: l, strokeDashoffset: u })), typeof t == "function" && U.createElement("div", { style: mn }, t({ remainingTime: f, elapsedTime: T, color: m })));
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 = [E.PRIMARY_GREEN1, E.SECONDARY_RED1, E.SECONDARY_RED1], gn = [10, 10, 0], Mn = /* @__PURE__ */ a("div")({
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
- }), vn = E.SECONDARY_GREEN6, Ie = E.SECONDARY_RED3, yn = E.NEUTRALS_GRAY3, Nn = ({
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] = L(t > 10 ? vn : Ie), c = ({
476
- remainingTime: u
477
- }) => /* @__PURE__ */ r(Mn, {
478
- children: u
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 = _((u) => {
482
- u === 10 && s(Ie);
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__ */ I(Tn, { children: [
534
- /* @__PURE__ */ I(An, { children: [
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__ */ I($, { children: [
536
+ t !== void 0 && s !== x.POLL && /* @__PURE__ */ f($, { children: [
537
537
  /* @__PURE__ */ r(zn, { name: "icon-trophy" }),
538
- /* @__PURE__ */ I(xn, { children: [
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, vote: t, close: n }) => {
546
- var i;
547
- const s = e.subject, c = e.type, l = (i = e.options) == null ? void 0 : i.options, [m, u] = L(!1), [f, T] = L(!1), [v, g] = L(""), A = e == null ? void 0 : e.id, D = _(
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), T(!0), await t(A, y), T(!1);
551
+ g(y), await n(A, y);
552
552
  }
553
553
  },
554
- [A, g, t]
554
+ [A, g, n]
555
555
  ), o = _(() => {
556
- u(!0), setTimeout(n, 3e3);
557
- }, [n]), d = B(
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
- ), h = B(() => e ? e.answers.map((N) => {
563
+ ), I = B(() => e ? e.answers.map((N) => {
564
564
  var y;
565
565
  return {
566
566
  ...N,
567
- questionVoted: !!d,
568
- youSelected: v === N.id,
569
- isLoading: f,
567
+ questionVoted: !!u,
568
+ youSelected: M === N.id,
569
+ isLoading: t,
570
570
  hasCorrectAnswer: p,
571
571
  questionType: e.type,
572
- answerTimeExpired: m,
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, m, f, e, d, D, v]), M = l && (l.case === "trivia" || l.case === "prediction") ? l.value : void 0;
579
- return /* @__PURE__ */ r(ie, { "data-question-header": "true", children: /* @__PURE__ */ r(qt, { children: /* @__PURE__ */ I(Yt, { children: [
580
- M && /* @__PURE__ */ r(
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: M,
584
- questionVoted: !!d,
585
- questionVotedCorrectly: d == null ? void 0 : d.correct,
586
- questionType: c,
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: m ? "Time expired" : e.type === x.POLL ? "Time remaining" : "To win",
595
- points: m ? void 0 : 100,
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: !0,
599
- isPlayingTimer: !d,
600
- timerDuration: d ? 0 : 30
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
- m ? /* @__PURE__ */ r(
604
- Et,
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__ */ I($, { children: [
610
- /* @__PURE__ */ r(Wt, { "data-isPrediction": e.type === x.PREDICTION, children: s }),
611
- /* @__PURE__ */ r(Vt, { children: h.map((N) => /* @__PURE__ */ r(cn, { ...N }, N.id)) })
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
- }), En = /* @__PURE__ */ a("div")({
626
+ }), Ln = /* @__PURE__ */ a("div")({
627
627
  name: "Description",
628
628
  class: "d1i2kpk2",
629
629
  propsAsIs: !1
630
- }), Ln = /* @__PURE__ */ a("div")({
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__ */ I(Cn, { children: [
651
- s && /* @__PURE__ */ I(Ln, { children: [
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__ */ I(bn, { children: [
658
+ /* @__PURE__ */ f(bn, { children: [
659
659
  /* @__PURE__ */ r($n, { children: (i == null ? void 0 : i.heading) || n }),
660
- /* @__PURE__ */ r(En, { children: i == null ? void 0 : i.body })
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__ */ I(Qn, { children: [
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__ */ I(Un, { href: e == null ? void 0 : e.webLink.url, target: "_blank", children: [
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 !i && s ? /* @__PURE__ */ r(wn, {
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__ */ I(_n, {
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__ */ I(Fn, { "data-position": e === "home" ? "left" : "right", children: [
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 Me = Number.isNaN || function(t) {
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 || Me(e) && Me(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 = [], u = 0; u < arguments.length; u++)
800
- m[u] = arguments[u];
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", ve = Xn ? 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 = ve();
815
+ var n = Me();
815
816
  function i() {
816
- ve() - n >= t ? e.call(null) : s.id = requestAnimationFrame(i);
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, u = e.initInstanceProps, f = e.shouldResetStyleCacheOnItemSizeChange, T = e.validateProps;
846
- return t = /* @__PURE__ */ function(v) {
847
- Zn(g, v);
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 = v.call(this, D) || this, o._instanceProps = u(o.props, ge(o)), o._outerRef = void 0, o._resetIsScrollingTimeoutId = null, o.state = {
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(d, p, h, M) {
857
+ }, o._callOnItemsRendered = void 0, o._callOnItemsRendered = K(function(u, p, I, v) {
857
858
  return o.props.onItemsRendered({
858
- overscanStartIndex: d,
859
+ overscanStartIndex: u,
859
860
  overscanStopIndex: p,
860
- visibleStartIndex: h,
861
- visibleStopIndex: M
861
+ visibleStartIndex: I,
862
+ visibleStopIndex: v
862
863
  });
863
- }), o._callOnScroll = void 0, o._callOnScroll = K(function(d, p, h) {
864
+ }), o._callOnScroll = void 0, o._callOnScroll = K(function(u, p, I) {
864
865
  return o.props.onScroll({
865
- scrollDirection: d,
866
+ scrollDirection: u,
866
867
  scrollOffset: p,
867
- scrollUpdateWasRequested: h
868
+ scrollUpdateWasRequested: I
868
869
  });
869
- }), o._getItemStyle = void 0, o._getItemStyle = function(d) {
870
- var p = o.props, h = p.direction, M = p.itemSize, N = p.layout, y = o._getItemStyleCache(f && M, f && N, f && h), S;
871
- if (y.hasOwnProperty(d))
872
- S = y[d];
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, d, o._instanceProps), O = s(o.props, d, o._instanceProps), k = h === "horizontal" || N === "horizontal", q = h === "rtl", Y = k ? z : 0;
875
- y[d] = S = {
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(d, p, h) {
886
+ }, o._getItemStyleCache = void 0, o._getItemStyleCache = K(function(u, p, I) {
886
887
  return {};
887
- }), o._onScrollHorizontal = function(d) {
888
- var p = d.currentTarget, h = p.clientWidth, M = p.scrollLeft, N = p.scrollWidth;
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 === M)
891
+ if (y.scrollOffset === v)
891
892
  return null;
892
- var S = o.props.direction, z = M;
893
+ var S = o.props.direction, z = v;
893
894
  if (S === "rtl")
894
895
  switch (Te()) {
895
896
  case "negative":
896
- z = -M;
897
+ z = -v;
897
898
  break;
898
899
  case "positive-descending":
899
- z = N - h - M;
900
+ z = N - I - v;
900
901
  break;
901
902
  }
902
- return z = Math.max(0, Math.min(z, N - h)), {
903
+ return z = Math.max(0, Math.min(z, N - I)), {
903
904
  isScrolling: !0,
904
- scrollDirection: y.scrollOffset < M ? "forward" : "backward",
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(d) {
910
- var p = d.currentTarget, h = p.clientHeight, M = p.scrollHeight, N = p.scrollTop;
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, M - h));
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(d) {
923
+ }, o._outerRefSetter = function(u) {
923
924
  var p = o.props.outerRef;
924
- o._outerRef = d, typeof p == "function" ? p(d) : p != null && typeof p == "object" && p.hasOwnProperty("current") && (p.current = d);
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, d) {
936
- return si(o, d), T(o), null;
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(d) {
941
- return d.scrollOffset === o ? null : {
942
- scrollDirection: d.scrollOffset < o ? "forward" : "backward",
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, d) {
948
- d === void 0 && (d = "auto");
949
- var p = this.props, h = p.itemCount, M = p.layout, N = this.state.scrollOffset;
950
- o = Math.max(0, Math.min(o, h - 1));
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
- M === "vertical" ? y = S.scrollWidth > S.clientWidth ? Ne() : 0 : y = S.scrollHeight > S.clientHeight ? Ne() : 0;
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, d, N, this._instanceProps, y));
957
+ this.scrollTo(c(this.props, o, u, N, this._instanceProps, y));
957
958
  }, A.componentDidMount = function() {
958
- var o = this.props, d = o.direction, p = o.initialScrollOffset, h = o.layout;
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 M = this._outerRef;
961
- d === "horizontal" || h === "horizontal" ? M.scrollLeft = p : M.scrollTop = p;
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, d = o.direction, p = o.layout, h = this.state, M = h.scrollOffset, N = h.scrollUpdateWasRequested;
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 (d === "horizontal" || p === "horizontal")
969
- if (d === "rtl")
969
+ if (u === "horizontal" || p === "horizontal")
970
+ if (u === "rtl")
970
971
  switch (Te()) {
971
972
  case "negative":
972
- y.scrollLeft = -M;
973
+ y.scrollLeft = -v;
973
974
  break;
974
975
  case "positive-ascending":
975
- y.scrollLeft = M;
976
+ y.scrollLeft = v;
976
977
  break;
977
978
  default:
978
979
  var S = y.clientWidth, z = y.scrollWidth;
979
- y.scrollLeft = z - S - M;
980
+ y.scrollLeft = z - S - v;
980
981
  break;
981
982
  }
982
983
  else
983
- y.scrollLeft = M;
984
+ y.scrollLeft = v;
984
985
  else
985
- y.scrollTop = M;
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, d = o.children, p = o.className, h = o.direction, M = 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, Ee = o.outerElementType, Le = o.outerTagName, Re = o.style, Qe = o.useIsScrolling, Ue = o.width, se = this.state.isScrolling, G = h === "horizontal" || Y === "horizontal", Pe = G ? this._onScrollHorizontal : this._onScrollVertical, re = this._getRangeToRender(), _e = re[0], qe = re[1], oe = [];
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 R = _e; R <= qe; R++)
994
- oe.push(Z(d, {
994
+ for (var E = _e; E <= qe; E++)
995
+ oe.push(Z(u, {
995
996
  data: O,
996
- key: q(R, O),
997
- index: R,
997
+ key: q(E, O),
998
+ index: E,
998
999
  isScrolling: Qe ? se : void 0,
999
- style: this._getItemStyle(R)
1000
+ style: this._getItemStyle(E)
1000
1001
  }));
1001
1002
  var ae = i(this.props, this._instanceProps);
1002
- return Z(Ee || Le || "div", {
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: M,
1009
+ height: v,
1009
1010
  width: Ue,
1010
1011
  overflow: "auto",
1011
1012
  WebkitOverflowScrolling: "touch",
1012
1013
  willChange: "transform",
1013
- direction: h
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 d = this._getRangeToRender(), p = d[0], h = d[1], M = d[2], N = d[3];
1029
- this._callOnItemsRendered(p, h, M, N);
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, d = o.itemCount, p = o.overscanCount, h = this.state, M = h.isScrolling, N = h.scrollDirection, y = h.scrollOffset;
1038
- if (d === 0)
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 = !M || N === "backward" ? Math.max(1, p) : 1, k = !M || N === "forward" ? Math.max(1, p) : 1;
1041
- return [Math.max(0, S - O), Math.max(0, Math.min(d - 1, z + k)), S, z];
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, u = t.height, f = t.itemCount, T = t.itemSize, v = t.layout, g = t.width, A = m === "horizontal" || v === "horizontal", D = A ? g : u, o = Math.max(0, f * T - D), d = Math.min(o, n * T), p = Math.max(0, n * T - D + T + l);
1068
- switch (i === "smart" && (s >= p - D && s <= d + D ? i = "auto" : i = "center"), i) {
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 d;
1071
+ return u;
1071
1072
  case "end":
1072
1073
  return p;
1073
1074
  case "center": {
1074
- var h = Math.round(p + (d - p) / 2);
1075
- return h < Math.ceil(D / 2) ? 0 : h > o + Math.floor(D / 2) ? o : h;
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 <= d ? s : s < p ? p : d;
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, u = t.layout, f = t.width, T = s === "horizontal" || u === "horizontal", v = n * m, g = T ? f : c, A = Math.ceil((g + i - v) / m);
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, u = null, f = s; f <= c; f++) {
1107
- var T = t(f);
1108
- T ? u !== null && (l.push(m, u), m = u = null) : (u = f, m === null && (m = f));
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 (u !== null) {
1111
- for (var v = Math.min(Math.max(u, m + i - 1), n - 1), g = u + 1; g <= v && !t(g); g++)
1112
- u = g;
1113
- l.push(m, u);
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), u = 0; u < l; u++)
1159
- m[u] = arguments[u];
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(f) {
1161
- var T = f.visibleStartIndex, v = f.visibleStopIndex;
1162
- s._lastRenderedStartIndex = T, s._lastRenderedStopIndex = v, s._ensureRowsLoaded(T, v);
1163
- }, s._setRef = function(f) {
1164
- s._listRef = f;
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, u = c.minimumBatchSize, f = u === void 0 ? 10 : u, T = c.threshold, v = T === void 0 ? 15 : T, g = ai({
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: f,
1193
- startIndex: Math.max(0, i - v),
1194
- stopIndex: Math.min(m - 1, s + v)
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(f) {
1204
- var T = i[f], v = i[f + 1], g = c(T, v);
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: v
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
- }), Mi = /* @__PURE__ */ a("span")({
1247
+ }), vi = /* @__PURE__ */ a("span")({
1247
1248
  name: "Name",
1248
1249
  class: "njsrqgr",
1249
1250
  propsAsIs: !1
1250
- }), vi = () => j, yi = /* @__PURE__ */ a(vi())({
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__ */ I(pi, { onClick: c, style: l, children: [
1263
+ }) => /* @__PURE__ */ f(pi, { onClick: c, style: l, children: [
1263
1264
  /* @__PURE__ */ r(mi, { children: e || 0 }),
1264
- /* @__PURE__ */ I(fi, { children: [
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__ */ I(gi, { children: [
1267
- /* @__PURE__ */ r(Mi, { children: n || "" }),
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: u, style: f }) => /* @__PURE__ */ r(
1297
+ children: ({ index: d, style: h }) => /* @__PURE__ */ r(
1297
1298
  Ni,
1298
1299
  {
1299
- style: { ...f, maxHeight: 48 },
1300
- ...e[u],
1301
- openItemDetail: () => n(e[u].userId),
1302
- isCurrentUser: !!t && t === e[u].userId
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[u].userId
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
- }), Ei = /* @__PURE__ */ a("button")({
1375
+ }), Li = /* @__PURE__ */ a("button")({
1375
1376
  name: "PlayButton",
1376
1377
  class: "p1pba9p1",
1377
1378
  propsAsIs: !1
1378
- }), Li = {
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], u = Li[l];
1393
- return m ? /* @__PURE__ */ I(zi, { onClick: () => c == null ? void 0 : c(e), children: [
1394
- /* @__PURE__ */ I($i, { children: [
1395
- /* @__PURE__ */ I(xi, { children: [
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__ */ I(bi, { children: [
1405
+ /* @__PURE__ */ f(bi, { children: [
1405
1406
  m.label,
1406
- t === x.TRIVIA && n === P.RESOLVED && " • Expired"
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(Ei, { children: "Play" }) : u })
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__ */ I(Qi, { children: [
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] = L(H.HOME);
1454
- return /* @__PURE__ */ I("div", {
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__ */ I(ie, {
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__ */ I($, {
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__ */ I(Bi, {
1518
+ children: /* @__PURE__ */ f(Bi, {
1518
1519
  children: [/* @__PURE__ */ r(xe, {
1519
1520
  label: "Friend's Rank",
1520
1521
  close: e.closeUser