// Module ID: 1065 // Function ID: 12120 // Name: distanceToMatch // Dependencies: [] // Module 1065 (distanceToMatch) function distanceToMatch(nodeType) { let num = Infinity; if (arguments.length > 2) { num = Infinity; if (undefined !== arguments[2]) { num = arguments[2]; } } let num2 = 0; if (arguments.length > 3) { num2 = 0; if (undefined !== arguments[3]) { num2 = arguments[3]; } } let num3 = -1; if (nodeType) { let num4 = -1; if (nodeType.nodeType === nodeType.ELEMENT_NODE) { num4 = -1; if (num2 <= num) { let tmp = num2; if (!arg1(nodeType)) { tmp = distanceToMatch(nodeType.parentNode, arg1, num, num2 + 1); } num4 = tmp; } } num3 = num4; } return num3; } function createMatchPredicate(arg0, arg1) { let closure_0 = arg0; let closure_1 = arg1; return (arg0) => { if (null === arg0) { return false; } else { if (arg0) { if ("string" === typeof arg0) { const _HermesInternal = HermesInternal; if (obj.matches("." + arg0)) { return true; } } else { let diff = tmp3 - 1; let flag2 = false; if (+obj.classList.length) { flag2 = true; while (!obj2.test(obj.classList[diff])) { let tmp5 = +diff; diff = tmp5 - 1; flag2 = false; if (!tmp5) { break; } } } if (flag2) { return true; } const obj2 = arg0; } } let tmp11 = tmp10; if (!!arg1) { tmp11 = !obj.matches(arg1); } return !tmp11; } }; } function hookSetter(arg0, arg1, arg2, arg3) { let tmp = arg2; let closure_0 = arg0; let closure_1 = arg1; let closure_2 = arg2; if (arguments.length > 4) { if (undefined !== arguments[4]) { let _window = arguments[4]; } const _Object = _window.Object; const ownPropertyDescriptor = _Object.getOwnPropertyDescriptor(arg0, arg1); const _Object2 = _window.Object; if (!arg3) { const obj = { set(arg0) { const arg1 = this; callback(() => { set.set.call(self, arg0); }, 0); let set = closure_3; if (closure_3) { set = closure_3.set; } if (set) { closure_3.set.call(this, arg0); const set2 = closure_3.set; } } }; tmp = obj; } _Object2.defineProperty(arg0, arg1, tmp); return () => { let obj = closure_3; if (!closure_3) { obj = {}; } return closure_23(arg0, arg1, obj, true); }; } _window = window; } function patch(arg0, arg1, arg2) { let closure_0 = arg0; let closure_1 = arg1; if (arg1 in arg0) { let closure_2 = tmp5; const tmp7 = arg2(tmp[tmp2]); if ("function" === typeof tmp7) { const prototype = tmp8.prototype; let obj = prototype; if (!prototype) { obj = {}; } tmp8.prototype = obj; const _Object = Object; obj = {}; obj = { enumerable: false, value: tmp5 }; obj.__rrweb_original__ = obj; Object.defineProperties(tmp8, obj); } arg0[arg1] = tmp7; return () => { arg0[arg1] = tmp5; }; } else { return () => { }; } } function isBlocked(arg0, arg1, arg2, arg3, arg4) { if (arg0) { let tmp3 = null; if (arg0) { if (tmp.nodeType === tmp.ELEMENT_NODE) { let parentElement = arg0; } else { parentElement = tmp.parentElement; } tmp3 = parentElement; } while (true) { if (tmp3) { let tmp6 = createMatchPredicate; let tmp7 = arg1; let tmp8 = arg2; let tmp9 = distanceToMatch; let tmp10 = distanceToMatch(tmp3, createMatchPredicate(arg1, arg2)); let num = 0; let tmp11 = tmp10 < 0; let tmp12 = !tmp11; if (!tmp11) { let num2 = -1; let num3 = -1; if (arg3) { let tmp13 = distanceToMatch; let tmp14 = createMatchPredicate; num3 = distanceToMatch(tmp3, createMatchPredicate(null, arg3)); } let tmp15 = tmp10 > -1 && num3 < 0 || tmp10 < num3; tmp12 = tmp15; } return tmp12; } else { let flag2 = false; return false; } } } else { return false; } } function getImplementation(arg0) { if (closure_9[arg0]) { return tmp2; } else { const _window = window; const _document = window.document; const _window2 = window; let obj2 = window[tmp]; if (_document) { if ("function" === typeof obj.createElement) { const element =