@streamlayer/react 0.32.4 → 0.32.6
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/masters2.js +2 -2
- package/lib/dist/cjs/gamification-feature.js +1 -1
- package/lib/dist/cjs/masters.js +14 -14
- package/lib/dist/es/gamification-feature.js +360 -353
- package/lib/dist/es/masters.js +3306 -3187
- package/lib/dist/index.d.ts +1 -0
- package/lib/dist/style.css +1 -1
- package/lib/es/gamification-feature.js +391 -384
- package/lib/es/masters2.js +1295 -1185
- package/lib/style.css +1 -1
- package/package.json +6 -6
package/lib/es/masters2.js
CHANGED
|
@@ -1,121 +1,121 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { d as
|
|
3
|
-
import { lazy as
|
|
4
|
-
import { FeatureType as
|
|
5
|
-
import { useStore as
|
|
6
|
-
import { FeatureStatus as
|
|
7
|
-
import { s as h, n as z, c as
|
|
8
|
-
import { NotificationType as
|
|
9
|
-
const
|
|
10
|
-
const m =
|
|
11
|
-
return g != null && g.loading ? /* @__PURE__ */
|
|
12
|
-
},
|
|
1
|
+
import { jsx as c, jsxs as I, Fragment as ie } from "react/jsx-runtime";
|
|
2
|
+
import { d as Ze, S as Wt, a as jt, b as Ht, s as Yt } from "./index2.js";
|
|
3
|
+
import { lazy as Vt, useMemo as Ue, Suspense as Qt, useRef as ye, useState as W, useEffect as X, Component as Kt, createElement as Xt, useCallback as ve, useLayoutEffect as Jt, useContext as Zt } from "react";
|
|
4
|
+
import { FeatureType as ze, QuestionType as D } from "@streamlayer/sdk-web-types";
|
|
5
|
+
import { useStore as re } from "@nanostores/react";
|
|
6
|
+
import { FeatureStatus as me } from "@streamlayer/sdk-web-interfaces";
|
|
7
|
+
import { s as h, n as z, c as wt } from "./index4.js";
|
|
8
|
+
import { NotificationType as Ae } from "@streamlayer/sdk-web-notifications";
|
|
9
|
+
const ei = ({ feature: s, sdk: n, children: l, className: f }) => {
|
|
10
|
+
const m = re(s.status), g = re(n.sdkStore.slStreamId);
|
|
11
|
+
return g != null && g.loading ? /* @__PURE__ */ c("div", { className: f, children: "event is loading..." }) : g != null && g.data ? m !== me.Ready ? /* @__PURE__ */ c("div", { className: f, children: "wait feature..." }) : l : /* @__PURE__ */ c("div", { className: f, children: "event is forbidden..." });
|
|
12
|
+
}, ti = Vt(() => import("./gamification-feature.js")), ii = ({
|
|
13
13
|
sdk: s,
|
|
14
14
|
feature: n,
|
|
15
|
-
className:
|
|
15
|
+
className: l
|
|
16
16
|
}) => {
|
|
17
|
-
const
|
|
18
|
-
return /* @__PURE__ */
|
|
19
|
-
|
|
17
|
+
const f = Ue(() => n && n.featureConfig.get().type === ze.GAMES ? /* @__PURE__ */ c(ei, { className: l, sdk: s, feature: n, children: /* @__PURE__ */ c(ti, { className: l, gamification: n, sdk: s }) }) : null, [s, n, l]);
|
|
18
|
+
return /* @__PURE__ */ c(
|
|
19
|
+
Qt,
|
|
20
20
|
{
|
|
21
|
-
fallback: /* @__PURE__ */
|
|
22
|
-
children:
|
|
21
|
+
fallback: /* @__PURE__ */ c("div", { style: { display: "flex", alignItems: "center", justifyContent: "center", width: "100%", height: "100%" }, children: "page loading..." }),
|
|
22
|
+
children: f
|
|
23
23
|
}
|
|
24
24
|
);
|
|
25
|
-
},
|
|
25
|
+
}, ri = /* @__PURE__ */ h("button")({
|
|
26
26
|
name: "SButton",
|
|
27
27
|
class: "sxxa0c",
|
|
28
28
|
propsAsIs: !1
|
|
29
|
-
}),
|
|
29
|
+
}), ni = /* @__PURE__ */ h("span")({
|
|
30
30
|
name: "ButtonIcon",
|
|
31
31
|
class: "b193dcyu",
|
|
32
32
|
propsAsIs: !1
|
|
33
|
-
}),
|
|
33
|
+
}), si = /* @__PURE__ */ h("span")({
|
|
34
34
|
name: "ButtonLabel",
|
|
35
35
|
class: "b40tuix",
|
|
36
36
|
propsAsIs: !1
|
|
37
|
-
}),
|
|
38
|
-
m && /* @__PURE__ */
|
|
39
|
-
/* @__PURE__ */
|
|
40
|
-
] }) }),
|
|
37
|
+
}), Oe = ({ disabled: s, active: n, onClick: l, label: f, icon: m }) => /* @__PURE__ */ c(ri, { onClick: l, disabled: s, "data-selected": n, children: /* @__PURE__ */ I(ie, { children: [
|
|
38
|
+
m && /* @__PURE__ */ c(ni, { children: m }),
|
|
39
|
+
/* @__PURE__ */ c(si, { children: f })
|
|
40
|
+
] }) }), oi = () => z, ai = /* @__PURE__ */ h(oi())({
|
|
41
41
|
name: "ButtonIcon",
|
|
42
42
|
class: "b1whzxvd",
|
|
43
43
|
propsAsIs: !0
|
|
44
|
-
}),
|
|
44
|
+
}), de = "channels", li = (s) => {
|
|
45
45
|
var n;
|
|
46
|
-
return /* @__PURE__ */
|
|
46
|
+
return /* @__PURE__ */ c(Oe, {
|
|
47
47
|
...s,
|
|
48
48
|
id: "channels",
|
|
49
49
|
label: "Channels",
|
|
50
|
-
icon: /* @__PURE__ */
|
|
50
|
+
icon: /* @__PURE__ */ c(ai, {
|
|
51
51
|
name: "icon-btn-channels",
|
|
52
52
|
"data-selected": (n = s.active) == null ? void 0 : n.toString()
|
|
53
53
|
})
|
|
54
54
|
});
|
|
55
|
-
},
|
|
55
|
+
}, ci = () => z, ui = /* @__PURE__ */ h(ci())({
|
|
56
56
|
name: "ButtonIcon",
|
|
57
57
|
class: "b11des7c",
|
|
58
58
|
propsAsIs: !0
|
|
59
|
-
}), ee = "featuredGroups",
|
|
59
|
+
}), ee = "featuredGroups", hi = (s) => {
|
|
60
60
|
var n;
|
|
61
|
-
return /* @__PURE__ */
|
|
61
|
+
return /* @__PURE__ */ c(Oe, {
|
|
62
62
|
...s,
|
|
63
63
|
label: "FG+",
|
|
64
64
|
id: "featuredGroups",
|
|
65
|
-
icon: /* @__PURE__ */
|
|
65
|
+
icon: /* @__PURE__ */ c(ui, {
|
|
66
66
|
name: "icon-btn-feature-groups",
|
|
67
67
|
"data-selected": (n = s.active) == null ? void 0 : n.toString()
|
|
68
68
|
})
|
|
69
69
|
});
|
|
70
|
-
},
|
|
70
|
+
}, di = () => z, pi = /* @__PURE__ */ h(di())({
|
|
71
71
|
name: "ButtonIcon",
|
|
72
72
|
class: "b180jd7l",
|
|
73
73
|
propsAsIs: !0
|
|
74
|
-
}),
|
|
74
|
+
}), be = "leaderboard", fi = (s) => {
|
|
75
75
|
var n;
|
|
76
|
-
return /* @__PURE__ */
|
|
76
|
+
return /* @__PURE__ */ c(Oe, {
|
|
77
77
|
...s,
|
|
78
78
|
label: "Leader Board",
|
|
79
79
|
id: "leaderboard",
|
|
80
|
-
icon: /* @__PURE__ */
|
|
80
|
+
icon: /* @__PURE__ */ c(pi, {
|
|
81
81
|
name: "icon-btn-leaderboard",
|
|
82
82
|
"data-selected": (n = s.active) == null ? void 0 : n.toString()
|
|
83
83
|
})
|
|
84
84
|
});
|
|
85
|
-
},
|
|
85
|
+
}, mi = /* @__PURE__ */ h("div")({
|
|
86
86
|
name: "Buttons",
|
|
87
87
|
class: "b6tbwuy",
|
|
88
88
|
propsAsIs: !1
|
|
89
|
-
}),
|
|
89
|
+
}), gi = ({
|
|
90
90
|
children: s,
|
|
91
91
|
className: n
|
|
92
|
-
}) => /* @__PURE__ */
|
|
92
|
+
}) => /* @__PURE__ */ c(mi, {
|
|
93
93
|
className: n,
|
|
94
94
|
children: s
|
|
95
|
-
}),
|
|
95
|
+
}), yi = () => gi, wi = /* @__PURE__ */ h(yi())({
|
|
96
96
|
name: "Navigation",
|
|
97
97
|
class: "n19lpak2",
|
|
98
98
|
propsAsIs: !0
|
|
99
|
-
}),
|
|
100
|
-
/* @__PURE__ */
|
|
101
|
-
/* @__PURE__ */
|
|
102
|
-
|
|
99
|
+
}), Ii = ({ activeOverlay: s, setActiveOverlay: n, sdkReady: l, className: f }) => /* @__PURE__ */ I(wi, { className: f, children: [
|
|
100
|
+
/* @__PURE__ */ c(li, { active: s === de, onClick: () => n(de) }),
|
|
101
|
+
/* @__PURE__ */ c(
|
|
102
|
+
hi,
|
|
103
103
|
{
|
|
104
104
|
active: s === ee,
|
|
105
|
-
disabled: !
|
|
105
|
+
disabled: !l,
|
|
106
106
|
onClick: () => {
|
|
107
107
|
n(ee);
|
|
108
108
|
}
|
|
109
109
|
}
|
|
110
110
|
),
|
|
111
|
-
/* @__PURE__ */
|
|
112
|
-
|
|
111
|
+
/* @__PURE__ */ c(
|
|
112
|
+
fi,
|
|
113
113
|
{
|
|
114
|
-
active: s ===
|
|
115
|
-
onClick: () => n(
|
|
114
|
+
active: s === be,
|
|
115
|
+
onClick: () => n(be)
|
|
116
116
|
}
|
|
117
117
|
)
|
|
118
|
-
] }),
|
|
118
|
+
] }), Ai = {
|
|
119
119
|
[D.TWEET]: { label: "Insight", iconName: "icon-insight" },
|
|
120
120
|
[D.PROMOTION]: { label: "Insight", iconName: "icon-insight" },
|
|
121
121
|
[D.UNSET]: void 0,
|
|
@@ -123,82 +123,219 @@ const Kt = ({ feature: s, sdk: n, children: c, className: d }) => {
|
|
|
123
123
|
[D.POLL]: { label: "Poll", iconName: "icon-poll" },
|
|
124
124
|
[D.TRIVIA]: { label: "Trivia", iconName: "icon-trivia" },
|
|
125
125
|
[D.PREDICTION]: { label: "Prediction", iconName: "icon-prediction" }
|
|
126
|
-
},
|
|
126
|
+
}, xi = /* @__PURE__ */ h("div")({
|
|
127
127
|
name: "Container",
|
|
128
128
|
class: "c1bgb86j",
|
|
129
129
|
propsAsIs: !1
|
|
130
|
-
}),
|
|
130
|
+
}), vi = /* @__PURE__ */ h("video")({
|
|
131
131
|
name: "Player",
|
|
132
132
|
class: "p6703cq",
|
|
133
133
|
propsAsIs: !1
|
|
134
|
-
}),
|
|
134
|
+
}), bi = /* @__PURE__ */ h("img")({
|
|
135
135
|
name: "Poster",
|
|
136
136
|
class: "p12ow7zo",
|
|
137
137
|
propsAsIs: !1
|
|
138
|
-
}),
|
|
138
|
+
}), Ei = /* @__PURE__ */ h("div")({
|
|
139
139
|
name: "Control",
|
|
140
140
|
class: "cdpal9o",
|
|
141
141
|
propsAsIs: !1
|
|
142
|
-
}),
|
|
143
|
-
const
|
|
144
|
-
return /* @__PURE__ */ I(
|
|
145
|
-
const o =
|
|
146
|
-
o && m((w) => w ? (o.pause(), !1) : (o.play(),
|
|
142
|
+
}), Bi = ({ poster: s, source: n }) => {
|
|
143
|
+
const l = ye(null), [f, m] = W(!1), [g, d] = W(!0);
|
|
144
|
+
return /* @__PURE__ */ I(xi, { onClick: () => {
|
|
145
|
+
const o = l == null ? void 0 : l.current;
|
|
146
|
+
o && m((w) => w ? (o.pause(), !1) : (o.play(), d(!1), !0));
|
|
147
147
|
}, children: [
|
|
148
|
-
/* @__PURE__ */
|
|
149
|
-
|
|
148
|
+
/* @__PURE__ */ c(
|
|
149
|
+
vi,
|
|
150
150
|
{
|
|
151
|
-
ref:
|
|
151
|
+
ref: l,
|
|
152
152
|
src: n,
|
|
153
153
|
onEnded: () => {
|
|
154
154
|
var o;
|
|
155
|
-
(o =
|
|
155
|
+
(o = l == null ? void 0 : l.current) == null || o.load(), m(!1), d(!0);
|
|
156
156
|
},
|
|
157
157
|
style: { visibility: g ? "hidden" : "visible" }
|
|
158
158
|
}
|
|
159
159
|
),
|
|
160
|
-
/* @__PURE__ */
|
|
161
|
-
/* @__PURE__ */
|
|
160
|
+
/* @__PURE__ */ c(bi, { src: s, style: { visibility: g ? "visible" : "hidden" } }),
|
|
161
|
+
/* @__PURE__ */ c(Ei, { children: !f && /* @__PURE__ */ c(z, { name: "icon-play" }) })
|
|
162
162
|
] });
|
|
163
|
-
},
|
|
163
|
+
}, _i = /* @__PURE__ */ h("div")({
|
|
164
164
|
name: "InsightContainer",
|
|
165
165
|
class: "i1pqqgpo",
|
|
166
166
|
propsAsIs: !1
|
|
167
|
-
}),
|
|
167
|
+
}), Ci = /* @__PURE__ */ h("img")({
|
|
168
168
|
name: "Image",
|
|
169
169
|
class: "igj7luu",
|
|
170
170
|
propsAsIs: !1
|
|
171
|
-
}),
|
|
171
|
+
}), Ti = /* @__PURE__ */ h("div")({
|
|
172
172
|
name: "InsightContent",
|
|
173
173
|
class: "i1qne9g6",
|
|
174
174
|
propsAsIs: !1
|
|
175
|
-
}),
|
|
175
|
+
}), Fi = /* @__PURE__ */ h("h3")({
|
|
176
176
|
name: "Title",
|
|
177
177
|
class: "ttpr98r",
|
|
178
178
|
propsAsIs: !1
|
|
179
|
-
}),
|
|
179
|
+
}), $i = /* @__PURE__ */ h("div")({
|
|
180
180
|
name: "Description",
|
|
181
181
|
class: "d17iaqp8",
|
|
182
182
|
propsAsIs: !1
|
|
183
|
-
}),
|
|
183
|
+
}), ki = /* @__PURE__ */ h("button")({
|
|
184
184
|
name: "ActionBtn",
|
|
185
185
|
class: "a16t3y7s",
|
|
186
186
|
propsAsIs: !1
|
|
187
|
-
}),
|
|
187
|
+
}), Si = ({
|
|
188
188
|
video: s,
|
|
189
189
|
image: n,
|
|
190
|
-
heading:
|
|
191
|
-
body:
|
|
190
|
+
heading: l,
|
|
191
|
+
body: f,
|
|
192
192
|
action: m
|
|
193
|
-
}) => /* @__PURE__ */ I(
|
|
194
|
-
(s == null ? void 0 : s.url) && /* @__PURE__ */
|
|
195
|
-
n && /* @__PURE__ */
|
|
196
|
-
/* @__PURE__ */ I(
|
|
197
|
-
/* @__PURE__ */
|
|
198
|
-
/* @__PURE__ */
|
|
199
|
-
m && /* @__PURE__ */
|
|
193
|
+
}) => /* @__PURE__ */ I(_i, { children: [
|
|
194
|
+
(s == null ? void 0 : s.url) && /* @__PURE__ */ c(Bi, { source: s.url, poster: s.thumbnailUrl }),
|
|
195
|
+
n && !(s != null && s.url) && /* @__PURE__ */ c(Ci, { src: n }),
|
|
196
|
+
/* @__PURE__ */ I(Ti, { children: [
|
|
197
|
+
/* @__PURE__ */ c(Fi, { children: l }),
|
|
198
|
+
/* @__PURE__ */ c($i, { children: f }),
|
|
199
|
+
m && /* @__PURE__ */ c(ki, { onClick: m, children: "View Insight" })
|
|
200
200
|
] })
|
|
201
|
-
] }),
|
|
201
|
+
] }), Li = /* @__PURE__ */ h("div")({
|
|
202
|
+
name: "Container",
|
|
203
|
+
class: "c1eptrjd",
|
|
204
|
+
propsAsIs: !1
|
|
205
|
+
}), Ri = /* @__PURE__ */ h("div")({
|
|
206
|
+
name: "CloseIconWrap",
|
|
207
|
+
class: "crylm65",
|
|
208
|
+
propsAsIs: !1
|
|
209
|
+
}), Ni = () => z, Ui = /* @__PURE__ */ h(Ni())({
|
|
210
|
+
name: "CloseIcon",
|
|
211
|
+
class: "c9mrcz7",
|
|
212
|
+
propsAsIs: !0
|
|
213
|
+
}), zi = /* @__PURE__ */ h("div")({
|
|
214
|
+
name: "Header",
|
|
215
|
+
class: "hw3lzv4",
|
|
216
|
+
propsAsIs: !1
|
|
217
|
+
}), Oi = () => z, Di = /* @__PURE__ */ h(Oi())({
|
|
218
|
+
name: "TypeIcon",
|
|
219
|
+
class: "t1rrb3kf",
|
|
220
|
+
propsAsIs: !0
|
|
221
|
+
}), Pi = /* @__PURE__ */ h("span")({
|
|
222
|
+
name: "TypeName",
|
|
223
|
+
class: "t1ydnjov",
|
|
224
|
+
propsAsIs: !1
|
|
225
|
+
}), Mi = /* @__PURE__ */ h("div")({
|
|
226
|
+
name: "Question",
|
|
227
|
+
class: "qlf90cl",
|
|
228
|
+
propsAsIs: !1
|
|
229
|
+
}), qi = /* @__PURE__ */ h("button")({
|
|
230
|
+
name: "AnswerButton",
|
|
231
|
+
class: "a1e0nhcl",
|
|
232
|
+
propsAsIs: !1
|
|
233
|
+
}), Gi = /* @__PURE__ */ h("div")({
|
|
234
|
+
name: "Container",
|
|
235
|
+
class: "cjq447q",
|
|
236
|
+
propsAsIs: !1
|
|
237
|
+
}), Wi = /* @__PURE__ */ h("div")({
|
|
238
|
+
name: "ImageContainer",
|
|
239
|
+
class: "i14egogb",
|
|
240
|
+
propsAsIs: !1
|
|
241
|
+
}), ji = /* @__PURE__ */ h("img")({
|
|
242
|
+
name: "Image",
|
|
243
|
+
class: "i2g9g4l",
|
|
244
|
+
propsAsIs: !1
|
|
245
|
+
}), Hi = /* @__PURE__ */ h("div")({
|
|
246
|
+
name: "Details",
|
|
247
|
+
class: "d1c454nm",
|
|
248
|
+
propsAsIs: !1
|
|
249
|
+
}), Yi = /* @__PURE__ */ h("div")({
|
|
250
|
+
name: "Name",
|
|
251
|
+
class: "n11nigc3",
|
|
252
|
+
propsAsIs: !1
|
|
253
|
+
}), Vi = /* @__PURE__ */ h("div")({
|
|
254
|
+
name: "UserName",
|
|
255
|
+
class: "urxa4k8",
|
|
256
|
+
propsAsIs: !1
|
|
257
|
+
}), Qi = ({ image: s, name: n, userName: l, verified: f }) => /* @__PURE__ */ I(Gi, { children: [
|
|
258
|
+
/* @__PURE__ */ c(Wi, { children: /* @__PURE__ */ c(ji, { src: s }) }),
|
|
259
|
+
/* @__PURE__ */ I(Hi, { children: [
|
|
260
|
+
/* @__PURE__ */ I(Yi, { children: [
|
|
261
|
+
n,
|
|
262
|
+
" ",
|
|
263
|
+
f && /* @__PURE__ */ c(z, { name: "icon-twitter-verified" })
|
|
264
|
+
] }),
|
|
265
|
+
/* @__PURE__ */ c(Vi, { children: l })
|
|
266
|
+
] })
|
|
267
|
+
] }), Ki = /* @__PURE__ */ h("div")({
|
|
268
|
+
name: "Container",
|
|
269
|
+
class: "c1t4f0x4",
|
|
270
|
+
propsAsIs: !1
|
|
271
|
+
}), Xi = /* @__PURE__ */ h("button")({
|
|
272
|
+
name: "ActionBtn",
|
|
273
|
+
class: "a16w1nl6",
|
|
274
|
+
propsAsIs: !1
|
|
275
|
+
}), Ji = /* @__PURE__ */ h("div")({
|
|
276
|
+
name: "Body",
|
|
277
|
+
class: "b14u54rf",
|
|
278
|
+
propsAsIs: !1
|
|
279
|
+
}), Zi = /* @__PURE__ */ h("img")({
|
|
280
|
+
name: "Image",
|
|
281
|
+
class: "i1hxm6zo",
|
|
282
|
+
propsAsIs: !1
|
|
283
|
+
}), er = /* @__PURE__ */ h("div")({
|
|
284
|
+
name: "Details",
|
|
285
|
+
class: "d1s19yop",
|
|
286
|
+
propsAsIs: !1
|
|
287
|
+
}), tr = /* @__PURE__ */ h("div")({
|
|
288
|
+
name: "QuoteWrap",
|
|
289
|
+
class: "q1qyx94r",
|
|
290
|
+
propsAsIs: !1
|
|
291
|
+
}), ir = /* @__PURE__ */ h("blockquote")({
|
|
292
|
+
name: "Quote",
|
|
293
|
+
class: "qs97clu",
|
|
294
|
+
propsAsIs: !1
|
|
295
|
+
}), rr = ({
|
|
296
|
+
account: s,
|
|
297
|
+
body: n,
|
|
298
|
+
image: l,
|
|
299
|
+
title: f,
|
|
300
|
+
action: m
|
|
301
|
+
}) => /* @__PURE__ */ I(Ki, { children: [
|
|
302
|
+
/* @__PURE__ */ c(tr, { children: /* @__PURE__ */ c(ir, { children: f }) }),
|
|
303
|
+
/* @__PURE__ */ I(er, { children: [
|
|
304
|
+
/* @__PURE__ */ c(Qi, { ...s }),
|
|
305
|
+
/* @__PURE__ */ c(Ji, { children: n }),
|
|
306
|
+
l && /* @__PURE__ */ c(Zi, { src: l })
|
|
307
|
+
] }),
|
|
308
|
+
m && /* @__PURE__ */ c(Xi, { onClick: m, children: "View Tweet" })
|
|
309
|
+
] }), et = ({
|
|
310
|
+
close: s,
|
|
311
|
+
action: n,
|
|
312
|
+
data: { questionType: l, question: f, insight: m, tweet: g }
|
|
313
|
+
}) => {
|
|
314
|
+
const d = Ai[l];
|
|
315
|
+
return d ? /* @__PURE__ */ I(Li, { children: [
|
|
316
|
+
/* @__PURE__ */ c(Ri, { onClick: s, children: /* @__PURE__ */ c(Ui, { name: "icon-cross" }) }),
|
|
317
|
+
l !== D.TWEET && /* @__PURE__ */ I(zi, { children: [
|
|
318
|
+
/* @__PURE__ */ c(
|
|
319
|
+
Di,
|
|
320
|
+
{
|
|
321
|
+
"data-type-trivia": l === D.TRIVIA,
|
|
322
|
+
"data-type-poll": l === D.POLL,
|
|
323
|
+
name: d.iconName
|
|
324
|
+
}
|
|
325
|
+
),
|
|
326
|
+
/* @__PURE__ */ c(Pi, { children: d.label })
|
|
327
|
+
] }),
|
|
328
|
+
l === D.FACTOID && /* @__PURE__ */ c(Si, { ...m, action: n }),
|
|
329
|
+
l === D.TWEET && // ToDo: connect with real Api data
|
|
330
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
331
|
+
// @ts-ignore
|
|
332
|
+
/* @__PURE__ */ c(rr, { ...g, action: n }),
|
|
333
|
+
l !== D.FACTOID && l !== D.TWEET && /* @__PURE__ */ I(ie, { children: [
|
|
334
|
+
/* @__PURE__ */ c(Mi, { children: f == null ? void 0 : f.title }),
|
|
335
|
+
/* @__PURE__ */ c(qi, { onClick: n, children: "Answer" })
|
|
336
|
+
] })
|
|
337
|
+
] }) : null;
|
|
338
|
+
}, oe = /* @__PURE__ */ h("div")({
|
|
202
339
|
name: "BGWrap",
|
|
203
340
|
class: "b1dqe0sz",
|
|
204
341
|
propsAsIs: !1
|
|
@@ -206,414 +343,320 @@ const Kt = ({ feature: s, sdk: n, children: c, className: d }) => {
|
|
|
206
343
|
name: "BGLineBase",
|
|
207
344
|
class: "b1v6w7ni",
|
|
208
345
|
propsAsIs: !1
|
|
209
|
-
}),
|
|
346
|
+
}), nr = () => P, sr = /* @__PURE__ */ h(nr())({
|
|
210
347
|
name: "BGOneLineOne",
|
|
211
348
|
class: "b2nqb1p",
|
|
212
349
|
propsAsIs: !0
|
|
213
|
-
}),
|
|
350
|
+
}), or = () => P, ar = /* @__PURE__ */ h(or())({
|
|
214
351
|
name: "BGOneLineTwo",
|
|
215
352
|
class: "b1xxgmbk",
|
|
216
353
|
propsAsIs: !0
|
|
217
|
-
}),
|
|
354
|
+
}), lr = () => P, cr = /* @__PURE__ */ h(lr())({
|
|
218
355
|
name: "BGOneLineThree",
|
|
219
356
|
class: "b63lwcb",
|
|
220
357
|
propsAsIs: !0
|
|
221
|
-
}),
|
|
358
|
+
}), ur = () => P, tt = /* @__PURE__ */ h(ur())({
|
|
222
359
|
name: "BGTwoLineOne",
|
|
223
360
|
class: "b2iah4",
|
|
224
361
|
propsAsIs: !0
|
|
225
|
-
}),
|
|
362
|
+
}), hr = () => P, it = /* @__PURE__ */ h(hr())({
|
|
226
363
|
name: "BGTwoLineTwo",
|
|
227
364
|
class: "b1xezvf6",
|
|
228
365
|
propsAsIs: !0
|
|
229
|
-
}),
|
|
366
|
+
}), dr = () => P, rt = /* @__PURE__ */ h(dr())({
|
|
230
367
|
name: "BGTwoLineThree",
|
|
231
368
|
class: "b1jz1hg0",
|
|
232
369
|
propsAsIs: !0
|
|
233
|
-
}),
|
|
370
|
+
}), pr = () => P, nt = /* @__PURE__ */ h(pr())({
|
|
234
371
|
name: "BGThreeLineOne",
|
|
235
372
|
class: "b18ho1tk",
|
|
236
373
|
propsAsIs: !0
|
|
237
|
-
}),
|
|
374
|
+
}), fr = () => P, st = /* @__PURE__ */ h(fr())({
|
|
238
375
|
name: "BGThreeLineTwo",
|
|
239
376
|
class: "b14uvjfm",
|
|
240
377
|
propsAsIs: !0
|
|
241
|
-
}),
|
|
378
|
+
}), mr = () => P, ot = /* @__PURE__ */ h(mr())({
|
|
242
379
|
name: "BGThreeLineThree",
|
|
243
380
|
class: "b11c3ns7",
|
|
244
381
|
propsAsIs: !0
|
|
245
|
-
}),
|
|
382
|
+
}), gr = () => P, at = /* @__PURE__ */ h(gr())({
|
|
246
383
|
name: "BGThreeLineFour",
|
|
247
384
|
class: "b1bqhhet",
|
|
248
385
|
propsAsIs: !0
|
|
249
|
-
}),
|
|
386
|
+
}), yr = () => P, wr = /* @__PURE__ */ h(yr())({
|
|
250
387
|
name: "BGFourLineOne",
|
|
251
388
|
class: "b1xyzi7o",
|
|
252
389
|
propsAsIs: !0
|
|
253
|
-
}),
|
|
390
|
+
}), Ir = () => P, Ar = /* @__PURE__ */ h(Ir())({
|
|
254
391
|
name: "BGFourLineTwo",
|
|
255
392
|
class: "byo0rup",
|
|
256
393
|
propsAsIs: !0
|
|
257
|
-
}),
|
|
394
|
+
}), xr = () => P, vr = /* @__PURE__ */ h(xr())({
|
|
258
395
|
name: "BGFourLineThree",
|
|
259
396
|
class: "b1oyiqgv",
|
|
260
397
|
propsAsIs: !0
|
|
261
|
-
}),
|
|
398
|
+
}), br = () => P, Er = /* @__PURE__ */ h(br())({
|
|
262
399
|
name: "BGFourLineFour",
|
|
263
400
|
class: "bx3ddqw",
|
|
264
401
|
propsAsIs: !0
|
|
265
|
-
}),
|
|
266
|
-
/* @__PURE__ */ I(
|
|
267
|
-
/* @__PURE__ */
|
|
268
|
-
/* @__PURE__ */
|
|
269
|
-
/* @__PURE__ */
|
|
402
|
+
}), Br = ({ step: s, correct: n }) => /* @__PURE__ */ I(ie, { children: [
|
|
403
|
+
/* @__PURE__ */ I(oe, { "data-active": s === 1, "data-first-screen": "true", children: [
|
|
404
|
+
/* @__PURE__ */ c(sr, {}),
|
|
405
|
+
/* @__PURE__ */ c(ar, {}),
|
|
406
|
+
/* @__PURE__ */ c(cr, {})
|
|
270
407
|
] }),
|
|
271
|
-
/* @__PURE__ */ I(
|
|
272
|
-
/* @__PURE__ */
|
|
273
|
-
/* @__PURE__ */
|
|
274
|
-
/* @__PURE__ */
|
|
408
|
+
/* @__PURE__ */ I(oe, { "data-active": s === 2, children: [
|
|
409
|
+
/* @__PURE__ */ c(tt, {}),
|
|
410
|
+
/* @__PURE__ */ c(it, {}),
|
|
411
|
+
/* @__PURE__ */ c(rt, {})
|
|
275
412
|
] }),
|
|
276
|
-
/* @__PURE__ */ I(
|
|
277
|
-
/* @__PURE__ */
|
|
278
|
-
/* @__PURE__ */
|
|
279
|
-
/* @__PURE__ */
|
|
413
|
+
/* @__PURE__ */ I(oe, { "data-active": s === 3, children: [
|
|
414
|
+
/* @__PURE__ */ c(tt, {}),
|
|
415
|
+
/* @__PURE__ */ c(it, {}),
|
|
416
|
+
/* @__PURE__ */ c(rt, {})
|
|
280
417
|
] }),
|
|
281
|
-
n ? /* @__PURE__ */ I(
|
|
282
|
-
/* @__PURE__ */ I(
|
|
283
|
-
/* @__PURE__ */
|
|
284
|
-
/* @__PURE__ */
|
|
285
|
-
/* @__PURE__ */
|
|
286
|
-
/* @__PURE__ */
|
|
418
|
+
n ? /* @__PURE__ */ I(ie, { children: [
|
|
419
|
+
/* @__PURE__ */ I(oe, { "data-active": s === 4, "data-correct": "false", children: [
|
|
420
|
+
/* @__PURE__ */ c(nt, {}),
|
|
421
|
+
/* @__PURE__ */ c(st, {}),
|
|
422
|
+
/* @__PURE__ */ c(ot, {}),
|
|
423
|
+
/* @__PURE__ */ c(at, {})
|
|
287
424
|
] }),
|
|
288
|
-
/* @__PURE__ */ I(
|
|
289
|
-
/* @__PURE__ */
|
|
290
|
-
/* @__PURE__ */
|
|
291
|
-
/* @__PURE__ */
|
|
292
|
-
/* @__PURE__ */
|
|
425
|
+
/* @__PURE__ */ I(oe, { "data-active": s === 5, "data-correct": "false", "data-last-screen": "true", children: [
|
|
426
|
+
/* @__PURE__ */ c(nt, {}),
|
|
427
|
+
/* @__PURE__ */ c(st, {}),
|
|
428
|
+
/* @__PURE__ */ c(ot, {}),
|
|
429
|
+
/* @__PURE__ */ c(at, {})
|
|
293
430
|
] })
|
|
294
|
-
] }) : /* @__PURE__ */ I(
|
|
295
|
-
/* @__PURE__ */
|
|
296
|
-
/* @__PURE__ */
|
|
297
|
-
/* @__PURE__ */
|
|
298
|
-
/* @__PURE__ */
|
|
431
|
+
] }) : /* @__PURE__ */ I(oe, { "data-active": s === 4, "data-correct": "false", "data-last-screen": "true", children: [
|
|
432
|
+
/* @__PURE__ */ c(wr, {}),
|
|
433
|
+
/* @__PURE__ */ c(Ar, {}),
|
|
434
|
+
/* @__PURE__ */ c(vr, {}),
|
|
435
|
+
/* @__PURE__ */ c(Er, {})
|
|
299
436
|
] })
|
|
300
|
-
] }),
|
|
437
|
+
] }), _r = /* @__PURE__ */ h("div")({
|
|
301
438
|
name: "Container",
|
|
302
|
-
class: "
|
|
439
|
+
class: "c1pgyo67",
|
|
303
440
|
propsAsIs: !1
|
|
304
|
-
}),
|
|
305
|
-
|
|
306
|
-
|
|
441
|
+
}), Cr = "hx17qu6", De = ({
|
|
442
|
+
children: s,
|
|
443
|
+
style: n,
|
|
444
|
+
className: l,
|
|
445
|
+
hiding: f
|
|
446
|
+
}) => /* @__PURE__ */ c(_r, {
|
|
447
|
+
style: n,
|
|
448
|
+
className: wt(l, f && Cr),
|
|
449
|
+
children: s
|
|
450
|
+
}), Tr = 118, Fr = () => De, $r = /* @__PURE__ */ h(Fr())({
|
|
451
|
+
name: "Container",
|
|
452
|
+
class: "c10131zw",
|
|
453
|
+
propsAsIs: !0
|
|
454
|
+
}), kr = /* @__PURE__ */ h("div")({
|
|
455
|
+
name: "InnerContainer",
|
|
456
|
+
class: "ir6k2eo",
|
|
307
457
|
propsAsIs: !1
|
|
308
|
-
}),
|
|
458
|
+
}), ae = /* @__PURE__ */ h("div")({
|
|
309
459
|
name: "Content",
|
|
310
460
|
class: "c1hwoq9l",
|
|
311
461
|
propsAsIs: !1
|
|
312
|
-
}),
|
|
462
|
+
}), le = /* @__PURE__ */ h("div")({
|
|
313
463
|
name: "Title",
|
|
314
464
|
class: "t4ujo4g",
|
|
315
465
|
propsAsIs: !1
|
|
316
|
-
}),
|
|
466
|
+
}), ge = /* @__PURE__ */ h("div")({
|
|
317
467
|
name: "Subtitle",
|
|
318
468
|
class: "s1pjil1h",
|
|
319
469
|
propsAsIs: !1
|
|
320
|
-
}),
|
|
470
|
+
}), Sr = () => ge, lt = /* @__PURE__ */ h(Sr())({
|
|
321
471
|
name: "SubtitleFG",
|
|
322
472
|
class: "s1iorwr9",
|
|
323
473
|
propsAsIs: !0
|
|
324
|
-
}),
|
|
474
|
+
}), Ie = /* @__PURE__ */ h("div")({
|
|
325
475
|
name: "AnswerText",
|
|
326
476
|
class: "a51sv9d",
|
|
327
477
|
propsAsIs: !1
|
|
328
|
-
}),
|
|
478
|
+
}), Lr = () => z, Te = /* @__PURE__ */ h(Lr())({
|
|
329
479
|
name: "FeedbackIcon",
|
|
330
480
|
class: "f1lbk2ye",
|
|
331
481
|
propsAsIs: !0
|
|
332
|
-
}),
|
|
482
|
+
}), ct = /* @__PURE__ */ h("button")({
|
|
333
483
|
name: "CloseButton",
|
|
334
484
|
class: "crcvk3t",
|
|
335
485
|
propsAsIs: !1
|
|
336
|
-
}),
|
|
486
|
+
}), Rr = () => z, ut = /* @__PURE__ */ h(Rr())({
|
|
337
487
|
name: "CloseIcon",
|
|
338
488
|
class: "c33p82r",
|
|
339
489
|
propsAsIs: !0
|
|
340
|
-
}),
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
}) => {
|
|
346
|
-
const [m, g] = V(1);
|
|
347
|
-
return he(() => {
|
|
348
|
-
const f = setInterval(() => {
|
|
349
|
-
g((o) => c && o > 4 || !c && o > 3 ? o : ++o);
|
|
490
|
+
}), ce = (s, n) => s === n ? "translateY(0px)" : s > n ? "translateY(100%)" : "translateY(-100%)", Nr = ({ close: s, votedAnswer: n, correct: l, correctAnswerTitle: f, questionTitle: m, saveHeight: g, style: d, hiding: o }) => {
|
|
491
|
+
const [w, v] = W(1), x = ye({});
|
|
492
|
+
X(() => {
|
|
493
|
+
const y = setInterval(() => {
|
|
494
|
+
v((A) => l && A > 4 || !l && A > 3 ? A : ++A);
|
|
350
495
|
}, 6e3);
|
|
351
|
-
return () => clearInterval(
|
|
352
|
-
}, [
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
/* @__PURE__ */ l(oe, { children: "Congratulations! You answered correctly." }),
|
|
373
|
-
/* @__PURE__ */ I(fe, { children: [
|
|
374
|
-
/* @__PURE__ */ l(Be, { name: "selected" }),
|
|
375
|
-
"Your Pick: ",
|
|
376
|
-
/* @__PURE__ */ l(ye, { children: n == null ? void 0 : n.title })
|
|
377
|
-
] })
|
|
496
|
+
return () => clearInterval(y);
|
|
497
|
+
}, [l]), X(() => {
|
|
498
|
+
var y, A;
|
|
499
|
+
x.current[w] && g(((A = (y = x.current[w]) == null ? void 0 : y.getBoundingClientRect()) == null ? void 0 : A.height) || Tr);
|
|
500
|
+
}, [w, g]);
|
|
501
|
+
const B = (y) => (A) => {
|
|
502
|
+
x.current && (x.current[y] = A);
|
|
503
|
+
};
|
|
504
|
+
return /* @__PURE__ */ c($r, { style: d.height ? d : { ...d, paddingTop: 0, paddingBottom: 0 }, hiding: o, children: /* @__PURE__ */ I(
|
|
505
|
+
kr,
|
|
506
|
+
{
|
|
507
|
+
style: {
|
|
508
|
+
height: d.height,
|
|
509
|
+
minHeight: d.height,
|
|
510
|
+
backgroundColor: w > 3 ? "var(--color-white)" : "var(--color-primary-green2)"
|
|
511
|
+
},
|
|
512
|
+
children: [
|
|
513
|
+
/* @__PURE__ */ c(Br, { step: w, correct: l }),
|
|
514
|
+
/* @__PURE__ */ I(ae, { ref: B(1), style: { transform: ce(1, w) }, children: [
|
|
515
|
+
/* @__PURE__ */ c(le, { children: "Master" }),
|
|
516
|
+
/* @__PURE__ */ c(lt, { children: "FEATURED GROUPS +" })
|
|
378
517
|
] }),
|
|
379
|
-
/* @__PURE__ */ I(
|
|
380
|
-
/* @__PURE__ */
|
|
381
|
-
/* @__PURE__ */
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
/* @__PURE__ */ I(fe, { children: [
|
|
387
|
-
/* @__PURE__ */ l(Be, { name: "selected" }),
|
|
518
|
+
/* @__PURE__ */ I(ae, { ref: B(2), style: { transform: ce(2, w) }, children: [
|
|
519
|
+
/* @__PURE__ */ c(le, { children: "Prediction results are in!" }),
|
|
520
|
+
/* @__PURE__ */ c(lt, { children: "FEATURED GROUPS +" })
|
|
521
|
+
] }),
|
|
522
|
+
/* @__PURE__ */ I(ae, { ref: B(3), style: { transform: ce(3, w) }, children: [
|
|
523
|
+
/* @__PURE__ */ c(le, { children: m }),
|
|
524
|
+
/* @__PURE__ */ c(ge, { children: /* @__PURE__ */ I(Ie, { children: [
|
|
388
525
|
"Your Pick: ",
|
|
389
|
-
|
|
390
|
-
] })
|
|
391
|
-
] })
|
|
392
|
-
] }) : /* @__PURE__ */ I(se, { children: [
|
|
393
|
-
/* @__PURE__ */ l(nt, { onClick: s, children: /* @__PURE__ */ l(st, { name: "icon-cross" }) }),
|
|
394
|
-
/* @__PURE__ */ I(oe, { "data-incorrect": "true", children: [
|
|
395
|
-
"Better luck next time! Correct: ",
|
|
396
|
-
d,
|
|
397
|
-
"."
|
|
526
|
+
n == null ? void 0 : n.title
|
|
527
|
+
] }) })
|
|
398
528
|
] }),
|
|
399
|
-
/* @__PURE__ */ I(
|
|
400
|
-
/* @__PURE__ */
|
|
401
|
-
|
|
402
|
-
|
|
529
|
+
l ? /* @__PURE__ */ I(ie, { children: [
|
|
530
|
+
/* @__PURE__ */ I(
|
|
531
|
+
ae,
|
|
532
|
+
{
|
|
533
|
+
ref: B(4),
|
|
534
|
+
style: { transform: ce(4, w), color: "var(--color-primary-green1)" },
|
|
535
|
+
children: [
|
|
536
|
+
/* @__PURE__ */ c(le, { children: "Congratulations! You answered correctly." }),
|
|
537
|
+
/* @__PURE__ */ I(ge, { children: [
|
|
538
|
+
/* @__PURE__ */ c(Te, { name: "selected" }),
|
|
539
|
+
/* @__PURE__ */ I(Ie, { children: [
|
|
540
|
+
"Your Pick: ",
|
|
541
|
+
n == null ? void 0 : n.title
|
|
542
|
+
] })
|
|
543
|
+
] })
|
|
544
|
+
]
|
|
545
|
+
}
|
|
546
|
+
),
|
|
547
|
+
/* @__PURE__ */ I(
|
|
548
|
+
ae,
|
|
549
|
+
{
|
|
550
|
+
ref: B(5),
|
|
551
|
+
style: { transform: ce(5, w), color: "var(--color-primary-green1)" },
|
|
552
|
+
children: [
|
|
553
|
+
/* @__PURE__ */ I(le, { children: [
|
|
554
|
+
"+",
|
|
555
|
+
n == null ? void 0 : n.points,
|
|
556
|
+
" points"
|
|
557
|
+
] }),
|
|
558
|
+
/* @__PURE__ */ I(ge, { children: [
|
|
559
|
+
/* @__PURE__ */ c(Te, { name: "selected" }),
|
|
560
|
+
/* @__PURE__ */ I(Ie, { children: [
|
|
561
|
+
"Your Pick: ",
|
|
562
|
+
n == null ? void 0 : n.title
|
|
563
|
+
] })
|
|
564
|
+
] }),
|
|
565
|
+
/* @__PURE__ */ c(ct, { onClick: s, children: /* @__PURE__ */ c(ut, { name: "icon-cross" }) })
|
|
566
|
+
]
|
|
567
|
+
}
|
|
568
|
+
)
|
|
569
|
+
] }) : /* @__PURE__ */ I(ae, { ref: B(4), style: { transform: ce(4, w) }, children: [
|
|
570
|
+
/* @__PURE__ */ I(le, { style: { color: "var(--color-neutrals-gray9)" }, children: [
|
|
571
|
+
"Better luck next time! Correct: ",
|
|
572
|
+
f,
|
|
573
|
+
"."
|
|
574
|
+
] }),
|
|
575
|
+
/* @__PURE__ */ I(ge, { style: { color: "var(--color-secondary-red1)" }, children: [
|
|
576
|
+
/* @__PURE__ */ c(Te, { name: "circleClose" }),
|
|
577
|
+
/* @__PURE__ */ I(Ie, { children: [
|
|
578
|
+
"Your Pick: ",
|
|
579
|
+
n == null ? void 0 : n.title
|
|
580
|
+
] })
|
|
581
|
+
] }),
|
|
582
|
+
/* @__PURE__ */ c(ct, { onClick: s, children: /* @__PURE__ */ c(ut, { name: "icon-cross" }) })
|
|
403
583
|
] })
|
|
404
|
-
]
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
}, ri = /* @__PURE__ */ h("div")({
|
|
408
|
-
name: "Container",
|
|
409
|
-
class: "c1eptrjd",
|
|
410
|
-
propsAsIs: !1
|
|
411
|
-
}), ii = /* @__PURE__ */ h("div")({
|
|
412
|
-
name: "CloseIconWrap",
|
|
413
|
-
class: "crylm65",
|
|
414
|
-
propsAsIs: !1
|
|
415
|
-
}), ni = () => z, si = /* @__PURE__ */ h(ni())({
|
|
416
|
-
name: "CloseIcon",
|
|
417
|
-
class: "c9mrcz7",
|
|
418
|
-
propsAsIs: !0
|
|
419
|
-
}), oi = /* @__PURE__ */ h("div")({
|
|
420
|
-
name: "Header",
|
|
421
|
-
class: "hw3lzv4",
|
|
422
|
-
propsAsIs: !1
|
|
423
|
-
}), ai = () => z, ci = /* @__PURE__ */ h(ai())({
|
|
424
|
-
name: "TypeIcon",
|
|
425
|
-
class: "t1rrb3kf",
|
|
426
|
-
propsAsIs: !0
|
|
427
|
-
}), li = /* @__PURE__ */ h("span")({
|
|
428
|
-
name: "TypeName",
|
|
429
|
-
class: "t1ydnjov",
|
|
430
|
-
propsAsIs: !1
|
|
431
|
-
}), ui = /* @__PURE__ */ h("div")({
|
|
432
|
-
name: "Question",
|
|
433
|
-
class: "qlf90cl",
|
|
434
|
-
propsAsIs: !1
|
|
435
|
-
}), hi = /* @__PURE__ */ h("button")({
|
|
436
|
-
name: "AnswerButton",
|
|
437
|
-
class: "a1e0nhcl",
|
|
438
|
-
propsAsIs: !1
|
|
439
|
-
}), pi = /* @__PURE__ */ h("div")({
|
|
440
|
-
name: "Container",
|
|
441
|
-
class: "cjq447q",
|
|
442
|
-
propsAsIs: !1
|
|
443
|
-
}), di = /* @__PURE__ */ h("div")({
|
|
444
|
-
name: "ImageContainer",
|
|
445
|
-
class: "i14egogb",
|
|
446
|
-
propsAsIs: !1
|
|
447
|
-
}), fi = /* @__PURE__ */ h("img")({
|
|
448
|
-
name: "Image",
|
|
449
|
-
class: "i2g9g4l",
|
|
450
|
-
propsAsIs: !1
|
|
451
|
-
}), mi = /* @__PURE__ */ h("div")({
|
|
452
|
-
name: "Details",
|
|
453
|
-
class: "d1c454nm",
|
|
454
|
-
propsAsIs: !1
|
|
455
|
-
}), gi = /* @__PURE__ */ h("div")({
|
|
456
|
-
name: "Name",
|
|
457
|
-
class: "n11nigc3",
|
|
458
|
-
propsAsIs: !1
|
|
459
|
-
}), yi = /* @__PURE__ */ h("div")({
|
|
460
|
-
name: "UserName",
|
|
461
|
-
class: "urxa4k8",
|
|
462
|
-
propsAsIs: !1
|
|
463
|
-
}), wi = ({ image: s, name: n, userName: c, verified: d }) => /* @__PURE__ */ I(pi, { children: [
|
|
464
|
-
/* @__PURE__ */ l(di, { children: /* @__PURE__ */ l(fi, { src: s }) }),
|
|
465
|
-
/* @__PURE__ */ I(mi, { children: [
|
|
466
|
-
/* @__PURE__ */ I(gi, { children: [
|
|
467
|
-
n,
|
|
468
|
-
" ",
|
|
469
|
-
d && /* @__PURE__ */ l(z, { name: "icon-twitter-verified" })
|
|
470
|
-
] }),
|
|
471
|
-
/* @__PURE__ */ l(yi, { children: c })
|
|
472
|
-
] })
|
|
473
|
-
] }), Ii = /* @__PURE__ */ h("div")({
|
|
474
|
-
name: "Container",
|
|
475
|
-
class: "c1t4f0x4",
|
|
476
|
-
propsAsIs: !1
|
|
477
|
-
}), Ai = /* @__PURE__ */ h("button")({
|
|
478
|
-
name: "ActionBtn",
|
|
479
|
-
class: "a16w1nl6",
|
|
480
|
-
propsAsIs: !1
|
|
481
|
-
}), xi = /* @__PURE__ */ h("div")({
|
|
482
|
-
name: "Body",
|
|
483
|
-
class: "b14u54rf",
|
|
484
|
-
propsAsIs: !1
|
|
485
|
-
}), bi = /* @__PURE__ */ h("img")({
|
|
486
|
-
name: "Image",
|
|
487
|
-
class: "i1hxm6zo",
|
|
488
|
-
propsAsIs: !1
|
|
489
|
-
}), Ei = /* @__PURE__ */ h("div")({
|
|
490
|
-
name: "Details",
|
|
491
|
-
class: "d1s19yop",
|
|
492
|
-
propsAsIs: !1
|
|
493
|
-
}), vi = /* @__PURE__ */ h("div")({
|
|
494
|
-
name: "QuoteWrap",
|
|
495
|
-
class: "q1qyx94r",
|
|
496
|
-
propsAsIs: !1
|
|
497
|
-
}), Bi = /* @__PURE__ */ h("blockquote")({
|
|
498
|
-
name: "Quote",
|
|
499
|
-
class: "qs97clu",
|
|
500
|
-
propsAsIs: !1
|
|
501
|
-
}), _i = ({
|
|
502
|
-
account: s,
|
|
503
|
-
body: n,
|
|
504
|
-
image: c,
|
|
505
|
-
title: d,
|
|
506
|
-
action: m
|
|
507
|
-
}) => /* @__PURE__ */ I(Ii, { children: [
|
|
508
|
-
/* @__PURE__ */ l(vi, { children: /* @__PURE__ */ l(Bi, { children: d }) }),
|
|
509
|
-
/* @__PURE__ */ I(Ei, { children: [
|
|
510
|
-
/* @__PURE__ */ l(wi, { ...s }),
|
|
511
|
-
/* @__PURE__ */ l(xi, { children: n }),
|
|
512
|
-
c && /* @__PURE__ */ l(bi, { src: c })
|
|
513
|
-
] }),
|
|
514
|
-
m && /* @__PURE__ */ l(Ai, { onClick: m, children: "View Tweet" })
|
|
515
|
-
] }), ot = ({
|
|
516
|
-
close: s,
|
|
517
|
-
action: n,
|
|
518
|
-
data: { questionType: c, question: d, insight: m, tweet: g }
|
|
519
|
-
}) => {
|
|
520
|
-
const f = mr[c];
|
|
521
|
-
return f ? d != null && d.predictionResult ? /* @__PURE__ */ l(ti, { close: s, ...d }) : /* @__PURE__ */ I(ri, { children: [
|
|
522
|
-
/* @__PURE__ */ l(ii, { onClick: s, children: /* @__PURE__ */ l(si, { name: "icon-cross" }) }),
|
|
523
|
-
c !== D.TWEET && /* @__PURE__ */ I(oi, { children: [
|
|
524
|
-
/* @__PURE__ */ l(
|
|
525
|
-
ci,
|
|
526
|
-
{
|
|
527
|
-
"data-type-trivia": c === D.TRIVIA,
|
|
528
|
-
"data-type-poll": c === D.POLL,
|
|
529
|
-
name: f.iconName
|
|
530
|
-
}
|
|
531
|
-
),
|
|
532
|
-
/* @__PURE__ */ l(li, { children: f.label })
|
|
533
|
-
] }),
|
|
534
|
-
c === D.FACTOID && /* @__PURE__ */ l(Cr, { ...m, action: n }),
|
|
535
|
-
c === D.TWEET && // ToDo: connect with real Api data
|
|
536
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
537
|
-
// @ts-ignore
|
|
538
|
-
/* @__PURE__ */ l(_i, { ...g, action: n }),
|
|
539
|
-
c !== D.FACTOID && c !== D.TWEET && /* @__PURE__ */ I(me, { children: [
|
|
540
|
-
/* @__PURE__ */ l(ui, { children: d == null ? void 0 : d.title }),
|
|
541
|
-
/* @__PURE__ */ l(hi, { onClick: n, children: "Answer" })
|
|
542
|
-
] })
|
|
543
|
-
] }) : null;
|
|
584
|
+
]
|
|
585
|
+
}
|
|
586
|
+
) });
|
|
544
587
|
};
|
|
545
|
-
var
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
var
|
|
550
|
-
for (var
|
|
551
|
-
|
|
588
|
+
var It = {}, At = {}, Ee = {};
|
|
589
|
+
Ee.byteLength = Or;
|
|
590
|
+
Ee.toByteArray = Pr;
|
|
591
|
+
Ee.fromByteArray = Gr;
|
|
592
|
+
var V = [], q = [], Ur = typeof Uint8Array < "u" ? Uint8Array : Array, Fe = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
|
|
593
|
+
for (var ue = 0, zr = Fe.length; ue < zr; ++ue)
|
|
594
|
+
V[ue] = Fe[ue], q[Fe.charCodeAt(ue)] = ue;
|
|
552
595
|
q["-".charCodeAt(0)] = 62;
|
|
553
596
|
q["_".charCodeAt(0)] = 63;
|
|
554
|
-
function
|
|
597
|
+
function xt(s) {
|
|
555
598
|
var n = s.length;
|
|
556
599
|
if (n % 4 > 0)
|
|
557
600
|
throw new Error("Invalid string. Length must be a multiple of 4");
|
|
558
|
-
var
|
|
559
|
-
|
|
560
|
-
var
|
|
561
|
-
return [
|
|
601
|
+
var l = s.indexOf("=");
|
|
602
|
+
l === -1 && (l = n);
|
|
603
|
+
var f = l === n ? 0 : 4 - l % 4;
|
|
604
|
+
return [l, f];
|
|
562
605
|
}
|
|
563
|
-
function
|
|
564
|
-
var n =
|
|
565
|
-
return (
|
|
606
|
+
function Or(s) {
|
|
607
|
+
var n = xt(s), l = n[0], f = n[1];
|
|
608
|
+
return (l + f) * 3 / 4 - f;
|
|
566
609
|
}
|
|
567
|
-
function
|
|
568
|
-
return (n +
|
|
610
|
+
function Dr(s, n, l) {
|
|
611
|
+
return (n + l) * 3 / 4 - l;
|
|
569
612
|
}
|
|
570
|
-
function
|
|
571
|
-
var n,
|
|
613
|
+
function Pr(s) {
|
|
614
|
+
var n, l = xt(s), f = l[0], m = l[1], g = new Ur(Dr(s, f, m)), d = 0, o = m > 0 ? f - 4 : f, w;
|
|
572
615
|
for (w = 0; w < o; w += 4)
|
|
573
|
-
n = q[s.charCodeAt(w)] << 18 | q[s.charCodeAt(w + 1)] << 12 | q[s.charCodeAt(w + 2)] << 6 | q[s.charCodeAt(w + 3)], g[
|
|
574
|
-
return m === 2 && (n = q[s.charCodeAt(w)] << 2 | q[s.charCodeAt(w + 1)] >> 4, g[
|
|
616
|
+
n = q[s.charCodeAt(w)] << 18 | q[s.charCodeAt(w + 1)] << 12 | q[s.charCodeAt(w + 2)] << 6 | q[s.charCodeAt(w + 3)], g[d++] = n >> 16 & 255, g[d++] = n >> 8 & 255, g[d++] = n & 255;
|
|
617
|
+
return m === 2 && (n = q[s.charCodeAt(w)] << 2 | q[s.charCodeAt(w + 1)] >> 4, g[d++] = n & 255), m === 1 && (n = q[s.charCodeAt(w)] << 10 | q[s.charCodeAt(w + 1)] << 4 | q[s.charCodeAt(w + 2)] >> 2, g[d++] = n >> 8 & 255, g[d++] = n & 255), g;
|
|
575
618
|
}
|
|
576
|
-
function
|
|
577
|
-
return
|
|
619
|
+
function Mr(s) {
|
|
620
|
+
return V[s >> 18 & 63] + V[s >> 12 & 63] + V[s >> 6 & 63] + V[s & 63];
|
|
578
621
|
}
|
|
579
|
-
function
|
|
580
|
-
for (var
|
|
581
|
-
|
|
622
|
+
function qr(s, n, l) {
|
|
623
|
+
for (var f, m = [], g = n; g < l; g += 3)
|
|
624
|
+
f = (s[g] << 16 & 16711680) + (s[g + 1] << 8 & 65280) + (s[g + 2] & 255), m.push(Mr(f));
|
|
582
625
|
return m.join("");
|
|
583
626
|
}
|
|
584
|
-
function
|
|
585
|
-
for (var n,
|
|
586
|
-
m.push(
|
|
587
|
-
return
|
|
588
|
-
|
|
589
|
-
)) :
|
|
590
|
-
|
|
627
|
+
function Gr(s) {
|
|
628
|
+
for (var n, l = s.length, f = l % 3, m = [], g = 16383, d = 0, o = l - f; d < o; d += g)
|
|
629
|
+
m.push(qr(s, d, d + g > o ? o : d + g));
|
|
630
|
+
return f === 1 ? (n = s[l - 1], m.push(
|
|
631
|
+
V[n >> 2] + V[n << 4 & 63] + "=="
|
|
632
|
+
)) : f === 2 && (n = (s[l - 2] << 8) + s[l - 1], m.push(
|
|
633
|
+
V[n >> 10] + V[n >> 4 & 63] + V[n << 2 & 63] + "="
|
|
591
634
|
)), m.join("");
|
|
592
635
|
}
|
|
593
|
-
var
|
|
636
|
+
var Pe = {};
|
|
594
637
|
/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
595
|
-
|
|
596
|
-
var g,
|
|
597
|
-
for (
|
|
638
|
+
Pe.read = function(s, n, l, f, m) {
|
|
639
|
+
var g, d, o = m * 8 - f - 1, w = (1 << o) - 1, v = w >> 1, x = -7, B = l ? m - 1 : 0, y = l ? -1 : 1, A = s[n + B];
|
|
640
|
+
for (B += y, g = A & (1 << -x) - 1, A >>= -x, x += o; x > 0; g = g * 256 + s[n + B], B += y, x -= 8)
|
|
598
641
|
;
|
|
599
|
-
for (
|
|
642
|
+
for (d = g & (1 << -x) - 1, g >>= -x, x += f; x > 0; d = d * 256 + s[n + B], B += y, x -= 8)
|
|
600
643
|
;
|
|
601
644
|
if (g === 0)
|
|
602
|
-
g = 1 -
|
|
645
|
+
g = 1 - v;
|
|
603
646
|
else {
|
|
604
647
|
if (g === w)
|
|
605
|
-
return
|
|
606
|
-
|
|
648
|
+
return d ? NaN : (A ? -1 : 1) * (1 / 0);
|
|
649
|
+
d = d + Math.pow(2, f), g = g - v;
|
|
607
650
|
}
|
|
608
|
-
return (A ? -1 : 1) *
|
|
651
|
+
return (A ? -1 : 1) * d * Math.pow(2, g - f);
|
|
609
652
|
};
|
|
610
|
-
|
|
611
|
-
var
|
|
612
|
-
for (n = Math.abs(n), isNaN(n) || n === 1 / 0 ? (o = isNaN(n) ? 1 : 0,
|
|
653
|
+
Pe.write = function(s, n, l, f, m, g) {
|
|
654
|
+
var d, o, w, v = g * 8 - m - 1, x = (1 << v) - 1, B = x >> 1, y = m === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0, A = f ? 0 : g - 1, b = f ? 1 : -1, _ = n < 0 || n === 0 && 1 / n < 0 ? 1 : 0;
|
|
655
|
+
for (n = Math.abs(n), isNaN(n) || n === 1 / 0 ? (o = isNaN(n) ? 1 : 0, d = x) : (d = Math.floor(Math.log(n) / Math.LN2), n * (w = Math.pow(2, -d)) < 1 && (d--, w *= 2), d + B >= 1 ? n += y / w : n += y * Math.pow(2, 1 - B), n * w >= 2 && (d++, w /= 2), d + B >= x ? (o = 0, d = x) : d + B >= 1 ? (o = (n * w - 1) * Math.pow(2, m), d = d + B) : (o = n * Math.pow(2, B - 1) * Math.pow(2, m), d = 0)); m >= 8; s[l + A] = o & 255, A += b, o /= 256, m -= 8)
|
|
613
656
|
;
|
|
614
|
-
for (
|
|
657
|
+
for (d = d << m | o, v += m; v > 0; s[l + A] = d & 255, A += b, d /= 256, v -= 8)
|
|
615
658
|
;
|
|
616
|
-
s[
|
|
659
|
+
s[l + A - b] |= _ * 128;
|
|
617
660
|
};
|
|
618
661
|
/*!
|
|
619
662
|
* The buffer module from node.js, for the browser.
|
|
@@ -622,7 +665,7 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
622
665
|
* @license MIT
|
|
623
666
|
*/
|
|
624
667
|
(function(s) {
|
|
625
|
-
const n =
|
|
668
|
+
const n = Ee, l = Pe, f = typeof Symbol == "function" && typeof Symbol.for == "function" ? Symbol.for("nodejs.util.inspect.custom") : null;
|
|
626
669
|
s.Buffer = o, s.SlowBuffer = F, s.INSPECT_MAX_BYTES = 50;
|
|
627
670
|
const m = 2147483647;
|
|
628
671
|
s.kMaxLength = m, o.TYPED_ARRAY_SUPPORT = g(), !o.TYPED_ARRAY_SUPPORT && typeof console < "u" && typeof console.error == "function" && console.error(
|
|
@@ -630,10 +673,10 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
630
673
|
);
|
|
631
674
|
function g() {
|
|
632
675
|
try {
|
|
633
|
-
const
|
|
676
|
+
const i = new Uint8Array(1), e = { foo: function() {
|
|
634
677
|
return 42;
|
|
635
678
|
} };
|
|
636
|
-
return Object.setPrototypeOf(e, Uint8Array.prototype), Object.setPrototypeOf(
|
|
679
|
+
return Object.setPrototypeOf(e, Uint8Array.prototype), Object.setPrototypeOf(i, e), i.foo() === 42;
|
|
637
680
|
} catch {
|
|
638
681
|
return !1;
|
|
639
682
|
}
|
|
@@ -651,136 +694,136 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
651
694
|
return this.byteOffset;
|
|
652
695
|
}
|
|
653
696
|
});
|
|
654
|
-
function
|
|
655
|
-
if (
|
|
656
|
-
throw new RangeError('The value "' +
|
|
657
|
-
const e = new Uint8Array(
|
|
697
|
+
function d(i) {
|
|
698
|
+
if (i > m)
|
|
699
|
+
throw new RangeError('The value "' + i + '" is invalid for option "size"');
|
|
700
|
+
const e = new Uint8Array(i);
|
|
658
701
|
return Object.setPrototypeOf(e, o.prototype), e;
|
|
659
702
|
}
|
|
660
|
-
function o(
|
|
661
|
-
if (typeof
|
|
703
|
+
function o(i, e, t) {
|
|
704
|
+
if (typeof i == "number") {
|
|
662
705
|
if (typeof e == "string")
|
|
663
706
|
throw new TypeError(
|
|
664
707
|
'The "string" argument must be of type string. Received type number'
|
|
665
708
|
);
|
|
666
|
-
return
|
|
709
|
+
return B(i);
|
|
667
710
|
}
|
|
668
|
-
return w(
|
|
711
|
+
return w(i, e, t);
|
|
669
712
|
}
|
|
670
713
|
o.poolSize = 8192;
|
|
671
|
-
function w(
|
|
672
|
-
if (typeof
|
|
673
|
-
return y(
|
|
674
|
-
if (ArrayBuffer.isView(
|
|
675
|
-
return
|
|
676
|
-
if (
|
|
714
|
+
function w(i, e, t) {
|
|
715
|
+
if (typeof i == "string")
|
|
716
|
+
return y(i, e);
|
|
717
|
+
if (ArrayBuffer.isView(i))
|
|
718
|
+
return b(i);
|
|
719
|
+
if (i == null)
|
|
677
720
|
throw new TypeError(
|
|
678
|
-
"The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof
|
|
721
|
+
"The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof i
|
|
679
722
|
);
|
|
680
|
-
if (
|
|
681
|
-
return
|
|
682
|
-
if (typeof
|
|
723
|
+
if (j(i, ArrayBuffer) || i && j(i.buffer, ArrayBuffer) || typeof SharedArrayBuffer < "u" && (j(i, SharedArrayBuffer) || i && j(i.buffer, SharedArrayBuffer)))
|
|
724
|
+
return _(i, e, t);
|
|
725
|
+
if (typeof i == "number")
|
|
683
726
|
throw new TypeError(
|
|
684
727
|
'The "value" argument must not be of type number. Received type number'
|
|
685
728
|
);
|
|
686
|
-
const
|
|
687
|
-
if (
|
|
688
|
-
return o.from(
|
|
689
|
-
const a = R(
|
|
729
|
+
const r = i.valueOf && i.valueOf();
|
|
730
|
+
if (r != null && r !== i)
|
|
731
|
+
return o.from(r, e, t);
|
|
732
|
+
const a = R(i);
|
|
690
733
|
if (a)
|
|
691
734
|
return a;
|
|
692
|
-
if (typeof Symbol < "u" && Symbol.toPrimitive != null && typeof
|
|
693
|
-
return o.from(
|
|
735
|
+
if (typeof Symbol < "u" && Symbol.toPrimitive != null && typeof i[Symbol.toPrimitive] == "function")
|
|
736
|
+
return o.from(i[Symbol.toPrimitive]("string"), e, t);
|
|
694
737
|
throw new TypeError(
|
|
695
|
-
"The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof
|
|
738
|
+
"The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof i
|
|
696
739
|
);
|
|
697
740
|
}
|
|
698
|
-
o.from = function(
|
|
699
|
-
return w(
|
|
741
|
+
o.from = function(i, e, t) {
|
|
742
|
+
return w(i, e, t);
|
|
700
743
|
}, Object.setPrototypeOf(o.prototype, Uint8Array.prototype), Object.setPrototypeOf(o, Uint8Array);
|
|
701
|
-
function
|
|
702
|
-
if (typeof
|
|
744
|
+
function v(i) {
|
|
745
|
+
if (typeof i != "number")
|
|
703
746
|
throw new TypeError('"size" argument must be of type number');
|
|
704
|
-
if (
|
|
705
|
-
throw new RangeError('The value "' +
|
|
747
|
+
if (i < 0)
|
|
748
|
+
throw new RangeError('The value "' + i + '" is invalid for option "size"');
|
|
706
749
|
}
|
|
707
|
-
function
|
|
708
|
-
return
|
|
750
|
+
function x(i, e, t) {
|
|
751
|
+
return v(i), i <= 0 ? d(i) : e !== void 0 ? typeof t == "string" ? d(i).fill(e, t) : d(i).fill(e) : d(i);
|
|
709
752
|
}
|
|
710
|
-
o.alloc = function(
|
|
711
|
-
return
|
|
753
|
+
o.alloc = function(i, e, t) {
|
|
754
|
+
return x(i, e, t);
|
|
712
755
|
};
|
|
713
|
-
function
|
|
714
|
-
return
|
|
756
|
+
function B(i) {
|
|
757
|
+
return v(i), d(i < 0 ? 0 : C(i) | 0);
|
|
715
758
|
}
|
|
716
|
-
o.allocUnsafe = function(
|
|
717
|
-
return
|
|
718
|
-
}, o.allocUnsafeSlow = function(
|
|
719
|
-
return
|
|
759
|
+
o.allocUnsafe = function(i) {
|
|
760
|
+
return B(i);
|
|
761
|
+
}, o.allocUnsafeSlow = function(i) {
|
|
762
|
+
return B(i);
|
|
720
763
|
};
|
|
721
|
-
function y(
|
|
764
|
+
function y(i, e) {
|
|
722
765
|
if ((typeof e != "string" || e === "") && (e = "utf8"), !o.isEncoding(e))
|
|
723
766
|
throw new TypeError("Unknown encoding: " + e);
|
|
724
|
-
const t = U(
|
|
725
|
-
let
|
|
726
|
-
const a =
|
|
727
|
-
return a !== t && (
|
|
728
|
-
}
|
|
729
|
-
function A(
|
|
730
|
-
const e =
|
|
731
|
-
for (let
|
|
732
|
-
t[
|
|
767
|
+
const t = U(i, e) | 0;
|
|
768
|
+
let r = d(t);
|
|
769
|
+
const a = r.write(i, e);
|
|
770
|
+
return a !== t && (r = r.slice(0, a)), r;
|
|
771
|
+
}
|
|
772
|
+
function A(i) {
|
|
773
|
+
const e = i.length < 0 ? 0 : C(i.length) | 0, t = d(e);
|
|
774
|
+
for (let r = 0; r < e; r += 1)
|
|
775
|
+
t[r] = i[r] & 255;
|
|
733
776
|
return t;
|
|
734
777
|
}
|
|
735
|
-
function
|
|
736
|
-
if (
|
|
737
|
-
const e = new Uint8Array(
|
|
738
|
-
return
|
|
778
|
+
function b(i) {
|
|
779
|
+
if (j(i, Uint8Array)) {
|
|
780
|
+
const e = new Uint8Array(i);
|
|
781
|
+
return _(e.buffer, e.byteOffset, e.byteLength);
|
|
739
782
|
}
|
|
740
|
-
return A(
|
|
783
|
+
return A(i);
|
|
741
784
|
}
|
|
742
|
-
function
|
|
743
|
-
if (e < 0 ||
|
|
785
|
+
function _(i, e, t) {
|
|
786
|
+
if (e < 0 || i.byteLength < e)
|
|
744
787
|
throw new RangeError('"offset" is outside of buffer bounds');
|
|
745
|
-
if (
|
|
788
|
+
if (i.byteLength < e + (t || 0))
|
|
746
789
|
throw new RangeError('"length" is outside of buffer bounds');
|
|
747
|
-
let
|
|
748
|
-
return e === void 0 && t === void 0 ?
|
|
790
|
+
let r;
|
|
791
|
+
return e === void 0 && t === void 0 ? r = new Uint8Array(i) : t === void 0 ? r = new Uint8Array(i, e) : r = new Uint8Array(i, e, t), Object.setPrototypeOf(r, o.prototype), r;
|
|
749
792
|
}
|
|
750
|
-
function R(
|
|
751
|
-
if (o.isBuffer(
|
|
752
|
-
const e =
|
|
753
|
-
return t.length === 0 ||
|
|
793
|
+
function R(i) {
|
|
794
|
+
if (o.isBuffer(i)) {
|
|
795
|
+
const e = C(i.length) | 0, t = d(e);
|
|
796
|
+
return t.length === 0 || i.copy(t, 0, 0, e), t;
|
|
754
797
|
}
|
|
755
|
-
if (
|
|
756
|
-
return typeof
|
|
757
|
-
if (
|
|
758
|
-
return A(
|
|
798
|
+
if (i.length !== void 0)
|
|
799
|
+
return typeof i.length != "number" || Ce(i.length) ? d(0) : A(i);
|
|
800
|
+
if (i.type === "Buffer" && Array.isArray(i.data))
|
|
801
|
+
return A(i.data);
|
|
759
802
|
}
|
|
760
|
-
function
|
|
761
|
-
if (
|
|
803
|
+
function C(i) {
|
|
804
|
+
if (i >= m)
|
|
762
805
|
throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x" + m.toString(16) + " bytes");
|
|
763
|
-
return
|
|
806
|
+
return i | 0;
|
|
764
807
|
}
|
|
765
|
-
function F(
|
|
766
|
-
return +
|
|
808
|
+
function F(i) {
|
|
809
|
+
return +i != i && (i = 0), o.alloc(+i);
|
|
767
810
|
}
|
|
768
811
|
o.isBuffer = function(e) {
|
|
769
812
|
return e != null && e._isBuffer === !0 && e !== o.prototype;
|
|
770
813
|
}, o.compare = function(e, t) {
|
|
771
|
-
if (
|
|
814
|
+
if (j(e, Uint8Array) && (e = o.from(e, e.offset, e.byteLength)), j(t, Uint8Array) && (t = o.from(t, t.offset, t.byteLength)), !o.isBuffer(e) || !o.isBuffer(t))
|
|
772
815
|
throw new TypeError(
|
|
773
816
|
'The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array'
|
|
774
817
|
);
|
|
775
818
|
if (e === t)
|
|
776
819
|
return 0;
|
|
777
|
-
let
|
|
778
|
-
for (let u = 0, p = Math.min(
|
|
820
|
+
let r = e.length, a = t.length;
|
|
821
|
+
for (let u = 0, p = Math.min(r, a); u < p; ++u)
|
|
779
822
|
if (e[u] !== t[u]) {
|
|
780
|
-
|
|
823
|
+
r = e[u], a = t[u];
|
|
781
824
|
break;
|
|
782
825
|
}
|
|
783
|
-
return
|
|
826
|
+
return r < a ? -1 : a < r ? 1 : 0;
|
|
784
827
|
}, o.isEncoding = function(e) {
|
|
785
828
|
switch (String(e).toLowerCase()) {
|
|
786
829
|
case "hex":
|
|
@@ -803,15 +846,15 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
803
846
|
throw new TypeError('"list" argument must be an Array of Buffers');
|
|
804
847
|
if (e.length === 0)
|
|
805
848
|
return o.alloc(0);
|
|
806
|
-
let
|
|
849
|
+
let r;
|
|
807
850
|
if (t === void 0)
|
|
808
|
-
for (t = 0,
|
|
809
|
-
t += e[
|
|
851
|
+
for (t = 0, r = 0; r < e.length; ++r)
|
|
852
|
+
t += e[r].length;
|
|
810
853
|
const a = o.allocUnsafe(t);
|
|
811
854
|
let u = 0;
|
|
812
|
-
for (
|
|
813
|
-
let p = e[
|
|
814
|
-
if (
|
|
855
|
+
for (r = 0; r < e.length; ++r) {
|
|
856
|
+
let p = e[r];
|
|
857
|
+
if (j(p, Uint8Array))
|
|
815
858
|
u + p.length > a.length ? (o.isBuffer(p) || (p = o.from(p)), p.copy(a, u)) : Uint8Array.prototype.set.call(
|
|
816
859
|
a,
|
|
817
860
|
p,
|
|
@@ -825,17 +868,17 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
825
868
|
}
|
|
826
869
|
return a;
|
|
827
870
|
};
|
|
828
|
-
function U(
|
|
829
|
-
if (o.isBuffer(
|
|
830
|
-
return
|
|
831
|
-
if (ArrayBuffer.isView(
|
|
832
|
-
return
|
|
833
|
-
if (typeof
|
|
871
|
+
function U(i, e) {
|
|
872
|
+
if (o.isBuffer(i))
|
|
873
|
+
return i.length;
|
|
874
|
+
if (ArrayBuffer.isView(i) || j(i, ArrayBuffer))
|
|
875
|
+
return i.byteLength;
|
|
876
|
+
if (typeof i != "string")
|
|
834
877
|
throw new TypeError(
|
|
835
|
-
'The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type ' + typeof
|
|
878
|
+
'The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type ' + typeof i
|
|
836
879
|
);
|
|
837
|
-
const t =
|
|
838
|
-
if (!
|
|
880
|
+
const t = i.length, r = arguments.length > 2 && arguments[2] === !0;
|
|
881
|
+
if (!r && t === 0)
|
|
839
882
|
return 0;
|
|
840
883
|
let a = !1;
|
|
841
884
|
for (; ; )
|
|
@@ -846,7 +889,7 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
846
889
|
return t;
|
|
847
890
|
case "utf8":
|
|
848
891
|
case "utf-8":
|
|
849
|
-
return
|
|
892
|
+
return _e(i).length;
|
|
850
893
|
case "ucs2":
|
|
851
894
|
case "ucs-2":
|
|
852
895
|
case "utf16le":
|
|
@@ -855,47 +898,47 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
855
898
|
case "hex":
|
|
856
899
|
return t >>> 1;
|
|
857
900
|
case "base64":
|
|
858
|
-
return
|
|
901
|
+
return Je(i).length;
|
|
859
902
|
default:
|
|
860
903
|
if (a)
|
|
861
|
-
return
|
|
904
|
+
return r ? -1 : _e(i).length;
|
|
862
905
|
e = ("" + e).toLowerCase(), a = !0;
|
|
863
906
|
}
|
|
864
907
|
}
|
|
865
908
|
o.byteLength = U;
|
|
866
|
-
function
|
|
867
|
-
let
|
|
909
|
+
function Q(i, e, t) {
|
|
910
|
+
let r = !1;
|
|
868
911
|
if ((e === void 0 || e < 0) && (e = 0), e > this.length || ((t === void 0 || t > this.length) && (t = this.length), t <= 0) || (t >>>= 0, e >>>= 0, t <= e))
|
|
869
912
|
return "";
|
|
870
|
-
for (
|
|
871
|
-
switch (
|
|
913
|
+
for (i || (i = "utf8"); ; )
|
|
914
|
+
switch (i) {
|
|
872
915
|
case "hex":
|
|
873
|
-
return
|
|
916
|
+
return Nt(this, e, t);
|
|
874
917
|
case "utf8":
|
|
875
918
|
case "utf-8":
|
|
876
|
-
return
|
|
919
|
+
return Ge(this, e, t);
|
|
877
920
|
case "ascii":
|
|
878
|
-
return
|
|
921
|
+
return Lt(this, e, t);
|
|
879
922
|
case "latin1":
|
|
880
923
|
case "binary":
|
|
881
|
-
return
|
|
924
|
+
return Rt(this, e, t);
|
|
882
925
|
case "base64":
|
|
883
|
-
return
|
|
926
|
+
return kt(this, e, t);
|
|
884
927
|
case "ucs2":
|
|
885
928
|
case "ucs-2":
|
|
886
929
|
case "utf16le":
|
|
887
930
|
case "utf-16le":
|
|
888
|
-
return
|
|
931
|
+
return Ut(this, e, t);
|
|
889
932
|
default:
|
|
890
|
-
if (
|
|
891
|
-
throw new TypeError("Unknown encoding: " +
|
|
892
|
-
|
|
933
|
+
if (r)
|
|
934
|
+
throw new TypeError("Unknown encoding: " + i);
|
|
935
|
+
i = (i + "").toLowerCase(), r = !0;
|
|
893
936
|
}
|
|
894
937
|
}
|
|
895
938
|
o.prototype._isBuffer = !0;
|
|
896
|
-
function M(
|
|
897
|
-
const
|
|
898
|
-
|
|
939
|
+
function M(i, e, t) {
|
|
940
|
+
const r = i[e];
|
|
941
|
+
i[e] = i[t], i[t] = r;
|
|
899
942
|
}
|
|
900
943
|
o.prototype.swap16 = function() {
|
|
901
944
|
const e = this.length;
|
|
@@ -920,7 +963,7 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
920
963
|
return this;
|
|
921
964
|
}, o.prototype.toString = function() {
|
|
922
965
|
const e = this.length;
|
|
923
|
-
return e === 0 ? "" : arguments.length === 0 ?
|
|
966
|
+
return e === 0 ? "" : arguments.length === 0 ? Ge(this, 0, e) : Q.apply(this, arguments);
|
|
924
967
|
}, o.prototype.toLocaleString = o.prototype.toString, o.prototype.equals = function(e) {
|
|
925
968
|
if (!o.isBuffer(e))
|
|
926
969
|
throw new TypeError("Argument must be a Buffer");
|
|
@@ -929,54 +972,54 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
929
972
|
let e = "";
|
|
930
973
|
const t = s.INSPECT_MAX_BYTES;
|
|
931
974
|
return e = this.toString("hex", 0, t).replace(/(.{2})/g, "$1 ").trim(), this.length > t && (e += " ... "), "<Buffer " + e + ">";
|
|
932
|
-
},
|
|
933
|
-
if (
|
|
975
|
+
}, f && (o.prototype[f] = o.prototype.inspect), o.prototype.compare = function(e, t, r, a, u) {
|
|
976
|
+
if (j(e, Uint8Array) && (e = o.from(e, e.offset, e.byteLength)), !o.isBuffer(e))
|
|
934
977
|
throw new TypeError(
|
|
935
978
|
'The "target" argument must be one of type Buffer or Uint8Array. Received type ' + typeof e
|
|
936
979
|
);
|
|
937
|
-
if (t === void 0 && (t = 0),
|
|
980
|
+
if (t === void 0 && (t = 0), r === void 0 && (r = e ? e.length : 0), a === void 0 && (a = 0), u === void 0 && (u = this.length), t < 0 || r > e.length || a < 0 || u > this.length)
|
|
938
981
|
throw new RangeError("out of range index");
|
|
939
|
-
if (a >= u && t >=
|
|
982
|
+
if (a >= u && t >= r)
|
|
940
983
|
return 0;
|
|
941
984
|
if (a >= u)
|
|
942
985
|
return -1;
|
|
943
|
-
if (t >=
|
|
986
|
+
if (t >= r)
|
|
944
987
|
return 1;
|
|
945
|
-
if (t >>>= 0,
|
|
988
|
+
if (t >>>= 0, r >>>= 0, a >>>= 0, u >>>= 0, this === e)
|
|
946
989
|
return 0;
|
|
947
|
-
let p = u - a,
|
|
948
|
-
const k = Math.min(p,
|
|
990
|
+
let p = u - a, E = r - t;
|
|
991
|
+
const k = Math.min(p, E), $ = this.slice(a, u), S = e.slice(t, r);
|
|
949
992
|
for (let T = 0; T < k; ++T)
|
|
950
993
|
if ($[T] !== S[T]) {
|
|
951
|
-
p = $[T],
|
|
994
|
+
p = $[T], E = S[T];
|
|
952
995
|
break;
|
|
953
996
|
}
|
|
954
|
-
return p <
|
|
997
|
+
return p < E ? -1 : E < p ? 1 : 0;
|
|
955
998
|
};
|
|
956
|
-
function
|
|
957
|
-
if (
|
|
999
|
+
function Me(i, e, t, r, a) {
|
|
1000
|
+
if (i.length === 0)
|
|
958
1001
|
return -1;
|
|
959
|
-
if (typeof t == "string" ? (
|
|
1002
|
+
if (typeof t == "string" ? (r = t, t = 0) : t > 2147483647 ? t = 2147483647 : t < -2147483648 && (t = -2147483648), t = +t, Ce(t) && (t = a ? 0 : i.length - 1), t < 0 && (t = i.length + t), t >= i.length) {
|
|
960
1003
|
if (a)
|
|
961
1004
|
return -1;
|
|
962
|
-
t =
|
|
1005
|
+
t = i.length - 1;
|
|
963
1006
|
} else if (t < 0)
|
|
964
1007
|
if (a)
|
|
965
1008
|
t = 0;
|
|
966
1009
|
else
|
|
967
1010
|
return -1;
|
|
968
|
-
if (typeof e == "string" && (e = o.from(e,
|
|
969
|
-
return e.length === 0 ? -1 :
|
|
1011
|
+
if (typeof e == "string" && (e = o.from(e, r)), o.isBuffer(e))
|
|
1012
|
+
return e.length === 0 ? -1 : qe(i, e, t, r, a);
|
|
970
1013
|
if (typeof e == "number")
|
|
971
|
-
return e = e & 255, typeof Uint8Array.prototype.indexOf == "function" ? a ? Uint8Array.prototype.indexOf.call(
|
|
1014
|
+
return e = e & 255, typeof Uint8Array.prototype.indexOf == "function" ? a ? Uint8Array.prototype.indexOf.call(i, e, t) : Uint8Array.prototype.lastIndexOf.call(i, e, t) : qe(i, [e], t, r, a);
|
|
972
1015
|
throw new TypeError("val must be string, number or Buffer");
|
|
973
1016
|
}
|
|
974
|
-
function
|
|
975
|
-
let u = 1, p =
|
|
976
|
-
if (
|
|
977
|
-
if (
|
|
1017
|
+
function qe(i, e, t, r, a) {
|
|
1018
|
+
let u = 1, p = i.length, E = e.length;
|
|
1019
|
+
if (r !== void 0 && (r = String(r).toLowerCase(), r === "ucs2" || r === "ucs-2" || r === "utf16le" || r === "utf-16le")) {
|
|
1020
|
+
if (i.length < 2 || e.length < 2)
|
|
978
1021
|
return -1;
|
|
979
|
-
u = 2, p /= 2,
|
|
1022
|
+
u = 2, p /= 2, E /= 2, t /= 2;
|
|
980
1023
|
}
|
|
981
1024
|
function k(S, T) {
|
|
982
1025
|
return u === 1 ? S[T] : S.readUInt16BE(T * u);
|
|
@@ -985,16 +1028,16 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
985
1028
|
if (a) {
|
|
986
1029
|
let S = -1;
|
|
987
1030
|
for ($ = t; $ < p; $++)
|
|
988
|
-
if (k(
|
|
989
|
-
if (S === -1 && (S = $), $ - S + 1 ===
|
|
1031
|
+
if (k(i, $) === k(e, S === -1 ? 0 : $ - S)) {
|
|
1032
|
+
if (S === -1 && (S = $), $ - S + 1 === E)
|
|
990
1033
|
return S * u;
|
|
991
1034
|
} else
|
|
992
1035
|
S !== -1 && ($ -= $ - S), S = -1;
|
|
993
1036
|
} else
|
|
994
|
-
for (t +
|
|
1037
|
+
for (t + E > p && (t = p - E), $ = t; $ >= 0; $--) {
|
|
995
1038
|
let S = !0;
|
|
996
|
-
for (let T = 0; T <
|
|
997
|
-
if (k(
|
|
1039
|
+
for (let T = 0; T < E; T++)
|
|
1040
|
+
if (k(i, $ + T) !== k(e, T)) {
|
|
998
1041
|
S = !1;
|
|
999
1042
|
break;
|
|
1000
1043
|
}
|
|
@@ -1003,74 +1046,74 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
1003
1046
|
}
|
|
1004
1047
|
return -1;
|
|
1005
1048
|
}
|
|
1006
|
-
o.prototype.includes = function(e, t,
|
|
1007
|
-
return this.indexOf(e, t,
|
|
1008
|
-
}, o.prototype.indexOf = function(e, t,
|
|
1009
|
-
return
|
|
1010
|
-
}, o.prototype.lastIndexOf = function(e, t,
|
|
1011
|
-
return
|
|
1049
|
+
o.prototype.includes = function(e, t, r) {
|
|
1050
|
+
return this.indexOf(e, t, r) !== -1;
|
|
1051
|
+
}, o.prototype.indexOf = function(e, t, r) {
|
|
1052
|
+
return Me(this, e, t, r, !0);
|
|
1053
|
+
}, o.prototype.lastIndexOf = function(e, t, r) {
|
|
1054
|
+
return Me(this, e, t, r, !1);
|
|
1012
1055
|
};
|
|
1013
|
-
function
|
|
1056
|
+
function _t(i, e, t, r) {
|
|
1014
1057
|
t = Number(t) || 0;
|
|
1015
|
-
const a =
|
|
1016
|
-
|
|
1058
|
+
const a = i.length - t;
|
|
1059
|
+
r ? (r = Number(r), r > a && (r = a)) : r = a;
|
|
1017
1060
|
const u = e.length;
|
|
1018
|
-
|
|
1061
|
+
r > u / 2 && (r = u / 2);
|
|
1019
1062
|
let p;
|
|
1020
|
-
for (p = 0; p <
|
|
1021
|
-
const
|
|
1022
|
-
if (
|
|
1063
|
+
for (p = 0; p < r; ++p) {
|
|
1064
|
+
const E = parseInt(e.substr(p * 2, 2), 16);
|
|
1065
|
+
if (Ce(E))
|
|
1023
1066
|
return p;
|
|
1024
|
-
|
|
1067
|
+
i[t + p] = E;
|
|
1025
1068
|
}
|
|
1026
1069
|
return p;
|
|
1027
1070
|
}
|
|
1028
|
-
function
|
|
1029
|
-
return
|
|
1071
|
+
function Ct(i, e, t, r) {
|
|
1072
|
+
return we(_e(e, i.length - t), i, t, r);
|
|
1030
1073
|
}
|
|
1031
|
-
function
|
|
1032
|
-
return
|
|
1074
|
+
function Tt(i, e, t, r) {
|
|
1075
|
+
return we(Pt(e), i, t, r);
|
|
1033
1076
|
}
|
|
1034
|
-
function
|
|
1035
|
-
return
|
|
1077
|
+
function Ft(i, e, t, r) {
|
|
1078
|
+
return we(Je(e), i, t, r);
|
|
1036
1079
|
}
|
|
1037
|
-
function
|
|
1038
|
-
return
|
|
1080
|
+
function $t(i, e, t, r) {
|
|
1081
|
+
return we(Mt(e, i.length - t), i, t, r);
|
|
1039
1082
|
}
|
|
1040
|
-
o.prototype.write = function(e, t,
|
|
1083
|
+
o.prototype.write = function(e, t, r, a) {
|
|
1041
1084
|
if (t === void 0)
|
|
1042
|
-
a = "utf8",
|
|
1043
|
-
else if (
|
|
1044
|
-
a = t,
|
|
1085
|
+
a = "utf8", r = this.length, t = 0;
|
|
1086
|
+
else if (r === void 0 && typeof t == "string")
|
|
1087
|
+
a = t, r = this.length, t = 0;
|
|
1045
1088
|
else if (isFinite(t))
|
|
1046
|
-
t = t >>> 0, isFinite(
|
|
1089
|
+
t = t >>> 0, isFinite(r) ? (r = r >>> 0, a === void 0 && (a = "utf8")) : (a = r, r = void 0);
|
|
1047
1090
|
else
|
|
1048
1091
|
throw new Error(
|
|
1049
1092
|
"Buffer.write(string, encoding, offset[, length]) is no longer supported"
|
|
1050
1093
|
);
|
|
1051
1094
|
const u = this.length - t;
|
|
1052
|
-
if ((
|
|
1095
|
+
if ((r === void 0 || r > u) && (r = u), e.length > 0 && (r < 0 || t < 0) || t > this.length)
|
|
1053
1096
|
throw new RangeError("Attempt to write outside buffer bounds");
|
|
1054
1097
|
a || (a = "utf8");
|
|
1055
1098
|
let p = !1;
|
|
1056
1099
|
for (; ; )
|
|
1057
1100
|
switch (a) {
|
|
1058
1101
|
case "hex":
|
|
1059
|
-
return
|
|
1102
|
+
return _t(this, e, t, r);
|
|
1060
1103
|
case "utf8":
|
|
1061
1104
|
case "utf-8":
|
|
1062
|
-
return
|
|
1105
|
+
return Ct(this, e, t, r);
|
|
1063
1106
|
case "ascii":
|
|
1064
1107
|
case "latin1":
|
|
1065
1108
|
case "binary":
|
|
1066
|
-
return
|
|
1109
|
+
return Tt(this, e, t, r);
|
|
1067
1110
|
case "base64":
|
|
1068
|
-
return
|
|
1111
|
+
return Ft(this, e, t, r);
|
|
1069
1112
|
case "ucs2":
|
|
1070
1113
|
case "ucs-2":
|
|
1071
1114
|
case "utf16le":
|
|
1072
1115
|
case "utf-16le":
|
|
1073
|
-
return
|
|
1116
|
+
return $t(this, e, t, r);
|
|
1074
1117
|
default:
|
|
1075
1118
|
if (p)
|
|
1076
1119
|
throw new TypeError("Unknown encoding: " + a);
|
|
@@ -1082,98 +1125,98 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
1082
1125
|
data: Array.prototype.slice.call(this._arr || this, 0)
|
|
1083
1126
|
};
|
|
1084
1127
|
};
|
|
1085
|
-
function
|
|
1086
|
-
return e === 0 && t ===
|
|
1128
|
+
function kt(i, e, t) {
|
|
1129
|
+
return e === 0 && t === i.length ? n.fromByteArray(i) : n.fromByteArray(i.slice(e, t));
|
|
1087
1130
|
}
|
|
1088
|
-
function
|
|
1089
|
-
t = Math.min(
|
|
1090
|
-
const
|
|
1131
|
+
function Ge(i, e, t) {
|
|
1132
|
+
t = Math.min(i.length, t);
|
|
1133
|
+
const r = [];
|
|
1091
1134
|
let a = e;
|
|
1092
1135
|
for (; a < t; ) {
|
|
1093
|
-
const u =
|
|
1094
|
-
let p = null,
|
|
1095
|
-
if (a +
|
|
1136
|
+
const u = i[a];
|
|
1137
|
+
let p = null, E = u > 239 ? 4 : u > 223 ? 3 : u > 191 ? 2 : 1;
|
|
1138
|
+
if (a + E <= t) {
|
|
1096
1139
|
let k, $, S, T;
|
|
1097
|
-
switch (
|
|
1140
|
+
switch (E) {
|
|
1098
1141
|
case 1:
|
|
1099
1142
|
u < 128 && (p = u);
|
|
1100
1143
|
break;
|
|
1101
1144
|
case 2:
|
|
1102
|
-
k =
|
|
1145
|
+
k = i[a + 1], (k & 192) === 128 && (T = (u & 31) << 6 | k & 63, T > 127 && (p = T));
|
|
1103
1146
|
break;
|
|
1104
1147
|
case 3:
|
|
1105
|
-
k =
|
|
1148
|
+
k = i[a + 1], $ = i[a + 2], (k & 192) === 128 && ($ & 192) === 128 && (T = (u & 15) << 12 | (k & 63) << 6 | $ & 63, T > 2047 && (T < 55296 || T > 57343) && (p = T));
|
|
1106
1149
|
break;
|
|
1107
1150
|
case 4:
|
|
1108
|
-
k =
|
|
1151
|
+
k = i[a + 1], $ = i[a + 2], S = i[a + 3], (k & 192) === 128 && ($ & 192) === 128 && (S & 192) === 128 && (T = (u & 15) << 18 | (k & 63) << 12 | ($ & 63) << 6 | S & 63, T > 65535 && T < 1114112 && (p = T));
|
|
1109
1152
|
}
|
|
1110
1153
|
}
|
|
1111
|
-
p === null ? (p = 65533,
|
|
1154
|
+
p === null ? (p = 65533, E = 1) : p > 65535 && (p -= 65536, r.push(p >>> 10 & 1023 | 55296), p = 56320 | p & 1023), r.push(p), a += E;
|
|
1112
1155
|
}
|
|
1113
|
-
return
|
|
1114
|
-
}
|
|
1115
|
-
const
|
|
1116
|
-
function
|
|
1117
|
-
const e =
|
|
1118
|
-
if (e <=
|
|
1119
|
-
return String.fromCharCode.apply(String,
|
|
1120
|
-
let t = "",
|
|
1121
|
-
for (;
|
|
1156
|
+
return St(r);
|
|
1157
|
+
}
|
|
1158
|
+
const We = 4096;
|
|
1159
|
+
function St(i) {
|
|
1160
|
+
const e = i.length;
|
|
1161
|
+
if (e <= We)
|
|
1162
|
+
return String.fromCharCode.apply(String, i);
|
|
1163
|
+
let t = "", r = 0;
|
|
1164
|
+
for (; r < e; )
|
|
1122
1165
|
t += String.fromCharCode.apply(
|
|
1123
1166
|
String,
|
|
1124
|
-
|
|
1167
|
+
i.slice(r, r += We)
|
|
1125
1168
|
);
|
|
1126
1169
|
return t;
|
|
1127
1170
|
}
|
|
1128
|
-
function
|
|
1129
|
-
let
|
|
1130
|
-
t = Math.min(
|
|
1171
|
+
function Lt(i, e, t) {
|
|
1172
|
+
let r = "";
|
|
1173
|
+
t = Math.min(i.length, t);
|
|
1131
1174
|
for (let a = e; a < t; ++a)
|
|
1132
|
-
|
|
1133
|
-
return
|
|
1175
|
+
r += String.fromCharCode(i[a] & 127);
|
|
1176
|
+
return r;
|
|
1134
1177
|
}
|
|
1135
|
-
function
|
|
1136
|
-
let
|
|
1137
|
-
t = Math.min(
|
|
1178
|
+
function Rt(i, e, t) {
|
|
1179
|
+
let r = "";
|
|
1180
|
+
t = Math.min(i.length, t);
|
|
1138
1181
|
for (let a = e; a < t; ++a)
|
|
1139
|
-
|
|
1140
|
-
return
|
|
1182
|
+
r += String.fromCharCode(i[a]);
|
|
1183
|
+
return r;
|
|
1141
1184
|
}
|
|
1142
|
-
function
|
|
1143
|
-
const
|
|
1144
|
-
(!e || e < 0) && (e = 0), (!t || t < 0 || t >
|
|
1185
|
+
function Nt(i, e, t) {
|
|
1186
|
+
const r = i.length;
|
|
1187
|
+
(!e || e < 0) && (e = 0), (!t || t < 0 || t > r) && (t = r);
|
|
1145
1188
|
let a = "";
|
|
1146
1189
|
for (let u = e; u < t; ++u)
|
|
1147
|
-
a +=
|
|
1190
|
+
a += qt[i[u]];
|
|
1148
1191
|
return a;
|
|
1149
1192
|
}
|
|
1150
|
-
function
|
|
1151
|
-
const
|
|
1193
|
+
function Ut(i, e, t) {
|
|
1194
|
+
const r = i.slice(e, t);
|
|
1152
1195
|
let a = "";
|
|
1153
|
-
for (let u = 0; u <
|
|
1154
|
-
a += String.fromCharCode(
|
|
1196
|
+
for (let u = 0; u < r.length - 1; u += 2)
|
|
1197
|
+
a += String.fromCharCode(r[u] + r[u + 1] * 256);
|
|
1155
1198
|
return a;
|
|
1156
1199
|
}
|
|
1157
1200
|
o.prototype.slice = function(e, t) {
|
|
1158
|
-
const
|
|
1159
|
-
e = ~~e, t = t === void 0 ?
|
|
1201
|
+
const r = this.length;
|
|
1202
|
+
e = ~~e, t = t === void 0 ? r : ~~t, e < 0 ? (e += r, e < 0 && (e = 0)) : e > r && (e = r), t < 0 ? (t += r, t < 0 && (t = 0)) : t > r && (t = r), t < e && (t = e);
|
|
1160
1203
|
const a = this.subarray(e, t);
|
|
1161
1204
|
return Object.setPrototypeOf(a, o.prototype), a;
|
|
1162
1205
|
};
|
|
1163
|
-
function N(
|
|
1164
|
-
if (
|
|
1206
|
+
function N(i, e, t) {
|
|
1207
|
+
if (i % 1 !== 0 || i < 0)
|
|
1165
1208
|
throw new RangeError("offset is not uint");
|
|
1166
|
-
if (
|
|
1209
|
+
if (i + e > t)
|
|
1167
1210
|
throw new RangeError("Trying to access beyond buffer length");
|
|
1168
1211
|
}
|
|
1169
|
-
o.prototype.readUintLE = o.prototype.readUIntLE = function(e, t,
|
|
1170
|
-
e = e >>> 0, t = t >>> 0,
|
|
1212
|
+
o.prototype.readUintLE = o.prototype.readUIntLE = function(e, t, r) {
|
|
1213
|
+
e = e >>> 0, t = t >>> 0, r || N(e, t, this.length);
|
|
1171
1214
|
let a = this[e], u = 1, p = 0;
|
|
1172
1215
|
for (; ++p < t && (u *= 256); )
|
|
1173
1216
|
a += this[e + p] * u;
|
|
1174
1217
|
return a;
|
|
1175
|
-
}, o.prototype.readUintBE = o.prototype.readUIntBE = function(e, t,
|
|
1176
|
-
e = e >>> 0, t = t >>> 0,
|
|
1218
|
+
}, o.prototype.readUintBE = o.prototype.readUIntBE = function(e, t, r) {
|
|
1219
|
+
e = e >>> 0, t = t >>> 0, r || N(e, t, this.length);
|
|
1177
1220
|
let a = this[e + --t], u = 1;
|
|
1178
1221
|
for (; t > 0 && (u *= 256); )
|
|
1179
1222
|
a += this[e + --t] * u;
|
|
@@ -1188,26 +1231,26 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
1188
1231
|
return e = e >>> 0, t || N(e, 4, this.length), (this[e] | this[e + 1] << 8 | this[e + 2] << 16) + this[e + 3] * 16777216;
|
|
1189
1232
|
}, o.prototype.readUint32BE = o.prototype.readUInt32BE = function(e, t) {
|
|
1190
1233
|
return e = e >>> 0, t || N(e, 4, this.length), this[e] * 16777216 + (this[e + 1] << 16 | this[e + 2] << 8 | this[e + 3]);
|
|
1191
|
-
}, o.prototype.readBigUInt64LE =
|
|
1192
|
-
e = e >>> 0,
|
|
1193
|
-
const t = this[e],
|
|
1194
|
-
(t === void 0 ||
|
|
1195
|
-
const a = t + this[++e] * 2 ** 8 + this[++e] * 2 ** 16 + this[++e] * 2 ** 24, u = this[++e] + this[++e] * 2 ** 8 + this[++e] * 2 ** 16 +
|
|
1234
|
+
}, o.prototype.readBigUInt64LE = Z(function(e) {
|
|
1235
|
+
e = e >>> 0, se(e, "offset");
|
|
1236
|
+
const t = this[e], r = this[e + 7];
|
|
1237
|
+
(t === void 0 || r === void 0) && fe(e, this.length - 8);
|
|
1238
|
+
const a = t + this[++e] * 2 ** 8 + this[++e] * 2 ** 16 + this[++e] * 2 ** 24, u = this[++e] + this[++e] * 2 ** 8 + this[++e] * 2 ** 16 + r * 2 ** 24;
|
|
1196
1239
|
return BigInt(a) + (BigInt(u) << BigInt(32));
|
|
1197
|
-
}), o.prototype.readBigUInt64BE =
|
|
1198
|
-
e = e >>> 0,
|
|
1199
|
-
const t = this[e],
|
|
1200
|
-
(t === void 0 ||
|
|
1201
|
-
const a = t * 2 ** 24 + this[++e] * 2 ** 16 + this[++e] * 2 ** 8 + this[++e], u = this[++e] * 2 ** 24 + this[++e] * 2 ** 16 + this[++e] * 2 ** 8 +
|
|
1240
|
+
}), o.prototype.readBigUInt64BE = Z(function(e) {
|
|
1241
|
+
e = e >>> 0, se(e, "offset");
|
|
1242
|
+
const t = this[e], r = this[e + 7];
|
|
1243
|
+
(t === void 0 || r === void 0) && fe(e, this.length - 8);
|
|
1244
|
+
const a = t * 2 ** 24 + this[++e] * 2 ** 16 + this[++e] * 2 ** 8 + this[++e], u = this[++e] * 2 ** 24 + this[++e] * 2 ** 16 + this[++e] * 2 ** 8 + r;
|
|
1202
1245
|
return (BigInt(a) << BigInt(32)) + BigInt(u);
|
|
1203
|
-
}), o.prototype.readIntLE = function(e, t,
|
|
1204
|
-
e = e >>> 0, t = t >>> 0,
|
|
1246
|
+
}), o.prototype.readIntLE = function(e, t, r) {
|
|
1247
|
+
e = e >>> 0, t = t >>> 0, r || N(e, t, this.length);
|
|
1205
1248
|
let a = this[e], u = 1, p = 0;
|
|
1206
1249
|
for (; ++p < t && (u *= 256); )
|
|
1207
1250
|
a += this[e + p] * u;
|
|
1208
1251
|
return u *= 128, a >= u && (a -= Math.pow(2, 8 * t)), a;
|
|
1209
|
-
}, o.prototype.readIntBE = function(e, t,
|
|
1210
|
-
e = e >>> 0, t = t >>> 0,
|
|
1252
|
+
}, o.prototype.readIntBE = function(e, t, r) {
|
|
1253
|
+
e = e >>> 0, t = t >>> 0, r || N(e, t, this.length);
|
|
1211
1254
|
let a = t, u = 1, p = this[e + --a];
|
|
1212
1255
|
for (; a > 0 && (u *= 256); )
|
|
1213
1256
|
p += this[e + --a] * u;
|
|
@@ -1216,168 +1259,168 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
1216
1259
|
return e = e >>> 0, t || N(e, 1, this.length), this[e] & 128 ? (255 - this[e] + 1) * -1 : this[e];
|
|
1217
1260
|
}, o.prototype.readInt16LE = function(e, t) {
|
|
1218
1261
|
e = e >>> 0, t || N(e, 2, this.length);
|
|
1219
|
-
const
|
|
1220
|
-
return
|
|
1262
|
+
const r = this[e] | this[e + 1] << 8;
|
|
1263
|
+
return r & 32768 ? r | 4294901760 : r;
|
|
1221
1264
|
}, o.prototype.readInt16BE = function(e, t) {
|
|
1222
1265
|
e = e >>> 0, t || N(e, 2, this.length);
|
|
1223
|
-
const
|
|
1224
|
-
return
|
|
1266
|
+
const r = this[e + 1] | this[e] << 8;
|
|
1267
|
+
return r & 32768 ? r | 4294901760 : r;
|
|
1225
1268
|
}, o.prototype.readInt32LE = function(e, t) {
|
|
1226
1269
|
return e = e >>> 0, t || N(e, 4, this.length), this[e] | this[e + 1] << 8 | this[e + 2] << 16 | this[e + 3] << 24;
|
|
1227
1270
|
}, o.prototype.readInt32BE = function(e, t) {
|
|
1228
1271
|
return e = e >>> 0, t || N(e, 4, this.length), this[e] << 24 | this[e + 1] << 16 | this[e + 2] << 8 | this[e + 3];
|
|
1229
|
-
}, o.prototype.readBigInt64LE =
|
|
1230
|
-
e = e >>> 0,
|
|
1231
|
-
const t = this[e],
|
|
1232
|
-
(t === void 0 ||
|
|
1233
|
-
const a = this[e + 4] + this[e + 5] * 2 ** 8 + this[e + 6] * 2 ** 16 + (
|
|
1272
|
+
}, o.prototype.readBigInt64LE = Z(function(e) {
|
|
1273
|
+
e = e >>> 0, se(e, "offset");
|
|
1274
|
+
const t = this[e], r = this[e + 7];
|
|
1275
|
+
(t === void 0 || r === void 0) && fe(e, this.length - 8);
|
|
1276
|
+
const a = this[e + 4] + this[e + 5] * 2 ** 8 + this[e + 6] * 2 ** 16 + (r << 24);
|
|
1234
1277
|
return (BigInt(a) << BigInt(32)) + BigInt(t + this[++e] * 2 ** 8 + this[++e] * 2 ** 16 + this[++e] * 2 ** 24);
|
|
1235
|
-
}), o.prototype.readBigInt64BE =
|
|
1236
|
-
e = e >>> 0,
|
|
1237
|
-
const t = this[e],
|
|
1238
|
-
(t === void 0 ||
|
|
1278
|
+
}), o.prototype.readBigInt64BE = Z(function(e) {
|
|
1279
|
+
e = e >>> 0, se(e, "offset");
|
|
1280
|
+
const t = this[e], r = this[e + 7];
|
|
1281
|
+
(t === void 0 || r === void 0) && fe(e, this.length - 8);
|
|
1239
1282
|
const a = (t << 24) + // Overflow
|
|
1240
1283
|
this[++e] * 2 ** 16 + this[++e] * 2 ** 8 + this[++e];
|
|
1241
|
-
return (BigInt(a) << BigInt(32)) + BigInt(this[++e] * 2 ** 24 + this[++e] * 2 ** 16 + this[++e] * 2 ** 8 +
|
|
1284
|
+
return (BigInt(a) << BigInt(32)) + BigInt(this[++e] * 2 ** 24 + this[++e] * 2 ** 16 + this[++e] * 2 ** 8 + r);
|
|
1242
1285
|
}), o.prototype.readFloatLE = function(e, t) {
|
|
1243
|
-
return e = e >>> 0, t || N(e, 4, this.length),
|
|
1286
|
+
return e = e >>> 0, t || N(e, 4, this.length), l.read(this, e, !0, 23, 4);
|
|
1244
1287
|
}, o.prototype.readFloatBE = function(e, t) {
|
|
1245
|
-
return e = e >>> 0, t || N(e, 4, this.length),
|
|
1288
|
+
return e = e >>> 0, t || N(e, 4, this.length), l.read(this, e, !1, 23, 4);
|
|
1246
1289
|
}, o.prototype.readDoubleLE = function(e, t) {
|
|
1247
|
-
return e = e >>> 0, t || N(e, 8, this.length),
|
|
1290
|
+
return e = e >>> 0, t || N(e, 8, this.length), l.read(this, e, !0, 52, 8);
|
|
1248
1291
|
}, o.prototype.readDoubleBE = function(e, t) {
|
|
1249
|
-
return e = e >>> 0, t || N(e, 8, this.length),
|
|
1292
|
+
return e = e >>> 0, t || N(e, 8, this.length), l.read(this, e, !1, 52, 8);
|
|
1250
1293
|
};
|
|
1251
|
-
function O(
|
|
1252
|
-
if (!o.isBuffer(
|
|
1294
|
+
function O(i, e, t, r, a, u) {
|
|
1295
|
+
if (!o.isBuffer(i))
|
|
1253
1296
|
throw new TypeError('"buffer" argument must be a Buffer instance');
|
|
1254
1297
|
if (e > a || e < u)
|
|
1255
1298
|
throw new RangeError('"value" argument is out of bounds');
|
|
1256
|
-
if (t +
|
|
1299
|
+
if (t + r > i.length)
|
|
1257
1300
|
throw new RangeError("Index out of range");
|
|
1258
1301
|
}
|
|
1259
|
-
o.prototype.writeUintLE = o.prototype.writeUIntLE = function(e, t,
|
|
1260
|
-
if (e = +e, t = t >>> 0,
|
|
1261
|
-
const
|
|
1262
|
-
O(this, e, t,
|
|
1302
|
+
o.prototype.writeUintLE = o.prototype.writeUIntLE = function(e, t, r, a) {
|
|
1303
|
+
if (e = +e, t = t >>> 0, r = r >>> 0, !a) {
|
|
1304
|
+
const E = Math.pow(2, 8 * r) - 1;
|
|
1305
|
+
O(this, e, t, r, E, 0);
|
|
1263
1306
|
}
|
|
1264
1307
|
let u = 1, p = 0;
|
|
1265
|
-
for (this[t] = e & 255; ++p <
|
|
1308
|
+
for (this[t] = e & 255; ++p < r && (u *= 256); )
|
|
1266
1309
|
this[t + p] = e / u & 255;
|
|
1267
|
-
return t +
|
|
1268
|
-
}, o.prototype.writeUintBE = o.prototype.writeUIntBE = function(e, t,
|
|
1269
|
-
if (e = +e, t = t >>> 0,
|
|
1270
|
-
const
|
|
1271
|
-
O(this, e, t,
|
|
1310
|
+
return t + r;
|
|
1311
|
+
}, o.prototype.writeUintBE = o.prototype.writeUIntBE = function(e, t, r, a) {
|
|
1312
|
+
if (e = +e, t = t >>> 0, r = r >>> 0, !a) {
|
|
1313
|
+
const E = Math.pow(2, 8 * r) - 1;
|
|
1314
|
+
O(this, e, t, r, E, 0);
|
|
1272
1315
|
}
|
|
1273
|
-
let u =
|
|
1316
|
+
let u = r - 1, p = 1;
|
|
1274
1317
|
for (this[t + u] = e & 255; --u >= 0 && (p *= 256); )
|
|
1275
1318
|
this[t + u] = e / p & 255;
|
|
1276
|
-
return t +
|
|
1277
|
-
}, o.prototype.writeUint8 = o.prototype.writeUInt8 = function(e, t,
|
|
1278
|
-
return e = +e, t = t >>> 0,
|
|
1279
|
-
}, o.prototype.writeUint16LE = o.prototype.writeUInt16LE = function(e, t,
|
|
1280
|
-
return e = +e, t = t >>> 0,
|
|
1281
|
-
}, o.prototype.writeUint16BE = o.prototype.writeUInt16BE = function(e, t,
|
|
1282
|
-
return e = +e, t = t >>> 0,
|
|
1283
|
-
}, o.prototype.writeUint32LE = o.prototype.writeUInt32LE = function(e, t,
|
|
1284
|
-
return e = +e, t = t >>> 0,
|
|
1285
|
-
}, o.prototype.writeUint32BE = o.prototype.writeUInt32BE = function(e, t,
|
|
1286
|
-
return e = +e, t = t >>> 0,
|
|
1319
|
+
return t + r;
|
|
1320
|
+
}, o.prototype.writeUint8 = o.prototype.writeUInt8 = function(e, t, r) {
|
|
1321
|
+
return e = +e, t = t >>> 0, r || O(this, e, t, 1, 255, 0), this[t] = e & 255, t + 1;
|
|
1322
|
+
}, o.prototype.writeUint16LE = o.prototype.writeUInt16LE = function(e, t, r) {
|
|
1323
|
+
return e = +e, t = t >>> 0, r || O(this, e, t, 2, 65535, 0), this[t] = e & 255, this[t + 1] = e >>> 8, t + 2;
|
|
1324
|
+
}, o.prototype.writeUint16BE = o.prototype.writeUInt16BE = function(e, t, r) {
|
|
1325
|
+
return e = +e, t = t >>> 0, r || O(this, e, t, 2, 65535, 0), this[t] = e >>> 8, this[t + 1] = e & 255, t + 2;
|
|
1326
|
+
}, o.prototype.writeUint32LE = o.prototype.writeUInt32LE = function(e, t, r) {
|
|
1327
|
+
return e = +e, t = t >>> 0, r || O(this, e, t, 4, 4294967295, 0), this[t + 3] = e >>> 24, this[t + 2] = e >>> 16, this[t + 1] = e >>> 8, this[t] = e & 255, t + 4;
|
|
1328
|
+
}, o.prototype.writeUint32BE = o.prototype.writeUInt32BE = function(e, t, r) {
|
|
1329
|
+
return e = +e, t = t >>> 0, r || O(this, e, t, 4, 4294967295, 0), this[t] = e >>> 24, this[t + 1] = e >>> 16, this[t + 2] = e >>> 8, this[t + 3] = e & 255, t + 4;
|
|
1287
1330
|
};
|
|
1288
|
-
function
|
|
1289
|
-
|
|
1331
|
+
function je(i, e, t, r, a) {
|
|
1332
|
+
Xe(e, r, a, i, t, 7);
|
|
1290
1333
|
let u = Number(e & BigInt(4294967295));
|
|
1291
|
-
|
|
1334
|
+
i[t++] = u, u = u >> 8, i[t++] = u, u = u >> 8, i[t++] = u, u = u >> 8, i[t++] = u;
|
|
1292
1335
|
let p = Number(e >> BigInt(32) & BigInt(4294967295));
|
|
1293
|
-
return
|
|
1336
|
+
return i[t++] = p, p = p >> 8, i[t++] = p, p = p >> 8, i[t++] = p, p = p >> 8, i[t++] = p, t;
|
|
1294
1337
|
}
|
|
1295
|
-
function
|
|
1296
|
-
|
|
1338
|
+
function He(i, e, t, r, a) {
|
|
1339
|
+
Xe(e, r, a, i, t, 7);
|
|
1297
1340
|
let u = Number(e & BigInt(4294967295));
|
|
1298
|
-
|
|
1341
|
+
i[t + 7] = u, u = u >> 8, i[t + 6] = u, u = u >> 8, i[t + 5] = u, u = u >> 8, i[t + 4] = u;
|
|
1299
1342
|
let p = Number(e >> BigInt(32) & BigInt(4294967295));
|
|
1300
|
-
return
|
|
1343
|
+
return i[t + 3] = p, p = p >> 8, i[t + 2] = p, p = p >> 8, i[t + 1] = p, p = p >> 8, i[t] = p, t + 8;
|
|
1301
1344
|
}
|
|
1302
|
-
o.prototype.writeBigUInt64LE =
|
|
1303
|
-
return
|
|
1304
|
-
}), o.prototype.writeBigUInt64BE =
|
|
1305
|
-
return
|
|
1306
|
-
}), o.prototype.writeIntLE = function(e, t,
|
|
1345
|
+
o.prototype.writeBigUInt64LE = Z(function(e, t = 0) {
|
|
1346
|
+
return je(this, e, t, BigInt(0), BigInt("0xffffffffffffffff"));
|
|
1347
|
+
}), o.prototype.writeBigUInt64BE = Z(function(e, t = 0) {
|
|
1348
|
+
return He(this, e, t, BigInt(0), BigInt("0xffffffffffffffff"));
|
|
1349
|
+
}), o.prototype.writeIntLE = function(e, t, r, a) {
|
|
1307
1350
|
if (e = +e, t = t >>> 0, !a) {
|
|
1308
|
-
const k = Math.pow(2, 8 *
|
|
1309
|
-
O(this, e, t,
|
|
1351
|
+
const k = Math.pow(2, 8 * r - 1);
|
|
1352
|
+
O(this, e, t, r, k - 1, -k);
|
|
1310
1353
|
}
|
|
1311
|
-
let u = 0, p = 1,
|
|
1312
|
-
for (this[t] = e & 255; ++u <
|
|
1313
|
-
e < 0 &&
|
|
1314
|
-
return t +
|
|
1315
|
-
}, o.prototype.writeIntBE = function(e, t,
|
|
1354
|
+
let u = 0, p = 1, E = 0;
|
|
1355
|
+
for (this[t] = e & 255; ++u < r && (p *= 256); )
|
|
1356
|
+
e < 0 && E === 0 && this[t + u - 1] !== 0 && (E = 1), this[t + u] = (e / p >> 0) - E & 255;
|
|
1357
|
+
return t + r;
|
|
1358
|
+
}, o.prototype.writeIntBE = function(e, t, r, a) {
|
|
1316
1359
|
if (e = +e, t = t >>> 0, !a) {
|
|
1317
|
-
const k = Math.pow(2, 8 *
|
|
1318
|
-
O(this, e, t,
|
|
1360
|
+
const k = Math.pow(2, 8 * r - 1);
|
|
1361
|
+
O(this, e, t, r, k - 1, -k);
|
|
1319
1362
|
}
|
|
1320
|
-
let u =
|
|
1363
|
+
let u = r - 1, p = 1, E = 0;
|
|
1321
1364
|
for (this[t + u] = e & 255; --u >= 0 && (p *= 256); )
|
|
1322
|
-
e < 0 &&
|
|
1323
|
-
return t +
|
|
1324
|
-
}, o.prototype.writeInt8 = function(e, t,
|
|
1325
|
-
return e = +e, t = t >>> 0,
|
|
1326
|
-
}, o.prototype.writeInt16LE = function(e, t,
|
|
1327
|
-
return e = +e, t = t >>> 0,
|
|
1328
|
-
}, o.prototype.writeInt16BE = function(e, t,
|
|
1329
|
-
return e = +e, t = t >>> 0,
|
|
1330
|
-
}, o.prototype.writeInt32LE = function(e, t,
|
|
1331
|
-
return e = +e, t = t >>> 0,
|
|
1332
|
-
}, o.prototype.writeInt32BE = function(e, t,
|
|
1333
|
-
return e = +e, t = t >>> 0,
|
|
1334
|
-
}, o.prototype.writeBigInt64LE =
|
|
1335
|
-
return
|
|
1336
|
-
}), o.prototype.writeBigInt64BE =
|
|
1337
|
-
return
|
|
1365
|
+
e < 0 && E === 0 && this[t + u + 1] !== 0 && (E = 1), this[t + u] = (e / p >> 0) - E & 255;
|
|
1366
|
+
return t + r;
|
|
1367
|
+
}, o.prototype.writeInt8 = function(e, t, r) {
|
|
1368
|
+
return e = +e, t = t >>> 0, r || O(this, e, t, 1, 127, -128), e < 0 && (e = 255 + e + 1), this[t] = e & 255, t + 1;
|
|
1369
|
+
}, o.prototype.writeInt16LE = function(e, t, r) {
|
|
1370
|
+
return e = +e, t = t >>> 0, r || O(this, e, t, 2, 32767, -32768), this[t] = e & 255, this[t + 1] = e >>> 8, t + 2;
|
|
1371
|
+
}, o.prototype.writeInt16BE = function(e, t, r) {
|
|
1372
|
+
return e = +e, t = t >>> 0, r || O(this, e, t, 2, 32767, -32768), this[t] = e >>> 8, this[t + 1] = e & 255, t + 2;
|
|
1373
|
+
}, o.prototype.writeInt32LE = function(e, t, r) {
|
|
1374
|
+
return e = +e, t = t >>> 0, r || O(this, e, t, 4, 2147483647, -2147483648), this[t] = e & 255, this[t + 1] = e >>> 8, this[t + 2] = e >>> 16, this[t + 3] = e >>> 24, t + 4;
|
|
1375
|
+
}, o.prototype.writeInt32BE = function(e, t, r) {
|
|
1376
|
+
return e = +e, t = t >>> 0, r || O(this, e, t, 4, 2147483647, -2147483648), e < 0 && (e = 4294967295 + e + 1), this[t] = e >>> 24, this[t + 1] = e >>> 16, this[t + 2] = e >>> 8, this[t + 3] = e & 255, t + 4;
|
|
1377
|
+
}, o.prototype.writeBigInt64LE = Z(function(e, t = 0) {
|
|
1378
|
+
return je(this, e, t, -BigInt("0x8000000000000000"), BigInt("0x7fffffffffffffff"));
|
|
1379
|
+
}), o.prototype.writeBigInt64BE = Z(function(e, t = 0) {
|
|
1380
|
+
return He(this, e, t, -BigInt("0x8000000000000000"), BigInt("0x7fffffffffffffff"));
|
|
1338
1381
|
});
|
|
1339
|
-
function
|
|
1340
|
-
if (t +
|
|
1382
|
+
function Ye(i, e, t, r, a, u) {
|
|
1383
|
+
if (t + r > i.length)
|
|
1341
1384
|
throw new RangeError("Index out of range");
|
|
1342
1385
|
if (t < 0)
|
|
1343
1386
|
throw new RangeError("Index out of range");
|
|
1344
1387
|
}
|
|
1345
|
-
function
|
|
1346
|
-
return e = +e, t = t >>> 0, a ||
|
|
1388
|
+
function Ve(i, e, t, r, a) {
|
|
1389
|
+
return e = +e, t = t >>> 0, a || Ye(i, e, t, 4), l.write(i, e, t, r, 23, 4), t + 4;
|
|
1347
1390
|
}
|
|
1348
|
-
o.prototype.writeFloatLE = function(e, t,
|
|
1349
|
-
return
|
|
1350
|
-
}, o.prototype.writeFloatBE = function(e, t,
|
|
1351
|
-
return
|
|
1391
|
+
o.prototype.writeFloatLE = function(e, t, r) {
|
|
1392
|
+
return Ve(this, e, t, !0, r);
|
|
1393
|
+
}, o.prototype.writeFloatBE = function(e, t, r) {
|
|
1394
|
+
return Ve(this, e, t, !1, r);
|
|
1352
1395
|
};
|
|
1353
|
-
function
|
|
1354
|
-
return e = +e, t = t >>> 0, a ||
|
|
1355
|
-
}
|
|
1356
|
-
o.prototype.writeDoubleLE = function(e, t,
|
|
1357
|
-
return
|
|
1358
|
-
}, o.prototype.writeDoubleBE = function(e, t,
|
|
1359
|
-
return
|
|
1360
|
-
}, o.prototype.copy = function(e, t,
|
|
1396
|
+
function Qe(i, e, t, r, a) {
|
|
1397
|
+
return e = +e, t = t >>> 0, a || Ye(i, e, t, 8), l.write(i, e, t, r, 52, 8), t + 8;
|
|
1398
|
+
}
|
|
1399
|
+
o.prototype.writeDoubleLE = function(e, t, r) {
|
|
1400
|
+
return Qe(this, e, t, !0, r);
|
|
1401
|
+
}, o.prototype.writeDoubleBE = function(e, t, r) {
|
|
1402
|
+
return Qe(this, e, t, !1, r);
|
|
1403
|
+
}, o.prototype.copy = function(e, t, r, a) {
|
|
1361
1404
|
if (!o.isBuffer(e))
|
|
1362
1405
|
throw new TypeError("argument should be a Buffer");
|
|
1363
|
-
if (
|
|
1406
|
+
if (r || (r = 0), !a && a !== 0 && (a = this.length), t >= e.length && (t = e.length), t || (t = 0), a > 0 && a < r && (a = r), a === r || e.length === 0 || this.length === 0)
|
|
1364
1407
|
return 0;
|
|
1365
1408
|
if (t < 0)
|
|
1366
1409
|
throw new RangeError("targetStart out of bounds");
|
|
1367
|
-
if (
|
|
1410
|
+
if (r < 0 || r >= this.length)
|
|
1368
1411
|
throw new RangeError("Index out of range");
|
|
1369
1412
|
if (a < 0)
|
|
1370
1413
|
throw new RangeError("sourceEnd out of bounds");
|
|
1371
|
-
a > this.length && (a = this.length), e.length - t < a -
|
|
1372
|
-
const u = a -
|
|
1373
|
-
return this === e && typeof Uint8Array.prototype.copyWithin == "function" ? this.copyWithin(t,
|
|
1414
|
+
a > this.length && (a = this.length), e.length - t < a - r && (a = e.length - t + r);
|
|
1415
|
+
const u = a - r;
|
|
1416
|
+
return this === e && typeof Uint8Array.prototype.copyWithin == "function" ? this.copyWithin(t, r, a) : Uint8Array.prototype.set.call(
|
|
1374
1417
|
e,
|
|
1375
|
-
this.subarray(
|
|
1418
|
+
this.subarray(r, a),
|
|
1376
1419
|
t
|
|
1377
1420
|
), u;
|
|
1378
|
-
}, o.prototype.fill = function(e, t,
|
|
1421
|
+
}, o.prototype.fill = function(e, t, r, a) {
|
|
1379
1422
|
if (typeof e == "string") {
|
|
1380
|
-
if (typeof t == "string" ? (a = t, t = 0,
|
|
1423
|
+
if (typeof t == "string" ? (a = t, t = 0, r = this.length) : typeof r == "string" && (a = r, r = this.length), a !== void 0 && typeof a != "string")
|
|
1381
1424
|
throw new TypeError("encoding must be a string");
|
|
1382
1425
|
if (typeof a == "string" && !o.isEncoding(a))
|
|
1383
1426
|
throw new TypeError("Unknown encoding: " + a);
|
|
@@ -1387,36 +1430,36 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
1387
1430
|
}
|
|
1388
1431
|
} else
|
|
1389
1432
|
typeof e == "number" ? e = e & 255 : typeof e == "boolean" && (e = Number(e));
|
|
1390
|
-
if (t < 0 || this.length < t || this.length <
|
|
1433
|
+
if (t < 0 || this.length < t || this.length < r)
|
|
1391
1434
|
throw new RangeError("Out of range index");
|
|
1392
|
-
if (
|
|
1435
|
+
if (r <= t)
|
|
1393
1436
|
return this;
|
|
1394
|
-
t = t >>> 0,
|
|
1437
|
+
t = t >>> 0, r = r === void 0 ? this.length : r >>> 0, e || (e = 0);
|
|
1395
1438
|
let u;
|
|
1396
1439
|
if (typeof e == "number")
|
|
1397
|
-
for (u = t; u <
|
|
1440
|
+
for (u = t; u < r; ++u)
|
|
1398
1441
|
this[u] = e;
|
|
1399
1442
|
else {
|
|
1400
|
-
const p = o.isBuffer(e) ? e : o.from(e, a),
|
|
1401
|
-
if (
|
|
1443
|
+
const p = o.isBuffer(e) ? e : o.from(e, a), E = p.length;
|
|
1444
|
+
if (E === 0)
|
|
1402
1445
|
throw new TypeError('The value "' + e + '" is invalid for argument "value"');
|
|
1403
|
-
for (u = 0; u <
|
|
1404
|
-
this[u + t] = p[u %
|
|
1446
|
+
for (u = 0; u < r - t; ++u)
|
|
1447
|
+
this[u + t] = p[u % E];
|
|
1405
1448
|
}
|
|
1406
1449
|
return this;
|
|
1407
1450
|
};
|
|
1408
|
-
const
|
|
1409
|
-
function
|
|
1410
|
-
|
|
1451
|
+
const ne = {};
|
|
1452
|
+
function Be(i, e, t) {
|
|
1453
|
+
ne[i] = class extends t {
|
|
1411
1454
|
constructor() {
|
|
1412
1455
|
super(), Object.defineProperty(this, "message", {
|
|
1413
1456
|
value: e.apply(this, arguments),
|
|
1414
1457
|
writable: !0,
|
|
1415
1458
|
configurable: !0
|
|
1416
|
-
}), this.name = `${this.name} [${
|
|
1459
|
+
}), this.name = `${this.name} [${i}]`, this.stack, delete this.name;
|
|
1417
1460
|
}
|
|
1418
1461
|
get code() {
|
|
1419
|
-
return
|
|
1462
|
+
return i;
|
|
1420
1463
|
}
|
|
1421
1464
|
set code(a) {
|
|
1422
1465
|
Object.defineProperty(this, "code", {
|
|
@@ -1427,80 +1470,80 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
1427
1470
|
});
|
|
1428
1471
|
}
|
|
1429
1472
|
toString() {
|
|
1430
|
-
return `${this.name} [${
|
|
1473
|
+
return `${this.name} [${i}]: ${this.message}`;
|
|
1431
1474
|
}
|
|
1432
1475
|
};
|
|
1433
1476
|
}
|
|
1434
|
-
|
|
1477
|
+
Be(
|
|
1435
1478
|
"ERR_BUFFER_OUT_OF_BOUNDS",
|
|
1436
|
-
function(
|
|
1437
|
-
return
|
|
1479
|
+
function(i) {
|
|
1480
|
+
return i ? `${i} is outside of buffer bounds` : "Attempt to access memory outside buffer bounds";
|
|
1438
1481
|
},
|
|
1439
1482
|
RangeError
|
|
1440
|
-
),
|
|
1483
|
+
), Be(
|
|
1441
1484
|
"ERR_INVALID_ARG_TYPE",
|
|
1442
|
-
function(
|
|
1443
|
-
return `The "${
|
|
1485
|
+
function(i, e) {
|
|
1486
|
+
return `The "${i}" argument must be of type number. Received type ${typeof e}`;
|
|
1444
1487
|
},
|
|
1445
1488
|
TypeError
|
|
1446
|
-
),
|
|
1489
|
+
), Be(
|
|
1447
1490
|
"ERR_OUT_OF_RANGE",
|
|
1448
|
-
function(
|
|
1449
|
-
let
|
|
1450
|
-
return Number.isInteger(t) && Math.abs(t) > 2 ** 32 ? a =
|
|
1491
|
+
function(i, e, t) {
|
|
1492
|
+
let r = `The value of "${i}" is out of range.`, a = t;
|
|
1493
|
+
return Number.isInteger(t) && Math.abs(t) > 2 ** 32 ? a = Ke(String(t)) : typeof t == "bigint" && (a = String(t), (t > BigInt(2) ** BigInt(32) || t < -(BigInt(2) ** BigInt(32))) && (a = Ke(a)), a += "n"), r += ` It must be ${e}. Received ${a}`, r;
|
|
1451
1494
|
},
|
|
1452
1495
|
RangeError
|
|
1453
1496
|
);
|
|
1454
|
-
function
|
|
1455
|
-
let e = "", t =
|
|
1456
|
-
const
|
|
1457
|
-
for (; t >=
|
|
1458
|
-
e = `_${
|
|
1459
|
-
return `${
|
|
1460
|
-
}
|
|
1461
|
-
function
|
|
1462
|
-
|
|
1463
|
-
}
|
|
1464
|
-
function
|
|
1465
|
-
if (
|
|
1497
|
+
function Ke(i) {
|
|
1498
|
+
let e = "", t = i.length;
|
|
1499
|
+
const r = i[0] === "-" ? 1 : 0;
|
|
1500
|
+
for (; t >= r + 4; t -= 3)
|
|
1501
|
+
e = `_${i.slice(t - 3, t)}${e}`;
|
|
1502
|
+
return `${i.slice(0, t)}${e}`;
|
|
1503
|
+
}
|
|
1504
|
+
function zt(i, e, t) {
|
|
1505
|
+
se(e, "offset"), (i[e] === void 0 || i[e + t] === void 0) && fe(e, i.length - (t + 1));
|
|
1506
|
+
}
|
|
1507
|
+
function Xe(i, e, t, r, a, u) {
|
|
1508
|
+
if (i > t || i < e) {
|
|
1466
1509
|
const p = typeof e == "bigint" ? "n" : "";
|
|
1467
|
-
let
|
|
1468
|
-
throw u > 3 ? e === 0 || e === BigInt(0) ?
|
|
1510
|
+
let E;
|
|
1511
|
+
throw u > 3 ? e === 0 || e === BigInt(0) ? E = `>= 0${p} and < 2${p} ** ${(u + 1) * 8}${p}` : E = `>= -(2${p} ** ${(u + 1) * 8 - 1}${p}) and < 2 ** ${(u + 1) * 8 - 1}${p}` : E = `>= ${e}${p} and <= ${t}${p}`, new ne.ERR_OUT_OF_RANGE("value", E, i);
|
|
1469
1512
|
}
|
|
1470
|
-
|
|
1513
|
+
zt(r, a, u);
|
|
1471
1514
|
}
|
|
1472
|
-
function
|
|
1473
|
-
if (typeof
|
|
1474
|
-
throw new
|
|
1515
|
+
function se(i, e) {
|
|
1516
|
+
if (typeof i != "number")
|
|
1517
|
+
throw new ne.ERR_INVALID_ARG_TYPE(e, "number", i);
|
|
1475
1518
|
}
|
|
1476
|
-
function
|
|
1477
|
-
throw Math.floor(
|
|
1519
|
+
function fe(i, e, t) {
|
|
1520
|
+
throw Math.floor(i) !== i ? (se(i, t), new ne.ERR_OUT_OF_RANGE(t || "offset", "an integer", i)) : e < 0 ? new ne.ERR_BUFFER_OUT_OF_BOUNDS() : new ne.ERR_OUT_OF_RANGE(
|
|
1478
1521
|
t || "offset",
|
|
1479
1522
|
`>= ${t ? 1 : 0} and <= ${e}`,
|
|
1480
|
-
|
|
1523
|
+
i
|
|
1481
1524
|
);
|
|
1482
1525
|
}
|
|
1483
|
-
const
|
|
1484
|
-
function
|
|
1485
|
-
if (
|
|
1526
|
+
const Ot = /[^+/0-9A-Za-z-_]/g;
|
|
1527
|
+
function Dt(i) {
|
|
1528
|
+
if (i = i.split("=")[0], i = i.trim().replace(Ot, ""), i.length < 2)
|
|
1486
1529
|
return "";
|
|
1487
|
-
for (;
|
|
1488
|
-
|
|
1489
|
-
return
|
|
1530
|
+
for (; i.length % 4 !== 0; )
|
|
1531
|
+
i = i + "=";
|
|
1532
|
+
return i;
|
|
1490
1533
|
}
|
|
1491
|
-
function
|
|
1534
|
+
function _e(i, e) {
|
|
1492
1535
|
e = e || 1 / 0;
|
|
1493
1536
|
let t;
|
|
1494
|
-
const
|
|
1537
|
+
const r = i.length;
|
|
1495
1538
|
let a = null;
|
|
1496
1539
|
const u = [];
|
|
1497
|
-
for (let p = 0; p <
|
|
1498
|
-
if (t =
|
|
1540
|
+
for (let p = 0; p < r; ++p) {
|
|
1541
|
+
if (t = i.charCodeAt(p), t > 55295 && t < 57344) {
|
|
1499
1542
|
if (!a) {
|
|
1500
1543
|
if (t > 56319) {
|
|
1501
1544
|
(e -= 3) > -1 && u.push(239, 191, 189);
|
|
1502
1545
|
continue;
|
|
1503
|
-
} else if (p + 1 ===
|
|
1546
|
+
} else if (p + 1 === r) {
|
|
1504
1547
|
(e -= 3) > -1 && u.push(239, 191, 189);
|
|
1505
1548
|
continue;
|
|
1506
1549
|
}
|
|
@@ -1547,126 +1590,126 @@ Ue.write = function(s, n, c, d, m, g) {
|
|
|
1547
1590
|
}
|
|
1548
1591
|
return u;
|
|
1549
1592
|
}
|
|
1550
|
-
function
|
|
1593
|
+
function Pt(i) {
|
|
1551
1594
|
const e = [];
|
|
1552
|
-
for (let t = 0; t <
|
|
1553
|
-
e.push(
|
|
1595
|
+
for (let t = 0; t < i.length; ++t)
|
|
1596
|
+
e.push(i.charCodeAt(t) & 255);
|
|
1554
1597
|
return e;
|
|
1555
1598
|
}
|
|
1556
|
-
function
|
|
1557
|
-
let t,
|
|
1599
|
+
function Mt(i, e) {
|
|
1600
|
+
let t, r, a;
|
|
1558
1601
|
const u = [];
|
|
1559
|
-
for (let p = 0; p <
|
|
1560
|
-
t =
|
|
1602
|
+
for (let p = 0; p < i.length && !((e -= 2) < 0); ++p)
|
|
1603
|
+
t = i.charCodeAt(p), r = t >> 8, a = t % 256, u.push(a), u.push(r);
|
|
1561
1604
|
return u;
|
|
1562
1605
|
}
|
|
1563
|
-
function
|
|
1564
|
-
return n.toByteArray(
|
|
1606
|
+
function Je(i) {
|
|
1607
|
+
return n.toByteArray(Dt(i));
|
|
1565
1608
|
}
|
|
1566
|
-
function
|
|
1609
|
+
function we(i, e, t, r) {
|
|
1567
1610
|
let a;
|
|
1568
|
-
for (a = 0; a <
|
|
1569
|
-
e[a + t] =
|
|
1611
|
+
for (a = 0; a < r && !(a + t >= e.length || a >= i.length); ++a)
|
|
1612
|
+
e[a + t] = i[a];
|
|
1570
1613
|
return a;
|
|
1571
1614
|
}
|
|
1572
|
-
function
|
|
1573
|
-
return
|
|
1615
|
+
function j(i, e) {
|
|
1616
|
+
return i instanceof e || i != null && i.constructor != null && i.constructor.name != null && i.constructor.name === e.name;
|
|
1574
1617
|
}
|
|
1575
|
-
function
|
|
1576
|
-
return
|
|
1618
|
+
function Ce(i) {
|
|
1619
|
+
return i !== i;
|
|
1577
1620
|
}
|
|
1578
|
-
const
|
|
1579
|
-
const
|
|
1621
|
+
const qt = function() {
|
|
1622
|
+
const i = "0123456789abcdef", e = new Array(256);
|
|
1580
1623
|
for (let t = 0; t < 16; ++t) {
|
|
1581
|
-
const
|
|
1624
|
+
const r = t * 16;
|
|
1582
1625
|
for (let a = 0; a < 16; ++a)
|
|
1583
|
-
e[
|
|
1626
|
+
e[r + a] = i[t] + i[a];
|
|
1584
1627
|
}
|
|
1585
1628
|
return e;
|
|
1586
1629
|
}();
|
|
1587
|
-
function
|
|
1588
|
-
return typeof BigInt > "u" ?
|
|
1630
|
+
function Z(i) {
|
|
1631
|
+
return typeof BigInt > "u" ? Gt : i;
|
|
1589
1632
|
}
|
|
1590
|
-
function
|
|
1633
|
+
function Gt() {
|
|
1591
1634
|
throw new Error("BigInt not supported");
|
|
1592
1635
|
}
|
|
1593
|
-
})(
|
|
1594
|
-
var
|
|
1595
|
-
function
|
|
1636
|
+
})(At);
|
|
1637
|
+
var vt = { exports: {} }, L = vt.exports = {}, H, Y;
|
|
1638
|
+
function Se() {
|
|
1596
1639
|
throw new Error("setTimeout has not been defined");
|
|
1597
1640
|
}
|
|
1598
|
-
function
|
|
1641
|
+
function Le() {
|
|
1599
1642
|
throw new Error("clearTimeout has not been defined");
|
|
1600
1643
|
}
|
|
1601
1644
|
(function() {
|
|
1602
1645
|
try {
|
|
1603
|
-
typeof setTimeout == "function" ?
|
|
1646
|
+
typeof setTimeout == "function" ? H = setTimeout : H = Se;
|
|
1604
1647
|
} catch {
|
|
1605
|
-
|
|
1648
|
+
H = Se;
|
|
1606
1649
|
}
|
|
1607
1650
|
try {
|
|
1608
|
-
typeof clearTimeout == "function" ?
|
|
1651
|
+
typeof clearTimeout == "function" ? Y = clearTimeout : Y = Le;
|
|
1609
1652
|
} catch {
|
|
1610
|
-
|
|
1653
|
+
Y = Le;
|
|
1611
1654
|
}
|
|
1612
1655
|
})();
|
|
1613
|
-
function
|
|
1614
|
-
if (
|
|
1656
|
+
function bt(s) {
|
|
1657
|
+
if (H === setTimeout)
|
|
1615
1658
|
return setTimeout(s, 0);
|
|
1616
|
-
if ((
|
|
1617
|
-
return
|
|
1659
|
+
if ((H === Se || !H) && setTimeout)
|
|
1660
|
+
return H = setTimeout, setTimeout(s, 0);
|
|
1618
1661
|
try {
|
|
1619
|
-
return
|
|
1662
|
+
return H(s, 0);
|
|
1620
1663
|
} catch {
|
|
1621
1664
|
try {
|
|
1622
|
-
return
|
|
1665
|
+
return H.call(null, s, 0);
|
|
1623
1666
|
} catch {
|
|
1624
|
-
return
|
|
1667
|
+
return H.call(this, s, 0);
|
|
1625
1668
|
}
|
|
1626
1669
|
}
|
|
1627
1670
|
}
|
|
1628
|
-
function
|
|
1629
|
-
if (
|
|
1671
|
+
function Wr(s) {
|
|
1672
|
+
if (Y === clearTimeout)
|
|
1630
1673
|
return clearTimeout(s);
|
|
1631
|
-
if ((
|
|
1632
|
-
return
|
|
1674
|
+
if ((Y === Le || !Y) && clearTimeout)
|
|
1675
|
+
return Y = clearTimeout, clearTimeout(s);
|
|
1633
1676
|
try {
|
|
1634
|
-
return
|
|
1677
|
+
return Y(s);
|
|
1635
1678
|
} catch {
|
|
1636
1679
|
try {
|
|
1637
|
-
return
|
|
1680
|
+
return Y.call(null, s);
|
|
1638
1681
|
} catch {
|
|
1639
|
-
return
|
|
1682
|
+
return Y.call(this, s);
|
|
1640
1683
|
}
|
|
1641
1684
|
}
|
|
1642
1685
|
}
|
|
1643
|
-
var
|
|
1644
|
-
function
|
|
1645
|
-
!
|
|
1686
|
+
var K = [], pe = !1, te, xe = -1;
|
|
1687
|
+
function jr() {
|
|
1688
|
+
!pe || !te || (pe = !1, te.length ? K = te.concat(K) : xe = -1, K.length && Et());
|
|
1646
1689
|
}
|
|
1647
|
-
function
|
|
1648
|
-
if (!
|
|
1649
|
-
var s =
|
|
1650
|
-
|
|
1651
|
-
for (var n =
|
|
1652
|
-
for (te =
|
|
1653
|
-
te && te[
|
|
1654
|
-
|
|
1690
|
+
function Et() {
|
|
1691
|
+
if (!pe) {
|
|
1692
|
+
var s = bt(jr);
|
|
1693
|
+
pe = !0;
|
|
1694
|
+
for (var n = K.length; n; ) {
|
|
1695
|
+
for (te = K, K = []; ++xe < n; )
|
|
1696
|
+
te && te[xe].run();
|
|
1697
|
+
xe = -1, n = K.length;
|
|
1655
1698
|
}
|
|
1656
|
-
te = null,
|
|
1699
|
+
te = null, pe = !1, Wr(s);
|
|
1657
1700
|
}
|
|
1658
1701
|
}
|
|
1659
1702
|
L.nextTick = function(s) {
|
|
1660
1703
|
var n = new Array(arguments.length - 1);
|
|
1661
1704
|
if (arguments.length > 1)
|
|
1662
|
-
for (var
|
|
1663
|
-
n[
|
|
1664
|
-
|
|
1705
|
+
for (var l = 1; l < arguments.length; l++)
|
|
1706
|
+
n[l - 1] = arguments[l];
|
|
1707
|
+
K.push(new Bt(s, n)), K.length === 1 && !pe && bt(Et);
|
|
1665
1708
|
};
|
|
1666
|
-
function
|
|
1709
|
+
function Bt(s, n) {
|
|
1667
1710
|
this.fun = s, this.array = n;
|
|
1668
1711
|
}
|
|
1669
|
-
|
|
1712
|
+
Bt.prototype.run = function() {
|
|
1670
1713
|
this.fun.apply(null, this.array);
|
|
1671
1714
|
};
|
|
1672
1715
|
L.title = "browser";
|
|
@@ -1675,17 +1718,17 @@ L.env = {};
|
|
|
1675
1718
|
L.argv = [];
|
|
1676
1719
|
L.version = "";
|
|
1677
1720
|
L.versions = {};
|
|
1678
|
-
function
|
|
1721
|
+
function J() {
|
|
1679
1722
|
}
|
|
1680
|
-
L.on =
|
|
1681
|
-
L.addListener =
|
|
1682
|
-
L.once =
|
|
1683
|
-
L.off =
|
|
1684
|
-
L.removeListener =
|
|
1685
|
-
L.removeAllListeners =
|
|
1686
|
-
L.emit =
|
|
1687
|
-
L.prependListener =
|
|
1688
|
-
L.prependOnceListener =
|
|
1723
|
+
L.on = J;
|
|
1724
|
+
L.addListener = J;
|
|
1725
|
+
L.once = J;
|
|
1726
|
+
L.off = J;
|
|
1727
|
+
L.removeListener = J;
|
|
1728
|
+
L.removeAllListeners = J;
|
|
1729
|
+
L.emit = J;
|
|
1730
|
+
L.prependListener = J;
|
|
1731
|
+
L.prependOnceListener = J;
|
|
1689
1732
|
L.listeners = function(s) {
|
|
1690
1733
|
return [];
|
|
1691
1734
|
};
|
|
@@ -1701,67 +1744,67 @@ L.chdir = function(s) {
|
|
|
1701
1744
|
L.umask = function() {
|
|
1702
1745
|
return 0;
|
|
1703
1746
|
};
|
|
1704
|
-
var
|
|
1747
|
+
var Hr = vt.exports;
|
|
1705
1748
|
(function(s) {
|
|
1706
1749
|
Object.defineProperty(s, Symbol.toStringTag, { value: "Module" });
|
|
1707
|
-
const n =
|
|
1750
|
+
const n = At, l = Hr, f = (d) => d && d.__esModule ? d : { default: d }, m = f(l), g = globalThis || void 0 || self;
|
|
1708
1751
|
Object.defineProperty(s, "Buffer", { enumerable: !0, get: () => n.Buffer }), Object.defineProperty(s, "process", { enumerable: !0, get: () => m.default }), s.global = g;
|
|
1709
|
-
})(
|
|
1752
|
+
})(It);
|
|
1710
1753
|
let G;
|
|
1711
|
-
typeof window < "u" ? G = window : typeof self < "u" ? G = self : G =
|
|
1712
|
-
let
|
|
1713
|
-
const
|
|
1714
|
-
|
|
1715
|
-
return
|
|
1716
|
-
}) : (
|
|
1717
|
-
|
|
1718
|
-
},
|
|
1719
|
-
const
|
|
1720
|
-
|
|
1721
|
-
}),
|
|
1722
|
-
|
|
1723
|
-
},
|
|
1724
|
-
return [
|
|
1754
|
+
typeof window < "u" ? G = window : typeof self < "u" ? G = self : G = It.global;
|
|
1755
|
+
let Re = null, Ne = null;
|
|
1756
|
+
const ht = 20, $e = G.clearTimeout, dt = G.setTimeout, ke = G.cancelAnimationFrame || G.mozCancelAnimationFrame || G.webkitCancelAnimationFrame, pt = G.requestAnimationFrame || G.mozRequestAnimationFrame || G.webkitRequestAnimationFrame;
|
|
1757
|
+
ke == null || pt == null ? (Re = $e, Ne = function(n) {
|
|
1758
|
+
return dt(n, ht);
|
|
1759
|
+
}) : (Re = function([n, l]) {
|
|
1760
|
+
ke(n), $e(l);
|
|
1761
|
+
}, Ne = function(n) {
|
|
1762
|
+
const l = pt(function() {
|
|
1763
|
+
$e(f), n();
|
|
1764
|
+
}), f = dt(function() {
|
|
1765
|
+
ke(l), n();
|
|
1766
|
+
}, ht);
|
|
1767
|
+
return [l, f];
|
|
1725
1768
|
});
|
|
1726
|
-
function
|
|
1727
|
-
let n,
|
|
1769
|
+
function Yr(s) {
|
|
1770
|
+
let n, l, f, m, g, d, o;
|
|
1728
1771
|
const w = typeof document < "u" && document.attachEvent;
|
|
1729
1772
|
if (!w) {
|
|
1730
|
-
|
|
1731
|
-
const F =
|
|
1732
|
-
|
|
1733
|
-
}, g = function(
|
|
1734
|
-
return
|
|
1735
|
-
}, o = function(
|
|
1736
|
-
if (
|
|
1773
|
+
d = function(C) {
|
|
1774
|
+
const F = C.__resizeTriggers__, U = F.firstElementChild, Q = F.lastElementChild, M = U.firstElementChild;
|
|
1775
|
+
Q.scrollLeft = Q.scrollWidth, Q.scrollTop = Q.scrollHeight, M.style.width = U.offsetWidth + 1 + "px", M.style.height = U.offsetHeight + 1 + "px", U.scrollLeft = U.scrollWidth, U.scrollTop = U.scrollHeight;
|
|
1776
|
+
}, g = function(C) {
|
|
1777
|
+
return C.offsetWidth !== C.__resizeLast__.width || C.offsetHeight !== C.__resizeLast__.height;
|
|
1778
|
+
}, o = function(C) {
|
|
1779
|
+
if (C.target.className && typeof C.target.className.indexOf == "function" && C.target.className.indexOf("contract-trigger") < 0 && C.target.className.indexOf("expand-trigger") < 0)
|
|
1737
1780
|
return;
|
|
1738
1781
|
const F = this;
|
|
1739
|
-
|
|
1782
|
+
d(this), this.__resizeRAF__ && Re(this.__resizeRAF__), this.__resizeRAF__ = Ne(function() {
|
|
1740
1783
|
g(F) && (F.__resizeLast__.width = F.offsetWidth, F.__resizeLast__.height = F.offsetHeight, F.__resizeListeners__.forEach(function(M) {
|
|
1741
|
-
M.call(F,
|
|
1784
|
+
M.call(F, C);
|
|
1742
1785
|
}));
|
|
1743
1786
|
});
|
|
1744
1787
|
};
|
|
1745
1788
|
let y = !1, A = "";
|
|
1746
|
-
|
|
1747
|
-
const
|
|
1748
|
-
let
|
|
1789
|
+
f = "animationstart";
|
|
1790
|
+
const b = "Webkit Moz O ms".split(" ");
|
|
1791
|
+
let _ = "webkitAnimationStart animationstart oAnimationStart MSAnimationStart".split(" "), R = "";
|
|
1749
1792
|
{
|
|
1750
|
-
const
|
|
1751
|
-
if (
|
|
1752
|
-
for (let F = 0; F <
|
|
1753
|
-
if (
|
|
1754
|
-
R =
|
|
1793
|
+
const C = document.createElement("fakeelement");
|
|
1794
|
+
if (C.style.animationName !== void 0 && (y = !0), y === !1) {
|
|
1795
|
+
for (let F = 0; F < b.length; F++)
|
|
1796
|
+
if (C.style[b[F] + "AnimationName"] !== void 0) {
|
|
1797
|
+
R = b[F], A = "-" + R.toLowerCase() + "-", f = _[F], y = !0;
|
|
1755
1798
|
break;
|
|
1756
1799
|
}
|
|
1757
1800
|
}
|
|
1758
1801
|
}
|
|
1759
|
-
|
|
1802
|
+
l = "resizeanim", n = "@" + A + "keyframes " + l + " { from { opacity: 0; } to { opacity: 0; } } ", m = A + "animation: 1ms " + l + "; ";
|
|
1760
1803
|
}
|
|
1761
|
-
const
|
|
1804
|
+
const v = function(y) {
|
|
1762
1805
|
if (!y.getElementById("detectElementResize")) {
|
|
1763
|
-
const A = (n || "") + ".resize-triggers { " + (m || "") + 'visibility: hidden; opacity: 0; } .resize-triggers, .resize-triggers > div, .contract-trigger:before { content: " "; display: block; position: absolute; top: 0; left: 0; height: 100%; width: 100%; overflow: hidden; z-index: -1; } .resize-triggers > div { background: #eee; overflow: auto; } .contract-trigger:before { width: 200%; height: 200%; }',
|
|
1764
|
-
|
|
1806
|
+
const A = (n || "") + ".resize-triggers { " + (m || "") + 'visibility: hidden; opacity: 0; } .resize-triggers, .resize-triggers > div, .contract-trigger:before { content: " "; display: block; position: absolute; top: 0; left: 0; height: 100%; width: 100%; overflow: hidden; z-index: -1; } .resize-triggers > div { background: #eee; overflow: auto; } .contract-trigger:before { width: 200%; height: 200%; }', b = y.head || y.getElementsByTagName("head")[0], _ = y.createElement("style");
|
|
1807
|
+
_.id = "detectElementResize", _.type = "text/css", s != null && _.setAttribute("nonce", s), _.styleSheet ? _.styleSheet.cssText = A : _.appendChild(y.createTextNode(A)), b.appendChild(_);
|
|
1765
1808
|
}
|
|
1766
1809
|
};
|
|
1767
1810
|
return {
|
|
@@ -1770,14 +1813,14 @@ function Oi(s) {
|
|
|
1770
1813
|
y.attachEvent("onresize", A);
|
|
1771
1814
|
else {
|
|
1772
1815
|
if (!y.__resizeTriggers__) {
|
|
1773
|
-
const
|
|
1774
|
-
|
|
1775
|
-
const R =
|
|
1776
|
-
R.className = "expand-trigger", R.appendChild(
|
|
1777
|
-
const
|
|
1778
|
-
|
|
1779
|
-
U.animationName ===
|
|
1780
|
-
}, y.__resizeTriggers__.addEventListener(
|
|
1816
|
+
const b = y.ownerDocument, _ = G.getComputedStyle(y);
|
|
1817
|
+
_ && _.position === "static" && (y.style.position = "relative"), v(b), y.__resizeLast__ = {}, y.__resizeListeners__ = [], (y.__resizeTriggers__ = b.createElement("div")).className = "resize-triggers";
|
|
1818
|
+
const R = b.createElement("div");
|
|
1819
|
+
R.className = "expand-trigger", R.appendChild(b.createElement("div"));
|
|
1820
|
+
const C = b.createElement("div");
|
|
1821
|
+
C.className = "contract-trigger", y.__resizeTriggers__.appendChild(R), y.__resizeTriggers__.appendChild(C), y.appendChild(y.__resizeTriggers__), d(y), y.addEventListener("scroll", o, !0), f && (y.__resizeTriggers__.__animationListener__ = function(U) {
|
|
1822
|
+
U.animationName === l && d(y);
|
|
1823
|
+
}, y.__resizeTriggers__.addEventListener(f, y.__resizeTriggers__.__animationListener__));
|
|
1781
1824
|
}
|
|
1782
1825
|
y.__resizeListeners__.push(A);
|
|
1783
1826
|
}
|
|
@@ -1786,7 +1829,7 @@ function Oi(s) {
|
|
|
1786
1829
|
if (w)
|
|
1787
1830
|
y.detachEvent("onresize", A);
|
|
1788
1831
|
else if (y.__resizeListeners__.splice(y.__resizeListeners__.indexOf(A), 1), !y.__resizeListeners__.length) {
|
|
1789
|
-
y.removeEventListener("scroll", o, !0), y.__resizeTriggers__.__animationListener__ && (y.__resizeTriggers__.removeEventListener(
|
|
1832
|
+
y.removeEventListener("scroll", o, !0), y.__resizeTriggers__.__animationListener__ && (y.__resizeTriggers__.removeEventListener(f, y.__resizeTriggers__.__animationListener__), y.__resizeTriggers__.__animationListener__ = null);
|
|
1790
1833
|
try {
|
|
1791
1834
|
y.__resizeTriggers__ = !y.removeChild(y.__resizeTriggers__);
|
|
1792
1835
|
} catch {
|
|
@@ -1795,7 +1838,7 @@ function Oi(s) {
|
|
|
1795
1838
|
}
|
|
1796
1839
|
};
|
|
1797
1840
|
}
|
|
1798
|
-
class
|
|
1841
|
+
class Vr extends Kt {
|
|
1799
1842
|
constructor(...n) {
|
|
1800
1843
|
super(...n), this.state = {
|
|
1801
1844
|
height: this.props.defaultHeight || 0,
|
|
@@ -1805,27 +1848,27 @@ class Di extends jt {
|
|
|
1805
1848
|
}, this._autoSizer = null, this._detectElementResize = null, this._parentNode = null, this._resizeObserver = null, this._timeoutId = null, this._onResize = () => {
|
|
1806
1849
|
this._timeoutId = null;
|
|
1807
1850
|
const {
|
|
1808
|
-
disableHeight:
|
|
1809
|
-
disableWidth:
|
|
1851
|
+
disableHeight: l,
|
|
1852
|
+
disableWidth: f,
|
|
1810
1853
|
onResize: m
|
|
1811
1854
|
} = this.props;
|
|
1812
1855
|
if (this._parentNode) {
|
|
1813
|
-
var g,
|
|
1814
|
-
const
|
|
1815
|
-
(!
|
|
1816
|
-
height:
|
|
1856
|
+
var g, d, o, w;
|
|
1857
|
+
const v = window.getComputedStyle(this._parentNode) || {}, x = parseFloat((g = v.paddingLeft) !== null && g !== void 0 ? g : "0"), B = parseFloat((d = v.paddingRight) !== null && d !== void 0 ? d : "0"), y = parseFloat((o = v.paddingTop) !== null && o !== void 0 ? o : "0"), A = parseFloat((w = v.paddingBottom) !== null && w !== void 0 ? w : "0"), b = this._parentNode.getBoundingClientRect(), _ = b.height - y - A, R = b.width - x - B, C = this._parentNode.offsetHeight - y - A, F = this._parentNode.offsetWidth - x - B;
|
|
1858
|
+
(!l && (this.state.height !== C || this.state.scaledHeight !== _) || !f && (this.state.width !== F || this.state.scaledWidth !== R)) && (this.setState({
|
|
1859
|
+
height: C,
|
|
1817
1860
|
width: F,
|
|
1818
|
-
scaledHeight:
|
|
1861
|
+
scaledHeight: _,
|
|
1819
1862
|
scaledWidth: R
|
|
1820
1863
|
}), typeof m == "function" && m({
|
|
1821
|
-
height:
|
|
1822
|
-
scaledHeight:
|
|
1864
|
+
height: C,
|
|
1865
|
+
scaledHeight: _,
|
|
1823
1866
|
scaledWidth: R,
|
|
1824
1867
|
width: F
|
|
1825
1868
|
}));
|
|
1826
1869
|
}
|
|
1827
|
-
}, this._setRef = (
|
|
1828
|
-
this._autoSizer =
|
|
1870
|
+
}, this._setRef = (l) => {
|
|
1871
|
+
this._autoSizer = l;
|
|
1829
1872
|
};
|
|
1830
1873
|
}
|
|
1831
1874
|
componentDidMount() {
|
|
@@ -1834,7 +1877,7 @@ class Di extends jt {
|
|
|
1834
1877
|
} = this.props;
|
|
1835
1878
|
this._autoSizer && this._autoSizer.parentNode && this._autoSizer.parentNode.ownerDocument && this._autoSizer.parentNode.ownerDocument.defaultView && this._autoSizer.parentNode instanceof this._autoSizer.parentNode.ownerDocument.defaultView.HTMLElement && (this._parentNode = this._autoSizer.parentNode, this._parentNode != null && (typeof ResizeObserver < "u" ? (this._resizeObserver = new ResizeObserver(() => {
|
|
1836
1879
|
this._timeoutId = setTimeout(this._onResize, 0);
|
|
1837
|
-
}), this._resizeObserver.observe(this._parentNode)) : (this._detectElementResize =
|
|
1880
|
+
}), this._resizeObserver.observe(this._parentNode)) : (this._detectElementResize = Yr(n), this._detectElementResize.addResizeListener(this._parentNode, this._onResize)), this._onResize()));
|
|
1838
1881
|
}
|
|
1839
1882
|
componentWillUnmount() {
|
|
1840
1883
|
this._parentNode && (this._detectElementResize && this._detectElementResize.removeResizeListener(this._parentNode, this._onResize), this._timeoutId !== null && clearTimeout(this._timeoutId), this._resizeObserver && (this._resizeObserver.observe(this._parentNode), this._resizeObserver.disconnect()));
|
|
@@ -1842,359 +1885,357 @@ class Di extends jt {
|
|
|
1842
1885
|
render() {
|
|
1843
1886
|
const {
|
|
1844
1887
|
children: n,
|
|
1845
|
-
defaultHeight:
|
|
1846
|
-
defaultWidth:
|
|
1888
|
+
defaultHeight: l,
|
|
1889
|
+
defaultWidth: f,
|
|
1847
1890
|
disableHeight: m = !1,
|
|
1848
1891
|
disableWidth: g = !1,
|
|
1849
|
-
nonce:
|
|
1892
|
+
nonce: d,
|
|
1850
1893
|
onResize: o,
|
|
1851
1894
|
style: w = {},
|
|
1852
|
-
tagName:
|
|
1853
|
-
...
|
|
1895
|
+
tagName: v = "div",
|
|
1896
|
+
...x
|
|
1854
1897
|
} = this.props, {
|
|
1855
|
-
height:
|
|
1898
|
+
height: B,
|
|
1856
1899
|
scaledHeight: y,
|
|
1857
1900
|
scaledWidth: A,
|
|
1858
|
-
width:
|
|
1859
|
-
} = this.state,
|
|
1901
|
+
width: b
|
|
1902
|
+
} = this.state, _ = {
|
|
1860
1903
|
overflow: "visible"
|
|
1861
1904
|
}, R = {};
|
|
1862
|
-
let
|
|
1863
|
-
return m || (
|
|
1905
|
+
let C = !1;
|
|
1906
|
+
return m || (B === 0 && (C = !0), _.height = 0, R.height = B, R.scaledHeight = y), g || (b === 0 && (C = !0), _.width = 0, R.width = b, R.scaledWidth = A), Xt(v, {
|
|
1864
1907
|
ref: this._setRef,
|
|
1865
1908
|
style: {
|
|
1866
|
-
...
|
|
1909
|
+
..._,
|
|
1867
1910
|
...w
|
|
1868
1911
|
},
|
|
1869
|
-
...
|
|
1870
|
-
}, !
|
|
1912
|
+
...x
|
|
1913
|
+
}, !C && n(R));
|
|
1871
1914
|
}
|
|
1872
1915
|
}
|
|
1873
|
-
const
|
|
1916
|
+
const Qr = /* @__PURE__ */ h("div")({
|
|
1874
1917
|
name: "Container",
|
|
1875
1918
|
class: "c1htq1lb",
|
|
1876
1919
|
propsAsIs: !1
|
|
1877
|
-
}),
|
|
1920
|
+
}), Kr = /* @__PURE__ */ h("div")({
|
|
1878
1921
|
name: "Content",
|
|
1879
1922
|
class: "cjyzpp7",
|
|
1880
1923
|
propsAsIs: !1
|
|
1881
|
-
}),
|
|
1924
|
+
}), Xr = /* @__PURE__ */ h("div")({
|
|
1882
1925
|
name: "Graphic",
|
|
1883
1926
|
class: "g16mldgz",
|
|
1884
1927
|
propsAsIs: !1
|
|
1885
|
-
}),
|
|
1928
|
+
}), Jr = /* @__PURE__ */ h("div")({
|
|
1886
1929
|
name: "Headline",
|
|
1887
1930
|
class: "h69js65",
|
|
1888
1931
|
propsAsIs: !1
|
|
1889
|
-
}),
|
|
1932
|
+
}), Zr = /* @__PURE__ */ h("div")({
|
|
1890
1933
|
name: "StepsContainer",
|
|
1891
1934
|
class: "smm7qmo",
|
|
1892
1935
|
propsAsIs: !1
|
|
1893
|
-
}),
|
|
1936
|
+
}), en = /* @__PURE__ */ h("span")({
|
|
1894
1937
|
name: "StepIndicator",
|
|
1895
1938
|
class: "s17knuw2",
|
|
1896
1939
|
propsAsIs: !1
|
|
1897
|
-
}),
|
|
1940
|
+
}), tn = ({
|
|
1898
1941
|
width: s,
|
|
1899
1942
|
graphicSrc: n,
|
|
1900
|
-
headline:
|
|
1901
|
-
stepsCount:
|
|
1943
|
+
headline: l,
|
|
1944
|
+
stepsCount: f,
|
|
1902
1945
|
currentStep: m
|
|
1903
|
-
}) => /* @__PURE__ */ I(
|
|
1904
|
-
/* @__PURE__ */ I(
|
|
1905
|
-
/* @__PURE__ */
|
|
1906
|
-
|
|
1946
|
+
}) => /* @__PURE__ */ I(Qr, { children: [
|
|
1947
|
+
/* @__PURE__ */ I(Kr, { children: [
|
|
1948
|
+
/* @__PURE__ */ c(Xr, { "data-centered": m === 0, children: /* @__PURE__ */ c("img", { src: n, alt: l, width: s || 300 }) }),
|
|
1949
|
+
l && /* @__PURE__ */ c(Jr, { children: l })
|
|
1907
1950
|
] }),
|
|
1908
|
-
/* @__PURE__ */
|
|
1909
|
-
] }),
|
|
1951
|
+
/* @__PURE__ */ c(Zr, { children: Array.from({ length: f }).map((g, d) => /* @__PURE__ */ c(en, { "data-active": m === d }, d)) })
|
|
1952
|
+
] }), rn = /* @__PURE__ */ h("div")({
|
|
1910
1953
|
name: "Container",
|
|
1911
1954
|
class: "c1itm4k7",
|
|
1912
1955
|
propsAsIs: !1
|
|
1913
|
-
}),
|
|
1956
|
+
}), nn = /* @__PURE__ */ h("div")({
|
|
1914
1957
|
name: "IconContainer",
|
|
1915
1958
|
class: "i1w4fsni",
|
|
1916
1959
|
propsAsIs: !1
|
|
1917
|
-
}),
|
|
1960
|
+
}), sn = () => z, on = /* @__PURE__ */ h(sn())({
|
|
1918
1961
|
name: "InviteGameIcon",
|
|
1919
1962
|
class: "i19m85r1",
|
|
1920
1963
|
propsAsIs: !0
|
|
1921
|
-
}),
|
|
1964
|
+
}), an = /* @__PURE__ */ h("div")({
|
|
1922
1965
|
name: "Content",
|
|
1923
1966
|
class: "c1mbu204",
|
|
1924
1967
|
propsAsIs: !1
|
|
1925
|
-
}),
|
|
1968
|
+
}), ln = /* @__PURE__ */ h("div")({
|
|
1926
1969
|
name: "Heading",
|
|
1927
1970
|
class: "h1amdqtv",
|
|
1928
1971
|
propsAsIs: !1
|
|
1929
|
-
}),
|
|
1972
|
+
}), cn = /* @__PURE__ */ h("div")({
|
|
1930
1973
|
name: "Subtext",
|
|
1931
1974
|
class: "s1lhlj9j",
|
|
1932
1975
|
propsAsIs: !1
|
|
1933
|
-
}),
|
|
1976
|
+
}), un = /* @__PURE__ */ h("div")({
|
|
1934
1977
|
name: "LinkContainer",
|
|
1935
1978
|
class: "l1wot35e",
|
|
1936
1979
|
propsAsIs: !1
|
|
1937
|
-
}),
|
|
1980
|
+
}), hn = /* @__PURE__ */ h("div")({
|
|
1938
1981
|
name: "LinkInfo",
|
|
1939
1982
|
class: "l1jdw39q",
|
|
1940
1983
|
propsAsIs: !1
|
|
1941
|
-
}),
|
|
1984
|
+
}), dn = /* @__PURE__ */ h("span")({
|
|
1942
1985
|
name: "LinkTitle",
|
|
1943
1986
|
class: "l1cr5mk",
|
|
1944
1987
|
propsAsIs: !1
|
|
1945
|
-
}),
|
|
1988
|
+
}), pn = /* @__PURE__ */ h("span")({
|
|
1946
1989
|
name: "LinkAddress",
|
|
1947
1990
|
class: "lvi87q4",
|
|
1948
1991
|
propsAsIs: !1
|
|
1949
|
-
}),
|
|
1992
|
+
}), fn = () => z, mn = /* @__PURE__ */ h(fn())({
|
|
1950
1993
|
name: "LinkIcon",
|
|
1951
1994
|
class: "l1pqlvw3",
|
|
1952
1995
|
propsAsIs: !0
|
|
1953
|
-
}),
|
|
1996
|
+
}), gn = /* @__PURE__ */ h("div")({
|
|
1954
1997
|
name: "SocialLinksContainer",
|
|
1955
1998
|
class: "s1n7kzeh",
|
|
1956
1999
|
propsAsIs: !1
|
|
1957
|
-
}),
|
|
2000
|
+
}), yn = /* @__PURE__ */ h("a")({
|
|
1958
2001
|
name: "SocialLink",
|
|
1959
2002
|
class: "s2m9o9y",
|
|
1960
2003
|
propsAsIs: !1
|
|
1961
|
-
}),
|
|
2004
|
+
}), wn = /* @__PURE__ */ h("span")({
|
|
1962
2005
|
name: "SocialLinkLabel",
|
|
1963
2006
|
class: "sewjbbn",
|
|
1964
2007
|
propsAsIs: !1
|
|
1965
|
-
}),
|
|
2008
|
+
}), In = ({
|
|
1966
2009
|
inviteLink: s,
|
|
1967
2010
|
socialLinks: n,
|
|
1968
|
-
inviteCardTitle:
|
|
1969
|
-
inviteCardSubtext:
|
|
2011
|
+
inviteCardTitle: l,
|
|
2012
|
+
inviteCardSubtext: f,
|
|
1970
2013
|
primaryColor: m,
|
|
1971
2014
|
className: g
|
|
1972
|
-
}) => /* @__PURE__ */ I(
|
|
1973
|
-
/* @__PURE__ */
|
|
1974
|
-
/* @__PURE__ */ I(
|
|
1975
|
-
/* @__PURE__ */
|
|
1976
|
-
/* @__PURE__ */
|
|
2015
|
+
}) => /* @__PURE__ */ I(rn, { className: g, children: [
|
|
2016
|
+
/* @__PURE__ */ c(nn, { style: { backgroundColor: m }, children: /* @__PURE__ */ c(on, { name: "invite-game-icon" }) }),
|
|
2017
|
+
/* @__PURE__ */ I(an, { children: [
|
|
2018
|
+
/* @__PURE__ */ c(ln, { children: l || "" }),
|
|
2019
|
+
/* @__PURE__ */ c(cn, { children: f || "" })
|
|
1977
2020
|
] }),
|
|
1978
|
-
s && /* @__PURE__ */ I(
|
|
2021
|
+
s && /* @__PURE__ */ I(un, { onClick: async () => {
|
|
1979
2022
|
if (s)
|
|
1980
2023
|
try {
|
|
1981
2024
|
await navigator.clipboard.writeText(s);
|
|
1982
|
-
} catch (
|
|
1983
|
-
console.error("Unable to copy to clipboard",
|
|
2025
|
+
} catch (d) {
|
|
2026
|
+
console.error("Unable to copy to clipboard", d);
|
|
1984
2027
|
}
|
|
1985
2028
|
}, children: [
|
|
1986
|
-
/* @__PURE__ */ I(
|
|
1987
|
-
/* @__PURE__ */
|
|
1988
|
-
/* @__PURE__ */
|
|
2029
|
+
/* @__PURE__ */ I(hn, { children: [
|
|
2030
|
+
/* @__PURE__ */ c(dn, { children: "Invite link" }),
|
|
2031
|
+
/* @__PURE__ */ c(pn, { children: s })
|
|
1989
2032
|
] }),
|
|
1990
|
-
/* @__PURE__ */
|
|
2033
|
+
/* @__PURE__ */ c(mn, { name: "icon-copy" })
|
|
1991
2034
|
] }),
|
|
1992
|
-
n && n.length > 0 && /* @__PURE__ */
|
|
1993
|
-
/* @__PURE__ */
|
|
1994
|
-
/* @__PURE__ */
|
|
2035
|
+
n && n.length > 0 && /* @__PURE__ */ c(gn, { children: n.map(({ icon: d, link: o, label: w }) => /* @__PURE__ */ I(yn, { href: o, target: "_blank", children: [
|
|
2036
|
+
/* @__PURE__ */ c(z, { name: d }),
|
|
2037
|
+
/* @__PURE__ */ c(wn, { children: w })
|
|
1995
2038
|
] }, o)) })
|
|
1996
|
-
] }),
|
|
2039
|
+
] }), An = /* @__PURE__ */ h("div")({
|
|
1997
2040
|
name: "Container",
|
|
1998
2041
|
class: "cm0bev",
|
|
1999
2042
|
propsAsIs: !1
|
|
2000
|
-
}),
|
|
2043
|
+
}), xn = /* @__PURE__ */ h("div")({
|
|
2001
2044
|
name: "Content",
|
|
2002
2045
|
class: "ce7x737",
|
|
2003
2046
|
propsAsIs: !1
|
|
2004
|
-
}),
|
|
2047
|
+
}), vn = /* @__PURE__ */ h("div")({
|
|
2005
2048
|
name: "Title",
|
|
2006
2049
|
class: "tc2tor6",
|
|
2007
2050
|
propsAsIs: !1
|
|
2008
|
-
}),
|
|
2051
|
+
}), bn = /* @__PURE__ */ h("div")({
|
|
2009
2052
|
name: "RulesList",
|
|
2010
2053
|
class: "r1k5klql",
|
|
2011
2054
|
propsAsIs: !1
|
|
2012
|
-
}),
|
|
2055
|
+
}), En = /* @__PURE__ */ h("div")({
|
|
2013
2056
|
name: "RulesItem",
|
|
2014
2057
|
class: "r1tf3ft2",
|
|
2015
2058
|
propsAsIs: !1
|
|
2016
|
-
}),
|
|
2059
|
+
}), Bn = /* @__PURE__ */ h("div")({
|
|
2017
2060
|
name: "RuleIcon",
|
|
2018
2061
|
class: "rwpvg1k",
|
|
2019
2062
|
propsAsIs: !1
|
|
2020
|
-
}),
|
|
2063
|
+
}), _n = /* @__PURE__ */ h("div")({
|
|
2021
2064
|
name: "RuleText",
|
|
2022
2065
|
class: "rbxiag0",
|
|
2023
2066
|
propsAsIs: !1
|
|
2024
|
-
}),
|
|
2067
|
+
}), Cn = /* @__PURE__ */ h("button")({
|
|
2025
2068
|
name: "TermsButton",
|
|
2026
2069
|
class: "t6cyrry",
|
|
2027
2070
|
propsAsIs: !1
|
|
2028
|
-
}),
|
|
2029
|
-
/* @__PURE__ */ I(
|
|
2030
|
-
/* @__PURE__ */
|
|
2031
|
-
/* @__PURE__ */
|
|
2032
|
-
m && /* @__PURE__ */
|
|
2033
|
-
/* @__PURE__ */
|
|
2071
|
+
}), Tn = ({ rules: s, rulesTitle: n, primaryColor: l }) => /* @__PURE__ */ I(An, { children: [
|
|
2072
|
+
/* @__PURE__ */ I(xn, { children: [
|
|
2073
|
+
/* @__PURE__ */ c(vn, { children: n }),
|
|
2074
|
+
/* @__PURE__ */ c(bn, { children: s == null ? void 0 : s.map(({ label: f, icon: m }, g) => /* @__PURE__ */ I(En, { children: [
|
|
2075
|
+
m && /* @__PURE__ */ c(Bn, { style: { backgroundColor: l }, children: /* @__PURE__ */ c(z, { name: m, "data-icon": m }) }),
|
|
2076
|
+
/* @__PURE__ */ c(_n, { children: f })
|
|
2034
2077
|
] }, g)) })
|
|
2035
2078
|
] }),
|
|
2036
|
-
/* @__PURE__ */
|
|
2037
|
-
] }),
|
|
2079
|
+
/* @__PURE__ */ c(Cn, { children: "See Terms and Conditions" })
|
|
2080
|
+
] }), Fn = /* @__PURE__ */ h("button")({
|
|
2038
2081
|
name: "SButton",
|
|
2039
2082
|
class: "s1nve60q",
|
|
2040
2083
|
propsAsIs: !1
|
|
2041
|
-
}),
|
|
2084
|
+
}), $n = /* @__PURE__ */ h("span")({
|
|
2042
2085
|
name: "ButtonLabel",
|
|
2043
2086
|
class: "b1xoswwx",
|
|
2044
2087
|
propsAsIs: !1
|
|
2045
|
-
}),
|
|
2088
|
+
}), kn = ({ disabled: s, variant: n = "primary", onClick: l, children: f, ...m }) => /* @__PURE__ */ c(Fn, { onClick: l, disabled: s, "data-variant": n, ...m, children: /* @__PURE__ */ c($n, { children: f }) }), Sn = /* @__PURE__ */ h("div")({
|
|
2046
2089
|
name: "Container",
|
|
2047
2090
|
class: "c18uddbs",
|
|
2048
2091
|
propsAsIs: !1
|
|
2049
|
-
}),
|
|
2092
|
+
}), Ln = /* @__PURE__ */ h("div")({
|
|
2050
2093
|
name: "Content",
|
|
2051
2094
|
class: "cvcfjf6",
|
|
2052
2095
|
propsAsIs: !1
|
|
2053
|
-
}),
|
|
2096
|
+
}), Rn = /* @__PURE__ */ h("div")({
|
|
2054
2097
|
name: "OnboardingHeader",
|
|
2055
2098
|
class: "o1ie27lw",
|
|
2056
2099
|
propsAsIs: !1
|
|
2057
|
-
}),
|
|
2100
|
+
}), Nn = /* @__PURE__ */ h("button")({
|
|
2058
2101
|
name: "CloseBtn",
|
|
2059
2102
|
class: "c15cjkwi",
|
|
2060
2103
|
propsAsIs: !1
|
|
2061
|
-
}),
|
|
2104
|
+
}), Un = () => z, zn = /* @__PURE__ */ h(Un())({
|
|
2062
2105
|
name: "IconClose",
|
|
2063
2106
|
class: "i1mavjt2",
|
|
2064
2107
|
propsAsIs: !0
|
|
2065
|
-
}),
|
|
2108
|
+
}), On = /* @__PURE__ */ h("div")({
|
|
2066
2109
|
name: "OnboardingFooter",
|
|
2067
2110
|
class: "o1x0dyzv",
|
|
2068
2111
|
propsAsIs: !1
|
|
2069
|
-
}),
|
|
2112
|
+
}), Dn = () => kn, Pn = /* @__PURE__ */ h(Dn())({
|
|
2070
2113
|
name: "OnboardingActionBtn",
|
|
2071
2114
|
class: "o1jfi9c3",
|
|
2072
2115
|
propsAsIs: !0
|
|
2073
|
-
}),
|
|
2116
|
+
}), he = {
|
|
2074
2117
|
steps: !1,
|
|
2075
2118
|
rules: !1,
|
|
2076
2119
|
inviteCard: !1
|
|
2077
|
-
},
|
|
2120
|
+
}, Mn = ({
|
|
2078
2121
|
gamification: s,
|
|
2079
2122
|
steps: n,
|
|
2080
|
-
rules:
|
|
2081
|
-
rulesBtnLabel:
|
|
2123
|
+
rules: l,
|
|
2124
|
+
rulesBtnLabel: f,
|
|
2082
2125
|
rulesTitle: m,
|
|
2083
2126
|
primaryColor: g,
|
|
2084
|
-
inviteLink:
|
|
2127
|
+
inviteLink: d,
|
|
2085
2128
|
socialLinks: o,
|
|
2086
2129
|
inviteCardTitle: w,
|
|
2087
|
-
inviteCardSubtext:
|
|
2088
|
-
inviteCardBtnLabel:
|
|
2089
|
-
onClose:
|
|
2130
|
+
inviteCardSubtext: v,
|
|
2131
|
+
inviteCardBtnLabel: x,
|
|
2132
|
+
onClose: B
|
|
2090
2133
|
}) => {
|
|
2091
|
-
const [y, A] =
|
|
2092
|
-
|
|
2093
|
-
n != null && n.length ?
|
|
2134
|
+
const [y, A] = W(0), [b, _] = W(he);
|
|
2135
|
+
X(() => {
|
|
2136
|
+
n != null && n.length ? _({ ...he, steps: !0 }) : l != null && l.length ? _({ ...he, rules: !0 }) : _({ ...he, inviteCard: !0 });
|
|
2094
2137
|
}, []);
|
|
2095
|
-
const R =
|
|
2096
|
-
n != null && n.length && y < n.length - 1 ? A((U) => ++U) :
|
|
2097
|
-
}, [y, n == null ? void 0 : n.length,
|
|
2138
|
+
const R = Ue(() => b.steps && y === 0 ? "Continue" : b.rules ? f || "Got it" : b.inviteCard ? x || "Play Now" : "Next", [b, y, f, x]), C = ve(() => {
|
|
2139
|
+
n != null && n.length && y < n.length - 1 ? A((U) => ++U) : l != null && l.length && b.steps ? _({ ...he, rules: !0 }) : b.rules && _({ ...he, inviteCard: !0 });
|
|
2140
|
+
}, [y, n == null ? void 0 : n.length, l == null ? void 0 : l.length, b, A, _]), F = async () => {
|
|
2098
2141
|
await s.onboardingStatus.submitInplay();
|
|
2099
2142
|
};
|
|
2100
|
-
return /* @__PURE__ */
|
|
2101
|
-
/* @__PURE__ */
|
|
2102
|
-
/* @__PURE__ */ I(
|
|
2103
|
-
|
|
2104
|
-
|
|
2105
|
-
|
|
2106
|
-
|
|
2143
|
+
return /* @__PURE__ */ c(Vr, { children: ({ width: U, height: Q }) => /* @__PURE__ */ I(Sn, { style: { width: U, height: Q }, children: [
|
|
2144
|
+
/* @__PURE__ */ c(Rn, { children: /* @__PURE__ */ c(Nn, { onClick: B, children: /* @__PURE__ */ c(zn, { name: "icon-close-btn-gray" }) }) }),
|
|
2145
|
+
/* @__PURE__ */ I(Ln, { children: [
|
|
2146
|
+
b.steps && (n == null ? void 0 : n.length) && /* @__PURE__ */ c(tn, { stepsCount: n.length, currentStep: y, ...n[y] }),
|
|
2147
|
+
b.rules && /* @__PURE__ */ c(Tn, { rules: l, rulesTitle: m, primaryColor: g }),
|
|
2148
|
+
b.inviteCard && /* @__PURE__ */ c(
|
|
2149
|
+
In,
|
|
2107
2150
|
{
|
|
2108
|
-
inviteLink:
|
|
2151
|
+
inviteLink: d,
|
|
2109
2152
|
inviteCardTitle: w,
|
|
2110
|
-
inviteCardSubtext:
|
|
2153
|
+
inviteCardSubtext: v,
|
|
2111
2154
|
primaryColor: g,
|
|
2112
2155
|
socialLinks: o
|
|
2113
2156
|
}
|
|
2114
2157
|
)
|
|
2115
2158
|
] }),
|
|
2116
|
-
/* @__PURE__ */
|
|
2159
|
+
/* @__PURE__ */ c(On, { children: /* @__PURE__ */ c(Pn, { onClick: b.inviteCard ? F : C, children: R }) })
|
|
2117
2160
|
] }) });
|
|
2118
|
-
},
|
|
2119
|
-
name: "Container",
|
|
2120
|
-
class: "c1pgyo67",
|
|
2121
|
-
propsAsIs: !1
|
|
2122
|
-
}), Rn = "hx17qu6", At = ({
|
|
2123
|
-
children: s,
|
|
2124
|
-
style: n,
|
|
2125
|
-
className: c,
|
|
2126
|
-
hiding: d
|
|
2127
|
-
}) => /* @__PURE__ */ l(Ln, {
|
|
2128
|
-
style: n,
|
|
2129
|
-
className: Vt(c, d && Rn),
|
|
2130
|
-
children: s
|
|
2131
|
-
}), Nn = /* @__PURE__ */ h("div")({
|
|
2161
|
+
}, qn = /* @__PURE__ */ h("div")({
|
|
2132
2162
|
name: "Container",
|
|
2133
2163
|
class: "cocfo2g",
|
|
2134
2164
|
propsAsIs: !1
|
|
2135
|
-
}),
|
|
2165
|
+
}), Gn = /* @__PURE__ */ h("div")({
|
|
2136
2166
|
name: "CloseIconWrap",
|
|
2137
2167
|
class: "c1pdhxdk",
|
|
2138
2168
|
propsAsIs: !1
|
|
2139
|
-
}),
|
|
2169
|
+
}), Wn = () => z, jn = /* @__PURE__ */ h(Wn())({
|
|
2140
2170
|
name: "CloseIcon",
|
|
2141
2171
|
class: "c1funj3r",
|
|
2142
2172
|
propsAsIs: !0
|
|
2143
|
-
}),
|
|
2173
|
+
}), Hn = /* @__PURE__ */ h("div")({
|
|
2144
2174
|
name: "Title",
|
|
2145
2175
|
class: "t1okg06y",
|
|
2146
2176
|
propsAsIs: !1
|
|
2147
|
-
}),
|
|
2177
|
+
}), Yn = /* @__PURE__ */ h("img")({
|
|
2148
2178
|
name: "SponsorLogo",
|
|
2149
2179
|
class: "sb1n923",
|
|
2150
2180
|
propsAsIs: !1
|
|
2151
|
-
}),
|
|
2181
|
+
}), Vn = /* @__PURE__ */ h("div")({
|
|
2152
2182
|
name: "PresentsTitle",
|
|
2153
2183
|
class: "p1stllxd",
|
|
2154
2184
|
propsAsIs: !1
|
|
2155
|
-
}),
|
|
2185
|
+
}), Qn = /* @__PURE__ */ h("div")({
|
|
2156
2186
|
name: "Subtitle",
|
|
2157
2187
|
class: "s13kvdzw",
|
|
2158
2188
|
propsAsIs: !1
|
|
2159
|
-
}),
|
|
2189
|
+
}), Kn = /* @__PURE__ */ h("div")({
|
|
2160
2190
|
name: "Description",
|
|
2161
2191
|
class: "dfvmv3t",
|
|
2162
2192
|
propsAsIs: !1
|
|
2163
|
-
}),
|
|
2193
|
+
}), Xn = /* @__PURE__ */ h("button")({
|
|
2164
2194
|
name: "ActionButton",
|
|
2165
2195
|
class: "ay8e3j9",
|
|
2166
2196
|
propsAsIs: !1
|
|
2167
|
-
}),
|
|
2168
|
-
var
|
|
2169
|
-
return /* @__PURE__ */ I(
|
|
2170
|
-
/* @__PURE__ */
|
|
2171
|
-
((m = (
|
|
2172
|
-
/* @__PURE__ */
|
|
2173
|
-
/* @__PURE__ */
|
|
2197
|
+
}), ft = ({ close: s, action: n, onboarding: l }) => {
|
|
2198
|
+
var f, m, g, d, o, w, v, x;
|
|
2199
|
+
return /* @__PURE__ */ I(qn, { children: [
|
|
2200
|
+
/* @__PURE__ */ c(Gn, { onClick: s, children: /* @__PURE__ */ c(jn, { name: "icon-cross" }) }),
|
|
2201
|
+
((m = (f = l == null ? void 0 : l.titleCard) == null ? void 0 : f.media) == null ? void 0 : m.sponsorLogo) && /* @__PURE__ */ I(Hn, { children: [
|
|
2202
|
+
/* @__PURE__ */ c(Yn, { alt: "sponsor-logo", src: (d = (g = l == null ? void 0 : l.titleCard) == null ? void 0 : g.media) == null ? void 0 : d.sponsorLogo }),
|
|
2203
|
+
/* @__PURE__ */ c(Vn, { children: "PRESENTS" })
|
|
2174
2204
|
] }),
|
|
2175
|
-
((o =
|
|
2176
|
-
((
|
|
2177
|
-
/* @__PURE__ */
|
|
2205
|
+
((o = l == null ? void 0 : l.titleCard) == null ? void 0 : o.title) && /* @__PURE__ */ c(Qn, { children: (w = l == null ? void 0 : l.titleCard) == null ? void 0 : w.title }),
|
|
2206
|
+
((v = l == null ? void 0 : l.titleCard) == null ? void 0 : v.subtitle) && /* @__PURE__ */ c(Kn, { children: (x = l == null ? void 0 : l.titleCard) == null ? void 0 : x.subtitle }),
|
|
2207
|
+
/* @__PURE__ */ c(Xn, { onClick: n, children: "Play Now" })
|
|
2178
2208
|
] });
|
|
2179
|
-
},
|
|
2209
|
+
}, Jn = /* @__PURE__ */ h("div")({
|
|
2180
2210
|
name: "OnboardingContainer",
|
|
2181
2211
|
class: "o9squag",
|
|
2212
|
+
propsAsIs: !1
|
|
2213
|
+
}), Zn = () => De, es = /* @__PURE__ */ h(Zn())({
|
|
2214
|
+
name: "OnboardingNotificationContainer",
|
|
2215
|
+
class: "o1c8wcli",
|
|
2182
2216
|
propsAsIs: !0
|
|
2183
|
-
}),
|
|
2184
|
-
|
|
2185
|
-
|
|
2186
|
-
|
|
2187
|
-
|
|
2188
|
-
|
|
2189
|
-
|
|
2217
|
+
}), mt = /* @__PURE__ */ h("div")({
|
|
2218
|
+
name: "InnerContainer",
|
|
2219
|
+
class: "i18oyadd",
|
|
2220
|
+
propsAsIs: !1
|
|
2221
|
+
}), ts = "cebdc0u", is = ({
|
|
2222
|
+
deepLink: s,
|
|
2223
|
+
onboardingOpts: n,
|
|
2224
|
+
notification: l,
|
|
2225
|
+
gamification: f
|
|
2190
2226
|
}) => {
|
|
2191
|
-
var
|
|
2192
|
-
const
|
|
2193
|
-
|
|
2194
|
-
|
|
2195
|
-
|
|
2196
|
-
|
|
2197
|
-
|
|
2227
|
+
var m, g, d, o, w, v;
|
|
2228
|
+
const [x, B] = W(void 0);
|
|
2229
|
+
return X(() => {
|
|
2230
|
+
const y = s.$store.subscribe((A) => {
|
|
2231
|
+
A && B(A.data);
|
|
2232
|
+
});
|
|
2233
|
+
return () => {
|
|
2234
|
+
y();
|
|
2235
|
+
};
|
|
2236
|
+
}, [s.$store]), /* @__PURE__ */ c(Jn, {
|
|
2237
|
+
className: wt(l.hiding && ts),
|
|
2238
|
+
children: /* @__PURE__ */ c(Mn, {
|
|
2198
2239
|
rules: [{
|
|
2199
2240
|
label: "Answer as many questions as you like.",
|
|
2200
2241
|
icon: "icon-btn-feature-groups"
|
|
@@ -2205,8 +2246,8 @@ const Pi = /* @__PURE__ */ h("div")({
|
|
|
2205
2246
|
label: "Top the leader board and best your friends.",
|
|
2206
2247
|
icon: "icon-trophy"
|
|
2207
2248
|
}],
|
|
2208
|
-
rulesBtnLabel: (
|
|
2209
|
-
rulesTitle: (
|
|
2249
|
+
rulesBtnLabel: (m = n.rules) == null ? void 0 : m.buttonLabel,
|
|
2250
|
+
rulesTitle: (g = n.rules) == null ? void 0 : g.heading,
|
|
2210
2251
|
steps: [{
|
|
2211
2252
|
graphicSrc: "https://cdn.streamlayer.io/assets/sdk-web/onboarding-steps/step_1.png",
|
|
2212
2253
|
headline: "Welcome to the Featured Groups +",
|
|
@@ -2225,14 +2266,14 @@ const Pi = /* @__PURE__ */ h("div")({
|
|
|
2225
2266
|
graphicSrc: "https://cdn.streamlayer.io/assets/sdk-web/onboarding-steps/step_5.png",
|
|
2226
2267
|
headline: "Compete against friends on the leaderboard"
|
|
2227
2268
|
}],
|
|
2228
|
-
primaryColor: (
|
|
2229
|
-
inviteLink:
|
|
2230
|
-
inviteCardTitle: (
|
|
2231
|
-
inviteCardSubtext: (
|
|
2232
|
-
inviteCardBtnLabel: (
|
|
2269
|
+
primaryColor: (d = n.inviteCard) == null ? void 0 : d.iconColor,
|
|
2270
|
+
inviteLink: x == null ? void 0 : x.url,
|
|
2271
|
+
inviteCardTitle: (o = n.inviteCard) == null ? void 0 : o.heading,
|
|
2272
|
+
inviteCardSubtext: (w = n.inviteCard) == null ? void 0 : w.subtext,
|
|
2273
|
+
inviteCardBtnLabel: (v = n.inviteCard) == null ? void 0 : v.buttonLabel,
|
|
2233
2274
|
onClose: () => {
|
|
2234
|
-
var
|
|
2235
|
-
|
|
2275
|
+
var y;
|
|
2276
|
+
(y = l.close) == null || y.call(l);
|
|
2236
2277
|
},
|
|
2237
2278
|
socialLinks: [{
|
|
2238
2279
|
icon: "icon-facebook",
|
|
@@ -2243,77 +2284,146 @@ const Pi = /* @__PURE__ */ h("div")({
|
|
|
2243
2284
|
link: "https://twitter.com/@TheMasters",
|
|
2244
2285
|
label: "X"
|
|
2245
2286
|
}],
|
|
2246
|
-
gamification:
|
|
2287
|
+
gamification: f
|
|
2247
2288
|
})
|
|
2248
2289
|
});
|
|
2249
|
-
},
|
|
2290
|
+
}, rs = ({
|
|
2250
2291
|
sdk: s,
|
|
2251
|
-
notification: n
|
|
2292
|
+
notification: n,
|
|
2293
|
+
saveHeight: l,
|
|
2294
|
+
style: f
|
|
2252
2295
|
}) => {
|
|
2253
|
-
const [
|
|
2254
|
-
return
|
|
2296
|
+
const m = ye(null), [g, d] = W(!1), o = s.getFeature(ze.GAMES), w = n.data.onboarding;
|
|
2297
|
+
return Jt(() => {
|
|
2298
|
+
var v;
|
|
2299
|
+
l(((v = m.current) == null ? void 0 : v.getBoundingClientRect().height) || 0);
|
|
2300
|
+
}, [l]), g && o && w ? /* @__PURE__ */ c(is, {
|
|
2255
2301
|
notification: n,
|
|
2256
2302
|
setOpened: d,
|
|
2257
|
-
gamification:
|
|
2258
|
-
onboardingOpts:
|
|
2259
|
-
deepLink:
|
|
2260
|
-
}) : /* @__PURE__ */
|
|
2261
|
-
children: /* @__PURE__ */
|
|
2262
|
-
|
|
2263
|
-
|
|
2264
|
-
|
|
2265
|
-
|
|
2303
|
+
gamification: o,
|
|
2304
|
+
onboardingOpts: w,
|
|
2305
|
+
deepLink: o.deepLink
|
|
2306
|
+
}) : /* @__PURE__ */ I(ie, {
|
|
2307
|
+
children: [/* @__PURE__ */ c(mt, {
|
|
2308
|
+
ref: (v) => {
|
|
2309
|
+
m.current = v;
|
|
2310
|
+
},
|
|
2311
|
+
style: {
|
|
2312
|
+
position: "absolute",
|
|
2313
|
+
visibility: "hidden"
|
|
2314
|
+
},
|
|
2315
|
+
children: /* @__PURE__ */ c(ft, {
|
|
2316
|
+
close: () => {
|
|
2317
|
+
},
|
|
2318
|
+
action: () => {
|
|
2319
|
+
},
|
|
2320
|
+
onboarding: w
|
|
2321
|
+
})
|
|
2322
|
+
}), /* @__PURE__ */ c(es, {
|
|
2323
|
+
style: f,
|
|
2324
|
+
hiding: n.hiding,
|
|
2325
|
+
children: /* @__PURE__ */ c(mt, {
|
|
2326
|
+
children: /* @__PURE__ */ c(ft, {
|
|
2327
|
+
close: n.close,
|
|
2328
|
+
action: () => d(!0),
|
|
2329
|
+
onboarding: w
|
|
2330
|
+
})
|
|
2331
|
+
})
|
|
2332
|
+
})]
|
|
2266
2333
|
});
|
|
2267
|
-
},
|
|
2334
|
+
}, ns = () => De, ss = /* @__PURE__ */ h(ns())({
|
|
2268
2335
|
name: "Container",
|
|
2269
2336
|
class: "ctckejh",
|
|
2270
2337
|
propsAsIs: !0
|
|
2271
|
-
}),
|
|
2272
|
-
|
|
2273
|
-
|
|
2338
|
+
}), gt = /* @__PURE__ */ h("div")({
|
|
2339
|
+
name: "InnerContainer",
|
|
2340
|
+
class: "i1ri7tzr",
|
|
2341
|
+
propsAsIs: !1
|
|
2342
|
+
}), os = (s) => {
|
|
2343
|
+
const [n, l] = W(0), f = ye(null), m = ve((d) => {
|
|
2344
|
+
f.current = d;
|
|
2345
|
+
}, []);
|
|
2346
|
+
X(() => {
|
|
2347
|
+
var d;
|
|
2348
|
+
const o = (d = f.current) == null ? void 0 : d.getBoundingClientRect();
|
|
2349
|
+
o && l(o.height);
|
|
2350
|
+
}, [s]);
|
|
2351
|
+
const g = ve((d) => {
|
|
2352
|
+
l(d);
|
|
2353
|
+
}, []);
|
|
2354
|
+
return [m, n, g];
|
|
2355
|
+
}, as = ({ sdk: s, notification: n }) => {
|
|
2356
|
+
var l, f;
|
|
2357
|
+
const [m, g, d] = os(n.id);
|
|
2358
|
+
return n.type === Ae.QUESTION ? /* @__PURE__ */ I(ie, { children: [
|
|
2359
|
+
/* @__PURE__ */ c(gt, { ref: m, style: { position: "absolute", visibility: "hidden" }, children: /* @__PURE__ */ c(et, { ...n }) }),
|
|
2360
|
+
/* @__PURE__ */ c(ss, { style: { height: n.hiding ? 0 : g }, hiding: n.hiding, children: /* @__PURE__ */ c(gt, { style: { height: "100%" }, children: /* @__PURE__ */ c(et, { ...n }) }) })
|
|
2361
|
+
] }) : n.type === Ae.QUESTION_RESOLVED && (f = (l = n.data) == null ? void 0 : l.question) != null && f.predictionResult ? /* @__PURE__ */ c(
|
|
2362
|
+
Nr,
|
|
2363
|
+
{
|
|
2364
|
+
style: { height: n.hiding ? 0 : g },
|
|
2365
|
+
saveHeight: d,
|
|
2366
|
+
close: n.close,
|
|
2367
|
+
hiding: n.hiding,
|
|
2368
|
+
...n.data.question
|
|
2369
|
+
}
|
|
2370
|
+
) : n.type === Ae.ONBOARDING ? /* @__PURE__ */ c(
|
|
2371
|
+
rs,
|
|
2372
|
+
{
|
|
2373
|
+
style: { height: n.hiding ? 0 : g },
|
|
2374
|
+
saveHeight: d,
|
|
2375
|
+
sdk: s,
|
|
2376
|
+
notification: n
|
|
2377
|
+
}
|
|
2378
|
+
) : null;
|
|
2379
|
+
}, ls = ({ sdk: s }) => {
|
|
2380
|
+
const [n] = W(s.getNotificationsStore()), l = re(n), f = Ue(() => {
|
|
2381
|
+
if (!(l != null && l.size))
|
|
2274
2382
|
return null;
|
|
2275
|
-
for (const m of
|
|
2276
|
-
if (m.type ===
|
|
2383
|
+
for (const m of l.values())
|
|
2384
|
+
if (m.type === Ae.ONBOARDING)
|
|
2277
2385
|
return m;
|
|
2278
|
-
return
|
|
2279
|
-
}, [
|
|
2280
|
-
return
|
|
2281
|
-
},
|
|
2386
|
+
return l.values().next().value;
|
|
2387
|
+
}, [l]);
|
|
2388
|
+
return f ? /* @__PURE__ */ c(as, { sdk: s, notification: f }) : null;
|
|
2389
|
+
}, cs = /* @__PURE__ */ h("div")({
|
|
2282
2390
|
name: "SDKContainer",
|
|
2283
2391
|
class: "stu11h7",
|
|
2284
2392
|
propsAsIs: !1
|
|
2285
|
-
}),
|
|
2393
|
+
}), yt = /* @__PURE__ */ h("div")({
|
|
2286
2394
|
name: "SDKScrollContainer",
|
|
2287
2395
|
class: "s1ucohr1",
|
|
2288
2396
|
propsAsIs: !1
|
|
2289
|
-
}),
|
|
2397
|
+
}), us = /* @__PURE__ */ h("div")({
|
|
2290
2398
|
name: "SDKContentContainer",
|
|
2291
2399
|
class: "s1el4wvm",
|
|
2292
2400
|
propsAsIs: !1
|
|
2293
|
-
}),
|
|
2401
|
+
}), hs = () => us, Bs = /* @__PURE__ */ h(hs())({
|
|
2294
2402
|
name: "SDKWhiteContainer",
|
|
2295
2403
|
class: "s1oe3036",
|
|
2296
2404
|
propsAsIs: !0
|
|
2297
|
-
}),
|
|
2298
|
-
const n =
|
|
2405
|
+
}), ds = (s) => {
|
|
2406
|
+
const n = ye(""), [l, f] = W(!1), m = re(s.status), g = re(s.userId()), d = m === "ready", [o, w] = W(ee), v = ve(
|
|
2299
2407
|
(y, A) => {
|
|
2300
|
-
w(A), A === ee ? (y && s.createEventSession(y),
|
|
2408
|
+
w(A), A === ee ? (y && s.createEventSession(y), window.requestAnimationFrame(() => {
|
|
2409
|
+
s.openFeature(ze.GAMES);
|
|
2410
|
+
})) : s.closeFeature();
|
|
2301
2411
|
},
|
|
2302
2412
|
[s]
|
|
2303
2413
|
);
|
|
2304
|
-
|
|
2305
|
-
!
|
|
2306
|
-
}, [
|
|
2307
|
-
const
|
|
2308
|
-
n.current = y, s.initializeApp().then(({ enabled: A, err:
|
|
2309
|
-
if (
|
|
2310
|
-
|
|
2414
|
+
X(() => {
|
|
2415
|
+
!d && o === ee && (w(de), s.closeFeature());
|
|
2416
|
+
}, [d, o, s]);
|
|
2417
|
+
const x = (y) => {
|
|
2418
|
+
n.current = y, f(!0), s.initializeApp().then(({ enabled: A, err: b }) => {
|
|
2419
|
+
if (b) {
|
|
2420
|
+
v(y, de);
|
|
2311
2421
|
return;
|
|
2312
2422
|
}
|
|
2313
2423
|
if (A) {
|
|
2314
|
-
s.isUserAuthorized().then((
|
|
2315
|
-
if (
|
|
2316
|
-
|
|
2424
|
+
s.isUserAuthorized().then((_) => {
|
|
2425
|
+
if (_) {
|
|
2426
|
+
v(y, ee);
|
|
2317
2427
|
return;
|
|
2318
2428
|
} else
|
|
2319
2429
|
s.disableApp();
|
|
@@ -2321,101 +2431,101 @@ const Pi = /* @__PURE__ */ h("div")({
|
|
|
2321
2431
|
return;
|
|
2322
2432
|
}
|
|
2323
2433
|
});
|
|
2324
|
-
},
|
|
2325
|
-
|
|
2434
|
+
}, B = () => {
|
|
2435
|
+
f(!1), s.disableApp();
|
|
2326
2436
|
};
|
|
2327
|
-
return
|
|
2437
|
+
return X(() => {
|
|
2328
2438
|
if (!g) {
|
|
2329
|
-
|
|
2439
|
+
d && (w(de), s.disableApp());
|
|
2330
2440
|
return;
|
|
2331
2441
|
}
|
|
2332
|
-
g && n.current &&
|
|
2442
|
+
g && n.current && l && s.initializeApp().then(() => {
|
|
2333
2443
|
s.createEventSession(n.current);
|
|
2334
2444
|
});
|
|
2335
2445
|
}, [g]), {
|
|
2336
|
-
sdkEnabled:
|
|
2337
|
-
sdkReady:
|
|
2446
|
+
sdkEnabled: l,
|
|
2447
|
+
sdkReady: d,
|
|
2338
2448
|
activeOverlay: o,
|
|
2339
|
-
activateAndLoadOverlay:
|
|
2340
|
-
activateEventWithId:
|
|
2341
|
-
deactivate:
|
|
2449
|
+
activateAndLoadOverlay: v,
|
|
2450
|
+
activateEventWithId: x,
|
|
2451
|
+
deactivate: B,
|
|
2342
2452
|
isLogged: !!g
|
|
2343
2453
|
};
|
|
2344
|
-
},
|
|
2345
|
-
const n =
|
|
2346
|
-
return
|
|
2454
|
+
}, ps = (s) => {
|
|
2455
|
+
const n = re(s.getActiveFeature()), l = re(s.streamStore()), [f, m] = W(null);
|
|
2456
|
+
return X(() => {
|
|
2347
2457
|
const g = s.getFeatures();
|
|
2348
2458
|
if (n)
|
|
2349
|
-
for (const [
|
|
2350
|
-
|
|
2459
|
+
for (const [d, o] of g)
|
|
2460
|
+
d === n ? o.status.get() === me.Suspended && (o.enable(), m(o)) : o.status.get() === me.Ready && o.disable();
|
|
2351
2461
|
else {
|
|
2352
|
-
for (const [,
|
|
2353
|
-
|
|
2462
|
+
for (const [, d] of g)
|
|
2463
|
+
d.status.get() === me.Ready && d.disable();
|
|
2354
2464
|
m(null);
|
|
2355
2465
|
}
|
|
2356
2466
|
return () => {
|
|
2357
|
-
for (const [,
|
|
2358
|
-
|
|
2467
|
+
for (const [, d] of g)
|
|
2468
|
+
d.status.get() === me.Ready && d.disable();
|
|
2359
2469
|
};
|
|
2360
|
-
}, [n, s,
|
|
2361
|
-
},
|
|
2362
|
-
const [,
|
|
2363
|
-
return /* @__PURE__ */
|
|
2364
|
-
},
|
|
2365
|
-
const { sdkEnabled:
|
|
2366
|
-
return
|
|
2470
|
+
}, [n, s, l]), [n, f];
|
|
2471
|
+
}, fs = ({ sdk: s, className: n }) => {
|
|
2472
|
+
const [, l] = ps(s);
|
|
2473
|
+
return /* @__PURE__ */ c(ii, { className: n, feature: l, sdk: s });
|
|
2474
|
+
}, ms = ({ sdk: s, overlays: n, children: l }) => {
|
|
2475
|
+
const { sdkEnabled: f, sdkReady: m, activeOverlay: g, activateAndLoadOverlay: d, activateEventWithId: o, deactivate: w, isLogged: v } = ds(s);
|
|
2476
|
+
return X(() => {
|
|
2367
2477
|
import("./gamification-feature.js");
|
|
2368
|
-
}, []), /* @__PURE__ */ I(
|
|
2369
|
-
|
|
2370
|
-
|
|
2478
|
+
}, []), /* @__PURE__ */ I(cs, { children: [
|
|
2479
|
+
f && /* @__PURE__ */ c(
|
|
2480
|
+
Ii,
|
|
2371
2481
|
{
|
|
2372
2482
|
sdkReady: m,
|
|
2373
2483
|
activeOverlay: g,
|
|
2374
|
-
className:
|
|
2375
|
-
setActiveOverlay: (
|
|
2484
|
+
className: Ze,
|
|
2485
|
+
setActiveOverlay: (x) => d("", x)
|
|
2376
2486
|
}
|
|
2377
2487
|
),
|
|
2378
|
-
m && /* @__PURE__ */
|
|
2379
|
-
/* @__PURE__ */
|
|
2380
|
-
|
|
2488
|
+
m && /* @__PURE__ */ c(ls, { sdk: s }),
|
|
2489
|
+
/* @__PURE__ */ c(
|
|
2490
|
+
yt,
|
|
2381
2491
|
{
|
|
2382
|
-
"data-nav":
|
|
2383
|
-
style: { display: !
|
|
2384
|
-
children:
|
|
2492
|
+
"data-nav": f.toString(),
|
|
2493
|
+
style: { display: !f || g === de ? "block" : "none" },
|
|
2494
|
+
children: l && l({ activateEventWithId: o, deactivate: w })
|
|
2385
2495
|
}
|
|
2386
2496
|
),
|
|
2387
|
-
/* @__PURE__ */
|
|
2388
|
-
|
|
2497
|
+
/* @__PURE__ */ c(
|
|
2498
|
+
yt,
|
|
2389
2499
|
{
|
|
2390
|
-
"data-nav":
|
|
2391
|
-
style: { display: g ===
|
|
2392
|
-
children: n && g ===
|
|
2500
|
+
"data-nav": f.toString(),
|
|
2501
|
+
style: { display: g === be ? "block" : "none" },
|
|
2502
|
+
children: n && g === be && n[g]
|
|
2393
2503
|
}
|
|
2394
2504
|
),
|
|
2395
|
-
m && g === ee && /* @__PURE__ */
|
|
2396
|
-
!
|
|
2505
|
+
m && g === ee && /* @__PURE__ */ c(fs, { className: Ze, sdk: s }),
|
|
2506
|
+
!v && /* @__PURE__ */ c("div", { style: { display: "flex", alignItems: "center", justifyContent: "center", width: "100%", height: "100%" }, children: "You are not logged in." })
|
|
2397
2507
|
] });
|
|
2398
2508
|
};
|
|
2399
|
-
const
|
|
2509
|
+
const _s = ({
|
|
2400
2510
|
sdkKey: s,
|
|
2401
2511
|
plugins: n,
|
|
2402
|
-
children:
|
|
2403
|
-
production:
|
|
2404
|
-
}) => /* @__PURE__ */
|
|
2405
|
-
const { sdk:
|
|
2406
|
-
if (
|
|
2512
|
+
children: l,
|
|
2513
|
+
production: f = !0
|
|
2514
|
+
}) => /* @__PURE__ */ c(Wt, { sdkKey: s, plugins: n, production: f, autoEnable: !1, children: l }), Cs = ({ children: s, overlays: n }) => {
|
|
2515
|
+
const { sdk: l, status: f } = Zt(jt);
|
|
2516
|
+
if (f === Ht.UNSET)
|
|
2407
2517
|
throw new Error("Wrap app in `StreamLayerProvider`");
|
|
2408
|
-
return
|
|
2518
|
+
return l ? /* @__PURE__ */ c("div", { className: "StreamLayerSDK", children: /* @__PURE__ */ c(Yt, { style: { height: "100%" }, children: /* @__PURE__ */ c(ms, { sdk: l, overlays: n, children: s }) }) }) : s({});
|
|
2409
2519
|
};
|
|
2410
2520
|
export {
|
|
2411
|
-
|
|
2412
|
-
|
|
2413
|
-
|
|
2414
|
-
|
|
2415
|
-
|
|
2416
|
-
|
|
2417
|
-
|
|
2418
|
-
|
|
2419
|
-
|
|
2420
|
-
|
|
2521
|
+
Vr as A,
|
|
2522
|
+
_s as M,
|
|
2523
|
+
In as O,
|
|
2524
|
+
Bs as a,
|
|
2525
|
+
Cs as b,
|
|
2526
|
+
De as f,
|
|
2527
|
+
us as n,
|
|
2528
|
+
Ai as o,
|
|
2529
|
+
yt as r,
|
|
2530
|
+
Bi as w
|
|
2421
2531
|
};
|