@kalamba/sdk 0.1.2 → 0.2.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/index.cjs +1 -1
- package/dist/index.d.ts +18 -8
- package/dist/index.js +45 -45
- package/dist/plugins.cjs +1 -1
- package/dist/plugins.d.ts +20 -10
- package/dist/plugins.js +174 -181
- package/dist/wrapper.d.ts +17 -7
- package/package.json +1 -1
package/dist/plugins.js
CHANGED
|
@@ -14,7 +14,7 @@ var y = (i, t, e) => (at(i, t, "read from private field"), e ? e.call(i) : t.get
|
|
|
14
14
|
t instanceof WeakSet ? t.add(i) : t.set(i, e);
|
|
15
15
|
}, E = (i, t, e, s) => (at(i, t, "write to private field"), s ? s.call(i, e) : t.set(i, e), e);
|
|
16
16
|
import { a as ot } from "./noop-3336849b.js";
|
|
17
|
-
function
|
|
17
|
+
function x(i, t) {
|
|
18
18
|
return (e, ...s) => {
|
|
19
19
|
console.log(`[%c${i}\x1B[m] %s`, t, e, ...s);
|
|
20
20
|
};
|
|
@@ -37,13 +37,13 @@ class $ {
|
|
|
37
37
|
});
|
|
38
38
|
}
|
|
39
39
|
}
|
|
40
|
-
|
|
41
|
-
function Ht(i, t) {
|
|
40
|
+
function Nt(i, t) {
|
|
42
41
|
return Math.round(i * 100 / t);
|
|
43
42
|
}
|
|
44
|
-
|
|
43
|
+
const Ht = x("BasicPlugin", "color:#000000;font-weight:bold;");
|
|
44
|
+
class xi extends $ {
|
|
45
45
|
constructor(...t) {
|
|
46
|
-
super(...t), this.registerToSdkEvents(), this.registerFromSdkEvents(),
|
|
46
|
+
super(...t), this.registerToSdkEvents(), this.registerFromSdkEvents(), Ht("configured");
|
|
47
47
|
}
|
|
48
48
|
registerToSdkEvents() {
|
|
49
49
|
window.addEventListener("message", (t) => {
|
|
@@ -54,8 +54,8 @@ class Ui extends $ {
|
|
|
54
54
|
this.send("settings", { music: s == null ? void 0 : s.musicEnabled, sounds: s == null ? void 0 : s.soundEnabled });
|
|
55
55
|
return;
|
|
56
56
|
case "doBalanceUpdate":
|
|
57
|
-
const { currency: n, coinValueInCents:
|
|
58
|
-
s.currency === n && typeof s.balanceInCurrency == "number" ? this.send("balance", { balance:
|
|
57
|
+
const { currency: n, coinValueInCents: c } = this.config.api;
|
|
58
|
+
s.currency === n && typeof s.balanceInCurrency == "number" ? this.send("balance", { balance: Nt(s.balanceInCurrency, c) }) : (s.balanceInCoins, this.send("balance", { balance: s.balanceInCoins }));
|
|
59
59
|
return;
|
|
60
60
|
case "doGamePause":
|
|
61
61
|
this.send("freeze");
|
|
@@ -90,8 +90,8 @@ class Ui extends $ {
|
|
|
90
90
|
});
|
|
91
91
|
}
|
|
92
92
|
}
|
|
93
|
-
const k =
|
|
94
|
-
class
|
|
93
|
+
const k = x("▼ DebuggingPlugin IN ▼", "color:#444444;font-weight:bold;"), zt = x("▲ DebuggingPlugin OUT ▲", "color:#444444;font-weight:bold;");
|
|
94
|
+
class Ui extends $ {
|
|
95
95
|
constructor(...t) {
|
|
96
96
|
super(...t), this.registerDebugToSdkEvents(), this.registerSdkToDebugEvents();
|
|
97
97
|
}
|
|
@@ -118,7 +118,7 @@ class xi extends $ {
|
|
|
118
118
|
zt(...t), this.send(...t);
|
|
119
119
|
}
|
|
120
120
|
}
|
|
121
|
-
const Vt =
|
|
121
|
+
const Vt = x("GigPlugin", "color:#000000;font-weight:bold;");
|
|
122
122
|
class Oi extends $ {
|
|
123
123
|
constructor(...t) {
|
|
124
124
|
super(...t), this.registerToSdkEvents(), this.registerFromSdkEvents(), Vt("configured");
|
|
@@ -169,7 +169,7 @@ class Oi extends $ {
|
|
|
169
169
|
});
|
|
170
170
|
}
|
|
171
171
|
}
|
|
172
|
-
const qt =
|
|
172
|
+
const qt = x("OryxPlugin", "color:#000000;font-weight:bold;");
|
|
173
173
|
class Li extends $ {
|
|
174
174
|
constructor(...t) {
|
|
175
175
|
super(...t), this.registerToSdkEvents(), this.registerFromSdkEvents(), qt("configured");
|
|
@@ -224,7 +224,7 @@ class Li extends $ {
|
|
|
224
224
|
});
|
|
225
225
|
}
|
|
226
226
|
}
|
|
227
|
-
const rt =
|
|
227
|
+
const rt = x("PariplayPlugin", "color:#000000;font-weight:bold;");
|
|
228
228
|
function Ge(i) {
|
|
229
229
|
try {
|
|
230
230
|
window.top.location = i;
|
|
@@ -234,10 +234,10 @@ function Ge(i) {
|
|
|
234
234
|
}
|
|
235
235
|
function Ne(i, t) {
|
|
236
236
|
return new Promise(function(s, n) {
|
|
237
|
-
const
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
},
|
|
237
|
+
const c = new XMLHttpRequest();
|
|
238
|
+
c.onload = function() {
|
|
239
|
+
c.status >= 200 && c.status < 300 ? s(c.responseText) : n(c.responseText);
|
|
240
|
+
}, c.open(i, t), c.send();
|
|
241
241
|
});
|
|
242
242
|
}
|
|
243
243
|
function He() {
|
|
@@ -252,7 +252,7 @@ function ze(i) {
|
|
|
252
252
|
return ["NOTIFICATION", "POPUP"].includes(e.messageType.toUpperCase());
|
|
253
253
|
});
|
|
254
254
|
}
|
|
255
|
-
function
|
|
255
|
+
function xt(i) {
|
|
256
256
|
try {
|
|
257
257
|
return JSON.parse(i.text);
|
|
258
258
|
} catch {
|
|
@@ -260,12 +260,12 @@ function Ut(i) {
|
|
|
260
260
|
}
|
|
261
261
|
}
|
|
262
262
|
function $t(i) {
|
|
263
|
-
return i.map(
|
|
263
|
+
return i.map(xt).filter(Boolean).find(function(e) {
|
|
264
264
|
return e.betId != null && e.winId != null;
|
|
265
265
|
}) || {};
|
|
266
266
|
}
|
|
267
267
|
function jt(i) {
|
|
268
|
-
return i.map(
|
|
268
|
+
return i.map(xt).filter(Boolean).find(function(e) {
|
|
269
269
|
return e.TotalBet != null && e.TotalWin != null;
|
|
270
270
|
}) || {};
|
|
271
271
|
}
|
|
@@ -323,10 +323,10 @@ class _i extends $ {
|
|
|
323
323
|
processInfoUiMessages(t) {
|
|
324
324
|
return t.reduce((e, s) => e.then(() => new Promise((n) => {
|
|
325
325
|
Object.assign({}, s, {
|
|
326
|
-
buttons: s.buttons.filter((
|
|
326
|
+
buttons: s.buttons.filter((c) => c.action.toUpperCase() === "CASHIER" ? !!this.config.api.cashierUrl : !0).map((c) => Object.assign({}, c, {
|
|
327
327
|
onRelease: () => {
|
|
328
|
-
const a = s.messageType.toUpperCase() === "POPUP" ? He : n, h = this.buttonActions[
|
|
329
|
-
h ? h(
|
|
328
|
+
const a = s.messageType.toUpperCase() === "POPUP" ? He : n, h = this.buttonActions[c.action.toUpperCase()];
|
|
329
|
+
h ? h(c, a) : a();
|
|
330
330
|
}
|
|
331
331
|
}))
|
|
332
332
|
});
|
|
@@ -363,12 +363,12 @@ class _i extends $ {
|
|
|
363
363
|
try {
|
|
364
364
|
const n = JSON.parse(
|
|
365
365
|
JSON.parse(atob(this.config.api.integrationData.token.split(".")[1])).token
|
|
366
|
-
),
|
|
366
|
+
), c = JSON.parse(n.integrationSpecificAttributes.sessionData || "{}");
|
|
367
367
|
s = {
|
|
368
368
|
ClientToken: n.integrationSpecificAttributes.clientToken,
|
|
369
369
|
CurrencyCode: n.currency,
|
|
370
370
|
PlayerTokenId: n.user,
|
|
371
|
-
SessionData:
|
|
371
|
+
SessionData: c
|
|
372
372
|
};
|
|
373
373
|
} catch {
|
|
374
374
|
s = void 0;
|
|
@@ -418,13 +418,13 @@ class _i extends $ {
|
|
|
418
418
|
this.postMessage("roundStarted", {
|
|
419
419
|
balanceBefore: this.coinsToCurrency(e.balance + e.data.gameState.totalBetFromCurrentGameCycle)
|
|
420
420
|
});
|
|
421
|
-
const s = e.data.gameState.stateTypeThisRound === "BaseGame", n = Wt(e.data.uiMessages),
|
|
421
|
+
const s = e.data.gameState.stateTypeThisRound === "BaseGame", n = Wt(e.data.uiMessages), c = ze(e.data.uiMessages), a = $t(n), h = jt(n);
|
|
422
422
|
this.postMessage("ticketReceived", {
|
|
423
423
|
Balance: this.coinsToCurrency(e.balance),
|
|
424
424
|
BetAmount: s ? this.coinsToCurrency(e.data.gameState.totalBetFromCurrentGameCycle) : 0,
|
|
425
425
|
CreditTransactionId: a.betId,
|
|
426
426
|
DebitTransactionId: a.winId,
|
|
427
|
-
Message:
|
|
427
|
+
Message: c,
|
|
428
428
|
SessionData: h,
|
|
429
429
|
Status: {
|
|
430
430
|
ErrCode: 0
|
|
@@ -432,7 +432,7 @@ class _i extends $ {
|
|
|
432
432
|
WinAmount: this.coinsToCurrency(e.data.gameRoundResult.win)
|
|
433
433
|
});
|
|
434
434
|
}), this.on("playStart", (e) => {
|
|
435
|
-
|
|
435
|
+
e.bet && this.postMessage("roundStart", {
|
|
436
436
|
totalBet: this.coinsToCurrency(e.bet.base * e.bet.multiplier)
|
|
437
437
|
});
|
|
438
438
|
}), this.on("loadEnd", () => {
|
|
@@ -444,7 +444,7 @@ class _i extends $ {
|
|
|
444
444
|
});
|
|
445
445
|
}
|
|
446
446
|
}
|
|
447
|
-
const he =
|
|
447
|
+
const he = x("RelaxFEIMPlugin", "color:#000000;font-weight:bold;");
|
|
448
448
|
class Fi extends $ {
|
|
449
449
|
constructor(...e) {
|
|
450
450
|
super(...e);
|
|
@@ -521,10 +521,10 @@ class Fi extends $ {
|
|
|
521
521
|
});
|
|
522
522
|
}
|
|
523
523
|
}
|
|
524
|
-
const Ve = U("TukoPlugin", "color:#000000;font-weight:bold;");
|
|
525
524
|
function Qt(i, t) {
|
|
526
525
|
return Math.round(i * 100 / t);
|
|
527
526
|
}
|
|
527
|
+
const Ve = x("TukoPlugin", "color:#000000;font-weight:bold;");
|
|
528
528
|
class Di extends $ {
|
|
529
529
|
constructor(...e) {
|
|
530
530
|
super(...e);
|
|
@@ -549,8 +549,8 @@ class Di extends $ {
|
|
|
549
549
|
this.send("settings", { music: n == null ? void 0 : n.musicEnabled, sounds: n == null ? void 0 : n.soundEnabled });
|
|
550
550
|
return;
|
|
551
551
|
case "doBalanceUpdate":
|
|
552
|
-
const { currency:
|
|
553
|
-
n.currency ===
|
|
552
|
+
const { currency: c, coinValueInCents: a } = this.config.api;
|
|
553
|
+
n.currency === c && typeof n.balanceInCurrency == "number" ? this.send("balance", { balance: Qt(n.balanceInCurrency, a) }) : (n.balanceInCoins, this.send("balance", { balance: n.balanceInCoins }));
|
|
554
554
|
return;
|
|
555
555
|
case "doGamePause":
|
|
556
556
|
this.send("freeze");
|
|
@@ -756,12 +756,12 @@ class ii extends Xt {
|
|
|
756
756
|
}
|
|
757
757
|
request(e, s) {
|
|
758
758
|
const n = this.buildPayload(e, s);
|
|
759
|
-
return new Promise((
|
|
759
|
+
return new Promise((c, a) => {
|
|
760
760
|
setTimeout(() => a({ request: { body: s, header: e }, type: "timeout" }), y(this, Z));
|
|
761
761
|
const h = (p) => {
|
|
762
762
|
const g = Me(p);
|
|
763
763
|
try {
|
|
764
|
-
e.cId === (g == null ? void 0 : g.header.cId) && (this.removeEventListener("message", h), g.header.code === 1 ?
|
|
764
|
+
e.cId === (g == null ? void 0 : g.header.cId) && (this.removeEventListener("message", h), g.header.code === 1 ? c(g) : a({ response: g, type: "response" }));
|
|
765
765
|
} catch {
|
|
766
766
|
a({ response: g, type: "error" });
|
|
767
767
|
}
|
|
@@ -785,49 +785,43 @@ class ii extends Xt {
|
|
|
785
785
|
return this.request(
|
|
786
786
|
s,
|
|
787
787
|
n
|
|
788
|
-
).then((
|
|
788
|
+
).then((c) => c.body);
|
|
789
789
|
}
|
|
790
790
|
openGame() {
|
|
791
791
|
const e = this.buildHeader("OpenGame"), s = {
|
|
792
792
|
gameCode: this.gameCode
|
|
793
793
|
};
|
|
794
|
-
return new Promise((n,
|
|
794
|
+
return new Promise((n, c) => {
|
|
795
795
|
const a = (h) => {
|
|
796
796
|
const p = Me(h);
|
|
797
797
|
Kt(p) && (this.removeEventListener("message", a), n(p.body));
|
|
798
798
|
};
|
|
799
799
|
this.addEventListener("message", a), this.request(e, s).catch((h) => {
|
|
800
|
-
ei(h.response) &&
|
|
800
|
+
ei(h.response) && c(h), c(h);
|
|
801
801
|
});
|
|
802
802
|
});
|
|
803
803
|
}
|
|
804
804
|
sendAcknowledgement(e) {
|
|
805
|
-
const { name: s, cId: n } = e.header,
|
|
805
|
+
const { name: s, cId: n } = e.header, c = this.buildHeader(s, n), a = this.buildPayload(c, {});
|
|
806
806
|
this.send(a);
|
|
807
807
|
}
|
|
808
808
|
sendAction(e, s) {
|
|
809
|
-
const n = this.buildHeader("GameAction"),
|
|
809
|
+
const n = this.buildHeader("GameAction"), c = {
|
|
810
810
|
...this.getBodyExtras(e),
|
|
811
811
|
data: s
|
|
812
812
|
};
|
|
813
813
|
return new Promise((a, h) => {
|
|
814
814
|
const p = (g) => {
|
|
815
815
|
const f = Me(g);
|
|
816
|
-
oe(f) &&
|
|
816
|
+
oe(f) && c.seqId === f.body.correlationSeqId && (this.removeEventListener("message", p), Yt(f) || Zt(f) ? a(f.body) : Jt(f) && h(f.body));
|
|
817
817
|
};
|
|
818
|
-
this.addEventListener("message", p), this.request(n,
|
|
818
|
+
this.addEventListener("message", p), this.request(n, c).catch(
|
|
819
819
|
(g) => {
|
|
820
820
|
h(g);
|
|
821
821
|
}
|
|
822
822
|
);
|
|
823
823
|
});
|
|
824
824
|
}
|
|
825
|
-
spin(e) {
|
|
826
|
-
return this.sendAction("SPIN", e);
|
|
827
|
-
}
|
|
828
|
-
bgAction(e) {
|
|
829
|
-
return this.sendAction("BG_ACTION", e);
|
|
830
|
-
}
|
|
831
825
|
setRequestTimeoutMs(e) {
|
|
832
826
|
E(this, Z, e);
|
|
833
827
|
}
|
|
@@ -883,7 +877,7 @@ const ni = {
|
|
|
883
877
|
tur: "tr",
|
|
884
878
|
ukr: "uk",
|
|
885
879
|
vie: "vi"
|
|
886
|
-
}, ai =
|
|
880
|
+
}, ai = x("KalambaBullseyePlugin", "color:#000000;font-weight:bold;");
|
|
887
881
|
var Ee;
|
|
888
882
|
class Bi extends si {
|
|
889
883
|
constructor(...e) {
|
|
@@ -928,12 +922,12 @@ class Bi extends si {
|
|
|
928
922
|
this.initialize(e), await this.socket.connect(), await this.socket.authenticate(!0), await this.socket.openGame();
|
|
929
923
|
}
|
|
930
924
|
async openGame() {
|
|
931
|
-
const e = new URLSearchParams(window.location.search), s = e.get("apiUrl"), n = e.get("cageCode"),
|
|
932
|
-
this.initialize({ apiUrl: s, cageCode: n, gameCode:
|
|
925
|
+
const e = new URLSearchParams(window.location.search), s = e.get("apiUrl"), n = e.get("cageCode"), c = e.get("gameCode"), a = e.get("operatorCode"), h = e.get("playMode"), p = e.get("token"), g = e.get("username"), f = e.get("gameHistoryUrl"), A = e.get("homeUrl") ?? void 0, D = e.get("cashierUrl") ?? void 0;
|
|
926
|
+
this.initialize({ apiUrl: s, cageCode: n, gameCode: c, operatorCode: a, playMode: h, token: p, username: g }), await this.socket.connect();
|
|
933
927
|
const B = await this.socket.authenticate(), le = await this.socket.openGame();
|
|
934
928
|
this.config.api = {
|
|
935
929
|
brand: n,
|
|
936
|
-
game:
|
|
930
|
+
game: c,
|
|
937
931
|
integration: a,
|
|
938
932
|
jurisdiction: B.jurisdictionCode,
|
|
939
933
|
playMode: h,
|
|
@@ -948,35 +942,34 @@ class Bi extends si {
|
|
|
948
942
|
homeUrl: A,
|
|
949
943
|
cashierUrl: D
|
|
950
944
|
};
|
|
951
|
-
const
|
|
952
|
-
return
|
|
945
|
+
const U = e.get("languageCode");
|
|
946
|
+
return U && (this.config.ui.language = U.length === 3 ? ni[U] ?? U : U), le;
|
|
953
947
|
}
|
|
954
948
|
// TODO: redefine PlayResponse type
|
|
955
949
|
play(e) {
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
}
|
|
950
|
+
const {
|
|
951
|
+
contract: { bet: s, ...n },
|
|
952
|
+
extra: c,
|
|
953
|
+
actionType: a
|
|
954
|
+
} = e;
|
|
955
|
+
return this.socket.sendAction(a, {
|
|
956
|
+
bet: s ? { baseBet: s.base, betMultiplier: s.multiplier } : void 0,
|
|
957
|
+
...n,
|
|
958
|
+
...c
|
|
959
|
+
});
|
|
967
960
|
}
|
|
968
961
|
registerFromSdkEvents() {
|
|
969
962
|
this.on("history", () => {
|
|
970
963
|
const {
|
|
971
|
-
api: { game: e, integration: s, integrationData: n, jurisdiction:
|
|
964
|
+
api: { game: e, integration: s, integrationData: n, jurisdiction: c, user: a, gameHistoryUrl: h },
|
|
972
965
|
ui: { language: p }
|
|
973
966
|
} = this.config, g = a.replace(/^user_/, "").replace(new RegExp(`_${s}$`), ""), f = new URL(h);
|
|
974
|
-
f.searchParams.set("gameCode", e), f.searchParams.set("jurisdiction",
|
|
967
|
+
f.searchParams.set("gameCode", e), f.searchParams.set("jurisdiction", c), f.searchParams.set("operatorCode", s), f.searchParams.set("token", n.token), f.searchParams.set("username", g), f.searchParams.set("languageCode", p), window.open(f.toString(), "_blank");
|
|
975
968
|
});
|
|
976
969
|
}
|
|
977
970
|
}
|
|
978
971
|
Ee = new WeakMap();
|
|
979
|
-
var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce = "object", Je = "string", fe = "major",
|
|
972
|
+
var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce = "object", Je = "string", fe = "major", d = "model", o = "name", l = "type", u = "vendor", r = "version", M = "architecture", K = "console", m = "mobile", b = "tablet", I = "smarttv", X = "wearable", Ye = "embedded", lt = "user-agent", Ze = 500, it = "brands", q = "formFactor", st = "fullVersionList", J = "platform", nt = "platformVersion", De = "bitness", V = "sec-ch-ua", ri = V + "-full-version-list", ci = V + "-arch", di = V + "-" + De, li = V + "-form-factor", ui = V + "-" + m, hi = V + "-" + d, Ut = V + "-" + J, pi = Ut + "-version", Ot = [it, st, m, d, J, nt, M, q, De], T = "browser", O = "cpu", P = "device", L = "engine", R = "os", Y = "result", Ce = "Amazon", pe = "Apple", ut = "ASUS", ht = "BlackBerry", Ie = "Google", pt = "Huawei", gt = "Lenovo", qe = "LG", Ue = "Microsoft", wt = "Motorola", Te = "Samsung", mt = "Sharp", Ae = "Sony", We = "Xiaomi", $e = "Zebra", j = "Mobile ", Q = " Browser", Re = "Chrome", gi = "Edge", ge = "Firefox", we = "Opera", ft = "Facebook", bt = "Sogou", et = "Windows", wi = typeof window !== H, C = wi && window.navigator ? window.navigator : void 0, G = C && C.userAgentData ? C.userAgentData : void 0, mi = function(i, t) {
|
|
980
973
|
var e = {};
|
|
981
974
|
for (var s in i)
|
|
982
975
|
e[s] = t[s] && t[s].length % 2 === 0 ? t[s].concat(i[s]) : i[s];
|
|
@@ -1027,12 +1020,12 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
1027
1020
|
return i = W(/^\s\s*/, i), typeof t === H ? i : i.substring(0, Ze);
|
|
1028
1021
|
}, Et = function(i, t) {
|
|
1029
1022
|
if (!(!i || !t))
|
|
1030
|
-
for (var e = 0, s, n,
|
|
1023
|
+
for (var e = 0, s, n, c, a, h, p; e < t.length && !h; ) {
|
|
1031
1024
|
var g = t[e], f = t[e + 1];
|
|
1032
1025
|
for (s = n = 0; s < g.length && !h && g[s]; )
|
|
1033
1026
|
if (h = g[s++].exec(i), h)
|
|
1034
|
-
for (
|
|
1035
|
-
p = h[++n], a = f[
|
|
1027
|
+
for (c = 0; c < f.length; c++)
|
|
1028
|
+
p = h[++n], a = f[c], typeof a === ce && a.length > 0 ? a.length === 2 ? typeof a[1] == Ke ? this[a[0]] = a[1].call(this, p) : this[a[0]] = a[1] : a.length === 3 ? typeof a[1] === Ke && !(a[1].exec && a[1].test) ? this[a[0]] = p ? a[1].call(this, p, a[2]) : void 0 : this[a[0]] = p ? p.replace(a[1], a[2]) : void 0 : a.length === 4 && (this[a[0]] = p ? a[3].call(this, p.replace(a[1], a[2])) : void 0) : this[a] = p || void 0;
|
|
1036
1029
|
e += 2;
|
|
1037
1030
|
}
|
|
1038
1031
|
}, Oe = function(i, t) {
|
|
@@ -1423,45 +1416,45 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
1423
1416
|
// Samsung
|
|
1424
1417
|
/\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
|
|
1425
1418
|
],
|
|
1426
|
-
[
|
|
1419
|
+
[d, [u, Te], [l, b]],
|
|
1427
1420
|
[
|
|
1428
1421
|
/\b((?:s[cgp]h|gt|sm)-\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,
|
|
1429
1422
|
/samsung[- ]([-\w]+)/i,
|
|
1430
1423
|
/sec-(sgh\w+)/i
|
|
1431
1424
|
],
|
|
1432
|
-
[
|
|
1425
|
+
[d, [u, Te], [l, m]],
|
|
1433
1426
|
[
|
|
1434
1427
|
// Apple
|
|
1435
1428
|
/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i
|
|
1436
1429
|
// iPod/iPhone
|
|
1437
1430
|
],
|
|
1438
|
-
[
|
|
1431
|
+
[d, [u, pe], [l, m]],
|
|
1439
1432
|
[
|
|
1440
1433
|
/\((ipad);[-\w\),; ]+apple/i,
|
|
1441
1434
|
// iPad
|
|
1442
1435
|
/applecoremedia\/[\w\.]+ \((ipad)/i,
|
|
1443
1436
|
/\b(ipad)\d\d?,\d\d?[;\]].+ios/i
|
|
1444
1437
|
],
|
|
1445
|
-
[
|
|
1438
|
+
[d, [u, pe], [l, b]],
|
|
1446
1439
|
[
|
|
1447
1440
|
/(macintosh);/i
|
|
1448
1441
|
],
|
|
1449
|
-
[
|
|
1442
|
+
[d, [u, pe]],
|
|
1450
1443
|
[
|
|
1451
1444
|
// Sharp
|
|
1452
1445
|
/\b(sh-?[altvz]?\d\d[a-ekm]?)/i
|
|
1453
1446
|
],
|
|
1454
|
-
[
|
|
1447
|
+
[d, [u, mt], [l, m]],
|
|
1455
1448
|
[
|
|
1456
1449
|
// Huawei
|
|
1457
1450
|
/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i
|
|
1458
1451
|
],
|
|
1459
|
-
[
|
|
1452
|
+
[d, [u, pt], [l, b]],
|
|
1460
1453
|
[
|
|
1461
1454
|
/(?:huawei|honor)([-\w ]+)[;\)]/i,
|
|
1462
1455
|
/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i
|
|
1463
1456
|
],
|
|
1464
|
-
[
|
|
1457
|
+
[d, [u, pt], [l, m]],
|
|
1465
1458
|
[
|
|
1466
1459
|
// Xiaomi
|
|
1467
1460
|
/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,
|
|
@@ -1477,92 +1470,92 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
1477
1470
|
/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite)?)(?: bui|\))/i
|
|
1478
1471
|
// Xiaomi Mi
|
|
1479
1472
|
],
|
|
1480
|
-
[[
|
|
1473
|
+
[[d, /_/g, " "], [u, We], [l, m]],
|
|
1481
1474
|
[
|
|
1482
1475
|
/oid[^\)]+; (2\d{4}(283|rpbf)[cgl])( bui|\))/i,
|
|
1483
1476
|
// Redmi Pad
|
|
1484
1477
|
/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i
|
|
1485
1478
|
// Mi Pad tablets
|
|
1486
1479
|
],
|
|
1487
|
-
[[
|
|
1480
|
+
[[d, /_/g, " "], [u, We], [l, b]],
|
|
1488
1481
|
[
|
|
1489
1482
|
// OPPO
|
|
1490
1483
|
/; (\w+) bui.+ oppo/i,
|
|
1491
1484
|
/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i
|
|
1492
1485
|
],
|
|
1493
|
-
[
|
|
1486
|
+
[d, [u, "OPPO"], [l, m]],
|
|
1494
1487
|
[
|
|
1495
1488
|
// Vivo
|
|
1496
1489
|
/vivo (\w+)(?: bui|\))/i,
|
|
1497
1490
|
/\b(v[12]\d{3}\w?[at])(?: bui|;)/i
|
|
1498
1491
|
],
|
|
1499
|
-
[
|
|
1492
|
+
[d, [u, "Vivo"], [l, m]],
|
|
1500
1493
|
[
|
|
1501
1494
|
// Realme
|
|
1502
1495
|
/\b(rmx[1-3]\d{3})(?: bui|;|\))/i
|
|
1503
1496
|
],
|
|
1504
|
-
[
|
|
1497
|
+
[d, [u, "Realme"], [l, m]],
|
|
1505
1498
|
[
|
|
1506
1499
|
// Motorola
|
|
1507
1500
|
/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,
|
|
1508
1501
|
/\bmot(?:orola)?[- ](\w*)/i,
|
|
1509
1502
|
/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i
|
|
1510
1503
|
],
|
|
1511
|
-
[
|
|
1504
|
+
[d, [u, wt], [l, m]],
|
|
1512
1505
|
[
|
|
1513
1506
|
/\b(mz60\d|xoom[2 ]{0,2}) build\//i
|
|
1514
1507
|
],
|
|
1515
|
-
[
|
|
1508
|
+
[d, [u, wt], [l, b]],
|
|
1516
1509
|
[
|
|
1517
1510
|
// LG
|
|
1518
1511
|
/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i
|
|
1519
1512
|
],
|
|
1520
|
-
[
|
|
1513
|
+
[d, [u, qe], [l, b]],
|
|
1521
1514
|
[
|
|
1522
1515
|
/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,
|
|
1523
1516
|
/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,
|
|
1524
1517
|
/\blg-?([\d\w]+) bui/i
|
|
1525
1518
|
],
|
|
1526
|
-
[
|
|
1519
|
+
[d, [u, qe], [l, m]],
|
|
1527
1520
|
[
|
|
1528
1521
|
// Lenovo
|
|
1529
1522
|
/(ideatab[-\w ]+)/i,
|
|
1530
1523
|
/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i
|
|
1531
1524
|
],
|
|
1532
|
-
[
|
|
1525
|
+
[d, [u, gt], [l, b]],
|
|
1533
1526
|
[
|
|
1534
1527
|
// Nokia
|
|
1535
1528
|
/(?:maemo|nokia).*(n900|lumia \d+)/i,
|
|
1536
1529
|
/nokia[-_ ]?([-\w\.]*)/i
|
|
1537
1530
|
],
|
|
1538
|
-
[[
|
|
1531
|
+
[[d, /_/g, " "], [u, "Nokia"], [l, m]],
|
|
1539
1532
|
[
|
|
1540
1533
|
// Google
|
|
1541
1534
|
/(pixel c)\b/i
|
|
1542
1535
|
// Google Pixel C
|
|
1543
1536
|
],
|
|
1544
|
-
[
|
|
1537
|
+
[d, [u, Ie], [l, b]],
|
|
1545
1538
|
[
|
|
1546
1539
|
/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i
|
|
1547
1540
|
// Google Pixel
|
|
1548
1541
|
],
|
|
1549
|
-
[
|
|
1542
|
+
[d, [u, Ie], [l, m]],
|
|
1550
1543
|
[
|
|
1551
1544
|
// Sony
|
|
1552
1545
|
/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
|
|
1553
1546
|
],
|
|
1554
|
-
[
|
|
1547
|
+
[d, [u, Ae], [l, m]],
|
|
1555
1548
|
[
|
|
1556
1549
|
/sony tablet [ps]/i,
|
|
1557
1550
|
/\b(?:sony)?sgp\w+(?: bui|\))/i
|
|
1558
1551
|
],
|
|
1559
|
-
[[
|
|
1552
|
+
[[d, "Xperia Tablet"], [u, Ae], [l, b]],
|
|
1560
1553
|
[
|
|
1561
1554
|
// OnePlus
|
|
1562
1555
|
/ (kb2005|in20[12]5|be20[12][59])\b/i,
|
|
1563
1556
|
/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i
|
|
1564
1557
|
],
|
|
1565
|
-
[
|
|
1558
|
+
[d, [u, "OnePlus"], [l, m]],
|
|
1566
1559
|
[
|
|
1567
1560
|
// Amazon
|
|
1568
1561
|
/(alexa)webm/i,
|
|
@@ -1571,39 +1564,39 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
1571
1564
|
/(kf[a-z]+)( bui|\)).+silk\//i
|
|
1572
1565
|
// Kindle Fire HD
|
|
1573
1566
|
],
|
|
1574
|
-
[
|
|
1567
|
+
[d, [u, Ce], [l, b]],
|
|
1575
1568
|
[
|
|
1576
1569
|
/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i
|
|
1577
1570
|
// Fire Phone
|
|
1578
1571
|
],
|
|
1579
|
-
[[
|
|
1572
|
+
[[d, /(.+)/g, "Fire Phone $1"], [u, Ce], [l, m]],
|
|
1580
1573
|
[
|
|
1581
1574
|
// BlackBerry
|
|
1582
1575
|
/(playbook);[-\w\),; ]+(rim)/i
|
|
1583
1576
|
// BlackBerry PlayBook
|
|
1584
1577
|
],
|
|
1585
|
-
[
|
|
1578
|
+
[d, u, [l, b]],
|
|
1586
1579
|
[
|
|
1587
1580
|
/\b((?:bb[a-f]|st[hv])100-\d)/i,
|
|
1588
1581
|
/\(bb10; (\w+)/i
|
|
1589
1582
|
// BlackBerry 10
|
|
1590
1583
|
],
|
|
1591
|
-
[
|
|
1584
|
+
[d, [u, ht], [l, m]],
|
|
1592
1585
|
[
|
|
1593
1586
|
// Asus
|
|
1594
1587
|
/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i
|
|
1595
1588
|
],
|
|
1596
|
-
[
|
|
1589
|
+
[d, [u, ut], [l, b]],
|
|
1597
1590
|
[
|
|
1598
1591
|
/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i
|
|
1599
1592
|
],
|
|
1600
|
-
[
|
|
1593
|
+
[d, [u, ut], [l, m]],
|
|
1601
1594
|
[
|
|
1602
1595
|
// HTC
|
|
1603
1596
|
/(nexus 9)/i
|
|
1604
1597
|
// HTC Nexus 9
|
|
1605
1598
|
],
|
|
1606
|
-
[
|
|
1599
|
+
[d, [u, "HTC"], [l, b]],
|
|
1607
1600
|
[
|
|
1608
1601
|
/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,
|
|
1609
1602
|
// HTC
|
|
@@ -1612,23 +1605,23 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
1612
1605
|
/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i
|
|
1613
1606
|
// Alcatel/GeeksPhone/Nexian/Panasonic/Sony
|
|
1614
1607
|
],
|
|
1615
|
-
[u, [
|
|
1608
|
+
[u, [d, /_/g, " "], [l, m]],
|
|
1616
1609
|
[
|
|
1617
1610
|
// Acer
|
|
1618
1611
|
/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i
|
|
1619
1612
|
],
|
|
1620
|
-
[
|
|
1613
|
+
[d, [u, "Acer"], [l, b]],
|
|
1621
1614
|
[
|
|
1622
1615
|
// Meizu
|
|
1623
1616
|
/droid.+; (m[1-5] note) bui/i,
|
|
1624
1617
|
/\bmz-([-\w]{2,})/i
|
|
1625
1618
|
],
|
|
1626
|
-
[
|
|
1619
|
+
[d, [u, "Meizu"], [l, m]],
|
|
1627
1620
|
[
|
|
1628
1621
|
// Ulefone
|
|
1629
1622
|
/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i
|
|
1630
1623
|
],
|
|
1631
|
-
[
|
|
1624
|
+
[d, [u, "Ulefone"], [l, m]],
|
|
1632
1625
|
[
|
|
1633
1626
|
// MIXED
|
|
1634
1627
|
/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno)[-_ ]?([-\w]*)/i,
|
|
@@ -1646,7 +1639,7 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
1646
1639
|
/(oppo) ?([\w ]+) bui/i
|
|
1647
1640
|
// OPPO
|
|
1648
1641
|
],
|
|
1649
|
-
[u,
|
|
1642
|
+
[u, d, [l, m]],
|
|
1650
1643
|
[
|
|
1651
1644
|
/(kobo)\s(ereader|touch)/i,
|
|
1652
1645
|
// Kobo
|
|
@@ -1657,41 +1650,41 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
1657
1650
|
/(kindle)\/([\w\.]+)/i
|
|
1658
1651
|
// Kindle
|
|
1659
1652
|
],
|
|
1660
|
-
[u,
|
|
1653
|
+
[u, d, [l, b]],
|
|
1661
1654
|
[
|
|
1662
1655
|
/(surface duo)/i
|
|
1663
1656
|
// Surface Duo
|
|
1664
1657
|
],
|
|
1665
|
-
[
|
|
1658
|
+
[d, [u, Ue], [l, b]],
|
|
1666
1659
|
[
|
|
1667
1660
|
/droid [\d\.]+; (fp\du?)(?: b|\))/i
|
|
1668
1661
|
// Fairphone
|
|
1669
1662
|
],
|
|
1670
|
-
[
|
|
1663
|
+
[d, [u, "Fairphone"], [l, m]],
|
|
1671
1664
|
[
|
|
1672
1665
|
/(shield[\w ]+) b/i
|
|
1673
1666
|
// Nvidia Shield Tablets
|
|
1674
1667
|
],
|
|
1675
|
-
[
|
|
1668
|
+
[d, [u, "Nvidia"], [l, b]],
|
|
1676
1669
|
[
|
|
1677
1670
|
/(sprint) (\w+)/i
|
|
1678
1671
|
// Sprint Phones
|
|
1679
1672
|
],
|
|
1680
|
-
[u,
|
|
1673
|
+
[u, d, [l, m]],
|
|
1681
1674
|
[
|
|
1682
1675
|
/(kin\.[onetw]{3})/i
|
|
1683
1676
|
// Microsoft Kin
|
|
1684
1677
|
],
|
|
1685
|
-
[[
|
|
1678
|
+
[[d, /\./g, " "], [u, Ue], [l, m]],
|
|
1686
1679
|
[
|
|
1687
1680
|
/droid.+; ([c6]+|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i
|
|
1688
1681
|
// Zebra
|
|
1689
1682
|
],
|
|
1690
|
-
[
|
|
1683
|
+
[d, [u, $e], [l, b]],
|
|
1691
1684
|
[
|
|
1692
1685
|
/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i
|
|
1693
1686
|
],
|
|
1694
|
-
[
|
|
1687
|
+
[d, [u, $e], [l, m]],
|
|
1695
1688
|
[
|
|
1696
1689
|
///////////////////
|
|
1697
1690
|
// SMARTTVS
|
|
@@ -1699,64 +1692,64 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
1699
1692
|
/smart-tv.+(samsung)/i
|
|
1700
1693
|
// Samsung
|
|
1701
1694
|
],
|
|
1702
|
-
[u, [
|
|
1695
|
+
[u, [l, I]],
|
|
1703
1696
|
[
|
|
1704
1697
|
/hbbtv.+maple;(\d+)/i
|
|
1705
1698
|
],
|
|
1706
|
-
[[
|
|
1699
|
+
[[d, /^/, "SmartTV"], [u, Te], [l, I]],
|
|
1707
1700
|
[
|
|
1708
1701
|
/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i
|
|
1709
1702
|
// LG SmartTV
|
|
1710
1703
|
],
|
|
1711
|
-
[[u, qe], [
|
|
1704
|
+
[[u, qe], [l, I]],
|
|
1712
1705
|
[
|
|
1713
1706
|
/(apple) ?tv/i
|
|
1714
1707
|
// Apple TV
|
|
1715
1708
|
],
|
|
1716
|
-
[u, [
|
|
1709
|
+
[u, [d, pe + " TV"], [l, I]],
|
|
1717
1710
|
[
|
|
1718
1711
|
/crkey/i
|
|
1719
1712
|
// Google Chromecast
|
|
1720
1713
|
],
|
|
1721
|
-
[[
|
|
1714
|
+
[[d, Re + "cast"], [u, Ie], [l, I]],
|
|
1722
1715
|
[
|
|
1723
1716
|
/droid.+aft(\w+)( bui|\))/i
|
|
1724
1717
|
// Fire TV
|
|
1725
1718
|
],
|
|
1726
|
-
[
|
|
1719
|
+
[d, [u, Ce], [l, I]],
|
|
1727
1720
|
[
|
|
1728
1721
|
/\(dtv[\);].+(aquos)/i,
|
|
1729
1722
|
/(aquos-tv[\w ]+)\)/i
|
|
1730
1723
|
// Sharp
|
|
1731
1724
|
],
|
|
1732
|
-
[
|
|
1725
|
+
[d, [u, mt], [l, I]],
|
|
1733
1726
|
[
|
|
1734
1727
|
/(bravia[\w ]+)( bui|\))/i
|
|
1735
1728
|
// Sony
|
|
1736
1729
|
],
|
|
1737
|
-
[
|
|
1730
|
+
[d, [u, Ae], [l, I]],
|
|
1738
1731
|
[
|
|
1739
1732
|
/(mitv-\w{5}) bui/i
|
|
1740
1733
|
// Xiaomi
|
|
1741
1734
|
],
|
|
1742
|
-
[
|
|
1735
|
+
[d, [u, We], [l, I]],
|
|
1743
1736
|
[
|
|
1744
1737
|
/Hbbtv.*(technisat) (.*);/i
|
|
1745
1738
|
// TechniSAT
|
|
1746
1739
|
],
|
|
1747
|
-
[u,
|
|
1740
|
+
[u, d, [l, I]],
|
|
1748
1741
|
[
|
|
1749
1742
|
/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,
|
|
1750
1743
|
// Roku
|
|
1751
1744
|
/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i
|
|
1752
1745
|
// HbbTV devices
|
|
1753
1746
|
],
|
|
1754
|
-
[[u, be], [
|
|
1747
|
+
[[u, be], [d, be], [l, I]],
|
|
1755
1748
|
[
|
|
1756
1749
|
/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i
|
|
1757
1750
|
// SmartTV from Unidentified Vendors
|
|
1758
1751
|
],
|
|
1759
|
-
[[
|
|
1752
|
+
[[l, I]],
|
|
1760
1753
|
[
|
|
1761
1754
|
///////////////////
|
|
1762
1755
|
// CONSOLES
|
|
@@ -1766,22 +1759,22 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
1766
1759
|
/(nintendo) (\w+)/i
|
|
1767
1760
|
// Nintendo
|
|
1768
1761
|
],
|
|
1769
|
-
[u,
|
|
1762
|
+
[u, d, [l, K]],
|
|
1770
1763
|
[
|
|
1771
1764
|
/droid.+; (shield) bui/i
|
|
1772
1765
|
// Nvidia
|
|
1773
1766
|
],
|
|
1774
|
-
[
|
|
1767
|
+
[d, [u, "Nvidia"], [l, K]],
|
|
1775
1768
|
[
|
|
1776
1769
|
/(playstation \w+)/i
|
|
1777
1770
|
// Playstation
|
|
1778
1771
|
],
|
|
1779
|
-
[
|
|
1772
|
+
[d, [u, Ae], [l, K]],
|
|
1780
1773
|
[
|
|
1781
1774
|
/\b(xbox(?: one)?(?!; xbox))[\); ]/i
|
|
1782
1775
|
// Microsoft Xbox
|
|
1783
1776
|
],
|
|
1784
|
-
[
|
|
1777
|
+
[d, [u, Ue], [l, K]],
|
|
1785
1778
|
[
|
|
1786
1779
|
///////////////////
|
|
1787
1780
|
// WEARABLES
|
|
@@ -1789,26 +1782,26 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
1789
1782
|
/((pebble))app/i
|
|
1790
1783
|
// Pebble
|
|
1791
1784
|
],
|
|
1792
|
-
[u,
|
|
1785
|
+
[u, d, [l, X]],
|
|
1793
1786
|
[
|
|
1794
1787
|
/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i
|
|
1795
1788
|
// Apple Watch
|
|
1796
1789
|
],
|
|
1797
|
-
[
|
|
1790
|
+
[d, [u, pe], [l, X]],
|
|
1798
1791
|
[
|
|
1799
1792
|
/droid.+; (glass) \d/i
|
|
1800
1793
|
// Google Glass
|
|
1801
1794
|
],
|
|
1802
|
-
[
|
|
1795
|
+
[d, [u, Ie], [l, X]],
|
|
1803
1796
|
[
|
|
1804
1797
|
/droid.+; (wt63?0{2,3})\)/i
|
|
1805
1798
|
],
|
|
1806
|
-
[
|
|
1799
|
+
[d, [u, $e], [l, X]],
|
|
1807
1800
|
[
|
|
1808
1801
|
/(quest( 2| pro)?)/i
|
|
1809
1802
|
// Oculus Quest
|
|
1810
1803
|
],
|
|
1811
|
-
[
|
|
1804
|
+
[d, [u, ft], [l, X]],
|
|
1812
1805
|
[
|
|
1813
1806
|
///////////////////
|
|
1814
1807
|
// EMBEDDED
|
|
@@ -1816,12 +1809,12 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
1816
1809
|
/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i
|
|
1817
1810
|
// Tesla
|
|
1818
1811
|
],
|
|
1819
|
-
[u, [
|
|
1812
|
+
[u, [l, Ye]],
|
|
1820
1813
|
[
|
|
1821
1814
|
/(aeobc)\b/i
|
|
1822
1815
|
// Echo Dot
|
|
1823
1816
|
],
|
|
1824
|
-
[
|
|
1817
|
+
[d, [u, Ce], [l, Ye]],
|
|
1825
1818
|
[
|
|
1826
1819
|
////////////////////
|
|
1827
1820
|
// MIXED (GENERIC)
|
|
@@ -1829,27 +1822,27 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
1829
1822
|
/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i
|
|
1830
1823
|
// Android Phones from Unidentified Vendors
|
|
1831
1824
|
],
|
|
1832
|
-
[
|
|
1825
|
+
[d, [l, m]],
|
|
1833
1826
|
[
|
|
1834
1827
|
/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i
|
|
1835
1828
|
// Android Tablets from Unidentified Vendors
|
|
1836
1829
|
],
|
|
1837
|
-
[
|
|
1830
|
+
[d, [l, b]],
|
|
1838
1831
|
[
|
|
1839
1832
|
/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i
|
|
1840
1833
|
// Unidentifiable Tablet
|
|
1841
1834
|
],
|
|
1842
|
-
[[
|
|
1835
|
+
[[l, b]],
|
|
1843
1836
|
[
|
|
1844
1837
|
/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i
|
|
1845
1838
|
// Unidentifiable Mobile
|
|
1846
1839
|
],
|
|
1847
|
-
[[
|
|
1840
|
+
[[l, m]],
|
|
1848
1841
|
[
|
|
1849
1842
|
/(android[-\w\. ]{0,9});.+buil/i
|
|
1850
1843
|
// Generic Android Device
|
|
1851
1844
|
],
|
|
1852
|
-
[
|
|
1845
|
+
[d, [u, "Generic"]]
|
|
1853
1846
|
],
|
|
1854
1847
|
engine: [
|
|
1855
1848
|
[
|
|
@@ -2023,7 +2016,7 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
2023
2016
|
return _.call(i.init, [
|
|
2024
2017
|
[T, [o, r, fe]],
|
|
2025
2018
|
[O, [M]],
|
|
2026
|
-
[P, [
|
|
2019
|
+
[P, [l, d, u]],
|
|
2027
2020
|
[L, [o, r]],
|
|
2028
2021
|
[R, [o, r]]
|
|
2029
2022
|
]), _.call(i.isIgnore, [
|
|
@@ -2036,12 +2029,12 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
2036
2029
|
]), _.call(i.toString, [
|
|
2037
2030
|
[T, [o, r]],
|
|
2038
2031
|
[O, [M]],
|
|
2039
|
-
[P, [u,
|
|
2032
|
+
[P, [u, d]],
|
|
2040
2033
|
[L, [o, r]],
|
|
2041
2034
|
[R, [o, r]]
|
|
2042
2035
|
]), i;
|
|
2043
2036
|
}(), fi = function(i, t) {
|
|
2044
|
-
var e = Pe.init[t], s = Pe.isIgnore[t] || 0, n = Pe.isIgnoreRgx[t] || 0,
|
|
2037
|
+
var e = Pe.init[t], s = Pe.isIgnore[t] || 0, n = Pe.isIgnoreRgx[t] || 0, c = Pe.toString[t] || 0;
|
|
2045
2038
|
function a() {
|
|
2046
2039
|
_.call(this, e);
|
|
2047
2040
|
}
|
|
@@ -2066,8 +2059,8 @@ var oi = "2.0.0-beta.2", re = "", dt = "?", Ke = "function", H = "undefined", ce
|
|
|
2066
2059
|
return p;
|
|
2067
2060
|
}, a.prototype.toString = function() {
|
|
2068
2061
|
var h = re;
|
|
2069
|
-
for (var p in
|
|
2070
|
-
typeof this[
|
|
2062
|
+
for (var p in c)
|
|
2063
|
+
typeof this[c[p]] !== H && (h += (h ? " " : re) + this[c[p]]);
|
|
2071
2064
|
return h || H;
|
|
2072
2065
|
}), G || (a.prototype.then = function(h) {
|
|
2073
2066
|
var p = this, g = function() {
|
|
@@ -2088,8 +2081,8 @@ function Lt(i, t) {
|
|
|
2088
2081
|
[it, je(i[V])],
|
|
2089
2082
|
[st, je(i[ri])],
|
|
2090
2083
|
[m, /\?1/.test(i[ui])],
|
|
2091
|
-
[
|
|
2092
|
-
[J, me(i[
|
|
2084
|
+
[d, me(i[hi])],
|
|
2085
|
+
[J, me(i[Ut])],
|
|
2093
2086
|
[nt, me(i[pi])],
|
|
2094
2087
|
[M, me(i[ci])],
|
|
2095
2088
|
[q, je(i[li])],
|
|
@@ -2102,8 +2095,8 @@ function Lt(i, t) {
|
|
|
2102
2095
|
function Mt(i, t, e, s) {
|
|
2103
2096
|
return this.get = function(n) {
|
|
2104
2097
|
return n ? this.data.hasOwnProperty(n) ? this.data[n] : void 0 : this.data;
|
|
2105
|
-
}, this.set = function(n,
|
|
2106
|
-
return this.data[n] =
|
|
2098
|
+
}, this.set = function(n, c) {
|
|
2099
|
+
return this.data[n] = c, this;
|
|
2107
2100
|
}, this.setCH = function(n) {
|
|
2108
2101
|
return this.uaCH = n, this;
|
|
2109
2102
|
}, this.detectFeature = function() {
|
|
@@ -2113,22 +2106,22 @@ function Mt(i, t, e, s) {
|
|
|
2113
2106
|
C.brave && typeof C.brave.isBrave == Ke && this.set(o, "Brave");
|
|
2114
2107
|
break;
|
|
2115
2108
|
case P:
|
|
2116
|
-
!this.get(
|
|
2109
|
+
!this.get(l) && G && G[m] && this.set(l, m), this.get(d) == "Macintosh" && C && typeof C.standalone !== H && C.maxTouchPoints && C.maxTouchPoints > 2 && this.set(d, "iPad").set(l, b);
|
|
2117
2110
|
break;
|
|
2118
2111
|
case R:
|
|
2119
2112
|
!this.get(o) && G && G[J] && this.set(o, G[J]);
|
|
2120
2113
|
break;
|
|
2121
2114
|
case Y:
|
|
2122
|
-
var n = this.data,
|
|
2115
|
+
var n = this.data, c = function(a) {
|
|
2123
2116
|
return n[a].getItem().detectFeature().get();
|
|
2124
2117
|
};
|
|
2125
|
-
this.set(T,
|
|
2118
|
+
this.set(T, c(T)).set(O, c(O)).set(P, c(P)).set(L, c(L)).set(R, c(R));
|
|
2126
2119
|
}
|
|
2127
2120
|
return this;
|
|
2128
2121
|
}, this.parseUA = function() {
|
|
2129
2122
|
return this.itemType != Y && Et.call(this.data, this.ua, this.rgxMap), this.itemType == T && this.set(fe, Qe(this.get(r))), this;
|
|
2130
2123
|
}, this.parseCH = function() {
|
|
2131
|
-
var n = this.uaCH,
|
|
2124
|
+
var n = this.uaCH, c = this.rgxMap;
|
|
2132
2125
|
switch (this.itemType) {
|
|
2133
2126
|
case T:
|
|
2134
2127
|
var a = n[st] || n[it], h;
|
|
@@ -2140,26 +2133,26 @@ function Mt(i, t, e, s) {
|
|
|
2140
2133
|
break;
|
|
2141
2134
|
case O:
|
|
2142
2135
|
var A = n[M];
|
|
2143
|
-
A && (A && n[De] == "64" && (A += "64"), Et.call(this.data, A + ";",
|
|
2136
|
+
A && (A && n[De] == "64" && (A += "64"), Et.call(this.data, A + ";", c));
|
|
2144
2137
|
break;
|
|
2145
2138
|
case P:
|
|
2146
|
-
if (n[m] && this.set(
|
|
2139
|
+
if (n[m] && this.set(l, m), n[d] && this.set(d, n[d]), n[d] == "Xbox" && this.set(l, K).set(u, Ue), n[q]) {
|
|
2147
2140
|
var D;
|
|
2148
2141
|
if (typeof n[q] != "string")
|
|
2149
2142
|
for (var B = 0; !D && B < n[q].length; )
|
|
2150
2143
|
D = Oe(n[q][B++], kt);
|
|
2151
2144
|
else
|
|
2152
2145
|
D = Oe(n[q], kt);
|
|
2153
|
-
this.set(
|
|
2146
|
+
this.set(l, D);
|
|
2154
2147
|
}
|
|
2155
2148
|
break;
|
|
2156
2149
|
case R:
|
|
2157
2150
|
var le = n[J];
|
|
2158
2151
|
if (le) {
|
|
2159
|
-
var
|
|
2160
|
-
le == et && (
|
|
2152
|
+
var U = n[nt];
|
|
2153
|
+
le == et && (U = parseInt(Qe(U), 10) >= 13 ? "11" : "10"), this.set(o, le).set(r, U);
|
|
2161
2154
|
}
|
|
2162
|
-
this.get(o) == et && n[
|
|
2155
|
+
this.get(o) == et && n[d] == "Xbox" && this.set(o, "Xbox").set(r, void 0);
|
|
2163
2156
|
break;
|
|
2164
2157
|
case Y:
|
|
2165
2158
|
var Ft = this.data, ue = function(Dt) {
|
|
@@ -2188,11 +2181,11 @@ function F(i, t, e) {
|
|
|
2188
2181
|
re
|
|
2189
2182
|
)
|
|
2190
2183
|
)
|
|
2191
|
-
), n = new Lt(e, !0),
|
|
2184
|
+
), n = new Lt(e, !0), c = t ? mi(St, t) : St, a = function(h) {
|
|
2192
2185
|
return h == Y ? function() {
|
|
2193
|
-
return new Mt(h, s,
|
|
2186
|
+
return new Mt(h, s, c, n).set("ua", s).set(T, this.getBrowser()).set(O, this.getCPU()).set(P, this.getDevice()).set(L, this.getEngine()).set(R, this.getOS()).get();
|
|
2194
2187
|
} : function() {
|
|
2195
|
-
return new Mt(h, s,
|
|
2188
|
+
return new Mt(h, s, c[h], n).parseUA().get();
|
|
2196
2189
|
};
|
|
2197
2190
|
};
|
|
2198
2191
|
return _.call(this, [
|
|
@@ -2213,7 +2206,7 @@ function F(i, t, e) {
|
|
|
2213
2206
|
F.VERSION = oi;
|
|
2214
2207
|
F.BROWSER = Be([o, r, fe]);
|
|
2215
2208
|
F.CPU = Be([M]);
|
|
2216
|
-
F.DEVICE = Be([
|
|
2209
|
+
F.DEVICE = Be([d, u, l, K, m, I, b, X, Ye]);
|
|
2217
2210
|
F.ENGINE = F.OS = Be([o, r]);
|
|
2218
2211
|
class bi {
|
|
2219
2212
|
constructor(t, e) {
|
|
@@ -2235,7 +2228,7 @@ function Ct(i) {
|
|
|
2235
2228
|
return i.reduce((t, e) => t + e, 0);
|
|
2236
2229
|
}
|
|
2237
2230
|
function yi(i) {
|
|
2238
|
-
const t = i.length, e = Ct(i) / t, s = i.map((
|
|
2231
|
+
const t = i.length, e = Ct(i) / t, s = i.map((c) => Math.pow(c - e, 2)), n = Ct(s) / t;
|
|
2239
2232
|
return Math.sqrt(n);
|
|
2240
2233
|
}
|
|
2241
2234
|
class It {
|
|
@@ -2246,11 +2239,11 @@ class It {
|
|
|
2246
2239
|
w(this, "frames", []);
|
|
2247
2240
|
w(this, "calculateFPS", () => {
|
|
2248
2241
|
const t = Math.floor((this.stopTime - this.startTime) / 1e3);
|
|
2249
|
-
return this.frames.map((e) => Math.floor((e - this.startTime) / 1e3)).reduce((e, s, n,
|
|
2242
|
+
return this.frames.map((e) => Math.floor((e - this.startTime) / 1e3)).reduce((e, s, n, c) => (c[n] !== c[n - 1] ? e.push(1) : e[e.length - 1]++, e), []).slice(0, t);
|
|
2250
2243
|
});
|
|
2251
2244
|
w(this, "getReport", () => {
|
|
2252
|
-
const t = this.calculateFPS(), e = Math.floor(this.frames.length / ((this.stopTime - this.startTime) / 1e3)), s = t.length > 0 ? Math.max(...t) : e, n = t.length > 0 ? Math.min(...t) : e,
|
|
2253
|
-
return { fpsAvg: e, fpsMax: s, fpsMin: n, fpsStdDev:
|
|
2245
|
+
const t = this.calculateFPS(), e = Math.floor(this.frames.length / ((this.stopTime - this.startTime) / 1e3)), s = t.length > 0 ? Math.max(...t) : e, n = t.length > 0 ? Math.min(...t) : e, c = t.length > 0 ? yi(t) : 0;
|
|
2246
|
+
return { fpsAvg: e, fpsMax: s, fpsMin: n, fpsStdDev: c };
|
|
2254
2247
|
});
|
|
2255
2248
|
w(this, "start", () => {
|
|
2256
2249
|
this.startTime = Date.now(), this.trackFrames();
|
|
@@ -2348,13 +2341,13 @@ class Gi extends bi {
|
|
|
2348
2341
|
// testVariants: '',
|
|
2349
2342
|
}), this.track("Game Open", y(this, te));
|
|
2350
2343
|
}), this.on("playCycleEnd", async (e) => {
|
|
2351
|
-
const s = await y(this, ie), { baseBet: n, betMultiplier:
|
|
2344
|
+
const s = await y(this, ie), { baseBet: n, betMultiplier: c, specialAction: a } = e.data.gameState.lastPlacedMainGameBet ?? {}, h = e.balance, p = e.data.gameState.totalBetFromCurrentGameCycle, g = e.data.gameState.totalWinFromCurrentGameCycle, f = g - p, A = a || "spin", D = e.data.gameState.cycleId;
|
|
2352
2345
|
this.track("Betting Activity", {
|
|
2353
2346
|
balance: h - f,
|
|
2354
2347
|
balanceAfter: h,
|
|
2355
2348
|
baseBet: n,
|
|
2356
2349
|
// baseBetIndex,
|
|
2357
|
-
betMultiplier:
|
|
2350
|
+
betMultiplier: c,
|
|
2358
2351
|
betType: A,
|
|
2359
2352
|
gameVersion: y(this, ee),
|
|
2360
2353
|
coinValueInCents: this.config.api.coinValueInCents,
|
|
@@ -2394,8 +2387,8 @@ class Gi extends bi {
|
|
|
2394
2387
|
reportFpsSample() {
|
|
2395
2388
|
const e = new It(), s = () => {
|
|
2396
2389
|
e.stop();
|
|
2397
|
-
const
|
|
2398
|
-
this.track("FPS Performance", { ...
|
|
2390
|
+
const c = e.getReport();
|
|
2391
|
+
this.track("FPS Performance", { ...c, fpsType: "sample" }), n();
|
|
2399
2392
|
}, n = async () => {
|
|
2400
2393
|
e.start(), setTimeout(s, this.FPS_SAMPLE_INTERVAL);
|
|
2401
2394
|
};
|
|
@@ -2419,10 +2412,10 @@ class Gi extends bi {
|
|
|
2419
2412
|
}
|
|
2420
2413
|
async deviceInfo() {
|
|
2421
2414
|
var p;
|
|
2422
|
-
const e = new F(navigator.userAgent), s = ki(), n = await Si(),
|
|
2415
|
+
const e = new F(navigator.userAgent), s = ki(), n = await Si(), c = e.getBrowser(), a = e.getDevice(), h = e.getOS();
|
|
2423
2416
|
return {
|
|
2424
|
-
browserName:
|
|
2425
|
-
browserVersion:
|
|
2417
|
+
browserName: c.name,
|
|
2418
|
+
browserVersion: c.version,
|
|
2426
2419
|
connection: (p = navigator.connection) == null ? void 0 : p.effectiveType,
|
|
2427
2420
|
deviceName: a.model,
|
|
2428
2421
|
deviceType: a.type,
|
|
@@ -2445,12 +2438,12 @@ class Gi extends bi {
|
|
|
2445
2438
|
}
|
|
2446
2439
|
}
|
|
2447
2440
|
Le = new WeakMap(), ee = new WeakMap(), te = new WeakMap(), ie = new WeakMap(), ve = new WeakMap(), _e = new WeakMap(), ke = new WeakMap(), Fe = new WeakMap();
|
|
2448
|
-
let
|
|
2441
|
+
let xe;
|
|
2449
2442
|
const Mi = new Uint8Array(16);
|
|
2450
2443
|
function Ci() {
|
|
2451
|
-
if (!
|
|
2444
|
+
if (!xe && (xe = typeof crypto < "u" && crypto.getRandomValues && crypto.getRandomValues.bind(crypto), !xe))
|
|
2452
2445
|
throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
|
|
2453
|
-
return
|
|
2446
|
+
return xe(Mi);
|
|
2454
2447
|
}
|
|
2455
2448
|
const S = [];
|
|
2456
2449
|
for (let i = 0; i < 256; ++i)
|
|
@@ -2541,16 +2534,16 @@ class Ni extends _t {
|
|
|
2541
2534
|
}
|
|
2542
2535
|
}
|
|
2543
2536
|
se = new WeakMap(), ne = new WeakMap(), ae = new WeakMap(), N = new WeakMap(), Se = new WeakMap();
|
|
2544
|
-
const Ai =
|
|
2537
|
+
const Ai = x("LoggingTracker", "color:#000000;font-weight:bold;");
|
|
2545
2538
|
class Hi extends _t {
|
|
2546
2539
|
track(t, e) {
|
|
2547
2540
|
Ai(`@${this.config.api.user}`, `[${t}]`, e);
|
|
2548
2541
|
}
|
|
2549
2542
|
}
|
|
2550
2543
|
export {
|
|
2551
|
-
|
|
2544
|
+
xi as BasicPlugin,
|
|
2552
2545
|
$ as CasinoPlugin,
|
|
2553
|
-
|
|
2546
|
+
Ui as DebuggingPlugin,
|
|
2554
2547
|
Oi as GigPlugin,
|
|
2555
2548
|
Bi as KalambaBullseyePlugin,
|
|
2556
2549
|
Gi as KalambaStargazerPlugin,
|