@jolibox/ads 1.4.9 → 1.4.11

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.
Files changed (2) hide show
  1. package/dist/index.js +332 -326
  2. package/package.json +4 -4
package/dist/index.js CHANGED
@@ -1,26 +1,26 @@
1
1
  var ln = Object.defineProperty, un = Object.defineProperties;
2
2
  var cn = Object.getOwnPropertyDescriptors;
3
3
  var We = Object.getOwnPropertySymbols;
4
- var Kt = Object.prototype.hasOwnProperty, zt = Object.prototype.propertyIsEnumerable;
5
- var qt = (t, e, i) => e in t ? ln(t, e, { enumerable: !0, configurable: !0, writable: !0, value: i }) : t[e] = i, yt = (t, e) => {
4
+ var qt = Object.prototype.hasOwnProperty, zt = Object.prototype.propertyIsEnumerable;
5
+ var Kt = (t, e, i) => e in t ? ln(t, e, { enumerable: !0, configurable: !0, writable: !0, value: i }) : t[e] = i, yt = (t, e) => {
6
6
  for (var i in e || (e = {}))
7
- Kt.call(e, i) && qt(t, i, e[i]);
7
+ qt.call(e, i) && Kt(t, i, e[i]);
8
8
  if (We)
9
9
  for (var i of We(e))
10
- zt.call(e, i) && qt(t, i, e[i]);
10
+ zt.call(e, i) && Kt(t, i, e[i]);
11
11
  return t;
12
12
  }, Wt = (t, e) => un(t, cn(e));
13
- var Ht = (t, e) => {
13
+ var Jt = (t, e) => {
14
14
  var i = {};
15
15
  for (var n in t)
16
- Kt.call(t, n) && e.indexOf(n) < 0 && (i[n] = t[n]);
16
+ qt.call(t, n) && e.indexOf(n) < 0 && (i[n] = t[n]);
17
17
  if (t != null && We)
18
18
  for (var n of We(t))
19
19
  e.indexOf(n) < 0 && zt.call(t, n) && (i[n] = t[n]);
20
20
  return i;
21
21
  };
22
22
  import { options as Te, Component as hn, isValidElement as fn } from "preact";
23
- import { useRef as mi, useLayoutEffect as vn, useEffect as Ce, useMemo as yn, useState as _e, useCallback as kt, render as ye, createRef as Jt } from "preact/compat";
23
+ import { useRef as mi, useLayoutEffect as vn, useEffect as Ce, useMemo as yn, useState as _e, useCallback as kt, render as ye, createRef as Ht } from "preact/compat";
24
24
  import { registerCanIUseContext as gn, invokeNative as gt, offNative as wn, onNative as An } from "@jolibox/native-bridge";
25
25
  var Si = Object.defineProperty, bn = Object.defineProperties, pn = Object.getOwnPropertyDescriptors, Yt = Object.getOwnPropertySymbols, _n = Object.prototype.hasOwnProperty, mn = Object.prototype.propertyIsEnumerable, Xt = (t, e, i) => e in t ? Si(t, e, {
26
26
  enumerable: !0,
@@ -48,14 +48,14 @@ var Si = Object.defineProperty, bn = Object.defineProperties, pn = Object.getOwn
48
48
  var o = (d) => {
49
49
  try {
50
50
  a(i.next(d));
51
- } catch (u) {
52
- r(u);
51
+ } catch (l) {
52
+ r(l);
53
53
  }
54
54
  }, s = (d) => {
55
55
  try {
56
56
  a(i.throw(d));
57
- } catch (u) {
58
- r(u);
57
+ } catch (l) {
58
+ r(l);
59
59
  }
60
60
  }, a = (d) => d.done ? n(d.value) : Promise.resolve(d.value).then(o, s);
61
61
  a((i = i.apply(t, e)).next());
@@ -286,14 +286,14 @@ var D = It, jn = class {
286
286
  console.info("[Jolibox SDK] Emitter is _disposed");
287
287
  };
288
288
  i && (e = e.bind(i));
289
- let u = new Be(e);
290
- return this._listeners ? this._listeners instanceof Be ? this._listeners = [this._listeners, u] : this._listeners.push(u) : ((r = (n = this.options) == null ? void 0 : n.onWillAddFirstListener) == null || r.call(n, this), this._listeners = u, (s = (o = this.options) == null ? void 0 : o.onDidFirstListener) == null || s.call(o, this)), (d = (a = this.options) == null ? void 0 : a.onDidAddListener) == null || d.call(a, this), this._size++, () => {
291
- var l, c, h, f;
289
+ let l = new Be(e);
290
+ return this._listeners ? this._listeners instanceof Be ? this._listeners = [this._listeners, l] : this._listeners.push(l) : ((r = (n = this.options) == null ? void 0 : n.onWillAddFirstListener) == null || r.call(n, this), this._listeners = l, (s = (o = this.options) == null ? void 0 : o.onDidFirstListener) == null || s.call(o, this)), (d = (a = this.options) == null ? void 0 : a.onDidAddListener) == null || d.call(a, this), this._size++, () => {
291
+ var u, c, h, f;
292
292
  if (!this._disposed) {
293
293
  if (this._listeners instanceof Be)
294
- this._listeners.id === u.id && (this._listeners = void 0, this._size = 0, (c = (l = this.options) == null ? void 0 : l.onDidRemoveLastListener) == null || c.call(l));
294
+ this._listeners.id === l.id && (this._listeners = void 0, this._size = 0, (c = (u = this.options) == null ? void 0 : u.onDidRemoveLastListener) == null || c.call(u));
295
295
  else if (this._listeners) {
296
- let v = this._listeners.indexOf(u);
296
+ let v = this._listeners.indexOf(l);
297
297
  v >= 0 && (this._listeners.splice(v, 1), this._size--, this._size === 0 && ((f = (h = this.options) == null ? void 0 : h.onDidRemoveLastListener) == null || f.call(h)));
298
298
  }
299
299
  }
@@ -365,15 +365,15 @@ var D = It, jn = class {
365
365
  }
366
366
  }, Rt = {};
367
367
  kn(Rt, {
368
- None: () => qn,
368
+ None: () => Kn,
369
369
  filter: () => zn,
370
370
  once: () => Ti,
371
- toPromise: () => Kn
371
+ toPromise: () => qn
372
372
  });
373
- var qn = () => (console.log("[Jolibox SDK] None Event"), () => {
373
+ var Kn = () => (console.log("[Jolibox SDK] None Event"), () => {
374
374
  console.log("[Jolibox SDK] None Event dispose");
375
375
  });
376
- function Kn(t) {
376
+ function qn(t) {
377
377
  return new Promise((e) => Ti(t)(e));
378
378
  }
379
379
  function Ti(t) {
@@ -408,12 +408,12 @@ var wt = Symbol.for("Jolibox.hostEmitter"), Wn = () => {
408
408
  }), globalThis[wt];
409
409
  };
410
410
  Wn();
411
- function Hn(t, e) {
411
+ function Jn(t, e) {
412
412
  let i = Math.min(t.length, e.length);
413
413
  for (let n = 0; n < i; n++)
414
- Jn(t[n], e[n]);
414
+ Hn(t[n], e[n]);
415
415
  }
416
- function Jn(t, e) {
416
+ function Hn(t, e) {
417
417
  if (Rn(e)) {
418
418
  if (typeof t !== e)
419
419
  throw new Error(`argument does not match constraint: typeof ${e}`);
@@ -443,7 +443,7 @@ var Tt = class {
443
443
  t.handler = function() {
444
444
  for (var r = arguments.length, o = new Array(r), s = 0; s < r; s++)
445
445
  o[s] = arguments[s];
446
- return Hn(o, i), n(...o);
446
+ return Jn(o, i), n(...o);
447
447
  };
448
448
  }
449
449
  let {
@@ -522,7 +522,7 @@ var ti = class {
522
522
  }
523
523
  };
524
524
  ti = Ei([ki], ti);
525
- function H(t, e, i) {
525
+ function J(t, e, i) {
526
526
  return (e = Yn(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
527
527
  }
528
528
  function Yn(t) {
@@ -554,7 +554,7 @@ const Se = (t) => t ? function() {
554
554
  };
555
555
  class Qn {
556
556
  constructor(e) {
557
- H(this, "context", void 0), H(this, "continueCallback", void 0), H(this, "adIsShowingCallback", void 0), H(this, "isBeforeAdCalled", !1), H(this, "isBeforeRewardCalled", !1), H(this, "isAdDismissedCalled", !1), H(this, "isAdViewedCalled", !1), H(this, "isAfterAdCalled", !1), H(this, "currentProvider", void 0), H(this, "currentClientParams", void 0), H(this, "adsHasResponse", !1), H(this, "videoChecker", window.document.createElement("video")), H(this, "contextInfo", void 0), H(this, "wrapShowAdFn", (i) => () => {
557
+ J(this, "context", void 0), J(this, "continueCallback", void 0), J(this, "adIsShowingCallback", void 0), J(this, "isBeforeAdCalled", !1), J(this, "isBeforeRewardCalled", !1), J(this, "isAdDismissedCalled", !1), J(this, "isAdViewedCalled", !1), J(this, "isAfterAdCalled", !1), J(this, "currentProvider", void 0), J(this, "currentClientParams", void 0), J(this, "adsHasResponse", !1), J(this, "videoChecker", window.document.createElement("video")), J(this, "contextInfo", void 0), J(this, "wrapShowAdFn", (i) => () => {
558
558
  var o, s, a;
559
559
  this.adsHasResponse = !0;
560
560
  let n = !1;
@@ -639,7 +639,7 @@ class Qn {
639
639
  }
640
640
  wrapAdBreakDone(e) {
641
641
  return (i) => {
642
- var n, r, o, s, a, d, u, l, c;
642
+ var n, r, o, s, a, d, l, u, c;
643
643
  switch (this.adsHasResponse = !0, this.context.track("CallAdBreakDone", {
644
644
  provider: (r = (n = this.currentProvider) == null ? void 0 : n.name) != null ? r : null,
645
645
  breakType: i.breakType,
@@ -658,7 +658,7 @@ class Qn {
658
658
  case "dismissed":
659
659
  case "error": {
660
660
  const h = Se(e);
661
- h == null || h(i), (u = this.adIsShowingCallback) == null || u.call(this, !1), (l = this.continueCallback) == null || l.call(this, [!1, i]);
661
+ h == null || h(i), (l = this.adIsShowingCallback) == null || l.call(this, !1), (u = this.continueCallback) == null || u.call(this, [!1, i]);
662
662
  break;
663
663
  }
664
664
  default: {
@@ -711,13 +711,13 @@ class Qn {
711
711
  }
712
712
  }
713
713
  window.setTimeout(() => {
714
- var a, d, u, l, c, h, f;
714
+ var a, d, l, u, c, h, f;
715
715
  this.adsHasResponse || (this.context.track("CallAdBreakTimeout", {
716
716
  type: i.type,
717
717
  provider: (d = (a = this.currentProvider) == null ? void 0 : a.name) != null ? d : null
718
718
  }), this.notifyIframeAdsEvent("JOLIBOX_AD_CALL_AD_BREAK_TIMEOUT", {
719
719
  type: i.type,
720
- provider: (l = (u = this.currentProvider) == null ? void 0 : u.name) != null ? l : null
720
+ provider: (u = (l = this.currentProvider) == null ? void 0 : l.name) != null ? u : null
721
721
  }), (h = this.continueCallback) == null || h.call(this, [!0, {
722
722
  breakType: i.type,
723
723
  breakName: i.type === "preroll" ? "" : (c = i.name) != null ? c : "",
@@ -728,7 +728,7 @@ class Qn {
728
728
  });
729
729
  }
730
730
  }
731
- function He(t, e, i) {
731
+ function Je(t, e, i) {
732
732
  return (e = Zn(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
733
733
  }
734
734
  function Zn(t) {
@@ -749,11 +749,11 @@ function er(t, e) {
749
749
  }
750
750
  class tr {
751
751
  constructor(e) {
752
- He(this, "context", void 0), He(this, "adBreakIsShowing", !1), He(this, "reportPageJumpOut", () => {
752
+ Je(this, "context", void 0), Je(this, "adBreakIsShowing", !1), Je(this, "reportPageJumpOut", () => {
753
753
  this.context.track("AdBreakJumpOut", {
754
754
  context: "AdsActionDetection"
755
755
  });
756
- }), He(this, "reportPageHide", () => {
756
+ }), Je(this, "reportPageHide", () => {
757
757
  this.context.track("AdBreakHide", {
758
758
  context: "AdsActionDetection"
759
759
  });
@@ -764,7 +764,7 @@ class tr {
764
764
  });
765
765
  }
766
766
  }
767
- function Je(t, e, i) {
767
+ function He(t, e, i) {
768
768
  return (e = ir(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
769
769
  }
770
770
  function ir(t) {
@@ -785,7 +785,7 @@ function nr(t, e) {
785
785
  }
786
786
  class rr {
787
787
  constructor(e) {
788
- Je(this, "configs", null), Je(this, "firstRun", !0), Je(this, "context", void 0), Je(this, "contextInfo", void 0), this.context = e, this.contextInfo = this.context.getContextInfo(), this.init();
788
+ He(this, "configs", null), He(this, "firstRun", !0), He(this, "context", void 0), He(this, "contextInfo", void 0), this.context = e, this.contextInfo = this.context.getContextInfo(), this.init();
789
789
  }
790
790
  async init() {
791
791
  try {
@@ -839,7 +839,7 @@ class ar {
839
839
  }), de(this, "adConfig", (n) => {
840
840
  const s = n, {
841
841
  onReady: r
842
- } = s, o = Ht(s, [
842
+ } = s, o = Jt(s, [
843
843
  "onReady"
844
844
  ]);
845
845
  this.context.track("CallAdConfig", o), this.configured ? console.warn("Ad config already set, skipping") : (this.configured = !0, this.push(n));
@@ -865,20 +865,20 @@ class ar {
865
865
  fullWidthResponsive: a,
866
866
  style: d
867
867
  } = n;
868
- let u;
868
+ let l;
869
869
  if (!r)
870
870
  throw new Error("targeting element is required");
871
- if (typeof r == "string" ? u = document.querySelector(r) : u = r, !u)
871
+ if (typeof r == "string" ? l = document.querySelector(r) : l = r, !l)
872
872
  throw new Error("targeting element not found");
873
- let l = o;
874
- if (l || (l = this.initParams.unitId), !l)
873
+ let u = o;
874
+ if (u || (u = this.initParams.unitId), !u)
875
875
  throw new Error("slot is required");
876
876
  const c = typeof s == "object" && Array.isArray(s) ? s.join(", ") : s, h = document.createElement("ins");
877
- if (h.className = "adsbygoogle", h.id = "jolibox-ads", h.style.display = "block", h.setAttribute("data-ad-client", this.initParams.clientId), h.setAttribute("data-ad-slot", l), c && h.setAttribute("data-ad-format", c), a && h.setAttribute("data-full-width-responsive", a), d && h.setAttribute("style", d), (g = this.contextInfo.testAdsMode) != null ? g : !1) {
877
+ if (h.className = "adsbygoogle", h.id = "jolibox-ads", h.style.display = "block", h.setAttribute("data-ad-client", this.initParams.clientId), h.setAttribute("data-ad-slot", u), c && h.setAttribute("data-ad-format", c), a && h.setAttribute("data-full-width-responsive", a), d && h.setAttribute("style", d), (g = this.contextInfo.testAdsMode) != null ? g : !1) {
878
878
  const A = document.createElement("div");
879
- A.style.position = "absolute", A.style.top = "0", A.style.left = "0", A.style.width = "100%", A.style.height = "100%", A.style.display = "flex", A.style.justifyContent = "center", A.style.alignItems = "center", A.style.backgroundColor = "rgba(0, 0, 0, 0.5)", A.style.color = "white", A.innerHTML = "Test Ad", h.style.position = "relative", u.appendChild(h), h.appendChild(A);
879
+ A.style.position = "absolute", A.style.top = "0", A.style.left = "0", A.style.width = "100%", A.style.height = "100%", A.style.display = "flex", A.style.justifyContent = "center", A.style.alignItems = "center", A.style.backgroundColor = "rgba(0, 0, 0, 0.5)", A.style.color = "white", A.innerHTML = "Test Ad", h.style.position = "relative", l.appendChild(h), h.appendChild(A);
880
880
  } else
881
- u.appendChild(h), new MutationObserver((S) => {
881
+ l.appendChild(h), new MutationObserver((S) => {
882
882
  S.forEach((p) => {
883
883
  if (p.type === "attributes" && p.attributeName === "data-ad-status") {
884
884
  const _ = h.getAttribute("data-ad-status");
@@ -1002,7 +1002,7 @@ function ae() {
1002
1002
  function Ze() {
1003
1003
  return Y;
1004
1004
  }
1005
- function qe(t, e) {
1005
+ function Ke(t, e) {
1006
1006
  return Ve(De, t, e);
1007
1007
  }
1008
1008
  function Ge(t) {
@@ -1044,7 +1044,7 @@ function Li(t) {
1044
1044
  return De = "", t;
1045
1045
  }
1046
1046
  function et(t) {
1047
- return Di(qe(Y - 1, Ot(t === 91 ? t + 2 : t === 40 ? t + 1 : t)));
1047
+ return Di(Ke(Y - 1, Ot(t === 91 ? t + 2 : t === 40 ? t + 1 : t)));
1048
1048
  }
1049
1049
  function pr(t) {
1050
1050
  for (; (N = ae()) && N < 33; )
@@ -1054,7 +1054,7 @@ function pr(t) {
1054
1054
  function _r(t, e) {
1055
1055
  for (; --e && Z() && !(N < 48 || N > 102 || N > 57 && N < 65 || N > 70 && N < 97); )
1056
1056
  ;
1057
- return qe(t, Ze() + (e < 6 && ae() == 32 && Z() == 32));
1057
+ return Ke(t, Ze() + (e < 6 && ae() == 32 && Z() == 32));
1058
1058
  }
1059
1059
  function Ot(t) {
1060
1060
  for (; Z(); )
@@ -1078,18 +1078,18 @@ function mr(t, e) {
1078
1078
  for (; Z() && t + N !== 57; )
1079
1079
  if (t + N === 84 && ae() === 47)
1080
1080
  break;
1081
- return "/*" + qe(e, Y - 1) + "*" + ct(t === 47 ? t : Z());
1081
+ return "/*" + Ke(e, Y - 1) + "*" + ct(t === 47 ? t : Z());
1082
1082
  }
1083
1083
  function Sr(t) {
1084
1084
  for (; !Ge(ae()); )
1085
1085
  Z();
1086
- return qe(t, Y);
1086
+ return Ke(t, Y);
1087
1087
  }
1088
1088
  function Er(t) {
1089
1089
  return Li(tt("", null, null, null, [""], t = Ni(t), 0, [0], t));
1090
1090
  }
1091
1091
  function tt(t, e, i, n, r, o, s, a, d) {
1092
- for (var u = 0, l = 0, c = s, h = 0, f = 0, v = 0, y = 1, w = 1, g = 1, A = 0, S = "", p = r, _ = o, E = n, b = S; w; )
1092
+ for (var l = 0, u = 0, c = s, h = 0, f = 0, v = 0, y = 1, w = 1, g = 1, A = 0, S = "", p = r, _ = o, E = n, b = S; w; )
1093
1093
  switch (v = A, A = Z()) {
1094
1094
  case 40:
1095
1095
  if (v != 108 && $(b, c - 1) == 58) {
@@ -1121,7 +1121,7 @@ function tt(t, e, i, n, r, o, s, a, d) {
1121
1121
  }
1122
1122
  break;
1123
1123
  case 123 * y:
1124
- a[u++] = se(b) * g;
1124
+ a[l++] = se(b) * g;
1125
1125
  case 125 * y:
1126
1126
  case 59:
1127
1127
  case 0:
@@ -1129,14 +1129,14 @@ function tt(t, e, i, n, r, o, s, a, d) {
1129
1129
  case 0:
1130
1130
  case 125:
1131
1131
  w = 0;
1132
- case 59 + l:
1132
+ case 59 + u:
1133
1133
  g == -1 && (b = R(b, /\f/g, "")), f > 0 && se(b) - c && Ye(f > 32 ? ni(b + ";", n, i, c - 1) : ni(R(b, " ", "") + ";", n, i, c - 2), d);
1134
1134
  break;
1135
1135
  case 59:
1136
1136
  b += ";";
1137
1137
  default:
1138
- if (Ye(E = ii(b, e, i, u, l, r, a, S, p = [], _ = [], c), o), A === 123)
1139
- if (l === 0)
1138
+ if (Ye(E = ii(b, e, i, l, u, r, a, S, p = [], _ = [], c), o), A === 123)
1139
+ if (u === 0)
1140
1140
  tt(b, e, E, E, p, o, c, a, _);
1141
1141
  else
1142
1142
  switch (h === 99 && $(b, 3) === 110 ? 100 : h) {
@@ -1150,7 +1150,7 @@ function tt(t, e, i, n, r, o, s, a, d) {
1150
1150
  tt(b, E, E, E, [""], _, 0, a, _);
1151
1151
  }
1152
1152
  }
1153
- u = l = f = 0, y = g = 1, S = b = "", c = s;
1153
+ l = u = f = 0, y = g = 1, S = b = "", c = s;
1154
1154
  break;
1155
1155
  case 58:
1156
1156
  c = 1 + se(b), f = v;
@@ -1163,13 +1163,13 @@ function tt(t, e, i, n, r, o, s, a, d) {
1163
1163
  }
1164
1164
  switch (b += ct(A), A * y) {
1165
1165
  case 38:
1166
- g = l > 0 ? 1 : (b += "\f", -1);
1166
+ g = u > 0 ? 1 : (b += "\f", -1);
1167
1167
  break;
1168
1168
  case 44:
1169
- a[u++] = (se(b) - 1) * g, g = 1;
1169
+ a[l++] = (se(b) - 1) * g, g = 1;
1170
1170
  break;
1171
1171
  case 64:
1172
- ae() === 45 && (b += et(Z())), h = ae(), l = c = se(S = b += Sr(Ze())), A++;
1172
+ ae() === 45 && (b += et(Z())), h = ae(), u = c = se(S = b += Sr(Ze())), A++;
1173
1173
  break;
1174
1174
  case 45:
1175
1175
  v === 45 && se(b) == 2 && (y = 0);
@@ -1177,11 +1177,11 @@ function tt(t, e, i, n, r, o, s, a, d) {
1177
1177
  }
1178
1178
  return o;
1179
1179
  }
1180
- function ii(t, e, i, n, r, o, s, a, d, u, l) {
1180
+ function ii(t, e, i, n, r, o, s, a, d, l, u) {
1181
1181
  for (var c = r - 1, h = r === 0 ? o : [""], f = Ft(h), v = 0, y = 0, w = 0; v < n; ++v)
1182
1182
  for (var g = 0, A = Ve(t, c + 1, c = fr(y = s[v])), S = t; g < f; ++g)
1183
1183
  (S = Di(y > 0 ? h[g] + " " + A : R(A, /&\f/g, h[g]))) && (d[w++] = S);
1184
- return ft(t, e, i, r === 0 ? Mt : a, d, u, l);
1184
+ return ft(t, e, i, r === 0 ? Mt : a, d, l, u);
1185
1185
  }
1186
1186
  function kr(t, e, i) {
1187
1187
  return ft(t, e, i, Ci, ct(Ar()), Ve(t, 2, -2), 0);
@@ -1233,7 +1233,7 @@ function Tr(t) {
1233
1233
  var Cr = function(e, i, n) {
1234
1234
  for (var r = 0, o = 0; r = o, o = ae(), r === 38 && o === 12 && (i[n] = 1), !Ge(o); )
1235
1235
  Z();
1236
- return qe(e, Y);
1236
+ return Ke(e, Y);
1237
1237
  }, Or = function(e, i) {
1238
1238
  var n = -1, r = 44;
1239
1239
  do
@@ -1265,9 +1265,9 @@ var Cr = function(e, i, n) {
1265
1265
  return;
1266
1266
  if (!(e.props.length === 1 && i.charCodeAt(0) !== 58 && !ri.get(n)) && !r) {
1267
1267
  ri.set(e, !0);
1268
- for (var o = [], s = Dr(i, o), a = n.props, d = 0, u = 0; d < s.length; d++)
1269
- for (var l = 0; l < a.length; l++, u++)
1270
- e.props[u] = o[d] ? s[d].replace(/&\f/g, a[l]) : a[l] + " " + s[d];
1268
+ for (var o = [], s = Dr(i, o), a = n.props, d = 0, l = 0; d < s.length; d++)
1269
+ for (var u = 0; u < a.length; u++, l++)
1270
+ e.props[l] = o[d] ? s[d].replace(/&\f/g, a[u]) : a[u] + " " + s[d];
1271
1271
  }
1272
1272
  }
1273
1273
  }, Nr = function(e) {
@@ -1443,15 +1443,15 @@ var Lr = function(e, i, n, r) {
1443
1443
  a.push(y);
1444
1444
  }
1445
1445
  );
1446
- var d, u = [Pr, Nr];
1446
+ var d, l = [Pr, Nr];
1447
1447
  {
1448
- var l, c = [Ir, Rr(function(y) {
1449
- l.insert(y);
1450
- })], h = xr(u.concat(r, c)), f = function(w) {
1448
+ var u, c = [Ir, Rr(function(y) {
1449
+ u.insert(y);
1450
+ })], h = xr(l.concat(r, c)), f = function(w) {
1451
1451
  return Re(Er(w), h);
1452
1452
  };
1453
1453
  d = function(w, g, A, S) {
1454
- l = A, f(w ? w + "{" + g.styles + "}" : g.styles), S && (v.inserted[g.name] = !0);
1454
+ u = A, f(w ? w + "{" + g.styles + "}" : g.styles), S && (v.inserted[g.name] = !0);
1455
1455
  };
1456
1456
  }
1457
1457
  var v = {
@@ -1596,8 +1596,8 @@ function dt(t, e, i) {
1596
1596
  var d = i;
1597
1597
  if (e == null)
1598
1598
  return d;
1599
- var u = e[d];
1600
- return u !== void 0 ? u : d;
1599
+ var l = e[d];
1600
+ return l !== void 0 ? l : d;
1601
1601
  }
1602
1602
  function Vr(t, e, i) {
1603
1603
  var n = "";
@@ -1614,15 +1614,15 @@ function Vr(t, e, i) {
1614
1614
  for (var d = 0; d < s.length; d++)
1615
1615
  oi(s[d]) && (n += At(o) + ":" + si(o, s[d]) + ";");
1616
1616
  else {
1617
- var u = dt(t, e, s);
1617
+ var l = dt(t, e, s);
1618
1618
  switch (o) {
1619
1619
  case "animation":
1620
1620
  case "animationName": {
1621
- n += At(o) + ":" + u + ";";
1621
+ n += At(o) + ":" + l + ";";
1622
1622
  break;
1623
1623
  }
1624
1624
  default:
1625
- n += o + "{" + u + "}";
1625
+ n += o + "{" + l + "}";
1626
1626
  }
1627
1627
  }
1628
1628
  }
@@ -1647,9 +1647,9 @@ function bt(t, e, i) {
1647
1647
  r += d[a];
1648
1648
  }
1649
1649
  ai.lastIndex = 0;
1650
- for (var u = "", l; (l = ai.exec(r)) !== null; )
1651
- u += "-" + l[1];
1652
- var c = $r(r) + u;
1650
+ for (var l = "", u; (u = ai.exec(r)) !== null; )
1651
+ l += "-" + u[1];
1652
+ var c = $r(r) + l;
1653
1653
  return {
1654
1654
  name: c,
1655
1655
  styles: r,
@@ -1670,7 +1670,7 @@ var Gr = function(e, i, n) {
1670
1670
  // so we don't have to add it to registered cache.
1671
1671
  // this improves memory usage since we can avoid storing the whole style string
1672
1672
  e.registered[r] === void 0 && (e.registered[r] = i.styles);
1673
- }, qr = function(e, i, n) {
1673
+ }, Kr = function(e, i, n) {
1674
1674
  Gr(e, i);
1675
1675
  var r = e.key + "-" + i.name;
1676
1676
  if (e.inserted[i.name] === void 0) {
@@ -1688,33 +1688,33 @@ function li(t, e, i) {
1688
1688
  var n = [], r = $i(t, n, i);
1689
1689
  return n.length < 2 ? i : r + e(n);
1690
1690
  }
1691
- var Kr = function(e) {
1691
+ var qr = function(e) {
1692
1692
  var i = Mr(e);
1693
1693
  i.sheet.speedy = function(a) {
1694
1694
  this.isSpeedy = a;
1695
1695
  }, i.compat = !0;
1696
1696
  var n = function() {
1697
- for (var d = arguments.length, u = new Array(d), l = 0; l < d; l++)
1698
- u[l] = arguments[l];
1699
- var c = bt(u, i.registered, void 0);
1700
- return qr(i, c), i.key + "-" + c.name;
1697
+ for (var d = arguments.length, l = new Array(d), u = 0; u < d; u++)
1698
+ l[u] = arguments[u];
1699
+ var c = bt(l, i.registered, void 0);
1700
+ return Kr(i, c), i.key + "-" + c.name;
1701
1701
  }, r = function() {
1702
- for (var d = arguments.length, u = new Array(d), l = 0; l < d; l++)
1703
- u[l] = arguments[l];
1704
- var c = bt(u, i.registered), h = "animation-" + c.name;
1702
+ for (var d = arguments.length, l = new Array(d), u = 0; u < d; u++)
1703
+ l[u] = arguments[u];
1704
+ var c = bt(l, i.registered), h = "animation-" + c.name;
1705
1705
  return di(i, {
1706
1706
  name: c.name,
1707
1707
  styles: "@keyframes " + h + "{" + c.styles + "}"
1708
1708
  }), h;
1709
1709
  }, o = function() {
1710
- for (var d = arguments.length, u = new Array(d), l = 0; l < d; l++)
1711
- u[l] = arguments[l];
1712
- var c = bt(u, i.registered);
1710
+ for (var d = arguments.length, l = new Array(d), u = 0; u < d; u++)
1711
+ l[u] = arguments[u];
1712
+ var c = bt(l, i.registered);
1713
1713
  di(i, c);
1714
1714
  }, s = function() {
1715
- for (var d = arguments.length, u = new Array(d), l = 0; l < d; l++)
1716
- u[l] = arguments[l];
1717
- return li(i.registered, n, zr(u));
1715
+ for (var d = arguments.length, l = new Array(d), u = 0; u < d; u++)
1716
+ l[u] = arguments[u];
1717
+ return li(i.registered, n, zr(l));
1718
1718
  };
1719
1719
  return {
1720
1720
  css: n,
@@ -1722,8 +1722,8 @@ var Kr = function(e) {
1722
1722
  injectGlobal: o,
1723
1723
  keyframes: r,
1724
1724
  hydrate: function(d) {
1725
- d.forEach(function(u) {
1726
- i.inserted[u] = !0;
1725
+ d.forEach(function(l) {
1726
+ i.inserted[l] = !0;
1727
1727
  });
1728
1728
  },
1729
1729
  flush: function() {
@@ -1759,19 +1759,19 @@ var Kr = function(e) {
1759
1759
  }
1760
1760
  }
1761
1761
  return i;
1762
- }, Wr = Kr({
1762
+ }, Wr = qr({
1763
1763
  key: "css"
1764
1764
  }), G = Wr.css, Dt, Q, pt, ui, ci = 0, Fi = [], B = Te, hi = B.__b, fi = B.__r, vi = B.diffed, yi = B.__c, gi = B.unmount, wi = B.__;
1765
- function Hr(t, e) {
1765
+ function Jr(t, e) {
1766
1766
  B.__h && B.__h(Q, t, ci || e), ci = 0;
1767
1767
  var i = Q.__H || (Q.__H = { __: [], __h: [] });
1768
1768
  return t >= i.__.length && i.__.push({}), i.__[t];
1769
1769
  }
1770
1770
  function Ui(t, e) {
1771
- var i = Hr(Dt++, 7);
1771
+ var i = Jr(Dt++, 7);
1772
1772
  return Xr(i.__H, e) && (i.__ = t(), i.__H = e, i.__h = t), i.__;
1773
1773
  }
1774
- function Jr() {
1774
+ function Hr() {
1775
1775
  for (var t; t = Fi.shift(); )
1776
1776
  if (t.__P && t.__H)
1777
1777
  try {
@@ -1793,7 +1793,7 @@ B.__b = function(t) {
1793
1793
  }, B.diffed = function(t) {
1794
1794
  vi && vi(t);
1795
1795
  var e = t.__c;
1796
- e && e.__H && (e.__H.__h.length && (Fi.push(e) !== 1 && ui === B.requestAnimationFrame || ((ui = B.requestAnimationFrame) || Yr)(Jr)), e.__H.__.forEach(function(i) {
1796
+ e && e.__H && (e.__H.__h.length && (Fi.push(e) !== 1 && ui === B.requestAnimationFrame || ((ui = B.requestAnimationFrame) || Yr)(Hr)), e.__H.__.forEach(function(i) {
1797
1797
  i.u && (i.__H = i.u), i.u = void 0;
1798
1798
  })), pt = Q = null;
1799
1799
  }, B.__c = function(t, e) {
@@ -1961,7 +1961,7 @@ function Gi(t) {
1961
1961
  }
1962
1962
  }
1963
1963
  }
1964
- function qi(t) {
1964
+ function Ki(t) {
1965
1965
  for (var e = t.s, i = void 0; e !== void 0; ) {
1966
1966
  var n = e.p;
1967
1967
  e.i === -1 ? (e.S.U(e), n !== void 0 && (n.n = e.n), e.n !== void 0 && (e.n.p = n)) : i = e, e.S.n = e.r, e.r !== void 0 && (e.r = void 0), e = n;
@@ -1986,7 +1986,7 @@ function Pe(t) {
1986
1986
  } catch (i) {
1987
1987
  this.v = i, this.f |= 16, this.i++;
1988
1988
  }
1989
- return T = t, qi(this), this.f &= -2, !0;
1989
+ return T = t, Ki(this), this.f &= -2, !0;
1990
1990
  };
1991
1991
  Pe.prototype.S = function(t) {
1992
1992
  if (this.t === void 0) {
@@ -2021,7 +2021,7 @@ Object.defineProperty(Pe.prototype, "value", { get: function() {
2021
2021
  function Ue(t) {
2022
2022
  return new Pe(t);
2023
2023
  }
2024
- function Ki(t) {
2024
+ function qi(t) {
2025
2025
  var e = t.u;
2026
2026
  if (t.u = void 0, typeof e == "function") {
2027
2027
  be++;
@@ -2039,17 +2039,17 @@ function Ki(t) {
2039
2039
  function Ut(t) {
2040
2040
  for (var e = t.s; e !== void 0; e = e.n)
2041
2041
  e.S.U(e);
2042
- t.x = void 0, t.s = void 0, Ki(t);
2042
+ t.x = void 0, t.s = void 0, qi(t);
2043
2043
  }
2044
2044
  function Zr(t) {
2045
2045
  if (T !== this)
2046
2046
  throw new Error("Out-of-order effect");
2047
- qi(this), T = t, this.f &= -2, 8 & this.f && Ut(this), vt();
2047
+ Ki(this), T = t, this.f &= -2, 8 & this.f && Ut(this), vt();
2048
2048
  }
2049
- function Ke(t) {
2049
+ function qe(t) {
2050
2050
  this.x = t, this.u = void 0, this.s = void 0, this.o = void 0, this.f = 32;
2051
2051
  }
2052
- Ke.prototype.c = function() {
2052
+ qe.prototype.c = function() {
2053
2053
  var t = this.S();
2054
2054
  try {
2055
2055
  if (8 & this.f || this.x === void 0)
@@ -2060,21 +2060,21 @@ Ke.prototype.c = function() {
2060
2060
  t();
2061
2061
  }
2062
2062
  };
2063
- Ke.prototype.S = function() {
2063
+ qe.prototype.S = function() {
2064
2064
  if (1 & this.f)
2065
2065
  throw new Error("Cycle detected");
2066
- this.f |= 1, this.f &= -9, Ki(this), Gi(this), be++;
2066
+ this.f |= 1, this.f &= -9, qi(this), Gi(this), be++;
2067
2067
  var t = T;
2068
2068
  return T = this, Zr.bind(this, t);
2069
2069
  };
2070
- Ke.prototype.N = function() {
2070
+ qe.prototype.N = function() {
2071
2071
  2 & this.f || (this.f |= 2, this.o = Fe, Fe = this);
2072
2072
  };
2073
- Ke.prototype.d = function() {
2073
+ qe.prototype.d = function() {
2074
2074
  this.f |= 8, 1 & this.f || Ut(this);
2075
2075
  };
2076
2076
  function ze(t) {
2077
- var e = new Ke(t);
2077
+ var e = new qe(t);
2078
2078
  try {
2079
2079
  e.c();
2080
2080
  } catch (i) {
@@ -2093,8 +2093,8 @@ function Ne(t, e) {
2093
2093
  function ut(t) {
2094
2094
  _t && _t(), _t = t && t.S();
2095
2095
  }
2096
- function Hi(t) {
2097
- var e = this, i = t.data, n = Ji(i);
2096
+ function Ji(t) {
2097
+ var e = this, i = t.data, n = Hi(i);
2098
2098
  n.value = i;
2099
2099
  var r = Ui(function() {
2100
2100
  for (var a = e, d = e.__v; d = d.__; )
@@ -2102,25 +2102,25 @@ function Hi(t) {
2102
2102
  d.__c.__$f |= 4;
2103
2103
  break;
2104
2104
  }
2105
- var u = Ue(function() {
2105
+ var l = Ue(function() {
2106
2106
  var f = n.value.value;
2107
2107
  return f === 0 ? 0 : f === !0 ? "" : f || "";
2108
- }), l = Ue(function() {
2109
- return !Array.isArray(u.value) && !fn(u.value);
2108
+ }), u = Ue(function() {
2109
+ return !Array.isArray(l.value) && !fn(l.value);
2110
2110
  }), c = ze(function() {
2111
- if (this.N = Yi, l.value) {
2112
- var f = u.value;
2111
+ if (this.N = Yi, u.value) {
2112
+ var f = l.value;
2113
2113
  a.__v && a.__v.__e && a.__v.__e.nodeType === 3 && (a.__v.__e.data = f);
2114
2114
  }
2115
2115
  }), h = e.__$u.d;
2116
2116
  return e.__$u.d = function() {
2117
2117
  c(), h.call(this);
2118
- }, [l, u];
2118
+ }, [u, l];
2119
2119
  }, []), o = r[0], s = r[1];
2120
2120
  return o.value ? s.peek() : s.value;
2121
2121
  }
2122
- Hi.displayName = "_st";
2123
- Object.defineProperties(U.prototype, { constructor: { configurable: !0, value: void 0 }, type: { configurable: !0, value: Hi }, props: { configurable: !0, get: function() {
2122
+ Ji.displayName = "_st";
2123
+ Object.defineProperties(U.prototype, { constructor: { configurable: !0, value: void 0 }, type: { configurable: !0, value: Ji }, props: { configurable: !0, get: function() {
2124
2124
  return { data: this };
2125
2125
  } }, __b: { configurable: !0, value: 1 } });
2126
2126
  Ne("__b", function(t, e) {
@@ -2164,8 +2164,8 @@ Ne("diffed", function(t, e) {
2164
2164
  else
2165
2165
  o = {}, i.U = o;
2166
2166
  for (var d in n) {
2167
- var u = o[d], l = n[d];
2168
- u === void 0 ? (u = eo(i, d, l, r), o[d] = u) : u.o(l, r);
2167
+ var l = o[d], u = n[d];
2168
+ l === void 0 ? (l = eo(i, d, u, r), o[d] = l) : l.o(u, r);
2169
2169
  }
2170
2170
  }
2171
2171
  }
@@ -2224,7 +2224,7 @@ hn.prototype.shouldComponentUpdate = function(t, e) {
2224
2224
  return !0;
2225
2225
  return !1;
2226
2226
  };
2227
- function Ji(t) {
2227
+ function Hi(t) {
2228
2228
  return Ui(function() {
2229
2229
  return k(t);
2230
2230
  }, []);
@@ -2284,11 +2284,11 @@ function m(t, e, i, n, r, o) {
2284
2284
  if ("ref" in d)
2285
2285
  for (a in d = {}, e)
2286
2286
  a == "ref" ? s = e[a] : d[a] = e[a];
2287
- var u = { type: t, props: d, key: i, ref: s, __k: null, __: null, __b: 0, __e: null, __c: null, constructor: void 0, __v: --ro, __i: -1, __u: 0, __source: r, __self: o };
2287
+ var l = { type: t, props: d, key: i, ref: s, __k: null, __: null, __b: 0, __e: null, __c: null, constructor: void 0, __v: --ro, __i: -1, __u: 0, __source: r, __self: o };
2288
2288
  if (typeof t == "function" && (s = t.defaultProps))
2289
2289
  for (a in s)
2290
2290
  d[a] === void 0 && (d[a] = s[a]);
2291
- return Te.vnode && Te.vnode(u), u;
2291
+ return Te.vnode && Te.vnode(l), l;
2292
2292
  }
2293
2293
  const oo = G`
2294
2294
  ${M}
@@ -2467,7 +2467,7 @@ const oo = G`
2467
2467
  const {
2468
2468
  startTimestamp: o,
2469
2469
  timerPaused: s
2470
- } = r, a = Ji(e);
2470
+ } = r, a = Hi(e);
2471
2471
  no(() => {
2472
2472
  a.value > 0 ? a.value -= 1 : P(() => {
2473
2473
  s.value = !0, a.value = 0;
@@ -2478,14 +2478,14 @@ const oo = G`
2478
2478
  return !1;
2479
2479
  const f = Date.now() - o.value;
2480
2480
  return a.value > 0 && e - a.value >= 5 && f >= 5e3;
2481
- }), u = Ue(() => {
2481
+ }), l = Ue(() => {
2482
2482
  if (i === "interstitial")
2483
2483
  return !0;
2484
2484
  if (!o.value)
2485
2485
  return !1;
2486
2486
  const f = Date.now() - o.value;
2487
2487
  return a.value <= 0 && f >= (e - 1) * 1e3 && e > 5;
2488
- }), l = Ue(() => i === "interstitial" ? !1 : !d.value && !u.value), c = async () => {
2488
+ }), u = Ue(() => i === "interstitial" ? !1 : !d.value && !l.value), c = async () => {
2489
2489
  if (s.value = !0, !await lo({
2490
2490
  title: "Are you sure?",
2491
2491
  content: "You will lose your reward if you dismiss this Ad."
@@ -2507,8 +2507,8 @@ const oo = G`
2507
2507
  className: "timer",
2508
2508
  children: [a.value, "s"]
2509
2509
  }), m("button", {
2510
- onClick: d.value ? c : u.value ? h : void 0,
2511
- disabled: l.value,
2510
+ onClick: d.value ? c : l.value ? h : void 0,
2511
+ disabled: u.value,
2512
2512
  children: m("svg", {
2513
2513
  width: "12",
2514
2514
  height: "12",
@@ -2566,8 +2566,8 @@ const oo = G`
2566
2566
  adLoaded: s,
2567
2567
  visible: a,
2568
2568
  countdown: d,
2569
- src: u,
2570
- mode: l
2569
+ src: l,
2570
+ mode: u
2571
2571
  } = e, c = yn(() => ho(), []), [h, f] = _e(!1), v = (w) => {
2572
2572
  var g, A, S, p;
2573
2573
  a.value = !1, w === "dismiss" ? (g = n.value) == null || g.call(n) : w === "viewed" && ((A = r.value) == null || A.call(r)), (S = i.value) == null || S.call(i), (p = o.value) == null || p.call(o), f(!1);
@@ -2576,18 +2576,18 @@ const oo = G`
2576
2576
  h || (f(!0), (w = s.value) == null || w.call(s));
2577
2577
  }, [h]);
2578
2578
  return Ce(() => {
2579
- h && (l.value === "reward" || l.value === "rewarded_insterstitial") && setTimeout(() => {
2579
+ h && (u.value === "reward" || u.value === "rewarded_insterstitial") && setTimeout(() => {
2580
2580
  c.startTimer();
2581
2581
  }, 100);
2582
- }, [h, l.value]), a.value ? m("div", {
2582
+ }, [h, u.value]), a.value ? m("div", {
2583
2583
  className: vo,
2584
2584
  children: [m(fo, {
2585
- mode: l.value,
2585
+ mode: u.value,
2586
2586
  onClose: v,
2587
2587
  countdown: d.value,
2588
2588
  state: c
2589
2589
  }), a.value && m("iframe", {
2590
- src: u.value,
2590
+ src: l.value,
2591
2591
  onLoad: y,
2592
2592
  sandbox: "allow-scripts allow-same-origin allow-forms allow-modals allow-downloads allow-popups allow-popups-to-escape-sandbox allow-top-navigation-by-user-activation allow-top-navigation allow-top-navigation-by-user-activation allow-top-navigation-to-custom-protocols"
2593
2593
  }), m(uo, {})]
@@ -2634,7 +2634,7 @@ class wo {
2634
2634
  };
2635
2635
  }
2636
2636
  async adBreak(e, i) {
2637
- var n, r, o, s, a, d, u, l;
2637
+ var n, r, o, s, a, d, l, u;
2638
2638
  if (!this.initialized || !this.adsOverlay || !i.params.url) {
2639
2639
  (n = e.adBreakDone) == null || n.call(e, {
2640
2640
  breakType: e.type,
@@ -2691,7 +2691,7 @@ class wo {
2691
2691
  breakName: this.lastUnDisplayedAdBreak.type === "preroll" ? "" : this.lastUnDisplayedAdBreak.name,
2692
2692
  breakFormat: this.lastUnDisplayedAdBreak.type === "reward" ? "reward" : "interstitial",
2693
2693
  breakStatus: "ignored"
2694
- }), this.lastUnDisplayedAdBreak = null), (u = e.beforeAd) == null || u.call(e);
2694
+ }), this.lastUnDisplayedAdBreak = null), (l = e.beforeAd) == null || l.call(e);
2695
2695
  const c = () => {
2696
2696
  var g;
2697
2697
  this.adsIsShowing = !1, (g = e.afterAd) == null || g.call(e);
@@ -2729,7 +2729,7 @@ class wo {
2729
2729
  this.state.countdown.value = (A = i.params.countdown) != null ? A : 15, this.state.src.value = i.params.url, this.state.mode.value = "reward", this.state.visible.value = !0;
2730
2730
  });
2731
2731
  };
2732
- this.lastUnDisplayedAdBreak = e, (l = e.beforeReward) == null || l.call(e, w);
2732
+ this.lastUnDisplayedAdBreak = e, (u = e.beforeReward) == null || u.call(e, w);
2733
2733
  break;
2734
2734
  }
2735
2735
  }
@@ -2842,10 +2842,10 @@ const Ao = () => {
2842
2842
  adLoaded: s,
2843
2843
  adError: a,
2844
2844
  visible: d,
2845
- payload: u
2846
- } = e, [l, c] = _e(!1), [h, f] = _e(0), [v, y] = _e(!1), [w, g] = _e(!1), [A, S] = _e("Loading next content..."), p = mi(null), _ = u.value, E = kt((L) => {
2847
- var C, W, q, I;
2848
- c(!1), d.value = !1, L === "dismiss" ? (C = n.value) == null || C.call(n) : (W = r.value) == null || W.call(r), (q = i.value) == null || q.call(i), (I = o.value) == null || I.call(o);
2845
+ payload: l
2846
+ } = e, [u, c] = _e(!1), [h, f] = _e(0), [v, y] = _e(!1), [w, g] = _e(!1), [A, S] = _e("Loading next content..."), p = mi(null), _ = l.value, E = kt((L) => {
2847
+ var C, W, K, I;
2848
+ c(!1), d.value = !1, L === "dismiss" ? (C = n.value) == null || C.call(n) : (W = r.value) == null || W.call(r), (K = i.value) == null || K.call(i), (I = o.value) == null || I.call(o);
2849
2849
  }, [d, n, r, i, o]), b = kt(() => {
2850
2850
  var L;
2851
2851
  c(!1), d.value = !1, (L = a.value) == null || L.call(a);
@@ -2860,14 +2860,14 @@ const Ao = () => {
2860
2860
  if (f(C), g(_.mode === "reward" ? C === 0 : !0), y(_.mode === "interstitial" ? C === 0 : !1), C === 0)
2861
2861
  return;
2862
2862
  let W = C;
2863
- const q = window.setInterval(() => {
2864
- W -= 1, f(Math.max(W, 0)), W <= 0 && (window.clearInterval(q), _.mode === "reward" ? g(!0) : y(!0));
2863
+ const K = window.setInterval(() => {
2864
+ W -= 1, f(Math.max(W, 0)), W <= 0 && (window.clearInterval(K), _.mode === "reward" ? g(!0) : y(!0));
2865
2865
  }, 1e3);
2866
2866
  return () => {
2867
- window.clearInterval(q);
2867
+ window.clearInterval(K);
2868
2868
  };
2869
2869
  }, [d.value, _, E]), Ce(() => {
2870
- var q;
2870
+ var K;
2871
2871
  if (!d.value || !_)
2872
2872
  return;
2873
2873
  const L = p.current;
@@ -2875,7 +2875,7 @@ const Ao = () => {
2875
2875
  return;
2876
2876
  if (L.innerHTML = "", S("Loading next content..."), c(!1), _.testMode) {
2877
2877
  const I = document.createElement("div");
2878
- I.className = bi, I.innerText = "Preview slot placeholder", L.appendChild(I), c(!0), (q = s.value) == null || q.call(s);
2878
+ I.className = bi, I.innerText = "Preview slot placeholder", L.appendChild(I), c(!0), (K = s.value) == null || K.call(s);
2879
2879
  return;
2880
2880
  }
2881
2881
  if (typeof window == "undefined") {
@@ -2921,7 +2921,7 @@ const Ao = () => {
2921
2921
  }), m("div", {
2922
2922
  className: Eo,
2923
2923
  ref: p,
2924
- children: !l && m("div", {
2924
+ children: !u && m("div", {
2925
2925
  className: bi,
2926
2926
  children: A
2927
2927
  })
@@ -2943,7 +2943,7 @@ const Ao = () => {
2943
2943
  })
2944
2944
  });
2945
2945
  };
2946
- function K(t, e, i) {
2946
+ function q(t, e, i) {
2947
2947
  return (e = To(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
2948
2948
  }
2949
2949
  function To(t) {
@@ -2964,7 +2964,7 @@ function Co(t, e) {
2964
2964
  }
2965
2965
  class Oo {
2966
2966
  constructor(e, i) {
2967
- if (K(this, "name", "ADSENSE_BANNER_AS_AFG"), K(this, "initialized", !1), K(this, "initCompleter", null), K(this, "context", void 0), K(this, "contextInfo", void 0), K(this, "initParams", void 0), K(this, "defaultCountdown", 5), K(this, "adsOverlay", null), K(this, "adsIsShowing", !1), K(this, "lastUnDisplayedAdBreak", null), K(this, "requestCounter", 0), K(this, "scriptPromise", null), K(this, "scriptReady", !1), K(this, "scriptFailed", !1), K(this, "state", Ao()), this.context = e, this.contextInfo = this.context.getContextInfo(), this.initParams = i, typeof window != "undefined") {
2967
+ if (q(this, "name", "ADSENSE_BANNER_AS_AFG"), q(this, "initialized", !1), q(this, "initCompleter", null), q(this, "context", void 0), q(this, "contextInfo", void 0), q(this, "initParams", void 0), q(this, "defaultCountdown", 5), q(this, "adsOverlay", null), q(this, "adsIsShowing", !1), q(this, "lastUnDisplayedAdBreak", null), q(this, "requestCounter", 0), q(this, "scriptPromise", null), q(this, "scriptReady", !1), q(this, "scriptFailed", !1), q(this, "state", Ao()), this.context = e, this.contextInfo = this.context.getContextInfo(), this.initParams = i, typeof window != "undefined") {
2968
2968
  const n = window;
2969
2969
  n.adsbygoogle = n.adsbygoogle || [];
2970
2970
  }
@@ -3041,7 +3041,7 @@ class Oo {
3041
3041
  this.state.payload.value = r, this.state.visible.value = !0;
3042
3042
  }
3043
3043
  adBreak(e, i) {
3044
- var s, a, d, u, l, c, h, f, v;
3044
+ var s, a, d, l, u, c, h, f, v;
3045
3045
  const n = e.type === "preroll" ? "" : e.name, r = e.type === "reward" ? "reward" : "interstitial";
3046
3046
  if (!this.initialized || !this.adsOverlay) {
3047
3047
  (s = e.adBreakDone) == null || s.call(e, {
@@ -3073,7 +3073,7 @@ class Oo {
3073
3073
  }
3074
3074
  switch (e.type) {
3075
3075
  case "preroll": {
3076
- (u = e.adBreakDone) == null || u.call(e, {
3076
+ (l = e.adBreakDone) == null || l.call(e, {
3077
3077
  breakType: e.type,
3078
3078
  breakName: "",
3079
3079
  breakFormat: "interstitial",
@@ -3085,7 +3085,7 @@ class Oo {
3085
3085
  case "browse":
3086
3086
  case "next":
3087
3087
  case "pause": {
3088
- (l = e.beforeAd) == null || l.call(e);
3088
+ (u = e.beforeAd) == null || u.call(e);
3089
3089
  const y = {
3090
3090
  breakType: e.type,
3091
3091
  breakName: e.name,
@@ -3212,8 +3212,8 @@ const Ee = (t, e) => {
3212
3212
  adLoaded: s,
3213
3213
  adLinkClicked: a,
3214
3214
  visible: d,
3215
- src: u
3216
- } = e, [l, c] = _e(!1), h = (v) => {
3215
+ src: l
3216
+ } = e, [u, c] = _e(!1), h = (v) => {
3217
3217
  var y, w, g, A;
3218
3218
  c(!1), d.value = !1, v === "dismiss" ? (y = n.value) == null || y.call(n) : v === "viewed" && ((w = r.value) == null || w.call(r)), (g = i.value) == null || g.call(i), (A = o.value) == null || A.call(o);
3219
3219
  }, f = () => {
@@ -3226,10 +3226,10 @@ const Ee = (t, e) => {
3226
3226
  }), Ee("appsrockets_ad_loaded", () => c(!0)), d.value ? m("div", {
3227
3227
  className: Do,
3228
3228
  style: {
3229
- display: l ? "flex" : "none"
3229
+ display: u ? "flex" : "none"
3230
3230
  },
3231
3231
  children: d.value && m("iframe", {
3232
- src: u.value,
3232
+ src: l.value,
3233
3233
  onLoad: f,
3234
3234
  allowFullScreen: !0,
3235
3235
  allow: "autoplay",
@@ -3282,7 +3282,7 @@ class Lo {
3282
3282
  };
3283
3283
  }
3284
3284
  adBreak(e, i) {
3285
- var o, s, a, d, u, l, c, h;
3285
+ var o, s, a, d, l, u, c, h;
3286
3286
  if (!this.initialized || !this.adsOverlay || !i.params.url) {
3287
3287
  (o = e.adBreakDone) == null || o.call(e, {
3288
3288
  breakType: e.type,
@@ -3346,7 +3346,7 @@ class Lo {
3346
3346
  break;
3347
3347
  }
3348
3348
  case "reward": {
3349
- this.lastUnDisplayedAdBreak && ((l = (u = this.lastUnDisplayedAdBreak).adBreakDone) == null || l.call(u, {
3349
+ this.lastUnDisplayedAdBreak && ((u = (l = this.lastUnDisplayedAdBreak).adBreakDone) == null || u.call(l, {
3350
3350
  breakType: this.lastUnDisplayedAdBreak.type,
3351
3351
  breakName: this.lastUnDisplayedAdBreak.type === "preroll" ? "" : this.lastUnDisplayedAdBreak.name,
3352
3352
  breakFormat: this.lastUnDisplayedAdBreak.type === "reward" ? "reward" : "interstitial",
@@ -3471,8 +3471,8 @@ let nn = class {
3471
3471
  else {
3472
3472
  const o = (s) => {
3473
3473
  s.slot === this.rewardedSlot && this.adsContext && (googletag.pubads().removeEventListener("rewardedSlotReady", o), this.readyEvent = s, this.adsContext.beforeReward(() => {
3474
- var a, d, u;
3475
- (d = (a = this.adsContext) == null ? void 0 : a.beforeAd) == null || d.call(a), (u = this.readyEvent) == null || u.makeRewardedVisible();
3474
+ var a, d, l;
3475
+ (d = (a = this.adsContext) == null ? void 0 : a.beforeAd) == null || d.call(a), (l = this.readyEvent) == null || l.makeRewardedVisible();
3476
3476
  }));
3477
3477
  };
3478
3478
  googletag.pubads().addEventListener("rewardedSlotReady", o), window.setTimeout(() => {
@@ -3485,7 +3485,7 @@ let nn = class {
3485
3485
  });
3486
3486
  }
3487
3487
  };
3488
- function J(t, e, i) {
3488
+ function H(t, e, i) {
3489
3489
  return (e = $o(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
3490
3490
  }
3491
3491
  function $o(t) {
@@ -3507,28 +3507,28 @@ function Fo(t, e) {
3507
3507
  class Uo {
3508
3508
  constructor(e, i, n) {
3509
3509
  var r = this;
3510
- J(this, "adUnit", void 0), J(this, "project", void 0), J(this, "keyValue", void 0), J(this, "adsContext", null), J(this, "gamingInterstitialSlot", null), J(this, "readyEvent", null), J(this, "isRetrying", !1), J(this, "withCommand", function() {
3510
+ H(this, "adUnit", void 0), H(this, "project", void 0), H(this, "keyValue", void 0), H(this, "adsContext", null), H(this, "gamingInterstitialSlot", null), H(this, "readyEvent", null), H(this, "isRetrying", !1), H(this, "withCommand", function() {
3511
3511
  googletag.cmd.push(...arguments);
3512
- }), J(this, "init", () => {
3512
+ }), H(this, "init", () => {
3513
3513
  var o;
3514
3514
  this.gamingInterstitialSlot = googletag.defineOutOfPageSlot(this.adUnit, googletag.enums.OutOfPageFormat.GAME_MANUAL_INTERSTITIAL), this.gamingInterstitialSlot && (this.gamingInterstitialSlot.addService(googletag.pubads()), googletag.pubads().addEventListener("gameManualInterstitialSlotReady", this.handleSlotReady), googletag.pubads().addEventListener("gameManualInterstitialSlotClosed", this.handleSlotClosed), this.keyValue && (Object.keys(this.keyValue).forEach((s) => {
3515
3515
  var a;
3516
3516
  (a = this.gamingInterstitialSlot) == null || a.setTargeting(s, this.keyValue[s]);
3517
3517
  }), Object.keys(this.keyValue).includes("project") || (o = this.gamingInterstitialSlot) == null || o.setTargeting("project", this.project)), googletag.display(this.gamingInterstitialSlot));
3518
- }), J(this, "destroy", function(o) {
3518
+ }), H(this, "destroy", function(o) {
3519
3519
  var a, d;
3520
3520
  (arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0) && ((d = (a = r.adsContext) == null ? void 0 : a.onEnd) == null || d.call(a, o), o !== "ignored" && (r.adsContext = null)), googletag.pubads().removeEventListener("gameManualInterstitialSlotReady", r.handleSlotReady), googletag.pubads().removeEventListener("gameManualInterstitialSlotClosed", r.handleSlotClosed), r.gamingInterstitialSlot && (googletag.destroySlots([r.gamingInterstitialSlot]), r.gamingInterstitialSlot = null, r.readyEvent = null);
3521
- }), J(this, "reinit", function(o) {
3521
+ }), H(this, "reinit", function(o) {
3522
3522
  let s = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0;
3523
3523
  r.destroy(o, s), r.init();
3524
- }), J(this, "handleSlotReady", (o) => {
3524
+ }), H(this, "handleSlotReady", (o) => {
3525
3525
  this.gamingInterstitialSlot === o.slot && (this.readyEvent = o);
3526
- }), J(this, "handleSlotClosed", (o) => {
3526
+ }), H(this, "handleSlotClosed", (o) => {
3527
3527
  var s, a;
3528
3528
  this.adsContext && this.gamingInterstitialSlot === o.slot && ((a = (s = this.adsContext).afterAd) == null || a.call(s), this.withCommand(() => {
3529
3529
  this.reinit("viewed");
3530
3530
  }));
3531
- }), J(this, "requestAds", (o) => {
3531
+ }), H(this, "requestAds", (o) => {
3532
3532
  this.withCommand(() => {
3533
3533
  var s, a, d;
3534
3534
  if (this.adsContext) {
@@ -3651,13 +3651,13 @@ class Go {
3651
3651
  }
3652
3652
  }
3653
3653
  function mt(t, e, i) {
3654
- return (e = qo(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
3654
+ return (e = Ko(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
3655
3655
  }
3656
- function qo(t) {
3657
- var e = Ko(t, "string");
3656
+ function Ko(t) {
3657
+ var e = qo(t, "string");
3658
3658
  return typeof e == "symbol" ? e : e + "";
3659
3659
  }
3660
- function Ko(t, e) {
3660
+ function qo(t, e) {
3661
3661
  if (typeof t != "object" || !t)
3662
3662
  return t;
3663
3663
  var i = t[Symbol.toPrimitive];
@@ -3722,10 +3722,10 @@ function z(t, e, i) {
3722
3722
  return (e = Wo(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
3723
3723
  }
3724
3724
  function Wo(t) {
3725
- var e = Ho(t, "string");
3725
+ var e = Jo(t, "string");
3726
3726
  return typeof e == "symbol" ? e : e + "";
3727
3727
  }
3728
- function Ho(t, e) {
3728
+ function Jo(t, e) {
3729
3729
  if (typeof t != "object" || !t)
3730
3730
  return t;
3731
3731
  var i = t[Symbol.toPrimitive];
@@ -3800,7 +3800,7 @@ class rn {
3800
3800
  }
3801
3801
  const a = r === "afv" ? void 0 : "cached", {
3802
3802
  data: d,
3803
- code: u
3803
+ code: l
3804
3804
  } = await this.context.httpClient.post("/api/ads/info", {
3805
3805
  data: {
3806
3806
  contextData: this.requestContext.getRequestContextData(o),
@@ -3810,8 +3810,8 @@ class rn {
3810
3810
  name: a
3811
3811
  }
3812
3812
  });
3813
- return u === "SUCCESS" || u === "BYPASS_ADS" ? {
3814
- code: u,
3813
+ return l === "SUCCESS" || l === "BYPASS_ADS" ? {
3814
+ code: l,
3815
3815
  data: d
3816
3816
  } : null;
3817
3817
  }), z(this, "cacheRewardInfo", () => {
@@ -3834,7 +3834,7 @@ class rn {
3834
3834
  }), this.context = e, this.contextInfo = this.context.getContextInfo(), this.requestContext = new jt(e), i != null && i.reward && this.cacheRewardInfo(), i != null && i.interstitial && this.cacheInterstitialInfo("start"), i != null && i.afv && this.cacheAFVInfo();
3835
3835
  }
3836
3836
  }
3837
- function Jo(t, e, i) {
3837
+ function Ho(t, e, i) {
3838
3838
  return (e = Yo(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
3839
3839
  }
3840
3840
  function Yo(t) {
@@ -3865,7 +3865,7 @@ const Qo = function(t) {
3865
3865
  };
3866
3866
  class on {
3867
3867
  constructor(e) {
3868
- this.context = e, Jo(this, "canIUseHelper", void 0), this.context = e;
3868
+ this.context = e, Ho(this, "canIUseHelper", void 0), this.context = e;
3869
3869
  const {
3870
3870
  canIUseNative: i
3871
3871
  } = gn(() => this.context.getContextInfo().deviceInfo.nativeSDKVersionCode || 1e6, () => this.context.getContextInfo().deviceInfo.platform || "h5");
@@ -3927,11 +3927,11 @@ class on {
3927
3927
  const s = () => {
3928
3928
  wn("onAdsStateChange", a), o && (clearTimeout(o), o = null);
3929
3929
  }, a = (d) => {
3930
- var l;
3930
+ var u;
3931
3931
  if (d.UUID !== n)
3932
3932
  return;
3933
- const u = (l = e.callbacks) == null ? void 0 : l[d.event];
3934
- u && Qo(u, d.data), ["onAdClosed", "onAdError", "onAdDismissed"].includes(d.event) && s();
3933
+ const l = (u = e.callbacks) == null ? void 0 : u[d.event];
3934
+ l && Qo(l, d.data), ["onAdClosed", "onAdError", "onAdDismissed"].includes(d.event) && s();
3935
3935
  };
3936
3936
  An("onAdsStateChange", a), r > 0 && (o = setTimeout(() => {
3937
3937
  s(), console.warn(`[JoliboxSDK] Event listener for ad ${n} auto-cleaned after ${r}ms timeout`);
@@ -4020,11 +4020,11 @@ class ts {
4020
4020
  }
4021
4021
  let n = !1, r = !1;
4022
4022
  this.adsContext.beforeReward(async () => {
4023
- var d, u;
4024
- (u = (d = this.adsContext) == null ? void 0 : d.beforeAd) == null || u.call(d);
4025
- const o = (l) => {
4023
+ var d, l;
4024
+ (l = (d = this.adsContext) == null ? void 0 : d.beforeAd) == null || l.call(d);
4025
+ const o = (u) => {
4026
4026
  var c, h, f;
4027
- r || (r = !0, l === "dismissed" && ((c = this.adsContext) == null || c.adDismissed()), (f = (h = this.adsContext) == null ? void 0 : h.afterAd) == null || f.call(h), this.reinit(l));
4027
+ r || (r = !0, u === "dismissed" && ((c = this.adsContext) == null || c.adDismissed()), (f = (h = this.adsContext) == null ? void 0 : h.afterAd) == null || f.call(h), this.reinit(u));
4028
4028
  }, s = {
4029
4029
  onAdShow: () => {
4030
4030
  },
@@ -4032,8 +4032,8 @@ class ts {
4032
4032
  o("error");
4033
4033
  },
4034
4034
  onAdRewarded: () => {
4035
- var l;
4036
- n = !0, (l = this.adsContext) == null || l.adViewed();
4035
+ var u;
4036
+ n = !0, (u = this.adsContext) == null || u.adViewed();
4037
4037
  },
4038
4038
  onAdDismissed: () => {
4039
4039
  o(n ? "viewed" : "dismissed");
@@ -4098,16 +4098,16 @@ class rs {
4098
4098
  this.destroy("notReady");
4099
4099
  }
4100
4100
  }), he(this, "showAd", async () => {
4101
- var d, u;
4101
+ var d, l;
4102
4102
  if (!this.adsContext) {
4103
4103
  this.destroy("error");
4104
4104
  return;
4105
4105
  }
4106
4106
  let r = !1;
4107
- (u = (d = this.adsContext).beforeAd) == null || u.call(d);
4108
- const o = (l) => {
4107
+ (l = (d = this.adsContext).beforeAd) == null || l.call(d);
4108
+ const o = (u) => {
4109
4109
  var c, h;
4110
- r || (r = !0, (h = (c = this.adsContext) == null ? void 0 : c.afterAd) == null || h.call(c), this.reinit(l));
4110
+ r || (r = !0, (h = (c = this.adsContext) == null ? void 0 : c.afterAd) == null || h.call(c), this.reinit(u));
4111
4111
  }, s = {
4112
4112
  onAdShow: () => {
4113
4113
  },
@@ -4229,8 +4229,8 @@ class as {
4229
4229
  beforeAd: s.beforeAd,
4230
4230
  afterAd: s.afterAd,
4231
4231
  onEnd: (d) => {
4232
- var u;
4233
- (u = e.adBreakDone) == null || u.call(e, {
4232
+ var l;
4233
+ (l = e.adBreakDone) == null || l.call(e, {
4234
4234
  breakName: s.name,
4235
4235
  breakType: e.type,
4236
4236
  breakFormat: "interstitial",
@@ -4245,6 +4245,9 @@ class as {
4245
4245
  }
4246
4246
  const St = "jolibox-nb-proxy";
4247
4247
  let ds = 0;
4248
+ function ls(t, e) {
4249
+ return e === "call" && t.join(".") === "GameSDK.showRewardAd" ? 0 : 15e3;
4250
+ }
4248
4251
  function pi(t, e, i, n) {
4249
4252
  return new Promise((r, o) => {
4250
4253
  if (!window.parent || window.parent === window) {
@@ -4252,11 +4255,11 @@ function pi(t, e, i, n) {
4252
4255
  return;
4253
4256
  }
4254
4257
  const s = `${St}-${++ds}`, a = (u) => {
4255
- const l = u.data;
4256
- (l == null ? void 0 : l.type) === `${St}:response` && l.id === s && (window.removeEventListener("message", a), clearTimeout(d), l.error ? o(new Error(l.error)) : r(l.result));
4257
- }, d = window.setTimeout(() => {
4258
- window.removeEventListener("message", a), o(new Error(`[ParentProxy] Timeout: ${t.join(".")}.${e}`));
4259
- }, 15e3);
4258
+ const c = u.data;
4259
+ (c == null ? void 0 : c.type) === `${St}:response` && c.id === s && (window.removeEventListener("message", a), l && clearTimeout(l), c.error ? o(new Error(c.error)) : r(c.result));
4260
+ }, d = ls(t, e), l = d > 0 ? window.setTimeout(() => {
4261
+ window.removeEventListener("message", a), o(new Error(`[ParentProxy] Timeout after ${d}ms: ${t.join(".")}.${e}`));
4262
+ }, d) : null;
4260
4263
  window.addEventListener("message", a), window.parent.postMessage({
4261
4264
  type: `${St}:request`,
4262
4265
  id: s,
@@ -4284,24 +4287,24 @@ function sn(t) {
4284
4287
  }
4285
4288
  });
4286
4289
  }
4287
- function ls(t) {
4290
+ function us(t) {
4288
4291
  return sn([t]);
4289
4292
  }
4290
4293
  const rt = () => {
4291
4294
  try {
4292
4295
  if (window.parent && window.parent !== window)
4293
- return ls("GameSDK");
4296
+ return us("GameSDK");
4294
4297
  } catch (t) {
4295
4298
  }
4296
4299
  };
4297
4300
  function ge(t, e, i) {
4298
- return (e = us(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
4301
+ return (e = cs(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
4299
4302
  }
4300
- function us(t) {
4301
- var e = cs(t, "string");
4303
+ function cs(t) {
4304
+ var e = hs(t, "string");
4302
4305
  return typeof e == "symbol" ? e : e + "";
4303
4306
  }
4304
- function cs(t, e) {
4307
+ function hs(t, e) {
4305
4308
  if (typeof t != "object" || !t)
4306
4309
  return t;
4307
4310
  var i = t[Symbol.toPrimitive];
@@ -4313,7 +4316,7 @@ function cs(t, e) {
4313
4316
  }
4314
4317
  return (e === "string" ? String : Number)(t);
4315
4318
  }
4316
- class hs {
4319
+ class fs {
4317
4320
  constructor() {
4318
4321
  ge(this, "adsContext", null), ge(this, "_isReady", !1), ge(this, "_isAvailable", !1), ge(this, "init", async () => {
4319
4322
  this._isReady = !1;
@@ -4354,14 +4357,17 @@ class hs {
4354
4357
  this._isReady = !0, this.showAd();
4355
4358
  else {
4356
4359
  const r = window.setTimeout(() => {
4357
- this._isReady || this.reinit("timeout");
4360
+ var o, s;
4361
+ console.log("[JoliboxSDK] NewsBreak requestAds timeoutId:", this._isReady), this._isReady || ((s = (o = this.adsContext) == null ? void 0 : o.adBreakDone) == null || s.call(o, "timeout"), this.reinit("timeout"));
4358
4362
  }, 5e3);
4359
4363
  i.createRewardAd({
4360
4364
  platform: "jolibox"
4361
4365
  }).then((o) => {
4362
- clearTimeout(r), o.success && o.ready ? (this._isReady = !0, this.showAd()) : this.reinit("noAdPreloaded");
4363
- }).catch(() => {
4364
- clearTimeout(r), this.reinit("noAdPreloaded");
4366
+ var s, a;
4367
+ console.log("[JoliboxSDK] NewsBreak requestAds sdk.createRewardAd result:", o), clearTimeout(r), o.success && o.ready ? (this._isReady = !0, this.showAd()) : (this.reinit("noAdPreloaded"), (a = (s = this.adsContext) == null ? void 0 : s.adBreakDone) == null || a.call(s, "noAdPreloaded"));
4368
+ }).catch((o) => {
4369
+ var s, a;
4370
+ console.log("[JoliboxSDK] NewsBreak requestAds sdk.createRewardAd error:", o), clearTimeout(r), this.reinit("noAdPreloaded"), (a = (s = this.adsContext) == null ? void 0 : s.adBreakDone) == null || a.call(s, "noAdPreloaded");
4365
4371
  });
4366
4372
  }
4367
4373
  }), ge(this, "showAd", () => {
@@ -4370,7 +4376,7 @@ class hs {
4370
4376
  return;
4371
4377
  }
4372
4378
  this.adsContext.beforeReward(async () => {
4373
- var i, n, r, o, s, a, d, u, l, c, h, f, v, y;
4379
+ var i, n, r, o, s, a, d, l, u, c, h, f, v, y;
4374
4380
  (n = (i = this.adsContext) == null ? void 0 : i.beforeAd) == null || n.call(i);
4375
4381
  const e = rt();
4376
4382
  if (!e) {
@@ -4383,22 +4389,22 @@ class hs {
4383
4389
  (a = (s = this.adsContext) == null ? void 0 : s.afterAd) == null || a.call(s), this.reinit("error");
4384
4390
  return;
4385
4391
  }
4386
- w.rewardGranted ? ((d = this.adsContext) == null || d.adViewed(), (l = (u = this.adsContext) == null ? void 0 : u.afterAd) == null || l.call(u), this.reinit("viewed")) : ((c = this.adsContext) == null || c.adDismissed(), (f = (h = this.adsContext) == null ? void 0 : h.afterAd) == null || f.call(h), this.reinit("dismissed"));
4392
+ w.rewardGranted ? ((d = this.adsContext) == null || d.adViewed(), (u = (l = this.adsContext) == null ? void 0 : l.afterAd) == null || u.call(l), this.reinit("viewed")) : ((c = this.adsContext) == null || c.adDismissed(), (f = (h = this.adsContext) == null ? void 0 : h.afterAd) == null || f.call(h), this.reinit("dismissed"));
4387
4393
  } catch (w) {
4388
- (y = (v = this.adsContext) == null ? void 0 : v.afterAd) == null || y.call(v), this.reinit("error");
4394
+ console.error("[JoliboxSDK] NewsBreak showRewardAd failed:", w), (y = (v = this.adsContext) == null ? void 0 : v.afterAd) == null || y.call(v), this.reinit("error");
4389
4395
  }
4390
4396
  });
4391
4397
  }), this.init();
4392
4398
  }
4393
4399
  }
4394
4400
  function _i(t, e, i) {
4395
- return (e = fs(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
4401
+ return (e = vs(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
4396
4402
  }
4397
- function fs(t) {
4398
- var e = vs(t, "string");
4403
+ function vs(t) {
4404
+ var e = ys(t, "string");
4399
4405
  return typeof e == "symbol" ? e : e + "";
4400
4406
  }
4401
- function vs(t, e) {
4407
+ function ys(t, e) {
4402
4408
  if (typeof t != "object" || !t)
4403
4409
  return t;
4404
4410
  var i = t[Symbol.toPrimitive];
@@ -4410,7 +4416,7 @@ function vs(t, e) {
4410
4416
  }
4411
4417
  return (e === "string" ? String : Number)(t);
4412
4418
  }
4413
- class ys {
4419
+ class gs {
4414
4420
  constructor() {
4415
4421
  _i(this, "name", "NEWSBREAK"), _i(this, "rewardAdManager", void 0);
4416
4422
  }
@@ -4420,7 +4426,7 @@ class ys {
4420
4426
  console.warn("[JoliboxSDK] NewsBreak GameSDK is not available on window");
4421
4427
  return;
4422
4428
  }
4423
- e.onEnter(), this.rewardAdManager = new hs();
4429
+ e.onEnter(), this.rewardAdManager = new fs();
4424
4430
  }
4425
4431
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
4426
4432
  adConfig(e, i) {
@@ -4464,13 +4470,13 @@ class ys {
4464
4470
  }
4465
4471
  }
4466
4472
  function te(t, e, i) {
4467
- return (e = gs(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
4473
+ return (e = ws(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
4468
4474
  }
4469
- function gs(t) {
4470
- var e = ws(t, "string");
4475
+ function ws(t) {
4476
+ var e = As(t, "string");
4471
4477
  return typeof e == "symbol" ? e : e + "";
4472
4478
  }
4473
- function ws(t, e) {
4479
+ function As(t, e) {
4474
4480
  if (typeof t != "object" || !t)
4475
4481
  return t;
4476
4482
  var i = t[Symbol.toPrimitive];
@@ -4482,7 +4488,7 @@ function ws(t, e) {
4482
4488
  }
4483
4489
  return (e === "string" ? String : Number)(t);
4484
4490
  }
4485
- class Zs {
4491
+ class ea {
4486
4492
  constructor(e) {
4487
4493
  if (te(this, "context", void 0), te(this, "contextInfo", void 0), te(this, "providers", {}), te(this, "channelPolicy", void 0), te(this, "adsActionDetection", void 0), te(this, "requestContext", void 0), te(this, "adsRequest", void 0), te(this, "initialized", !1), te(this, "adsIsShowing", !1), te(this, "lastAdBreak", void 0), te(this, "initializedTimeStamp", Date.now()), e)
4488
4494
  this.context = e, this.channelPolicy = new rr(this.context), this.adsActionDetection = new tr(this.context), this.contextInfo = this.context.getContextInfo(), this.adsRequest = new rn(e), this.requestContext = new jt(e);
@@ -4542,7 +4548,7 @@ class Zs {
4542
4548
  }
4543
4549
  case "NEWSBREAK": {
4544
4550
  console.log("[JoliboxSDK] NewsBreak Provider", a);
4545
- const d = new ys();
4551
+ const d = new gs();
4546
4552
  await d.init(), this.providers.NEWSBREAK = d;
4547
4553
  break;
4548
4554
  }
@@ -4554,7 +4560,7 @@ class Zs {
4554
4560
  this.providers.ADSENSE ? this.providers.ADSENSE.adConfig(e) : window.adsbygoogle.push(e);
4555
4561
  }
4556
4562
  async adBreak(e) {
4557
- var r, o, s, a, d, u, l, c, h, f, v, y, w, g, A, S;
4563
+ var r, o, s, a, d, l, u, c, h, f, v, y, w, g, A, S;
4558
4564
  const i = Date.now();
4559
4565
  if (i - this.initializedTimeStamp < 3e3) {
4560
4566
  (r = e.adBreakDone) == null || r.call(e, {
@@ -4592,7 +4598,7 @@ class Zs {
4592
4598
  });
4593
4599
  return;
4594
4600
  }
4595
- if (!this.context.checkNetwork()) {
4601
+ if (!this.context.checkNetwork() && !this.providers.NEWSBREAK) {
4596
4602
  (d = e.adBreakDone) == null || d.call(e, {
4597
4603
  breakType: e.type,
4598
4604
  breakName: e.type === "preroll" ? void 0 : e.name,
@@ -4606,7 +4612,7 @@ class Zs {
4606
4612
  if (E === "BYPASS_ADS") {
4607
4613
  switch (e.type) {
4608
4614
  case "preroll": {
4609
- (u = e.adBreakDone) == null || u.call(e, {
4615
+ (l = e.adBreakDone) == null || l.call(e, {
4610
4616
  breakType: e.type,
4611
4617
  breakFormat: "interstitial",
4612
4618
  breakStatus: "viewed"
@@ -4626,7 +4632,7 @@ class Zs {
4626
4632
  break;
4627
4633
  }
4628
4634
  default: {
4629
- (l = e.beforeAd) == null || l.call(e), (c = e.afterAd) == null || c.call(e), (h = e.adBreakDone) == null || h.call(e, {
4635
+ (u = e.beforeAd) == null || u.call(e), (c = e.afterAd) == null || c.call(e), (h = e.adBreakDone) == null || h.call(e, {
4630
4636
  breakType: e.type,
4631
4637
  breakName: e.name,
4632
4638
  breakFormat: "interstitial",
@@ -4663,12 +4669,12 @@ class Zs {
4663
4669
  provider: "INTERNAL_NATIVE",
4664
4670
  params: L
4665
4671
  };
4666
- let q;
4667
- for (L.length > 0 ? q = [W].concat(C) : q = C, q = q.sort((I, X) => I.seq - X.seq).map((I, X) => Wt(yt({}, I), {
4672
+ let K;
4673
+ for (L.length > 0 ? K = [W].concat(C) : K = C, K = K.sort((I, X) => I.seq - X.seq).map((I, X) => Wt(yt({}, I), {
4668
4674
  seq: X
4669
4675
  // re-assign seq
4670
- })); q.length > 0; ) {
4671
- const I = q.shift(), X = this.providers[I.provider];
4676
+ })); K.length > 0; ) {
4677
+ const I = K.shift(), X = this.providers[I.provider];
4672
4678
  if (X) {
4673
4679
  const [an, dn] = await me.callAdBreakAndContinue(X, e, I, (Vt) => {
4674
4680
  var Gt;
@@ -4702,13 +4708,13 @@ class Zs {
4702
4708
  }
4703
4709
  }
4704
4710
  function Xe(t, e, i) {
4705
- return (e = As(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
4711
+ return (e = bs(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
4706
4712
  }
4707
- function As(t) {
4708
- var e = bs(t, "string");
4713
+ function bs(t) {
4714
+ var e = ps(t, "string");
4709
4715
  return typeof e == "symbol" ? e : e + "";
4710
4716
  }
4711
- function bs(t, e) {
4717
+ function ps(t, e) {
4712
4718
  if (typeof t != "object" || !t)
4713
4719
  return t;
4714
4720
  var i = t[Symbol.toPrimitive];
@@ -4720,7 +4726,7 @@ function bs(t, e) {
4720
4726
  }
4721
4727
  return (e === "string" ? String : Number)(t);
4722
4728
  }
4723
- class ps {
4729
+ class _s {
4724
4730
  constructor(e) {
4725
4731
  Xe(this, "context", void 0), Xe(this, "currentProvider", void 0), Xe(this, "continueCallback", void 0), Xe(this, "contextInfo", void 0), this.context = e, this.contextInfo = e.getContextInfo();
4726
4732
  }
@@ -4772,13 +4778,13 @@ class ps {
4772
4778
  }
4773
4779
  }
4774
4780
  function Et(t, e, i) {
4775
- return (e = _s(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
4781
+ return (e = ms(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
4776
4782
  }
4777
- function _s(t) {
4778
- var e = ms(t, "string");
4783
+ function ms(t) {
4784
+ var e = Ss(t, "string");
4779
4785
  return typeof e == "symbol" ? e : e + "";
4780
4786
  }
4781
- function ms(t, e) {
4787
+ function Ss(t, e) {
4782
4788
  if (typeof t != "object" || !t)
4783
4789
  return t;
4784
4790
  var i = t[Symbol.toPrimitive];
@@ -4804,13 +4810,13 @@ class F extends Error {
4804
4810
  }
4805
4811
  }
4806
4812
  function O(t, e, i) {
4807
- return (e = Ss(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
4813
+ return (e = Es(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
4808
4814
  }
4809
- function Ss(t) {
4810
- var e = Es(t, "string");
4815
+ function Es(t) {
4816
+ var e = ks(t, "string");
4811
4817
  return typeof e == "symbol" ? e : e + "";
4812
4818
  }
4813
- function Es(t, e) {
4819
+ function ks(t, e) {
4814
4820
  if (typeof t != "object" || !t)
4815
4821
  return t;
4816
4822
  var i = t[Symbol.toPrimitive];
@@ -4822,13 +4828,13 @@ function Es(t, e) {
4822
4828
  }
4823
4829
  return (e === "string" ? String : Number)(t);
4824
4830
  }
4825
- class ks {
4831
+ class Is {
4826
4832
  constructor(e, i, n) {
4827
4833
  O(this, "adsLoader", void 0), O(this, "adDisplayContainer", void 0), O(this, "isAdPlaying", !1), O(this, "isContentFinished", !1), O(this, "videoContent", void 0), O(this, "adContainer", void 0), O(this, "adsManager", void 0), O(this, "intervalTimer", void 0), O(this, "completed", !1), O(this, "adTagUrl", void 0), O(this, "notifyRequestAd", void 0), O(this, "notifyLoaded", void 0), O(this, "notifyPlayingAd", void 0), O(this, "notifyCompleted", void 0), O(this, "notifyError", void 0), O(this, "destroy", () => {
4828
- var r, o, s, a, d, u, l, c, h, f, v;
4829
- this.intervalTimer && clearInterval(this.intervalTimer), (r = this.adsManager) == null || r.stop(), (o = this.adDisplayContainer) == null || o.destroy(), (s = this.adsLoader) == null || s.removeEventListener(window.google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED, this.onAdsManagerLoaded), (a = this.adsLoader) == null || a.removeEventListener(window.google.ima.AdErrorEvent.Type.AD_ERROR, this.onAdError), (d = this.adsManager) == null || d.removeEventListener(window.google.ima.AdErrorEvent.Type.AD_ERROR, this.onAdError), (u = this.adsManager) == null || u.removeEventListener(window.google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED, this.onContentPauseRequested), (l = this.adsManager) == null || l.removeEventListener(window.google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED, this.onContentResumeRequested), (c = this.adsManager) == null || c.removeEventListener(window.google.ima.AdEvent.Type.ALL_ADS_COMPLETED, this.onAdEvent), (h = this.adsManager) == null || h.removeEventListener(window.google.ima.AdEvent.Type.LOADED, this.onAdEvent), (f = this.adsManager) == null || f.removeEventListener(window.google.ima.AdEvent.Type.STARTED, this.onAdEvent), (v = this.adsManager) == null || v.removeEventListener(window.google.ima.AdEvent.Type.COMPLETE, this.onAdEvent);
4834
+ var r, o, s, a, d, l, u, c, h, f, v;
4835
+ this.intervalTimer && clearInterval(this.intervalTimer), (r = this.adsManager) == null || r.stop(), (o = this.adDisplayContainer) == null || o.destroy(), (s = this.adsLoader) == null || s.removeEventListener(window.google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED, this.onAdsManagerLoaded), (a = this.adsLoader) == null || a.removeEventListener(window.google.ima.AdErrorEvent.Type.AD_ERROR, this.onAdError), (d = this.adsManager) == null || d.removeEventListener(window.google.ima.AdErrorEvent.Type.AD_ERROR, this.onAdError), (l = this.adsManager) == null || l.removeEventListener(window.google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED, this.onContentPauseRequested), (u = this.adsManager) == null || u.removeEventListener(window.google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED, this.onContentResumeRequested), (c = this.adsManager) == null || c.removeEventListener(window.google.ima.AdEvent.Type.ALL_ADS_COMPLETED, this.onAdEvent), (h = this.adsManager) == null || h.removeEventListener(window.google.ima.AdEvent.Type.LOADED, this.onAdEvent), (f = this.adsManager) == null || f.removeEventListener(window.google.ima.AdEvent.Type.STARTED, this.onAdEvent), (v = this.adsManager) == null || v.removeEventListener(window.google.ima.AdEvent.Type.COMPLETE, this.onAdEvent);
4830
4836
  }), O(this, "requestAds", async (r, o) => {
4831
- var l;
4837
+ var u;
4832
4838
  this.createAdDisplayContainer(), this.notifyRequestAd = r.onAdRequested, this.notifyLoaded = r.onAdLoaded, this.notifyPlayingAd = r.onAdPlaying, this.notifyCompleted = r.onAdCompleted, this.notifyError = (c) => {
4833
4839
  var h;
4834
4840
  return (h = r.onAdError) == null ? void 0 : h.call(r, F.from(c, "GOOGLE_IMA_ERROR"));
@@ -4845,8 +4851,8 @@ class ks {
4845
4851
  const h = window.encodeURIComponent(o.params[c]);
4846
4852
  d += `&${c}=${h}`;
4847
4853
  });
4848
- const u = `${this.adTagUrl}${d}`;
4849
- a.adTagUrl = u, a.linearAdSlotWidth = 640, a.linearAdSlotHeight = 400, a.nonLinearAdSlotWidth = 640, a.nonLinearAdSlotHeight = 150, this.adsLoader.requestAds(a), (l = this.notifyRequestAd) == null || l.call(this);
4854
+ const l = `${this.adTagUrl}${d}`;
4855
+ a.adTagUrl = l, a.linearAdSlotWidth = 640, a.linearAdSlotHeight = 400, a.nonLinearAdSlotWidth = 640, a.nonLinearAdSlotHeight = 150, this.adsLoader.requestAds(a), (u = this.notifyRequestAd) == null || u.call(this);
4850
4856
  }), O(this, "createAdDisplayContainer", () => {
4851
4857
  this.adDisplayContainer = new window.google.ima.AdDisplayContainer(this.adContainer, this.videoContent);
4852
4858
  }), O(this, "playAds", () => {
@@ -4861,7 +4867,7 @@ class ks {
4861
4867
  const o = new window.google.ima.AdsRenderingSettings();
4862
4868
  o.restoreCustomPlaybackStateOnAdBreakComplete = !0, o.loadVideoTimeout = 1e4, this.adsManager = r.getAdsManager(this.videoContent, o), this.adsManager.addEventListener(window.google.ima.AdErrorEvent.Type.AD_ERROR, this.onAdError), this.adsManager.addEventListener(window.google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED, this.onContentPauseRequested), this.adsManager.addEventListener(window.google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED, this.onContentResumeRequested), this.adsManager.addEventListener(window.google.ima.AdEvent.Type.ALL_ADS_COMPLETED, this.onAdEvent), this.adsManager.addEventListener(window.google.ima.AdEvent.Type.LOADED, this.onAdEvent), this.adsManager.addEventListener(window.google.ima.AdEvent.Type.STARTED, this.onAdEvent), this.adsManager.addEventListener(window.google.ima.AdEvent.Type.COMPLETE, this.onAdEvent), r.type === "adsManagerLoaded" && this.playAds();
4863
4869
  }), O(this, "onAdEvent", (r) => {
4864
- var s, a, d, u;
4870
+ var s, a, d, l;
4865
4871
  const o = r.getAd();
4866
4872
  switch (r.type) {
4867
4873
  case window.google.ima.AdEvent.Type.LOADED:
@@ -4875,7 +4881,7 @@ class ks {
4875
4881
  o != null && o.isLinear() && clearInterval(this.intervalTimer), this.completed || (this.completed = !0, (d = this.notifyCompleted) == null || d.call(this, r));
4876
4882
  break;
4877
4883
  case window.google.ima.AdEvent.Type.ALL_ADS_COMPLETED:
4878
- o != null && o.isLinear() && clearInterval(this.intervalTimer), this.completed || (this.completed = !0, (u = this.notifyCompleted) == null || u.call(this, r));
4884
+ o != null && o.isLinear() && clearInterval(this.intervalTimer), this.completed || (this.completed = !0, (l = this.notifyCompleted) == null || l.call(this, r));
4879
4885
  break;
4880
4886
  }
4881
4887
  }), O(this, "onAdError", (r) => {
@@ -4889,8 +4895,8 @@ class ks {
4889
4895
  }
4890
4896
  }
4891
4897
  var ot = /* @__PURE__ */ ((t) => (t[t.ADS_REQUEST_NETWORK_ERROR = 1012] = "ADS_REQUEST_NETWORK_ERROR", t[t.ASSET_FALLBACK_FAILED = 1021] = "ASSET_FALLBACK_FAILED", t[t.AUTOPLAY_DISALLOWED = 1205] = "AUTOPLAY_DISALLOWED", t[t.COMPANION_AD_LOADING_FAILED = 603] = "COMPANION_AD_LOADING_FAILED", t[t.COMPANION_REQUIRED_ERROR = 602] = "COMPANION_REQUIRED_ERROR", t[t.FAILED_TO_REQUEST_ADS = 1005] = "FAILED_TO_REQUEST_ADS", t[t.INVALID_AD_TAG = 1013] = "INVALID_AD_TAG", t[t.INVALID_ADX_EXTENSION = 1105] = "INVALID_ADX_EXTENSION", t[t.INVALID_ARGUMENTS = 1101] = "INVALID_ARGUMENTS", t[t.NONLINEAR_DIMENSIONS_ERROR = 501] = "NONLINEAR_DIMENSIONS_ERROR", t[t.OVERLAY_AD_LOADING_FAILED = 502] = "OVERLAY_AD_LOADING_FAILED", t[t.OVERLAY_AD_PLAYING_FAILED = 500] = "OVERLAY_AD_PLAYING_FAILED", t[t.STREAM_INITIALIZATION_FAILED = 1020] = "STREAM_INITIALIZATION_FAILED", t[t.UNKNOWN_AD_RESPONSE = 1010] = "UNKNOWN_AD_RESPONSE", t[t.UNKNOWN_ERROR = 900] = "UNKNOWN_ERROR", t[t.UNSUPPORTED_LOCALE = 1011] = "UNSUPPORTED_LOCALE", t[t.VAST_ASSET_NOT_FOUND = 1007] = "VAST_ASSET_NOT_FOUND", t[t.VAST_EMPTY_RESPONSE = 1009] = "VAST_EMPTY_RESPONSE", t[t.VAST_LINEAR_ASSET_MISMATCH = 403] = "VAST_LINEAR_ASSET_MISMATCH", t[t.VAST_LOAD_TIMEOUT = 301] = "VAST_LOAD_TIMEOUT", t[t.VAST_MALFORMED_RESPONSE = 100] = "VAST_MALFORMED_RESPONSE", t[t.VAST_MEDIA_LOAD_TIMEOUT = 402] = "VAST_MEDIA_LOAD_TIMEOUT", t[t.VAST_NO_ADS_AFTER_WRAPPER = 303] = "VAST_NO_ADS_AFTER_WRAPPER", t[t.VAST_NONLINEAR_ASSET_MISMATCH = 503] = "VAST_NONLINEAR_ASSET_MISMATCH", t[t.VAST_PROBLEM_DISPLAYING_MEDIA_FILE = 405] = "VAST_PROBLEM_DISPLAYING_MEDIA_FILE", t[t.VAST_SCHEMA_VALIDATION_ERROR = 101] = "VAST_SCHEMA_VALIDATION_ERROR", t[t.VAST_TOO_MANY_REDIRECTS = 302] = "VAST_TOO_MANY_REDIRECTS", t[t.VAST_TRAFFICKING_ERROR = 200] = "VAST_TRAFFICKING_ERROR", t[t.VAST_UNEXPECTED_DURATION_ERROR = 202] = "VAST_UNEXPECTED_DURATION_ERROR", t[t.VAST_UNEXPECTED_LINEARITY = 201] = "VAST_UNEXPECTED_LINEARITY", t[t.VAST_UNSUPPORTED_VERSION = 102] = "VAST_UNSUPPORTED_VERSION", t[t.VAST_WRAPPER_ERROR = 300] = "VAST_WRAPPER_ERROR", t[t.VIDEO_PLAY_ERROR = 400] = "VIDEO_PLAY_ERROR", t[t.VPAID_ERROR = 901] = "VPAID_ERROR", t))(ot || {});
4892
- const Is = () => {
4893
- const t = k(!1), e = k(!1), i = k(null), n = Jt(), r = Jt();
4898
+ const xs = () => {
4899
+ const t = k(!1), e = k(!1), i = k(null), n = Ht(), r = Ht();
4894
4900
  return {
4895
4901
  visible: t,
4896
4902
  canRetry: e,
@@ -4898,7 +4904,7 @@ const Is = () => {
4898
4904
  videoRef: n,
4899
4905
  adContainerRef: r
4900
4906
  };
4901
- }, xs = G`
4907
+ }, Rs = G`
4902
4908
  ${M}
4903
4909
  position: fixed;
4904
4910
  left: 0;
@@ -4943,7 +4949,7 @@ const Is = () => {
4943
4949
  cursor: pointer;
4944
4950
  }
4945
4951
  }
4946
- `, Rs = (t) => {
4952
+ `, Ts = (t) => {
4947
4953
  let {
4948
4954
  onReady: e,
4949
4955
  state: i
@@ -4962,7 +4968,7 @@ const Is = () => {
4962
4968
  return Ce(() => {
4963
4969
  e();
4964
4970
  }, [e]), m("div", {
4965
- className: xs,
4971
+ className: Rs,
4966
4972
  style: {
4967
4973
  display: n.value ? "block" : "none"
4968
4974
  },
@@ -5009,13 +5015,13 @@ const Is = () => {
5009
5015
  });
5010
5016
  };
5011
5017
  function fe(t, e, i) {
5012
- return (e = Ts(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
5018
+ return (e = Cs(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
5013
5019
  }
5014
- function Ts(t) {
5015
- var e = Cs(t, "string");
5020
+ function Cs(t) {
5021
+ var e = Os(t, "string");
5016
5022
  return typeof e == "symbol" ? e : e + "";
5017
5023
  }
5018
- function Cs(t, e) {
5024
+ function Os(t, e) {
5019
5025
  if (typeof t != "object" || !t)
5020
5026
  return t;
5021
5027
  var i = t[Symbol.toPrimitive];
@@ -5027,9 +5033,9 @@ function Cs(t, e) {
5027
5033
  }
5028
5034
  return (e === "string" ? String : Number)(t);
5029
5035
  }
5030
- class Os {
5036
+ class Ds {
5031
5037
  constructor(e) {
5032
- fe(this, "name", "GOOGLE_IMA"), fe(this, "context", void 0), fe(this, "adsOverlay", null), fe(this, "initialized", !1), fe(this, "ima", null), fe(this, "state", Is()), fe(this, "init", async (i) => {
5038
+ fe(this, "name", "GOOGLE_IMA"), fe(this, "context", void 0), fe(this, "adsOverlay", null), fe(this, "initialized", !1), fe(this, "ima", null), fe(this, "state", xs()), fe(this, "init", async (i) => {
5033
5039
  if (this.initialized)
5034
5040
  return;
5035
5041
  const n = "//imasdk.googleapis.com/js/sdkloader/ima3.js";
@@ -5045,29 +5051,29 @@ class Os {
5045
5051
  }, s.onerror = o, document.head.appendChild(s);
5046
5052
  }
5047
5053
  }), this.adsOverlay = document.createElement("div"), this.adsOverlay.id = "jolibox-ima-overlay", document.documentElement.appendChild(this.adsOverlay), await new Promise((r, o) => {
5048
- ye(m(Rs, {
5054
+ ye(m(Ts, {
5049
5055
  state: this.state,
5050
5056
  onReady: () => {
5051
- this.ima = new ks(i.params.url, this.state.videoRef.current, this.state.adContainerRef.current), r();
5057
+ this.ima = new Is(i.params.url, this.state.videoRef.current, this.state.adContainerRef.current), r();
5052
5058
  }
5053
5059
  }), this.adsOverlay);
5054
5060
  }), this.initialized = !0;
5055
5061
  }), fe(this, "destroy", () => {
5056
5062
  this.adsOverlay && (ye(null, this.adsOverlay), this.adsOverlay.remove()), this.ima && this.ima.destroy(), this.initialized = !1;
5057
5063
  }), fe(this, "requestAd", (i, n) => {
5058
- var u;
5064
+ var l;
5059
5065
  if (!this.adsOverlay || !this.ima || !this.initialized) {
5060
- const l = F.from(new Error("IMA not initialized"), "JOLIBOX_IMA_ERROR");
5061
- (u = i.onAdError) == null || u.call(i, l);
5066
+ const u = F.from(new Error("IMA not initialized"), "JOLIBOX_IMA_ERROR");
5067
+ (l = i.onAdError) == null || l.call(i, u);
5062
5068
  return;
5063
5069
  }
5064
- const r = (l) => {
5070
+ const r = (u) => {
5065
5071
  var c;
5066
- this.ima.destroy(), this.state.visible.value = !1, (c = i.onAdCompleted) == null || c.call(i, l);
5067
- }, o = (l) => {
5072
+ this.ima.destroy(), this.state.visible.value = !1, (c = i.onAdCompleted) == null || c.call(i, u);
5073
+ }, o = (u) => {
5068
5074
  var h;
5069
5075
  let c = !1;
5070
- switch (l.raw.getErrorCode()) {
5076
+ switch (u.raw.getErrorCode()) {
5071
5077
  case ot.AUTOPLAY_DISALLOWED:
5072
5078
  case ot.VIDEO_PLAY_ERROR:
5073
5079
  case ot.ADS_REQUEST_NETWORK_ERROR: {
@@ -5082,7 +5088,7 @@ class Os {
5082
5088
  if (!c)
5083
5089
  this.ima.destroy(), P(() => {
5084
5090
  this.state.canRetry.value = !1, this.state.retry.value = null, this.state.visible.value = !1;
5085
- }), (h = i.onAdError) == null || h.call(i, l);
5091
+ }), (h = i.onAdError) == null || h.call(i, u);
5086
5092
  else {
5087
5093
  const f = () => {
5088
5094
  this.ima.destroy(), this.requestAd(i, n);
@@ -5091,25 +5097,25 @@ class Os {
5091
5097
  this.state.canRetry.value = !0, this.state.retry.value = f;
5092
5098
  });
5093
5099
  }
5094
- }, s = (l) => {
5100
+ }, s = (u) => {
5095
5101
  var c;
5096
- this.state.visible.value = !0, (c = i.onAdLoaded) == null || c.call(i, l);
5097
- }, a = (l) => {
5102
+ this.state.visible.value = !0, (c = i.onAdLoaded) == null || c.call(i, u);
5103
+ }, a = (u) => {
5098
5104
  var c;
5099
- (c = i.onAdPlaying) == null || c.call(i, l);
5105
+ (c = i.onAdPlaying) == null || c.call(i, u);
5100
5106
  }, d = Object.assign({}, i);
5101
5107
  d.onAdCompleted = r, d.onAdError = o, d.onAdLoaded = s, d.onAdPlaying = a, this.ima.requestAds(d, n);
5102
5108
  }), this.context = e;
5103
5109
  }
5104
5110
  }
5105
5111
  function re(t, e, i) {
5106
- return (e = Ds(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
5112
+ return (e = Ps(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
5107
5113
  }
5108
- function Ds(t) {
5109
- var e = Ps(t, "string");
5114
+ function Ps(t) {
5115
+ var e = Ns(t, "string");
5110
5116
  return typeof e == "symbol" ? e : e + "";
5111
5117
  }
5112
- function Ps(t, e) {
5118
+ function Ns(t, e) {
5113
5119
  if (typeof t != "object" || !t)
5114
5120
  return t;
5115
5121
  var i = t[Symbol.toPrimitive];
@@ -5121,7 +5127,7 @@ function Ps(t, e) {
5121
5127
  }
5122
5128
  return (e === "string" ? String : Number)(t);
5123
5129
  }
5124
- class Ns {
5130
+ class Ls {
5125
5131
  constructor(e) {
5126
5132
  re(this, "name", "OKSPIN"), re(this, "initialized", !1), re(this, "initCompleter", null), re(this, "context", void 0), re(this, "adsOverlay", null), re(this, "adsIsShowing", !1), re(this, "state", Xi()), re(this, "init", async (i) => {
5127
5133
  var n;
@@ -5132,7 +5138,7 @@ class Ns {
5132
5138
  var i;
5133
5139
  this.adsOverlay && (ye(null, this.adsOverlay), (i = this.adsOverlay) == null || i.remove()), this.initialized = !1;
5134
5140
  }), re(this, "requestAd", (i, n) => {
5135
- var s, a, d, u;
5141
+ var s, a, d, l;
5136
5142
  if (!this.adsOverlay || !this.initialized) {
5137
5143
  (s = i.onAdError) == null || s.call(i, F.from(new Error("Ads not initialized"), "JOLIBOX_IMA_ERROR"));
5138
5144
  return;
@@ -5143,27 +5149,27 @@ class Ns {
5143
5149
  }
5144
5150
  (d = i.onAdRequested) == null || d.call(i);
5145
5151
  const r = () => {
5146
- var l;
5147
- this.adsIsShowing = !1, (l = i.onAdCompleted) == null || l.call(i, void 0);
5152
+ var u;
5153
+ this.adsIsShowing = !1, (u = i.onAdCompleted) == null || u.call(i, void 0);
5148
5154
  }, o = () => {
5149
- var l;
5150
- (l = i.onAdLoaded) == null || l.call(i, void 0);
5155
+ var u;
5156
+ (u = i.onAdLoaded) == null || u.call(i, void 0);
5151
5157
  };
5152
5158
  this.adsIsShowing = !0, P(() => {
5153
- var l;
5154
- this.state.adLoaded.value = o, this.state.adBreakDone.value = r, this.state.countdown.value = (l = n.params.countdown) != null ? l : 15, this.state.src.value = n.params.url, this.state.mode.value = "rewarded_insterstitial", this.state.visible.value = !0;
5155
- }), (u = i.onAdPlaying) == null || u.call(i, void 0);
5159
+ var u;
5160
+ this.state.adLoaded.value = o, this.state.adBreakDone.value = r, this.state.countdown.value = (u = n.params.countdown) != null ? u : 15, this.state.src.value = n.params.url, this.state.mode.value = "rewarded_insterstitial", this.state.visible.value = !0;
5161
+ }), (l = i.onAdPlaying) == null || l.call(i, void 0);
5156
5162
  }), this.context = e;
5157
5163
  }
5158
5164
  }
5159
5165
  function ie(t, e, i) {
5160
- return (e = Ls(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
5166
+ return (e = Bs(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
5161
5167
  }
5162
- function Ls(t) {
5163
- var e = Bs(t, "string");
5168
+ function Bs(t) {
5169
+ var e = Ms(t, "string");
5164
5170
  return typeof e == "symbol" ? e : e + "";
5165
5171
  }
5166
- function Bs(t, e) {
5172
+ function Ms(t, e) {
5167
5173
  if (typeof t != "object" || !t)
5168
5174
  return t;
5169
5175
  var i = t[Symbol.toPrimitive];
@@ -5175,7 +5181,7 @@ function Bs(t, e) {
5175
5181
  }
5176
5182
  return (e === "string" ? String : Number)(t);
5177
5183
  }
5178
- class Ms {
5184
+ class $s {
5179
5185
  constructor(e) {
5180
5186
  ie(this, "name", "APPSROCKETS"), ie(this, "initialized", !1), ie(this, "initCompleter", null), ie(this, "context", void 0), ie(this, "adsOverlay", null), ie(this, "adsIsShowing", !1), ie(this, "state", Zi()), ie(this, "processUrl", (i) => {
5181
5187
  var s;
@@ -5190,16 +5196,16 @@ class Ms {
5190
5196
  var i;
5191
5197
  this.adsOverlay && (ye(null, this.adsOverlay), (i = this.adsOverlay) == null || i.remove()), this.initialized = !1;
5192
5198
  }), ie(this, "requestAd", (i, n) => {
5193
- var d, u, l, c;
5199
+ var d, l, u, c;
5194
5200
  if (!this.adsOverlay || !this.initialized) {
5195
5201
  (d = i.onAdError) == null || d.call(i, F.from(new Error("Ads not initialized"), "JOLIBOX_IMA_ERROR"));
5196
5202
  return;
5197
5203
  }
5198
5204
  if (this.adsIsShowing) {
5199
- (u = i.onAdError) == null || u.call(i, F.from(new Error("Ads already showing"), "JOLIBOX_IMA_ERROR"));
5205
+ (l = i.onAdError) == null || l.call(i, F.from(new Error("Ads already showing"), "JOLIBOX_IMA_ERROR"));
5200
5206
  return;
5201
5207
  }
5202
- (l = i.onAdRequested) == null || l.call(i);
5208
+ (u = i.onAdRequested) == null || u.call(i);
5203
5209
  const r = () => {
5204
5210
  var h;
5205
5211
  this.adsIsShowing = !1, (h = i.onAdCompleted) == null || h.call(i, void 0);
@@ -5220,13 +5226,13 @@ class Ms {
5220
5226
  }
5221
5227
  }
5222
5228
  function we(t, e, i) {
5223
- return (e = $s(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
5229
+ return (e = Fs(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
5224
5230
  }
5225
- function $s(t) {
5226
- var e = Fs(t, "string");
5231
+ function Fs(t) {
5232
+ var e = Us(t, "string");
5227
5233
  return typeof e == "symbol" ? e : e + "";
5228
5234
  }
5229
- function Fs(t, e) {
5235
+ function Us(t, e) {
5230
5236
  if (typeof t != "object" || !t)
5231
5237
  return t;
5232
5238
  var i = t[Symbol.toPrimitive];
@@ -5238,7 +5244,7 @@ function Fs(t, e) {
5238
5244
  }
5239
5245
  return (e === "string" ? String : Number)(t);
5240
5246
  }
5241
- class Us {
5247
+ class js {
5242
5248
  constructor(e) {
5243
5249
  we(this, "name", "GOOGLE_GPT"), we(this, "context", void 0), we(this, "contextInfo", void 0), we(this, "rewardAdManager", void 0), we(this, "init", async (i) => {
5244
5250
  if (!this.rewardAdManager) {
@@ -5291,13 +5297,13 @@ class Us {
5291
5297
  }
5292
5298
  }
5293
5299
  function oe(t, e, i) {
5294
- return (e = js(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
5300
+ return (e = Vs(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
5295
5301
  }
5296
- function js(t) {
5297
- var e = Vs(t, "string");
5302
+ function Vs(t) {
5303
+ var e = Gs(t, "string");
5298
5304
  return typeof e == "symbol" ? e : e + "";
5299
5305
  }
5300
- function Vs(t, e) {
5306
+ function Gs(t, e) {
5301
5307
  if (typeof t != "object" || !t)
5302
5308
  return t;
5303
5309
  var i = t[Symbol.toPrimitive];
@@ -5345,22 +5351,22 @@ class ve {
5345
5351
  for (const r of i)
5346
5352
  switch (r.provider) {
5347
5353
  case "GOOGLE_GPT": {
5348
- const o = new Us(this.context);
5354
+ const o = new js(this.context);
5349
5355
  await o.init(r), this.providers.GOOGLE_GPT = o;
5350
5356
  break;
5351
5357
  }
5352
5358
  case "GOOGLE_IMA": {
5353
- const o = new Os(this.context);
5359
+ const o = new Ds(this.context);
5354
5360
  await o.init(r), this.providers.GOOGLE_IMA = o;
5355
5361
  break;
5356
5362
  }
5357
5363
  case "OKSPIN": {
5358
- const o = new Ns(this.context);
5364
+ const o = new Ls(this.context);
5359
5365
  await o.init(r), this.providers.OKSPIN = o;
5360
5366
  break;
5361
5367
  }
5362
5368
  case "APPSROCKETS": {
5363
- const o = new Ms(this.context);
5369
+ const o = new $s(this.context);
5364
5370
  await o.init(r), this.providers.APPSROCKETS = o;
5365
5371
  break;
5366
5372
  }
@@ -5401,7 +5407,7 @@ class ve {
5401
5407
  this.initialized = !1, this.preloadedAd = null;
5402
5408
  }
5403
5409
  async requestAd(e) {
5404
- var i, n, r, o, s, a, d, u, l, c, h, f;
5410
+ var i, n, r, o, s, a, d, l, u, c, h, f;
5405
5411
  if ((i = this.context.eventEmitter) == null || i.emit("isAdShowing", !0), this.initialized || await this.init(), !this.context.checkNetwork()) {
5406
5412
  const v = F.from(new Error("No network connection"), "JOLIBOX_IMA_ERROR");
5407
5413
  (n = e.onAdError) == null || n.call(e, v);
@@ -5420,11 +5426,11 @@ class ve {
5420
5426
  const g = w.sort((_, E) => _.seq - E.seq);
5421
5427
  if (g.length === 0) {
5422
5428
  const _ = F.from(new Error("No ads available"), "JOLIBOX_IMA_ERROR");
5423
- (l = e.onAdError) == null || l.call(e, _);
5429
+ (u = e.onAdError) == null || u.call(e, _);
5424
5430
  return;
5425
5431
  }
5426
5432
  let A = !0, S = null;
5427
- const p = new ps(this.context);
5433
+ const p = new _s(this.context);
5428
5434
  for (; g.length > 0; ) {
5429
5435
  const _ = g.shift(), E = this.providers[_.provider];
5430
5436
  if (E) {
@@ -5438,7 +5444,7 @@ class ve {
5438
5444
  A && S && ((c = e.onAdError) == null || c.call(e, S));
5439
5445
  } else {
5440
5446
  const g = F.from(new Error("Unknown error"), "JOLIBOX_IMA_ERROR");
5441
- (u = e.onAdError) == null || u.call(e, g);
5447
+ (l = e.onAdError) == null || l.call(e, g);
5442
5448
  return;
5443
5449
  }
5444
5450
  } catch (v) {
@@ -5452,9 +5458,9 @@ class ve {
5452
5458
  oe(ve, "STORAGE_KEY_INIT", "jolibox_afv_init_data");
5453
5459
  oe(ve, "STORAGE_KEY_INFO", "jolibox_afv_info_data");
5454
5460
  function ke(t, e, i) {
5455
- return (e = Gs(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
5461
+ return (e = Ks(e)) in t ? Object.defineProperty(t, e, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : t[e] = i, t;
5456
5462
  }
5457
- function Gs(t) {
5463
+ function Ks(t) {
5458
5464
  var e = qs(t, "string");
5459
5465
  return typeof e == "symbol" ? e : e + "";
5460
5466
  }
@@ -5470,7 +5476,7 @@ function qs(t, e) {
5470
5476
  }
5471
5477
  return (e === "string" ? String : Number)(t);
5472
5478
  }
5473
- class ea extends Error {
5479
+ class ta extends Error {
5474
5480
  constructor(e) {
5475
5481
  super(e), ke(this, "name", void 0), ke(this, "message", void 0), ke(this, "errMsg", void 0), ke(this, "code", void 0), ke(this, "data", void 0), ke(this, "extra", void 0), this.name = "ResponseError", this.message = e, this.errMsg = e;
5476
5482
  }
@@ -5478,13 +5484,13 @@ class ea extends Error {
5478
5484
  export {
5479
5485
  F as AFVWrappedError,
5480
5486
  ar as GoogleAdSenseProvider,
5481
- Os as GoogleIMAProvider,
5487
+ Ds as GoogleIMAProvider,
5482
5488
  Uo as InterstitialAdManager,
5483
- Zs as JoliboxAdsForGame,
5489
+ ea as JoliboxAdsForGame,
5484
5490
  ve as JoliboxAdsForVideo,
5485
5491
  wo as OKSpinForGameProvider,
5486
- Ns as OKSpinForVideoProvider,
5487
- ea as ResponseError,
5492
+ Ls as OKSpinForVideoProvider,
5493
+ ta as ResponseError,
5488
5494
  nn as RewardAdManager,
5489
5495
  tn as initGPTServices
5490
5496
  };