@streamlayer/react 1.24.5 → 1.24.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (103) hide show
  1. package/lib/cjs/Question.js +1 -1
  2. package/lib/cjs/advertisement.js +26 -26
  3. package/lib/cjs/bet-pack.js +1 -1
  4. package/lib/cjs/feature.js +1 -1
  5. package/lib/cjs/{index-DvqmgCor.js → index-CfSdnrfA.js} +1 -1
  6. package/lib/cjs/index10.js +1 -1
  7. package/lib/cjs/index11.js +1 -1
  8. package/lib/cjs/index12.js +1 -1
  9. package/lib/cjs/index13.js +4 -1
  10. package/lib/cjs/index14.js +1 -4
  11. package/lib/cjs/index15.js +1 -1
  12. package/lib/cjs/index16.js +2 -2
  13. package/lib/cjs/index2.js +1 -1
  14. package/lib/cjs/index4.js +3 -3
  15. package/lib/cjs/index6.js +1 -1
  16. package/lib/cjs/index7.js +1 -1
  17. package/lib/cjs/index9.js +2 -2
  18. package/lib/cjs/insight.js +1 -1
  19. package/lib/cjs/masters2.js +3 -3
  20. package/lib/cjs/notification.js +1 -1
  21. package/lib/cjs/pause-ad.js +1 -1
  22. package/lib/cjs/points.js +1 -1
  23. package/lib/cjs/polymarket.js +1 -1
  24. package/lib/cjs/storage.js +1 -1
  25. package/lib/cjs/useStreamLayerApp2.js +13 -13
  26. package/lib/classic/cjs/Question.js +1 -1
  27. package/lib/classic/cjs/advertisement.js +26 -26
  28. package/lib/classic/cjs/bet-pack.js +3 -3
  29. package/lib/classic/cjs/feature.js +1 -1
  30. package/lib/classic/cjs/{index-DvqmgCor.js → index-CfSdnrfA.js} +1 -1
  31. package/lib/classic/cjs/index10.js +1 -1
  32. package/lib/classic/cjs/index11.js +1 -1
  33. package/lib/classic/cjs/index12.js +1 -1
  34. package/lib/classic/cjs/index13.js +1 -1
  35. package/lib/classic/cjs/index2.js +2 -2
  36. package/lib/classic/cjs/index5.js +1 -1
  37. package/lib/classic/cjs/index7.js +2 -2
  38. package/lib/classic/cjs/index8.js +1 -1
  39. package/lib/classic/cjs/index9.js +1 -1
  40. package/lib/classic/cjs/insight.js +1 -1
  41. package/lib/classic/cjs/notification2.js +1 -1
  42. package/lib/classic/cjs/pause-ad.js +1 -1
  43. package/lib/classic/cjs/points.js +1 -1
  44. package/lib/classic/cjs/polymarket.js +1 -1
  45. package/lib/classic/cjs/useStreamLayerApp2.js +13 -13
  46. package/lib/classic/es/Question.js +313 -198
  47. package/lib/classic/es/advertisement.js +1988 -1955
  48. package/lib/classic/es/bet-pack.js +12 -13
  49. package/lib/classic/es/feature.js +188 -37
  50. package/lib/{es/index-DvqmgCor.js → classic/es/index-CfSdnrfA.js} +1 -1
  51. package/lib/classic/es/index10.js +309 -2580
  52. package/lib/classic/es/index11.js +2580 -305
  53. package/lib/classic/es/index12.js +12 -12
  54. package/lib/classic/es/index13.js +2 -2
  55. package/lib/classic/es/index2.js +129 -121
  56. package/lib/classic/es/index5.js +0 -1
  57. package/lib/classic/es/index7.js +2 -2
  58. package/lib/classic/es/index8.js +1 -1
  59. package/lib/classic/es/index9.js +1 -1
  60. package/lib/classic/es/insight.js +1 -1
  61. package/lib/classic/es/notification2.js +137 -138
  62. package/lib/classic/es/pause-ad.js +124 -149
  63. package/lib/classic/es/points.js +3 -4
  64. package/lib/classic/es/polymarket.js +1 -1
  65. package/lib/classic/es/useStreamLayerApp2.js +2931 -2877
  66. package/lib/classic/source.css +1 -1
  67. package/lib/dist/cjs/{index-DvqmgCor.js → index-CfSdnrfA.js} +1 -1
  68. package/lib/dist/cjs/masters.js +31 -31
  69. package/lib/dist/es/{index-DvqmgCor.js → index-CfSdnrfA.js} +1 -1
  70. package/lib/dist/es/masters.js +7957 -7774
  71. package/lib/dist/index.d.ts +2 -0
  72. package/lib/es/Question.js +66 -65
  73. package/lib/es/advertisement.js +1988 -1955
  74. package/lib/es/bet-pack.js +1 -1
  75. package/lib/es/feature.js +188 -37
  76. package/lib/{classic/es/index-DvqmgCor.js → es/index-CfSdnrfA.js} +1 -1
  77. package/lib/es/index10.js +1 -1
  78. package/lib/es/index11.js +12 -12
  79. package/lib/es/index12.js +366 -2579
  80. package/lib/es/index13.js +789 -234
  81. package/lib/es/index14.js +293 -792
  82. package/lib/es/index15.js +2580 -305
  83. package/lib/es/index16.js +41 -42
  84. package/lib/es/index2.js +279 -271
  85. package/lib/es/index4.js +15 -16
  86. package/lib/es/index6.js +0 -1
  87. package/lib/es/index7.js +1 -1
  88. package/lib/es/index9.js +2 -2
  89. package/lib/es/insight.js +1 -1
  90. package/lib/es/masters2.js +194 -183
  91. package/lib/es/notification.js +22 -23
  92. package/lib/es/pause-ad.js +124 -149
  93. package/lib/es/points.js +20 -21
  94. package/lib/es/polymarket.js +1 -1
  95. package/lib/es/storage.js +1 -1
  96. package/lib/es/useStreamLayerApp2.js +2931 -2877
  97. package/lib/source.css +1 -1
  98. package/lib/style.css +1 -1
  99. package/package.json +72 -53
  100. package/lib/cjs/sl-types.js +0 -1
  101. package/lib/classic/cjs/sl-types.js +0 -1
  102. package/lib/classic/es/sl-types.js +0 -156
  103. package/lib/es/sl-types.js +0 -156
