@obb871001/api-integration-sdk 1.0.121 → 1.0.123
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.cjs +8 -8
- package/dist/index.js +659 -634
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
import Le, { createContext as
|
|
2
|
-
import { useQuery as
|
|
1
|
+
import Le, { createContext as mi, useContext as ri, useCallback as V, useMemo as ta, useEffect as De, useRef as Ga } from "react";
|
|
2
|
+
import { useQuery as ie, QueryClient as at, QueryClientProvider as it, useQueries as oi, useMutation as ma } from "@tanstack/react-query";
|
|
3
3
|
import tt from "axios";
|
|
4
|
-
import { find as
|
|
4
|
+
import { find as Ve, isEmpty as O, isObject as Ae, flatMap as Ie, isArray as ne, map as Be, entries as lt, values as nt, keys as Ma, get as we, 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
9
|
var Fe = { exports: {} }, he = {};
|
|
10
|
-
var
|
|
10
|
+
var Pa;
|
|
11
11
|
function st() {
|
|
12
|
-
if (
|
|
13
|
-
|
|
14
|
-
var e = Le, i = Symbol.for("react.element"), m = Symbol.for("react.fragment"), n = Object.prototype.hasOwnProperty, r = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,
|
|
15
|
-
function f(_,
|
|
16
|
-
var
|
|
17
|
-
|
|
18
|
-
for (
|
|
19
|
-
if (_ && _.defaultProps) for (
|
|
12
|
+
if (Pa) return he;
|
|
13
|
+
Pa = 1;
|
|
14
|
+
var e = Le, i = Symbol.for("react.element"), m = Symbol.for("react.fragment"), n = Object.prototype.hasOwnProperty, r = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, u = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
15
|
+
function f(_, p, g) {
|
|
16
|
+
var o, 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 (o in p) n.call(p, o) && !u.hasOwnProperty(o) && (t[o] = p[o]);
|
|
19
|
+
if (_ && _.defaultProps) for (o in p = _.defaultProps, p) t[o] === void 0 && (t[o] = p[o]);
|
|
20
20
|
return { $$typeof: i, type: _, key: d, ref: l, props: t, _owner: r.current };
|
|
21
21
|
}
|
|
22
22
|
return he.Fragment = m, he.jsx = f, he.jsxs = f, he;
|
|
23
23
|
}
|
|
24
24
|
var ke = {};
|
|
25
|
-
var
|
|
25
|
+
var xa;
|
|
26
26
|
function ut() {
|
|
27
|
-
return
|
|
28
|
-
var e = Le, i = Symbol.for("react.element"), m = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = Symbol.for("react.strict_mode"),
|
|
27
|
+
return xa || (xa = 1, process.env.NODE_ENV !== "production" && (function() {
|
|
28
|
+
var e = Le, i = Symbol.for("react.element"), m = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), r = 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"), o = Symbol.for("react.suspense_list"), t = Symbol.for("react.memo"), d = Symbol.for("react.lazy"), l = Symbol.for("react.offscreen"), s = Symbol.iterator, y = "@@iterator";
|
|
29
29
|
function b(a) {
|
|
30
30
|
if (a === null || typeof a != "object")
|
|
31
31
|
return null;
|
|
32
|
-
var U =
|
|
32
|
+
var U = s && a[s] || a[y];
|
|
33
33
|
return typeof U == "function" ? U : null;
|
|
34
34
|
}
|
|
35
35
|
var c = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
@@ -53,7 +53,7 @@ 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 === n || a ===
|
|
56
|
+
return !!(typeof a == "string" || typeof a == "function" || a === n || a === u || I || a === r || a === g || a === o || 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.
|
|
@@ -81,13 +81,13 @@ function ut() {
|
|
|
81
81
|
return "Fragment";
|
|
82
82
|
case m:
|
|
83
83
|
return "Portal";
|
|
84
|
-
case
|
|
84
|
+
case u:
|
|
85
85
|
return "Profiler";
|
|
86
86
|
case r:
|
|
87
87
|
return "StrictMode";
|
|
88
|
-
case
|
|
88
|
+
case g:
|
|
89
89
|
return "Suspense";
|
|
90
|
-
case
|
|
90
|
+
case o:
|
|
91
91
|
return "SuspenseList";
|
|
92
92
|
}
|
|
93
93
|
if (typeof a == "object")
|
|
@@ -98,7 +98,7 @@ function ut() {
|
|
|
98
98
|
case f:
|
|
99
99
|
var C = a;
|
|
100
100
|
return B(C._context) + ".Provider";
|
|
101
|
-
case
|
|
101
|
+
case p:
|
|
102
102
|
return Ge(a, a.render, "ForwardRef");
|
|
103
103
|
case t:
|
|
104
104
|
var h = a.displayName || null;
|
|
@@ -114,18 +114,18 @@ function ut() {
|
|
|
114
114
|
}
|
|
115
115
|
return null;
|
|
116
116
|
}
|
|
117
|
-
var
|
|
118
|
-
function
|
|
117
|
+
var A = Object.assign, re = 0, q, Me, Re, x, F, Y, Ce;
|
|
118
|
+
function oe() {
|
|
119
119
|
}
|
|
120
|
-
|
|
121
|
-
function
|
|
120
|
+
oe.__reactDisabledLog = !0;
|
|
121
|
+
function le() {
|
|
122
122
|
{
|
|
123
|
-
if (
|
|
123
|
+
if (re === 0) {
|
|
124
124
|
q = console.log, Me = console.info, Re = 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,
|
|
128
|
-
value:
|
|
128
|
+
value: oe,
|
|
129
129
|
writable: !0
|
|
130
130
|
};
|
|
131
131
|
Object.defineProperties(console, {
|
|
@@ -138,42 +138,42 @@ function ut() {
|
|
|
138
138
|
groupEnd: a
|
|
139
139
|
});
|
|
140
140
|
}
|
|
141
|
-
|
|
141
|
+
re++;
|
|
142
142
|
}
|
|
143
143
|
}
|
|
144
144
|
function Pe() {
|
|
145
145
|
{
|
|
146
|
-
if (
|
|
146
|
+
if (re--, re === 0) {
|
|
147
147
|
var a = {
|
|
148
148
|
configurable: !0,
|
|
149
149
|
enumerable: !0,
|
|
150
150
|
writable: !0
|
|
151
151
|
};
|
|
152
152
|
Object.defineProperties(console, {
|
|
153
|
-
log:
|
|
153
|
+
log: A({}, a, {
|
|
154
154
|
value: q
|
|
155
155
|
}),
|
|
156
|
-
info:
|
|
156
|
+
info: A({}, a, {
|
|
157
157
|
value: Me
|
|
158
158
|
}),
|
|
159
|
-
warn:
|
|
159
|
+
warn: A({}, a, {
|
|
160
160
|
value: Re
|
|
161
161
|
}),
|
|
162
|
-
error:
|
|
162
|
+
error: A({}, a, {
|
|
163
163
|
value: x
|
|
164
164
|
}),
|
|
165
|
-
group:
|
|
165
|
+
group: A({}, a, {
|
|
166
166
|
value: F
|
|
167
167
|
}),
|
|
168
|
-
groupCollapsed:
|
|
168
|
+
groupCollapsed: A({}, a, {
|
|
169
169
|
value: Y
|
|
170
170
|
}),
|
|
171
|
-
groupEnd:
|
|
171
|
+
groupEnd: A({}, a, {
|
|
172
172
|
value: Ce
|
|
173
173
|
})
|
|
174
174
|
});
|
|
175
175
|
}
|
|
176
|
-
|
|
176
|
+
re < 0 && T("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
177
177
|
}
|
|
178
178
|
}
|
|
179
179
|
var ce = c.ReactCurrentDispatcher, X;
|
|
@@ -190,13 +190,13 @@ function ut() {
|
|
|
190
190
|
` + X + a;
|
|
191
191
|
}
|
|
192
192
|
}
|
|
193
|
-
var
|
|
193
|
+
var se = !1, xe;
|
|
194
194
|
{
|
|
195
195
|
var Gi = typeof WeakMap == "function" ? WeakMap : Map;
|
|
196
196
|
xe = new Gi();
|
|
197
197
|
}
|
|
198
|
-
function
|
|
199
|
-
if (!a ||
|
|
198
|
+
function _a(a, U) {
|
|
199
|
+
if (!a || se)
|
|
200
200
|
return "";
|
|
201
201
|
{
|
|
202
202
|
var C = xe.get(a);
|
|
@@ -204,11 +204,11 @@ function ut() {
|
|
|
204
204
|
return C;
|
|
205
205
|
}
|
|
206
206
|
var h;
|
|
207
|
-
|
|
207
|
+
se = !0;
|
|
208
208
|
var G = Error.prepareStackTrace;
|
|
209
209
|
Error.prepareStackTrace = void 0;
|
|
210
210
|
var M;
|
|
211
|
-
M = ce.current, ce.current = null,
|
|
211
|
+
M = ce.current, ce.current = null, le();
|
|
212
212
|
try {
|
|
213
213
|
if (U) {
|
|
214
214
|
var N = function() {
|
|
@@ -261,13 +261,13 @@ function ut() {
|
|
|
261
261
|
}
|
|
262
262
|
}
|
|
263
263
|
} finally {
|
|
264
|
-
|
|
264
|
+
se = !1, ce.current = M, Pe(), Error.prepareStackTrace = G;
|
|
265
265
|
}
|
|
266
|
-
var Ue = a ? a.displayName || a.name : "",
|
|
267
|
-
return typeof a == "function" && xe.set(a,
|
|
266
|
+
var Ue = a ? a.displayName || a.name : "", ue = Ue ? _e(Ue) : "";
|
|
267
|
+
return typeof a == "function" && xe.set(a, ue), ue;
|
|
268
268
|
}
|
|
269
269
|
function Mi(a, U, C) {
|
|
270
|
-
return
|
|
270
|
+
return _a(a, !1);
|
|
271
271
|
}
|
|
272
272
|
function Ri(a) {
|
|
273
273
|
var U = a.prototype;
|
|
@@ -277,18 +277,18 @@ function ut() {
|
|
|
277
277
|
if (a == null)
|
|
278
278
|
return "";
|
|
279
279
|
if (typeof a == "function")
|
|
280
|
-
return
|
|
280
|
+
return _a(a, Ri(a));
|
|
281
281
|
if (typeof a == "string")
|
|
282
282
|
return _e(a);
|
|
283
283
|
switch (a) {
|
|
284
|
-
case
|
|
284
|
+
case g:
|
|
285
285
|
return _e("Suspense");
|
|
286
|
-
case
|
|
286
|
+
case o:
|
|
287
287
|
return _e("SuspenseList");
|
|
288
288
|
}
|
|
289
289
|
if (typeof a == "object")
|
|
290
290
|
switch (a.$$typeof) {
|
|
291
|
-
case
|
|
291
|
+
case p:
|
|
292
292
|
return Mi(a.render);
|
|
293
293
|
case t:
|
|
294
294
|
return Oe(a.type, U, C);
|
|
@@ -302,13 +302,13 @@ function ut() {
|
|
|
302
302
|
}
|
|
303
303
|
return "";
|
|
304
304
|
}
|
|
305
|
-
var ve = Object.prototype.hasOwnProperty,
|
|
305
|
+
var ve = Object.prototype.hasOwnProperty, fa = {}, Ua = c.ReactDebugCurrentFrame;
|
|
306
306
|
function He(a) {
|
|
307
307
|
if (a) {
|
|
308
308
|
var U = a._owner, C = Oe(a.type, a._source, U ? U.type : null);
|
|
309
|
-
|
|
309
|
+
Ua.setExtraStackFrame(C);
|
|
310
310
|
} else
|
|
311
|
-
|
|
311
|
+
Ua.setExtraStackFrame(null);
|
|
312
312
|
}
|
|
313
313
|
function Pi(a, U, C, h, G) {
|
|
314
314
|
{
|
|
@@ -325,12 +325,12 @@ 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
|
|
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));
|
|
329
329
|
}
|
|
330
330
|
}
|
|
331
331
|
}
|
|
332
332
|
var xi = Array.isArray;
|
|
333
|
-
function
|
|
333
|
+
function Ke(a) {
|
|
334
334
|
return xi(a);
|
|
335
335
|
}
|
|
336
336
|
function Oi(a) {
|
|
@@ -341,24 +341,24 @@ function ut() {
|
|
|
341
341
|
}
|
|
342
342
|
function Hi(a) {
|
|
343
343
|
try {
|
|
344
|
-
return
|
|
344
|
+
return ya(a), !1;
|
|
345
345
|
} catch {
|
|
346
346
|
return !0;
|
|
347
347
|
}
|
|
348
348
|
}
|
|
349
|
-
function
|
|
349
|
+
function ya(a) {
|
|
350
350
|
return "" + a;
|
|
351
351
|
}
|
|
352
|
-
function
|
|
352
|
+
function ba(a) {
|
|
353
353
|
if (Hi(a))
|
|
354
|
-
return T("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Oi(a)),
|
|
354
|
+
return T("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Oi(a)), ya(a);
|
|
355
355
|
}
|
|
356
|
-
var
|
|
356
|
+
var Ta = c.ReactCurrentOwner, wi = {
|
|
357
357
|
key: !0,
|
|
358
358
|
ref: !0,
|
|
359
359
|
__self: !0,
|
|
360
360
|
__source: !0
|
|
361
|
-
},
|
|
361
|
+
}, Ca, va;
|
|
362
362
|
function Fi(a) {
|
|
363
363
|
if (ve.call(a, "ref")) {
|
|
364
364
|
var U = Object.getOwnPropertyDescriptor(a, "ref").get;
|
|
@@ -376,12 +376,12 @@ function ut() {
|
|
|
376
376
|
return a.key !== void 0;
|
|
377
377
|
}
|
|
378
378
|
function Ji(a, U) {
|
|
379
|
-
typeof a.ref == "string" &&
|
|
379
|
+
typeof a.ref == "string" && Ta.current;
|
|
380
380
|
}
|
|
381
381
|
function zi(a, U) {
|
|
382
382
|
{
|
|
383
383
|
var C = function() {
|
|
384
|
-
|
|
384
|
+
Ca || (Ca = !0, T("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", U));
|
|
385
385
|
};
|
|
386
386
|
C.isReactWarning = !0, Object.defineProperty(a, "key", {
|
|
387
387
|
get: C,
|
|
@@ -392,7 +392,7 @@ function ut() {
|
|
|
392
392
|
function Zi(a, U) {
|
|
393
393
|
{
|
|
394
394
|
var C = function() {
|
|
395
|
-
|
|
395
|
+
va || (va = !0, T("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", U));
|
|
396
396
|
};
|
|
397
397
|
C.isReactWarning = !0, Object.defineProperty(a, "ref", {
|
|
398
398
|
get: C,
|
|
@@ -432,7 +432,7 @@ function ut() {
|
|
|
432
432
|
function Ai(a, U, C, h, G) {
|
|
433
433
|
{
|
|
434
434
|
var M, N = {}, k = null, W = null;
|
|
435
|
-
C !== void 0 && (
|
|
435
|
+
C !== void 0 && (ba(C), k = "" + C), Wi(U) && (ba(U.key), k = "" + U.key), Fi(U) && (W = U.ref, Ji(U, G));
|
|
436
436
|
for (M in U)
|
|
437
437
|
ve.call(U, M) && !wi.hasOwnProperty(M) && (N[M] = U[M]);
|
|
438
438
|
if (a && a.defaultProps) {
|
|
@@ -444,26 +444,26 @@ function ut() {
|
|
|
444
444
|
var P = typeof a == "function" ? a.displayName || a.name || "Unknown" : a;
|
|
445
445
|
k && zi(N, P), W && Zi(N, P);
|
|
446
446
|
}
|
|
447
|
-
return Vi(a, k, W, G, h,
|
|
447
|
+
return Vi(a, k, W, G, h, Ta.current, N);
|
|
448
448
|
}
|
|
449
449
|
}
|
|
450
|
-
var
|
|
450
|
+
var je = c.ReactCurrentOwner, ha = c.ReactDebugCurrentFrame;
|
|
451
451
|
function fe(a) {
|
|
452
452
|
if (a) {
|
|
453
453
|
var U = a._owner, C = Oe(a.type, a._source, U ? U.type : null);
|
|
454
|
-
|
|
454
|
+
ha.setExtraStackFrame(C);
|
|
455
455
|
} else
|
|
456
|
-
|
|
456
|
+
ha.setExtraStackFrame(null);
|
|
457
457
|
}
|
|
458
|
-
var
|
|
459
|
-
|
|
460
|
-
function
|
|
458
|
+
var Qe;
|
|
459
|
+
Qe = !1;
|
|
460
|
+
function qe(a) {
|
|
461
461
|
return typeof a == "object" && a !== null && a.$$typeof === i;
|
|
462
462
|
}
|
|
463
|
-
function
|
|
463
|
+
function ka() {
|
|
464
464
|
{
|
|
465
|
-
if (
|
|
466
|
-
var a = w(
|
|
465
|
+
if (je.current) {
|
|
466
|
+
var a = w(je.current.type);
|
|
467
467
|
if (a)
|
|
468
468
|
return `
|
|
469
469
|
|
|
@@ -475,10 +475,10 @@ Check the render method of \`` + a + "`.";
|
|
|
475
475
|
function Ii(a) {
|
|
476
476
|
return "";
|
|
477
477
|
}
|
|
478
|
-
var
|
|
478
|
+
var Sa = {};
|
|
479
479
|
function Bi(a) {
|
|
480
480
|
{
|
|
481
|
-
var U =
|
|
481
|
+
var U = ka();
|
|
482
482
|
if (!U) {
|
|
483
483
|
var C = typeof a == "string" ? a : a.displayName || a.name;
|
|
484
484
|
C && (U = `
|
|
@@ -488,35 +488,35 @@ Check the top-level render call using <` + C + ">.");
|
|
|
488
488
|
return U;
|
|
489
489
|
}
|
|
490
490
|
}
|
|
491
|
-
function
|
|
491
|
+
function Na(a, U) {
|
|
492
492
|
{
|
|
493
493
|
if (!a._store || a._store.validated || a.key != null)
|
|
494
494
|
return;
|
|
495
495
|
a._store.validated = !0;
|
|
496
496
|
var C = Bi(U);
|
|
497
|
-
if (
|
|
497
|
+
if (Sa[C])
|
|
498
498
|
return;
|
|
499
|
-
|
|
499
|
+
Sa[C] = !0;
|
|
500
500
|
var h = "";
|
|
501
|
-
a && a._owner && a._owner !==
|
|
501
|
+
a && a._owner && a._owner !== je.current && (h = " It was passed a child from " + w(a._owner.type) + "."), fe(a), T('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', C, h), fe(null);
|
|
502
502
|
}
|
|
503
503
|
}
|
|
504
|
-
function
|
|
504
|
+
function Da(a, U) {
|
|
505
505
|
{
|
|
506
506
|
if (typeof a != "object")
|
|
507
507
|
return;
|
|
508
|
-
if (
|
|
508
|
+
if (Ke(a))
|
|
509
509
|
for (var C = 0; C < a.length; C++) {
|
|
510
510
|
var h = a[C];
|
|
511
|
-
|
|
511
|
+
qe(h) && Na(h, U);
|
|
512
512
|
}
|
|
513
|
-
else if (
|
|
513
|
+
else if (qe(a))
|
|
514
514
|
a._store && (a._store.validated = !0);
|
|
515
515
|
else if (a) {
|
|
516
516
|
var G = b(a);
|
|
517
517
|
if (typeof G == "function" && G !== a.entries)
|
|
518
518
|
for (var M = G.call(a), N; !(N = M.next()).done; )
|
|
519
|
-
|
|
519
|
+
qe(N.value) && Na(N.value, U);
|
|
520
520
|
}
|
|
521
521
|
}
|
|
522
522
|
}
|
|
@@ -528,7 +528,7 @@ Check the top-level render call using <` + C + ">.");
|
|
|
528
528
|
var C;
|
|
529
529
|
if (typeof U == "function")
|
|
530
530
|
C = U.propTypes;
|
|
531
|
-
else if (typeof U == "object" && (U.$$typeof ===
|
|
531
|
+
else if (typeof U == "object" && (U.$$typeof === p || // Note: Memo only checks outer props here.
|
|
532
532
|
// Inner props are checked in the reconciler.
|
|
533
533
|
U.$$typeof === t))
|
|
534
534
|
C = U.propTypes;
|
|
@@ -537,8 +537,8 @@ Check the top-level render call using <` + C + ">.");
|
|
|
537
537
|
if (C) {
|
|
538
538
|
var h = w(U);
|
|
539
539
|
Pi(C, a.props, "prop", h, a);
|
|
540
|
-
} else if (U.PropTypes !== void 0 && !
|
|
541
|
-
|
|
540
|
+
} else if (U.PropTypes !== void 0 && !Qe) {
|
|
541
|
+
Qe = !0;
|
|
542
542
|
var G = w(U);
|
|
543
543
|
T("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", G || "Unknown");
|
|
544
544
|
}
|
|
@@ -557,17 +557,17 @@ Check the top-level render call using <` + C + ">.");
|
|
|
557
557
|
a.ref !== null && (fe(a), T("Invalid attribute `ref` supplied to `React.Fragment`."), fe(null));
|
|
558
558
|
}
|
|
559
559
|
}
|
|
560
|
-
var
|
|
561
|
-
function
|
|
560
|
+
var Ea = {};
|
|
561
|
+
function La(a, U, C, h, G, M) {
|
|
562
562
|
{
|
|
563
563
|
var N = Te(a);
|
|
564
564
|
if (!N) {
|
|
565
565
|
var k = "";
|
|
566
566
|
(a === void 0 || typeof a == "object" && a !== null && Object.keys(a).length === 0) && (k += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
567
567
|
var W = Ii();
|
|
568
|
-
W ? k += W : k +=
|
|
568
|
+
W ? k += W : k += ka();
|
|
569
569
|
var R;
|
|
570
|
-
a === null ? R = "null" :
|
|
570
|
+
a === null ? R = "null" : Ke(a) ? R = "array" : a !== void 0 && a.$$typeof === i ? (R = "<" + (w(a.type) || "Unknown") + " />", k = " Did you accidentally export a JSX literal instead of a component?") : R = typeof a, T("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", R, k);
|
|
571
571
|
}
|
|
572
572
|
var P = Ai(a, U, C, G, M);
|
|
573
573
|
if (P == null)
|
|
@@ -576,49 +576,49 @@ Check the top-level render call using <` + C + ">.");
|
|
|
576
576
|
var Z = U.children;
|
|
577
577
|
if (Z !== void 0)
|
|
578
578
|
if (h)
|
|
579
|
-
if (
|
|
579
|
+
if (Ke(Z)) {
|
|
580
580
|
for (var Ue = 0; Ue < Z.length; Ue++)
|
|
581
|
-
|
|
581
|
+
Da(Z[Ue], a);
|
|
582
582
|
Object.freeze && Object.freeze(Z);
|
|
583
583
|
} else
|
|
584
584
|
T("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
|
|
585
585
|
else
|
|
586
|
-
|
|
586
|
+
Da(Z, a);
|
|
587
587
|
}
|
|
588
588
|
if (ve.call(U, "key")) {
|
|
589
|
-
var
|
|
589
|
+
var ue = w(a), J = Object.keys(U).filter(function(et) {
|
|
590
590
|
return et !== "key";
|
|
591
|
-
}),
|
|
592
|
-
if (!
|
|
591
|
+
}), Ye = J.length > 0 ? "{key: someKey, " + J.join(": ..., ") + ": ...}" : "{key: someKey}";
|
|
592
|
+
if (!Ea[ue + Ye]) {
|
|
593
593
|
var $i = J.length > 0 ? "{" + J.join(": ..., ") + ": ...}" : "{}";
|
|
594
594
|
T(`A props object containing a "key" prop is being spread into JSX:
|
|
595
595
|
let props = %s;
|
|
596
596
|
<%s {...props} />
|
|
597
597
|
React keys must be passed directly to JSX without using spread:
|
|
598
598
|
let props = %s;
|
|
599
|
-
<%s key={someKey} {...props} />`,
|
|
599
|
+
<%s key={someKey} {...props} />`, Ye, ue, $i, ue), Ea[ue + Ye] = !0;
|
|
600
600
|
}
|
|
601
601
|
}
|
|
602
602
|
return a === n ? ji(P) : Ki(P), P;
|
|
603
603
|
}
|
|
604
604
|
}
|
|
605
605
|
function Qi(a, U, C) {
|
|
606
|
-
return
|
|
606
|
+
return La(a, U, C, !0);
|
|
607
607
|
}
|
|
608
608
|
function qi(a, U, C) {
|
|
609
|
-
return
|
|
609
|
+
return La(a, U, C, !1);
|
|
610
610
|
}
|
|
611
611
|
var Yi = qi, Xi = Qi;
|
|
612
612
|
ke.Fragment = n, ke.jsx = Yi, ke.jsxs = Xi;
|
|
613
613
|
})()), ke;
|
|
614
614
|
}
|
|
615
|
-
var
|
|
615
|
+
var Oa;
|
|
616
616
|
function pt() {
|
|
617
|
-
return
|
|
617
|
+
return Oa || (Oa = 1, process.env.NODE_ENV === "production" ? Fe.exports = st() : Fe.exports = ut()), Fe.exports;
|
|
618
618
|
}
|
|
619
619
|
var ze = pt();
|
|
620
|
-
const
|
|
621
|
-
const e =
|
|
620
|
+
const si = mi(null), te = () => {
|
|
621
|
+
const e = ri(si);
|
|
622
622
|
if (!e)
|
|
623
623
|
throw new Error("useApiContext must be used within ApiProvider");
|
|
624
624
|
return e;
|
|
@@ -629,7 +629,7 @@ function gt({
|
|
|
629
629
|
timeoutMs: m = 15e3,
|
|
630
630
|
lng: n = "tw",
|
|
631
631
|
store: r,
|
|
632
|
-
onError:
|
|
632
|
+
onError: u
|
|
633
633
|
} = {}) {
|
|
634
634
|
const f = tt.create({
|
|
635
635
|
baseURL: e,
|
|
@@ -638,43 +638,43 @@ function gt({
|
|
|
638
638
|
});
|
|
639
639
|
return f.interceptors.request.use(async (_) => {
|
|
640
640
|
if (_.headers = _.headers || {}, i) {
|
|
641
|
-
const
|
|
642
|
-
|
|
641
|
+
const g = await i();
|
|
642
|
+
g && (_.headers.Authorization = `Bearer ${g}`);
|
|
643
643
|
}
|
|
644
|
-
const
|
|
645
|
-
return _.headers.Currency =
|
|
644
|
+
const p = r?.getState()?.isWalletCurrency || r?.getState()?.currency?.currentCurrency || "TWD";
|
|
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(_)
|
|
649
649
|
), f;
|
|
650
650
|
}
|
|
651
|
-
const
|
|
652
|
-
const e =
|
|
651
|
+
const ui = mi(null), ul = () => {
|
|
652
|
+
const e = ri(ui);
|
|
653
653
|
if (!e)
|
|
654
654
|
throw new Error(
|
|
655
655
|
"useGameInfoContext must be used within a GameInfoCtx.Provider"
|
|
656
656
|
);
|
|
657
657
|
return e;
|
|
658
|
-
},
|
|
658
|
+
}, pl = () => {
|
|
659
659
|
const e = (n, r) => !n && !r, i = (n) => n.startsWith("pc.");
|
|
660
660
|
return {
|
|
661
661
|
executeLogout: ({
|
|
662
662
|
isCallBackInvalid: n = !1,
|
|
663
663
|
hostname: r = "",
|
|
664
|
-
shouldRedirect:
|
|
664
|
+
shouldRedirect: u,
|
|
665
665
|
onShowError: f,
|
|
666
666
|
onCleanup: _,
|
|
667
|
-
onRemoveToken:
|
|
668
|
-
onRedirect:
|
|
669
|
-
onGoogleLogout:
|
|
667
|
+
onRemoveToken: p,
|
|
668
|
+
onRedirect: g,
|
|
669
|
+
onGoogleLogout: o
|
|
670
670
|
}) => {
|
|
671
671
|
const t = i(r);
|
|
672
|
-
e(n, t) && f?.(), _?.(),
|
|
672
|
+
e(n, t) && f?.(), _?.(), p?.(), u && g?.("/"), o?.();
|
|
673
673
|
},
|
|
674
674
|
shouldShowErrorNotice: e,
|
|
675
675
|
isMachineDomain: i
|
|
676
676
|
};
|
|
677
|
-
},
|
|
677
|
+
}, pi = (e = [], i) => Ve(e, { gameTypeName: i })?.gameTypeUid, gi = (e = [], i) => Ve(e, { platform: i })?.platformUid, di = (e = [], i) => Ve(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
678
|
const n = m?.game_subtype || "UNKNOWN";
|
|
679
679
|
return i[n] || (i[n] = []), i[n].push(m), i;
|
|
680
680
|
}, {}), ct = ({
|
|
@@ -684,12 +684,12 @@ const si = ni(null), sl = () => {
|
|
|
684
684
|
allGameTypes: n,
|
|
685
685
|
allPlatforms: r
|
|
686
686
|
}) => {
|
|
687
|
-
const
|
|
688
|
-
return
|
|
689
|
-
const
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
687
|
+
const u = pi(n, e);
|
|
688
|
+
return u ? i.reduce((f, _) => {
|
|
689
|
+
const p = gi(r, _), g = di(r, _), o = m[u] || [], t = ci(
|
|
690
|
+
o,
|
|
691
|
+
p,
|
|
692
|
+
g
|
|
693
693
|
);
|
|
694
694
|
return O(t) || (f[_] = t), f;
|
|
695
695
|
}, {}) : {};
|
|
@@ -698,16 +698,16 @@ const si = ni(null), sl = () => {
|
|
|
698
698
|
gamesOfType: i = [],
|
|
699
699
|
allPlatforms: m = []
|
|
700
700
|
}) => {
|
|
701
|
-
const n =
|
|
701
|
+
const n = gi(m, e), r = di(m, e), u = ci(
|
|
702
702
|
i,
|
|
703
703
|
n,
|
|
704
704
|
r
|
|
705
705
|
);
|
|
706
|
-
return dt(
|
|
707
|
-
}, ft = (e = {}) => !
|
|
708
|
-
const r = i.map((
|
|
709
|
-
return r.forEach((
|
|
710
|
-
m[
|
|
706
|
+
return dt(u);
|
|
707
|
+
}, ft = (e = {}) => !Ae(e) || O(e) ? [] : Ie(e), Ha = (e = []) => !ne(e) || O(e) ? [] : Be(e, "platform"), Ut = (e = []) => !ne(e) || O(e) ? [] : Be(e, "gameTypeName"), yt = (e = []) => !ne(e) || O(e) ? [] : Be(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
|
+
const r = i.map((u) => u.game_subtype);
|
|
709
|
+
return r.forEach((u) => {
|
|
710
|
+
m[u] = m[u] || [];
|
|
711
711
|
}), r.includes(n.game_subtype) && m[n.game_subtype].push(n), m;
|
|
712
712
|
}, {}), Ct = ({
|
|
713
713
|
gameTypes: e = [],
|
|
@@ -715,7 +715,7 @@ const si = ni(null), sl = () => {
|
|
|
715
715
|
gameList: m = {},
|
|
716
716
|
allGameTypes: n = [],
|
|
717
717
|
allPlatforms: r = []
|
|
718
|
-
}) => !
|
|
718
|
+
}) => !ne(e) || !ne(i) ? {} : O(m) ? {} : e.reduce((u, f) => {
|
|
719
719
|
const _ = ct({
|
|
720
720
|
gameTypeName: f,
|
|
721
721
|
platforms: i,
|
|
@@ -723,35 +723,35 @@ const si = ni(null), sl = () => {
|
|
|
723
723
|
allGameTypes: n,
|
|
724
724
|
allPlatforms: r
|
|
725
725
|
});
|
|
726
|
-
return O(_) || (
|
|
727
|
-
}, {}),
|
|
726
|
+
return O(_) || (u[f] = _), u;
|
|
727
|
+
}, {}), gl = ({
|
|
728
728
|
types: e = [],
|
|
729
729
|
platforms: i = [],
|
|
730
730
|
allGameType: m = [],
|
|
731
731
|
allGamePlatform: n = [],
|
|
732
732
|
allGameList: r = {}
|
|
733
|
-
} = {}) => !Array.isArray(e) || !Array.isArray(i) ? {} : e.reduce((
|
|
734
|
-
const _ =
|
|
735
|
-
if (!_) return
|
|
736
|
-
const
|
|
733
|
+
} = {}) => !Array.isArray(e) || !Array.isArray(i) ? {} : e.reduce((u, f) => {
|
|
734
|
+
const _ = pi(m, f);
|
|
735
|
+
if (!_) return u;
|
|
736
|
+
const p = r[_] || [], g = i.reduce((o, t) => {
|
|
737
737
|
const d = _t({
|
|
738
738
|
platformName: t,
|
|
739
|
-
gamesOfType:
|
|
739
|
+
gamesOfType: p,
|
|
740
740
|
allPlatforms: n
|
|
741
741
|
});
|
|
742
|
-
return O(d) ?
|
|
742
|
+
return O(d) ? o : { ...o, [t]: d };
|
|
743
743
|
}, {});
|
|
744
|
-
return O(
|
|
745
|
-
}, {}), vt = (e = {}) => !
|
|
746
|
-
m[r] ? m[r] = [...m[r], ...
|
|
744
|
+
return O(g) || (u[f] = g), u;
|
|
745
|
+
}, {}), vt = (e = {}) => !Ae(e) || O(e) ? {} : Object.values(e).reduce((m, n) => (Object.entries(n).forEach(([r, u]) => {
|
|
746
|
+
m[r] ? m[r] = [...m[r], ...u] : m[r] = u;
|
|
747
747
|
}), m), {}), ht = (e = {}) => {
|
|
748
|
-
if (!
|
|
748
|
+
if (!Ae(e) || O(e)) return {};
|
|
749
749
|
const i = {};
|
|
750
750
|
for (const [m, n] of Object.entries(e)) {
|
|
751
751
|
i[m] = {};
|
|
752
752
|
for (const r of n) {
|
|
753
|
-
const
|
|
754
|
-
i[m][
|
|
753
|
+
const u = r.game_subtype;
|
|
754
|
+
i[m][u] || (i[m][u] = []), i[m][u].push(r);
|
|
755
755
|
}
|
|
756
756
|
}
|
|
757
757
|
return i;
|
|
@@ -761,14 +761,14 @@ const si = ni(null), sl = () => {
|
|
|
761
761
|
allGameType: m = [],
|
|
762
762
|
allGame_subtype: n = [],
|
|
763
763
|
allNewGameList: r = [],
|
|
764
|
-
allTopGameList:
|
|
764
|
+
allTopGameList: u = [],
|
|
765
765
|
randomlySelectedGames: f = [],
|
|
766
766
|
userFavoriteGame: _ = {},
|
|
767
|
-
exclusiveBrandGames:
|
|
768
|
-
highlightGames:
|
|
769
|
-
originPlatform:
|
|
767
|
+
exclusiveBrandGames: p = [],
|
|
768
|
+
highlightGames: g = [],
|
|
769
|
+
originPlatform: o = []
|
|
770
770
|
}) => {
|
|
771
|
-
const t = ft(e), d =
|
|
771
|
+
const t = ft(e), d = Ha(i), l = Ut(m), s = yt(n), y = Ha(o), b = bt(_), c = Ct({
|
|
772
772
|
gameTypes: l,
|
|
773
773
|
platforms: d,
|
|
774
774
|
gameList: e,
|
|
@@ -776,12 +776,12 @@ const si = ni(null), sl = () => {
|
|
|
776
776
|
allPlatforms: i
|
|
777
777
|
}), T = Tt(t, n), S = vt(c), E = ht(S), v = lt(c).reduce(
|
|
778
778
|
(L, [I, Q]) => {
|
|
779
|
-
const Te =
|
|
779
|
+
const Te = Ie(nt(Q));
|
|
780
780
|
return L[I] = Te, L;
|
|
781
781
|
},
|
|
782
782
|
{}
|
|
783
|
-
), D =
|
|
784
|
-
const Q =
|
|
783
|
+
), D = Ma(c).reduce((L, I) => {
|
|
784
|
+
const Q = Ma(c[I]);
|
|
785
785
|
return L[I] = Q, L;
|
|
786
786
|
}, {});
|
|
787
787
|
return {
|
|
@@ -793,17 +793,17 @@ const si = ni(null), sl = () => {
|
|
|
793
793
|
},
|
|
794
794
|
type: {
|
|
795
795
|
main: l,
|
|
796
|
-
sub:
|
|
796
|
+
sub: s,
|
|
797
797
|
originMain: m,
|
|
798
798
|
originSub: n
|
|
799
799
|
},
|
|
800
800
|
gameList: {
|
|
801
801
|
all: t,
|
|
802
802
|
new: r,
|
|
803
|
-
top:
|
|
803
|
+
top: u,
|
|
804
804
|
favorite: b,
|
|
805
|
-
highlight:
|
|
806
|
-
exclusiveBrand:
|
|
805
|
+
highlight: g,
|
|
806
|
+
exclusiveBrand: p,
|
|
807
807
|
randomlySelected: f
|
|
808
808
|
},
|
|
809
809
|
categorized: {
|
|
@@ -817,12 +817,12 @@ const si = ni(null), sl = () => {
|
|
|
817
817
|
favorite: b
|
|
818
818
|
}
|
|
819
819
|
};
|
|
820
|
-
},
|
|
820
|
+
}, dl = (e = []) => !ne(e) || O(e) ? [] : Ie(e, (i) => O(i.SubPlatformEnum) ? i : i.SubPlatformEnum.map((m) => ({
|
|
821
821
|
...i,
|
|
822
822
|
...m,
|
|
823
823
|
platform: m.SubPlatformEnum,
|
|
824
824
|
platformEnum: m.SubPlatformEnum
|
|
825
|
-
}))),
|
|
825
|
+
}))), ra = (e) => {
|
|
826
826
|
switch (e) {
|
|
827
827
|
case "tw":
|
|
828
828
|
return "zh_TW";
|
|
@@ -841,46 +841,46 @@ const si = ni(null), sl = () => {
|
|
|
841
841
|
default:
|
|
842
842
|
return e;
|
|
843
843
|
}
|
|
844
|
-
},
|
|
845
|
-
const { client: e } =
|
|
846
|
-
async (
|
|
847
|
-
const { mac_address:
|
|
848
|
-
mac_address:
|
|
849
|
-
app_version:
|
|
850
|
-
anydesk_id:
|
|
844
|
+
}, me = () => {
|
|
845
|
+
const { client: e } = te(), i = V(
|
|
846
|
+
async (o) => {
|
|
847
|
+
const { mac_address: t = "", app_version: d = "", anydesk_id: l = "" } = o, { data: s } = await e.post("/cash-register/login", {
|
|
848
|
+
mac_address: t,
|
|
849
|
+
app_version: d,
|
|
850
|
+
anydesk_id: l
|
|
851
851
|
});
|
|
852
|
-
return
|
|
852
|
+
return s;
|
|
853
853
|
},
|
|
854
854
|
[e]
|
|
855
|
-
), m =
|
|
856
|
-
async (
|
|
857
|
-
const { account:
|
|
855
|
+
), m = V(async () => e.get("/member/getMemberInfo"), [e]), n = V(async () => await e.get("/member/getGameList"), [e]), r = V(async () => await e.get("/member/getNowCurrencyExchange"), [e]), u = V(async () => await e.get("member/getFavoriteGame"), [e]), f = V(
|
|
856
|
+
async (o) => {
|
|
857
|
+
const { account: t, password: d, trans_code: l } = o;
|
|
858
858
|
return await e.post("/login", {
|
|
859
|
-
memId:
|
|
860
|
-
passwd:
|
|
861
|
-
trans_code:
|
|
859
|
+
memId: t,
|
|
860
|
+
passwd: d,
|
|
861
|
+
trans_code: l
|
|
862
862
|
});
|
|
863
863
|
},
|
|
864
864
|
[e]
|
|
865
|
-
), _ =
|
|
866
|
-
async (
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
status: t
|
|
865
|
+
), _ = V(async () => await e.post("/logout"), [e]), p = V(
|
|
866
|
+
async (o) => {
|
|
867
|
+
const { gameUid: t = "", status: d = 0 } = o;
|
|
868
|
+
return await e.put(`/member/toggleFavoriteGame/${t}`, {
|
|
869
|
+
status: d
|
|
871
870
|
});
|
|
872
871
|
},
|
|
873
872
|
[e]
|
|
874
|
-
);
|
|
873
|
+
), g = V(async () => await e.get("/profit/ranking"), [e]);
|
|
875
874
|
return {
|
|
876
875
|
machineLoginApi: i,
|
|
877
876
|
userInfoApi: m,
|
|
878
877
|
userGameListApi: n,
|
|
879
|
-
userFavoriteGameApi:
|
|
878
|
+
userFavoriteGameApi: u,
|
|
880
879
|
userCurrencyExchangeApi: r,
|
|
881
880
|
userLoginApi: f,
|
|
882
881
|
userLogoutApi: _,
|
|
883
|
-
addOrRemoveFavoriteGameApi:
|
|
882
|
+
addOrRemoveFavoriteGameApi: p,
|
|
883
|
+
rankingGameApi: g
|
|
884
884
|
};
|
|
885
885
|
}, St = {
|
|
886
886
|
platform: { all: [], origin: [], originPlatform: [], byGameType: {} },
|
|
@@ -903,26 +903,26 @@ const si = ni(null), sl = () => {
|
|
|
903
903
|
},
|
|
904
904
|
user: { favorite: [] }
|
|
905
905
|
}, Nt = ({ enabled: e = !0 } = {}) => {
|
|
906
|
-
const { getToken: i } =
|
|
906
|
+
const { getToken: i } = te(), { userFavoriteGameApi: m, userGameListApi: n } = me(), { data: r, isLoading: u, error: f, refetch: _ } = ie({
|
|
907
907
|
queryKey: ["gamesInfo"],
|
|
908
908
|
queryFn: async () => {
|
|
909
|
-
let
|
|
909
|
+
let p = {}, g = {};
|
|
910
910
|
try {
|
|
911
|
-
await i?.() && (
|
|
912
|
-
} catch (
|
|
913
|
-
console.warn("Failed to fetch favorite games:",
|
|
911
|
+
await i?.() && (g = await n(), p = await m());
|
|
912
|
+
} catch (o) {
|
|
913
|
+
console.warn("Failed to fetch favorite games:", o);
|
|
914
914
|
}
|
|
915
915
|
return kt({
|
|
916
|
-
allGameList:
|
|
917
|
-
allGamePlatform:
|
|
918
|
-
allGameType:
|
|
919
|
-
allGame_subtype:
|
|
920
|
-
allNewGameList:
|
|
921
|
-
allTopGameList:
|
|
922
|
-
userFavoriteGame:
|
|
923
|
-
randomlySelectedGames:
|
|
924
|
-
exclusiveBrandGames:
|
|
925
|
-
highlightGames:
|
|
916
|
+
allGameList: g.gameTypeGroup || window.gameTypeGroup || {},
|
|
917
|
+
allGamePlatform: g.platforms || window.platforms || [],
|
|
918
|
+
allGameType: g.gameType || window.gameType || [],
|
|
919
|
+
allGame_subtype: g.gameSubType || window.gameSubType || [],
|
|
920
|
+
allNewGameList: g.newGames || window.newGames || [],
|
|
921
|
+
allTopGameList: g.topGames || window.topGames || [],
|
|
922
|
+
userFavoriteGame: p.userFavoriteGame || {},
|
|
923
|
+
randomlySelectedGames: g.randomlySelectedGames || window.randomlySelectedGames || [],
|
|
924
|
+
exclusiveBrandGames: g.exclusiveBrandGames || window.exclusiveBrandGames || [],
|
|
925
|
+
highlightGames: g.highlightGames || window.highlightGames || [],
|
|
926
926
|
originPlatform: window.originPlatform || []
|
|
927
927
|
});
|
|
928
928
|
},
|
|
@@ -936,7 +936,7 @@ const si = ni(null), sl = () => {
|
|
|
936
936
|
});
|
|
937
937
|
return {
|
|
938
938
|
gamesInfo: r || St,
|
|
939
|
-
isLoading:
|
|
939
|
+
isLoading: u,
|
|
940
940
|
error: f,
|
|
941
941
|
refetch: _
|
|
942
942
|
};
|
|
@@ -27476,16 +27476,16 @@ const si = ni(null), sl = () => {
|
|
|
27476
27476
|
m && Dt(!0);
|
|
27477
27477
|
}, [m]);
|
|
27478
27478
|
const n = Nt({ enabled: i });
|
|
27479
|
-
return /* @__PURE__ */ ze.jsx(
|
|
27479
|
+
return /* @__PURE__ */ ze.jsx(ui.Provider, { value: n, children: e });
|
|
27480
27480
|
};
|
|
27481
|
-
function
|
|
27481
|
+
function cl({
|
|
27482
27482
|
children: e,
|
|
27483
27483
|
autoFetchGamesInfo: i = !1,
|
|
27484
27484
|
useMockData: m = !1,
|
|
27485
27485
|
queryClient: n,
|
|
27486
27486
|
...r
|
|
27487
27487
|
}) {
|
|
27488
|
-
const
|
|
27488
|
+
const u = ta(() => gt(r), [r]), f = ta(
|
|
27489
27489
|
() => new at({
|
|
27490
27490
|
defaultOptions: {
|
|
27491
27491
|
queries: {
|
|
@@ -27496,71 +27496,71 @@ function dl({
|
|
|
27496
27496
|
}),
|
|
27497
27497
|
[]
|
|
27498
27498
|
), _ = n || f;
|
|
27499
|
-
return /* @__PURE__ */ ze.jsx(it, { client: _, children: /* @__PURE__ */ ze.jsx(
|
|
27499
|
+
return /* @__PURE__ */ ze.jsx(it, { client: _, children: /* @__PURE__ */ ze.jsx(si.Provider, { value: { client: u, ...r }, children: /* @__PURE__ */ ze.jsx(Et, { autoFetch: i, mockData: m, children: e }) }) });
|
|
27500
27500
|
}
|
|
27501
|
-
const
|
|
27502
|
-
const { userCurrencyExchangeApi: m } =
|
|
27503
|
-
return
|
|
27501
|
+
const _l = ({ otherQueryKey: e = [], options: i = {} } = {}) => {
|
|
27502
|
+
const { userCurrencyExchangeApi: m } = me(), { getToken: n } = te(), { enabled: r, ...u } = i, _ = !!n?.() && (r ? r.every((p) => p) : !0);
|
|
27503
|
+
return oi({
|
|
27504
27504
|
queries: [
|
|
27505
27505
|
{
|
|
27506
27506
|
queryKey: ["userCurrencyExchange", ...e],
|
|
27507
27507
|
queryFn: () => m(),
|
|
27508
27508
|
enabled: _,
|
|
27509
27509
|
// ← 使用合併後的條件
|
|
27510
|
-
...
|
|
27510
|
+
...u
|
|
27511
27511
|
// ← 不包含 enabled
|
|
27512
27512
|
}
|
|
27513
27513
|
]
|
|
27514
27514
|
});
|
|
27515
|
-
},
|
|
27515
|
+
}, fl = ({
|
|
27516
27516
|
refetchInterval: e = 5e4,
|
|
27517
27517
|
trigger: i = [],
|
|
27518
27518
|
enabled: m = !0
|
|
27519
27519
|
} = {}) => {
|
|
27520
|
-
const { getToken: n } =
|
|
27521
|
-
return
|
|
27520
|
+
const { getToken: n } = te(), r = n?.(), { userInfoApi: u } = me();
|
|
27521
|
+
return oi({
|
|
27522
27522
|
queries: [
|
|
27523
27523
|
{
|
|
27524
27524
|
queryKey: ["getMemberInfo", ...i],
|
|
27525
|
-
queryFn: async () => await
|
|
27525
|
+
queryFn: async () => await u(),
|
|
27526
27526
|
refetchInterval: e,
|
|
27527
27527
|
enabled: !!r && m
|
|
27528
27528
|
}
|
|
27529
27529
|
]
|
|
27530
27530
|
});
|
|
27531
|
-
},
|
|
27531
|
+
}, Ul = ({ enabled: e = !0 } = {}) => {
|
|
27532
27532
|
const {
|
|
27533
27533
|
userInfoApi: i,
|
|
27534
27534
|
userFavoriteGameApi: m,
|
|
27535
27535
|
userGameListApi: n,
|
|
27536
27536
|
userCurrencyExchangeApi: r
|
|
27537
|
-
} =
|
|
27537
|
+
} = me(), u = ie({
|
|
27538
27538
|
queryKey: ["getMemInfo"],
|
|
27539
27539
|
queryFn: async () => i(),
|
|
27540
27540
|
enabled: e
|
|
27541
|
-
}), f =
|
|
27541
|
+
}), f = ie({
|
|
27542
27542
|
queryKey: ["getFavoriteGame"],
|
|
27543
27543
|
queryFn: async () => m(),
|
|
27544
|
-
enabled: e &&
|
|
27545
|
-
}), _ =
|
|
27544
|
+
enabled: e && u.isSuccess
|
|
27545
|
+
}), _ = ie({
|
|
27546
27546
|
queryKey: ["getUserGameList"],
|
|
27547
27547
|
queryFn: async () => n(),
|
|
27548
|
-
enabled: e &&
|
|
27549
|
-
}),
|
|
27548
|
+
enabled: e && u.isSuccess && f.isSuccess
|
|
27549
|
+
}), p = ie({
|
|
27550
27550
|
queryKey: ["getUserCurrencyExchange"],
|
|
27551
27551
|
queryFn: async () => r(),
|
|
27552
|
-
enabled: e &&
|
|
27552
|
+
enabled: e && u.isSuccess && f.isSuccess && _.isSuccess
|
|
27553
27553
|
});
|
|
27554
27554
|
return [
|
|
27555
|
-
|
|
27555
|
+
u,
|
|
27556
27556
|
f,
|
|
27557
27557
|
_,
|
|
27558
|
-
|
|
27558
|
+
p
|
|
27559
27559
|
];
|
|
27560
27560
|
};
|
|
27561
|
-
var
|
|
27561
|
+
var Xe = {}, z = {}, $e = {}, wa;
|
|
27562
27562
|
function j() {
|
|
27563
|
-
return
|
|
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
27565
|
var i = 1, m = 1e3 * i;
|
|
27566
27566
|
e.DEFAULT_OPTIONS = {}, e.EMPTY_EVENT_HANDLERS = {}, e.DEFAULT_EVENT_SOURCE_OPTIONS = {
|
|
@@ -27572,8 +27572,8 @@ function j() {
|
|
|
27572
27572
|
interval: 25e3
|
|
27573
27573
|
};
|
|
27574
27574
|
var n;
|
|
27575
|
-
(function(
|
|
27576
|
-
|
|
27575
|
+
(function(u) {
|
|
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
27577
|
})(n || (e.ReadyState = n = {}));
|
|
27578
27578
|
var r = function() {
|
|
27579
27579
|
try {
|
|
@@ -27583,11 +27583,11 @@ function j() {
|
|
|
27583
27583
|
}
|
|
27584
27584
|
};
|
|
27585
27585
|
e.isReactNative = typeof navigator < "u" && navigator.product === "ReactNative", e.isEventSourceSupported = !e.isReactNative && r();
|
|
27586
|
-
})(
|
|
27586
|
+
})($e)), $e;
|
|
27587
27587
|
}
|
|
27588
|
-
var Se = {},
|
|
27589
|
-
function
|
|
27590
|
-
return
|
|
27588
|
+
var Se = {}, ea = {}, Fa;
|
|
27589
|
+
function oa() {
|
|
27590
|
+
return Fa || (Fa = 1, (function(e) {
|
|
27591
27591
|
Object.defineProperty(e, "__esModule", { value: !0 }), e.resetWebSockets = e.sharedWebSockets = void 0, e.sharedWebSockets = {};
|
|
27592
27592
|
var i = function(m) {
|
|
27593
27593
|
if (m && e.sharedWebSockets.hasOwnProperty(m))
|
|
@@ -27597,59 +27597,59 @@ function ra() {
|
|
|
27597
27597
|
e.sharedWebSockets.hasOwnProperty(n) && delete e.sharedWebSockets[n];
|
|
27598
27598
|
};
|
|
27599
27599
|
e.resetWebSockets = i;
|
|
27600
|
-
})(
|
|
27600
|
+
})(ea)), ea;
|
|
27601
27601
|
}
|
|
27602
|
-
var
|
|
27603
|
-
function
|
|
27604
|
-
if (
|
|
27605
|
-
|
|
27602
|
+
var pe = {}, $ = {}, Wa;
|
|
27603
|
+
function sa() {
|
|
27604
|
+
if (Wa) return $;
|
|
27605
|
+
Wa = 1, Object.defineProperty($, "__esModule", { value: !0 }), $.setUpSocketIOPing = $.appendQueryParams = $.parseSocketIOUrl = void 0;
|
|
27606
27606
|
var e = j(), i = function(r) {
|
|
27607
27607
|
if (r) {
|
|
27608
|
-
var
|
|
27609
|
-
return "".concat(
|
|
27608
|
+
var u = /^https|wss/.test(r), f = r.replace(/^(https?|wss?)(:\/\/)?/, ""), _ = f.replace(/\/$/, ""), p = u ? "wss" : "ws";
|
|
27609
|
+
return "".concat(p, "://").concat(_).concat(e.SOCKET_IO_PATH);
|
|
27610
27610
|
} else if (r === "") {
|
|
27611
|
-
var
|
|
27612
|
-
return "".concat(
|
|
27611
|
+
var u = /^https/.test(window.location.protocol), p = u ? "wss" : "ws", g = window.location.port ? ":".concat(window.location.port) : "";
|
|
27612
|
+
return "".concat(p, "://").concat(window.location.hostname).concat(g).concat(e.SOCKET_IO_PATH);
|
|
27613
27613
|
}
|
|
27614
27614
|
return r;
|
|
27615
27615
|
};
|
|
27616
27616
|
$.parseSocketIOUrl = i;
|
|
27617
|
-
var m = function(r,
|
|
27618
|
-
|
|
27619
|
-
var f = /\?([\w]+=[\w]+)/, _ = f.test(r),
|
|
27620
|
-
var t =
|
|
27621
|
-
return
|
|
27617
|
+
var m = function(r, u) {
|
|
27618
|
+
u === void 0 && (u = {});
|
|
27619
|
+
var f = /\?([\w]+=[\w]+)/, _ = f.test(r), p = "".concat(Object.entries(u).reduce(function(g, o) {
|
|
27620
|
+
var t = o[0], d = o[1];
|
|
27621
|
+
return g + "".concat(t, "=").concat(d, "&");
|
|
27622
27622
|
}, "").slice(0, -1));
|
|
27623
|
-
return "".concat(r).concat(_ ? "&" : "?").concat(
|
|
27623
|
+
return "".concat(r).concat(_ ? "&" : "?").concat(p);
|
|
27624
27624
|
};
|
|
27625
27625
|
$.appendQueryParams = m;
|
|
27626
|
-
var n = function(r,
|
|
27627
|
-
|
|
27626
|
+
var n = function(r, u) {
|
|
27627
|
+
u === void 0 && (u = e.SOCKET_IO_PING_INTERVAL);
|
|
27628
27628
|
var f = function() {
|
|
27629
27629
|
return r(e.SOCKET_IO_PING_CODE);
|
|
27630
27630
|
};
|
|
27631
|
-
return window.setInterval(f,
|
|
27631
|
+
return window.setInterval(f, u);
|
|
27632
27632
|
};
|
|
27633
27633
|
return $.setUpSocketIOPing = n, $;
|
|
27634
27634
|
}
|
|
27635
|
-
var We = {},
|
|
27635
|
+
var We = {}, Ja;
|
|
27636
27636
|
function _i() {
|
|
27637
|
-
if (
|
|
27638
|
-
|
|
27637
|
+
if (Ja) return We;
|
|
27638
|
+
Ja = 1, Object.defineProperty(We, "__esModule", { value: !0 }), We.heartbeat = m;
|
|
27639
27639
|
var e = j();
|
|
27640
27640
|
function i(n) {
|
|
27641
|
-
return Array.isArray(n) ? n.reduce(function(r,
|
|
27642
|
-
return r.current >
|
|
27641
|
+
return Array.isArray(n) ? n.reduce(function(r, u) {
|
|
27642
|
+
return r.current > u.current ? r : u;
|
|
27643
27643
|
}).current : n.current;
|
|
27644
27644
|
}
|
|
27645
|
-
function m(n, r,
|
|
27646
|
-
var f =
|
|
27645
|
+
function m(n, r, u) {
|
|
27646
|
+
var f = u || {}, _ = f.interval, p = _ === void 0 ? e.DEFAULT_HEARTBEAT.interval : _, g = f.timeout, o = 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), s = Date.now(), y = setInterval(function() {
|
|
27647
27647
|
var b = Date.now(), c = i(r);
|
|
27648
|
-
if (c +
|
|
27649
|
-
console.warn("Heartbeat timed out, closing connection, last message received ".concat(b - c, "ms ago, last ping sent ").concat(b -
|
|
27650
|
-
else if (c +
|
|
27648
|
+
if (c + o <= b)
|
|
27649
|
+
console.warn("Heartbeat timed out, closing connection, last message received ".concat(b - c, "ms ago, last ping sent ").concat(b - s, "ms ago")), n.close();
|
|
27650
|
+
else if (c + p <= b && s + p <= b)
|
|
27651
27651
|
try {
|
|
27652
|
-
typeof d == "function" ? n.send(d()) : n.send(d),
|
|
27652
|
+
typeof d == "function" ? n.send(d()) : n.send(d), s = b;
|
|
27653
27653
|
} catch (T) {
|
|
27654
27654
|
console.error("Heartbeat failed, closing connection", T instanceof Error ? T.message : T), n.close();
|
|
27655
27655
|
}
|
|
@@ -27661,44 +27661,44 @@ function _i() {
|
|
|
27661
27661
|
}
|
|
27662
27662
|
return We;
|
|
27663
27663
|
}
|
|
27664
|
-
var Ne = {},
|
|
27665
|
-
function
|
|
27666
|
-
return
|
|
27664
|
+
var Ne = {}, aa = {}, za;
|
|
27665
|
+
function ua() {
|
|
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 = {}, m = [], n = function(
|
|
27669
|
-
return (0, e.hasSubscribers)(
|
|
27668
|
+
var i = {}, m = [], n = function(p) {
|
|
27669
|
+
return (0, e.hasSubscribers)(p) ? Array.from(i[p]) : m;
|
|
27670
27670
|
};
|
|
27671
27671
|
e.getSubscribers = n;
|
|
27672
|
-
var r = function(
|
|
27673
|
-
var
|
|
27674
|
-
return ((
|
|
27672
|
+
var r = function(p) {
|
|
27673
|
+
var g;
|
|
27674
|
+
return ((g = i[p]) === null || g === void 0 ? void 0 : g.size) > 0;
|
|
27675
27675
|
};
|
|
27676
27676
|
e.hasSubscribers = r;
|
|
27677
|
-
var
|
|
27678
|
-
i[
|
|
27677
|
+
var u = function(p, g) {
|
|
27678
|
+
i[p] = i[p] || /* @__PURE__ */ new Set(), i[p].add(g);
|
|
27679
27679
|
};
|
|
27680
|
-
e.addSubscriber =
|
|
27681
|
-
var f = function(
|
|
27682
|
-
i[
|
|
27680
|
+
e.addSubscriber = u;
|
|
27681
|
+
var f = function(p, g) {
|
|
27682
|
+
i[p].delete(g);
|
|
27683
27683
|
};
|
|
27684
27684
|
e.removeSubscriber = f;
|
|
27685
|
-
var _ = function(
|
|
27686
|
-
if (
|
|
27687
|
-
delete i[
|
|
27685
|
+
var _ = function(p) {
|
|
27686
|
+
if (p && i.hasOwnProperty(p))
|
|
27687
|
+
delete i[p];
|
|
27688
27688
|
else
|
|
27689
|
-
for (var
|
|
27690
|
-
i.hasOwnProperty(
|
|
27689
|
+
for (var g in i)
|
|
27690
|
+
i.hasOwnProperty(g) && delete i[g];
|
|
27691
27691
|
};
|
|
27692
27692
|
e.resetSubscribers = _;
|
|
27693
|
-
})(
|
|
27693
|
+
})(aa)), aa;
|
|
27694
27694
|
}
|
|
27695
|
-
var
|
|
27696
|
-
function
|
|
27697
|
-
if (
|
|
27698
|
-
|
|
27699
|
-
var e =
|
|
27700
|
-
function m(r,
|
|
27701
|
-
if (!
|
|
27695
|
+
var Za;
|
|
27696
|
+
function pa() {
|
|
27697
|
+
if (Za) return Ne;
|
|
27698
|
+
Za = 1, Object.defineProperty(Ne, "__esModule", { value: !0 }), Ne.assertIsWebSocket = m, Ne.resetGlobalState = n;
|
|
27699
|
+
var e = oa(), i = ua();
|
|
27700
|
+
function m(r, u) {
|
|
27701
|
+
if (!u && !(r instanceof WebSocket))
|
|
27702
27702
|
throw new Error("");
|
|
27703
27703
|
}
|
|
27704
27704
|
function n(r) {
|
|
@@ -27706,46 +27706,46 @@ function ua() {
|
|
|
27706
27706
|
}
|
|
27707
27707
|
return Ne;
|
|
27708
27708
|
}
|
|
27709
|
-
var
|
|
27709
|
+
var Va;
|
|
27710
27710
|
function Lt() {
|
|
27711
|
-
if (
|
|
27712
|
-
|
|
27713
|
-
var e =
|
|
27714
|
-
return e = Object.assign || function(
|
|
27711
|
+
if (Va) return pe;
|
|
27712
|
+
Va = 1;
|
|
27713
|
+
var e = pe && pe.__assign || function() {
|
|
27714
|
+
return e = Object.assign || function(o) {
|
|
27715
27715
|
for (var t, d = 1, l = arguments.length; d < l; d++) {
|
|
27716
27716
|
t = arguments[d];
|
|
27717
|
-
for (var
|
|
27717
|
+
for (var s in t) Object.prototype.hasOwnProperty.call(t, s) && (o[s] = t[s]);
|
|
27718
27718
|
}
|
|
27719
|
-
return
|
|
27719
|
+
return o;
|
|
27720
27720
|
}, e.apply(this, arguments);
|
|
27721
27721
|
};
|
|
27722
|
-
Object.defineProperty(
|
|
27723
|
-
var i =
|
|
27724
|
-
|
|
27722
|
+
Object.defineProperty(pe, "__esModule", { value: !0 }), pe.attachListeners = void 0;
|
|
27723
|
+
var i = sa(), m = _i(), n = j(), r = pa(), u = function(o, t, d, l) {
|
|
27724
|
+
o.onmessage = function(s) {
|
|
27725
27725
|
var y;
|
|
27726
|
-
t.current.onMessage && t.current.onMessage(
|
|
27726
|
+
t.current.onMessage && t.current.onMessage(s), typeof l?.current == "number" && (l.current = Date.now()), !(typeof t.current.filter == "function" && t.current.filter(s) !== !0) && (t.current.heartbeat && typeof t.current.heartbeat != "boolean" && ((y = t.current.heartbeat) === null || y === void 0 ? void 0 : y.returnMessage) === s.data || d(s));
|
|
27727
27727
|
};
|
|
27728
|
-
}, f = function(
|
|
27729
|
-
|
|
27730
|
-
if (t.current.onOpen && t.current.onOpen(y), l.current = 0, d(n.ReadyState.OPEN), t.current.heartbeat &&
|
|
27728
|
+
}, f = function(o, t, d, l, s) {
|
|
27729
|
+
o.onopen = function(y) {
|
|
27730
|
+
if (t.current.onOpen && t.current.onOpen(y), l.current = 0, d(n.ReadyState.OPEN), t.current.heartbeat && o instanceof WebSocket) {
|
|
27731
27731
|
var b = typeof t.current.heartbeat == "boolean" ? void 0 : t.current.heartbeat;
|
|
27732
|
-
|
|
27732
|
+
s.current = Date.now(), (0, m.heartbeat)(o, s, b);
|
|
27733
27733
|
}
|
|
27734
27734
|
};
|
|
27735
|
-
}, _ = function(
|
|
27736
|
-
if (n.isEventSourceSupported &&
|
|
27735
|
+
}, _ = function(o, t, d, l, s) {
|
|
27736
|
+
if (n.isEventSourceSupported && o instanceof EventSource)
|
|
27737
27737
|
return function() {
|
|
27738
27738
|
};
|
|
27739
|
-
(0, r.assertIsWebSocket)(
|
|
27739
|
+
(0, r.assertIsWebSocket)(o, t.current.skipAssert);
|
|
27740
27740
|
var y;
|
|
27741
|
-
return
|
|
27741
|
+
return o.onclose = function(b) {
|
|
27742
27742
|
var c;
|
|
27743
27743
|
if (t.current.onClose && t.current.onClose(b), d(n.ReadyState.CLOSED), t.current.shouldReconnect && t.current.shouldReconnect(b)) {
|
|
27744
27744
|
var T = (c = t.current.reconnectAttempts) !== null && c !== void 0 ? c : n.DEFAULT_RECONNECT_LIMIT;
|
|
27745
|
-
if (
|
|
27746
|
-
var S = typeof t.current.reconnectInterval == "function" ? t.current.reconnectInterval(
|
|
27745
|
+
if (s.current < T) {
|
|
27746
|
+
var S = typeof t.current.reconnectInterval == "function" ? t.current.reconnectInterval(s.current) : t.current.reconnectInterval;
|
|
27747
27747
|
y = window.setTimeout(function() {
|
|
27748
|
-
|
|
27748
|
+
s.current++, l();
|
|
27749
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"));
|
|
@@ -27753,171 +27753,171 @@ function Lt() {
|
|
|
27753
27753
|
}, function() {
|
|
27754
27754
|
return y && window.clearTimeout(y);
|
|
27755
27755
|
};
|
|
27756
|
-
},
|
|
27756
|
+
}, p = function(o, t, d, l, s) {
|
|
27757
27757
|
var y;
|
|
27758
|
-
return
|
|
27758
|
+
return o.onerror = function(b) {
|
|
27759
27759
|
var c;
|
|
27760
|
-
if (t.current.onError && t.current.onError(b), n.isEventSourceSupported &&
|
|
27761
|
-
if (
|
|
27762
|
-
var T = typeof t.current.reconnectInterval == "function" ? t.current.reconnectInterval(
|
|
27760
|
+
if (t.current.onError && t.current.onError(b), n.isEventSourceSupported && o 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), o.close()), t.current.retryOnError)
|
|
27761
|
+
if (s.current < ((c = t.current.reconnectAttempts) !== null && c !== void 0 ? c : n.DEFAULT_RECONNECT_LIMIT)) {
|
|
27762
|
+
var T = typeof t.current.reconnectInterval == "function" ? t.current.reconnectInterval(s.current) : t.current.reconnectInterval;
|
|
27763
27763
|
y = window.setTimeout(function() {
|
|
27764
|
-
|
|
27764
|
+
s.current++, l();
|
|
27765
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
|
-
},
|
|
27771
|
+
}, g = function(o, t, d, l, s, y, b) {
|
|
27772
27772
|
var c = t.setLastMessage, T = t.setReadyState, S, E, v;
|
|
27773
|
-
return d.current.fromSocketIO && (S = (0, i.setUpSocketIOPing)(b)),
|
|
27774
|
-
T(n.ReadyState.CLOSING), E(), v(),
|
|
27773
|
+
return d.current.fromSocketIO && (S = (0, i.setUpSocketIOPing)(b)), u(o, d, c, y), f(o, d, T, s, y), E = _(o, d, T, l, s), v = p(o, d, T, l, s), function() {
|
|
27774
|
+
T(n.ReadyState.CLOSING), E(), v(), o.close(), S && clearInterval(S);
|
|
27775
27775
|
};
|
|
27776
27776
|
};
|
|
27777
|
-
return
|
|
27777
|
+
return pe.attachListeners = g, pe;
|
|
27778
27778
|
}
|
|
27779
|
-
var
|
|
27779
|
+
var ge = {}, Aa;
|
|
27780
27780
|
function Gt() {
|
|
27781
|
-
if (
|
|
27782
|
-
|
|
27783
|
-
var e =
|
|
27781
|
+
if (Aa) return ge;
|
|
27782
|
+
Aa = 1;
|
|
27783
|
+
var e = ge && ge.__assign || function() {
|
|
27784
27784
|
return e = Object.assign || function(t) {
|
|
27785
|
-
for (var d, l = 1,
|
|
27785
|
+
for (var d, l = 1, s = arguments.length; l < s; l++) {
|
|
27786
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
|
-
Object.defineProperty(
|
|
27793
|
-
var i =
|
|
27794
|
-
t.onmessage = function(
|
|
27792
|
+
Object.defineProperty(ge, "__esModule", { value: !0 }), ge.attachSharedListeners = void 0;
|
|
27793
|
+
var i = oa(), m = j(), n = ua(), r = sa(), u = _i(), f = function(t, d, l) {
|
|
27794
|
+
t.onmessage = function(s) {
|
|
27795
27795
|
(0, n.getSubscribers)(d).forEach(function(y) {
|
|
27796
27796
|
var b;
|
|
27797
|
-
y.optionsRef.current.onMessage && y.optionsRef.current.onMessage(
|
|
27797
|
+
y.optionsRef.current.onMessage && y.optionsRef.current.onMessage(s), 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(s) !== !0) && (l && typeof l != "boolean" && l?.returnMessage === s.data || y.setLastMessage(s));
|
|
27798
27798
|
});
|
|
27799
27799
|
};
|
|
27800
27800
|
}, _ = function(t, d, l) {
|
|
27801
|
-
t.onopen = function(
|
|
27801
|
+
t.onopen = function(s) {
|
|
27802
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(
|
|
27805
|
-
}), l && t instanceof WebSocket && (0,
|
|
27804
|
+
b.reconnectCount.current = 0, b.optionsRef.current.onOpen && b.optionsRef.current.onOpen(s), 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
27807
|
}), typeof l == "boolean" ? void 0 : l);
|
|
27808
27808
|
};
|
|
27809
|
-
},
|
|
27809
|
+
}, p = function(t, d) {
|
|
27810
27810
|
t instanceof WebSocket && (t.onclose = function(l) {
|
|
27811
|
-
(0, n.getSubscribers)(d).forEach(function(
|
|
27812
|
-
|
|
27813
|
-
}), delete i.sharedWebSockets[d], (0, n.getSubscribers)(d).forEach(function(
|
|
27811
|
+
(0, n.getSubscribers)(d).forEach(function(s) {
|
|
27812
|
+
s.optionsRef.current.onClose && s.optionsRef.current.onClose(l), s.setReadyState(m.ReadyState.CLOSED);
|
|
27813
|
+
}), delete i.sharedWebSockets[d], (0, n.getSubscribers)(d).forEach(function(s) {
|
|
27814
27814
|
var y;
|
|
27815
|
-
if (
|
|
27816
|
-
var b = (y =
|
|
27817
|
-
if (
|
|
27818
|
-
var c = typeof
|
|
27815
|
+
if (s.optionsRef.current.shouldReconnect && s.optionsRef.current.shouldReconnect(l)) {
|
|
27816
|
+
var b = (y = s.optionsRef.current.reconnectAttempts) !== null && y !== void 0 ? y : m.DEFAULT_RECONNECT_LIMIT;
|
|
27817
|
+
if (s.reconnectCount.current < b) {
|
|
27818
|
+
var c = typeof s.optionsRef.current.reconnectInterval == "function" ? s.optionsRef.current.reconnectInterval(s.reconnectCount.current) : s.optionsRef.current.reconnectInterval;
|
|
27819
27819
|
setTimeout(function() {
|
|
27820
|
-
|
|
27820
|
+
s.reconnectCount.current++, s.reconnect.current();
|
|
27821
27821
|
}, c ?? m.DEFAULT_RECONNECT_INTERVAL_MS);
|
|
27822
27822
|
} else
|
|
27823
|
-
|
|
27823
|
+
s.optionsRef.current.onReconnectStop && s.optionsRef.current.onReconnectStop(s.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
27828
|
t.onerror = function(l) {
|
|
27829
|
-
(0, n.getSubscribers)(d).forEach(function(
|
|
27830
|
-
|
|
27829
|
+
(0, n.getSubscribers)(d).forEach(function(s) {
|
|
27830
|
+
s.optionsRef.current.onError && s.optionsRef.current.onError(l), m.isEventSourceSupported && t instanceof EventSource && (s.optionsRef.current.onClose && s.optionsRef.current.onClose(e(e({}, l), { code: 1006, reason: "An error occurred with the EventSource: ".concat(l), wasClean: !1 })), s.setReadyState(m.ReadyState.CLOSED));
|
|
27831
27831
|
}), m.isEventSourceSupported && t instanceof EventSource && t.close();
|
|
27832
27832
|
};
|
|
27833
|
-
},
|
|
27833
|
+
}, o = function(t, d, l, s) {
|
|
27834
27834
|
var y;
|
|
27835
|
-
return l.current.fromSocketIO && (y = (0, r.setUpSocketIOPing)(
|
|
27835
|
+
return l.current.fromSocketIO && (y = (0, r.setUpSocketIOPing)(s)), 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
|
};
|
|
27839
|
-
return
|
|
27839
|
+
return ge.attachSharedListeners = o, ge;
|
|
27840
27840
|
}
|
|
27841
|
-
var
|
|
27841
|
+
var Ia;
|
|
27842
27842
|
function Mt() {
|
|
27843
|
-
if (
|
|
27844
|
-
|
|
27845
|
-
var e =
|
|
27843
|
+
if (Ia) return Se;
|
|
27844
|
+
Ia = 1, Object.defineProperty(Se, "__esModule", { value: !0 }), Se.createOrJoinSocket = void 0;
|
|
27845
|
+
var e = oa(), i = j(), m = Lt(), n = Gt(), r = ua(), u = function(_, p, g, o, t) {
|
|
27846
27846
|
return function() {
|
|
27847
|
-
if ((0, r.removeSubscriber)(_,
|
|
27847
|
+
if ((0, r.removeSubscriber)(_, p), !(0, r.hasSubscribers)(_)) {
|
|
27848
27848
|
try {
|
|
27849
27849
|
var d = e.sharedWebSockets[_];
|
|
27850
27850
|
d instanceof WebSocket && (d.onclose = function(l) {
|
|
27851
|
-
|
|
27851
|
+
g.current.onClose && g.current.onClose(l), o(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(_,
|
|
27859
|
-
if (!i.isEventSourceSupported &&
|
|
27858
|
+
}, f = function(_, p, g, o, t, d, l, s, y) {
|
|
27859
|
+
if (!i.isEventSourceSupported && o.current.eventSourceOptions)
|
|
27860
27860
|
throw i.isReactNative ? new Error("EventSource is not supported in ReactNative") : new Error("EventSource is not supported");
|
|
27861
|
-
if (
|
|
27861
|
+
if (o.current.share) {
|
|
27862
27862
|
var b = null;
|
|
27863
|
-
e.sharedWebSockets[
|
|
27863
|
+
e.sharedWebSockets[p] === void 0 ? (e.sharedWebSockets[p] = o.current.eventSourceOptions ? new EventSource(p, o.current.eventSourceOptions) : new WebSocket(p, o.current.protocols), _.current = e.sharedWebSockets[p], g(i.ReadyState.CONNECTING), b = (0, n.attachSharedListeners)(e.sharedWebSockets[p], p, o, y)) : (_.current = e.sharedWebSockets[p], g(e.sharedWebSockets[p].readyState));
|
|
27864
27864
|
var c = {
|
|
27865
27865
|
setLastMessage: t,
|
|
27866
|
-
setReadyState:
|
|
27867
|
-
optionsRef:
|
|
27866
|
+
setReadyState: g,
|
|
27867
|
+
optionsRef: o,
|
|
27868
27868
|
reconnectCount: l,
|
|
27869
|
-
lastMessageTime:
|
|
27869
|
+
lastMessageTime: s,
|
|
27870
27870
|
reconnect: d
|
|
27871
27871
|
};
|
|
27872
|
-
return (0, r.addSubscriber)(
|
|
27872
|
+
return (0, r.addSubscriber)(p, c), u(p, c, o, g, b);
|
|
27873
27873
|
} else {
|
|
27874
|
-
if (_.current =
|
|
27874
|
+
if (_.current = o.current.eventSourceOptions ? new EventSource(p, o.current.eventSourceOptions) : new WebSocket(p, o.current.protocols), g(i.ReadyState.CONNECTING), !_.current)
|
|
27875
27875
|
throw new Error("WebSocket failed to be created");
|
|
27876
27876
|
return (0, m.attachListeners)(_.current, {
|
|
27877
27877
|
setLastMessage: t,
|
|
27878
|
-
setReadyState:
|
|
27879
|
-
},
|
|
27878
|
+
setReadyState: g
|
|
27879
|
+
}, o, d.current, l, s, y);
|
|
27880
27880
|
}
|
|
27881
27881
|
};
|
|
27882
27882
|
return Se.createOrJoinSocket = f, Se;
|
|
27883
27883
|
}
|
|
27884
|
-
var ee = {},
|
|
27884
|
+
var ee = {}, Ba;
|
|
27885
27885
|
function Rt() {
|
|
27886
|
-
return
|
|
27887
|
-
var i = ee && ee.__awaiter || function(
|
|
27886
|
+
return Ba || (Ba = 1, (function(e) {
|
|
27887
|
+
var i = ee && ee.__awaiter || function(p, g, o, t) {
|
|
27888
27888
|
function d(l) {
|
|
27889
|
-
return l instanceof
|
|
27890
|
-
|
|
27889
|
+
return l instanceof o ? l : new o(function(s) {
|
|
27890
|
+
s(l);
|
|
27891
27891
|
});
|
|
27892
27892
|
}
|
|
27893
|
-
return new (
|
|
27893
|
+
return new (o || (o = Promise))(function(l, s) {
|
|
27894
27894
|
function y(T) {
|
|
27895
27895
|
try {
|
|
27896
27896
|
c(t.next(T));
|
|
27897
27897
|
} catch (S) {
|
|
27898
|
-
|
|
27898
|
+
s(S);
|
|
27899
27899
|
}
|
|
27900
27900
|
}
|
|
27901
27901
|
function b(T) {
|
|
27902
27902
|
try {
|
|
27903
27903
|
c(t.throw(T));
|
|
27904
27904
|
} catch (S) {
|
|
27905
|
-
|
|
27905
|
+
s(S);
|
|
27906
27906
|
}
|
|
27907
27907
|
}
|
|
27908
27908
|
function c(T) {
|
|
27909
27909
|
T.done ? l(T.value) : d(T.value).then(y, b);
|
|
27910
27910
|
}
|
|
27911
|
-
c((t = t.apply(
|
|
27911
|
+
c((t = t.apply(p, g || [])).next());
|
|
27912
27912
|
});
|
|
27913
|
-
}, m = ee && ee.__generator || function(
|
|
27914
|
-
var
|
|
27913
|
+
}, m = ee && ee.__generator || function(p, g) {
|
|
27914
|
+
var o = { label: 0, sent: function() {
|
|
27915
27915
|
if (l[0] & 1) throw l[1];
|
|
27916
27916
|
return l[1];
|
|
27917
|
-
}, trys: [], ops: [] }, t, d, l,
|
|
27918
|
-
return
|
|
27917
|
+
}, trys: [], ops: [] }, t, d, l, s = Object.create((typeof Iterator == "function" ? Iterator : Object).prototype);
|
|
27918
|
+
return s.next = y(0), s.throw = y(1), s.return = y(2), typeof Symbol == "function" && (s[Symbol.iterator] = function() {
|
|
27919
27919
|
return this;
|
|
27920
|
-
}),
|
|
27920
|
+
}), s;
|
|
27921
27921
|
function y(c) {
|
|
27922
27922
|
return function(T) {
|
|
27923
27923
|
return b([c, T]);
|
|
@@ -27925,7 +27925,7 @@ function Rt() {
|
|
|
27925
27925
|
}
|
|
27926
27926
|
function b(c) {
|
|
27927
27927
|
if (t) throw new TypeError("Generator is already executing.");
|
|
27928
|
-
for (;
|
|
27928
|
+
for (; s && (s = 0, c[0] && (o = 0)), o; ) try {
|
|
27929
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
27930
|
switch (d = 0, l && (c = [c[0] & 2, l.value]), c[0]) {
|
|
27931
27931
|
case 0:
|
|
@@ -27933,34 +27933,34 @@ function Rt() {
|
|
|
27933
27933
|
l = c;
|
|
27934
27934
|
break;
|
|
27935
27935
|
case 4:
|
|
27936
|
-
return
|
|
27936
|
+
return o.label++, { value: c[1], done: !1 };
|
|
27937
27937
|
case 5:
|
|
27938
|
-
|
|
27938
|
+
o.label++, d = c[1], c = [0];
|
|
27939
27939
|
continue;
|
|
27940
27940
|
case 7:
|
|
27941
|
-
c =
|
|
27941
|
+
c = o.ops.pop(), o.trys.pop();
|
|
27942
27942
|
continue;
|
|
27943
27943
|
default:
|
|
27944
|
-
if (l =
|
|
27945
|
-
|
|
27944
|
+
if (l = o.trys, !(l = l.length > 0 && l[l.length - 1]) && (c[0] === 6 || c[0] === 2)) {
|
|
27945
|
+
o = 0;
|
|
27946
27946
|
continue;
|
|
27947
27947
|
}
|
|
27948
27948
|
if (c[0] === 3 && (!l || c[1] > l[0] && c[1] < l[3])) {
|
|
27949
|
-
|
|
27949
|
+
o.label = c[1];
|
|
27950
27950
|
break;
|
|
27951
27951
|
}
|
|
27952
|
-
if (c[0] === 6 &&
|
|
27953
|
-
|
|
27952
|
+
if (c[0] === 6 && o.label < l[1]) {
|
|
27953
|
+
o.label = l[1], l = c;
|
|
27954
27954
|
break;
|
|
27955
27955
|
}
|
|
27956
|
-
if (l &&
|
|
27957
|
-
|
|
27956
|
+
if (l && o.label < l[2]) {
|
|
27957
|
+
o.label = l[2], o.ops.push(c);
|
|
27958
27958
|
break;
|
|
27959
27959
|
}
|
|
27960
|
-
l[2] &&
|
|
27960
|
+
l[2] && o.ops.pop(), o.trys.pop();
|
|
27961
27961
|
continue;
|
|
27962
27962
|
}
|
|
27963
|
-
c =
|
|
27963
|
+
c = g.call(p, o);
|
|
27964
27964
|
} catch (T) {
|
|
27965
27965
|
c = [6, T], d = 0;
|
|
27966
27966
|
} finally {
|
|
@@ -27969,22 +27969,22 @@ function Rt() {
|
|
|
27969
27969
|
if (c[0] & 5) throw c[1];
|
|
27970
27970
|
return { value: c[0] ? c[1] : void 0, done: !0 };
|
|
27971
27971
|
}
|
|
27972
|
-
}, n = ee && ee.__spreadArray || function(
|
|
27973
|
-
if (
|
|
27974
|
-
(l || !(t in
|
|
27975
|
-
return
|
|
27972
|
+
}, n = ee && ee.__spreadArray || function(p, g, o) {
|
|
27973
|
+
if (o || 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
|
-
var r =
|
|
27979
|
-
return new Promise(function(
|
|
27980
|
-
return window.setTimeout(
|
|
27978
|
+
var r = sa(), u = j(), f = function(p) {
|
|
27979
|
+
return new Promise(function(g) {
|
|
27980
|
+
return window.setTimeout(g, p);
|
|
27981
27981
|
});
|
|
27982
|
-
}, _ = function(
|
|
27983
|
-
for (var
|
|
27984
|
-
|
|
27985
|
-
return i(void 0, n([
|
|
27982
|
+
}, _ = function(p, g) {
|
|
27983
|
+
for (var o = [], t = 2; t < arguments.length; t++)
|
|
27984
|
+
o[t - 2] = arguments[t];
|
|
27985
|
+
return i(void 0, n([p, g], o, !0), void 0, function(d, l, s) {
|
|
27986
27986
|
var y, b, c, T, S, E, v, D;
|
|
27987
|
-
return
|
|
27987
|
+
return s === void 0 && (s = 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(), l.current.retryOnError ? (b = (E = l.current.reconnectAttempts) !== null && E !== void 0 ? E :
|
|
27997
|
+
return L.sent(), l.current.retryOnError ? (b = (E = l.current.reconnectAttempts) !== null && E !== void 0 ? E : u.DEFAULT_RECONNECT_LIMIT, s < b ? (c = typeof l.current.reconnectInterval == "function" ? l.current.reconnectInterval(s) : 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, l,
|
|
27999
|
+
return L.sent(), [2, (0, e.getUrl)(d, l, s + 1)];
|
|
28000
28000
|
case 5:
|
|
28001
|
-
return (D = (v = l.current).onReconnectStop) === null || D === void 0 || D.call(v,
|
|
28001
|
+
return (D = (v = l.current).onReconnectStop) === null || D === void 0 || D.call(v, s), [2, null];
|
|
28002
28002
|
case 6:
|
|
28003
28003
|
return [3, 8];
|
|
28004
28004
|
case 7:
|
|
@@ -28018,44 +28018,44 @@ function Rt() {
|
|
|
28018
28018
|
e.getUrl = _;
|
|
28019
28019
|
})(ee)), ee;
|
|
28020
28020
|
}
|
|
28021
|
-
var
|
|
28021
|
+
var ia = {}, Ka;
|
|
28022
28022
|
function Pt() {
|
|
28023
|
-
return
|
|
28023
|
+
return Ka || (Ka = 1, (function(e) {
|
|
28024
28024
|
Object.defineProperty(e, "__esModule", { value: !0 }), e.websocketWrapper = void 0;
|
|
28025
28025
|
var i = function(m, n) {
|
|
28026
28026
|
return new Proxy(m, {
|
|
28027
|
-
get: function(r,
|
|
28028
|
-
var f = r[
|
|
28029
|
-
return
|
|
28027
|
+
get: function(r, u) {
|
|
28028
|
+
var f = r[u];
|
|
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
|
-
set: function(r,
|
|
28033
|
-
return /^on/.test(
|
|
28032
|
+
set: function(r, u, f) {
|
|
28033
|
+
return /^on/.test(u) ? (console.warn("The websocket's event handlers should be defined through the options object passed into useWebSocket."), !1) : (r[u] = f, !0);
|
|
28034
28034
|
}
|
|
28035
28035
|
});
|
|
28036
28036
|
};
|
|
28037
28037
|
e.websocketWrapper = i, e.default = e.websocketWrapper;
|
|
28038
|
-
})(
|
|
28038
|
+
})(ia)), ia;
|
|
28039
28039
|
}
|
|
28040
|
-
var
|
|
28041
|
-
function
|
|
28042
|
-
if (
|
|
28043
|
-
|
|
28040
|
+
var ja;
|
|
28041
|
+
function ga() {
|
|
28042
|
+
if (ja) return z;
|
|
28043
|
+
ja = 1;
|
|
28044
28044
|
var e = z && z.__assign || function() {
|
|
28045
28045
|
return e = Object.assign || function(d) {
|
|
28046
|
-
for (var l,
|
|
28047
|
-
l = arguments[
|
|
28046
|
+
for (var l, s = 1, y = arguments.length; s < y; s++) {
|
|
28047
|
+
l = arguments[s];
|
|
28048
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, l,
|
|
28052
|
+
}, i = z && z.__awaiter || function(d, l, s, y) {
|
|
28053
28053
|
function b(c) {
|
|
28054
|
-
return c instanceof
|
|
28054
|
+
return c instanceof s ? c : new s(function(T) {
|
|
28055
28055
|
T(c);
|
|
28056
28056
|
});
|
|
28057
28057
|
}
|
|
28058
|
-
return new (
|
|
28058
|
+
return new (s || (s = Promise))(function(c, T) {
|
|
28059
28059
|
function S(D) {
|
|
28060
28060
|
try {
|
|
28061
28061
|
v(y.next(D));
|
|
@@ -28076,7 +28076,7 @@ function pa() {
|
|
|
28076
28076
|
v((y = y.apply(d, l || [])).next());
|
|
28077
28077
|
});
|
|
28078
28078
|
}, m = z && z.__generator || function(d, l) {
|
|
28079
|
-
var
|
|
28079
|
+
var s = { label: 0, sent: function() {
|
|
28080
28080
|
if (c[0] & 1) throw c[1];
|
|
28081
28081
|
return c[1];
|
|
28082
28082
|
}, trys: [], ops: [] }, y, b, c, T = Object.create((typeof Iterator == "function" ? Iterator : Object).prototype);
|
|
@@ -28090,7 +28090,7 @@ function pa() {
|
|
|
28090
28090
|
}
|
|
28091
28091
|
function E(v) {
|
|
28092
28092
|
if (y) throw new TypeError("Generator is already executing.");
|
|
28093
|
-
for (; T && (T = 0, v[0] && (
|
|
28093
|
+
for (; T && (T = 0, v[0] && (s = 0)), s; ) try {
|
|
28094
28094
|
if (y = 1, b && (c = v[0] & 2 ? b.return : v[0] ? b.throw || ((c = b.return) && c.call(b), 0) : b.next) && !(c = c.call(b, v[1])).done) return c;
|
|
28095
28095
|
switch (b = 0, c && (v = [v[0] & 2, c.value]), v[0]) {
|
|
28096
28096
|
case 0:
|
|
@@ -28098,34 +28098,34 @@ function pa() {
|
|
|
28098
28098
|
c = v;
|
|
28099
28099
|
break;
|
|
28100
28100
|
case 4:
|
|
28101
|
-
return
|
|
28101
|
+
return s.label++, { value: v[1], done: !1 };
|
|
28102
28102
|
case 5:
|
|
28103
|
-
|
|
28103
|
+
s.label++, b = v[1], v = [0];
|
|
28104
28104
|
continue;
|
|
28105
28105
|
case 7:
|
|
28106
|
-
v =
|
|
28106
|
+
v = s.ops.pop(), s.trys.pop();
|
|
28107
28107
|
continue;
|
|
28108
28108
|
default:
|
|
28109
|
-
if (c =
|
|
28110
|
-
|
|
28109
|
+
if (c = s.trys, !(c = c.length > 0 && c[c.length - 1]) && (v[0] === 6 || v[0] === 2)) {
|
|
28110
|
+
s = 0;
|
|
28111
28111
|
continue;
|
|
28112
28112
|
}
|
|
28113
28113
|
if (v[0] === 3 && (!c || v[1] > c[0] && v[1] < c[3])) {
|
|
28114
|
-
|
|
28114
|
+
s.label = v[1];
|
|
28115
28115
|
break;
|
|
28116
28116
|
}
|
|
28117
|
-
if (v[0] === 6 &&
|
|
28118
|
-
|
|
28117
|
+
if (v[0] === 6 && s.label < c[1]) {
|
|
28118
|
+
s.label = c[1], c = v;
|
|
28119
28119
|
break;
|
|
28120
28120
|
}
|
|
28121
|
-
if (c &&
|
|
28122
|
-
|
|
28121
|
+
if (c && s.label < c[2]) {
|
|
28122
|
+
s.label = c[2], s.ops.push(v);
|
|
28123
28123
|
break;
|
|
28124
28124
|
}
|
|
28125
|
-
c[2] &&
|
|
28125
|
+
c[2] && s.ops.pop(), s.trys.pop();
|
|
28126
28126
|
continue;
|
|
28127
28127
|
}
|
|
28128
|
-
v = l.call(d,
|
|
28128
|
+
v = l.call(d, s);
|
|
28129
28129
|
} catch (D) {
|
|
28130
28130
|
v = [6, D], b = 0;
|
|
28131
28131
|
} finally {
|
|
@@ -28138,8 +28138,8 @@ function pa() {
|
|
|
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 r = Le,
|
|
28142
|
-
l === void 0 && (l = f.DEFAULT_OPTIONS),
|
|
28141
|
+
var r = Le, u = rt, f = j(), _ = Mt(), p = Rt(), g = n(Pt()), o = pa(), t = function(d, l, s) {
|
|
28142
|
+
l === void 0 && (l = f.DEFAULT_OPTIONS), s === void 0 && (s = !0);
|
|
28143
28143
|
var y = (0, r.useState)(null), b = y[0], c = y[1], T = (0, r.useState)({}), S = T[0], E = T[1], v = (0, r.useMemo)(function() {
|
|
28144
28144
|
if (!l.disableJson && b)
|
|
28145
28145
|
try {
|
|
@@ -28151,47 +28151,47 @@ function pa() {
|
|
|
28151
28151
|
}, [b, l.disableJson]), D = (0, r.useRef)(null), L = (0, r.useRef)(null), I = (0, r.useRef)(function() {
|
|
28152
28152
|
}), Q = (0, r.useRef)(0), Te = (0, r.useRef)(Date.now()), Ge = (0, r.useRef)([]), B = (0, r.useRef)(null), w = (0, r.useRef)(l);
|
|
28153
28153
|
w.current = l;
|
|
28154
|
-
var
|
|
28154
|
+
var A = D.current && S[D.current] !== void 0 ? S[D.current] : d !== null && s === !0 ? f.ReadyState.CONNECTING : f.ReadyState.UNINSTANTIATED, re = l.queryParams ? JSON.stringify(l.queryParams) : null, q = (0, r.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,
|
|
28160
|
+
((Y = L.current) === null || Y === void 0 ? void 0 : Y.readyState) === f.ReadyState.OPEN ? ((0, o.assertIsWebSocket)(L.current, w.current.skipAssert), L.current.send(x)) : F && Ge.current.push(x);
|
|
28161
28161
|
}, []), Me = (0, r.useCallback)(function(x, F) {
|
|
28162
28162
|
F === void 0 && (F = !0), q(JSON.stringify(x), F);
|
|
28163
28163
|
}, [q]), Re = (0, r.useCallback)(function() {
|
|
28164
|
-
return w.current.share !== !0 || f.isEventSourceSupported && L.current instanceof EventSource ? L.current : (B.current === null && L.current && ((0,
|
|
28164
|
+
return w.current.share !== !0 || f.isEventSourceSupported && L.current instanceof EventSource ? L.current : (B.current === null && L.current && ((0, o.assertIsWebSocket)(L.current, w.current.skipAssert), B.current = (0, g.default)(L.current, I)), B.current);
|
|
28165
28165
|
}, []);
|
|
28166
28166
|
return (0, r.useEffect)(function() {
|
|
28167
|
-
if (d !== null &&
|
|
28167
|
+
if (d !== null && s === !0) {
|
|
28168
28168
|
var x, F = !1, Y = !0, Ce = function() {
|
|
28169
28169
|
return i(void 0, void 0, void 0, function() {
|
|
28170
|
-
var
|
|
28170
|
+
var oe, le, Pe;
|
|
28171
28171
|
return m(this, function(ce) {
|
|
28172
28172
|
switch (ce.label) {
|
|
28173
28173
|
case 0:
|
|
28174
|
-
return
|
|
28174
|
+
return oe = D, [4, (0, p.getUrl)(d, w)];
|
|
28175
28175
|
case 1:
|
|
28176
|
-
return
|
|
28176
|
+
return oe.current = ce.sent(), D.current === null ? (console.error("Failed to get a valid URL. WebSocket connection aborted."), D.current = "ABORTED", (0, u.flushSync)(function() {
|
|
28177
28177
|
return E(function(X) {
|
|
28178
28178
|
return e(e({}, X), { ABORTED: f.ReadyState.CLOSED });
|
|
28179
28179
|
});
|
|
28180
28180
|
}), [
|
|
28181
28181
|
2
|
|
28182
28182
|
/*return*/
|
|
28183
|
-
]) : (
|
|
28184
|
-
F || (0,
|
|
28183
|
+
]) : (le = function(X) {
|
|
28184
|
+
F || (0, u.flushSync)(function() {
|
|
28185
28185
|
return c(X);
|
|
28186
28186
|
});
|
|
28187
28187
|
}, Pe = function(X) {
|
|
28188
|
-
F || (0,
|
|
28188
|
+
F || (0, u.flushSync)(function() {
|
|
28189
28189
|
return E(function(_e) {
|
|
28190
|
-
var
|
|
28191
|
-
return e(e({}, _e), D.current && (
|
|
28190
|
+
var se;
|
|
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,
|
|
28194
|
+
}, Y && (x = (0, _.createOrJoinSocket)(L, D.current, Pe, w, le, I, Q, Te, q)), [
|
|
28195
28195
|
2
|
|
28196
28196
|
/*return*/
|
|
28197
28197
|
]);
|
|
@@ -28204,60 +28204,60 @@ function pa() {
|
|
|
28204
28204
|
}, Ce(), function() {
|
|
28205
28205
|
F = !0, Y = !1, B.current && (B.current = null), x?.(), c(null);
|
|
28206
28206
|
};
|
|
28207
|
-
} else (d === null ||
|
|
28208
|
-
var
|
|
28209
|
-
return e(e({},
|
|
28207
|
+
} else (d === null || s === !1) && (Q.current = 0, E(function(oe) {
|
|
28208
|
+
var le;
|
|
28209
|
+
return e(e({}, oe), D.current && (le = {}, le[D.current] = f.ReadyState.CLOSED, le));
|
|
28210
28210
|
}));
|
|
28211
|
-
}, [d,
|
|
28212
|
-
|
|
28211
|
+
}, [d, s, re, q]), (0, r.useEffect)(function() {
|
|
28212
|
+
A === f.ReadyState.OPEN && Ge.current.splice(0).forEach(function(x) {
|
|
28213
28213
|
q(x);
|
|
28214
28214
|
});
|
|
28215
|
-
}, [
|
|
28215
|
+
}, [A]), {
|
|
28216
28216
|
sendMessage: q,
|
|
28217
28217
|
sendJsonMessage: Me,
|
|
28218
28218
|
lastMessage: b,
|
|
28219
28219
|
lastJsonMessage: v,
|
|
28220
|
-
readyState:
|
|
28220
|
+
readyState: A,
|
|
28221
28221
|
getWebSocket: Re
|
|
28222
28222
|
};
|
|
28223
28223
|
};
|
|
28224
28224
|
return z.useWebSocket = t, z;
|
|
28225
28225
|
}
|
|
28226
|
-
var
|
|
28226
|
+
var de = {}, Qa;
|
|
28227
28227
|
function xt() {
|
|
28228
|
-
if (
|
|
28229
|
-
|
|
28230
|
-
var e =
|
|
28228
|
+
if (Qa) return de;
|
|
28229
|
+
Qa = 1;
|
|
28230
|
+
var e = de && de.__assign || function() {
|
|
28231
28231
|
return e = Object.assign || function(_) {
|
|
28232
|
-
for (var
|
|
28233
|
-
|
|
28234
|
-
for (var t in
|
|
28232
|
+
for (var p, g = 1, o = arguments.length; g < o; g++) {
|
|
28233
|
+
p = arguments[g];
|
|
28234
|
+
for (var t in p) Object.prototype.hasOwnProperty.call(p, t) && (_[t] = p[t]);
|
|
28235
28235
|
}
|
|
28236
28236
|
return _;
|
|
28237
28237
|
}, e.apply(this, arguments);
|
|
28238
28238
|
};
|
|
28239
|
-
Object.defineProperty(
|
|
28240
|
-
var i = Le, m =
|
|
28239
|
+
Object.defineProperty(de, "__esModule", { value: !0 }), de.useSocketIO = void 0;
|
|
28240
|
+
var i = Le, m = ga(), n = j(), r = {
|
|
28241
28241
|
type: "empty",
|
|
28242
28242
|
payload: null
|
|
28243
|
-
},
|
|
28243
|
+
}, u = function(_) {
|
|
28244
28244
|
if (!_ || !_.data)
|
|
28245
28245
|
return r;
|
|
28246
|
-
var
|
|
28247
|
-
if (!
|
|
28246
|
+
var p = _.data.match(/\[.*]/);
|
|
28247
|
+
if (!p)
|
|
28248
28248
|
return r;
|
|
28249
|
-
var
|
|
28250
|
-
return !Array.isArray(
|
|
28251
|
-
type:
|
|
28252
|
-
payload:
|
|
28249
|
+
var g = JSON.parse(p);
|
|
28250
|
+
return !Array.isArray(g) || !g[1] ? r : {
|
|
28251
|
+
type: g[0],
|
|
28252
|
+
payload: g[1]
|
|
28253
28253
|
};
|
|
28254
|
-
}, f = function(_,
|
|
28255
|
-
|
|
28256
|
-
var
|
|
28257
|
-
return e(e({},
|
|
28258
|
-
}, []), t = (0, m.useWebSocket)(_,
|
|
28259
|
-
return
|
|
28260
|
-
}, [
|
|
28254
|
+
}, f = function(_, p, g) {
|
|
28255
|
+
p === void 0 && (p = n.DEFAULT_OPTIONS), g === void 0 && (g = !0);
|
|
28256
|
+
var o = (0, i.useMemo)(function() {
|
|
28257
|
+
return e(e({}, p), { fromSocketIO: !0 });
|
|
28258
|
+
}, []), t = (0, m.useWebSocket)(_, o, g), d = t.sendMessage, l = t.sendJsonMessage, s = t.lastMessage, y = t.readyState, b = t.getWebSocket, c = (0, i.useMemo)(function() {
|
|
28259
|
+
return u(s);
|
|
28260
|
+
}, [s]);
|
|
28261
28261
|
return {
|
|
28262
28262
|
sendMessage: d,
|
|
28263
28263
|
sendJsonMessage: l,
|
|
@@ -28267,38 +28267,38 @@ function xt() {
|
|
|
28267
28267
|
getWebSocket: b
|
|
28268
28268
|
};
|
|
28269
28269
|
};
|
|
28270
|
-
return
|
|
28270
|
+
return de.useSocketIO = f, de;
|
|
28271
28271
|
}
|
|
28272
|
-
var ae = {},
|
|
28272
|
+
var ae = {}, qa;
|
|
28273
28273
|
function Ot() {
|
|
28274
|
-
if (
|
|
28275
|
-
|
|
28274
|
+
if (qa) return ae;
|
|
28275
|
+
qa = 1;
|
|
28276
28276
|
var e = ae && ae.__assign || function() {
|
|
28277
28277
|
return e = Object.assign || function(f) {
|
|
28278
|
-
for (var _,
|
|
28279
|
-
_ = arguments[
|
|
28280
|
-
for (var
|
|
28278
|
+
for (var _, p = 1, g = arguments.length; p < g; p++) {
|
|
28279
|
+
_ = arguments[p];
|
|
28280
|
+
for (var o in _) Object.prototype.hasOwnProperty.call(_, o) && (f[o] = _[o]);
|
|
28281
28281
|
}
|
|
28282
28282
|
return f;
|
|
28283
28283
|
}, e.apply(this, arguments);
|
|
28284
28284
|
}, i = ae && ae.__rest || function(f, _) {
|
|
28285
|
-
var
|
|
28286
|
-
for (var
|
|
28285
|
+
var p = {};
|
|
28286
|
+
for (var g in f) Object.prototype.hasOwnProperty.call(f, g) && _.indexOf(g) < 0 && (p[g] = f[g]);
|
|
28287
28287
|
if (f != null && typeof Object.getOwnPropertySymbols == "function")
|
|
28288
|
-
for (var
|
|
28289
|
-
_.indexOf(
|
|
28290
|
-
return
|
|
28288
|
+
for (var o = 0, g = Object.getOwnPropertySymbols(f); o < g.length; o++)
|
|
28289
|
+
_.indexOf(g[o]) < 0 && Object.prototype.propertyIsEnumerable.call(f, g[o]) && (p[g[o]] = f[g[o]]);
|
|
28290
|
+
return p;
|
|
28291
28291
|
};
|
|
28292
28292
|
Object.defineProperty(ae, "__esModule", { value: !0 }), ae.useEventSource = void 0;
|
|
28293
|
-
var m = Le, n =
|
|
28293
|
+
var m = Le, n = ga(), r = j(), u = function(f, _, p) {
|
|
28294
28294
|
_ === void 0 && (_ = r.DEFAULT_EVENT_SOURCE_OPTIONS);
|
|
28295
|
-
var
|
|
28296
|
-
|
|
28295
|
+
var g = _.withCredentials, o = _.events, t = i(_, ["withCredentials", "events"]);
|
|
28296
|
+
p === void 0 && (p = !0);
|
|
28297
28297
|
var d = e(e({}, t), { eventSourceOptions: {
|
|
28298
|
-
withCredentials:
|
|
28298
|
+
withCredentials: g
|
|
28299
28299
|
} }), l = (0, m.useRef)(r.EMPTY_EVENT_HANDLERS);
|
|
28300
|
-
|
|
28301
|
-
var
|
|
28300
|
+
o && (l.current = o);
|
|
28301
|
+
var s = (0, n.useWebSocket)(f, d, p), y = s.lastMessage, b = s.readyState, c = s.getWebSocket;
|
|
28302
28302
|
return (0, m.useEffect)(function() {
|
|
28303
28303
|
y?.type && Object.entries(l.current).forEach(function(T) {
|
|
28304
28304
|
var S = T[0], E = T[1];
|
|
@@ -28310,13 +28310,13 @@ function Ot() {
|
|
|
28310
28310
|
getEventSource: c
|
|
28311
28311
|
};
|
|
28312
28312
|
};
|
|
28313
|
-
return ae.useEventSource =
|
|
28313
|
+
return ae.useEventSource = u, ae;
|
|
28314
28314
|
}
|
|
28315
|
-
var
|
|
28315
|
+
var Ya;
|
|
28316
28316
|
function Ht() {
|
|
28317
|
-
return
|
|
28317
|
+
return Ya || (Ya = 1, (function(e) {
|
|
28318
28318
|
Object.defineProperty(e, "__esModule", { value: !0 }), e.resetGlobalState = e.useEventSource = e.ReadyState = e.useSocketIO = e.default = void 0;
|
|
28319
|
-
var i =
|
|
28319
|
+
var i = ga();
|
|
28320
28320
|
Object.defineProperty(e, "default", { enumerable: !0, get: function() {
|
|
28321
28321
|
return i.useWebSocket;
|
|
28322
28322
|
} });
|
|
@@ -28332,11 +28332,11 @@ function Ht() {
|
|
|
28332
28332
|
Object.defineProperty(e, "useEventSource", { enumerable: !0, get: function() {
|
|
28333
28333
|
return r.useEventSource;
|
|
28334
28334
|
} });
|
|
28335
|
-
var
|
|
28335
|
+
var u = pa();
|
|
28336
28336
|
Object.defineProperty(e, "resetGlobalState", { enumerable: !0, get: function() {
|
|
28337
|
-
return
|
|
28337
|
+
return u.resetGlobalState;
|
|
28338
28338
|
} });
|
|
28339
|
-
})(
|
|
28339
|
+
})(Xe)), Xe;
|
|
28340
28340
|
}
|
|
28341
28341
|
var wt = Ht();
|
|
28342
28342
|
const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
@@ -28350,20 +28350,20 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28350
28350
|
TRANSFER_IN_GAME: "transfer_in_game",
|
|
28351
28351
|
CHECK_REQUEST: "CHECK_RREQUEST",
|
|
28352
28352
|
CASH_REGISTER_LIMIT: "cash_register_limit"
|
|
28353
|
-
}, Wt = 3e4,
|
|
28353
|
+
}, Wt = 3e4, yl = ({
|
|
28354
28354
|
socketUrl: e,
|
|
28355
28355
|
socketHandlers: i = {},
|
|
28356
28356
|
options: m = {}
|
|
28357
28357
|
}) => {
|
|
28358
|
-
const n =
|
|
28359
|
-
sendMessage:
|
|
28358
|
+
const n = Ga(!1), r = Ga(i), {
|
|
28359
|
+
sendMessage: u,
|
|
28360
28360
|
// 發送普通訊息
|
|
28361
28361
|
sendJsonMessage: f,
|
|
28362
28362
|
// 發送 JSON 訊息
|
|
28363
28363
|
lastMessage: _,
|
|
28364
28364
|
// 最後接收到的訊息
|
|
28365
28365
|
// lastJsonMessage, // 最後接收到的 JSON 訊息
|
|
28366
|
-
readyState:
|
|
28366
|
+
readyState: p
|
|
28367
28367
|
// WebSocket 連線狀態
|
|
28368
28368
|
// getWebSocket, // 獲取 WebSocket 實例
|
|
28369
28369
|
} = Ft(e, {
|
|
@@ -28373,7 +28373,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28373
28373
|
reconnectAttempts: 9999,
|
|
28374
28374
|
reconnectInterval: 1e3,
|
|
28375
28375
|
...m
|
|
28376
|
-
}),
|
|
28376
|
+
}), g = ta(() => {
|
|
28377
28377
|
try {
|
|
28378
28378
|
return JSON.parse(_?.data);
|
|
28379
28379
|
} catch {
|
|
@@ -28381,33 +28381,33 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28381
28381
|
}
|
|
28382
28382
|
}, [_?.data]);
|
|
28383
28383
|
return De(() => {
|
|
28384
|
-
const
|
|
28385
|
-
() =>
|
|
28384
|
+
const o = setInterval(
|
|
28385
|
+
() => u("ping"),
|
|
28386
28386
|
Wt
|
|
28387
28387
|
);
|
|
28388
|
-
return () => clearInterval(
|
|
28389
|
-
}, [
|
|
28388
|
+
return () => clearInterval(o);
|
|
28389
|
+
}, [u]), De(() => {
|
|
28390
28390
|
r.current = i;
|
|
28391
28391
|
}, [i]), De(() => {
|
|
28392
|
-
if (!
|
|
28392
|
+
if (!g) return;
|
|
28393
28393
|
const {
|
|
28394
|
-
onDeposit:
|
|
28394
|
+
onDeposit: o,
|
|
28395
28395
|
onTransCode: t,
|
|
28396
28396
|
onError: d,
|
|
28397
28397
|
onUpdateMember: l,
|
|
28398
|
-
onMaintainNotice:
|
|
28398
|
+
onMaintainNotice: s,
|
|
28399
28399
|
onMaintainNoticeMember: y,
|
|
28400
28400
|
onReload: b,
|
|
28401
28401
|
onTransferInGame: c,
|
|
28402
28402
|
onCashRegisterLimit: T
|
|
28403
|
-
} = r.current, S = we(
|
|
28404
|
-
memberInfoUid: we(
|
|
28405
|
-
data: we(
|
|
28406
|
-
memo: we(
|
|
28403
|
+
} = r.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)
|
|
28407
28407
|
};
|
|
28408
28408
|
switch (S) {
|
|
28409
28409
|
case K.DEPOSIT:
|
|
28410
|
-
|
|
28410
|
+
o?.(E);
|
|
28411
28411
|
break;
|
|
28412
28412
|
case K.TRANS_CODE:
|
|
28413
28413
|
t?.(E);
|
|
@@ -28419,7 +28419,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28419
28419
|
l?.(E);
|
|
28420
28420
|
break;
|
|
28421
28421
|
case K.MAINTAIN_NOTICE:
|
|
28422
|
-
|
|
28422
|
+
s?.(E);
|
|
28423
28423
|
break;
|
|
28424
28424
|
case K.MAINTAIN_NOTICE_MEMBER:
|
|
28425
28425
|
y?.(E);
|
|
@@ -28438,80 +28438,93 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28438
28438
|
console.warn("Unknown socket type:", S);
|
|
28439
28439
|
break;
|
|
28440
28440
|
}
|
|
28441
|
-
}, [
|
|
28442
|
-
sendMessage:
|
|
28441
|
+
}, [g]), De(() => () => n.current = !0, []), {
|
|
28442
|
+
sendMessage: u,
|
|
28443
28443
|
sendJsonMessage: f,
|
|
28444
|
-
readyState:
|
|
28444
|
+
readyState: p
|
|
28445
28445
|
// WebSocket 連線狀態
|
|
28446
28446
|
};
|
|
28447
28447
|
}, fi = () => {
|
|
28448
|
-
const { client: e } =
|
|
28448
|
+
const { client: e } = te(), i = V(async () => {
|
|
28449
28449
|
const { data: n } = await e.get("/carousels");
|
|
28450
28450
|
return n;
|
|
28451
|
-
}, [e]), m =
|
|
28451
|
+
}, [e]), m = V(async () => await e.get("/marquees"), [e]);
|
|
28452
28452
|
return { commonCarouselApi: i, commonMarqueeApi: m };
|
|
28453
|
-
},
|
|
28454
|
-
const {
|
|
28455
|
-
return
|
|
28453
|
+
}, bl = () => {
|
|
28454
|
+
const { lng: e } = te(), { commonCarouselApi: i } = fi(), m = ra(e);
|
|
28455
|
+
return ie({
|
|
28456
28456
|
queryKey: ["getCarouselList"],
|
|
28457
|
-
queryFn: async () => await
|
|
28457
|
+
queryFn: async () => await i(),
|
|
28458
|
+
select: (n) => {
|
|
28459
|
+
const { data: r } = n;
|
|
28460
|
+
return r.map((f) => {
|
|
28461
|
+
const { carousels_lang: _ } = f;
|
|
28462
|
+
return {
|
|
28463
|
+
...f,
|
|
28464
|
+
carousel_current_language: Ve(
|
|
28465
|
+
_,
|
|
28466
|
+
(p) => p.lang === m || p.lang === "en_US"
|
|
28467
|
+
) || {}
|
|
28468
|
+
};
|
|
28469
|
+
});
|
|
28470
|
+
}
|
|
28458
28471
|
});
|
|
28459
|
-
},
|
|
28460
|
-
const { lng: e } =
|
|
28461
|
-
return
|
|
28472
|
+
}, Tl = () => {
|
|
28473
|
+
const { lng: e } = te(), { commonMarqueeApi: i } = fi(), m = ra(e);
|
|
28474
|
+
return ie({
|
|
28462
28475
|
queryKey: ["getMarqueeList"],
|
|
28463
28476
|
queryFn: async () => i(),
|
|
28464
28477
|
select: (n) => {
|
|
28465
28478
|
const r = n.Marquees;
|
|
28466
|
-
return
|
|
28479
|
+
return Be(r, (f) => f[m] || f["en-US"]);
|
|
28467
28480
|
}
|
|
28468
28481
|
});
|
|
28469
28482
|
}, Jt = () => {
|
|
28470
|
-
const { client: e, lng: i } =
|
|
28471
|
-
return { playGameApi:
|
|
28483
|
+
const { client: e, lng: i } = te(), m = ra(i || "tw");
|
|
28484
|
+
return { playGameApi: V(
|
|
28472
28485
|
async (r) => {
|
|
28473
28486
|
const {
|
|
28474
|
-
gameUid:
|
|
28487
|
+
gameUid: u = "",
|
|
28475
28488
|
// 遊戲唯一標識
|
|
28476
28489
|
gameCode: f = "",
|
|
28477
28490
|
// 遊戲代碼
|
|
28478
28491
|
isMobile: _ = !1,
|
|
28479
28492
|
// 是否為行動裝置
|
|
28480
|
-
gameCurrency:
|
|
28493
|
+
gameCurrency: p = "",
|
|
28481
28494
|
// 遊戲幣別
|
|
28482
|
-
currentCurrency:
|
|
28495
|
+
currentCurrency: g = ""
|
|
28483
28496
|
// 目前使用的幣別
|
|
28484
28497
|
} = r;
|
|
28485
28498
|
return await e.post("/game/go", {
|
|
28486
|
-
gameUid:
|
|
28499
|
+
gameUid: u,
|
|
28487
28500
|
gameCode: f,
|
|
28488
28501
|
lang: m,
|
|
28489
28502
|
is_mobile: _,
|
|
28490
|
-
currency_code:
|
|
28491
|
-
gameCurrencyNow:
|
|
28492
|
-
walletCurrencyNow:
|
|
28503
|
+
currency_code: p,
|
|
28504
|
+
gameCurrencyNow: g,
|
|
28505
|
+
walletCurrencyNow: g
|
|
28493
28506
|
});
|
|
28494
28507
|
},
|
|
28495
28508
|
[e, m]
|
|
28496
28509
|
) };
|
|
28497
|
-
}, Ui = "3.7.8", zt = Ui, be = typeof Buffer == "function",
|
|
28510
|
+
}, 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) => {
|
|
28498
28511
|
let i = {};
|
|
28499
28512
|
return e.forEach((m, n) => i[m] = n), i;
|
|
28500
|
-
})(Ee), Vt = /^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/, H = String.fromCharCode.bind(String),
|
|
28501
|
-
let i, m, n, r,
|
|
28513
|
+
})(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) => {
|
|
28514
|
+
let i, m, n, r, u = "";
|
|
28502
28515
|
const f = e.length % 3;
|
|
28503
28516
|
for (let _ = 0; _ < e.length; ) {
|
|
28504
28517
|
if ((m = e.charCodeAt(_++)) > 255 || (n = e.charCodeAt(_++)) > 255 || (r = e.charCodeAt(_++)) > 255)
|
|
28505
28518
|
throw new TypeError("invalid character found");
|
|
28506
|
-
i = m << 16 | n << 8 | r,
|
|
28519
|
+
i = m << 16 | n << 8 | r, u += Ee[i >> 18 & 63] + Ee[i >> 12 & 63] + Ee[i >> 6 & 63] + Ee[i & 63];
|
|
28507
28520
|
}
|
|
28508
|
-
return f ?
|
|
28509
|
-
},
|
|
28521
|
+
return f ? u.slice(0, f - 3) + "===".substring(f) : u;
|
|
28522
|
+
}, da = typeof btoa == "function" ? (e) => btoa(e) : be ? (e) => Buffer.from(e, "binary").toString("base64") : Ti, la = be ? (e) => Buffer.from(e).toString("base64") : (e) => {
|
|
28510
28523
|
let m = [];
|
|
28511
28524
|
for (let n = 0, r = e.length; n < r; n += 4096)
|
|
28512
28525
|
m.push(H.apply(null, e.subarray(n, n + 4096)));
|
|
28513
|
-
return
|
|
28514
|
-
}, Ze = (e, i = !1) => i ? yi(
|
|
28526
|
+
return da(m.join(""));
|
|
28527
|
+
}, Ze = (e, i = !1) => i ? yi(la(e)) : la(e), At = (e) => {
|
|
28515
28528
|
if (e.length < 2) {
|
|
28516
28529
|
var i = e.charCodeAt(0);
|
|
28517
28530
|
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);
|
|
@@ -28519,7 +28532,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28519
28532
|
var i = 65536 + (e.charCodeAt(0) - 55296) * 1024 + (e.charCodeAt(1) - 56320);
|
|
28520
28533
|
return H(240 | i >>> 18 & 7) + H(128 | i >>> 12 & 63) + H(128 | i >>> 6 & 63) + H(128 | i & 63);
|
|
28521
28534
|
}
|
|
28522
|
-
}, It = /[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g, Ci = (e) => e.replace(It, At),
|
|
28535
|
+
}, 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) => la($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) => {
|
|
28523
28536
|
switch (e.length) {
|
|
28524
28537
|
case 4:
|
|
28525
28538
|
var i = (7 & e.charCodeAt(0)) << 18 | (63 & e.charCodeAt(1)) << 12 | (63 & e.charCodeAt(2)) << 6 | 63 & e.charCodeAt(3), m = i - 65536;
|
|
@@ -28534,10 +28547,10 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28534
28547
|
throw new TypeError("malformed base64.");
|
|
28535
28548
|
e += "==".slice(2 - (e.length & 3));
|
|
28536
28549
|
let i, m, n, r = [];
|
|
28537
|
-
for (let
|
|
28538
|
-
i = Je[e.charAt(
|
|
28550
|
+
for (let u = 0; u < e.length; )
|
|
28551
|
+
i = Je[e.charAt(u++)] << 18 | Je[e.charAt(u++)] << 12 | (m = Je[e.charAt(u++)]) << 6 | (n = Je[e.charAt(u++)]), m === 64 ? r.push(H(i >> 16 & 255)) : n === 64 ? r.push(H(i >> 16 & 255, i >> 8 & 255)) : r.push(H(i >> 16 & 255, i >> 8 & 255, i & 255));
|
|
28539
28552
|
return r.join("");
|
|
28540
|
-
},
|
|
28553
|
+
}, 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 == "-" ? "+" : "/")), na = (e) => jt(Ni(e)), Qt = (e) => {
|
|
28541
28554
|
if (typeof e != "string")
|
|
28542
28555
|
return !1;
|
|
28543
28556
|
const i = e.replace(/\s+/g, "").replace(/={0,2}$/, "");
|
|
@@ -28550,7 +28563,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28550
28563
|
}), Ei = function() {
|
|
28551
28564
|
const e = (i, m) => Object.defineProperty(String.prototype, i, Di(m));
|
|
28552
28565
|
e("fromBase64", function() {
|
|
28553
|
-
return
|
|
28566
|
+
return na(this);
|
|
28554
28567
|
}), e("toBase64", function(i) {
|
|
28555
28568
|
return ye(this, i);
|
|
28556
28569
|
}), e("toBase64URI", function() {
|
|
@@ -28574,50 +28587,50 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28574
28587
|
}, Yt = {
|
|
28575
28588
|
version: Ui,
|
|
28576
28589
|
VERSION: zt,
|
|
28577
|
-
atob:
|
|
28590
|
+
atob: ca,
|
|
28578
28591
|
atobPolyfill: hi,
|
|
28579
|
-
btoa:
|
|
28592
|
+
btoa: da,
|
|
28580
28593
|
btoaPolyfill: Ti,
|
|
28581
|
-
fromBase64:
|
|
28594
|
+
fromBase64: na,
|
|
28582
28595
|
toBase64: ye,
|
|
28583
28596
|
encode: ye,
|
|
28584
|
-
encodeURI:
|
|
28585
|
-
encodeURL:
|
|
28597
|
+
encodeURI: ii,
|
|
28598
|
+
encodeURL: ii,
|
|
28586
28599
|
utob: Ci,
|
|
28587
28600
|
btou: vi,
|
|
28588
|
-
decode:
|
|
28601
|
+
decode: na,
|
|
28589
28602
|
isValid: Qt,
|
|
28590
28603
|
fromUint8Array: Ze,
|
|
28591
28604
|
toUint8Array: Si,
|
|
28592
28605
|
extendString: Ei,
|
|
28593
28606
|
extendUint8Array: Li,
|
|
28594
28607
|
extendBuiltins: qt
|
|
28595
|
-
},
|
|
28608
|
+
}, Cl = (e, i) => {
|
|
28596
28609
|
const { playGameApi: m } = Jt();
|
|
28597
|
-
return
|
|
28610
|
+
return ie({
|
|
28598
28611
|
queryKey: ["playGame"],
|
|
28599
28612
|
queryFn: async () => {
|
|
28600
|
-
const { gameUid: n, gameCode: r, isMobile:
|
|
28613
|
+
const { gameUid: n, gameCode: r, isMobile: u, gameCurrency: f, currentCurrency: _ } = e || {}, p = await m({
|
|
28601
28614
|
gameUid: n,
|
|
28602
28615
|
gameCode: r,
|
|
28603
|
-
isMobile:
|
|
28616
|
+
isMobile: u,
|
|
28604
28617
|
gameCurrency: f,
|
|
28605
28618
|
currentCurrency: _
|
|
28606
28619
|
}), {
|
|
28607
|
-
game_currency:
|
|
28608
|
-
lang:
|
|
28620
|
+
game_currency: g,
|
|
28621
|
+
lang: o,
|
|
28609
28622
|
not_support_iframe: t,
|
|
28610
28623
|
portrait: d,
|
|
28611
28624
|
url: l,
|
|
28612
|
-
is_html_code:
|
|
28625
|
+
is_html_code: s,
|
|
28613
28626
|
message: y
|
|
28614
|
-
} =
|
|
28627
|
+
} = p;
|
|
28615
28628
|
return {
|
|
28616
|
-
gameCurrency:
|
|
28617
|
-
lang:
|
|
28629
|
+
gameCurrency: g,
|
|
28630
|
+
lang: o,
|
|
28618
28631
|
supportIframe: !t,
|
|
28619
28632
|
supportPortrait: d,
|
|
28620
|
-
isHtmlCode:
|
|
28633
|
+
isHtmlCode: s,
|
|
28621
28634
|
gameUrl: l,
|
|
28622
28635
|
decodeGameUrl: Yt.decode(l),
|
|
28623
28636
|
message: y
|
|
@@ -28627,38 +28640,49 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28627
28640
|
...i
|
|
28628
28641
|
});
|
|
28629
28642
|
}, Xt = ({ options: e } = {}) => {
|
|
28630
|
-
const { userLoginApi: i } =
|
|
28631
|
-
return
|
|
28643
|
+
const { userLoginApi: i } = me();
|
|
28644
|
+
return ma({
|
|
28632
28645
|
mutationKey: ["userLogin"],
|
|
28633
28646
|
mutationFn: async (m) => i(m),
|
|
28634
28647
|
...e
|
|
28635
28648
|
});
|
|
28636
28649
|
}, $t = ({ options: e } = {}) => {
|
|
28637
|
-
const { userLogoutApi: i } =
|
|
28638
|
-
return
|
|
28650
|
+
const { userLogoutApi: i } = me();
|
|
28651
|
+
return ma({
|
|
28639
28652
|
mutationKey: ["userLogout"],
|
|
28640
28653
|
mutationFn: async () => i(),
|
|
28641
28654
|
...e
|
|
28642
28655
|
});
|
|
28643
28656
|
}, el = ({ options: e } = {}) => {
|
|
28644
|
-
const { addOrRemoveFavoriteGameApi: i } =
|
|
28645
|
-
return
|
|
28657
|
+
const { addOrRemoveFavoriteGameApi: i } = me();
|
|
28658
|
+
return ma({
|
|
28646
28659
|
mutationKey: ["toggleFavoriteGame"],
|
|
28647
28660
|
mutationFn: async (m) => i(m),
|
|
28648
28661
|
...e
|
|
28649
28662
|
});
|
|
28650
|
-
},
|
|
28663
|
+
}, al = ({ options: e } = {}) => {
|
|
28664
|
+
const { rankingGameApi: i } = me();
|
|
28665
|
+
return ie({
|
|
28666
|
+
queryKey: ["rankingGame"],
|
|
28667
|
+
queryFn: async () => i(),
|
|
28668
|
+
enabled: window.profit_ranking_status !== 1,
|
|
28669
|
+
...e
|
|
28670
|
+
});
|
|
28671
|
+
}, vl = ({
|
|
28651
28672
|
options: e = {
|
|
28652
28673
|
login: {},
|
|
28653
28674
|
logout: {},
|
|
28654
|
-
toggleFavoriteGame: {}
|
|
28675
|
+
toggleFavoriteGame: {},
|
|
28676
|
+
rankingGame: {}
|
|
28655
28677
|
}
|
|
28656
28678
|
} = {}) => {
|
|
28657
28679
|
const i = Xt({ options: e.login }), m = $t({ options: e.logout }), n = el({
|
|
28658
28680
|
options: e.toggleFavoriteGame
|
|
28681
|
+
}), r = al({
|
|
28682
|
+
options: e.rankingGame
|
|
28659
28683
|
});
|
|
28660
|
-
return { login: i, logout: m, toggleFavoriteGame: n };
|
|
28661
|
-
},
|
|
28684
|
+
return { login: i, logout: m, toggleFavoriteGame: n, rankingGame: r };
|
|
28685
|
+
}, ti = (e) => {
|
|
28662
28686
|
switch (e) {
|
|
28663
28687
|
case "tw":
|
|
28664
28688
|
return "Tw";
|
|
@@ -28677,24 +28701,24 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28677
28701
|
default:
|
|
28678
28702
|
return "En";
|
|
28679
28703
|
}
|
|
28680
|
-
},
|
|
28681
|
-
const { lng: i } =
|
|
28704
|
+
}, il = "https://d1h3qe8voog6w4.cloudfront.net", li = "https://d3jx2uvukujuvn.cloudfront.net", ni = "game-icon-ds88", hl = ({ gameData: e = {} } = {}) => {
|
|
28705
|
+
const { lng: i } = te(), m = ti(i), {
|
|
28682
28706
|
gameCode: n,
|
|
28683
28707
|
// 遊戲代碼
|
|
28684
28708
|
gameUid: r,
|
|
28685
28709
|
// 遊戲唯一標識符
|
|
28686
|
-
gameTypeUid:
|
|
28710
|
+
gameTypeUid: u,
|
|
28687
28711
|
// 遊戲類型唯一標識符
|
|
28688
28712
|
platformUid: f,
|
|
28689
28713
|
// 平台唯一標識符
|
|
28690
28714
|
// platform_enum: platformEnum, // 平台枚舉
|
|
28691
28715
|
currencyCode: _,
|
|
28692
28716
|
// 支援貨幣
|
|
28693
|
-
enterLobbyMode:
|
|
28717
|
+
enterLobbyMode: p,
|
|
28694
28718
|
// 進入大廳模式
|
|
28695
|
-
game_platform:
|
|
28719
|
+
game_platform: g,
|
|
28696
28720
|
// 遊戲平台
|
|
28697
|
-
game_subtype:
|
|
28721
|
+
game_subtype: o,
|
|
28698
28722
|
// 遊戲子類型
|
|
28699
28723
|
game_type: t,
|
|
28700
28724
|
// 遊戲類型
|
|
@@ -28702,7 +28726,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28702
28726
|
// 遊戲標籤
|
|
28703
28727
|
isUnderMaintenance: l,
|
|
28704
28728
|
// 是否維護中
|
|
28705
|
-
support_vertical:
|
|
28729
|
+
support_vertical: s,
|
|
28706
28730
|
// 是否支援直向
|
|
28707
28731
|
support_horizontal: y,
|
|
28708
28732
|
// 是否支援橫向
|
|
@@ -28716,20 +28740,20 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28716
28740
|
// 越南名稱
|
|
28717
28741
|
gameNameTw: E
|
|
28718
28742
|
// 繁體中文名稱
|
|
28719
|
-
} = e, v = e?.[`gameName${
|
|
28743
|
+
} = e, v = e?.[`gameName${ti(m)}`], D = `${li}/${ni}/en/${g}/${Ra(n, / /g, "_")}.webp`, L = `${li}/${ni}/en/${g}/${Ra(n, / /g, "_")}.gif`;
|
|
28720
28744
|
return {
|
|
28721
28745
|
gameCode: n,
|
|
28722
28746
|
gameUid: r,
|
|
28723
|
-
gameTypeUid:
|
|
28747
|
+
gameTypeUid: u,
|
|
28724
28748
|
providerUid: f,
|
|
28725
28749
|
supportCurrency: _,
|
|
28726
|
-
enterLobbyMode:
|
|
28727
|
-
gamePlatform:
|
|
28728
|
-
gameSubType:
|
|
28750
|
+
enterLobbyMode: p,
|
|
28751
|
+
gamePlatform: g,
|
|
28752
|
+
gameSubType: o,
|
|
28729
28753
|
gameType: t,
|
|
28730
28754
|
gameTags: d,
|
|
28731
28755
|
isUnderMaintenance: l,
|
|
28732
|
-
supportVertical:
|
|
28756
|
+
supportVertical: s,
|
|
28733
28757
|
supportHorizontal: y,
|
|
28734
28758
|
userClickCount: b,
|
|
28735
28759
|
gameNameEn: c,
|
|
@@ -28740,7 +28764,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28740
28764
|
gameImageUrl: D,
|
|
28741
28765
|
gameImageUrlAnimated: L
|
|
28742
28766
|
};
|
|
28743
|
-
},
|
|
28767
|
+
}, tl = "ds88platformIcon", ll = (e, i = !1) => mt([
|
|
28744
28768
|
"EVO",
|
|
28745
28769
|
"IMSPRIBE",
|
|
28746
28770
|
"SABA",
|
|
@@ -28751,7 +28775,7 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28751
28775
|
"HACK",
|
|
28752
28776
|
"NAGA",
|
|
28753
28777
|
"RSG"
|
|
28754
|
-
], e) && i ? `${e}_dark` : e,
|
|
28778
|
+
], e) && i ? `${e}_dark` : e, kl = ({ platformData: e, darkMode: i } = {}) => {
|
|
28755
28779
|
const {
|
|
28756
28780
|
SubPlatformEnum: m,
|
|
28757
28781
|
// 子平台枚舉
|
|
@@ -28759,53 +28783,53 @@ const Ft = /* @__PURE__ */ ot(wt), K = {
|
|
|
28759
28783
|
// 平台枚舉
|
|
28760
28784
|
isUnderMaintenance: r,
|
|
28761
28785
|
// 是否維護中
|
|
28762
|
-
maintenanceStartTime:
|
|
28786
|
+
maintenanceStartTime: u,
|
|
28763
28787
|
// 維護開始時間
|
|
28764
28788
|
maintenanceEndTime: f,
|
|
28765
28789
|
// 維護結束時間
|
|
28766
28790
|
platform: _,
|
|
28767
28791
|
// 平台代碼
|
|
28768
|
-
platformUid:
|
|
28792
|
+
platformUid: p,
|
|
28769
28793
|
// 平台唯一標識符
|
|
28770
|
-
platformMode:
|
|
28794
|
+
platformMode: g,
|
|
28771
28795
|
// 平台模式
|
|
28772
|
-
temp_maintenance_start_time:
|
|
28796
|
+
temp_maintenance_start_time: o,
|
|
28773
28797
|
// 臨時維護開始時間
|
|
28774
28798
|
temp_maintenance_end_time: t
|
|
28775
28799
|
// 臨時維護結束時間
|
|
28776
|
-
} = e || {}, d = `${
|
|
28800
|
+
} = e || {}, d = `${il}/${tl}/${ll(n, i)}.png`;
|
|
28777
28801
|
return {
|
|
28778
28802
|
subPlatformEnum: m,
|
|
28779
28803
|
platformEnum: n,
|
|
28780
28804
|
isUnderMaintenance: r,
|
|
28781
|
-
maintenanceStartTime:
|
|
28805
|
+
maintenanceStartTime: u,
|
|
28782
28806
|
maintenanceEndTime: f,
|
|
28783
28807
|
platform: _,
|
|
28784
|
-
platformUid:
|
|
28785
|
-
platformMode:
|
|
28786
|
-
tempMaintenanceStartTime:
|
|
28808
|
+
platformUid: p,
|
|
28809
|
+
platformMode: g,
|
|
28810
|
+
tempMaintenanceStartTime: o,
|
|
28787
28811
|
tempMaintenanceEndTime: t,
|
|
28788
28812
|
platformImageUrl: d
|
|
28789
28813
|
};
|
|
28790
28814
|
};
|
|
28791
28815
|
export {
|
|
28792
|
-
|
|
28793
|
-
|
|
28794
|
-
|
|
28816
|
+
si as ApiCtx,
|
|
28817
|
+
cl as ApiProvider,
|
|
28818
|
+
ui as GamesInfoCtx,
|
|
28795
28819
|
Ct as buildMultiTypes,
|
|
28796
|
-
|
|
28820
|
+
gl as buildMultiTypesWithSubTypes,
|
|
28797
28821
|
_t as buildSinglePlatformWithSubTypes,
|
|
28798
28822
|
ct as buildSingleType,
|
|
28799
28823
|
Tt as categorizeGames,
|
|
28800
|
-
|
|
28801
|
-
|
|
28824
|
+
ra as convertLanguageCode,
|
|
28825
|
+
pl as createLogoutHandler,
|
|
28802
28826
|
yt as extractGameSubTypeNames,
|
|
28803
28827
|
Ut as extractGameTypeNames,
|
|
28804
|
-
|
|
28805
|
-
|
|
28806
|
-
|
|
28807
|
-
|
|
28808
|
-
|
|
28828
|
+
Ha as extractPlatformNames,
|
|
28829
|
+
ci as filterGamesByPlatform,
|
|
28830
|
+
pi as findGameTypeUid,
|
|
28831
|
+
gi as findPlatformUid,
|
|
28832
|
+
di as findSubPlatform,
|
|
28809
28833
|
ft as flattenAllGames,
|
|
28810
28834
|
bt as flattenFavoriteGames,
|
|
28811
28835
|
vt as groupGamesByPlatform,
|
|
@@ -28813,21 +28837,22 @@ export {
|
|
|
28813
28837
|
dt as groupGamesBySubType,
|
|
28814
28838
|
Dt as initMockWindowData,
|
|
28815
28839
|
kt as processGameInfo,
|
|
28816
|
-
|
|
28817
|
-
|
|
28818
|
-
|
|
28819
|
-
|
|
28820
|
-
|
|
28821
|
-
|
|
28840
|
+
dl as processPlatformData,
|
|
28841
|
+
te as useApiContext,
|
|
28842
|
+
_l as useBalanceGetter,
|
|
28843
|
+
yl as useClientWebSocket,
|
|
28844
|
+
hl as useGameConfig,
|
|
28845
|
+
ul as useGameInfoContext,
|
|
28822
28846
|
Nt as useGamesInfo,
|
|
28823
|
-
|
|
28824
|
-
|
|
28825
|
-
|
|
28826
|
-
|
|
28847
|
+
bl as useGetCarouseList,
|
|
28848
|
+
Tl as useGetMarquee,
|
|
28849
|
+
fl as useGetMemberInfo,
|
|
28850
|
+
Ul as useInitializeWithToken,
|
|
28827
28851
|
Xt as useLogin,
|
|
28828
28852
|
$t as useLogout,
|
|
28829
|
-
|
|
28830
|
-
|
|
28853
|
+
kl as usePlatformConfig,
|
|
28854
|
+
Cl as usePlayGame,
|
|
28855
|
+
al as useRankingGame,
|
|
28831
28856
|
el as useToggleFavoriteGame,
|
|
28832
|
-
|
|
28857
|
+
vl as useUser
|
|
28833
28858
|
};
|