@obb871001/api-integration-sdk 1.0.136 → 1.0.139

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,31 +1,31 @@
1
1
  import Le, { createContext as mi, useContext as ri, useCallback as V, useMemo as ia, useEffect as De, useRef as Ga } from "react";
2
2
  import { useQuery as ie, QueryClient as at, QueryClientProvider as it, useQueries as oi, useMutation as na } from "@tanstack/react-query";
3
3
  import tt from "axios";
4
- import { find as ma, isEmpty as O, isObject as Ve, flatMap as Ae, isArray as ne, map as Ie, entries as lt, values as nt, keys as Ma, get as we, replace as Ra, includes as mt } from "lodash";
4
+ import { find as ma, isEmpty as O, isObject as Ae, flatMap as Ie, isArray as ne, map as Ge, entries as lt, values as nt, keys as Ma, get as Fe, replace as Ra, includes as mt } from "lodash";
5
5
  import rt from "react-dom";
6
6
  function ot(e) {
7
7
  return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
8
8
  }
9
- var Fe = { exports: {} }, he = {};
9
+ var We = { exports: {} }, he = {};
10
10
  var Pa;
11
11
  function st() {
12
12
  if (Pa) return he;
13
13
  Pa = 1;
14
- var e = Le, i = Symbol.for("react.element"), l = Symbol.for("react.fragment"), m = Object.prototype.hasOwnProperty, s = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, u = { key: !0, ref: !0, __self: !0, __source: !0 };
14
+ var e = Le, i = Symbol.for("react.element"), m = Symbol.for("react.fragment"), n = Object.prototype.hasOwnProperty, s = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, u = { key: !0, ref: !0, __self: !0, __source: !0 };
15
15
  function f(_, p, g) {
16
- var r, t = {}, d = null, n = null;
17
- g !== void 0 && (d = "" + g), p.key !== void 0 && (d = "" + p.key), p.ref !== void 0 && (n = p.ref);
18
- for (r in p) m.call(p, r) && !u.hasOwnProperty(r) && (t[r] = p[r]);
16
+ var r, t = {}, d = null, l = null;
17
+ g !== void 0 && (d = "" + g), p.key !== void 0 && (d = "" + p.key), p.ref !== void 0 && (l = p.ref);
18
+ for (r in p) n.call(p, r) && !u.hasOwnProperty(r) && (t[r] = p[r]);
19
19
  if (_ && _.defaultProps) for (r in p = _.defaultProps, p) t[r] === void 0 && (t[r] = p[r]);
20
- return { $$typeof: i, type: _, key: d, ref: n, props: t, _owner: s.current };
20
+ return { $$typeof: i, type: _, key: d, ref: l, props: t, _owner: s.current };
21
21
  }
22
- return he.Fragment = l, he.jsx = f, he.jsxs = f, he;
22
+ return he.Fragment = m, he.jsx = f, he.jsxs = f, he;
23
23
  }
24
24
  var ke = {};
25
25
  var xa;
