@kalamba/sdk 0.10.1 → 0.13.1
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/{errors-afd9f527.js → errors-7cbbda8a.js} +6 -6
- package/dist/{errors-358575c3.cjs → errors-db453887.cjs} +2 -2
- package/dist/index.cjs +2 -2
- package/dist/index.d.ts +1 -0
- package/dist/index.js +67 -53
- package/dist/plugins.cjs +2 -2
- package/dist/plugins.d.ts +24 -17
- package/dist/plugins.js +641 -645
- package/dist/v4-58efbfa1.js +48 -0
- package/dist/v4-bada56b0.cjs +5 -0
- package/dist/wrapper.cjs +2 -2
- package/dist/wrapper.d.ts +1 -0
- package/dist/wrapper.js +587 -581
- package/package.json +12 -7
- package/dist/noop-3336849b.js +0 -18
- package/dist/noop-b3c54b76.cjs +0 -5
package/dist/plugins.js
CHANGED
|
@@ -1,39 +1,39 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* BSD 3-Clause License
|
|
3
|
-
* Copyright (c)
|
|
3
|
+
* Copyright (c) 2025, Kalamba Games Limited
|
|
4
4
|
*/
|
|
5
|
-
var
|
|
6
|
-
var
|
|
7
|
-
var
|
|
5
|
+
var zt = Object.defineProperty;
|
|
6
|
+
var qt = (s, t, e) => t in s ? zt(s, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[t] = e;
|
|
7
|
+
var m = (s, t, e) => (qt(s, typeof t != "symbol" ? t + "" : t, e), e), nt = (s, t, e) => {
|
|
8
8
|
if (!t.has(s))
|
|
9
9
|
throw TypeError("Cannot " + e);
|
|
10
10
|
};
|
|
11
|
-
var y = (s, t, e) => (
|
|
11
|
+
var y = (s, t, e) => (nt(s, t, "read from private field"), e ? e.call(s) : t.get(s)), C = (s, t, e) => {
|
|
12
12
|
if (t.has(s))
|
|
13
13
|
throw TypeError("Cannot add the same private member more than once");
|
|
14
14
|
t instanceof WeakSet ? t.add(s) : t.set(s, e);
|
|
15
|
-
},
|
|
16
|
-
import { a as
|
|
17
|
-
import { a as
|
|
18
|
-
function
|
|
15
|
+
}, E = (s, t, e, i) => (nt(s, t, "write to private field"), i ? i.call(s, e) : t.set(s, e), e);
|
|
16
|
+
import { a as Be } from "./errors-7cbbda8a.js";
|
|
17
|
+
import { a as ot, v as Wt } from "./v4-58efbfa1.js";
|
|
18
|
+
function O(s, t) {
|
|
19
19
|
return (e, ...i) => {
|
|
20
20
|
console.log(`[%c${s}\x1B[m] %s`, t, e, ...i);
|
|
21
21
|
};
|
|
22
22
|
}
|
|
23
|
-
function
|
|
23
|
+
function xt(s, t) {
|
|
24
24
|
return Math.round(s * 100 / t);
|
|
25
25
|
}
|
|
26
|
-
class
|
|
26
|
+
class z {
|
|
27
27
|
constructor(t, e) {
|
|
28
|
-
|
|
29
|
-
|
|
28
|
+
m(this, "config");
|
|
29
|
+
m(this, "sdkConfig");
|
|
30
30
|
this.config = t, this.sdkConfig = e;
|
|
31
31
|
}
|
|
32
32
|
on(t, e, i) {
|
|
33
|
-
const
|
|
34
|
-
|
|
33
|
+
const a = function(n) {
|
|
34
|
+
n.data.message !== `kalamba:wrapper-casino:${t}` && n.data.message !== `kalamba:wrapper:${t}` || e(n.data.payload);
|
|
35
35
|
};
|
|
36
|
-
window.addEventListener("message",
|
|
36
|
+
window.addEventListener("message", a, i);
|
|
37
37
|
}
|
|
38
38
|
send(t, ...[e]) {
|
|
39
39
|
window.postMessage({
|
|
@@ -42,10 +42,10 @@ class j {
|
|
|
42
42
|
});
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
|
-
const
|
|
46
|
-
class
|
|
45
|
+
const $t = O("BasicPlugin", "color:#000000;font-weight:bold;");
|
|
46
|
+
class Oi extends z {
|
|
47
47
|
constructor(...t) {
|
|
48
|
-
super(...t), this.registerToSdkEvents(), this.registerFromSdkEvents(),
|
|
48
|
+
super(...t), this.registerToSdkEvents(), this.registerFromSdkEvents(), $t("configured");
|
|
49
49
|
}
|
|
50
50
|
registerToSdkEvents() {
|
|
51
51
|
window.addEventListener("message", (t) => {
|
|
@@ -56,8 +56,8 @@ class Di extends j {
|
|
|
56
56
|
this.send("settings", { music: i == null ? void 0 : i.musicEnabled, sounds: i == null ? void 0 : i.soundEnabled });
|
|
57
57
|
return;
|
|
58
58
|
case "doBalanceUpdate":
|
|
59
|
-
const { currency:
|
|
60
|
-
i.currency ===
|
|
59
|
+
const { currency: a, coinValueInCents: o } = this.sdkConfig.api;
|
|
60
|
+
i.currency === a && typeof i.balanceInCurrency == "number" ? this.send("balance", { balance: xt(i.balanceInCurrency, o) }) : (i.balanceInCoins, this.send("balance", { balance: i.balanceInCoins }));
|
|
61
61
|
return;
|
|
62
62
|
case "doGamePause":
|
|
63
63
|
this.send("freeze");
|
|
@@ -92,8 +92,8 @@ class Di extends j {
|
|
|
92
92
|
});
|
|
93
93
|
}
|
|
94
94
|
}
|
|
95
|
-
const
|
|
96
|
-
class
|
|
95
|
+
const v = O("▼ DebuggingPlugin IN ▼", "color:#444444;font-weight:bold;"), jt = O("▲ DebuggingPlugin OUT ▲", "color:#444444;font-weight:bold;");
|
|
96
|
+
class xi extends z {
|
|
97
97
|
constructor(...t) {
|
|
98
98
|
super(...t), this.registerDebugToSdkEvents(), this.registerSdkToDebugEvents();
|
|
99
99
|
}
|
|
@@ -114,16 +114,16 @@ class Ni extends j {
|
|
|
114
114
|
};
|
|
115
115
|
}
|
|
116
116
|
registerSdkToDebugEvents() {
|
|
117
|
-
this.on("autoplay", (t) =>
|
|
117
|
+
this.on("autoplay", (t) => v("autoplay", t)), this.on("balance", (t) => v("balance", t)), this.on("bet", (t) => v("bet", t)), this.on("cashier", (t) => v("cashier", t)), this.on("choice", (t) => v("choice", t)), this.on("close", (t) => v("close", t)), this.on("error", (t) => v("error", t)), this.on("loadEnd", (t) => v("loadEnd", t)), this.on("loadProgress", (t) => v("loadProgress", t)), this.on("loadStart", (t) => v("loadStart", t)), this.on("playCycleStart", (t) => v("playCycleStart", t)), this.on("playCycleEnd", (t) => v("playCycleEnd", t)), this.on("playEnd", (t) => v("playEnd", t)), this.on("playError", (t) => v("playError", t)), this.on("playReady", (t) => v("playReady", t)), this.on("playStart", (t) => v("playStart", t)), this.on("settings", (t) => v("settings", t));
|
|
118
118
|
}
|
|
119
119
|
_send(...t) {
|
|
120
|
-
|
|
120
|
+
jt(...t), this.send(...t);
|
|
121
121
|
}
|
|
122
122
|
}
|
|
123
|
-
const
|
|
124
|
-
class
|
|
123
|
+
const Qt = O("GigPlugin", "color:#000000;font-weight:bold;");
|
|
124
|
+
class Ri extends z {
|
|
125
125
|
constructor(...t) {
|
|
126
|
-
super(...t), this.registerToSdkEvents(), this.registerFromSdkEvents(),
|
|
126
|
+
super(...t), this.registerToSdkEvents(), this.registerFromSdkEvents(), Qt("configured");
|
|
127
127
|
}
|
|
128
128
|
postMessage(t) {
|
|
129
129
|
const e = {
|
|
@@ -171,10 +171,10 @@ class Gi extends j {
|
|
|
171
171
|
});
|
|
172
172
|
}
|
|
173
173
|
}
|
|
174
|
-
const
|
|
175
|
-
class
|
|
174
|
+
const Xt = O("OryxPlugin", "color:#000000;font-weight:bold;");
|
|
175
|
+
class Li extends z {
|
|
176
176
|
constructor(...t) {
|
|
177
|
-
super(...t), this.registerToSdkEvents(), this.registerFromSdkEvents(),
|
|
177
|
+
super(...t), this.registerToSdkEvents(), this.registerFromSdkEvents(), Xt("configured");
|
|
178
178
|
}
|
|
179
179
|
registerToSdkEvents() {
|
|
180
180
|
window.addEventListener("message", (t) => {
|
|
@@ -226,54 +226,54 @@ class Hi extends j {
|
|
|
226
226
|
});
|
|
227
227
|
}
|
|
228
228
|
}
|
|
229
|
-
const
|
|
230
|
-
function
|
|
229
|
+
const rt = O("PariplayPlugin", "color:#000000;font-weight:bold;");
|
|
230
|
+
function Ne(s) {
|
|
231
231
|
try {
|
|
232
232
|
window.top.location = s;
|
|
233
233
|
} catch {
|
|
234
234
|
window.location = s;
|
|
235
235
|
}
|
|
236
236
|
}
|
|
237
|
-
function
|
|
238
|
-
return new Promise(function(i,
|
|
237
|
+
function Ge(s, t) {
|
|
238
|
+
return new Promise(function(i, a) {
|
|
239
239
|
const o = new XMLHttpRequest();
|
|
240
240
|
o.onload = function() {
|
|
241
|
-
o.status >= 200 && o.status < 300 ? i(o.responseText) :
|
|
241
|
+
o.status >= 200 && o.status < 300 ? i(o.responseText) : a(o.responseText);
|
|
242
242
|
}, o.open(s, t), o.send();
|
|
243
243
|
});
|
|
244
244
|
}
|
|
245
|
-
function
|
|
245
|
+
function He() {
|
|
246
246
|
}
|
|
247
|
-
function
|
|
247
|
+
function Kt(s) {
|
|
248
248
|
return s.filter(function(e) {
|
|
249
249
|
return e.messageType.toUpperCase() === "DATA";
|
|
250
250
|
});
|
|
251
251
|
}
|
|
252
|
-
function
|
|
252
|
+
function Ve(s) {
|
|
253
253
|
return s.filter(function(e) {
|
|
254
254
|
return ["NOTIFICATION", "POPUP"].includes(e.messageType.toUpperCase());
|
|
255
255
|
});
|
|
256
256
|
}
|
|
257
|
-
function
|
|
257
|
+
function Rt(s) {
|
|
258
258
|
try {
|
|
259
259
|
return JSON.parse(s.text);
|
|
260
260
|
} catch {
|
|
261
261
|
return {};
|
|
262
262
|
}
|
|
263
263
|
}
|
|
264
|
-
function
|
|
265
|
-
return s.map(
|
|
264
|
+
function Jt(s) {
|
|
265
|
+
return s.map(Rt).filter(Boolean).find(function(e) {
|
|
266
266
|
return e.betId != null && e.winId != null;
|
|
267
267
|
}) || {};
|
|
268
268
|
}
|
|
269
|
-
function
|
|
270
|
-
return s.map(
|
|
269
|
+
function Yt(s) {
|
|
270
|
+
return s.map(Rt).filter(Boolean).find(function(e) {
|
|
271
271
|
return e.TotalBet != null && e.TotalWin != null;
|
|
272
272
|
}) || {};
|
|
273
273
|
}
|
|
274
|
-
class
|
|
274
|
+
class Ui extends z {
|
|
275
275
|
constructor(...t) {
|
|
276
|
-
super(...t), this.registerToSdkEvents(), this.registerFromSdkEvents(),
|
|
276
|
+
super(...t), this.registerToSdkEvents(), this.registerFromSdkEvents(), rt("configured");
|
|
277
277
|
}
|
|
278
278
|
postMessage(t, e) {
|
|
279
279
|
const i = {
|
|
@@ -281,26 +281,26 @@ class Vi extends j {
|
|
|
281
281
|
sender: this.sdkConfig.api.game,
|
|
282
282
|
type: t
|
|
283
283
|
};
|
|
284
|
-
e != null && (i.data = e),
|
|
284
|
+
e != null && (i.data = e), rt("postMessage", i), window.parent.postMessage(i, "*");
|
|
285
285
|
}
|
|
286
286
|
coinsToCurrency(t) {
|
|
287
287
|
return t * this.sdkConfig.api.coinValueInCents / 100;
|
|
288
288
|
}
|
|
289
289
|
handleContinueButton(t, e) {
|
|
290
|
-
t.link &&
|
|
290
|
+
t.link && Ge("GET", t.link), e();
|
|
291
291
|
}
|
|
292
292
|
handleLinkButton(t, e) {
|
|
293
293
|
switch (t.linkType.toUpperCase()) {
|
|
294
294
|
case "AJAX":
|
|
295
|
-
|
|
295
|
+
Ge("GET", t.link), e();
|
|
296
296
|
return;
|
|
297
297
|
case "AJAXRESPONSE":
|
|
298
|
-
|
|
298
|
+
Ge("GET", t.link).then(() => {
|
|
299
299
|
e();
|
|
300
300
|
});
|
|
301
301
|
return;
|
|
302
302
|
case "REDIRECT":
|
|
303
|
-
|
|
303
|
+
Ne(t.link), e();
|
|
304
304
|
return;
|
|
305
305
|
}
|
|
306
306
|
}
|
|
@@ -323,17 +323,17 @@ class Vi extends j {
|
|
|
323
323
|
};
|
|
324
324
|
}
|
|
325
325
|
processInfoUiMessages(t) {
|
|
326
|
-
return t.reduce((e, i) => e.then(() => new Promise((
|
|
326
|
+
return t.reduce((e, i) => e.then(() => new Promise((a) => {
|
|
327
327
|
Object.assign({}, i, {
|
|
328
328
|
buttons: i.buttons.filter((o) => o.action.toUpperCase() === "CASHIER" ? !!this.sdkConfig.api.cashierUrl : !0).map((o) => Object.assign({}, o, {
|
|
329
329
|
onRelease: () => {
|
|
330
|
-
const
|
|
331
|
-
h ? h(o,
|
|
330
|
+
const n = i.messageType.toUpperCase() === "POPUP" ? He : a, h = this.buttonActions[o.action.toUpperCase()];
|
|
331
|
+
h ? h(o, n) : n();
|
|
332
332
|
}
|
|
333
333
|
}))
|
|
334
334
|
});
|
|
335
|
-
}).catch(
|
|
336
|
-
}).catch(
|
|
335
|
+
}).catch(He)), Promise.resolve()).then(() => {
|
|
336
|
+
}).catch(He);
|
|
337
337
|
}
|
|
338
338
|
registerToSdkEvents() {
|
|
339
339
|
window.addEventListener("message", (t) => {
|
|
@@ -363,13 +363,13 @@ class Vi extends j {
|
|
|
363
363
|
this.on("openGameResponse", (e) => {
|
|
364
364
|
let i;
|
|
365
365
|
try {
|
|
366
|
-
const
|
|
366
|
+
const a = JSON.parse(
|
|
367
367
|
JSON.parse(atob(this.sdkConfig.api.integrationData.token.split(".")[1])).token
|
|
368
|
-
), o = JSON.parse(
|
|
368
|
+
), o = JSON.parse(a.integrationSpecificAttributes.sessionData || "{}");
|
|
369
369
|
i = {
|
|
370
|
-
ClientToken:
|
|
371
|
-
CurrencyCode:
|
|
372
|
-
PlayerTokenId:
|
|
370
|
+
ClientToken: a.integrationSpecificAttributes.clientToken,
|
|
371
|
+
CurrencyCode: a.currency,
|
|
372
|
+
PlayerTokenId: a.user,
|
|
373
373
|
SessionData: o
|
|
374
374
|
};
|
|
375
375
|
} catch {
|
|
@@ -380,8 +380,8 @@ class Vi extends j {
|
|
|
380
380
|
success: !0
|
|
381
381
|
});
|
|
382
382
|
try {
|
|
383
|
-
const
|
|
384
|
-
this.processInfoUiMessages(
|
|
383
|
+
const a = Ve(e.contract.uiMessages);
|
|
384
|
+
this.processInfoUiMessages(a);
|
|
385
385
|
} catch {
|
|
386
386
|
}
|
|
387
387
|
}), this.on("balance", ({ balance: e }) => {
|
|
@@ -397,25 +397,25 @@ class Vi extends j {
|
|
|
397
397
|
window.history.back();
|
|
398
398
|
}
|
|
399
399
|
else
|
|
400
|
-
this.sdkConfig.api.homeUrl === "(api)" ? this.postMessage("quit") :
|
|
400
|
+
this.sdkConfig.api.homeUrl === "(api)" ? this.postMessage("quit") : Ne(this.sdkConfig.api.homeUrl);
|
|
401
401
|
}), this.on("playEnd", (e) => {
|
|
402
402
|
this.postMessage("roundEnded", {
|
|
403
403
|
balanceAfter: this.coinsToCurrency(e.contract.balance.coins),
|
|
404
404
|
win: this.coinsToCurrency(e.contract.win.round)
|
|
405
405
|
});
|
|
406
406
|
try {
|
|
407
|
-
const i =
|
|
407
|
+
const i = Ve(e.contract.uiMessages);
|
|
408
408
|
this.processInfoUiMessages(i);
|
|
409
409
|
} catch {
|
|
410
410
|
}
|
|
411
411
|
}), this.on("playError", (e) => {
|
|
412
|
-
var i,
|
|
412
|
+
var i, a;
|
|
413
413
|
this.postMessage("ticketReceived", {
|
|
414
414
|
// TODO: Operator specific error code and message
|
|
415
415
|
ErrorCode: (i = e.data) == null ? void 0 : i.code,
|
|
416
416
|
ErrorMessage: "ERROR",
|
|
417
417
|
Status: {
|
|
418
|
-
ErrCode: (
|
|
418
|
+
ErrCode: (a = e.data) == null ? void 0 : a.code
|
|
419
419
|
}
|
|
420
420
|
});
|
|
421
421
|
}), this.on("playResponse", (e) => {
|
|
@@ -424,12 +424,12 @@ class Vi extends j {
|
|
|
424
424
|
e.contract.balance.coins + e.contract.bet.lastPaid.base * e.contract.bet.lastPaid.multiplier
|
|
425
425
|
)
|
|
426
426
|
});
|
|
427
|
-
const i = ["BaseGame", "PaidSpin"].includes(e.contract.stateType.thisRound),
|
|
427
|
+
const i = ["BaseGame", "PaidSpin"].includes(e.contract.stateType.thisRound), a = Kt(e.contract.uiMessages), o = Ve(e.contract.uiMessages), n = Jt(a), h = Yt(a);
|
|
428
428
|
this.postMessage("ticketReceived", {
|
|
429
429
|
Balance: this.coinsToCurrency(e.contract.balance.coins),
|
|
430
430
|
BetAmount: i ? this.coinsToCurrency(e.contract.bet.lastPaid.base * e.contract.bet.lastPaid.multiplier) : 0,
|
|
431
|
-
CreditTransactionId:
|
|
432
|
-
DebitTransactionId:
|
|
431
|
+
CreditTransactionId: n.betId,
|
|
432
|
+
DebitTransactionId: n.winId,
|
|
433
433
|
Message: o,
|
|
434
434
|
SessionData: h,
|
|
435
435
|
Status: {
|
|
@@ -446,18 +446,18 @@ class Vi extends j {
|
|
|
446
446
|
}), this.on("loadStart", () => {
|
|
447
447
|
this.postMessage("onAppFrameReady");
|
|
448
448
|
}), this.on("cashier", () => {
|
|
449
|
-
this.sdkConfig.api.cashierUrl && (this.sdkConfig.api.cashierUrl === "(api)" ? this.postMessage("cashier") :
|
|
449
|
+
this.sdkConfig.api.cashierUrl && (this.sdkConfig.api.cashierUrl === "(api)" ? this.postMessage("cashier") : Ne(this.sdkConfig.api.cashierUrl));
|
|
450
450
|
});
|
|
451
451
|
}
|
|
452
452
|
}
|
|
453
|
-
const
|
|
454
|
-
class
|
|
453
|
+
const ue = O("RelaxFEIMPlugin", "color:#000000;font-weight:bold;");
|
|
454
|
+
class _i extends z {
|
|
455
455
|
constructor(...e) {
|
|
456
456
|
super(...e);
|
|
457
|
-
|
|
457
|
+
m(this, "VERSION", "1.17.0");
|
|
458
458
|
const i = document.createElement("script");
|
|
459
459
|
i.src = `https://d3nsdzdtjbr5ml.cloudfront.net/casino/relaxlibs/feim/${this.VERSION}/rlxfeim.min.js`, i.onload = () => {
|
|
460
|
-
|
|
460
|
+
ue("loaded"), window.FEIM.configure({
|
|
461
461
|
p2pConfig: {
|
|
462
462
|
currency: this.sdkConfig.api.currency,
|
|
463
463
|
launchParams: {
|
|
@@ -465,11 +465,11 @@ class zi extends j {
|
|
|
465
465
|
homeurl: "homeUrl"
|
|
466
466
|
}
|
|
467
467
|
}
|
|
468
|
-
}),
|
|
468
|
+
}), ue("configured"), this.registerToSdkEvents(), this.registerFromSdkEvents();
|
|
469
469
|
}, document.body.appendChild(i);
|
|
470
470
|
}
|
|
471
471
|
registerToSdkEvents() {
|
|
472
|
-
window.FEIM.on.errorMessageDismissed(() => this.send("unfreeze")), window.FEIM.on.errorMessageDisplayed(() => this.send("freeze")), window.FEIM.on.exitingGame(() =>
|
|
472
|
+
window.FEIM.on.errorMessageDismissed(() => this.send("unfreeze")), window.FEIM.on.errorMessageDisplayed(() => this.send("freeze")), window.FEIM.on.exitingGame(() => ue("!!! NOT IMPLEMENTED: exitingGame !!!")), window.FEIM.on.freeze(() => this.send("freeze")), window.FEIM.on.initialized(() => ue("!!! NOT IMPLEMENTED: initialized !!!")), window.FEIM.on.pauseAutoPlay(() => this.send("suspend")), window.FEIM.on.refreshBalance(() => ue("!!! NOT IMPLEMENTED: refreshBalance !!!")), window.FEIM.on.toggleGameHelp(() => {
|
|
473
473
|
this.send("help", {});
|
|
474
474
|
}), window.FEIM.on.togglePaytable(() => {
|
|
475
475
|
this.send("paytable", {});
|
|
@@ -525,33 +525,33 @@ class zi extends j {
|
|
|
525
525
|
});
|
|
526
526
|
}
|
|
527
527
|
}
|
|
528
|
-
const
|
|
529
|
-
class
|
|
528
|
+
const ze = O("TukoPlugin", "color:#000000;font-weight:bold;");
|
|
529
|
+
class Bi extends z {
|
|
530
530
|
constructor(...e) {
|
|
531
531
|
super(...e);
|
|
532
|
-
|
|
533
|
-
const
|
|
534
|
-
|
|
535
|
-
this.ping(
|
|
536
|
-
}, this.PING_INTERVAL), this.registerToSdkEvents(), this.registerFromSdkEvents(),
|
|
532
|
+
m(this, "PING_INTERVAL", 1e4);
|
|
533
|
+
const a = new URLSearchParams(window.location.search).get("pingCallbackUrl");
|
|
534
|
+
a && window.setInterval(() => {
|
|
535
|
+
this.ping(a);
|
|
536
|
+
}, this.PING_INTERVAL), this.registerToSdkEvents(), this.registerFromSdkEvents(), ze("configured");
|
|
537
537
|
}
|
|
538
538
|
ping(e) {
|
|
539
539
|
const i = new XMLHttpRequest();
|
|
540
540
|
i.onreadystatechange = function() {
|
|
541
|
-
i.readyState === XMLHttpRequest.DONE && (i.status === 0 || i.status >= 200 && i.status < 400 ?
|
|
541
|
+
i.readyState === XMLHttpRequest.DONE && (i.status === 0 || i.status >= 200 && i.status < 400 ? ze("ping ok", i) : ze("ping error", i));
|
|
542
542
|
}, i.open("GET", e), i.send();
|
|
543
543
|
}
|
|
544
544
|
registerToSdkEvents() {
|
|
545
545
|
window.addEventListener("message", (e) => {
|
|
546
546
|
try {
|
|
547
|
-
const { type: i, payload:
|
|
547
|
+
const { type: i, payload: a } = e.data;
|
|
548
548
|
switch (i) {
|
|
549
549
|
case "doAudioSettings":
|
|
550
|
-
this.send("settings", { music:
|
|
550
|
+
this.send("settings", { music: a == null ? void 0 : a.musicEnabled, sounds: a == null ? void 0 : a.soundEnabled });
|
|
551
551
|
return;
|
|
552
552
|
case "doBalanceUpdate":
|
|
553
|
-
const { currency: o, coinValueInCents:
|
|
554
|
-
|
|
553
|
+
const { currency: o, coinValueInCents: n } = this.sdkConfig.api;
|
|
554
|
+
a.currency === o && typeof a.balanceInCurrency == "number" ? this.send("balance", { balance: xt(a.balanceInCurrency, n) }) : (a.balanceInCoins, this.send("balance", { balance: a.balanceInCoins }));
|
|
555
555
|
return;
|
|
556
556
|
case "doGamePause":
|
|
557
557
|
this.send("freeze");
|
|
@@ -586,81 +586,104 @@ class qi extends j {
|
|
|
586
586
|
});
|
|
587
587
|
}
|
|
588
588
|
}
|
|
589
|
-
|
|
589
|
+
const ct = O("QuantaPlugin", "color:#000000;font-weight:bold;");
|
|
590
|
+
class Fi extends z {
|
|
591
|
+
constructor(...t) {
|
|
592
|
+
super(...t), this.registerFromSdkEvents(), ct("configured");
|
|
593
|
+
}
|
|
594
|
+
postMessage(t) {
|
|
595
|
+
const e = { event: t };
|
|
596
|
+
ct("QuantaPlugin::postMessage", e), window.parent.postMessage(e, "*");
|
|
597
|
+
}
|
|
598
|
+
registerFromSdkEvents() {
|
|
599
|
+
this.on("close", () => {
|
|
600
|
+
this.postMessage("GameClosed");
|
|
601
|
+
}), this.on("loadEnd", () => {
|
|
602
|
+
this.postMessage("GameLoaded");
|
|
603
|
+
}), this.on("playCycleStart", () => {
|
|
604
|
+
this.postMessage("RoundStarted");
|
|
605
|
+
}), this.on("playCycleEnd", () => {
|
|
606
|
+
this.postMessage("RoundEnded");
|
|
607
|
+
}), this.on("playError", () => {
|
|
608
|
+
this.postMessage("RoundEnded");
|
|
609
|
+
});
|
|
610
|
+
}
|
|
611
|
+
}
|
|
612
|
+
var Zt = "2.0.0-beta.3", re = "", dt = "?", Ke = "function", H = "undefined", ce = "object", Je = "string", we = "major", l = "model", r = "name", d = "type", u = "vendor", c = "version", M = "architecture", J = "console", b = "mobile", f = "tablet", I = "smarttv", Pe = "wearable", lt = "xr", Ye = "embedded", ut = "user-agent", Ze = 500, it = "brands", W = "formFactors", st = "fullVersionList", Y = "platform", at = "platformVersion", Fe = "bitness", q = "sec-ch-ua", ei = q + "-full-version-list", ti = q + "-arch", ii = q + "-" + Fe, si = q + "-form-factors", ai = q + "-" + b, ni = q + "-" + l, Lt = q + "-" + Y, oi = Lt + "-version", Ut = [it, st, b, l, Y, at, M, W, Fe], T = "browser", _ = "cpu", x = "device", B = "engine", P = "os", Z = "result", Ee = "Amazon", he = "Apple", ht = "ASUS", pt = "BlackBerry", ve = "Google", gt = "Huawei", mt = "Lenovo", qe = "LG", Ae = "Microsoft", wt = "Motorola", Ce = "Samsung", bt = "Sharp", Me = "Sony", We = "Xiaomi", $e = "Zebra", X = "Mobile ", K = " Browser", Se = "Chrome", ri = "Edge", pe = "Firefox", ge = "Opera", ft = "Facebook", yt = "Sogou", et = "Windows", ci = typeof window !== H, S = ci && window.navigator ? window.navigator : void 0, N = S && S.userAgentData ? S.userAgentData : void 0, di = function(s, t) {
|
|
590
613
|
var e = {}, i = t;
|
|
591
|
-
if (!
|
|
614
|
+
if (!Oe(t)) {
|
|
592
615
|
i = {};
|
|
593
|
-
for (var
|
|
594
|
-
for (var o in t[
|
|
595
|
-
i[o] = t[
|
|
616
|
+
for (var a in t)
|
|
617
|
+
for (var o in t[a])
|
|
618
|
+
i[o] = t[a][o].concat(i[o] ? i[o] : []);
|
|
596
619
|
}
|
|
597
|
-
for (var
|
|
598
|
-
e[
|
|
620
|
+
for (var n in s)
|
|
621
|
+
e[n] = i[n] && i[n].length % 2 === 0 ? i[n].concat(s[n]) : s[n];
|
|
599
622
|
return e;
|
|
600
|
-
},
|
|
623
|
+
}, De = function(s) {
|
|
601
624
|
for (var t = {}, e = 0; e < s.length; e++)
|
|
602
625
|
t[s[e].toUpperCase()] = s[e];
|
|
603
626
|
return t;
|
|
604
|
-
},
|
|
605
|
-
if (typeof s ===
|
|
627
|
+
}, tt = function(s, t) {
|
|
628
|
+
if (typeof s === ce && s.length > 0) {
|
|
606
629
|
for (var e in s)
|
|
607
|
-
if (
|
|
630
|
+
if (V(s[e]) == V(t))
|
|
608
631
|
return !0;
|
|
609
632
|
return !1;
|
|
610
633
|
}
|
|
611
|
-
return
|
|
612
|
-
},
|
|
634
|
+
return de(s) ? V(t).indexOf(V(s)) !== -1 : !1;
|
|
635
|
+
}, Oe = function(s, t) {
|
|
613
636
|
for (var e in s)
|
|
614
|
-
return /^(browser|cpu|device|engine|os)$/.test(e) || (t ?
|
|
615
|
-
},
|
|
616
|
-
return typeof s ===
|
|
617
|
-
},
|
|
637
|
+
return /^(browser|cpu|device|engine|os)$/.test(e) || (t ? Oe(s[e]) : !1);
|
|
638
|
+
}, de = function(s) {
|
|
639
|
+
return typeof s === Je;
|
|
640
|
+
}, je = function(s) {
|
|
618
641
|
if (s) {
|
|
619
642
|
for (var t = [], e = $(/\\?\"/g, s).split(","), i = 0; i < e.length; i++)
|
|
620
643
|
if (e[i].indexOf(";") > -1) {
|
|
621
|
-
var
|
|
622
|
-
t[i] = { brand:
|
|
644
|
+
var a = be(e[i]).split(";v=");
|
|
645
|
+
t[i] = { brand: a[0], version: a[1] };
|
|
623
646
|
} else
|
|
624
|
-
t[i] =
|
|
647
|
+
t[i] = be(e[i]);
|
|
625
648
|
return t;
|
|
626
649
|
}
|
|
627
|
-
},
|
|
628
|
-
return
|
|
629
|
-
},
|
|
630
|
-
return
|
|
631
|
-
},
|
|
650
|
+
}, V = function(s) {
|
|
651
|
+
return de(s) ? s.toLowerCase() : s;
|
|
652
|
+
}, Qe = function(s) {
|
|
653
|
+
return de(s) ? $(/[^\d\.]/g, s).split(".")[0] : void 0;
|
|
654
|
+
}, F = function(s) {
|
|
632
655
|
for (var t in s) {
|
|
633
656
|
var e = s[t];
|
|
634
|
-
typeof e ==
|
|
657
|
+
typeof e == ce && e.length == 2 ? this[e[0]] = e[1] : this[e] = void 0;
|
|
635
658
|
}
|
|
636
659
|
return this;
|
|
637
660
|
}, $ = function(s, t) {
|
|
638
|
-
return
|
|
639
|
-
},
|
|
661
|
+
return de(t) ? t.replace(s, re) : t;
|
|
662
|
+
}, me = function(s) {
|
|
640
663
|
return $(/\\?\"/g, s);
|
|
641
|
-
},
|
|
642
|
-
if (
|
|
643
|
-
return s = $(/^\s\s*/, s), typeof t ===
|
|
644
|
-
},
|
|
664
|
+
}, be = function(s, t) {
|
|
665
|
+
if (de(s))
|
|
666
|
+
return s = $(/^\s\s*/, s), typeof t === H ? s : s.substring(0, Ze);
|
|
667
|
+
}, kt = function(s, t) {
|
|
645
668
|
if (!(!s || !t))
|
|
646
|
-
for (var e = 0, i,
|
|
647
|
-
var
|
|
648
|
-
for (i =
|
|
649
|
-
if (h =
|
|
650
|
-
for (o = 0; o <
|
|
651
|
-
p = h[++
|
|
669
|
+
for (var e = 0, i, a, o, n, h, p; e < t.length && !h; ) {
|
|
670
|
+
var w = t[e], g = t[e + 1];
|
|
671
|
+
for (i = a = 0; i < w.length && !h && w[i]; )
|
|
672
|
+
if (h = w[i++].exec(s), h)
|
|
673
|
+
for (o = 0; o < g.length; o++)
|
|
674
|
+
p = h[++a], n = g[o], typeof n === ce && n.length > 0 ? n.length === 2 ? typeof n[1] == Ke ? this[n[0]] = n[1].call(this, p) : this[n[0]] = n[1] : n.length === 3 ? typeof n[1] === Ke && !(n[1].exec && n[1].test) ? this[n[0]] = p ? n[1].call(this, p, n[2]) : void 0 : this[n[0]] = p ? p.replace(n[1], n[2]) : void 0 : n.length === 4 && (this[n[0]] = p ? n[3].call(this, p.replace(n[1], n[2])) : void 0) : this[n] = p || void 0;
|
|
652
675
|
e += 2;
|
|
653
676
|
}
|
|
654
|
-
},
|
|
677
|
+
}, xe = function(s, t) {
|
|
655
678
|
for (var e in t)
|
|
656
|
-
if (typeof t[e] ===
|
|
679
|
+
if (typeof t[e] === ce && t[e].length > 0) {
|
|
657
680
|
for (var i = 0; i < t[e].length; i++)
|
|
658
|
-
if (
|
|
659
|
-
return e ===
|
|
660
|
-
} else if (
|
|
661
|
-
return e ===
|
|
681
|
+
if (tt(t[e][i], s))
|
|
682
|
+
return e === dt ? void 0 : e;
|
|
683
|
+
} else if (tt(t[e], s))
|
|
684
|
+
return e === dt ? void 0 : e;
|
|
662
685
|
return t.hasOwnProperty("*") ? t["*"] : s;
|
|
663
|
-
},
|
|
686
|
+
}, Et = {
|
|
664
687
|
ME: "4.90",
|
|
665
688
|
"NT 3.11": "NT3.51",
|
|
666
689
|
"NT 4.0": "NT4.0",
|
|
@@ -672,7 +695,7 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
672
695
|
"8.1": "NT 6.3",
|
|
673
696
|
10: ["NT 6.4", "NT 10.0"],
|
|
674
697
|
RT: "ARM"
|
|
675
|
-
},
|
|
698
|
+
}, vt = {
|
|
676
699
|
embedded: "Automotive",
|
|
677
700
|
mobile: "Mobile",
|
|
678
701
|
tablet: ["Tablet", "EInk"],
|
|
@@ -681,14 +704,14 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
681
704
|
xr: ["VR", "XR"],
|
|
682
705
|
"?": ["Desktop", "Unknown"],
|
|
683
706
|
"*": void 0
|
|
684
|
-
},
|
|
707
|
+
}, Ct = {
|
|
685
708
|
browser: [
|
|
686
709
|
[
|
|
687
710
|
// Most common regardless engine
|
|
688
711
|
/\b(?:crmo|crios)\/([\w\.]+)/i
|
|
689
712
|
// Chrome for Android/iOS
|
|
690
713
|
],
|
|
691
|
-
[c, [r,
|
|
714
|
+
[c, [r, X + "Chrome"]],
|
|
692
715
|
[
|
|
693
716
|
/edg(?:e|ios|a)?\/([\w\.]+)/i
|
|
694
717
|
// Microsoft Edge
|
|
@@ -708,17 +731,17 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
708
731
|
/opios[\/ ]+([\w\.]+)/i
|
|
709
732
|
// Opera mini on iphone >= 8.0
|
|
710
733
|
],
|
|
711
|
-
[c, [r,
|
|
734
|
+
[c, [r, ge + " Mini"]],
|
|
712
735
|
[
|
|
713
736
|
/\bop(?:rg)?x\/([\w\.]+)/i
|
|
714
737
|
// Opera GX
|
|
715
738
|
],
|
|
716
|
-
[c, [r,
|
|
739
|
+
[c, [r, ge + " GX"]],
|
|
717
740
|
[
|
|
718
741
|
/\bopr\/([\w\.]+)/i
|
|
719
742
|
// Opera Webkit
|
|
720
743
|
],
|
|
721
|
-
[c, [r,
|
|
744
|
+
[c, [r, ge]],
|
|
722
745
|
[
|
|
723
746
|
// Mixed
|
|
724
747
|
/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i
|
|
@@ -781,22 +804,22 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
781
804
|
/slbrowser\/([\w\.]+)/i
|
|
782
805
|
// Smart Lenovo Browser
|
|
783
806
|
],
|
|
784
|
-
[c, [r, "Smart " +
|
|
807
|
+
[c, [r, "Smart " + mt + K]],
|
|
785
808
|
[
|
|
786
809
|
/(avast|avg)\/([\w\.]+)/i
|
|
787
810
|
// Avast/AVG Secure Browser
|
|
788
811
|
],
|
|
789
|
-
[[r, /(.+)/, "$1 Secure" +
|
|
812
|
+
[[r, /(.+)/, "$1 Secure" + K], c],
|
|
790
813
|
[
|
|
791
814
|
/\bfocus\/([\w\.]+)/i
|
|
792
815
|
// Firefox Focus
|
|
793
816
|
],
|
|
794
|
-
[c, [r,
|
|
817
|
+
[c, [r, pe + " Focus"]],
|
|
795
818
|
[
|
|
796
819
|
/\bopt\/([\w\.]+)/i
|
|
797
820
|
// Opera Touch
|
|
798
821
|
],
|
|
799
|
-
[c, [r,
|
|
822
|
+
[c, [r, ge + " Touch"]],
|
|
800
823
|
[
|
|
801
824
|
/coc_coc\w+\/([\w\.]+)/i
|
|
802
825
|
// Coc Coc Browser
|
|
@@ -811,22 +834,22 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
811
834
|
/coast\/([\w\.]+)/i
|
|
812
835
|
// Opera Coast
|
|
813
836
|
],
|
|
814
|
-
[c, [r,
|
|
837
|
+
[c, [r, ge + " Coast"]],
|
|
815
838
|
[
|
|
816
839
|
/miuibrowser\/([\w\.]+)/i
|
|
817
840
|
// MIUI Browser
|
|
818
841
|
],
|
|
819
|
-
[c, [r, "MIUI" +
|
|
842
|
+
[c, [r, "MIUI" + K]],
|
|
820
843
|
[
|
|
821
844
|
/fxios\/([\w\.-]+)/i
|
|
822
845
|
// Firefox for iOS
|
|
823
846
|
],
|
|
824
|
-
[c, [r,
|
|
847
|
+
[c, [r, X + pe]],
|
|
825
848
|
[
|
|
826
849
|
/\bqihu|(qi?ho?o?|360)browser/i
|
|
827
850
|
// 360
|
|
828
851
|
],
|
|
829
|
-
[[r, "360" +
|
|
852
|
+
[[r, "360" + K]],
|
|
830
853
|
[
|
|
831
854
|
/\b(qq)\/([\w\.]+)/i
|
|
832
855
|
// QQ
|
|
@@ -835,13 +858,13 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
835
858
|
[
|
|
836
859
|
/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i
|
|
837
860
|
],
|
|
838
|
-
[[r, /(.+)/, "$1" +
|
|
861
|
+
[[r, /(.+)/, "$1" + K], c],
|
|
839
862
|
[
|
|
840
863
|
// Oculus/Sailfish/HuaweiBrowser/VivoBrowser/PicoBrowser
|
|
841
864
|
/samsungbrowser\/([\w\.]+)/i
|
|
842
865
|
// Samsung Internet
|
|
843
866
|
],
|
|
844
|
-
[c, [r,
|
|
867
|
+
[c, [r, Ce + " Internet"]],
|
|
845
868
|
[
|
|
846
869
|
/(comodo_dragon)\/([\w\.]+)/i
|
|
847
870
|
// Comodo Dragon
|
|
@@ -851,12 +874,12 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
851
874
|
/metasr[\/ ]?([\d\.]+)/i
|
|
852
875
|
// Sogou Explorer
|
|
853
876
|
],
|
|
854
|
-
[c, [r,
|
|
877
|
+
[c, [r, yt + " Explorer"]],
|
|
855
878
|
[
|
|
856
879
|
/(sogou)mo\w+\/([\d\.]+)/i
|
|
857
880
|
// Sogou Mobile
|
|
858
881
|
],
|
|
859
|
-
[[r,
|
|
882
|
+
[[r, yt + " Mobile"], c],
|
|
860
883
|
[
|
|
861
884
|
/(electron)\/([\w\.]+) safari/i,
|
|
862
885
|
// Electron-based App
|
|
@@ -878,7 +901,7 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
878
901
|
/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i
|
|
879
902
|
// Facebook App for iOS & Android
|
|
880
903
|
],
|
|
881
|
-
[[r,
|
|
904
|
+
[[r, ft], c],
|
|
882
905
|
[
|
|
883
906
|
/(Klarna)\/([\w\.]+)/i,
|
|
884
907
|
// Klarna Shopping Browser for iOS & Android
|
|
@@ -912,22 +935,22 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
912
935
|
/headlesschrome(?:\/([\w\.]+)| )/i
|
|
913
936
|
// Chrome Headless
|
|
914
937
|
],
|
|
915
|
-
[c, [r,
|
|
938
|
+
[c, [r, Se + " Headless"]],
|
|
916
939
|
[
|
|
917
940
|
/ wv\).+(chrome)\/([\w\.]+)/i
|
|
918
941
|
// Chrome WebView
|
|
919
942
|
],
|
|
920
|
-
[[r,
|
|
943
|
+
[[r, Se + " WebView"], c],
|
|
921
944
|
[
|
|
922
945
|
/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i
|
|
923
946
|
// Android Browser
|
|
924
947
|
],
|
|
925
|
-
[c, [r, "Android" +
|
|
948
|
+
[c, [r, "Android" + K]],
|
|
926
949
|
[
|
|
927
950
|
/chrome\/([\w\.]+) mobile/i
|
|
928
951
|
// Chrome Mobile
|
|
929
952
|
],
|
|
930
|
-
[c, [r,
|
|
953
|
+
[c, [r, X + "Chrome"]],
|
|
931
954
|
[
|
|
932
955
|
/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i
|
|
933
956
|
// Chrome/OmniWeb/Arora/Tizen/Nokia
|
|
@@ -937,11 +960,11 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
937
960
|
/version\/([\w\.\,]+) .*mobile(?:\/\w+ | ?)safari/i
|
|
938
961
|
// Safari Mobile
|
|
939
962
|
],
|
|
940
|
-
[c, [r,
|
|
963
|
+
[c, [r, X + "Safari"]],
|
|
941
964
|
[
|
|
942
965
|
/iphone .*mobile(?:\/\w+ | ?)safari/i
|
|
943
966
|
],
|
|
944
|
-
[[r,
|
|
967
|
+
[[r, X + "Safari"]],
|
|
945
968
|
[
|
|
946
969
|
/version\/([\w\.\,]+) .*(safari)/i
|
|
947
970
|
// Safari
|
|
@@ -961,7 +984,7 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
961
984
|
/(?:mobile|tablet);.*(firefox)\/([\w\.-]+)/i
|
|
962
985
|
// Firefox Mobile
|
|
963
986
|
],
|
|
964
|
-
[[r,
|
|
987
|
+
[[r, X + pe], c],
|
|
965
988
|
[
|
|
966
989
|
/(navigator|netscape\d?)\/([-\w\.]+)/i
|
|
967
990
|
// Netscape
|
|
@@ -976,7 +999,7 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
976
999
|
/mobile vr; rv:([\w\.]+)\).+firefox/i
|
|
977
1000
|
// Firefox Reality
|
|
978
1001
|
],
|
|
979
|
-
[c, [r,
|
|
1002
|
+
[c, [r, pe + " Reality"]],
|
|
980
1003
|
[
|
|
981
1004
|
/ekiohf.+(flow)\/([\w\.]+)/i,
|
|
982
1005
|
// Flow
|
|
@@ -1001,51 +1024,51 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1001
1024
|
/(cobalt)\/([\w\.]+)/i
|
|
1002
1025
|
// Cobalt
|
|
1003
1026
|
],
|
|
1004
|
-
[r, [c, /[^\d\.]+./,
|
|
1027
|
+
[r, [c, /[^\d\.]+./, re]]
|
|
1005
1028
|
],
|
|
1006
1029
|
cpu: [
|
|
1007
1030
|
[
|
|
1008
1031
|
/\b(?:(amd|x|x86[-_]?|wow|win)64)\b/i
|
|
1009
1032
|
// AMD64 (x64)
|
|
1010
1033
|
],
|
|
1011
|
-
[[
|
|
1034
|
+
[[M, "amd64"]],
|
|
1012
1035
|
[
|
|
1013
1036
|
/(ia32(?=;))/i,
|
|
1014
1037
|
// IA32 (quicktime)
|
|
1015
1038
|
/((?:i[346]|x)86)[;\)]/i
|
|
1016
1039
|
// IA32 (x86)
|
|
1017
1040
|
],
|
|
1018
|
-
[[
|
|
1041
|
+
[[M, "ia32"]],
|
|
1019
1042
|
[
|
|
1020
1043
|
/\b(aarch64|arm(v?8e?l?|_?64))\b/i
|
|
1021
1044
|
// ARM64
|
|
1022
1045
|
],
|
|
1023
|
-
[[
|
|
1046
|
+
[[M, "arm64"]],
|
|
1024
1047
|
[
|
|
1025
1048
|
/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i
|
|
1026
1049
|
// ARMHF
|
|
1027
1050
|
],
|
|
1028
|
-
[[
|
|
1051
|
+
[[M, "armhf"]],
|
|
1029
1052
|
[
|
|
1030
1053
|
// PocketPC mistakenly identified as PowerPC
|
|
1031
1054
|
/windows (ce|mobile); ppc;/i
|
|
1032
1055
|
],
|
|
1033
|
-
[[
|
|
1056
|
+
[[M, "arm"]],
|
|
1034
1057
|
[
|
|
1035
1058
|
/((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i
|
|
1036
1059
|
// PowerPC
|
|
1037
1060
|
],
|
|
1038
|
-
[[
|
|
1061
|
+
[[M, /ower/, re, V]],
|
|
1039
1062
|
[
|
|
1040
1063
|
/(sun4\w)[;\)]/i
|
|
1041
1064
|
// SPARC
|
|
1042
1065
|
],
|
|
1043
|
-
[[
|
|
1066
|
+
[[M, "sparc"]],
|
|
1044
1067
|
[
|
|
1045
1068
|
/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i
|
|
1046
1069
|
// IA64, 68K, ARM/64, AVR/32, IRIX/64, MIPS/64, SPARC/64, PA-RISC
|
|
1047
1070
|
],
|
|
1048
|
-
[[
|
|
1071
|
+
[[M, V]]
|
|
1049
1072
|
],
|
|
1050
1073
|
device: [
|
|
1051
1074
|
[
|
|
@@ -1055,45 +1078,45 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1055
1078
|
// Samsung
|
|
1056
1079
|
/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i
|
|
1057
1080
|
],
|
|
1058
|
-
[l, [u,
|
|
1081
|
+
[l, [u, Ce], [d, f]],
|
|
1059
1082
|
[
|
|
1060
1083
|
/\b((?:s[cgp]h|gt|sm)-\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,
|
|
1061
1084
|
/samsung[- ]([-\w]+)/i,
|
|
1062
1085
|
/sec-(sgh\w+)/i
|
|
1063
1086
|
],
|
|
1064
|
-
[l, [u,
|
|
1087
|
+
[l, [u, Ce], [d, b]],
|
|
1065
1088
|
[
|
|
1066
1089
|
// Apple
|
|
1067
1090
|
/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i
|
|
1068
1091
|
// iPod/iPhone
|
|
1069
1092
|
],
|
|
1070
|
-
[l, [u,
|
|
1093
|
+
[l, [u, he], [d, b]],
|
|
1071
1094
|
[
|
|
1072
1095
|
/\((ipad);[-\w\),; ]+apple/i,
|
|
1073
1096
|
// iPad
|
|
1074
1097
|
/applecoremedia\/[\w\.]+ \((ipad)/i,
|
|
1075
1098
|
/\b(ipad)\d\d?,\d\d?[;\]].+ios/i
|
|
1076
1099
|
],
|
|
1077
|
-
[l, [u,
|
|
1100
|
+
[l, [u, he], [d, f]],
|
|
1078
1101
|
[
|
|
1079
1102
|
/(macintosh);/i
|
|
1080
1103
|
],
|
|
1081
|
-
[l, [u,
|
|
1104
|
+
[l, [u, he]],
|
|
1082
1105
|
[
|
|
1083
1106
|
// Sharp
|
|
1084
1107
|
/\b(sh-?[altvz]?\d\d[a-ekm]?)/i
|
|
1085
1108
|
],
|
|
1086
|
-
[l, [u,
|
|
1109
|
+
[l, [u, bt], [d, b]],
|
|
1087
1110
|
[
|
|
1088
1111
|
// Huawei
|
|
1089
1112
|
/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i
|
|
1090
1113
|
],
|
|
1091
|
-
[l, [u,
|
|
1114
|
+
[l, [u, gt], [d, f]],
|
|
1092
1115
|
[
|
|
1093
1116
|
/(?:huawei|honor)([-\w ]+)[;\)]/i,
|
|
1094
1117
|
/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i
|
|
1095
1118
|
],
|
|
1096
|
-
[l, [u,
|
|
1119
|
+
[l, [u, gt], [d, b]],
|
|
1097
1120
|
[
|
|
1098
1121
|
// Xiaomi
|
|
1099
1122
|
/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,
|
|
@@ -1109,14 +1132,14 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1109
1132
|
/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite)?)(?: bui|\))/i
|
|
1110
1133
|
// Xiaomi Mi
|
|
1111
1134
|
],
|
|
1112
|
-
[[l, /_/g, " "], [u,
|
|
1135
|
+
[[l, /_/g, " "], [u, We], [d, b]],
|
|
1113
1136
|
[
|
|
1114
1137
|
/oid[^\)]+; (2\d{4}(283|rpbf)[cgl])( bui|\))/i,
|
|
1115
1138
|
// Redmi Pad
|
|
1116
1139
|
/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i
|
|
1117
1140
|
// Mi Pad tablets
|
|
1118
1141
|
],
|
|
1119
|
-
[[l, /_/g, " "], [u,
|
|
1142
|
+
[[l, /_/g, " "], [u, We], [d, f]],
|
|
1120
1143
|
[
|
|
1121
1144
|
// OPPO
|
|
1122
1145
|
/; (\w+) bui.+ oppo/i,
|
|
@@ -1144,28 +1167,28 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1144
1167
|
/\bmot(?:orola)?[- ](\w*)/i,
|
|
1145
1168
|
/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i
|
|
1146
1169
|
],
|
|
1147
|
-
[l, [u,
|
|
1170
|
+
[l, [u, wt], [d, b]],
|
|
1148
1171
|
[
|
|
1149
1172
|
/\b(mz60\d|xoom[2 ]{0,2}) build\//i
|
|
1150
1173
|
],
|
|
1151
|
-
[l, [u,
|
|
1174
|
+
[l, [u, wt], [d, f]],
|
|
1152
1175
|
[
|
|
1153
1176
|
// LG
|
|
1154
1177
|
/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i
|
|
1155
1178
|
],
|
|
1156
|
-
[l, [u,
|
|
1179
|
+
[l, [u, qe], [d, f]],
|
|
1157
1180
|
[
|
|
1158
1181
|
/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,
|
|
1159
1182
|
/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,
|
|
1160
1183
|
/\blg-?([\d\w]+) bui/i
|
|
1161
1184
|
],
|
|
1162
|
-
[l, [u,
|
|
1185
|
+
[l, [u, qe], [d, b]],
|
|
1163
1186
|
[
|
|
1164
1187
|
// Lenovo
|
|
1165
1188
|
/(ideatab[-\w ]+)/i,
|
|
1166
1189
|
/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i
|
|
1167
1190
|
],
|
|
1168
|
-
[l, [u,
|
|
1191
|
+
[l, [u, mt], [d, f]],
|
|
1169
1192
|
[
|
|
1170
1193
|
// Nokia
|
|
1171
1194
|
/(?:maemo|nokia).*(n900|lumia \d+)/i,
|
|
@@ -1177,22 +1200,22 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1177
1200
|
/(pixel c)\b/i
|
|
1178
1201
|
// Google Pixel C
|
|
1179
1202
|
],
|
|
1180
|
-
[l, [u,
|
|
1203
|
+
[l, [u, ve], [d, f]],
|
|
1181
1204
|
[
|
|
1182
1205
|
/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i
|
|
1183
1206
|
// Google Pixel
|
|
1184
1207
|
],
|
|
1185
|
-
[l, [u,
|
|
1208
|
+
[l, [u, ve], [d, b]],
|
|
1186
1209
|
[
|
|
1187
1210
|
// Sony
|
|
1188
1211
|
/droid.+ (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i
|
|
1189
1212
|
],
|
|
1190
|
-
[l, [u,
|
|
1213
|
+
[l, [u, Me], [d, b]],
|
|
1191
1214
|
[
|
|
1192
1215
|
/sony tablet [ps]/i,
|
|
1193
1216
|
/\b(?:sony)?sgp\w+(?: bui|\))/i
|
|
1194
1217
|
],
|
|
1195
|
-
[[l, "Xperia Tablet"], [u,
|
|
1218
|
+
[[l, "Xperia Tablet"], [u, Me], [d, f]],
|
|
1196
1219
|
[
|
|
1197
1220
|
// OnePlus
|
|
1198
1221
|
/ (kb2005|in20[12]5|be20[12][59])\b/i,
|
|
@@ -1207,12 +1230,12 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1207
1230
|
/(kf[a-z]+)( bui|\)).+silk\//i
|
|
1208
1231
|
// Kindle Fire HD
|
|
1209
1232
|
],
|
|
1210
|
-
[l, [u,
|
|
1233
|
+
[l, [u, Ee], [d, f]],
|
|
1211
1234
|
[
|
|
1212
1235
|
/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i
|
|
1213
1236
|
// Fire Phone
|
|
1214
1237
|
],
|
|
1215
|
-
[[l, /(.+)/g, "Fire Phone $1"], [u,
|
|
1238
|
+
[[l, /(.+)/g, "Fire Phone $1"], [u, Ee], [d, b]],
|
|
1216
1239
|
[
|
|
1217
1240
|
// BlackBerry
|
|
1218
1241
|
/(playbook);[-\w\),; ]+(rim)/i
|
|
@@ -1224,16 +1247,16 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1224
1247
|
/\(bb10; (\w+)/i
|
|
1225
1248
|
// BlackBerry 10
|
|
1226
1249
|
],
|
|
1227
|
-
[l, [u,
|
|
1250
|
+
[l, [u, pt], [d, b]],
|
|
1228
1251
|
[
|
|
1229
1252
|
// Asus
|
|
1230
1253
|
/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i
|
|
1231
1254
|
],
|
|
1232
|
-
[l, [u,
|
|
1255
|
+
[l, [u, ht], [d, f]],
|
|
1233
1256
|
[
|
|
1234
1257
|
/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i
|
|
1235
1258
|
],
|
|
1236
|
-
[l, [u,
|
|
1259
|
+
[l, [u, ht], [d, b]],
|
|
1237
1260
|
[
|
|
1238
1261
|
// HTC
|
|
1239
1262
|
/(nexus 9)/i
|
|
@@ -1298,7 +1321,7 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1298
1321
|
/(surface duo)/i
|
|
1299
1322
|
// Surface Duo
|
|
1300
1323
|
],
|
|
1301
|
-
[l, [u,
|
|
1324
|
+
[l, [u, Ae], [d, f]],
|
|
1302
1325
|
[
|
|
1303
1326
|
/droid [\d\.]+; (fp\du?)(?: b|\))/i
|
|
1304
1327
|
// Fairphone
|
|
@@ -1318,16 +1341,16 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1318
1341
|
/(kin\.[onetw]{3})/i
|
|
1319
1342
|
// Microsoft Kin
|
|
1320
1343
|
],
|
|
1321
|
-
[[l, /\./g, " "], [u,
|
|
1344
|
+
[[l, /\./g, " "], [u, Ae], [d, b]],
|
|
1322
1345
|
[
|
|
1323
1346
|
/droid.+; ([c6]+|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i
|
|
1324
1347
|
// Zebra
|
|
1325
1348
|
],
|
|
1326
|
-
[l, [u,
|
|
1349
|
+
[l, [u, $e], [d, f]],
|
|
1327
1350
|
[
|
|
1328
1351
|
/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i
|
|
1329
1352
|
],
|
|
1330
|
-
[l, [u,
|
|
1353
|
+
[l, [u, $e], [d, b]],
|
|
1331
1354
|
[
|
|
1332
1355
|
///////////////////
|
|
1333
1356
|
// SMARTTVS
|
|
@@ -1335,64 +1358,64 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1335
1358
|
/smart-tv.+(samsung)/i
|
|
1336
1359
|
// Samsung
|
|
1337
1360
|
],
|
|
1338
|
-
[u, [d,
|
|
1361
|
+
[u, [d, I]],
|
|
1339
1362
|
[
|
|
1340
1363
|
/hbbtv.+maple;(\d+)/i
|
|
1341
1364
|
],
|
|
1342
|
-
[[l, /^/, "SmartTV"], [u,
|
|
1365
|
+
[[l, /^/, "SmartTV"], [u, Ce], [d, I]],
|
|
1343
1366
|
[
|
|
1344
1367
|
/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i
|
|
1345
1368
|
// LG SmartTV
|
|
1346
1369
|
],
|
|
1347
|
-
[[u,
|
|
1370
|
+
[[u, qe], [d, I]],
|
|
1348
1371
|
[
|
|
1349
1372
|
/(apple) ?tv/i
|
|
1350
1373
|
// Apple TV
|
|
1351
1374
|
],
|
|
1352
|
-
[u, [l,
|
|
1375
|
+
[u, [l, he + " TV"], [d, I]],
|
|
1353
1376
|
[
|
|
1354
1377
|
/crkey/i
|
|
1355
1378
|
// Google Chromecast
|
|
1356
1379
|
],
|
|
1357
|
-
[[l,
|
|
1380
|
+
[[l, Se + "cast"], [u, ve], [d, I]],
|
|
1358
1381
|
[
|
|
1359
1382
|
/droid.+aft(\w+)( bui|\))/i
|
|
1360
1383
|
// Fire TV
|
|
1361
1384
|
],
|
|
1362
|
-
[l, [u,
|
|
1385
|
+
[l, [u, Ee], [d, I]],
|
|
1363
1386
|
[
|
|
1364
1387
|
/\(dtv[\);].+(aquos)/i,
|
|
1365
1388
|
/(aquos-tv[\w ]+)\)/i
|
|
1366
1389
|
// Sharp
|
|
1367
1390
|
],
|
|
1368
|
-
[l, [u,
|
|
1391
|
+
[l, [u, bt], [d, I]],
|
|
1369
1392
|
[
|
|
1370
1393
|
/(bravia[\w ]+)( bui|\))/i
|
|
1371
1394
|
// Sony
|
|
1372
1395
|
],
|
|
1373
|
-
[l, [u,
|
|
1396
|
+
[l, [u, Me], [d, I]],
|
|
1374
1397
|
[
|
|
1375
1398
|
/(mitv-\w{5}) bui/i
|
|
1376
1399
|
// Xiaomi
|
|
1377
1400
|
],
|
|
1378
|
-
[l, [u,
|
|
1401
|
+
[l, [u, We], [d, I]],
|
|
1379
1402
|
[
|
|
1380
1403
|
/Hbbtv.*(technisat) (.*);/i
|
|
1381
1404
|
// TechniSAT
|
|
1382
1405
|
],
|
|
1383
|
-
[u, l, [d,
|
|
1406
|
+
[u, l, [d, I]],
|
|
1384
1407
|
[
|
|
1385
1408
|
/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,
|
|
1386
1409
|
// Roku
|
|
1387
1410
|
/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i
|
|
1388
1411
|
// HbbTV devices
|
|
1389
1412
|
],
|
|
1390
|
-
[[u,
|
|
1413
|
+
[[u, be], [l, be], [d, I]],
|
|
1391
1414
|
[
|
|
1392
1415
|
/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i
|
|
1393
1416
|
// SmartTV from Unidentified Vendors
|
|
1394
1417
|
],
|
|
1395
|
-
[[d,
|
|
1418
|
+
[[d, I]],
|
|
1396
1419
|
[
|
|
1397
1420
|
///////////////////
|
|
1398
1421
|
// CONSOLES
|
|
@@ -1402,22 +1425,22 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1402
1425
|
/(nintendo) (\w+)/i
|
|
1403
1426
|
// Nintendo
|
|
1404
1427
|
],
|
|
1405
|
-
[u, l, [d,
|
|
1428
|
+
[u, l, [d, J]],
|
|
1406
1429
|
[
|
|
1407
1430
|
/droid.+; (shield) bui/i
|
|
1408
1431
|
// Nvidia
|
|
1409
1432
|
],
|
|
1410
|
-
[l, [u, "Nvidia"], [d,
|
|
1433
|
+
[l, [u, "Nvidia"], [d, J]],
|
|
1411
1434
|
[
|
|
1412
1435
|
/(playstation \w+)/i
|
|
1413
1436
|
// Playstation
|
|
1414
1437
|
],
|
|
1415
|
-
[l, [u,
|
|
1438
|
+
[l, [u, Me], [d, J]],
|
|
1416
1439
|
[
|
|
1417
1440
|
/\b(xbox(?: one)?(?!; xbox))[\); ]/i
|
|
1418
1441
|
// Microsoft Xbox
|
|
1419
1442
|
],
|
|
1420
|
-
[l, [u,
|
|
1443
|
+
[l, [u, Ae], [d, J]],
|
|
1421
1444
|
[
|
|
1422
1445
|
///////////////////
|
|
1423
1446
|
// WEARABLES
|
|
@@ -1425,16 +1448,16 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1425
1448
|
/((pebble))app/i
|
|
1426
1449
|
// Pebble
|
|
1427
1450
|
],
|
|
1428
|
-
[u, l, [d,
|
|
1451
|
+
[u, l, [d, Pe]],
|
|
1429
1452
|
[
|
|
1430
1453
|
/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i
|
|
1431
1454
|
// Apple Watch
|
|
1432
1455
|
],
|
|
1433
|
-
[l, [u,
|
|
1456
|
+
[l, [u, he], [d, Pe]],
|
|
1434
1457
|
[
|
|
1435
1458
|
/droid.+; (wt63?0{2,3})\)/i
|
|
1436
1459
|
],
|
|
1437
|
-
[l, [u,
|
|
1460
|
+
[l, [u, $e], [d, Pe]],
|
|
1438
1461
|
[
|
|
1439
1462
|
///////////////////
|
|
1440
1463
|
// XR
|
|
@@ -1442,12 +1465,12 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1442
1465
|
/droid.+; (glass) \d/i
|
|
1443
1466
|
// Google Glass
|
|
1444
1467
|
],
|
|
1445
|
-
[l, [u,
|
|
1468
|
+
[l, [u, ve], [d, lt]],
|
|
1446
1469
|
[
|
|
1447
1470
|
/(quest( \d| pro)?)/i
|
|
1448
1471
|
// Oculus Quest
|
|
1449
1472
|
],
|
|
1450
|
-
[l, [u,
|
|
1473
|
+
[l, [u, ft], [d, lt]],
|
|
1451
1474
|
[
|
|
1452
1475
|
///////////////////
|
|
1453
1476
|
// EMBEDDED
|
|
@@ -1455,12 +1478,12 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1455
1478
|
/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i
|
|
1456
1479
|
// Tesla
|
|
1457
1480
|
],
|
|
1458
|
-
[u, [d,
|
|
1481
|
+
[u, [d, Ye]],
|
|
1459
1482
|
[
|
|
1460
1483
|
/(aeobc)\b/i
|
|
1461
1484
|
// Echo Dot
|
|
1462
1485
|
],
|
|
1463
|
-
[l, [u,
|
|
1486
|
+
[l, [u, Ee], [d, Ye]],
|
|
1464
1487
|
[
|
|
1465
1488
|
////////////////////
|
|
1466
1489
|
// MIXED (GENERIC)
|
|
@@ -1495,7 +1518,7 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1495
1518
|
/windows.+ edge\/([\w\.]+)/i
|
|
1496
1519
|
// EdgeHTML
|
|
1497
1520
|
],
|
|
1498
|
-
[c, [r,
|
|
1521
|
+
[c, [r, ri + "HTML"]],
|
|
1499
1522
|
[
|
|
1500
1523
|
/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i
|
|
1501
1524
|
// Blink
|
|
@@ -1532,14 +1555,14 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1532
1555
|
/(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i
|
|
1533
1556
|
// Windows Phone
|
|
1534
1557
|
],
|
|
1535
|
-
[r, [c,
|
|
1558
|
+
[r, [c, xe, Et]],
|
|
1536
1559
|
[
|
|
1537
1560
|
/windows nt 6\.2; (arm)/i,
|
|
1538
1561
|
// Windows RT
|
|
1539
1562
|
/windows[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i,
|
|
1540
1563
|
/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i
|
|
1541
1564
|
],
|
|
1542
|
-
[[c,
|
|
1565
|
+
[[c, xe, Et], [r, et]],
|
|
1543
1566
|
[
|
|
1544
1567
|
// iOS/macOS
|
|
1545
1568
|
/ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,
|
|
@@ -1575,7 +1598,7 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1575
1598
|
/\(bb(10);/i
|
|
1576
1599
|
// BlackBerry 10
|
|
1577
1600
|
],
|
|
1578
|
-
[c, [r,
|
|
1601
|
+
[c, [r, pt]],
|
|
1579
1602
|
[
|
|
1580
1603
|
/(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i
|
|
1581
1604
|
// Symbian
|
|
@@ -1585,7 +1608,7 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1585
1608
|
/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i
|
|
1586
1609
|
// Firefox OS
|
|
1587
1610
|
],
|
|
1588
|
-
[c, [r,
|
|
1611
|
+
[c, [r, pe + " OS"]],
|
|
1589
1612
|
[
|
|
1590
1613
|
/web0s;.+rt(tv)/i,
|
|
1591
1614
|
/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i
|
|
@@ -1602,7 +1625,7 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1602
1625
|
/crkey\/([\d\.]+)/i
|
|
1603
1626
|
// Google Chromecast
|
|
1604
1627
|
],
|
|
1605
|
-
[c, [r,
|
|
1628
|
+
[c, [r, Se + "cast"]],
|
|
1606
1629
|
[
|
|
1607
1630
|
/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i
|
|
1608
1631
|
// Chromium OS
|
|
@@ -1657,214 +1680,214 @@ var si = "2.0.0-beta.3", ce = "", ht = "?", et = "function", V = "undefined", de
|
|
|
1657
1680
|
],
|
|
1658
1681
|
[r, c]
|
|
1659
1682
|
]
|
|
1660
|
-
},
|
|
1683
|
+
}, Ie = function() {
|
|
1661
1684
|
var s = { init: {}, isIgnore: {}, isIgnoreRgx: {}, toString: {} };
|
|
1662
|
-
return
|
|
1663
|
-
[
|
|
1664
|
-
[
|
|
1685
|
+
return F.call(s.init, [
|
|
1686
|
+
[T, [r, c, we, d]],
|
|
1687
|
+
[_, [M]],
|
|
1665
1688
|
[x, [d, l, u]],
|
|
1666
|
-
[
|
|
1689
|
+
[B, [r, c]],
|
|
1667
1690
|
[P, [r, c]]
|
|
1668
|
-
]),
|
|
1669
|
-
[
|
|
1670
|
-
[
|
|
1691
|
+
]), F.call(s.isIgnore, [
|
|
1692
|
+
[T, [c, we]],
|
|
1693
|
+
[B, [c]],
|
|
1671
1694
|
[P, [c]]
|
|
1672
|
-
]),
|
|
1673
|
-
[
|
|
1695
|
+
]), F.call(s.isIgnoreRgx, [
|
|
1696
|
+
[T, / ?browser$/i],
|
|
1674
1697
|
[P, / ?os$/i]
|
|
1675
|
-
]),
|
|
1676
|
-
[
|
|
1677
|
-
[
|
|
1698
|
+
]), F.call(s.toString, [
|
|
1699
|
+
[T, [r, c]],
|
|
1700
|
+
[_, [M]],
|
|
1678
1701
|
[x, [u, l]],
|
|
1679
|
-
[
|
|
1702
|
+
[B, [r, c]],
|
|
1680
1703
|
[P, [r, c]]
|
|
1681
1704
|
]), s;
|
|
1682
|
-
}(),
|
|
1683
|
-
var e =
|
|
1684
|
-
function
|
|
1685
|
-
|
|
1705
|
+
}(), li = function(s, t) {
|
|
1706
|
+
var e = Ie.init[t], i = Ie.isIgnore[t] || 0, a = Ie.isIgnoreRgx[t] || 0, o = Ie.toString[t] || 0;
|
|
1707
|
+
function n() {
|
|
1708
|
+
F.call(this, e);
|
|
1686
1709
|
}
|
|
1687
|
-
return
|
|
1710
|
+
return n.prototype.getItem = function() {
|
|
1688
1711
|
return s;
|
|
1689
|
-
},
|
|
1690
|
-
return
|
|
1691
|
-
return s.setCH(new
|
|
1712
|
+
}, n.prototype.withClientHints = function() {
|
|
1713
|
+
return N ? N.getHighEntropyValues(Ut).then(function(h) {
|
|
1714
|
+
return s.setCH(new _t(h, !1)).parseCH().get();
|
|
1692
1715
|
}) : s.parseCH().get();
|
|
1693
|
-
},
|
|
1716
|
+
}, n.prototype.withFeatureCheck = function() {
|
|
1694
1717
|
return s.detectFeature().get();
|
|
1695
|
-
}, t !=
|
|
1718
|
+
}, t != Z && (n.prototype.is = function(h) {
|
|
1696
1719
|
var p = !1;
|
|
1697
|
-
for (var
|
|
1698
|
-
if (this.hasOwnProperty(
|
|
1699
|
-
if (p = !0, h !=
|
|
1720
|
+
for (var w in this)
|
|
1721
|
+
if (this.hasOwnProperty(w) && !tt(i, w) && V(a ? $(a, this[w]) : this[w]) == V(a ? $(a, h) : h)) {
|
|
1722
|
+
if (p = !0, h != H)
|
|
1700
1723
|
break;
|
|
1701
|
-
} else if (h ==
|
|
1724
|
+
} else if (h == H && p) {
|
|
1702
1725
|
p = !p;
|
|
1703
1726
|
break;
|
|
1704
1727
|
}
|
|
1705
1728
|
return p;
|
|
1706
|
-
},
|
|
1707
|
-
var h =
|
|
1729
|
+
}, n.prototype.toString = function() {
|
|
1730
|
+
var h = re;
|
|
1708
1731
|
for (var p in o)
|
|
1709
|
-
typeof this[o[p]] !==
|
|
1710
|
-
return h ||
|
|
1711
|
-
}),
|
|
1712
|
-
var p = this,
|
|
1713
|
-
for (var
|
|
1714
|
-
p.hasOwnProperty(
|
|
1732
|
+
typeof this[o[p]] !== H && (h += (h ? " " : re) + this[o[p]]);
|
|
1733
|
+
return h || H;
|
|
1734
|
+
}), N || (n.prototype.then = function(h) {
|
|
1735
|
+
var p = this, w = function() {
|
|
1736
|
+
for (var k in p)
|
|
1737
|
+
p.hasOwnProperty(k) && (this[k] = p[k]);
|
|
1715
1738
|
};
|
|
1716
|
-
|
|
1717
|
-
is:
|
|
1718
|
-
toString:
|
|
1739
|
+
w.prototype = {
|
|
1740
|
+
is: n.prototype.is,
|
|
1741
|
+
toString: n.prototype.toString
|
|
1719
1742
|
};
|
|
1720
|
-
var
|
|
1721
|
-
return h(
|
|
1722
|
-
}), new
|
|
1743
|
+
var g = new w();
|
|
1744
|
+
return h(g), g;
|
|
1745
|
+
}), new n();
|
|
1723
1746
|
};
|
|
1724
|
-
function
|
|
1725
|
-
if (s = s || {},
|
|
1726
|
-
|
|
1727
|
-
[
|
|
1728
|
-
[
|
|
1729
|
-
[b, /\?1/.test(s[
|
|
1730
|
-
[l,
|
|
1731
|
-
[
|
|
1732
|
-
[
|
|
1733
|
-
[
|
|
1734
|
-
[W,
|
|
1735
|
-
[
|
|
1747
|
+
function _t(s, t) {
|
|
1748
|
+
if (s = s || {}, F.call(this, Ut), t)
|
|
1749
|
+
F.call(this, [
|
|
1750
|
+
[it, je(s[q])],
|
|
1751
|
+
[st, je(s[ei])],
|
|
1752
|
+
[b, /\?1/.test(s[ai])],
|
|
1753
|
+
[l, me(s[ni])],
|
|
1754
|
+
[Y, me(s[Lt])],
|
|
1755
|
+
[at, me(s[oi])],
|
|
1756
|
+
[M, me(s[ti])],
|
|
1757
|
+
[W, je(s[si])],
|
|
1758
|
+
[Fe, me(s[ii])]
|
|
1736
1759
|
]);
|
|
1737
1760
|
else
|
|
1738
1761
|
for (var e in s)
|
|
1739
|
-
this.hasOwnProperty(e) && typeof s[e] !==
|
|
1762
|
+
this.hasOwnProperty(e) && typeof s[e] !== H && (this[e] = s[e]);
|
|
1740
1763
|
}
|
|
1741
|
-
function
|
|
1742
|
-
return this.get = function(
|
|
1743
|
-
return
|
|
1744
|
-
}, this.set = function(
|
|
1745
|
-
return this.data[
|
|
1746
|
-
}, this.setCH = function(
|
|
1747
|
-
return this.uaCH =
|
|
1764
|
+
function Mt(s, t, e, i) {
|
|
1765
|
+
return this.get = function(a) {
|
|
1766
|
+
return a ? this.data.hasOwnProperty(a) ? this.data[a] : void 0 : this.data;
|
|
1767
|
+
}, this.set = function(a, o) {
|
|
1768
|
+
return this.data[a] = o, this;
|
|
1769
|
+
}, this.setCH = function(a) {
|
|
1770
|
+
return this.uaCH = a, this;
|
|
1748
1771
|
}, this.detectFeature = function() {
|
|
1749
|
-
if (
|
|
1772
|
+
if (S && S.userAgent == this.ua)
|
|
1750
1773
|
switch (this.itemType) {
|
|
1751
|
-
case
|
|
1752
|
-
|
|
1774
|
+
case T:
|
|
1775
|
+
S.brave && typeof S.brave.isBrave == Ke && this.set(r, "Brave");
|
|
1753
1776
|
break;
|
|
1754
1777
|
case x:
|
|
1755
|
-
!this.get(d) &&
|
|
1778
|
+
!this.get(d) && N && N[b] && this.set(d, b), this.get(l) == "Macintosh" && S && typeof S.standalone !== H && S.maxTouchPoints && S.maxTouchPoints > 2 && this.set(l, "iPad").set(d, f);
|
|
1756
1779
|
break;
|
|
1757
1780
|
case P:
|
|
1758
|
-
!this.get(r) &&
|
|
1781
|
+
!this.get(r) && N && N[Y] && this.set(r, N[Y]);
|
|
1759
1782
|
break;
|
|
1760
|
-
case
|
|
1761
|
-
var
|
|
1762
|
-
return n
|
|
1783
|
+
case Z:
|
|
1784
|
+
var a = this.data, o = function(n) {
|
|
1785
|
+
return a[n].getItem().detectFeature().get();
|
|
1763
1786
|
};
|
|
1764
|
-
this.set(
|
|
1787
|
+
this.set(T, o(T)).set(_, o(_)).set(x, o(x)).set(B, o(B)).set(P, o(P));
|
|
1765
1788
|
}
|
|
1766
1789
|
return this;
|
|
1767
1790
|
}, this.parseUA = function() {
|
|
1768
|
-
return this.itemType !=
|
|
1791
|
+
return this.itemType != Z && kt.call(this.data, this.ua, this.rgxMap), this.itemType == T && this.set(we, Qe(this.get(c))), this;
|
|
1769
1792
|
}, this.parseCH = function() {
|
|
1770
|
-
var
|
|
1793
|
+
var a = this.uaCH, o = this.rgxMap;
|
|
1771
1794
|
switch (this.itemType) {
|
|
1772
|
-
case
|
|
1773
|
-
var
|
|
1774
|
-
if (
|
|
1775
|
-
for (var p in
|
|
1776
|
-
var
|
|
1777
|
-
!/not.a.brand/i.test(
|
|
1795
|
+
case T:
|
|
1796
|
+
var n = a[st] || a[it], h;
|
|
1797
|
+
if (n)
|
|
1798
|
+
for (var p in n) {
|
|
1799
|
+
var w = $(/(Google|Microsoft) /, n[p].brand || n[p]), g = n[p].version;
|
|
1800
|
+
!/not.a.brand/i.test(w) && (!h || /chrom/i.test(h) && !/chromi/i.test(w)) && (this.set(r, w).set(c, g).set(we, Qe(g)), h = w);
|
|
1778
1801
|
}
|
|
1779
1802
|
break;
|
|
1780
|
-
case
|
|
1781
|
-
var
|
|
1782
|
-
|
|
1803
|
+
case _:
|
|
1804
|
+
var k = a[M];
|
|
1805
|
+
k && (k && a[Fe] == "64" && (k += "64"), kt.call(this.data, k + ";", o));
|
|
1783
1806
|
break;
|
|
1784
1807
|
case x:
|
|
1785
|
-
if (
|
|
1786
|
-
var
|
|
1787
|
-
if (typeof
|
|
1788
|
-
for (var
|
|
1789
|
-
|
|
1808
|
+
if (a[b] && this.set(d, b), a[l] && this.set(l, a[l]), a[l] == "Xbox" && this.set(d, J).set(u, Ae), a[W]) {
|
|
1809
|
+
var D;
|
|
1810
|
+
if (typeof a[W] != "string")
|
|
1811
|
+
for (var j = 0; !D && j < a[W].length; )
|
|
1812
|
+
D = xe(a[W][j++], vt);
|
|
1790
1813
|
else
|
|
1791
|
-
|
|
1792
|
-
this.set(d,
|
|
1814
|
+
D = xe(a[W], vt);
|
|
1815
|
+
this.set(d, D);
|
|
1793
1816
|
}
|
|
1794
1817
|
break;
|
|
1795
1818
|
case P:
|
|
1796
|
-
var
|
|
1797
|
-
if (
|
|
1798
|
-
var L =
|
|
1799
|
-
|
|
1819
|
+
var Q = a[Y];
|
|
1820
|
+
if (Q) {
|
|
1821
|
+
var L = a[at];
|
|
1822
|
+
Q == et && (L = parseInt(Qe(L), 10) >= 13 ? "11" : "10"), this.set(r, Q).set(c, L);
|
|
1800
1823
|
}
|
|
1801
|
-
this.get(r) ==
|
|
1824
|
+
this.get(r) == et && a[l] == "Xbox" && this.set(r, "Xbox").set(c, void 0);
|
|
1802
1825
|
break;
|
|
1803
|
-
case
|
|
1804
|
-
var
|
|
1805
|
-
return
|
|
1826
|
+
case Z:
|
|
1827
|
+
var le = this.data, A = function(U) {
|
|
1828
|
+
return le[U].getItem().setCH(a).parseCH().get();
|
|
1806
1829
|
};
|
|
1807
|
-
this.set(
|
|
1830
|
+
this.set(T, A(T)).set(_, A(_)).set(x, A(x)).set(B, A(B)).set(P, A(P));
|
|
1808
1831
|
}
|
|
1809
1832
|
return this;
|
|
1810
|
-
},
|
|
1833
|
+
}, F.call(this, [
|
|
1811
1834
|
["itemType", s],
|
|
1812
1835
|
["ua", t],
|
|
1813
1836
|
["uaCH", i],
|
|
1814
1837
|
["rgxMap", e],
|
|
1815
|
-
["data",
|
|
1838
|
+
["data", li(this, s)]
|
|
1816
1839
|
]), this;
|
|
1817
1840
|
}
|
|
1818
1841
|
function R(s, t, e) {
|
|
1819
|
-
if (typeof s ===
|
|
1842
|
+
if (typeof s === ce ? (Oe(s, !0) ? (typeof t === ce && (e = t), t = s) : (e = s, t = void 0), s = void 0) : typeof s === Je && !Oe(t, !0) && (e = t, t = void 0), !(this instanceof R))
|
|
1820
1843
|
return new R(s, t, e).getResult();
|
|
1821
|
-
var i = typeof s ===
|
|
1844
|
+
var i = typeof s === Je ? s : (
|
|
1822
1845
|
// Passed user-agent string
|
|
1823
|
-
|
|
1846
|
+
S && S.userAgent ? S.userAgent : (
|
|
1824
1847
|
// navigator.userAgent
|
|
1825
|
-
e && e[
|
|
1848
|
+
e && e[ut] ? e[ut] : (
|
|
1826
1849
|
// User-Agent from passed headers
|
|
1827
|
-
|
|
1850
|
+
re
|
|
1828
1851
|
)
|
|
1829
1852
|
)
|
|
1830
|
-
),
|
|
1831
|
-
return h ==
|
|
1832
|
-
return new
|
|
1853
|
+
), a = new _t(e, !0), o = t ? di(Ct, t) : Ct, n = function(h) {
|
|
1854
|
+
return h == Z ? function() {
|
|
1855
|
+
return new Mt(h, i, o, a).set("ua", i).set(T, this.getBrowser()).set(_, this.getCPU()).set(x, this.getDevice()).set(B, this.getEngine()).set(P, this.getOS()).get();
|
|
1833
1856
|
} : function() {
|
|
1834
|
-
return new
|
|
1857
|
+
return new Mt(h, i, o[h], a).parseUA().get();
|
|
1835
1858
|
};
|
|
1836
1859
|
};
|
|
1837
|
-
return
|
|
1838
|
-
["getBrowser",
|
|
1839
|
-
["getCPU",
|
|
1840
|
-
["getDevice",
|
|
1841
|
-
["getEngine",
|
|
1842
|
-
["getOS",
|
|
1843
|
-
["getResult",
|
|
1860
|
+
return F.call(this, [
|
|
1861
|
+
["getBrowser", n(T)],
|
|
1862
|
+
["getCPU", n(_)],
|
|
1863
|
+
["getDevice", n(x)],
|
|
1864
|
+
["getEngine", n(B)],
|
|
1865
|
+
["getOS", n(P)],
|
|
1866
|
+
["getResult", n(Z)],
|
|
1844
1867
|
["getUA", function() {
|
|
1845
1868
|
return i;
|
|
1846
1869
|
}],
|
|
1847
1870
|
["setUA", function(h) {
|
|
1848
|
-
return
|
|
1871
|
+
return de(h) && (i = h.length > Ze ? be(h, Ze) : h), this;
|
|
1849
1872
|
}]
|
|
1850
1873
|
]).setUA(i), this;
|
|
1851
1874
|
}
|
|
1852
|
-
R.VERSION =
|
|
1853
|
-
R.BROWSER =
|
|
1854
|
-
R.CPU =
|
|
1855
|
-
R.DEVICE =
|
|
1856
|
-
R.ENGINE = R.OS =
|
|
1857
|
-
class
|
|
1875
|
+
R.VERSION = Zt;
|
|
1876
|
+
R.BROWSER = De([r, c, we, d]);
|
|
1877
|
+
R.CPU = De([M]);
|
|
1878
|
+
R.DEVICE = De([l, u, d, J, b, I, f, Pe, Ye]);
|
|
1879
|
+
R.ENGINE = R.OS = De([r, c]);
|
|
1880
|
+
class ui {
|
|
1858
1881
|
constructor(t, e) {
|
|
1859
|
-
|
|
1860
|
-
|
|
1882
|
+
m(this, "config");
|
|
1883
|
+
m(this, "sdkConfig");
|
|
1861
1884
|
this.config = t, this.sdkConfig = e;
|
|
1862
1885
|
}
|
|
1863
1886
|
on(t, e, i) {
|
|
1864
|
-
const
|
|
1865
|
-
|
|
1887
|
+
const a = function(n) {
|
|
1888
|
+
n.data.message !== `kalamba:wrapper-rgs:${t}` && n.data.message !== `kalamba:wrapper:${t}` || e(n.data.payload);
|
|
1866
1889
|
};
|
|
1867
|
-
window.addEventListener("message",
|
|
1890
|
+
window.addEventListener("message", a, i);
|
|
1868
1891
|
}
|
|
1869
1892
|
send(t, ...[e]) {
|
|
1870
1893
|
window.postMessage({
|
|
@@ -1873,16 +1896,16 @@ class mi {
|
|
|
1873
1896
|
});
|
|
1874
1897
|
}
|
|
1875
1898
|
}
|
|
1876
|
-
class
|
|
1899
|
+
class hi {
|
|
1877
1900
|
constructor(t) {
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1901
|
+
m(this, "socket", null);
|
|
1902
|
+
m(this, "webSocketUrl");
|
|
1903
|
+
m(this, "eventListeners", {
|
|
1881
1904
|
close: [],
|
|
1882
1905
|
error: [],
|
|
1883
1906
|
message: []
|
|
1884
1907
|
});
|
|
1885
|
-
|
|
1908
|
+
m(this, "connect", async () => {
|
|
1886
1909
|
const t = new WebSocket(this.webSocketUrl);
|
|
1887
1910
|
return t.addEventListener("message", this.handleMessage), new Promise((e) => {
|
|
1888
1911
|
t.addEventListener(
|
|
@@ -1894,32 +1917,32 @@ class wi {
|
|
|
1894
1917
|
);
|
|
1895
1918
|
});
|
|
1896
1919
|
});
|
|
1897
|
-
|
|
1920
|
+
m(this, "send", (t) => {
|
|
1898
1921
|
if (this.socket == null)
|
|
1899
1922
|
throw new Error("Cannot send message, the WebSocket connection is not open");
|
|
1900
1923
|
this.socket.send(t);
|
|
1901
1924
|
});
|
|
1902
|
-
|
|
1925
|
+
m(this, "close", () => {
|
|
1903
1926
|
if (this.socket == null)
|
|
1904
1927
|
throw new Error("Cannot close the WebSocket connection that is not open");
|
|
1905
1928
|
this.socket.close();
|
|
1906
1929
|
});
|
|
1907
|
-
|
|
1930
|
+
m(this, "handleClose", (t) => {
|
|
1908
1931
|
this.eventListeners.close.forEach((e) => {
|
|
1909
1932
|
e(t);
|
|
1910
1933
|
}), this.socket.removeEventListener("message", this.handleMessage), this.socket.removeEventListener("close", this.handleClose), this.socket.removeEventListener("error", this.handleError), this.socket = null;
|
|
1911
1934
|
});
|
|
1912
|
-
|
|
1935
|
+
m(this, "handleError", (t) => {
|
|
1913
1936
|
this.eventListeners.error.forEach((e) => {
|
|
1914
1937
|
e(t);
|
|
1915
1938
|
});
|
|
1916
1939
|
});
|
|
1917
|
-
|
|
1940
|
+
m(this, "handleMessage", (t) => {
|
|
1918
1941
|
this.eventListeners.message.forEach((e) => {
|
|
1919
1942
|
e(t);
|
|
1920
1943
|
});
|
|
1921
1944
|
});
|
|
1922
|
-
|
|
1945
|
+
m(this, "handleOpen", (t) => {
|
|
1923
1946
|
const e = t.target;
|
|
1924
1947
|
e.addEventListener("close", this.handleClose), e.addEventListener("error", this.handleError), this.socket = e;
|
|
1925
1948
|
});
|
|
@@ -1933,35 +1956,35 @@ class wi {
|
|
|
1933
1956
|
i !== -1 && this.eventListeners[t].splice(i, 1);
|
|
1934
1957
|
}
|
|
1935
1958
|
}
|
|
1936
|
-
function
|
|
1959
|
+
function Te(s) {
|
|
1937
1960
|
return JSON.parse(s == null ? void 0 : s.data);
|
|
1938
1961
|
}
|
|
1939
|
-
function
|
|
1962
|
+
function pi(s) {
|
|
1940
1963
|
var t;
|
|
1941
1964
|
return ((t = s == null ? void 0 : s.header) == null ? void 0 : t.name) === "Ping";
|
|
1942
1965
|
}
|
|
1943
|
-
function
|
|
1966
|
+
function St(s) {
|
|
1944
1967
|
var t;
|
|
1945
1968
|
return ((t = s == null ? void 0 : s.header) == null ? void 0 : t.name) === "RealityCheck";
|
|
1946
1969
|
}
|
|
1947
|
-
function
|
|
1970
|
+
function Re(s) {
|
|
1948
1971
|
return s.header.name === "GameEvent";
|
|
1949
1972
|
}
|
|
1950
|
-
function
|
|
1951
|
-
return
|
|
1973
|
+
function gi(s) {
|
|
1974
|
+
return Re(s) && s.body.event === "OPEN_GAME";
|
|
1952
1975
|
}
|
|
1953
|
-
function
|
|
1976
|
+
function It(s) {
|
|
1954
1977
|
return s.header.code !== 1;
|
|
1955
1978
|
}
|
|
1956
|
-
function
|
|
1957
|
-
return
|
|
1979
|
+
function mi(s) {
|
|
1980
|
+
return Re(s) && s.body.event.includes("_RESULT");
|
|
1958
1981
|
}
|
|
1959
|
-
var
|
|
1960
|
-
class
|
|
1982
|
+
var ee, fe;
|
|
1983
|
+
class wi extends hi {
|
|
1961
1984
|
constructor(e, i) {
|
|
1962
|
-
const
|
|
1963
|
-
|
|
1964
|
-
super(
|
|
1985
|
+
const a = new URL(e.apiUrl);
|
|
1986
|
+
a.searchParams.set("cageCode", e.cageCode), a.searchParams.set("gameCode", e.gameCode), a.searchParams.set("operatorCode", e.operatorCode), a.searchParams.set("playMode", e.playMode), a.searchParams.set("token", e.token), a.searchParams.set("username", e.username);
|
|
1987
|
+
super(a.toString());
|
|
1965
1988
|
/*
|
|
1966
1989
|
* Correlation ID. Used in Request and Response types.
|
|
1967
1990
|
* ----
|
|
@@ -1972,7 +1995,7 @@ class ki extends wi {
|
|
|
1972
1995
|
* request sent. Client and server independently maintain their own
|
|
1973
1996
|
* correlation id counter.
|
|
1974
1997
|
*/
|
|
1975
|
-
|
|
1998
|
+
m(this, "cId", 0);
|
|
1976
1999
|
// Initial values for header
|
|
1977
2000
|
/*
|
|
1978
2001
|
* Increasing message ID
|
|
@@ -1984,20 +2007,20 @@ class ki extends wi {
|
|
|
1984
2007
|
* received out of sync).
|
|
1985
2008
|
*/
|
|
1986
2009
|
// TODO make sure messages are processed in order
|
|
1987
|
-
|
|
2010
|
+
m(this, "mId", 0);
|
|
1988
2011
|
// Initial values for body
|
|
1989
2012
|
/*
|
|
1990
2013
|
* Sequence ID. Action/Event correlation.
|
|
1991
2014
|
*/
|
|
1992
|
-
|
|
1993
|
-
|
|
1994
|
-
|
|
1995
|
-
|
|
1996
|
-
|
|
1997
|
-
const i =
|
|
1998
|
-
(
|
|
2015
|
+
m(this, "seqId", 0);
|
|
2016
|
+
m(this, "gameCode");
|
|
2017
|
+
C(this, ee, void 0);
|
|
2018
|
+
C(this, fe, void 0);
|
|
2019
|
+
m(this, "onMessage", (e) => {
|
|
2020
|
+
const i = Te(e);
|
|
2021
|
+
(Re(i) || pi(i) || St(i)) && this.sendAcknowledgement(i), St(i) && this.handleRealityCheck(i);
|
|
1999
2022
|
});
|
|
2000
|
-
this.eventListeners.realityCheck = [], this.gameCode = e.gameCode,
|
|
2023
|
+
this.eventListeners.realityCheck = [], this.gameCode = e.gameCode, E(this, ee, i.requestTimeoutMs), E(this, fe, i.gameVersion ?? "unknown"), this.addEventListener("message", this.onMessage);
|
|
2001
2024
|
}
|
|
2002
2025
|
handleRealityCheck(e) {
|
|
2003
2026
|
this.eventListeners.realityCheck.forEach((i) => {
|
|
@@ -2033,48 +2056,48 @@ class ki extends wi {
|
|
|
2033
2056
|
};
|
|
2034
2057
|
}
|
|
2035
2058
|
request(e, i) {
|
|
2036
|
-
const
|
|
2037
|
-
return new Promise((o,
|
|
2038
|
-
setTimeout(() =>
|
|
2059
|
+
const a = this.buildPayload(e, i);
|
|
2060
|
+
return new Promise((o, n) => {
|
|
2061
|
+
setTimeout(() => n({ type: "timeout" }), y(this, ee));
|
|
2039
2062
|
const h = (p) => {
|
|
2040
|
-
const
|
|
2063
|
+
const w = Te(p);
|
|
2041
2064
|
try {
|
|
2042
|
-
e.cId ===
|
|
2065
|
+
e.cId === w.header.cId && (this.removeEventListener("message", h), w.header.code === 1 ? o(w) : n({ message: w, type: "error" }));
|
|
2043
2066
|
} catch {
|
|
2044
|
-
|
|
2067
|
+
n({ message: w, type: "error" });
|
|
2045
2068
|
}
|
|
2046
2069
|
};
|
|
2047
|
-
this.addEventListener("message", h), this.send(
|
|
2070
|
+
this.addEventListener("message", h), this.send(a);
|
|
2048
2071
|
});
|
|
2049
2072
|
}
|
|
2050
2073
|
freeRounds(e) {
|
|
2051
2074
|
const i = this.buildHeader("ActivateFreeRound");
|
|
2052
|
-
return this.request(i, e).then((
|
|
2075
|
+
return this.request(i, e).then((a) => a.body).catch((a) => {
|
|
2053
2076
|
var o;
|
|
2054
|
-
throw { data: (o =
|
|
2077
|
+
throw { data: (o = a == null ? void 0 : a.message) == null ? void 0 : o.body, type: a.type };
|
|
2055
2078
|
});
|
|
2056
2079
|
}
|
|
2057
2080
|
async authenticate(e = !1) {
|
|
2058
|
-
const i = this.buildHeader("Authenticate"),
|
|
2081
|
+
const i = this.buildHeader("Authenticate"), a = {
|
|
2059
2082
|
clientType: 3,
|
|
2060
|
-
version: y(this,
|
|
2083
|
+
version: y(this, fe),
|
|
2061
2084
|
reconnect: e
|
|
2062
2085
|
};
|
|
2063
|
-
return this.request(i,
|
|
2064
|
-
var
|
|
2065
|
-
throw { data: (
|
|
2086
|
+
return this.request(i, a).then((o) => o.body).catch((o) => {
|
|
2087
|
+
var n;
|
|
2088
|
+
throw { data: (n = o == null ? void 0 : o.message) == null ? void 0 : n.body, type: o.type };
|
|
2066
2089
|
});
|
|
2067
2090
|
}
|
|
2068
2091
|
async openGame() {
|
|
2069
2092
|
const e = this.buildHeader("OpenGame"), i = {
|
|
2070
2093
|
gameCode: this.gameCode
|
|
2071
2094
|
};
|
|
2072
|
-
return new Promise((
|
|
2073
|
-
const
|
|
2074
|
-
const p =
|
|
2075
|
-
|
|
2095
|
+
return new Promise((a, o) => {
|
|
2096
|
+
const n = (h) => {
|
|
2097
|
+
const p = Te(h);
|
|
2098
|
+
gi(p) ? (this.removeEventListener("message", n), a(p.body)) : It(p) && o({ data: p.body, type: "error" });
|
|
2076
2099
|
};
|
|
2077
|
-
this.addEventListener("message",
|
|
2100
|
+
this.addEventListener("message", n), this.request(e, i).catch(
|
|
2078
2101
|
(h) => {
|
|
2079
2102
|
var p;
|
|
2080
2103
|
return o({ data: (p = h == null ? void 0 : h.message) == null ? void 0 : p.body, type: h.type });
|
|
@@ -2083,33 +2106,33 @@ class ki extends wi {
|
|
|
2083
2106
|
});
|
|
2084
2107
|
}
|
|
2085
2108
|
sendAcknowledgement(e) {
|
|
2086
|
-
const { name: i, cId:
|
|
2087
|
-
this.send(
|
|
2109
|
+
const { name: i, cId: a } = e.header, o = this.buildHeader(i, a), n = this.buildPayload(o, {});
|
|
2110
|
+
this.send(n);
|
|
2088
2111
|
}
|
|
2089
2112
|
sendAction(e, i) {
|
|
2090
|
-
const
|
|
2113
|
+
const a = this.buildHeader("GameAction"), o = {
|
|
2091
2114
|
...this.getBodyExtras(e),
|
|
2092
2115
|
data: i
|
|
2093
2116
|
};
|
|
2094
|
-
return new Promise((
|
|
2095
|
-
const p = (
|
|
2096
|
-
const
|
|
2097
|
-
|
|
2117
|
+
return new Promise((n, h) => {
|
|
2118
|
+
const p = (w) => {
|
|
2119
|
+
const g = Te(w);
|
|
2120
|
+
Re(g) && o.seqId === g.body.correlationSeqId && (this.removeEventListener("message", p), mi(g) ? n(g.body) : It(g) && h({ data: g.body, type: "error" }));
|
|
2098
2121
|
};
|
|
2099
|
-
this.addEventListener("message", p), this.request(
|
|
2100
|
-
(
|
|
2101
|
-
var
|
|
2102
|
-
return h({ data: (
|
|
2122
|
+
this.addEventListener("message", p), this.request(a, o).catch(
|
|
2123
|
+
(w) => {
|
|
2124
|
+
var g;
|
|
2125
|
+
return h({ data: (g = w == null ? void 0 : w.message) == null ? void 0 : g.body, type: w.type });
|
|
2103
2126
|
}
|
|
2104
2127
|
);
|
|
2105
2128
|
});
|
|
2106
2129
|
}
|
|
2107
2130
|
setRequestTimeoutMs(e) {
|
|
2108
|
-
|
|
2131
|
+
E(this, ee, e);
|
|
2109
2132
|
}
|
|
2110
2133
|
}
|
|
2111
|
-
|
|
2112
|
-
function
|
|
2134
|
+
ee = new WeakMap(), fe = new WeakMap();
|
|
2135
|
+
function Bt(s) {
|
|
2113
2136
|
const t = s.contract;
|
|
2114
2137
|
return t ? {
|
|
2115
2138
|
contract: {
|
|
@@ -2139,15 +2162,15 @@ function Ht(s) {
|
|
|
2139
2162
|
}
|
|
2140
2163
|
};
|
|
2141
2164
|
}
|
|
2142
|
-
function
|
|
2165
|
+
function Ft(s) {
|
|
2143
2166
|
var t, e;
|
|
2144
2167
|
return {
|
|
2145
2168
|
// SDK error codes are the same as RGS error codes so we don't need any mapping here
|
|
2146
|
-
code: ((t = s.data) == null ? void 0 : t.code) ??
|
|
2169
|
+
code: ((t = s.data) == null ? void 0 : t.code) ?? Be.UNKNOWN,
|
|
2147
2170
|
details: (e = s.data) == null ? void 0 : e.details
|
|
2148
2171
|
};
|
|
2149
2172
|
}
|
|
2150
|
-
function
|
|
2173
|
+
function Dt(s, t) {
|
|
2151
2174
|
const e = t.contract;
|
|
2152
2175
|
if (!e) {
|
|
2153
2176
|
const i = t.data;
|
|
@@ -2173,22 +2196,22 @@ function zt(s, t) {
|
|
|
2173
2196
|
coins: t.balance,
|
|
2174
2197
|
version: t.balanceVersion
|
|
2175
2198
|
},
|
|
2176
|
-
freeRounds: (i.FREE_ROUNDS ?? []).map((
|
|
2199
|
+
freeRounds: (i.FREE_ROUNDS ?? []).map((a) => ({
|
|
2177
2200
|
conf: {
|
|
2178
|
-
base:
|
|
2179
|
-
multiplier:
|
|
2180
|
-
numAwarded:
|
|
2201
|
+
base: a.conf.baseBet,
|
|
2202
|
+
multiplier: a.conf.betMultiplier,
|
|
2203
|
+
numAwarded: a.conf.numAwarded
|
|
2181
2204
|
},
|
|
2182
2205
|
data: {
|
|
2183
|
-
numPlayed:
|
|
2184
|
-
win:
|
|
2185
|
-
numLeft:
|
|
2206
|
+
numPlayed: a.data.numPlayed,
|
|
2207
|
+
win: a.data.winAmount,
|
|
2208
|
+
numLeft: a.data.numLeft
|
|
2186
2209
|
},
|
|
2187
|
-
id:
|
|
2188
|
-
rejectable:
|
|
2189
|
-
skippable:
|
|
2190
|
-
status:
|
|
2191
|
-
type:
|
|
2210
|
+
id: a.id,
|
|
2211
|
+
rejectable: a.rejectable,
|
|
2212
|
+
skippable: a.skippable,
|
|
2213
|
+
status: a.status,
|
|
2214
|
+
type: a.type
|
|
2192
2215
|
})),
|
|
2193
2216
|
gameModel: i.additionalConfigData.gameModelFile,
|
|
2194
2217
|
metaData: i.gameConfigData.metaData,
|
|
@@ -2267,15 +2290,15 @@ function zt(s, t) {
|
|
|
2267
2290
|
data: t.opaqueGameServerToUi
|
|
2268
2291
|
};
|
|
2269
2292
|
}
|
|
2270
|
-
function
|
|
2293
|
+
function Nt(s) {
|
|
2271
2294
|
var t, e;
|
|
2272
2295
|
return {
|
|
2273
2296
|
// SDK error codes are the same as RGS error codes so we don't need any mapping here
|
|
2274
|
-
code: ((t = s.data) == null ? void 0 : t.code) ??
|
|
2297
|
+
code: ((t = s.data) == null ? void 0 : t.code) ?? Be.UNKNOWN,
|
|
2275
2298
|
details: (e = s.data) == null ? void 0 : e.details
|
|
2276
2299
|
};
|
|
2277
2300
|
}
|
|
2278
|
-
function
|
|
2301
|
+
function Gt(s) {
|
|
2279
2302
|
const t = s.contract;
|
|
2280
2303
|
if (!t) {
|
|
2281
2304
|
const e = s.data;
|
|
@@ -2375,22 +2398,22 @@ function Wt(s) {
|
|
|
2375
2398
|
data: s.opaqueGameServerToUi
|
|
2376
2399
|
};
|
|
2377
2400
|
}
|
|
2378
|
-
function
|
|
2401
|
+
function Ht(s) {
|
|
2379
2402
|
var t, e;
|
|
2380
2403
|
return {
|
|
2381
2404
|
// SDK error codes are the same as RGS error codes so we don't need any mapping here
|
|
2382
|
-
code: ((t = s.data) == null ? void 0 : t.code) ??
|
|
2405
|
+
code: ((t = s.data) == null ? void 0 : t.code) ?? Be.UNKNOWN,
|
|
2383
2406
|
details: (e = s.data) == null ? void 0 : e.details
|
|
2384
2407
|
};
|
|
2385
2408
|
}
|
|
2386
|
-
const
|
|
2387
|
-
parseAuthenticateResponse:
|
|
2388
|
-
parseAuthenticateError:
|
|
2389
|
-
parseOpenGameResponse:
|
|
2390
|
-
parseOpenGameError:
|
|
2391
|
-
parsePlayResponse:
|
|
2392
|
-
parsePlayError:
|
|
2393
|
-
},
|
|
2409
|
+
const Di = {
|
|
2410
|
+
parseAuthenticateResponse: Bt,
|
|
2411
|
+
parseAuthenticateError: Ft,
|
|
2412
|
+
parseOpenGameResponse: Dt,
|
|
2413
|
+
parseOpenGameError: Nt,
|
|
2414
|
+
parsePlayResponse: Gt,
|
|
2415
|
+
parsePlayError: Ht
|
|
2416
|
+
}, bi = {
|
|
2394
2417
|
bul: "bg",
|
|
2395
2418
|
chi: "zh",
|
|
2396
2419
|
zho: "zh",
|
|
@@ -2422,13 +2445,13 @@ const Wi = {
|
|
|
2422
2445
|
tur: "tr",
|
|
2423
2446
|
ukr: "uk",
|
|
2424
2447
|
vie: "vi"
|
|
2425
|
-
}, { device:
|
|
2426
|
-
class
|
|
2448
|
+
}, { device: fi } = R(navigator.userAgent), yi = O("KalambaBullseyePlugin", "color:#000000;font-weight:bold;");
|
|
2449
|
+
class Ni extends ui {
|
|
2427
2450
|
constructor(...e) {
|
|
2428
2451
|
super(...e);
|
|
2429
2452
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
2430
2453
|
// @ts-ignore
|
|
2431
|
-
|
|
2454
|
+
m(this, "socket");
|
|
2432
2455
|
this.on("openGame", async () => {
|
|
2433
2456
|
try {
|
|
2434
2457
|
const i = await this.openGame();
|
|
@@ -2438,34 +2461,34 @@ class $i extends mi {
|
|
|
2438
2461
|
}
|
|
2439
2462
|
}), this.on("play", async (i) => {
|
|
2440
2463
|
try {
|
|
2441
|
-
const
|
|
2442
|
-
this.send("playResponse",
|
|
2443
|
-
} catch (
|
|
2444
|
-
this.send("playError",
|
|
2464
|
+
const a = await this.play(i);
|
|
2465
|
+
this.send("playResponse", a);
|
|
2466
|
+
} catch (a) {
|
|
2467
|
+
this.send("playError", a);
|
|
2445
2468
|
}
|
|
2446
2469
|
}), this.on("freeRounds", async (i) => {
|
|
2447
2470
|
try {
|
|
2448
2471
|
await this.socket.freeRounds(i), this.send("freeRoundsResponse", i);
|
|
2449
|
-
} catch (
|
|
2450
|
-
this.send("freeRoundsError",
|
|
2472
|
+
} catch (a) {
|
|
2473
|
+
this.send("freeRoundsError", a);
|
|
2451
2474
|
}
|
|
2452
2475
|
}), this.on("configured", (i) => {
|
|
2453
2476
|
this.socket.setRequestTimeoutMs(i.ui.requestTimeoutMs);
|
|
2454
2477
|
}), this.registerFromSdkEvents();
|
|
2455
2478
|
}
|
|
2456
2479
|
initialize(e) {
|
|
2457
|
-
this.socket = new
|
|
2480
|
+
this.socket = new wi(e, {
|
|
2458
2481
|
gameVersion: this.config.gameVersion,
|
|
2459
2482
|
requestTimeoutMs: this.sdkConfig.ui.requestTimeoutMs
|
|
2460
|
-
}), ["
|
|
2483
|
+
}), ["fireboltroulette"].includes(e.gameCode) || (this.socket.addEventListener("close", (i) => {
|
|
2461
2484
|
i.code === 1008 ? this.send("error", {
|
|
2462
2485
|
type: "CLOSE",
|
|
2463
2486
|
messageCode: "TOO_MANY_OPEN_GAMES",
|
|
2464
2487
|
messageKey: "RgsError.TOO_MANY_OPEN_GAMES"
|
|
2465
2488
|
}) : i.code === 1011 || this.reconnect();
|
|
2466
|
-
}), ["mobile", "tablet"].includes(
|
|
2489
|
+
}), ["mobile", "tablet"].includes(fi.type ?? "") && document.addEventListener("visibilitychange", async () => {
|
|
2467
2490
|
document.hidden || (this.socket.socket ? this.socket.socket && [WebSocket.CONNECTING, WebSocket.OPEN].includes(this.socket.socket.readyState) && this.socket.close() : this.reconnect());
|
|
2468
|
-
})), this.socket.addEventListener("error", (i) =>
|
|
2491
|
+
})), this.socket.addEventListener("error", (i) => yi("error", i)), this.socket.addEventListener("realityCheck", (i) => {
|
|
2469
2492
|
this.send("realityCheck", i);
|
|
2470
2493
|
});
|
|
2471
2494
|
}
|
|
@@ -2477,30 +2500,31 @@ class $i extends mi {
|
|
|
2477
2500
|
}
|
|
2478
2501
|
}
|
|
2479
2502
|
async openGame() {
|
|
2480
|
-
const e = new URLSearchParams(window.location.search), i = e.get("apiUrl"),
|
|
2481
|
-
this.initialize({ apiUrl: i, cageCode:
|
|
2503
|
+
const e = new URLSearchParams(window.location.search), i = e.get("apiUrl"), a = e.get("cageCode"), o = e.get("gameCode"), n = e.get("operatorCode"), h = e.get("playMode"), p = e.get("token"), w = e.get("username"), g = e.get("gameHistoryUrl"), k = e.get("homeUrl") ?? void 0, D = e.get("cashierUrl") ?? void 0;
|
|
2504
|
+
this.initialize({ apiUrl: i, cageCode: a, gameCode: o, operatorCode: n, playMode: h, token: p, username: w });
|
|
2482
2505
|
try {
|
|
2483
2506
|
await this.socket.connect();
|
|
2484
2507
|
} catch {
|
|
2485
|
-
throw { type: "error", data: { code:
|
|
2508
|
+
throw { type: "error", data: { code: Be.CONNECTION_ERROR } };
|
|
2486
2509
|
}
|
|
2487
|
-
let
|
|
2510
|
+
let j;
|
|
2488
2511
|
try {
|
|
2489
|
-
|
|
2490
|
-
} catch (
|
|
2491
|
-
throw { type:
|
|
2512
|
+
j = await this.socket.authenticate();
|
|
2513
|
+
} catch (U) {
|
|
2514
|
+
throw { type: U.type, data: U.type === "error" ? Ft(U.data) : void 0 };
|
|
2492
2515
|
}
|
|
2493
|
-
let
|
|
2516
|
+
let Q;
|
|
2494
2517
|
try {
|
|
2495
|
-
|
|
2496
|
-
} catch (
|
|
2497
|
-
throw { type:
|
|
2518
|
+
Q = await this.socket.openGame();
|
|
2519
|
+
} catch (U) {
|
|
2520
|
+
throw { type: U.type, data: U.type === "error" ? Nt(U.data) : void 0 };
|
|
2498
2521
|
}
|
|
2499
|
-
const L =
|
|
2522
|
+
const L = Bt(j), le = Dt(j, Q);
|
|
2500
2523
|
this.sdkConfig.api = {
|
|
2501
|
-
|
|
2524
|
+
...this.sdkConfig.api,
|
|
2525
|
+
brand: a,
|
|
2502
2526
|
game: o,
|
|
2503
|
-
integration:
|
|
2527
|
+
integration: n,
|
|
2504
2528
|
jurisdiction: L.contract.jurisdiction,
|
|
2505
2529
|
playMode: h,
|
|
2506
2530
|
user: L.contract.username,
|
|
@@ -2510,100 +2534,100 @@ class $i extends mi {
|
|
|
2510
2534
|
country: L.contract.country,
|
|
2511
2535
|
currency: L.contract.currency,
|
|
2512
2536
|
coinValueInCents: L.contract.coinValueInCents,
|
|
2513
|
-
gameHistoryUrl:
|
|
2514
|
-
homeUrl:
|
|
2515
|
-
cashierUrl:
|
|
2516
|
-
|
|
2517
|
-
lastRoundId:
|
|
2537
|
+
gameHistoryUrl: g,
|
|
2538
|
+
homeUrl: k,
|
|
2539
|
+
cashierUrl: D,
|
|
2540
|
+
backendSessionId: le.contract.sessionId,
|
|
2541
|
+
lastRoundId: le.contract.roundId
|
|
2518
2542
|
};
|
|
2519
|
-
const
|
|
2520
|
-
return
|
|
2543
|
+
const A = e.get("languageCode");
|
|
2544
|
+
return A && (this.sdkConfig.ui.language = A.length === 3 ? bi[A] ?? A : A), le;
|
|
2521
2545
|
}
|
|
2522
2546
|
async play(e) {
|
|
2523
2547
|
for (; !this.socket.socket; )
|
|
2524
|
-
await new Promise((
|
|
2548
|
+
await new Promise((k) => setTimeout(() => k(), 500));
|
|
2525
2549
|
const {
|
|
2526
|
-
contract: { bet: i, forcedOutcomes:
|
|
2527
|
-
extra:
|
|
2550
|
+
contract: { bet: i, forcedOutcomes: a, ...o },
|
|
2551
|
+
extra: n,
|
|
2528
2552
|
payloadToInject: h,
|
|
2529
2553
|
actionType: p
|
|
2530
|
-
} = e,
|
|
2554
|
+
} = e, w = {
|
|
2531
2555
|
bet: i ? { baseBet: i.base, betMultiplier: i.multiplier } : void 0,
|
|
2532
|
-
forcedOutcomes:
|
|
2556
|
+
forcedOutcomes: a,
|
|
2533
2557
|
// TODO: get rid of contractRest - it' a legacy from old RGS
|
|
2534
2558
|
...o,
|
|
2535
2559
|
...h,
|
|
2536
|
-
opaqueUiToGameServer:
|
|
2560
|
+
opaqueUiToGameServer: n
|
|
2537
2561
|
};
|
|
2538
|
-
let
|
|
2562
|
+
let g;
|
|
2539
2563
|
try {
|
|
2540
|
-
|
|
2541
|
-
} catch (
|
|
2542
|
-
throw { type:
|
|
2564
|
+
g = await this.socket.sendAction(p, w);
|
|
2565
|
+
} catch (k) {
|
|
2566
|
+
throw { type: k.type, data: k.type === "error" ? Ht(k.data) : void 0 };
|
|
2543
2567
|
}
|
|
2544
|
-
return
|
|
2568
|
+
return Gt(g);
|
|
2545
2569
|
}
|
|
2546
2570
|
registerFromSdkEvents() {
|
|
2547
2571
|
this.on("history", () => {
|
|
2548
2572
|
const {
|
|
2549
|
-
api: { game: e, integration: i, integrationData:
|
|
2573
|
+
api: { game: e, integration: i, integrationData: a, jurisdiction: o, user: n, gameHistoryUrl: h },
|
|
2550
2574
|
ui: { language: p }
|
|
2551
|
-
} = this.sdkConfig,
|
|
2552
|
-
|
|
2575
|
+
} = this.sdkConfig, w = n.replace(/^user_/, "").replace(new RegExp(`_${i}$`), ""), g = new URL(window.location.href);
|
|
2576
|
+
g.hostname = g.hostname.replace(/^v\./, "").replace(/^play\./, "history."), g.pathname = g.pathname.replace(/(\/[0-9]+\.[0-9]+\.[0-9]+)?\/wrapper\.html/, "/list/index.html"), g.search = "", g.searchParams.set("apiUrl", new URL(h).origin), g.searchParams.set("gameCode", e), g.searchParams.set("jurisdiction", o), g.searchParams.set("operatorCode", i), g.searchParams.set("token", a.token), g.searchParams.set("username", w), g.searchParams.set("languageCode", p), this.config.gameHistoryUrl && g.searchParams.set("gameHistoryUrl", this.config.gameHistoryUrl), window.open(g.toString(), "_blank");
|
|
2553
2577
|
});
|
|
2554
2578
|
}
|
|
2555
2579
|
}
|
|
2556
|
-
class
|
|
2580
|
+
class ki {
|
|
2557
2581
|
constructor(t, e, i) {
|
|
2558
|
-
|
|
2559
|
-
|
|
2560
|
-
|
|
2582
|
+
m(this, "trackers");
|
|
2583
|
+
m(this, "config");
|
|
2584
|
+
m(this, "sdkConfig");
|
|
2561
2585
|
this.trackers = t, this.config = e, this.sdkConfig = i;
|
|
2562
2586
|
}
|
|
2563
2587
|
on(t, e, i) {
|
|
2564
|
-
const
|
|
2565
|
-
|
|
2588
|
+
const a = function(n) {
|
|
2589
|
+
n.data.message !== `kalamba:wrapper-telemetry:${t}` && n.data.message !== `kalamba:wrapper:${t}` || e(n.data.payload);
|
|
2566
2590
|
};
|
|
2567
|
-
window.addEventListener("message",
|
|
2591
|
+
window.addEventListener("message", a, i);
|
|
2568
2592
|
}
|
|
2569
2593
|
track(t, e) {
|
|
2570
2594
|
this.trackers.forEach((i) => i.track(t, e));
|
|
2571
2595
|
}
|
|
2572
2596
|
}
|
|
2573
|
-
function
|
|
2597
|
+
function Tt(s) {
|
|
2574
2598
|
return s.reduce((t, e) => t + e, 0);
|
|
2575
2599
|
}
|
|
2576
|
-
function
|
|
2577
|
-
const t = s.length, e =
|
|
2578
|
-
return Math.sqrt(
|
|
2600
|
+
function Ei(s) {
|
|
2601
|
+
const t = s.length, e = Tt(s) / t, i = s.map((o) => Math.pow(o - e, 2)), a = Tt(i) / t;
|
|
2602
|
+
return Math.sqrt(a);
|
|
2579
2603
|
}
|
|
2580
|
-
class
|
|
2604
|
+
class Pt {
|
|
2581
2605
|
constructor() {
|
|
2582
|
-
|
|
2583
|
-
|
|
2584
|
-
|
|
2585
|
-
|
|
2586
|
-
|
|
2606
|
+
m(this, "rafId", -1);
|
|
2607
|
+
m(this, "startTime", 0);
|
|
2608
|
+
m(this, "stopTime", 0);
|
|
2609
|
+
m(this, "frames", []);
|
|
2610
|
+
m(this, "calculateFPS", () => {
|
|
2587
2611
|
const t = Math.floor((this.stopTime - this.startTime) / 1e3);
|
|
2588
|
-
return this.frames.map((e) => Math.floor((e - this.startTime) / 1e3)).reduce((e, i,
|
|
2612
|
+
return this.frames.map((e) => Math.floor((e - this.startTime) / 1e3)).reduce((e, i, a, o) => (o[a] !== o[a - 1] ? e.push(1) : e[e.length - 1]++, e), []).slice(0, t);
|
|
2589
2613
|
});
|
|
2590
|
-
|
|
2591
|
-
const t = this.calculateFPS(), e = Math.floor(this.frames.length / ((this.stopTime - this.startTime) / 1e3)), i = t.length > 0 ? Math.max(...t) : e,
|
|
2592
|
-
return { fpsAvg: e, fpsMax: i, fpsMin:
|
|
2614
|
+
m(this, "getReport", () => {
|
|
2615
|
+
const t = this.calculateFPS(), e = Math.floor(this.frames.length / ((this.stopTime - this.startTime) / 1e3)), i = t.length > 0 ? Math.max(...t) : e, a = t.length > 0 ? Math.min(...t) : e, o = t.length > 0 ? Ei(t) : 0;
|
|
2616
|
+
return { fpsAvg: e, fpsMax: i, fpsMin: a, fpsStdDev: o };
|
|
2593
2617
|
});
|
|
2594
|
-
|
|
2618
|
+
m(this, "start", () => {
|
|
2595
2619
|
this.startTime = Date.now(), this.frames = [], this.trackFrames();
|
|
2596
2620
|
});
|
|
2597
|
-
|
|
2621
|
+
m(this, "stop", () => {
|
|
2598
2622
|
cancelAnimationFrame(this.rafId), this.stopTime = Date.now();
|
|
2599
2623
|
});
|
|
2600
|
-
|
|
2624
|
+
m(this, "trackFrames", () => {
|
|
2601
2625
|
this.frames.push(Date.now()), this.rafId = requestAnimationFrame(this.trackFrames);
|
|
2602
2626
|
});
|
|
2603
2627
|
}
|
|
2604
2628
|
}
|
|
2605
|
-
const
|
|
2606
|
-
function
|
|
2629
|
+
const vi = "landscape", Ci = "portrait";
|
|
2630
|
+
function Mi() {
|
|
2607
2631
|
try {
|
|
2608
2632
|
const s = document.createElement("canvas");
|
|
2609
2633
|
return !!window.WebGLRenderingContext && (s.getContext("webgl") || s.getContext("experimental-webgl")) instanceof WebGLRenderingContext;
|
|
@@ -2611,7 +2635,7 @@ function Ai() {
|
|
|
2611
2635
|
return !1;
|
|
2612
2636
|
}
|
|
2613
2637
|
}
|
|
2614
|
-
async function
|
|
2638
|
+
async function Si() {
|
|
2615
2639
|
if (!window.createImageBitmap)
|
|
2616
2640
|
return !1;
|
|
2617
2641
|
const e = await (await fetch("data:image/webp;base64,UklGRiQAAABXRUJQVlA4IBgAAAAwAQCdASoCAAEAAQAcJaQAA3AA/v3AgAA=")).blob();
|
|
@@ -2621,33 +2645,33 @@ async function Pi() {
|
|
|
2621
2645
|
return !1;
|
|
2622
2646
|
}
|
|
2623
2647
|
}
|
|
2624
|
-
function
|
|
2625
|
-
return window.innerWidth >= window.innerHeight ?
|
|
2648
|
+
function Xe() {
|
|
2649
|
+
return window.innerWidth >= window.innerHeight ? vi : Ci;
|
|
2626
2650
|
}
|
|
2627
|
-
var
|
|
2628
|
-
class
|
|
2651
|
+
var Le, te, ie, se, ye, Ue, ke, _e;
|
|
2652
|
+
class Gi extends ki {
|
|
2629
2653
|
constructor(...e) {
|
|
2630
2654
|
super(...e);
|
|
2631
|
-
|
|
2655
|
+
m(this, "FPS_SAMPLE_INTERVAL", 1e4);
|
|
2632
2656
|
// wrapper state
|
|
2633
|
-
|
|
2634
|
-
|
|
2635
|
-
|
|
2636
|
-
|
|
2637
|
-
|
|
2638
|
-
|
|
2639
|
-
|
|
2640
|
-
|
|
2641
|
-
|
|
2642
|
-
|
|
2657
|
+
C(this, Le, 0);
|
|
2658
|
+
C(this, te, void 0);
|
|
2659
|
+
C(this, ie, void 0);
|
|
2660
|
+
C(this, se, void 0);
|
|
2661
|
+
C(this, ye, !1);
|
|
2662
|
+
C(this, Ue, !1);
|
|
2663
|
+
C(this, ke, "");
|
|
2664
|
+
C(this, _e, []);
|
|
2665
|
+
E(this, ie, {}), E(this, se, this.deviceInfo()), E(this, te, this.config.gameVersion), this.on("state", ({ balance: i }) => {
|
|
2666
|
+
E(this, Le, i);
|
|
2643
2667
|
}), this.on("autoplay", ({ action: i }) => {
|
|
2644
|
-
["start", "resume"].includes(i) ?
|
|
2668
|
+
["start", "resume"].includes(i) ? E(this, ye, !0) : E(this, ye, !1);
|
|
2645
2669
|
}), this.on("settings", ({ fastPlay: i }) => {
|
|
2646
|
-
i !== void 0 &&
|
|
2670
|
+
i !== void 0 && E(this, Ue, i);
|
|
2647
2671
|
}), this.registerEvents();
|
|
2648
2672
|
}
|
|
2649
2673
|
async registerEvents() {
|
|
2650
|
-
y(this,
|
|
2674
|
+
y(this, se).then((e) => {
|
|
2651
2675
|
this.track("Device Information", e);
|
|
2652
2676
|
}), this.on("loadStart", () => {
|
|
2653
2677
|
this.track("Game Loading", { progress: 0, step: "initial" });
|
|
@@ -2661,9 +2685,9 @@ class ji extends Mi {
|
|
|
2661
2685
|
systemMessageType: e.type
|
|
2662
2686
|
});
|
|
2663
2687
|
}), this.on("openGameResponse", async (e) => {
|
|
2664
|
-
|
|
2688
|
+
E(this, ke, e.contract.stateType.nextRound), E(this, ie, {
|
|
2665
2689
|
balanceInCoins: e.contract.balance.coins,
|
|
2666
|
-
clientVersion: y(this,
|
|
2690
|
+
clientVersion: y(this, te),
|
|
2667
2691
|
coinValueInCents: this.sdkConfig.api.coinValueInCents,
|
|
2668
2692
|
coinValueInCentsFloat: this.sdkConfig.api.coinValueInCents,
|
|
2669
2693
|
currency: this.sdkConfig.api.currency,
|
|
@@ -2681,21 +2705,22 @@ class ji extends Mi {
|
|
|
2681
2705
|
platform: "WEB",
|
|
2682
2706
|
playMode: this.sdkConfig.api.playMode,
|
|
2683
2707
|
referrer: window.location.hostname,
|
|
2684
|
-
|
|
2708
|
+
rootTrackingSessionID: this.sdkConfig.api.sessionId,
|
|
2709
|
+
backendSessionID: this.sdkConfig.api.backendSessionId,
|
|
2685
2710
|
// rtpVariant: 'unknown',
|
|
2686
2711
|
serverVersion: e.contract.metaData.version
|
|
2687
2712
|
// testVariants: '',
|
|
2688
|
-
}), this.track("Game Open", y(this,
|
|
2713
|
+
}), this.track("Game Open", y(this, ie));
|
|
2689
2714
|
}), this.on("playCycleEnd", async (e) => {
|
|
2690
|
-
const i = await y(this,
|
|
2715
|
+
const i = await y(this, se), { base: a, multiplier: o, specialAction: n } = e.contract.bet.lastPaid ?? {}, h = e.contract.balance.coins, p = e.contract.bet.lastPaid.base * e.contract.bet.lastPaid.multiplier, w = e.contract.win.total, g = w - p, k = n || "spin", D = e.contract.roundId;
|
|
2691
2716
|
this.track("Betting Activity", {
|
|
2692
|
-
balance: h -
|
|
2717
|
+
balance: h - g,
|
|
2693
2718
|
balanceAfter: h,
|
|
2694
|
-
baseBet:
|
|
2719
|
+
baseBet: a,
|
|
2695
2720
|
// baseBetIndex,
|
|
2696
2721
|
betMultiplier: o,
|
|
2697
|
-
betType:
|
|
2698
|
-
gameVersion: y(this,
|
|
2722
|
+
betType: k,
|
|
2723
|
+
gameVersion: y(this, te),
|
|
2699
2724
|
coinValueInCents: this.sdkConfig.api.coinValueInCents,
|
|
2700
2725
|
coinValueInCentsFloat: this.sdkConfig.api.coinValueInCents,
|
|
2701
2726
|
currency: this.sdkConfig.api.currency,
|
|
@@ -2703,20 +2728,20 @@ class ji extends Mi {
|
|
|
2703
2728
|
gameCode: this.sdkConfig.api.game,
|
|
2704
2729
|
gameCodeServer: this.sdkConfig.api.game,
|
|
2705
2730
|
isMobile: i.isMobile,
|
|
2706
|
-
netResult:
|
|
2731
|
+
netResult: g,
|
|
2707
2732
|
operatorName: "kalamba",
|
|
2708
|
-
orientation:
|
|
2733
|
+
orientation: Xe(),
|
|
2709
2734
|
partnerId: this.sdkConfig.api.brand,
|
|
2710
2735
|
partnerParentId: this.sdkConfig.api.integration,
|
|
2711
2736
|
platform: "WEB",
|
|
2712
2737
|
playMode: this.sdkConfig.api.playMode,
|
|
2713
|
-
roundId:
|
|
2738
|
+
roundId: D,
|
|
2714
2739
|
// TODO: uncomment when tracking TrackingEvent.GameSpin is implemented
|
|
2715
2740
|
// roundTypes: [...this.#roundTypes],
|
|
2716
2741
|
roundTypes: ["BaseGame"],
|
|
2717
2742
|
totalBet: p,
|
|
2718
|
-
totalWin:
|
|
2719
|
-
}),
|
|
2743
|
+
totalWin: w
|
|
2744
|
+
}), E(this, _e, []);
|
|
2720
2745
|
}), this.on("telemetry.click", (e) => {
|
|
2721
2746
|
this.track("UI Interaction", {
|
|
2722
2747
|
action: "click",
|
|
@@ -2731,17 +2756,17 @@ class ji extends Mi {
|
|
|
2731
2756
|
}), this.reportFpsSample(), this.reportFpsRound();
|
|
2732
2757
|
}
|
|
2733
2758
|
reportFpsSample() {
|
|
2734
|
-
const e = new
|
|
2759
|
+
const e = new Pt(), i = () => {
|
|
2735
2760
|
e.stop();
|
|
2736
2761
|
const o = e.getReport();
|
|
2737
|
-
this.track("FPS Performance", { ...o, fpsType: "sample" }),
|
|
2738
|
-
},
|
|
2762
|
+
this.track("FPS Performance", { ...o, fpsType: "sample" }), a();
|
|
2763
|
+
}, a = async () => {
|
|
2739
2764
|
e.start(), setTimeout(i, this.FPS_SAMPLE_INTERVAL);
|
|
2740
2765
|
};
|
|
2741
|
-
|
|
2766
|
+
a();
|
|
2742
2767
|
}
|
|
2743
2768
|
reportFpsRound() {
|
|
2744
|
-
const e = new
|
|
2769
|
+
const e = new Pt();
|
|
2745
2770
|
this.on("playCycleStart", () => {
|
|
2746
2771
|
e.start();
|
|
2747
2772
|
}), this.on("playCycleEnd", () => {
|
|
@@ -2752,13 +2777,13 @@ class ji extends Mi {
|
|
|
2752
2777
|
}
|
|
2753
2778
|
getExtraUiInteractionData() {
|
|
2754
2779
|
return {
|
|
2755
|
-
orientation:
|
|
2756
|
-
stateType: y(this,
|
|
2780
|
+
orientation: Xe(),
|
|
2781
|
+
stateType: y(this, ke)
|
|
2757
2782
|
};
|
|
2758
2783
|
}
|
|
2759
2784
|
async deviceInfo() {
|
|
2760
2785
|
var h;
|
|
2761
|
-
const { browser: e, device: i, os:
|
|
2786
|
+
const { browser: e, device: i, os: a } = R(navigator.userAgent), o = Mi(), n = await Si();
|
|
2762
2787
|
return {
|
|
2763
2788
|
browserName: e.name,
|
|
2764
2789
|
browserVersion: e.version,
|
|
@@ -2767,11 +2792,11 @@ class ji extends Mi {
|
|
|
2767
2792
|
deviceType: i.type,
|
|
2768
2793
|
isMobile: ["mobile", "tablet"].includes(i.type ?? ""),
|
|
2769
2794
|
isWebGLSupported: o,
|
|
2770
|
-
isWebPSupported:
|
|
2795
|
+
isWebPSupported: n,
|
|
2771
2796
|
manufacturer: i.vendor,
|
|
2772
|
-
operatingSystem:
|
|
2773
|
-
operatingSystemVersion:
|
|
2774
|
-
orientation:
|
|
2797
|
+
operatingSystem: a.name,
|
|
2798
|
+
operatingSystemVersion: a.version,
|
|
2799
|
+
orientation: Xe(),
|
|
2775
2800
|
pixelRatio: window.devicePixelRatio,
|
|
2776
2801
|
screenHeight: window.screen.height,
|
|
2777
2802
|
screenSize: `${window.screen.width}x${window.screen.height}`,
|
|
@@ -2783,66 +2808,36 @@ class ji extends Mi {
|
|
|
2783
2808
|
};
|
|
2784
2809
|
}
|
|
2785
2810
|
}
|
|
2786
|
-
|
|
2787
|
-
|
|
2788
|
-
for (var Ze = 0; Ze < 256; ++Ze)
|
|
2789
|
-
C.push((Ze + 256).toString(16).slice(1));
|
|
2790
|
-
function Oi(s, t = 0) {
|
|
2791
|
-
return (C[s[t + 0]] + C[s[t + 1]] + C[s[t + 2]] + C[s[t + 3]] + "-" + C[s[t + 4]] + C[s[t + 5]] + "-" + C[s[t + 6]] + C[s[t + 7]] + "-" + C[s[t + 8]] + C[s[t + 9]] + "-" + C[s[t + 10]] + C[s[t + 11]] + C[s[t + 12]] + C[s[t + 13]] + C[s[t + 14]] + C[s[t + 15]]).toLowerCase();
|
|
2792
|
-
}
|
|
2793
|
-
var Oe, xi = new Uint8Array(16);
|
|
2794
|
-
function Ri() {
|
|
2795
|
-
if (!Oe && (Oe = typeof crypto < "u" && crypto.getRandomValues && crypto.getRandomValues.bind(crypto), !Oe))
|
|
2796
|
-
throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
|
|
2797
|
-
return Oe(xi);
|
|
2798
|
-
}
|
|
2799
|
-
var Ui = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto);
|
|
2800
|
-
const Rt = {
|
|
2801
|
-
randomUUID: Ui
|
|
2802
|
-
};
|
|
2803
|
-
function Ut(s, t, e) {
|
|
2804
|
-
if (Rt.randomUUID && !t && !s)
|
|
2805
|
-
return Rt.randomUUID();
|
|
2806
|
-
s = s || {};
|
|
2807
|
-
var i = s.random || (s.rng || Ri)();
|
|
2808
|
-
if (i[6] = i[6] & 15 | 64, i[8] = i[8] & 63 | 128, t) {
|
|
2809
|
-
e = e || 0;
|
|
2810
|
-
for (var n = 0; n < 16; ++n)
|
|
2811
|
-
t[e + n] = i[n];
|
|
2812
|
-
return t;
|
|
2813
|
-
}
|
|
2814
|
-
return Oi(i);
|
|
2815
|
-
}
|
|
2816
|
-
class jt {
|
|
2811
|
+
Le = new WeakMap(), te = new WeakMap(), ie = new WeakMap(), se = new WeakMap(), ye = new WeakMap(), Ue = new WeakMap(), ke = new WeakMap(), _e = new WeakMap();
|
|
2812
|
+
class Vt {
|
|
2817
2813
|
constructor(t, e) {
|
|
2818
|
-
|
|
2819
|
-
|
|
2814
|
+
m(this, "config");
|
|
2815
|
+
m(this, "sdkConfig");
|
|
2820
2816
|
this.config = t, this.sdkConfig = e;
|
|
2821
2817
|
}
|
|
2822
2818
|
}
|
|
2823
|
-
const
|
|
2824
|
-
var ae,
|
|
2825
|
-
class
|
|
2819
|
+
const At = 25, Ot = 1e4;
|
|
2820
|
+
var ae, ne, oe, G;
|
|
2821
|
+
class Hi extends Vt {
|
|
2826
2822
|
constructor(...e) {
|
|
2827
2823
|
super(...e);
|
|
2828
|
-
|
|
2829
|
-
|
|
2830
|
-
|
|
2831
|
-
|
|
2832
|
-
|
|
2833
|
-
|
|
2834
|
-
k(this, oe, /* @__PURE__ */ (/* @__PURE__ */ new Date()).getTime()), k(this, H, []), k(this, Ee, Ut()), this.processQueueForced = this.processQueue.bind(this, !0), this.schedule(), fetch(y(this, ae), {
|
|
2824
|
+
C(this, ae, "https://europe-west3-stargazer-328808.cloudfunctions.net/collect-events");
|
|
2825
|
+
C(this, ne, void 0);
|
|
2826
|
+
C(this, oe, void 0);
|
|
2827
|
+
C(this, G, []);
|
|
2828
|
+
m(this, "processQueueForced");
|
|
2829
|
+
E(this, ne, (/* @__PURE__ */ new Date()).getTime()), E(this, G, []), this.processQueueForced = this.processQueue.bind(this, !0), this.schedule(), fetch(y(this, ae), {
|
|
2835
2830
|
method: "OPTIONS"
|
|
2836
|
-
}).catch(
|
|
2831
|
+
}).catch(ot), this.subscribe();
|
|
2837
2832
|
}
|
|
2838
2833
|
subscribe() {
|
|
2839
2834
|
window.addEventListener("beforeunload", this.processQueueForced, !1), window.addEventListener("pagehide", this.processQueueForced, !1), window.addEventListener("visibilitychange", this.processQueueForced, !1);
|
|
2840
2835
|
}
|
|
2841
2836
|
schedule() {
|
|
2842
|
-
y(this,
|
|
2837
|
+
y(this, oe) && clearTimeout(y(this, oe)), E(this, oe, window.setTimeout(() => this.processQueue(), Ot));
|
|
2843
2838
|
}
|
|
2844
2839
|
send(e) {
|
|
2845
|
-
|
|
2840
|
+
E(this, ne, (/* @__PURE__ */ new Date()).getTime());
|
|
2846
2841
|
try {
|
|
2847
2842
|
navigator.sendBeacon(y(this, ae), JSON.stringify(e));
|
|
2848
2843
|
} catch {
|
|
@@ -2853,19 +2848,19 @@ class Xi extends jt {
|
|
|
2853
2848
|
"Content-Type": "application/json"
|
|
2854
2849
|
},
|
|
2855
2850
|
keepalive: !0
|
|
2856
|
-
}).catch(
|
|
2851
|
+
}).catch(ot);
|
|
2857
2852
|
}
|
|
2858
2853
|
this.schedule();
|
|
2859
2854
|
}
|
|
2860
2855
|
addToQueue(e) {
|
|
2861
|
-
y(this,
|
|
2856
|
+
y(this, G).push(e), this.processQueue();
|
|
2862
2857
|
}
|
|
2863
2858
|
processQueue(e = !1) {
|
|
2864
|
-
if (!(this.sdkConfig == null || !this.sdkConfig.ui.feature.allowTelemetry) && !(!e && y(this,
|
|
2865
|
-
for (; y(this,
|
|
2866
|
-
const i = y(this,
|
|
2867
|
-
...
|
|
2868
|
-
sessionID:
|
|
2859
|
+
if (!(this.sdkConfig == null || !this.sdkConfig.ui.feature.allowTelemetry) && !(!e && y(this, G).length < At && (/* @__PURE__ */ new Date()).getTime() - y(this, ne) < Ot))
|
|
2860
|
+
for (; y(this, G).length; ) {
|
|
2861
|
+
const i = y(this, G).splice(0, At).map((a) => ({
|
|
2862
|
+
...a,
|
|
2863
|
+
sessionID: this.sdkConfig.api.sessionId,
|
|
2869
2864
|
userID: this.sdkConfig.api.user
|
|
2870
2865
|
}));
|
|
2871
2866
|
this.send(i);
|
|
@@ -2875,33 +2870,34 @@ class Xi extends jt {
|
|
|
2875
2870
|
this.addToQueue({
|
|
2876
2871
|
eventName: e,
|
|
2877
2872
|
eventParams: i,
|
|
2878
|
-
eventTimestamp:
|
|
2879
|
-
eventUUID:
|
|
2873
|
+
eventTimestamp: (/* @__PURE__ */ new Date()).getTime(),
|
|
2874
|
+
eventUUID: Wt()
|
|
2880
2875
|
});
|
|
2881
2876
|
}
|
|
2882
2877
|
}
|
|
2883
|
-
ae = new WeakMap(),
|
|
2884
|
-
const
|
|
2885
|
-
class
|
|
2878
|
+
ae = new WeakMap(), ne = new WeakMap(), oe = new WeakMap(), G = new WeakMap();
|
|
2879
|
+
const Ii = O("LoggingTracker", "color:#000000;font-weight:bold;");
|
|
2880
|
+
class Vi extends Vt {
|
|
2886
2881
|
track(t, e) {
|
|
2887
|
-
|
|
2882
|
+
Ii(`@${this.sdkConfig.api.user}`, `[${t}]`, e);
|
|
2888
2883
|
}
|
|
2889
2884
|
}
|
|
2890
2885
|
export {
|
|
2891
|
-
|
|
2892
|
-
|
|
2893
|
-
|
|
2894
|
-
|
|
2895
|
-
|
|
2896
|
-
|
|
2897
|
-
|
|
2898
|
-
|
|
2899
|
-
|
|
2900
|
-
|
|
2901
|
-
|
|
2902
|
-
|
|
2903
|
-
|
|
2904
|
-
|
|
2905
|
-
|
|
2906
|
-
|
|
2886
|
+
Oi as BasicPlugin,
|
|
2887
|
+
z as CasinoPlugin,
|
|
2888
|
+
xi as DebuggingPlugin,
|
|
2889
|
+
Ri as GigPlugin,
|
|
2890
|
+
Di as KalambaBullseyeParsers,
|
|
2891
|
+
Ni as KalambaBullseyePlugin,
|
|
2892
|
+
Gi as KalambaStargazerPlugin,
|
|
2893
|
+
Hi as KalambaStargazerTracker,
|
|
2894
|
+
Vi as LoggingTracker,
|
|
2895
|
+
Li as OryxPlugin,
|
|
2896
|
+
Ui as PariplayPlugin,
|
|
2897
|
+
Fi as QuantaPlugin,
|
|
2898
|
+
_i as RelaxFEIMPlugin,
|
|
2899
|
+
ui as RgsPlugin,
|
|
2900
|
+
ki as TelemetryPlugin,
|
|
2901
|
+
Vt as Tracker,
|
|
2902
|
+
Bi as TukoPlugin
|
|
2907
2903
|
};
|