aibox-web-tracing 0.0.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/es/index.mjs ADDED
@@ -0,0 +1,3702 @@
1
+ import { ref as qt, computed as Pt, watch as $t } from "vue";
2
+ import { record as Qt } from "rrweb";
3
+ import xt from "pako";
4
+ import { Base64 as Ae } from "js-base64";
5
+ function ee(e) {
6
+ return function(t) {
7
+ return Object.prototype.toString.call(t) === `[object ${e}]`;
8
+ };
9
+ }
10
+ const et = ee("RegExp"), Kt = ee("Number"), en = ee("String"), tn = ee("Boolean"), nn = ee("Function"), Te = ee("Array"), rn = ee("Window"), Ce = (e) => tn(e) && String(e) === "false";
11
+ function on(e) {
12
+ return en(e) && e.trim() === "" || e === void 0 || e === null;
13
+ }
14
+ const an = rn(typeof window < "u" ? window : 0), sn = !!window?.process?.versions?.electron, je = typeof navigator < "u" && navigator.userAgent.includes("jsdom") || typeof window < "u" && window.jsdom;
15
+ function Nt() {
16
+ return an || sn || je ? window : {};
17
+ }
18
+ function cn() {
19
+ return p.__webTracing__ = p.__webTracing__ || {}, p.__webTracing__;
20
+ }
21
+ function un() {
22
+ return !!p.__webTracingInit__;
23
+ }
24
+ const p = Nt(), C = cn();
25
+ function ae(...e) {
26
+ d.value.debug && console.log("@web-tracing: ", ...e);
27
+ }
28
+ function se(...e) {
29
+ console.error("@web-tracing: ", ...e);
30
+ }
31
+ function D(e, t, n, r = !1) {
32
+ e.addEventListener(t, n, r);
33
+ }
34
+ function de(e, t, n, r = !1) {
35
+ if (e !== void 0 && (t in e || r)) {
36
+ const o = e[t], a = n(o);
37
+ nn(a) && (e[t] = a);
38
+ }
39
+ }
40
+ function ce(e) {
41
+ return Object.keys(e).forEach((t) => {
42
+ const n = e[t];
43
+ Kt(n) && (e[t] = n === 0 ? void 0 : parseFloat(n.toFixed(2)));
44
+ }), e;
45
+ }
46
+ function F() {
47
+ return typeof document > "u" || document.location == null ? "" : document.location.href;
48
+ }
49
+ function R() {
50
+ return Date.now();
51
+ }
52
+ function Ft(e, t, n = !1) {
53
+ let r = null, o;
54
+ return function(a, ...s) {
55
+ o = s, r === null && (n && e.apply(this, o), r = setTimeout(() => {
56
+ r = null, e.apply(this, o);
57
+ }, t));
58
+ };
59
+ }
60
+ function ln(e, t, n = !1) {
61
+ let r = null;
62
+ return function(o, ...a) {
63
+ n && (e.call(this, ...a), n = !1), r && clearTimeout(r), r = setTimeout(() => {
64
+ e.call(this, ...a);
65
+ }, t);
66
+ };
67
+ }
68
+ function Oe(e, ...t) {
69
+ const n = /* @__PURE__ */ new Map();
70
+ for (const r of e) {
71
+ const o = t.filter((a) => r[a]).map((a) => r[a]).join(":");
72
+ n.has(o) || n.set(o, []), n.get(o).push(r);
73
+ }
74
+ return Array.from(n.values());
75
+ }
76
+ function Ie(e, ...t) {
77
+ return t.forEach((n) => {
78
+ for (const r in n)
79
+ n[r] !== null && et(n[r]) ? e[r] = n[r] : n[r] !== null && typeof n[r] == "object" ? e[r] = Ie(
80
+ e[r] || (Te(n[r]) ? [] : {}),
81
+ n[r]
82
+ ) : e[r] = n[r];
83
+ }), e;
84
+ }
85
+ function P(e) {
86
+ return un() ? !0 : (se(`${e} 需要在SDK初始化之后使用`), !1);
87
+ }
88
+ function ue(e) {
89
+ return Object.prototype.toString.call(e).slice(8, -1).toLowerCase();
90
+ }
91
+ function fe(e, t) {
92
+ return e in t;
93
+ }
94
+ function dn(e) {
95
+ return Math.random() <= e;
96
+ }
97
+ function te(e, t, n = "0") {
98
+ const r = String(e);
99
+ if (r.length < t) {
100
+ let o = r;
101
+ for (let a = 0; a < t - r.length; a += 1)
102
+ o = n + o;
103
+ return o;
104
+ }
105
+ return r;
106
+ }
107
+ function fn(e) {
108
+ return e.split("?")[0];
109
+ }
110
+ function We() {
111
+ const e = /* @__PURE__ */ new Date(), t = parseInt(
112
+ `${e.getFullYear()}${te(e.getMonth() + 1, 2)}${te(
113
+ e.getDate(),
114
+ 2
115
+ )}`,
116
+ 10
117
+ ).toString(16), n = parseInt(
118
+ `${te(e.getHours(), 2)}${te(e.getMinutes(), 2)}${te(
119
+ e.getSeconds(),
120
+ 2
121
+ )}${te(e.getMilliseconds(), 3)}`,
122
+ 10
123
+ ).toString(16);
124
+ let r = t + n.length + n;
125
+ for (; r.length < 32; )
126
+ r += Math.floor(Math.random() * 16).toString(16);
127
+ return `${r.slice(0, 8)}-${r.slice(8, 16)}-${r.slice(16)}`;
128
+ }
129
+ function tt(e) {
130
+ const t = document.cookie.match(new RegExp(`${e}=([^;]+)(;|$)`));
131
+ return t ? t[1] : void 0;
132
+ }
133
+ function hn(e, t) {
134
+ return navigator.sendBeacon(e, JSON.stringify(t));
135
+ }
136
+ const we = [];
137
+ function mn(e, t) {
138
+ return new Promise((n) => {
139
+ const r = new Image();
140
+ r.src = `${e}?v=${encodeURIComponent(JSON.stringify(t))}`, we.push(r), r.onload = () => {
141
+ n();
142
+ }, r.onerror = function() {
143
+ n();
144
+ };
145
+ });
146
+ }
147
+ function st(e, t, n = 5e3) {
148
+ return new Promise((r, o) => {
149
+ const a = new XMLHttpRequest();
150
+ a.open("post", e), a.setRequestHeader("content-type", "application/json"), a.timeout = n, a.send(JSON.stringify(t)), a.onreadystatechange = function() {
151
+ a.readyState === 4 && (a.status >= 200 && a.status < 300 ? r() : o(new Error("@web-tracing XMLHttpRequest error: " + a.status)));
152
+ }, a.ontimeout = function() {
153
+ o(new Error("@web-tracing XMLHttpRequest timeout"));
154
+ }, a.onerror = function() {
155
+ o(new Error("@web-tracing XMLHttpRequest network error"));
156
+ };
157
+ });
158
+ }
159
+ function Ee(e, t, n) {
160
+ if (e.length === 0) return n;
161
+ let r;
162
+ for (let o = 0; o < e.length; o++) {
163
+ const a = e[o];
164
+ o === 0 || t ? r = a(n) : r = a(r);
165
+ }
166
+ return r;
167
+ }
168
+ function Pe(e) {
169
+ return Te(e) ? e : [e];
170
+ }
171
+ const pn = Array.prototype.map || function(t) {
172
+ const n = [];
173
+ for (let r = 0; r < this.length; r += 1)
174
+ n.push(t(this[r], r, this));
175
+ return n;
176
+ };
177
+ function Mt(e, t) {
178
+ return pn.call(e, t);
179
+ }
180
+ const vn = Array.prototype.filter || function(t, n) {
181
+ const r = [];
182
+ for (let o = 0; o < this.length; o += 1)
183
+ n(this[o], o, this) && r.push(this[o]);
184
+ return r;
185
+ };
186
+ function gn(e, t) {
187
+ return vn.call(e, t);
188
+ }
189
+ const bn = window.requestIdleCallback || window.requestAnimationFrame || ((e) => setTimeout(e, 17));
190
+ function ct(e, t) {
191
+ const n = JSON.stringify(e);
192
+ return new TextEncoder().encode(n).length / 1024 > t;
193
+ }
194
+ function Be(e) {
195
+ if (!e) return {};
196
+ const t = {}, n = e.split("?")[1];
197
+ if (n) {
198
+ const r = n.split("&");
199
+ for (const o of r) {
200
+ const [a, s] = o.split("=");
201
+ t[decodeURIComponent(a)] = decodeURIComponent(s);
202
+ }
203
+ }
204
+ return t;
205
+ }
206
+ function Ze(e, t = /* @__PURE__ */ new Map()) {
207
+ if (e !== null && typeof e == "object") {
208
+ let n = t.get(e);
209
+ return n || (e instanceof Array ? (n = [], t.set(e, n), e.forEach((r, o) => {
210
+ n[o] = Ze(r, t);
211
+ })) : (n = {}, t.set(e, n), Object.keys(e).forEach((r) => {
212
+ fe(r, e) && (n[r] = Ze(e[r], t));
213
+ })), n);
214
+ }
215
+ return e;
216
+ }
217
+ function B(e, t, n, r = !1) {
218
+ e.removeEventListener(t, n, r);
219
+ }
220
+ class yn {
221
+ dsn = "";
222
+ // 上报地址
223
+ appName = "";
224
+ // 应用名称
225
+ appCode = "";
226
+ // 应用code
227
+ appVersion = "";
228
+ // 应用版本
229
+ userUuid = "";
230
+ // 用户id(外部填充进来的id)
231
+ sdkUserUuid = "";
232
+ // 用户id(sdk内部生成的id)
233
+ debug = !1;
234
+ // 是否开启调试模式(控制台会输出sdk动作)
235
+ pv = {
236
+ core: !1
237
+ // 页面跳转-是否自动发送页面跳转相关数据
238
+ };
239
+ performance = {
240
+ core: !1,
241
+ // 性能数据-是否采集静态资源、接口的相关数据
242
+ firstResource: !1,
243
+ // 性能数据-是否采集首次进入页面的数据(ps: tcp连接耗时,HTML加载完成时间,首次可交互时间)
244
+ server: !1
245
+ // 接口请求-是否采集接口请求(成功的才会采集)
246
+ };
247
+ error = {
248
+ core: !1,
249
+ // 是否采集异常数据(ps: 资源引入错误,promise错误,控制台输出错误)
250
+ server: !1
251
+ // 接口请求-是否采集报错接口数据
252
+ };
253
+ event = {
254
+ core: !1
255
+ // 页面点击-是否采集点击事件
256
+ };
257
+ recordScreen = !0;
258
+ // 是否启动录屏
259
+ timeout = 5e3;
260
+ // 日志上报超时时间(毫秒)
261
+ maxQueueLength = 200;
262
+ // 上报接口异常,日志队列最大缓存数
263
+ checkRecoverInterval = 1;
264
+ // 多长时间检测一次上报接口是否恢复(分钟)
265
+ ext = {};
266
+ // 自定义全局附加参数(放在baseInfo中)
267
+ tracesSampleRate = 1;
268
+ // 抽样发送
269
+ cacheMaxLength = 5;
270
+ // 上报数据最大缓存数
271
+ cacheWatingTime = 5e3;
272
+ // 上报数据最大等待时间
273
+ ignoreErrors = [];
274
+ // 错误类型事件过滤
275
+ ignoreRequest = [];
276
+ // 请求类型事件过滤
277
+ scopeError = !1;
278
+ // 当某个时间段报错时,会将此类错误转为特殊错误类型,会新增错误持续时间范围
279
+ localization = !1;
280
+ // 是否本地化:sdk不再主动发送事件,事件都存储在本地,由用户手动调用方法发送
281
+ sendTypeByXmlBody = !1;
282
+ // 是否强制指定发送形式为xml,body请求方式
283
+ // whiteScreen = false // 开启白屏检测
284
+ // 添加到行为列表前的 hook (在这里面可以给出错误类型,然后就能达到用户想拿到是何种事件类型的触发)
285
+ beforePushEventList = [];
286
+ // 数据上报前的 hook
287
+ beforeSendData = [];
288
+ // 数据上报后的 hook
289
+ afterSendData = [];
290
+ // 本地化存储溢出后的回调
291
+ localizationOverFlow = () => {
292
+ };
293
+ constructor(t) {
294
+ const n = this.transitionOptions(t);
295
+ n.ignoreRequest.push(new RegExp(n.dsn)), Ie(this, n);
296
+ }
297
+ /**
298
+ * 对入参配置项进行转换
299
+ */
300
+ transitionOptions(t) {
301
+ const n = Ie({}, this, t), { beforePushEventList: r, beforeSendData: o, afterSendData: a } = t, { pv: s, performance: c, error: i, event: u } = n;
302
+ return typeof s == "boolean" && (n.pv = {
303
+ core: s
304
+ }), typeof c == "boolean" && (n.performance = {
305
+ core: c,
306
+ firstResource: c,
307
+ server: c
308
+ }), typeof i == "boolean" && (n.error = {
309
+ core: i,
310
+ server: i
311
+ }), typeof u == "boolean" && (n.event = {
312
+ core: u
313
+ }), r && (n.beforePushEventList = [r]), o && (n.beforeSendData = [o]), a && (n.afterSendData = [a]), t.timeout !== void 0 && (n.timeout = t.timeout), t.maxQueueLength !== void 0 && (n.maxQueueLength = t.maxQueueLength), t.checkRecoverInterval !== void 0 && (n.checkRecoverInterval = t.checkRecoverInterval), n;
314
+ }
315
+ }
316
+ function En(e) {
317
+ const {
318
+ dsn: t,
319
+ appName: n,
320
+ appCode: r,
321
+ appVersion: o,
322
+ userUuid: a,
323
+ debug: s,
324
+ recordScreen: c,
325
+ pv: i,
326
+ performance: u,
327
+ error: l,
328
+ event: h,
329
+ ext: v,
330
+ tracesSampleRate: g,
331
+ cacheMaxLength: S,
332
+ cacheWatingTime: y,
333
+ ignoreErrors: m,
334
+ ignoreRequest: k,
335
+ scopeError: x,
336
+ localization: j,
337
+ sendTypeByXmlBody: q,
338
+ // whiteScreen,
339
+ beforePushEventList: ye,
340
+ beforeSendData: _,
341
+ timeout: Yt,
342
+ maxQueueLength: Gt,
343
+ checkRecoverInterval: _t,
344
+ transformSendParams: zt
345
+ } = e, z = [];
346
+ return i && typeof i == "object" ? z.push(E(i.core, "pv.core", "boolean")) : z.push(E(i, "pv", "boolean")), u && typeof u == "object" ? z.push(
347
+ E(u.core, "performance.core", "boolean"),
348
+ E(
349
+ u.firstResource,
350
+ "performance.firstResource",
351
+ "boolean"
352
+ ),
353
+ E(u.server, "performance.server", "boolean")
354
+ ) : z.push(E(u, "performance", "boolean")), l && typeof l == "object" ? z.push(
355
+ E(l.core, "error.core", "boolean"),
356
+ E(l.server, "error.server", "boolean")
357
+ ) : z.push(E(l, "error", "boolean")), h && typeof h == "object" ? z.push(E(h.core, "event.core", "boolean")) : z.push(E(h, "event", "boolean")), [
358
+ E(t, "dsn", "string"),
359
+ E(n, "appName", "string"),
360
+ E(r, "appCode", "string"),
361
+ E(o, "appVersion", "string"),
362
+ E(a, "userUuid", "string"),
363
+ E(s, "debug", "boolean"),
364
+ E(c, "recordScreen", "boolean"),
365
+ E(v, "ext", "object"),
366
+ E(g, "tracesSampleRate", "number"),
367
+ E(S, "cacheMaxLength", "number"),
368
+ E(y, "cacheWatingTime", "number"),
369
+ E(m, "ignoreErrors", "array"),
370
+ lt(m, "ignoreErrors", ["string", "regexp"]),
371
+ E(k, "ignoreRequest", "array"),
372
+ lt(k, "ignoreRequest", ["string", "regexp"]),
373
+ E(x, "scopeError", "boolean"),
374
+ E(j, "localization", "boolean"),
375
+ E(q, "sendTypeByXmlBody", "boolean"),
376
+ // validateOption(whiteScreen, 'whiteScreen', 'boolean'),
377
+ E(ye, "beforePushEventList", "function"),
378
+ E(_, "beforeSendData", "function"),
379
+ E(Yt, "timeout", "number"),
380
+ E(Gt, "maxQueueLength", "number"),
381
+ E(_t, "checkRecoverInterval", "number"),
382
+ E(zt, "transformSendParams", "function")
383
+ ].every((Jt) => !!Jt);
384
+ }
385
+ function Sn(e) {
386
+ return [
387
+ ut(e.appName, "appName"),
388
+ ut(e.dsn, "dsn")
389
+ ].every((n) => !!n);
390
+ }
391
+ function ut(e, t) {
392
+ return on(e) ? (se(`【${t}】参数必填`), !1) : !0;
393
+ }
394
+ function E(e, t, n) {
395
+ return !e || ue(e) === n ? !0 : (se(
396
+ `TypeError:【${t}】期望传入${n}类型,目前是${ue(
397
+ e
398
+ )}类型`
399
+ ), !1);
400
+ }
401
+ function lt(e, t, n) {
402
+ if (!e) return !0;
403
+ let r = !0;
404
+ return e.forEach((o) => {
405
+ n.includes(ue(o)) || (se(
406
+ `TypeError:【${t}】数组内的值期望传入${n.join(
407
+ "|"
408
+ )}类型,目前值${o}是${ue(o)}类型`
409
+ ), r = !1);
410
+ }), r;
411
+ }
412
+ let d;
413
+ function Ln(e) {
414
+ return !Sn(e) || !En(e) ? !1 : (d = qt(new yn(e)), C.options = d, !0);
415
+ }
416
+ const wn = "0.0.1", dt = "_webtracing_device_id", Ye = "_webtracing_session_id", Rn = 18e5, Ge = "_webtracing_localization_key", An = wn, f = {
417
+ ERROR: "error",
418
+ CONSOLEERROR: "consoleError",
419
+ UNHANDLEDREJECTION: "unhandledrejection",
420
+ CLICK: "click",
421
+ LOAD: "load",
422
+ BEFOREUNLOAD: "beforeunload",
423
+ FETCH: "fetch",
424
+ XHROPEN: "xhr-open",
425
+ XHRSEND: "xhr-send",
426
+ HASHCHANGE: "hashchange",
427
+ HISTORYPUSHSTATE: "history-pushState",
428
+ HISTORYREPLACESTATE: "history-replaceState",
429
+ POPSTATE: "popstate",
430
+ READYSTATECHANGE: "readystatechange",
431
+ ONLINE: "online",
432
+ OFFLINE: "offline"
433
+ }, V = {
434
+ PV: "pv",
435
+ // 路由跳转
436
+ PVDURATION: "pv-duration",
437
+ // 页面停留事件
438
+ ERROR: "error",
439
+ // 错误
440
+ PERFORMANCE: "performance",
441
+ // 资源
442
+ CLICK: "click",
443
+ // 点击
444
+ DWELL: "dwell",
445
+ // 页面卸载
446
+ CUSTOM: "custom",
447
+ // 手动触发事件
448
+ INTERSECTION: "intersection"
449
+ // 曝光采集
450
+ }, O = {
451
+ PAGE: "page",
452
+ // 页面
453
+ RESOURCE: "resource",
454
+ // 资源
455
+ SERVER: "server",
456
+ // 请求
457
+ CODE: "code",
458
+ // code
459
+ REJECT: "reject",
460
+ // reject
461
+ CONSOLEERROR: "console.error"
462
+ // console.error
463
+ }, In = {
464
+ 0: "navigate",
465
+ // 网页通过点击链接,地址栏输入,表单提交,脚本操作等方式加载
466
+ 1: "reload",
467
+ // 网页通过“重新加载”按钮或者location.reload()方法加载
468
+ 2: "back_forward",
469
+ // 网页通过“前进”或“后退”按钮加载
470
+ 255: "reserved"
471
+ // 任何其他来源的加载
472
+ };
473
+ class kn {
474
+ handlers;
475
+ constructor() {
476
+ this.handlers = {};
477
+ }
478
+ /**
479
+ * 为目标类型事件添加回调
480
+ * @param handler 需要被添加的类型以及回调函数
481
+ */
482
+ addEvent(t) {
483
+ !this.handlers[t.type] && (this.handlers[t.type] = []), this._getCallbackIndex(t) === -1 && this.handlers[t.type]?.push(t.callback);
484
+ }
485
+ /**
486
+ * 为目标类型事件删除回调
487
+ * @param handler 需要被删除的类型以及回调函数
488
+ */
489
+ delEvent(t) {
490
+ const n = this._getCallbackIndex(t);
491
+ n !== -1 && this.handlers[t.type]?.splice(n, 1);
492
+ }
493
+ /**
494
+ * 为目标类型事件更改回调
495
+ * @param handler 需要被更改的类型以及回调函数
496
+ * @param newCallback 新的回调函数
497
+ */
498
+ changeEvent(t, n) {
499
+ const r = this._getCallbackIndex(t);
500
+ r !== -1 && this.handlers[t.type]?.splice(r, 1, n);
501
+ }
502
+ /**
503
+ * 获取目标类型事件所有的回调
504
+ * @param type 事件类型
505
+ */
506
+ getEvent(t) {
507
+ return this.handlers[t] || [];
508
+ }
509
+ /**
510
+ * 执行目标类型事件所有的回调
511
+ * @param type 事件类型
512
+ * @param args 额外参数
513
+ */
514
+ runEvent(t, ...n) {
515
+ this.getEvent(t).forEach((o) => {
516
+ o(...n);
517
+ });
518
+ }
519
+ /**
520
+ * 获取函数在 callback 列表中的位置
521
+ */
522
+ _getCallbackIndex(t) {
523
+ if (this.handlers[t.type]) {
524
+ const n = this.handlers[t.type];
525
+ return n ? n.findIndex((r) => r === t.callback) : -1;
526
+ } else
527
+ return -1;
528
+ }
529
+ /**
530
+ * 移除多个指定类型的事件监听
531
+ * @param types 事件类型数组
532
+ */
533
+ removeEvents(t) {
534
+ t.forEach((n) => {
535
+ delete this.handlers[n];
536
+ });
537
+ }
538
+ }
539
+ const b = C.eventBus || (C.eventBus = new kn()), A = {
540
+ consoleError: null,
541
+ xhrOpen: null,
542
+ xhrSend: null,
543
+ fetch: null,
544
+ historyPushState: null,
545
+ historyReplaceState: null
546
+ }, w = {
547
+ error: null,
548
+ unhandledrejection: null,
549
+ click: null,
550
+ load: null,
551
+ beforeunload: null,
552
+ hashchange: null,
553
+ popstate: null,
554
+ offline: null,
555
+ online: null
556
+ };
557
+ function Tn() {
558
+ for (const e in f)
559
+ fe(e, f) && Cn(e);
560
+ }
561
+ function Cn(e) {
562
+ if (!fe(e, f)) return;
563
+ switch (f[e]) {
564
+ case f.ERROR:
565
+ On(f.ERROR);
566
+ break;
567
+ case f.UNHANDLEDREJECTION:
568
+ Pn(f.UNHANDLEDREJECTION);
569
+ break;
570
+ case f.CONSOLEERROR:
571
+ xn(f.CONSOLEERROR);
572
+ break;
573
+ case f.CLICK:
574
+ Nn(f.CLICK);
575
+ break;
576
+ case f.LOAD:
577
+ Fn(f.LOAD);
578
+ break;
579
+ case f.BEFOREUNLOAD:
580
+ Mn(f.BEFOREUNLOAD);
581
+ break;
582
+ case f.XHROPEN:
583
+ Vn(f.XHROPEN);
584
+ break;
585
+ case f.XHRSEND:
586
+ Hn(f.XHRSEND);
587
+ break;
588
+ case f.FETCH:
589
+ Dn(f.FETCH);
590
+ break;
591
+ case f.HASHCHANGE:
592
+ Xn(f.HASHCHANGE);
593
+ break;
594
+ case f.HISTORYPUSHSTATE:
595
+ jn(f.HISTORYPUSHSTATE);
596
+ break;
597
+ case f.HISTORYREPLACESTATE:
598
+ Un(f.HISTORYREPLACESTATE);
599
+ break;
600
+ case f.POPSTATE:
601
+ Wn(f.POPSTATE);
602
+ break;
603
+ case f.OFFLINE:
604
+ Bn(f.OFFLINE);
605
+ break;
606
+ case f.ONLINE:
607
+ Zn(f.ONLINE);
608
+ break;
609
+ }
610
+ }
611
+ function On(e) {
612
+ const t = function(n) {
613
+ b.runEvent(e, n);
614
+ };
615
+ w.error = t, D(p, "error", t, !0);
616
+ }
617
+ function Pn(e) {
618
+ const t = function(n) {
619
+ b.runEvent(e, n);
620
+ };
621
+ w.unhandledrejection = t, D(p, "unhandledrejection", t);
622
+ }
623
+ function xn(e) {
624
+ A.consoleError = console.error, de(console, "error", (t) => function(n, ...r) {
625
+ r[0] && r[0].slice && r[0].slice(0, 12) === "@web-tracing" || b.runEvent(e, r), t.apply(this, r);
626
+ });
627
+ }
628
+ function Nn(e) {
629
+ if (!("document" in p)) return;
630
+ const t = Ft(b.runEvent, 100, !0), n = function(r, o) {
631
+ t.call(b, e, o);
632
+ };
633
+ w.click = n, D(p.document, "click", n, !0);
634
+ }
635
+ function Fn(e) {
636
+ const t = function(n) {
637
+ b.runEvent(e, n);
638
+ };
639
+ w.load = t, D(p, "load", t, !0);
640
+ }
641
+ function Mn(e) {
642
+ const t = function(n) {
643
+ b.runEvent(e, n);
644
+ };
645
+ w.beforeunload = t, D(p, "beforeunload", t, !1);
646
+ }
647
+ function Vn(e) {
648
+ "XMLHttpRequest" in p && (A.xhrOpen = XMLHttpRequest.prototype.open, de(XMLHttpRequest.prototype, "open", (t) => function(n, ...r) {
649
+ b.runEvent(e, ...r), t.apply(this, r);
650
+ }));
651
+ }
652
+ function Hn(e) {
653
+ "XMLHttpRequest" in p && (A.xhrSend = XMLHttpRequest.prototype.send, de(XMLHttpRequest.prototype, "send", (t) => function(n, ...r) {
654
+ b.runEvent(e, this, ...r), t.apply(this, r);
655
+ }));
656
+ }
657
+ function Dn(e) {
658
+ "fetch" in p && (A.fetch = p.fetch, de(p, "fetch", (t) => function(n, ...r) {
659
+ const o = R(), a = {};
660
+ return t.apply(p, r).then((s) => (b.runEvent(e, r[0], r[1], s, o, a), s));
661
+ }));
662
+ }
663
+ function Xn(e) {
664
+ const t = function(n) {
665
+ b.runEvent(e, n);
666
+ };
667
+ w.hashchange = t, D(p, "hashchange", t);
668
+ }
669
+ function Un(e) {
670
+ A.historyReplaceState = history.replaceState, de(history, "replaceState", (t) => function(n, ...r) {
671
+ b.runEvent(e, ...r), t.apply(this, r);
672
+ });
673
+ }
674
+ function jn(e) {
675
+ A.historyPushState = history.pushState, de(history, "pushState", (t) => function(n, ...r) {
676
+ b.runEvent(e, ...r), t.apply(this, r);
677
+ });
678
+ }
679
+ function Wn(e) {
680
+ const t = function(n) {
681
+ b.runEvent(e, n);
682
+ };
683
+ w.popstate = t, D(p, "popstate", t);
684
+ }
685
+ function Bn(e) {
686
+ const t = function(n) {
687
+ b.runEvent(e, n);
688
+ };
689
+ w.offline = t, D(p, "offline", t);
690
+ }
691
+ function Zn(e) {
692
+ const t = function(n) {
693
+ b.runEvent(e, n);
694
+ };
695
+ w.offline = t, D(p, "offline", t);
696
+ }
697
+ function Yn() {
698
+ A.consoleError && console.error !== A.consoleError && (console.error = A.consoleError), A.xhrOpen && XMLHttpRequest.prototype.open !== A.xhrOpen && (XMLHttpRequest.prototype.open = A.xhrOpen), A.xhrSend && XMLHttpRequest.prototype.send !== A.xhrSend && (XMLHttpRequest.prototype.send = A.xhrSend), A.fetch && p.fetch !== A.fetch && (p.fetch = A.fetch), A.historyPushState && history.pushState !== A.historyPushState && (history.pushState = A.historyPushState), A.historyReplaceState && history.replaceState !== A.historyReplaceState && (history.replaceState = A.historyReplaceState), w.error && B(p, "error", w.error, !0), w.unhandledrejection && B(p, "unhandledrejection", w.unhandledrejection), w.click && B(p.document, "click", w.click, !0), w.load && B(p, "load", w.load, !0), w.beforeunload && B(p, "beforeunload", w.beforeunload, !1), w.hashchange && B(p, "hashchange", w.hashchange), w.popstate && B(p, "popstate", w.popstate), w.offline && B(p, "offline", w.offline), w.online && B(p, "online", w.online), Object.keys(A).forEach((e) => {
699
+ A[e] = null;
700
+ }), Object.keys(w).forEach((e) => {
701
+ w[e] = null;
702
+ });
703
+ }
704
+ let _e = function() {
705
+ return _e = Object.assign || function(e) {
706
+ for (var t, n = 1, r = arguments.length; n < r; n++)
707
+ for (const o in t = arguments[n])
708
+ Object.prototype.hasOwnProperty.call(t, o) && (e[o] = t[o]);
709
+ return e;
710
+ }, _e.apply(this, arguments);
711
+ };
712
+ function G(e, t, n, r) {
713
+ return new (n || (n = Promise))(function(o, a) {
714
+ function s(u) {
715
+ try {
716
+ i(r.next(u));
717
+ } catch (l) {
718
+ a(l);
719
+ }
720
+ }
721
+ function c(u) {
722
+ try {
723
+ i(r.throw(u));
724
+ } catch (l) {
725
+ a(l);
726
+ }
727
+ }
728
+ function i(u) {
729
+ let l;
730
+ u.done ? o(u.value) : (l = u.value, l instanceof n ? l : new n(function(h) {
731
+ h(l);
732
+ })).then(s, c);
733
+ }
734
+ i((r = r.apply(e, [])).next());
735
+ });
736
+ }
737
+ function W(e, t) {
738
+ let n, r, o, a, s = {
739
+ label: 0,
740
+ sent: function() {
741
+ if (1 & o[0]) throw o[1];
742
+ return o[1];
743
+ },
744
+ trys: [],
745
+ ops: []
746
+ };
747
+ return a = { next: c(0), throw: c(1), return: c(2) }, typeof Symbol == "function" && (a[Symbol.iterator] = function() {
748
+ return this;
749
+ }), a;
750
+ function c(i) {
751
+ return function(u) {
752
+ return (function(l) {
753
+ if (n) throw new TypeError("Generator is already executing.");
754
+ for (; a && (a = 0, l[0] && (s = 0)), s; )
755
+ try {
756
+ if (n = 1, r && (o = 2 & l[0] ? r.return : l[0] ? r.throw || ((o = r.return) && o.call(r), 0) : r.next) && !(o = o.call(r, l[1])).done)
757
+ return o;
758
+ switch (r = 0, o && (l = [2 & l[0], o.value]), l[0]) {
759
+ case 0:
760
+ case 1:
761
+ o = l;
762
+ break;
763
+ case 4:
764
+ return s.label++, { value: l[1], done: !1 };
765
+ case 5:
766
+ s.label++, r = l[1], l = [0];
767
+ continue;
768
+ case 7:
769
+ l = s.ops.pop(), s.trys.pop();
770
+ continue;
771
+ default:
772
+ if (o = s.trys, !((o = o.length > 0 && o[o.length - 1]) || l[0] !== 6 && l[0] !== 2)) {
773
+ s = 0;
774
+ continue;
775
+ }
776
+ if (l[0] === 3 && (!o || l[1] > o[0] && l[1] < o[3])) {
777
+ s.label = l[1];
778
+ break;
779
+ }
780
+ if (l[0] === 6 && s.label < o[1]) {
781
+ s.label = o[1], o = l;
782
+ break;
783
+ }
784
+ if (o && s.label < o[2]) {
785
+ s.label = o[2], s.ops.push(l);
786
+ break;
787
+ }
788
+ o[2] && s.ops.pop(), s.trys.pop();
789
+ continue;
790
+ }
791
+ l = t.call(e, s);
792
+ } catch (h) {
793
+ l = [6, h], r = 0;
794
+ } finally {
795
+ n = o = 0;
796
+ }
797
+ if (5 & l[0]) throw l[1];
798
+ return { value: l[0] ? l[1] : void 0, done: !0 };
799
+ })([i, u]);
800
+ };
801
+ }
802
+ }
803
+ function ie(e, t, n) {
804
+ if (n || arguments.length === 2)
805
+ for (var r, o = 0, a = t.length; o < a; o++)
806
+ !r && o in t || (r || (r = Array.prototype.slice.call(t, 0, o)), r[o] = t[o]);
807
+ return e.concat(r || Array.prototype.slice.call(t));
808
+ }
809
+ function Y(e, t) {
810
+ return new Promise(function(n) {
811
+ return setTimeout(n, e, t);
812
+ });
813
+ }
814
+ function Vt(e) {
815
+ return !!e && typeof e.then == "function";
816
+ }
817
+ function ft(e, t) {
818
+ try {
819
+ const n = e();
820
+ Vt(n) ? n.then(
821
+ function(r) {
822
+ return t(!0, r);
823
+ },
824
+ function(r) {
825
+ return t(!1, r);
826
+ }
827
+ ) : t(!0, n);
828
+ } catch (n) {
829
+ t(!1, n);
830
+ }
831
+ }
832
+ function ht(e, t, n) {
833
+ return n === void 0 && (n = 16), G(this, void 0, void 0, function() {
834
+ let r, o, a;
835
+ return W(this, function(s) {
836
+ switch (s.label) {
837
+ case 0:
838
+ r = Date.now(), o = 0, s.label = 1;
839
+ case 1:
840
+ return o < e.length ? (t(e[o], o), (a = Date.now()) >= r + n ? (r = a, [4, Y(0)]) : [3, 3]) : [3, 4];
841
+ case 2:
842
+ s.sent(), s.label = 3;
843
+ case 3:
844
+ return ++o, [3, 1];
845
+ case 4:
846
+ return [2];
847
+ }
848
+ });
849
+ });
850
+ }
851
+ function ke(e) {
852
+ e.then(void 0, function() {
853
+ });
854
+ }
855
+ function J(e, t) {
856
+ e = [e[0] >>> 16, 65535 & e[0], e[1] >>> 16, 65535 & e[1]], t = [t[0] >>> 16, 65535 & t[0], t[1] >>> 16, 65535 & t[1]];
857
+ const n = [0, 0, 0, 0];
858
+ return n[3] += e[3] + t[3], n[2] += n[3] >>> 16, n[3] &= 65535, n[2] += e[2] + t[2], n[1] += n[2] >>> 16, n[2] &= 65535, n[1] += e[1] + t[1], n[0] += n[1] >>> 16, n[1] &= 65535, n[0] += e[0] + t[0], n[0] &= 65535, [n[0] << 16 | n[1], n[2] << 16 | n[3]];
859
+ }
860
+ function H(e, t) {
861
+ e = [e[0] >>> 16, 65535 & e[0], e[1] >>> 16, 65535 & e[1]], t = [t[0] >>> 16, 65535 & t[0], t[1] >>> 16, 65535 & t[1]];
862
+ const n = [0, 0, 0, 0];
863
+ return n[3] += e[3] * t[3], n[2] += n[3] >>> 16, n[3] &= 65535, n[2] += e[2] * t[3], n[1] += n[2] >>> 16, n[2] &= 65535, n[2] += e[3] * t[2], n[1] += n[2] >>> 16, n[2] &= 65535, n[1] += e[1] * t[3], n[0] += n[1] >>> 16, n[1] &= 65535, n[1] += e[2] * t[2], n[0] += n[1] >>> 16, n[1] &= 65535, n[1] += e[3] * t[1], n[0] += n[1] >>> 16, n[1] &= 65535, n[0] += e[0] * t[3] + e[1] * t[2] + e[2] * t[1] + e[3] * t[0], n[0] &= 65535, [n[0] << 16 | n[1], n[2] << 16 | n[3]];
864
+ }
865
+ function ne(e, t) {
866
+ return (t %= 64) === 32 ? [e[1], e[0]] : t < 32 ? [e[0] << t | e[1] >>> 32 - t, e[1] << t | e[0] >>> 32 - t] : (t -= 32, [e[1] << t | e[0] >>> 32 - t, e[0] << t | e[1] >>> 32 - t]);
867
+ }
868
+ function M(e, t) {
869
+ return (t %= 64) === 0 ? e : t < 32 ? [e[0] << t | e[1] >>> 32 - t, e[1] << t] : [e[1] << t - 32, 0];
870
+ }
871
+ function I(e, t) {
872
+ return [e[0] ^ t[0], e[1] ^ t[1]];
873
+ }
874
+ function mt(e) {
875
+ return e = I(e, [0, e[0] >>> 1]), e = I(e = H(e, [4283543511, 3981806797]), [0, e[0] >>> 1]), e = I(e = H(e, [3301882366, 444984403]), [0, e[0] >>> 1]);
876
+ }
877
+ function Gn(e, t) {
878
+ t = t || 0;
879
+ let n, r = (e = e || "").length % 16, o = e.length - r, a = [0, t], s = [0, t], c = [0, 0], i = [0, 0], u = [2277735313, 289559509], l = [1291169091, 658871167];
880
+ for (n = 0; n < o; n += 16)
881
+ c = [
882
+ 255 & e.charCodeAt(n + 4) | (255 & e.charCodeAt(n + 5)) << 8 | (255 & e.charCodeAt(n + 6)) << 16 | (255 & e.charCodeAt(n + 7)) << 24,
883
+ 255 & e.charCodeAt(n) | (255 & e.charCodeAt(n + 1)) << 8 | (255 & e.charCodeAt(n + 2)) << 16 | (255 & e.charCodeAt(n + 3)) << 24
884
+ ], i = [
885
+ 255 & e.charCodeAt(n + 12) | (255 & e.charCodeAt(n + 13)) << 8 | (255 & e.charCodeAt(n + 14)) << 16 | (255 & e.charCodeAt(n + 15)) << 24,
886
+ 255 & e.charCodeAt(n + 8) | (255 & e.charCodeAt(n + 9)) << 8 | (255 & e.charCodeAt(n + 10)) << 16 | (255 & e.charCodeAt(n + 11)) << 24
887
+ ], c = ne(c = H(c, u), 31), a = J(a = ne(a = I(a, c = H(c, l)), 27), s), a = J(H(a, [0, 5]), [0, 1390208809]), i = ne(i = H(i, l), 33), s = J(s = ne(s = I(s, i = H(i, u)), 31), a), s = J(H(s, [0, 5]), [0, 944331445]);
888
+ switch (c = [0, 0], i = [0, 0], r) {
889
+ case 15:
890
+ i = I(i, M([0, e.charCodeAt(n + 14)], 48));
891
+ case 14:
892
+ i = I(i, M([0, e.charCodeAt(n + 13)], 40));
893
+ case 13:
894
+ i = I(i, M([0, e.charCodeAt(n + 12)], 32));
895
+ case 12:
896
+ i = I(i, M([0, e.charCodeAt(n + 11)], 24));
897
+ case 11:
898
+ i = I(i, M([0, e.charCodeAt(n + 10)], 16));
899
+ case 10:
900
+ i = I(i, M([0, e.charCodeAt(n + 9)], 8));
901
+ case 9:
902
+ i = H(i = I(i, [0, e.charCodeAt(n + 8)]), l), s = I(s, i = H(i = ne(i, 33), u));
903
+ case 8:
904
+ c = I(c, M([0, e.charCodeAt(n + 7)], 56));
905
+ case 7:
906
+ c = I(c, M([0, e.charCodeAt(n + 6)], 48));
907
+ case 6:
908
+ c = I(c, M([0, e.charCodeAt(n + 5)], 40));
909
+ case 5:
910
+ c = I(c, M([0, e.charCodeAt(n + 4)], 32));
911
+ case 4:
912
+ c = I(c, M([0, e.charCodeAt(n + 3)], 24));
913
+ case 3:
914
+ c = I(c, M([0, e.charCodeAt(n + 2)], 16));
915
+ case 2:
916
+ c = I(c, M([0, e.charCodeAt(n + 1)], 8));
917
+ case 1:
918
+ c = H(c = I(c, [0, e.charCodeAt(n)]), u), a = I(a, c = H(c = ne(c, 31), l));
919
+ }
920
+ return a = J(a = I(a, [0, e.length]), s = I(s, [0, e.length])), s = J(s, a), a = J(a = mt(a), s = mt(s)), s = J(s, a), ("00000000" + (a[0] >>> 0).toString(16)).slice(-8) + ("00000000" + (a[1] >>> 0).toString(16)).slice(-8) + ("00000000" + (s[0] >>> 0).toString(16)).slice(-8) + ("00000000" + (s[1] >>> 0).toString(16)).slice(-8);
921
+ }
922
+ function xe(e) {
923
+ return parseInt(e);
924
+ }
925
+ function X(e) {
926
+ return parseFloat(e);
927
+ }
928
+ function Z(e, t) {
929
+ return typeof e == "number" && isNaN(e) ? t : e;
930
+ }
931
+ function U(e) {
932
+ return e.reduce(function(t, n) {
933
+ return t + (n ? 1 : 0);
934
+ }, 0);
935
+ }
936
+ function Ht(e, t) {
937
+ if (t === void 0 && (t = 1), Math.abs(t) >= 1) return Math.round(e / t) * t;
938
+ const n = 1 / t;
939
+ return Math.round(e * n) / n;
940
+ }
941
+ function pt(e) {
942
+ return e && typeof e == "object" && "message" in e ? e : { message: e };
943
+ }
944
+ function _n(e) {
945
+ return typeof e != "function";
946
+ }
947
+ function zn(e, t, n) {
948
+ const r = Object.keys(e).filter(function(a) {
949
+ return !(function(s, c) {
950
+ for (let i = 0, u = s.length; i < u; ++i) if (s[i] === c) return !0;
951
+ return !1;
952
+ })(n, a);
953
+ }), o = Array(r.length);
954
+ return ht(r, function(a, s) {
955
+ o[s] = (function(c, i) {
956
+ const u = new Promise(function(l) {
957
+ const h = Date.now();
958
+ ft(c.bind(null, i), function() {
959
+ for (var v = [], g = 0; g < arguments.length; g++)
960
+ v[g] = arguments[g];
961
+ const S = Date.now() - h;
962
+ if (!v[0])
963
+ return l(function() {
964
+ return { error: pt(v[1]), duration: S };
965
+ });
966
+ const y = v[1];
967
+ if (_n(y))
968
+ return l(function() {
969
+ return { value: y, duration: S };
970
+ });
971
+ l(function() {
972
+ return new Promise(function(m) {
973
+ const k = Date.now();
974
+ ft(y, function() {
975
+ for (var x = [], j = 0; j < arguments.length; j++)
976
+ x[j] = arguments[j];
977
+ const q = S + Date.now() - k;
978
+ if (!x[0]) return m({ error: pt(x[1]), duration: q });
979
+ m({ value: x[1], duration: q });
980
+ });
981
+ });
982
+ });
983
+ });
984
+ });
985
+ return ke(u), function() {
986
+ return u.then(function(l) {
987
+ return l();
988
+ });
989
+ };
990
+ })(e[a], t);
991
+ }), function() {
992
+ return G(this, void 0, void 0, function() {
993
+ let a, s, c, i, u, l;
994
+ return W(this, function(h) {
995
+ switch (h.label) {
996
+ case 0:
997
+ for (a = {}, s = 0, c = r; s < c.length; s++)
998
+ i = c[s], a[i] = void 0;
999
+ u = Array(r.length), l = function() {
1000
+ let v;
1001
+ return W(this, function(g) {
1002
+ switch (g.label) {
1003
+ case 0:
1004
+ return v = !0, [
1005
+ 4,
1006
+ ht(r, function(S, y) {
1007
+ if (!u[y])
1008
+ if (o[y]) {
1009
+ const m = o[y]().then(function(k) {
1010
+ return a[S] = k;
1011
+ });
1012
+ ke(m), u[y] = m;
1013
+ } else v = !1;
1014
+ })
1015
+ ];
1016
+ case 1:
1017
+ return g.sent(), v ? [2, "break"] : [4, Y(1)];
1018
+ case 2:
1019
+ return g.sent(), [2];
1020
+ }
1021
+ });
1022
+ }, h.label = 1;
1023
+ case 1:
1024
+ return [5, l()];
1025
+ case 2:
1026
+ if (h.sent() === "break") return [3, 4];
1027
+ h.label = 3;
1028
+ case 3:
1029
+ return [3, 1];
1030
+ case 4:
1031
+ return [4, Promise.all(u)];
1032
+ case 5:
1033
+ return h.sent(), [2, a];
1034
+ }
1035
+ });
1036
+ });
1037
+ };
1038
+ }
1039
+ function Dt() {
1040
+ const e = window, t = navigator;
1041
+ return U([
1042
+ "MSCSSMatrix" in e,
1043
+ "msSetImmediate" in e,
1044
+ "msIndexedDB" in e,
1045
+ "msMaxTouchPoints" in t,
1046
+ "msPointerEnabled" in t
1047
+ ]) >= 4;
1048
+ }
1049
+ function Jn() {
1050
+ const e = window, t = navigator;
1051
+ return U([
1052
+ "msWriteProfilerMark" in e,
1053
+ "MSStream" in e,
1054
+ "msLaunchUri" in t,
1055
+ "msSaveBlob" in t
1056
+ ]) >= 3 && !Dt();
1057
+ }
1058
+ function ze() {
1059
+ const e = window, t = navigator;
1060
+ return U([
1061
+ "webkitPersistentStorage" in t,
1062
+ "webkitTemporaryStorage" in t,
1063
+ t.vendor.indexOf("Google") === 0,
1064
+ "webkitResolveLocalFileSystemURL" in e,
1065
+ "BatteryManager" in e,
1066
+ "webkitMediaStream" in e,
1067
+ "webkitSpeechGrammar" in e
1068
+ ]) >= 5;
1069
+ }
1070
+ function me() {
1071
+ const e = window, t = navigator;
1072
+ return U([
1073
+ "ApplePayError" in e,
1074
+ "CSSPrimitiveValue" in e,
1075
+ "Counter" in e,
1076
+ t.vendor.indexOf("Apple") === 0,
1077
+ "getStorageUpdates" in t,
1078
+ "WebKitMediaKeys" in e
1079
+ ]) >= 4;
1080
+ }
1081
+ function Je() {
1082
+ const e = window;
1083
+ return U([
1084
+ "safari" in e,
1085
+ !("DeviceMotionEvent" in e),
1086
+ !("ongestureend" in e),
1087
+ !("standalone" in navigator)
1088
+ ]) >= 3;
1089
+ }
1090
+ function qn() {
1091
+ let e, t, n = window;
1092
+ return U([
1093
+ "buildID" in navigator,
1094
+ "MozAppearance" in ((t = (e = document.documentElement) === null || e === void 0 ? void 0 : e.style) !== null && t !== void 0 ? t : {}),
1095
+ "onmozfullscreenchange" in n,
1096
+ "mozInnerScreenX" in n,
1097
+ "CSSMozDocumentRule" in n,
1098
+ "CanvasCaptureMediaStream" in n
1099
+ ]) >= 4;
1100
+ }
1101
+ function $n() {
1102
+ const e = document;
1103
+ return e.fullscreenElement || e.msFullscreenElement || e.mozFullScreenElement || e.webkitFullscreenElement || null;
1104
+ }
1105
+ function Xt() {
1106
+ const e = ze(), t = qn();
1107
+ if (!e && !t) return !1;
1108
+ const n = window;
1109
+ return U([
1110
+ "onorientationchange" in n,
1111
+ "orientation" in n,
1112
+ e && !("SharedWorker" in n),
1113
+ t && /android/i.test(navigator.appVersion)
1114
+ ]) >= 2;
1115
+ }
1116
+ function vt(e) {
1117
+ const t = new Error(e);
1118
+ return t.name = e, t;
1119
+ }
1120
+ function gt(e, t, n) {
1121
+ let r, o, a;
1122
+ return n === void 0 && (n = 50), G(this, void 0, void 0, function() {
1123
+ let s, c;
1124
+ return W(this, function(i) {
1125
+ switch (i.label) {
1126
+ case 0:
1127
+ s = document, i.label = 1;
1128
+ case 1:
1129
+ return s.body ? [3, 3] : [4, Y(n)];
1130
+ case 2:
1131
+ return i.sent(), [3, 1];
1132
+ case 3:
1133
+ c = s.createElement("iframe"), i.label = 4;
1134
+ case 4:
1135
+ return i.trys.push([4, , 10, 11]), [
1136
+ 4,
1137
+ new Promise(function(u, l) {
1138
+ let h = !1, v = function() {
1139
+ h = !0, u();
1140
+ };
1141
+ c.onload = v, c.onerror = function(y) {
1142
+ h = !0, l(y);
1143
+ };
1144
+ const g = c.style;
1145
+ g.setProperty("display", "block", "important"), g.position = "absolute", g.top = "0", g.left = "0", g.visibility = "hidden", c.src = "about:blank", s.body.appendChild(c);
1146
+ const S = function() {
1147
+ let y, m;
1148
+ h || (((m = (y = c.contentWindow) === null || y === void 0 ? void 0 : y.document) === null || m === void 0 ? void 0 : m.readyState) === "complete" ? v() : setTimeout(S, 10));
1149
+ };
1150
+ S();
1151
+ })
1152
+ ];
1153
+ case 5:
1154
+ i.sent(), i.label = 6;
1155
+ case 6:
1156
+ return !((o = (r = c.contentWindow) === null || r === void 0 ? void 0 : r.document) === null || o === void 0) && o.body ? [3, 8] : [4, Y(n)];
1157
+ case 7:
1158
+ return i.sent(), [3, 6];
1159
+ case 8:
1160
+ return [4, e(c, c.contentWindow)];
1161
+ case 9:
1162
+ return [2, i.sent()];
1163
+ case 10:
1164
+ return (a = c.parentNode) === null || a === void 0 || a.removeChild(c), [7];
1165
+ case 11:
1166
+ return [2];
1167
+ }
1168
+ });
1169
+ });
1170
+ }
1171
+ function Qn(e) {
1172
+ for (var t = (function(c) {
1173
+ for (var i, u, l = "Unexpected syntax '".concat(c, "'"), h = /^\s*([a-z-]*)(.*)$/i.exec(c), v = h[1] || void 0, g = {}, S = /([.:#][\w-]+|\[.+?\])/gi, y = function(k, x) {
1174
+ g[k] = g[k] || [], g[k].push(x);
1175
+ }; ; ) {
1176
+ const k = S.exec(h[2]);
1177
+ if (!k) break;
1178
+ const x = k[0];
1179
+ switch (x[0]) {
1180
+ case ".":
1181
+ y("class", x.slice(1));
1182
+ break;
1183
+ case "#":
1184
+ y("id", x.slice(1));
1185
+ break;
1186
+ case "[":
1187
+ var m = /^\[([\w-]+)([~|^$*]?=("(.*?)"|([\w-]+)))?(\s+[is])?\]$/.exec(x);
1188
+ if (!m) throw new Error(l);
1189
+ y(
1190
+ m[1],
1191
+ (u = (i = m[4]) !== null && i !== void 0 ? i : m[5]) !== null && u !== void 0 ? u : ""
1192
+ );
1193
+ break;
1194
+ default:
1195
+ throw new Error(l);
1196
+ }
1197
+ }
1198
+ return [v, g];
1199
+ })(e), n = t[0], r = t[1], o = document.createElement(n ?? "div"), a = 0, s = Object.keys(r); a < s.length; a++) {
1200
+ const c = s[a], i = r[c].join(" ");
1201
+ c === "style" ? Kn(o.style, i) : o.setAttribute(c, i);
1202
+ }
1203
+ return o;
1204
+ }
1205
+ function Kn(e, t) {
1206
+ for (let n = 0, r = t.split(";"); n < r.length; n++) {
1207
+ const o = r[n], a = /^\s*([\w-]+)\s*:\s*(.+?)(\s*!([\w-]+))?\s*$/.exec(o);
1208
+ if (a) {
1209
+ const s = a[1], c = a[2], i = a[4];
1210
+ e.setProperty(s, c, i || "");
1211
+ }
1212
+ }
1213
+ }
1214
+ const re = ["monospace", "sans-serif", "serif"], bt = [
1215
+ "sans-serif-thin",
1216
+ "ARNO PRO",
1217
+ "Agency FB",
1218
+ "Arabic Typesetting",
1219
+ "Arial Unicode MS",
1220
+ "AvantGarde Bk BT",
1221
+ "BankGothic Md BT",
1222
+ "Batang",
1223
+ "Bitstream Vera Sans Mono",
1224
+ "Calibri",
1225
+ "Century",
1226
+ "Century Gothic",
1227
+ "Clarendon",
1228
+ "EUROSTILE",
1229
+ "Franklin Gothic",
1230
+ "Futura Bk BT",
1231
+ "Futura Md BT",
1232
+ "GOTHAM",
1233
+ "Gill Sans",
1234
+ "HELV",
1235
+ "Haettenschweiler",
1236
+ "Helvetica Neue",
1237
+ "Humanst521 BT",
1238
+ "Leelawadee",
1239
+ "Letter Gothic",
1240
+ "Levenim MT",
1241
+ "Lucida Bright",
1242
+ "Lucida Sans",
1243
+ "Menlo",
1244
+ "MS Mincho",
1245
+ "MS Outlook",
1246
+ "MS Reference Specialty",
1247
+ "MS UI Gothic",
1248
+ "MT Extra",
1249
+ "MYRIAD PRO",
1250
+ "Marlett",
1251
+ "Meiryo UI",
1252
+ "Microsoft Uighur",
1253
+ "Minion Pro",
1254
+ "Monotype Corsiva",
1255
+ "PMingLiU",
1256
+ "Pristina",
1257
+ "SCRIPTINA",
1258
+ "Segoe UI Light",
1259
+ "Serifa",
1260
+ "SimHei",
1261
+ "Small Fonts",
1262
+ "Staccato222 BT",
1263
+ "TRAJAN PRO",
1264
+ "Univers CE 55 Medium",
1265
+ "Vrinda",
1266
+ "ZWAdobeF"
1267
+ ];
1268
+ function Ne(e) {
1269
+ return e.toDataURL();
1270
+ }
1271
+ let Se, Fe;
1272
+ function er() {
1273
+ const e = this;
1274
+ return (function() {
1275
+ if (Fe === void 0) {
1276
+ const t = function() {
1277
+ const n = Me();
1278
+ Ve(n) ? Fe = setTimeout(t, 2500) : (Se = n, Fe = void 0);
1279
+ };
1280
+ t();
1281
+ }
1282
+ })(), function() {
1283
+ return G(e, void 0, void 0, function() {
1284
+ let t;
1285
+ return W(this, function(n) {
1286
+ switch (n.label) {
1287
+ case 0:
1288
+ return Ve(t = Me()) ? Se ? [2, ie([], Se, !0)] : $n() ? [
1289
+ 4,
1290
+ (r = document, (r.exitFullscreen || r.msExitFullscreen || r.mozCancelFullScreen || r.webkitExitFullscreen).call(r))
1291
+ ] : [3, 2] : [3, 2];
1292
+ case 1:
1293
+ n.sent(), t = Me(), n.label = 2;
1294
+ case 2:
1295
+ return Ve(t) || (Se = t), [2, t];
1296
+ }
1297
+ let r;
1298
+ });
1299
+ });
1300
+ };
1301
+ }
1302
+ function Me() {
1303
+ const e = screen;
1304
+ return [
1305
+ Z(X(e.availTop), null),
1306
+ Z(X(e.width) - X(e.availWidth) - Z(X(e.availLeft), 0), null),
1307
+ Z(X(e.height) - X(e.availHeight) - Z(X(e.availTop), 0), null),
1308
+ Z(X(e.availLeft), null)
1309
+ ];
1310
+ }
1311
+ function Ve(e) {
1312
+ for (let t = 0; t < 4; ++t) if (e[t]) return !1;
1313
+ return !0;
1314
+ }
1315
+ function tr(e) {
1316
+ let t;
1317
+ return G(this, void 0, void 0, function() {
1318
+ let n, r, o, a, s, c, i;
1319
+ return W(this, function(u) {
1320
+ switch (u.label) {
1321
+ case 0:
1322
+ for (n = document, r = n.createElement("div"), o = new Array(e.length), a = {}, yt(r), i = 0; i < e.length; ++i)
1323
+ s = Qn(e[i]), yt(c = n.createElement("div")), c.appendChild(s), r.appendChild(c), o[i] = s;
1324
+ u.label = 1;
1325
+ case 1:
1326
+ return n.body ? [3, 3] : [4, Y(50)];
1327
+ case 2:
1328
+ return u.sent(), [3, 1];
1329
+ case 3:
1330
+ n.body.appendChild(r);
1331
+ try {
1332
+ for (i = 0; i < e.length; ++i) o[i].offsetParent || (a[e[i]] = !0);
1333
+ } finally {
1334
+ (t = r.parentNode) === null || t === void 0 || t.removeChild(r);
1335
+ }
1336
+ return [2, a];
1337
+ }
1338
+ });
1339
+ });
1340
+ }
1341
+ function yt(e) {
1342
+ e.style.setProperty("display", "block", "important");
1343
+ }
1344
+ function Et(e) {
1345
+ return matchMedia("(inverted-colors: ".concat(e, ")")).matches;
1346
+ }
1347
+ function St(e) {
1348
+ return matchMedia("(forced-colors: ".concat(e, ")")).matches;
1349
+ }
1350
+ function oe(e) {
1351
+ return matchMedia("(prefers-contrast: ".concat(e, ")")).matches;
1352
+ }
1353
+ function Lt(e) {
1354
+ return matchMedia("(prefers-reduced-motion: ".concat(e, ")")).matches;
1355
+ }
1356
+ function wt(e) {
1357
+ return matchMedia("(dynamic-range: ".concat(e, ")")).matches;
1358
+ }
1359
+ const L = Math, N = function() {
1360
+ return 0;
1361
+ }, He = {
1362
+ default: [],
1363
+ apple: [{ font: "-apple-system-body" }],
1364
+ serif: [{ fontFamily: "serif" }],
1365
+ sans: [{ fontFamily: "sans-serif" }],
1366
+ mono: [{ fontFamily: "monospace" }],
1367
+ min: [{ fontSize: "1px" }],
1368
+ system: [{ fontFamily: "system-ui" }]
1369
+ }, nr = {
1370
+ fonts: function() {
1371
+ return gt(function(e, t) {
1372
+ const n = t.document, r = n.body;
1373
+ r.style.fontSize = "48px";
1374
+ const o = n.createElement("div"), a = {}, s = {}, c = function(l) {
1375
+ const h = n.createElement("span"), v = h.style;
1376
+ return v.position = "absolute", v.top = "0", v.left = "0", v.fontFamily = l, h.textContent = "mmMwWLliI0O&1", o.appendChild(h), h;
1377
+ }, i = re.map(c), u = (function() {
1378
+ for (var l = {}, h = function(S) {
1379
+ l[S] = re.map(function(y) {
1380
+ return (function(m, k) {
1381
+ return c("'".concat(m, "',").concat(k));
1382
+ })(S, y);
1383
+ });
1384
+ }, v = 0, g = bt; v < g.length; v++)
1385
+ h(g[v]);
1386
+ return l;
1387
+ })();
1388
+ r.appendChild(o);
1389
+ for (let l = 0; l < re.length; l++)
1390
+ a[re[l]] = i[l].offsetWidth, s[re[l]] = i[l].offsetHeight;
1391
+ return bt.filter(function(l) {
1392
+ return t = u[l], re.some(function(h, v) {
1393
+ return t[v].offsetWidth !== a[h] || t[v].offsetHeight !== s[h];
1394
+ });
1395
+ });
1396
+ });
1397
+ },
1398
+ domBlockers: function(e) {
1399
+ const t = (e === void 0 ? {} : e).debug;
1400
+ return G(this, void 0, void 0, function() {
1401
+ let n, r, o, a, s;
1402
+ return W(this, function(c) {
1403
+ switch (c.label) {
1404
+ case 0:
1405
+ return me() || Xt() ? (i = atob, n = {
1406
+ abpIndo: [
1407
+ "#Iklan-Melayang",
1408
+ "#Kolom-Iklan-728",
1409
+ "#SidebarIklan-wrapper",
1410
+ i("YVt0aXRsZT0iN25hZ2EgcG9rZXIiIGld"),
1411
+ '[title="ALIENBOLA" i]'
1412
+ ],
1413
+ abpvn: [
1414
+ "#quangcaomb",
1415
+ i("Lmlvc0Fkc2lvc0Fkcy1sYXlvdXQ="),
1416
+ ".quangcao",
1417
+ i("W2hyZWZePSJodHRwczovL3I4OC52bi8iXQ=="),
1418
+ i("W2hyZWZePSJodHRwczovL3piZXQudm4vIl0=")
1419
+ ],
1420
+ adBlockFinland: [
1421
+ ".mainostila",
1422
+ i("LnNwb25zb3JpdA=="),
1423
+ ".ylamainos",
1424
+ i("YVtocmVmKj0iL2NsaWNrdGhyZ2guYXNwPyJd"),
1425
+ i("YVtocmVmXj0iaHR0cHM6Ly9hcHAucmVhZHBlYWsuY29tL2FkcyJd")
1426
+ ],
1427
+ adBlockPersian: [
1428
+ "#navbar_notice_50",
1429
+ ".kadr",
1430
+ 'TABLE[width="140px"]',
1431
+ "#divAgahi",
1432
+ i("I2FkMl9pbmxpbmU=")
1433
+ ],
1434
+ adBlockWarningRemoval: [
1435
+ "#adblock-honeypot",
1436
+ ".adblocker-root",
1437
+ ".wp_adblock_detect",
1438
+ i("LmhlYWRlci1ibG9ja2VkLWFk"),
1439
+ i("I2FkX2Jsb2NrZXI=")
1440
+ ],
1441
+ adGuardAnnoyances: [
1442
+ 'amp-embed[type="zen"]',
1443
+ ".hs-sosyal",
1444
+ "#cookieconsentdiv",
1445
+ 'div[class^="app_gdpr"]',
1446
+ ".as-oil"
1447
+ ],
1448
+ adGuardBase: [
1449
+ ".BetterJsPopOverlay",
1450
+ i("I2FkXzMwMFgyNTA="),
1451
+ i("I2Jhbm5lcmZsb2F0MjI="),
1452
+ i("I2FkLWJhbm5lcg=="),
1453
+ i("I2NhbXBhaWduLWJhbm5lcg==")
1454
+ ],
1455
+ adGuardChinese: [
1456
+ i("LlppX2FkX2FfSA=="),
1457
+ i("YVtocmVmKj0iL29kMDA1LmNvbSJd"),
1458
+ i("YVtocmVmKj0iLmh0aGJldDM0LmNvbSJd"),
1459
+ ".qq_nr_lad",
1460
+ "#widget-quan"
1461
+ ],
1462
+ adGuardFrench: [
1463
+ i("I2Jsb2NrLXZpZXdzLWFkcy1zaWRlYmFyLWJsb2NrLWJsb2Nr"),
1464
+ "#pavePub",
1465
+ i("LmFkLWRlc2t0b3AtcmVjdGFuZ2xl"),
1466
+ ".mobile_adhesion",
1467
+ ".widgetadv"
1468
+ ],
1469
+ adGuardGerman: [
1470
+ i("LmJhbm5lcml0ZW13ZXJidW5nX2hlYWRfMQ=="),
1471
+ i("LmJveHN0YXJ0d2VyYnVuZw=="),
1472
+ i("LndlcmJ1bmcz"),
1473
+ i(
1474
+ "YVtocmVmXj0iaHR0cDovL3d3dy5laXMuZGUvaW5kZXgucGh0bWw/cmVmaWQ9Il0="
1475
+ ),
1476
+ i(
1477
+ "YVtocmVmXj0iaHR0cHM6Ly93d3cudGlwaWNvLmNvbS8/YWZmaWxpYXRlSWQ9Il0="
1478
+ )
1479
+ ],
1480
+ adGuardJapanese: [
1481
+ "#kauli_yad_1",
1482
+ i("YVtocmVmXj0iaHR0cDovL2FkMi50cmFmZmljZ2F0ZS5uZXQvIl0="),
1483
+ i("Ll9wb3BJbl9pbmZpbml0ZV9hZA=="),
1484
+ i("LmFkZ29vZ2xl"),
1485
+ i("LmFkX3JlZ3VsYXIz")
1486
+ ],
1487
+ adGuardMobile: [
1488
+ i("YW1wLWF1dG8tYWRz"),
1489
+ i("LmFtcF9hZA=="),
1490
+ 'amp-embed[type="24smi"]',
1491
+ "#mgid_iframe1",
1492
+ i("I2FkX2ludmlld19hcmVh")
1493
+ ],
1494
+ adGuardRussian: [
1495
+ i("YVtocmVmXj0iaHR0cHM6Ly9hZC5sZXRtZWFkcy5jb20vIl0="),
1496
+ i("LnJlY2xhbWE="),
1497
+ 'div[id^="smi2adblock"]',
1498
+ i("ZGl2W2lkXj0iQWRGb3hfYmFubmVyXyJd"),
1499
+ i("I2FkX3NxdWFyZQ==")
1500
+ ],
1501
+ adGuardSocial: [
1502
+ i(
1503
+ "YVtocmVmXj0iLy93d3cuc3R1bWJsZXVwb24uY29tL3N1Ym1pdD91cmw9Il0="
1504
+ ),
1505
+ i("YVtocmVmXj0iLy90ZWxlZ3JhbS5tZS9zaGFyZS91cmw/Il0="),
1506
+ ".etsy-tweet",
1507
+ "#inlineShare",
1508
+ ".popup-social"
1509
+ ],
1510
+ adGuardSpanishPortuguese: [
1511
+ "#barraPublicidade",
1512
+ "#Publicidade",
1513
+ "#publiEspecial",
1514
+ "#queTooltip",
1515
+ i("W2hyZWZePSJodHRwOi8vYWRzLmdsaXNwYS5jb20vIl0=")
1516
+ ],
1517
+ adGuardTrackingProtection: [
1518
+ "#qoo-counter",
1519
+ i("YVtocmVmXj0iaHR0cDovL2NsaWNrLmhvdGxvZy5ydS8iXQ=="),
1520
+ i(
1521
+ "YVtocmVmXj0iaHR0cDovL2hpdGNvdW50ZXIucnUvdG9wL3N0YXQucGhwIl0="
1522
+ ),
1523
+ i("YVtocmVmXj0iaHR0cDovL3RvcC5tYWlsLnJ1L2p1bXAiXQ=="),
1524
+ "#top100counter"
1525
+ ],
1526
+ adGuardTurkish: [
1527
+ "#backkapat",
1528
+ i("I3Jla2xhbWk="),
1529
+ i("YVtocmVmXj0iaHR0cDovL2Fkc2Vydi5vbnRlay5jb20udHIvIl0="),
1530
+ i("YVtocmVmXj0iaHR0cDovL2l6bGVuemkuY29tL2NhbXBhaWduLyJd"),
1531
+ i("YVtocmVmXj0iaHR0cDovL3d3dy5pbnN0YWxsYWRzLm5ldC8iXQ==")
1532
+ ],
1533
+ bulgarian: [
1534
+ i("dGQjZnJlZW5ldF90YWJsZV9hZHM="),
1535
+ "#ea_intext_div",
1536
+ ".lapni-pop-over",
1537
+ "#xenium_hot_offers",
1538
+ i("I25ld0Fk")
1539
+ ],
1540
+ easyList: [
1541
+ i("I0FEX0NPTlRST0xfMjg="),
1542
+ i("LnNlY29uZC1wb3N0LWFkcy13cmFwcGVy"),
1543
+ ".universalboxADVBOX03",
1544
+ i("LmFkdmVydGlzZW1lbnQtNzI4eDkw"),
1545
+ i("LnNxdWFyZV9hZHM=")
1546
+ ],
1547
+ easyListChina: [
1548
+ i("YVtocmVmKj0iLndlbnNpeHVldGFuZy5jb20vIl0="),
1549
+ i("LmFwcGd1aWRlLXdyYXBbb25jbGljayo9ImJjZWJvcy5jb20iXQ=="),
1550
+ i("LmZyb250cGFnZUFkdk0="),
1551
+ "#taotaole",
1552
+ "#aafoot.top_box"
1553
+ ],
1554
+ easyListCookie: [
1555
+ "#AdaCompliance.app-notice",
1556
+ ".text-center.rgpd",
1557
+ ".panel--cookie",
1558
+ ".js-cookies-andromeda",
1559
+ ".elxtr-consent"
1560
+ ],
1561
+ easyListCzechSlovak: [
1562
+ "#onlajny-stickers",
1563
+ i("I3Jla2xhbW5pLWJveA=="),
1564
+ i("LnJla2xhbWEtbWVnYWJvYXJk"),
1565
+ ".sklik",
1566
+ i("W2lkXj0ic2tsaWtSZWtsYW1hIl0=")
1567
+ ],
1568
+ easyListDutch: [
1569
+ i("I2FkdmVydGVudGll"),
1570
+ i("I3ZpcEFkbWFya3RCYW5uZXJCbG9jaw=="),
1571
+ ".adstekst",
1572
+ i("YVtocmVmXj0iaHR0cHM6Ly94bHR1YmUubmwvY2xpY2svIl0="),
1573
+ "#semilo-lrectangle"
1574
+ ],
1575
+ easyListGermany: [
1576
+ i("I0FkX1dpbjJkYXk="),
1577
+ i("I3dlcmJ1bmdzYm94MzAw"),
1578
+ i(
1579
+ "YVtocmVmXj0iaHR0cDovL3d3dy5yb3RsaWNodGthcnRlaS5jb20vP3NjPSJd"
1580
+ ),
1581
+ i("I3dlcmJ1bmdfd2lkZXNreXNjcmFwZXJfc2NyZWVu"),
1582
+ i(
1583
+ "YVtocmVmXj0iaHR0cDovL2xhbmRpbmcucGFya3BsYXR6a2FydGVpLmNvbS8/YWc9Il0="
1584
+ )
1585
+ ],
1586
+ easyListItaly: [
1587
+ i("LmJveF9hZHZfYW5udW5jaQ=="),
1588
+ ".sb-box-pubbliredazionale",
1589
+ i(
1590
+ "YVtocmVmXj0iaHR0cDovL2FmZmlsaWF6aW9uaWFkcy5zbmFpLml0LyJd"
1591
+ ),
1592
+ i("YVtocmVmXj0iaHR0cHM6Ly9hZHNlcnZlci5odG1sLml0LyJd"),
1593
+ i(
1594
+ "YVtocmVmXj0iaHR0cHM6Ly9hZmZpbGlhemlvbmlhZHMuc25haS5pdC8iXQ=="
1595
+ )
1596
+ ],
1597
+ easyListLithuania: [
1598
+ i("LnJla2xhbW9zX3RhcnBhcw=="),
1599
+ i("LnJla2xhbW9zX251b3JvZG9z"),
1600
+ i("aW1nW2FsdD0iUmVrbGFtaW5pcyBza3lkZWxpcyJd"),
1601
+ i("aW1nW2FsdD0iRGVkaWt1b3RpLmx0IHNlcnZlcmlhaSJd"),
1602
+ i("aW1nW2FsdD0iSG9zdGluZ2FzIFNlcnZlcmlhaS5sdCJd")
1603
+ ],
1604
+ estonian: [
1605
+ i("QVtocmVmKj0iaHR0cDovL3BheTRyZXN1bHRzMjQuZXUiXQ==")
1606
+ ],
1607
+ fanboyAnnoyances: [
1608
+ "#feedback-tab",
1609
+ "#taboola-below-article",
1610
+ ".feedburnerFeedBlock",
1611
+ ".widget-feedburner-counter",
1612
+ '[title="Subscribe to our blog"]'
1613
+ ],
1614
+ fanboyAntiFacebook: [".util-bar-module-firefly-visible"],
1615
+ fanboyEnhancedTrackers: [
1616
+ ".open.pushModal",
1617
+ "#issuem-leaky-paywall-articles-zero-remaining-nag",
1618
+ "#sovrn_container",
1619
+ 'div[class$="-hide"][zoompage-fontsize][style="display: block;"]',
1620
+ ".BlockNag__Card"
1621
+ ],
1622
+ fanboySocial: [
1623
+ ".td-tags-and-social-wrapper-box",
1624
+ ".twitterContainer",
1625
+ ".youtube-social",
1626
+ 'a[title^="Like us on Facebook"]',
1627
+ 'img[alt^="Share on Digg"]'
1628
+ ],
1629
+ frellwitSwedish: [
1630
+ i(
1631
+ "YVtocmVmKj0iY2FzaW5vcHJvLnNlIl1bdGFyZ2V0PSJfYmxhbmsiXQ=="
1632
+ ),
1633
+ i("YVtocmVmKj0iZG9rdG9yLXNlLm9uZWxpbmsubWUiXQ=="),
1634
+ "article.category-samarbete",
1635
+ i("ZGl2LmhvbGlkQWRz"),
1636
+ "ul.adsmodern"
1637
+ ],
1638
+ greekAdBlock: [
1639
+ i("QVtocmVmKj0iYWRtYW4ub3RlbmV0LmdyL2NsaWNrPyJd"),
1640
+ i(
1641
+ "QVtocmVmKj0iaHR0cDovL2F4aWFiYW5uZXJzLmV4b2R1cy5nci8iXQ=="
1642
+ ),
1643
+ i(
1644
+ "QVtocmVmKj0iaHR0cDovL2ludGVyYWN0aXZlLmZvcnRobmV0LmdyL2NsaWNrPyJd"
1645
+ ),
1646
+ "DIV.agores300",
1647
+ "TABLE.advright"
1648
+ ],
1649
+ hungarian: [
1650
+ "#cemp_doboz",
1651
+ ".optimonk-iframe-container",
1652
+ i("LmFkX19tYWlu"),
1653
+ i("W2NsYXNzKj0iR29vZ2xlQWRzIl0="),
1654
+ "#hirdetesek_box"
1655
+ ],
1656
+ iDontCareAboutCookies: [
1657
+ '.alert-info[data-block-track*="CookieNotice"]',
1658
+ ".ModuleTemplateCookieIndicator",
1659
+ ".o--cookies--container",
1660
+ ".cookie-msg-info-container",
1661
+ "#cookies-policy-sticky"
1662
+ ],
1663
+ icelandicAbp: [
1664
+ i(
1665
+ "QVtocmVmXj0iL2ZyYW1ld29yay9yZXNvdXJjZXMvZm9ybXMvYWRzLmFzcHgiXQ=="
1666
+ )
1667
+ ],
1668
+ latvian: [
1669
+ i(
1670
+ "YVtocmVmPSJodHRwOi8vd3d3LnNhbGlkemluaS5sdi8iXVtzdHlsZT0iZGlzcGxheTogYmxvY2s7IHdpZHRoOiAxMjBweDsgaGVpZ2h0OiA0MHB4OyBvdmVyZmxvdzogaGlkZGVuOyBwb3NpdGlvbjogcmVsYXRpdmU7Il0="
1671
+ ),
1672
+ i(
1673
+ "YVtocmVmPSJodHRwOi8vd3d3LnNhbGlkemluaS5sdi8iXVtzdHlsZT0iZGlzcGxheTogYmxvY2s7IHdpZHRoOiA4OHB4OyBoZWlnaHQ6IDMxcHg7IG92ZXJmbG93OiBoaWRkZW47IHBvc2l0aW9uOiByZWxhdGl2ZTsiXQ=="
1674
+ )
1675
+ ],
1676
+ listKr: [
1677
+ i("YVtocmVmKj0iLy9hZC5wbGFuYnBsdXMuY28ua3IvIl0="),
1678
+ i("I2xpdmVyZUFkV3JhcHBlcg=="),
1679
+ i("YVtocmVmKj0iLy9hZHYuaW1hZHJlcC5jby5rci8iXQ=="),
1680
+ i("aW5zLmZhc3R2aWV3LWFk"),
1681
+ ".revenue_unit_item.dable"
1682
+ ],
1683
+ listeAr: [
1684
+ i("LmdlbWluaUxCMUFk"),
1685
+ ".right-and-left-sponsers",
1686
+ i("YVtocmVmKj0iLmFmbGFtLmluZm8iXQ=="),
1687
+ i("YVtocmVmKj0iYm9vcmFxLm9yZyJd"),
1688
+ i("YVtocmVmKj0iZHViaXp6bGUuY29tL2FyLz91dG1fc291cmNlPSJd")
1689
+ ],
1690
+ listeFr: [
1691
+ i("YVtocmVmXj0iaHR0cDovL3Byb21vLnZhZG9yLmNvbS8iXQ=="),
1692
+ i("I2FkY29udGFpbmVyX3JlY2hlcmNoZQ=="),
1693
+ i("YVtocmVmKj0id2Vib3JhbWEuZnIvZmNnaS1iaW4vIl0="),
1694
+ ".site-pub-interstitiel",
1695
+ 'div[id^="crt-"][data-criteo-id]'
1696
+ ],
1697
+ officialPolish: [
1698
+ "#ceneo-placeholder-ceneo-12",
1699
+ i("W2hyZWZePSJodHRwczovL2FmZi5zZW5kaHViLnBsLyJd"),
1700
+ i(
1701
+ "YVtocmVmXj0iaHR0cDovL2Fkdm1hbmFnZXIudGVjaGZ1bi5wbC9yZWRpcmVjdC8iXQ=="
1702
+ ),
1703
+ i(
1704
+ "YVtocmVmXj0iaHR0cDovL3d3dy50cml6ZXIucGwvP3V0bV9zb3VyY2UiXQ=="
1705
+ ),
1706
+ i("ZGl2I3NrYXBpZWNfYWQ=")
1707
+ ],
1708
+ ro: [
1709
+ i(
1710
+ "YVtocmVmXj0iLy9hZmZ0cmsuYWx0ZXgucm8vQ291bnRlci9DbGljayJd"
1711
+ ),
1712
+ 'a[href^="/magazin/"]',
1713
+ i(
1714
+ "YVtocmVmXj0iaHR0cHM6Ly9ibGFja2ZyaWRheXNhbGVzLnJvL3Ryay9zaG9wLyJd"
1715
+ ),
1716
+ i(
1717
+ "YVtocmVmXj0iaHR0cHM6Ly9ldmVudC4ycGVyZm9ybWFudC5jb20vZXZlbnRzL2NsaWNrIl0="
1718
+ ),
1719
+ i("YVtocmVmXj0iaHR0cHM6Ly9sLnByb2ZpdHNoYXJlLnJvLyJd")
1720
+ ],
1721
+ ruAd: [
1722
+ i("YVtocmVmKj0iLy9mZWJyYXJlLnJ1LyJd"),
1723
+ i("YVtocmVmKj0iLy91dGltZy5ydS8iXQ=="),
1724
+ i("YVtocmVmKj0iOi8vY2hpa2lkaWtpLnJ1Il0="),
1725
+ "#pgeldiz",
1726
+ ".yandex-rtb-block"
1727
+ ],
1728
+ thaiAds: [
1729
+ "a[href*=macau-uta-popup]",
1730
+ i("I2Fkcy1nb29nbGUtbWlkZGxlX3JlY3RhbmdsZS1ncm91cA=="),
1731
+ i("LmFkczMwMHM="),
1732
+ ".bumq",
1733
+ ".img-kosana"
1734
+ ],
1735
+ webAnnoyancesUltralist: [
1736
+ "#mod-social-share-2",
1737
+ "#social-tools",
1738
+ i("LmN0cGwtZnVsbGJhbm5lcg=="),
1739
+ ".zergnet-recommend",
1740
+ ".yt.btn-link.btn-md.btn"
1741
+ ]
1742
+ }, r = Object.keys(n), [
1743
+ 4,
1744
+ tr(
1745
+ (s = []).concat.apply(
1746
+ s,
1747
+ r.map(function(u) {
1748
+ return n[u];
1749
+ })
1750
+ )
1751
+ )
1752
+ ]) : [2, void 0];
1753
+ case 1:
1754
+ return o = c.sent(), t && (function(u, l) {
1755
+ for (var h = "DOM blockers debug:\n```", v = 0, g = Object.keys(u); v < g.length; v++) {
1756
+ const S = g[v];
1757
+ h += `
1758
+ `.concat(S, ":");
1759
+ for (let y = 0, m = u[S]; y < m.length; y++) {
1760
+ const k = m[y];
1761
+ h += `
1762
+ `.concat(l[k] ? "🚫" : "➡️", " ").concat(k);
1763
+ }
1764
+ }
1765
+ console.log("".concat(h, "\n```"));
1766
+ })(n, o), (a = r.filter(function(u) {
1767
+ const l = n[u];
1768
+ return U(
1769
+ l.map(function(h) {
1770
+ return o[h];
1771
+ })
1772
+ ) > 0.6 * l.length;
1773
+ })).sort(), [2, a];
1774
+ }
1775
+ let i;
1776
+ });
1777
+ });
1778
+ },
1779
+ fontPreferences: function() {
1780
+ return (function(e, t) {
1781
+ return t === void 0 && (t = 4e3), gt(function(n, r) {
1782
+ const o = r.document, a = o.body, s = a.style;
1783
+ s.width = "".concat(t, "px"), s.webkitTextSizeAdjust = s.textSizeAdjust = "none", ze() ? a.style.zoom = "".concat(1 / r.devicePixelRatio) : me() && (a.style.zoom = "reset");
1784
+ const c = o.createElement("div");
1785
+ return c.textContent = ie([], Array(t / 20 << 0), !0).map(function() {
1786
+ return "word";
1787
+ }).join(" "), a.appendChild(c), e(o, a);
1788
+ });
1789
+ })(function(e, t) {
1790
+ for (var n = {}, r = {}, o = 0, a = Object.keys(He); o < a.length; o++) {
1791
+ var s = a[o], c = He[s], i = c[0], u = i === void 0 ? {} : i, l = c[1], h = l === void 0 ? "mmMwWLliI0fiflO&1" : l, v = e.createElement("span");
1792
+ v.textContent = h, v.style.whiteSpace = "nowrap";
1793
+ for (let g = 0, S = Object.keys(u); g < S.length; g++) {
1794
+ const y = S[g], m = u[y];
1795
+ m !== void 0 && (v.style[y] = m);
1796
+ }
1797
+ n[s] = v, t.appendChild(e.createElement("br")), t.appendChild(v);
1798
+ }
1799
+ for (let g = 0, S = Object.keys(He); g < S.length; g++)
1800
+ r[s = S[g]] = n[s].getBoundingClientRect().width;
1801
+ return r;
1802
+ });
1803
+ },
1804
+ audio: function() {
1805
+ const e = window, t = e.OfflineAudioContext || e.webkitOfflineAudioContext;
1806
+ if (!t) return -2;
1807
+ if (me() && !Je() && !(function() {
1808
+ const u = window;
1809
+ return U([
1810
+ "DOMRectList" in u,
1811
+ "RTCPeerConnectionIceEvent" in u,
1812
+ "SVGGeometryElement" in u,
1813
+ "ontransitioncancel" in u
1814
+ ]) >= 3;
1815
+ })())
1816
+ return -1;
1817
+ const n = new t(1, 5e3, 44100), r = n.createOscillator();
1818
+ r.type = "triangle", r.frequency.value = 1e4;
1819
+ const o = n.createDynamicsCompressor();
1820
+ o.threshold.value = -50, o.knee.value = 40, o.ratio.value = 12, o.attack.value = 0, o.release.value = 0.25, r.connect(o), o.connect(n.destination), r.start(0);
1821
+ const a = (function(u) {
1822
+ let l = 3, h = 500, v = 500, g = 5e3, S = function() {
1823
+ };
1824
+ return [
1825
+ new Promise(function(y, m) {
1826
+ let k = !1, x = 0, j = 0;
1827
+ u.oncomplete = function(_) {
1828
+ return y(_.renderedBuffer);
1829
+ };
1830
+ const q = function() {
1831
+ setTimeout(function() {
1832
+ return m(vt("timeout"));
1833
+ }, Math.min(v, j + g - Date.now()));
1834
+ }, ye = function() {
1835
+ try {
1836
+ const _ = u.startRendering();
1837
+ switch (Vt(_) && ke(_), u.state) {
1838
+ case "running":
1839
+ j = Date.now(), k && q();
1840
+ break;
1841
+ case "suspended":
1842
+ document.hidden || x++, k && x >= l ? m(vt("suspended")) : setTimeout(ye, h);
1843
+ }
1844
+ } catch (_) {
1845
+ m(_);
1846
+ }
1847
+ };
1848
+ ye(), S = function() {
1849
+ k || (k = !0, j > 0 && q());
1850
+ };
1851
+ }),
1852
+ S
1853
+ ];
1854
+ })(n), s = a[0], c = a[1], i = s.then(
1855
+ function(u) {
1856
+ return (function(l) {
1857
+ for (var h = 0, v = 0; v < l.length; ++v) h += Math.abs(l[v]);
1858
+ return h;
1859
+ })(u.getChannelData(0).subarray(4500));
1860
+ },
1861
+ function(u) {
1862
+ if (u.name === "timeout" || u.name === "suspended") return -3;
1863
+ throw u;
1864
+ }
1865
+ );
1866
+ return ke(i), function() {
1867
+ return c(), i;
1868
+ };
1869
+ },
1870
+ screenFrame: function() {
1871
+ const e = this, t = er();
1872
+ return function() {
1873
+ return G(e, void 0, void 0, function() {
1874
+ let n, r;
1875
+ return W(this, function(o) {
1876
+ switch (o.label) {
1877
+ case 0:
1878
+ return [4, t()];
1879
+ case 1:
1880
+ return n = o.sent(), [
1881
+ 2,
1882
+ [
1883
+ (r = function(a) {
1884
+ return a === null ? null : Ht(a, 10);
1885
+ })(n[0]),
1886
+ r(n[1]),
1887
+ r(n[2]),
1888
+ r(n[3])
1889
+ ]
1890
+ ];
1891
+ }
1892
+ });
1893
+ });
1894
+ };
1895
+ },
1896
+ osCpu: function() {
1897
+ return navigator.oscpu;
1898
+ },
1899
+ languages: function() {
1900
+ let e, t = navigator, n = [], r = t.language || t.userLanguage || t.browserLanguage || t.systemLanguage;
1901
+ if (r !== void 0 && n.push([r]), Array.isArray(t.languages))
1902
+ ze() && U([
1903
+ !("MediaSettingsRange" in (e = window)),
1904
+ "RTCEncodedAudioFrame" in e,
1905
+ "" + e.Intl == "[object Intl]",
1906
+ "" + e.Reflect == "[object Reflect]"
1907
+ ]) >= 3 || n.push(t.languages);
1908
+ else if (typeof t.languages == "string") {
1909
+ const o = t.languages;
1910
+ o && n.push(o.split(","));
1911
+ }
1912
+ return n;
1913
+ },
1914
+ colorDepth: function() {
1915
+ return window.screen.colorDepth;
1916
+ },
1917
+ deviceMemory: function() {
1918
+ return Z(X(navigator.deviceMemory), void 0);
1919
+ },
1920
+ screenResolution: function() {
1921
+ const e = screen, t = function(r) {
1922
+ return Z(xe(r), null);
1923
+ }, n = [t(e.width), t(e.height)];
1924
+ return n.sort().reverse(), n;
1925
+ },
1926
+ hardwareConcurrency: function() {
1927
+ return Z(xe(navigator.hardwareConcurrency), void 0);
1928
+ },
1929
+ timezone: function() {
1930
+ let e, t = (e = window.Intl) === null || e === void 0 ? void 0 : e.DateTimeFormat;
1931
+ if (t) {
1932
+ const o = new t().resolvedOptions().timeZone;
1933
+ if (o) return o;
1934
+ }
1935
+ let n, r = (n = (/* @__PURE__ */ new Date()).getFullYear(), -Math.max(
1936
+ X(new Date(n, 0, 1).getTimezoneOffset()),
1937
+ X(new Date(n, 6, 1).getTimezoneOffset())
1938
+ ));
1939
+ return "UTC".concat(r >= 0 ? "+" : "").concat(Math.abs(r));
1940
+ },
1941
+ sessionStorage: function() {
1942
+ try {
1943
+ return !!window.sessionStorage;
1944
+ } catch {
1945
+ return !0;
1946
+ }
1947
+ },
1948
+ localStorage: function() {
1949
+ try {
1950
+ return !!window.localStorage;
1951
+ } catch {
1952
+ return !0;
1953
+ }
1954
+ },
1955
+ indexedDB: function() {
1956
+ if (!Dt() && !Jn())
1957
+ try {
1958
+ return !!window.indexedDB;
1959
+ } catch {
1960
+ return !0;
1961
+ }
1962
+ },
1963
+ openDatabase: function() {
1964
+ return !!window.openDatabase;
1965
+ },
1966
+ cpuClass: function() {
1967
+ return navigator.cpuClass;
1968
+ },
1969
+ platform: function() {
1970
+ const e = navigator.platform;
1971
+ return e === "MacIntel" && me() && !Je() ? (function() {
1972
+ if (navigator.platform === "iPad") return !0;
1973
+ const t = screen, n = t.width / t.height;
1974
+ return U([
1975
+ "MediaSource" in window,
1976
+ !!Element.prototype.webkitRequestFullscreen,
1977
+ n > 0.65 && n < 1.53
1978
+ ]) >= 2;
1979
+ })() ? "iPad" : "iPhone" : e;
1980
+ },
1981
+ plugins: function() {
1982
+ const e = navigator.plugins;
1983
+ if (e) {
1984
+ for (var t = [], n = 0; n < e.length; ++n) {
1985
+ const a = e[n];
1986
+ if (a) {
1987
+ for (var r = [], o = 0; o < a.length; ++o) {
1988
+ const s = a[o];
1989
+ r.push({ type: s.type, suffixes: s.suffixes });
1990
+ }
1991
+ t.push({ name: a.name, description: a.description, mimeTypes: r });
1992
+ }
1993
+ }
1994
+ return t;
1995
+ }
1996
+ },
1997
+ canvas: function() {
1998
+ let e, t, n = !1, r = (function() {
1999
+ const s = document.createElement("canvas");
2000
+ return s.width = 1, s.height = 1, [s, s.getContext("2d")];
2001
+ })(), o = r[0], a = r[1];
2002
+ if ((function(s, c) {
2003
+ return !(!c || !s.toDataURL);
2004
+ })(o, a)) {
2005
+ n = (function(c) {
2006
+ return c.rect(0, 0, 10, 10), c.rect(2, 2, 6, 6), !c.isPointInPath(5, 5, "evenodd");
2007
+ })(a), (function(c, i) {
2008
+ c.width = 240, c.height = 60, i.textBaseline = "alphabetic", i.fillStyle = "#f60", i.fillRect(100, 1, 62, 20), i.fillStyle = "#069", i.font = '11pt "Times New Roman"';
2009
+ const u = "Cwm fjordbank gly ".concat(
2010
+ "😃"
2011
+ );
2012
+ i.fillText(u, 2, 15), i.fillStyle = "rgba(102, 204, 0, 0.2)", i.font = "18pt Arial", i.fillText(u, 4, 45);
2013
+ })(o, a);
2014
+ const s = Ne(o);
2015
+ s !== Ne(o) ? e = t = "unstable" : (t = s, (function(c, i) {
2016
+ c.width = 122, c.height = 110, i.globalCompositeOperation = "multiply";
2017
+ for (let u = 0, l = [
2018
+ ["#f2f", 40, 40],
2019
+ ["#2ff", 80, 40],
2020
+ ["#ff2", 60, 80]
2021
+ ]; u < l.length; u++) {
2022
+ const h = l[u], v = h[0], g = h[1], S = h[2];
2023
+ i.fillStyle = v, i.beginPath(), i.arc(g, S, 40, 0, 2 * Math.PI, !0), i.closePath(), i.fill();
2024
+ }
2025
+ i.fillStyle = "#f9c", i.arc(60, 60, 60, 0, 2 * Math.PI, !0), i.arc(60, 60, 20, 0, 2 * Math.PI, !0), i.fill("evenodd");
2026
+ })(o, a), e = Ne(o));
2027
+ } else e = t = "";
2028
+ return { winding: n, geometry: e, text: t };
2029
+ },
2030
+ touchSupport: function() {
2031
+ let e, t = navigator, n = 0;
2032
+ t.maxTouchPoints !== void 0 ? n = xe(t.maxTouchPoints) : t.msMaxTouchPoints !== void 0 && (n = t.msMaxTouchPoints);
2033
+ try {
2034
+ document.createEvent("TouchEvent"), e = !0;
2035
+ } catch {
2036
+ e = !1;
2037
+ }
2038
+ return {
2039
+ maxTouchPoints: n,
2040
+ touchEvent: e,
2041
+ touchStart: "ontouchstart" in window
2042
+ };
2043
+ },
2044
+ vendor: function() {
2045
+ return navigator.vendor || "";
2046
+ },
2047
+ vendorFlavors: function() {
2048
+ for (var e = [], t = 0, n = [
2049
+ "chrome",
2050
+ "safari",
2051
+ "__crWeb",
2052
+ "__gCrWeb",
2053
+ "yandex",
2054
+ "__yb",
2055
+ "__ybro",
2056
+ "__firefox__",
2057
+ "__edgeTrackingPreventionStatistics",
2058
+ "webkit",
2059
+ "oprt",
2060
+ "samsungAr",
2061
+ "ucweb",
2062
+ "UCShellJava",
2063
+ "puffinDevice"
2064
+ ]; t < n.length; t++) {
2065
+ const r = n[t], o = window[r];
2066
+ o && typeof o == "object" && e.push(r);
2067
+ }
2068
+ return e.sort();
2069
+ },
2070
+ cookiesEnabled: function() {
2071
+ const e = document;
2072
+ try {
2073
+ e.cookie = "cookietest=1; SameSite=Strict;";
2074
+ const t = e.cookie.indexOf("cookietest=") !== -1;
2075
+ return e.cookie = "cookietest=1; SameSite=Strict; expires=Thu, 01-Jan-1970 00:00:01 GMT", t;
2076
+ } catch {
2077
+ return !1;
2078
+ }
2079
+ },
2080
+ colorGamut: function() {
2081
+ for (let e = 0, t = ["rec2020", "p3", "srgb"]; e < t.length; e++) {
2082
+ const n = t[e];
2083
+ if (matchMedia("(color-gamut: ".concat(n, ")")).matches) return n;
2084
+ }
2085
+ },
2086
+ invertedColors: function() {
2087
+ return !!Et("inverted") || !Et("none") && void 0;
2088
+ },
2089
+ forcedColors: function() {
2090
+ return !!St("active") || !St("none") && void 0;
2091
+ },
2092
+ monochrome: function() {
2093
+ if (matchMedia("(min-monochrome: 0)").matches) {
2094
+ for (let e = 0; e <= 100; ++e)
2095
+ if (matchMedia("(max-monochrome: ".concat(e, ")")).matches) return e;
2096
+ throw new Error("Too high value");
2097
+ }
2098
+ },
2099
+ contrast: function() {
2100
+ return oe("no-preference") ? 0 : oe("high") || oe("more") ? 1 : oe("low") || oe("less") ? -1 : oe("forced") ? 10 : void 0;
2101
+ },
2102
+ reducedMotion: function() {
2103
+ return !!Lt("reduce") || !Lt("no-preference") && void 0;
2104
+ },
2105
+ hdr: function() {
2106
+ return !!wt("high") || !wt("standard") && void 0;
2107
+ },
2108
+ math: function() {
2109
+ let e, t = L.acos || N, n = L.acosh || N, r = L.asin || N, o = L.asinh || N, a = L.atanh || N, s = L.atan || N, c = L.sin || N, i = L.sinh || N, u = L.cos || N, l = L.cosh || N, h = L.tan || N, v = L.tanh || N, g = L.exp || N, S = L.expm1 || N, y = L.log1p || N;
2110
+ return {
2111
+ acos: t(0.12312423423423424),
2112
+ acosh: n(1e308),
2113
+ acoshPf: (e = 1e154, L.log(e + L.sqrt(e * e - 1))),
2114
+ asin: r(0.12312423423423424),
2115
+ asinh: o(1),
2116
+ asinhPf: (function(m) {
2117
+ return L.log(m + L.sqrt(m * m + 1));
2118
+ })(1),
2119
+ atanh: a(0.5),
2120
+ atanhPf: (function(m) {
2121
+ return L.log((1 + m) / (1 - m)) / 2;
2122
+ })(0.5),
2123
+ atan: s(0.5),
2124
+ sin: c(-1e300),
2125
+ sinh: i(1),
2126
+ sinhPf: (function(m) {
2127
+ return L.exp(m) - 1 / L.exp(m) / 2;
2128
+ })(1),
2129
+ cos: u(10.000000000123),
2130
+ cosh: l(1),
2131
+ coshPf: (function(m) {
2132
+ return (L.exp(m) + 1 / L.exp(m)) / 2;
2133
+ })(1),
2134
+ tan: h(-1e300),
2135
+ tanh: v(1),
2136
+ tanhPf: (function(m) {
2137
+ return (L.exp(2 * m) - 1) / (L.exp(2 * m) + 1);
2138
+ })(1),
2139
+ exp: g(1),
2140
+ expm1: S(1),
2141
+ expm1Pf: (function(m) {
2142
+ return L.exp(m) - 1;
2143
+ })(1),
2144
+ log1p: y(10),
2145
+ log1pPf: (function(m) {
2146
+ return L.log(1 + m);
2147
+ })(10),
2148
+ powPI: (function(m) {
2149
+ return L.pow(L.PI, m);
2150
+ })(-100)
2151
+ };
2152
+ },
2153
+ videoCard: function() {
2154
+ let e, t = document.createElement("canvas"), n = (e = t.getContext("webgl")) !== null && e !== void 0 ? e : t.getContext("experimental-webgl");
2155
+ if (n && "getExtension" in n) {
2156
+ const r = n.getExtension("WEBGL_debug_renderer_info");
2157
+ if (r)
2158
+ return {
2159
+ vendor: (n.getParameter(r.UNMASKED_VENDOR_WEBGL) || "").toString(),
2160
+ renderer: (n.getParameter(r.UNMASKED_RENDERER_WEBGL) || "").toString()
2161
+ };
2162
+ }
2163
+ },
2164
+ pdfViewerEnabled: function() {
2165
+ return navigator.pdfViewerEnabled;
2166
+ },
2167
+ architecture: function() {
2168
+ const e = new Float32Array(1), t = new Uint8Array(e.buffer);
2169
+ return e[0] = 1 / 0, e[0] = e[0] - e[0], t[3];
2170
+ }
2171
+ };
2172
+ function rr(e) {
2173
+ const t = (function(r) {
2174
+ if (Xt()) return 0.4;
2175
+ if (me()) return Je() ? 0.5 : 0.3;
2176
+ const o = r.platform.value || "";
2177
+ return /^Win/.test(o) ? 0.6 : /^Mac/.test(o) ? 0.5 : 0.7;
2178
+ })(e), n = (function(r) {
2179
+ return Ht(0.99 + 0.01 * r, 1e-4);
2180
+ })(t);
2181
+ return {
2182
+ score: t,
2183
+ comment: "$ if upgrade to Pro: https://fpjs.dev/pro".replace(
2184
+ /\$/g,
2185
+ "".concat(n)
2186
+ )
2187
+ };
2188
+ }
2189
+ function or(e) {
2190
+ return JSON.stringify(
2191
+ e,
2192
+ function(t, n) {
2193
+ return n instanceof Error ? _e(
2194
+ {
2195
+ name: (ie = n).name,
2196
+ message: ie.message,
2197
+ stack: (Y = ie.stack) === null || Y === void 0 ? void 0 : Y.split(`
2198
+ `)
2199
+ },
2200
+ ie
2201
+ ) : n;
2202
+ },
2203
+ 2
2204
+ );
2205
+ }
2206
+ function ir(e) {
2207
+ return Gn(
2208
+ (function(t) {
2209
+ for (var n = "", r = 0, o = Object.keys(t).sort(); r < o.length; r++) {
2210
+ const a = o[r], s = t[a], c = s.error ? "error" : JSON.stringify(s.value);
2211
+ n += "".concat(n ? "|" : "").concat(a.replace(/([:|\\])/g, "\\$1"), ":").concat(c);
2212
+ }
2213
+ return n;
2214
+ })(e)
2215
+ );
2216
+ }
2217
+ function ar(e) {
2218
+ return e === void 0 && (e = 50), (function(t, n) {
2219
+ n === void 0 && (n = 1 / 0);
2220
+ const r = window.requestIdleCallback;
2221
+ return r ? new Promise(function(o) {
2222
+ return r.call(
2223
+ window,
2224
+ function() {
2225
+ return o();
2226
+ },
2227
+ { timeout: n }
2228
+ );
2229
+ }) : Y(Math.min(t, n));
2230
+ })(e, 2 * e);
2231
+ }
2232
+ function sr(e, t) {
2233
+ const n = Date.now();
2234
+ return {
2235
+ get: function(r) {
2236
+ return G(this, void 0, void 0, function() {
2237
+ let o, a, s;
2238
+ return W(this, function(c) {
2239
+ switch (c.label) {
2240
+ case 0:
2241
+ return o = Date.now(), [4, e()];
2242
+ case 1:
2243
+ return a = c.sent(), s = (function(i) {
2244
+ let u;
2245
+ return {
2246
+ get visitorId() {
2247
+ return u === void 0 && (u = ir(this.components)), u;
2248
+ },
2249
+ set visitorId(l) {
2250
+ u = l;
2251
+ },
2252
+ confidence: rr(i),
2253
+ components: i,
2254
+ version: "3.4.1"
2255
+ };
2256
+ })(a), (t || r?.debug) && console.log(
2257
+ "Copy the text below to get the debug data:\n\n```\nversion: ".concat(s.version, `
2258
+ userAgent: `).concat(navigator.userAgent, `
2259
+ timeBetweenLoadAndGet: `).concat(o - n, `
2260
+ visitorId: `).concat(s.visitorId, `
2261
+ components: `).concat(or(a), "\n```")
2262
+ ), [2, s];
2263
+ }
2264
+ });
2265
+ });
2266
+ }
2267
+ };
2268
+ }
2269
+ function cr(e) {
2270
+ const t = e === void 0 ? {} : e, n = t.delayFallback, r = t.debug;
2271
+ return t.monitoring, G(this, void 0, void 0, function() {
2272
+ return W(this, function(o) {
2273
+ switch (o.label) {
2274
+ case 0:
2275
+ return [4, ar(n)];
2276
+ case 1:
2277
+ return o.sent(), [2, sr(zn(nr, { debug: r }, []), r)];
2278
+ }
2279
+ });
2280
+ });
2281
+ }
2282
+ function nt() {
2283
+ const e = tt(Ye) || `s_${We()}`, t = new Date(R() + Rn);
2284
+ return document.cookie = `${Ye}=${e};path=/;max-age=1800;expires=${t.toUTCString()}`, e;
2285
+ }
2286
+ function ur() {
2287
+ return tt(Ye) || nt();
2288
+ }
2289
+ nt();
2290
+ function lr(e) {
2291
+ return Ut.test(e);
2292
+ }
2293
+ function dr(e) {
2294
+ return jt.test(e);
2295
+ }
2296
+ const Ut = /((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])/, jt = /((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))/, fr = [jt, Ut];
2297
+ function hr(e) {
2298
+ let t, n = window.RTCPeerConnection || window.mozRTCPeerConnection || window.webkitRTCPeerConnection;
2299
+ function r() {
2300
+ (t = new n({
2301
+ iceServers: [{ urls: "stun:stun.l.google.com:19302" }]
2302
+ })).onicecandidate = (s) => a(s), t.createDataChannel("fake_data_channel");
2303
+ }
2304
+ function o() {
2305
+ return t.createOffer().then((s) => t.setLocalDescription(s));
2306
+ }
2307
+ function a(s) {
2308
+ s && s.candidate && s.candidate.candidate && e(s && s.candidate && s.candidate.candidate);
2309
+ }
2310
+ return {
2311
+ start: function() {
2312
+ r(), o();
2313
+ },
2314
+ stop: function() {
2315
+ if (t)
2316
+ try {
2317
+ t.close();
2318
+ } finally {
2319
+ t.onicecandidate = () => {
2320
+ }, t = null;
2321
+ }
2322
+ },
2323
+ createConnection: r,
2324
+ createStunRequest: o,
2325
+ handleCandidates: a
2326
+ };
2327
+ }
2328
+ function qe(e) {
2329
+ if (e && e < 100)
2330
+ throw new Error("Custom timeout cannot be under 100 milliseconds.");
2331
+ const t = [], n = hr(function(o) {
2332
+ const a = [];
2333
+ for (const s of fr) {
2334
+ const c = [], i = s.exec(o);
2335
+ if (i) {
2336
+ for (let u = 0; u < i.length; u++)
2337
+ (lr(i[u]) || dr(i[u])) && c.push(i[u]);
2338
+ a.push(c);
2339
+ }
2340
+ }
2341
+ (function(s) {
2342
+ t.includes(s) || t.push(r(s.flat(1 / 0)));
2343
+ })(a.flat(1 / 0));
2344
+ });
2345
+ function r(o) {
2346
+ return Array.from(new Set(o));
2347
+ }
2348
+ return new Promise(function(o, a) {
2349
+ n.start(), setTimeout(() => {
2350
+ t && t !== [] ? o(r(t.flat(1 / 0))) : a("No IP addresses were found."), n.stop();
2351
+ }, e || 500);
2352
+ });
2353
+ }
2354
+ function rt(e) {
2355
+ return new Promise(function(t, n) {
2356
+ const r = [];
2357
+ qe(e).then((o) => {
2358
+ o.forEach((a) => {
2359
+ a.match(/^(192\.168\.|169\.254\.|10\.|172\.(1[6-9]|2\d|3[01]))/) ? r.push({ ip: a, type: "private", IPv4: !0 }) : a.match(
2360
+ /((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))/
2361
+ ) ? r.push({ ip: a, type: "IPv6", IPv4: !1 }) : r.push({ ip: a, type: "public", IPv4: !0 });
2362
+ }), t(r);
2363
+ }).catch(n);
2364
+ });
2365
+ }
2366
+ function mr(e) {
2367
+ return rt(e).then((t) => {
2368
+ const n = t.filter((r) => r.IPv4);
2369
+ for (let r = 0; r < n.length; r++) n[r] = n[r].ip;
2370
+ return n || "";
2371
+ });
2372
+ }
2373
+ function pr(e) {
2374
+ return rt(e).then((t) => {
2375
+ const n = t.filter((r) => r.type === "IPv6");
2376
+ for (let r = 0; r < n.length; r++) n[r] = n[r].ip;
2377
+ return n ? n.ip : "";
2378
+ });
2379
+ }
2380
+ function Wt(e) {
2381
+ return Object.assign(qe(e), {
2382
+ types: rt,
2383
+ public: qe,
2384
+ IPv4: mr,
2385
+ IPv6: pr
2386
+ });
2387
+ }
2388
+ class $e {
2389
+ static maxSize = 0.01 * 1024 * 1e3;
2390
+ // 5Mb
2391
+ static getItem(t) {
2392
+ const n = localStorage.getItem(t);
2393
+ return n ? JSON.parse(n) : null;
2394
+ }
2395
+ static setItem(t, n) {
2396
+ localStorage.setItem(t, JSON.stringify(n));
2397
+ }
2398
+ static removeItem(t) {
2399
+ localStorage.removeItem(t);
2400
+ }
2401
+ static getSize() {
2402
+ let t = 0;
2403
+ for (let n = 0; n < localStorage.length; n++) {
2404
+ const r = localStorage.key(n);
2405
+ if (r) {
2406
+ const o = localStorage.getItem(r);
2407
+ o && (t += this.getBytes(o));
2408
+ }
2409
+ }
2410
+ return t;
2411
+ }
2412
+ /**
2413
+ * sendData专属存储
2414
+ * 特殊性:
2415
+ * 1. 每次存储检查最大容量(5M),如超过则不再继续存并通知外部
2416
+ * 2. 按照特定结构去拼接
2417
+ *
2418
+ * 注意:刷新页面测试会加入卸载事件,这在控制台是看不到的
2419
+ */
2420
+ static setSendDataItem(t, n) {
2421
+ if (this.getSize() >= this.maxSize) return !1;
2422
+ const r = this.getItem(t) || {
2423
+ baseInfo: {},
2424
+ eventInfo: []
2425
+ }, o = {
2426
+ baseInfo: Ie(r.baseInfo, n.baseInfo),
2427
+ eventInfo: r.eventInfo.concat(n.eventInfo)
2428
+ };
2429
+ return this.setItem(t, o), !0;
2430
+ }
2431
+ static getBytes(t) {
2432
+ return new Blob([t]).size;
2433
+ }
2434
+ }
2435
+ class vr {
2436
+ events = [];
2437
+ // 批次队列
2438
+ timeoutID;
2439
+ // 延迟发送ID
2440
+ isServerAvailable = !0;
2441
+ // 接口是否可用
2442
+ retryTimer;
2443
+ // 重试定时器
2444
+ /**
2445
+ * 发送事件列表
2446
+ */
2447
+ send() {
2448
+ if (!this.events.length || !this.isServerAvailable) return;
2449
+ const t = this.events.slice(0, d.value.cacheMaxLength);
2450
+ this.events = this.events.slice(d.value.cacheMaxLength);
2451
+ const n = R(), r = Pt(() => ({
2452
+ baseInfo: {
2453
+ ...le.base?.value,
2454
+ sendTime: n,
2455
+ userUuid: d.value.userUuid
2456
+ },
2457
+ eventInfo: Mt(t, (s) => (s.sendTime = n, s))
2458
+ })), o = d.value.transformSendParams ? d.value.transformSendParams(r.value) : null;
2459
+ if (d.value.localization) {
2460
+ $e.setSendDataItem(
2461
+ Ge,
2462
+ r.value
2463
+ ) || d.value.localizationOverFlow(r.value);
2464
+ return;
2465
+ }
2466
+ const a = Ee(
2467
+ d.value.beforeSendData,
2468
+ !1,
2469
+ o ?? r.value
2470
+ );
2471
+ Ce(a) || this.validateObject(a, "beforeSendData") && (ae("send events", a), this.executeSend(d.value.dsn, a).then((s) => {
2472
+ s.success === !1 ? this.handleServerError() : (this.isServerAvailable = !0, Ee(d.value.afterSendData, !0, {
2473
+ ...s,
2474
+ params: a
2475
+ }));
2476
+ }), this.events.length && bn(this.send.bind(this)));
2477
+ }
2478
+ handleServerError() {
2479
+ if (this.isServerAvailable = !1, this.retryTimer && clearTimeout(this.retryTimer), d.value.checkRecoverInterval === -1) return;
2480
+ const t = (d.value.checkRecoverInterval ?? 1) * 60 * 1e3;
2481
+ this.retryTimer = setTimeout(() => {
2482
+ this.testServerAvailable();
2483
+ }, t);
2484
+ }
2485
+ testServerAvailable() {
2486
+ st(d.value.dsn, { ping: 1 }, d.value.timeout).then(() => {
2487
+ this.isServerAvailable = !0, this.retryTimer && clearTimeout(this.retryTimer), this.events.length && this.send();
2488
+ }).catch(() => {
2489
+ this.handleServerError();
2490
+ });
2491
+ }
2492
+ /**
2493
+ * 发送本地事件列表
2494
+ * @param e 需要发送的事件信息
2495
+ */
2496
+ sendLocal(t) {
2497
+ const n = d.value.transformSendParams ? d.value.transformSendParams(t) : null, r = Ee(
2498
+ d.value.beforeSendData,
2499
+ !1,
2500
+ n ?? t
2501
+ );
2502
+ Ce(r) || this.validateObject(r, "beforeSendData") && (ae("send events", r), this.executeSend(d.value.dsn, r));
2503
+ }
2504
+ /**
2505
+ * 记录需要发送的埋点数据
2506
+ * @param e 需要发送的事件信息
2507
+ * @param flush 是否立即发送
2508
+ */
2509
+ emit(t, n = !1) {
2510
+ if (!t || !C.lineStatus.onLine || !n && !dn(d.value.tracesSampleRate)) return;
2511
+ Te(t) || (t = [t]);
2512
+ const r = d.value.maxQueueLength ?? 200;
2513
+ if (!this.isServerAvailable && this.events.length >= r) {
2514
+ this.events = this.events.slice(this.events.length - r + t.length).concat(t);
2515
+ return;
2516
+ }
2517
+ const o = Ee(
2518
+ d.value.beforePushEventList,
2519
+ !1,
2520
+ t
2521
+ );
2522
+ Ce(o) || this.validateObject(o, "beforePushEventList") && (this.events = this.events.concat(o), nt(), this.timeoutID && clearTimeout(this.timeoutID), le._initSuccess && (this.events.length >= d.value.cacheMaxLength || n ? this.send() : this.timeoutID = setTimeout(
2523
+ this.send.bind(this),
2524
+ d.value.cacheWatingTime
2525
+ )));
2526
+ }
2527
+ /**
2528
+ * 发送数据
2529
+ * @param url 目标地址
2530
+ * @param data 附带参数
2531
+ */
2532
+ executeSend(t, n) {
2533
+ let r = 1;
2534
+ return d.value.sendTypeByXmlBody ? r = 3 : p.navigator ? r = ct(n, 60) ? 3 : 1 : r = ct(n, 2) ? 3 : 2, new Promise((o) => {
2535
+ switch (r) {
2536
+ case 1:
2537
+ o({ sendType: "sendBeacon", success: hn(t, n) });
2538
+ break;
2539
+ case 2:
2540
+ mn(t, n).then(() => {
2541
+ o({ sendType: "image", success: !0 });
2542
+ }).catch(() => {
2543
+ o({ sendType: "image", success: !1 });
2544
+ });
2545
+ break;
2546
+ case 3:
2547
+ st(t, n, d.value.timeout).then(() => {
2548
+ o({ sendType: "xml", success: !0 });
2549
+ }).catch(() => {
2550
+ o({ sendType: "xml", success: !1 });
2551
+ });
2552
+ break;
2553
+ }
2554
+ });
2555
+ }
2556
+ /**
2557
+ * 验证选项的类型 - 只验证是否为 {} []
2558
+ * 返回 false意思是取消放入队列 / 取消发送
2559
+ */
2560
+ validateObject(t, n) {
2561
+ return t === !1 ? !1 : t ? ["object", "array"].includes(ue(t)) ? !0 : (se(
2562
+ `TypeError: ${n}期望返回 {} 或者 [] 类型,目前是${ue(
2563
+ t
2564
+ )}类型`
2565
+ ), !1) : (se(`NullError: ${n}期望返回 {} 或者 [] 类型,目前无返回值`), !1);
2566
+ }
2567
+ /**
2568
+ * 销毁定时器和队列
2569
+ */
2570
+ destroy() {
2571
+ this.timeoutID && clearTimeout(this.timeoutID), this.retryTimer && clearTimeout(this.retryTimer), this.events = [], this.isServerAvailable = !0;
2572
+ }
2573
+ }
2574
+ let T;
2575
+ function gr() {
2576
+ C.sendData = new vr(), T = C.sendData;
2577
+ }
2578
+ class br {
2579
+ base;
2580
+ pageId;
2581
+ sdkUserUuid = "";
2582
+ device;
2583
+ // 基础信息是否初始化成功
2584
+ _initSuccess = !1;
2585
+ constructor() {
2586
+ this.pageId = We(), this.initSdkUserUuid().then(() => {
2587
+ this.initDevice(), this.initBase();
2588
+ }).finally(() => {
2589
+ this._initSuccess = !0, T.emit([]);
2590
+ });
2591
+ }
2592
+ initDevice() {
2593
+ const { screen: t } = Nt(), { clientWidth: n, clientHeight: r } = document.documentElement, { width: o, height: a, colorDepth: s, pixelDepth: c } = t;
2594
+ let i = tt(dt);
2595
+ i || (i = `t_${We()}`, document.cookie = `${dt}=${i};path=/;`), this.device = {
2596
+ clientHeight: r,
2597
+ // 网页可见区高度
2598
+ clientWidth: n,
2599
+ // 网页可见区宽度
2600
+ colorDepth: s,
2601
+ // 显示屏幕调色板的比特深度
2602
+ pixelDepth: c,
2603
+ // 显示屏幕的颜色分辨率
2604
+ deviceId: i,
2605
+ // id
2606
+ screenWidth: o,
2607
+ // 显示屏幕的宽度
2608
+ screenHeight: a,
2609
+ // 显示屏幕的高度
2610
+ vendor: navigator.vendor,
2611
+ // 浏览器名称
2612
+ platform: navigator.platform
2613
+ // 浏览器平台的环境,不是电脑系统的x64这样的(浏览器平台的环境可能是x32)
2614
+ };
2615
+ }
2616
+ /**
2617
+ * 初始化 base 数据
2618
+ */
2619
+ initBase() {
2620
+ const t = ur();
2621
+ let n = "";
2622
+ this.base = Pt(() => ({
2623
+ ...this.device,
2624
+ userUuid: d.value.userUuid,
2625
+ sdkUserUuid: this.sdkUserUuid,
2626
+ ext: d.value.ext,
2627
+ appName: d.value.appName,
2628
+ appCode: d.value.appCode,
2629
+ pageId: this.pageId,
2630
+ sessionId: t,
2631
+ sdkVersion: An,
2632
+ ip: n
2633
+ })), !je && Wt().then((r) => {
2634
+ this.base.value.ip = r[0], n = r[0];
2635
+ });
2636
+ }
2637
+ /**
2638
+ * 初始化sdk中给用户的唯一标识
2639
+ */
2640
+ initSdkUserUuid() {
2641
+ return je ? Promise.resolve().then(() => {
2642
+ this.sdkUserUuid = "unit-test-id", d.value.sdkUserUuid = "unit-test-id";
2643
+ }) : cr({}).then((t) => t.get()).then((t) => {
2644
+ const n = t.visitorId;
2645
+ this.sdkUserUuid = n, d.value.sdkUserUuid = n;
2646
+ });
2647
+ }
2648
+ }
2649
+ let le;
2650
+ function yr() {
2651
+ le = new br(), C.baseInfo = le;
2652
+ }
2653
+ class Er {
2654
+ onLine = !0;
2655
+ constructor() {
2656
+ this.init();
2657
+ }
2658
+ init() {
2659
+ b.addEvent({
2660
+ type: f.OFFLINE,
2661
+ callback: (t) => {
2662
+ t.type === "offline" && (ae("网络断开"), this.onLine = !1);
2663
+ }
2664
+ }), b.addEvent({
2665
+ type: f.ONLINE,
2666
+ callback: (t) => {
2667
+ t.type === "online" && (ae("网络连接"), this.onLine = !0);
2668
+ }
2669
+ });
2670
+ }
2671
+ }
2672
+ function Sr() {
2673
+ C.lineStatus = new Er(), C.lineStatus;
2674
+ }
2675
+ const Lr = 5e3, wr = 3;
2676
+ let $;
2677
+ class Rt {
2678
+ eventList = [
2679
+ { scope: `${R()}-`, eventList: [] }
2680
+ ];
2681
+ closeCallback;
2682
+ constructor() {
2683
+ this.init();
2684
+ }
2685
+ init() {
2686
+ this.closeCallback = Qt({
2687
+ emit: (t, n) => {
2688
+ const r = this.eventList[this.eventList.length - 1];
2689
+ r.eventList.push(t), n && (this.eventList.length > 0 && (this.eventList[this.eventList.length - 1].scope = r.scope + R()), this.eventList.length > wr && this.eventList.shift(), this.eventList.push({ scope: `${R()}-`, eventList: [] }));
2690
+ },
2691
+ recordCanvas: !0,
2692
+ checkoutEveryNms: Lr
2693
+ // 每5s重新制作快照
2694
+ });
2695
+ }
2696
+ close() {
2697
+ this.closeCallback?.(), this.closeCallback = void 0;
2698
+ }
2699
+ }
2700
+ function Rr() {
2701
+ $t(d, (e, t) => {
2702
+ e.recordScreen !== t.recordScreen && (e.recordScreen ? $ = new Rt() : ($?.close(), $ = void 0));
2703
+ }), $ = d.value.recordScreen ? new Rt() : void 0;
2704
+ }
2705
+ function Ar() {
2706
+ return $?.eventList ?? [];
2707
+ }
2708
+ function Ir(e) {
2709
+ if (!e) return e;
2710
+ const t = typeof e != "string" && typeof e != "number" ? JSON.stringify(e) : e, n = Ae.encode(t), r = xt.gzip(n), o = Array.from(r);
2711
+ let a = "";
2712
+ return o.forEach((s) => {
2713
+ a += String.fromCharCode(s);
2714
+ }), Ae.btoa(a);
2715
+ }
2716
+ function kr(e) {
2717
+ const n = Ae.atob(e).split("").map(function(l) {
2718
+ return l.charCodeAt(0);
2719
+ }), r = new Uint8Array(n), o = xt.ungzip(r);
2720
+ let a = "";
2721
+ const s = 8 * 1024;
2722
+ let c;
2723
+ for (c = 0; c < o.length / s; c++)
2724
+ a += String.fromCharCode.apply(
2725
+ null,
2726
+ o.slice(c * s, (c + 1) * s)
2727
+ );
2728
+ a += String.fromCharCode.apply(null, o.slice(c * s));
2729
+ const i = Ae.decode(a);
2730
+ let u = "";
2731
+ try {
2732
+ u = JSON.parse(i);
2733
+ } catch (l) {
2734
+ /Unexpected token o in JSON at position 0/.test(l) && (u = i);
2735
+ }
2736
+ return u;
2737
+ }
2738
+ function Tr() {
2739
+ $?.close(), $ = void 0;
2740
+ }
2741
+ const Cr = 2e3, Or = 2e4, Le = 5, De = ["errMessage", "eventId", "requestUrl"];
2742
+ class Pr {
2743
+ cacheErrorA;
2744
+ cacheErrorB;
2745
+ throttleProxyAddCacheErrorA;
2746
+ throttleProxyAddCacheErrorB;
2747
+ constructor() {
2748
+ this.cacheErrorA = [], this.cacheErrorB = [], this.throttleProxyAddCacheErrorA = ln(
2749
+ this.proxyAddCacheErrorA,
2750
+ Cr
2751
+ ), this.throttleProxyAddCacheErrorB = Ft(
2752
+ this.proxyAddCacheErrorB,
2753
+ Or
2754
+ );
2755
+ }
2756
+ proxyAddCacheErrorA() {
2757
+ let t = this.cacheErrorA.length;
2758
+ if (!t) return;
2759
+ const n = Oe(this.cacheErrorA, ...De), r = n.filter((a) => a.length < Le), o = n.filter((a) => a.length >= Le);
2760
+ if (r.length && T.emit(r.flat(1 / 0)), o.length) {
2761
+ const a = [];
2762
+ o.forEach((s) => {
2763
+ const c = s[0];
2764
+ c.batchError = !0, c.batchErrorLength = s.length, c.batchErrorLastHappenTime = s[s.length - 1].triggerTime, a.push(c);
2765
+ }), this.cacheErrorB.push(...a), this.throttleProxyAddCacheErrorB();
2766
+ }
2767
+ for (; t--; )
2768
+ this.cacheErrorA.shift();
2769
+ }
2770
+ proxyAddCacheErrorB() {
2771
+ let t = this.cacheErrorB.length;
2772
+ if (!t) return;
2773
+ const n = Oe(this.cacheErrorB, ...De);
2774
+ for (; t--; )
2775
+ this.cacheErrorB.shift();
2776
+ const r = [];
2777
+ n.forEach((o) => {
2778
+ const a = o[0];
2779
+ o.length > 1 && (a.batchErrorLength = o.reduce(
2780
+ (s, c) => s += c.batchErrorLength,
2781
+ 0
2782
+ ), a.batchErrorLastHappenTime = o[o.length - 1].triggerTime), r.push(a);
2783
+ }), T.emit(r);
2784
+ }
2785
+ /**
2786
+ * 获取所有的错误
2787
+ * 用户突然关闭页面时调用此方法集成错误
2788
+ */
2789
+ sendAllCacheError() {
2790
+ const t = this.cacheErrorA.concat(this.cacheErrorB), n = Oe(t, ...De), r = n.filter((a) => a.length < Le), o = n.filter((a) => a.length >= Le);
2791
+ if (r.length && T.emit(r.flat(1 / 0), !0), o.length) {
2792
+ const a = [];
2793
+ o.forEach((s) => {
2794
+ const c = s[0];
2795
+ c.batchError = !0, c.batchErrorLength = s.length, c.batchErrorLastHappenTime = s[s.length - 1].triggerTime, a.push(c);
2796
+ }), T.emit(a, !0);
2797
+ }
2798
+ }
2799
+ pushCacheErrorA(t) {
2800
+ this.cacheErrorA.push(t), this.throttleProxyAddCacheErrorA(), this.cacheErrorA.length >= 50 && (this.proxyAddCacheErrorA(), this.proxyAddCacheErrorB());
2801
+ }
2802
+ }
2803
+ let ot;
2804
+ function xr() {
2805
+ ot = new Pr();
2806
+ }
2807
+ function Nr(e) {
2808
+ return e.map((n) => {
2809
+ if (n === null) return "null";
2810
+ if (n === void 0) return "undefined";
2811
+ if (typeof n == "string") return n;
2812
+ if (typeof n == "number" || typeof n == "boolean") return String(n);
2813
+ if (typeof n == "function")
2814
+ return `[Function: ${n.name || "anonymous"}]`;
2815
+ if (n instanceof Error)
2816
+ return `${n.name}: ${n.message}${n.stack ? `
2817
+ ` + n.stack : ""}`;
2818
+ if (typeof n == "object")
2819
+ try {
2820
+ return JSON.stringify(n, null, 2);
2821
+ } catch {
2822
+ return n.toString();
2823
+ }
2824
+ return String(n);
2825
+ }).join(" | ");
2826
+ }
2827
+ function At(e) {
2828
+ const { stack: t = "", message: n = "" } = e, r = { eventId: O.CODE, errMessage: n, errStack: t };
2829
+ if (t) {
2830
+ const o = /^\s*at\s*([^(]+)\s*\((.+?):(\d+):(\d+)\)$/, a = /^\s*([^@]*)@(.+?):(\d+):(\d+)$/, s = t.replace(
2831
+ new RegExp(`^[\\w\\s:]*${n}
2832
+ `),
2833
+ ""
2834
+ ), i = Mt(
2835
+ gn(s.split(`
2836
+ `), (u) => u),
2837
+ (u) => {
2838
+ const l = u.match(o);
2839
+ if (l)
2840
+ return {
2841
+ triggerPageUrl: l[2],
2842
+ line: l[3],
2843
+ // 错误发生位置的行数
2844
+ col: l[4]
2845
+ // 错误发生位置的列数
2846
+ };
2847
+ const h = u.match(a);
2848
+ return h ? {
2849
+ triggerPageUrl: h[2],
2850
+ line: h[3],
2851
+ col: h[4]
2852
+ } : {};
2853
+ }
2854
+ )[0] || {};
2855
+ return { ...r, ...i };
2856
+ }
2857
+ return r;
2858
+ }
2859
+ function Qe(e) {
2860
+ if (e instanceof Error) {
2861
+ const { message: t, stack: n, lineNumber: r, fileName: o, columnNumber: a } = e;
2862
+ return o ? {
2863
+ errMessage: t,
2864
+ errStack: n,
2865
+ eventId: O.CODE,
2866
+ line: r,
2867
+ // 不稳定属性 - 在某些浏览器可能是undefined,被废弃了
2868
+ col: a,
2869
+ // 不稳定属性 - 非标准,有些浏览器可能不支持
2870
+ triggerPageUrl: o
2871
+ // 不稳定属性 - 非标准,有些浏览器可能不支持
2872
+ } : At(e);
2873
+ }
2874
+ return e.message ? At(e) : typeof e == "string" ? { eventId: O.REJECT, errMessage: e } : Te(e) ? { eventId: O.CONSOLEERROR, errMessage: Nr(e) } : {};
2875
+ }
2876
+ function Fr(e) {
2877
+ return e && e.reason !== void 0;
2878
+ }
2879
+ function It(e) {
2880
+ if (Fr(e))
2881
+ return { eventId: O.CODE, ...Qe(e.reason) };
2882
+ const { target: t } = e;
2883
+ if (t instanceof HTMLElement && t.nodeType === 1) {
2884
+ const n = {
2885
+ initiatorType: t.nodeName.toLowerCase(),
2886
+ eventId: O.RESOURCE,
2887
+ requestUrl: ""
2888
+ };
2889
+ switch (t.nodeName.toLowerCase()) {
2890
+ case "link":
2891
+ n.requestUrl = t.href;
2892
+ break;
2893
+ default:
2894
+ n.requestUrl = t.currentSrc || t.src;
2895
+ }
2896
+ return n;
2897
+ }
2898
+ if (e.error) {
2899
+ const n = e.error;
2900
+ return n.fileName = n.filename || e.filename, n.columnNumber = n.colno || e.colno, n.lineNumber = n.lineno || e.lineno, { eventId: O.CODE, ...Qe(n) };
2901
+ }
2902
+ return {
2903
+ eventId: O.CODE,
2904
+ line: p.event.errorLine,
2905
+ col: p.event.errorCharacter,
2906
+ errMessage: p.event.errorMessage,
2907
+ triggerPageUrl: p.event.errorUrl
2908
+ };
2909
+ }
2910
+ function Xe(e) {
2911
+ if (!d.value.ignoreErrors.length) return !1;
2912
+ let t = e.errMessage || e.message;
2913
+ return t ? (t = String(t), d.value.ignoreErrors.some((n) => et(n) ? n.test(t) ? (ae(`ignoreErrors拦截成功 - 截条件:${n} 错误信息:${t}`), !0) : !1 : t === n ? (ae(`ignoreErrors拦截成功 - 截条件:${n} 错误信息:${t}`), !0) : !1)) : !1;
2914
+ }
2915
+ function Mr() {
2916
+ return JSON.parse(
2917
+ JSON.stringify(Ar())
2918
+ ).slice(-2).map((t) => t.eventList).flat();
2919
+ }
2920
+ function Re(e, t = !1) {
2921
+ const n = {
2922
+ ...e,
2923
+ eventType: V.ERROR,
2924
+ recordscreen: d.value.recordScreen ? Ir(Mr()) : null,
2925
+ triggerPageUrl: F(),
2926
+ triggerTime: R()
2927
+ };
2928
+ d.value.scopeError ? ot.pushCacheErrorA(n) : T.emit(n, t);
2929
+ }
2930
+ function Vr() {
2931
+ d.value.error.core && (d.value.scopeError && (xr(), b.addEvent({
2932
+ type: f.BEFOREUNLOAD,
2933
+ callback: () => {
2934
+ ot.sendAllCacheError();
2935
+ }
2936
+ })), b.addEvent({
2937
+ type: f.ERROR,
2938
+ callback: (e) => {
2939
+ const t = It(e);
2940
+ Xe(t) || Re(t);
2941
+ }
2942
+ }), b.addEvent({
2943
+ type: f.UNHANDLEDREJECTION,
2944
+ callback: (e) => {
2945
+ const t = It(e);
2946
+ Xe(t) || Re(t);
2947
+ }
2948
+ }), b.addEvent({
2949
+ type: f.CONSOLEERROR,
2950
+ callback: (e) => {
2951
+ const t = Qe(e);
2952
+ Xe(t) || Re({ eventId: O.CODE, ...t });
2953
+ }
2954
+ }));
2955
+ }
2956
+ function it(e = {}, t = !1) {
2957
+ Re(e, t);
2958
+ }
2959
+ function Hr() {
2960
+ b.removeEvents([
2961
+ f.ERROR,
2962
+ f.UNHANDLEDREJECTION,
2963
+ f.CONSOLEERROR
2964
+ ]);
2965
+ }
2966
+ function Ue(e, t) {
2967
+ return e.find((n) => n.hasAttribute && n.hasAttribute(t));
2968
+ }
2969
+ function kt(e) {
2970
+ if (e.length > 0) {
2971
+ const t = ["em", "b", "strong", "span", "img", "i", "code"];
2972
+ return e.filter(
2973
+ ({ tagName: r }) => t.indexOf(r.toLowerCase()) >= 0
2974
+ ).length === e.length;
2975
+ }
2976
+ return !0;
2977
+ }
2978
+ function Bt(e, t = "") {
2979
+ if (!e) return t;
2980
+ const n = e.parentElement, { id: r } = e, o = e.tagName.toLowerCase(), a = t ? `>${t}` : "";
2981
+ return !n || n === document.documentElement || n === document.body ? `${o}${a}` : r ? `#${r}${a}` : Bt(n, `${o}${a}`);
2982
+ }
2983
+ class Dr {
2984
+ eventId = "";
2985
+ // 事件ID
2986
+ eventType = "";
2987
+ // 事件类型
2988
+ title = "";
2989
+ // 事件名
2990
+ triggerPageUrl = "";
2991
+ // 当前页面URL
2992
+ x = -1;
2993
+ // 被点击元素与屏幕左边距离
2994
+ y = -1;
2995
+ // 被点击元素与屏幕上边距离
2996
+ params = {};
2997
+ // 事件参数
2998
+ elementPath = "";
2999
+ // 被点击元素的层级
3000
+ triggerTime = -1;
3001
+ // 事件发生时间
3002
+ constructor(t = {}) {
3003
+ Object.keys(t).forEach((n) => {
3004
+ fe(n, t) && (this[n] = t[n] || null);
3005
+ });
3006
+ }
3007
+ }
3008
+ function Xr() {
3009
+ b.addEvent({
3010
+ type: f.CLICK,
3011
+ callback: (e) => {
3012
+ const t = new Dr({
3013
+ eventType: V.CLICK
3014
+ }), n = e.composedPath() ? e.composedPath() : e.target ? Ur(e.target) : [], r = n.find(
3015
+ (i) => i.hasAttribute && (i.hasAttribute("data-warden-container") || i.hasAttribute("data-warden-event-id") || i.hasAttribute("data-warden-title"))
3016
+ );
3017
+ if (!r) return;
3018
+ const { scrollTop: o, scrollLeft: a } = document.documentElement, { top: s, left: c } = e.target.getBoundingClientRect();
3019
+ t.x = c + a, t.y = s + o, t.triggerTime = R(), t.triggerPageUrl = F(), t.title = jr(r), t.eventId = Zr(n), t.params = Yr(n), t.elementPath = Bt(r).slice(-128), T.emit(t);
3020
+ }
3021
+ });
3022
+ }
3023
+ function Ur(e, t = { includeSelf: !0, order: "asc" }) {
3024
+ if (!e) return [];
3025
+ const { includeSelf: n, order: r } = t;
3026
+ let o = n ? e : e.parentElement, a = [];
3027
+ for (; o; )
3028
+ a = r === "asc" ? a.concat(o) : [o].concat(a), o = o.parentElement;
3029
+ return a;
3030
+ }
3031
+ function jr(e) {
3032
+ const t = Tt(e);
3033
+ if (t) return t;
3034
+ let n = e.parentElement;
3035
+ for (; n && n !== document.body && !n.hasAttribute("data-warden-container"); )
3036
+ n = n.parentElement;
3037
+ const r = Tt(n);
3038
+ if (r) return r;
3039
+ const { tagName: o } = e;
3040
+ return !e.hasChildNodes() || o.toLowerCase() === "svg" ? Wr(e) : Br(e);
3041
+ }
3042
+ function Tt(e) {
3043
+ return e ? e.hasAttribute("data-warden-title") ? e.getAttribute("data-warden-title") : e.title : "";
3044
+ }
3045
+ function Wr(e) {
3046
+ const { tagName: t, textContent: n } = e;
3047
+ if (t === "IMG") return e.getAttribute("alt") || null;
3048
+ if (t === "svg") {
3049
+ const r = [...Array(e.children)].find((o) => o.tagName === "use");
3050
+ if (r) return r.getAttribute("xlink:href") || null;
3051
+ }
3052
+ return n;
3053
+ }
3054
+ function Br(e) {
3055
+ const { tagName: t, textContent: n } = e;
3056
+ if (t === "A")
3057
+ return kt([...Array.from(e.children)]) ? n : e.getAttribute("href") || null;
3058
+ if (t === "BUTTON") {
3059
+ const o = e.getAttribute("name"), a = kt([...Array.from(e.children)]);
3060
+ return o || a ? n : e.getAttribute("href") || null;
3061
+ }
3062
+ const { length: r } = [...Array.from(e.children)].filter(
3063
+ () => e.hasChildNodes()
3064
+ );
3065
+ return r > 0 ? null : n;
3066
+ }
3067
+ function Zr(e = []) {
3068
+ const t = Ue(e, "data-warden-event-id");
3069
+ if (t) return t.getAttribute("data-warden-event-id");
3070
+ const n = Ue(e, "title");
3071
+ if (n) return n.getAttribute("title");
3072
+ const r = Ue(e, "data-warden-container");
3073
+ if (r) {
3074
+ if (r.getAttribute("data-warden-event-id"))
3075
+ return r.getAttribute("data-warden-event-id");
3076
+ if (r.getAttribute("title"))
3077
+ return r.getAttribute("title");
3078
+ const o = r.getAttribute("data-warden-container");
3079
+ if (typeof o == "string" && o) return o;
3080
+ }
3081
+ return e[0].tagName.toLowerCase();
3082
+ }
3083
+ function Yr(e = []) {
3084
+ const t = /^data-warden-/;
3085
+ let n, r = -1;
3086
+ for (let i = 0; i < e.length; i++) {
3087
+ const u = e[i];
3088
+ if (n = (u && u.attributes && Array.from(u.attributes) || []).find(
3089
+ (h) => h.nodeName.match(t) ? h.nodeName.match(t) : h.nodeName.indexOf("data-warden-container") !== -1
3090
+ ), n) {
3091
+ r = i;
3092
+ break;
3093
+ }
3094
+ }
3095
+ if (r < 0) return {};
3096
+ const o = e[r], a = Array.from(o.attributes) || [], s = {}, c = ["container", "title", "event-id"];
3097
+ return a.forEach((i) => {
3098
+ if (i.nodeName.indexOf("data-warden") < 0) return;
3099
+ const u = i.nodeName.replace(t, "");
3100
+ c.includes(u) || (s[u] = i.nodeValue);
3101
+ }), s;
3102
+ }
3103
+ function Gr() {
3104
+ d.value.event.core && Xr();
3105
+ }
3106
+ function _r(e = {}, t = !1) {
3107
+ T.emit(
3108
+ {
3109
+ ...e,
3110
+ eventType: V.CUSTOM,
3111
+ triggerTime: R(),
3112
+ triggerPageUrl: F()
3113
+ },
3114
+ t
3115
+ );
3116
+ }
3117
+ function zr() {
3118
+ b.removeEvents([f.CLICK, f.LOAD]);
3119
+ }
3120
+ const Q = {
3121
+ performance: !!p.performance,
3122
+ getEntriesByType: !!(p.performance && p.performance.getEntriesByType),
3123
+ PerformanceObserver: "PerformanceObserver" in p,
3124
+ MutationObserver: "MutationObserver" in p,
3125
+ PerformanceNavigationTiming: "PerformanceNavigationTiming" in p
3126
+ }, Jr = {
3127
+ initiatorType: "",
3128
+ transferSize: 0,
3129
+ encodedBodySize: 0,
3130
+ decodedBodySize: 0,
3131
+ duration: 0,
3132
+ redirectStart: 0,
3133
+ redirectEnd: 0,
3134
+ startTime: 0,
3135
+ fetchStart: 0,
3136
+ domainLookupStart: 0,
3137
+ domainLookupEnd: 0,
3138
+ connectStart: 0,
3139
+ connectEnd: 0,
3140
+ requestStart: 0,
3141
+ responseStart: 0,
3142
+ responseEnd: 0,
3143
+ workerStart: 0
3144
+ };
3145
+ function Ct(e) {
3146
+ const t = ["img", "script", "link", "audio", "video", "css"], n = e.getEntriesByType(
3147
+ "resource"
3148
+ ), r = [];
3149
+ return n.forEach((o) => {
3150
+ const { initiatorType: a = "" } = o;
3151
+ if (t.indexOf(a.toLowerCase()) < 0) return;
3152
+ if (we.length) {
3153
+ const c = we.findIndex(
3154
+ (i) => i.src === o.name
3155
+ );
3156
+ if (c !== -1) {
3157
+ we.splice(c, 1);
3158
+ return;
3159
+ }
3160
+ }
3161
+ const s = {};
3162
+ Object.keys(Jr).forEach((c) => {
3163
+ fe(c, o) && (s[c] = o[c]);
3164
+ }), r.push(
3165
+ ce({
3166
+ ...s,
3167
+ eventType: V.PERFORMANCE,
3168
+ eventId: O.RESOURCE,
3169
+ requestUrl: o.name,
3170
+ triggerTime: R(),
3171
+ triggerPageUrl: F()
3172
+ })
3173
+ );
3174
+ }), r.length && T.emit(r), r;
3175
+ }
3176
+ let pe = null, ve = null;
3177
+ function qr() {
3178
+ const e = ["img", "script", "link"];
3179
+ pe = new MutationObserver((t) => {
3180
+ for (let n = 0; n < t.length; n += 1) {
3181
+ const r = R(), { addedNodes: o = [] } = t[n];
3182
+ o.forEach((a) => {
3183
+ const { nodeName: s } = a;
3184
+ e.indexOf(s.toLowerCase()) !== -1 && (D(a, f.LOAD, function() {
3185
+ T.emit(
3186
+ ce({
3187
+ eventType: V.PERFORMANCE,
3188
+ eventId: O.RESOURCE,
3189
+ requestUrl: a.src || a.href,
3190
+ duration: R() - r,
3191
+ triggerTime: R(),
3192
+ triggerPageUrl: F()
3193
+ })
3194
+ );
3195
+ }), D(a, f.ERROR, function() {
3196
+ T.emit(
3197
+ ce({
3198
+ eventType: V.PERFORMANCE,
3199
+ eventId: O.RESOURCE,
3200
+ requestUrl: a.src || a.href,
3201
+ responseStatus: "error",
3202
+ duration: R() - r,
3203
+ triggerTime: R(),
3204
+ triggerPageUrl: F()
3205
+ })
3206
+ );
3207
+ }));
3208
+ });
3209
+ }
3210
+ }), pe.observe(p.document, {
3211
+ subtree: !0,
3212
+ // 目标以及目标的后代改变都会观察
3213
+ childList: !0
3214
+ // 表示观察目标子节点的变化,比如添加或者删除目标子节点,不包括修改子节点以及子节点后代的变化
3215
+ // attributes: true, // 观察属性变动
3216
+ // attributeFilter: ['src', 'href'] // 要观察的属性
3217
+ });
3218
+ }
3219
+ function $r() {
3220
+ const e = (t) => {
3221
+ const n = { ...t, triggerPageUrl: F() };
3222
+ C.firstScreen ? C.firstScreen.push({ ...n }) : C.firstScreen = [{ ...n }], T.emit(
3223
+ ce({
3224
+ ...n,
3225
+ eventType: V.PERFORMANCE,
3226
+ eventId: O.PAGE
3227
+ })
3228
+ );
3229
+ };
3230
+ new PerformanceObserver((t, n) => {
3231
+ const r = t.getEntriesByName("first-contentful-paint")[0];
3232
+ r && (n.disconnect(), e({ fcp: r.startTime }));
3233
+ }).observe({ type: "paint", buffered: !0 }), new PerformanceObserver((t, n) => {
3234
+ const r = t.getEntriesByType("largest-contentful-paint").at(-1);
3235
+ r && (n.disconnect(), e({ lcp: r.startTime }));
3236
+ }).observe({ type: "largest-contentful-paint", buffered: !0 });
3237
+ }
3238
+ function Qr() {
3239
+ const e = {}, { performance: t } = p;
3240
+ let n = t.timing;
3241
+ if (e.fmp = 0, Q.getEntriesByType) {
3242
+ const o = t.getEntriesByType("paint");
3243
+ if (o.length && (e.fmp = o[o.length - 1].startTime), Q.PerformanceNavigationTiming) {
3244
+ const a = t.getEntriesByType("navigation")[0];
3245
+ a && (n = a);
3246
+ }
3247
+ }
3248
+ e.fmp && Q.PerformanceNavigationTiming && (e.fmp -= n.fetchStart), e.whiteScreenTime = n.responseEnd - n.fetchStart, e.tti = n.domInteractive - n.fetchStart, e.ready = n.domContentLoadedEventEnd - n.fetchStart, e.loadTime = n.loadEventStart - n.fetchStart, e.firstByte = n.responseStart - n.domainLookupStart, e.dns = n.domainLookupEnd - n.domainLookupStart, e.dnsCache = n.domainLookupStart - n.fetchStart, e.tcp = n.connectEnd - n.connectStart, e.ttfb = n.responseStart - n.requestStart, e.trans = n.responseEnd - n.responseStart, e.dom = n.domInteractive - n.responseEnd, e.res = n.loadEventStart - n.domContentLoadedEventEnd, e.ssllink = n.connectEnd - n.secureConnectionStart, e.redirect = n.redirectEnd - n.redirectStart, e.unloadTime = n.unloadEventEnd - n.unloadEventStart;
3249
+ const r = { ...e, triggerPageUrl: F() };
3250
+ C.firstScreen ? C.firstScreen.push({ ...r }) : C.firstScreen = [{ ...r }], T.emit(
3251
+ ce({
3252
+ ...r,
3253
+ eventType: V.PERFORMANCE,
3254
+ eventId: O.PAGE
3255
+ })
3256
+ );
3257
+ }
3258
+ function Ot() {
3259
+ Q.performance && d.value.performance.firstResource && (Qr(), $r()), Q.performance && d.value.performance.core && (Ct(p.performance), Q.PerformanceObserver ? (ve = new PerformanceObserver(Ct), ve.observe({ entryTypes: ["resource"] })) : Q.MutationObserver && qr());
3260
+ }
3261
+ function Kr() {
3262
+ !d.value.performance.firstResource && !d.value.performance.core || (document.readyState === "complete" ? Ot() : b.addEvent({
3263
+ type: f.LOAD,
3264
+ callback: () => {
3265
+ Ot();
3266
+ }
3267
+ }));
3268
+ }
3269
+ function at(e = {}, t = !1) {
3270
+ const n = {
3271
+ ...e,
3272
+ triggerTime: R(),
3273
+ triggerPageUrl: F(),
3274
+ eventType: V.PERFORMANCE
3275
+ };
3276
+ T.emit(ce(n), t);
3277
+ }
3278
+ function eo() {
3279
+ pe && (pe.disconnect(), pe = null), ve && (ve.disconnect(), ve = null);
3280
+ }
3281
+ function to() {
3282
+ b.addEvent({
3283
+ type: f.FETCH,
3284
+ callback: async (e, t = {}, n, r, o = {}) => {
3285
+ const { method: a = "GET", body: s = {} } = t, { url: c, status: i, statusText: u } = n, l = String(a).toLocaleLowerCase();
3286
+ Zt(c) || (i === 200 || i === 304 ? d.value.performance.server && at({
3287
+ eventId: O.SERVER,
3288
+ requestUrl: c,
3289
+ triggerTime: r,
3290
+ duration: R() - r,
3291
+ responseStatus: i,
3292
+ requestMethod: l,
3293
+ requestType: "fetch",
3294
+ ...o,
3295
+ params: a.toUpperCase() === "POST" ? s : Be(c)
3296
+ }) : d.value.error.server && it({
3297
+ eventId: O.SERVER,
3298
+ triggerTime: r,
3299
+ duration: R() - r,
3300
+ errMessage: u,
3301
+ requestUrl: fn(c),
3302
+ responseStatus: i,
3303
+ requestMethod: l,
3304
+ requestType: "fetch",
3305
+ ...o,
3306
+ params: a.toUpperCase() === "POST" ? s : Be(c)
3307
+ }));
3308
+ }
3309
+ });
3310
+ }
3311
+ class no {
3312
+ requestUrl = "";
3313
+ // 请求地址
3314
+ requestMethod = "";
3315
+ // 请求类型 GET POST
3316
+ requestParams = {};
3317
+ // get请求的参数
3318
+ triggerTime = -1;
3319
+ // 请求发生时间
3320
+ constructor(t = {}) {
3321
+ Object.keys(t).forEach((n) => {
3322
+ fe(n, t) && (this[n] = t[n] || null);
3323
+ });
3324
+ }
3325
+ }
3326
+ function ro() {
3327
+ const e = new no();
3328
+ b.addEvent({
3329
+ type: f.XHROPEN,
3330
+ callback: (t, n) => {
3331
+ e.requestMethod = String(t).toLocaleLowerCase(), e.requestUrl = n, e.requestParams = Be(n);
3332
+ }
3333
+ }), b.addEvent({
3334
+ type: f.XHRSEND,
3335
+ callback: (t, n) => {
3336
+ D(t, f.READYSTATECHANGE, function() {
3337
+ const { readyState: r, status: o, responseURL: a, statusText: s } = t, c = t.responseType === "" || t.responseType === "text" ? t.responseText : "";
3338
+ if (r === 4) {
3339
+ const i = a || e.requestUrl;
3340
+ if (Zt(i)) return;
3341
+ o === 200 || o === 304 ? d.value.performance.server && at({
3342
+ eventId: O.SERVER,
3343
+ requestUrl: i,
3344
+ requestMethod: e.requestMethod,
3345
+ requestType: "xhr",
3346
+ responseStatus: o,
3347
+ duration: R() - e.triggerTime,
3348
+ params: e.requestMethod === "post" ? n : e.requestParams
3349
+ }) : d.value.error.server && it({
3350
+ eventId: O.SERVER,
3351
+ errMessage: s || c,
3352
+ requestUrl: i,
3353
+ requestMethod: e.requestMethod,
3354
+ requestType: "xhr",
3355
+ responseStatus: o,
3356
+ params: e.requestMethod === "post" ? n : e.requestParams
3357
+ });
3358
+ }
3359
+ }), e.triggerTime = R();
3360
+ }
3361
+ });
3362
+ }
3363
+ function Zt(e) {
3364
+ return !d.value.ignoreRequest.length || !e ? !1 : d.value.ignoreRequest.some((t) => et(t) ? !!t.test(e) : e === t);
3365
+ }
3366
+ function oo() {
3367
+ !d.value.performance.server && !d.value.error.server || (ro(), to());
3368
+ }
3369
+ function io() {
3370
+ b.removeEvents([
3371
+ f.FETCH,
3372
+ f.XHROPEN,
3373
+ f.XHRSEND
3374
+ ]);
3375
+ }
3376
+ let K = F();
3377
+ function ao() {
3378
+ if (!d.value.pv.core) return;
3379
+ let e = !1, t = !1;
3380
+ he({ referer: document.referrer }), b.addEvent({
3381
+ type: f.HISTORYPUSHSTATE,
3382
+ callback: () => {
3383
+ t || (e = !1, he({ action: "navigation" }));
3384
+ }
3385
+ }), b.addEvent({
3386
+ type: f.HISTORYREPLACESTATE,
3387
+ callback: () => {
3388
+ t = !0, e = !1, he({ action: "navigation" }), setTimeout(() => {
3389
+ t = !1;
3390
+ }, 100);
3391
+ }
3392
+ }), b.addEvent({
3393
+ type: f.HASHCHANGE,
3394
+ callback: () => {
3395
+ t || (e || he(), e = !1);
3396
+ }
3397
+ }), b.addEvent({
3398
+ type: f.POPSTATE,
3399
+ callback: () => {
3400
+ if (!t) {
3401
+ if (p.location.hash !== "") {
3402
+ const n = K.indexOf("#") > 0 ? K.slice(0, K.indexOf("#")) : K;
3403
+ if (p.location.href.slice(0, p.location.href.indexOf("#")) === n)
3404
+ return;
3405
+ }
3406
+ e = !0, he();
3407
+ }
3408
+ }
3409
+ }), b.addEvent({
3410
+ type: f.BEFOREUNLOAD,
3411
+ callback: () => {
3412
+ const n = R() - Ke;
3413
+ Object.values(ge).length > 0 && n > 100 && T.emit({ ...ge, durationTime: n }, !0);
3414
+ }
3415
+ });
3416
+ }
3417
+ let Ke = R(), ge = {};
3418
+ function he(e = {}) {
3419
+ const { referer: t = K, action: n, params: r, title: o } = e;
3420
+ let a = n;
3421
+ a || (a = In[performance.navigation.type] || ""), setTimeout(
3422
+ () => {
3423
+ K = F();
3424
+ const s = {
3425
+ eventType: V.PV,
3426
+ eventId: le.pageId,
3427
+ triggerPageUrl: F(),
3428
+ referer: t,
3429
+ params: r,
3430
+ title: o || document.title,
3431
+ action: a,
3432
+ triggerTime: R()
3433
+ };
3434
+ T.emit(s);
3435
+ const c = R() - Ke;
3436
+ Ke = R(), Object.values(ge).length > 0 && c > 100 && T.emit({ ...ge, durationTime: c }), ge = {
3437
+ ...s,
3438
+ eventType: V.PVDURATION
3439
+ };
3440
+ },
3441
+ o ? 0 : 17
3442
+ );
3443
+ }
3444
+ function so(e = {}, t = !1) {
3445
+ T.emit(
3446
+ {
3447
+ referer: K,
3448
+ title: document.title,
3449
+ ...e,
3450
+ eventType: V.PV,
3451
+ eventId: le.pageId,
3452
+ triggerPageUrl: F(),
3453
+ triggerTime: R()
3454
+ },
3455
+ t
3456
+ );
3457
+ }
3458
+ function co() {
3459
+ b.removeEvents([
3460
+ f.HISTORYPUSHSTATE,
3461
+ f.HISTORYREPLACESTATE,
3462
+ f.HASHCHANGE,
3463
+ f.POPSTATE,
3464
+ f.BEFOREUNLOAD
3465
+ ]);
3466
+ }
3467
+ class uo {
3468
+ ioMap = {};
3469
+ targetMap = [];
3470
+ options = {
3471
+ root: null,
3472
+ rootMargin: "0px",
3473
+ threshold: 0.5
3474
+ // 阀值设为0.5,当只有比例达到一半时才触发回调函数
3475
+ };
3476
+ /**
3477
+ * 针对 threshold 生成不同监听对象 (不允许同一个dom被两个监听对象监听)
3478
+ * @param threshold 阈值
3479
+ */
3480
+ initObserver(t) {
3481
+ return new IntersectionObserver(
3482
+ (n) => {
3483
+ n.forEach((r) => {
3484
+ if (r.isIntersecting) {
3485
+ const o = this.targetMap.find(
3486
+ (a) => a.target === r.target
3487
+ );
3488
+ o && (o.showTime = R());
3489
+ } else {
3490
+ const o = this.targetMap.find(
3491
+ (a) => a.target === r.target
3492
+ );
3493
+ if (o) {
3494
+ if (!o.showTime) return;
3495
+ o.showEndTime = R(), this.sendEvent(o);
3496
+ }
3497
+ }
3498
+ });
3499
+ },
3500
+ {
3501
+ ...this.options,
3502
+ threshold: t
3503
+ }
3504
+ );
3505
+ }
3506
+ /**
3507
+ * 发送事件
3508
+ */
3509
+ sendEvent(t) {
3510
+ T.emit({
3511
+ eventType: V.INTERSECTION,
3512
+ triggerPageUrl: F(),
3513
+ ...t
3514
+ });
3515
+ }
3516
+ /**
3517
+ * 开始观察目标元素
3518
+ * 分为初始加载和过程中加载
3519
+ * @param params 附带的额外参数
3520
+ */
3521
+ observe(t) {
3522
+ Pe(t).forEach((r) => {
3523
+ const o = Pe(r.target);
3524
+ Object.prototype.hasOwnProperty.call(this.ioMap, r.threshold) || (this.ioMap[r.threshold] = this.initObserver(r.threshold || 0.5)), o.forEach((a) => {
3525
+ this.targetMap.findIndex(
3526
+ (c) => c.target === a
3527
+ ) === -1 && (this.ioMap[r.threshold].observe(a), this.targetMap.push({
3528
+ target: a,
3529
+ threshold: r.threshold,
3530
+ observeTime: R(),
3531
+ // 开始监听的时间
3532
+ params: r.params
3533
+ }));
3534
+ });
3535
+ });
3536
+ }
3537
+ /**
3538
+ * 对元素停止观察
3539
+ */
3540
+ unobserve(t) {
3541
+ Pe(t).forEach((r) => {
3542
+ const o = this.targetMap.findIndex(
3543
+ (s) => s.target === r
3544
+ );
3545
+ if (o === -1) return;
3546
+ const a = this.ioMap[this.targetMap[o].threshold];
3547
+ a && (this.targetMap.splice(o, 1), a.unobserve(r));
3548
+ });
3549
+ }
3550
+ /**
3551
+ * 对所有元素停止观察
3552
+ */
3553
+ disconnect() {
3554
+ for (const t in this.ioMap)
3555
+ Object.prototype.hasOwnProperty.call(this.ioMap, t) && this.ioMap[t].disconnect();
3556
+ this.targetMap = [], this.ioMap = {};
3557
+ }
3558
+ }
3559
+ let be;
3560
+ function lo() {
3561
+ C.intersection = new uo(), be = C.intersection;
3562
+ }
3563
+ function fo() {
3564
+ be?.disconnect();
3565
+ }
3566
+ function ho(e) {
3567
+ return kr(e);
3568
+ }
3569
+ function mo(e) {
3570
+ P("beforePushEventList") && d.value.beforePushEventList.push(e);
3571
+ }
3572
+ function po(e) {
3573
+ P("beforeSendData") && d.value.beforeSendData.push(e);
3574
+ }
3575
+ function vo(e) {
3576
+ P("afterSendData") && d.value.afterSendData.push(e);
3577
+ }
3578
+ function go(e) {
3579
+ P("setUserUuid") && (d.value.userUuid = e);
3580
+ }
3581
+ function bo() {
3582
+ if (P("getUserUuid"))
3583
+ return d.value.userUuid;
3584
+ }
3585
+ function yo() {
3586
+ if (P("getSDKUserUuid"))
3587
+ return d.value.sdkUserUuid;
3588
+ }
3589
+ function Eo() {
3590
+ if (P("getBaseInfo"))
3591
+ return {
3592
+ ...C.baseInfo.base,
3593
+ userUuid: d.value.userUuid
3594
+ };
3595
+ }
3596
+ function So() {
3597
+ if (P("getFirstScreen"))
3598
+ return { ...C.firstScreen };
3599
+ }
3600
+ function Lo(e = {}, t = !1) {
3601
+ if (P("traceError"))
3602
+ return it(e, t);
3603
+ }
3604
+ function wo(e = {}, t = !1) {
3605
+ if (P("tracePerformance"))
3606
+ return at(e, t);
3607
+ }
3608
+ function Ro(e = {}, t = !1) {
3609
+ if (P("traceCustomEvent"))
3610
+ return _r(e, t);
3611
+ }
3612
+ function Ao(e = {}, t = !1) {
3613
+ if (P("tracePageView"))
3614
+ return so(e, t);
3615
+ }
3616
+ function Io() {
3617
+ return Wt().then((e) => e[0]);
3618
+ }
3619
+ function ko(e) {
3620
+ P("intersectionObserver") && be.observe(e);
3621
+ }
3622
+ function To(e) {
3623
+ P("intersectionUnobserve") && be.unobserve(e);
3624
+ }
3625
+ function Co() {
3626
+ P("intersectionDisconnect") && be.disconnect();
3627
+ }
3628
+ function Oo() {
3629
+ if (!P("sendData") && !d.value.localization) return;
3630
+ const e = $e.getItem(Ge);
3631
+ e && (T.sendLocal(e), $e.removeItem(Ge));
3632
+ }
3633
+ function Po(e) {
3634
+ !P("localizationOverFlow") && !d.value.localization || (d.value.localizationOverFlow = e);
3635
+ }
3636
+ function xo() {
3637
+ return Ze(d.value);
3638
+ }
3639
+ const Uo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3640
+ __proto__: null,
3641
+ afterSendData: vo,
3642
+ beforePushEventList: mo,
3643
+ beforeSendData: po,
3644
+ getBaseInfo: Eo,
3645
+ getFirstScreen: So,
3646
+ getIPs: Io,
3647
+ getOptions: xo,
3648
+ getSDKUserUuid: yo,
3649
+ getUserUuid: bo,
3650
+ intersectionDisconnect: Co,
3651
+ intersectionObserver: ko,
3652
+ intersectionUnobserve: To,
3653
+ sendLocal: Oo,
3654
+ setLocalizationOverFlow: Po,
3655
+ setUserUuid: go,
3656
+ traceCustomEvent: Ro,
3657
+ traceError: Lo,
3658
+ tracePageView: Ao,
3659
+ tracePerformance: wo,
3660
+ unzipRecordscreen: ho
3661
+ }, Symbol.toStringTag, { value: "Module" }));
3662
+ function No(e) {
3663
+ p.__webTracingInit__ || Ln(e) && (Tn(), yr(), gr(), Sr(), Vr(), Gr(), oo(), Kr(), ao(), lo(), d.value.recordScreen && Rr(), p.__webTracingInit__ = !0);
3664
+ }
3665
+ function jo() {
3666
+ zr(), Hr(), io(), eo(), fo(), Tr(), co(), Yn(), T && T.destroy(), p.__webTracingInit__ = !1;
3667
+ }
3668
+ function Fo(e, t) {
3669
+ No(t);
3670
+ }
3671
+ const Wo = { install: Fo };
3672
+ export {
3673
+ V as SEDNEVENTTYPES,
3674
+ O as SENDID,
3675
+ d as _options,
3676
+ vo as afterSendData,
3677
+ mo as beforePushEventList,
3678
+ po as beforeSendData,
3679
+ Wo as default,
3680
+ jo as destroyTracing,
3681
+ Uo as exportMethods,
3682
+ Eo as getBaseInfo,
3683
+ So as getFirstScreen,
3684
+ Io as getIPs,
3685
+ xo as getOptions,
3686
+ yo as getSDKUserUuid,
3687
+ bo as getUserUuid,
3688
+ No as init,
3689
+ Co as intersectionDisconnect,
3690
+ ko as intersectionObserver,
3691
+ To as intersectionUnobserve,
3692
+ se as logError,
3693
+ Qe as parseError,
3694
+ Oo as sendLocal,
3695
+ Po as setLocalizationOverFlow,
3696
+ go as setUserUuid,
3697
+ Ro as traceCustomEvent,
3698
+ Lo as traceError,
3699
+ Ao as tracePageView,
3700
+ wo as tracePerformance,
3701
+ ho as unzipRecordscreen
3702
+ };