package/lib/es/index4.js CHANGED
@@ -1,12 +1,11 @@
1
1
  import { jsx as P, jsxs as F } from "react/jsx-runtime";
2
- import { s as _, u as Se, c as Ee } from "./sl-types.js";
3
- import $, { forwardRef as Ae, useRef as D, useState as W, useEffect as X, useLayoutEffect as mt, createContext as je, useMemo as He, useCallback as Re, memo as ht } from "react";
4
- import gt from "lodash.throttle";
2
+ import { s as _, u as Se, a as mt, c as Ee } from "./feature.js";
3
+ import $, { forwardRef as Ae, useRef as D, useState as W, useEffect as X, useLayoutEffect as ht, createContext as je, useMemo as He, useCallback as Re, memo as gt } from "react";
4
+ import vt from "lodash.throttle";
5
5
  import { B as te } from "./index8.js";
6
- import { d as vt } from "./index9.js";
7
- import { Q as wt } from "./index14.js";
8
- import { e as yt, f as bt, S as qe } from "./useStreamLayerApp2.js";
9
- import { c as St } from "./feature.js";
6
+ import { d as wt } from "./index9.js";
7
+ import { Q as yt } from "./index13.js";
8
+ import { e as bt, f as St, S as qe } from "./useStreamLayerApp2.js";
10
9
  function _e(t) {
11
10
  return t !== null && typeof t == "object" && "constructor" in t && t.constructor === Object;
12
11
  }
@@ -2617,7 +2616,7 @@ function Xs(t, e, s) {
2617
2616
  }));
2618
2617
  }
2619
2618
  function ee(t, e) {
2620
- return typeof window > "u" ? X(t, e) : mt(t, e);
2619
+ return typeof window > "u" ? X(t, e) : ht(t, e);
2621
2620
  }
