@streamlayer/web-os 0.4.3 → 0.4.4
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/cjs/index.js +1 -1
- package/lib/cjs/index2.js +25 -40
- package/lib/classic/cjs/classic.js +1 -1
- package/lib/classic/cjs/gamification-feature.js +1 -1
- package/lib/classic/cjs/index.js +1 -1
- package/lib/classic/cjs/index2.js +1 -10
- package/lib/classic/classic.d.ts +2 -13
- package/lib/classic/core/app/app.d.ts +16 -0
- package/lib/classic/core/app/event.d.ts +6 -0
- package/lib/classic/core/app/provider.d.ts +49 -0
- package/lib/classic/core/app/useStreamLayerApp.d.ts +23 -0
- package/lib/classic/core/index.d.ts +4 -0
- package/lib/classic/es/classic.js +78 -8
- package/lib/classic/es/gamification-feature.js +638 -2
- package/lib/classic/es/index.js +157 -10
- package/lib/classic/es/index2.js +19054 -11977
- package/lib/classic/index.d.ts +2 -13
- package/lib/classic.d.ts +2 -13
- package/lib/core/app/app.d.ts +16 -0
- package/lib/core/app/event.d.ts +6 -0
- package/lib/core/app/provider.d.ts +49 -0
- package/lib/core/app/useStreamLayerApp.d.ts +23 -0
- package/lib/core/index.d.ts +4 -0
- package/lib/es/gamification-feature.js +606 -2
- package/lib/es/index.js +2 -2
- package/lib/es/index2.js +16237 -23252
- package/lib/index.d.ts +2 -13
- package/package.json +19 -20
- package/lib/cjs/gamification-feature2.js +0 -1
- package/lib/classic/cjs/classic2.js +0 -10
- package/lib/classic/cjs/gamification-feature2.js +0 -1
- package/lib/classic/cjs/gamification-feature3.js +0 -1
- package/lib/classic/cjs/index3.js +0 -1
- package/lib/classic/es/classic2.js +0 -13037
- package/lib/classic/es/gamification-feature2.js +0 -4
- package/lib/classic/es/gamification-feature3.js +0 -643
- package/lib/classic/es/index3.js +0 -14930
- package/lib/es/gamification-feature2.js +0 -608
|
@@ -1,608 +0,0 @@
|
|
|
1
|
-
import { jsxs as i, jsx as s, Fragment as C } from "react/jsx-runtime";
|
|
2
|
-
import { t as z, e as w, f as T, a as H, b as j, A as Y, s as a, i as W, I as U, c as $, B as h, d as f, u, r as L, S as K, O as D, g as q, R as O, D as P, w as _, p as ss, h as es, l as as, j as ns, k as ls, m as ts, n as is, o as os, C as rs } from "./index2.js";
|
|
3
|
-
import "@noriginmedia/norigin-spatial-navigation";
|
|
4
|
-
import { useRef as G, useState as Z, useCallback as x, useEffect as R } from "react";
|
|
5
|
-
import "react-countdown-circle-timer";
|
|
6
|
-
import { createPortal as cs } from "react-dom";
|
|
7
|
-
import "react-countup";
|
|
8
|
-
import "nanostores";
|
|
9
|
-
import "lodash.throttle";
|
|
10
|
-
import ds from "react-infinite-scroller";
|
|
11
|
-
const ps = /* @__PURE__ */ T("CjZzdHJlYW1sYXllci9hbmFseXRpY3MvdjEvaW52aXRhdGlvbnMvaW52aXRhdGlvbnMucHJvdG8SJHN0cmVhbWxheWVyLmFuYWx5dGljcy52MS5pbnZpdGF0aW9ucyLhAgoXVG90YWxJbnZpdGF0aW9uc1JlcXVlc3QSYAoGZmlsdGVyGAEgASgLMlAuc3RyZWFtbGF5ZXIuYW5hbHl0aWNzLnYxLmludml0YXRpb25zLlRvdGFsSW52aXRhdGlvbnNSZXF1ZXN0LlRvdGFsUmVxdWVzdEZpbHRlchrjAQoSVG90YWxSZXF1ZXN0RmlsdGVyEjcKBnBlcmlvZBgBIAEoCzInLnN0cmVhbWxheWVyLmFuYWx5dGljcy52MS5jb21tb24uUGVyaW9kEhEKCWV2ZW50X2lkcxgCIAMoBBJMCgpjYXRlZ29yaWVzGAMgAygOMjguc3RyZWFtbGF5ZXIuYW5hbHl0aWNzLnYxLmludml0YXRpb25zLkludml0YXRpb25DYXRlZ29yeRIzCgRraW5kGAQgASgOMiUuc3RyZWFtbGF5ZXIuYW5hbHl0aWNzLnYxLmNvbW1vbi5LaW5kIrABChhUb3RhbEludml0YXRpb25zUmVzcG9uc2USXgoEZGF0YRgB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0dBTUVTEAQqZQoOSW52aXRhdGlvbkZyb20SGQoVSU5WSVRBVElPTl9GUk9NX1VOU0VUEAASHgoaSU5WSVRBVElPTl9GUk9NX1RJVExFX0NBUkQQARIYChRJTlZJVEFUSU9OX0ZST01fTUVOVRACQrYBCihjb20uc3RyZWFtbGF5ZXIuYW5hbHl0aWNzLmludml0YXRpb25zLnYxQhtTdHJlYW1MYXllckludml0YXRpb25zUHJvdG9QAVpiZ2l0aHViLmNvbS9zdHJlYW1sYXllci9zbC1wcm90b2ZpbGVzLy5idWlsZC9nby9zdHJlYW1sYXllci9hbmFseXRpY3MvdjEvaW52aXRhdGlvbnM7c2xfaW52aXRhdGlvbnOiAgZTTF9BUEliBnByb3RvMw", [H, j]), ms = /* @__PURE__ */ w(ps, 1), B = /* @__PURE__ */ z(ms), bs = (e, n, l) => {
|
|
12
|
-
const o = n >= Y.lg && n < Y.xl ? 75 : 52;
|
|
13
|
-
e.current && window.scrollTo({
|
|
14
|
-
top: e.current.offsetTop - o,
|
|
15
|
-
...l
|
|
16
|
-
});
|
|
17
|
-
}, us = /* @__PURE__ */ a("div")({
|
|
18
|
-
name: "Container",
|
|
19
|
-
class: "c1zy8a",
|
|
20
|
-
propsAsIs: !1
|
|
21
|
-
}), hs = /* @__PURE__ */ a("div")({
|
|
22
|
-
name: "Title",
|
|
23
|
-
class: "t1vih9p5",
|
|
24
|
-
propsAsIs: !1
|
|
25
|
-
}), As = /* @__PURE__ */ a("div")({
|
|
26
|
-
name: "Indicator",
|
|
27
|
-
class: "i1fbnvpb",
|
|
28
|
-
propsAsIs: !1
|
|
29
|
-
}), y = ({ indicator: e, title: n }) => /* @__PURE__ */ i(us, { children: [
|
|
30
|
-
/* @__PURE__ */ s(hs, { children: n }),
|
|
31
|
-
/* @__PURE__ */ s(As, { children: e })
|
|
32
|
-
] }), vs = /* @__PURE__ */ a("div")({
|
|
33
|
-
name: "Container",
|
|
34
|
-
class: "ctmhwyc",
|
|
35
|
-
propsAsIs: !1
|
|
36
|
-
}), Ws = /* @__PURE__ */ a("div")({
|
|
37
|
-
name: "Indicator",
|
|
38
|
-
class: "i1jri200",
|
|
39
|
-
propsAsIs: !1
|
|
40
|
-
}), Is = /* @__PURE__ */ a("div")({
|
|
41
|
-
name: "Title",
|
|
42
|
-
class: "t8s05oq",
|
|
43
|
-
propsAsIs: !1
|
|
44
|
-
}), I = ({ indicator: e, title: n }) => /* @__PURE__ */ i(vs, { children: [
|
|
45
|
-
/* @__PURE__ */ s(Ws, { children: e }),
|
|
46
|
-
/* @__PURE__ */ s(Is, { children: n })
|
|
47
|
-
] }), Rs = /* @__PURE__ */ a("div")({
|
|
48
|
-
name: "Container",
|
|
49
|
-
class: "c1yrpn9o",
|
|
50
|
-
propsAsIs: !1
|
|
51
|
-
}), gs = /* @__PURE__ */ a("div")({
|
|
52
|
-
name: "TopInfo",
|
|
53
|
-
class: "t17fwahh",
|
|
54
|
-
propsAsIs: !1
|
|
55
|
-
}), Vs = /* @__PURE__ */ a("div")({
|
|
56
|
-
name: "BottomInfo",
|
|
57
|
-
class: "by6w7e9",
|
|
58
|
-
propsAsIs: !1
|
|
59
|
-
}), Cs = /* @__PURE__ */ a("div")({
|
|
60
|
-
name: "User",
|
|
61
|
-
class: "u1g7arbm",
|
|
62
|
-
propsAsIs: !1
|
|
63
|
-
}), Gs = /* @__PURE__ */ a("img")({
|
|
64
|
-
name: "Avatar",
|
|
65
|
-
class: "a1ldeata",
|
|
66
|
-
propsAsIs: !1
|
|
67
|
-
}), Zs = /* @__PURE__ */ a("div")({
|
|
68
|
-
name: "UserInfo",
|
|
69
|
-
class: "u10d4koz",
|
|
70
|
-
propsAsIs: !1
|
|
71
|
-
}), Xs = /* @__PURE__ */ a("div")({
|
|
72
|
-
name: "UserName",
|
|
73
|
-
class: "u1q6roj0",
|
|
74
|
-
propsAsIs: !1
|
|
75
|
-
}), Ss = /* @__PURE__ */ a("div")({
|
|
76
|
-
name: "UserRating",
|
|
77
|
-
class: "ui0m425",
|
|
78
|
-
propsAsIs: !1
|
|
79
|
-
}), Ys = /* @__PURE__ */ a("img")({
|
|
80
|
-
name: "TrophyIcon",
|
|
81
|
-
class: "t1el3mrn",
|
|
82
|
-
propsAsIs: !1
|
|
83
|
-
}), ys = /* @__PURE__ */ a("div")({
|
|
84
|
-
name: "RtsContainer",
|
|
85
|
-
class: "r2vgnxv",
|
|
86
|
-
propsAsIs: !1
|
|
87
|
-
}), Es = /* @__PURE__ */ a("div")({
|
|
88
|
-
name: "RtsDivider",
|
|
89
|
-
class: "roqn06j",
|
|
90
|
-
propsAsIs: !1
|
|
91
|
-
}), Ns = /* @__PURE__ */ a("div")({
|
|
92
|
-
name: "Rts",
|
|
93
|
-
class: "r15adx7c",
|
|
94
|
-
propsAsIs: !1
|
|
95
|
-
}), E = /* @__PURE__ */ a("div")({
|
|
96
|
-
name: "RtsIndicator",
|
|
97
|
-
class: "rv59lta",
|
|
98
|
-
propsAsIs: !1
|
|
99
|
-
}), N = /* @__PURE__ */ a("div")({
|
|
100
|
-
name: "RtsLabel",
|
|
101
|
-
class: "r55lotb",
|
|
102
|
-
propsAsIs: !1
|
|
103
|
-
}), Fs = /* @__PURE__ */ a("div")({
|
|
104
|
-
name: "Divider",
|
|
105
|
-
class: "d1knfgqt",
|
|
106
|
-
propsAsIs: !1
|
|
107
|
-
}), ks = /* @__PURE__ */ a("div")({
|
|
108
|
-
name: "Ranks",
|
|
109
|
-
class: "r1mqo824",
|
|
110
|
-
propsAsIs: !1
|
|
111
|
-
}), Us = /* @__PURE__ */ a("div")({
|
|
112
|
-
name: "Statistics",
|
|
113
|
-
class: "sxareh6",
|
|
114
|
-
propsAsIs: !1
|
|
115
|
-
}), $s = /* @__PURE__ */ a("div")({
|
|
116
|
-
name: "AvatarPlaceholder",
|
|
117
|
-
class: "amcu48h",
|
|
118
|
-
propsAsIs: !1
|
|
119
|
-
}), fs = /* @__PURE__ */ a("button")({
|
|
120
|
-
name: "UserAccountBtn",
|
|
121
|
-
class: "u32nfkp",
|
|
122
|
-
propsAsIs: !1
|
|
123
|
-
}), Ls = "data:image/svg+xml,%3csvg%20width='16'%20height='16'%20viewBox='0%200%2016%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20id='Trophy'%3e%3cpath%20id='Combined%20Shape'%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M3.69197%204.66662C3.69197%205.99705%203.92914%207.17787%204.4035%208.20912C3.49966%208.02451%202.74487%207.66486%202.1391%207.13014C1.53333%206.59542%201.23046%206.0798%201.23046%205.58328V4.66662H3.69197ZM14.7686%204.66662V5.58328C14.7686%206.0798%2014.4658%206.59542%2013.86%207.13014C13.2542%207.66486%2012.4994%208.02451%2011.5956%208.20912C12.0699%207.17787%2012.3071%205.99705%2012.3071%204.66662H14.7686ZM15.9998%205.58329V4.36108C15.9998%204.10645%2015.9101%203.89002%2015.7306%203.71178C15.5511%203.53354%2015.3332%203.44442%2015.0768%203.44442H12.3076V2.52776C12.3076%202.10763%2012.1569%201.74797%2011.8556%201.44878C11.5544%201.14959%2011.1922%201%2010.7691%201H5.23072C4.80764%201%204.44547%201.14959%204.14419%201.44878C3.84291%201.74797%203.69227%202.10763%203.69227%202.52776V3.44442H0.923068C0.666659%203.44442%200.448714%203.53354%200.269228%203.71178C0.0897418%203.89002%200%204.10645%200%204.36108V5.58329C0%206.03525%200.13301%206.49039%200.399034%206.94872C0.665059%207.40705%201.02403%207.82082%201.47595%208.19003C1.92787%208.55924%202.48234%208.86957%203.13939%209.12101C3.79644%209.37246%204.48713%209.51409%205.21149%209.54592C5.48071%209.88967%205.7852%2010.192%206.12494%2010.453C6.36853%2010.6695%206.53679%2010.9002%206.62974%2011.1453C6.72269%2011.3904%206.76916%2011.6752%206.76916%2011.9999C6.76916%2012.3436%206.67141%2012.6333%206.4759%2012.8688C6.28038%2013.1043%205.96789%2013.2221%205.53841%2013.2221C5.05764%2013.2221%204.62976%2013.3669%204.25476%2013.6566C3.87977%2013.9462%203.69227%2014.3106%203.69227%2014.7499V15.361C3.69227%2015.4501%203.72112%2015.5233%203.77881%2015.5806C3.8365%2015.6379%203.91022%2015.6665%203.99996%2015.6665H11.9999C12.0896%2015.6665%2012.1633%2015.6379%2012.221%2015.5806C12.2787%2015.5233%2012.3076%2015.4501%2012.3076%2015.361V14.7499C12.3076%2014.3106%2012.1201%2013.9462%2011.7451%2013.6566C11.3701%2013.3669%2010.9422%2013.2221%2010.4614%2013.2221C10.0319%2013.2221%209.71945%2013.1043%209.52394%2012.8688C9.32843%2012.6333%209.23068%2012.3436%209.23068%2011.9999C9.23068%2011.6752%209.27715%2011.3904%209.3701%2011.1453C9.46305%2010.9002%209.63131%2010.6695%209.8749%2010.453C10.2146%2010.192%2010.5191%209.88967%2010.7884%209.54592C11.5127%209.51409%2012.2034%209.37246%2012.8604%209.12101C13.5175%208.86957%2014.072%208.55924%2014.5239%208.19003C14.9758%207.82082%2015.3348%207.40705%2015.6008%206.94872C15.8668%206.49039%2015.9998%206.03525%2015.9998%205.58329ZM6.76047%207.1798L8.05109%206.49997L9.3417%207.1798L9.09521%205.73989L10.1393%204.72015L8.69639%204.51007L8.05109%203.2L7.40578%204.51007L5.96283%204.72015L7.00696%205.73989L6.76047%207.1798Z'%20fill='%23F2C94C'/%3e%3c/g%3e%3c/svg%3e", xs = ({
|
|
124
|
-
loading: e,
|
|
125
|
-
hideFriendsRank: n,
|
|
126
|
-
avatar: l,
|
|
127
|
-
name: o,
|
|
128
|
-
points: t,
|
|
129
|
-
friendsRank: r,
|
|
130
|
-
rank: d,
|
|
131
|
-
streak: p,
|
|
132
|
-
correct: c,
|
|
133
|
-
incorrect: m,
|
|
134
|
-
inTop: b,
|
|
135
|
-
successRate: g
|
|
136
|
-
}) => /* @__PURE__ */ i(Rs, { "data-loading": e, children: [
|
|
137
|
-
/* @__PURE__ */ s(gs, { children: /* @__PURE__ */ s(W, { loading: e, children: /* @__PURE__ */ i(Cs, { children: [
|
|
138
|
-
/* @__PURE__ */ i(fs, { children: [
|
|
139
|
-
l && /* @__PURE__ */ s(Gs, { alt: "avatar", src: l }),
|
|
140
|
-
!l && /* @__PURE__ */ s($s, { children: U(o || "") })
|
|
141
|
-
] }),
|
|
142
|
-
/* @__PURE__ */ i(Zs, { children: [
|
|
143
|
-
/* @__PURE__ */ s(Xs, { children: o }),
|
|
144
|
-
/* @__PURE__ */ i(Ss, { children: [
|
|
145
|
-
/* @__PURE__ */ i(ys, { children: [
|
|
146
|
-
/* @__PURE__ */ i(Ns, { children: [
|
|
147
|
-
/* @__PURE__ */ s(Ys, { alt: "rank-icon", src: Ls }),
|
|
148
|
-
/* @__PURE__ */ i(E, { children: [
|
|
149
|
-
$(t),
|
|
150
|
-
/* @__PURE__ */ s(N, { children: "PTS" })
|
|
151
|
-
] })
|
|
152
|
-
] }),
|
|
153
|
-
n && /* @__PURE__ */ i(E, { children: [
|
|
154
|
-
/* @__PURE__ */ s(Es, {}),
|
|
155
|
-
d || 0,
|
|
156
|
-
/* @__PURE__ */ s(N, { children: "global rank" })
|
|
157
|
-
] })
|
|
158
|
-
] }),
|
|
159
|
-
!n && /* @__PURE__ */ i(C, { children: [
|
|
160
|
-
/* @__PURE__ */ s(Fs, {}),
|
|
161
|
-
/* @__PURE__ */ i("div", { children: [
|
|
162
|
-
"TOP ",
|
|
163
|
-
b || 0,
|
|
164
|
-
"%"
|
|
165
|
-
] })
|
|
166
|
-
] })
|
|
167
|
-
] })
|
|
168
|
-
] })
|
|
169
|
-
] }) }) }),
|
|
170
|
-
/* @__PURE__ */ i(Vs, { children: [
|
|
171
|
-
!n && /* @__PURE__ */ i(ks, { children: [
|
|
172
|
-
/* @__PURE__ */ s(W, { loading: e, style: { width: "100%" }, children: /* @__PURE__ */ s(y, { indicator: r || 0, title: "Friends rank" }) }),
|
|
173
|
-
/* @__PURE__ */ s(W, { loading: e, style: { width: "100%" }, children: /* @__PURE__ */ s(y, { indicator: d || 0, title: "Global rank" }) })
|
|
174
|
-
] }),
|
|
175
|
-
/* @__PURE__ */ s(W, { loading: e, children: /* @__PURE__ */ i(Us, { children: [
|
|
176
|
-
/* @__PURE__ */ s(I, { indicator: p || 0, title: "Win streak" }),
|
|
177
|
-
/* @__PURE__ */ s(I, { indicator: c || 0, title: "Correct" }),
|
|
178
|
-
/* @__PURE__ */ s(I, { indicator: m || 0, title: "Incorrect" }),
|
|
179
|
-
/* @__PURE__ */ s(I, { indicator: `${g || 0}%`, title: "Succ. rate" })
|
|
180
|
-
] }) })
|
|
181
|
-
] })
|
|
182
|
-
] }), Bs = /* @__PURE__ */ a("div")({
|
|
183
|
-
name: "Container",
|
|
184
|
-
class: "c115qtkr",
|
|
185
|
-
propsAsIs: !1
|
|
186
|
-
}), Js = /* @__PURE__ */ a("div")({
|
|
187
|
-
name: "STabs",
|
|
188
|
-
class: "sxnslc8",
|
|
189
|
-
propsAsIs: !1
|
|
190
|
-
}), Qs = /* @__PURE__ */ a("button")({
|
|
191
|
-
name: "Button",
|
|
192
|
-
class: "b1umzux0",
|
|
193
|
-
propsAsIs: !1
|
|
194
|
-
}), Ms = /* @__PURE__ */ a("span")({
|
|
195
|
-
name: "Title",
|
|
196
|
-
class: "tspsaas",
|
|
197
|
-
propsAsIs: !1
|
|
198
|
-
});
|
|
199
|
-
var v = /* @__PURE__ */ ((e) => (e.HOME = "home", e.LEADERBOARD = "leaderboard", e))(v || {});
|
|
200
|
-
const F = ({ title: e, active: n, onClick: l }) => /* @__PURE__ */ s(Qs, { "data-a": "intr", onClick: l, "data-selected": n, children: /* @__PURE__ */ s(Ms, { "data-a": "intr", children: e }) }), zs = ({ activePage: e = "home", toggleActivePage: n }) => /* @__PURE__ */ s(Bs, { children: /* @__PURE__ */ i(Js, { "data-position": e === "home" ? "left" : "right", children: [
|
|
201
|
-
/* @__PURE__ */ s(F, { title: "Home", active: e === "home", onClick: () => n(
|
|
202
|
-
"home"
|
|
203
|
-
/* HOME */
|
|
204
|
-
) }),
|
|
205
|
-
/* @__PURE__ */ s(
|
|
206
|
-
F,
|
|
207
|
-
{
|
|
208
|
-
title: "Friends",
|
|
209
|
-
active: e === "leaderboard",
|
|
210
|
-
onClick: () => n(
|
|
211
|
-
"leaderboard"
|
|
212
|
-
/* LEADERBOARD */
|
|
213
|
-
)
|
|
214
|
-
}
|
|
215
|
-
)
|
|
216
|
-
] }) }), ws = /* @__PURE__ */ a("button")({
|
|
217
|
-
name: "Container",
|
|
218
|
-
class: "cpjnajb",
|
|
219
|
-
propsAsIs: !1
|
|
220
|
-
}), Ts = /* @__PURE__ */ a("div")({
|
|
221
|
-
name: "Content",
|
|
222
|
-
class: "c4m6kaz",
|
|
223
|
-
propsAsIs: !1
|
|
224
|
-
}), Hs = /* @__PURE__ */ a("span")({
|
|
225
|
-
name: "Title",
|
|
226
|
-
class: "t1h8t9cc",
|
|
227
|
-
propsAsIs: !1
|
|
228
|
-
}), js = () => /* @__PURE__ */ s(ws, { children: /* @__PURE__ */ i(Ts, { children: [
|
|
229
|
-
/* @__PURE__ */ s(h, { name: "iconCopySuccess" }),
|
|
230
|
-
/* @__PURE__ */ s(Hs, { children: "Link Copied to Clipboard" })
|
|
231
|
-
] }) }), J = (e) => {
|
|
232
|
-
const n = G(), [l, o] = Z(null), t = x(
|
|
233
|
-
async (r) => {
|
|
234
|
-
var d;
|
|
235
|
-
if (r && (d = navigator == null ? void 0 : navigator.clipboard) != null && d.writeText) {
|
|
236
|
-
n.current && (clearTimeout(n.current), o(null));
|
|
237
|
-
try {
|
|
238
|
-
await navigator.clipboard.writeText(r), e.current && (o(cs(/* @__PURE__ */ s(js, {}), e.current)), n.current = setTimeout(() => {
|
|
239
|
-
o(null);
|
|
240
|
-
}, 1e3));
|
|
241
|
-
} catch (p) {
|
|
242
|
-
console.error("Unable to copy to clipboard", p);
|
|
243
|
-
}
|
|
244
|
-
}
|
|
245
|
-
},
|
|
246
|
-
[e]
|
|
247
|
-
);
|
|
248
|
-
return R(() => () => {
|
|
249
|
-
clearTimeout(n.current);
|
|
250
|
-
}, []), [t, l];
|
|
251
|
-
}, Ks = /* @__PURE__ */ a("div")({
|
|
252
|
-
name: "Container",
|
|
253
|
-
class: "c1ux29ft",
|
|
254
|
-
propsAsIs: !1
|
|
255
|
-
}), Ds = () => h, qs = /* @__PURE__ */ a(Ds())({
|
|
256
|
-
name: "FriendsIcon",
|
|
257
|
-
class: "f10ncfg2",
|
|
258
|
-
propsAsIs: !0
|
|
259
|
-
}), Os = /* @__PURE__ */ a("div")({
|
|
260
|
-
name: "Content",
|
|
261
|
-
class: "c1yc07bd",
|
|
262
|
-
propsAsIs: !1
|
|
263
|
-
}), Ps = /* @__PURE__ */ a("div")({
|
|
264
|
-
name: "Title",
|
|
265
|
-
class: "tj6cq7w",
|
|
266
|
-
propsAsIs: !1
|
|
267
|
-
}), _s = /* @__PURE__ */ a("div")({
|
|
268
|
-
name: "Description",
|
|
269
|
-
class: "d1ag78xo",
|
|
270
|
-
propsAsIs: !1
|
|
271
|
-
}), se = () => h, ee = /* @__PURE__ */ a(se())({
|
|
272
|
-
name: "ArrowInviteIcon",
|
|
273
|
-
class: "awohrz6",
|
|
274
|
-
propsAsIs: !0
|
|
275
|
-
}), ae = ({ title: e, description: n, onClick: l, className: o }) => {
|
|
276
|
-
const [t] = f({
|
|
277
|
-
type: "invitation",
|
|
278
|
-
action: "sent",
|
|
279
|
-
payload: {
|
|
280
|
-
from: B.TITLE_CARD
|
|
281
|
-
}
|
|
282
|
-
});
|
|
283
|
-
return /* @__PURE__ */ i(Ks, { "data-a": "intr", onClick: t(l), className: o, children: [
|
|
284
|
-
/* @__PURE__ */ s(qs, { name: "icon-friends" }),
|
|
285
|
-
/* @__PURE__ */ i(Os, { children: [
|
|
286
|
-
/* @__PURE__ */ s(Ps, { children: e }),
|
|
287
|
-
/* @__PURE__ */ s(_s, { children: n })
|
|
288
|
-
] }),
|
|
289
|
-
/* @__PURE__ */ s(ee, { name: "icon-copy" })
|
|
290
|
-
] });
|
|
291
|
-
}, ne = /* @__PURE__ */ a("div")({
|
|
292
|
-
name: "Container",
|
|
293
|
-
class: "culdu4a",
|
|
294
|
-
propsAsIs: !1
|
|
295
|
-
}), le = /* @__PURE__ */ a("div")({
|
|
296
|
-
name: "Position",
|
|
297
|
-
class: "pwf8e69",
|
|
298
|
-
propsAsIs: !1
|
|
299
|
-
}), te = /* @__PURE__ */ a("img")({
|
|
300
|
-
name: "Avatar",
|
|
301
|
-
class: "atf4yh4",
|
|
302
|
-
propsAsIs: !1
|
|
303
|
-
}), ie = /* @__PURE__ */ a("div")({
|
|
304
|
-
name: "AvatarPlaceholder",
|
|
305
|
-
class: "a1dg29ja",
|
|
306
|
-
propsAsIs: !1
|
|
307
|
-
}), oe = /* @__PURE__ */ a("div")({
|
|
308
|
-
name: "Content",
|
|
309
|
-
class: "c10a68rc",
|
|
310
|
-
propsAsIs: !1
|
|
311
|
-
}), re = /* @__PURE__ */ a("div")({
|
|
312
|
-
name: "NameContainer",
|
|
313
|
-
class: "nc4kck5",
|
|
314
|
-
propsAsIs: !1
|
|
315
|
-
}), ce = /* @__PURE__ */ a("span")({
|
|
316
|
-
name: "Name",
|
|
317
|
-
class: "njsrqgr",
|
|
318
|
-
propsAsIs: !1
|
|
319
|
-
}), de = () => h, pe = /* @__PURE__ */ a(de())({
|
|
320
|
-
name: "CurrentUserBadge",
|
|
321
|
-
class: "c17uc4zr",
|
|
322
|
-
propsAsIs: !0
|
|
323
|
-
}), me = ({
|
|
324
|
-
friendsRank: e,
|
|
325
|
-
avatar: n,
|
|
326
|
-
name: l,
|
|
327
|
-
userId: o,
|
|
328
|
-
points: t,
|
|
329
|
-
isCurrentUser: r,
|
|
330
|
-
style: d
|
|
331
|
-
}) => /* @__PURE__ */ i(ne, { "data-name": o, style: d, children: [
|
|
332
|
-
/* @__PURE__ */ s(le, { children: e || 0 }),
|
|
333
|
-
/* @__PURE__ */ i(oe, { children: [
|
|
334
|
-
n ? /* @__PURE__ */ s(te, { alt: "leaderboard-item-avatar", src: n }) : /* @__PURE__ */ s(ie, { children: U(l || "") }),
|
|
335
|
-
/* @__PURE__ */ i(re, { children: [
|
|
336
|
-
/* @__PURE__ */ s(ce, { children: l || "" }),
|
|
337
|
-
r && /* @__PURE__ */ s(pe, { name: "icon-star" })
|
|
338
|
-
] })
|
|
339
|
-
] }),
|
|
340
|
-
/* @__PURE__ */ s("div", { children: $(t) })
|
|
341
|
-
] }), be = /* @__PURE__ */ a("div")({
|
|
342
|
-
name: "Container",
|
|
343
|
-
class: "c16btbfp",
|
|
344
|
-
propsAsIs: !1
|
|
345
|
-
}), ue = ({
|
|
346
|
-
items: e,
|
|
347
|
-
currentUserId: n,
|
|
348
|
-
openItemDetail: l,
|
|
349
|
-
fetchMore: o,
|
|
350
|
-
scrollNode: t,
|
|
351
|
-
hasMore: r
|
|
352
|
-
}) => {
|
|
353
|
-
const d = x((p) => {
|
|
354
|
-
const c = p.target.getAttribute("data-name");
|
|
355
|
-
c && l(c);
|
|
356
|
-
}, [l]);
|
|
357
|
-
return /* @__PURE__ */ s(ds, {
|
|
358
|
-
loadMore: o,
|
|
359
|
-
initialLoad: !1,
|
|
360
|
-
hasMore: r,
|
|
361
|
-
useWindow: !1,
|
|
362
|
-
getScrollParent: () => t.current,
|
|
363
|
-
children: /* @__PURE__ */ s(be, {
|
|
364
|
-
"data-a": "intr",
|
|
365
|
-
onClick: d,
|
|
366
|
-
children: e.map((p) => /* @__PURE__ */ s(me, {
|
|
367
|
-
...p,
|
|
368
|
-
isCurrentUser: !!n && n === p.userId
|
|
369
|
-
}, p.userId))
|
|
370
|
-
})
|
|
371
|
-
});
|
|
372
|
-
}, he = /* @__PURE__ */ a("div")({
|
|
373
|
-
name: "Container",
|
|
374
|
-
class: "c1itm4k7",
|
|
375
|
-
propsAsIs: !1
|
|
376
|
-
}), Ae = /* @__PURE__ */ a("div")({
|
|
377
|
-
name: "IconContainer",
|
|
378
|
-
class: "i1w4fsni",
|
|
379
|
-
propsAsIs: !1
|
|
380
|
-
}), ve = () => h, We = /* @__PURE__ */ a(ve())({
|
|
381
|
-
name: "InviteGameIcon",
|
|
382
|
-
class: "i19m85r1",
|
|
383
|
-
propsAsIs: !0
|
|
384
|
-
}), Ie = /* @__PURE__ */ a("div")({
|
|
385
|
-
name: "Content",
|
|
386
|
-
class: "c1mbu204",
|
|
387
|
-
propsAsIs: !1
|
|
388
|
-
}), Re = /* @__PURE__ */ a("div")({
|
|
389
|
-
name: "Heading",
|
|
390
|
-
class: "h1amdqtv",
|
|
391
|
-
propsAsIs: !1
|
|
392
|
-
}), ge = /* @__PURE__ */ a("div")({
|
|
393
|
-
name: "Subtext",
|
|
394
|
-
class: "s1lhlj9j",
|
|
395
|
-
propsAsIs: !1
|
|
396
|
-
}), Ve = /* @__PURE__ */ a("div")({
|
|
397
|
-
name: "LinkContainer",
|
|
398
|
-
class: "l1wot35e",
|
|
399
|
-
propsAsIs: !1
|
|
400
|
-
}), Ce = /* @__PURE__ */ a("div")({
|
|
401
|
-
name: "LinkInfo",
|
|
402
|
-
class: "l1jdw39q",
|
|
403
|
-
propsAsIs: !1
|
|
404
|
-
}), Ge = /* @__PURE__ */ a("span")({
|
|
405
|
-
name: "LinkTitle",
|
|
406
|
-
class: "l1cr5mk",
|
|
407
|
-
propsAsIs: !1
|
|
408
|
-
}), Ze = /* @__PURE__ */ a("span")({
|
|
409
|
-
name: "LinkAddress",
|
|
410
|
-
class: "lvi87q4",
|
|
411
|
-
propsAsIs: !1
|
|
412
|
-
}), Xe = () => h, Se = /* @__PURE__ */ a(Xe())({
|
|
413
|
-
name: "LinkIcon",
|
|
414
|
-
class: "l1pqlvw3",
|
|
415
|
-
propsAsIs: !0
|
|
416
|
-
}), Ye = ({
|
|
417
|
-
inviteLink: e,
|
|
418
|
-
inviteCardTitle: n,
|
|
419
|
-
inviteCardSubtext: l,
|
|
420
|
-
primaryColor: o,
|
|
421
|
-
className: t
|
|
422
|
-
}) => {
|
|
423
|
-
const r = G(null), [d, p] = J(r), [c] = f({
|
|
424
|
-
type: "invitation",
|
|
425
|
-
action: "sent",
|
|
426
|
-
payload: {
|
|
427
|
-
from: B.MENU
|
|
428
|
-
}
|
|
429
|
-
});
|
|
430
|
-
return /* @__PURE__ */ i(he, { className: t, children: [
|
|
431
|
-
/* @__PURE__ */ s(Ae, { style: { backgroundColor: o }, children: /* @__PURE__ */ s(We, { name: "invite-game-icon" }) }),
|
|
432
|
-
/* @__PURE__ */ i(Ie, { children: [
|
|
433
|
-
/* @__PURE__ */ s(Re, { children: n || "" }),
|
|
434
|
-
/* @__PURE__ */ s(ge, { children: l || "" })
|
|
435
|
-
] }),
|
|
436
|
-
e && /* @__PURE__ */ i(Ve, { ref: r, "data-a": "intr", onClick: c(() => d(e)), children: [
|
|
437
|
-
/* @__PURE__ */ i(Ce, { children: [
|
|
438
|
-
/* @__PURE__ */ s(Ge, { children: "Invite link" }),
|
|
439
|
-
/* @__PURE__ */ s(Ze, { children: e })
|
|
440
|
-
] }),
|
|
441
|
-
/* @__PURE__ */ s(Se, { name: "icon-copy" })
|
|
442
|
-
] }),
|
|
443
|
-
p
|
|
444
|
-
] });
|
|
445
|
-
}, ye = /* @__PURE__ */ a("div")({
|
|
446
|
-
name: "InviteFriendsContainer",
|
|
447
|
-
class: "i1c9dygq",
|
|
448
|
-
propsAsIs: !1
|
|
449
|
-
}), Ee = ({
|
|
450
|
-
deepLink: e
|
|
451
|
-
}) => /* @__PURE__ */ s(ye, {
|
|
452
|
-
children: /* @__PURE__ */ s(Ye, {
|
|
453
|
-
inviteLink: e,
|
|
454
|
-
inviteCardTitle: "It’s More Fun With Friends",
|
|
455
|
-
inviteCardSubtext: "Invite and compete against your friends for the top spot on the leaderboard."
|
|
456
|
-
})
|
|
457
|
-
}), Ne = /* @__PURE__ */ a("div")({
|
|
458
|
-
name: "InviteLinkContainer",
|
|
459
|
-
class: "i1odbhm4",
|
|
460
|
-
propsAsIs: !1
|
|
461
|
-
}), Fe = ({
|
|
462
|
-
gamification: e,
|
|
463
|
-
scrollNode: n,
|
|
464
|
-
scrollStore: l
|
|
465
|
-
}) => {
|
|
466
|
-
const o = G(null), {
|
|
467
|
-
data: t,
|
|
468
|
-
hasMore: r,
|
|
469
|
-
loading: d,
|
|
470
|
-
key: p
|
|
471
|
-
} = u(e.leaderboardList.$store), {
|
|
472
|
-
data: c
|
|
473
|
-
} = u(e.deepLink.$store), [m, b] = J(o);
|
|
474
|
-
return !t.length && !d ? /* @__PURE__ */ s(Ee, {
|
|
475
|
-
deepLink: c
|
|
476
|
-
}) : /* @__PURE__ */ i(C, {
|
|
477
|
-
children: [/* @__PURE__ */ s(ue, {
|
|
478
|
-
items: t,
|
|
479
|
-
scrollNode: n,
|
|
480
|
-
scrollStore: l,
|
|
481
|
-
fetchMore: e.leaderboardList.fetchMore,
|
|
482
|
-
hasMore: r,
|
|
483
|
-
openItemDetail: e.openUser,
|
|
484
|
-
currentUserId: e.currentUserId.get()
|
|
485
|
-
}, p), c && /* @__PURE__ */ s(Ne, {
|
|
486
|
-
ref: o,
|
|
487
|
-
children: /* @__PURE__ */ s(ae, {
|
|
488
|
-
"data-a": "intr",
|
|
489
|
-
onClick: () => m(c),
|
|
490
|
-
title: "Invite Friends",
|
|
491
|
-
description: "Challenge them now!"
|
|
492
|
-
})
|
|
493
|
-
}), b]
|
|
494
|
-
});
|
|
495
|
-
}, ke = () => L, Ue = /* @__PURE__ */ a(ke())({
|
|
496
|
-
name: "Container",
|
|
497
|
-
class: "cll3md7",
|
|
498
|
-
propsAsIs: !0
|
|
499
|
-
}), $e = () => K, fe = /* @__PURE__ */ a($e())({
|
|
500
|
-
name: "ActionBtn",
|
|
501
|
-
class: "a10g1iik",
|
|
502
|
-
propsAsIs: !0
|
|
503
|
-
}), Le = ({ questionId: e, ...n }) => /* @__PURE__ */ i(Ue, { "data-a": "intr", "data-name": e, children: [
|
|
504
|
-
/* @__PURE__ */ s(D, { questionId: e, ...n }),
|
|
505
|
-
/* @__PURE__ */ s(fe, { "data-a": "intr", "data-name": e, children: "View Insight" })
|
|
506
|
-
] }), xe = () => L, Be = /* @__PURE__ */ a(xe())({
|
|
507
|
-
name: "Container",
|
|
508
|
-
class: "cl56x6b",
|
|
509
|
-
propsAsIs: !0
|
|
510
|
-
}), Je = /* @__PURE__ */ a("button")({
|
|
511
|
-
name: "ActionButton",
|
|
512
|
-
class: "a11pzf92",
|
|
513
|
-
propsAsIs: !1
|
|
514
|
-
}), Qe = /* @__PURE__ */ a("blockquote")({
|
|
515
|
-
name: "Quote",
|
|
516
|
-
class: "q1hbaleq",
|
|
517
|
-
propsAsIs: !1
|
|
518
|
-
}), Me = ({ ...e }) => /* @__PURE__ */ i(Be, { "data-a": "intr", "data-name": e.tweetId, children: [
|
|
519
|
-
e.title && /* @__PURE__ */ s(Qe, { children: e.title }),
|
|
520
|
-
/* @__PURE__ */ s(q, { ...e }),
|
|
521
|
-
/* @__PURE__ */ s(Je, { "data-a": "intr", "data-name": e.tweetId, children: "View Insight" })
|
|
522
|
-
] }), k = /* @__PURE__ */ a("div")({
|
|
523
|
-
name: "QuestionsContainer",
|
|
524
|
-
class: "qvghv3l",
|
|
525
|
-
propsAsIs: !1
|
|
526
|
-
}), ze = ({ questions: e, openQuestion: n, controlVideo: l }) => e ? /* @__PURE__ */ s(k, { "data-a": "intr", onClick: (t) => {
|
|
527
|
-
const r = t.target.getAttribute("data-name");
|
|
528
|
-
r && (_(), n(r, { openedFrom: "list" }));
|
|
529
|
-
}, children: e == null ? void 0 : e.map((t) => {
|
|
530
|
-
var r, d, p;
|
|
531
|
-
if (t.type === "question" && ((r = t.attributes) == null ? void 0 : r.attributes.case) === "question") {
|
|
532
|
-
const c = t.attributes.attributes.value;
|
|
533
|
-
return /* @__PURE__ */ s(O, { ...c }, c.questionId);
|
|
534
|
-
}
|
|
535
|
-
if (t.type === "insight" && ((d = t.attributes) == null ? void 0 : d.attributes.case) === "insight") {
|
|
536
|
-
const c = t.attributes.attributes.value;
|
|
537
|
-
return /* @__PURE__ */ s(Le, { controlVideo: l, ...c }, c.questionId);
|
|
538
|
-
}
|
|
539
|
-
if (t.type === "tweet" && ((p = t.attributes) == null ? void 0 : p.attributes.case) === "tweet") {
|
|
540
|
-
const c = t.attributes.attributes.value, m = t.attributes.id;
|
|
541
|
-
return /* @__PURE__ */ s(Me, { controlVideo: l, ...c, tweetId: m }, m);
|
|
542
|
-
}
|
|
543
|
-
return null;
|
|
544
|
-
}) }) : /* @__PURE__ */ s(k, { children: Array.from({ length: 5 }).map((t, r) => /* @__PURE__ */ s(P, {}, r)) }), we = ({ store: e, openQuestion: n }) => {
|
|
545
|
-
const { sdk: l } = ss(), o = u(e);
|
|
546
|
-
return /* @__PURE__ */ s(ze, { openQuestion: n, questions: o.data, controlVideo: l == null ? void 0 : l.controlVideoPlayer });
|
|
547
|
-
}, Te = ({ userSummary: e }) => {
|
|
548
|
-
var n;
|
|
549
|
-
const [l, o] = Z(void 0);
|
|
550
|
-
return R(() => {
|
|
551
|
-
const t = e.$store.subscribe((r) => {
|
|
552
|
-
r && o(r);
|
|
553
|
-
});
|
|
554
|
-
return () => {
|
|
555
|
-
t();
|
|
556
|
-
};
|
|
557
|
-
}, [e]), /* @__PURE__ */ s(xs, { loading: !(l != null && l.summary), ...l == null ? void 0 : l.summary, successRate: (n = l == null ? void 0 : l.percentage) == null ? void 0 : n.correct });
|
|
558
|
-
}, He = ({ gamification: e, className: n, scrollStore: l, scrollNode: o, appNode: t, style: r, responsiveStore: d }) => {
|
|
559
|
-
const { tabsShown: p } = u(l, { keys: ["tabsShown"] }), c = u(e.friendsTabEnabled), [m, b] = Z(v.HOME), [, g] = es(), { sdkInDesktopView: X, screen: Q } = u(d, { keys: ["sdkInDesktopView"] }), M = (A) => {
|
|
560
|
-
g(() => {
|
|
561
|
-
var S;
|
|
562
|
-
b(A), X === !1 && (((S = t.current) == null ? void 0 : S.getBoundingClientRect().y) || 0) < 0 && bs(t, Q.size, { behavior: "instant" });
|
|
563
|
-
});
|
|
564
|
-
};
|
|
565
|
-
R(() => l.subscribe((A) => {
|
|
566
|
-
if (A.scrollPosition === 0) {
|
|
567
|
-
l.setKey("tabsShown", !0);
|
|
568
|
-
return;
|
|
569
|
-
}
|
|
570
|
-
d.get().sdkInDesktopView ? l.setKey("tabsShown", A.scrollDirection === "backward") : l.setKey("tabsShown", A.scrollDirection === "forward");
|
|
571
|
-
}), [l, d]), R(() => {
|
|
572
|
-
c || b(v.HOME);
|
|
573
|
-
}, [c]);
|
|
574
|
-
let V = "0px";
|
|
575
|
-
return X ? V = p ? "0px" : "calc(0px - var(--header-height))" : V = p ? "var(--header-height)" : "0px", /* @__PURE__ */ i(as, { className: ns(n, "SL-Tabs", "sl-hide-on-modal"), style: r, children: [
|
|
576
|
-
c && /* @__PURE__ */ s(
|
|
577
|
-
ls,
|
|
578
|
-
{
|
|
579
|
-
style: {
|
|
580
|
-
top: V
|
|
581
|
-
},
|
|
582
|
-
children: /* @__PURE__ */ s(zs, { activePage: m, toggleActivePage: M })
|
|
583
|
-
}
|
|
584
|
-
),
|
|
585
|
-
m === v.HOME && /* @__PURE__ */ i(C, { children: [
|
|
586
|
-
/* @__PURE__ */ s(ts, { children: /* @__PURE__ */ s(is, { children: /* @__PURE__ */ s(Te, { userSummary: e.userSummary }) }) }),
|
|
587
|
-
/* @__PURE__ */ s(os, { style: { flex: 1 }, children: /* @__PURE__ */ s(we, { openQuestion: e.openQuestion, store: e.feedList.getStore() }) })
|
|
588
|
-
] }),
|
|
589
|
-
m === v.LEADERBOARD && /* @__PURE__ */ s(rs, { children: /* @__PURE__ */ s(Fe, { scrollStore: l, scrollNode: o, gamification: e }) })
|
|
590
|
-
] });
|
|
591
|
-
}, na = ({
|
|
592
|
-
gamification: e,
|
|
593
|
-
scrollStore: n,
|
|
594
|
-
className: l,
|
|
595
|
-
appNode: o,
|
|
596
|
-
scrollNode: t,
|
|
597
|
-
responsiveStore: r
|
|
598
|
-
}) => /* @__PURE__ */ s(He, {
|
|
599
|
-
appNode: o,
|
|
600
|
-
scrollStore: n,
|
|
601
|
-
scrollNode: t,
|
|
602
|
-
className: l,
|
|
603
|
-
gamification: e,
|
|
604
|
-
responsiveStore: r
|
|
605
|
-
});
|
|
606
|
-
export {
|
|
607
|
-
na as default
|
|
608
|
-
};
|