@streamlayer/react 1.9.4 → 1.9.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,12 +1,12 @@
1
- import { jsx as e, jsxs as v, Fragment as co } from "react/jsx-runtime";
2
- import { useRef as F, useState as R, useCallback as Eo, useEffect as P } from "react";
3
- import { e as k, s as n, h as ko, g as po, i as D, Y as Lo, a as mo, L as Mo, u as Po, j as Oo, b as _o, S as T, d as Bo } from "./index2.js";
4
- import { N, a as uo, b as vo, C as Ao, c as go, P as M, d as S, A as xo, e as Ro, S as Do } from "./useStreamLayerApp2.js";
5
- const qo = /* @__PURE__ */ n("div")({
1
+ import { jsx as e, jsxs as v, Fragment as po } from "react/jsx-runtime";
2
+ import { useRef as F, useState as R, useCallback as ko, useEffect as M } from "react";
3
+ import { e as k, s as n, h as Po, g as mo, i as D, Y as Lo, a as uo, L as Mo, u as Oo, j as _o, b as Bo, S as T, d as xo } from "./index2.js";
4
+ import { N, a as vo, b as Ao, C as go, c as ho, P as L, d as S, A as Ro, e as Do, S as qo } from "./useStreamLayerApp2.js";
5
+ const wo = /* @__PURE__ */ n("div")({
6
6
  name: "Container",
7
7
  class: "c5b6wdg",
8
8
  propsAsIs: !1
9
- }), wo = "a1rlj479", Vo = "s35f1di", jo = "sj4471g", Uo = "b12050d8", Fo = "b1d5ybek", zo = (o) => o === "left" || o === "right" ? Vo : Uo, Go = (o) => o === "left" || o === "right" ? jo : Fo, Wo = (o) => o === "left" ? "avdxyl3" : o === "right" ? "a1bisd08" : o === "top" ? "a1u9y2aj" : "a1qqaks", z = ({
9
+ }), Vo = "a1rlj479", jo = "s35f1di", Uo = "sj4471g", Fo = "b12050d8", zo = "b1d5ybek", Go = (o) => o === "left" || o === "right" ? jo : Fo, Wo = (o) => o === "left" || o === "right" ? Uo : zo, Ho = (o) => o === "left" ? "avdxyl3" : o === "right" ? "a1bisd08" : o === "top" ? "a1u9y2aj" : "a1qqaks", z = ({
10
10
  children: o,
11
11
  style: s,
12
12
  className: i,
@@ -14,30 +14,30 @@ const qo = /* @__PURE__ */ n("div")({
14
14
  hiding: l,
15
15
  direction: r = "left",
16
16
  onAnimationEnd: c
17
- }) => /* @__PURE__ */ e(qo, {
17
+ }) => /* @__PURE__ */ e(wo, {
18
18
  style: s,
19
- className: k(i, wo, Wo(r), t && !l && zo(r), t && l && Go(r)),
19
+ className: k(i, Vo, Ho(r), t && !l && Go(r), t && l && Wo(r)),
20
20
  onAnimationEnd: c,
21
21
  children: o
22
- }), Ho = /* @__PURE__ */ n("a")({
22
+ }), Ko = /* @__PURE__ */ n("a")({
23
23
  name: "Link",
24
24
  class: "l1sgte8c",
25
25
  propsAsIs: !1
26
- }), Ko = /* @__PURE__ */ n("div")({
26
+ }), Yo = /* @__PURE__ */ n("div")({
27
27
  name: "BannerContainer",
28
28
  class: "b7yfc72",
29
29
  propsAsIs: !1
30
- }), Yo = () => Ho, Jo = /* @__PURE__ */ n(Yo())({
30
+ }), Jo = () => Ko, Zo = /* @__PURE__ */ n(Jo())({
31
31
  name: "BannerLink",
32
32
  class: "bejjq94",
33
33
  propsAsIs: !0
34
- }), Xo = ({ promotion: o, promotionId: s, hiding: i, direction: t = "bottom" }) => {
34
+ }), Qo = ({ promotion: o, promotionId: s, hiding: i, direction: t = "bottom" }) => {
35
35
  var l, r;
36
36
  if (!((l = o.additionalBanner) != null && l.imageUrl))
37
37
  return null;
38
38
  let c = (r = o.additionalBanner) == null ? void 0 : r.url;
39
- return c && c.indexOf("http") !== 0 && (c = `https://${c}`), /* @__PURE__ */ e(z, { direction: t, hiding: i, children: /* @__PURE__ */ e(Ko, { className: "BannerContainer", children: /* @__PURE__ */ e(
40
- Jo,
39
+ return c && c.indexOf("http") !== 0 && (c = `https://${c}`), /* @__PURE__ */ e(z, { direction: t, hiding: i, children: /* @__PURE__ */ e(Yo, { className: "BannerContainer", children: /* @__PURE__ */ e(
40
+ Zo,
41
41
  {
42
42
  as: c ? "a" : "span",
43
43
  className: "BannerLink",
@@ -52,19 +52,19 @@ const qo = /* @__PURE__ */ n("div")({
52
52
  target: "_blank"
53
53
  }
54
54
  ) }) });
55
- }, Zo = /* @__PURE__ */ n("div")({
55
+ }, Xo = /* @__PURE__ */ n("div")({
56
56
  name: "NotificationContent",
57
57
  class: "n18wsqoo",
58
58
  propsAsIs: !1
59
- }), Qo = /* @__PURE__ */ n("div")({
59
+ }), oe = /* @__PURE__ */ n("div")({
60
60
  name: "Body",
61
61
  class: "b1ia90c2",
62
62
  propsAsIs: !1
63
- }), oe = /* @__PURE__ */ n("div")({
63
+ }), ee = /* @__PURE__ */ n("div")({
64
64
  name: "Title",
65
65
  class: "tg2z08v",
66
66
  propsAsIs: !1
67
- }), ee = /* @__PURE__ */ n("div")({
67
+ }), ne = /* @__PURE__ */ n("div")({
68
68
  name: "Text",
69
69
  class: "t59zdk1",
70
70
  propsAsIs: !1
@@ -72,80 +72,80 @@ const qo = /* @__PURE__ */ n("div")({
72
72
  name: "MediaImgBottom",
73
73
  class: "m1ab9fq",
74
74
  propsAsIs: !1
75
- }), ne = () => G, se = /* @__PURE__ */ n(ne())({
75
+ }), se = () => G, te = /* @__PURE__ */ n(se())({
76
76
  name: "MediaImgMiddle",
77
77
  class: "m9fsr0y",
78
78
  propsAsIs: !0
79
- }), te = /* @__PURE__ */ n("img")({
79
+ }), ie = /* @__PURE__ */ n("img")({
80
80
  name: "CtaIcon",
81
81
  class: "cvi9y5q",
82
82
  propsAsIs: !1
83
- }), ie = /* @__PURE__ */ n("button")({
83
+ }), ae = /* @__PURE__ */ n("button")({
84
84
  name: "Button",
85
85
  class: "bgl6boa",
86
86
  propsAsIs: !1
87
- }), ae = /* @__PURE__ */ n("div")({
87
+ }), re = /* @__PURE__ */ n("div")({
88
88
  name: "Logo",
89
89
  class: "l5mq0z",
90
90
  propsAsIs: !1
91
- }), re = /* @__PURE__ */ n("div")({
91
+ }), le = /* @__PURE__ */ n("div")({
92
92
  name: "Footer",
93
93
  class: "f1mse0ft",
94
94
  propsAsIs: !1
95
- }), le = /* @__PURE__ */ n("div")({
95
+ }), de = /* @__PURE__ */ n("div")({
96
96
  name: "Vector",
97
97
  class: "v1hcloah",
98
98
  propsAsIs: !1
99
- }), de = /* @__PURE__ */ n("div")({
99
+ }), ce = /* @__PURE__ */ n("div")({
100
100
  name: "NotificationContainer",
101
101
  class: "n3n65jf",
102
102
  propsAsIs: !1
103
- }), ce = {
103
+ }), pe = {
104
104
  [N.BOTTOM]: G,
105
- [N.MIDDLE]: se
106
- }, pe = ({ src: o, imagePosition: s }) => {
107
- const i = ce[s] || G;
105
+ [N.MIDDLE]: te
106
+ }, me = ({ src: o, imagePosition: s }) => {
107
+ const i = pe[s] || G;
108
108
  return /* @__PURE__ */ e(i, { children: /* @__PURE__ */ e("img", { src: o, alt: "" }) });
109
- }, me = ({ notification: o, open: s }) => {
110
- if (!o || !o.promotion || o.enabled !== uo.NOTIFICATION_ENABLED)
109
+ }, ue = ({ notification: o, open: s }) => {
110
+ if (!o || !o.promotion || o.enabled !== vo.NOTIFICATION_ENABLED)
111
111
  return null;
112
112
  const { title: i, body: t, image: l, promotion: r } = o, { sponsorLogo: c, sponsorLogoMode: m, imagePosition: A, ctaButton: a } = r;
113
- return /* @__PURE__ */ v(de, { className: "SL_Lower_Third_Notification", onClick: s, children: [
114
- /* @__PURE__ */ v(Zo, { children: [
115
- /* @__PURE__ */ e(pe, { src: l, imagePosition: A }),
116
- /* @__PURE__ */ v(Qo, { children: [
117
- i && /* @__PURE__ */ e(oe, { children: i }),
118
- t && /* @__PURE__ */ e(ee, { children: t })
113
+ return /* @__PURE__ */ v(ce, { className: "SL_Lower_Third_Notification", onClick: s, children: [
114
+ /* @__PURE__ */ v(Xo, { children: [
115
+ /* @__PURE__ */ e(me, { src: l, imagePosition: A }),
116
+ /* @__PURE__ */ v(oe, { children: [
117
+ i && /* @__PURE__ */ e(ee, { children: i }),
118
+ t && /* @__PURE__ */ e(ne, { children: t })
119
119
  ] })
120
120
  ] }),
121
- /* @__PURE__ */ v(re, { children: [
122
- m !== vo.NOTIFICATION_SPONSOR_LOGO_NONE && /* @__PURE__ */ v(co, { children: [
123
- /* @__PURE__ */ e(ae, { children: /* @__PURE__ */ e("img", { src: c, alt: i }) }),
124
- /* @__PURE__ */ e(le, {})
121
+ /* @__PURE__ */ v(le, { children: [
122
+ m !== Ao.NOTIFICATION_SPONSOR_LOGO_NONE && /* @__PURE__ */ v(po, { children: [
123
+ /* @__PURE__ */ e(re, { children: /* @__PURE__ */ e("img", { src: c, alt: i }) }),
124
+ /* @__PURE__ */ e(de, {})
125
125
  ] }),
126
- /* @__PURE__ */ v(ie, { name: "promo-button", style: { color: a == null ? void 0 : a.textColor, backgroundColor: a == null ? void 0 : a.color }, children: [
127
- (a == null ? void 0 : a.ctaIcon) && (a == null ? void 0 : a.ctaIconMode) === Ao.CTA_ICON_TRANSPARENT && /* @__PURE__ */ e(te, { src: a == null ? void 0 : a.ctaIcon, alt: "cta-icon" }),
126
+ /* @__PURE__ */ v(ae, { name: "promo-button", style: { color: a == null ? void 0 : a.textColor, backgroundColor: a == null ? void 0 : a.color }, children: [
127
+ (a == null ? void 0 : a.ctaIcon) && (a == null ? void 0 : a.ctaIconMode) === go.CTA_ICON_TRANSPARENT && /* @__PURE__ */ e(ie, { src: a == null ? void 0 : a.ctaIcon, alt: "cta-icon" }),
128
128
  (a == null ? void 0 : a.label) || "Open"
129
129
  ] })
130
130
  ] })
131
131
  ] });
132
- }, ue = /* @__PURE__ */ n("div")({
132
+ }, ve = /* @__PURE__ */ n("div")({
133
133
  name: "NotificationContent",
134
134
  class: "n1ku6hz",
135
135
  propsAsIs: !1
136
- }), ve = /* @__PURE__ */ n("div")({
136
+ }), Ae = /* @__PURE__ */ n("div")({
137
137
  name: "NotificationContainer",
138
138
  class: "nbxqmol",
139
139
  propsAsIs: !1
140
- }), Ae = /* @__PURE__ */ n("div")({
140
+ }), ge = /* @__PURE__ */ n("div")({
141
141
  name: "Body",
142
142
  class: "b1gu3eml",
143
143
  propsAsIs: !1
144
- }), ge = /* @__PURE__ */ n("div")({
144
+ }), he = /* @__PURE__ */ n("div")({
145
145
  name: "Title",
146
146
  class: "t1u17zva",
147
147
  propsAsIs: !1
148
- }), he = /* @__PURE__ */ n("div")({
148
+ }), Ie = /* @__PURE__ */ n("div")({
149
149
  name: "Text",
150
150
  class: "t10ko1g",
151
151
  propsAsIs: !1
@@ -153,35 +153,35 @@ const qo = /* @__PURE__ */ n("div")({
153
153
  name: "Media",
154
154
  class: "mntc42e",
155
155
  propsAsIs: !1
156
- }), Ie = () => q, to = /* @__PURE__ */ n(Ie())({
156
+ }), ye = () => q, io = /* @__PURE__ */ n(ye())({
157
157
  name: "MediaImgFit",
158
158
  class: "ml060eo",
159
159
  propsAsIs: !0
160
- }), ye = () => q, ho = /* @__PURE__ */ n(ye())({
160
+ }), be = () => q, Io = /* @__PURE__ */ n(be())({
161
161
  name: "MediaImgCentered",
162
162
  class: "m1vqlvig",
163
163
  propsAsIs: !0
164
- }), be = () => ho, fe = /* @__PURE__ */ n(be())({
164
+ }), fe = () => Io, Ne = /* @__PURE__ */ n(fe())({
165
165
  name: "MediaImgBottom",
166
166
  class: "m1e7tvi5",
167
167
  propsAsIs: !0
168
- }), Ne = () => q, $e = /* @__PURE__ */ n(Ne())({
168
+ }), $e = () => q, Ce = /* @__PURE__ */ n($e())({
169
169
  name: "MediaImgSolid",
170
170
  class: "mqvntt2",
171
171
  propsAsIs: !0
172
- }), Ce = () => q, Te = /* @__PURE__ */ n(Ce())({
172
+ }), Te = () => q, Se = /* @__PURE__ */ n(Te())({
173
173
  name: "MediaImgMiddle",
174
174
  class: "m12jtj3u",
175
175
  propsAsIs: !0
176
- }), Se = /* @__PURE__ */ n("img")({
176
+ }), Ee = /* @__PURE__ */ n("img")({
177
177
  name: "CtaIcon",
178
178
  class: "ckq1frv",
179
179
  propsAsIs: !1
180
- }), Ee = /* @__PURE__ */ n("button")({
180
+ }), ke = /* @__PURE__ */ n("button")({
181
181
  name: "Button",
182
182
  class: "bis90pl",
183
183
  propsAsIs: !1
184
- }), ke = () => ko, Le = /* @__PURE__ */ n(ke())({
184
+ }), Pe = () => Po, Le = /* @__PURE__ */ n(Pe())({
185
185
  name: "StyledChevronRight",
186
186
  class: "s9mjmz3",
187
187
  propsAsIs: !0
@@ -189,133 +189,133 @@ const qo = /* @__PURE__ */ n("div")({
189
189
  name: "Logo",
190
190
  class: "l1cf50a7",
191
191
  propsAsIs: !1
192
- }), Pe = {
193
- [N.UNSET]: to,
194
- [N.FIT]: to,
195
- [N.CENTERED]: ho,
196
- [N.BOTTOM]: fe,
197
- [N.SOLID]: $e,
198
- [N.MIDDLE]: Te
199
- }, Oe = ({ src: o, imagePosition: s }) => {
200
- const i = Pe[s];
192
+ }), Oe = {
193
+ [N.UNSET]: io,
194
+ [N.FIT]: io,
195
+ [N.CENTERED]: Io,
196
+ [N.BOTTOM]: Ne,
197
+ [N.SOLID]: Ce,
198
+ [N.MIDDLE]: Se
199
+ }, _e = ({ src: o, imagePosition: s }) => {
200
+ const i = Oe[s];
201
201
  return /* @__PURE__ */ e(i, { children: /* @__PURE__ */ e("img", { src: o, alt: "" }) });
202
- }, _e = ({ notification: o, open: s, promotionId: i, hiding: t, direction: l = "left" }) => {
203
- if (!o || !o.promotion || o.enabled !== uo.NOTIFICATION_ENABLED)
202
+ }, Be = ({ notification: o, open: s, promotionId: i, hiding: t, direction: l = "left" }) => {
203
+ if (!o || !o.promotion || o.enabled !== vo.NOTIFICATION_ENABLED)
204
204
  return null;
205
- if (o.promotion.mode === go.LOWER_THIRD)
206
- return /* @__PURE__ */ e(me, { notification: o, open: s });
205
+ if (o.promotion.mode === ho.LOWER_THIRD)
206
+ return /* @__PURE__ */ e(ue, { notification: o, open: s });
207
207
  const { title: r, body: c, image: m, promotion: A } = o, { sponsorLogo: a, sponsorLogoMode: g, imagePosition: u, ctaButton: p } = A;
208
- return /* @__PURE__ */ e(z, { className: "SL_Rich_Notification", direction: l, hiding: t, children: /* @__PURE__ */ v(ve, { onClick: s, children: [
209
- g !== vo.NOTIFICATION_SPONSOR_LOGO_NONE && /* @__PURE__ */ e(Me, { children: /* @__PURE__ */ e("img", { src: a, alt: r }) }),
210
- /* @__PURE__ */ v(ue, { children: [
211
- /* @__PURE__ */ e(Oe, { src: m, imagePosition: u }),
212
- /* @__PURE__ */ v(Ae, { children: [
213
- r && /* @__PURE__ */ e(ge, { children: r }),
214
- c && /* @__PURE__ */ e(he, { children: c })
208
+ return /* @__PURE__ */ e(z, { className: "SL_Rich_Notification", direction: l, hiding: t, children: /* @__PURE__ */ v(Ae, { onClick: s, children: [
209
+ g !== Ao.NOTIFICATION_SPONSOR_LOGO_NONE && /* @__PURE__ */ e(Me, { children: /* @__PURE__ */ e("img", { src: a, alt: r }) }),
210
+ /* @__PURE__ */ v(ve, { children: [
211
+ /* @__PURE__ */ e(_e, { src: m, imagePosition: u }),
212
+ /* @__PURE__ */ v(ge, { children: [
213
+ r && /* @__PURE__ */ e(he, { children: r }),
214
+ c && /* @__PURE__ */ e(Ie, { children: c })
215
215
  ] }),
216
- /* @__PURE__ */ v(Ee, { name: "promo-button", style: { color: p == null ? void 0 : p.textColor, backgroundColor: p == null ? void 0 : p.color }, children: [
217
- (p == null ? void 0 : p.ctaIcon) && (p == null ? void 0 : p.ctaIconMode) === Ao.CTA_ICON_TRANSPARENT && /* @__PURE__ */ e(Se, { src: p == null ? void 0 : p.ctaIcon, alt: "cta-icon" }),
216
+ /* @__PURE__ */ v(ke, { name: "promo-button", style: { color: p == null ? void 0 : p.textColor, backgroundColor: p == null ? void 0 : p.color }, children: [
217
+ (p == null ? void 0 : p.ctaIcon) && (p == null ? void 0 : p.ctaIconMode) === go.CTA_ICON_TRANSPARENT && /* @__PURE__ */ e(Ee, { src: p == null ? void 0 : p.ctaIcon, alt: "cta-icon" }),
218
218
  (p == null ? void 0 : p.label) || "Open"
219
219
  ] }),
220
220
  /* @__PURE__ */ e(Le, { name: "chevronRight" })
221
221
  ] })
222
222
  ] }) });
223
- }, Be = /* @__PURE__ */ n("div")({
223
+ }, xe = /* @__PURE__ */ n("div")({
224
224
  name: "OverlayContainer",
225
225
  class: "okzhq2w",
226
226
  propsAsIs: !1
227
- }), Io = /* @__PURE__ */ n("div")({
227
+ }), yo = /* @__PURE__ */ n("div")({
228
228
  name: "PromoOverlay",
229
229
  class: "pmgz5i",
230
230
  propsAsIs: !1
231
- }), yo = /* @__PURE__ */ n("div")({
231
+ }), bo = /* @__PURE__ */ n("div")({
232
232
  name: "Header",
233
233
  class: "hyxi3jt",
234
234
  propsAsIs: !1
235
- }), bo = /* @__PURE__ */ n("div")({
235
+ }), fo = /* @__PURE__ */ n("div")({
236
236
  name: "HeaderContent",
237
237
  class: "h149e3gp",
238
238
  propsAsIs: !1
239
- }), fo = "h10toh7", io = /* @__PURE__ */ n("img")({
239
+ }), No = "h10toh7", ao = /* @__PURE__ */ n("img")({
240
240
  name: "SponsorLogo",
241
241
  class: "s1jyea6t",
242
242
  propsAsIs: !1
243
- }), xe = /* @__PURE__ */ n("div")({
243
+ }), Re = /* @__PURE__ */ n("div")({
244
244
  name: "SponsorName",
245
245
  class: "szpfa3h",
246
246
  propsAsIs: !1
247
- }), No = /* @__PURE__ */ n("div")({
247
+ }), $o = /* @__PURE__ */ n("div")({
248
248
  name: "Media",
249
249
  class: "m1crmu01",
250
250
  propsAsIs: !1
251
- }), Re = /* @__PURE__ */ n("img")({
251
+ }), De = /* @__PURE__ */ n("img")({
252
252
  name: "PromoImg",
253
253
  class: "p1l37r8s",
254
254
  propsAsIs: !1
255
- }), De = "s1nmch9k", ao = /* @__PURE__ */ n("div")({
255
+ }), qe = "s1nmch9k", ro = /* @__PURE__ */ n("div")({
256
256
  name: "Content",
257
257
  class: "c1er0ljd",
258
258
  propsAsIs: !1
259
- }), qe = /* @__PURE__ */ n("div")({
259
+ }), we = /* @__PURE__ */ n("div")({
260
260
  name: "Description",
261
261
  class: "dydopmr",
262
262
  propsAsIs: !1
263
- }), we = /* @__PURE__ */ n("div")({
263
+ }), Ve = /* @__PURE__ */ n("div")({
264
264
  name: "Sponsor",
265
265
  class: "s1w6nt04",
266
266
  propsAsIs: !1
267
- }), Ve = /* @__PURE__ */ n("div")({
267
+ }), je = /* @__PURE__ */ n("div")({
268
268
  name: "SponsorText",
269
269
  class: "s1evcmtq",
270
270
  propsAsIs: !1
271
- }), $o = /* @__PURE__ */ n("div")({
271
+ }), Co = /* @__PURE__ */ n("div")({
272
272
  name: "ADLogo",
273
273
  class: "awodx0x",
274
274
  propsAsIs: !1
275
- }), je = /* @__PURE__ */ n("span")({
275
+ }), Ue = /* @__PURE__ */ n("span")({
276
276
  name: "SponsoredText",
277
277
  class: "s1q3n6oi",
278
278
  propsAsIs: !1
279
- }), Ue = /* @__PURE__ */ n("div")({
279
+ }), Fe = /* @__PURE__ */ n("div")({
280
280
  name: "ActionBtnWrap",
281
281
  class: "a8d4xfk",
282
282
  propsAsIs: !1
283
- }), Fe = /* @__PURE__ */ n("a")({
283
+ }), ze = /* @__PURE__ */ n("a")({
284
284
  name: "ActionButton",
285
285
  class: "at6oobh",
286
286
  propsAsIs: !1
287
- }), ze = /* @__PURE__ */ n("div")({
287
+ }), Ge = /* @__PURE__ */ n("div")({
288
288
  name: "Title",
289
289
  class: "t1gyg7tt",
290
290
  propsAsIs: !1
291
- }), Ge = "h17rwbtk", We = /* @__PURE__ */ n("div")({
291
+ }), We = "h17rwbtk", He = /* @__PURE__ */ n("div")({
292
292
  name: "Container",
293
293
  class: "c10m2bce",
294
294
  propsAsIs: !1
295
- }), ro = /* @__PURE__ */ n("div")({
295
+ }), lo = /* @__PURE__ */ n("div")({
296
296
  name: "Item",
297
297
  class: "ig23yq5",
298
298
  propsAsIs: !1
299
- }), He = /* @__PURE__ */ n("div")({
299
+ }), Ke = /* @__PURE__ */ n("div")({
300
300
  name: "Dot",
301
301
  class: "d1f6aqua",
302
302
  propsAsIs: !1
303
- }), Ke = ({
303
+ }), Ye = ({
304
304
  time: o,
305
305
  adCount: s,
306
306
  adPosition: i
307
307
  }) => {
308
308
  const t = Math.floor(o / 60), l = o - t * 60;
309
- return t === 0 && l === 0 && s === i ? null : /* @__PURE__ */ v(We, {
310
- children: [s > 1 && /* @__PURE__ */ v(co, {
311
- children: [/* @__PURE__ */ v(ro, {
309
+ return t === 0 && l === 0 && s === i ? null : /* @__PURE__ */ v(He, {
310
+ children: [s > 1 && /* @__PURE__ */ v(po, {
311
+ children: [/* @__PURE__ */ v(lo, {
312
312
  children: [i, " of ", s]
313
- }), /* @__PURE__ */ e(He, {})]
314
- }), /* @__PURE__ */ v(ro, {
313
+ }), /* @__PURE__ */ e(Ke, {})]
314
+ }), /* @__PURE__ */ v(lo, {
315
315
  children: [t, ":", l < 10 ? `0${l}` : l]
316
316
  })]
317
317
  });
318
- }, Ye = (o, s, { onPlay: i, onStop: t, onProgress: l }) => {
318
+ }, Je = (o, s, { onPlay: i, onStop: t, onProgress: l }) => {
319
319
  const r = google.ima;
320
320
  let c = new r.AdDisplayContainer(o), m = new r.AdsLoader(c), A = new r.AdsRequest(), a;
321
321
  m.addEventListener(
@@ -342,15 +342,15 @@ const qo = /* @__PURE__ */ n("div")({
342
342
  }
343
343
  return g;
344
344
  };
345
- }, Je = /* @__PURE__ */ n("div")({
345
+ }, Ze = /* @__PURE__ */ n("div")({
346
346
  name: "Container",
347
347
  class: "c4q6dw1",
348
348
  propsAsIs: !1
349
- }), Xe = /* @__PURE__ */ n("div")({
349
+ }), Qe = /* @__PURE__ */ n("div")({
350
350
  name: "ControlsContainer",
351
351
  class: "c1la67r",
352
352
  propsAsIs: !1
353
- }), Ze = "m3guev", Qe = "m7099mt", on = "mmm6o5s", en = ({
353
+ }), Xe = "m3guev", on = "m7099mt", en = "mmm6o5s", nn = ({
354
354
  promotion: o,
355
355
  controlVideo: s,
356
356
  promotionId: i,
@@ -359,15 +359,15 @@ const qo = /* @__PURE__ */ n("div")({
359
359
  skipAutoClose: r
360
360
  }) => {
361
361
  var c;
362
- const m = F(null), [A, a] = R(!1), [g, u] = R(0), [p, I] = R(0), [$, h] = R(0), y = F(), b = Eo(() => {
362
+ const m = F(null), [A, a] = R(!1), [g, u] = R(0), [p, I] = R(0), [$, h] = R(0), y = F(), b = ko(() => {
363
363
  u(0), I(0), h(0), a(!1), s == null || s({
364
364
  muted: !1
365
365
  });
366
366
  }, [s]);
367
- P(() => {
367
+ M(() => {
368
368
  if (l != null && l.url && m.current) {
369
369
  b();
370
- const f = Ye(m.current, l.url, {
370
+ const f = Je(m.current, l.url, {
371
371
  onPlay: () => {
372
372
  D.emit("advertisement", {
373
373
  action: "videoPlay",
@@ -391,24 +391,24 @@ const qo = /* @__PURE__ */ n("div")({
391
391
  };
392
392
  }
393
393
  }, [l == null ? void 0 : l.url, s, b, i, o.type, t]);
394
- const O = ((c = o.sponsor) == null ? void 0 : c.logo) && o.logoMode === M.CENTER;
395
- return /* @__PURE__ */ v(Io, {
394
+ const O = ((c = o.sponsor) == null ? void 0 : c.logo) && o.logoMode === L.CENTER;
395
+ return /* @__PURE__ */ v(yo, {
396
396
  className: "PromoOverlay",
397
- children: [/* @__PURE__ */ v(yo, {
398
- children: [/* @__PURE__ */ e(bo, {
399
- className: k(!O && fo),
400
- children: /* @__PURE__ */ e($o, {
397
+ children: [/* @__PURE__ */ v(bo, {
398
+ children: [/* @__PURE__ */ e(fo, {
399
+ className: k(!O && No),
400
+ children: /* @__PURE__ */ e(Co, {
401
401
  style: {
402
402
  transform: "scale(1.5)"
403
403
  },
404
404
  children: "Ad"
405
405
  })
406
- }), /* @__PURE__ */ v(Xe, {
407
- children: [/* @__PURE__ */ e(Ke, {
406
+ }), /* @__PURE__ */ v(Qe, {
407
+ children: [/* @__PURE__ */ e(Ye, {
408
408
  time: g,
409
409
  adCount: p,
410
410
  adPosition: $
411
- }), r && /* @__PURE__ */ e(po, {
411
+ }), r && /* @__PURE__ */ e(mo, {
412
412
  className: "ClosePromoIcon",
413
413
  close: () => {
414
414
  var f;
@@ -416,71 +416,72 @@ const qo = /* @__PURE__ */ n("div")({
416
416
  }
417
417
  })]
418
418
  })]
419
- }), /* @__PURE__ */ e(No, {
420
- className: k(Ze, A && Qe, !A && on),
421
- children: /* @__PURE__ */ e(Je, {
419
+ }), /* @__PURE__ */ e($o, {
420
+ className: k(Xe, A && on, !A && en),
421
+ children: /* @__PURE__ */ e(Ze, {
422
422
  ref: m
423
423
  })
424
424
  })]
425
425
  });
426
- }, lo = (o) => {
427
- var s, i, t, l, r, c, m, A, a, g, u, p, I, $, h, y, b, O, f, C, W, H, K, Y, J, X, Z, Q, oo, eo;
426
+ }, co = (o) => {
427
+ var s, i, t, l, r, c, m, A, a, g, u, p, I, $, h, y, b, O, f, C, W, H, K, Y, J, Z, Q, X, oo, eo;
428
428
  const {
429
429
  promotion: d,
430
- advertisementPaused: Co,
430
+ open: no,
431
+ advertisementPaused: To,
431
432
  togglePause: E,
432
433
  controlVideo: _,
433
- skipAutoClose: To,
434
+ skipAutoClose: So,
434
435
  promotionId: B,
435
- onClose: So,
436
+ onClose: Eo,
436
437
  markAsViewed: w,
437
- externalAd: no
438
- } = o, V = d.type === S.INGAME_IAB11_LBAR || d.type === S.INGAME_IAB11, j = ((s = d.sponsor) == null ? void 0 : s.logo) && d.logoMode === M.CENTER, so = !!((t = (i = d.banner) == null ? void 0 : i.video) != null && t.url), x = d.autoPlayVideo === xo.ENABLED;
439
- if (P(() => {
440
- E == null || E(so || x);
441
- }, []), P(() => {
438
+ externalAd: so
439
+ } = o, V = d.type === S.INGAME_IAB11_LBAR || d.type === S.INGAME_IAB11, j = ((s = d.sponsor) == null ? void 0 : s.logo) && d.logoMode === L.CENTER, to = !!((t = (i = d.banner) == null ? void 0 : i.video) != null && t.url), x = d.autoPlayVideo === Ro.ENABLED;
440
+ if (M(() => {
441
+ E == null || E(to || x), no == null || no();
442
+ }, []), M(() => {
442
443
  B && d.type && w && w();
443
- }, [B, d.type, w]), P(() => () => {
444
+ }, [B, d.type, w]), M(() => () => {
444
445
  _ == null || _({ muted: !1 });
445
- }, [_]), no)
446
- return /* @__PURE__ */ e(en, { ...o, externalAd: no });
447
- let L = (l = d.banner) == null ? void 0 : l.url;
448
- L && L.indexOf("http") !== 0 && (L = `https://${L}`);
446
+ }, [_]), so)
447
+ return /* @__PURE__ */ e(nn, { ...o, externalAd: so });
448
+ let P = (l = d.banner) == null ? void 0 : l.url;
449
+ P && P.indexOf("http") !== 0 && (P = `https://${P}`);
449
450
  let U = !0;
450
- return so && (!Co || !x ? U = !0 : U = !1), /* @__PURE__ */ v(Io, { className: "PromoOverlay", children: [
451
- /* @__PURE__ */ v(yo, { children: [
452
- /* @__PURE__ */ v(bo, { className: k(!j && fo), children: [
453
- ((r = d.sponsor) == null ? void 0 : r.logo) && d.logoMode === M.LEFT && /* @__PURE__ */ e(io, { src: (c = d.sponsor) == null ? void 0 : c.logo, alt: "promo" }),
451
+ return to && (!To || !x ? U = !0 : U = !1), /* @__PURE__ */ v(yo, { className: "PromoOverlay", children: [
452
+ /* @__PURE__ */ v(bo, { children: [
453
+ /* @__PURE__ */ v(fo, { className: k(!j && No), children: [
454
+ ((r = d.sponsor) == null ? void 0 : r.logo) && d.logoMode === L.LEFT && /* @__PURE__ */ e(ao, { src: (c = d.sponsor) == null ? void 0 : c.logo, alt: "promo" }),
454
455
  /* @__PURE__ */ v(
455
- we,
456
+ Ve,
456
457
  {
457
458
  style: {
458
- paddingLeft: (m = d.sponsor) != null && m.logo && d.logoMode === M.LEFT ? "0px" : "8px"
459
+ paddingLeft: (m = d.sponsor) != null && m.logo && d.logoMode === L.LEFT ? "0px" : "8px"
459
460
  },
460
461
  children: [
461
- ((A = d.sponsor) == null ? void 0 : A.logo) && d.logoMode === M.LEFT && /* @__PURE__ */ e(xe, { children: (a = d.sponsor) == null ? void 0 : a.name }),
462
- /* @__PURE__ */ v(Ve, { className: "SponsorText", children: [
463
- /* @__PURE__ */ e($o, { children: "AD" }),
464
- /* @__PURE__ */ e(je, { children: "SPONSORED" })
462
+ ((A = d.sponsor) == null ? void 0 : A.logo) && d.logoMode === L.LEFT && /* @__PURE__ */ e(Re, { children: (a = d.sponsor) == null ? void 0 : a.name }),
463
+ /* @__PURE__ */ v(je, { className: "SponsorText", children: [
464
+ /* @__PURE__ */ e(Co, { children: "AD" }),
465
+ /* @__PURE__ */ e(Ue, { children: "SPONSORED" })
465
466
  ] })
466
467
  ]
467
468
  }
468
469
  )
469
470
  ] }),
470
471
  /* @__PURE__ */ e(
471
- po,
472
+ mo,
472
473
  {
473
474
  className: "ClosePromoIcon",
474
- close: So,
475
+ close: Eo,
475
476
  autoClose: (g = d.closeTimer) == null ? void 0 : g.auto,
476
- duration: To ? 0 : (u = d.closeTimer) == null ? void 0 : u.seconds,
477
+ duration: So ? 0 : (u = d.closeTimer) == null ? void 0 : u.seconds,
477
478
  isPlaying: U
478
479
  }
479
480
  )
480
481
  ] }),
481
- /* @__PURE__ */ v(No, { children: [
482
- j && /* @__PURE__ */ e(io, { className: De, src: (p = d.sponsor) == null ? void 0 : p.logo, alt: "promo" }),
483
- /* @__PURE__ */ e(ao, { children: ($ = (I = d.banner) == null ? void 0 : I.video) != null && $.url ? /* @__PURE__ */ e(
482
+ /* @__PURE__ */ v($o, { children: [
483
+ j && /* @__PURE__ */ e(ao, { className: qe, src: (p = d.sponsor) == null ? void 0 : p.logo, alt: "promo" }),
484
+ /* @__PURE__ */ e(ro, { children: ($ = (I = d.banner) == null ? void 0 : I.video) != null && $.url ? /* @__PURE__ */ e(
484
485
  Lo,
485
486
  {
486
487
  source: (y = (h = d.banner) == null ? void 0 : h.video) == null ? void 0 : y.url,
@@ -501,19 +502,19 @@ const qo = /* @__PURE__ */ n("div")({
501
502
  controlVideo: _,
502
503
  autoPlay: x
503
504
  }
504
- ) : (f = d.banner) != null && f.imageUrl ? /* @__PURE__ */ e(Re, { style: V ? { aspectRatio: "1/1" } : {}, src: (C = d.banner) == null ? void 0 : C.imageUrl, alt: "promo" }) : null }),
505
- !V && /* @__PURE__ */ v(ao, { children: [
506
- ((W = d.banner) == null ? void 0 : W.title) && /* @__PURE__ */ e(ze, { className: k("AdvTitle", j && Ge), children: (H = d.banner) == null ? void 0 : H.title }),
507
- ((K = d.banner) == null ? void 0 : K.body) && /* @__PURE__ */ e(qe, { className: "AdvDescription", children: (Y = d.banner) == null ? void 0 : Y.body })
505
+ ) : (f = d.banner) != null && f.imageUrl ? /* @__PURE__ */ e(De, { style: V ? { aspectRatio: "1/1" } : {}, src: (C = d.banner) == null ? void 0 : C.imageUrl, alt: "promo" }) : null }),
506
+ !V && /* @__PURE__ */ v(ro, { children: [
507
+ ((W = d.banner) == null ? void 0 : W.title) && /* @__PURE__ */ e(Ge, { className: k("AdvTitle", j && We), children: (H = d.banner) == null ? void 0 : H.title }),
508
+ ((K = d.banner) == null ? void 0 : K.body) && /* @__PURE__ */ e(we, { className: "AdvDescription", children: (Y = d.banner) == null ? void 0 : Y.body })
508
509
  ] })
509
510
  ] }),
510
- d.buttonType !== Ro.NO_BUTTON && /* @__PURE__ */ e(Ue, { children: /* @__PURE__ */ e(
511
- Fe,
511
+ d.buttonType !== Do.NO_BUTTON && /* @__PURE__ */ e(Fe, { children: /* @__PURE__ */ e(
512
+ ze,
512
513
  {
513
- href: L,
514
+ href: P,
514
515
  style: {
515
- backgroundColor: ((X = (J = d.banner) == null ? void 0 : J.ctaButton) == null ? void 0 : X.color) || "#009dc4",
516
- color: ((Q = (Z = d.banner) == null ? void 0 : Z.ctaButton) == null ? void 0 : Q.textColor) || "#fff"
516
+ backgroundColor: ((Z = (J = d.banner) == null ? void 0 : J.ctaButton) == null ? void 0 : Z.color) || "#009dc4",
517
+ color: ((X = (Q = d.banner) == null ? void 0 : Q.ctaButton) == null ? void 0 : X.textColor) || "#fff"
517
518
  },
518
519
  "data-analytics": "button",
519
520
  "data-promo-id": B,
@@ -523,11 +524,11 @@ const qo = /* @__PURE__ */ n("div")({
523
524
  }
524
525
  ) })
525
526
  ] });
526
- }, nn = /* @__PURE__ */ n("div")({
527
+ }, sn = /* @__PURE__ */ n("div")({
527
528
  name: "SidebarContainer",
528
529
  class: "s1abskp8",
529
530
  propsAsIs: !1
530
- }), sn = ({
531
+ }), tn = ({
531
532
  children: o,
532
533
  direction: s,
533
534
  style: i,
@@ -538,10 +539,10 @@ const qo = /* @__PURE__ */ n("div")({
538
539
  style: i,
539
540
  hiding: l,
540
541
  className: t,
541
- children: /* @__PURE__ */ e(nn, {
542
+ children: /* @__PURE__ */ e(sn, {
542
543
  children: o
543
544
  })
544
- }), tn = (o) => (o == null ? void 0 : o.type) === S.INGAME_IAB11_LBAR || (o == null ? void 0 : o.type) === S.INGAME_IAB21_LBAR, an = (o) => (o == null ? void 0 : o.type) === S.INGAME_IAB11 || (o == null ? void 0 : o.type) === S.INGAME_IAB21, rn = ({
545
+ }), an = (o) => (o == null ? void 0 : o.type) === S.INGAME_IAB11_LBAR || (o == null ? void 0 : o.type) === S.INGAME_IAB21_LBAR, rn = (o) => (o == null ? void 0 : o.type) === S.INGAME_IAB11 || (o == null ? void 0 : o.type) === S.INGAME_IAB21, ln = ({
545
546
  advertisement: o,
546
547
  close: s,
547
548
  skipTypeCheck: i,
@@ -556,45 +557,54 @@ const qo = /* @__PURE__ */ n("div")({
556
557
  controlVideo: u,
557
558
  advertisementPaused: p,
558
559
  togglePause: I
559
- }) => o.promotion ? c && o.notification ? /* @__PURE__ */ e(_e, { open: a, notification: o.notification, promotionId: o.question.id }) : !r && !m && (i || an(o.promotion)) ? /* @__PURE__ */ e(Be, { className: "PromoOverlayContainer", children: /* @__PURE__ */ e(
560
- lo,
560
+ }) => o.promotion ? c && o.notification ? /* @__PURE__ */ e(
561
+ Be,
562
+ {
563
+ open: () => a == null ? void 0 : a({ fromNotification: !0 }),
564
+ notification: o.notification,
565
+ promotionId: o.question.id
566
+ }
567
+ ) : !r && !m && (i || rn(o.promotion)) ? /* @__PURE__ */ e(xe, { className: "PromoOverlayContainer", children: /* @__PURE__ */ e(
568
+ co,
561
569
  {
562
570
  markAsViewed: A,
563
571
  promotionId: o.question.id,
564
572
  promotion: o.promotion,
565
573
  onClose: s,
574
+ open: a,
566
575
  skipAutoClose: t,
567
576
  externalAd: g,
568
577
  controlVideo: u,
569
578
  advertisementPaused: p,
570
579
  togglePause: I
571
580
  }
572
- ) }) : r && (i || tn(o.promotion)) ? /* @__PURE__ */ e(sn, { className: "PromoSidebarContainer", direction: r, hiding: !1, children: /* @__PURE__ */ e(
573
- lo,
581
+ ) }) : r && (i || an(o.promotion)) ? /* @__PURE__ */ e(tn, { className: "PromoSidebarContainer", direction: r, hiding: !1, children: /* @__PURE__ */ e(
582
+ co,
574
583
  {
575
584
  markAsViewed: A,
576
585
  promotionId: o.question.id,
577
586
  promotion: o.promotion,
578
587
  externalAd: g,
579
588
  onClose: s,
589
+ open: a,
580
590
  controlVideo: u,
581
591
  skipAutoClose: t,
582
592
  advertisementPaused: p,
583
593
  togglePause: I
584
594
  }
585
595
  ) }) : m ? /* @__PURE__ */ e(
586
- Xo,
596
+ Qo,
587
597
  {
588
598
  promotionId: o.question.id,
589
599
  hiding: !1,
590
600
  promotion: o.promotion,
591
601
  direction: m
592
602
  }
593
- ) : null : null, ln = /* @__PURE__ */ n("div")({
603
+ ) : null : null, dn = /* @__PURE__ */ n("div")({
594
604
  name: "AdvertisementUIWrap",
595
605
  class: "aa6pjif",
596
606
  propsAsIs: !1
597
- }), dn = (o) => {
607
+ }), cn = (o) => {
598
608
  const s = o.target;
599
609
  if (s instanceof HTMLAnchorElement && s.target === "_blank") {
600
610
  const i = s.getAttribute("data-promo-id") || "", t = s.getAttribute("data-promo-type") || S.UNSET;
@@ -612,7 +622,7 @@ const qo = /* @__PURE__ */ n("div")({
612
622
  }
613
623
  });
614
624
  }
615
- }, cn = ({
625
+ }, pn = ({
616
626
  gamification: o,
617
627
  layoutMode: s,
618
628
  skipAutoClose: i,
@@ -626,23 +636,23 @@ const qo = /* @__PURE__ */ n("div")({
626
636
  controlVideo: g
627
637
  }) => {
628
638
  var u, p, I;
629
- const $ = F(null), h = mo(o.advertisement.$store);
639
+ const $ = F(null), h = uo(o.advertisement.$store);
630
640
  Mo($, {
631
641
  enabled: !!h.data,
632
642
  event: "click",
633
- listener: dn
643
+ listener: cn
634
644
  });
635
645
  const y = !r && !l;
636
646
  if (h.data === void 0 || !A && h.isViewed)
637
647
  return null;
638
- const b = ((I = (p = (u = h == null ? void 0 : h.data) == null ? void 0 : u.notification) == null ? void 0 : p.promotion) == null ? void 0 : I.mode) === go.LOWER_THIRD;
639
- return /* @__PURE__ */ e(ln, {
648
+ const b = ((I = (p = (u = h == null ? void 0 : h.data) == null ? void 0 : u.notification) == null ? void 0 : p.promotion) == null ? void 0 : I.mode) === ho.LOWER_THIRD;
649
+ return /* @__PURE__ */ e(dn, {
640
650
  ref: $,
641
651
  style: {
642
652
  height: y ? "auto" : "100%"
643
653
  },
644
654
  className: k("SL-AdvertisementUIWrap", m && "mobile-view", b && "SL-AdvertisementUIWrap--lower-third"),
645
- children: /* @__PURE__ */ e(rn, {
655
+ children: /* @__PURE__ */ e(ln, {
646
656
  skipTypeCheck: t,
647
657
  sidebar: l,
648
658
  banner: r,
@@ -659,7 +669,7 @@ const qo = /* @__PURE__ */ n("div")({
659
669
  controlVideo: g
660
670
  })
661
671
  });
662
- }, pn = ({
672
+ }, mn = ({
663
673
  sdk: o,
664
674
  sidebar: s,
665
675
  externalAd: i,
@@ -671,8 +681,8 @@ const qo = /* @__PURE__ */ n("div")({
671
681
  persistent: A,
672
682
  notification: a
673
683
  }) => {
674
- const g = mo(o.featuresList.getStore());
675
- if (P(() => {
684
+ const g = uo(o.featuresList.getStore());
685
+ if (M(() => {
676
686
  if (i) {
677
687
  const p = document.createElement("script");
678
688
  p.async = !0, p.src = "https://imasdk.googleapis.com/js/sdkloader/ima3.js", document.body.appendChild(p);
@@ -693,8 +703,8 @@ const qo = /* @__PURE__ */ n("div")({
693
703
  });
694
704
  if (!g)
695
705
  return null;
696
- const u = o.getFeature(Do.GAMES);
697
- return u ? /* @__PURE__ */ e(cn, {
706
+ const u = o.getFeature(qo.GAMES);
707
+ return u ? /* @__PURE__ */ e(pn, {
698
708
  gamification: u,
699
709
  sidebar: s,
700
710
  banner: t,
@@ -707,7 +717,7 @@ const qo = /* @__PURE__ */ n("div")({
707
717
  externalAd: i,
708
718
  controlVideo: o.controlVideoPlayer
709
719
  }) : null;
710
- }, gn = ({
720
+ }, hn = ({
711
721
  event: o,
712
722
  sidebar: s,
713
723
  banner: i,
@@ -719,10 +729,10 @@ const qo = /* @__PURE__ */ n("div")({
719
729
  skipTypeCheck: A,
720
730
  externalAd: a
721
731
  }) => {
722
- const g = Po(), u = Oo(), p = _o();
732
+ const g = Oo(), u = _o(), p = Bo();
723
733
  return g ? a && !u.promotionExternalAd ? o !== void 0 && /* @__PURE__ */ e(T, { event: o }) : !a && u.promotionExternalAd ? o !== void 0 && /* @__PURE__ */ e(T, { event: o }) : s && !u.promotionSidebar ? o !== void 0 && /* @__PURE__ */ e(T, { event: o }) : i && !u.promotionBanner ? o !== void 0 && /* @__PURE__ */ e(T, { event: o }) : m && !u.promotionNotification ? o !== void 0 && /* @__PURE__ */ e(T, { event: o }) : !i && !s && !m && !u.promotionOverlay ? o !== void 0 && /* @__PURE__ */ e(T, { event: o }) : /* @__PURE__ */ v("div", { className: "StreamLayerSDK", children: [
724
- /* @__PURE__ */ e(Bo, { customTheme: c ?? p, children: /* @__PURE__ */ e(
725
- pn,
734
+ /* @__PURE__ */ e(xo, { customTheme: c ?? p, children: /* @__PURE__ */ e(
735
+ mn,
726
736
  {
727
737
  sdk: g,
728
738
  sidebar: s,
@@ -740,6 +750,6 @@ const qo = /* @__PURE__ */ n("div")({
740
750
  ] }) : null;
741
751
  };
742
752
  export {
743
- gn as StreamLayerSDKAdvertisement,
744
- pn as StreamLayerSDKAdvertisementUI
753
+ hn as StreamLayerSDKAdvertisement,
754
+ mn as StreamLayerSDKAdvertisementUI
745
755
  };