2622
2621
  const De = /* @__PURE__ */ je(null), Us = /* @__PURE__ */ je(null), lt = /* @__PURE__ */ Ae(function(t, e) {
2623
2622
  let {
@@ -2895,8 +2894,8 @@ const Qs = () => lt, Ks = /* @__PURE__ */ _(Qs())({
2895
2894
  className: t
2896
2895
  }) => /* @__PURE__ */ P(cr, {
2897
2896
  className: t,
2898
- children: /* @__PURE__ */ P(vt, {})
2899
- }), ur = ({ question: t, vote: e }) => t ? /* @__PURE__ */ P(wt, { close: () => {
2897
+ children: /* @__PURE__ */ P(wt, {})
2898
+ }), ur = ({ question: t, vote: e }) => t ? /* @__PURE__ */ P(yt, { close: () => {
2900
2899
  }, openedQuestion: t, vote: e, isLoading: !1, isEarlyPrediction: !0 }) : null, pr = /* @__PURE__ */ _("span")({
2901
2900
  name: "NextButton",
2902
2901
  class: "n991vvm",
@@ -3232,7 +3231,7 @@ const br = ({ data: t, gamification: e, onEvent: s, swipeable: r, autoplay: n })
3232
3231
  e.closeQuestion();
3233
3232
  }, [p, h] = W(1.1);
3234
3233
  return X(() => {
3235
- const g = gt(() => {
3234
+ const g = vt(() => {
3236
3235
  const m = l.current?.size;
3237
3236
  if (!m)
3238
3237
  return;
@@ -3275,7 +3274,7 @@ const br = ({ data: t, gamification: e, onEvent: s, swipeable: r, autoplay: n })
3275
3274
  {
3276
3275
  onEvent: n,
3277
3276
  actionFn: () => n({ type: "slHardRefresh" }),
3278
- description: l instanceof yt && l.code !== bt.InvalidArgument ? `The event ID was not
3277
+ description: l instanceof bt && l.code !== St.InvalidArgument ? `The event ID was not
3279
3278
  specified or is invalid.` : `The server is unable to
3280
3279
  handle this request.`
3281
3280
  }
@@ -3302,7 +3301,7 @@ handle this request.`
3302
3301
  name: "BetPackContainer",
3303
3302
  class: "b18vssq2",
3304
3303
  propsAsIs: !1
3305
- }), ie = "slBetPackCb", Tr = St("betPack-ui"), xr = (t, e = {}) => {
3304
+ }), ie = "slBetPackCb", Tr = mt("betPack-ui"), xr = (t, e = {}) => {
3306
3305
  const { questionId: s, answerId: r } = e, n = { questionId: s, answerId: r };
3307
3306
  Tr.debug({ id: ie, type: t, ...n }), window.top?.postMessage({ id: ie, type: t, ...n }, "*"), window.webkit && window.webkit.messageHandlers && window.webkit.messageHandlers[ie] && window.webkit.messageHandlers[ie].postMessage({ type: t, ...n }), window.slBetPackCb?.postMessage && window.slBetPackCb.postMessage(JSON.stringify({ type: t, ...n, from: "base" }));
3308
3307
  }, Cr = (t) => {
@@ -3343,7 +3342,7 @@ handle this request.`
3343
3342
  name: "SlideSwitchButton",
3344
3343
  class: "spp13y7",
3345
3344
  propsAsIs: !1
3346
- }), Wr = Ae(({ sdk: t, onEvent: e, close: s }, r) => {
3345
+ }), qr = Ae(({ sdk: t, onEvent: e, close: s }, r) => {
3347
3346
  const [n, i] = W(), [l, a] = W(), o = Re(
3348
3347
  (c) => {
3349
3348
  if (c.type === "slBetPackReady") {
@@ -3387,7 +3386,7 @@ handle this request.`
3387
3386
  description: `You are not authorized to
3388
3387
  view this resource.`
3389
3388
  }
3390
- ) : /* @__PURE__ */ P(Le, {}), Gr = ht(({ sdk: t, swipeable: e = !0, onEvent: s = Cr, overlay: r }) => {
3389
+ ) : /* @__PURE__ */ P(Le, {}), Gr = gt(({ sdk: t, swipeable: e = !0, onEvent: s = Cr, overlay: r }) => {
3391
3390
  const n = Se(t.featuresList.getStore()), i = He(() => t.getFeature(qe.GAMES), [n]), l = Se(t.getUserStore());
3392
3391
  return X(() => (t.writeOverlaySessionId(), () => {
3393
3392
  t.writeOverlaySessionId("");
@@ -3401,5 +3400,5 @@ view this resource.`
3401
3400
  });
3402
3401
  export {
3403
3402
  Gr as D,
3404
- Wr as a
3403
+ qr as a
3405
3404
  };
package/lib/es/index6.js CHANGED
@@ -1,5 +1,4 @@
1
1
  import "./feature.js";
2
2
  import "nanostores";
3
- import "./sl-types.js";
4
3
  import { Q as i } from "./useStreamLayerApp2.js";
5
4
  i.FACTOID + "", i.POLL + "", i.TRIVIA + "", i.PREDICTION + "", i.TWEET + "";
package/lib/es/index7.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { jsx as e } from "react/jsx-runtime";
2
- import { c as o } from "./sl-types.js";
2
+ import { c as o } from "./feature.js";
3
3
  import { h as a } from "./theme.js";
4
4
  const l = ({ children: m, customTheme: r, themeMode: s, style: t }) => /* @__PURE__ */ e("div", { className: "StreamLayerSDKTheme", children: /* @__PURE__ */ e("div", { className: o(a, s, r), style: t, children: m }) });
5
5
  export {
package/lib/es/index9.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { jsx as F } from "react/jsx-runtime";
2
- import { d as n } from "./index12.js";
2
+ import { d as n } from "./index15.js";
3
3
  import { useEffect as D, useState as S, useCallback as C } from "react";
4
- import { s as I } from "./sl-types.js";
4
+ import { s as I } from "./feature.js";
5
5
  import { CountdownCircleTimer as t } from "react-countdown-circle-timer";
6
6
  import { B as a } from "./index8.js";
7
7
  const f = {
package/lib/es/insight.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { jsx as u, jsxs as c } from "react/jsx-runtime";
2
2
  import { h as p } from "./index7.js";
3
- import { u as a, s as h } from "./sl-types.js";
3
+ import { u as a, s as h } from "./feature.js";
4
4
  import { useRef as f, useEffect as l } from "react";
5
5
  import { _ as I } from "./Question.js";
6
6
  import { S as g } from "./useStreamLayerApp2.js";