fansunited-frontend-components 0.0.39 → 0.0.40
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/ChanceGame.js +104 -102
- package/ClassicQuizPlay.js +45 -42
- package/CollectLead.js +25 -24
- package/Discussion.js +376 -378
- package/EitherOrPlay.d.ts +4 -0
- package/EitherOrPlay.d.ts.map +1 -0
- package/EitherOrPlay.js +2533 -0
- package/EventGamePlay.js +59 -54
- package/MatchQuizPlay.js +63 -57
- package/PersonalityQuizPlay.js +7935 -7201
- package/PickThePair.js +153 -151
- package/PollVote.js +108 -104
- package/chunks/{AlertMessage-C2aBXCrl.js → AlertMessage-cjTHrMUK.js} +51 -51
- package/chunks/ArrowRightAlt-88jKjh6A.js +8 -0
- package/chunks/Avatar-CQCrd1m-.js +352 -0
- package/chunks/ChanceGameEmbedVariant-DWqOTf4o.js +1051 -0
- package/chunks/{CheckCircle-D-GH16Lb.js → CheckCircle-ClY-iOQ5.js} +105 -105
- package/chunks/{CollectLeadForm-o9NdYQgu.js → CollectLeadForm-0vVnu4DL.js} +5 -5
- package/chunks/FavoriteBorder-BHnvGBrn.js +11 -0
- package/chunks/{useInfoPage-v91yL5SS.js → NotFoundSkeleton-B3RNa8KJ.js} +451 -646
- package/chunks/Notification-BTtUhfZQ.js +615 -0
- package/chunks/OverlayLeadAfterCollection-CaBbwZVo.js +480 -0
- package/chunks/{OverlayScoreStateSkeleton-xvq9lQEi.js → OverlayScoreStateSkeleton-DJn0Rim3.js} +3 -3
- package/chunks/Person-D0Im9_zE.js +522 -0
- package/chunks/{PickOneOfX-C2YpLk40.js → PickOneOfX-DYQ4c1o2.js} +7 -7
- package/chunks/{Portal-DWAr8MhA.js → Portal-B9wkUnY2.js} +7 -7
- package/chunks/{ConstantsProvider-BPJJz9fq.js → PrizeCard-gMp7I66d.js} +3593 -2860
- package/chunks/{Spinner-m59ZJZ35.js → Spinner-BBA89t5s.js} +50 -50
- package/chunks/StandardLeadAfterCollection-L1cOGfS6.js +432 -0
- package/chunks/{Tabs-BGihvj9C.js → Tabs-D_n8rNw3.js} +28 -28
- package/chunks/{Textarea-Bzlb89Zp.js → Textarea-BdN2xj4j.js} +44 -44
- package/chunks/{TimerOutlined-DiX8hCoC.js → TimerOutlined-DmKZDDI-.js} +1 -1
- package/chunks/chevron-right-DGEksBI7.js +330 -0
- package/chunks/default-quiz-bg-vertical-CT7rrg9o.js +5 -0
- package/chunks/index-2s5UkG1y.js +1607 -0
- package/chunks/useImageVariant-pnFelF9A.js +535 -0
- package/chunks/useInfoPage-DPkzE5Gn.js +204 -0
- package/components.d.ts +2 -1
- package/components.d.ts.map +1 -1
- package/index.d.ts +1 -0
- package/index.d.ts.map +1 -1
- package/index.js +4 -2
- package/package.json +1 -1
- package/chunks/ChanceGameEmbedVariant-BvIKBhq_.js +0 -2609
- package/chunks/Notification-Bwcoljir.js +0 -961
- package/chunks/OverlayLeadAfterCollection-B3D5ct0J.js +0 -901
- package/chunks/chevron-right-Dlc9ZKhv.js +0 -846
- package/chunks/useImageVariant-Do8kOVs2.js +0 -537
|
@@ -1,2609 +0,0 @@
|
|
|
1
|
-
var pe = Object.defineProperty;
|
|
2
|
-
var De = (e, t, a) => t in e ? pe(e, t, { enumerable: !0, configurable: !0, writable: !0, value: a }) : e[t] = a;
|
|
3
|
-
var i = (e, t, a) => De(e, typeof t != "symbol" ? t + "" : t, a);
|
|
4
|
-
import { jsx as c, jsxs as b, Fragment as U } from "react/jsx-runtime";
|
|
5
|
-
import { a0 as le, a5 as te, B as m, T as L, e as ie, a3 as Ie, u as ae, f as ne, v as q, w as Q, x as V, y as oe, W as $, d as ve, a2 as Le, a8 as ue } from "./ConstantsProvider-BPJJz9fq.js";
|
|
6
|
-
import { h as be, g as Ne, s as j, u as _e, d as we, a as Pe, e as Me, b as ke } from "./useImageVariant-Do8kOVs2.js";
|
|
7
|
-
import "react";
|
|
8
|
-
import { R as W, A as Fe, u as Ve } from "./useInfoPage-v91yL5SS.js";
|
|
9
|
-
import "react-dom";
|
|
10
|
-
import { A as xe } from "./AlertMessage-C2aBXCrl.js";
|
|
11
|
-
import { f as Ge, e as He, P as Be } from "./PickOneOfX-C2YpLk40.js";
|
|
12
|
-
const $t = ({
|
|
13
|
-
additionalCTA: e,
|
|
14
|
-
buttonStyle: t,
|
|
15
|
-
buttonContentStyle: a,
|
|
16
|
-
textStyle: r
|
|
17
|
-
}) => {
|
|
18
|
-
const { t: l } = le();
|
|
19
|
-
return e ? e.component ? e.component : e.onClick ? /* @__PURE__ */ c(te, { sx: t, onClick: e.onClick, children: e.defaultLabel && /* @__PURE__ */ c(m, { sx: a, children: /* @__PURE__ */ c(L, { sx: r, children: e.defaultLabel }) }) }) : e.url ? /* @__PURE__ */ c(
|
|
20
|
-
te,
|
|
21
|
-
{
|
|
22
|
-
component: "a",
|
|
23
|
-
href: e.url,
|
|
24
|
-
target: e.target || "_self",
|
|
25
|
-
sx: t,
|
|
26
|
-
children: /* @__PURE__ */ c(L, { sx: r, children: e.defaultLabel || l("common.additional") })
|
|
27
|
-
}
|
|
28
|
-
) : null : null;
|
|
29
|
-
}, Ye = (e) => {
|
|
30
|
-
var t, a, r, l;
|
|
31
|
-
return {
|
|
32
|
-
// Main headline section with background image
|
|
33
|
-
headlineSection: {
|
|
34
|
-
display: "flex",
|
|
35
|
-
flexDirection: "column",
|
|
36
|
-
justifyContent: "space-between",
|
|
37
|
-
gap: "10px",
|
|
38
|
-
flex: e.isMobile ? "1" : "0 0 50%",
|
|
39
|
-
width: e.isMobile ? "100%" : "50%",
|
|
40
|
-
minWidth: e.isMobile ? "100%" : "50%",
|
|
41
|
-
maxWidth: e.isMobile ? "100%" : "50%",
|
|
42
|
-
backgroundImage: e.finalImage ? `url("${e.finalImage}")` : "none",
|
|
43
|
-
backgroundSize: "cover",
|
|
44
|
-
backgroundPosition: "center",
|
|
45
|
-
borderTopLeftRadius: e.borderRadius.md,
|
|
46
|
-
borderTopRightRadius: e.isMobile ? e.borderRadius.md : 0,
|
|
47
|
-
borderBottomLeftRadius: e.isMobile ? 0 : e.borderRadius.md,
|
|
48
|
-
overflow: "hidden",
|
|
49
|
-
height: "auto",
|
|
50
|
-
position: "relative",
|
|
51
|
-
minHeight: e.isMobile ? "210px" : "430px",
|
|
52
|
-
"&::before": e.finalImage ? {
|
|
53
|
-
content: '""',
|
|
54
|
-
position: "absolute",
|
|
55
|
-
width: "100%",
|
|
56
|
-
height: "100%",
|
|
57
|
-
background: e.imageBackgroundGradient,
|
|
58
|
-
borderTopLeftRadius: "5px",
|
|
59
|
-
borderTopRightRadius: "5px"
|
|
60
|
-
} : {}
|
|
61
|
-
},
|
|
62
|
-
// Headline section without image
|
|
63
|
-
headlineSectionNoImage: {
|
|
64
|
-
display: "flex",
|
|
65
|
-
flexDirection: "column",
|
|
66
|
-
justifyContent: "space-between",
|
|
67
|
-
gap: "10px",
|
|
68
|
-
flex: e.isMobile ? "1" : "0 0 50%",
|
|
69
|
-
width: e.isMobile ? "100%" : "50%",
|
|
70
|
-
minWidth: e.isMobile ? "100%" : "50%",
|
|
71
|
-
maxWidth: e.isMobile ? "100%" : "50%",
|
|
72
|
-
borderTopLeftRadius: e.borderRadius.md,
|
|
73
|
-
borderTopRightRadius: e.isMobile ? e.borderRadius.md : 0,
|
|
74
|
-
borderBottomLeftRadius: e.isMobile ? 0 : e.borderRadius.md,
|
|
75
|
-
overflow: "hidden",
|
|
76
|
-
height: "auto",
|
|
77
|
-
position: "relative",
|
|
78
|
-
minHeight: e.isMobile ? "210px" : "430px",
|
|
79
|
-
backgroundColor: ((t = e.brandingColors) == null ? void 0 : t.backgroundColor) || e.textColor + "10"
|
|
80
|
-
},
|
|
81
|
-
// Embed code headline section (for poll-vote and classic-quiz-play)
|
|
82
|
-
embedCodeHeadlineSection: {
|
|
83
|
-
display: "flex",
|
|
84
|
-
flexDirection: "column",
|
|
85
|
-
justifyContent: "space-between",
|
|
86
|
-
gap: "10px",
|
|
87
|
-
flex: e.isMobile ? "1" : "0 0 50%",
|
|
88
|
-
width: e.isMobile ? "100%" : "50%",
|
|
89
|
-
minWidth: e.isMobile ? "100%" : "50%",
|
|
90
|
-
maxWidth: e.isMobile ? "100%" : "50%",
|
|
91
|
-
borderTopLeftRadius: e.borderRadius.md,
|
|
92
|
-
borderTopRightRadius: e.isMobile ? e.borderRadius.md : 0,
|
|
93
|
-
borderBottomLeftRadius: e.isMobile ? 0 : e.borderRadius.md,
|
|
94
|
-
overflow: "hidden",
|
|
95
|
-
height: "auto",
|
|
96
|
-
position: "relative",
|
|
97
|
-
minHeight: e.isMobile ? "210px" : "430px"
|
|
98
|
-
},
|
|
99
|
-
// AspectRatio container for embed code
|
|
100
|
-
aspectRatioContainer: {
|
|
101
|
-
borderRadius: 0,
|
|
102
|
-
width: "100%",
|
|
103
|
-
height: "100%"
|
|
104
|
-
},
|
|
105
|
-
// Headline content wrapper
|
|
106
|
-
headlineContent: {
|
|
107
|
-
zIndex: 1,
|
|
108
|
-
height: "100%",
|
|
109
|
-
p: e.spacingScale.xl,
|
|
110
|
-
gap: e.spacingScale.xl,
|
|
111
|
-
display: "flex",
|
|
112
|
-
flexDirection: "column",
|
|
113
|
-
justifyContent: "space-between"
|
|
114
|
-
},
|
|
115
|
-
// Embed code headline content (shown in question area when embed code is present)
|
|
116
|
-
embedCodeHeadlineContent: {
|
|
117
|
-
px: e.spacingScale.lg,
|
|
118
|
-
pt: e.spacingScale.lg,
|
|
119
|
-
display: "flex",
|
|
120
|
-
flexDirection: "column",
|
|
121
|
-
gap: e.spacingScale.md
|
|
122
|
-
},
|
|
123
|
-
// Headline typography (with image background)
|
|
124
|
-
headlineText: {
|
|
125
|
-
fontWeight: 500,
|
|
126
|
-
lineHeight: "166%",
|
|
127
|
-
letterSpacing: "1px",
|
|
128
|
-
fontSize: "0.75em",
|
|
129
|
-
color: ((a = e.brandingColors) == null ? void 0 : a.secondaryColor) || e.darkTextColor,
|
|
130
|
-
opacity: "70%",
|
|
131
|
-
textTransform: "uppercase",
|
|
132
|
-
fontFamily: e.fontFamilySecondary,
|
|
133
|
-
textAlign: e.isMobile ? "center" : "left"
|
|
134
|
-
},
|
|
135
|
-
// Headline typography (without image background)
|
|
136
|
-
headlineTextNoImage: {
|
|
137
|
-
fontWeight: 500,
|
|
138
|
-
lineHeight: "166%",
|
|
139
|
-
letterSpacing: "1px",
|
|
140
|
-
fontSize: "0.75em",
|
|
141
|
-
color: e.secondaryColor,
|
|
142
|
-
opacity: "70%",
|
|
143
|
-
textTransform: "uppercase",
|
|
144
|
-
fontFamily: e.fontFamilySecondary,
|
|
145
|
-
textAlign: e.isMobile ? "center" : "left"
|
|
146
|
-
},
|
|
147
|
-
// Content container
|
|
148
|
-
contentContainer: {
|
|
149
|
-
display: "flex",
|
|
150
|
-
flexDirection: "column",
|
|
151
|
-
gap: e.spacingScale["3xs"]
|
|
152
|
-
},
|
|
153
|
-
// Title typography (with image background)
|
|
154
|
-
titleText: {
|
|
155
|
-
fontWeight: 700,
|
|
156
|
-
lineHeight: "133%",
|
|
157
|
-
fontSize: "1.5em",
|
|
158
|
-
letterSpacing: "0.15px",
|
|
159
|
-
color: ((r = e.brandingColors) == null ? void 0 : r.contentColor) || e.darkTextColor,
|
|
160
|
-
fontFamily: e.fontFamilyPrimary,
|
|
161
|
-
textAlign: e.isMobile ? "center" : "left"
|
|
162
|
-
},
|
|
163
|
-
// Title typography (without image background)
|
|
164
|
-
titleTextNoImage: {
|
|
165
|
-
fontWeight: 700,
|
|
166
|
-
lineHeight: "133%",
|
|
167
|
-
fontSize: "1.5em",
|
|
168
|
-
letterSpacing: "0.15px",
|
|
169
|
-
color: e.textColor,
|
|
170
|
-
fontFamily: e.fontFamilyPrimary,
|
|
171
|
-
textAlign: e.isMobile ? "center" : "left"
|
|
172
|
-
},
|
|
173
|
-
// Description typography (with image background)
|
|
174
|
-
descriptionText: {
|
|
175
|
-
fontWeight: 400,
|
|
176
|
-
lineHeight: "140%",
|
|
177
|
-
fontSize: "1.25em",
|
|
178
|
-
letterSpacing: "0.15px",
|
|
179
|
-
color: ((l = e.brandingColors) == null ? void 0 : l.secondaryColor) || e.darkTextColor,
|
|
180
|
-
opacity: "70%",
|
|
181
|
-
fontFamily: e.fontFamilyPrimary,
|
|
182
|
-
textAlign: e.isMobile ? "center" : "left"
|
|
183
|
-
},
|
|
184
|
-
// Description typography (without image background)
|
|
185
|
-
descriptionTextNoImage: {
|
|
186
|
-
fontWeight: 400,
|
|
187
|
-
lineHeight: "140%",
|
|
188
|
-
fontSize: "1.25em",
|
|
189
|
-
letterSpacing: "0.15px",
|
|
190
|
-
color: e.secondaryColor,
|
|
191
|
-
opacity: "70%",
|
|
192
|
-
fontFamily: e.fontFamilyPrimary,
|
|
193
|
-
textAlign: e.isMobile ? "center" : "left"
|
|
194
|
-
},
|
|
195
|
-
// Question area / content section
|
|
196
|
-
questionArea: {
|
|
197
|
-
flex: e.isMobile ? "1" : "0 0 50%",
|
|
198
|
-
width: e.isMobile ? "100%" : "50%",
|
|
199
|
-
minWidth: e.isMobile ? "100%" : "50%",
|
|
200
|
-
maxWidth: e.isMobile ? "100%" : "50%",
|
|
201
|
-
display: "flex",
|
|
202
|
-
flexDirection: "column",
|
|
203
|
-
justifyContent: "center"
|
|
204
|
-
}
|
|
205
|
-
};
|
|
206
|
-
}, Jt = ({
|
|
207
|
-
entity: e,
|
|
208
|
-
headline: t,
|
|
209
|
-
finalImage: a,
|
|
210
|
-
children: r,
|
|
211
|
-
embedCodeContainerRef: l,
|
|
212
|
-
hasEmbedCode: f = !1,
|
|
213
|
-
brandingLogo: _,
|
|
214
|
-
renderPresentedBy: s,
|
|
215
|
-
rulesDisplay: E
|
|
216
|
-
}) => {
|
|
217
|
-
var G, F;
|
|
218
|
-
const o = ie(), u = Ie(), g = e.type === "poll" || e.type === "match-quiz" ? u : o, S = ae(), y = ne(), T = q().primary, O = q().secondary, D = Q(), C = ((G = e.branding) == null ? void 0 : G.colors) || null, A = ((F = e.branding) == null ? void 0 : F.urls) || null, P = (C == null ? void 0 : C.contentColor) || V().textColor, v = (C == null ? void 0 : C.secondaryColor) || V().textColor, w = (C == null ? void 0 : C.backgroundColor) || V().surfaceVariant, n = "60%", h = S.colorSchemes.dark.textColor, d = oe(
|
|
219
|
-
$.SPLIT
|
|
220
|
-
), x = Ye({
|
|
221
|
-
finalImage: a,
|
|
222
|
-
spacingScale: y,
|
|
223
|
-
borderRadius: D,
|
|
224
|
-
fontFamilyPrimary: T,
|
|
225
|
-
fontFamilySecondary: O,
|
|
226
|
-
secondaryColor: v,
|
|
227
|
-
opacity: n,
|
|
228
|
-
bgcolor: be(w || ""),
|
|
229
|
-
textColor: P,
|
|
230
|
-
brandingColors: C,
|
|
231
|
-
darkTextColor: h,
|
|
232
|
-
imageBackgroundGradient: d,
|
|
233
|
-
isMobile: g
|
|
234
|
-
}), I = Ne(
|
|
235
|
-
A == null ? void 0 : A.primaryUrl,
|
|
236
|
-
A == null ? void 0 : A.secondaryUrl,
|
|
237
|
-
"image"
|
|
238
|
-
), R = () => {
|
|
239
|
-
I && window.open(I, "_blank", "noopener,noreferrer");
|
|
240
|
-
}, N = (Y, H) => I ? typeof window > "u" ? /* @__PURE__ */ c(
|
|
241
|
-
m,
|
|
242
|
-
{
|
|
243
|
-
component: "a",
|
|
244
|
-
href: I,
|
|
245
|
-
target: "_blank",
|
|
246
|
-
rel: "noopener noreferrer",
|
|
247
|
-
sx: {
|
|
248
|
-
...H,
|
|
249
|
-
cursor: "pointer",
|
|
250
|
-
textDecoration: "none"
|
|
251
|
-
},
|
|
252
|
-
children: Y
|
|
253
|
-
}
|
|
254
|
-
) : /* @__PURE__ */ c(
|
|
255
|
-
m,
|
|
256
|
-
{
|
|
257
|
-
sx: {
|
|
258
|
-
...H,
|
|
259
|
-
cursor: "pointer"
|
|
260
|
-
},
|
|
261
|
-
onClick: R,
|
|
262
|
-
children: Y
|
|
263
|
-
}
|
|
264
|
-
) : /* @__PURE__ */ c(m, { sx: H, children: Y });
|
|
265
|
-
return /* @__PURE__ */ b(U, { children: [
|
|
266
|
-
f && l ? /* @__PURE__ */ c(m, { sx: x.embedCodeHeadlineSection, children: /* @__PURE__ */ c(
|
|
267
|
-
Fe,
|
|
268
|
-
{
|
|
269
|
-
ratio: "16/9",
|
|
270
|
-
sx: x.aspectRatioContainer,
|
|
271
|
-
slotProps: { content: { sx: { height: "100%" } } },
|
|
272
|
-
children: /* @__PURE__ */ c(m, { ref: l })
|
|
273
|
-
}
|
|
274
|
-
) }) : a ? N(
|
|
275
|
-
/* @__PURE__ */ b(m, { sx: x.headlineContent, children: [
|
|
276
|
-
/* @__PURE__ */ b(m, { children: [
|
|
277
|
-
/* @__PURE__ */ b(
|
|
278
|
-
m,
|
|
279
|
-
{
|
|
280
|
-
sx: {
|
|
281
|
-
display: "flex",
|
|
282
|
-
alignItems: "center",
|
|
283
|
-
justifyContent: g ? "center" : "flex-start",
|
|
284
|
-
gap: y["3xs"]
|
|
285
|
-
},
|
|
286
|
-
children: [
|
|
287
|
-
/* @__PURE__ */ c(L, { sx: x.headlineText, children: t }),
|
|
288
|
-
/* @__PURE__ */ c(W, { rulesDisplay: E, rules: e.rules || "" })
|
|
289
|
-
]
|
|
290
|
-
}
|
|
291
|
-
),
|
|
292
|
-
/* @__PURE__ */ b(m, { sx: x.contentContainer, children: [
|
|
293
|
-
/* @__PURE__ */ c(L, { sx: x.titleText, children: e.title }),
|
|
294
|
-
/* @__PURE__ */ c(L, { sx: x.descriptionText, children: j(e.description) })
|
|
295
|
-
] })
|
|
296
|
-
] }),
|
|
297
|
-
_ && !g && s && /* @__PURE__ */ c(m, { children: s((C == null ? void 0 : C.contentColor) || h) })
|
|
298
|
-
] }),
|
|
299
|
-
x.headlineSection
|
|
300
|
-
) : /* @__PURE__ */ c(m, { sx: x.headlineSectionNoImage, children: /* @__PURE__ */ b(m, { sx: x.headlineContent, children: [
|
|
301
|
-
/* @__PURE__ */ b(m, { children: [
|
|
302
|
-
/* @__PURE__ */ b(
|
|
303
|
-
m,
|
|
304
|
-
{
|
|
305
|
-
sx: {
|
|
306
|
-
display: "flex",
|
|
307
|
-
alignItems: "center",
|
|
308
|
-
justifyContent: g ? "center" : "flex-start",
|
|
309
|
-
gap: y["3xs"]
|
|
310
|
-
},
|
|
311
|
-
children: [
|
|
312
|
-
/* @__PURE__ */ c(L, { sx: x.headlineTextNoImage, children: t }),
|
|
313
|
-
/* @__PURE__ */ c(W, { rulesDisplay: E, rules: e.rules || "" })
|
|
314
|
-
]
|
|
315
|
-
}
|
|
316
|
-
),
|
|
317
|
-
/* @__PURE__ */ b(m, { sx: x.contentContainer, children: [
|
|
318
|
-
/* @__PURE__ */ c(L, { sx: x.titleTextNoImage, children: e.title }),
|
|
319
|
-
/* @__PURE__ */ c(L, { sx: x.descriptionTextNoImage, children: j(e.description) })
|
|
320
|
-
] })
|
|
321
|
-
] }),
|
|
322
|
-
_ && !g && s && /* @__PURE__ */ c(m, { children: s(P) })
|
|
323
|
-
] }) }),
|
|
324
|
-
/* @__PURE__ */ b(m, { sx: x.questionArea, children: [
|
|
325
|
-
f && l && /* @__PURE__ */ c(m, { sx: x.embedCodeHeadlineContent, children: /* @__PURE__ */ b(m, { children: [
|
|
326
|
-
/* @__PURE__ */ b(
|
|
327
|
-
m,
|
|
328
|
-
{
|
|
329
|
-
sx: {
|
|
330
|
-
display: "flex",
|
|
331
|
-
alignItems: "center",
|
|
332
|
-
justifyContent: "center",
|
|
333
|
-
gap: y["3xs"]
|
|
334
|
-
},
|
|
335
|
-
children: [
|
|
336
|
-
/* @__PURE__ */ c(
|
|
337
|
-
L,
|
|
338
|
-
{
|
|
339
|
-
sx: {
|
|
340
|
-
...x.headlineTextNoImage,
|
|
341
|
-
textAlign: "center"
|
|
342
|
-
},
|
|
343
|
-
children: t
|
|
344
|
-
}
|
|
345
|
-
),
|
|
346
|
-
/* @__PURE__ */ c(W, { rulesDisplay: E, rules: e.rules || "" })
|
|
347
|
-
]
|
|
348
|
-
}
|
|
349
|
-
),
|
|
350
|
-
/* @__PURE__ */ b(m, { sx: x.contentContainer, children: [
|
|
351
|
-
/* @__PURE__ */ c(
|
|
352
|
-
L,
|
|
353
|
-
{
|
|
354
|
-
sx: {
|
|
355
|
-
...x.titleTextNoImage,
|
|
356
|
-
textAlign: "center"
|
|
357
|
-
},
|
|
358
|
-
children: e.title
|
|
359
|
-
}
|
|
360
|
-
),
|
|
361
|
-
/* @__PURE__ */ c(
|
|
362
|
-
L,
|
|
363
|
-
{
|
|
364
|
-
sx: {
|
|
365
|
-
...x.descriptionTextNoImage,
|
|
366
|
-
textAlign: "center"
|
|
367
|
-
},
|
|
368
|
-
children: j(e.description)
|
|
369
|
-
}
|
|
370
|
-
)
|
|
371
|
-
] })
|
|
372
|
-
] }) }),
|
|
373
|
-
r
|
|
374
|
-
] })
|
|
375
|
-
] });
|
|
376
|
-
}, Ue = (e) => {
|
|
377
|
-
var t, a, r;
|
|
378
|
-
return {
|
|
379
|
-
// Wrapper container for the entire split layout
|
|
380
|
-
wrapper: {
|
|
381
|
-
display: "flex",
|
|
382
|
-
flexDirection: e.isMobile || e.isLarge && !e.alwaysShowImage || e.alwaysShowImage && e.isLarge ? "column" : "row",
|
|
383
|
-
width: "100%"
|
|
384
|
-
},
|
|
385
|
-
// Desktop image section with background image and overlay
|
|
386
|
-
desktopImageSection: {
|
|
387
|
-
display: e.isLarge && !e.alwaysShowImage ? "none" : "flex",
|
|
388
|
-
flexDirection: "column",
|
|
389
|
-
justifyContent: "space-between",
|
|
390
|
-
gap: "10px",
|
|
391
|
-
flex: e.isMobile || e.isLarge && e.alwaysShowImage ? "1" : "0 0 50%",
|
|
392
|
-
width: e.isMobile || e.isLarge && e.alwaysShowImage ? "100%" : "50%",
|
|
393
|
-
minWidth: e.isMobile || e.isLarge && e.alwaysShowImage ? "100%" : "50%",
|
|
394
|
-
maxWidth: e.isMobile || e.isLarge && e.alwaysShowImage ? "100%" : "50%",
|
|
395
|
-
backgroundImage: `url("${e.finalImage}")`,
|
|
396
|
-
backgroundSize: "cover",
|
|
397
|
-
backgroundPosition: "center",
|
|
398
|
-
borderTopLeftRadius: e.isTabulated ? 0 : e.borderRadius.md,
|
|
399
|
-
borderTopRightRadius: e.isMobile || e.isLarge && e.alwaysShowImage ? e.isTabulated ? 0 : e.borderRadius.md : 0,
|
|
400
|
-
borderBottomLeftRadius: e.isMobile || e.isLarge && e.alwaysShowImage ? 0 : e.borderRadius.md,
|
|
401
|
-
overflow: "hidden",
|
|
402
|
-
height: "auto",
|
|
403
|
-
position: "relative",
|
|
404
|
-
minHeight: e.isMobile || e.isLarge && e.alwaysShowImage ? "210px" : "430px",
|
|
405
|
-
maxHeight: e.isMobile || e.isLarge && e.alwaysShowImage ? "auto" : "100%",
|
|
406
|
-
"&::before": {
|
|
407
|
-
content: '""',
|
|
408
|
-
position: "absolute",
|
|
409
|
-
width: "100%",
|
|
410
|
-
height: "100%",
|
|
411
|
-
background: e.imageBackgroundGradient,
|
|
412
|
-
borderTopLeftRadius: "5px",
|
|
413
|
-
borderTopRightRadius: "5px"
|
|
414
|
-
}
|
|
415
|
-
},
|
|
416
|
-
// Image section content wrapper
|
|
417
|
-
imageSectionContent: {
|
|
418
|
-
zIndex: 1,
|
|
419
|
-
height: "100%",
|
|
420
|
-
p: e.spacingScale.xl,
|
|
421
|
-
display: "flex",
|
|
422
|
-
flexDirection: "column",
|
|
423
|
-
justifyContent: "space-between",
|
|
424
|
-
gap: e.spacingScale.xl
|
|
425
|
-
},
|
|
426
|
-
// Headline text
|
|
427
|
-
headlineText: {
|
|
428
|
-
fontWeight: 500,
|
|
429
|
-
lineHeight: "166%",
|
|
430
|
-
letterSpacing: "1px",
|
|
431
|
-
fontSize: "0.75em",
|
|
432
|
-
color: ((t = e.brandingColors) == null ? void 0 : t.secondaryColor) || e.darkTextColor,
|
|
433
|
-
opacity: "70%",
|
|
434
|
-
textTransform: "uppercase",
|
|
435
|
-
fontFamily: e.fontFamilySecondary,
|
|
436
|
-
textAlign: e.isLarge ? "center" : "left"
|
|
437
|
-
},
|
|
438
|
-
// Content container (title + description)
|
|
439
|
-
contentContainer: {
|
|
440
|
-
display: "flex",
|
|
441
|
-
flexDirection: "column",
|
|
442
|
-
gap: e.spacingScale["3xs"]
|
|
443
|
-
},
|
|
444
|
-
// Title text
|
|
445
|
-
titleText: {
|
|
446
|
-
fontWeight: 700,
|
|
447
|
-
lineHeight: "133%",
|
|
448
|
-
fontSize: "1.5em",
|
|
449
|
-
letterSpacing: "0.15px",
|
|
450
|
-
color: ((a = e.brandingColors) == null ? void 0 : a.contentColor) || e.darkTextColor,
|
|
451
|
-
fontFamily: e.fontFamilyPrimary,
|
|
452
|
-
textAlign: e.isLarge ? "center" : "left"
|
|
453
|
-
},
|
|
454
|
-
// Description text
|
|
455
|
-
descriptionText: {
|
|
456
|
-
fontWeight: 500,
|
|
457
|
-
lineHeight: "140%",
|
|
458
|
-
fontSize: "1.25em",
|
|
459
|
-
letterSpacing: "0.15px",
|
|
460
|
-
color: ((r = e.brandingColors) == null ? void 0 : r.secondaryColor) || e.darkTextColor,
|
|
461
|
-
opacity: "70%",
|
|
462
|
-
fontFamily: e.fontFamilyPrimary,
|
|
463
|
-
textAlign: e.isLarge ? "center" : "left"
|
|
464
|
-
},
|
|
465
|
-
// Presented by desktop container
|
|
466
|
-
presentedByDesktop: {
|
|
467
|
-
display: "block"
|
|
468
|
-
},
|
|
469
|
-
// Question/Content area (right side on desktop, below image on mobile)
|
|
470
|
-
questionArea: {
|
|
471
|
-
flex: e.isMobile || e.isLarge && !e.alwaysShowImage || e.alwaysShowImage && e.isLarge ? "1" : "0 0 50%",
|
|
472
|
-
width: e.isMobile || e.isLarge && !e.alwaysShowImage || e.alwaysShowImage && e.isLarge ? "100%" : "50%",
|
|
473
|
-
minWidth: e.isMobile || e.isLarge && !e.alwaysShowImage || e.alwaysShowImage && e.isLarge ? "100%" : "50%",
|
|
474
|
-
maxWidth: e.isMobile || e.isLarge && !e.alwaysShowImage || e.alwaysShowImage && e.isLarge ? "100%" : "50%",
|
|
475
|
-
display: "flex",
|
|
476
|
-
flexDirection: "column"
|
|
477
|
-
}
|
|
478
|
-
};
|
|
479
|
-
}, Qt = ({
|
|
480
|
-
entity: e,
|
|
481
|
-
headline: t,
|
|
482
|
-
finalImage: a,
|
|
483
|
-
brandingContent: r,
|
|
484
|
-
children: l,
|
|
485
|
-
isTabulated: f = !1,
|
|
486
|
-
alwaysShowImage: _ = !1,
|
|
487
|
-
rulesDisplay: s
|
|
488
|
-
}) => {
|
|
489
|
-
var A;
|
|
490
|
-
const E = ie(), o = Ie(), u = ae(), g = ne(), S = q().primary, y = q().secondary, T = Q(), O = oe(
|
|
491
|
-
$.SPLIT
|
|
492
|
-
), D = ((A = e.branding) == null ? void 0 : A.colors) || null, C = Ue({
|
|
493
|
-
finalImage: a,
|
|
494
|
-
spacingScale: g,
|
|
495
|
-
borderRadius: T,
|
|
496
|
-
fontFamilyPrimary: S,
|
|
497
|
-
fontFamilySecondary: y,
|
|
498
|
-
brandingColors: D,
|
|
499
|
-
darkTextColor: u.colorSchemes.dark.textColor,
|
|
500
|
-
imageBackgroundGradient: O,
|
|
501
|
-
isMobile: E,
|
|
502
|
-
isLarge: o,
|
|
503
|
-
isTabulated: f,
|
|
504
|
-
alwaysShowImage: _
|
|
505
|
-
});
|
|
506
|
-
return /* @__PURE__ */ b(m, { sx: C.wrapper, children: [
|
|
507
|
-
/* @__PURE__ */ c(m, { sx: C.desktopImageSection, children: /* @__PURE__ */ b(m, { sx: C.imageSectionContent, children: [
|
|
508
|
-
/* @__PURE__ */ b(m, { children: [
|
|
509
|
-
/* @__PURE__ */ b(
|
|
510
|
-
m,
|
|
511
|
-
{
|
|
512
|
-
sx: {
|
|
513
|
-
display: "flex",
|
|
514
|
-
alignItems: "center",
|
|
515
|
-
gap: g["3xs"]
|
|
516
|
-
},
|
|
517
|
-
children: [
|
|
518
|
-
/* @__PURE__ */ c(L, { level: "body-sm", sx: C.headlineText, children: t }),
|
|
519
|
-
/* @__PURE__ */ c(W, { rulesDisplay: s, rules: e.rules || "" })
|
|
520
|
-
]
|
|
521
|
-
}
|
|
522
|
-
),
|
|
523
|
-
/* @__PURE__ */ b(m, { sx: C.contentContainer, children: [
|
|
524
|
-
/* @__PURE__ */ c(L, { level: "body-lg", sx: C.titleText, children: e.title }),
|
|
525
|
-
/* @__PURE__ */ c(L, { level: "body-md", sx: C.descriptionText, children: j(e.description) })
|
|
526
|
-
] })
|
|
527
|
-
] }),
|
|
528
|
-
/* @__PURE__ */ c(m, { sx: C.presentedByDesktop, children: r })
|
|
529
|
-
] }) }),
|
|
530
|
-
/* @__PURE__ */ c(m, { sx: C.questionArea, children: l })
|
|
531
|
-
] });
|
|
532
|
-
}, je = (e) => {
|
|
533
|
-
var t, a, r;
|
|
534
|
-
return {
|
|
535
|
-
// Mobile headline with image background
|
|
536
|
-
mobileHeadlineWithImage: {
|
|
537
|
-
display: e.isMobile ? "flex" : "none",
|
|
538
|
-
flexDirection: "column",
|
|
539
|
-
justifyContent: "space-between",
|
|
540
|
-
gap: "10px",
|
|
541
|
-
backgroundImage: `url("${e.finalImage}")`,
|
|
542
|
-
backgroundSize: "cover",
|
|
543
|
-
backgroundPosition: "center",
|
|
544
|
-
borderTopLeftRadius: "5px",
|
|
545
|
-
borderTopRightRadius: "5px",
|
|
546
|
-
position: "relative",
|
|
547
|
-
minHeight: "210px",
|
|
548
|
-
overflow: "hidden",
|
|
549
|
-
height: "auto",
|
|
550
|
-
"&::before": {
|
|
551
|
-
content: '""',
|
|
552
|
-
position: "absolute",
|
|
553
|
-
width: "100%",
|
|
554
|
-
height: "100%",
|
|
555
|
-
background: e.imageBackgroundGradient,
|
|
556
|
-
borderTopLeftRadius: "5px",
|
|
557
|
-
borderTopRightRadius: "5px"
|
|
558
|
-
}
|
|
559
|
-
},
|
|
560
|
-
// Content inside mobile headline with image
|
|
561
|
-
mobileHeadlineContent: {
|
|
562
|
-
zIndex: 1,
|
|
563
|
-
height: "100%",
|
|
564
|
-
p: e.spacingScale.xl,
|
|
565
|
-
gap: e.spacingScale["2xl"],
|
|
566
|
-
display: "flex",
|
|
567
|
-
flexDirection: "column",
|
|
568
|
-
justifyContent: "space-between"
|
|
569
|
-
},
|
|
570
|
-
// Mobile headline without image
|
|
571
|
-
mobileHeadlineWithoutImage: {
|
|
572
|
-
display: e.isMobile ? "flex" : "none",
|
|
573
|
-
flex: "0.5",
|
|
574
|
-
flexDirection: "column",
|
|
575
|
-
justifyContent: "space-between",
|
|
576
|
-
p: e.spacingScale.lg,
|
|
577
|
-
gap: e.spacingScale["2xl"]
|
|
578
|
-
},
|
|
579
|
-
// Headline typography (mobile with image)
|
|
580
|
-
headlineTypographyMobileImage: {
|
|
581
|
-
fontWeight: 500,
|
|
582
|
-
lineHeight: "166%",
|
|
583
|
-
letterSpacing: "1px",
|
|
584
|
-
fontSize: "0.75em",
|
|
585
|
-
color: ((t = e.brandingColors) == null ? void 0 : t.secondaryColor) || e.darkTextColor,
|
|
586
|
-
opacity: "70%",
|
|
587
|
-
textTransform: "uppercase",
|
|
588
|
-
fontFamily: e.fontFamilySecondary,
|
|
589
|
-
textAlign: "center"
|
|
590
|
-
},
|
|
591
|
-
// Headline typography (mobile without image & desktop)
|
|
592
|
-
headlineTypography: {
|
|
593
|
-
fontWeight: 500,
|
|
594
|
-
lineHeight: "166%",
|
|
595
|
-
letterSpacing: "1px",
|
|
596
|
-
textTransform: "uppercase",
|
|
597
|
-
fontSize: "0.75em",
|
|
598
|
-
color: e.secondaryColor,
|
|
599
|
-
opacity: e.opacity,
|
|
600
|
-
fontFamily: e.fontFamilySecondary,
|
|
601
|
-
textAlign: "center"
|
|
602
|
-
},
|
|
603
|
-
// Title typography (mobile with image)
|
|
604
|
-
titleTypographyMobileImage: {
|
|
605
|
-
fontWeight: 700,
|
|
606
|
-
lineHeight: "133%",
|
|
607
|
-
fontSize: "1.5em",
|
|
608
|
-
letterSpacing: "0.15px",
|
|
609
|
-
color: ((a = e.brandingColors) == null ? void 0 : a.contentColor) || e.darkTextColor,
|
|
610
|
-
fontFamily: e.fontFamilyPrimary,
|
|
611
|
-
textAlign: "center"
|
|
612
|
-
},
|
|
613
|
-
// Title typography (mobile without image & desktop)
|
|
614
|
-
titleTypography: {
|
|
615
|
-
fontWeight: 700,
|
|
616
|
-
lineHeight: "133%",
|
|
617
|
-
letterSpacing: "0px",
|
|
618
|
-
fontSize: "1.5em",
|
|
619
|
-
color: e.textColor,
|
|
620
|
-
fontFamily: e.fontFamilyPrimary,
|
|
621
|
-
textAlign: e.isMobile ? "center" : "left"
|
|
622
|
-
},
|
|
623
|
-
// Description typography (mobile with image)
|
|
624
|
-
descriptionTypographyMobileImage: {
|
|
625
|
-
fontWeight: 400,
|
|
626
|
-
lineHeight: "140%",
|
|
627
|
-
fontSize: "1.25em",
|
|
628
|
-
letterSpacing: "0.15px",
|
|
629
|
-
color: ((r = e.brandingColors) == null ? void 0 : r.secondaryColor) || e.darkTextColor,
|
|
630
|
-
opacity: "70%",
|
|
631
|
-
fontFamily: e.fontFamilyPrimary,
|
|
632
|
-
textAlign: "center"
|
|
633
|
-
},
|
|
634
|
-
// Description typography (mobile without image & desktop)
|
|
635
|
-
descriptionTypography: {
|
|
636
|
-
fontWeight: 400,
|
|
637
|
-
lineHeight: "140%",
|
|
638
|
-
letterSpacing: "0.15px",
|
|
639
|
-
fontSize: "1.25em",
|
|
640
|
-
color: e.secondaryColor,
|
|
641
|
-
opacity: e.opacity,
|
|
642
|
-
fontFamily: e.fontFamilyPrimary,
|
|
643
|
-
textAlign: e.isMobile ? "center" : "left"
|
|
644
|
-
},
|
|
645
|
-
// Desktop title typography (centered)
|
|
646
|
-
titleTypographyDesktop: {
|
|
647
|
-
fontWeight: 700,
|
|
648
|
-
lineHeight: "133%",
|
|
649
|
-
letterSpacing: "0px",
|
|
650
|
-
fontSize: "1.5em",
|
|
651
|
-
color: e.textColor,
|
|
652
|
-
fontFamily: e.fontFamilyPrimary
|
|
653
|
-
},
|
|
654
|
-
// Desktop description typography (centered)
|
|
655
|
-
descriptionTypographyDesktop: {
|
|
656
|
-
fontWeight: 400,
|
|
657
|
-
lineHeight: "140%",
|
|
658
|
-
letterSpacing: "0.15px",
|
|
659
|
-
fontSize: "1.25em",
|
|
660
|
-
color: e.secondaryColor,
|
|
661
|
-
opacity: e.opacity,
|
|
662
|
-
fontFamily: e.fontFamilyPrimary
|
|
663
|
-
},
|
|
664
|
-
// Image container (left position)
|
|
665
|
-
imageContainerLeft: {
|
|
666
|
-
display: e.isMobile ? "none" : "block",
|
|
667
|
-
flex: "0.3",
|
|
668
|
-
borderTopLeftRadius: e.borderRadius.md,
|
|
669
|
-
borderBottomLeftRadius: e.borderRadius.md,
|
|
670
|
-
overflow: "hidden",
|
|
671
|
-
height: "auto",
|
|
672
|
-
position: "relative"
|
|
673
|
-
},
|
|
674
|
-
// Image container (right position)
|
|
675
|
-
imageContainerRight: {
|
|
676
|
-
display: e.isMobile ? "none" : "block",
|
|
677
|
-
flex: "0.3",
|
|
678
|
-
borderTopRightRadius: "5px",
|
|
679
|
-
borderBottomRightRadius: "5px",
|
|
680
|
-
overflow: "hidden",
|
|
681
|
-
height: "auto",
|
|
682
|
-
position: "relative"
|
|
683
|
-
},
|
|
684
|
-
// Main content area
|
|
685
|
-
mainContentArea: {
|
|
686
|
-
flex: e.isMobile ? "1" : e.finalImage ? "0.7" : "1",
|
|
687
|
-
// display: props.isMobile ? "block" : "flex",
|
|
688
|
-
display: "flex",
|
|
689
|
-
flexDirection: "column",
|
|
690
|
-
p: e.spacingScale.md,
|
|
691
|
-
gap: e.isMobile ? e.spacingScale.md : e.spacingScale.lg
|
|
692
|
-
},
|
|
693
|
-
// Desktop headline container
|
|
694
|
-
desktopHeadlineContainer: {
|
|
695
|
-
display: e.isMobile ? "none" : "flex",
|
|
696
|
-
flexDirection: "column",
|
|
697
|
-
justifyContent: "space-between",
|
|
698
|
-
gap: e.spacingScale["2xl"],
|
|
699
|
-
textAlign: "center"
|
|
700
|
-
},
|
|
701
|
-
// Content container
|
|
702
|
-
contentContainer: {
|
|
703
|
-
display: "flex",
|
|
704
|
-
flexDirection: "column",
|
|
705
|
-
gap: e.spacingScale["3xs"]
|
|
706
|
-
},
|
|
707
|
-
// Question area
|
|
708
|
-
questionArea: {
|
|
709
|
-
display: "flex",
|
|
710
|
-
flexDirection: "column",
|
|
711
|
-
px: e.spacingScale.md
|
|
712
|
-
},
|
|
713
|
-
// Question container
|
|
714
|
-
questionContainer: {
|
|
715
|
-
display: "flex",
|
|
716
|
-
flexDirection: "column",
|
|
717
|
-
gap: e.isMobile ? e.spacingScale.md : e.spacingScale.lg
|
|
718
|
-
},
|
|
719
|
-
// Alert container
|
|
720
|
-
alertContainer: {
|
|
721
|
-
// py: props.spacingScale.md,
|
|
722
|
-
display: "flex",
|
|
723
|
-
flexDirection: "column",
|
|
724
|
-
backdropFilter: "blur(4px)"
|
|
725
|
-
},
|
|
726
|
-
image: {
|
|
727
|
-
width: "100%",
|
|
728
|
-
height: "100%",
|
|
729
|
-
objectFit: "cover"
|
|
730
|
-
},
|
|
731
|
-
// CTA container
|
|
732
|
-
ctaContainer: {
|
|
733
|
-
display: "flex",
|
|
734
|
-
flexDirection: "column",
|
|
735
|
-
alignItems: "center"
|
|
736
|
-
},
|
|
737
|
-
// CTA content wrapper
|
|
738
|
-
ctaContentWrapper: {
|
|
739
|
-
display: "flex",
|
|
740
|
-
flexDirection: "column",
|
|
741
|
-
justifyContent: "center",
|
|
742
|
-
alignItems: "center",
|
|
743
|
-
gap: e.spacingScale.lg
|
|
744
|
-
},
|
|
745
|
-
// Buttons container
|
|
746
|
-
buttonsContainer: {
|
|
747
|
-
display: "flex",
|
|
748
|
-
flexDirection: e.isMobile ? "column" : "row",
|
|
749
|
-
gap: e.spacingScale.md
|
|
750
|
-
},
|
|
751
|
-
// Try again button
|
|
752
|
-
tryAgainButton: {
|
|
753
|
-
display: "flex",
|
|
754
|
-
py: e.spacingScale.xs,
|
|
755
|
-
px: "16px",
|
|
756
|
-
flexDirection: "column",
|
|
757
|
-
justifyContent: "center",
|
|
758
|
-
alignItems: "center",
|
|
759
|
-
gap: "8px",
|
|
760
|
-
borderRadius: e.borderRadius.xl,
|
|
761
|
-
border: e.borderSize + " solid " + e.primaryColor,
|
|
762
|
-
bgcolor: e.buttonBgColor,
|
|
763
|
-
"&:hover": {
|
|
764
|
-
bgcolor: e.onSurfaceColor,
|
|
765
|
-
borderColor: e.primaryColor
|
|
766
|
-
},
|
|
767
|
-
fontSize: "0.8125em"
|
|
768
|
-
},
|
|
769
|
-
// Try again button content
|
|
770
|
-
tryAgainButtonContent: {
|
|
771
|
-
display: "flex",
|
|
772
|
-
justifyContent: "center",
|
|
773
|
-
alignItems: "center",
|
|
774
|
-
gap: "8px",
|
|
775
|
-
alignSelf: "stretch"
|
|
776
|
-
},
|
|
777
|
-
// Try again icon
|
|
778
|
-
tryAgainIcon: {
|
|
779
|
-
display: "flex",
|
|
780
|
-
width: "16px",
|
|
781
|
-
height: "16px",
|
|
782
|
-
justifyContent: "flex-end",
|
|
783
|
-
alignItems: "center",
|
|
784
|
-
color: e.textPrimary
|
|
785
|
-
},
|
|
786
|
-
// Try again text
|
|
787
|
-
tryAgainText: {
|
|
788
|
-
color: e.textPrimary,
|
|
789
|
-
textAlign: "center",
|
|
790
|
-
fontFamily: e.fontFamilyPrimary,
|
|
791
|
-
fontSize: "0.8125em",
|
|
792
|
-
fontStyle: "normal",
|
|
793
|
-
fontWeight: 500,
|
|
794
|
-
lineHeight: "22px",
|
|
795
|
-
letterSpacing: "0.46px",
|
|
796
|
-
textTransform: "uppercase"
|
|
797
|
-
},
|
|
798
|
-
// Presented by container
|
|
799
|
-
presentedByContainer: {
|
|
800
|
-
px: e.spacingScale.md
|
|
801
|
-
}
|
|
802
|
-
};
|
|
803
|
-
}, Ee = ve(/* @__PURE__ */ c("path", {
|
|
804
|
-
d: "M12 5V1L7 6l5 5V7c3.31 0 6 2.69 6 6s-2.69 6-6 6-6-2.69-6-6H4c0 4.42 3.58 8 8 8s8-3.58 8-8-3.58-8-8-8"
|
|
805
|
-
}), "Replay"), Zt = (e) => {
|
|
806
|
-
var d;
|
|
807
|
-
const t = ((d = e.entity.branding) == null ? void 0 : d.colors) || null, a = ae(), r = ie(), l = _e(
|
|
808
|
-
{
|
|
809
|
-
images: e.entity.images || null,
|
|
810
|
-
imagePlaceholder: e.defaultImagePlaceholderUrl ? e.defaultImagePlaceholderUrl : ""
|
|
811
|
-
},
|
|
812
|
-
$.STANDARD
|
|
813
|
-
), f = ne(), _ = q().primary, s = q().secondary, E = Q(), o = (t == null ? void 0 : t.contentColor) || V().textColor, u = V().textPrimary, g = (t == null ? void 0 : t.primaryColor) || V().palette.primary.plainColor, S = (t == null ? void 0 : t.secondaryColor) || V().textColor, y = Le().size, T = V().surface, O = V().onSurface, D = oe(
|
|
814
|
-
$.STANDARD
|
|
815
|
-
), { t: C } = le(), A = e.imagePosition || "left", P = "60%", v = e.customAlertTitle ?? (e.isApiError ? C("common.error.title") : C("common.authentication.accessRequired")), w = e.customAlertMessage ?? (e.isApiError ? e.apiErrorMessage || C("common.error.message") : C("common.authentication.invalidOrMissingAuth")), n = je({
|
|
816
|
-
finalImage: l,
|
|
817
|
-
spacingScale: f,
|
|
818
|
-
borderRadius: E,
|
|
819
|
-
fontFamilyPrimary: _,
|
|
820
|
-
fontFamilySecondary: s,
|
|
821
|
-
textColor: o,
|
|
822
|
-
secondaryColor: S,
|
|
823
|
-
brandingColors: t,
|
|
824
|
-
darkTextColor: a.colorSchemes.dark.textColor,
|
|
825
|
-
opacity: P,
|
|
826
|
-
imagePosition: A,
|
|
827
|
-
imageBackgroundGradient: D,
|
|
828
|
-
textPrimary: u,
|
|
829
|
-
primaryColor: g,
|
|
830
|
-
borderSize: y,
|
|
831
|
-
buttonBgColor: T,
|
|
832
|
-
onSurfaceColor: O,
|
|
833
|
-
isMobile: r
|
|
834
|
-
}), h = () => !e.isApiError || !e.toggleTryAgain ? /* @__PURE__ */ c(U, {}) : /* @__PURE__ */ b(U, { children: [
|
|
835
|
-
/* @__PURE__ */ c(m, { sx: n.ctaContainer, children: /* @__PURE__ */ c(m, { sx: n.ctaContentWrapper, children: /* @__PURE__ */ c(m, { sx: n.buttonsContainer, children: /* @__PURE__ */ c(te, { sx: n.tryAgainButton, onClick: e.toggleTryAgain, children: /* @__PURE__ */ b(m, { sx: n.tryAgainButtonContent, children: [
|
|
836
|
-
/* @__PURE__ */ c(Ee, { sx: n.tryAgainIcon }),
|
|
837
|
-
/* @__PURE__ */ c(L, { sx: n.tryAgainText, children: e.tryAgainButtonText })
|
|
838
|
-
] }) }) }) }) }),
|
|
839
|
-
/* @__PURE__ */ c(m, { sx: n.presentedByContainer, children: e.renderPresentedBy(o) })
|
|
840
|
-
] });
|
|
841
|
-
return /* @__PURE__ */ b(U, { children: [
|
|
842
|
-
l ? /* @__PURE__ */ c(m, { sx: n.mobileHeadlineWithImage, children: /* @__PURE__ */ c(m, { sx: n.mobileHeadlineContent, children: /* @__PURE__ */ b(m, { children: [
|
|
843
|
-
/* @__PURE__ */ b(
|
|
844
|
-
m,
|
|
845
|
-
{
|
|
846
|
-
sx: {
|
|
847
|
-
display: "flex",
|
|
848
|
-
alignItems: "center",
|
|
849
|
-
justifyContent: "center",
|
|
850
|
-
gap: f["3xs"]
|
|
851
|
-
},
|
|
852
|
-
children: [
|
|
853
|
-
/* @__PURE__ */ c(
|
|
854
|
-
L,
|
|
855
|
-
{
|
|
856
|
-
level: "body-sm",
|
|
857
|
-
sx: n.headlineTypographyMobileImage,
|
|
858
|
-
children: e.headline
|
|
859
|
-
}
|
|
860
|
-
),
|
|
861
|
-
/* @__PURE__ */ c(
|
|
862
|
-
W,
|
|
863
|
-
{
|
|
864
|
-
rulesDisplay: e.rulesDisplay,
|
|
865
|
-
rules: e.entity.rules || ""
|
|
866
|
-
}
|
|
867
|
-
)
|
|
868
|
-
]
|
|
869
|
-
}
|
|
870
|
-
),
|
|
871
|
-
/* @__PURE__ */ b(m, { sx: n.contentContainer, children: [
|
|
872
|
-
/* @__PURE__ */ c(
|
|
873
|
-
L,
|
|
874
|
-
{
|
|
875
|
-
level: "body-lg",
|
|
876
|
-
sx: n.titleTypographyMobileImage,
|
|
877
|
-
children: e.entity.title
|
|
878
|
-
}
|
|
879
|
-
),
|
|
880
|
-
/* @__PURE__ */ c(
|
|
881
|
-
L,
|
|
882
|
-
{
|
|
883
|
-
level: "body-md",
|
|
884
|
-
sx: n.descriptionTypographyMobileImage,
|
|
885
|
-
children: j(e.entity.description)
|
|
886
|
-
}
|
|
887
|
-
)
|
|
888
|
-
] })
|
|
889
|
-
] }) }) }) : /* @__PURE__ */ c(m, { sx: n.mobileHeadlineWithoutImage, children: /* @__PURE__ */ b(m, { children: [
|
|
890
|
-
/* @__PURE__ */ b(
|
|
891
|
-
m,
|
|
892
|
-
{
|
|
893
|
-
sx: {
|
|
894
|
-
display: "flex",
|
|
895
|
-
alignItems: "center",
|
|
896
|
-
justifyContent: "center",
|
|
897
|
-
gap: f["3xs"]
|
|
898
|
-
},
|
|
899
|
-
children: [
|
|
900
|
-
/* @__PURE__ */ c(L, { level: "body-sm", sx: n.headlineTypography, children: e.headline }),
|
|
901
|
-
/* @__PURE__ */ c(
|
|
902
|
-
W,
|
|
903
|
-
{
|
|
904
|
-
rulesDisplay: e.rulesDisplay,
|
|
905
|
-
rules: e.entity.rules || ""
|
|
906
|
-
}
|
|
907
|
-
)
|
|
908
|
-
]
|
|
909
|
-
}
|
|
910
|
-
),
|
|
911
|
-
/* @__PURE__ */ b(m, { sx: n.contentContainer, children: [
|
|
912
|
-
/* @__PURE__ */ c(L, { level: "h4", sx: n.titleTypography, children: e.entity.title }),
|
|
913
|
-
/* @__PURE__ */ c(L, { level: "body-md", sx: n.descriptionTypography, children: j(e.entity.description) })
|
|
914
|
-
] })
|
|
915
|
-
] }) }),
|
|
916
|
-
l && A === "left" && /* @__PURE__ */ c(m, { sx: n.imageContainerLeft, children: /* @__PURE__ */ c("img", { src: l, alt: "illustration", style: n.image }) }),
|
|
917
|
-
/* @__PURE__ */ b(m, { sx: n.mainContentArea, children: [
|
|
918
|
-
/* @__PURE__ */ c(m, { sx: { px: f.md }, children: /* @__PURE__ */ c(m, { sx: n.desktopHeadlineContainer, children: /* @__PURE__ */ b(
|
|
919
|
-
m,
|
|
920
|
-
{
|
|
921
|
-
sx: {
|
|
922
|
-
display: "flex",
|
|
923
|
-
flexDirection: "column",
|
|
924
|
-
alignItems: "center"
|
|
925
|
-
},
|
|
926
|
-
children: [
|
|
927
|
-
/* @__PURE__ */ b(
|
|
928
|
-
m,
|
|
929
|
-
{
|
|
930
|
-
sx: {
|
|
931
|
-
display: "flex",
|
|
932
|
-
alignItems: "center",
|
|
933
|
-
gap: f["3xs"]
|
|
934
|
-
},
|
|
935
|
-
children: [
|
|
936
|
-
/* @__PURE__ */ c(L, { level: "body-sm", sx: n.headlineTypography, children: e.headline }),
|
|
937
|
-
/* @__PURE__ */ c(
|
|
938
|
-
W,
|
|
939
|
-
{
|
|
940
|
-
rulesDisplay: e.rulesDisplay,
|
|
941
|
-
rules: e.entity.rules || ""
|
|
942
|
-
}
|
|
943
|
-
)
|
|
944
|
-
]
|
|
945
|
-
}
|
|
946
|
-
),
|
|
947
|
-
/* @__PURE__ */ b(m, { sx: n.contentContainer, children: [
|
|
948
|
-
/* @__PURE__ */ c(L, { level: "h4", sx: n.titleTypographyDesktop, children: e.entity.title }),
|
|
949
|
-
/* @__PURE__ */ c(
|
|
950
|
-
L,
|
|
951
|
-
{
|
|
952
|
-
level: "body-md",
|
|
953
|
-
sx: n.descriptionTypographyDesktop,
|
|
954
|
-
children: j(e.entity.description)
|
|
955
|
-
}
|
|
956
|
-
)
|
|
957
|
-
] })
|
|
958
|
-
]
|
|
959
|
-
}
|
|
960
|
-
) }) }),
|
|
961
|
-
/* @__PURE__ */ c(m, { sx: n.questionArea, children: /* @__PURE__ */ c(m, { sx: n.questionContainer, children: /* @__PURE__ */ c(m, { sx: n.alertContainer, children: /* @__PURE__ */ c(
|
|
962
|
-
xe,
|
|
963
|
-
{
|
|
964
|
-
variant: e.alertVariant || "error",
|
|
965
|
-
title: v,
|
|
966
|
-
message: w
|
|
967
|
-
}
|
|
968
|
-
) }) }) }),
|
|
969
|
-
h(),
|
|
970
|
-
!e.isApiError && /* @__PURE__ */ c(m, { sx: { ...n.presentedByContainer, mt: "auto" }, children: e.renderPresentedBy(o) })
|
|
971
|
-
] }),
|
|
972
|
-
l && A === "right" && /* @__PURE__ */ c(m, { sx: n.imageContainerRight, children: /* @__PURE__ */ c("img", { src: l, alt: "illustration", style: n.image }) })
|
|
973
|
-
] });
|
|
974
|
-
}, We = (e) => {
|
|
975
|
-
var t, a, r;
|
|
976
|
-
return {
|
|
977
|
-
// Main headline section with background image
|
|
978
|
-
headlineSection: {
|
|
979
|
-
display: "flex",
|
|
980
|
-
flexDirection: "column",
|
|
981
|
-
justifyContent: "space-between",
|
|
982
|
-
gap: "10px",
|
|
983
|
-
flex: "0.5",
|
|
984
|
-
backgroundImage: `url("${e.finalImage}")`,
|
|
985
|
-
backgroundSize: "cover",
|
|
986
|
-
backgroundPosition: "center",
|
|
987
|
-
borderTopLeftRadius: e.mdBorderRadius,
|
|
988
|
-
borderTopRightRadius: e.isMobile ? e.mdBorderRadius : 0,
|
|
989
|
-
borderBottomLeftRadius: e.isMobile ? 0 : e.mdBorderRadius,
|
|
990
|
-
overflow: "hidden",
|
|
991
|
-
height: "auto",
|
|
992
|
-
position: "relative",
|
|
993
|
-
minHeight: e.isMobile ? "210px" : "430px",
|
|
994
|
-
"&::before": {
|
|
995
|
-
content: '""',
|
|
996
|
-
position: "absolute",
|
|
997
|
-
width: "100%",
|
|
998
|
-
height: "100%",
|
|
999
|
-
background: e.imageBackgroundGradient,
|
|
1000
|
-
borderTopLeftRadius: "5px",
|
|
1001
|
-
borderTopRightRadius: "5px"
|
|
1002
|
-
}
|
|
1003
|
-
},
|
|
1004
|
-
// Headline content wrapper
|
|
1005
|
-
headlineContent: {
|
|
1006
|
-
zIndex: 1,
|
|
1007
|
-
height: "100%",
|
|
1008
|
-
p: e.spacingScale.xl,
|
|
1009
|
-
gap: e.spacingScale.xl,
|
|
1010
|
-
display: "flex",
|
|
1011
|
-
flexDirection: "column",
|
|
1012
|
-
justifyContent: "space-between"
|
|
1013
|
-
},
|
|
1014
|
-
// Headline text
|
|
1015
|
-
headlineText: {
|
|
1016
|
-
fontWeight: 500,
|
|
1017
|
-
lineHeight: "166%",
|
|
1018
|
-
letterSpacing: "1px",
|
|
1019
|
-
fontSize: "0.75em",
|
|
1020
|
-
color: ((t = e.brandingColors) == null ? void 0 : t.secondaryColor) || e.darkTextColor,
|
|
1021
|
-
opacity: "70%",
|
|
1022
|
-
textTransform: "uppercase",
|
|
1023
|
-
fontFamily: e.fontFamilySecondary,
|
|
1024
|
-
textAlign: e.isMobile ? "center" : "left"
|
|
1025
|
-
},
|
|
1026
|
-
// Content container
|
|
1027
|
-
contentContainer: {
|
|
1028
|
-
display: "flex",
|
|
1029
|
-
flexDirection: "column",
|
|
1030
|
-
gap: e.spacingScale["3xs"]
|
|
1031
|
-
},
|
|
1032
|
-
// Title text
|
|
1033
|
-
titleText: {
|
|
1034
|
-
fontWeight: 700,
|
|
1035
|
-
lineHeight: "133%",
|
|
1036
|
-
fontSize: "1.5em",
|
|
1037
|
-
letterSpacing: "0.15px",
|
|
1038
|
-
color: ((a = e.brandingColors) == null ? void 0 : a.contentColor) || e.darkTextColor,
|
|
1039
|
-
fontFamily: e.fontFamilyPrimary,
|
|
1040
|
-
textAlign: e.isMobile ? "center" : "left"
|
|
1041
|
-
},
|
|
1042
|
-
// Description text
|
|
1043
|
-
descriptionText: {
|
|
1044
|
-
fontWeight: 400,
|
|
1045
|
-
lineHeight: "140%",
|
|
1046
|
-
fontSize: "1.25em",
|
|
1047
|
-
letterSpacing: "0.15px",
|
|
1048
|
-
color: ((r = e.brandingColors) == null ? void 0 : r.secondaryColor) || e.darkTextColor,
|
|
1049
|
-
opacity: "70%",
|
|
1050
|
-
fontFamily: e.fontFamilyPrimary,
|
|
1051
|
-
textAlign: e.isMobile ? "center" : "left"
|
|
1052
|
-
},
|
|
1053
|
-
// Presented by desktop container
|
|
1054
|
-
presentedByDesktop: {
|
|
1055
|
-
display: e.isMobile ? "none" : "block"
|
|
1056
|
-
},
|
|
1057
|
-
// Question area (error section)
|
|
1058
|
-
questionArea: {
|
|
1059
|
-
flex: "0.5",
|
|
1060
|
-
display: "flex",
|
|
1061
|
-
flexDirection: "column",
|
|
1062
|
-
justifyContent: "center",
|
|
1063
|
-
gap: e.spacingScale.md,
|
|
1064
|
-
p: e.spacingScale.lg
|
|
1065
|
-
},
|
|
1066
|
-
// Presented by mobile container
|
|
1067
|
-
presentedByMobile: {
|
|
1068
|
-
display: e.isMobile ? "block" : "none"
|
|
1069
|
-
},
|
|
1070
|
-
// CTA container
|
|
1071
|
-
ctaContainer: {
|
|
1072
|
-
display: "flex",
|
|
1073
|
-
flexDirection: "column",
|
|
1074
|
-
alignItems: "center"
|
|
1075
|
-
},
|
|
1076
|
-
// CTA content wrapper
|
|
1077
|
-
ctaContentWrapper: {
|
|
1078
|
-
display: "flex",
|
|
1079
|
-
flexDirection: "column",
|
|
1080
|
-
justifyContent: "center",
|
|
1081
|
-
alignItems: "center",
|
|
1082
|
-
gap: e.spacingScale.lg
|
|
1083
|
-
},
|
|
1084
|
-
// Buttons container
|
|
1085
|
-
buttonsContainer: {
|
|
1086
|
-
display: "flex",
|
|
1087
|
-
flexDirection: "column",
|
|
1088
|
-
gap: "16px"
|
|
1089
|
-
},
|
|
1090
|
-
// Try again button
|
|
1091
|
-
tryAgainButton: {
|
|
1092
|
-
display: "flex",
|
|
1093
|
-
py: e.spacingScale.xs,
|
|
1094
|
-
px: "16px",
|
|
1095
|
-
flexDirection: "column",
|
|
1096
|
-
justifyContent: "center",
|
|
1097
|
-
alignItems: "center",
|
|
1098
|
-
gap: "8px",
|
|
1099
|
-
borderRadius: e.borderRadius.xl,
|
|
1100
|
-
color: e.textPrimary,
|
|
1101
|
-
bgcolor: e.surfaceColor,
|
|
1102
|
-
"&:hover": {
|
|
1103
|
-
bgcolor: e.onSurfaceColor
|
|
1104
|
-
},
|
|
1105
|
-
fontSize: "0.9375em"
|
|
1106
|
-
},
|
|
1107
|
-
// Try again button content
|
|
1108
|
-
tryAgainButtonContent: {
|
|
1109
|
-
display: "flex",
|
|
1110
|
-
justifyContent: "center",
|
|
1111
|
-
alignItems: "center",
|
|
1112
|
-
gap: "8px",
|
|
1113
|
-
alignSelf: "stretch"
|
|
1114
|
-
},
|
|
1115
|
-
// Try again icon
|
|
1116
|
-
tryAgainIcon: {
|
|
1117
|
-
display: "flex",
|
|
1118
|
-
width: "16px",
|
|
1119
|
-
height: "16px",
|
|
1120
|
-
justifyContent: "flex-end",
|
|
1121
|
-
alignItems: "center",
|
|
1122
|
-
color: e.textPrimary
|
|
1123
|
-
},
|
|
1124
|
-
// Try again text
|
|
1125
|
-
tryAgainText: {
|
|
1126
|
-
color: e.textPrimary,
|
|
1127
|
-
textAlign: "center",
|
|
1128
|
-
fontFamily: e.fontFamilyPrimary,
|
|
1129
|
-
fontSize: "0.8125em",
|
|
1130
|
-
fontStyle: "normal",
|
|
1131
|
-
fontWeight: 500,
|
|
1132
|
-
lineHeight: "22px",
|
|
1133
|
-
letterSpacing: "0.46px",
|
|
1134
|
-
textTransform: "uppercase"
|
|
1135
|
-
}
|
|
1136
|
-
};
|
|
1137
|
-
}, ei = (e) => {
|
|
1138
|
-
var n;
|
|
1139
|
-
const t = ae(), a = ie(), r = ((n = e.entity.branding) == null ? void 0 : n.colors) || null, l = e.defaultImagePlaceholderUrl ? e.defaultImagePlaceholderUrl : a ? we : Pe, f = _e(
|
|
1140
|
-
{
|
|
1141
|
-
images: e.entity.images || null,
|
|
1142
|
-
imagePlaceholder: l
|
|
1143
|
-
},
|
|
1144
|
-
$.SPLIT
|
|
1145
|
-
), { t: _ } = le(), s = V().textPrimary, E = V().surface, o = V().onSurface, u = (r == null ? void 0 : r.backgroundColor) || V().surfaceVariant, g = Q(), S = q().secondary, y = q().primary, T = Q().md, O = V().textColor, D = ne(), C = oe(
|
|
1146
|
-
$.SPLIT
|
|
1147
|
-
), A = e.customAlertTitle ?? (e.isApiError ? _("common.error.title") : _("common.authentication.accessRequired")), P = e.customAlertMessage ?? (e.isApiError ? e.apiErrorMessage || _("common.error.message") : _("common.authentication.invalidOrMissingAuth")), v = We({
|
|
1148
|
-
finalImage: f,
|
|
1149
|
-
spacingScale: D,
|
|
1150
|
-
borderRadius: Q(),
|
|
1151
|
-
fontFamilyPrimary: y,
|
|
1152
|
-
fontFamilySecondary: S,
|
|
1153
|
-
mdBorderRadius: T,
|
|
1154
|
-
textColor: O,
|
|
1155
|
-
brandingColors: r,
|
|
1156
|
-
darkTextColor: t.colorSchemes.dark.textColor,
|
|
1157
|
-
imageBackgroundGradient: C,
|
|
1158
|
-
textPrimary: s,
|
|
1159
|
-
surfaceColor: E,
|
|
1160
|
-
onSurfaceColor: o,
|
|
1161
|
-
isMobile: a
|
|
1162
|
-
}), w = () => !e.isApiError || !e.toggleTryAgain ? /* @__PURE__ */ c(U, {}) : /* @__PURE__ */ c(
|
|
1163
|
-
m,
|
|
1164
|
-
{
|
|
1165
|
-
sx: {
|
|
1166
|
-
p: D.lg,
|
|
1167
|
-
gap: D.lg,
|
|
1168
|
-
display: "flex",
|
|
1169
|
-
flexDirection: "column",
|
|
1170
|
-
backdropFilter: "blur(4px)",
|
|
1171
|
-
bgcolor: `rgba(${u ? be(u || "").replace(/[^\d,]/g, "") : ""}, 0.5)`,
|
|
1172
|
-
borderRadius: g.sm
|
|
1173
|
-
},
|
|
1174
|
-
children: /* @__PURE__ */ c(m, { sx: v.ctaContainer, children: /* @__PURE__ */ c(m, { sx: v.ctaContentWrapper, children: /* @__PURE__ */ c(m, { sx: v.buttonsContainer, children: /* @__PURE__ */ c(te, { sx: v.tryAgainButton, onClick: e.toggleTryAgain, children: /* @__PURE__ */ b(m, { sx: v.tryAgainButtonContent, children: [
|
|
1175
|
-
/* @__PURE__ */ c(Ee, { sx: v.tryAgainIcon }),
|
|
1176
|
-
/* @__PURE__ */ c(L, { sx: v.tryAgainText, children: e.tryAgainButtonText })
|
|
1177
|
-
] }) }) }) }) })
|
|
1178
|
-
}
|
|
1179
|
-
);
|
|
1180
|
-
return /* @__PURE__ */ b(U, { children: [
|
|
1181
|
-
/* @__PURE__ */ c(m, { sx: v.headlineSection, children: /* @__PURE__ */ b(m, { sx: v.headlineContent, children: [
|
|
1182
|
-
/* @__PURE__ */ b(m, { children: [
|
|
1183
|
-
/* @__PURE__ */ b(
|
|
1184
|
-
m,
|
|
1185
|
-
{
|
|
1186
|
-
sx: {
|
|
1187
|
-
display: "flex",
|
|
1188
|
-
alignItems: "center",
|
|
1189
|
-
justifyContent: a ? "center" : "left",
|
|
1190
|
-
gap: D["3xs"]
|
|
1191
|
-
},
|
|
1192
|
-
children: [
|
|
1193
|
-
/* @__PURE__ */ c(L, { level: "body-sm", sx: v.headlineText, children: e.headline }),
|
|
1194
|
-
/* @__PURE__ */ c(
|
|
1195
|
-
W,
|
|
1196
|
-
{
|
|
1197
|
-
rulesDisplay: e.rulesDisplay,
|
|
1198
|
-
rules: e.entity.rules || ""
|
|
1199
|
-
}
|
|
1200
|
-
)
|
|
1201
|
-
]
|
|
1202
|
-
}
|
|
1203
|
-
),
|
|
1204
|
-
/* @__PURE__ */ b(m, { sx: v.contentContainer, children: [
|
|
1205
|
-
/* @__PURE__ */ c(L, { level: "body-lg", sx: v.titleText, children: e.entity.title }),
|
|
1206
|
-
/* @__PURE__ */ c(L, { level: "body-md", sx: v.descriptionText, children: j(e.entity.description) })
|
|
1207
|
-
] })
|
|
1208
|
-
] }),
|
|
1209
|
-
/* @__PURE__ */ c(m, { sx: v.presentedByDesktop, children: e.renderPresentedBy(
|
|
1210
|
-
(r == null ? void 0 : r.contentColor) || t.colorSchemes.dark.textColor
|
|
1211
|
-
) })
|
|
1212
|
-
] }) }),
|
|
1213
|
-
/* @__PURE__ */ b(m, { sx: v.questionArea, children: [
|
|
1214
|
-
/* @__PURE__ */ c(
|
|
1215
|
-
xe,
|
|
1216
|
-
{
|
|
1217
|
-
variant: e.alertVariant || "error",
|
|
1218
|
-
title: A,
|
|
1219
|
-
message: P
|
|
1220
|
-
}
|
|
1221
|
-
),
|
|
1222
|
-
w(),
|
|
1223
|
-
/* @__PURE__ */ c(m, { sx: v.presentedByMobile, children: e.renderPresentedBy((r == null ? void 0 : r.contentColor) || O) })
|
|
1224
|
-
] })
|
|
1225
|
-
] });
|
|
1226
|
-
}, ze = (e) => {
|
|
1227
|
-
var t;
|
|
1228
|
-
return {
|
|
1229
|
-
// Main container with background overlay
|
|
1230
|
-
mainContainer: {
|
|
1231
|
-
display: "flex",
|
|
1232
|
-
flexDirection: "column",
|
|
1233
|
-
gap: "40px",
|
|
1234
|
-
p: e.spacingScale.xl,
|
|
1235
|
-
boxShadow: "md",
|
|
1236
|
-
border: (t = e.brandingColors) != null && t.borderColor ? `${e.borderSize} solid ${e.brandingColors.borderColor}` : "none",
|
|
1237
|
-
overflow: "hidden",
|
|
1238
|
-
backgroundImage: e.backgroundImage,
|
|
1239
|
-
backgroundSize: "cover",
|
|
1240
|
-
backgroundPosition: "center",
|
|
1241
|
-
position: "relative",
|
|
1242
|
-
borderRadius: e.borderRadius.md,
|
|
1243
|
-
"&::before": {
|
|
1244
|
-
content: '""',
|
|
1245
|
-
position: "absolute",
|
|
1246
|
-
background: e.imageBackgroundGradient,
|
|
1247
|
-
top: 0,
|
|
1248
|
-
left: 0,
|
|
1249
|
-
right: 0,
|
|
1250
|
-
bottom: 0,
|
|
1251
|
-
borderRadius: "inherit",
|
|
1252
|
-
zIndex: 0
|
|
1253
|
-
}
|
|
1254
|
-
},
|
|
1255
|
-
// Headline section wrapper
|
|
1256
|
-
headlineSection: {
|
|
1257
|
-
display: "flex",
|
|
1258
|
-
justifyContent: "space-between",
|
|
1259
|
-
flex: "1 0 0",
|
|
1260
|
-
alignSelf: "stretch"
|
|
1261
|
-
},
|
|
1262
|
-
// Headline content container
|
|
1263
|
-
headlineContent: {
|
|
1264
|
-
display: "flex",
|
|
1265
|
-
flexDirection: "column",
|
|
1266
|
-
alignItems: "flex-start",
|
|
1267
|
-
flex: "1 0 0",
|
|
1268
|
-
gap: "16px"
|
|
1269
|
-
},
|
|
1270
|
-
// Headline content with z-index
|
|
1271
|
-
headlineContentInner: {
|
|
1272
|
-
zIndex: 10
|
|
1273
|
-
},
|
|
1274
|
-
// Headline typography
|
|
1275
|
-
headlineText: {
|
|
1276
|
-
fontWeight: 500,
|
|
1277
|
-
lineHeight: "166%",
|
|
1278
|
-
letterSpacing: "1px",
|
|
1279
|
-
textAlign: e.isMobile ? "center" : "left",
|
|
1280
|
-
color: e.secondaryColor,
|
|
1281
|
-
opacity: "70%",
|
|
1282
|
-
textTransform: "uppercase",
|
|
1283
|
-
fontFamily: e.fontFamilySecondary,
|
|
1284
|
-
fontSize: "0.75em"
|
|
1285
|
-
},
|
|
1286
|
-
// Content container
|
|
1287
|
-
contentContainer: {
|
|
1288
|
-
display: "flex",
|
|
1289
|
-
flexDirection: "column",
|
|
1290
|
-
gap: e.spacingScale["3xs"]
|
|
1291
|
-
},
|
|
1292
|
-
// Title typography
|
|
1293
|
-
titleText: {
|
|
1294
|
-
fontWeight: 700,
|
|
1295
|
-
lineHeight: "133%",
|
|
1296
|
-
letterSpacing: "0px",
|
|
1297
|
-
textAlign: e.isMobile ? "center" : "left",
|
|
1298
|
-
fontSize: "1.5em",
|
|
1299
|
-
color: e.darkTextColor,
|
|
1300
|
-
fontFamily: e.fontFamilyPrimary
|
|
1301
|
-
},
|
|
1302
|
-
// Description typography
|
|
1303
|
-
descriptionText: {
|
|
1304
|
-
fontWeight: 400,
|
|
1305
|
-
lineHeight: "140%",
|
|
1306
|
-
letterSpacing: "0.15px",
|
|
1307
|
-
fontSize: "1.25em",
|
|
1308
|
-
textAlign: e.isMobile ? "center" : "left",
|
|
1309
|
-
color: e.secondaryColor,
|
|
1310
|
-
opacity: "70%",
|
|
1311
|
-
fontFamily: e.fontFamilyPrimary
|
|
1312
|
-
},
|
|
1313
|
-
// Bottom section container
|
|
1314
|
-
bottomSection: {
|
|
1315
|
-
display: "flex",
|
|
1316
|
-
flexDirection: "column",
|
|
1317
|
-
gap: "24px",
|
|
1318
|
-
zIndex: 1
|
|
1319
|
-
},
|
|
1320
|
-
// Footer container
|
|
1321
|
-
footerContainer: {
|
|
1322
|
-
display: "flex",
|
|
1323
|
-
alignItems: "center",
|
|
1324
|
-
justifyContent: "space-between",
|
|
1325
|
-
flexDirection: e.isMobile ? "column-reverse" : "row",
|
|
1326
|
-
gap: e.spacingScale.md
|
|
1327
|
-
},
|
|
1328
|
-
ctaSection: {
|
|
1329
|
-
borderRadius: e.borderRadius.md,
|
|
1330
|
-
py: e.spacingScale.md,
|
|
1331
|
-
display: "flex",
|
|
1332
|
-
flexDirection: "column",
|
|
1333
|
-
alignItems: "center",
|
|
1334
|
-
alignSelf: "stretch",
|
|
1335
|
-
gap: e.spacingScale.md,
|
|
1336
|
-
backdropFilter: "blur(4px)",
|
|
1337
|
-
position: "relative",
|
|
1338
|
-
"&::before": {
|
|
1339
|
-
content: '""',
|
|
1340
|
-
position: "absolute",
|
|
1341
|
-
top: 0,
|
|
1342
|
-
left: 0,
|
|
1343
|
-
right: 0,
|
|
1344
|
-
bottom: 0,
|
|
1345
|
-
backgroundColor: e.contentBgColor,
|
|
1346
|
-
opacity: 0.25,
|
|
1347
|
-
borderRadius: "inherit",
|
|
1348
|
-
zIndex: 0,
|
|
1349
|
-
backdropFilter: "blur(4px)"
|
|
1350
|
-
},
|
|
1351
|
-
"& > *": {
|
|
1352
|
-
position: "relative",
|
|
1353
|
-
zIndex: 1
|
|
1354
|
-
}
|
|
1355
|
-
},
|
|
1356
|
-
// Buttons container
|
|
1357
|
-
buttonsContainer: {
|
|
1358
|
-
display: "flex",
|
|
1359
|
-
flexDirection: "column",
|
|
1360
|
-
gap: e.spacingScale.md
|
|
1361
|
-
},
|
|
1362
|
-
// Try again button
|
|
1363
|
-
tryAgainButton: {
|
|
1364
|
-
display: "flex",
|
|
1365
|
-
minHeight: "48px",
|
|
1366
|
-
py: "12px",
|
|
1367
|
-
pr: "24px",
|
|
1368
|
-
pl: "16px",
|
|
1369
|
-
flexDirection: "column",
|
|
1370
|
-
justifyContent: "center",
|
|
1371
|
-
alignItems: "center",
|
|
1372
|
-
gap: "8px",
|
|
1373
|
-
borderRadius: e.borderRadius.xl,
|
|
1374
|
-
bgcolor: e.onSurfaceColor,
|
|
1375
|
-
"&:hover": {
|
|
1376
|
-
bgcolor: e.surfaceVariantColor
|
|
1377
|
-
},
|
|
1378
|
-
fontSize: "0.9375em"
|
|
1379
|
-
},
|
|
1380
|
-
// Try again button content
|
|
1381
|
-
tryAgainButtonContent: {
|
|
1382
|
-
display: "flex",
|
|
1383
|
-
justifyContent: "center",
|
|
1384
|
-
alignItems: "center",
|
|
1385
|
-
gap: "8px",
|
|
1386
|
-
alignSelf: "stretch"
|
|
1387
|
-
},
|
|
1388
|
-
// Try again icon
|
|
1389
|
-
tryAgainIcon: {
|
|
1390
|
-
display: "flex",
|
|
1391
|
-
width: "24px",
|
|
1392
|
-
height: "24px",
|
|
1393
|
-
justifyContent: "center",
|
|
1394
|
-
alignItems: "center",
|
|
1395
|
-
color: e.textPrimary
|
|
1396
|
-
},
|
|
1397
|
-
// Try again text
|
|
1398
|
-
tryAgainText: {
|
|
1399
|
-
color: e.textPrimary,
|
|
1400
|
-
textAlign: "center",
|
|
1401
|
-
fontFamily: e.fontFamilyPrimary,
|
|
1402
|
-
fontSize: "0.9375em",
|
|
1403
|
-
fontStyle: "normal",
|
|
1404
|
-
fontWeight: 500,
|
|
1405
|
-
lineHeight: "24px",
|
|
1406
|
-
letterSpacing: "0.46px",
|
|
1407
|
-
textTransform: "uppercase"
|
|
1408
|
-
}
|
|
1409
|
-
};
|
|
1410
|
-
}, ti = (e) => {
|
|
1411
|
-
const t = ne(), a = ae(), r = ie(), { t: l } = le(), f = oe(
|
|
1412
|
-
$.OVERLAY
|
|
1413
|
-
), { brandingImage: _, brandingColors: s, brandingLogo: E } = Me(e.entity.branding || null), o = _ || _e(
|
|
1414
|
-
{
|
|
1415
|
-
images: e.entity.images || null,
|
|
1416
|
-
imagePlaceholder: e.defaultImagePlaceholderUrl || ""
|
|
1417
|
-
},
|
|
1418
|
-
$.OVERLAY
|
|
1419
|
-
), u = ke(o), g = (s == null ? void 0 : s.contentColor) || a.colorSchemes.dark.textColor, S = a.customFontFamily.dark.primary, y = a.customFontFamily.dark.secondary, T = a.customRadius.dark, O = a.border.dark.size, D = (s == null ? void 0 : s.backgroundColor) || a.colorSchemes.dark.surfaceVariant, C = a.colorSchemes.dark.onSurface, A = a.colorSchemes.dark.surfaceVariant, P = a.colorSchemes.dark.textPrimary, v = e.customAlertTitle ?? (e.isApiError ? l("common.error.title") : l("common.authentication.accessRequired")), w = e.customAlertMessage ?? (e.isApiError ? e.apiErrorMessage || l("common.error.message") : l("common.authentication.invalidOrMissingAuth")), n = ze({
|
|
1420
|
-
spacingScale: t,
|
|
1421
|
-
brandingColors: s,
|
|
1422
|
-
secondaryColor: g,
|
|
1423
|
-
fontFamilyPrimary: S,
|
|
1424
|
-
fontFamilySecondary: y,
|
|
1425
|
-
borderRadius: T,
|
|
1426
|
-
borderSize: O,
|
|
1427
|
-
darkTextColor: a.colorSchemes.dark.textColor,
|
|
1428
|
-
backgroundImage: u,
|
|
1429
|
-
imageBackgroundGradient: f,
|
|
1430
|
-
contentBgColor: D,
|
|
1431
|
-
onSurfaceColor: C,
|
|
1432
|
-
surfaceVariantColor: A,
|
|
1433
|
-
textPrimary: P,
|
|
1434
|
-
isMobile: r
|
|
1435
|
-
}), h = () => !e.isApiError || !e.toggleTryAgain ? /* @__PURE__ */ c(U, {}) : /* @__PURE__ */ c(m, { sx: n.ctaSection, children: /* @__PURE__ */ c(m, { sx: n.buttonsContainer, children: /* @__PURE__ */ c(te, { sx: n.tryAgainButton, onClick: e.toggleTryAgain, children: /* @__PURE__ */ b(m, { sx: n.tryAgainButtonContent, children: [
|
|
1436
|
-
/* @__PURE__ */ c(Ee, { sx: n.tryAgainIcon }),
|
|
1437
|
-
/* @__PURE__ */ c(L, { sx: n.tryAgainText, children: e.tryAgainButtonText })
|
|
1438
|
-
] }) }) }) });
|
|
1439
|
-
return /* @__PURE__ */ b(m, { sx: n.mainContainer, children: [
|
|
1440
|
-
/* @__PURE__ */ c(m, { children: /* @__PURE__ */ c(m, { sx: n.headlineSection, children: /* @__PURE__ */ c(m, { sx: n.headlineContent, children: /* @__PURE__ */ b(m, { sx: n.headlineContentInner, children: [
|
|
1441
|
-
/* @__PURE__ */ b(
|
|
1442
|
-
m,
|
|
1443
|
-
{
|
|
1444
|
-
sx: {
|
|
1445
|
-
display: "flex",
|
|
1446
|
-
alignItems: "center",
|
|
1447
|
-
justifyContent: r ? "center" : "left",
|
|
1448
|
-
gap: t["3xs"]
|
|
1449
|
-
},
|
|
1450
|
-
children: [
|
|
1451
|
-
/* @__PURE__ */ c(L, { level: "body-sm", sx: n.headlineText, children: e.headline }),
|
|
1452
|
-
/* @__PURE__ */ c(
|
|
1453
|
-
W,
|
|
1454
|
-
{
|
|
1455
|
-
rulesDisplay: e.rulesDisplay,
|
|
1456
|
-
isOverlayVariant: !0,
|
|
1457
|
-
rules: e.entity.rules || ""
|
|
1458
|
-
}
|
|
1459
|
-
)
|
|
1460
|
-
]
|
|
1461
|
-
}
|
|
1462
|
-
),
|
|
1463
|
-
/* @__PURE__ */ b(m, { sx: n.contentContainer, children: [
|
|
1464
|
-
/* @__PURE__ */ c(L, { level: "h4", sx: n.titleText, children: e.entity.title }),
|
|
1465
|
-
/* @__PURE__ */ c(L, { level: "body-lg", sx: n.descriptionText, children: j(e.entity.description) })
|
|
1466
|
-
] })
|
|
1467
|
-
] }) }) }) }),
|
|
1468
|
-
/* @__PURE__ */ b(m, { sx: n.bottomSection, children: [
|
|
1469
|
-
/* @__PURE__ */ c(
|
|
1470
|
-
xe,
|
|
1471
|
-
{
|
|
1472
|
-
variant: e.alertVariant || "error",
|
|
1473
|
-
title: v,
|
|
1474
|
-
message: w
|
|
1475
|
-
}
|
|
1476
|
-
),
|
|
1477
|
-
h(),
|
|
1478
|
-
E ? /* @__PURE__ */ c(m, { sx: n.footerContainer, children: e.renderPresentedBy(a.colorSchemes.dark.textColor) }) : /* @__PURE__ */ c(U, {})
|
|
1479
|
-
] })
|
|
1480
|
-
] });
|
|
1481
|
-
}, ii = ({
|
|
1482
|
-
entityId: e,
|
|
1483
|
-
sdk: t,
|
|
1484
|
-
children: a
|
|
1485
|
-
}) => {
|
|
1486
|
-
const { infoPage: r } = Ve(e, "chance-game", t);
|
|
1487
|
-
return !r || r.id === "not-found" ? null : /* @__PURE__ */ c(U, { children: a(r) });
|
|
1488
|
-
};
|
|
1489
|
-
var Ke = Object.create, ce = Object.defineProperty, Xe = Object.getOwnPropertyDescriptor, qe = Object.getOwnPropertyNames, $e = Object.getPrototypeOf, Je = Object.prototype.hasOwnProperty, Qe = (e, t, a) => t in e ? ce(e, t, { enumerable: !0, configurable: !0, writable: !0, value: a }) : e[t] = a, Ze = (e, t) => () => (e && (t = e(e = 0)), t), de = (e, t) => () => (t || e((t = { exports: {} }).exports, t), t.exports), et = (e, t) => {
|
|
1490
|
-
for (var a in t) ce(e, a, { get: t[a], enumerable: !0 });
|
|
1491
|
-
}, tt = (e, t, a, r) => {
|
|
1492
|
-
if (t && typeof t == "object" || typeof t == "function") for (let l of qe(t)) !Je.call(e, l) && l !== a && ce(e, l, { get: () => t[l], enumerable: !(r = Xe(t, l)) || r.enumerable });
|
|
1493
|
-
return e;
|
|
1494
|
-
}, it = (e, t, a) => (a = e != null ? Ke($e(e)) : {}, tt(!e || !e.__esModule ? ce(a, "default", { value: e, enumerable: !0 }) : a, e)), B = (e, t, a) => (Qe(e, typeof t != "symbol" ? t + "" : t, a), a), Oe = {};
|
|
1495
|
-
et(Oe, { default: () => Ae });
|
|
1496
|
-
var Se, Ae, at = Ze(() => {
|
|
1497
|
-
Se = { getItem: async () => null, setItem: async () => null, removeItem: async () => null, clear: async () => null, getAllKeys: async () => [], multiGet: async () => [], multiSet: async () => null, multiRemove: async () => null, mergeItem: async () => null, multiMerge: async () => null }, Ae = Se;
|
|
1498
|
-
}), nt = de((e, t) => {
|
|
1499
|
-
var a = function() {
|
|
1500
|
-
function r(y, T) {
|
|
1501
|
-
return T != null && y instanceof T;
|
|
1502
|
-
}
|
|
1503
|
-
var l;
|
|
1504
|
-
try {
|
|
1505
|
-
l = Map;
|
|
1506
|
-
} catch {
|
|
1507
|
-
l = function() {
|
|
1508
|
-
};
|
|
1509
|
-
}
|
|
1510
|
-
var f;
|
|
1511
|
-
try {
|
|
1512
|
-
f = Set;
|
|
1513
|
-
} catch {
|
|
1514
|
-
f = function() {
|
|
1515
|
-
};
|
|
1516
|
-
}
|
|
1517
|
-
var _;
|
|
1518
|
-
try {
|
|
1519
|
-
_ = Promise;
|
|
1520
|
-
} catch {
|
|
1521
|
-
_ = function() {
|
|
1522
|
-
};
|
|
1523
|
-
}
|
|
1524
|
-
function s(y, T, O, D, C) {
|
|
1525
|
-
typeof T == "object" && (O = T.depth, D = T.prototype, C = T.includeNonEnumerable, T = T.circular);
|
|
1526
|
-
var A = [], P = [], v = typeof Buffer < "u";
|
|
1527
|
-
typeof T > "u" && (T = !0), typeof O > "u" && (O = 1 / 0);
|
|
1528
|
-
function w(n, h) {
|
|
1529
|
-
if (n === null) return null;
|
|
1530
|
-
if (h === 0) return n;
|
|
1531
|
-
var d, x;
|
|
1532
|
-
if (typeof n != "object") return n;
|
|
1533
|
-
if (r(n, l)) d = new l();
|
|
1534
|
-
else if (r(n, f)) d = new f();
|
|
1535
|
-
else if (r(n, _)) d = new _(function(z, K) {
|
|
1536
|
-
n.then(function(X) {
|
|
1537
|
-
z(w(X, h - 1));
|
|
1538
|
-
}, function(X) {
|
|
1539
|
-
K(w(X, h - 1));
|
|
1540
|
-
});
|
|
1541
|
-
});
|
|
1542
|
-
else if (s.__isArray(n)) d = [];
|
|
1543
|
-
else if (s.__isRegExp(n)) d = new RegExp(n.source, S(n)), n.lastIndex && (d.lastIndex = n.lastIndex);
|
|
1544
|
-
else if (s.__isDate(n)) d = new Date(n.getTime());
|
|
1545
|
-
else {
|
|
1546
|
-
if (v && Buffer.isBuffer(n)) return Buffer.allocUnsafe ? d = Buffer.allocUnsafe(n.length) : d = new Buffer(n.length), n.copy(d), d;
|
|
1547
|
-
r(n, Error) ? d = Object.create(n) : typeof D > "u" ? (x = Object.getPrototypeOf(n), d = Object.create(x)) : (d = Object.create(D), x = D);
|
|
1548
|
-
}
|
|
1549
|
-
if (T) {
|
|
1550
|
-
var I = A.indexOf(n);
|
|
1551
|
-
if (I != -1) return P[I];
|
|
1552
|
-
A.push(n), P.push(d);
|
|
1553
|
-
}
|
|
1554
|
-
r(n, l) && n.forEach(function(z, K) {
|
|
1555
|
-
var X = w(K, h - 1), re = w(z, h - 1);
|
|
1556
|
-
d.set(X, re);
|
|
1557
|
-
}), r(n, f) && n.forEach(function(z) {
|
|
1558
|
-
var K = w(z, h - 1);
|
|
1559
|
-
d.add(K);
|
|
1560
|
-
});
|
|
1561
|
-
for (var R in n) {
|
|
1562
|
-
var N;
|
|
1563
|
-
x && (N = Object.getOwnPropertyDescriptor(x, R)), !(N && N.set == null) && (d[R] = w(n[R], h - 1));
|
|
1564
|
-
}
|
|
1565
|
-
if (Object.getOwnPropertySymbols) for (var M = Object.getOwnPropertySymbols(n), R = 0; R < M.length; R++) {
|
|
1566
|
-
var G = M[R], F = Object.getOwnPropertyDescriptor(n, G);
|
|
1567
|
-
F && !F.enumerable && !C || (d[G] = w(n[G], h - 1), F.enumerable || Object.defineProperty(d, G, { enumerable: !1 }));
|
|
1568
|
-
}
|
|
1569
|
-
if (C) for (var Y = Object.getOwnPropertyNames(n), R = 0; R < Y.length; R++) {
|
|
1570
|
-
var H = Y[R], F = Object.getOwnPropertyDescriptor(n, H);
|
|
1571
|
-
F && F.enumerable || (d[H] = w(n[H], h - 1), Object.defineProperty(d, H, { enumerable: !1 }));
|
|
1572
|
-
}
|
|
1573
|
-
return d;
|
|
1574
|
-
}
|
|
1575
|
-
return w(y, O);
|
|
1576
|
-
}
|
|
1577
|
-
s.clonePrototype = function(y) {
|
|
1578
|
-
if (y === null) return null;
|
|
1579
|
-
var T = function() {
|
|
1580
|
-
};
|
|
1581
|
-
return T.prototype = y, new T();
|
|
1582
|
-
};
|
|
1583
|
-
function E(y) {
|
|
1584
|
-
return Object.prototype.toString.call(y);
|
|
1585
|
-
}
|
|
1586
|
-
s.__objToStr = E;
|
|
1587
|
-
function o(y) {
|
|
1588
|
-
return typeof y == "object" && E(y) === "[object Date]";
|
|
1589
|
-
}
|
|
1590
|
-
s.__isDate = o;
|
|
1591
|
-
function u(y) {
|
|
1592
|
-
return typeof y == "object" && E(y) === "[object Array]";
|
|
1593
|
-
}
|
|
1594
|
-
s.__isArray = u;
|
|
1595
|
-
function g(y) {
|
|
1596
|
-
return typeof y == "object" && E(y) === "[object RegExp]";
|
|
1597
|
-
}
|
|
1598
|
-
s.__isRegExp = g;
|
|
1599
|
-
function S(y) {
|
|
1600
|
-
var T = "";
|
|
1601
|
-
return y.global && (T += "g"), y.ignoreCase && (T += "i"), y.multiline && (T += "m"), T;
|
|
1602
|
-
}
|
|
1603
|
-
return s.__getRegExpFlags = S, s;
|
|
1604
|
-
}();
|
|
1605
|
-
typeof t == "object" && t.exports && (t.exports = a);
|
|
1606
|
-
}), ot = de((e, t) => {
|
|
1607
|
-
var a = typeof Reflect == "object" ? Reflect : null, r = a && typeof a.apply == "function" ? a.apply : function(n, h, d) {
|
|
1608
|
-
return Function.prototype.apply.call(n, h, d);
|
|
1609
|
-
}, l;
|
|
1610
|
-
a && typeof a.ownKeys == "function" ? l = a.ownKeys : Object.getOwnPropertySymbols ? l = function(n) {
|
|
1611
|
-
return Object.getOwnPropertyNames(n).concat(Object.getOwnPropertySymbols(n));
|
|
1612
|
-
} : l = function(n) {
|
|
1613
|
-
return Object.getOwnPropertyNames(n);
|
|
1614
|
-
};
|
|
1615
|
-
function f(n) {
|
|
1616
|
-
console && console.warn && console.warn(n);
|
|
1617
|
-
}
|
|
1618
|
-
var _ = Number.isNaN || function(n) {
|
|
1619
|
-
return n !== n;
|
|
1620
|
-
};
|
|
1621
|
-
function s() {
|
|
1622
|
-
s.init.call(this);
|
|
1623
|
-
}
|
|
1624
|
-
t.exports = s, t.exports.once = P, s.EventEmitter = s, s.prototype._events = void 0, s.prototype._eventsCount = 0, s.prototype._maxListeners = void 0;
|
|
1625
|
-
var E = 10;
|
|
1626
|
-
function o(n) {
|
|
1627
|
-
if (typeof n != "function") throw new TypeError('The "listener" argument must be of type Function. Received type ' + typeof n);
|
|
1628
|
-
}
|
|
1629
|
-
Object.defineProperty(s, "defaultMaxListeners", { enumerable: !0, get: function() {
|
|
1630
|
-
return E;
|
|
1631
|
-
}, set: function(n) {
|
|
1632
|
-
if (typeof n != "number" || n < 0 || _(n)) throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received ' + n + ".");
|
|
1633
|
-
E = n;
|
|
1634
|
-
} }), s.init = function() {
|
|
1635
|
-
(this._events === void 0 || this._events === Object.getPrototypeOf(this)._events) && (this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0), this._maxListeners = this._maxListeners || void 0;
|
|
1636
|
-
}, s.prototype.setMaxListeners = function(n) {
|
|
1637
|
-
if (typeof n != "number" || n < 0 || _(n)) throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received ' + n + ".");
|
|
1638
|
-
return this._maxListeners = n, this;
|
|
1639
|
-
};
|
|
1640
|
-
function u(n) {
|
|
1641
|
-
return n._maxListeners === void 0 ? s.defaultMaxListeners : n._maxListeners;
|
|
1642
|
-
}
|
|
1643
|
-
s.prototype.getMaxListeners = function() {
|
|
1644
|
-
return u(this);
|
|
1645
|
-
}, s.prototype.emit = function(n) {
|
|
1646
|
-
for (var h = [], d = 1; d < arguments.length; d++) h.push(arguments[d]);
|
|
1647
|
-
var x = n === "error", I = this._events;
|
|
1648
|
-
if (I !== void 0) x = x && I.error === void 0;
|
|
1649
|
-
else if (!x) return !1;
|
|
1650
|
-
if (x) {
|
|
1651
|
-
var R;
|
|
1652
|
-
if (h.length > 0 && (R = h[0]), R instanceof Error) throw R;
|
|
1653
|
-
var N = new Error("Unhandled error." + (R ? " (" + R.message + ")" : ""));
|
|
1654
|
-
throw N.context = R, N;
|
|
1655
|
-
}
|
|
1656
|
-
var M = I[n];
|
|
1657
|
-
if (M === void 0) return !1;
|
|
1658
|
-
if (typeof M == "function") r(M, this, h);
|
|
1659
|
-
else for (var G = M.length, F = D(M, G), d = 0; d < G; ++d) r(F[d], this, h);
|
|
1660
|
-
return !0;
|
|
1661
|
-
};
|
|
1662
|
-
function g(n, h, d, x) {
|
|
1663
|
-
var I, R, N;
|
|
1664
|
-
if (o(d), R = n._events, R === void 0 ? (R = n._events = /* @__PURE__ */ Object.create(null), n._eventsCount = 0) : (R.newListener !== void 0 && (n.emit("newListener", h, d.listener ? d.listener : d), R = n._events), N = R[h]), N === void 0) N = R[h] = d, ++n._eventsCount;
|
|
1665
|
-
else if (typeof N == "function" ? N = R[h] = x ? [d, N] : [N, d] : x ? N.unshift(d) : N.push(d), I = u(n), I > 0 && N.length > I && !N.warned) {
|
|
1666
|
-
N.warned = !0;
|
|
1667
|
-
var M = new Error("Possible EventEmitter memory leak detected. " + N.length + " " + String(h) + " listeners added. Use emitter.setMaxListeners() to increase limit");
|
|
1668
|
-
M.name = "MaxListenersExceededWarning", M.emitter = n, M.type = h, M.count = N.length, f(M);
|
|
1669
|
-
}
|
|
1670
|
-
return n;
|
|
1671
|
-
}
|
|
1672
|
-
s.prototype.addListener = function(n, h) {
|
|
1673
|
-
return g(this, n, h, !1);
|
|
1674
|
-
}, s.prototype.on = s.prototype.addListener, s.prototype.prependListener = function(n, h) {
|
|
1675
|
-
return g(this, n, h, !0);
|
|
1676
|
-
};
|
|
1677
|
-
function S() {
|
|
1678
|
-
if (!this.fired) return this.target.removeListener(this.type, this.wrapFn), this.fired = !0, arguments.length === 0 ? this.listener.call(this.target) : this.listener.apply(this.target, arguments);
|
|
1679
|
-
}
|
|
1680
|
-
function y(n, h, d) {
|
|
1681
|
-
var x = { fired: !1, wrapFn: void 0, target: n, type: h, listener: d }, I = S.bind(x);
|
|
1682
|
-
return I.listener = d, x.wrapFn = I, I;
|
|
1683
|
-
}
|
|
1684
|
-
s.prototype.once = function(n, h) {
|
|
1685
|
-
return o(h), this.on(n, y(this, n, h)), this;
|
|
1686
|
-
}, s.prototype.prependOnceListener = function(n, h) {
|
|
1687
|
-
return o(h), this.prependListener(n, y(this, n, h)), this;
|
|
1688
|
-
}, s.prototype.removeListener = function(n, h) {
|
|
1689
|
-
var d, x, I, R, N;
|
|
1690
|
-
if (o(h), x = this._events, x === void 0) return this;
|
|
1691
|
-
if (d = x[n], d === void 0) return this;
|
|
1692
|
-
if (d === h || d.listener === h) --this._eventsCount === 0 ? this._events = /* @__PURE__ */ Object.create(null) : (delete x[n], x.removeListener && this.emit("removeListener", n, d.listener || h));
|
|
1693
|
-
else if (typeof d != "function") {
|
|
1694
|
-
for (I = -1, R = d.length - 1; R >= 0; R--) if (d[R] === h || d[R].listener === h) {
|
|
1695
|
-
N = d[R].listener, I = R;
|
|
1696
|
-
break;
|
|
1697
|
-
}
|
|
1698
|
-
if (I < 0) return this;
|
|
1699
|
-
I === 0 ? d.shift() : C(d, I), d.length === 1 && (x[n] = d[0]), x.removeListener !== void 0 && this.emit("removeListener", n, N || h);
|
|
1700
|
-
}
|
|
1701
|
-
return this;
|
|
1702
|
-
}, s.prototype.off = s.prototype.removeListener, s.prototype.removeAllListeners = function(n) {
|
|
1703
|
-
var h, d, x;
|
|
1704
|
-
if (d = this._events, d === void 0) return this;
|
|
1705
|
-
if (d.removeListener === void 0) return arguments.length === 0 ? (this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0) : d[n] !== void 0 && (--this._eventsCount === 0 ? this._events = /* @__PURE__ */ Object.create(null) : delete d[n]), this;
|
|
1706
|
-
if (arguments.length === 0) {
|
|
1707
|
-
var I = Object.keys(d), R;
|
|
1708
|
-
for (x = 0; x < I.length; ++x) R = I[x], R !== "removeListener" && this.removeAllListeners(R);
|
|
1709
|
-
return this.removeAllListeners("removeListener"), this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0, this;
|
|
1710
|
-
}
|
|
1711
|
-
if (h = d[n], typeof h == "function") this.removeListener(n, h);
|
|
1712
|
-
else if (h !== void 0) for (x = h.length - 1; x >= 0; x--) this.removeListener(n, h[x]);
|
|
1713
|
-
return this;
|
|
1714
|
-
};
|
|
1715
|
-
function T(n, h, d) {
|
|
1716
|
-
var x = n._events;
|
|
1717
|
-
if (x === void 0) return [];
|
|
1718
|
-
var I = x[h];
|
|
1719
|
-
return I === void 0 ? [] : typeof I == "function" ? d ? [I.listener || I] : [I] : d ? A(I) : D(I, I.length);
|
|
1720
|
-
}
|
|
1721
|
-
s.prototype.listeners = function(n) {
|
|
1722
|
-
return T(this, n, !0);
|
|
1723
|
-
}, s.prototype.rawListeners = function(n) {
|
|
1724
|
-
return T(this, n, !1);
|
|
1725
|
-
}, s.listenerCount = function(n, h) {
|
|
1726
|
-
return typeof n.listenerCount == "function" ? n.listenerCount(h) : O.call(n, h);
|
|
1727
|
-
}, s.prototype.listenerCount = O;
|
|
1728
|
-
function O(n) {
|
|
1729
|
-
var h = this._events;
|
|
1730
|
-
if (h !== void 0) {
|
|
1731
|
-
var d = h[n];
|
|
1732
|
-
if (typeof d == "function") return 1;
|
|
1733
|
-
if (d !== void 0) return d.length;
|
|
1734
|
-
}
|
|
1735
|
-
return 0;
|
|
1736
|
-
}
|
|
1737
|
-
s.prototype.eventNames = function() {
|
|
1738
|
-
return this._eventsCount > 0 ? l(this._events) : [];
|
|
1739
|
-
};
|
|
1740
|
-
function D(n, h) {
|
|
1741
|
-
for (var d = new Array(h), x = 0; x < h; ++x) d[x] = n[x];
|
|
1742
|
-
return d;
|
|
1743
|
-
}
|
|
1744
|
-
function C(n, h) {
|
|
1745
|
-
for (; h + 1 < n.length; h++) n[h] = n[h + 1];
|
|
1746
|
-
n.pop();
|
|
1747
|
-
}
|
|
1748
|
-
function A(n) {
|
|
1749
|
-
for (var h = new Array(n.length), d = 0; d < h.length; ++d) h[d] = n[d].listener || n[d];
|
|
1750
|
-
return h;
|
|
1751
|
-
}
|
|
1752
|
-
function P(n, h) {
|
|
1753
|
-
return new Promise(function(d, x) {
|
|
1754
|
-
function I(N) {
|
|
1755
|
-
n.removeListener(h, R), x(N);
|
|
1756
|
-
}
|
|
1757
|
-
function R() {
|
|
1758
|
-
typeof n.removeListener == "function" && n.removeListener("error", I), d([].slice.call(arguments));
|
|
1759
|
-
}
|
|
1760
|
-
w(n, h, R, { once: !0 }), h !== "error" && v(n, I, { once: !0 });
|
|
1761
|
-
});
|
|
1762
|
-
}
|
|
1763
|
-
function v(n, h, d) {
|
|
1764
|
-
typeof n.on == "function" && w(n, "error", h, d);
|
|
1765
|
-
}
|
|
1766
|
-
function w(n, h, d, x) {
|
|
1767
|
-
if (typeof n.on == "function") x.once ? n.once(h, d) : n.on(h, d);
|
|
1768
|
-
else if (typeof n.addEventListener == "function") n.addEventListener(h, function I(R) {
|
|
1769
|
-
x.once && n.removeEventListener(h, I), d(R);
|
|
1770
|
-
});
|
|
1771
|
-
else throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type ' + typeof n);
|
|
1772
|
-
}
|
|
1773
|
-
}), rt = de((e, t) => {
|
|
1774
|
-
(function() {
|
|
1775
|
-
var a, r, l = [].splice, f = function(s, E) {
|
|
1776
|
-
if (!(s instanceof E)) throw new Error("Bound instance method accessed before binding");
|
|
1777
|
-
}, _ = [].indexOf;
|
|
1778
|
-
r = nt(), a = ot().EventEmitter, t.exports = (function() {
|
|
1779
|
-
class s extends a {
|
|
1780
|
-
constructor(o = {}) {
|
|
1781
|
-
super(), this.get = this.get.bind(this), this.mget = this.mget.bind(this), this.set = this.set.bind(this), this.mset = this.mset.bind(this), this.del = this.del.bind(this), this.take = this.take.bind(this), this.ttl = this.ttl.bind(this), this.getTtl = this.getTtl.bind(this), this.keys = this.keys.bind(this), this.has = this.has.bind(this), this.getStats = this.getStats.bind(this), this.flushAll = this.flushAll.bind(this), this.flushStats = this.flushStats.bind(this), this.close = this.close.bind(this), this._checkData = this._checkData.bind(this), this._check = this._check.bind(this), this._isInvalidKey = this._isInvalidKey.bind(this), this._wrap = this._wrap.bind(this), this._getValLength = this._getValLength.bind(this), this._error = this._error.bind(this), this._initErrors = this._initErrors.bind(this), this.options = o, this._initErrors(), this.data = {}, this.options = Object.assign({ forceString: !1, objectValueSize: 80, promiseValueSize: 80, arrayValueSize: 40, stdTTL: 0, checkperiod: 600, useClones: !0, deleteOnExpire: !0, enableLegacyCallbacks: !1, maxKeys: -1 }, this.options), this.options.enableLegacyCallbacks && (console.warn("WARNING! node-cache legacy callback support will drop in v6.x"), ["get", "mget", "set", "del", "ttl", "getTtl", "keys", "has"].forEach((u) => {
|
|
1782
|
-
var g;
|
|
1783
|
-
g = this[u], this[u] = function(...S) {
|
|
1784
|
-
var y, T, O, D;
|
|
1785
|
-
if (O = S, [...S] = O, [y] = l.call(S, -1), typeof y == "function") try {
|
|
1786
|
-
D = g(...S), y(null, D);
|
|
1787
|
-
} catch (C) {
|
|
1788
|
-
T = C, y(T);
|
|
1789
|
-
}
|
|
1790
|
-
else return g(...S, y);
|
|
1791
|
-
};
|
|
1792
|
-
})), this.stats = { hits: 0, misses: 0, keys: 0, ksize: 0, vsize: 0 }, this.validKeyTypes = ["string", "number"], this._checkData();
|
|
1793
|
-
}
|
|
1794
|
-
get(o) {
|
|
1795
|
-
var u, g;
|
|
1796
|
-
if (f(this, s), (g = this._isInvalidKey(o)) != null) throw g;
|
|
1797
|
-
if (this.data[o] != null && this._check(o, this.data[o])) return this.stats.hits++, u = this._unwrap(this.data[o]), u;
|
|
1798
|
-
this.stats.misses++;
|
|
1799
|
-
}
|
|
1800
|
-
mget(o) {
|
|
1801
|
-
var u, g, S, y, T, O;
|
|
1802
|
-
if (f(this, s), !Array.isArray(o)) throw u = this._error("EKEYSTYPE"), u;
|
|
1803
|
-
for (O = {}, S = 0, T = o.length; S < T; S++) {
|
|
1804
|
-
if (y = o[S], (g = this._isInvalidKey(y)) != null) throw g;
|
|
1805
|
-
this.data[y] != null && this._check(y, this.data[y]) ? (this.stats.hits++, O[y] = this._unwrap(this.data[y])) : this.stats.misses++;
|
|
1806
|
-
}
|
|
1807
|
-
return O;
|
|
1808
|
-
}
|
|
1809
|
-
set(o, u, g) {
|
|
1810
|
-
var S, y, T;
|
|
1811
|
-
if (f(this, s), this.options.maxKeys > -1 && this.stats.keys >= this.options.maxKeys) throw S = this._error("ECACHEFULL"), S;
|
|
1812
|
-
if (this.options.forceString && !1 === "string" && (u = JSON.stringify(u)), g == null && (g = this.options.stdTTL), (y = this._isInvalidKey(o)) != null) throw y;
|
|
1813
|
-
return T = !1, this.data[o] && (T = !0, this.stats.vsize -= this._getValLength(this._unwrap(this.data[o], !1))), this.data[o] = this._wrap(u, g), this.stats.vsize += this._getValLength(u), T || (this.stats.ksize += this._getKeyLength(o), this.stats.keys++), this.emit("set", o, u), !0;
|
|
1814
|
-
}
|
|
1815
|
-
mset(o) {
|
|
1816
|
-
var u, g, S, y, T, O, D, C, A, P;
|
|
1817
|
-
if (f(this, s), this.options.maxKeys > -1 && this.stats.keys + o.length >= this.options.maxKeys) throw u = this._error("ECACHEFULL"), u;
|
|
1818
|
-
for (S = 0, D = o.length; S < D; S++) {
|
|
1819
|
-
if (O = o[S], { key: T, val: P, ttl: A } = O, A && typeof A != "number") throw u = this._error("ETTLTYPE"), u;
|
|
1820
|
-
if ((g = this._isInvalidKey(T)) != null) throw g;
|
|
1821
|
-
}
|
|
1822
|
-
for (y = 0, C = o.length; y < C; y++) O = o[y], { key: T, val: P, ttl: A } = O, this.set(T, P, A);
|
|
1823
|
-
return !0;
|
|
1824
|
-
}
|
|
1825
|
-
del(o) {
|
|
1826
|
-
var u, g, S, y, T, O;
|
|
1827
|
-
for (f(this, s), Array.isArray(o) || (o = [o]), u = 0, S = 0, T = o.length; S < T; S++) {
|
|
1828
|
-
if (y = o[S], (g = this._isInvalidKey(y)) != null) throw g;
|
|
1829
|
-
this.data[y] != null && (this.stats.vsize -= this._getValLength(this._unwrap(this.data[y], !1)), this.stats.ksize -= this._getKeyLength(y), this.stats.keys--, u++, O = this.data[y], delete this.data[y], this.emit("del", y, O.v));
|
|
1830
|
-
}
|
|
1831
|
-
return u;
|
|
1832
|
-
}
|
|
1833
|
-
take(o) {
|
|
1834
|
-
var u;
|
|
1835
|
-
return f(this, s), u = this.get(o), u != null && this.del(o), u;
|
|
1836
|
-
}
|
|
1837
|
-
ttl(o, u) {
|
|
1838
|
-
var g;
|
|
1839
|
-
if (f(this, s), u || (u = this.options.stdTTL), !o) return !1;
|
|
1840
|
-
if ((g = this._isInvalidKey(o)) != null) throw g;
|
|
1841
|
-
return this.data[o] != null && this._check(o, this.data[o]) ? (u >= 0 ? this.data[o] = this._wrap(this.data[o].v, u, !1) : this.del(o), !0) : !1;
|
|
1842
|
-
}
|
|
1843
|
-
getTtl(o) {
|
|
1844
|
-
var u, g;
|
|
1845
|
-
if (f(this, s), !!o) {
|
|
1846
|
-
if ((g = this._isInvalidKey(o)) != null) throw g;
|
|
1847
|
-
if (this.data[o] != null && this._check(o, this.data[o])) return u = this.data[o].t, u;
|
|
1848
|
-
}
|
|
1849
|
-
}
|
|
1850
|
-
keys() {
|
|
1851
|
-
var o;
|
|
1852
|
-
return f(this, s), o = Object.keys(this.data), o;
|
|
1853
|
-
}
|
|
1854
|
-
has(o) {
|
|
1855
|
-
var u;
|
|
1856
|
-
return f(this, s), u = this.data[o] != null && this._check(o, this.data[o]), u;
|
|
1857
|
-
}
|
|
1858
|
-
getStats() {
|
|
1859
|
-
return f(this, s), this.stats;
|
|
1860
|
-
}
|
|
1861
|
-
flushAll(o = !0) {
|
|
1862
|
-
f(this, s), this.data = {}, this.stats = { hits: 0, misses: 0, keys: 0, ksize: 0, vsize: 0 }, this._killCheckPeriod(), this._checkData(o), this.emit("flush");
|
|
1863
|
-
}
|
|
1864
|
-
flushStats() {
|
|
1865
|
-
f(this, s), this.stats = { hits: 0, misses: 0, keys: 0, ksize: 0, vsize: 0 }, this.emit("flush_stats");
|
|
1866
|
-
}
|
|
1867
|
-
close() {
|
|
1868
|
-
f(this, s), this._killCheckPeriod();
|
|
1869
|
-
}
|
|
1870
|
-
_checkData(o = !0) {
|
|
1871
|
-
var u, g, S;
|
|
1872
|
-
f(this, s), g = this.data;
|
|
1873
|
-
for (u in g) S = g[u], this._check(u, S);
|
|
1874
|
-
o && this.options.checkperiod > 0 && (this.checkTimeout = setTimeout(this._checkData, this.options.checkperiod * 1e3, o), this.checkTimeout != null && this.checkTimeout.unref != null && this.checkTimeout.unref());
|
|
1875
|
-
}
|
|
1876
|
-
_killCheckPeriod() {
|
|
1877
|
-
if (this.checkTimeout != null) return clearTimeout(this.checkTimeout);
|
|
1878
|
-
}
|
|
1879
|
-
_check(o, u) {
|
|
1880
|
-
var g;
|
|
1881
|
-
return f(this, s), g = !0, u.t !== 0 && u.t < Date.now() && (this.options.deleteOnExpire && (g = !1, this.del(o)), this.emit("expired", o, this._unwrap(u))), g;
|
|
1882
|
-
}
|
|
1883
|
-
_isInvalidKey(o) {
|
|
1884
|
-
var u;
|
|
1885
|
-
if (f(this, s), u = typeof o, _.call(this.validKeyTypes, u) < 0) return this._error("EKEYTYPE", { type: typeof o });
|
|
1886
|
-
}
|
|
1887
|
-
_wrap(o, u, g = !0) {
|
|
1888
|
-
var S, y, T;
|
|
1889
|
-
return f(this, s), this.options.useClones || (g = !1), y = Date.now(), S = 0, T = 1e3, u === 0 ? S = 0 : u ? S = y + u * T : this.options.stdTTL === 0 ? S = this.options.stdTTL : S = y + this.options.stdTTL * T, { t: S, v: g ? r(o) : o };
|
|
1890
|
-
}
|
|
1891
|
-
_unwrap(o, u = !0) {
|
|
1892
|
-
return this.options.useClones || (u = !1), o.v != null ? u ? r(o.v) : o.v : null;
|
|
1893
|
-
}
|
|
1894
|
-
_getKeyLength(o) {
|
|
1895
|
-
return o.toString().length;
|
|
1896
|
-
}
|
|
1897
|
-
_getValLength(o) {
|
|
1898
|
-
return f(this, s), typeof o == "string" ? o.length : this.options.forceString ? JSON.stringify(o).length : Array.isArray(o) ? this.options.arrayValueSize * o.length : typeof o == "number" ? 8 : typeof (o == null ? void 0 : o.then) == "function" ? this.options.promiseValueSize : typeof Buffer < "u" && Buffer !== null && Buffer.isBuffer(o) ? o.length : o != null && typeof o == "object" ? this.options.objectValueSize * Object.keys(o).length : typeof o == "boolean" ? 8 : 0;
|
|
1899
|
-
}
|
|
1900
|
-
_error(o, u = {}) {
|
|
1901
|
-
var g;
|
|
1902
|
-
return f(this, s), g = new Error(), g.name = o, g.errorcode = o, g.message = this.ERRORS[o] != null ? this.ERRORS[o](u) : "-", g.data = u, g;
|
|
1903
|
-
}
|
|
1904
|
-
_initErrors() {
|
|
1905
|
-
var o, u, g;
|
|
1906
|
-
f(this, s), this.ERRORS = {}, g = this._ERRORS;
|
|
1907
|
-
for (u in g) o = g[u], this.ERRORS[u] = this.createErrorMessage(o);
|
|
1908
|
-
}
|
|
1909
|
-
createErrorMessage(o) {
|
|
1910
|
-
return function(u) {
|
|
1911
|
-
return o.replace("__key", u.type);
|
|
1912
|
-
};
|
|
1913
|
-
}
|
|
1914
|
-
}
|
|
1915
|
-
return s.prototype._ERRORS = { ENOTFOUND: "Key `__key` not found", ECACHEFULL: "Cache max keys amount exceeded", EKEYTYPE: "The key argument has to be of type `string` or `number`. Found: `__key`", EKEYSTYPE: "The keys argument has to be an array.", ETTLTYPE: "The ttl argument has to be a number." }, s;
|
|
1916
|
-
}).call(this);
|
|
1917
|
-
}).call(e);
|
|
1918
|
-
}), st = de((e, t) => {
|
|
1919
|
-
(function() {
|
|
1920
|
-
var a;
|
|
1921
|
-
a = t.exports = rt(), a.version = "5.1.2";
|
|
1922
|
-
}).call(e);
|
|
1923
|
-
}), lt = ((e) => (e.EN = "en", e.BG = "bg", e.RO = "ro", e.EL = "el", e.SK = "sk", e.PT = "pt", e.SR = "sr", e.HU = "hu", e.SV = "sv", e.ES = "es", e.FR = "fr", e.NL = "nl", e.DE = "de", e.IT = "it", e.AR = "ar", e))(lt || {}), ct = ((e) => (e.DEV = "dev", e.PROD = "prod", e.STAGING = "staging", e))(ct || {}), dt = ((e) => (e.NATIVE = "native", e.ENETPULSE = "enetpulse", e.SPORTRADAR = "sportradar", e.SPORTAL_365 = "sportal365", e.API_FOOTBALL = "api_football", e))(dt || {}), ut = ((e) => (e.DEFAULT = "default", e.STANDARD = "standard", e))(ut || {}), ht = ((e) => (e.FT_1X2 = "FT_1X2", e.HT_1X2 = "HT_1X2", e.BOTH_TEAMS_SCORE = "BOTH_TEAMS_SCORE", e.DOUBLE_CHANCE = "DOUBLE_CHANCE", e.HT_FT = "HT_FT", e.PLAYER_SCORE = "PLAYER_SCORE", e.PLAYER_YELLOW_CARD = "PLAYER_YELLOW_CARD", e.PLAYER_RED_CARD = "PLAYER_RED_CARD", e.RED_CARD_MATCH = "RED_CARD_MATCH", e.PENALTY_MATCH = "PENALTY_MATCH", e.PLAYER_SCORE_FIRST_GOAL = "PLAYER_SCORE_FIRST_GOAL", e.CORNERS_MATCH = "CORNERS_MATCH", e.CORRECT_SCORE = "CORRECT_SCORE", e.CORRECT_SCORE_ADVANCED = "CORRECT_SCORE_ADVANCED", e.CORRECT_SCORE_HT = "CORRECT_SCORE_HT", e.PLAYER_SCORE_HATTRICK = "PLAYER_SCORE_HATTRICK", e.PLAYER_SCORE_TWICE = "PLAYER_SCORE_TWICE", e.OVER_GOALS_0_5 = "OVER_GOALS_0_5", e.OVER_GOALS_1_5 = "OVER_GOALS_1_5", e.OVER_GOALS_2_5 = "OVER_GOALS_2_5", e.OVER_GOALS_3_5 = "OVER_GOALS_3_5", e.OVER_GOALS_4_5 = "OVER_GOALS_4_5", e.OVER_GOALS_5_5 = "OVER_GOALS_5_5", e.OVER_GOALS_6_5 = "OVER_GOALS_6_5", e.OVER_CORNERS_6_5 = "OVER_CORNERS_6_5", e.OVER_CORNERS_7_5 = "OVER_CORNERS_7_5", e.OVER_CORNERS_8_5 = "OVER_CORNERS_8_5", e.OVER_CORNERS_9_5 = "OVER_CORNERS_9_5", e.OVER_CORNERS_10_5 = "OVER_CORNERS_10_5", e.OVER_CORNERS_11_5 = "OVER_CORNERS_11_5", e.OVER_CORNERS_12_5 = "OVER_CORNERS_12_5", e.OVER_CORNERS_13_5 = "OVER_CORNERS_13_5", e))(ht || {});
|
|
1924
|
-
function ge(e) {
|
|
1925
|
-
this.message = e;
|
|
1926
|
-
}
|
|
1927
|
-
ge.prototype = new Error(), ge.prototype.name = "InvalidCharacterError";
|
|
1928
|
-
typeof window < "u" && window.atob && window.atob.bind(window);
|
|
1929
|
-
function Ce(e) {
|
|
1930
|
-
this.message = e;
|
|
1931
|
-
}
|
|
1932
|
-
Ce.prototype = new Error(), Ce.prototype.name = "InvalidTokenError";
|
|
1933
|
-
var ft = ((e) => (e[e.BAD_METHOD_CALL = 400] = "BAD_METHOD_CALL", e[e.UNAUTHORIZED = 401] = "UNAUTHORIZED", e[e.NOT_FOUND = 404] = "NOT_FOUND", e[e.PRECONDITION_FAILED = 412] = "PRECONDITION_FAILED", e))(ft || {}), mt = ((e) => (e.INVALID_TEMPLATE = "INVALID_TEMPLATE", e.INVALID_PREDICTION = "INVALID_PREDICTION", e.INVALID_MARKET = "INVALID_MARKET", e.INVALID_FIELD = "INVALID_FIELD", e.INVALID_TYPE = "INVALID_TYPE", e.EXCEEDED_LENGTH = "EXCEEDED_LENGTH", e.INVALID_TOKEN = "invalid_token", e.UNAUTHORIZED = "unauthorized", e.INVALID_FILTERS = "invalid_filters", e.INVALID_AVATAR = "invalid_avatar", e.INVALID_METHOD_CALL = "invalid_method_call", e.INVALID_LIMIT = "invalid_limit", e.INVALID_TEMPLATE_GROUP_ID = "invalid_template_group_id", e.INVALID_TEMPLATE_GROUP_FILTERS = "invalid_template_group_filters", e.INVALID_PAGE_NUMBER = "invalid_page_number", e.INVALID_DISCUSSION_IDS = "invalid_discussion_ids", e.ID_MAPPING_NOT_FOUND = "id_mapping_not_found", e.INVALID_COMPETITION_ID = "invalid_competition_id", e.INVALID_TEAM_ID = "invalid_team_id", e.INVALID_IDS = "invalid_ids", e.INVALID_INPUT_PROVIDER = "invalid_input_provider", e.INVALID_OUTPUT_PROVIDER = "invalid_output_provider", e.INVALID_MATCH_SUMMARY = "invalid_match_summary", e.INVALID_MATCH_SUMMARY_PREDICTIONS = "invalid_match_summary_predictions", e.INVALID_MATCH_SUMMARY_PREDICTIONS_KEYS = "invalid_match_summary_predictions_keys", e.ENTITY_IDS_NOT_FOUND = "entity_ids_not_found", e.MATCH_IDS_NOT_FOUND = "match_ids_not_found", e.INVALID_MATCH_IDS = "invalid_match_ids", e.ODD_CLIENT_CONFIGURATION_NOT_FOUND = "odd_client_configuration_not_found", e))(mt || {}), k = { native: "id", sportradar: "sportradar_id", sportal365: "sportal365_id", enetpulse: "enetpulse_id", api_football: "api_football_id" };
|
|
1934
|
-
(/* @__PURE__ */ new Map()).set("FT_1X2", "fullTimeOneXTwo").set("HT_1X2", "halfTimeOneXTwo").set("BOTH_TEAMS_SCORE", "bothTeamsScore").set("DOUBLE_CHANCE", "doubleChance").set("HT_FT", "halfTimeFullTime").set("PLAYER_SCORE", "playerScore").set("PLAYER_YELLOW_CARD", "playerYellowCard").set("PLAYER_RED_CARD", "playerRedCard").set("RED_CARD_MATCH", "redCardMatch").set("PENALTY_MATCH", "penaltyMatch").set("PLAYER_SCORE_FIRST_GOAL", "playerScoreFirstGoal").set("CORNERS_MATCH", "cornersMatch").set("CORRECT_SCORE", "correctScore").set("CORRECT_SCORE_ADVANCED", "correctScoreAdvanced").set("CORRECT_SCORE_HT", "correctScoreHalfTime").set("PLAYER_SCORE_HATTRICK", "playerScoreHattrick").set("PLAYER_SCORE_TWICE", "playerScoreTwice").set("OVER_GOALS_0_5", "overZeroPointFiveGoals").set("OVER_GOALS_1_5", "overOnePointFiveGoals").set("OVER_GOALS_2_5", "overTwoPointFiveGoals").set("OVER_GOALS_3_5", "overThreePointFiveGoals").set("OVER_GOALS_4_5", "overFourPointFiveGoals").set("OVER_GOALS_5_5", "overFivePointFiveGoals").set("OVER_GOALS_6_5", "overSixPointFiveGoals").set("OVER_CORNERS_6_5", "overSixPointFiveCorners").set("OVER_CORNERS_7_5", "overSevenPointFiveCorners").set("OVER_CORNERS_8_5", "overEightPointFiveCorners").set("OVER_CORNERS_9_5", "overNinePointFiveCorners").set("OVER_CORNERS_10_5", "overTenPointFiveCorners").set("OVER_CORNERS_11_5", "overElevenPointFiveCorners").set("OVER_CORNERS_12_5", "overTwelvePointFiveCorners").set("OVER_CORNERS_13_5", "overThirteenPointFiveCorners");
|
|
1935
|
-
var gt = ((e) => (e.INVALID_MATCH_ID = "Match id is invalid!", e.INVALID_PLAYER_ID = "Player id is invalid!", e.QUERY_PARAM_MATCH_IDS_EXCEEDED = "Maximum matchIds in PredictionFilters should be 10 or less.", e.QUERY_PARAM_FILTERS_LIMIT_EXCEEDED = "Maximum limit for filtering games is 50 or less.", e.INVALID_FIXTURES_FIELD = "Fixtures field is invalid. For more information please visit our documentation", e.INVALID_TOKEN = "Invalid JWT token is provided", e.EXPIRED_TOKEN = "The provided JWT token is expired", e.ENTITIES_NEEDED = "At least one of footballCompetitions, footballTeams or footballPlayers properties should be provided for filters.", e.ENTITIES_FOLLOWS_FILTERS_EXCEEDED = "Maximum length per entity should be 24 or less.", e.INVALID_TYPE = "You have provided invalid type. The valid type is ", e.INVALID_VALUE = "You have provided invalid value. The valid value is ", e.INVALID_AVATAR = "Invalid URL syntax for avatar image.", e.INVALID_GET_PROFILES_METHOD_CALL = "The method 'getByIds' from Profile namespace is not called correctly. You need to provide 'profileIds' OR 'search' parameters to the method, but you can't use both of them or neither of them.", e.INVALID_LIMIT = "Invalid limit. The maximum limit is: ", e.INVALID_LIMIT_TYPE = "Invalid limit type. The proper type is number.", e.FILTER_COMBINATION_ERROR = "You need to use both 'entityIds' and 'entityType' filters together", e.INVALID_ENTITY_TYPE = "Invalid 'entityType' filter. Please use one of the following valid options: competition, team, or player", e.INVALID_TEMPLATE_GROUP_ID = "There is no group in this template with the provided groupId", e.INVALID_TEMPLATE_GROUP_FILTERS = "The provided template group has no filters", e.INVALID_PAGE_NUMBER = "Invalid page number provided. Use number between 1 and max number of pages.", e.INVALID_DISCUSSION_IDS = "Invalid discussion ids argument. Please provide at least one discussion id in an array", e.EXCEEDED_DISCUSSION_IDS = "Maximum number of discussion ids exceeded. The maximum number of discussion ids is 50. You can use 'getPostsCountExtended' method for more than 50 discussion ids.", e.EXCEEDED_EXTENDED_DISCUSSION_IDS = "Maximum number of discussion ids exceeded. The maximum number of discussion ids is: ", e.ID_MAPPING_NOT_FOUND = "No ID mappings are available for the provided ID. ID argument: ", e.INVALID_PARAM = "Invalid parameter provided. Please check the following parameter: ", e.INVALID_COMPETITION_ID = "Invalid competition ID provided. Please provide a valid competition ID.", e.INVALID_TEAM_ID = "Invalid team ID provided. Please provide a valid team ID.", e.INVALID_OR_EMPTY_IDS = "Invalid or empty IDs provided. Please provide at least one ID.", e.INVALID_PROVIDER = "Invalid provider. The valid providers are: 'native', 'enetpulse', 'sportal365', 'sportradar' and 'api_football'.", e.INVALID_OUTPUT_PROVIDER = "Invalid output provider. The output can not be the same as the input provider.", e.MATCH_SUMMARY_REQUIRED = "Match summary is required.", e.MATCH_SUMMARY_PREDICTIONS_REQUIRED = "Predictions in match summary are required.", e.INVALID_MATCH_SUMMARY_PREDICTIONS_KEYS = "Keys in predictions in match summary are invalid. The valid ones are: ", e.INVALID_COLLECT_LEAD_METHOD_CALL = "The method 'collectLead' from Profile namespace is not called correctly. You need to provide 'requestBody' parameter to the method.", e.REQUIRED_FIXTURES_FIELD = "Fixtures field is required and should contain at least one fixtures object. For more information please visit our documentation", e.INVALID_TIEBREAKER_FIELD = "Tiebreaker field is invalid. It should contain statTotal key with integer value. For more information please visit our documentation", e.ENTITY_IDS_NOT_FOUND = "Some of the sport entity IDs were not found for the provided id schema", e.MATCH_IDS_NOT_FOUND = "Some of the match IDs were not found for the provided id schema", e.INVALID_STANDING_PREDICTION_ARGUMENT = "The prediction argument is invalid. For more information please visit our documentation", e.INVALID_MAP_PLAYERS_ROLES_KEYS = "The keys in the players roles map are not part of the valid keys. The valid keys are: ", e.INVALID_MAP_PLAYERS_ROLES_VALUES = "The values in the map are not valid. The valid ones are: ", e.INVALID_MATCH_IDS = "Match IDs are invalid!", e.MISSING_ODD_CLIENT_CONFIGURATION = "Odds namespace requires oddClient configuration to be set", e.INVALID_COLLECT_CONSENTS_METHOD_CALL = "The method 'collectConsents' from Profile namespace is not called correctly. You need to provide 'consents' parameter to the method.", e))(gt || {}), yt = ((e) => (e.LIKE = "like", e.DISLIKE = "dislike", e.PAGE_VIEW = "page_view", e.CONTENT_CONSUMED = "content_consumed", e.SHARE = "share", e.COMMENT = "comment", e.CLICK_AD = "click_ad", e.PREDICTION_MADE = "prediction_made", e.CONVERT = "convert", e.MANAGE_INTERESTS = "manage_interests", e.GAME_PARTICIPATION = "game_participation", e.ARTICLE_CONSUMED = "article_consumed", e.VIDEO_CONSUMED = "video_consumed", e.SHORT_VIDEO_CONSUMED = "short_video_consumed", e.LONG_VIDEO_CONSUMED = "long_video_consumed", e.AUDIO_CONSUMED = "audio_consumed", e.GALLERY_CONSUMED = "gallery_consumed", e.IMAGE_CONSUMED = "image_consumed", e.POLL_PARTICIPATION = "poll_participation", e))(yt || {}), he = "FansUnited", se = { football: { ids: [], countries: [], competitions: [], expirations: { ids: 0 } }, profile: { info: {}, statistics: {}, badges: null, countries: [], expirations: { profile: 0, statistics: 0, badges: 0 } }, client: { features: {}, expirations: { features: 0 } } }, Z = class {
|
|
1936
|
-
constructor(e) {
|
|
1937
|
-
i(this, "idSchema", "");
|
|
1938
|
-
i(this, "storageInstance", null);
|
|
1939
|
-
i(this, "expirationProfileTimeout", 600);
|
|
1940
|
-
i(this, "expirationBadgesTimeout", 3600);
|
|
1941
|
-
i(this, "expirationClientFeaturesTimeout", 14400);
|
|
1942
|
-
i(this, "expirationFootballIdsTimeout", 604800);
|
|
1943
|
-
i(this, "clearData", async () => {
|
|
1944
|
-
await this.setData(se);
|
|
1945
|
-
});
|
|
1946
|
-
i(this, "getCompetitions", async (e) => {
|
|
1947
|
-
let t = await this.getData();
|
|
1948
|
-
return e ? e.competitionSearchFilter(t.football.competitions) : t.football.competitions;
|
|
1949
|
-
});
|
|
1950
|
-
i(this, "setCompetitions", async (e) => {
|
|
1951
|
-
let t = await this.getData(), a = [...t.football.competitions];
|
|
1952
|
-
a.push(...e), t.football.competitions = this.makeCompetitionsUnique(a), await this.setData(t);
|
|
1953
|
-
});
|
|
1954
|
-
i(this, "getCompetitionsLength", async () => (await this.getData()).football.competitions.length);
|
|
1955
|
-
i(this, "getEntityById", async (e = "", t = "") => (await this.getData()).football.ids.find((a) => {
|
|
1956
|
-
let r = k[this.idSchema];
|
|
1957
|
-
return a && `${a[r]}` === t && a.resource === e;
|
|
1958
|
-
}));
|
|
1959
|
-
i(this, "getEntity", async (e, t, a) => {
|
|
1960
|
-
let r = await this.getData();
|
|
1961
|
-
return Array.isArray(e) ? r.football.ids.filter((l) => {
|
|
1962
|
-
let f = k[a];
|
|
1963
|
-
return l && e.includes(`${l[f]}`) && l.resource === t;
|
|
1964
|
-
}) : r.football.ids.find((l) => {
|
|
1965
|
-
let f = k[a];
|
|
1966
|
-
return l && `${l[f]}` === e && l.resource === t;
|
|
1967
|
-
});
|
|
1968
|
-
});
|
|
1969
|
-
i(this, "checkForExistingIdObjs", async (e, t) => {
|
|
1970
|
-
let a = k[t], r = {};
|
|
1971
|
-
for (let l of Object.keys(e)) {
|
|
1972
|
-
let f = e[l], _ = (await this.getEntity(f, l, t)).map((E) => E[a]), s = e[l].filter((E) => !_.includes(E));
|
|
1973
|
-
r[l] = f.map((E) => s.includes(E) ? { id: E, exists: !1 } : { id: E, exists: !0 });
|
|
1974
|
-
}
|
|
1975
|
-
return r;
|
|
1976
|
-
});
|
|
1977
|
-
i(this, "getIdsByType", async (e, t, a) => {
|
|
1978
|
-
let r = await this.getData(), l = k[a], f = k[t], _ = {};
|
|
1979
|
-
return Object.keys(e).forEach((s) => {
|
|
1980
|
-
let E = e[s], o = [];
|
|
1981
|
-
r.football.ids.forEach((u) => {
|
|
1982
|
-
E.forEach((g, S) => {
|
|
1983
|
-
g === u[f] && s === u.resource && (o[S] = u[l]);
|
|
1984
|
-
});
|
|
1985
|
-
}), _[s] = o;
|
|
1986
|
-
}), _;
|
|
1987
|
-
});
|
|
1988
|
-
i(this, "addIdMapping", async (e) => {
|
|
1989
|
-
let t = await this.getData();
|
|
1990
|
-
t.football.ids.push(e), await this.setData(t);
|
|
1991
|
-
});
|
|
1992
|
-
i(this, "addIdMappings", async (e) => {
|
|
1993
|
-
let t = await this.getData(), a = t.football.ids;
|
|
1994
|
-
a = [...a, ...e], t.football.ids = a, await this.setData(t);
|
|
1995
|
-
});
|
|
1996
|
-
i(this, "addTopIdMappings", async (e) => {
|
|
1997
|
-
let t = await this.getData();
|
|
1998
|
-
if (t.football.ids.length) {
|
|
1999
|
-
let a = JSON.parse(JSON.stringify(t.football.ids));
|
|
2000
|
-
a = a.filter((r) => r.resource !== "match"), e = e.filter((r) => r.resource === "match"), a = [...a, ...e], t.football.ids = a;
|
|
2001
|
-
} else t.football.ids = e;
|
|
2002
|
-
t.football.expirations.ids = Math.floor(Date.now() / 1e3) + this.expirationFootballIdsTimeout, await this.setData(t);
|
|
2003
|
-
});
|
|
2004
|
-
i(this, "setOwnProfile", async (e) => {
|
|
2005
|
-
let t = await this.getData();
|
|
2006
|
-
t.profile.info = e, t.profile.expirations.profile = Math.floor(Date.now() / 1e3) + this.expirationProfileTimeout, await this.setData(t);
|
|
2007
|
-
});
|
|
2008
|
-
i(this, "getOwnProfile", async () => (await this.getData()).profile.info);
|
|
2009
|
-
i(this, "getProfileCountries", async () => (await this.getData()).profile.countries);
|
|
2010
|
-
i(this, "setProfileCountries", async (e) => {
|
|
2011
|
-
let t = await this.getData();
|
|
2012
|
-
t.profile.countries = e, await this.setData(t);
|
|
2013
|
-
});
|
|
2014
|
-
i(this, "getProfileStats", async () => (await this.getData()).profile.statistics);
|
|
2015
|
-
i(this, "setProfileStats", async (e) => {
|
|
2016
|
-
let t = await this.getData();
|
|
2017
|
-
t.profile.statistics = e, t.profile.expirations.statistics = Math.floor(Date.now() / 1e3) + this.expirationProfileTimeout, await this.setData(t);
|
|
2018
|
-
});
|
|
2019
|
-
i(this, "getProfileBadges", async () => (await this.getData()).profile.badges);
|
|
2020
|
-
i(this, "setProfileBadges", async (e) => {
|
|
2021
|
-
let t = await this.getData();
|
|
2022
|
-
t.profile.badges = e, t.profile.expirations.badges = Math.floor(Date.now() / 1e3) + this.expirationBadgesTimeout, await this.setData(t);
|
|
2023
|
-
});
|
|
2024
|
-
i(this, "getFootballCountries", async () => (await this.getData()).football.countries);
|
|
2025
|
-
i(this, "setFootballCountries", async (e) => {
|
|
2026
|
-
let t = await this.getData();
|
|
2027
|
-
t.football.countries = e, await this.setData(t);
|
|
2028
|
-
});
|
|
2029
|
-
i(this, "getClientFeatures", async () => (await this.getData()).client.features);
|
|
2030
|
-
i(this, "setClientFeatures", async (e) => {
|
|
2031
|
-
let t = await this.getData(), a = JSON.parse(JSON.stringify(e));
|
|
2032
|
-
t.client.expirations.features = Math.floor(Date.now() / 1e3) + this.expirationClientFeaturesTimeout, t.client.features = a, await this.setData(t);
|
|
2033
|
-
});
|
|
2034
|
-
i(this, "deleteClientFeatures", async () => {
|
|
2035
|
-
let e = await this.getData(), t = JSON.parse(JSON.stringify(e));
|
|
2036
|
-
t.client = { features: {}, expirations: { features: 0 } }, await this.setData(t);
|
|
2037
|
-
});
|
|
2038
|
-
i(this, "getExpiration", async (e, t) => {
|
|
2039
|
-
await this.initialNewSchema(e, "expirations");
|
|
2040
|
-
let a = await this.getData();
|
|
2041
|
-
switch (t) {
|
|
2042
|
-
case "profile":
|
|
2043
|
-
return a.profile.expirations.profile;
|
|
2044
|
-
case "statistics":
|
|
2045
|
-
return a.profile.expirations.statistics;
|
|
2046
|
-
case "badges":
|
|
2047
|
-
return a.profile.expirations.badges;
|
|
2048
|
-
case "features":
|
|
2049
|
-
return a.client.expirations.features;
|
|
2050
|
-
case "ids":
|
|
2051
|
-
return a.football.expirations.ids;
|
|
2052
|
-
}
|
|
2053
|
-
});
|
|
2054
|
-
i(this, "makeCompetitionsUnique", (e) => {
|
|
2055
|
-
let t = /* @__PURE__ */ new Set();
|
|
2056
|
-
return e.filter((a) => {
|
|
2057
|
-
let r = !t.has(a.id);
|
|
2058
|
-
return t.add(a.id), r;
|
|
2059
|
-
});
|
|
2060
|
-
});
|
|
2061
|
-
i(this, "initialNewSchema", async (e, t) => {
|
|
2062
|
-
let a = await this.getData();
|
|
2063
|
-
(!a || !a[e] || !a[e][t]) && await this.setData(se);
|
|
2064
|
-
});
|
|
2065
|
-
this.idSchema = e, this.getStorageInstance();
|
|
2066
|
-
}
|
|
2067
|
-
static getInstance(e) {
|
|
2068
|
-
return Z.instance || (Z.instance = new Z(e)), Z.instance;
|
|
2069
|
-
}
|
|
2070
|
-
async getStorageInstance() {
|
|
2071
|
-
try {
|
|
2072
|
-
let e = await Promise.resolve().then(() => (at(), Oe));
|
|
2073
|
-
this.storageInstance = e.default;
|
|
2074
|
-
} catch (e) {
|
|
2075
|
-
console.error(e);
|
|
2076
|
-
}
|
|
2077
|
-
}
|
|
2078
|
-
async getData() {
|
|
2079
|
-
try {
|
|
2080
|
-
let e = await this.storageInstance.getItem(he);
|
|
2081
|
-
return e ? JSON.parse(e) : (await this.storageInstance.setItem(he, JSON.stringify(se)), se);
|
|
2082
|
-
} catch (e) {
|
|
2083
|
-
throw console.error("AsyncStorage error:", e), e;
|
|
2084
|
-
}
|
|
2085
|
-
}
|
|
2086
|
-
async setData(e) {
|
|
2087
|
-
await this.storageInstance.setItem(he, JSON.stringify(e));
|
|
2088
|
-
}
|
|
2089
|
-
}, _t = Z;
|
|
2090
|
-
B(_t, "instance");
|
|
2091
|
-
var fe = "FansUnited", me = { football: { ids: [], countries: [], competitions: [], expirations: { ids: 0 } }, profile: { info: {}, statistics: {}, badges: null, countries: [], expirations: { profile: 0, statistics: 0, badges: 0 } }, client: { features: {}, expirations: { features: 0 } } }, ee = class {
|
|
2092
|
-
constructor(e) {
|
|
2093
|
-
i(this, "idSchema", "");
|
|
2094
|
-
i(this, "expirationProfileTimeout", 600);
|
|
2095
|
-
i(this, "expirationBadgesTimeout", 3600);
|
|
2096
|
-
i(this, "expirationClientFeaturesTimeout", 14400);
|
|
2097
|
-
i(this, "expirationFootballIdsTimeout", 604800);
|
|
2098
|
-
i(this, "clearData", async () => {
|
|
2099
|
-
this.setData(me);
|
|
2100
|
-
});
|
|
2101
|
-
i(this, "getEntityById", async (e = "", t = "") => this.getData().football.ids.find((a) => {
|
|
2102
|
-
let r = k[this.idSchema];
|
|
2103
|
-
return a && `${a[r]}` === t && a.resource === e;
|
|
2104
|
-
}));
|
|
2105
|
-
i(this, "getEntity", (e, t, a) => Array.isArray(e) ? this.getData().football.ids.filter((r) => {
|
|
2106
|
-
let l = k[a];
|
|
2107
|
-
return r && e.includes(`${r[l]}`) && r.resource === t;
|
|
2108
|
-
}) : this.getData().football.ids.find((r) => {
|
|
2109
|
-
let l = k[a];
|
|
2110
|
-
return r && `${r[l]}` === e && r.resource === t;
|
|
2111
|
-
}));
|
|
2112
|
-
i(this, "getEntityByNativeId", (e = "", t = "") => this.getData().football.ids.find((a) => a && `${a.id}` === t && a.resource === e));
|
|
2113
|
-
i(this, "checkForExistingIdObjs", async (e, t) => {
|
|
2114
|
-
let a = k[t], r = {};
|
|
2115
|
-
return Object.keys(e).forEach((l) => {
|
|
2116
|
-
let f = e[l], _ = this.getEntity(f, l, t).map((E) => E[a]), s = e[l].filter((E) => !_.includes(E));
|
|
2117
|
-
r[l] = f.map((E) => s.includes(E) ? { id: E, exists: !1 } : { id: E, exists: !0 });
|
|
2118
|
-
}), r;
|
|
2119
|
-
});
|
|
2120
|
-
i(this, "getIdsByType", async (e, t, a) => {
|
|
2121
|
-
let r = k[a], l = k[t], f = {};
|
|
2122
|
-
return Object.keys(e).forEach((_) => {
|
|
2123
|
-
let s = e[_], E = [];
|
|
2124
|
-
this.getData().football.ids.forEach((o) => {
|
|
2125
|
-
s.forEach((u, g) => {
|
|
2126
|
-
u === o[l] && _ === o.resource && (E[g] = o[r]);
|
|
2127
|
-
});
|
|
2128
|
-
}), f[_] = E;
|
|
2129
|
-
}), f;
|
|
2130
|
-
});
|
|
2131
|
-
i(this, "addIdMapping", (e) => {
|
|
2132
|
-
let t = this.getData();
|
|
2133
|
-
t.football.ids.push(e), this.setData(t);
|
|
2134
|
-
});
|
|
2135
|
-
i(this, "addIdMappings", async (e) => {
|
|
2136
|
-
let t = this.getData(), a = t.football.ids;
|
|
2137
|
-
a = [...a, ...e], t.football.ids = a, this.setData(t);
|
|
2138
|
-
});
|
|
2139
|
-
i(this, "addTopIdMappings", async (e) => {
|
|
2140
|
-
let t = this.getData();
|
|
2141
|
-
if (t.football.ids.length) {
|
|
2142
|
-
let a = JSON.parse(JSON.stringify(t.football.ids));
|
|
2143
|
-
a = a.filter((r) => r.resource !== "match"), e = e.filter((r) => r.resource === "match"), a = [...a, ...e], t.football.ids = a;
|
|
2144
|
-
} else t.football.ids = e;
|
|
2145
|
-
t.football.expirations.ids = Math.floor(Date.now() / 1e3) + this.expirationFootballIdsTimeout, this.setData(t);
|
|
2146
|
-
});
|
|
2147
|
-
i(this, "setOwnProfile", async (e) => {
|
|
2148
|
-
let t = this.getData();
|
|
2149
|
-
t.profile.info = e, t.profile.expirations.profile = Math.floor(Date.now() / 1e3) + this.expirationProfileTimeout, this.setData(t);
|
|
2150
|
-
});
|
|
2151
|
-
i(this, "getOwnProfile", () => this.getData().profile.info);
|
|
2152
|
-
i(this, "getProfileCountries", () => this.getData().profile.countries);
|
|
2153
|
-
i(this, "setProfileCountries", async (e) => {
|
|
2154
|
-
let t = this.getData();
|
|
2155
|
-
t.profile.countries = e, this.setData(t);
|
|
2156
|
-
});
|
|
2157
|
-
i(this, "getProfileStats", () => this.getData().profile.statistics);
|
|
2158
|
-
i(this, "setProfileStats", async (e) => {
|
|
2159
|
-
let t = this.getData();
|
|
2160
|
-
t.profile.statistics = e, t.profile.expirations.statistics = Math.floor(Date.now() / 1e3) + this.expirationProfileTimeout, this.setData(t);
|
|
2161
|
-
});
|
|
2162
|
-
i(this, "getProfileBadges", () => this.getData().profile.badges);
|
|
2163
|
-
i(this, "setProfileBadges", async (e) => {
|
|
2164
|
-
let t = this.getData();
|
|
2165
|
-
t.profile.badges = e, t.profile.expirations.badges = Math.floor(Date.now() / 1e3) + this.expirationBadgesTimeout, this.setData(t);
|
|
2166
|
-
});
|
|
2167
|
-
i(this, "getFootballCountries", () => this.getData().football.countries);
|
|
2168
|
-
i(this, "setFootballCountries", async (e) => {
|
|
2169
|
-
let t = this.getData();
|
|
2170
|
-
t.football.countries = e, this.setData(t);
|
|
2171
|
-
});
|
|
2172
|
-
i(this, "getCompetitions", (e) => {
|
|
2173
|
-
let t = this.getData();
|
|
2174
|
-
return e ? e.competitionSearchFilter(t.football.competitions) : t.football.competitions;
|
|
2175
|
-
});
|
|
2176
|
-
i(this, "setCompetitions", async (e) => {
|
|
2177
|
-
let t = this.getData(), a = [...t.football.competitions];
|
|
2178
|
-
a.push(...e), t.football.competitions = this.makeCompetitionsUnique(a), this.setData(t);
|
|
2179
|
-
});
|
|
2180
|
-
i(this, "getCompetitionsLength", async () => {
|
|
2181
|
-
let { football: e } = this.getData();
|
|
2182
|
-
return e.competitions.length;
|
|
2183
|
-
});
|
|
2184
|
-
i(this, "getClientFeatures", () => this.getData().client.features);
|
|
2185
|
-
i(this, "setClientFeatures", async (e) => {
|
|
2186
|
-
let t = this.getData(), a = JSON.parse(JSON.stringify(e));
|
|
2187
|
-
t.client.expirations.features = Math.floor(Date.now() / 1e3) + this.expirationClientFeaturesTimeout, t.client.features = a, this.setData(t);
|
|
2188
|
-
});
|
|
2189
|
-
i(this, "deleteClientFeatures", async () => {
|
|
2190
|
-
let e = this.getData(), t = JSON.parse(JSON.stringify(e));
|
|
2191
|
-
t.client = { features: {}, expirations: { features: 0 } }, this.setData(t);
|
|
2192
|
-
});
|
|
2193
|
-
i(this, "getExpiration", async (e, t) => {
|
|
2194
|
-
this.initialNewSchema(e, "expirations");
|
|
2195
|
-
let a = this.getData();
|
|
2196
|
-
switch (t) {
|
|
2197
|
-
case "profile":
|
|
2198
|
-
return a.profile.expirations.profile;
|
|
2199
|
-
case "statistics":
|
|
2200
|
-
return a.profile.expirations.statistics;
|
|
2201
|
-
case "badges":
|
|
2202
|
-
return a.profile.expirations.badges;
|
|
2203
|
-
case "features":
|
|
2204
|
-
return a.client.expirations.features;
|
|
2205
|
-
case "ids":
|
|
2206
|
-
return a.football.expirations.ids;
|
|
2207
|
-
}
|
|
2208
|
-
});
|
|
2209
|
-
i(this, "makeCompetitionsUnique", (e) => {
|
|
2210
|
-
let t = /* @__PURE__ */ new Set();
|
|
2211
|
-
return e.filter((a) => {
|
|
2212
|
-
let r = !t.has(a.id);
|
|
2213
|
-
return t.add(a.id), r;
|
|
2214
|
-
});
|
|
2215
|
-
});
|
|
2216
|
-
i(this, "getData", () => (localStorage.getItem(fe) || this.setData(me), JSON.parse(localStorage.getItem(fe))));
|
|
2217
|
-
i(this, "setData", (e) => {
|
|
2218
|
-
localStorage.setItem(fe, JSON.stringify(e));
|
|
2219
|
-
});
|
|
2220
|
-
i(this, "initialNewSchema", (e, t) => {
|
|
2221
|
-
let a = this.getData();
|
|
2222
|
-
(!a || !a[e] || !a[e][t]) && this.setData(me);
|
|
2223
|
-
});
|
|
2224
|
-
this.idSchema = e;
|
|
2225
|
-
}
|
|
2226
|
-
static getInstance(e) {
|
|
2227
|
-
return ee.instance || (ee.instance = new ee(e)), ee.instance;
|
|
2228
|
-
}
|
|
2229
|
-
}, xt = ee;
|
|
2230
|
-
B(xt, "instance");
|
|
2231
|
-
var Et = it(st()), p = class {
|
|
2232
|
-
constructor(e) {
|
|
2233
|
-
i(this, "profileTTL", 600);
|
|
2234
|
-
i(this, "clientTTL", 14400);
|
|
2235
|
-
i(this, "profileBadgesTTL", 3600);
|
|
2236
|
-
i(this, "idMappingsExpiration", 0);
|
|
2237
|
-
i(this, "idSchema", "");
|
|
2238
|
-
i(this, "clearData", async () => p.nodeCache.flushAll());
|
|
2239
|
-
i(this, "getEntityById", async (e, t) => {
|
|
2240
|
-
let a = p.nodeCache.get("ids");
|
|
2241
|
-
return a ? a.find((r) => {
|
|
2242
|
-
let l = k[this.idSchema];
|
|
2243
|
-
return r && `${r[l]}` === t && r.resource === e;
|
|
2244
|
-
}) : null;
|
|
2245
|
-
});
|
|
2246
|
-
i(this, "getEntity", async (e, t, a) => {
|
|
2247
|
-
let r = p.nodeCache.get("ids");
|
|
2248
|
-
return r ? Array.isArray(e) ? [] : null : Array.isArray(e) ? r.filter((l) => {
|
|
2249
|
-
let f = k[a];
|
|
2250
|
-
return l && e.includes(`${l[f]}`) && l.resource === t;
|
|
2251
|
-
}) : r.find((l) => {
|
|
2252
|
-
let f = k[a];
|
|
2253
|
-
return l && `${l[f]}` === e && l.resource === t;
|
|
2254
|
-
});
|
|
2255
|
-
});
|
|
2256
|
-
i(this, "checkForExistingIdObjs", async (e, t) => {
|
|
2257
|
-
let a = k[t], r = {};
|
|
2258
|
-
for (let l of Object.keys(e)) {
|
|
2259
|
-
let f = e[l], _ = (await this.getEntity(f, l, t)).map((E) => E[a]), s = e[l].filter((E) => !_.includes(E));
|
|
2260
|
-
r[l] = f.map((E) => s.includes(E) ? { id: E, exists: !1 } : { id: E, exists: !0 });
|
|
2261
|
-
}
|
|
2262
|
-
return r;
|
|
2263
|
-
});
|
|
2264
|
-
i(this, "getIdsByType", async (e, t, a) => {
|
|
2265
|
-
let r = k[a], l = k[t], f = p.nodeCache.get("ids"), _ = {};
|
|
2266
|
-
return f ? (Object.keys(e).forEach((s) => {
|
|
2267
|
-
let E = e[s], o = [];
|
|
2268
|
-
f.forEach((u) => {
|
|
2269
|
-
E.forEach((g, S) => {
|
|
2270
|
-
g === u[l] && s === u.resource && (o[S] = u[r]);
|
|
2271
|
-
});
|
|
2272
|
-
}), _[s] = o;
|
|
2273
|
-
}), _) : null;
|
|
2274
|
-
});
|
|
2275
|
-
i(this, "addIdMapping", async (e) => {
|
|
2276
|
-
let t = p.nodeCache.get("ids");
|
|
2277
|
-
t.push(e), p.nodeCache.set("ids", t);
|
|
2278
|
-
});
|
|
2279
|
-
i(this, "addIdMappings", async (e) => {
|
|
2280
|
-
let t = p.nodeCache.get("ids");
|
|
2281
|
-
t = [...t, ...e], p.nodeCache.set("ids", t);
|
|
2282
|
-
});
|
|
2283
|
-
i(this, "addTopIdMappings", async (e) => {
|
|
2284
|
-
let t = p.nodeCache.get("ids"), a = 604800;
|
|
2285
|
-
if (t) {
|
|
2286
|
-
let r = JSON.parse(JSON.stringify(t));
|
|
2287
|
-
r = r.filter((l) => l.resource !== "match"), e = e.filter((l) => l.resource === "match"), r = [...r, ...e], p.nodeCache.set("ids", r);
|
|
2288
|
-
} else p.nodeCache.set("ids", e);
|
|
2289
|
-
this.idMappingsExpiration = Math.floor(Date.now() / 1e3) + a;
|
|
2290
|
-
});
|
|
2291
|
-
i(this, "setOwnProfile", async (e) => {
|
|
2292
|
-
p.nodeCache.set("profile", e, this.profileTTL);
|
|
2293
|
-
});
|
|
2294
|
-
i(this, "getOwnProfile", async () => p.nodeCache.get("profile"));
|
|
2295
|
-
i(this, "getProfileCountries", async () => p.nodeCache.get("profile_countries"));
|
|
2296
|
-
i(this, "setProfileCountries", async (e) => {
|
|
2297
|
-
p.nodeCache.set("profile_countries", e);
|
|
2298
|
-
});
|
|
2299
|
-
i(this, "getProfileStats", async () => p.nodeCache.get("profile_stats"));
|
|
2300
|
-
i(this, "setProfileStats", async (e) => {
|
|
2301
|
-
p.nodeCache.set("profile_stats", e, this.profileTTL);
|
|
2302
|
-
});
|
|
2303
|
-
i(this, "getProfileBadges", async () => p.nodeCache.get("profile_badges"));
|
|
2304
|
-
i(this, "setProfileBadges", async (e) => {
|
|
2305
|
-
p.nodeCache.set("profile_badges", e, this.profileBadgesTTL);
|
|
2306
|
-
});
|
|
2307
|
-
i(this, "getFootballCountries", async () => p.nodeCache.get("football_countries"));
|
|
2308
|
-
i(this, "setFootballCountries", async (e) => {
|
|
2309
|
-
p.nodeCache.set("football_countries", e);
|
|
2310
|
-
});
|
|
2311
|
-
i(this, "getCompetitions", async (e) => {
|
|
2312
|
-
let t = p.nodeCache.get("football_competitions");
|
|
2313
|
-
return t ? e ? e.competitionSearchFilter(t) : t : null;
|
|
2314
|
-
});
|
|
2315
|
-
i(this, "setCompetitions", async (e) => {
|
|
2316
|
-
p.nodeCache.set("football_competitions", e);
|
|
2317
|
-
});
|
|
2318
|
-
i(this, "getCompetitionsLength", async () => {
|
|
2319
|
-
let e = p.nodeCache.get("football_competitions");
|
|
2320
|
-
return e ? e.length : 0;
|
|
2321
|
-
});
|
|
2322
|
-
i(this, "getClientFeatures", async () => p.nodeCache.get("client"));
|
|
2323
|
-
i(this, "setClientFeatures", async (e) => {
|
|
2324
|
-
p.nodeCache.set("client", e, this.clientTTL);
|
|
2325
|
-
});
|
|
2326
|
-
i(this, "deleteClientFeatures", async () => {
|
|
2327
|
-
p.nodeCache.del("client");
|
|
2328
|
-
});
|
|
2329
|
-
i(this, "getExpiration", async (e, t) => {
|
|
2330
|
-
let a = this.getKeyFromExpirationType(t);
|
|
2331
|
-
return a === "ids" ? this.idMappingsExpiration : p.nodeCache.getTtl(a);
|
|
2332
|
-
});
|
|
2333
|
-
i(this, "getKeyFromExpirationType", (e) => {
|
|
2334
|
-
switch (e) {
|
|
2335
|
-
case "profile":
|
|
2336
|
-
return "profile";
|
|
2337
|
-
case "statistics":
|
|
2338
|
-
return "profile_stats";
|
|
2339
|
-
case "badges":
|
|
2340
|
-
return "profile_badges";
|
|
2341
|
-
case "features":
|
|
2342
|
-
return "client";
|
|
2343
|
-
case "ids":
|
|
2344
|
-
return "ids";
|
|
2345
|
-
}
|
|
2346
|
-
});
|
|
2347
|
-
}
|
|
2348
|
-
static getInstance(e) {
|
|
2349
|
-
return p.instance || (p.instance = new p(e), p.nodeCache.options.useClones = !1), p.instance;
|
|
2350
|
-
}
|
|
2351
|
-
}, Re = p;
|
|
2352
|
-
B(Re, "instance"), B(Re, "nodeCache", new Et.default());
|
|
2353
|
-
var Tt = ((e) => (e.ACTIVE = "ACTIVE", e.WON = "WON", e.LOST = "LOST", e.PARTIALLY_WON = "PARTIALLY_WON", e.CANCELED = "CANCELED", e))(Tt || {}), St = ((e) => (e.ACTIVE = "ACTIVE", e.WON = "WON", e.LOST = "LOST", e.PARTIALLY_WON = "PARTIALLY_WON", e.CANCELED = "CANCELED", e))(St || {}), ai = class {
|
|
2354
|
-
constructor() {
|
|
2355
|
-
i(this, "id", null);
|
|
2356
|
-
i(this, "title", null);
|
|
2357
|
-
i(this, "description", null);
|
|
2358
|
-
i(this, "images", null);
|
|
2359
|
-
i(this, "rules", null);
|
|
2360
|
-
i(this, "customFields", null);
|
|
2361
|
-
i(this, "type", "EVENT");
|
|
2362
|
-
i(this, "status", null);
|
|
2363
|
-
i(this, "related", []);
|
|
2364
|
-
i(this, "tiebreaker", null);
|
|
2365
|
-
i(this, "predictionsCutoff", null);
|
|
2366
|
-
i(this, "fixtures", []);
|
|
2367
|
-
i(this, "branding", null);
|
|
2368
|
-
i(this, "brandingId", null);
|
|
2369
|
-
i(this, "createdAt", null);
|
|
2370
|
-
i(this, "updatedAt", null);
|
|
2371
|
-
}
|
|
2372
|
-
}, Ct = ((e) => (e.BOOLEAN = "BOOLEAN", e.NUMBER = "NUMBER", e.ENUM = "ENUM", e.FREE_INPUT = "FREE_INPUT", e))(Ct || {}), Rt = ((e) => (e.PARTICIPANT_ONE = "PARTICIPANT_ONE", e.PARTICIPANT_TWO = "PARTICIPANT_TWO", e.DRAW = "DRAW", e))(Rt || {}), It = ((e) => (e.OPEN = "OPEN", e.LIVE = "LIVE", e.PENDING = "PENDING", e.CANCELED = "CANCELED", e.CLOSED = "CLOSED", e.SETTLED = "SETTLED", e))(It || {}), ni = class {
|
|
2373
|
-
constructor() {
|
|
2374
|
-
i(this, "fixtures", []);
|
|
2375
|
-
i(this, "tiebreaker");
|
|
2376
|
-
}
|
|
2377
|
-
}, Te = class {
|
|
2378
|
-
constructor() {
|
|
2379
|
-
i(this, "main", null);
|
|
2380
|
-
i(this, "cover", null);
|
|
2381
|
-
i(this, "mobile", null);
|
|
2382
|
-
}
|
|
2383
|
-
}, bt = class {
|
|
2384
|
-
constructor() {
|
|
2385
|
-
i(this, "timeTiebreaker", !1);
|
|
2386
|
-
}
|
|
2387
|
-
}, Ot = class {
|
|
2388
|
-
constructor() {
|
|
2389
|
-
i(this, "id", null);
|
|
2390
|
-
i(this, "title", null);
|
|
2391
|
-
i(this, "alternativeTitle", null);
|
|
2392
|
-
i(this, "description", null);
|
|
2393
|
-
i(this, "type", null);
|
|
2394
|
-
i(this, "images", new Te());
|
|
2395
|
-
i(this, "participationCount", null);
|
|
2396
|
-
i(this, "questionsCount", null);
|
|
2397
|
-
i(this, "status", null);
|
|
2398
|
-
i(this, "language", null);
|
|
2399
|
-
i(this, "authRequirement", null);
|
|
2400
|
-
i(this, "flags", null);
|
|
2401
|
-
i(this, "customFields", null);
|
|
2402
|
-
i(this, "labels", null);
|
|
2403
|
-
i(this, "branding", null);
|
|
2404
|
-
i(this, "brandingId", null);
|
|
2405
|
-
i(this, "related", []);
|
|
2406
|
-
i(this, "time", null);
|
|
2407
|
-
i(this, "points", null);
|
|
2408
|
-
i(this, "scored", !1);
|
|
2409
|
-
i(this, "maxAttempts", null);
|
|
2410
|
-
i(this, "averageScore", null);
|
|
2411
|
-
i(this, "perfectScore", null);
|
|
2412
|
-
i(this, "adContent", null);
|
|
2413
|
-
i(this, "context", null);
|
|
2414
|
-
i(this, "createdAt", null);
|
|
2415
|
-
i(this, "updatedAt", null);
|
|
2416
|
-
}
|
|
2417
|
-
}, oi = class extends Ot {
|
|
2418
|
-
constructor() {
|
|
2419
|
-
super(...arguments);
|
|
2420
|
-
i(this, "rules", null);
|
|
2421
|
-
i(this, "questions", []);
|
|
2422
|
-
}
|
|
2423
|
-
}, ri = class {
|
|
2424
|
-
constructor() {
|
|
2425
|
-
i(this, "classicQuizId", null);
|
|
2426
|
-
i(this, "classicQuizModel", null);
|
|
2427
|
-
i(this, "correct", null);
|
|
2428
|
-
i(this, "classicQuizQuestions", null);
|
|
2429
|
-
i(this, "personalBest", null);
|
|
2430
|
-
i(this, "points", null);
|
|
2431
|
-
i(this, "answers", []);
|
|
2432
|
-
i(this, "attempts", 0);
|
|
2433
|
-
}
|
|
2434
|
-
}, At = ((e) => (e.PRE_EVENT = "PRE_EVENT", e.LIVE = "LIVE", e.ALL = "ALL", e))(At || {}), pt = ((e) => (e.ORDINARY_TIME = "ORDINARY_TIME", e.FULL_TIME = "FULL_TIME", e))(pt || {}), Dt = ((e) => (e.DECIMAL = "DECIMAL", e.MONEYLINE = "MONEYLINE", e.FRACTIONAL = "FRACTIONAL", e))(Dt || {}), vt = ((e) => (e.FT_1X2 = "FT_1X2", e.DOUBLE_CHANCE = "DOUBLE_CHANCE", e.HT_FT = "HT_FT", e.BOTH_TEAMS_SCORE = "BOTH_TEAMS_SCORE", e.CORRECT_SCORE = "CORRECT_SCORE", e.PLAYER_SCORE_FIRST_GOAL = "PLAYER_SCORE_FIRST_GOAL", e.PLAYER_SCORE = "PLAYER_SCORE", e.PLAYER_RED_CARD = "PLAYER_RED_CARD", e.PLAYER_YELLOW_CARD = "PLAYER_YELLOW_CARD", e.OVER_GOALS_0_5 = "OVER_GOALS_0_5", e.OVER_GOALS_1_5 = "OVER_GOALS_1_5", e.OVER_GOALS_2_5 = "OVER_GOALS_2_5", e.OVER_GOALS_3_5 = "OVER_GOALS_3_5", e.OVER_GOALS_4_5 = "OVER_GOALS_4_5", e.OVER_GOALS_5_5 = "OVER_GOALS_5_5", e))(vt || {}), si = class {
|
|
2435
|
-
constructor() {
|
|
2436
|
-
i(this, "gameInstanceId", null);
|
|
2437
|
-
i(this, "fixtures", null);
|
|
2438
|
-
}
|
|
2439
|
-
}, Lt = ((e) => (e.ACTIVE = "ACTIVE", e.WON = "WON", e.LOST = "LOST", e.PARTIALLY_WON = "PARTIALLY_WON", e.CANCELED = "CANCELED", e))(Lt || {}), Nt = class {
|
|
2440
|
-
constructor() {
|
|
2441
|
-
i(this, "id", null);
|
|
2442
|
-
i(this, "title", null);
|
|
2443
|
-
i(this, "description", null);
|
|
2444
|
-
i(this, "type", null);
|
|
2445
|
-
i(this, "status", null);
|
|
2446
|
-
i(this, "authRequirement", null);
|
|
2447
|
-
i(this, "scheduleOpenAt", null);
|
|
2448
|
-
i(this, "predictionsCutoff", null);
|
|
2449
|
-
i(this, "fixtures", []);
|
|
2450
|
-
i(this, "tiebreaker", new bt());
|
|
2451
|
-
i(this, "participantsCount", 0);
|
|
2452
|
-
i(this, "related", []);
|
|
2453
|
-
i(this, "excludedProfileIds", null);
|
|
2454
|
-
i(this, "rules", null);
|
|
2455
|
-
i(this, "labels", null);
|
|
2456
|
-
i(this, "customFields", null);
|
|
2457
|
-
i(this, "branding", null);
|
|
2458
|
-
i(this, "brandingId", null);
|
|
2459
|
-
i(this, "flags", null);
|
|
2460
|
-
i(this, "images", new Te());
|
|
2461
|
-
i(this, "createdAt", null);
|
|
2462
|
-
i(this, "updatedAt", null);
|
|
2463
|
-
}
|
|
2464
|
-
}, li = class extends Nt {
|
|
2465
|
-
constructor() {
|
|
2466
|
-
super(...arguments);
|
|
2467
|
-
i(this, "adContent", null);
|
|
2468
|
-
}
|
|
2469
|
-
}, wt = class {
|
|
2470
|
-
constructor() {
|
|
2471
|
-
i(this, "id", null);
|
|
2472
|
-
i(this, "title", null);
|
|
2473
|
-
i(this, "alternativeTitle", null);
|
|
2474
|
-
i(this, "description", null);
|
|
2475
|
-
i(this, "type", null);
|
|
2476
|
-
i(this, "images", new Te());
|
|
2477
|
-
i(this, "status", null);
|
|
2478
|
-
i(this, "language", null);
|
|
2479
|
-
i(this, "authRequirement", null);
|
|
2480
|
-
i(this, "totalVotes", null);
|
|
2481
|
-
i(this, "flags", []);
|
|
2482
|
-
i(this, "customFields", null);
|
|
2483
|
-
i(this, "branding", null);
|
|
2484
|
-
i(this, "brandingId", null);
|
|
2485
|
-
i(this, "embedCode", null);
|
|
2486
|
-
i(this, "labels", null);
|
|
2487
|
-
i(this, "adContent", null);
|
|
2488
|
-
i(this, "context", null);
|
|
2489
|
-
i(this, "options", []);
|
|
2490
|
-
i(this, "related", []);
|
|
2491
|
-
i(this, "preferencesEnabled", !1);
|
|
2492
|
-
i(this, "multipleChoice", !1);
|
|
2493
|
-
i(this, "maxMultipleChoiceOptions", null);
|
|
2494
|
-
i(this, "participationCount", 0);
|
|
2495
|
-
i(this, "maxAttempts", 0);
|
|
2496
|
-
i(this, "externalActivity", null);
|
|
2497
|
-
i(this, "createdAt", null);
|
|
2498
|
-
i(this, "updatedAt", null);
|
|
2499
|
-
}
|
|
2500
|
-
}, ci = class extends wt {
|
|
2501
|
-
constructor() {
|
|
2502
|
-
super(...arguments);
|
|
2503
|
-
i(this, "rules", null);
|
|
2504
|
-
}
|
|
2505
|
-
}, Pt = class {
|
|
2506
|
-
constructor() {
|
|
2507
|
-
i(this, "id", null);
|
|
2508
|
-
i(this, "pollId", null);
|
|
2509
|
-
i(this, "optionId", null);
|
|
2510
|
-
i(this, "optionIds", []);
|
|
2511
|
-
i(this, "userId", null);
|
|
2512
|
-
i(this, "createdAt", null);
|
|
2513
|
-
}
|
|
2514
|
-
}, di = class extends Pt {
|
|
2515
|
-
constructor() {
|
|
2516
|
-
super(...arguments);
|
|
2517
|
-
i(this, "previousVotes", []);
|
|
2518
|
-
i(this, "attempts", null);
|
|
2519
|
-
}
|
|
2520
|
-
}, Mt = ((e) => (e.LIKE = "like", e.DISLIKE = "dislike", e.SHARE = "share", e.COMMENT = "comment", e.PREDICTION_MADE = "prediction_made", e))(Mt || {}), kt = ((e) => (e.CORRECT = "CORRECT", e.INCORRECT = "INCORRECT", e.PARTIALLY_CORRECT = "PARTIALLY_CORRECT", e.NOT_VERIFIED = "NOT_VERIFIED", e))(kt || {}), Ft = ((e) => (e.ONE = "1", e.X = "x", e.TWO = "2", e))(Ft || {}), Vt = ((e) => (e.ONE_X = "1x", e.X_TWO = "x2", e.ONE_TWO = "12", e))(Vt || {}), Gt = ((e) => (e.ONE_ONE = "1/1", e.ONE_X = "1/x", e.ONE_TWO = "1/2", e.X_ONE = "x/1", e.X_X = "x/x", e.X_TWO = "x/2", e.TWO_ONE = "2/1", e.TWO_X = "2/x", e.TWO_TWO = "2/2", e))(Gt || {}), Ht = ((e) => (e.NONE = "none", e.FINISHED = "finished", e.CANCELLED = "cancelled", e.POSTPONED = "postponed", e.NOT_STARTED = "not_started", e.FIRST_HALF = "1st_half", e.SECOND_HALF = "2nd_half", e.FINISHED_AFTER_AWARDED_WIN = "finished_after_awarded_win", e.TO_FINISH = "to_finish", e.FINISHED_AET = "finished_aet", e.HALFTIME = "halftime", e.FINISHED_AP = "finished_ap", e.INTERRUPTED = "interrupted", e.KICK_OFF_DELAYED = "kick_off_delayed", e.ABANDONED = "abandoned", e.WAITING_FOR_PENALTY = "waiting_for_penalty", e.PENALTY = "penalty", e.PAUSE = "pause", e.EXTRA_TIME_1ST_HALF = "extra_time_1st_half", e.EXTRA_TIME_END_OF_1ST_HALF = "extra_time_end_of_1st_half", e.EXTRA_TIME_2ND_HALF = "extra_time_2nd_half", e.WAITING_FOR_EXTRA_TIME = "waiting_for_extra_time", e.NO_INFO_YET = "no_info_yet", e.AWAITING_INFO = "awaiting_info", e.FINISHED_ASG = "finished_asg", e))(Ht || {}), ye = class {
|
|
2521
|
-
constructor() {
|
|
2522
|
-
}
|
|
2523
|
-
static createMatchMarketsResultsModel(e, t) {
|
|
2524
|
-
var a, r, l, f, _, s, E, o, u, g, S, y, T, O, D, C, A, P, v, w, n, h, d, x, I, R, N, M, G, F, Y, H, z, K, X, re;
|
|
2525
|
-
return { FT_1X2: this.createOneXTwoResult(e.scores, "full_time"), HT_1X2: this.createOneXTwoResult(e.scores, "half_time"), BOTH_TEAMS_SCORE: e.scores.ftScore.homeGoals > 0 && e.scores.ftScore.awayGoals > 0, DOUBLE_CHANCE: this.createDoubleChanceResult(e.scores), HT_FT: this.createHalfTimeFullTimeResult(e.scores), RED_CARD_MATCH: this.createMarketResultByCriteria(e, "red_card"), PENALTY_MATCH: this.createMarketResultByCriteria(e, "penalty"), CORNERS_MATCH: isNaN(((r = (a = e.stats) == null ? void 0 : a.corners) == null ? void 0 : r.homeTeam) + ((f = (l = e.stats) == null ? void 0 : l.corners) == null ? void 0 : f.awayTeam)) ? null : e.stats.corners.homeTeam + e.stats.corners.awayTeam, PLAYER_YELLOW_CARD: this.createPlayersMarketsResults(e, t, "yellow_card"), PLAYER_RED_CARD: this.createPlayersMarketsResults(e, t, "red_card"), PLAYER_SCORE_FIRST_GOAL: this.createPlayersMarketsResults(e, t, "first_goal"), PLAYER_SCORE: this.createPlayersMarketsResults(e, t, "one_goal"), PLAYER_SCORE_TWICE: this.createPlayersMarketsResults(e, t, "two_goals"), PLAYER_SCORE_HATTRICK: this.createPlayersMarketsResults(e, t, "hattrick"), CORRECT_SCORE: { homeGoals: e.scores.ftScore.homeGoals, awayGoals: e.scores.ftScore.awayGoals }, CORRECT_SCORE_ADVANCED: { homeGoals: e.scores.ftScore.homeGoals, awayGoals: e.scores.ftScore.awayGoals }, CORRECT_SCORE_HT: { homeGoals: e.scores.htScore.homeGoals, awayGoals: e.scores.htScore.awayGoals }, OVER_GOALS_0_5: e.scores.ftScore.homeGoals + e.scores.ftScore.awayGoals > 0, OVER_GOALS_1_5: e.scores.ftScore.homeGoals + e.scores.ftScore.awayGoals > 1, OVER_GOALS_2_5: e.scores.ftScore.homeGoals + e.scores.ftScore.awayGoals > 2, OVER_GOALS_3_5: e.scores.ftScore.homeGoals + e.scores.ftScore.awayGoals > 3, OVER_GOALS_4_5: e.scores.ftScore.homeGoals + e.scores.ftScore.awayGoals > 4, OVER_GOALS_5_5: e.scores.ftScore.homeGoals + e.scores.ftScore.awayGoals > 5, OVER_GOALS_6_5: e.scores.ftScore.homeGoals + e.scores.ftScore.awayGoals > 6, OVER_CORNERS_6_5: isNaN(((s = (_ = e.stats) == null ? void 0 : _.corners) == null ? void 0 : s.homeTeam) + ((o = (E = e.stats) == null ? void 0 : E.corners) == null ? void 0 : o.awayTeam)) ? null : e.stats.corners.homeTeam + e.stats.corners.awayTeam > 6, OVER_CORNERS_7_5: isNaN(((g = (u = e.stats) == null ? void 0 : u.corners) == null ? void 0 : g.homeTeam) + ((y = (S = e.stats) == null ? void 0 : S.corners) == null ? void 0 : y.awayTeam)) ? null : e.stats.corners.homeTeam + e.stats.corners.awayTeam > 7, OVER_CORNERS_8_5: isNaN(((O = (T = e.stats) == null ? void 0 : T.corners) == null ? void 0 : O.homeTeam) + ((C = (D = e.stats) == null ? void 0 : D.corners) == null ? void 0 : C.awayTeam)) ? null : e.stats.corners.homeTeam + e.stats.corners.awayTeam > 8, OVER_CORNERS_9_5: isNaN(((P = (A = e.stats) == null ? void 0 : A.corners) == null ? void 0 : P.homeTeam) + ((w = (v = e.stats) == null ? void 0 : v.corners) == null ? void 0 : w.awayTeam)) ? null : e.stats.corners.homeTeam + e.stats.corners.awayTeam > 9, OVER_CORNERS_10_5: isNaN(((h = (n = e.stats) == null ? void 0 : n.corners) == null ? void 0 : h.homeTeam) + ((x = (d = e.stats) == null ? void 0 : d.corners) == null ? void 0 : x.awayTeam)) ? null : e.stats.corners.homeTeam + e.stats.corners.awayTeam > 10, OVER_CORNERS_11_5: isNaN(((R = (I = e.stats) == null ? void 0 : I.corners) == null ? void 0 : R.homeTeam) + ((M = (N = e.stats) == null ? void 0 : N.corners) == null ? void 0 : M.awayTeam)) ? null : e.stats.corners.homeTeam + e.stats.corners.awayTeam > 11, OVER_CORNERS_12_5: isNaN(((F = (G = e.stats) == null ? void 0 : G.corners) == null ? void 0 : F.homeTeam) + ((H = (Y = e.stats) == null ? void 0 : Y.corners) == null ? void 0 : H.awayTeam)) ? null : e.stats.corners.homeTeam + e.stats.corners.awayTeam > 12, OVER_CORNERS_13_5: isNaN(((K = (z = e.stats) == null ? void 0 : z.corners) == null ? void 0 : K.homeTeam) + ((re = (X = e.stats) == null ? void 0 : X.corners) == null ? void 0 : re.awayTeam)) ? null : e.stats.corners.homeTeam + e.stats.corners.awayTeam > 13 };
|
|
2526
|
-
}
|
|
2527
|
-
}, J = ye;
|
|
2528
|
-
B(J, "createOneXTwoResult", (e, t) => {
|
|
2529
|
-
var a, r, l, f;
|
|
2530
|
-
return t === "full_time" ? e.ftScore.homeGoals > e.ftScore.awayGoals ? "1" : e.ftScore.homeGoals === e.ftScore.awayGoals ? "x" : "2" : ((a = e == null ? void 0 : e.htScore) == null ? void 0 : a.homeGoals) > ((r = e == null ? void 0 : e.htScore) == null ? void 0 : r.awayGoals) ? "1" : ((l = e == null ? void 0 : e.htScore) == null ? void 0 : l.homeGoals) === ((f = e == null ? void 0 : e.htScore) == null ? void 0 : f.awayGoals) ? "x" : "2";
|
|
2531
|
-
}), B(J, "createDoubleChanceResult", (e) => {
|
|
2532
|
-
var t, a, r, l;
|
|
2533
|
-
return ((t = e == null ? void 0 : e.ftScore) == null ? void 0 : t.homeGoals) > ((a = e == null ? void 0 : e.ftScore) == null ? void 0 : a.awayGoals) ? ["1x", "12"] : ((r = e == null ? void 0 : e.ftScore) == null ? void 0 : r.homeGoals) === ((l = e == null ? void 0 : e.ftScore) == null ? void 0 : l.awayGoals) ? ["1x", "x2"] : ["x2", "12"];
|
|
2534
|
-
}), B(J, "createHalfTimeFullTimeResult", (e) => {
|
|
2535
|
-
var t, a, r, l, f, _, s, E, o, u, g, S, y, T, O, D, C, A, P, v, w, n, h, d;
|
|
2536
|
-
if (((t = e == null ? void 0 : e.htScore) == null ? void 0 : t.homeGoals) > ((a = e == null ? void 0 : e.htScore) == null ? void 0 : a.awayGoals)) {
|
|
2537
|
-
if (((r = e == null ? void 0 : e.ftScore) == null ? void 0 : r.homeGoals) > ((l = e == null ? void 0 : e.ftScore) == null ? void 0 : l.awayGoals)) return "1/1";
|
|
2538
|
-
if (((f = e == null ? void 0 : e.ftScore) == null ? void 0 : f.homeGoals) === ((_ = e == null ? void 0 : e.ftScore) == null ? void 0 : _.awayGoals)) return "1/x";
|
|
2539
|
-
if (((s = e == null ? void 0 : e.ftScore) == null ? void 0 : s.homeGoals) < ((E = e == null ? void 0 : e.ftScore) == null ? void 0 : E.awayGoals)) return "1/2";
|
|
2540
|
-
}
|
|
2541
|
-
if (((o = e == null ? void 0 : e.htScore) == null ? void 0 : o.homeGoals) === ((u = e == null ? void 0 : e.htScore) == null ? void 0 : u.awayGoals)) {
|
|
2542
|
-
if (((g = e == null ? void 0 : e.ftScore) == null ? void 0 : g.homeGoals) > ((S = e == null ? void 0 : e.ftScore) == null ? void 0 : S.awayGoals)) return "x/1";
|
|
2543
|
-
if (((y = e == null ? void 0 : e.ftScore) == null ? void 0 : y.homeGoals) === ((T = e == null ? void 0 : e.ftScore) == null ? void 0 : T.awayGoals)) return "x/x";
|
|
2544
|
-
if (((O = e == null ? void 0 : e.ftScore) == null ? void 0 : O.homeGoals) < ((D = e == null ? void 0 : e.ftScore) == null ? void 0 : D.awayGoals)) return "x/2";
|
|
2545
|
-
}
|
|
2546
|
-
if (((C = e == null ? void 0 : e.htScore) == null ? void 0 : C.homeGoals) < ((A = e == null ? void 0 : e.htScore) == null ? void 0 : A.awayGoals)) {
|
|
2547
|
-
if (((P = e == null ? void 0 : e.ftScore) == null ? void 0 : P.homeGoals) > ((v = e == null ? void 0 : e.ftScore) == null ? void 0 : v.awayGoals)) return "2/1";
|
|
2548
|
-
if (((w = e == null ? void 0 : e.ftScore) == null ? void 0 : w.homeGoals) === ((n = e == null ? void 0 : e.ftScore) == null ? void 0 : n.awayGoals)) return "2/x";
|
|
2549
|
-
if (((h = e == null ? void 0 : e.ftScore) == null ? void 0 : h.homeGoals) < ((d = e == null ? void 0 : e.ftScore) == null ? void 0 : d.awayGoals)) return "2/2";
|
|
2550
|
-
}
|
|
2551
|
-
}), B(J, "createMarketResultByCriteria", (e, t) => !e.timeline || !e.timeline.length ? null : t === "red_card" ? e.timeline.filter((a) => Number(a.minute) <= 90).some((a) => a.type === "red_card") : e.timeline.filter((a) => Number(a.minute) <= 90).some((a) => a.type.startsWith(t))), B(J, "createPlayersMarketsResults", (e, t, a) => {
|
|
2552
|
-
if (!e.timeline || !e.timeline.length) return a === "first_goal" ? null : [];
|
|
2553
|
-
if (a === "first_goal") {
|
|
2554
|
-
let _ = e.timeline.find((s) => s.type === "goal" || s.type === "penalty_goal" || s.type === "own_goal") || null;
|
|
2555
|
-
if (_) {
|
|
2556
|
-
let s = t[_.player.id];
|
|
2557
|
-
return { playerId: _.type === "goal" || _.type === "penalty_goal" ? _.player.id : "OWN_GOAL", playerModel: s };
|
|
2558
|
-
}
|
|
2559
|
-
return null;
|
|
2560
|
-
}
|
|
2561
|
-
if (a === "yellow_card" || a === "red_card") return ye.transformPlayerMarketResult(e.timeline.filter((_) => Number(_.minute) <= 90).filter((_) => _.type === a).map((_) => t[_.player.id]));
|
|
2562
|
-
let r = /* @__PURE__ */ new Map(), l = a === "one_goal" ? 1 : a === "two_goals" ? 2 : 3, f = [];
|
|
2563
|
-
return e.timeline.filter((_) => Number(_.minute) <= 90).filter((_) => _.type === "goal" || _.type === "penalty_goal").forEach((_) => {
|
|
2564
|
-
let s = t[_.player.id];
|
|
2565
|
-
if (r.has(_.player.id)) {
|
|
2566
|
-
let E = r.get(_.player.id);
|
|
2567
|
-
E.push(s), r.set(_.player.id, E);
|
|
2568
|
-
} else r.set(_.player.id, [s]);
|
|
2569
|
-
}), r.forEach((_) => {
|
|
2570
|
-
_.length >= l && f.push(_[0]);
|
|
2571
|
-
}), ye.transformPlayerMarketResult(f);
|
|
2572
|
-
}), B(J, "transformPlayerMarketResult", (e) => e.map((t) => ({ playerId: t.id, playerModel: t })));
|
|
2573
|
-
(/* @__PURE__ */ new Map()).set("minutesPlayed", "Minutes Played").set("cleanSheets", "Clean Sheets").set("concededGoals", "Goals Conceded").set("saves", "Saves").set("penaltySaved", "Penalties Saved").set("penaltyCommitted", "Penalties Committed").set("yellowCards", "Yellow Cards").set("redCards", "Red Cards").set("assists", "Assists").set("foulsCommitted", "Fouls Committed").set("ownGoals", "Own Goals").set("goals", "Goals").set("tackles", "Tackles").set("shotsOn", "Shots On Target").set("penaltyGoals", "Penalty Goals").set("penaltyWon", "Penalty Won").set("penaltyMissed", "Penalty Missed").set("penaltySaved", "Penalty Saved").set("penaltyReceived", "Penalty Received").set("shots", "Shots").set("shotsBlocked", "Shots Blocked").set("offsides", "Offsides").set("foulsWon", "Fouls Won").set("tacklesBlocks", "Tackles Blocks").set("tacklesInterceptions", "Tackles Interceptions").set("caughtBall", "Caught Ball").set("passes", "Passes").set("crosses", "Crosses").set("interceptions", "Interceptions").set("keyPasses", "Key Passes").set("passesAccuracy", "Passes Accuracy").set("duels", "Duels").set("duelsWon", "Duels Won").set("dribblesAttempts", "Dribbles Attempts").set("dribblesSuccess", "Dribbles Success").set("dribblesPast", "Dribbles Past");
|
|
2574
|
-
const ui = ({
|
|
2575
|
-
infoPage: e,
|
|
2576
|
-
variant: t,
|
|
2577
|
-
forceMobile: a
|
|
2578
|
-
}) => {
|
|
2579
|
-
switch (t) {
|
|
2580
|
-
case ue.PENALTY_SHOOTOUT:
|
|
2581
|
-
return /* @__PURE__ */ c(Be, { infoPage: e, forceMobile: a });
|
|
2582
|
-
case ue.PICK_ONE_OF_X:
|
|
2583
|
-
return /* @__PURE__ */ c(He, { infoPage: e, forceMobile: a });
|
|
2584
|
-
case ue.PRIZE_WHEEL:
|
|
2585
|
-
default:
|
|
2586
|
-
return /* @__PURE__ */ c(Ge, { infoPage: e, forceMobile: a });
|
|
2587
|
-
}
|
|
2588
|
-
};
|
|
2589
|
-
export {
|
|
2590
|
-
$t as A,
|
|
2591
|
-
ii as C,
|
|
2592
|
-
oi as H,
|
|
2593
|
-
ai as L,
|
|
2594
|
-
di as M,
|
|
2595
|
-
ti as O,
|
|
2596
|
-
Ee as R,
|
|
2597
|
-
Jt as S,
|
|
2598
|
-
Qt as a,
|
|
2599
|
-
ei as b,
|
|
2600
|
-
Zt as c,
|
|
2601
|
-
ui as d,
|
|
2602
|
-
Ct as e,
|
|
2603
|
-
ni as f,
|
|
2604
|
-
ci as g,
|
|
2605
|
-
ri as h,
|
|
2606
|
-
li as i,
|
|
2607
|
-
si as j,
|
|
2608
|
-
ht as n
|
|
2609
|
-
};
|