@jumio/websdk 0.3.8 → 0.3.10
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/README.md +10 -8
- package/assets/BRAZILIAN_ID.BychxTsM.webp +0 -0
- package/assets/BRAZILIAN_ID.COOwtpxb.js +5 -0
- package/assets/style.css +1 -388
- package/dd/profiler-DTWkT7Mn.js +235 -0
- package/dd/startRecording-DqW-BV0C.js +1494 -0
- package/{ar.6FvD271D.js → i18n/ar.ClpiOMp8.js} +18 -6
- package/{az.xV1CTm4w.js → i18n/az.Zjkmxx0W.js} +17 -5
- package/{bg.CCHtVJ8V.js → i18n/bg.TQ5gDhpN.js} +17 -5
- package/{bn.DDCfJGfy.js → i18n/bn.DqLfaDm8.js} +18 -6
- package/{ca.BmzzNtsu.js → i18n/ca.N1Ii2N6w.js} +17 -5
- package/{ceb.DP4PBOky.js → i18n/ceb.DGoxFAno.js} +17 -5
- package/{cs.CF_-gGCz.js → i18n/cs.B219Ze7G.js} +17 -5
- package/{da.BvNYfmLS.js → i18n/da.BmYd7JeC.js} +18 -6
- package/{de.ChoKs_Ih.js → i18n/de.4yYjZHjq.js} +17 -5
- package/{el.CmH9V0Yg.js → i18n/el.w7n6P_Tm.js} +17 -5
- package/{en._TYEyLHi.js → i18n/en.Ct44TlJ6.js} +15 -3
- package/{en_GB.0E4-hrRx.js → i18n/en_GB.DZfrkPbd.js} +15 -3
- package/{es.D__FE4D_.js → i18n/es.DcA3jLM9.js} +17 -5
- package/{es_MX.Db15FX9q.js → i18n/es_MX.ClqTjKZ-.js} +17 -5
- package/{et.Gn0z9Ivj.js → i18n/et.MMOd-uTo.js} +17 -5
- package/{fi.DzSyn__-.js → i18n/fi.CWbrDO4V.js} +17 -5
- package/{fil.DbXgzFds.js → i18n/fil.BJfPVW56.js} +17 -5
- package/{fr.Nad_Iv9w.js → i18n/fr.CjZ5cmiI.js} +17 -5
- package/{fr_CA.BqIhyqJg.js → i18n/fr_CA.CtHm7-qi.js} +19 -7
- package/{ga.DZftCvLf.js → i18n/ga.D6-1kfWr.js} +17 -5
- package/{he.D_Ot5G9X.js → i18n/he.Bi8juarT.js} +17 -5
- package/{hi.k1gL9P6R.js → i18n/hi.CFfDmSnf.js} +19 -7
- package/{hr.CFkMZjpr.js → i18n/hr.DZlUE7C8.js} +16 -4
- package/{hu.ChFZfAE3.js → i18n/hu.BpD-aMLX.js} +17 -5
- package/{hy.DNM9FTFD.js → i18n/hy.BaLqt_2N.js} +17 -5
- package/{id.CUwbO5IH.js → i18n/id.uRdF9gWF.js} +17 -5
- package/{is.hApbPYEY.js → i18n/is.BYQe-WHx.js} +17 -5
- package/{it.Bhegj4nF.js → i18n/it.CkU67L1U.js} +17 -5
- package/{ja.CJXtbCJw.js → i18n/ja.BH3qTT3H.js} +17 -5
- package/{jv.DQNROsUW.js → i18n/jv.B4fRWclO.js} +17 -5
- package/{ka_GE.DRQWZxDK.js → i18n/ka_GE.CTzSn9eo.js} +17 -5
- package/{kk.SmX8cO85.js → i18n/kk.C0siUu93.js} +17 -5
- package/{km_KH.tErSrUl8.js → i18n/km_KH.ZTbV01Qz.js} +17 -5
- package/{ko.BSuxjnwo.js → i18n/ko.Bb4J3kDH.js} +17 -5
- package/{lt.9xY-bF8b.js → i18n/lt.D3asVxYB.js} +16 -4
- package/{lv.KAJ3Th5c.js → i18n/lv.fkwne764.js} +17 -5
- package/{ms.B8ifUn3g.js → i18n/ms.DEHT6MDZ.js} +17 -5
- package/{my.46LpbgwX.js → i18n/my.CRVpYNLc.js} +17 -5
- package/{nl.jT_sFmTM.js → i18n/nl.DV_Z3712.js} +17 -5
- package/{no.C7sncEKD.js → i18n/no.C91-fx2t.js} +17 -5
- package/{pl.5XkGPjIZ.js → i18n/pl.deHkL4G-.js} +17 -5
- package/{pt.DgAAo08E.js → i18n/pt.D7DApQ_g.js} +17 -5
- package/{pt_BR.DEMIQWXD.js → i18n/pt_BR.DeWUm5I5.js} +17 -5
- package/{ro.O04ahCMK.js → i18n/ro.Bgy4hiF2.js} +17 -5
- package/{ru.58VavBFj.js → i18n/ru.Cn-5tOIR.js} +17 -5
- package/{sk.CKOgMaWx.js → i18n/sk.rlnyfpQR.js} +17 -5
- package/{sl.T6u4zQdv.js → i18n/sl.BHBnOa58.js} +21 -9
- package/{sq.DhxxMSD4.js → i18n/sq.qB--p25v.js} +17 -5
- package/{sr_Cyrl.ScPJhaK1.js → i18n/sr_Cyrl.CSBzkXjX.js} +16 -4
- package/{sr_Latn.ClgaYy2P.js → i18n/sr_Latn._nXdqCNI.js} +16 -4
- package/{sv.BqoHH9_Z.js → i18n/sv.exooz9wm.js} +17 -5
- package/{sw.ASoszWzl.js → i18n/sw.BrOra_jt.js} +16 -4
- package/{th.wQot4sEY.js → i18n/th.LZGAQSSx.js} +17 -5
- package/{tr.BgMiJg4a.js → i18n/tr.Dizt7E2M.js} +17 -5
- package/{uk.ODxwJ7HV.js → i18n/uk.xMYrw91N.js} +17 -5
- package/{ur.CE1x0LsE.js → i18n/ur.BmuWXUfh.js} +18 -6
- package/{uz.DBb8NWV6.js → i18n/uz.CzsxPnXQ.js} +21 -9
- package/{vi.DTsjGEnr.js → i18n/vi.B_KdJnMy.js} +17 -5
- package/{zh_CN.C898bOEl.js → i18n/zh_CN.BBdQPt4L.js} +17 -5
- package/{zh_HK.Bi_0oROP.js → i18n/zh_HK.BRzNtOzu.js} +17 -5
- package/index.BloC8BH6.js +64242 -0
- package/index.d.ts +3599 -1043
- package/index.html +41 -13
- package/index.js +24 -822
- package/index2.js +869 -0
- package/ml/assets_da_web_1_1_6.tar.D1WfMJyS.gz +0 -0
- package/ml/assets_da_web_1_1_6.tar.DmSCvmf5.js +5 -0
- package/ml/dac.D2xph-5h.js +5 -0
- package/ml/dac.DeLxs2vM.wasm +0 -0
- package/ml/dac_simd.2xjZJ5dE.js +5 -0
- package/ml/dac_simd.BHe9yV3l.wasm +0 -0
- package/package.json +8 -4
- package/pdfjs/pdf-U_mH0bJO.js +17500 -0
- package/pdfjs/pdf.worker.min-DFxVranA.js +5 -0
- package/third-party-licenses.txt +1684 -8532
- package/BRAZILIAN_ID.BmZRIYzL.js +0 -5
- package/CHANGELOG.md +0 -106
- package/assets/fonts/jumio-sdk-icomoon.svg +0 -117
- package/assets/fonts/jumio-sdk-icomoon.ttf +0 -0
- package/assets/fonts/jumio-sdk-icomoon.woff +0 -0
- package/assets_da_web_1_1_6.tar.CCpLQ2oJ.js +0 -5
- package/dac.C1nISBeT.js +0 -5
- package/dac_simd.CQrYamf5.js +0 -5
- package/index.C0rkfp1G.js +0 -60487
- package/pdfjs/pdf-DDTuoCrJ.js +0 -17532
- package/pdfjs/pdf.worker.min-BJaB4MSa.js +0 -5
- package/profiler.B7SF_C2Q.js +0 -278
- package/startRecording.BFOwOm6d.js +0 -1227
package/profiler.B7SF_C2Q.js
DELETED
|
@@ -1,278 +0,0 @@
|
|
|
1
|
-
import { c as x, j as O, o as J, a as Q, R as W, b as Y, d as Z, s as $, e as ee, f as T, g as M, h as te, m as I, i as ne, k as se, l as re, n as oe, p as ae, r as ie } from "./index.C0rkfp1G.js";
|
|
2
|
-
function le(e, t, o, a) {
|
|
3
|
-
const f = (d) => {
|
|
4
|
-
t.notify(14, { error: d }), Q("Error reported to customer", { "error.message": d.message });
|
|
5
|
-
}, l = x([e.profilingEndpointBuilder], e.batchBytesLimit, f), p = o(a);
|
|
6
|
-
return {
|
|
7
|
-
async send({ event: d, ...h }) {
|
|
8
|
-
const v = new FormData(), s = O(d);
|
|
9
|
-
if (!s)
|
|
10
|
-
throw new Error("Failed to serialize event");
|
|
11
|
-
v.append("event", new Blob([s], { type: "application/json" }), "event.json");
|
|
12
|
-
let w = s.length;
|
|
13
|
-
for (const [k, E] of J(h)) {
|
|
14
|
-
const m = O(E);
|
|
15
|
-
if (!m)
|
|
16
|
-
throw new Error("Failed to serialize attachment");
|
|
17
|
-
const g = await ce(p, m);
|
|
18
|
-
w += g.outputBytesCount, v.append(k, new Blob([g.output]), k);
|
|
19
|
-
}
|
|
20
|
-
l.send({
|
|
21
|
-
data: v,
|
|
22
|
-
bytesCount: w
|
|
23
|
-
});
|
|
24
|
-
}
|
|
25
|
-
};
|
|
26
|
-
}
|
|
27
|
-
function ce(e, t) {
|
|
28
|
-
return new Promise((o) => {
|
|
29
|
-
e.write(t), e.finish((a) => {
|
|
30
|
-
o(a);
|
|
31
|
-
});
|
|
32
|
-
});
|
|
33
|
-
}
|
|
34
|
-
function ue(e) {
|
|
35
|
-
let t = 0;
|
|
36
|
-
for (const o of e)
|
|
37
|
-
o.stackId !== void 0 && t++;
|
|
38
|
-
return t;
|
|
39
|
-
}
|
|
40
|
-
const y = /* @__PURE__ */ new Map();
|
|
41
|
-
function de(e, t) {
|
|
42
|
-
y.set(t, e);
|
|
43
|
-
}
|
|
44
|
-
function fe(e) {
|
|
45
|
-
return y.get(e);
|
|
46
|
-
}
|
|
47
|
-
function R(e) {
|
|
48
|
-
for (const t of y.keys())
|
|
49
|
-
t < e && y.delete(t);
|
|
50
|
-
}
|
|
51
|
-
function me({ rawRumEvent: e, startTime: t }) {
|
|
52
|
-
if (e.type !== W.LONG_TASK)
|
|
53
|
-
return;
|
|
54
|
-
const o = e.long_task.id;
|
|
55
|
-
de(o, t);
|
|
56
|
-
}
|
|
57
|
-
const pe = /\/(?![vV]\d{1,2}\/)([^/\d?]*\d+[^/?]*)/g;
|
|
58
|
-
function ve(e) {
|
|
59
|
-
return e ? e.replace(pe, "/?") : "/";
|
|
60
|
-
}
|
|
61
|
-
const A = (e, t) => e || ve(t);
|
|
62
|
-
function be(e, t, o) {
|
|
63
|
-
const a = {
|
|
64
|
-
application: {
|
|
65
|
-
id: t
|
|
66
|
-
}
|
|
67
|
-
};
|
|
68
|
-
o && (a.session = {
|
|
69
|
-
id: o
|
|
70
|
-
});
|
|
71
|
-
const { ids: f, names: l } = he(e.views);
|
|
72
|
-
f.length && (a.view = {
|
|
73
|
-
id: f,
|
|
74
|
-
name: l
|
|
75
|
-
});
|
|
76
|
-
const p = e.longTasks.map((d) => d.id).filter((d) => d !== void 0);
|
|
77
|
-
return p.length && (a.long_task = { id: p }), a;
|
|
78
|
-
}
|
|
79
|
-
function he(e) {
|
|
80
|
-
const t = { ids: [], names: [] };
|
|
81
|
-
for (const o of e)
|
|
82
|
-
t.ids.push(o.viewId), o.viewName && t.names.push(o.viewName);
|
|
83
|
-
return t.names = Array.from(new Set(t.names)), t;
|
|
84
|
-
}
|
|
85
|
-
function ge(e, t, o) {
|
|
86
|
-
return {
|
|
87
|
-
event: we(e, t, o),
|
|
88
|
-
"wall-time.json": e
|
|
89
|
-
};
|
|
90
|
-
}
|
|
91
|
-
function we(e, t, o) {
|
|
92
|
-
const a = Y(t), f = be(e, t.applicationId, o), l = ke(a);
|
|
93
|
-
return {
|
|
94
|
-
...f,
|
|
95
|
-
attachments: ["wall-time.json"],
|
|
96
|
-
start: new Date(e.startClocks.timeStamp).toISOString(),
|
|
97
|
-
end: new Date(e.endClocks.timeStamp).toISOString(),
|
|
98
|
-
family: "chrome",
|
|
99
|
-
runtime: "chrome",
|
|
100
|
-
format: "json",
|
|
101
|
-
version: 4,
|
|
102
|
-
// Ingestion event version (not the version application tag)
|
|
103
|
-
tags_profiler: l.join(","),
|
|
104
|
-
_dd: {
|
|
105
|
-
clock_drift: Z()
|
|
106
|
-
}
|
|
107
|
-
};
|
|
108
|
-
}
|
|
109
|
-
function ke(e) {
|
|
110
|
-
return e.concat(["language:javascript", "runtime:chrome", "family:chrome", "host:browser"]);
|
|
111
|
-
}
|
|
112
|
-
const Te = {
|
|
113
|
-
sampleIntervalMs: 10,
|
|
114
|
-
// Sample stack trace every 10ms
|
|
115
|
-
collectIntervalMs: 6e4,
|
|
116
|
-
// Collect data every minute
|
|
117
|
-
minProfileDurationMs: 5e3,
|
|
118
|
-
// Require at least 5 seconds of profile data to reduce noise and cost
|
|
119
|
-
minNumberOfSamples: 50
|
|
120
|
-
// Require at least 50 samples (~500 ms) to report a profile to reduce noise and cost
|
|
121
|
-
};
|
|
122
|
-
function Ee(e, t, o, a, f, l = Te) {
|
|
123
|
-
const p = le(
|
|
124
|
-
e,
|
|
125
|
-
t,
|
|
126
|
-
f,
|
|
127
|
-
6
|
|
128
|
-
/* DeflateEncoderStreamId.PROFILING */
|
|
129
|
-
), d = $(ee.LONG_ANIMATION_FRAME);
|
|
130
|
-
let h;
|
|
131
|
-
const v = [];
|
|
132
|
-
let s = { state: "stopped" };
|
|
133
|
-
function w(n) {
|
|
134
|
-
s.state !== "running" && (h = n ? {
|
|
135
|
-
startClocks: n.startClocks,
|
|
136
|
-
viewId: n.id,
|
|
137
|
-
viewName: A(n.name, document.location.pathname)
|
|
138
|
-
} : void 0, v.push(M(e, window, "visibilitychange", B).stop, M(e, window, "beforeunload", C).stop), m());
|
|
139
|
-
}
|
|
140
|
-
async function k() {
|
|
141
|
-
await P("stopped"), v.forEach((n) => n()), R(T().relative), a.set({ status: "stopped", error_reason: void 0 });
|
|
142
|
-
}
|
|
143
|
-
function E(n) {
|
|
144
|
-
if (n.state === "running")
|
|
145
|
-
return {
|
|
146
|
-
cleanupTasks: n.cleanupTasks,
|
|
147
|
-
observer: n.observer
|
|
148
|
-
};
|
|
149
|
-
const r = [];
|
|
150
|
-
let i;
|
|
151
|
-
if (e.trackLongTasks) {
|
|
152
|
-
i = new PerformanceObserver(F), i.observe({
|
|
153
|
-
entryTypes: [V()]
|
|
154
|
-
});
|
|
155
|
-
const u = t.subscribe(12, (b) => {
|
|
156
|
-
me(b);
|
|
157
|
-
});
|
|
158
|
-
r.push(() => i == null ? void 0 : i.disconnect()), r.push(u.unsubscribe);
|
|
159
|
-
}
|
|
160
|
-
const c = t.subscribe(2, (u) => {
|
|
161
|
-
const b = {
|
|
162
|
-
viewId: u.id,
|
|
163
|
-
// Note: `viewName` is only filled when users use manual view creation via `startView` method.
|
|
164
|
-
viewName: A(u.name, document.location.pathname),
|
|
165
|
-
startClocks: u.startClocks
|
|
166
|
-
};
|
|
167
|
-
S(b), h = b;
|
|
168
|
-
});
|
|
169
|
-
return r.push(c.unsubscribe), {
|
|
170
|
-
cleanupTasks: r,
|
|
171
|
-
observer: i
|
|
172
|
-
};
|
|
173
|
-
}
|
|
174
|
-
function m() {
|
|
175
|
-
const n = te().Profiler;
|
|
176
|
-
if (!n)
|
|
177
|
-
throw a.set({ status: "error", error_reason: "not-supported-by-browser" }), new Error("RUM Profiler is not supported in this browser.");
|
|
178
|
-
g(s).catch(I);
|
|
179
|
-
const { cleanupTasks: r, observer: i } = E(s);
|
|
180
|
-
let c;
|
|
181
|
-
try {
|
|
182
|
-
c = new n({
|
|
183
|
-
sampleInterval: l.sampleIntervalMs,
|
|
184
|
-
// Keep buffer size at 1.5 times of minimum required to collect data for a profiling instance
|
|
185
|
-
maxBufferSize: Math.round(l.collectIntervalMs * 1.5 / l.sampleIntervalMs)
|
|
186
|
-
});
|
|
187
|
-
} catch (u) {
|
|
188
|
-
u instanceof Error && u.message.includes("disabled by Document Policy") ? (ne.warn("[DD_RUM] Profiler startup failed. Ensure your server includes the `Document-Policy: js-profiling` response header when serving HTML pages.", u), a.set({ status: "error", error_reason: "missing-document-policy-header" })) : a.set({ status: "error", error_reason: "unexpected-exception" });
|
|
189
|
-
return;
|
|
190
|
-
}
|
|
191
|
-
a.set({ status: "running", error_reason: void 0 }), s = {
|
|
192
|
-
state: "running",
|
|
193
|
-
startClocks: T(),
|
|
194
|
-
profiler: c,
|
|
195
|
-
timeoutId: se(m, l.collectIntervalMs),
|
|
196
|
-
longTasks: [],
|
|
197
|
-
views: [],
|
|
198
|
-
cleanupTasks: r,
|
|
199
|
-
observer: i
|
|
200
|
-
}, S(h), c.addEventListener("samplebufferfull", _);
|
|
201
|
-
}
|
|
202
|
-
async function g(n) {
|
|
203
|
-
var r, i;
|
|
204
|
-
if (n.state !== "running")
|
|
205
|
-
return;
|
|
206
|
-
L((i = (r = n.observer) === null || r === void 0 ? void 0 : r.takeRecords()) !== null && i !== void 0 ? i : []), re(n.timeoutId), n.profiler.removeEventListener("samplebufferfull", _);
|
|
207
|
-
const { startClocks: c, longTasks: u, views: b } = n, H = T();
|
|
208
|
-
await n.profiler.stop().then((N) => {
|
|
209
|
-
const D = T(), q = u.length > 0, K = oe(c.timeStamp, D.timeStamp) < l.minProfileDurationMs, X = ue(N.samples) < l.minNumberOfSamples;
|
|
210
|
-
!q && (K || X) || (j(
|
|
211
|
-
// Enrich trace with time and instance data
|
|
212
|
-
Object.assign(N, {
|
|
213
|
-
startClocks: c,
|
|
214
|
-
endClocks: D,
|
|
215
|
-
clocksOrigin: ae(),
|
|
216
|
-
longTasks: u,
|
|
217
|
-
views: b,
|
|
218
|
-
sampleInterval: l.sampleIntervalMs
|
|
219
|
-
})
|
|
220
|
-
), R(H.relative));
|
|
221
|
-
}).catch(I);
|
|
222
|
-
}
|
|
223
|
-
async function P(n) {
|
|
224
|
-
s.state === "running" && (s.cleanupTasks.forEach((r) => r()), await g(s), s = { state: n });
|
|
225
|
-
}
|
|
226
|
-
function S(n) {
|
|
227
|
-
s.state !== "running" || !n || s.views.push(n);
|
|
228
|
-
}
|
|
229
|
-
function j(n) {
|
|
230
|
-
var r;
|
|
231
|
-
const i = (r = o.findTrackedSession()) === null || r === void 0 ? void 0 : r.id, c = ge(n, e, i);
|
|
232
|
-
p.send(c);
|
|
233
|
-
}
|
|
234
|
-
function _() {
|
|
235
|
-
m();
|
|
236
|
-
}
|
|
237
|
-
function F(n) {
|
|
238
|
-
L(n.getEntries());
|
|
239
|
-
}
|
|
240
|
-
function L(n) {
|
|
241
|
-
if (s.state === "running")
|
|
242
|
-
for (const r of n) {
|
|
243
|
-
if (r.duration < l.sampleIntervalMs)
|
|
244
|
-
continue;
|
|
245
|
-
const i = ie(r.startTime), c = fe(i.relative);
|
|
246
|
-
s.longTasks.push({
|
|
247
|
-
id: c,
|
|
248
|
-
duration: r.duration,
|
|
249
|
-
entryType: r.entryType,
|
|
250
|
-
startClocks: i
|
|
251
|
-
});
|
|
252
|
-
}
|
|
253
|
-
}
|
|
254
|
-
function B() {
|
|
255
|
-
document.visibilityState === "hidden" && s.state === "running" ? P("paused").catch(I) : document.visibilityState === "visible" && s.state === "paused" && m();
|
|
256
|
-
}
|
|
257
|
-
function C() {
|
|
258
|
-
m();
|
|
259
|
-
}
|
|
260
|
-
function V() {
|
|
261
|
-
return d ? "long-animation-frame" : "longtask";
|
|
262
|
-
}
|
|
263
|
-
function U() {
|
|
264
|
-
return s.state === "stopped";
|
|
265
|
-
}
|
|
266
|
-
function z() {
|
|
267
|
-
return s.state === "running";
|
|
268
|
-
}
|
|
269
|
-
function G() {
|
|
270
|
-
return s.state === "paused";
|
|
271
|
-
}
|
|
272
|
-
return { start: w, stop: k, isStopped: U, isRunning: z, isPaused: G };
|
|
273
|
-
}
|
|
274
|
-
export {
|
|
275
|
-
Te as DEFAULT_RUM_PROFILER_CONFIGURATION,
|
|
276
|
-
Ee as createRumProfiler
|
|
277
|
-
};
|
|
278
|
-
//# sourceMappingURL=profiler.B7SF_C2Q.js.map
|