26
26
  function ut() {
27
27
  return xa || (xa = 1, process.env.NODE_ENV !== "production" && (function() {
28
- var e = Le, i = Symbol.for("react.element"), l = Symbol.for("react.portal"), m = Symbol.for("react.fragment"), s = Symbol.for("react.strict_mode"), u = Symbol.for("react.profiler"), f = Symbol.for("react.provider"), _ = Symbol.for("react.context"), p = Symbol.for("react.forward_ref"), g = Symbol.for("react.suspense"), r = Symbol.for("react.suspense_list"), t = Symbol.for("react.memo"), d = Symbol.for("react.lazy"), n = Symbol.for("react.offscreen"), o = Symbol.iterator, y = "@@iterator";
28
+ var e = Le, i = Symbol.for("react.element"), m = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), s = Symbol.for("react.strict_mode"), u = Symbol.for("react.profiler"), f = Symbol.for("react.provider"), _ = Symbol.for("react.context"), p = Symbol.for("react.forward_ref"), g = Symbol.for("react.suspense"), r = Symbol.for("react.suspense_list"), t = Symbol.for("react.memo"), d = Symbol.for("react.lazy"), l = Symbol.for("react.offscreen"), o = Symbol.iterator, y = "@@iterator";
29
29
  function b(a) {
30
30
  if (a === null || typeof a != "object")
31
31
  return null;
@@ -53,13 +53,13 @@ function ut() {
53
53
  var E = !1, v = !1, D = !1, L = !1, I = !1, Q;
54
54
  Q = Symbol.for("react.module.reference");
55
55
  function Te(a) {
56
- return !!(typeof a == "string" || typeof a == "function" || a === m || a === u || I || a === s || a === g || a === r || L || a === n || E || v || D || typeof a == "object" && a !== null && (a.$$typeof === d || a.$$typeof === t || a.$$typeof === f || a.$$typeof === _ || a.$$typeof === p || // This needs to include all possible module reference object
56
+ return !!(typeof a == "string" || typeof a == "function" || a === n || a === u || I || a === s || a === g || a === r || L || a === l || E || v || D || typeof a == "object" && a !== null && (a.$$typeof === d || a.$$typeof === t || a.$$typeof === f || a.$$typeof === _ || a.$$typeof === p || // This needs to include all possible module reference object
57
57
  // types supported by any Flight configuration anywhere since
58
58
  // we don't know which Flight build this will end up being used
59
59
  // with.
60
60
  a.$$typeof === Q || a.getModuleId !== void 0));
61
61
  }
62
- function Ge(a, U, C) {
62
+ function Me(a, U, C) {
63
63
  var h = a.displayName;
64
64
  if (h)
65
65
  return h;
@@ -77,9 +77,9 @@ function ut() {
77
77
  if (typeof a == "string")
78
78
  return a;
79
79
  switch (a) {
80
- case m:
80
+ case n:
81
81
  return "Fragment";
82
- case l:
82
+ case m:
83
83
  return "Portal";
84
84
  case u:
85
85
  return "Profiler";
@@ -99,7 +99,7 @@ function ut() {
99
99
  var C = a;
100
100
  return B(C._context) + ".Provider";
101
101
  case p:
102
- return Ge(a, a.render, "ForwardRef");
102
+ return Me(a, a.render, "ForwardRef");
103
103
  case t:
104
104
  var h = a.displayName || null;
105
105
  return h !== null ? h : w(a.type) || "Memo";
@@ -114,14 +114,14 @@ function ut() {
114
114
  }
115
115
  return null;
116
116
  }
117
- var A = Object.assign, re = 0, q, Me, Re, x, F, Y, Ce;
117
+ var A = Object.assign, re = 0, q, Re, Pe, x, F, Y, Ce;
118
118
  function oe() {
119
119
  }
120
120
  oe.__reactDisabledLog = !0;
121
121
  function le() {
122
122
  {
123
123
  if (re === 0) {
124
- q = console.log, Me = console.info, Re = console.warn, x = console.error, F = console.group, Y = console.groupCollapsed, Ce = console.groupEnd;
124
+ q = console.log, Re = console.info, Pe = console.warn, x = console.error, F = console.group, Y = console.groupCollapsed, Ce = console.groupEnd;
125
125
  var a = {
126
126
  configurable: !0,
127
127
  enumerable: !0,
@@ -141,7 +141,7 @@ function ut() {
141
141
  re++;
142
142
  }
143
143
  }
144
- function Pe() {
144
+ function xe() {
145
145
  {
146
146
  if (re--, re === 0) {
147
147
  var a = {
@@ -154,10 +154,10 @@ function ut() {
154
154
  value: q
155
155
  }),
156
156
  info: A({}, a, {
157
- value: Me
157
+ value: Re
158
158
  }),
159
159
  warn: A({}, a, {
160
- value: Re
160
+ value: Pe
161
161
  }),
162
162
  error: A({}, a, {
163
163
  value: x
@@ -190,16 +190,16 @@ function ut() {
190
190
  ` + X + a;
191
191
  }
192
192
  }
193
- var se = !1, xe;
193
+ var se = !1, Oe;
194
194
  {
195
195
  var Gi = typeof WeakMap == "function" ? WeakMap : Map;
196
- xe = new Gi();
196
+ Oe = new Gi();
197
197
  }
198
198
  function _a(a, U) {
199
199
  if (!a || se)
200
200
  return "";
201
201
  {
202
- var C = xe.get(a);
202
+ var C = Oe.get(a);
203
203
  if (C !== void 0)
204
204
  return C;
205
205
  }
@@ -254,17 +254,17 @@ function ut() {
254
254
  if (R--, P--, P < 0 || k[R] !== W[P]) {
255
255
  var Z = `
256
256
  ` + k[R].replace(" at new ", " at ");
257
- return a.displayName && Z.includes("<anonymous>") && (Z = Z.replace("<anonymous>", a.displayName)), typeof a == "function" && xe.set(a, Z), Z;
257
+ return a.displayName && Z.includes("<anonymous>") && (Z = Z.replace("<anonymous>", a.displayName)), typeof a == "function" && Oe.set(a, Z), Z;
258
258
  }
259
259
  while (R >= 1 && P >= 0);
260
260
  break;
261
261
  }
262
262
  }
263
263
  } finally {
264
- se = !1, ce.current = M, Pe(), Error.prepareStackTrace = G;
264
+ se = !1, ce.current = M, xe(), Error.prepareStackTrace = G;
265
265
  }
266
266
  var Ue = a ? a.displayName || a.name : "", ue = Ue ? _e(Ue) : "";
267
- return typeof a == "function" && xe.set(a, ue), ue;
267
+ return typeof a == "function" && Oe.set(a, ue), ue;
268
268
  }
269
269
  function Mi(a, U, C) {
270
270
  return _a(a, !1);
@@ -273,7 +273,7 @@ function ut() {
273
273
  var U = a.prototype;
274
274
  return !!(U && U.isReactComponent);
275
275
  }
276
- function Oe(a, U, C) {
276
+ function He(a, U, C) {
277
277
  if (a == null)
278
278
  return "";
279
279
  if (typeof a == "function")
@@ -291,11 +291,11 @@ function ut() {
291
291
  case p:
292
292
  return Mi(a.render);
293
293
  case t:
294
- return Oe(a.type, U, C);
294
+ return He(a.type, U, C);
295
295
  case d: {
296
296
  var h = a, G = h._payload, M = h._init;
297
297
  try {
298
- return Oe(M(G), U, C);
298
+ return He(M(G), U, C);
299
299
  } catch {
300
300
  }
301
301
  }
@@ -303,9 +303,9 @@ function ut() {
303
303
  return "";
304
304
  }
305
305
  var ve = Object.prototype.hasOwnProperty, fa = {}, Ua = c.ReactDebugCurrentFrame;
306
- function He(a) {
306
+ function we(a) {
307
307
  if (a) {
308
- var U = a._owner, C = Oe(a.type, a._source, U ? U.type : null);
308
+ var U = a._owner, C = He(a.type, a._source, U ? U.type : null);
309
309
  Ua.setExtraStackFrame(C);
310
310
  } else
311
311
  Ua.setExtraStackFrame(null);
@@ -325,7 +325,7 @@ function ut() {
325
325
  } catch (R) {
326
326
  k = R;
327
327
  }
328
- k && !(k instanceof Error) && (He(G), T("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", h || "React class", C, N, typeof k), He(null)), k instanceof Error && !(k.message in fa) && (fa[k.message] = !0, He(G), T("Failed %s type: %s", C, k.message), He(null));
328
+ k && !(k instanceof Error) && (we(G), T("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", h || "React class", C, N, typeof k), we(null)), k instanceof Error && !(k.message in fa) && (fa[k.message] = !0, we(G), T("Failed %s type: %s", C, k.message), we(null));
329
329
  }
330
330
  }
331
331
  }
@@ -450,7 +450,7 @@ function ut() {
450
450
  var Ke = c.ReactCurrentOwner, ha = c.ReactDebugCurrentFrame;
451
451
  function fe(a) {
452
452
  if (a) {
453
- var U = a._owner, C = Oe(a.type, a._source, U ? U.type : null);
453
+ var U = a._owner, C = He(a.type, a._source, U ? U.type : null);
454
454
  ha.setExtraStackFrame(C);
455
455
  } else
456
456
  ha.setExtraStackFrame(null);
@@ -599,7 +599,7 @@ React keys must be passed directly to JSX without using spread:
599
599
  <%s key={someKey} {...props} />`, qe, ue, $i, ue), Ea[ue + qe] = !0;
600
600
  }
601
601
  }
602
- return a === m ? ji(P) : Ki(P), P;
602
+ return a === n ? ji(P) : Ki(P), P;
603
603
  }
604
604
  }
605
605
  function Qi(a, U, C) {
@@ -609,14 +609,14 @@ React keys must be passed directly to JSX without using spread:
609
609
  return La(a, U, C, !1);
610
610
  }
611
611
  var Yi = qi, Xi = Qi;
612
- ke.Fragment = m, ke.jsx = Yi, ke.jsxs = Xi;
612
+ ke.Fragment = n, ke.jsx = Yi, ke.jsxs = Xi;
613
613
  })()), ke;
614
614
  }
615
615
  var Oa;
616
616
  function pt() {
617
- return Oa || (Oa = 1, process.env.NODE_ENV === "production" ? Fe.exports = st() : Fe.exports = ut()), Fe.exports;
617
+ return Oa || (Oa = 1, process.env.NODE_ENV === "production" ? We.exports = st() : We.exports = ut()), We.exports;
618
618
  }
619
- var ze = pt();
619
+ var Ze = pt();
620
620
  const si = mi(null), te = () => {
621
621
  const e = ri(si);
622
622
  if (!e)
@@ -626,14 +626,14 @@ const si = mi(null), te = () => {
626
626
  function gt({
627
627
  baseURL: e,
628
628
  getToken: i,
629
- timeoutMs: l = 15e3,
630
- lng: m = "tw",
629
+ timeoutMs: m = 15e3,
630
+ lng: n = "tw",
631
631
  store: s,
632
632
  onError: u
633
633
  } = {}) {
634
634
  const f = tt.create({
635
635
  baseURL: e,
636
- timeout: l,
636
+ timeout: m,
637
637
  headers: { "Content-Type": "application/json" }
638
638
  });
639
639
  return f.interceptors.request.use(async (_) => {
@@ -642,7 +642,7 @@ function gt({
642
642
  g && (_.headers.Authorization = `Bearer ${g}`);
643
643
  }
644
644
  const p = s?.getState()?.isWalletCurrency || s?.getState()?.currency?.currentCurrency || "TWD";
645
- return _.headers.Currency = p, _.headers["currency-code"] = p, _.headers.lang = m, _;
645
+ return _.headers.Currency = p, _.headers["currency-code"] = p, _.headers.lang = n, _;
646
646
  }), f.interceptors.response.use(
647
647
  (_) => _.data,
648
648
  (_) => u ? u(_, { instance: f }) : Promise.reject(_)
@@ -656,10 +656,10 @@ const ui = mi(null), sl = () => {
656
656
  );
657
657
  return e;
658
658
  }, ul = () => {
659
- const e = (m, s) => !m && !s, i = (m) => m.startsWith("pc.");
659
+ const e = (n, s) => !n && !s, i = (n) => n.startsWith("pc.");
660
660
  return {
661
661
  executeLogout: ({
662
- isCallBackInvalid: m = !1,
662
+ isCallBackInvalid: n = !1,
663
663
  hostname: s = "",
664
664
  shouldRedirect: u,
665
665
  onShowError: f,
@@ -669,24 +669,24 @@ const ui = mi(null), sl = () => {
669
669
  onGoogleLogout: r
670
670
  }) => {
671
671
  const t = i(s);
672
- e(m, t) && f?.(), _?.(), p?.(), u && g?.("/"), r?.();
672
+ e(n, t) && f?.(), _?.(), p?.(), u && g?.("/"), r?.();
673
673
  },
674
674
  shouldShowErrorNotice: e,
675
675
  isMachineDomain: i
676
676
  };
677
- }, pi = (e = [], i) => ma(e, { gameTypeName: i })?.gameTypeUid, gi = (e = [], i) => ma(e, { platform: i })?.platformUid, di = (e = [], i) => ma(e, { SubPlatformEnum: i }), ci = (e = [], i, l) => O(e) ? [] : e.filter((m) => l ? String(m?.SubPlatformEnumUid) === String(l?.SubPlatformEnumUid) : String(m.platformUid) === String(i)), dt = (e = []) => O(e) ? {} : e.reduce((i, l) => {
678
- const m = l?.game_subtype || "UNKNOWN";
679
- return i[m] || (i[m] = []), i[m].push(l), i;
677
+ }, pi = (e = [], i) => ma(e, { gameTypeName: i })?.gameTypeUid, gi = (e = [], i) => ma(e, { platform: i })?.platformUid, di = (e = [], i) => ma(e, { SubPlatformEnum: i }), ci = (e = [], i, m) => O(e) ? [] : e.filter((n) => m ? String(n?.SubPlatformEnumUid) === String(m?.SubPlatformEnumUid) : String(n.platformUid) === String(i)), dt = (e = []) => O(e) ? {} : e.reduce((i, m) => {
678
+ const n = m?.game_subtype || "UNKNOWN";
679
+ return i[n] || (i[n] = []), i[n].push(m), i;
680
680
  }, {}), ct = ({
681
681
  gameTypeName: e,
682
682
  platforms: i,
683
- gameList: l,
684
- allGameTypes: m,
683
+ gameList: m,
684
+ allGameTypes: n,
685
685
  allPlatforms: s
686
686
  }) => {
687
- const u = pi(m, e);
687
+ const u = pi(n, e);
688
688
  return u ? i.reduce((f, _) => {
689
- const p = gi(s, _), g = di(s, _), r = l[u] || [], t = ci(
689
+ const p = gi(s, _), g = di(s, _), r = m[u] || [], t = ci(
690
690
  r,
691
691
  p,
692
692
  g
@@ -696,70 +696,70 @@ const ui = mi(null), sl = () => {
696
696
  }, _t = ({
697
697
  platformName: e,
698
698
  gamesOfType: i = [],
699
- allPlatforms: l = []
699
+ allPlatforms: m = []
700
700
  }) => {
701
- const m = gi(l, e), s = di(l, e), u = ci(
701
+ const n = gi(m, e), s = di(m, e), u = ci(
702
702
  i,
703
- m,
703
+ n,
704
704
  s
705
705
  );
706
706
  return dt(u);
707
- }, ft = (e = {}) => !Ve(e) || O(e) ? [] : Ae(e), Ha = (e = []) => !ne(e) || O(e) ? [] : Ie(e, "platform"), Ut = (e = []) => !ne(e) || O(e) ? [] : Ie(e, "gameTypeName"), yt = (e = []) => !ne(e) || O(e) ? [] : Ie(e, "game_subtype"), bt = (e = {}) => !Ve(e) || O(e) ? [] : Ae(e), Tt = (e = [], i = []) => !ne(e) || O(e) ? {} : !ne(i) || O(i) ? {} : e.reduce((l, m) => {
707
+ }, ft = (e = {}) => !Ae(e) || O(e) ? [] : Ie(e), Ha = (e = []) => !ne(e) || O(e) ? [] : Ge(e, "platform"), Ut = (e = []) => !ne(e) || O(e) ? [] : Ge(e, "gameTypeName"), yt = (e = []) => !ne(e) || O(e) ? [] : Ge(e, "game_subtype"), bt = (e = {}) => !Ae(e) || O(e) ? [] : Ie(e), Tt = (e = [], i = []) => !ne(e) || O(e) ? {} : !ne(i) || O(i) ? {} : e.reduce((m, n) => {
708
708
  const s = i.map((u) => u.game_subtype);
709
709
  return s.forEach((u) => {
710
- l[u] = l[u] || [];
711
- }), s.includes(m.game_subtype) && l[m.game_subtype].push(m), l;
710
+ m[u] = m[u] || [];
711
+ }), s.includes(n.game_subtype) && m[n.game_subtype].push(n), m;
712
712
  }, {}), Ct = ({
713
713
  gameTypes: e = [],
714
714
  platforms: i = [],
715
- gameList: l = {},
716
- allGameTypes: m = [],
715
+ gameList: m = {},
716
+ allGameTypes: n = [],
717
717
  allPlatforms: s = []
718
- }) => !ne(e) || !ne(i) ? {} : O(l) ? {} : e.reduce((u, f) => {
718
+ }) => !ne(e) || !ne(i) ? {} : O(m) ? {} : e.reduce((u, f) => {
719
719
  const _ = ct({
720
720
  gameTypeName: f,
721
721
  platforms: i,
722
- gameList: l,
723
- allGameTypes: m,
722
+ gameList: m,
723
+ allGameTypes: n,
724
724
  allPlatforms: s
725
725
  });
726
726
  return O(_) || (u[f] = _), u;
727
727
  }, {}), pl = ({
728
728
  types: e = [],
729
729
  platforms: i = [],
730
- allGameType: l = [],
731
- allGamePlatform: m = [],
730
+ allGameType: m = [],
731
+ allGamePlatform: n = [],
732
732
  allGameList: s = {}
733
733
  } = {}) => !Array.isArray(e) || !Array.isArray(i) ? {} : e.reduce((u, f) => {
734
- const _ = pi(l, f);
734
+ const _ = pi(m, f);
735
735
  if (!_) return u;
736
736
  const p = s[_] || [], g = i.reduce((r, t) => {
737
737
  const d = _t({
738
738
  platformName: t,
739
739
  gamesOfType: p,
740
- allPlatforms: m
740
+ allPlatforms: n
741
741
  });
742
742
  return O(d) ? r : { ...r, [t]: d };
743
743
  }, {});
744
744
  return O(g) || (u[f] = g), u;
745
- }, {}), vt = (e = {}) => !Ve(e) || O(e) ? {} : Object.values(e).reduce((l, m) => (Object.entries(m).forEach(([s, u]) => {
746
- l[s] ? l[s] = [...l[s], ...u] : l[s] = u;
747
- }), l), {}), ht = (e = {}) => {
748
- if (!Ve(e) || O(e)) return {};
745
+ }, {}), vt = (e = {}) => !Ae(e) || O(e) ? {} : Object.values(e).reduce((m, n) => (Object.entries(n).forEach(([s, u]) => {
746
+ m[s] ? m[s] = [...m[s], ...u] : m[s] = u;
747
+ }), m), {}), ht = (e = {}) => {
748
+ if (!Ae(e) || O(e)) return {};
749
749
  const i = {};
750
- for (const [l, m] of Object.entries(e)) {
751
- i[l] = {};
752
- for (const s of m) {
750
+ for (const [m, n] of Object.entries(e)) {
751
+ i[m] = {};
752
+ for (const s of n) {
753
753
  const u = s.game_subtype;
754
- i[l][u] || (i[l][u] = []), i[l][u].push(s);
754
+ i[m][u] || (i[m][u] = []), i[m][u].push(s);
755
755
  }
756
756
  }
757
757
  return i;
758
758
  }, kt = ({
759
759
  allGameList: e = {},
760
760
  allGamePlatform: i = [],
761
- allGameType: l = [],
762
- allGame_subtype: m = [],
761
+ allGameType: m = [],
762
+ allGame_subtype: n = [],
763
763
  allNewGameList: s = [],
764
764
  allTopGameList: u = [],
765
765
  randomlySelectedGames: f = [],
@@ -768,15 +768,15 @@ const ui = mi(null), sl = () => {
768
768
  highlightGames: g = [],
769
769
  originPlatform: r = []
770
770
  }) => {
771
- const t = ft(e), d = Ha(i), n = Ut(l), o = yt(m), y = Ha(r), b = bt(_), c = Ct({
772
- gameTypes: n,
771
+ const t = ft(e), d = Ha(i), l = Ut(m), o = yt(n), y = Ha(r), b = bt(_), c = Ct({
772
+ gameTypes: l,
773
773
  platforms: d,
774
774
  gameList: e,
775
- allGameTypes: l,
775
+ allGameTypes: m,
776
776
  allPlatforms: i
777
- }), T = Tt(t, m), S = vt(c), E = ht(S), v = lt(c).reduce(
777
+ }), T = Tt(t, n), S = vt(c), E = ht(S), v = lt(c).reduce(
778
778
  (L, [I, Q]) => {
779
- const Te = Ae(nt(Q));
779
+ const Te = Ie(nt(Q));
780
780
  return L[I] = Te, L;
781
781
  },
782
782
  {}
@@ -792,10 +792,10 @@ const ui = mi(null), sl = () => {
792
792
  byGameType: D
793
793
  },
794
794
  type: {
795
- main: n,
795
+ main: l,
796
796
  sub: o,
797
- originMain: l,
798
- originSub: m
797
+ originMain: m,
798
+ originSub: n
799
799
  },
800
800
  gameList: {
801
801
  all: t,
@@ -817,11 +817,11 @@ const ui = mi(null), sl = () => {
817
817
  favorite: b
818
818
  }
819
819
  };
820
- }, gl = (e = []) => !ne(e) || O(e) ? [] : Ae(e, (i) => O(i.SubPlatformEnum) ? i : i.SubPlatformEnum.map((l) => ({
820
+ }, gl = (e = []) => !ne(e) || O(e) ? [] : Ie(e, (i) => O(i.SubPlatformEnum) ? i : i.SubPlatformEnum.map((m) => ({
821
821
  ...i,
822
- ...l,
823
- platform: l.SubPlatformEnum,
824
- platformEnum: l.SubPlatformEnum
822
+ ...m,
823
+ platform: m.SubPlatformEnum,
824
+ platformEnum: m.SubPlatformEnum
825
825
  }))), ra = (e) => {
826
826
  switch (e) {
827
827
  case "tw":
@@ -844,21 +844,21 @@ const ui = mi(null), sl = () => {
844
844
  }, me = () => {
845
845
  const { client: e } = te(), i = V(
846
846
  async (r) => {
847
- const { mac_address: t = "", app_version: d = "", anydesk_id: n = "" } = r, { data: o } = await e.post("/cash-register/login", {
847
+ const { mac_address: t = "", app_version: d = "", anydesk_id: l = "" } = r, { data: o } = await e.post("/cash-register/login", {
848
848
  mac_address: t,
849
849
  app_version: d,
850
- anydesk_id: n
850
+ anydesk_id: l
851
851
  });
852
852
  return o;
853
853
  },
854
854
  [e]
855
- ), l = V(async () => e.get("/member/getMemberInfo"), [e]), m = V(async () => await e.get("/member/getGameList"), [e]), s = V(async () => await e.get("/member/getNowCurrencyExchange"), [e]), u = V(async () => await e.get("member/getFavoriteGame"), [e]), f = V(
855
+ ), m = V(async () => e.get("/member/getMemberInfo"), [e]), n = V(async () => await e.get("/member/getGameList"), [e]), s = V(async () => await e.get("/member/getNowCurrencyExchange"), [e]), u = V(async () => await e.get("member/getFavoriteGame"), [e]), f = V(
856
856
  async (r) => {
857
- const { account: t, password: d, trans_code: n } = r;
857
+ const { account: t, password: d, trans_code: l } = r;
858
858
  return await e.post("/login", {
859
859
  memId: t,
860
860
  passwd: d,
861
- trans_code: n
861
+ trans_code: l
862
862
  });
863
863
  },
864
864
  [e]
@@ -873,8 +873,8 @@ const ui = mi(null), sl = () => {
873
873
  ), g = V(async () => await e.get("/profit/ranking"), [e]);
874
874
  return {
875
875
  machineLoginApi: i,
876
- userInfoApi: l,
877
- userGameListApi: m,
876
+ userInfoApi: m,
877
+ userGameListApi: n,
878
878
  userFavoriteGameApi: u,
879
879
  userCurrencyExchangeApi: s,
880
880
  userLoginApi: f,
@@ -903,12 +903,12 @@ const ui = mi(null), sl = () => {
903
903
  },
904
904
  user: { favorite: [] }
905
905
  }, Nt = ({ enabled: e = !0 } = {}) => {
906
- const { getToken: i } = te(), { userFavoriteGameApi: l, userGameListApi: m } = me(), { data: s, isLoading: u, error: f, refetch: _ } = ie({
906
+ const { getToken: i } = te(), { userFavoriteGameApi: m, userGameListApi: n } = me(), { data: s, isLoading: u, error: f, refetch: _ } = ie({
907
907
  queryKey: ["gamesInfo"],
908
908
  queryFn: async () => {
909
909
  let p = {}, g = {};
910
910
  try {
911
- await i?.() && (g = await m(), p = await l());
911
+ await i?.() && (g = await n(), p = await m());
912
912
  } catch (r) {
913
913
  console.warn("Failed to fetch favorite games:", r);
914
914
  }
@@ -27470,19 +27470,19 @@ const ui = mi(null), sl = () => {
27470
27470
  }, Et = ({
27471
27471
  children: e,
27472
27472
  autoFetch: i = !1,
27473
- mockData: l = !1
27473
+ mockData: m = !1
27474
27474
  }) => {
27475
27475
  De(() => {
27476
- l && Dt(!0);
27477
- }, [l]);
27478
- const m = Nt({ enabled: i });
27479
- return /* @__PURE__ */ ze.jsx(ui.Provider, { value: m, children: e });
27476
+ m && Dt(!0);
27477
+ }, [m]);
27478
+ const n = Nt({ enabled: i });
27479
+ return /* @__PURE__ */ Ze.jsx(ui.Provider, { value: n, children: e });
27480
27480
  };
27481
27481
  function dl({
27482
27482
  children: e,
27483
27483
  autoFetchGamesInfo: i = !1,
27484
- useMockData: l = !1,
27485
- queryClient: m,
27484
+ useMockData: m = !1,
27485
+ queryClient: n,
27486
27486
  ...s
27487
27487
  }) {
27488
27488
  const u = ia(() => gt(s), [s]), f = ia(
@@ -27495,16 +27495,16 @@ function dl({
27495
27495
  }
27496
27496
  }),
27497
27497
  []
27498
- ), _ = m || f;
27499
- return /* @__PURE__ */ ze.jsx(it, { client: _, children: /* @__PURE__ */ ze.jsx(si.Provider, { value: { client: u, ...s }, children: /* @__PURE__ */ ze.jsx(Et, { autoFetch: i, mockData: l, children: e }) }) });
27498
+ ), _ = n || f;
27499
+ return /* @__PURE__ */ Ze.jsx(it, { client: _, children: /* @__PURE__ */ Ze.jsx(si.Provider, { value: { client: u, ...s }, children: /* @__PURE__ */ Ze.jsx(Et, { autoFetch: i, mockData: m, children: e }) }) });
27500
27500
  }
27501
27501
  const cl = ({ otherQueryKey: e = [], options: i = {} } = {}) => {
27502
- const { userCurrencyExchangeApi: l } = me(), { getToken: m } = te(), { enabled: s, ...u } = i, _ = !!m?.() && (s ? s.every((p) => p) : !0);
27502
+ const { userCurrencyExchangeApi: m } = me(), { getToken: n } = te(), { enabled: s, ...u } = i, _ = !!n?.() && (s ? s.every((p) => p) : !0);
27503
27503
  return oi({
27504
27504
  queries: [
27505
27505
  {
27506
27506
  queryKey: ["userCurrencyExchange", ...e],
27507
- queryFn: () => l(),
27507
+ queryFn: () => m(),
27508
27508
  enabled: _,
27509
27509
  // ← 使用合併後的條件
27510
27510
  ...u
@@ -27515,24 +27515,24 @@ const cl = ({ otherQueryKey: e = [], options: i = {} } = {}) => {
27515
27515
  }, _l = ({
27516
27516
  refetchInterval: e = 5e4,
27517
27517
  trigger: i = [],
27518
- enabled: l = !0
27518
+ enabled: m = !0
27519
27519
  } = {}) => {
27520
- const { getToken: m } = te(), s = m?.(), { userInfoApi: u } = me();
27520
+ const { getToken: n } = te(), s = n?.(), { userInfoApi: u } = me();
27521
27521
  return oi({
27522
27522
  queries: [
27523
27523
  {
27524
27524
  queryKey: ["getMemberInfo", ...i],
27525
27525
  queryFn: async () => await u(),
27526
27526
  refetchInterval: e,
27527
- enabled: !!s && l
27527
+ enabled: !!s && m
27528
27528
  }
27529
27529
  ]
27530
27530
  });
27531
27531
  }, fl = ({ enabled: e = !0 } = {}) => {
27532
27532
  const {
27533
27533
  userInfoApi: i,
27534
- userFavoriteGameApi: l,
27535
- userGameListApi: m,
27534
+ userFavoriteGameApi: m,
27535
+ userGameListApi: n,
27536
27536
  userCurrencyExchangeApi: s
27537
27537
  } = me(), u = ie({
27538
27538
  queryKey: ["getMemInfo"],
@@ -27540,11 +27540,11 @@ const cl = ({ otherQueryKey: e = [], options: i = {} } = {}) => {
27540
27540
  enabled: e
27541
27541
  }), f = ie({
27542
27542
  queryKey: ["getFavoriteGame"],
27543
- queryFn: async () => l(),
27543
+ queryFn: async () => m(),
27544
27544
  enabled: e && u.isSuccess
27545
27545
  }), _ = ie({
27546
27546
  queryKey: ["getUserGameList"],
27547
- queryFn: async () => m(),
27547
+ queryFn: async () => n(),
27548
27548
  enabled: e && u.isSuccess && f.isSuccess
27549
27549
  }), p = ie({
27550
27550
  queryKey: ["getUserCurrencyExchange"],
@@ -27562,19 +27562,19 @@ var Ye = {}, z = {}, Xe = {}, wa;
27562
27562
  function j() {
27563
27563
  return wa || (wa = 1, (function(e) {
27564
27564
  Object.defineProperty(e, "__esModule", { value: !0 }), e.isEventSourceSupported = e.isReactNative = e.ReadyState = e.DEFAULT_HEARTBEAT = e.UNPARSABLE_JSON_OBJECT = e.DEFAULT_RECONNECT_INTERVAL_MS = e.DEFAULT_RECONNECT_LIMIT = e.SOCKET_IO_PING_CODE = e.SOCKET_IO_PATH = e.SOCKET_IO_PING_INTERVAL = e.DEFAULT_EVENT_SOURCE_OPTIONS = e.EMPTY_EVENT_HANDLERS = e.DEFAULT_OPTIONS = void 0;
27565
- var i = 1, l = 1e3 * i;
27565
+ var i = 1, m = 1e3 * i;
27566
27566
  e.DEFAULT_OPTIONS = {}, e.EMPTY_EVENT_HANDLERS = {}, e.DEFAULT_EVENT_SOURCE_OPTIONS = {
27567
27567
  withCredentials: !1,
27568
27568
  events: e.EMPTY_EVENT_HANDLERS
27569
- }, e.SOCKET_IO_PING_INTERVAL = 25 * l, e.SOCKET_IO_PATH = "/socket.io/?EIO=3&transport=websocket", e.SOCKET_IO_PING_CODE = "2", e.DEFAULT_RECONNECT_LIMIT = 20, e.DEFAULT_RECONNECT_INTERVAL_MS = 5e3, e.UNPARSABLE_JSON_OBJECT = {}, e.DEFAULT_HEARTBEAT = {
27569
+ }, e.SOCKET_IO_PING_INTERVAL = 25 * m, e.SOCKET_IO_PATH = "/socket.io/?EIO=3&transport=websocket", e.SOCKET_IO_PING_CODE = "2", e.DEFAULT_RECONNECT_LIMIT = 20, e.DEFAULT_RECONNECT_INTERVAL_MS = 5e3, e.UNPARSABLE_JSON_OBJECT = {}, e.DEFAULT_HEARTBEAT = {
27570
27570
  message: "ping",
27571
27571
  timeout: 6e4,
27572
27572
  interval: 25e3
27573
27573
  };
27574
- var m;
27574
+ var n;
27575
27575
  (function(u) {
27576
27576
  u[u.UNINSTANTIATED = -1] = "UNINSTANTIATED", u[u.CONNECTING = 0] = "CONNECTING", u[u.OPEN = 1] = "OPEN", u[u.CLOSING = 2] = "CLOSING", u[u.CLOSED = 3] = "CLOSED";
27577
- })(m || (e.ReadyState = m = {}));
27577
+ })(n || (e.ReadyState = n = {}));
27578
27578
  var s = function() {
27579
27579
  try {
27580
27580
  return "EventSource" in globalThis;
@@ -27589,12 +27589,12 @@ var Se = {}, $e = {}, Fa;
27589
27589
  function oa() {
27590
27590
  return Fa || (Fa = 1, (function(e) {
27591
27591
  Object.defineProperty(e, "__esModule", { value: !0 }), e.resetWebSockets = e.sharedWebSockets = void 0, e.sharedWebSockets = {};
27592
- var i = function(l) {
27593
- if (l && e.sharedWebSockets.hasOwnProperty(l))
27594
- delete e.sharedWebSockets[l];
27592
+ var i = function(m) {
27593
+ if (m && e.sharedWebSockets.hasOwnProperty(m))
27594
+ delete e.sharedWebSockets[m];
27595
27595
  else
27596
- for (var m in e.sharedWebSockets)
27597
- e.sharedWebSockets.hasOwnProperty(m) && delete e.sharedWebSockets[m];
27596
+ for (var n in e.sharedWebSockets)
27597
+ e.sharedWebSockets.hasOwnProperty(n) && delete e.sharedWebSockets[n];
27598
27598
  };
27599
27599
  e.resetWebSockets = i;
27600
27600
  })($e)), $e;
@@ -27614,7 +27614,7 @@ function sa() {
27614
27614
  return s;
27615
27615
  };
27616
27616
  $.parseSocketIOUrl = i;
27617
- var l = function(s, u) {
27617
+ var m = function(s, u) {
27618
27618
  u === void 0 && (u = {});
27619
27619
  var f = /\?([\w]+=[\w]+)/, _ = f.test(s), p = "".concat(Object.entries(u).reduce(function(g, r) {
27620
27620
  var t = r[0], d = r[1];
@@ -27622,53 +27622,53 @@ function sa() {
27622
27622
  }, "").slice(0, -1));
27623
27623
  return "".concat(s).concat(_ ? "&" : "?").concat(p);
27624
27624
  };
27625
- $.appendQueryParams = l;
27626
- var m = function(s, u) {
27625
+ $.appendQueryParams = m;
27626
+ var n = function(s, u) {
27627
27627
  u === void 0 && (u = e.SOCKET_IO_PING_INTERVAL);
27628
27628
  var f = function() {
27629
27629
  return s(e.SOCKET_IO_PING_CODE);
27630
27630
  };
27631
27631
  return window.setInterval(f, u);
27632
27632
  };
27633
- return $.setUpSocketIOPing = m, $;
27633
+ return $.setUpSocketIOPing = n, $;
27634
27634
  }
27635
- var We = {}, Ja;
27635
+ var Je = {}, Ja;
27636
27636
  function _i() {
27637
- if (Ja) return We;
27638
- Ja = 1, Object.defineProperty(We, "__esModule", { value: !0 }), We.heartbeat = l;
27637
+ if (Ja) return Je;
27638
+ Ja = 1, Object.defineProperty(Je, "__esModule", { value: !0 }), Je.heartbeat = m;
27639
27639
  var e = j();
27640
- function i(m) {
27641
- return Array.isArray(m) ? m.reduce(function(s, u) {
27640
+ function i(n) {
27641
+ return Array.isArray(n) ? n.reduce(function(s, u) {
27642
27642
  return s.current > u.current ? s : u;
27643
- }).current : m.current;
27643
+ }).current : n.current;
27644
27644
  }
27645
- function l(m, s, u) {
27646
- var f = u || {}, _ = f.interval, p = _ === void 0 ? e.DEFAULT_HEARTBEAT.interval : _, g = f.timeout, r = g === void 0 ? e.DEFAULT_HEARTBEAT.timeout : g, t = f.message, d = t === void 0 ? e.DEFAULT_HEARTBEAT.message : t, n = Math.max(100, p / 10), o = Date.now(), y = setInterval(function() {
27645
+ function m(n, s, u) {
27646
+ var f = u || {}, _ = f.interval, p = _ === void 0 ? e.DEFAULT_HEARTBEAT.interval : _, g = f.timeout, r = g === void 0 ? e.DEFAULT_HEARTBEAT.timeout : g, t = f.message, d = t === void 0 ? e.DEFAULT_HEARTBEAT.message : t, l = Math.max(100, p / 10), o = Date.now(), y = setInterval(function() {
27647
27647
  var b = Date.now(), c = i(s);
27648
27648
  if (c + r <= b)
27649
- console.warn("Heartbeat timed out, closing connection, last message received ".concat(b - c, "ms ago, last ping sent ").concat(b - o, "ms ago")), m.close();
27649
+ console.warn("Heartbeat timed out, closing connection, last message received ".concat(b - c, "ms ago, last ping sent ").concat(b - o, "ms ago")), n.close();
27650
27650
  else if (c + p <= b && o + p <= b)
27651
27651
  try {
27652
- typeof d == "function" ? m.send(d()) : m.send(d), o = b;
27652
+ typeof d == "function" ? n.send(d()) : n.send(d), o = b;
27653
27653
  } catch (T) {
27654
- console.error("Heartbeat failed, closing connection", T instanceof Error ? T.message : T), m.close();
27654
+ console.error("Heartbeat failed, closing connection", T instanceof Error ? T.message : T), n.close();
27655
27655
  }
27656
- }, n);
27657
- return m.addEventListener("close", function() {
27656
+ }, l);
27657
+ return n.addEventListener("close", function() {
27658
27658
  clearInterval(y);
27659
27659
  }), function() {
27660
27660
  };
27661
27661
  }
27662
- return We;
27662
+ return Je;
27663
27663
  }
27664
27664
  var Ne = {}, ea = {}, za;
27665
27665
  function ua() {
27666
27666
  return za || (za = 1, (function(e) {
27667
27667
  Object.defineProperty(e, "__esModule", { value: !0 }), e.resetSubscribers = e.removeSubscriber = e.addSubscriber = e.hasSubscribers = e.getSubscribers = void 0;
27668
- var i = {}, l = [], m = function(p) {
27669
- return (0, e.hasSubscribers)(p) ? Array.from(i[p]) : l;
27668
+ var i = {}, m = [], n = function(p) {
27669
+ return (0, e.hasSubscribers)(p) ? Array.from(i[p]) : m;
27670
27670
  };
27671
- e.getSubscribers = m;
27671
+ e.getSubscribers = n;
27672
27672
  var s = function(p) {
27673
27673
  var g;
27674
27674
  return ((g = i[p]) === null || g === void 0 ? void 0 : g.size) > 0;
@@ -27695,13 +27695,13 @@ function ua() {
27695
27695
  var Za;
27696
27696
  function pa() {
27697
27697
  if (Za) return Ne;
27698
- Za = 1, Object.defineProperty(Ne, "__esModule", { value: !0 }), Ne.assertIsWebSocket = l, Ne.resetGlobalState = m;
27698
+ Za = 1, Object.defineProperty(Ne, "__esModule", { value: !0 }), Ne.assertIsWebSocket = m, Ne.resetGlobalState = n;
27699
27699
  var e = oa(), i = ua();
27700
- function l(s, u) {
27700
+ function m(s, u) {
27701
27701
  if (!u && !(s instanceof WebSocket))
27702
27702
  throw new Error("");
27703
27703
  }
27704
- function m(s) {
27704
+ function n(s) {
27705
27705
  (0, i.resetSubscribers)(s), (0, e.resetWebSockets)(s);
27706
27706
  }
27707
27707
  return Ne;
@@ -27712,7 +27712,7 @@ function Lt() {
27712
27712
  Va = 1;
27713
27713
  var e = pe && pe.__assign || function() {
27714
27714
  return e = Object.assign || function(r) {
27715
- for (var t, d = 1, n = arguments.length; d < n; d++) {
27715
+ for (var t, d = 1, l = arguments.length; d < l; d++) {
27716
27716
  t = arguments[d];
27717
27717
  for (var o in t) Object.prototype.hasOwnProperty.call(t, o) && (r[o] = t[o]);
27718
27718
  }
@@ -27720,58 +27720,58 @@ function Lt() {
27720
27720
  }, e.apply(this, arguments);
27721
27721
  };
27722
27722
  Object.defineProperty(pe, "__esModule", { value: !0 }), pe.attachListeners = void 0;
27723
- var i = sa(), l = _i(), m = j(), s = pa(), u = function(r, t, d, n) {
27723
+ var i = sa(), m = _i(), n = j(), s = pa(), u = function(r, t, d, l) {
27724
27724
  r.onmessage = function(o) {
27725
27725
  var y;
27726
- t.current.onMessage && t.current.onMessage(o), typeof n?.current == "number" && (n.current = Date.now()), !(typeof t.current.filter == "function" && t.current.filter(o) !== !0) && (t.current.heartbeat && typeof t.current.heartbeat != "boolean" && ((y = t.current.heartbeat) === null || y === void 0 ? void 0 : y.returnMessage) === o.data || d(o));
27726
+ t.current.onMessage && t.current.onMessage(o), typeof l?.current == "number" && (l.current = Date.now()), !(typeof t.current.filter == "function" && t.current.filter(o) !== !0) && (t.current.heartbeat && typeof t.current.heartbeat != "boolean" && ((y = t.current.heartbeat) === null || y === void 0 ? void 0 : y.returnMessage) === o.data || d(o));
27727
27727
  };
27728
- }, f = function(r, t, d, n, o) {
27728
+ }, f = function(r, t, d, l, o) {
27729
27729
  r.onopen = function(y) {
27730
- if (t.current.onOpen && t.current.onOpen(y), n.current = 0, d(m.ReadyState.OPEN), t.current.heartbeat && r instanceof WebSocket) {
27730
+ if (t.current.onOpen && t.current.onOpen(y), l.current = 0, d(n.ReadyState.OPEN), t.current.heartbeat && r instanceof WebSocket) {
27731
27731
  var b = typeof t.current.heartbeat == "boolean" ? void 0 : t.current.heartbeat;
27732
- o.current = Date.now(), (0, l.heartbeat)(r, o, b);
27732
+ o.current = Date.now(), (0, m.heartbeat)(r, o, b);
27733
27733
  }
27734
27734
  };
27735
- }, _ = function(r, t, d, n, o) {
27736
- if (m.isEventSourceSupported && r instanceof EventSource)
27735
+ }, _ = function(r, t, d, l, o) {
27736
+ if (n.isEventSourceSupported && r instanceof EventSource)
27737
27737
  return function() {
27738
27738
  };
27739
27739
  (0, s.assertIsWebSocket)(r, t.current.skipAssert);
27740
27740
  var y;
27741
27741
  return r.onclose = function(b) {
27742
27742
  var c;
27743
- if (t.current.onClose && t.current.onClose(b), d(m.ReadyState.CLOSED), t.current.shouldReconnect && t.current.shouldReconnect(b)) {
27744
- var T = (c = t.current.reconnectAttempts) !== null && c !== void 0 ? c : m.DEFAULT_RECONNECT_LIMIT;
27743
+ if (t.current.onClose && t.current.onClose(b), d(n.ReadyState.CLOSED), t.current.shouldReconnect && t.current.shouldReconnect(b)) {
27744
+ var T = (c = t.current.reconnectAttempts) !== null && c !== void 0 ? c : n.DEFAULT_RECONNECT_LIMIT;
27745
27745
  if (o.current < T) {
27746
27746
  var S = typeof t.current.reconnectInterval == "function" ? t.current.reconnectInterval(o.current) : t.current.reconnectInterval;
27747
27747
  y = window.setTimeout(function() {
27748
- o.current++, n();
27749
- }, S ?? m.DEFAULT_RECONNECT_INTERVAL_MS);
27748
+ o.current++, l();
27749
+ }, S ?? n.DEFAULT_RECONNECT_INTERVAL_MS);
27750
27750
  } else
27751
27751
  t.current.onReconnectStop && t.current.onReconnectStop(T), console.warn("Max reconnect attempts of ".concat(T, " exceeded"));
27752
27752
  }
27753
27753
  }, function() {
27754
27754
  return y && window.clearTimeout(y);
27755
27755
  };
27756
- }, p = function(r, t, d, n, o) {
27756
+ }, p = function(r, t, d, l, o) {
27757
27757
  var y;
27758
27758
  return r.onerror = function(b) {
27759
27759
  var c;
27760
- if (t.current.onError && t.current.onError(b), m.isEventSourceSupported && r instanceof EventSource && (t.current.onClose && t.current.onClose(e(e({}, b), { code: 1006, reason: "An error occurred with the EventSource: ".concat(b), wasClean: !1 })), d(m.ReadyState.CLOSED), r.close()), t.current.retryOnError)
27761
- if (o.current < ((c = t.current.reconnectAttempts) !== null && c !== void 0 ? c : m.DEFAULT_RECONNECT_LIMIT)) {
27760
+ if (t.current.onError && t.current.onError(b), n.isEventSourceSupported && r instanceof EventSource && (t.current.onClose && t.current.onClose(e(e({}, b), { code: 1006, reason: "An error occurred with the EventSource: ".concat(b), wasClean: !1 })), d(n.ReadyState.CLOSED), r.close()), t.current.retryOnError)
27761
+ if (o.current < ((c = t.current.reconnectAttempts) !== null && c !== void 0 ? c : n.DEFAULT_RECONNECT_LIMIT)) {
27762
27762
  var T = typeof t.current.reconnectInterval == "function" ? t.current.reconnectInterval(o.current) : t.current.reconnectInterval;
27763
27763
  y = window.setTimeout(function() {
27764
- o.current++, n();
27765
- }, T ?? m.DEFAULT_RECONNECT_INTERVAL_MS);
27764
+ o.current++, l();
27765
+ }, T ?? n.DEFAULT_RECONNECT_INTERVAL_MS);
27766
27766
  } else
27767
27767
  t.current.onReconnectStop && t.current.onReconnectStop(t.current.reconnectAttempts), console.warn("Max reconnect attempts of ".concat(t.current.reconnectAttempts, " exceeded"));
27768
27768
  }, function() {
27769
27769
  return y && window.clearTimeout(y);
27770
27770
  };
27771
- }, g = function(r, t, d, n, o, y, b) {
27771
+ }, g = function(r, t, d, l, o, y, b) {
27772
27772
  var c = t.setLastMessage, T = t.setReadyState, S, E, v;
27773
- return d.current.fromSocketIO && (S = (0, i.setUpSocketIOPing)(b)), u(r, d, c, y), f(r, d, T, o, y), E = _(r, d, T, n, o), v = p(r, d, T, n, o), function() {
27774
- T(m.ReadyState.CLOSING), E(), v(), r.close(), S && clearInterval(S);
27773
+ return d.current.fromSocketIO && (S = (0, i.setUpSocketIOPing)(b)), u(r, d, c, y), f(r, d, T, o, y), E = _(r, d, T, l, o), v = p(r, d, T, l, o), function() {
27774
+ T(n.ReadyState.CLOSING), E(), v(), r.close(), S && clearInterval(S);
27775
27775
  };
27776
27776
  };
27777
27777
  return pe.attachListeners = g, pe;
@@ -27782,57 +27782,57 @@ function Gt() {
27782
27782
  Aa = 1;
27783
27783
  var e = ge && ge.__assign || function() {
27784
27784
  return e = Object.assign || function(t) {
27785
- for (var d, n = 1, o = arguments.length; n < o; n++) {
27786
- d = arguments[n];
27785
+ for (var d, l = 1, o = arguments.length; l < o; l++) {
27786
+ d = arguments[l];
27787
27787
  for (var y in d) Object.prototype.hasOwnProperty.call(d, y) && (t[y] = d[y]);
27788
27788
  }
27789
27789
  return t;
27790
27790
  }, e.apply(this, arguments);
27791
27791
  };
27792
27792
  Object.defineProperty(ge, "__esModule", { value: !0 }), ge.attachSharedListeners = void 0;
27793
- var i = oa(), l = j(), m = ua(), s = sa(), u = _i(), f = function(t, d, n) {
27793
+ var i = oa(), m = j(), n = ua(), s = sa(), u = _i(), f = function(t, d, l) {
27794
27794
  t.onmessage = function(o) {
27795
- (0, m.getSubscribers)(d).forEach(function(y) {
27795
+ (0, n.getSubscribers)(d).forEach(function(y) {
27796
27796
  var b;
27797
- y.optionsRef.current.onMessage && y.optionsRef.current.onMessage(o), typeof ((b = y?.lastMessageTime) === null || b === void 0 ? void 0 : b.current) == "number" && (y.lastMessageTime.current = Date.now()), !(typeof y.optionsRef.current.filter == "function" && y.optionsRef.current.filter(o) !== !0) && (n && typeof n != "boolean" && n?.returnMessage === o.data || y.setLastMessage(o));
27797
+ y.optionsRef.current.onMessage && y.optionsRef.current.onMessage(o), typeof ((b = y?.lastMessageTime) === null || b === void 0 ? void 0 : b.current) == "number" && (y.lastMessageTime.current = Date.now()), !(typeof y.optionsRef.current.filter == "function" && y.optionsRef.current.filter(o) !== !0) && (l && typeof l != "boolean" && l?.returnMessage === o.data || y.setLastMessage(o));
27798
27798
  });
27799
27799
  };
27800
- }, _ = function(t, d, n) {
27800
+ }, _ = function(t, d, l) {
27801
27801
  t.onopen = function(o) {
27802
- var y = (0, m.getSubscribers)(d);
27802
+ var y = (0, n.getSubscribers)(d);
27803
27803
  y.forEach(function(b) {
27804
- b.reconnectCount.current = 0, b.optionsRef.current.onOpen && b.optionsRef.current.onOpen(o), b.setReadyState(l.ReadyState.OPEN), n && t instanceof WebSocket && (b.lastMessageTime.current = Date.now());
27805
- }), n && t instanceof WebSocket && (0, u.heartbeat)(t, y.map(function(b) {
27804
+ b.reconnectCount.current = 0, b.optionsRef.current.onOpen && b.optionsRef.current.onOpen(o), b.setReadyState(m.ReadyState.OPEN), l && t instanceof WebSocket && (b.lastMessageTime.current = Date.now());
27805
+ }), l && t instanceof WebSocket && (0, u.heartbeat)(t, y.map(function(b) {
27806
27806
  return b.lastMessageTime;
27807
- }), typeof n == "boolean" ? void 0 : n);
27807
+ }), typeof l == "boolean" ? void 0 : l);
27808
27808
  };
27809
27809
  }, p = function(t, d) {
27810
- t instanceof WebSocket && (t.onclose = function(n) {
27811
- (0, m.getSubscribers)(d).forEach(function(o) {
27812
- o.optionsRef.current.onClose && o.optionsRef.current.onClose(n), o.setReadyState(l.ReadyState.CLOSED);
27813
- }), delete i.sharedWebSockets[d], (0, m.getSubscribers)(d).forEach(function(o) {
27810
+ t instanceof WebSocket && (t.onclose = function(l) {
27811
+ (0, n.getSubscribers)(d).forEach(function(o) {
27812
+ o.optionsRef.current.onClose && o.optionsRef.current.onClose(l), o.setReadyState(m.ReadyState.CLOSED);
27813
+ }), delete i.sharedWebSockets[d], (0, n.getSubscribers)(d).forEach(function(o) {
27814
27814
  var y;
27815
- if (o.optionsRef.current.shouldReconnect && o.optionsRef.current.shouldReconnect(n)) {
27816
- var b = (y = o.optionsRef.current.reconnectAttempts) !== null && y !== void 0 ? y : l.DEFAULT_RECONNECT_LIMIT;
27815
+ if (o.optionsRef.current.shouldReconnect && o.optionsRef.current.shouldReconnect(l)) {
27816
+ var b = (y = o.optionsRef.current.reconnectAttempts) !== null && y !== void 0 ? y : m.DEFAULT_RECONNECT_LIMIT;
27817
27817
  if (o.reconnectCount.current < b) {
27818
27818
  var c = typeof o.optionsRef.current.reconnectInterval == "function" ? o.optionsRef.current.reconnectInterval(o.reconnectCount.current) : o.optionsRef.current.reconnectInterval;
27819
27819
  setTimeout(function() {
27820
27820
  o.reconnectCount.current++, o.reconnect.current();
27821
- }, c ?? l.DEFAULT_RECONNECT_INTERVAL_MS);
27821
+ }, c ?? m.DEFAULT_RECONNECT_INTERVAL_MS);
27822
27822
  } else
27823
27823
  o.optionsRef.current.onReconnectStop && o.optionsRef.current.onReconnectStop(o.optionsRef.current.reconnectAttempts), console.warn("Max reconnect attempts of ".concat(b, " exceeded"));
27824
27824
  }
27825
27825
  });
27826
27826
  });
27827
27827
  }, g = function(t, d) {
27828
- t.onerror = function(n) {
27829
- (0, m.getSubscribers)(d).forEach(function(o) {
27830
- o.optionsRef.current.onError && o.optionsRef.current.onError(n), l.isEventSourceSupported && t instanceof EventSource && (o.optionsRef.current.onClose && o.optionsRef.current.onClose(e(e({}, n), { code: 1006, reason: "An error occurred with the EventSource: ".concat(n), wasClean: !1 })), o.setReadyState(l.ReadyState.CLOSED));
27831
- }), l.isEventSourceSupported && t instanceof EventSource && t.close();
27828
+ t.onerror = function(l) {
27829
+ (0, n.getSubscribers)(d).forEach(function(o) {
27830
+ o.optionsRef.current.onError && o.optionsRef.current.onError(l), m.isEventSourceSupported && t instanceof EventSource && (o.optionsRef.current.onClose && o.optionsRef.current.onClose(e(e({}, l), { code: 1006, reason: "An error occurred with the EventSource: ".concat(l), wasClean: !1 })), o.setReadyState(m.ReadyState.CLOSED));
27831
+ }), m.isEventSourceSupported && t instanceof EventSource && t.close();
27832
27832
  };
27833
- }, r = function(t, d, n, o) {
27833
+ }, r = function(t, d, l, o) {
27834
27834
  var y;
27835
- return n.current.fromSocketIO && (y = (0, s.setUpSocketIOPing)(o)), f(t, d, n.current.heartbeat), p(t, d), _(t, d, n.current.heartbeat), g(t, d), function() {
27835
+ return l.current.fromSocketIO && (y = (0, s.setUpSocketIOPing)(o)), f(t, d, l.current.heartbeat), p(t, d), _(t, d, l.current.heartbeat), g(t, d), function() {
27836
27836
  y && clearInterval(y);
27837
27837
  };
27838
27838
  };
@@ -27842,30 +27842,30 @@ var Ia;
27842
27842
  function Mt() {
27843
27843
  if (Ia) return Se;
27844
27844
  Ia = 1, Object.defineProperty(Se, "__esModule", { value: !0 }), Se.createOrJoinSocket = void 0;
27845
- var e = oa(), i = j(), l = Lt(), m = Gt(), s = ua(), u = function(_, p, g, r, t) {
27845
+ var e = oa(), i = j(), m = Lt(), n = Gt(), s = ua(), u = function(_, p, g, r, t) {
27846
27846
  return function() {
27847
27847
  if ((0, s.removeSubscriber)(_, p), !(0, s.hasSubscribers)(_)) {
27848
27848
  try {
27849
27849
  var d = e.sharedWebSockets[_];
27850
- d instanceof WebSocket && (d.onclose = function(n) {
27851
- g.current.onClose && g.current.onClose(n), r(i.ReadyState.CLOSED);
27850
+ d instanceof WebSocket && (d.onclose = function(l) {
27851
+ g.current.onClose && g.current.onClose(l), r(i.ReadyState.CLOSED);
27852
27852
  }), d.close();
27853
27853
  } catch {
27854
27854
  }
27855
27855
  t && t(), delete e.sharedWebSockets[_];
27856
27856
  }
27857
27857
  };
27858
- }, f = function(_, p, g, r, t, d, n, o, y) {
27858
+ }, f = function(_, p, g, r, t, d, l, o, y) {
27859
27859
  if (!i.isEventSourceSupported && r.current.eventSourceOptions)
27860
27860
  throw i.isReactNative ? new Error("EventSource is not supported in ReactNative") : new Error("EventSource is not supported");
27861
27861
  if (r.current.share) {
27862
27862
  var b = null;
27863
- e.sharedWebSockets[p] === void 0 ? (e.sharedWebSockets[p] = r.current.eventSourceOptions ? new EventSource(p, r.current.eventSourceOptions) : new WebSocket(p, r.current.protocols), _.current = e.sharedWebSockets[p], g(i.ReadyState.CONNECTING), b = (0, m.attachSharedListeners)(e.sharedWebSockets[p], p, r, y)) : (_.current = e.sharedWebSockets[p], g(e.sharedWebSockets[p].readyState));
27863
+ e.sharedWebSockets[p] === void 0 ? (e.sharedWebSockets[p] = r.current.eventSourceOptions ? new EventSource(p, r.current.eventSourceOptions) : new WebSocket(p, r.current.protocols), _.current = e.sharedWebSockets[p], g(i.ReadyState.CONNECTING), b = (0, n.attachSharedListeners)(e.sharedWebSockets[p], p, r, y)) : (_.current = e.sharedWebSockets[p], g(e.sharedWebSockets[p].readyState));
27864
27864
  var c = {
27865
27865
  setLastMessage: t,
27866
27866
  setReadyState: g,
27867
27867
  optionsRef: r,
27868
- reconnectCount: n,
27868
+ reconnectCount: l,
27869
27869
  lastMessageTime: o,
27870
27870
  reconnect: d
27871
27871
  };
@@ -27873,10 +27873,10 @@ function Mt() {
27873
27873
  } else {
27874
27874
  if (_.current = r.current.eventSourceOptions ? new EventSource(p, r.current.eventSourceOptions) : new WebSocket(p, r.current.protocols), g(i.ReadyState.CONNECTING), !_.current)
27875
27875
  throw new Error("WebSocket failed to be created");
27876
- return (0, l.attachListeners)(_.current, {
27876
+ return (0, m.attachListeners)(_.current, {
27877
27877
  setLastMessage: t,
27878
27878
  setReadyState: g
27879
- }, r, d.current, n, o, y);
27879
+ }, r, d.current, l, o, y);
27880
27880
  }
27881
27881
  };
27882
27882
  return Se.createOrJoinSocket = f, Se;
@@ -27885,12 +27885,12 @@ var ee = {}, Ba;
27885
27885
  function Rt() {
27886
27886
  return Ba || (Ba = 1, (function(e) {
27887
27887
  var i = ee && ee.__awaiter || function(p, g, r, t) {
27888
- function d(n) {
27889
- return n instanceof r ? n : new r(function(o) {
27890
- o(n);
27888
+ function d(l) {
27889
+ return l instanceof r ? l : new r(function(o) {
27890
+ o(l);
27891
27891
  });
27892
27892
  }
27893
- return new (r || (r = Promise))(function(n, o) {
27893
+ return new (r || (r = Promise))(function(l, o) {
27894
27894
  function y(T) {
27895
27895
  try {
27896
27896
  c(t.next(T));
@@ -27906,15 +27906,15 @@ function Rt() {
27906
27906
  }
27907
27907
  }
27908
27908
  function c(T) {
27909
- T.done ? n(T.value) : d(T.value).then(y, b);
27909
+ T.done ? l(T.value) : d(T.value).then(y, b);
27910
27910
  }
27911
27911
  c((t = t.apply(p, g || [])).next());
27912
27912
  });
27913
- }, l = ee && ee.__generator || function(p, g) {
27913
+ }, m = ee && ee.__generator || function(p, g) {
27914
27914
  var r = { label: 0, sent: function() {
27915
- if (n[0] & 1) throw n[1];
27916
- return n[1];
27917
- }, trys: [], ops: [] }, t, d, n, o = Object.create((typeof Iterator == "function" ? Iterator : Object).prototype);
27915
+ if (l[0] & 1) throw l[1];
27916
+ return l[1];
27917
+ }, trys: [], ops: [] }, t, d, l, o = Object.create((typeof Iterator == "function" ? Iterator : Object).prototype);
27918
27918
  return o.next = y(0), o.throw = y(1), o.return = y(2), typeof Symbol == "function" && (o[Symbol.iterator] = function() {
27919
27919
  return this;
27920
27920
  }), o;
@@ -27926,11 +27926,11 @@ function Rt() {
27926
27926
  function b(c) {
27927
27927
  if (t) throw new TypeError("Generator is already executing.");
27928
27928
  for (; o && (o = 0, c[0] && (r = 0)), r; ) try {
27929
- if (t = 1, d && (n = c[0] & 2 ? d.return : c[0] ? d.throw || ((n = d.return) && n.call(d), 0) : d.next) && !(n = n.call(d, c[1])).done) return n;
27930
- switch (d = 0, n && (c = [c[0] & 2, n.value]), c[0]) {
27929
+ if (t = 1, d && (l = c[0] & 2 ? d.return : c[0] ? d.throw || ((l = d.return) && l.call(d), 0) : d.next) && !(l = l.call(d, c[1])).done) return l;
27930
+ switch (d = 0, l && (c = [c[0] & 2, l.value]), c[0]) {
27931
27931
  case 0:
27932
27932
  case 1:
27933
- n = c;
27933
+ l = c;
27934
27934
  break;
27935
27935
  case 4:
27936
27936
  return r.label++, { value: c[1], done: !1 };
@@ -27941,38 +27941,38 @@ function Rt() {
27941
27941
  c = r.ops.pop(), r.trys.pop();
27942
27942
  continue;
27943
27943
  default:
27944
- if (n = r.trys, !(n = n.length > 0 && n[n.length - 1]) && (c[0] === 6 || c[0] === 2)) {
27944
+ if (l = r.trys, !(l = l.length > 0 && l[l.length - 1]) && (c[0] === 6 || c[0] === 2)) {
27945
27945
  r = 0;
27946
27946
  continue;
27947
27947
  }
27948
- if (c[0] === 3 && (!n || c[1] > n[0] && c[1] < n[3])) {
27948
+ if (c[0] === 3 && (!l || c[1] > l[0] && c[1] < l[3])) {
27949
27949
  r.label = c[1];
27950
27950
  break;
27951
27951
  }
27952
- if (c[0] === 6 && r.label < n[1]) {
27953
- r.label = n[1], n = c;
27952
+ if (c[0] === 6 && r.label < l[1]) {
27953
+ r.label = l[1], l = c;
27954
27954
  break;
27955
27955
  }
27956
- if (n && r.label < n[2]) {
27957
- r.label = n[2], r.ops.push(c);
27956
+ if (l && r.label < l[2]) {
27957
+ r.label = l[2], r.ops.push(c);
27958
27958
  break;
27959
27959
  }
27960
- n[2] && r.ops.pop(), r.trys.pop();
27960
+ l[2] && r.ops.pop(), r.trys.pop();
27961
27961
  continue;
27962
27962
  }
27963
27963
  c = g.call(p, r);
27964
27964
  } catch (T) {
27965
27965
  c = [6, T], d = 0;
27966
27966
  } finally {
27967
- t = n = 0;
27967
+ t = l = 0;
27968
27968
  }
27969
27969
  if (c[0] & 5) throw c[1];
27970
27970
  return { value: c[0] ? c[1] : void 0, done: !0 };
27971
27971
  }
27972
- }, m = ee && ee.__spreadArray || function(p, g, r) {
27973
- if (r || arguments.length === 2) for (var t = 0, d = g.length, n; t < d; t++)
27974
- (n || !(t in g)) && (n || (n = Array.prototype.slice.call(g, 0, t)), n[t] = g[t]);
27975
- return p.concat(n || Array.prototype.slice.call(g));
27972
+ }, n = ee && ee.__spreadArray || function(p, g, r) {
27973
+ if (r || arguments.length === 2) for (var t = 0, d = g.length, l; t < d; t++)
27974
+ (l || !(t in g)) && (l || (l = Array.prototype.slice.call(g, 0, t)), l[t] = g[t]);
27975
+ return p.concat(l || Array.prototype.slice.call(g));
27976
27976
  };
27977
27977
  Object.defineProperty(e, "__esModule", { value: !0 }), e.getUrl = void 0;
27978
27978
  var s = sa(), u = j(), f = function(p) {
@@ -27982,9 +27982,9 @@ function Rt() {
27982
27982
  }, _ = function(p, g) {
27983
27983
  for (var r = [], t = 2; t < arguments.length; t++)
27984
27984
  r[t - 2] = arguments[t];
27985
- return i(void 0, m([p, g], r, !0), void 0, function(d, n, o) {
27985
+ return i(void 0, n([p, g], r, !0), void 0, function(d, l, o) {
27986
27986
  var y, b, c, T, S, E, v, D;
27987
- return o === void 0 && (o = 0), l(this, function(L) {
27987
+ return o === void 0 && (o = 0), m(this, function(L) {
27988
27988
  switch (L.label) {
27989
27989
  case 0:
27990
27990
  if (typeof d != "function") return [3, 10];
@@ -27994,11 +27994,11 @@ function Rt() {
27994
27994
  case 2:
27995
27995
  return y = L.sent(), [3, 9];
27996
27996
  case 3:
27997
- return L.sent(), n.current.retryOnError ? (b = (E = n.current.reconnectAttempts) !== null && E !== void 0 ? E : u.DEFAULT_RECONNECT_LIMIT, o < b ? (c = typeof n.current.reconnectInterval == "function" ? n.current.reconnectInterval(o) : n.current.reconnectInterval, [4, f(c ?? u.DEFAULT_RECONNECT_INTERVAL_MS)]) : [3, 5]) : [3, 7];
27997
+ return L.sent(), l.current.retryOnError ? (b = (E = l.current.reconnectAttempts) !== null && E !== void 0 ? E : u.DEFAULT_RECONNECT_LIMIT, o < b ? (c = typeof l.current.reconnectInterval == "function" ? l.current.reconnectInterval(o) : l.current.reconnectInterval, [4, f(c ?? u.DEFAULT_RECONNECT_INTERVAL_MS)]) : [3, 5]) : [3, 7];
27998
27998
  case 4:
27999
- return L.sent(), [2, (0, e.getUrl)(d, n, o + 1)];
27999
+ return L.sent(), [2, (0, e.getUrl)(d, l, o + 1)];
28000
28000
  case 5:
28001
- return (D = (v = n.current).onReconnectStop) === null || D === void 0 || D.call(v, o), [2, null];
28001
+ return (D = (v = l.current).onReconnectStop) === null || D === void 0 || D.call(v, o), [2, null];
28002
28002
  case 6:
28003
28003
  return [3, 8];
28004
28004
  case 7:
@@ -28010,7 +28010,7 @@ function Rt() {
28010
28010
  case 10:
28011
28011
  y = d, L.label = 11;
28012
28012
  case 11:
28013
- return T = n.current.fromSocketIO ? (0, s.parseSocketIOUrl)(y) : y, S = n.current.queryParams ? (0, s.appendQueryParams)(T, n.current.queryParams) : T, [2, S];
28013
+ return T = l.current.fromSocketIO ? (0, s.parseSocketIOUrl)(y) : y, S = l.current.queryParams ? (0, s.appendQueryParams)(T, l.current.queryParams) : T, [2, S];
28014
28014
  }
28015
28015
  });
28016
28016
  });
@@ -28022,11 +28022,11 @@ var aa = {}, Ka;
28022
28022
  function Pt() {
28023
28023
  return Ka || (Ka = 1, (function(e) {
28024
28024
  Object.defineProperty(e, "__esModule", { value: !0 }), e.websocketWrapper = void 0;
28025
- var i = function(l, m) {
28026
- return new Proxy(l, {
28025
+ var i = function(m, n) {
28026
+ return new Proxy(m, {
28027
28027
  get: function(s, u) {
28028
28028
  var f = s[u];
28029
- return u === "reconnect" ? m : typeof f == "function" ? (console.error("Calling methods directly on the websocket is not supported at this moment. You must use the methods returned by useWebSocket."), function() {
28029
+ return u === "reconnect" ? n : typeof f == "function" ? (console.error("Calling methods directly on the websocket is not supported at this moment. You must use the methods returned by useWebSocket."), function() {
28030
28030
  }) : f;
28031
28031
  },
28032
28032
  set: function(s, u, f) {
@@ -28043,13 +28043,13 @@ function ga() {
28043
28043
  ja = 1;
28044
28044
  var e = z && z.__assign || function() {
28045
28045
  return e = Object.assign || function(d) {
28046
- for (var n, o = 1, y = arguments.length; o < y; o++) {
28047
- n = arguments[o];
28048
- for (var b in n) Object.prototype.hasOwnProperty.call(n, b) && (d[b] = n[b]);
28046
+ for (var l, o = 1, y = arguments.length; o < y; o++) {
28047
+ l = arguments[o];
28048
+ for (var b in l) Object.prototype.hasOwnProperty.call(l, b) && (d[b] = l[b]);
28049
28049
  }
28050
28050
  return d;
28051
28051
  }, e.apply(this, arguments);
28052
- }, i = z && z.__awaiter || function(d, n, o, y) {
28052
+ }, i = z && z.__awaiter || function(d, l, o, y) {
28053
28053
  function b(c) {
28054
28054
  return c instanceof o ? c : new o(function(T) {
28055
28055
  T(c);
@@ -28073,9 +28073,9 @@ function ga() {
28073
28073
  function v(D) {
28074
28074
  D.done ? c(D.value) : b(D.value).then(S, E);
28075
28075
  }
28076
- v((y = y.apply(d, n || [])).next());
28076
+ v((y = y.apply(d, l || [])).next());
28077
28077
  });
28078
- }, l = z && z.__generator || function(d, n) {
28078
+ }, m = z && z.__generator || function(d, l) {
28079
28079
  var o = { label: 0, sent: function() {
28080
28080
  if (c[0] & 1) throw c[1];
28081
28081
  return c[1];
@@ -28125,7 +28125,7 @@ function ga() {
28125
28125
  c[2] && o.ops.pop(), o.trys.pop();
28126
28126
  continue;
28127
28127
  }
28128
- v = n.call(d, o);
28128
+ v = l.call(d, o);
28129
28129
  } catch (D) {
28130
28130
  v = [6, D], b = 0;
28131
28131
  } finally {
@@ -28134,41 +28134,41 @@ function ga() {
28134
28134
  if (v[0] & 5) throw v[1];
28135
28135
  return { value: v[0] ? v[1] : void 0, done: !0 };
28136
28136
  }
28137
- }, m = z && z.__importDefault || function(d) {
28137
+ }, n = z && z.__importDefault || function(d) {
28138
28138
  return d && d.__esModule ? d : { default: d };
28139
28139
  };
28140
28140
  Object.defineProperty(z, "__esModule", { value: !0 }), z.useWebSocket = void 0;
28141
- var s = Le, u = rt, f = j(), _ = Mt(), p = Rt(), g = m(Pt()), r = pa(), t = function(d, n, o) {
28142
- n === void 0 && (n = f.DEFAULT_OPTIONS), o === void 0 && (o = !0);
28141
+ var s = Le, u = rt, f = j(), _ = Mt(), p = Rt(), g = n(Pt()), r = pa(), t = function(d, l, o) {
28142
+ l === void 0 && (l = f.DEFAULT_OPTIONS), o === void 0 && (o = !0);
28143
28143
  var y = (0, s.useState)(null), b = y[0], c = y[1], T = (0, s.useState)({}), S = T[0], E = T[1], v = (0, s.useMemo)(function() {
28144
- if (!n.disableJson && b)
28144
+ if (!l.disableJson && b)
28145
28145
  try {
28146
28146
  return JSON.parse(b.data);
28147
28147
  } catch {
28148
28148
  return f.UNPARSABLE_JSON_OBJECT;
28149
28149
  }
28150
28150
  return null;
28151
- }, [b, n.disableJson]), D = (0, s.useRef)(null), L = (0, s.useRef)(null), I = (0, s.useRef)(function() {
28152
- }), Q = (0, s.useRef)(0), Te = (0, s.useRef)(Date.now()), Ge = (0, s.useRef)([]), B = (0, s.useRef)(null), w = (0, s.useRef)(n);
28153
- w.current = n;
28154
- var A = D.current && S[D.current] !== void 0 ? S[D.current] : d !== null && o === !0 ? f.ReadyState.CONNECTING : f.ReadyState.UNINSTANTIATED, re = n.queryParams ? JSON.stringify(n.queryParams) : null, q = (0, s.useCallback)(function(x, F) {
28151
+ }, [b, l.disableJson]), D = (0, s.useRef)(null), L = (0, s.useRef)(null), I = (0, s.useRef)(function() {
28152
+ }), Q = (0, s.useRef)(0), Te = (0, s.useRef)(Date.now()), Me = (0, s.useRef)([]), B = (0, s.useRef)(null), w = (0, s.useRef)(l);
28153
+ w.current = l;
28154
+ var A = D.current && S[D.current] !== void 0 ? S[D.current] : d !== null && o === !0 ? f.ReadyState.CONNECTING : f.ReadyState.UNINSTANTIATED, re = l.queryParams ? JSON.stringify(l.queryParams) : null, q = (0, s.useCallback)(function(x, F) {
28155
28155
  var Y;
28156
28156
  if (F === void 0 && (F = !0), f.isEventSourceSupported && L.current instanceof EventSource) {
28157
28157
  console.warn("Unable to send a message from an eventSource");
28158
28158
  return;
28159
28159
  }
28160
- ((Y = L.current) === null || Y === void 0 ? void 0 : Y.readyState) === f.ReadyState.OPEN ? ((0, r.assertIsWebSocket)(L.current, w.current.skipAssert), L.current.send(x)) : F && Ge.current.push(x);
28161
- }, []), Me = (0, s.useCallback)(function(x, F) {
28160
+ ((Y = L.current) === null || Y === void 0 ? void 0 : Y.readyState) === f.ReadyState.OPEN ? ((0, r.assertIsWebSocket)(L.current, w.current.skipAssert), L.current.send(x)) : F && Me.current.push(x);
28161
+ }, []), Re = (0, s.useCallback)(function(x, F) {
28162
28162
  F === void 0 && (F = !0), q(JSON.stringify(x), F);
28163
- }, [q]), Re = (0, s.useCallback)(function() {
28163
+ }, [q]), Pe = (0, s.useCallback)(function() {
28164
28164
  return w.current.share !== !0 || f.isEventSourceSupported && L.current instanceof EventSource ? L.current : (B.current === null && L.current && ((0, r.assertIsWebSocket)(L.current, w.current.skipAssert), B.current = (0, g.default)(L.current, I)), B.current);
28165
28165
  }, []);
28166
28166
  return (0, s.useEffect)(function() {
28167
28167
  if (d !== null && o === !0) {
28168
28168
  var x, F = !1, Y = !0, Ce = function() {
28169
28169
  return i(void 0, void 0, void 0, function() {
28170
- var oe, le, Pe;
28171
- return l(this, function(ce) {
28170
+ var oe, le, xe;
28171
+ return m(this, function(ce) {
28172
28172
  switch (ce.label) {
28173
28173
  case 0:
28174
28174
  return oe = D, [4, (0, p.getUrl)(d, w)];
@@ -28184,14 +28184,14 @@ function ga() {
28184
28184
  F || (0, u.flushSync)(function() {
28185
28185
  return c(X);
28186
28186
  });
28187
- }, Pe = function(X) {
28187
+ }, xe = function(X) {
28188
28188
  F || (0, u.flushSync)(function() {
28189
28189
  return E(function(_e) {
28190
28190
  var se;
28191
28191
  return e(e({}, _e), D.current && (se = {}, se[D.current] = X, se));
28192
28192
  });
28193
28193
  });
28194
- }, Y && (x = (0, _.createOrJoinSocket)(L, D.current, Pe, w, le, I, Q, Te, q)), [
28194
+ }, Y && (x = (0, _.createOrJoinSocket)(L, D.current, xe, w, le, I, Q, Te, q)), [
28195
28195
  2
28196
28196
  /*return*/
28197
28197
  ]);
@@ -28209,16 +28209,16 @@ function ga() {
28209
28209
  return e(e({}, oe), D.current && (le = {}, le[D.current] = f.ReadyState.CLOSED, le));
28210
28210
  }));
28211
28211
  }, [d, o, re, q]), (0, s.useEffect)(function() {
28212
- A === f.ReadyState.OPEN && Ge.current.splice(0).forEach(function(x) {
28212
+ A === f.ReadyState.OPEN && Me.current.splice(0).forEach(function(x) {
28213
28213
  q(x);
28214
28214
  });
28215
28215
  }, [A]), {
28216
28216
  sendMessage: q,
28217
- sendJsonMessage: Me,
28217
+ sendJsonMessage: Re,
28218
28218
  lastMessage: b,
28219
28219
  lastJsonMessage: v,
28220
28220
  readyState: A,
28221
- getWebSocket: Re
28221
+ getWebSocket: Pe
28222
28222
  };
28223
28223
  };
28224
28224
  return z.useWebSocket = t, z;
@@ -28237,7 +28237,7 @@ function xt() {
28237
28237
  }, e.apply(this, arguments);
28238
28238
  };
28239
28239
  Object.defineProperty(de, "__esModule", { value: !0 }), de.useSocketIO = void 0;
28240
- var i = Le, l = ga(), m = j(), s = {
28240
+ var i = Le, m = ga(), n = j(), s = {
28241
28241
  type: "empty",
28242
28242
  payload: null
28243
28243
  }, u = function(_) {
@@ -28252,15 +28252,15 @@ function xt() {
28252
28252
  payload: g[1]
28253
28253
  };
28254
28254
  }, f = function(_, p, g) {
28255
- p === void 0 && (p = m.DEFAULT_OPTIONS), g === void 0 && (g = !0);
28255
+ p === void 0 && (p = n.DEFAULT_OPTIONS), g === void 0 && (g = !0);
28256
28256
  var r = (0, i.useMemo)(function() {
28257
28257
  return e(e({}, p), { fromSocketIO: !0 });
28258
- }, []), t = (0, l.useWebSocket)(_, r, g), d = t.sendMessage, n = t.sendJsonMessage, o = t.lastMessage, y = t.readyState, b = t.getWebSocket, c = (0, i.useMemo)(function() {
28258
+ }, []), t = (0, m.useWebSocket)(_, r, g), d = t.sendMessage, l = t.sendJsonMessage, o = t.lastMessage, y = t.readyState, b = t.getWebSocket, c = (0, i.useMemo)(function() {
28259
28259
  return u(o);
28260
28260
  }, [o]);
28261
28261
  return {
28262
28262
  sendMessage: d,
28263
- sendJsonMessage: n,
28263
+ sendJsonMessage: l,
28264
28264
  lastMessage: c,
28265
28265
  lastJsonMessage: c,
28266
28266
  readyState: y,
@@ -28290,17 +28290,17 @@ function Ot() {
28290
28290
  return p;
28291
28291
  };
28292
28292
  Object.defineProperty(ae, "__esModule", { value: !0 }), ae.useEventSource = void 0;
28293
- var l = Le, m = ga(), s = j(), u = function(f, _, p) {
28293
+ var m = Le, n = ga(), s = j(), u = function(f, _, p) {
28294
28294
  _ === void 0 && (_ = s.DEFAULT_EVENT_SOURCE_OPTIONS);
28295
28295
  var g = _.withCredentials, r = _.events, t = i(_, ["withCredentials", "events"]);
28296
28296
  p === void 0 && (p = !0);
28297
28297
  var d = e(e({}, t), { eventSourceOptions: {
28298
28298
  withCredentials: g
28299
- } }), n = (0, l.useRef)(s.EMPTY_EVENT_HANDLERS);
28300
- r && (n.current = r);
28301
- var o = (0, m.useWebSocket)(f, d, p), y = o.lastMessage, b = o.readyState, c = o.getWebSocket;
28302
- return (0, l.useEffect)(function() {
28303
- y?.type && Object.entries(n.current).forEach(function(T) {
28299
+ } }), l = (0, m.useRef)(s.EMPTY_EVENT_HANDLERS);
28300
+ r && (l.current = r);
28301
+ var o = (0, n.useWebSocket)(f, d, p), y = o.lastMessage, b = o.readyState, c = o.getWebSocket;
28302
+ return (0, m.useEffect)(function() {
28303
+ y?.type && Object.entries(l.current).forEach(function(T) {
28304
28304
  var S = T[0], E = T[1];
28305
28305
  S === y.type && E(y);
28306
28306
  });
@@ -28320,13 +28320,13 @@ function Ht() {
28320
28320
  Object.defineProperty(e, "default", { enumerable: !0, get: function() {
28321
28321
  return i.useWebSocket;
28322
28322
  } });
28323
- var l = xt();
28323
+ var m = xt();
28324
28324
  Object.defineProperty(e, "useSocketIO", { enumerable: !0, get: function() {
28325
- return l.useSocketIO;
28325
+ return m.useSocketIO;
28326
28326
  } });
28327
- var m = j();
28327
+ var n = j();
28328
28328
  Object.defineProperty(e, "ReadyState", { enumerable: !0, get: function() {
28329
- return m.ReadyState;
28329
+ return n.ReadyState;
28330
28330
  } });
28331
28331
  var s = Ot();
28332
28332
  Object.defineProperty(e, "useEventSource", { enumerable: !0, get: function() {
@@ -28353,9 +28353,9 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28353
28353
  }, Wt = 3e4, Ul = ({
28354
28354
  socketUrl: e,
28355
28355
  socketHandlers: i = {},
28356
- options: l = {}
28356
+ options: m = {}
28357
28357
  }) => {
28358
- const m = Ga(!1), s = Ga(i), {
28358
+ const n = Ga(!1), s = Ga(i), {
28359
28359
  sendMessage: u,
28360
28360
  // 發送普通訊息
28361
28361
  sendJsonMessage: f,
@@ -28369,10 +28369,10 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28369
28369
  } = Ft(e, {
28370
28370
  queryParams: { key: "wsky" },
28371
28371
  onOpen: () => console.log("連線成功"),
28372
- shouldReconnect: () => m.current === !1,
28372
+ shouldReconnect: () => n.current === !1,
28373
28373
  reconnectAttempts: 9999,
28374
28374
  reconnectInterval: 1e3,
28375
- ...l
28375
+ ...m
28376
28376
  }), g = ia(() => {
28377
28377
  try {
28378
28378
  return JSON.parse(_?.data);
@@ -28394,16 +28394,16 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28394
28394
  onDeposit: r,
28395
28395
  onTransCode: t,
28396
28396
  onError: d,
28397
- onUpdateMember: n,
28397
+ onUpdateMember: l,
28398
28398
  onMaintainNotice: o,
28399
28399
  onMaintainNoticeMember: y,
28400
28400
  onReload: b,
28401
28401
  onTransferInGame: c,
28402
28402
  onCashRegisterLimit: T
28403
- } = s.current, S = we(g, "type", ""), E = {
28404
- memberInfoUid: we(g, "member_info_uid", null),
28405
- data: we(g, "data", null),
28406
- memo: we(g, "memo", null)
28403
+ } = s.current, S = Fe(g, "type", ""), E = {
28404
+ memberInfoUid: Fe(g, "member_info_uid", null),
28405
+ data: Fe(g, "data", null),
28406
+ memo: Fe(g, "memo", null)
28407
28407
  };
28408
28408
  switch (S) {
28409
28409
  case K.DEPOSIT:
@@ -28416,7 +28416,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28416
28416
  d?.(E);
28417
28417
  break;
28418
28418
  case K.UPDATE_MEMBER:
28419
- n?.(E);
28419
+ l?.(E);
28420
28420
  break;
28421
28421
  case K.MAINTAIN_NOTICE:
28422
28422
  o?.(E);
@@ -28438,7 +28438,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28438
28438
  console.warn("Unknown socket type:", S);
28439
28439
  break;
28440
28440
  }
28441
- }, [g]), De(() => () => m.current = !0, []), {
28441
+ }, [g]), De(() => () => n.current = !0, []), {
28442
28442
  sendMessage: u,
28443
28443
  sendJsonMessage: f,
28444
28444
  readyState: p
@@ -28446,31 +28446,31 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28446
28446
  };
28447
28447
  }, fi = () => {
28448
28448
  const { client: e } = te(), i = V(async () => {
28449
- const { data: m } = await e.get("/carousels");
28450
- return m;
28451
- }, [e]), l = V(async () => await e.get("/marquees"), [e]);
28452
- return { commonCarouselApi: i, commonMarqueeApi: l };
28449
+ const { data: n } = await e.get("/carousels");
28450
+ return n;
28451
+ }, [e]), m = V(async () => await e.get("/marquees"), [e]);
28452
+ return { commonCarouselApi: i, commonMarqueeApi: m };
28453
28453
  }, yl = () => {
28454
- const { lng: e } = te(), { commonCarouselApi: i } = fi(), l = ra(e);
28454
+ const { lng: e } = te(), { commonCarouselApi: i } = fi(), m = ra(e);
28455
28455
  return ie({
28456
28456
  queryKey: ["getCarouselList"],
28457
28457
  queryFn: async () => await i(),
28458
- select: (m) => m.map((u) => {
28458
+ select: (n) => n.map((u) => {
28459
28459
  const { carousels_lang: f } = u;
28460
28460
  return {
28461
28461
  ...u,
28462
- carousel_current_language: f?.find((_) => _.lang === l) || {}
28462
+ carousel_current_language: f?.find((_) => _.lang === m) || {}
28463
28463
  };
28464
28464
  })
28465
28465
  });
28466
28466
  }, bl = () => {
28467
- const { lng: e } = te(), { commonMarqueeApi: i } = fi(), l = ra(e);
28467
+ const { lng: e } = te(), { commonMarqueeApi: i } = fi(), m = ra(e);
28468
28468
  return ie({
28469
28469
  queryKey: ["getMarqueeList"],
28470
28470
  queryFn: async () => i(),
28471
- select: (m) => {
28472
- const s = m.Marquees;
28473
- return Ie(s, (f) => f[l] || f["en-US"]);
28471
+ select: (n) => {
28472
+ const s = n.Marquees;
28473
+ return Ge(s, (f) => f[m] || f["en-US"]);
28474
28474
  }
28475
28475
  });
28476
28476
  }, Tl = ({ options: e } = {}) => {
@@ -28479,11 +28479,43 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28479
28479
  queryKey: ["rankingGame"],
28480
28480
  queryFn: async () => i(),
28481
28481
  enabled: window.profit_ranking_status === 1,
28482
- select: (l) => l.data || [],
28482
+ select: (m) => {
28483
+ const { data: n } = m;
28484
+ return Ge(n, (u) => {
28485
+ const {
28486
+ game_uid: f,
28487
+ game_code: _,
28488
+ game_name_en: p,
28489
+ game_platform_uid: g,
28490
+ memId: r,
28491
+ platform: t,
28492
+ popularity_ranking: d,
28493
+ profit: l
28494
+ } = u;
28495
+ return {
28496
+ gameUid: f,
28497
+ //遊戲UID
28498
+ gameCode: _,
28499
+ //遊戲代碼
28500
+ gameNameEn: p,
28501
+ //遊戲名稱(英文)
28502
+ gamePlatformUid: g,
28503
+ //遊戲平台UID
28504
+ memId: r,
28505
+ //會員ID
28506
+ platform: t,
28507
+ //平台
28508
+ popularityRanking: d,
28509
+ //人氣排名
28510
+ profit: l
28511
+ //winloss
28512
+ };
28513
+ }) || [];
28514
+ },
28483
28515
  ...e
28484
28516
  });
28485
28517
  }, Jt = () => {
28486
- const { client: e, lng: i } = te(), l = ra(i || "tw");
28518
+ const { client: e, lng: i } = te(), m = ra(i || "tw");
28487
28519
  return { playGameApi: V(
28488
28520
  async (s) => {
28489
28521
  const {
@@ -28501,33 +28533,33 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28501
28533
  return await e.post("/game/go", {
28502
28534
  gameUid: u,
28503
28535
  gameCode: f,
28504
- lang: l,
28536
+ lang: m,
28505
28537
  is_mobile: _,
28506
28538
  currency_code: p,
28507
28539
  gameCurrencyNow: g,
28508
28540
  walletCurrencyNow: g
28509
28541
  });
28510
28542
  },
28511
- [e, l]
28543
+ [e, m]
28512
28544
  ) };
28513
- }, Ui = "3.7.8", zt = Ui, be = typeof Buffer == "function", Xa = typeof TextDecoder == "function" ? new TextDecoder() : void 0, $a = typeof TextEncoder == "function" ? new TextEncoder() : void 0, Zt = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=", Ee = Array.prototype.slice.call(Zt), Je = ((e) => {
28545
+ }, Ui = "3.7.8", zt = Ui, be = typeof Buffer == "function", Xa = typeof TextDecoder == "function" ? new TextDecoder() : void 0, $a = typeof TextEncoder == "function" ? new TextEncoder() : void 0, Zt = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=", Ee = Array.prototype.slice.call(Zt), ze = ((e) => {
28514
28546
  let i = {};
28515
- return e.forEach((l, m) => i[l] = m), i;
28547
+ return e.forEach((m, n) => i[m] = n), i;
28516
28548
  })(Ee), Vt = /^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/, H = String.fromCharCode.bind(String), ei = typeof Uint8Array.from == "function" ? Uint8Array.from.bind(Uint8Array) : (e) => new Uint8Array(Array.prototype.slice.call(e, 0)), yi = (e) => e.replace(/=/g, "").replace(/[+\/]/g, (i) => i == "+" ? "-" : "_"), bi = (e) => e.replace(/[^A-Za-z0-9\+\/]/g, ""), Ti = (e) => {
28517
- let i, l, m, s, u = "";
28549
+ let i, m, n, s, u = "";
28518
28550
  const f = e.length % 3;
28519
28551
  for (let _ = 0; _ < e.length; ) {
28520
- if ((l = e.charCodeAt(_++)) > 255 || (m = e.charCodeAt(_++)) > 255 || (s = e.charCodeAt(_++)) > 255)
28552
+ if ((m = e.charCodeAt(_++)) > 255 || (n = e.charCodeAt(_++)) > 255 || (s = e.charCodeAt(_++)) > 255)
28521
28553
  throw new TypeError("invalid character found");
28522
- i = l << 16 | m << 8 | s, u += Ee[i >> 18 & 63] + Ee[i >> 12 & 63] + Ee[i >> 6 & 63] + Ee[i & 63];
28554
+ i = m << 16 | n << 8 | s, u += Ee[i >> 18 & 63] + Ee[i >> 12 & 63] + Ee[i >> 6 & 63] + Ee[i & 63];
28523
28555
  }
28524
28556
  return f ? u.slice(0, f - 3) + "===".substring(f) : u;
28525
28557
  }, da = typeof btoa == "function" ? (e) => btoa(e) : be ? (e) => Buffer.from(e, "binary").toString("base64") : Ti, ta = be ? (e) => Buffer.from(e).toString("base64") : (e) => {
28526
- let l = [];
28527
- for (let m = 0, s = e.length; m < s; m += 4096)
28528
- l.push(H.apply(null, e.subarray(m, m + 4096)));
28529
- return da(l.join(""));
28530
- }, Ze = (e, i = !1) => i ? yi(ta(e)) : ta(e), At = (e) => {
28558
+ let m = [];
28559
+ for (let n = 0, s = e.length; n < s; n += 4096)
28560
+ m.push(H.apply(null, e.subarray(n, n + 4096)));
28561
+ return da(m.join(""));
28562
+ }, Ve = (e, i = !1) => i ? yi(ta(e)) : ta(e), At = (e) => {
28531
28563
  if (e.length < 2) {
28532
28564
  var i = e.charCodeAt(0);
28533
28565
  return i < 128 ? e : i < 2048 ? H(192 | i >>> 6) + H(128 | i & 63) : H(224 | i >>> 12 & 15) + H(128 | i >>> 6 & 63) + H(128 | i & 63);
@@ -28538,8 +28570,8 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28538
28570
  }, It = /[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g, Ci = (e) => e.replace(It, At), ai = be ? (e) => Buffer.from(e, "utf8").toString("base64") : $a ? (e) => ta($a.encode(e)) : (e) => da(Ci(e)), ye = (e, i = !1) => i ? yi(ai(e)) : ai(e), ii = (e) => ye(e, !0), Bt = /[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g, Kt = (e) => {
28539
28571
  switch (e.length) {
28540
28572
  case 4:
28541
- var i = (7 & e.charCodeAt(0)) << 18 | (63 & e.charCodeAt(1)) << 12 | (63 & e.charCodeAt(2)) << 6 | 63 & e.charCodeAt(3), l = i - 65536;
28542
- return H((l >>> 10) + 55296) + H((l & 1023) + 56320);
28573
+ var i = (7 & e.charCodeAt(0)) << 18 | (63 & e.charCodeAt(1)) << 12 | (63 & e.charCodeAt(2)) << 6 | 63 & e.charCodeAt(3), m = i - 65536;
28574
+ return H((m >>> 10) + 55296) + H((m & 1023) + 56320);
28543
28575
  case 3:
28544
28576
  return H((15 & e.charCodeAt(0)) << 12 | (63 & e.charCodeAt(1)) << 6 | 63 & e.charCodeAt(2));
28545
28577
  default:
@@ -28549,9 +28581,9 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28549
28581
  if (e = e.replace(/\s+/g, ""), !Vt.test(e))
28550
28582
  throw new TypeError("malformed base64.");
28551
28583
  e += "==".slice(2 - (e.length & 3));
28552
- let i, l, m, s = [];
28584
+ let i, m, n, s = [];
28553
28585
  for (let u = 0; u < e.length; )
28554
- i = Je[e.charAt(u++)] << 18 | Je[e.charAt(u++)] << 12 | (l = Je[e.charAt(u++)]) << 6 | (m = Je[e.charAt(u++)]), l === 64 ? s.push(H(i >> 16 & 255)) : m === 64 ? s.push(H(i >> 16 & 255, i >> 8 & 255)) : s.push(H(i >> 16 & 255, i >> 8 & 255, i & 255));
28586
+ i = ze[e.charAt(u++)] << 18 | ze[e.charAt(u++)] << 12 | (m = ze[e.charAt(u++)]) << 6 | (n = ze[e.charAt(u++)]), m === 64 ? s.push(H(i >> 16 & 255)) : n === 64 ? s.push(H(i >> 16 & 255, i >> 8 & 255)) : s.push(H(i >> 16 & 255, i >> 8 & 255, i & 255));
28555
28587
  return s.join("");
28556
28588
  }, ca = typeof atob == "function" ? (e) => atob(bi(e)) : be ? (e) => Buffer.from(e, "base64").toString("binary") : hi, ki = be ? (e) => ei(Buffer.from(e, "base64")) : (e) => ei(ca(e).split("").map((i) => i.charCodeAt(0))), Si = (e) => ki(Ni(e)), jt = be ? (e) => Buffer.from(e, "base64").toString("utf8") : Xa ? (e) => Xa.decode(ki(e)) : (e) => vi(ca(e)), Ni = (e) => bi(e.replace(/[-_]/g, (i) => i == "-" ? "+" : "/")), la = (e) => jt(Ni(e)), Qt = (e) => {
28557
28589
  if (typeof e != "string")
@@ -28564,7 +28596,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28564
28596
  writable: !0,
28565
28597
  configurable: !0
28566
28598
  }), Ei = function() {
28567
- const e = (i, l) => Object.defineProperty(String.prototype, i, Di(l));
28599
+ const e = (i, m) => Object.defineProperty(String.prototype, i, Di(m));
28568
28600
  e("fromBase64", function() {
28569
28601
  return la(this);
28570
28602
  }), e("toBase64", function(i) {
@@ -28577,13 +28609,13 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28577
28609
  return Si(this);
28578
28610
  });
28579
28611
  }, Li = function() {
28580
- const e = (i, l) => Object.defineProperty(Uint8Array.prototype, i, Di(l));
28612
+ const e = (i, m) => Object.defineProperty(Uint8Array.prototype, i, Di(m));
28581
28613
  e("toBase64", function(i) {
28582
- return Ze(this, i);
28614
+ return Ve(this, i);
28583
28615
  }), e("toBase64URI", function() {
28584
- return Ze(this, !0);
28616
+ return Ve(this, !0);
28585
28617
  }), e("toBase64URL", function() {
28586
- return Ze(this, !0);
28618
+ return Ve(this, !0);
28587
28619
  });
28588
28620
  }, qt = () => {
28589
28621
  Ei(), Li();
@@ -28603,18 +28635,18 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28603
28635
  btou: vi,
28604
28636
  decode: la,
28605
28637
  isValid: Qt,
28606
- fromUint8Array: Ze,
28638
+ fromUint8Array: Ve,
28607
28639
  toUint8Array: Si,
28608
28640
  extendString: Ei,
28609
28641
  extendUint8Array: Li,
28610
28642
  extendBuiltins: qt
28611
28643
  }, Cl = (e, i) => {
28612
- const { playGameApi: l } = Jt();
28644
+ const { playGameApi: m } = Jt();
28613
28645
  return ie({
28614
28646
  queryKey: ["playGame"],
28615
28647
  queryFn: async () => {
28616
- const { gameUid: m, gameCode: s, isMobile: u, gameCurrency: f, currentCurrency: _ } = e || {}, p = await l({
28617
- gameUid: m,
28648
+ const { gameUid: n, gameCode: s, isMobile: u, gameCurrency: f, currentCurrency: _ } = e || {}, p = await m({
28649
+ gameUid: n,
28618
28650
  gameCode: s,
28619
28651
  isMobile: u,
28620
28652
  gameCurrency: f,
@@ -28624,7 +28656,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28624
28656
  lang: r,
28625
28657
  not_support_iframe: t,
28626
28658
  portrait: d,
28627
- url: n,
28659
+ url: l,
28628
28660
  is_html_code: o,
28629
28661
  message: y
28630
28662
  } = p;
@@ -28634,8 +28666,8 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28634
28666
  supportIframe: !t,
28635
28667
  supportPortrait: d,
28636
28668
  isHtmlCode: o,
28637
- gameUrl: n,
28638
- decodeGameUrl: Yt.decode(n),
28669
+ gameUrl: l,
28670
+ decodeGameUrl: Yt.decode(l),
28639
28671
  message: y
28640
28672
  };
28641
28673
  },
@@ -28646,7 +28678,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28646
28678
  const { userLoginApi: i } = me();
28647
28679
  return na({
28648
28680
  mutationKey: ["userLogin"],
28649
- mutationFn: async (l) => i(l),
28681
+ mutationFn: async (m) => i(m),
28650
28682
  ...e
28651
28683
  });
28652
28684
  }, $t = ({ options: e } = {}) => {
@@ -28660,7 +28692,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28660
28692
  const { addOrRemoveFavoriteGameApi: i } = me();
28661
28693
  return na({
28662
28694
  mutationKey: ["toggleFavoriteGame"],
28663
- mutationFn: async (l) => i(l),
28695
+ mutationFn: async (m) => i(m),
28664
28696
  ...e
28665
28697
  });
28666
28698
  }, vl = ({
@@ -28670,10 +28702,10 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28670
28702
  toggleFavoriteGame: {}
28671
28703
  }
28672
28704
  } = {}) => {
28673
- const i = Xt({ options: e.login }), l = $t({ options: e.logout }), m = el({
28705
+ const i = Xt({ options: e.login }), m = $t({ options: e.logout }), n = el({
28674
28706
  options: e.toggleFavoriteGame
28675
28707
  });
28676
- return { login: i, logout: l, toggleFavoriteGame: m };
28708
+ return { login: i, logout: m, toggleFavoriteGame: n };
28677
28709
  }, ti = (e) => {
28678
28710
  switch (e) {
28679
28711
  case "tw":
@@ -28694,8 +28726,8 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28694
28726
  return "En";
28695
28727
  }
28696
28728
  }, al = "https://d1h3qe8voog6w4.cloudfront.net", li = "https://d3jx2uvukujuvn.cloudfront.net", ni = "game-icon-ds88", hl = ({ gameData: e = {} } = {}) => {
28697
- const { lng: i } = te(), l = ti(i), {
28698
- gameCode: m,
28729
+ const { lng: i } = te(), m = ti(i), {
28730
+ gameCode: n,
28699
28731
  // 遊戲代碼
28700
28732
  gameUid: s,
28701
28733
  // 遊戲唯一標識符
@@ -28716,7 +28748,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28716
28748
  // 遊戲類型
28717
28749
  game_tags: d,
28718
28750
  // 遊戲標籤
28719
- isUnderMaintenance: n,
28751
+ isUnderMaintenance: l,
28720
28752
  // 是否維護中
28721
28753
  support_vertical: o,
28722
28754
  // 是否支援直向
@@ -28732,9 +28764,9 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28732
28764
  // 越南名稱
28733
28765
  gameNameTw: E
28734
28766
  // 繁體中文名稱
28735
- } = e, v = e?.[`gameName${ti(l)}`], D = `${li}/${ni}/en/${g}/${Ra(m, / /g, "_")}.webp`, L = `${li}/${ni}/en/${g}/${Ra(m, / /g, "_")}.gif`;
28767
+ } = e, v = e?.[`gameName${ti(m)}`], D = `${li}/${ni}/en/${g}/${Ra(n, / /g, "_")}.webp`, L = `${li}/${ni}/en/${g}/${Ra(n, / /g, "_")}.gif`;
28736
28768
  return {
28737
- gameCode: m,
28769
+ gameCode: n,
28738
28770
  gameUid: s,
28739
28771
  gameTypeUid: u,
28740
28772
  providerUid: f,
@@ -28744,7 +28776,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28744
28776
  gameSubType: r,
28745
28777
  gameType: t,
28746
28778
  gameTags: d,
28747
- isUnderMaintenance: n,
28779
+ isUnderMaintenance: l,
28748
28780
  supportVertical: o,
28749
28781
  supportHorizontal: y,
28750
28782
  userClickCount: b,
@@ -28769,9 +28801,9 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28769
28801
  "RSG"
28770
28802
  ], e) && i ? `${e}_dark` : e, kl = ({ platformData: e, darkMode: i } = {}) => {
28771
28803
  const {
28772
- SubPlatformEnum: l,
28804
+ SubPlatformEnum: m,
28773
28805
  // 子平台枚舉
28774
- platformEnum: m,
28806
+ platformEnum: n,
28775
28807
  // 平台枚舉
28776
28808
  isUnderMaintenance: s,
28777
28809
  // 是否維護中
@@ -28789,10 +28821,10 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
28789
28821
  // 臨時維護開始時間
28790
28822
  temp_maintenance_end_time: t
28791
28823
  // 臨時維護結束時間
28792
- } = e || {}, d = `${al}/${il}/${tl(m, i)}.png`;
28824
+ } = e || {}, d = `${al}/${il}/${tl(n, i)}.png`;
28793
28825
  return {
28794
- subPlatformEnum: l,
28795
- platformEnum: m,
28826
+ subPlatformEnum: m,
28827
+ platformEnum: n,
28796
28828
  isUnderMaintenance: s,
28797
28829
  maintenanceStartTime: u,
28798
28830
  maintenanceEndTime: f,