UNPKG

@papa-sports/web-tracing-vue2

Version:

基于 JS 跨平台插件,为前端项目提供【 埋点、行为、性能、异常、请求、资源、路由、曝光、录屏 】监控手段 - vue2版本

29 lines 207 kB
(function(b){"use strict";var x=function(){return x=Object.assign||function(n){for(var t,r=1,a=arguments.length;r<a;r++){t=arguments[r];for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(n[i]=t[i])}return n},x.apply(this,arguments)};function ic(e,n,t,r){function a(i){return i instanceof t?i:new t(function(s){s(i)})}return new(t||(t=Promise))(function(i,s){function o(u){try{c(r.next(u))}catch(h){s(h)}}function l(u){try{c(r.throw(u))}catch(h){s(h)}}function c(u){u.done?i(u.value):a(u.value).then(o,l)}c((r=r.apply(e,n||[])).next())})}function oc(e,n){var t={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},r,a,i,s=Object.create((typeof Iterator=="function"?Iterator:Object).prototype);return s.next=o(0),s.throw=o(1),s.return=o(2),typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function o(c){return function(u){return l([c,u])}}function l(c){if(r)throw new TypeError("Generator is already executing.");for(;s&&(s=0,c[0]&&(t=0)),t;)try{if(r=1,a&&(i=c[0]&2?a.return:c[0]?a.throw||((i=a.return)&&i.call(a),0):a.next)&&!(i=i.call(a,c[1])).done)return i;switch(a=0,i&&(c=[c[0]&2,i.value]),c[0]){case 0:case 1:i=c;break;case 4:return t.label++,{value:c[1],done:!1};case 5:t.label++,a=c[1],c=[0];continue;case 7:c=t.ops.pop(),t.trys.pop();continue;default:if(i=t.trys,!(i=i.length>0&&i[i.length-1])&&(c[0]===6||c[0]===2)){t=0;continue}if(c[0]===3&&(!i||c[1]>i[0]&&c[1]<i[3])){t.label=c[1];break}if(c[0]===6&&t.label<i[1]){t.label=i[1],i=c;break}if(i&&t.label<i[2]){t.label=i[2],t.ops.push(c);break}i[2]&&t.ops.pop(),t.trys.pop();continue}c=n.call(e,t)}catch(u){c=[6,u],a=0}finally{r=i=0}if(c[0]&5)throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}}function ie(e,n,t){if(t||arguments.length===2)for(var r=0,a=n.length,i;r<a;r++)(i||!(r in n))&&(i||(i=Array.prototype.slice.call(n,0,r)),i[r]=n[r]);return e.concat(i||Array.prototype.slice.call(n))}typeof SuppressedError=="function"&&SuppressedError;function nt(e){return function(n){return Object.prototype.toString.call(n)==="[object ".concat(e,"]")}}var rr=nt("RegExp"),sc=nt("Number"),cc=nt("String"),lc=nt("Boolean"),uc=nt("Function"),wn=nt("Array"),dc=nt("Window"),ar=function(e){return lc(e)&&String(e)==="false"};function fc(e){return cc(e)&&e.trim()===""||e===void 0||e===null}var ir,or,hc=dc(typeof window<"u"?window:0),pc=!!(!((or=(ir=window?.process)===null||ir===void 0?void 0:ir.versions)===null||or===void 0)&&or.electron),sr=typeof navigator<"u"&&navigator.userAgent.includes("jsdom")||typeof window<"u"&&window.jsdom;function Ea(){return hc||pc||sr?window:{}}function gc(){return L.__webTracing__=L.__webTracing__||{},L.__webTracing__}function mc(){return!!L.__webTracingInit__}var L=Ea(),he=gc(),pt=function(){function e(){this.subs=new Set}return e.prototype.addSub=function(){e.target&&this.subs.add(e.target)},e.prototype.notify=function(){for(var n=[],t=0;t<arguments.length;t++)n[t]=arguments[t];this.subs.forEach(function(r){r.proxy.dirty=!0,r.update.apply(r,n)})},e}(),cr="__webtracingobserver__";function vc(e){return Object.prototype.toString.call(e)==="[object RegExp]"}var bc=function(){function e(n){this.target=n}return e.prototype.defineReactive=function(){var n=new pt,t=yc(function(){n.addSub()},function(r){n.notify(r)});return new Proxy(this.target,t)},e}();function yc(e,n){var t=new WeakMap,r={get:function(a,i,s){var o=Reflect.get(a,i,s);if(e&&e(),typeof o=="object"&&o!==null&&!vc(o)){var l=t.get(o);return l||(l=new Proxy(o,r),t.set(o,l)),l}return o},set:function(a,i,s,o){var l=Reflect.get(a,i,o);if(l===s)return l;var c=JSON.parse(JSON.stringify(a)),u=Reflect.set(a,i,s,o);return n&&n(c),u}};return r}var Ic=new WeakMap;function _c(e){var n={value:e};n[cr]=!0;var t=new bc(n),r=t.defineReactive();return Ic.set(t,r),r}function wc(e){return!!e[cr]}var ka=[];function Ra(e){pt.target&&ka.push(pt.target),pt.target=e}function xa(){pt.target=ka.pop()}var Ta=function(){function e(n,t,r){var a=t.computed,i=t.watch,s=t.callback;this.getter=r,this.computed=a||!1,this.watch=i||!1,this.callback=s,this.proxy={value:"",dirty:!0},this.vm=n,a?this.dep=new pt:i?this.watchGet():this.get()}return e.prototype.update=function(n){this.computed?this.dep.notify():this.watch?n!==this.proxy.value&&this.callback&&this.callback(this.proxy.value,n):this.get()},e.prototype.get=function(){Ra(this);var n=this.computed?La.get(this.vm).call(this.vm):"";return n!==this.proxy.value&&(this.proxy.dirty=!1,this.proxy.value=n),xa(),n},e.prototype.watchGet=function(){Ra(this),this.proxy.dirty=!1,this.getter&&(this.proxy.value=this.getter()),xa()},e.prototype.depend=function(){this.dep.addSub()},e}(),Cc=function(){function e(n){this.target=n}return e.prototype.defineReactive=function(){var n=new Ta(this,{computed:!0}),t={get:function(){return n.proxy.dirty?(n.depend(),n.get()):(n.depend(),n.proxy.value)}};return new Proxy(this.target,t)},e}(),La=new WeakMap;function Sc(e){var n={value:0};n[cr]=!0;var t=new Cc(n),r=t.defineReactive();return La.set(t,e),r}function Ac(e,n){new Ta("",{watch:!0,callback:e},n)}function Ec(e,n){wc(e)&&Ac(function(t,r){n(t,r)},function(){return e.value})}function lr(){return!!window.Proxy}function kc(e){return lr()?_c(e):{value:e}}function Oa(e){return lr()?Sc(e):{value:e()}}function Rc(e,n){return lr()?Ec(e,n):function(){return{}}}var xc=function(){function e(n){this.dsn="",this.appName="",this.appCode="",this.appVersion="",this.userUuid="",this.sdkUserUuid="",this.debug=!1,this.pv={core:!1},this.performance={core:!1,firstResource:!1,server:!1},this.error={core:!1,server:!1},this.event={core:!1},this.recordScreen=!0,this.ext={},this.tracesSampleRate=1,this.cacheMaxLength=5,this.cacheWatingTime=5e3,this.ignoreErrors=[],this.ignoreRequest=[],this.scopeError=!1,this.localization=!1,this.sendTypeByXmlBody=!1,this.beforePushEventList=[],this.beforeSendData=[],this.afterSendData=[],this.localizationOverFlow=function(){};var t=this.transitionOptions(n);t.ignoreRequest.push(new RegExp(t.dsn)),Cn(this,t)}return e.prototype.transitionOptions=function(n){var t=Cn({},this,n),r=n.beforePushEventList,a=n.beforeSendData,i=n.afterSendData,s=t.pv,o=t.performance,l=t.error,c=t.event;return typeof s=="boolean"&&(t.pv={core:s}),typeof o=="boolean"&&(t.performance={core:o,firstResource:o,server:o}),typeof l=="boolean"&&(t.error={core:l,server:l}),typeof c=="boolean"&&(t.event={core:c}),r&&(t.beforePushEventList=[r]),a&&(t.beforeSendData=[a]),i&&(t.afterSendData=[i]),t},e}();function Tc(e){var n=e.dsn,t=e.appName,r=e.appCode,a=e.appVersion,i=e.userUuid,s=e.debug,o=e.recordScreen,l=e.pv,c=e.performance,u=e.error,h=e.event,d=e.ext,f=e.tracesSampleRate,p=e.cacheMaxLength,v=e.cacheWatingTime,g=e.ignoreErrors,I=e.ignoreRequest,_=e.scopeError,m=e.localization,y=e.sendTypeByXmlBody,S=e.beforePushEventList,T=e.beforeSendData,w=e.isParseDataCode,k=e.parseDataOption,A=[];l&&typeof l=="object"?A.push(Z(l.core,"pv.core","boolean")):A.push(Z(l,"pv","boolean")),c&&typeof c=="object"?A.push(Z(c.core,"performance.core","boolean"),Z(c.firstResource,"performance.firstResource","boolean"),Z(c.server,"performance.server","boolean")):A.push(Z(c,"performance","boolean")),u&&typeof u=="object"?A.push(Z(u.core,"error.core","boolean"),Z(u.server,"error.server","boolean")):A.push(Z(u,"error","boolean")),h&&typeof h=="object"?A.push(Z(h.core,"event.core","boolean")):A.push(Z(h,"event","boolean"));var C=[Z(n,"dsn","string"),Z(t,"appName","string"),Z(r,"appCode","string"),Z(a,"appVersion","string"),Z(i,"userUuid","string"),Z(s,"debug","boolean"),Z(o,"recordScreen","boolean"),Z(d,"ext","object"),Z(f,"tracesSampleRate","number"),Z(p,"cacheMaxLength","number"),Z(v,"cacheWatingTime","number"),Z(g,"ignoreErrors","array"),Na(g,"ignoreErrors",["string","regexp"]),Z(I,"ignoreRequest","array"),Na(I,"ignoreRequest",["string","regexp"]),Z(_,"scopeError","boolean"),Z(m,"localization","boolean"),Z(y,"sendTypeByXmlBody","boolean"),Z(S,"beforePushEventList","function"),Z(T,"beforeSendData","function"),Z(w,"isParseDataCode","boolean"),Z(k,"parseDataOption","object")];return C.every(function(R){return!!R})}function Lc(e){var n=[Ma(e.appName,"appName"),Ma(e.dsn,"dsn")];return n.every(function(t){return!!t})}function Ma(e,n){return fc(e)?(Xe("\u3010".concat(n,"\u3011\u53C2\u6570\u5FC5\u586B")),!1):!0}function Z(e,n,t){return!e||vt(e)===t?!0:(Xe("TypeError:\u3010".concat(n,"\u3011\u671F\u671B\u4F20\u5165").concat(t,"\u7C7B\u578B\uFF0C\u76EE\u524D\u662F").concat(vt(e),"\u7C7B\u578B")),!1)}function Na(e,n,t){if(!e)return!0;var r=!0;return e.forEach(function(a){t.includes(vt(a))||(Xe("TypeError:\u3010".concat(n,"\u3011\u6570\u7EC4\u5185\u7684\u503C\u671F\u671B\u4F20\u5165").concat(t.join("|"),"\u7C7B\u578B\uFF0C\u76EE\u524D\u503C").concat(a,"\u662F").concat(vt(a),"\u7C7B\u578B")),r=!1)}),r}b.options=void 0;function Oc(e){return!Lc(e)||!Tc(e)?!1:(b.options=kc(new xc(e)),he.options=b.options,!0)}function gt(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];b.options.value.debug&&console.log.apply(console,ie(["@papa-sports: "],e,!1))}function Xe(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];console.error.apply(console,ie(["@papa-sports: "],e,!1))}function Ie(e,n,t,r){r===void 0&&(r=!1),e.addEventListener(n,t,r)}function mt(e,n,t,r){if(r===void 0&&(r=!1),e!==void 0&&(n in e||r)){var a=e[n],i=t(a);uc(i)&&(e[n]=i)}}function Vt(e){return Object.keys(e).forEach(function(n){var t=e[n];sc(t)&&(e[n]=t===0?void 0:parseFloat(t.toFixed(2)))}),e}function me(){return typeof document>"u"||document.location==null?"":document.location.href}function B(){return Date.now()}function Da(e,n,t){t===void 0&&(t=!1);var r=null,a;return function(){for(var i=this,s=[],o=0;o<arguments.length;o++)s[o]=arguments[o];a=s,r===null&&(t&&e.apply(this,a),r=setTimeout(function(){r=null,e.apply(i,a)},n))}}function Mc(e,n,t){t===void 0&&(t=!1);var r=null;return function(){for(var a=this,i=[],s=0;s<arguments.length;s++)i[s]=arguments[s];t&&(e.call.apply(e,ie([this],i,!1)),t=!1),r&&clearTimeout(r),r=setTimeout(function(){e.call.apply(e,ie([a],i,!1))},n)}}function ur(e){for(var n=[],t=1;t<arguments.length;t++)n[t-1]=arguments[t];for(var r=new Map,a=function(l){var c=n.filter(function(u){return l[u]}).map(function(u){return l[u]}).join(":");r.has(c)||r.set(c,[]),r.get(c).push(l)},i=0,s=e;i<s.length;i++){var o=s[i];a(o)}return Array.from(r.values())}function Cn(e){for(var n=[],t=1;t<arguments.length;t++)n[t-1]=arguments[t];return n.forEach(function(r){for(var a in r)r[a]!==null&&rr(r[a])?e[a]=r[a]:r[a]!==null&&typeof r[a]=="object"?e[a]=Cn(e[a]||(wn(r[a])?[]:{}),r[a]):e[a]=r[a]}),e}function ne(e){return mc()?!0:(Xe("".concat(e," \u9700\u8981\u5728SDK\u521D\u59CB\u5316\u4E4B\u540E\u4F7F\u7528")),!1)}function vt(e){return Object.prototype.toString.call(e).slice(8,-1).toLowerCase()}function bt(e,n){return e in n}function Nc(e){return Math.random()<=e}function yt(e,n,t){t===void 0&&(t="0");var r=String(e);if(r.length<n){for(var a=r,i=0;i<n-r.length;i+=1)a=t+a;return a}return r}function Fa(e){return e.split("?")[0]}function dr(){for(var e=new Date,n=parseInt("".concat(e.getFullYear()).concat(yt(e.getMonth()+1,2)).concat(yt(e.getDate(),2)),10).toString(16),t=parseInt("".concat(yt(e.getHours(),2)).concat(yt(e.getMinutes(),2)).concat(yt(e.getSeconds(),2)).concat(yt(e.getMilliseconds(),3)),10).toString(16),r=n+t.length+t;r.length<32;)r+=Math.floor(Math.random()*16).toString(16);return"".concat(r.slice(0,8),"-").concat(r.slice(8,16),"-").concat(r.slice(16))}function fr(e){var n=document.cookie.match(new RegExp("".concat(e,"=([^;]+)(;|$)")));return n?n[1]:void 0}function Dc(e,n){return navigator.sendBeacon(e,JSON.stringify(n))}var Sn=[];function Fc(e,n){return new Promise(function(t){var r=new Image;r.src="".concat(e,"?v=").concat(encodeURIComponent(JSON.stringify(n))),Sn.push(r),r.onload=function(){t()},r.onerror=function(){t()}})}function Zc(e,n){return new Promise(function(t){var r=new XMLHttpRequest;r.open("post",e),r.setRequestHeader("content-type","application/json"),r.send(JSON.stringify(n)),r.onreadystatechange=function(){r.readyState===4&&t()}})}function An(e,n,t){if(e.length===0)return t;for(var r=void 0,a=0;a<e.length;a++){var i=e[a];a===0||n?r=i(t):r=i(r)}return r}function hr(e){return wn(e)?e:[e]}var Bc=Array.prototype.map||function(n){for(var t=[],r=0;r<this.length;r+=1)t.push(n(this[r],r,this));return t};function Za(e,n){return Bc.call(e,n)}var Uc=Array.prototype.filter||function(n){for(var t=[],r=0;r<this.length;r+=1)n(this[r],r,this)&&t.push(this[r]);return t};function zc(e,n){return Uc.call(e,n)}var Wc=window.requestIdleCallback||window.requestAnimationFrame||function(e){return setTimeout(e,17)};function Ba(e,n){var t=JSON.stringify(e),r=new TextEncoder().encode(t).length,a=r/1024;return a>n}function En(e){var n={},t=e.split("?")[1];if(t)for(var r=t.split("&"),a=0,i=r;a<i.length;a++){var s=i[a],o=s.split("="),l=o[0],c=o[1];n[decodeURIComponent(l)]=decodeURIComponent(c)}return n}function pr(e,n){if(n===void 0&&(n=new Map),e!==null&&typeof e=="object"){var t=n.get(e);return t||(e instanceof Array?(t=[],n.set(e,t),e.forEach(function(r,a){t[a]=pr(r,n)})):(t={},n.set(e,t),Object.keys(e).forEach(function(r){bt(r,e)&&(t[r]=pr(e[r],n))})),t)}return e}var Vc="2.0.13",Ua="_webtracing_device_id",gr="_webtracing_session_id",Pc=18e5,mr="_webtracing_localization_key",Hc=Vc,E;(function(e){e.ERROR="error",e.CONSOLEERROR="consoleError",e.UNHANDLEDREJECTION="unhandledrejection",e.CLICK="click",e.LOAD="load",e.BEFOREUNLOAD="beforeunload",e.FETCH="fetch",e.XHROPEN="xhr-open",e.XHRSEND="xhr-send",e.HASHCHANGE="hashchange",e.HISTORYPUSHSTATE="history-pushState",e.HISTORYREPLACESTATE="history-replaceState",e.POPSTATE="popstate",e.READYSTATECHANGE="readystatechange",e.ONLINE="online",e.OFFLINE="offline"})(E||(E={}));var pe;(function(e){e.PV="pv",e.PVDURATION="pv-duration",e.ERROR="error",e.PERFORMANCE="performance",e.CLICK="click",e.DWELL="dwell",e.CUSTOM="custom",e.INTERSECTION="intersection"})(pe||(pe={})),b.SENDID=void 0,function(e){e.PAGE="page",e.RESOURCE="resource",e.SERVER="server",e.CODE="code",e.REJECT="reject",e.CONSOLEERROR="console.error"}(b.SENDID||(b.SENDID={}));var Gc={0:"navigate",1:"reload",2:"back_forward",255:"reserved"},Xc=function(){function e(){this.handlers={}}return e.prototype.addEvent=function(n){var t;!this.handlers[n.type]&&(this.handlers[n.type]=[]);var r=this._getCallbackIndex(n);r===-1&&((t=this.handlers[n.type])===null||t===void 0||t.push(n.callback))},e.prototype.delEvent=function(n){var t,r=this._getCallbackIndex(n);r!==-1&&((t=this.handlers[n.type])===null||t===void 0||t.splice(r,1))},e.prototype.changeEvent=function(n,t){var r,a=this._getCallbackIndex(n);a!==-1&&((r=this.handlers[n.type])===null||r===void 0||r.splice(a,1,t))},e.prototype.getEvent=function(n){return this.handlers[n]||[]},e.prototype.runEvent=function(n){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];var a=this.getEvent(n);a.forEach(function(i){i.apply(void 0,t)})},e.prototype._getCallbackIndex=function(n){if(this.handlers[n.type]){var t=this.handlers[n.type];return t?t.findIndex(function(r){return r===n.callback}):-1}else return-1},e}(),M=he.eventBus||(he.eventBus=new Xc);function jc(){for(var e in E)bt(e,E)&&Yc(e)}function Yc(e){if(bt(e,E)){var n=E[e];switch(n){case E.ERROR:Kc(E.ERROR);break;case E.UNHANDLEDREJECTION:Jc(E.UNHANDLEDREJECTION);break;case E.CONSOLEERROR:qc(E.CONSOLEERROR);break;case E.CLICK:Qc(E.CLICK);break;case E.LOAD:$c(E.LOAD);break;case E.BEFOREUNLOAD:el(E.BEFOREUNLOAD);break;case E.XHROPEN:tl(E.XHROPEN);break;case E.XHRSEND:nl(E.XHRSEND);break;case E.FETCH:rl(E.FETCH);break;case E.HASHCHANGE:al(E.HASHCHANGE);break;case E.HISTORYPUSHSTATE:ol(E.HISTORYPUSHSTATE);break;case E.HISTORYREPLACESTATE:il(E.HISTORYREPLACESTATE);break;case E.POPSTATE:sl(E.POPSTATE);break;case E.OFFLINE:cl(E.OFFLINE);break;case E.ONLINE:ll(E.ONLINE);break}}}function Kc(e){Ie(L,"error",function(n){M.runEvent(e,n)},!0)}function Jc(e){Ie(L,"unhandledrejection",function(n){M.runEvent(e,n)})}function qc(e){mt(console,"error",function(n){return function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];t[0]&&t[0].slice&&t[0].slice(0,12)==="@papa-sports"||M.runEvent(e,t),n.apply(this,t)}})}function Qc(e){if("document"in L){var n=Da(M.runEvent,100,!0);Ie(L.document,"click",function(t){n.call(M,e,t)},!0)}}function $c(e){Ie(L,"load",function(n){M.runEvent(e,n)},!0)}function el(e){Ie(L,"beforeunload",function(n){M.runEvent(e,n)},!1)}function tl(e){"XMLHttpRequest"in L&&mt(XMLHttpRequest.prototype,"open",function(n){return function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];M.runEvent.apply(M,ie([e],t,!1)),n.apply(this,t)}})}function nl(e){"XMLHttpRequest"in L&&mt(XMLHttpRequest.prototype,"send",function(n){return function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];M.runEvent.apply(M,ie([e,this],t,!1)),n.apply(this,t)}})}function rl(e){"fetch"in L&&mt(L,"fetch",function(n){return function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var a=B(),i={};return n.apply(L,t).then(function(s){return M.runEvent(e,t[0],t[1],s,a,i),s})}})}function al(e){Ie(L,"hashchange",function(n){M.runEvent(e,n)})}function il(e){"history"in L&&"pushState"in L.history&&mt(L.history,"replaceState",function(n){return function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];M.runEvent.apply(M,ie([e],t,!1)),n.apply(this,t)}})}function ol(e){"history"in L&&"pushState"in L.history&&mt(L.history,"pushState",function(n){return function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];M.runEvent.apply(M,ie([e],t,!1)),n.apply(this,t)}})}function sl(e){Ie(L,"popstate",function(n){M.runEvent(e,n)})}function cl(e){Ie(L,"offline",function(n){M.runEvent(e,n)},!0)}function ll(e){Ie(L,"online",function(n){M.runEvent(e,n)},!0)}var vr=function(){return vr=Object.assign||function(e){for(var n,t=1,r=arguments.length;t<r;t++)for(var a in n=arguments[t])Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a]);return e},vr.apply(this,arguments)};function Be(e,n,t,r){return new(t||(t=Promise))(function(a,i){function s(c){try{l(r.next(c))}catch(u){i(u)}}function o(c){try{l(r.throw(c))}catch(u){i(u)}}function l(c){var u;c.done?a(c.value):(u=c.value,u instanceof t?u:new t(function(h){h(u)})).then(s,o)}l((r=r.apply(e,n||[])).next())})}function xe(e,n){var t,r,a,i,s={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]};return i={next:o(0),throw:o(1),return:o(2)},typeof Symbol=="function"&&(i[Symbol.iterator]=function(){return this}),i;function o(l){return function(c){return function(u){if(t)throw new TypeError("Generator is already executing.");for(;i&&(i=0,u[0]&&(s=0)),s;)try{if(t=1,r&&(a=2&u[0]?r.return:u[0]?r.throw||((a=r.return)&&a.call(r),0):r.next)&&!(a=a.call(r,u[1])).done)return a;switch(r=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return s.label++,{value:u[1],done:!1};case 5:s.label++,r=u[1],u=[0];continue;case 7:u=s.ops.pop(),s.trys.pop();continue;default:if(a=s.trys,!((a=a.length>0&&a[a.length-1])||u[0]!==6&&u[0]!==2)){s=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){s.label=u[1];break}if(u[0]===6&&s.label<a[1]){s.label=a[1],a=u;break}if(a&&s.label<a[2]){s.label=a[2],s.ops.push(u);break}a[2]&&s.ops.pop(),s.trys.pop();continue}u=n.call(e,s)}catch(h){u=[6,h],r=0}finally{t=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}([l,c])}}}function It(e,n,t){if(t||arguments.length===2)for(var r,a=0,i=n.length;a<i;a++)!r&&a in n||(r||(r=Array.prototype.slice.call(n,0,a)),r[a]=n[a]);return e.concat(r||Array.prototype.slice.call(n))}function Ue(e,n){return new Promise(function(t){return setTimeout(t,e,n)})}function za(e){return!!e&&typeof e.then=="function"}function Wa(e,n){try{var t=e();za(t)?t.then(function(r){return n(!0,r)},function(r){return n(!1,r)}):n(!0,t)}catch(r){n(!1,r)}}function Va(e,n,t){return t===void 0&&(t=16),Be(this,void 0,void 0,function(){var r,a,i;return xe(this,function(s){switch(s.label){case 0:r=Date.now(),a=0,s.label=1;case 1:return a<e.length?(n(e[a],a),(i=Date.now())>=r+t?(r=i,[4,Ue(0)]):[3,3]):[3,4];case 2:s.sent(),s.label=3;case 3:return++a,[3,1];case 4:return[2]}})})}function kn(e){e.then(void 0,function(){})}function je(e,n){e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]],n=[n[0]>>>16,65535&n[0],n[1]>>>16,65535&n[1]];var t=[0,0,0,0];return t[3]+=e[3]+n[3],t[2]+=t[3]>>>16,t[3]&=65535,t[2]+=e[2]+n[2],t[1]+=t[2]>>>16,t[2]&=65535,t[1]+=e[1]+n[1],t[0]+=t[1]>>>16,t[1]&=65535,t[0]+=e[0]+n[0],t[0]&=65535,[t[0]<<16|t[1],t[2]<<16|t[3]]}function _e(e,n){e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]],n=[n[0]>>>16,65535&n[0],n[1]>>>16,65535&n[1]];var t=[0,0,0,0];return t[3]+=e[3]*n[3],t[2]+=t[3]>>>16,t[3]&=65535,t[2]+=e[2]*n[3],t[1]+=t[2]>>>16,t[2]&=65535,t[2]+=e[3]*n[2],t[1]+=t[2]>>>16,t[2]&=65535,t[1]+=e[1]*n[3],t[0]+=t[1]>>>16,t[1]&=65535,t[1]+=e[2]*n[2],t[0]+=t[1]>>>16,t[1]&=65535,t[1]+=e[3]*n[1],t[0]+=t[1]>>>16,t[1]&=65535,t[0]+=e[0]*n[3]+e[1]*n[2]+e[2]*n[1]+e[3]*n[0],t[0]&=65535,[t[0]<<16|t[1],t[2]<<16|t[3]]}function _t(e,n){return(n%=64)===32?[e[1],e[0]]:n<32?[e[0]<<n|e[1]>>>32-n,e[1]<<n|e[0]>>>32-n]:(n-=32,[e[1]<<n|e[0]>>>32-n,e[0]<<n|e[1]>>>32-n])}function ve(e,n){return(n%=64)===0?e:n<32?[e[0]<<n|e[1]>>>32-n,e[1]<<n]:[e[1]<<n-32,0]}function G(e,n){return[e[0]^n[0],e[1]^n[1]]}function Pa(e){return e=G(e,[0,e[0]>>>1]),e=G(e=_e(e,[4283543511,3981806797]),[0,e[0]>>>1]),e=G(e=_e(e,[3301882366,444984403]),[0,e[0]>>>1])}function ul(e,n){n=n||0;var t,r=(e=e||"").length%16,a=e.length-r,i=[0,n],s=[0,n],o=[0,0],l=[0,0],c=[2277735313,289559509],u=[1291169091,658871167];for(t=0;t<a;t+=16)o=[255&e.charCodeAt(t+4)|(255&e.charCodeAt(t+5))<<8|(255&e.charCodeAt(t+6))<<16|(255&e.charCodeAt(t+7))<<24,255&e.charCodeAt(t)|(255&e.charCodeAt(t+1))<<8|(255&e.charCodeAt(t+2))<<16|(255&e.charCodeAt(t+3))<<24],l=[255&e.charCodeAt(t+12)|(255&e.charCodeAt(t+13))<<8|(255&e.charCodeAt(t+14))<<16|(255&e.charCodeAt(t+15))<<24,255&e.charCodeAt(t+8)|(255&e.charCodeAt(t+9))<<8|(255&e.charCodeAt(t+10))<<16|(255&e.charCodeAt(t+11))<<24],o=_t(o=_e(o,c),31),i=je(i=_t(i=G(i,o=_e(o,u)),27),s),i=je(_e(i,[0,5]),[0,1390208809]),l=_t(l=_e(l,u),33),s=je(s=_t(s=G(s,l=_e(l,c)),31),i),s=je(_e(s,[0,5]),[0,944331445]);switch(o=[0,0],l=[0,0],r){case 15:l=G(l,ve([0,e.charCodeAt(t+14)],48));case 14:l=G(l,ve([0,e.charCodeAt(t+13)],40));case 13:l=G(l,ve([0,e.charCodeAt(t+12)],32));case 12:l=G(l,ve([0,e.charCodeAt(t+11)],24));case 11:l=G(l,ve([0,e.charCodeAt(t+10)],16));case 10:l=G(l,ve([0,e.charCodeAt(t+9)],8));case 9:l=_e(l=G(l,[0,e.charCodeAt(t+8)]),u),s=G(s,l=_e(l=_t(l,33),c));case 8:o=G(o,ve([0,e.charCodeAt(t+7)],56));case 7:o=G(o,ve([0,e.charCodeAt(t+6)],48));case 6:o=G(o,ve([0,e.charCodeAt(t+5)],40));case 5:o=G(o,ve([0,e.charCodeAt(t+4)],32));case 4:o=G(o,ve([0,e.charCodeAt(t+3)],24));case 3:o=G(o,ve([0,e.charCodeAt(t+2)],16));case 2:o=G(o,ve([0,e.charCodeAt(t+1)],8));case 1:o=_e(o=G(o,[0,e.charCodeAt(t)]),c),i=G(i,o=_e(o=_t(o,31),u))}return i=je(i=G(i,[0,e.length]),s=G(s,[0,e.length])),s=je(s,i),i=je(i=Pa(i),s=Pa(s)),s=je(s,i),("00000000"+(i[0]>>>0).toString(16)).slice(-8)+("00000000"+(i[1]>>>0).toString(16)).slice(-8)+("00000000"+(s[0]>>>0).toString(16)).slice(-8)+("00000000"+(s[1]>>>0).toString(16)).slice(-8)}function br(e){return parseInt(e)}function Ee(e){return parseFloat(e)}function ze(e,n){return typeof e=="number"&&isNaN(e)?n:e}function ke(e){return e.reduce(function(n,t){return n+(t?1:0)},0)}function Ha(e,n){if(n===void 0&&(n=1),Math.abs(n)>=1)return Math.round(e/n)*n;var t=1/n;return Math.round(e*t)/t}function Ga(e){return e&&typeof e=="object"&&"message"in e?e:{message:e}}function dl(e){return typeof e!="function"}function fl(e,n,t){var r=Object.keys(e).filter(function(i){return!function(s,o){for(var l=0,c=s.length;l<c;++l)if(s[l]===o)return!0;return!1}(t,i)}),a=Array(r.length);return Va(r,function(i,s){a[s]=function(o,l){var c=new Promise(function(u){var h=Date.now();Wa(o.bind(null,l),function(){for(var d=[],f=0;f<arguments.length;f++)d[f]=arguments[f];var p=Date.now()-h;if(!d[0])return u(function(){return{error:Ga(d[1]),duration:p}});var v=d[1];if(dl(v))return u(function(){return{value:v,duration:p}});u(function(){return new Promise(function(g){var I=Date.now();Wa(v,function(){for(var _=[],m=0;m<arguments.length;m++)_[m]=arguments[m];var y=p+Date.now()-I;if(!_[0])return g({error:Ga(_[1]),duration:y});g({value:_[1],duration:y})})})})})});return kn(c),function(){return c.then(function(u){return u()})}}(e[i],n)}),function(){return Be(this,void 0,void 0,function(){var i,s,o,l,c,u;return xe(this,function(h){switch(h.label){case 0:for(i={},s=0,o=r;s<o.length;s++)l=o[s],i[l]=void 0;c=Array(r.length),u=function(){var d;return xe(this,function(f){switch(f.label){case 0:return d=!0,[4,Va(r,function(p,v){if(!c[v])if(a[v]){var g=a[v]().then(function(I){return i[p]=I});kn(g),c[v]=g}else d=!1})];case 1:return f.sent(),d?[2,"break"]:[4,Ue(1)];case 2:return f.sent(),[2]}})},h.label=1;case 1:return[5,u()];case 2:if(h.sent()==="break")return[3,4];h.label=3;case 3:return[3,1];case 4:return[4,Promise.all(c)];case 5:return h.sent(),[2,i]}})})}}function Xa(){var e=window,n=navigator;return ke(["MSCSSMatrix"in e,"msSetImmediate"in e,"msIndexedDB"in e,"msMaxTouchPoints"in n,"msPointerEnabled"in n])>=4}function hl(){var e=window,n=navigator;return ke(["msWriteProfilerMark"in e,"MSStream"in e,"msLaunchUri"in n,"msSaveBlob"in n])>=3&&!Xa()}function yr(){var e=window,n=navigator;return ke(["webkitPersistentStorage"in n,"webkitTemporaryStorage"in n,n.vendor.indexOf("Google")===0,"webkitResolveLocalFileSystemURL"in e,"BatteryManager"in e,"webkitMediaStream"in e,"webkitSpeechGrammar"in e])>=5}function Pt(){var e=window,n=navigator;return ke(["ApplePayError"in e,"CSSPrimitiveValue"in e,"Counter"in e,n.vendor.indexOf("Apple")===0,"getStorageUpdates"in n,"WebKitMediaKeys"in e])>=4}function Ir(){var e=window;return ke(["safari"in e,!("DeviceMotionEvent"in e),!("ongestureend"in e),!("standalone"in navigator)])>=3}function pl(){var e,n,t=window;return ke(["buildID"in navigator,"MozAppearance"in((n=(e=document.documentElement)===null||e===void 0?void 0:e.style)!==null&&n!==void 0?n:{}),"onmozfullscreenchange"in t,"mozInnerScreenX"in t,"CSSMozDocumentRule"in t,"CanvasCaptureMediaStream"in t])>=4}function gl(){var e=document;return e.fullscreenElement||e.msFullscreenElement||e.mozFullScreenElement||e.webkitFullscreenElement||null}function ja(){var e=yr(),n=pl();if(!e&&!n)return!1;var t=window;return ke(["onorientationchange"in t,"orientation"in t,e&&!("SharedWorker"in t),n&&/android/i.test(navigator.appVersion)])>=2}function Ya(e){var n=new Error(e);return n.name=e,n}function Ka(e,n,t){var r,a,i;return t===void 0&&(t=50),Be(this,void 0,void 0,function(){var s,o;return xe(this,function(l){switch(l.label){case 0:s=document,l.label=1;case 1:return s.body?[3,3]:[4,Ue(t)];case 2:return l.sent(),[3,1];case 3:o=s.createElement("iframe"),l.label=4;case 4:return l.trys.push([4,,10,11]),[4,new Promise(function(c,u){var h=!1,d=function(){h=!0,c()};o.onload=d,o.onerror=function(v){h=!0,u(v)};var f=o.style;f.setProperty("display","block","important"),f.position="absolute",f.top="0",f.left="0",f.visibility="hidden",n&&"srcdoc"in o?o.srcdoc=n:o.src="about:blank",s.body.appendChild(o);var p=function(){var v,g;h||(((g=(v=o.contentWindow)===null||v===void 0?void 0:v.document)===null||g===void 0?void 0:g.readyState)==="complete"?d():setTimeout(p,10))};p()})];case 5:l.sent(),l.label=6;case 6:return!((a=(r=o.contentWindow)===null||r===void 0?void 0:r.document)===null||a===void 0)&&a.body?[3,8]:[4,Ue(t)];case 7:return l.sent(),[3,6];case 8:return[4,e(o,o.contentWindow)];case 9:return[2,l.sent()];case 10:return(i=o.parentNode)===null||i===void 0||i.removeChild(o),[7];case 11:return[2]}})})}function ml(e){for(var n=function(c){for(var u,h,d="Unexpected syntax '".concat(c,"'"),f=/^\s*([a-z-]*)(.*)$/i.exec(c),p=f[1]||void 0,v={},g=/([.:#][\w-]+|\[.+?\])/gi,I=function(S,T){v[S]=v[S]||[],v[S].push(T)};;){var _=g.exec(f[2]);if(!_)break;var m=_[0];switch(m[0]){case".":I("class",m.slice(1));break;case"#":I("id",m.slice(1));break;case"[":var y=/^\[([\w-]+)([~|^$*]?=("(.*?)"|([\w-]+)))?(\s+[is])?\]$/.exec(m);if(!y)throw new Error(d);I(y[1],(h=(u=y[4])!==null&&u!==void 0?u:y[5])!==null&&h!==void 0?h:"");break;default:throw new Error(d)}}return[p,v]}(e),t=n[0],r=n[1],a=document.createElement(t??"div"),i=0,s=Object.keys(r);i<s.length;i++){var o=s[i],l=r[o].join(" ");o==="style"?vl(a.style,l):a.setAttribute(o,l)}return a}function vl(e,n){for(var t=0,r=n.split(";");t<r.length;t++){var a=r[t],i=/^\s*([\w-]+)\s*:\s*(.+?)(\s*!([\w-]+))?\s*$/.exec(a);if(i){var s=i[1],o=i[2],l=i[4];e.setProperty(s,o,l||"")}}}var wt=["monospace","sans-serif","serif"],Ja=["sans-serif-thin","ARNO PRO","Agency FB","Arabic Typesetting","Arial Unicode MS","AvantGarde Bk BT","BankGothic Md BT","Batang","Bitstream Vera Sans Mono","Calibri","Century","Century Gothic","Clarendon","EUROSTILE","Franklin Gothic","Futura Bk BT","Futura Md BT","GOTHAM","Gill Sans","HELV","Haettenschweiler","Helvetica Neue","Humanst521 BT","Leelawadee","Letter Gothic","Levenim MT","Lucida Bright","Lucida Sans","Menlo","MS Mincho","MS Outlook","MS Reference Specialty","MS UI Gothic","MT Extra","MYRIAD PRO","Marlett","Meiryo UI","Microsoft Uighur","Minion Pro","Monotype Corsiva","PMingLiU","Pristina","SCRIPTINA","Segoe UI Light","Serifa","SimHei","Small Fonts","Staccato222 BT","TRAJAN PRO","Univers CE 55 Medium","Vrinda","ZWAdobeF"];function _r(e){return e.toDataURL()}var Rn,wr;function bl(){var e=this;return function(){if(wr===void 0){var n=function(){var t=Cr();Sr(t)?wr=setTimeout(n,2500):(Rn=t,wr=void 0)};n()}}(),function(){return Be(e,void 0,void 0,function(){var n;return xe(this,function(t){switch(t.label){case 0:return Sr(n=Cr())?Rn?[2,It([],Rn,!0)]:gl()?[4,(r=document,(r.exitFullscreen||r.msExitFullscreen||r.mozCancelFullScreen||r.webkitExitFullscreen).call(r))]:[3,2]:[3,2];case 1:t.sent(),n=Cr(),t.label=2;case 2:return Sr(n)||(Rn=n),[2,n]}var r})})}}function Cr(){var e=screen;return[ze(Ee(e.availTop),null),ze(Ee(e.width)-Ee(e.availWidth)-ze(Ee(e.availLeft),0),null),ze(Ee(e.height)-Ee(e.availHeight)-ze(Ee(e.availTop),0),null),ze(Ee(e.availLeft),null)]}function Sr(e){for(var n=0;n<4;++n)if(e[n])return!1;return!0}function yl(e){var n;return Be(this,void 0,void 0,function(){var t,r,a,i,s,o,l;return xe(this,function(c){switch(c.label){case 0:for(t=document,r=t.createElement("div"),a=new Array(e.length),i={},qa(r),l=0;l<e.length;++l)s=ml(e[l]),qa(o=t.createElement("div")),o.appendChild(s),r.appendChild(o),a[l]=s;c.label=1;case 1:return t.body?[3,3]:[4,Ue(50)];case 2:return c.sent(),[3,1];case 3:t.body.appendChild(r);try{for(l=0;l<e.length;++l)a[l].offsetParent||(i[e[l]]=!0)}finally{(n=r.parentNode)===null||n===void 0||n.removeChild(r)}return[2,i]}})})}function qa(e){e.style.setProperty("display","block","important")}function Qa(e){return matchMedia("(inverted-colors: ".concat(e,")")).matches}function $a(e){return matchMedia("(forced-colors: ".concat(e,")")).matches}function Ct(e){return matchMedia("(prefers-contrast: ".concat(e,")")).matches}function ei(e){return matchMedia("(prefers-reduced-motion: ".concat(e,")")).matches}function ti(e){return matchMedia("(dynamic-range: ".concat(e,")")).matches}var z=Math,oe=function(){return 0},Ar={default:[],apple:[{font:"-apple-system-body"}],serif:[{fontFamily:"serif"}],sans:[{fontFamily:"sans-serif"}],mono:[{fontFamily:"monospace"}],min:[{fontSize:"1px"}],system:[{fontFamily:"system-ui"}]},Il={fonts:function(){return Ka(function(e,n){var t=n.document,r=t.body;r.style.fontSize="48px";var a=t.createElement("div"),i={},s={},o=function(h){var d=t.createElement("span"),f=d.style;return f.position="absolute",f.top="0",f.left="0",f.fontFamily=h,d.textContent="mmMwWLliI0O&1",a.appendChild(d),d},l=wt.map(o),c=function(){for(var h={},d=function(v){h[v]=wt.map(function(g){return function(I,_){return o("'".concat(I,"',").concat(_))}(v,g)})},f=0,p=Ja;f<p.length;f++)d(p[f]);return h}();r.appendChild(a);for(var u=0;u<wt.length;u++)i[wt[u]]=l[u].offsetWidth,s[wt[u]]=l[u].offsetHeight;return Ja.filter(function(h){return n=c[h],wt.some(function(d,f){return n[f].offsetWidth!==i[d]||n[f].offsetHeight!==s[d]})})})},domBlockers:function(e){var n=(e===void 0?{}:e).debug;return Be(this,void 0,void 0,function(){var t,r,a,i,s;return xe(this,function(o){switch(o.label){case 0:return Pt()||ja()?(l=atob,t={abpIndo:["#Iklan-Melayang","#Kolom-Iklan-728","#SidebarIklan-wrapper",l("YVt0aXRsZT0iN25hZ2EgcG9rZXIiIGld"),'[title="ALIENBOLA" i]'],abpvn:["#quangcaomb",l("Lmlvc0Fkc2lvc0Fkcy1sYXlvdXQ="),".quangcao",l("W2hyZWZePSJodHRwczovL3I4OC52bi8iXQ=="),l("W2hyZWZePSJodHRwczovL3piZXQudm4vIl0=")],adBlockFinland:[".mainostila",l("LnNwb25zb3JpdA=="),".ylamainos",l("YVtocmVmKj0iL2NsaWNrdGhyZ2guYXNwPyJd"),l("YVtocmVmXj0iaHR0cHM6Ly9hcHAucmVhZHBlYWsuY29tL2FkcyJd")],adBlockPersian:["#navbar_notice_50",".kadr",'TABLE[width="140px"]',"#divAgahi",l("I2FkMl9pbmxpbmU=")],adBlockWarningRemoval:["#adblock-honeypot",".adblocker-root",".wp_adblock_detect",l("LmhlYWRlci1ibG9ja2VkLWFk"),l("I2FkX2Jsb2NrZXI=")],adGuardAnnoyances:['amp-embed[type="zen"]',".hs-sosyal","#cookieconsentdiv",'div[class^="app_gdpr"]',".as-oil"],adGuardBase:[".BetterJsPopOverlay",l("I2FkXzMwMFgyNTA="),l("I2Jhbm5lcmZsb2F0MjI="),l("I2FkLWJhbm5lcg=="),l("I2NhbXBhaWduLWJhbm5lcg==")],adGuardChinese:[l("LlppX2FkX2FfSA=="),l("YVtocmVmKj0iL29kMDA1LmNvbSJd"),l("YVtocmVmKj0iLmh0aGJldDM0LmNvbSJd"),".qq_nr_lad","#widget-quan"],adGuardFrench:[l("I2Jsb2NrLXZpZXdzLWFkcy1zaWRlYmFyLWJsb2NrLWJsb2Nr"),"#pavePub",l("LmFkLWRlc2t0b3AtcmVjdGFuZ2xl"),".mobile_adhesion",".widgetadv"],adGuardGerman:[l("LmJhbm5lcml0ZW13ZXJidW5nX2hlYWRfMQ=="),l("LmJveHN0YXJ0d2VyYnVuZw=="),l("LndlcmJ1bmcz"),l("YVtocmVmXj0iaHR0cDovL3d3dy5laXMuZGUvaW5kZXgucGh0bWw/cmVmaWQ9Il0="),l("YVtocmVmXj0iaHR0cHM6Ly93d3cudGlwaWNvLmNvbS8/YWZmaWxpYXRlSWQ9Il0=")],adGuardJapanese:["#kauli_yad_1",l("YVtocmVmXj0iaHR0cDovL2FkMi50cmFmZmljZ2F0ZS5uZXQvIl0="),l("Ll9wb3BJbl9pbmZpbml0ZV9hZA=="),l("LmFkZ29vZ2xl"),l("LmFkX3JlZ3VsYXIz")],adGuardMobile:[l("YW1wLWF1dG8tYWRz"),l("LmFtcF9hZA=="),'amp-embed[type="24smi"]',"#mgid_iframe1",l("I2FkX2ludmlld19hcmVh")],adGuardRussian:[l("YVtocmVmXj0iaHR0cHM6Ly9hZC5sZXRtZWFkcy5jb20vIl0="),l("LnJlY2xhbWE="),'div[id^="smi2adblock"]',l("ZGl2W2lkXj0iQWRGb3hfYmFubmVyXyJd"),l("I2FkX3NxdWFyZQ==")],adGuardSocial:[l("YVtocmVmXj0iLy93d3cuc3R1bWJsZXVwb24uY29tL3N1Ym1pdD91cmw9Il0="),l("YVtocmVmXj0iLy90ZWxlZ3JhbS5tZS9zaGFyZS91cmw/Il0="),".etsy-tweet","#inlineShare",".popup-social"],adGuardSpanishPortuguese:["#barraPublicidade","#Publicidade","#publiEspecial","#queTooltip",l("W2hyZWZePSJodHRwOi8vYWRzLmdsaXNwYS5jb20vIl0=")],adGuardTrackingProtection:["#qoo-counter",l("YVtocmVmXj0iaHR0cDovL2NsaWNrLmhvdGxvZy5ydS8iXQ=="),l("YVtocmVmXj0iaHR0cDovL2hpdGNvdW50ZXIucnUvdG9wL3N0YXQucGhwIl0="),l("YVtocmVmXj0iaHR0cDovL3RvcC5tYWlsLnJ1L2p1bXAiXQ=="),"#top100counter"],adGuardTurkish:["#backkapat",l("I3Jla2xhbWk="),l("YVtocmVmXj0iaHR0cDovL2Fkc2Vydi5vbnRlay5jb20udHIvIl0="),l("YVtocmVmXj0iaHR0cDovL2l6bGVuemkuY29tL2NhbXBhaWduLyJd"),l("YVtocmVmXj0iaHR0cDovL3d3dy5pbnN0YWxsYWRzLm5ldC8iXQ==")],bulgarian:[l("dGQjZnJlZW5ldF90YWJsZV9hZHM="),"#ea_intext_div",".lapni-pop-over","#xenium_hot_offers",l("I25ld0Fk")],easyList:[l("I0FEX0NPTlRST0xfMjg="),l("LnNlY29uZC1wb3N0LWFkcy13cmFwcGVy"),".universalboxADVBOX03",l("LmFkdmVydGlzZW1lbnQtNzI4eDkw"),l("LnNxdWFyZV9hZHM=")],easyListChina:[l("YVtocmVmKj0iLndlbnNpeHVldGFuZy5jb20vIl0="),l("LmFwcGd1aWRlLXdyYXBbb25jbGljayo9ImJjZWJvcy5jb20iXQ=="),l("LmZyb250cGFnZUFkdk0="),"#taotaole","#aafoot.top_box"],easyListCookie:["#AdaCompliance.app-notice",".text-center.rgpd",".panel--cookie",".js-cookies-andromeda",".elxtr-consent"],easyListCzechSlovak:["#onlajny-stickers",l("I3Jla2xhbW5pLWJveA=="),l("LnJla2xhbWEtbWVnYWJvYXJk"),".sklik",l("W2lkXj0ic2tsaWtSZWtsYW1hIl0=")],easyListDutch:[l("I2FkdmVydGVudGll"),l("I3ZpcEFkbWFya3RCYW5uZXJCbG9jaw=="),".adstekst",l("YVtocmVmXj0iaHR0cHM6Ly94bHR1YmUubmwvY2xpY2svIl0="),"#semilo-lrectangle"],easyListGermany:[l("I0FkX1dpbjJkYXk="),l("I3dlcmJ1bmdzYm94MzAw"),l("YVtocmVmXj0iaHR0cDovL3d3dy5yb3RsaWNodGthcnRlaS5jb20vP3NjPSJd"),l("I3dlcmJ1bmdfd2lkZXNreXNjcmFwZXJfc2NyZWVu"),l("YVtocmVmXj0iaHR0cDovL2xhbmRpbmcucGFya3BsYXR6a2FydGVpLmNvbS8/YWc9Il0=")],easyListItaly:[l("LmJveF9hZHZfYW5udW5jaQ=="),".sb-box-pubbliredazionale",l("YVtocmVmXj0iaHR0cDovL2FmZmlsaWF6aW9uaWFkcy5zbmFpLml0LyJd"),l("YVtocmVmXj0iaHR0cHM6Ly9hZHNlcnZlci5odG1sLml0LyJd"),l("YVtocmVmXj0iaHR0cHM6Ly9hZmZpbGlhemlvbmlhZHMuc25haS5pdC8iXQ==")],easyListLithuania:[l("LnJla2xhbW9zX3RhcnBhcw=="),l("LnJla2xhbW9zX251b3JvZG9z"),l("aW1nW2FsdD0iUmVrbGFtaW5pcyBza3lkZWxpcyJd"),l("aW1nW2FsdD0iRGVkaWt1b3RpLmx0IHNlcnZlcmlhaSJd"),l("aW1nW2FsdD0iSG9zdGluZ2FzIFNlcnZlcmlhaS5sdCJd")],estonian:[l("QVtocmVmKj0iaHR0cDovL3BheTRyZXN1bHRzMjQuZXUiXQ==")],fanboyAnnoyances:["#feedback-tab","#taboola-below-article",".feedburnerFeedBlock",".widget-feedburner-counter",'[title="Subscribe to our blog"]'],fanboyAntiFacebook:[".util-bar-module-firefly-visible"],fanboyEnhancedTrackers:[".open.pushModal","#issuem-leaky-paywall-articles-zero-remaining-nag","#sovrn_container",'div[class$="-hide"][zoompage-fontsize][style="display: block;"]',".BlockNag__Card"],fanboySocial:[".td-tags-and-social-wrapper-box",".twitterContainer",".youtube-social",'a[title^="Like us on Facebook"]','img[alt^="Share on Digg"]'],frellwitSwedish:[l("YVtocmVmKj0iY2FzaW5vcHJvLnNlIl1bdGFyZ2V0PSJfYmxhbmsiXQ=="),l("YVtocmVmKj0iZG9rdG9yLXNlLm9uZWxpbmsubWUiXQ=="),"article.category-samarbete",l("ZGl2LmhvbGlkQWRz"),"ul.adsmodern"],greekAdBlock:[l("QVtocmVmKj0iYWRtYW4ub3RlbmV0LmdyL2NsaWNrPyJd"),l("QVtocmVmKj0iaHR0cDovL2F4aWFiYW5uZXJzLmV4b2R1cy5nci8iXQ=="),l("QVtocmVmKj0iaHR0cDovL2ludGVyYWN0aXZlLmZvcnRobmV0LmdyL2NsaWNrPyJd"),"DIV.agores300","TABLE.advright"],hungarian:["#cemp_doboz",".optimonk-iframe-container",l("LmFkX19tYWlu"),l("W2NsYXNzKj0iR29vZ2xlQWRzIl0="),"#hirdetesek_box"],iDontCareAboutCookies:['.alert-info[data-block-track*="CookieNotice"]',".ModuleTemplateCookieIndicator",".o--cookies--container",".cookie-msg-info-container","#cookies-policy-sticky"],icelandicAbp:[l("QVtocmVmXj0iL2ZyYW1ld29yay9yZXNvdXJjZXMvZm9ybXMvYWRzLmFzcHgiXQ==")],latvian:[l("YVtocmVmPSJodHRwOi8vd3d3LnNhbGlkemluaS5sdi8iXVtzdHlsZT0iZGlzcGxheTogYmxvY2s7IHdpZHRoOiAxMjBweDsgaGVpZ2h0OiA0MHB4OyBvdmVyZmxvdzogaGlkZGVuOyBwb3NpdGlvbjogcmVsYXRpdmU7Il0="),l("YVtocmVmPSJodHRwOi8vd3d3LnNhbGlkemluaS5sdi8iXVtzdHlsZT0iZGlzcGxheTogYmxvY2s7IHdpZHRoOiA4OHB4OyBoZWlnaHQ6IDMxcHg7IG92ZXJmbG93OiBoaWRkZW47IHBvc2l0aW9uOiByZWxhdGl2ZTsiXQ==")],listKr:[l("YVtocmVmKj0iLy9hZC5wbGFuYnBsdXMuY28ua3IvIl0="),l("I2xpdmVyZUFkV3JhcHBlcg=="),l("YVtocmVmKj0iLy9hZHYuaW1hZHJlcC5jby5rci8iXQ=="),l("aW5zLmZhc3R2aWV3LWFk"),".revenue_unit_item.dable"],listeAr:[l("LmdlbWluaUxCMUFk"),".right-and-left-sponsers",l("YVtocmVmKj0iLmFmbGFtLmluZm8iXQ=="),l("YVtocmVmKj0iYm9vcmFxLm9yZyJd"),l("YVtocmVmKj0iZHViaXp6bGUuY29tL2FyLz91dG1fc291cmNlPSJd")],listeFr:[l("YVtocmVmXj0iaHR0cDovL3Byb21vLnZhZG9yLmNvbS8iXQ=="),l("I2FkY29udGFpbmVyX3JlY2hlcmNoZQ=="),l("YVtocmVmKj0id2Vib3JhbWEuZnIvZmNnaS1iaW4vIl0="),".site-pub-interstitiel",'div[id^="crt-"][data-criteo-id]'],officialPolish:["#ceneo-placeholder-ceneo-12",l("W2hyZWZePSJodHRwczovL2FmZi5zZW5kaHViLnBsLyJd"),l("YVtocmVmXj0iaHR0cDovL2Fkdm1hbmFnZXIudGVjaGZ1bi5wbC9yZWRpcmVjdC8iXQ=="),l("YVtocmVmXj0iaHR0cDovL3d3dy50cml6ZXIucGwvP3V0bV9zb3VyY2UiXQ=="),l("ZGl2I3NrYXBpZWNfYWQ=")],ro:[l("YVtocmVmXj0iLy9hZmZ0cmsuYWx0ZXgucm8vQ291bnRlci9DbGljayJd"),'a[href^="/magazin/"]',l("YVtocmVmXj0iaHR0cHM6Ly9ibGFja2ZyaWRheXNhbGVzLnJvL3Ryay9zaG9wLyJd"),l("YVtocmVmXj0iaHR0cHM6Ly9ldmVudC4ycGVyZm9ybWFudC5jb20vZXZlbnRzL2NsaWNrIl0="),l("YVtocmVmXj0iaHR0cHM6Ly9sLnByb2ZpdHNoYXJlLnJvLyJd")],ruAd:[l("YVtocmVmKj0iLy9mZWJyYXJlLnJ1LyJd"),l("YVtocmVmKj0iLy91dGltZy5ydS8iXQ=="),l("YVtocmVmKj0iOi8vY2hpa2lkaWtpLnJ1Il0="),"#pgeldiz",".yandex-rtb-block"],thaiAds:["a[href*=macau-uta-popup]",l("I2Fkcy1nb29nbGUtbWlkZGxlX3JlY3RhbmdsZS1ncm91cA=="),l("LmFkczMwMHM="),".bumq",".img-kosana"],webAnnoyancesUltralist:["#mod-social-share-2","#social-tools",l("LmN0cGwtZnVsbGJhbm5lcg=="),".zergnet-recommend",".yt.btn-link.btn-md.btn"]},r=Object.keys(t),[4,yl((s=[]).concat.apply(s,r.map(function(c){return t[c]})))]):[2,void 0];case 1:return a=o.sent(),n&&function(c,u){for(var h="DOM blockers debug:\n```",d=0,f=Object.keys(c);d<f.length;d++){var p=f[d];h+=`
`.concat(p,":");for(var v=0,g=c[p];v<g.length;v++){var I=g[v];h+=`
  `.concat(u[I]?"\u{1F6AB}":"\u27A1\uFE0F"," ").concat(I)}}console.log("".concat(h,"\n```"))}(t,a),(i=r.filter(function(c){var u=t[c];return ke(u.map(function(h){return a[h]}))>.6*u.length})).sort(),[2,i]}var l})})},fontPreferences:function(){return function(e,n){return n===void 0&&(n=4e3),Ka(function(t,r){var a=r.document,i=a.body,s=i.style;s.width="".concat(n,"px"),s.webkitTextSizeAdjust=s.textSizeAdjust="none",yr()?i.style.zoom="".concat(1/r.devicePixelRatio):Pt()&&(i.style.zoom="reset");var o=a.createElement("div");return o.textContent=It([],Array(n/20<<0),!0).map(function(){return"word"}).join(" "),i.appendChild(o),e(a,i)})}(function(e,n){for(var t={},r={},a=0,i=Object.keys(Ar);a<i.length;a++){var s=i[a],o=Ar[s],l=o[0],c=l===void 0?{}:l,u=o[1],h=u===void 0?"mmMwWLliI0fiflO&1":u,d=e.createElement("span");d.textContent=h,d.style.whiteSpace="nowrap";for(var f=0,p=Object.keys(c);f<p.length;f++){var v=p[f],g=c[v];g!==void 0&&(d.style[v]=g)}t[s]=d,n.appendChild(e.createElement("br")),n.appendChild(d)}for(var I=0,_=Object.keys(Ar);I<_.length;I++)r[s=_[I]]=t[s].getBoundingClientRect().width;return r})},audio:function(){var e=window,n=e.OfflineAudioContext||e.webkitOfflineAudioContext;if(!n)return-2;if(Pt()&&!Ir()&&!function(){var c=window;return ke(["DOMRectList"in c,"RTCPeerConnectionIceEvent"in c,"SVGGeometryElement"in c,"ontransitioncancel"in c])>=3}())return-1;var t=new n(1,5e3,44100),r=t.createOscillator();r.type="triangle",r.frequency.value=1e4;var a=t.createDynamicsCompressor();a.threshold.value=-50,a.knee.value=40,a.ratio.value=12,a.attack.value=0,a.release.value=.25,r.connect(a),a.connect(t.destination),r.start(0);var i=function(c){var u=3,h=500,d=500,f=5e3,p=function(){};return[new Promise(function(v,g){var I=!1,_=0,m=0;c.oncomplete=function(T){return v(T.renderedBuffer)};var y=function(){setTimeout(function(){return g(Ya("timeout"))},Math.min(d,m+f-Date.now()))},S=function(){try{var T=c.startRendering();switch(za(T)&&kn(T),c.state){case"running":m=Date.now(),I&&y();break;case"suspended":document.hidden||_++,I&&_>=u?g(Ya("suspended")):setTimeout(S,h)}}catch(w){g(w)}};S(),p=function(){I||(I=!0,m>0&&y())}}),p]}(t),s=i[0],o=i[1],l=s.then(function(c){return function(u){for(var h=0,d=0;d<u.length;++d)h+=Math.abs(u[d]);return h}(c.getChannelData(0).subarray(4500))},function(c){if(c.name==="timeout"||c.name==="suspended")return-3;throw c});return kn(l),function(){return o(),l}},screenFrame:function(){var e=this,n=bl();return function(){return Be(e,void 0,void 0,function(){var t,r;return xe(this,function(a){switch(a.label){case 0:return[4,n()];case 1:return t=a.sent(),[2,[(r=function(i){return i===null?null:Ha(i,10)})(t[0]),r(t[1]),r(t[2]),r(t[3])]]}})})}},osCpu:function(){return navigator.oscpu},languages:function(){var e,n=navigator,t=[],r=n.language||n.userLanguage||n.browserLanguage||n.systemLanguage;if(r!==void 0&&t.push([r]),Array.isArray(n.languages))yr()&&ke([!("MediaSettingsRange"in(e=window)),"RTCEncodedAudioFrame"in e,""+e.Intl=="[object Intl]",""+e.Reflect=="[object Reflect]"])>=3||t.push(n.languages);else if(typeof n.languages=="string"){var a=n.languages;a&&t.push(a.split(","))}return t},colorDepth:function(){return window.screen.colorDepth},deviceMemory:function(){return ze(Ee(navigator.deviceMemory),void 0)},screenResolution:function(){var e=screen,n=function(r){return ze(br(r),null)},t=[n(e.width),n(e.height)];return t.sort().reverse(),t},hardwareConcurrency:function(){return ze(br(navigator.hardwareConcurrency),void 0)},timezone:function(){var e,n=(e=window.Intl)===null||e===void 0?void 0:e.DateTimeFormat;if(n){var t=new n().resolvedOptions().timeZone;if(t)return t}var r,a=(r=new Date().getFullYear(),-Math.max(Ee(new Date(r,0,1).getTimezoneOffset()),Ee(new Date(r,6,1).getTimezoneOffset())));return"UTC".concat(a>=0?"+":"").concat(Math.abs(a))},sessionStorage:function(){try{return!!window.sessionStorage}catch{return!0}},localStorage:function(){try{return!!window.localStorage}catch{return!0}},indexedDB:function(){if(!Xa()&&!hl())try{return!!window.indexedDB}catch{return!0}},openDatabase:function(){return!!window.openDatabase},cpuClass:function(){return navigator.cpuClass},platform:function(){var e=navigator.platform;return e==="MacIntel"&&Pt()&&!Ir()?function(){if(navigator.platform==="iPad")return!0;var n=screen,t=n.width/n.height;return ke(["MediaSource"in window,!!Element.prototype.webkitRequestFullscreen,t>.65&&t<1.53])>=2}()?"iPad":"iPhone":e},plugins:function(){var e=navigator.plugins;if(e){for(var n=[],t=0;t<e.length;++t){var r=e[t];if(r){for(var a=[],i=0;i<r.length;++i){var s=r[i];a.push({type:s.type,suffixes:s.suffixes})}n.push({name:r.name,description:r.description,mimeTypes:a})}}return n}},canvas:function(){var e,n,t=!1,r=function(){var o=document.createElement("canvas");return o.width=1,o.height=1,[o,o.getContext("2d")]}(),a=r[0],i=r[1];if(function(o,l){return!(!l||!o.toDataURL)}(a,i)){t=function(o){return o.rect(0,0,10,10),o.rect(2,2,6,6),!o.isPointInPath(5,5,"evenodd")}(i),function(o,l){o.width=240,o.height=60,l.textBaseline="alphabetic",l.fillStyle="#f60",l.fillRect(100,1,62,20),l.fillStyle="#069",l.font='11pt "Times New Roman"';var c="Cwm fjordbank gly ".concat(String.fromCharCode(55357,56835));l.fillText(c,2,15),l.fillStyle="rgba(102, 204, 0, 0.2)",l.font="18pt Arial",l.fillText(c,4,45)}(a,i);var s=_r(a);s!==_r(a)?e=n="unstable":(n=s,function(o,l){o.width=122,o.height=110,l.globalCompositeOperation="multiply";for(var c=0,u=[["#f2f",40,40],["#2ff",80,40],["#ff2",60,80]];c<u.length;c++){var h=u[c],d=h[0],f=h[1],p=h[2];l.fillStyle=d,l.beginPath(),l.arc(f,p,40,0,2*Math.PI,!0),l.closePath(),l.fill()}l.fillStyle="#f9c",l.arc(60,60,60,0,2*Math.PI,!0),l.arc(60,60,20,0,2*Math.PI,!0),l.fill("evenodd")}(a,i),e=_r(a))}else e=n="";return{winding:t,geometry:e,text:n}},touchSupport:function(){var e,n=navigator,t=0;n.maxTouchPoints!==void 0?t=br(n.maxTouchPoints):n.msMaxTouchPoints!==void 0&&(t=n.msMaxTouchPoints);try{document.createEvent("TouchEvent"),e=!0}catch{e=!1}return{maxTouchPoints:t,touchEvent:e,touchStart:"ontouchstart"in window}},vendor:function(){return navigator.vendor||""},vendorFlavors:function(){for(var e=[],n=0,t=["chrome","safari","__crWeb","__gCrWeb","yandex","__yb","__ybro","__firefox__","__edgeTrackingPreventionStatistics","webkit","oprt","samsungAr","ucweb","UCShellJava","puffinDevice"];n<t.length;n++){var r=t[n],a=window[r];a&&typeof a=="object"&&e.push(r)}return e.sort()},cookiesEnabled:function(){var e=document;try{e.cookie="cookietest=1; SameSite=Strict;";var n=e.cookie.indexOf("cookietest=")!==-1;return e.cookie="cookietest=1; SameSite=Strict; expires=Thu, 01-Jan-1970 00:00:01 GMT",n}catch{return!1}},colorGamut:function(){for(var e=0,n=["rec2020","p3","srgb"];e<n.length;e++){var t=n[e];if(matchMedia("(color-gamut: ".concat(t,")")).matches)return t}},invertedColors:function(){return!!Qa("inverted")||!Qa("none")&&void 0},forcedColors:function(){return!!$a("active")||!$a("none")&&void 0},monochrome:function(){if(matchMedia("(min-monochrome: 0)").matches){for(var e=0;e<=100;++e)if(matchMedia("(max-monochrome: ".concat(e,")")).matches)return e;throw new Error("Too high value")}},contrast:function(){return Ct("no-preference")?0:Ct("high")||Ct("more")?1:Ct("low")||Ct("less")?-1:Ct("forced")?10:void 0},reducedMotion:function(){return!!ei("reduce")||!ei("no-preference")&&void 0},hdr:function(){return!!ti("high")||!ti("standard")&&void 0},math:function(){var e,n=z.acos||oe,t=z.acosh||oe,r=z.asin||oe,a=z.asinh||oe,i=z.atanh||oe,s=z.atan||oe,o=z.sin||oe,l=z.sinh||oe,c=z.cos||oe,u=z.cosh||oe,h=z.tan||oe,d=z.tanh||oe,f=z.exp||oe,p=z.expm1||oe,v=z.log1p||oe;return{acos:n(.12312423423423424),acosh:t(1e308),acoshPf:(e=1e154,z.log(e+z.sqrt(e*e-1))),asin:r(.12312423423423424),asinh:a(1),asinhPf:function(g){return z.log(g+z.sqrt(g*g+1))}(1),atanh:i(.5),atanhPf:function(g){return z.log((1+g)/(1-g))/2}(.5),atan:s(.5),sin:o(-1e300),sinh:l(1),sinhPf:function(g){return z.exp(g)-1/z.exp(g)/2}(1),cos:c(10.000000000123),cosh:u(1),coshPf:function(g){return(z.exp(g)+1/z.exp(g))/2}(1),tan:h(-1e300),tanh:d(1),tanhPf:function(g){return(z.exp(2*g)-1)/(z.exp(2*g)+1)}(1),exp:f(1),expm1:p(1),expm1Pf:function(g){return z.exp(g)-1}(1),log1p:v(10),log1pPf:function(g){return z.log(1+g)}(10),powPI:function(g){return z.pow(z.PI,g)}(-100)}},videoCard:function(){var e,n=document.createElement("canvas"),t=(e=n.getContext("webgl"))!==null&&e!==void 0?e:n.getContext("experimental-webgl");if(t&&"getExtension"in t){var r=t.getExtension("WEBGL_debug_renderer_info");if(r)return{vendor:(t.getParameter(r.UNMASKED_VENDOR_WEBGL)||"").toString(),renderer:(t.getParameter(r.UNMASKED_RENDERER_WEBGL)||"").toString()}}},pdfViewerEnabled:function(){return navigator.pdfViewerEnabled},architecture:function(){var e=new Float32Array(1),n=new Uint8Array(e.buffer);return e[0]=1/0,e[0]=e[0]-e[0],n[3]}};function _l(e){var n=function(r){if(ja())return .4;if(Pt())return Ir()?.5:.3;var a=r.platform.value||"";return/^Win/.test(a)?.6:/^Mac/.test(a)?.5:.7}(e),t=function(r){return Ha(.99+.01*r,1e-4)}(n);return{score:n,comment:"$ if upgrade to Pro: https://fpjs.dev/pro".replace(/\$/g,"".concat(t))}}function wl(e){return JSON.stringify(e,function(n,t){return t instanceof Error?vr({name:(It=t).name,message:It.message,stack:(Ue=It.stack)===null||Ue===void 0?void 0:Ue.split(`
`)},It):t},2)}function Cl(e){return ul(function(n){for(var t="",r=0,a=Object.keys(n).sort();r<a.length;r++){var i=a[r],s=n[i],o=s.error?"error":JSON.stringify(s.value);t+="".concat(t?"|":"").concat(i.replace(/([:|\\])/g,"\\$1"),":").concat(o)}return t}(e))}function Sl(e){return e===void 0&&(e=50),function(n,t){t===void 0&&(t=1/0);var r=window.requestIdleCallback;return r?new Promise(function(a){return r.call(window,function(){return a()},{timeout:t})}):Ue(Math.min(n,t))}(e,2*e)}function Al(e,n){var t=Date.now();return{get:function(r){return Be(this,void 0,void 0,function(){var a,i,s;return xe(this,function(o){switch(o.label){case 0:return a=Date.now(),[4,e()];case 1:return i=o.sent(),s=function(l){var c;return{get visitorId(){return c===void 0&&(c=Cl(this.components)),c},set visitorId(u){c=u},confidence:_l(l),components:l,version:"3.4.1"}}(i),(n||r?.debug)&&console.log("Copy the text below to get the debug data:\n\n```\nversion: ".concat(s.version,`
userAgent: `).concat(navigator.userAgent,`
timeBetweenLoadAndGet: `).concat(a-t,`
visitorId: `).concat(s.visitorId,`
components: `).concat(wl(i),"\n```")),[2,s]}})})}}}function El(e){var n=e===void 0?{}:e,t=n.delayFallback,r=n.debug;return n.monitoring,Be(this,void 0,void 0,function(){return xe(this,function(a){switch(a.label){case 0:return[4,Sl(t)];case 1:return a.sent(),[2,Al(fl(Il,{debug:r},[]),r)]}})})}function Er(){var e=fr(gr)||"s_".concat(dr()),n=new Date(B()+Pc);return document.cookie="".concat(gr,"=").concat(e,";path=/;max-age=1800;expires=").concat(n.toUTCString()),e}function kl(){return fr(gr)||Er()}Er();function Rl(e){return ni.test(e)}function xl(e){return ri.test(e)}var ni=/((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])/,ri=/((([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}))|:)))/,Tl=[ri,ni];function Ll(e){var n,t=window.RTCPeerConnection||window.mozRTCPeerConnection||window.webkitRTCPeerConnection;function r(){(n=new t({iceServers:[{urls:"stun:stun.l.google.com:19302"}]})).onicecandidate=function(s){return i(s)},n.createDataChannel("fake_data_channel")}function a(){return n.createOffer().then(function(s){return n.setLocalDescription(s)})}function i(s){s&&s.candidate&&s.candidate.candidate&&e(s&&s.candidate&&s.candidate.candidate)}return{start:function(){r(),a()},stop:function(){if(n)try{n.close()}finally{n.onicecandidate=function(){},n=null}},createConnection:r,createStunRequest:a,handleCandidates:i}}function kr(e){if(e&&e<100)throw new Error("Custom timeout cannot be under 100 milliseconds.");var n=[],t=Ll(function(a){for(var i=[],s=0,o=Tl;s<o.length;s++){var l=o[s],c=[],u=l.exec(a);if(u){for(var h=0;h<u.length;h++)(Rl(u[h])||xl(u[h]))&&c.push(u[h]);i.push(c)}}(function(d){n.includes(d)||n.push(r(d.flat(1/0)))})(i.flat(1/0))});function r(a){return Array.from(new Set(a))}return new Promise(function(a,i){t.start(),setTimeout(function(){n&&n!==[]?a(r(n.flat(1/0))):i("No IP addresses were found."),t.stop()},e||500)})}function Rr(e){return new Promise(function(n,t){var r=[];kr(e).then(function(a){a.forEach(function(i){i.match(/^(192\.168\.|169\.254\.|10\.|172\.(1[6-9]|2\d|3[01]))/)?r.push({ip:i,type:"private",IPv4:!0}):i.match(/((([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}))|:)))/)?r.push({ip:i,type:"IPv6",IPv4:!1}):r.push({ip:i,type:"public",IPv4:!0})}),n(r)}).catch(t)})}function Ol(e){return Rr(e).then(function(n){for(var t=n.filter(function(a){return a.IPv4}),r=0;r<t.length;r++)t[r]=t[r].ip;return t||""})}function Ml(e){return Rr(e).then(function(n){for(var t=n.filter(function(a){return a.type==="IPv6"}),r=0;r<t.length;r++)t[r]=t[r].ip;return t?t.ip:""})}function ai(e){return Object.assign(kr(e),{types:Rr,public:kr,IPv4:Ol,IPv6:Ml})}var xr=function(){function e(){}return e.getItem=function(n){var t=localStorage.getItem(n);return t?JSON.parse(t):null},e.setItem=function(n,t){localStorage.setItem(n,JSON.stringify(t))},e.removeItem=function(n){localStorage.removeItem(n)},e.getSize=function(){for(var n=0,t=0;t<localStorage.length;t++){var r=localStorage.key(t);if(r){var a=localStorage.getItem(r);a&&(n+=this.getBytes(a))}}return n},e.setSendDataItem=function(n,t){if(this.getSize()>=this.maxSize)return!1;var r=this.getItem(n)||{baseInfo:{},eventInfo:[]},a={baseInfo:Cn(r.baseInfo,t.baseInfo),eventInfo:r.eventInfo.concat(t.eventInfo)};return this.setItem(n,a),!0},e.getBytes=function(n){var t=new Blob([n]);return t.size},e.maxSize=5*1024*1e3,e}(),Nl=function(){function e(){this.events=[]}return e.prototype.send=function(){if(this.events.length){var n=this.events.slice(0,b.options.value.cacheMaxLength);this.events=this.events.slice(b.options.value.cacheMaxLength);var t=B(),r=Oa(function(){var s;return{baseInfo:x(x({},(s=St.base)===null||s===void 0?void 0:s.value),{sendTime:t,userUuid:b.options.value.userUuid}),eventInfo:Za(n,function(o){return o.sendTime=t,o})}});if(b.options.value.localization){var a=xr.setSendDataItem(mr,r.value);a||b.options.value.localizationOverFlow(r.value);return}var i=An(b.options.value.beforeSendData,!1,r.value);ar(i)||this.validateObject(i,"beforeSendData")&&(gt("send events",r.value),this.executeSend(b.options.value.dsn,i).then(function(s){An(b.options.value.afterSendData,!0,x(x({},s),{params:i}))}),this.events.length&&Wc(this.send.bind(this)))}},e.prototype.sendLocal=function(n){var t=An(b.options.value.beforeSendData,!1,n);ar(t)||this.validateObject(t,"beforeSendData")&&(gt("send events",t),this.executeSend(b.options.value.dsn,t))},e.prototype.emit=function(n,t){if(t===void 0&&(t=!1),!!n&&he.lineStatus.onLine&&!(!t&&!Nc(b.options.value.tracesSampleRate))){wn(n)||(n=[n]);var r=An(b.options.value.beforePushEventList,!1,n);ar(r)||this.validateObject(r,"beforePushEventList")&&(this.events=this.events.concat(r),Er(),this.timeoutID&&clearTimeout(this.timeoutID),St._initSuccess&&(this.events.length>=b.options.value.cacheMaxLength||t?this.send():this.timeoutID=setTimeout(this.send.bind(this),b.options.value.cacheWatingTime)))}},e.prototype.executeSend=function(n,t){var r=1;return b.options.value.sendTypeByXmlBody?r=3:L.navigator?r=Ba(t,60)?3:1:r=Ba(t,2)?3:2,new Promise(function(a){switch(r){case 1:a({sendType:"sendBeacon",success:Dc(n,t)});break;case 2:Fc(n,t).then(function(){a({sendType:"image",success:!0})});break;case 3:Zc(n,t).then(function(){a({sendType:"xml",success:!0})});break}})},e.prototype.validateObject=function(n,t){return n===!1?!1:n?["object","array"].includes(vt(n))?!0:(Xe("TypeError: ".concat(t,"\u671F\u671B\u8FD4\u56DE {} \u6216\u8005 [] \u7C7B\u578B\uFF0C\u76EE\u524D\u662F").concat(vt(n),"\u7C7B\u578B")),!1):(Xe("NullError: ".concat(t,"\u671F\u671B\u8FD4\u56DE {} \u6216\u8005 [] \u7C7B\u578B\uFF0C\u76EE\u524D\u65E0\u8FD4\u56DE\u503C")),!1)},e}(),K;function Dl(){he.sendData=new Nl,K=he.sendData}var Fl=function(){function e(){var n=this;this.sdkUserUuid="",this._initSuccess=!1,this.pageId=dr(),this.initSdkUserUuid().then(function(){n.initDevice(),n.initBase()}).finally(function(){n._initSuccess=!0,K.emit([])})}return e.prototype.initDevice=function(){var n=Ea().screen,t=document.documentElement,r=t.clientWidth,a=t.clientHeight,i=n.width,s=n.height,o=n.colorDepth,l=n.pixelDepth,c=fr(Ua);c||(c="t_".concat(dr()),document.cookie="".concat(Ua,"=").concat(c,";path=/;")),this.device={clientHeight:a,clientWidth:r,colorDepth:o,pixelDepth:l,deviceId:c,screenWidth:i,screenHeight:s,vendor:navigator.vendor,platform:navigator.platform}},e.prototype.initBase=function(){var n=this,t=kl(),r="";this.base=Oa(function(){return x(x({},n.device),{userUuid:b.options.value.userUuid,sdkUserUuid:n.sdkUserUuid,ext:b.options.value.ext,appName:b.options.value.appName,appCode:b.options.value.appCode,pageId:n.pageId,sessionId:t,sdkVersion:Hc,ip:r})}),!sr&&ai().then(function(a){n.base.value.ip=a[0],r=a[0]})},e.prototype.initSdkUserUuid=function(){var n=this;return sr?Promise.resolve().then(function(){n.sdkUserUuid="unit-test-id",b.options.value.sdkUserUuid="unit-test-id"}):El({}).then(function(t){return t.get()}).then(function(t){var r=t.visitorId;n.sdkUserUuid=r,b.options.value.sdkUserUuid=r})},e}(),St;function Zl(){St=new Fl,he.baseInfo=St}var Bl=function(){function e(){this.onLine=!0,this.init()}return e.prototype.init=function(){var n=this;M.addEvent({type:E.OFFLINE,callback:function(t){t.type==="offline"&&(gt("\u7F51\u7EDC\u65AD\u5F00"),n.onLine=!1)}}),M.addEvent({type:E.ONLINE,callback:function(t){t.type==="online"&&(gt("\u7F51\u7EDC\u8FDE\u63A5"),n.onLine=!0)}})},e}();function Ul(){he.lineStatus=new Bl,he.lineStatus}var J;(function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"})(J||(J={}));function zl(e){return e.nodeType===e.ELEMENT_NODE}function Ht(e){var n=e?.host;return n?.shadowRoot===e}function Gt(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function Wl(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(" background-clip: text;"," -webkit-background-clip: text; background-clip: text;")),e}function Tr(e){try{var n=e.rules||e.cssRules;return n?Wl(Array.from(n).map(ii).join("")):null}catch{return null}}function ii(e){var n=e.cssText;if(Vl(e))try{n=Tr(e.styleSheet)||n}catch{}return n}function Vl(e){return"styleSheet"in e}var oi=function(){function e(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}return e.prototype.getId=function(n){var t;if(!n)return-1;var r=(t=this.getMeta(n))===null||t===void 0?void 0:t.id;return r??-1},e.prototype.getNode=function(n){return this.idNodeMap.get(n)||null},e.prototype.getIds=function(){return Array.from(this.idNodeMap.keys())},e.prototype.getMeta=function(n){return this.nodeMetaMap.get(n)||null},e.prototype.removeNodeFromMap=function(n){var t=this,r=this.getId(n);this.idNodeMap.delete(r),n.childNodes&&n.childNodes.forEach(function(a){return t.removeNodeFromMap(a)})},e.prototype.has=function(n){return this.idNodeMap.has(n)},e.prototype.hasNode=function(n){return this.nodeMetaMap.has(n)},e.prototype.add=function(n,t){var r=t.id;this.idNodeMap.set(r,n),this.nodeMetaMap.set(n,t)},e.prototype.replace=function(n,t){var r=this.getNode(n);if(r){var a=this.nodeMetaMap.get(r);a&&this.nodeMetaMap.set(t,a)}this.idNodeMap.set(n,t)},e.prototype.reset=function(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap},e}();function Pl(){return new oi}function Lr(e){var n=e.maskInputOptions,t=e.tagName,r=e.type,a=e.value,i=e.maskInputFn,s=a||"";return(n[t.toLowerCase()]||n[r])&&(i?s=i(s):s="*".repeat(s.length)),s}var si="__rrweb_original__";function Hl(e){var n=e.getContext("2d");if(!n)return!0;for(var t=50,r=0;r<e.width;r+=t)for(var a=0;a<e.height;a+=t){var i=n.getImageData,s=si in i?i[si]:i,o=new Uint32Array(s.call(n,r,a,Math.min(t,e.width-r),Math.min(t,e.height-a)).data.buffer);if(o.some(function(l){return l!==0}))return!1}return!0}var Gl=1,Xl=new RegExp("[^a-z0-9-_:]"),Xt=-2;function ci(){return Gl++}function jl(e){if(e instanceof HTMLFormElement)return"form";var n=e.tagName.toLowerCase().trim();return Xl.test(n)?"div":n}function Yl(e){return e.cssRules?Array.from(e.cssRules).map(function(n){return n.cssText||""}).join(""):""}function Kl(e){var n="";return e.indexOf("//")>-1?n=e.split("/").slice(0,3).join("/"):n=e.split("/")[0],n=n.split("?")[0],n}var At,li,Jl=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,ql=/^(?!www\.|(?:http|ftp)s?:\/\/|[A-Za-z]:\\|\/\/|#).*/,Ql=/^(data:)([^,]*),(.*)/i;function xn(e,n){return(e||"").replace(Jl,function(t,r,a,i,s,o){var l=a||s||o,c=r||i||"";if(!l)return t;if(!ql.test(l)||Ql.test(l))return"url(".concat(c).concat(l).concat(c,")");if(l[0]==="/")return"url(".concat(c).concat(Kl(n)+l).concat(c,")");var u=n.split("/"),h=l.split("/");u.pop();for(var d=0,f=h;d<f.length;d++){var p=f[d];p!=="."&&(p===".."?u.pop():u.push(p))}return"url(".concat(c).concat(u.join("/")).concat(c,")")})}var $l=/^[^ \t\n\r\u000c]+/,eu=/^[, \t\n\r\u000c]+/;function tu(e,n){if(n.trim()==="")return n;var t=0;function r(c){var u,h=c.exec(n.substring(t));return h?(u=h[0],t+=u.length,u):""}for(var a=[];r(eu),!(t>=n.length);){var i=r($l);if(i.slice(-1)===",")i=Et(e,i.substring(0,i.length-1)),a.push(i);else{var s="";i=Et(e,i);for(var o=!1;;){var l=n.charAt(t);if(l===""){a.push((i+s).trim());break}else if(o)l===")"&&(o=!1);else if(l===","){t+=1,a.push((i+s).trim());break}else l==="("&&(o=!0);s+=l,t+=1}}}return a.join(", ")}function Et(e,n){if(!n||n.trim()==="")return n;var t=e.createElement("a");return t.href=n,t.href}function nu(e){return!!(e.tagName==="svg"||e.ownerSVGElement)}function Or(){var e=document.createElement("a");return e.href="",e.href}function ui(e,n,t,r){return t==="src"||t==="href"&&r&&!(n==="use"&&r[0]==="#")||t==="xlink:href"&&r&&r[0]!=="#"||t==="background"&&r&&(n==="table"||n==="td"||n==="th")?Et(e,r):t==="srcset"&&r?tu(e,r):t==="style"&&r?xn(r,Or()):n==="object"&&t==="data"&&r?Et(e,r):r}function ru(e,n,t){if(typeof n=="string"){if(e.classList.contains(n))return!0}else for(var r=e.classList.length;r--;){var a=e.classList[r];if(n.test(a))return!0}return t?e.matches(t):!1}function Tn(e,n,t){if(!e)return!1;if(e.nodeType!==e.ELEMENT_NODE)return t?Tn(e.parentNode,n,t):!1;for(var r=e.classList.length;r--;){var a=e.classList[r];if(n.test(a))return!0}return t?Tn(e.parentNode,n,t):!1}function di(e,n,t){var r=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(r===null)return!1;if(typeof n=="string"){if(r.classList.contains(n)||r.closest(".".concat(n)))return!0}else if(Tn(r,n,!0))return!0;return!!(t&&(r.matches(t)||r.closest(t)))}function au(e,n,t){var r=e.contentWindow;if(r){var a=!1,i;try{i=r.document.readyState}catch{return}if(i!=="complete"){var s=setTimeout(function(){a||(n(),a=!0)},t);e.addEventListener("load",function(){clearTimeout(s),a=!0,n()});return}var o="about:blank";if(r.location.href!==o||e.src===o||e.src==="")return setTimeout(n,0),e.addEventListener("load",n);e.addEventListener("load",n)}}function iu(e,n,t){var r=!1,a;try{a=e.sheet}catch{return}if(!a){var i=setTimeout(function(){r||(n(),r=!0)},t);e.addEventListener("load",function(){clearTimeout(i),r=!0,n()})}}function ou(e,n){var t=n.doc,r=n.mirror,a=n.blockClass,i=n.blockSelector,s=n.maskTextClass,o=n.maskTextSelector,l=n.inlineStylesheet,c=n.maskInputOptions,u=c===void 0?{}:c,h=n.maskTextFn,d=n.maskInputFn,f=n.dataURLOptions,p=f===void 0?{}:f,v=n.inlineImages,g=n.recordCanvas,I=n.keepIframeSrcFn,_=n.newlyAddedElement,m=_===void 0?!1:_,y=su(t,r);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:J.Document,childNodes:[],compatMode:e.compatMode}:{type:J.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:J.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:y};case e.ELEMENT_NODE:return lu(e,{doc:t,blockClass:a,blockSelector:i,inlineStylesheet:l,maskInputOptions:u,maskInputFn:d,dataURLOptions:p,inlineImages:v,recordCanvas:g,keepIframeSrcFn:I,newlyAddedElement:m,rootId:y});case e.TEXT_NODE:return cu(e,{maskTextClass:s,maskTextSelector:o,maskTextFn:h,rootId:y});case e.CDATA_SECTION_NODE:return{type:J.CDATA,textContent:"",rootId:y};case e.COMMENT_NODE:return{type:J.Comment,textContent:e.textContent||"",rootId:y};default:return!1}}function su(e,n){if(n.hasNode(e)){var t=n.getId(e);return t===1?void 0:t}}function cu(e,n){var t,r=n.maskTextClass,a=n.maskTextSelector,i=n.maskTextFn,s=n.rootId,o=e.parentNode&&e.parentNode.tagName,l=e.textContent,c=o==="STYLE"?!0:void 0,u=o==="SCRIPT"?!0:void 0;if(c&&l){try{e.nextSibling||e.previousSibling||!((t=e.parentNode.sheet)===null||t===void 0)&&t.cssRules&&(l=Yl(e.parentNode.sheet))}catch(h){console.warn("Cannot get CSS styles from text's parentNode. Error: ".concat(h),e)}l=xn(l,Or())}return u&&(l="SCRIPT_PLACEHOLDER"),!c&&!u&&l&&di(e,r,a)&&(l=i?i(l):l.replace(/[\S]/g,"*")),{type:J.Text,textContent:l||"",isStyle:c,rootId:s}}function lu(e,n){for(var t=n.doc,r=n.blockClass,a=n.blockSelector,i=n.inlineStylesheet,s=n.maskInputOptions,o=s===void 0?{}:s,l=n.maskInputFn,c=n.dataURLOptions,u=c===void 0?{}:c,h=n.inlineImages,d=n.recordCanvas,f=n.keepIframeSrcFn,p=n.newlyAddedElement,v=p===void 0?!1:p,g=n.rootId,I=ru(e,r,a),_=jl(e),m={},y=e.attributes.length,S=0;S<y;S++){var T=e.attributes[S];m[T.name]=ui(t,_,T.name,T.value)}if(_==="link"&&i){var w=Array.from(t.styleSheets).find(function(de){return de.href===e.href}),k=null;w&&(k=Tr(w)),k&&(delete m.rel,delete m.href,m._cssText=xn(k,w.href))}if(_==="style"&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){var k=Tr(e.sheet);k&&(m._cssText=xn(k,Or()))}if(_==="input"||_==="textarea"||_==="select"){var A=e.value,C=e.checked;m.type!=="radio"&&m.type!=="checkbox"&&m.type!=="submit"&&m.type!=="button"&&A?m.value=Lr({type:m.type,tagName:_,value:A,maskInputOptions:o,maskInputFn:l}):C&&(m.checked=C)}if(_==="option"&&(e.selected&&!o.select?m.selected=!0:delete m.selected),_==="canvas"&&d){if(e.__context==="2d")Hl(e)||(m.rr_dataURL=e.toDataURL(u.type,u.quality));else if(!("__context"in e)){var R=e.toDataURL(u.type,u.quality),ee=document.createElement("canvas");ee.width=e.width,ee.height=e.height;var ue=ee.toDataURL(u.type,u.quality);R!==ue&&(m.rr_dataURL=R)}}if(_==="img"&&h){At||(At=t.createElement("canvas"),li=At.getContext("2d"));var H=e,te=H.crossOrigin;H.crossOrigin="anonymous";var Se=function(){try{At.width=H.naturalWidth,At.height=H.naturalHeight,li.drawImage(H,0,0),m.rr_dataURL=At.toDataURL(u.type,u.quality)}catch(de){console.warn("Cannot inline img src=".concat(H.currentSrc,"! Error: ").concat(de))}te?m.crossOrigin=te:H.removeAttribute("crossorigin")};H.complete&&H.naturalWidth!==0?Se():H.onload=Se}if((_==="audio"||_==="video")&&(m.rr_mediaState=e.paused?"paused":"played",m.rr_mediaCurrentTime=e.currentTime),v||(e.scrollLeft&&(m.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(m.rr_scrollTop=e.scrollTop)),I){var Ge=e.getBoundingClientRect(),Ne=Ge.width,Ae=Ge.height;m={class:m.class,rr_width:"".concat(Ne,"px"),rr_height:"".concat(Ae,"px")}}return _==="iframe"&&!f(m.src)&&(e.contentDocument||(m.rr_src=m.src),delete m.src),{type:J.Element,tagName:_,attributes:m,childNodes:[],isSVG:nu(e)||void 0,needBlock:I,rootId:g}}function P(e){return e===void 0?"":e.toLowerCase()}function uu(e,n){if(n.comment&&e.type===J.Comment)return!0;if(e.type===J.Element){if(n.script&&(e.tagName==="script"||e.tagName==="link"&&(e.attributes.rel==="preload"||e.attributes.rel==="modulepreload")&&e.attributes.as==="script"||e.tagName==="link"&&e.attributes.rel==="prefetch"&&typeof e.attributes.href=="string"&&e.attributes.href.endsWith(".js")))return!0;if(n.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(P(e.attributes.name).match(/^msapplication-tile(image|color)$/)||P(e.attributes.name)==="application-name"||P(e.attributes.rel)==="icon"||P(e.attributes.rel)==="apple-touch-icon"||P(e.attributes.rel)==="shortcut icon")))return!0;if(e.tagName==="meta"){if(n.headMetaDescKeywords&&P(e.attributes.name).match(/^description|keywords$/))return!0;if(n.headMetaSocial&&(P(e.attributes.property).match(/^(og|twitter|fb):/)||P(e.attributes.name).match(/^(og|twitter):/)||P(e.attributes.name)==="pinterest"))return!0;if(n.headMetaRobots&&(P(e.attributes.name)==="robots"||P(e.attributes.name)==="googlebot"||P(e.attributes.name)==="bingbot"))return!0;if(n.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return!0;if(n.headMetaAuthorship&&(P(e.attributes.name)==="author"||P(e.attributes.name)==="generator"||P(e.attributes.name)==="framework"||P(e.attributes.name)==="publisher"||P(e.attributes.name)==="progid"||P(e.attributes.property).match(/^article:/)||P(e.attributes.property).match(/^product:/)))return!0;if(n.headMetaVerification&&(P(e.attributes.name)==="google-site-verification"||P(e.attributes.name)==="yandex-verification"||P(e.attributes.name)==="csrf-token"||P(e.attributes.name)==="p:domain_verify"||P(e.attributes.name)==="verify-v1"||P(e.attributes.name)==="verification"||P(e.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function kt(e,n){var t=n.doc,r=n.mirror,a=n.blockClass,i=n.blockSelector,s=n.maskTextClass,o=n.maskTextSelector,l=n.skipChild,c=l===void 0?!1:l,u=n.inlineStylesheet,h=u===void 0?!0:u,d=n.maskInputOptions,f=d===void 0?{}:d,p=n.maskTextFn,v=n.maskInputFn,g=n.slimDOMOptions,I=n.dataURLOptions,_=I===void 0?{}:I,m=n.inlineImages,y=m===void 0?!1:m,S=n.recordCanvas,T=S===void 0?!1:S,w=n.onSerialize,k=n.onIframeLoad,A=n.iframeLoadTimeout,C=A===void 0?5e3:A,R=n.onStylesheetLoad,ee=n.stylesheetLoadTimeout,ue=ee===void 0?5e3:ee,H=n.keepIframeSrcFn,te=H===void 0?function(){return!1}:H,Se=n.newlyAddedElement,Ge=Se===void 0?!1:Se,Ne=n.preserveWhiteSpace,Ae=Ne===void 0?!0:Ne,de=ou(e,{doc:t,mirror:r,blockClass:a,blockSelector:i,maskTextClass:s,maskTextSelector:o,inlineStylesheet:h,maskInputOptions:f,maskTextFn:p,maskInputFn:v,dataURLOptions:_,inlineImages:y,recordCanvas:T,keepIframeSrcFn:te,newlyAddedElement:Ge});if(!de)return console.warn(e,"not serialized"),null;var et;r.hasNode(e)?et=r.getId(e):uu(de,g)||!Ae&&de.type===J.Text&&!de.isStyle&&!de.textContent.replace(/^\s+|\s+$/gm,"").length?et=Xt:et=ci();var Y=Object.assign(de,{id:et});if(r.add(e,Y),et===Xt)return null;w&&w(e);var _n=!c;if(Y.type===J.Element){_n=_n&&!Y.needBlock,delete Y.needBlock;var De=e.shadowRoot;De&&Gt(De)&&(Y.isShadowHost=!0)}if((Y.type===J.Document||Y.type===J.Element)&&_n){g.headWhitespace&&Y.type===J.Element&&Y.tagName==="head"&&(Ae=!1);for(var Fe={doc:t,mirror:r,blockClass:a,blockSelector:i,maskTextClass:s,maskTextSelector:o,skipChild:c,inlineStylesheet:h,maskInputOptions:f,maskTextFn:p,maskInputFn:v,slimDOMOptions:g,dataURLOptions:_,inlineImages:y,recordCanvas:T,preserveWhiteSpace:Ae,onSerialize:w,onIframeLoad:k,iframeLoadTimeout:C,onStylesheetLoad:R,stylesheetLoadTimeout:ue,keepIframeSrcFn:te},tt=0,O=Array.from(e.childNodes);tt<O.length;tt++){var fe=O[tt],W=kt(fe,Fe);W&&Y.childNodes.push(W)}if(zl(e)&&e.shadowRoot)for(var Q=0,Ze=Array.from(e.shadowRoot.childNodes);Q<Ze.length;Q++){var fe=Ze[Q],W=kt(fe,Fe);W&&(Gt(e.shadowRoot)&&(W.isShadow=!0),Y.childNodes.push(W))}}return e.parentNode&&Ht(e.parentNode)&&Gt(e.parentNode)&&(Y.isShadow=!0),Y.type===J.Element&&Y.tagName==="iframe"&&au(e,function(){var V=e.contentDocument;if(V&&k){var Wt=kt(V,{doc:V,mirror:r,blockClass:a,blockSelector:i,maskTextClass:s,maskTextSelector:o,skipChild:!1,inlineStylesheet:h,maskInputOptions:f,maskTextFn:p,maskInputFn:v,slimDOMOptions:g,dataURLOptions:_,inlineImages:y,recordCanvas:T,preserveWhiteSpace:Ae,onSerialize:w,onIframeLoad:k,iframeLoadTimeout:C,onStylesheetLoad:R,stylesheetLoadTimeout:ue,keepIframeSrcFn:te});Wt&&k(e,Wt)}},C),Y.type===J.Element&&Y.tagName==="link"&&Y.attributes.rel==="stylesheet"&&iu(e,function(){if(R){var V=kt(e,{doc:t,mirror:r,blockClass:a,blockSelector:i,maskTextClass:s,maskTextSelector:o,skipChild:!1,inlineStylesheet:h,maskInputOptions:f,maskTextFn:p,maskInputFn:v,slimDOMOptions:g,dataURLOptions:_,inlineImages:y,recordCanvas:T,preserveWhiteSpace:Ae,onSerialize:w,onIframeLoad:k,iframeLoadTimeout:C,onStylesheetLoad:R,stylesheetLoadTimeout:ue,keepIframeSrcFn:te});V&&R(e,V)}},ue),Y}function du(e,n){var t=n||{},r=t.mirror,a=r===void 0?new oi:r,i=t.blockClass,s=i===void 0?"rr-block":i,o=t.blockSelector,l=o===void 0?null:o,c=t.maskTextClass,u=c===void 0?"rr-mask":c,h=t.maskTextSelector,d=h===void 0?null:h,f=t.inlineStylesheet,p=f===void 0?!0:f,v=t.inlineImages,g=v===void 0?!1:v,I=t.recordCanvas,_=I===void 0?!1:I,m=t.maskAllInputs,y=m===void 0?!1:m,S=t.maskTextFn,T=t.maskInputFn,w=t.slimDOM,k=w===void 0?!1:w,A=t.dataURLOptions,C=t.preserveWhiteSpace,R=t.onSerialize,ee=t.onIframeLoad,ue=t.iframeLoadTimeout,H=t.onStylesheetLoad,te=t.stylesheetLoadTimeout,Se=t.keepIframeSrcFn,Ge=Se===void 0?function(){return!1}:Se,Ne=y===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:y===!1?{password:!0}:y,Ae=k===!0||k==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:k==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:k===!1?{}:k;return kt(e,{doc:e,mirror:a,blockClass:s,blockSelector:l,maskTextClass:u,maskTextSelector:d,skipChild:!1,inlineStylesheet:p,maskInputOptions:Ne,maskTextFn:S,maskInputFn:T,slimDOMOptions:Ae,dataURLOptions:A,inlineImages:g,recordCanvas:_,preserveWhiteSpace:C,onSerialize:R,onIframeLoad:ee,iframeLoadTimeout:ue,onStylesheetLoad:H,stylesheetLoadTimeout:te,keepIframeSrcFn:Ge,newlyAddedElement:!1})}function se(e,n){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:document;const r={capture:!0,passive:!0};return t.addEventListener(e,n,r),()=>t.removeEventListener(e,n,r)}const Rt=`Please stop import mirror directly. Instead of that,\r
now you can use replayer.getMirror() to access the mirror instance of a replayer,\r
or you can use record.mirror to access the mirror instance during recording.`;let fi={map:{},getId(){return console.error(Rt),-1},getNode(){return console.error(Rt),null},removeNodeFromMap(){console.error(Rt)},has(){return console.error(Rt),!1},reset(){console.error(Rt)}};typeof window<"u"&&window.Proxy&&window.Reflect&&(fi=new Proxy(fi,{get(e,n,t){return n==="map"&&console.error(Rt),Reflect.get(e,n,t)}}));function jt(e,n){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=null,a=0;return function(){for(var i=arguments.length,s=new Array(i),o=0;o<i;o++)s[o]=arguments[o];const l=Date.now();!a&&t.leading===!1&&(a=l);const c=n-(l-a),u=this;c<=0||c>n?(r&&(clearTimeout(r),r=null),a=l,e.apply(u,s)):!r&&t.trailing!==!1&&(r=setTimeout(()=>{a=t.leading===!1?0:Date.now(),r=null,e.apply(u,s)},c))}}function Ln(e,n,t,r){let a=arguments.length>4&&arguments[4]!==void 0?arguments[4]:window;const i=a.Object.getOwnPropertyDescriptor(e,n);return a.Object.defineProperty(e,n,r?t:{set(s){setTimeout(()=>{t.set.call(this,s)},0),i&&i.set&&i.set.call(this,s)}}),()=>Ln(e,n,i||{},!0)}function Yt(e,n,t){try{if(!(n in e))return()=>{};const r=e[n],a=t(r);return typeof a=="function"&&(a.prototype=a.prototype||{},Object.defineProperties(a,{__rrweb_original__:{enumerable:!1,value:r}})),e[n]=a,()=>{e[n]=r}}catch{return()=>{}}}function hi(e){var n,t,r,a,i,s;const o=e.document;return{left:o.scrollingElement?o.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:o?.documentElement.scrollLeft||((t=(n=o?.body)===null||n===void 0?void 0:n.parentElement)===null||t===void 0?void 0:t.scrollLeft)||((r=o?.body)===null||r===void 0?void 0:r.scrollLeft)||0,top:o.scrollingElement?o.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:o?.documentElement.scrollTop||((i=(a=o?.body)===null||a===void 0?void 0:a.parentElement)===null||i===void 0?void 0:i.scrollTop)||((s=o?.body)===null||s===void 0?void 0:s.scrollTop)||0}}function pi(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function gi(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function ce(e,n,t,r){if(!e)return!1;const a=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(!a)return!1;if(typeof n=="string"){if(a.classList.contains(n)||r&&a.closest("."+n)!==null)return!0}else if(Tn(a,n,r))return!0;return!!(t&&(a.matches(t)||r&&a.closest(t)!==null))}function fu(e,n){return n.getId(e)!==-1}function Mr(e,n){return n.getId(e)===Xt}function mi(e,n){if(Ht(e))return!1;const t=n.getId(e);return n.has(t)?e.parentNode&&e.parentNode.nodeType===e.DOCUMENT_NODE?!1:e.parentNode?mi(e.parentNode,n):!0:!0}function vi(e){return!!e.changedTouches}function hu(){var e=this;let n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window;"NodeList"in n&&!n.NodeList.prototype.forEach&&(n.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in n&&!n.DOMTokenList.prototype.forEach&&(n.DOMTokenList.prototype.forEach=Array.prototype.forEach),Node.prototype.contains||(Node.prototype.contains=function(){for(var t=arguments.length,r=new Array(t),a=0;a<t;a++)r[a]=arguments[a];let i=r[0];if(!(0 in r))throw new TypeError("1 argument is required");do if(e===i)return!0;while(i=i&&i.parentNode);return!1})}function bi(e,n){return!!(e.nodeName==="IFRAME"&&n.getMeta(e))}function yi(e,n){return!!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&n.getMeta(e))}function Nr(e){return!!e?.shadowRoot}class pu{constructor(){this.id=1,this.styleIDMap=new WeakMap,this.idStyleMap=new Map}getId(n){var t;return(t=this.styleIDMap.get(n))!==null&&t!==void 0?t:-1}has(n){return this.styleIDMap.has(n)}add(n,t){if(this.has(n))return this.getId(n);let r;return t===void 0?r=this.id++:r=t,this.styleIDMap.set(n,r),this.idStyleMap.set(r,n),r}getStyle(n){return this.idStyleMap.get(n)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}}function Ii(e){var n,t;let r=null;return((t=(n=e.getRootNode)===null||n===void 0?void 0:n.call(e))===null||t===void 0?void 0:t.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&e.getRootNode().host&&(r=e.getRootNode().host),r}function gu(e){let n=e,t;for(;t=Ii(n);)n=t;return n}function mu(e){const n=e.ownerDocument;if(!n)return!1;const t=gu(e);return n.contains(t)}function _i(e){const n=e.ownerDocument;return n?n.contains(e)||mu(e):!1}var F=(e=>(e[e.DomContentLoaded=0]="DomContentLoaded",e[e.Load=1]="Load",e[e.FullSnapshot=2]="FullSnapshot",e[e.IncrementalSnapshot=3]="IncrementalSnapshot",e[e.Meta=4]="Meta",e[e.Custom=5]="Custom",e[e.Plugin=6]="Plugin",e))(F||{}),D=(e=>(e[e.Mutation=0]="Mutation",e[e.MouseMove=1]="MouseMove",e[e.MouseInteraction=2]="MouseInteraction",e[e.Scroll=3]="Scroll",e[e.ViewportResize=4]="ViewportResize",e[e.Input=5]="Input",e[e.TouchMove=6]="TouchMove",e[e.MediaInteraction=7]="MediaInteraction",e[e.StyleSheetRule=8]="StyleSheetRule",e[e.CanvasMutation=9]="CanvasMutation",e[e.Font=10]="Font",e[e.Log=11]="Log",e[e.Drag=12]="Drag",e[e.StyleDeclaration=13]="StyleDeclaration",e[e.Selection=14]="Selection",e[e.AdoptedStyleSheet=15]="AdoptedStyleSheet",e))(D||{}),Dr=(e=>(e[e.MouseUp=0]="MouseUp",e[e.MouseDown=1]="MouseDown",e[e.Click=2]="Click",e[e.ContextMenu=3]="ContextMenu",e[e.DblClick=4]="DblClick",e[e.Focus=5]="Focus",e[e.Blur=6]="Blur",e[e.TouchStart=7]="TouchStart",e[e.TouchMove_Departed=8]="TouchMove_Departed",e[e.TouchEnd=9]="TouchEnd",e[e.TouchCancel=10]="TouchCancel",e))(Dr||{}),xt=(e=>(e[e["2D"]=0]="2D",e[e.WebGL=1]="WebGL",e[e.WebGL2=2]="WebGL2",e))(xt||{});function wi(e){return"__ln"in e}class vu{constructor(){this.length=0,this.head=null}get(n){if(n>=this.length)throw new Error("Position outside of list range");let t=this.head;for(let r=0;r<n;r++)t=t?.next||null;return t}addNode(n){const t={value:n,previous:null,next:null};if(n.__ln=t,n.previousSibling&&wi(n.previousSibling)){const r=n.previousSibling.__ln.next;t.next=r,t.previous=n.previousSibling.__ln,n.previousSibling.__ln.next=t,r&&(r.previous=t)}else if(n.nextSibling&&wi(n.nextSibling)&&n.nextSibling.__ln.previous){const r=n.nextSibling.__ln.previous;t.previous=r,t.next=n.nextSibling.__ln,n.nextSibling.__ln.previous=t,r&&(r.next=t)}else this.head&&(this.head.previous=t),t.next=this.head,this.head=t;this.length++}removeNode(n){const t=n.__ln;this.head&&(t.previous?(t.previous.next=t.next,t.next&&(t.next.previous=t.previous)):(this.head=t.next,this.head&&(this.head.previous=null)),n.__ln&&delete n.__ln,this.length--)}}const Ci=(e,n)=>`${e}@${n}`;class bu{constructor(){this.frozen=!1,this.locked=!1,this.texts=[],this.attributes=[],this.removes=[],this.mapRemoves=[],this.movedMap={},this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.processMutations=n=>{n.forEach(this.processMutation),this.emit()},this.emit=()=>{if(this.frozen||this.locked)return;const n=[],t=new vu,r=o=>{let l=o,c=Xt;for(;c===Xt;)l=l&&l.nextSibling,c=l&&this.mirror.getId(l);return c},a=o=>{if(!o.parentNode||!_i(o))return;const l=Ht(o.parentNode)?this.mirror.getId(Ii(o)):this.mirror.getId(o.parentNode),c=r(o);if(l===-1||c===-1)return t.addNode(o);const u=kt(o,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskTextClass:this.maskTextClass,maskTextSelector:this.maskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:h=>{bi(h,this.mirror)&&this.iframeManager.addIframe(h),yi(h,this.mirror)&&this.stylesheetManager.trackLinkElement(h),Nr(o)&&this.shadowDomManager.addShadowRoot(o.shadowRoot,this.doc)},onIframeLoad:(h,d)=>{this.iframeManager.attachIframe(h,d),this.shadowDomManager.observeAttachShadow(h)},onStylesheetLoad:(h,d)=>{this.stylesheetManager.attachLinkElement(h,d)}});u&&n.push({parentId:l,nextId:c,node:u})};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(const o of Array.from(this.movedSet.values()))Si(this.removes,o,this.mirror)&&!this.movedSet.has(o.parentNode)||a(o);for(const o of Array.from(this.addedSet.values()))!Ei(this.droppedSet,o)&&!Si(this.removes,o,this.mirror)||Ei(this.movedSet,o)?a(o):this.droppedSet.add(o);let i=null;for(;t.length;){let o=null;if(i){const l=this.mirror.getId(i.value.parentNode),c=r(i.value);l!==-1&&c!==-1&&(o=i)}if(!o)for(let l=t.length-1;l>=0;l--){const c=t.get(l);if(c){const u=this.mirror.getId(c.value.parentNode);if(r(c.value)===-1)continue;if(u!==-1){o=c;break}else{const d=c.value;if(d.parentNode&&d.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE){const f=d.parentNode.host;if(this.mirror.getId(f)!==-1){o=c;break}}}}}if(!o){for(;t.head;)t.removeNode(t.head.value);break}i=o.previous,t.removeNode(o.value),a(o.value)}const s={texts:this.texts.map(o=>({id:this.mirror.getId(o.node),value:o.value})).filter(o=>this.mirror.has(o.id)),attributes:this.attributes.map(o=>({id:this.mirror.getId(o.node),attributes:o.attributes})).filter(o=>this.mirror.has(o.id)),removes:this.removes,adds:n};!s.texts.length&&!s.attributes.length&&!s.removes.length&&!s.adds.length||(this.texts=[],this.attributes=[],this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.movedMap={},this.mutationCb(s))},this.processMutation=n=>{if(!Mr(n.target,this.mirror))switch(n.type){case"characterData":{const t=n.target.textContent;!ce(n.target,this.blockClass,this.blockSelector,!1)&&t!==n.oldValue&&this.texts.push({value:di(n.target,this.maskTextClass,this.maskTextSelector)&&t?this.maskTextFn?this.maskTextFn(t):t.replace(/[\S]/g,"*"):t,node:n.target});break}case"attributes":{const t=n.target;let r=n.target.getAttribute(n.attributeName);if(n.attributeName==="value"&&(r=Lr({maskInputOptions:this.maskInputOptions,tagName:n.target.tagName,type:n.target.getAttribute("type"),value:r,maskInputFn:this.maskInputFn})),ce(n.target,this.blockClass,this.blockSelector,!1)||r===n.oldValue)return;let a=this.attributes.find(i=>i.node===n.target);if(t.tagName==="IFRAME"&&n.attributeName==="src"&&!this.keepIframeSrcFn(r))if(!t.contentDocument)n.attributeName="rr_src";else return;if(a||(a={node:n.target,attributes:{}},this.attributes.push(a)),n.attributeName==="style"){const i=this.doc.createElement("span");n.oldValue&&i.setAttribute("style",n.oldValue),(a.attributes.style===void 0||a.attributes.style===null)&&(a.attributes.style={});const s=a.attributes.style;for(const o of Array.from(t.style)){const l=t.style.getPropertyValue(o),c=t.style.getPropertyPriority(o);(l!==i.style.getPropertyValue(o)||c!==i.style.getPropertyPriority(o))&&(c===""?s[o]=l:s[o]=[l,c])}for(const o of Array.from(i.style))t.style.getPropertyValue(o)===""&&(s[o]=!1)}else a.attributes[n.attributeName]=ui(this.doc,t.tagName,n.attributeName,r);break}case"childList":{if(ce(n.target,this.blockClass,this.blockSelector,!0))return;n.addedNodes.forEach(t=>this.genAdds(t,n.target)),n.removedNodes.forEach(t=>{const r=this.mirror.getId(t),a=Ht(n.target)?this.mirror.getId(n.target.host):this.mirror.getId(n.target);ce(n.target,this.blockClass,this.blockSelector,!1)||Mr(t,this.mirror)||!fu(t,this.mirror)||(this.addedSet.has(t)?(Fr(this.addedSet,t),this.droppedSet.add(t)):this.addedSet.has(n.target)&&r===-1||mi(n.target,this.mirror)||(this.movedSet.has(t)&&this.movedMap[Ci(r,a)]?Fr(this.movedSet,t):this.removes.push({parentId:a,id:r,isShadow:Ht(n.target)&&Gt(n.target)?!0:void 0})),this.mapRemoves.push(t))});break}}},this.genAdds=(n,t)=>{if(!this.processedNodeManager.inOtherBuffer(n,this)){if(this.mirror.hasNode(n)){if(Mr(n,this.mirror))return;this.movedSet.add(n);let r=null;t&&this.mirror.hasNode(t)&&(r=this.mirror.getId(t)),r&&r!==-1&&(this.movedMap[Ci(this.mirror.getId(n),r)]=!0)}else this.addedSet.add(n),this.droppedSet.delete(n);ce(n,this.blockClass,this.blockSelector,!1)||(n.childNodes.forEach(r=>this.genAdds(r)),Nr(n)&&n.shadowRoot.childNodes.forEach(r=>{this.processedNodeManager.add(r,this),this.genAdds(r,n)}))}}}init(n){["mutationCb","blockClass","blockSelector","maskTextClass","maskTextSelector","inlineStylesheet","maskInputOptions","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(t=>{this[t]=n[t]})}freeze(){this.frozen=!0,this.canvasManager.freeze()}unfreeze(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()}isFrozen(){return this.frozen}lock(){this.locked=!0,this.canvasManager.lock()}unlock(){this.locked=!1,this.canvasManager.unlock(),this.emit()}reset(){this.shadowDomManager.reset(),this.canvasManager.reset()}}function Fr(e,n){e.delete(n),n.childNodes.forEach(t=>Fr(e,t))}function Si(e,n,t){return e.length===0?!1:Ai(e,n,t)}function Ai(e,n,t){const{parentNode:r}=n;if(!r)return!1;const a=t.getId(r);return e.some(i=>i.id===a)?!0:Ai(e,r,t)}function Ei(e,n){return e.size===0?!1:ki(e,n)}function ki(e,n){const{parentNode:t}=n;return t?e.has(t)?!0:ki(e,t):!1}class yu{constructor(){this.nodeMap=new WeakMap,this.periodicallyClear()}periodicallyClear(){requestAnimationFrame(()=>{this.clear(),this.periodicallyClear()})}inOtherBuffer(n,t){const r=this.nodeMap.get(n);return r&&Array.from(r).some(a=>a!==t)}add(n,t){this.nodeMap.set(n,(this.nodeMap.get(n)||new Set).add(t))}clear(){this.nodeMap=new WeakMap}}const rt=[],Ri=new yu;function Kt(e){try{if("composedPath"in e){const n=e.composedPath();if(n.length)return n[0]}else if("path"in e&&e.path.length)return e.path[0];return e.target}catch{return e.target}}function xi(e,n){var t,r;const a=new bu;rt.push(a),a.init(e);let i=window.MutationObserver||window.__rrMutationObserver;const s=(r=(t=window?.Zone)===null||t===void 0?void 0:t.__symbol__)===null||r===void 0?void 0:r.call(t,"MutationObserver");s&&window[s]&&(i=window[s]);const o=new i(a.processMutations.bind(a));return o.observe(n,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),o}function Iu(e){let{mousemoveCb:n,sampling:t,doc:r,mirror:a}=e;if(t.mousemove===!1)return()=>{};const i=typeof t.mousemove=="number"?t.mousemove:50,s=typeof t.mousemoveCallback=="number"?t.mousemoveCallback:500;let o=[],l;const c=jt(d=>{const f=Date.now()-l;n(o.map(p=>(p.timeOffset-=f,p)),d),o=[],l=null},s),u=jt(d=>{const f=Kt(d),{clientX:p,clientY:v}=vi(d)?d.changedTouches[0]:d;l||(l=Date.now()),o.push({x:p,y:v,id:a.getId(f),timeOffset:Date.now()-l}),c(typeof DragEvent<"u"&&d instanceof DragEvent?D.Drag:d instanceof MouseEvent?D.MouseMove:D.TouchMove)},i,{trailing:!1}),h=[se("mousemove",u,r),se("touchmove",u,r),se("drag",u,r)];return()=>{h.forEach(d=>d())}}function _u(e){let{mouseInteractionCb:n,doc:t,mirror:r,blockClass:a,blockSelector:i,sampling:s}=e;if(s.mouseInteraction===!1)return()=>{};const o=s.mouseInteraction===!0||s.mouseInteraction===void 0?{}:s.mouseInteraction,l=[],c=u=>h=>{const d=Kt(h);if(ce(d,a,i,!0))return;const f=vi(h)?h.changedTouches[0]:h;if(!f)return;const p=r.getId(d),{clientX:v,clientY:g}=f;n({type:Dr[u],id:p,x:v,y:g})};return Object.keys(Dr).filter(u=>Number.isNaN(Number(u))&&!u.endsWith("_Departed")&&o[u]!==!1).forEach(u=>{const h=u.toLowerCase(),d=c(u);l.push(se(h,d,t))}),()=>{l.forEach(u=>u())}}function Ti(e){let{scrollCb:n,doc:t,mirror:r,blockClass:a,blockSelector:i,sampling:s}=e;const o=jt(l=>{const c=Kt(l);if(!c||ce(c,a,i,!0))return;const u=r.getId(c);if(c===t&&t.defaultView){const h=hi(t.defaultView);n({id:u,x:h.left,y:h.top})}else n({id:u,x:c.scrollLeft,y:c.scrollTop})},s.scroll||100);return se("scroll",o,t)}function wu(e){let{viewportResizeCb:n}=e,t=-1,r=-1;const a=jt(()=>{const i=pi(),s=gi();(t!==i||r!==s)&&(n({width:Number(s),height:Number(i)}),t=i,r=s)},200);return se("resize",a,window)}function Li(e,n){const t=Object.assign({},e);return n||delete t.userTriggered,t}const Cu=["INPUT","TEXTAREA","SELECT"],Oi=new WeakMap;function Su(e){let{inputCb:n,doc:t,mirror:r,blockClass:a,blockSelector:i,ignoreClass:s,maskInputOptions:o,maskInputFn:l,sampling:c,userTriggeredOnInput:u}=e;function h(_){let m=Kt(_);const y=_.isTrusted;if(m&&m.tagName==="OPTION"&&(m=m.parentElement),!m||!m.tagName||Cu.indexOf(m.tagName)<0||ce(m,a,i,!0))return;const S=m.type;if(m.classList.contains(s))return;let T=m.value,w=!1;S==="radio"||S==="checkbox"?w=m.checked:(o[m.tagName.toLowerCase()]||o[S])&&(T=Lr({maskInputOptions:o,tagName:m.tagName,type:S,value:T,maskInputFn:l})),d(m,Li({text:T,isChecked:w,userTriggered:y},u));const k=m.name;S==="radio"&&k&&w&&t.querySelectorAll(`input[type="radio"][name="${k}"]`).forEach(A=>{A!==m&&d(A,Li({text:A.value,isChecked:!w,userTriggered:!1},u))})}function d(_,m){const y=Oi.get(_);if(!y||y.text!==m.text||y.isChecked!==m.isChecked){Oi.set(_,m);const S=r.getId(_);n(Object.assign(Object.assign({},m),{id:S}))}}const p=(c.input==="last"?["change"]:["input","change"]).map(_=>se(_,h,t)),v=t.defaultView;if(!v)return()=>{p.forEach(_=>_())};const g=v.Object.getOwnPropertyDescriptor(v.HTMLInputElement.prototype,"value"),I=[[v.HTMLInputElement.prototype,"value"],[v.HTMLInputElement.prototype,"checked"],[v.HTMLSelectElement.prototype,"value"],[v.HTMLTextAreaElement.prototype,"value"],[v.HTMLSelectElement.prototype,"selectedIndex"],[v.HTMLOptionElement.prototype,"selected"]];return g&&g.set&&p.push(...I.map(_=>Ln(_[0],_[1],{set(){h({target:this})}},!1,v))),()=>{p.forEach(_=>_())}}function On(e){const n=[];function t(r,a){if(Mn("CSSGroupingRule")&&r.parentRule instanceof CSSGroupingRule||Mn("CSSMediaRule")&&r.parentRule instanceof CSSMediaRule||Mn("CSSSupportsRule")&&r.parentRule instanceof CSSSupportsRule||Mn("CSSConditionRule")&&r.parentRule instanceof CSSConditionRule){const s=Array.from(r.parentRule.cssRules).indexOf(r);a.unshift(s)}else if(r.parentStyleSheet){const s=Array.from(r.parentStyleSheet.cssRules).indexOf(r);a.unshift(s)}return a}return t(e,n)}function Ye(e,n,t){let r,a;return e?(e.ownerNode?r=n.getId(e.ownerNode):a=t.getId(e),{styleId:a,id:r}):{}}function Au(e,n){let{styleSheetRuleCb:t,mirror:r,stylesheetManager:a}=e,{win:i}=n;if(!i.CSSStyleSheet||!i.CSSStyleSheet.prototype)return()=>{};const s=i.CSSStyleSheet.prototype.insertRule;i.CSSStyleSheet.prototype.insertRule=function(d,f){const{id:p,styleId:v}=Ye(this,r,a.styleMirror);return(p&&p!==-1||v&&v!==-1)&&t({id:p,styleId:v,adds:[{rule:d,index:f}]}),s.apply(this,[d,f])};const o=i.CSSStyleSheet.prototype.deleteRule;i.CSSStyleSheet.prototype.deleteRule=function(d){const{id:f,styleId:p}=Ye(this,r,a.styleMirror);return(f&&f!==-1||p&&p!==-1)&&t({id:f,styleId:p,removes:[{index:d}]}),o.apply(this,[d])};let l;i.CSSStyleSheet.prototype.replace&&(l=i.CSSStyleSheet.prototype.replace,i.CSSStyleSheet.prototype.replace=function(d){const{id:f,styleId:p}=Ye(this,r,a.styleMirror);return(f&&f!==-1||p&&p!==-1)&&t({id:f,styleId:p,replace:d}),l.apply(this,[d])});let c;i.CSSStyleSheet.prototype.replaceSync&&(c=i.CSSStyleSheet.prototype.replaceSync,i.CSSStyleSheet.prototype.replaceSync=function(d){const{id:f,styleId:p}=Ye(this,r,a.styleMirror);return(f&&f!==-1||p&&p!==-1)&&t({id:f,styleId:p,replaceSync:d}),c.apply(this,[d])});const u={};Nn("CSSGroupingRule")?u.CSSGroupingRule=i.CSSGroupingRule:(Nn("CSSMediaRule")&&(u.CSSMediaRule=i.CSSMediaRule),Nn("CSSConditionRule")&&(u.CSSConditionRule=i.CSSConditionRule),Nn("CSSSupportsRule")&&(u.CSSSupportsRule=i.CSSSupportsRule));const h={};return Object.entries(u).forEach(d=>{let[f,p]=d;h[f]={insertRule:p.prototype.insertRule,deleteRule:p.prototype.deleteRule},p.prototype.insertRule=function(v,g){const{id:I,styleId:_}=Ye(this.parentStyleSheet,r,a.styleMirror);return(I&&I!==-1||_&&_!==-1)&&t({id:I,styleId:_,adds:[{rule:v,index:[...On(this),g||0]}]}),h[f].insertRule.apply(this,[v,g])},p.prototype.deleteRule=function(v){const{id:g,styleId:I}=Ye(this.parentStyleSheet,r,a.styleMirror);return(g&&g!==-1||I&&I!==-1)&&t({id:g,styleId:I,removes:[{index:[...On(this),v]}]}),h[f].deleteRule.apply(this,[v])}}),()=>{i.CSSStyleSheet.prototype.insertRule=s,i.CSSStyleSheet.prototype.deleteRule=o,l&&(i.CSSStyleSheet.prototype.replace=l),c&&(i.CSSStyleSheet.prototype.replaceSync=c),Object.entries(u).forEach(d=>{let[f,p]=d;p.prototype.insertRule=h[f].insertRule,p.prototype.deleteRule=h[f].deleteRule})}}function Mi(e,n){let{mirror:t,stylesheetManager:r}=e;var a,i,s;let o=null;n.nodeName==="#document"?o=t.getId(n):o=t.getId(n.host);const l=n.nodeName==="#document"?(a=n.defaultView)===null||a===void 0?void 0:a.Document:(s=(i=n.ownerDocument)===null||i===void 0?void 0:i.defaultView)===null||s===void 0?void 0:s.ShadowRoot,c=Object.getOwnPropertyDescriptor(l?.prototype,"adoptedStyleSheets");return o===null||o===-1||!l||!c?()=>{}:(Object.defineProperty(n,"adoptedStyleSheets",{configurable:c.configurable,enumerable:c.enumerable,get(){var u;return(u=c.get)===null||u===void 0?void 0:u.call(this)},set(u){var h;const d=(h=c.set)===null||h===void 0?void 0:h.call(this,u);if(o!==null&&o!==-1)try{r.adoptStyleSheets(u,o)}catch{}return d}}),()=>{Object.defineProperty(n,"adoptedStyleSheets",{configurable:c.configurable,enumerable:c.enumerable,get:c.get,set:c.set})})}function Eu(e,n){let{styleDeclarationCb:t,mirror:r,ignoreCSSAttributes:a,stylesheetManager:i}=e,{win:s}=n;const o=s.CSSStyleDeclaration.prototype.setProperty;s.CSSStyleDeclaration.prototype.setProperty=function(c,u,h){var d;if(a.has(c))return o.apply(this,[c,u,h]);const{id:f,styleId:p}=Ye((d=this.parentRule)===null||d===void 0?void 0:d.parentStyleSheet,r,i.styleMirror);return(f&&f!==-1||p&&p!==-1)&&t({id:f,styleId:p,set:{property:c,value:u,priority:h},index:On(this.parentRule)}),o.apply(this,[c,u,h])};const l=s.CSSStyleDeclaration.prototype.removeProperty;return s.CSSStyleDeclaration.prototype.removeProperty=function(c){var u;if(a.has(c))return l.apply(this,[c]);const{id:h,styleId:d}=Ye((u=this.parentRule)===null||u===void 0?void 0:u.parentStyleSheet,r,i.styleMirror);return(h&&h!==-1||d&&d!==-1)&&t({id:h,styleId:d,remove:{property:c},index:On(this.parentRule)}),l.apply(this,[c])},()=>{s.CSSStyleDeclaration.prototype.setProperty=o,s.CSSStyleDeclaration.prototype.removeProperty=l}}function ku(e){let{mediaInteractionCb:n,blockClass:t,blockSelector:r,mirror:a,sampling:i}=e;const s=l=>jt(c=>{const u=Kt(c);if(!u||ce(u,t,r,!0))return;const{currentTime:h,volume:d,muted:f,playbackRate:p}=u;n({type:l,id:a.getId(u),currentTime:h,volume:d,muted:f,playbackRate:p})},i.media||500),o=[se("play",s(0)),se("pause",s(1)),se("seeked",s(2)),se("volumechange",s(3)),se("ratechange",s(4))];return()=>{o.forEach(l=>l())}}function Ru(e){let{fontCb:n,doc:t}=e;const r=t.defaultView;if(!r)return()=>{};const a=[],i=new WeakMap,s=r.FontFace;r.FontFace=function(c,u,h){const d=new s(c,u,h);return i.set(d,{family:c,buffer:typeof u!="string",descriptors:h,fontSource:typeof u=="string"?u:JSON.stringify(Array.from(new Uint8Array(u)))}),d};const o=Yt(t.fonts,"add",function(l){return function(c){return setTimeout(()=>{const u=i.get(c);u&&(n(u),i.delete(c))},0),l.apply(this,[c])}});return a.push(()=>{r.FontFace=s}),a.push(o),()=>{a.forEach(l=>l())}}function xu(e){const{doc:n,mirror:t,blockClass:r,blockSelector:a,selectionCb:i}=e;let s=!0;const o=()=>{const l=n.getSelection();if(!l||s&&l?.isCollapsed)return;s=l.isCollapsed||!1;const c=[],u=l.rangeCount||0;for(let h=0;h<u;h++){const d=l.getRangeAt(h),{startContainer:f,startOffset:p,endContainer:v,endOffset:g}=d;ce(f,r,a,!0)||ce(v,r,a,!0)||c.push({start:t.getId(f),startOffset:p,end:t.getId(v),endOffset:g})}i({ranges:c})};return o(),se("selectionchange",o)}function Tu(e,n){const{mutationCb:t,mousemoveCb:r,mouseInteractionCb:a,scrollCb:i,viewportResizeCb:s,inputCb:o,mediaInteractionCb:l,styleSheetRuleCb:c,styleDeclarationCb:u,canvasMutationCb:h,fontCb:d,selectionCb:f}=e;e.mutationCb=function(){n.mutation&&n.mutation(...arguments),t(...arguments)},e.mousemoveCb=function(){n.mousemove&&n.mousemove(...arguments),r(...arguments)},e.mouseInteractionCb=function(){n.mouseInteraction&&n.mouseInteraction(...arguments),a(...arguments)},e.scrollCb=function(){n.scroll&&n.scroll(...arguments),i(...arguments)},e.viewportResizeCb=function(){n.viewportResize&&n.viewportResize(...arguments),s(...arguments)},e.inputCb=function(){n.input&&n.input(...arguments),o(...arguments)},e.mediaInteractionCb=function(){n.mediaInteaction&&n.mediaInteaction(...arguments),l(...arguments)},e.styleSheetRuleCb=function(){n.styleSheetRule&&n.styleSheetRule(...arguments),c(...arguments)},e.styleDeclarationCb=function(){n.styleDeclaration&&n.styleDeclaration(...arguments),u(...arguments)},e.canvasMutationCb=function(){n.canvasMutation&&n.canvasMutation(...arguments),h(...arguments)},e.fontCb=function(){n.font&&n.font(...arguments),d(...arguments)},e.selectionCb=function(){n.selection&&n.selection(...arguments),f(...arguments)}}function Lu(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const t=e.doc.defaultView;if(!t)return()=>{};Tu(e,n);const r=xi(e,e.doc),a=Iu(e),i=_u(e),s=Ti(e),o=wu(e),l=Su(e),c=ku(e),u=Au(e,{win:t}),h=Mi(e,e.doc),d=Eu(e,{win:t}),f=e.collectFonts?Ru(e):()=>{},p=xu(e),v=[];for(const g of e.plugins)v.push(g.observer(g.callback,t,g.options));return()=>{rt.forEach(g=>g.reset()),r.disconnect(),a(),i(),s(),o(),l(),c(),u(),h(),d(),f(),p(),v.forEach(g=>g())}}function Mn(e){return typeof window[e]<"u"}function Nn(e){return!!(typeof window[e]<"u"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class Ni{constructor(n){this.generateIdFn=n,this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap}getId(n,t,r,a){const i=r||this.getIdToRemoteIdMap(n),s=a||this.getRemoteIdToIdMap(n);let o=i.get(t);return o||(o=this.generateIdFn(),i.set(t,o),s.set(o,t)),o}getIds(n,t){const r=this.getIdToRemoteIdMap(n),a=this.getRemoteIdToIdMap(n);return t.map(i=>this.getId(n,i,r,a))}getRemoteId(n,t,r){const a=r||this.getRemoteIdToIdMap(n);if(typeof t!="number")return t;const i=a.get(t);return i||-1}getRemoteIds(n,t){const r=this.getRemoteIdToIdMap(n);return t.map(a=>this.getRemoteId(n,a,r))}reset(n){if(!n){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(n),this.iframeRemoteIdToIdMap.delete(n)}getIdToRemoteIdMap(n){let t=this.iframeIdToRemoteIdMap.get(n);return t||(t=new Map,this.iframeIdToRemoteIdMap.set(n,t)),t}getRemoteIdToIdMap(n){let t=this.iframeRemoteIdToIdMap.get(n);return t||(t=new Map,this.iframeRemoteIdToIdMap.set(n,t)),t}}class Ou{constructor(n){this.iframes=new WeakMap,this.crossOriginIframeMap=new WeakMap,this.crossOriginIframeMirror=new Ni(ci),this.crossOriginIframeRootIdMap=new WeakMap,this.mutationCb=n.mutationCb,this.wrappedEmit=n.wrappedEmit,this.stylesheetManager=n.stylesheetManager,this.recordCrossOriginIframes=n.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new Ni(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=n.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}addIframe(n){this.iframes.set(n,!0),n.contentWindow&&this.crossOriginIframeMap.set(n.contentWindow,n)}addLoadListener(n){this.loadListener=n}attachIframe(n,t){var r;this.mutationCb({adds:[{parentId:this.mirror.getId(n),nextId:null,node:t}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),(r=this.loadListener)===null||r===void 0||r.call(this,n),n.contentDocument&&n.contentDocument.adoptedStyleSheets&&n.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(n.contentDocument.adoptedStyleSheets,this.mirror.getId(n.contentDocument))}handleMessage(n){const t=n;if(t.data.type!=="rrweb"||t.origin!==t.data.origin||!n.source)return;const a=this.crossOriginIframeMap.get(n.source);if(!a)return;const i=this.transformCrossOriginEvent(a,t.data.event);i&&this.wrappedEmit(i,t.data.isCheckout)}transformCrossOriginEvent(n,t){var r;switch(t.type){case F.FullSnapshot:{this.crossOriginIframeMirror.reset(n),this.crossOriginIframeStyleMirror.reset(n),this.replaceIdOnNode(t.data.node,n);const a=t.data.node.id;return this.crossOriginIframeRootIdMap.set(n,a),this.patchRootIdOnNode(t.data.node,a),{timestamp:t.timestamp,type:F.IncrementalSnapshot,data:{source:D.Mutation,adds:[{parentId:this.mirror.getId(n),nextId:null,node:t.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case F.Meta:case F.Load:case F.DomContentLoaded:return!1;case F.Plugin:return t;case F.Custom:return this.replaceIds(t.data.payload,n,["id","parentId","previousId","nextId"]),t;case F.IncrementalSnapshot:switch(t.data.source){case D.Mutation:return t.data.adds.forEach(a=>{this.replaceIds(a,n,["parentId","nextId","previousId"]),this.replaceIdOnNode(a.node,n);const i=this.crossOriginIframeRootIdMap.get(n);i&&this.patchRootIdOnNode(a.node,i)}),t.data.removes.forEach(a=>{this.replaceIds(a,n,["parentId","id"])}),t.data.attributes.forEach(a=>{this.replaceIds(a,n,["id"])}),t.data.texts.forEach(a=>{this.replaceIds(a,n,["id"])}),t;case D.Drag:case D.TouchMove:case D.MouseMove:return t.data.positions.forEach(a=>{this.replaceIds(a,n,["id"])}),t;case D.ViewportResize:return!1;case D.MediaInteraction:case D.MouseInteraction:case D.Scroll:case D.CanvasMutation:case D.Input:return this.replaceIds(t.data,n,["id"]),t;case D.StyleSheetRule:case D.StyleDeclaration:return this.replaceIds(t.data,n,["id"]),this.replaceStyleIds(t.data,n,["styleId"]),t;case D.Font:return t;case D.Selection:return t.data.ranges.forEach(a=>{this.replaceIds(a,n,["start","end"])}),t;case D.AdoptedStyleSheet:return this.replaceIds(t.data,n,["id"]),this.replaceStyleIds(t.data,n,["styleIds"]),(r=t.data.styles)===null||r===void 0||r.forEach(a=>{this.replaceStyleIds(a,n,["styleId"])}),t}}}replace(n,t,r,a){for(const i of a)!Array.isArray(t[i])&&typeof t[i]!="number"||(Array.isArray(t[i])?t[i]=n.getIds(r,t[i]):t[i]=n.getId(r,t[i]));return t}replaceIds(n,t,r){return this.replace(this.crossOriginIframeMirror,n,t,r)}replaceStyleIds(n,t,r){return this.replace(this.crossOriginIframeStyleMirror,n,t,r)}replaceIdOnNode(n,t){this.replaceIds(n,t,["id","rootId"]),"childNodes"in n&&n.childNodes.forEach(r=>{this.replaceIdOnNode(r,t)})}patchRootIdOnNode(n,t){n.type!==J.Document&&!n.rootId&&(n.rootId=t),"childNodes"in n&&n.childNodes.forEach(r=>{this.patchRootIdOnNode(r,t)})}}class Mu{constructor(n){this.shadowDoms=new WeakSet,this.restoreHandlers=[],this.mutationCb=n.mutationCb,this.scrollCb=n.scrollCb,this.bypassOptions=n.bypassOptions,this.mirror=n.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(n,t){if(!Gt(n)||this.shadowDoms.has(n))return;this.shadowDoms.add(n);const r=xi(Object.assign(Object.assign({},this.bypassOptions),{doc:t,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this}),n);this.restoreHandlers.push(()=>r.disconnect()),this.restoreHandlers.push(Ti(Object.assign(Object.assign({},this.bypassOptions),{scrollCb:this.scrollCb,doc:n,mirror:this.mirror}))),setTimeout(()=>{n.adoptedStyleSheets&&n.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(n.adoptedStyleSheets,this.mirror.getId(n.host)),this.restoreHandlers.push(Mi({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},n))},0)}observeAttachShadow(n){!n.contentWindow||!n.contentDocument||this.patchAttachShadow(n.contentWindow.Element,n.contentDocument)}patchAttachShadow(n,t){const r=this;this.restoreHandlers.push(Yt(n.prototype,"attachShadow",function(a){return function(i){const s=a.call(this,i);return this.shadowRoot&&_i(this)&&r.addShadowRoot(this.shadowRoot,t),s}}))}reset(){this.restoreHandlers.forEach(n=>{try{n()}catch{}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet}}/*! *****************************************************************************
    Copyright (c) Microsoft Corporation.

    Permission to use, copy, modify, and/or distribute this software for any
    purpose with or without fee is hereby granted.

    THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
    REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
    AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
    INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
    LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
    OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
    PERFORMANCE OF THIS SOFTWARE.
    ***************************************************************************** */function Nu(e,n){var t={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&n.indexOf(r)<0&&(t[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(t[r[a]]=e[r[a]]);return t}function Du(e,n,t,r){function a(i){return i instanceof t?i:new t(function(s){s(i)})}return new(t||(t=Promise))(function(i,s){function o(u){try{c(r.next(u))}catch(h){s(h)}}function l(u){try{c(r.throw(u))}catch(h){s(h)}}function c(u){u.done?i(u.value):a(u.value).then(o,l)}c((r=r.apply(e,n||[])).next())})}for(var Tt="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Fu=typeof Uint8Array>"u"?[]:new Uint8Array(256),Dn=0;Dn<Tt.length;Dn++)Fu[Tt.charCodeAt(Dn)]=Dn;var Zu=function(e){var n=new Uint8Array(e),t,r=n.length,a="";for(t=0;t<r;t+=3)a+=Tt[n[t]>>2],a+=Tt[(n[t]&3)<<4|n[t+1]>>4],a+=Tt[(n[t+1]&15)<<2|n[t+2]>>6],a+=Tt[n[t+2]&63];return r%3===2?a=a.substring(0,a.length-1)+"=":r%3===1&&(a=a.substring(0,a.length-2)+"=="),a};const Di=new Map;function Bu(e,n){let t=Di.get(e);return t||(t=new Map,Di.set(e,t)),t.has(n)||t.set(n,[]),t.get(n)}const Fi=(e,n,t)=>{if(!e||!(Bi(e,n)||typeof e=="object"))return;const r=e.constructor.name,a=Bu(t,r);let i=a.indexOf(e);return i===-1&&(i=a.length,a.push(e)),i};function Fn(e,n,t){if(e instanceof Array)return e.map(r=>Fn(r,n,t));if(e===null)return e;if(e instanceof Float32Array||e instanceof Float64Array||e instanceof Int32Array||e instanceof Uint32Array||e instanceof Uint8Array||e instanceof Uint16Array||e instanceof Int16Array||e instanceof Int8Array||e instanceof Uint8ClampedArray)return{rr_type:e.constructor.name,args:[Object.values(e)]};if(e instanceof ArrayBuffer){const r=e.constructor.name,a=Zu(e);return{rr_type:r,base64:a}}else{if(e instanceof DataView)return{rr_type:e.constructor.name,args:[Fn(e.buffer,n,t),e.byteOffset,e.byteLength]};if(e instanceof HTMLImageElement){const r=e.constructor.name,{src:a}=e;return{rr_type:r,src:a}}else if(e instanceof HTMLCanvasElement){const r="HTMLImageElement",a=e.toDataURL();return{rr_type:r,src:a}}else{if(e instanceof ImageData)return{rr_type:e.constructor.name,args:[Fn(e.data,n,t),e.width,e.height]};if(Bi(e,n)||typeof e=="object"){const r=e.constructor.name,a=Fi(e,n,t);return{rr_type:r,index:a}}}}return e}const Zi=(e,n,t)=>[...e].map(r=>Fn(r,n,t)),Bi=(e,n)=>!!["WebGLActiveInfo","WebGLBuffer","WebGLFramebuffer","WebGLProgram","WebGLRenderbuffer","WebGLShader","WebGLShaderPrecisionFormat","WebGLTexture","WebGLUniformLocation","WebGLVertexArrayObject","WebGLVertexArrayObjectOES"].filter(a=>typeof n[a]=="function").find(a=>e instanceof n[a]);function Uu(e,n,t,r){const a=[],i=Object.getOwnPropertyNames(n.CanvasRenderingContext2D.prototype);for(const s of i)try{if(typeof n.CanvasRenderingContext2D.prototype[s]!="function")continue;const o=Yt(n.CanvasRenderingContext2D.prototype,s,function(l){return function(){for(var c=arguments.length,u=new Array(c),h=0;h<c;h++)u[h]=arguments[h];return ce(this.canvas,t,r,!0)||setTimeout(()=>{const d=Zi([...u],n,this);e(this.canvas,{type:xt["2D"],property:s,args:d})},0),l.apply(this,u)}});a.push(o)}catch{const l=Ln(n.CanvasRenderingContext2D.prototype,s,{set(c){e(this.canvas,{type:xt["2D"],property:s,args:[c],setter:!0})}});a.push(l)}return()=>{a.forEach(s=>s())}}function Ui(e,n,t){const r=[];try{const a=Yt(e.HTMLCanvasElement.prototype,"getContext",function(i){return function(s){ce(this,n,t,!0)||"__context"in this||(this.__context=s);for(var o=arguments.length,l=new Array(o>1?o-1:0),c=1;c<o;c++)l[c-1]=arguments[c];return i.apply(this,[s,...l])}});r.push(a)}catch{console.error("failed to patch HTMLCanvasElement.prototype.getContext")}return()=>{r.forEach(a=>a())}}function zi(e,n,t,r,a,i,s){const o=[],l=Object.getOwnPropertyNames(e);for(const c of l)if(!["isContextLost","canvas","drawingBufferWidth","drawingBufferHeight"].includes(c))try{if(typeof e[c]!="function")continue;const u=Yt(e,c,function(h){return function(){for(var d=arguments.length,f=new Array(d),p=0;p<d;p++)f[p]=arguments[p];const v=h.apply(this,f);if(Fi(v,s,this),!ce(this.canvas,r,a,!0)){const g=Zi([...f],s,this),I={type:n,property:c,args:g};t(this.canvas,I)}return v}});o.push(u)}catch{const h=Ln(e,c,{set(d){t(this.canvas,{type:n,property:c,args:[d],setter:!0})}});o.push(h)}return o}function zu(e,n,t,r,a){const i=[];return i.push(...zi(n.WebGLRenderingContext.prototype,xt.WebGL,e,t,r,a,n)),typeof n.WebGL2RenderingContext<"u"&&i.push(...zi(n.WebGL2RenderingContext.prototype,xt.WebGL2,e,t,r,a,n)),()=>{i.forEach(s=>s())}}var Wi=null;try{var Wu=typeof module<"u"&&typeof module.require=="function"&&module.require("worker_threads")||typeof __non_webpack_require__=="function"&&__non_webpack_require__("worker_threads")||typeof require=="function"&&require("worker_threads");Wi=Wu.Worker}catch{}function Vu(e,n){return Buffer.from(e,"base64").toString(n?"utf16":"utf8")}function Pu(e,n,t){var r=n===void 0?null:n,a=t===void 0?!1:t,i=Vu(e,a),s=i.indexOf(`
`,10)+1,o=i.substring(s)+(r?"//# sourceMappingURL="+r:"");return function(c){return new Wi(o,Object.assign({},c,{eval:!0}))}}function Hu(e,n){var t=atob(e);if(n){for(var r=new Uint8Array(t.length),a=0,i=t.length;a<i;++a)r[a]=t.charCodeAt(a);return String.fromCharCode.apply(null,new Uint16Array(r.buffer))}return t}function Gu(e,n,t){var r=n===void 0?null:n,a=t===void 0?!1:t,i=Hu(e,a),s=i.indexOf(`
`,10)+1,o=i.substring(s)+(r?"//# sourceMappingURL="+r:""),l=new Blob([o],{type:"application/javascript"});return URL.createObjectURL(l)}function Xu(e,n,t){var r;return function(i){return r=r||Gu(e,n,t),new Worker(r,i)}}var ju=Object.prototype.toString.call(typeof process<"u"?process:0)==="[object process]";function Yu(){return ju}function Ku(e,n,t){return Yu()?Pu(e,n,t):Xu(e,n,t)}var Ju=Ku("Lyogcm9sbHVwLXBsdWdpbi13ZWItd29ya2VyLWxvYWRlciAqLwooZnVuY3Rpb24gKCkgewogICAgJ3VzZSBzdHJpY3QnOwoKICAgIC8qISAqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKg0KICAgIENvcHlyaWdodCAoYykgTWljcm9zb2Z0IENvcnBvcmF0aW9uLg0KDQogICAgUGVybWlzc2lvbiB0byB1c2UsIGNvcHksIG1vZGlmeSwgYW5kL29yIGRpc3RyaWJ1dGUgdGhpcyBzb2Z0d2FyZSBmb3IgYW55DQogICAgcHVycG9zZSB3aXRoIG9yIHdpdGhvdXQgZmVlIGlzIGhlcmVieSBncmFudGVkLg0KDQogICAgVEhFIFNPRlRXQVJFIElTIFBST1ZJREVEICJBUyBJUyIgQU5EIFRIRSBBVVRIT1IgRElTQ0xBSU1TIEFMTCBXQVJSQU5USUVTIFdJVEgNCiAgICBSRUdBUkQgVE8gVEhJUyBTT0ZUV0FSRSBJTkNMVURJTkcgQUxMIElNUExJRUQgV0FSUkFOVElFUyBPRiBNRVJDSEFOVEFCSUxJVFkNCiAgICBBTkQgRklUTkVTUy4gSU4gTk8gRVZFTlQgU0hBTEwgVEhFIEFVVEhPUiBCRSBMSUFCTEUgRk9SIEFOWSBTUEVDSUFMLCBESVJFQ1QsDQogICAgSU5ESVJFQ1QsIE9SIENPTlNFUVVFTlRJQUwgREFNQUdFUyBPUiBBTlkgREFNQUdFUyBXSEFUU09FVkVSIFJFU1VMVElORyBGUk9NDQogICAgTE9TUyBPRiBVU0UsIERBVEEgT1IgUFJPRklUUywgV0hFVEhFUiBJTiBBTiBBQ1RJT04gT0YgQ09OVFJBQ1QsIE5FR0xJR0VOQ0UgT1INCiAgICBPVEhFUiBUT1JUSU9VUyBBQ1RJT04sIEFSSVNJTkcgT1VUIE9GIE9SIElOIENPTk5FQ1RJT04gV0lUSCBUSEUgVVNFIE9SDQogICAgUEVSRk9STUFOQ0UgT0YgVEhJUyBTT0ZUV0FSRS4NCiAgICAqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKiAqLw0KDQogICAgZnVuY3Rpb24gX19hd2FpdGVyKHRoaXNBcmcsIF9hcmd1bWVudHMsIFAsIGdlbmVyYXRvcikgew0KICAgICAgICBmdW5jdGlvbiBhZG9wdCh2YWx1ZSkgeyByZXR1cm4gdmFsdWUgaW5zdGFuY2VvZiBQID8gdmFsdWUgOiBuZXcgUChmdW5jdGlvbiAocmVzb2x2ZSkgeyByZXNvbHZlKHZhbHVlKTsgfSk7IH0NCiAgICAgICAgcmV0dXJuIG5ldyAoUCB8fCAoUCA9IFByb21pc2UpKShmdW5jdGlvbiAocmVzb2x2ZSwgcmVqZWN0KSB7DQogICAgICAgICAgICBmdW5jdGlvbiBmdWxmaWxsZWQodmFsdWUpIHsgdHJ5IHsgc3RlcChnZW5lcmF0b3IubmV4dCh2YWx1ZSkpOyB9IGNhdGNoIChlKSB7IHJlamVjdChlKTsgfSB9DQogICAgICAgICAgICBmdW5jdGlvbiByZWplY3RlZCh2YWx1ZSkgeyB0cnkgeyBzdGVwKGdlbmVyYXRvclsidGhyb3ciXSh2YWx1ZSkpOyB9IGNhdGNoIChlKSB7IHJlamVjdChlKTsgfSB9DQogICAgICAgICAgICBmdW5jdGlvbiBzdGVwKHJlc3VsdCkgeyByZXN1bHQuZG9uZSA/IHJlc29sdmUocmVzdWx0LnZhbHVlKSA6IGFkb3B0KHJlc3VsdC52YWx1ZSkudGhlbihmdWxmaWxsZWQsIHJlamVjdGVkKTsgfQ0KICAgICAgICAgICAgc3RlcCgoZ2VuZXJhdG9yID0gZ2VuZXJhdG9yLmFwcGx5KHRoaXNBcmcsIF9hcmd1bWVudHMgfHwgW10pKS5uZXh0KCkpOw0KICAgICAgICB9KTsNCiAgICB9CgogICAgLyoKICAgICAqIGJhc2U2NC1hcnJheWJ1ZmZlciAxLjAuMSA8aHR0cHM6Ly9naXRodWIuY29tL25pa2xhc3ZoL2Jhc2U2NC1hcnJheWJ1ZmZlcj4KICAgICAqIENvcHlyaWdodCAoYykgMjAyMSBOaWtsYXMgdm9uIEhlcnR6ZW4gPGh0dHBzOi8vaGVydHplbi5jb20+CiAgICAgKiBSZWxlYXNlZCB1bmRlciBNSVQgTGljZW5zZQogICAgICovCiAgICB2YXIgY2hhcnMgPSAnQUJDREVGR0hJSktMTU5PUFFSU1RVVldYWVphYmNkZWZnaGlqa2xtbm9wcXJzdHV2d3h5ejAxMjM0NTY3ODkrLyc7CiAgICAvLyBVc2UgYSBsb29rdXAgdGFibGUgdG8gZmluZCB0aGUgaW5kZXguCiAgICB2YXIgbG9va3VwID0gdHlwZW9mIFVpbnQ4QXJyYXkgPT09ICd1bmRlZmluZWQnID8gW10gOiBuZXcgVWludDhBcnJheSgyNTYpOwogICAgZm9yICh2YXIgaSA9IDA7IGkgPCBjaGFycy5sZW5ndGg7IGkrKykgewogICAgICAgIGxvb2t1cFtjaGFycy5jaGFyQ29kZUF0KGkpXSA9IGk7CiAgICB9CiAgICB2YXIgZW5jb2RlID0gZnVuY3Rpb24gKGFycmF5YnVmZmVyKSB7CiAgICAgICAgdmFyIGJ5dGVzID0gbmV3IFVpbnQ4QXJyYXkoYXJyYXlidWZmZXIpLCBpLCBsZW4gPSBieXRlcy5sZW5ndGgsIGJhc2U2NCA9ICcnOwogICAgICAgIGZvciAoaSA9IDA7IGkgPCBsZW47IGkgKz0gMykgewogICAgICAgICAgICBiYXNlNjQgKz0gY2hhcnNbYnl0ZXNbaV0gPj4gMl07CiAgICAgICAgICAgIGJhc2U2NCArPSBjaGFyc1soKGJ5dGVzW2ldICYgMykgPDwgNCkgfCAoYnl0ZXNbaSArIDFdID4+IDQpXTsKICAgICAgICAgICAgYmFzZTY0ICs9IGNoYXJzWygoYnl0ZXNbaSArIDFdICYgMTUpIDw8IDIpIHwgKGJ5dGVzW2kgKyAyXSA+PiA2KV07CiAgICAgICAgICAgIGJhc2U2NCArPSBjaGFyc1tieXRlc1tpICsgMl0gJiA2M107CiAgICAgICAgfQogICAgICAgIGlmIChsZW4gJSAzID09PSAyKSB7CiAgICAgICAgICAgIGJhc2U2NCA9IGJhc2U2NC5zdWJzdHJpbmcoMCwgYmFzZTY0Lmxlbmd0aCAtIDEpICsgJz0nOwogICAgICAgIH0KICAgICAgICBlbHNlIGlmIChsZW4gJSAzID09PSAxKSB7CiAgICAgICAgICAgIGJhc2U2NCA9IGJhc2U2NC5zdWJzdHJpbmcoMCwgYmFzZTY0Lmxlbmd0aCAtIDIpICsgJz09JzsKICAgICAgICB9CiAgICAgICAgcmV0dXJuIGJhc2U2NDsKICAgIH07CgogICAgY29uc3QgbGFzdEJsb2JNYXAgPSBuZXcgTWFwKCk7DQogICAgY29uc3QgdHJhbnNwYXJlbnRCbG9iTWFwID0gbmV3IE1hcCgpOw0KICAgIGZ1bmN0aW9uIGdldFRyYW5zcGFyZW50QmxvYkZvcih3aWR0aCwgaGVpZ2h0LCBkYXRhVVJMT3B0aW9ucykgew0KICAgICAgICByZXR1cm4gX19hd2FpdGVyKHRoaXMsIHZvaWQgMCwgdm9pZCAwLCBmdW5jdGlvbiogKCkgew0KICAgICAgICAgICAgY29uc3QgaWQgPSBgJHt3aWR0aH0tJHtoZWlnaHR9YDsNCiAgICAgICAgICAgIGlmICgnT2Zmc2NyZWVuQ2FudmFzJyBpbiBnbG9iYWxUaGlzKSB7DQogICAgICAgICAgICAgICAgaWYgKHRyYW5zcGFyZW50QmxvYk1hcC5oYXMoaWQpKQ0KICAgICAgICAgICAgICAgICAgICByZXR1cm4gdHJhbnNwYXJlbnRCbG9iTWFwLmdldChpZCk7DQogICAgICAgICAgICAgICAgY29uc3Qgb2Zmc2NyZWVuID0gbmV3IE9mZnNjcmVlbkNhbnZhcyh3aWR0aCwgaGVpZ2h0KTsNCiAgICAgICAgICAgICAgICBvZmZzY3JlZW4uZ2V0Q29udGV4dCgnMmQnKTsNCiAgICAgICAgICAgICAgICBjb25zdCBibG9iID0geWllbGQgb2Zmc2NyZWVuLmNvbnZlcnRUb0Jsb2IoZGF0YVVSTE9wdGlvbnMpOw0KICAgICAgICAgICAgICAgIGNvbnN0IGFycmF5QnVmZmVyID0geWllbGQgYmxvYi5hcnJheUJ1ZmZlcigpOw0KICAgICAgICAgICAgICAgIGNvbnN0IGJhc2U2NCA9IGVuY29kZShhcnJheUJ1ZmZlcik7DQogICAgICAgICAgICAgICAgdHJhbnNwYXJlbnRCbG9iTWFwLnNldChpZCwgYmFzZTY0KTsNCiAgICAgICAgICAgICAgICByZXR1cm4gYmFzZTY0Ow0KICAgICAgICAgICAgfQ0KICAgICAgICAgICAgZWxzZSB7DQogICAgICAgICAgICAgICAgcmV0dXJuICcnOw0KICAgICAgICAgICAgfQ0KICAgICAgICB9KTsNCiAgICB9DQogICAgY29uc3Qgd29ya2VyID0gc2VsZjsNCiAgICB3b3JrZXIub25tZXNzYWdlID0gZnVuY3Rpb24gKGUpIHsNCiAgICAgICAgcmV0dXJuIF9fYXdhaXRlcih0aGlzLCB2b2lkIDAsIHZvaWQgMCwgZnVuY3Rpb24qICgpIHsNCiAgICAgICAgICAgIGlmICgnT2Zmc2NyZWVuQ2FudmFzJyBpbiBnbG9iYWxUaGlzKSB7DQogICAgICAgICAgICAgICAgY29uc3QgeyBpZCwgYml0bWFwLCB3aWR0aCwgaGVpZ2h0LCBkYXRhVVJMT3B0aW9ucyB9ID0gZS5kYXRhOw0KICAgICAgICAgICAgICAgIGNvbnN0IHRyYW5zcGFyZW50QmFzZTY0ID0gZ2V0VHJhbnNwYXJlbnRCbG9iRm9yKHdpZHRoLCBoZWlnaHQsIGRhdGFVUkxPcHRpb25zKTsNCiAgICAgICAgICAgICAgICBjb25zdCBvZmZzY3JlZW4gPSBuZXcgT2Zmc2NyZWVuQ2FudmFzKHdpZHRoLCBoZWlnaHQpOw0KICAgICAgICAgICAgICAgIGNvbnN0IGN0eCA9IG9mZnNjcmVlbi5nZXRDb250ZXh0KCcyZCcpOw0KICAgICAgICAgICAgICAgIGN0eC5kcmF3SW1hZ2UoYml0bWFwLCAwLCAwKTsNCiAgICAgICAgICAgICAgICBiaXRtYXAuY2xvc2UoKTsNCiAgICAgICAgICAgICAgICBjb25zdCBibG9iID0geWllbGQgb2Zmc2NyZWVuLmNvbnZlcnRUb0Jsb2IoZGF0YVVSTE9wdGlvbnMpOw0KICAgICAgICAgICAgICAgIGNvbnN0IHR5cGUgPSBibG9iLnR5cGU7DQogICAgICAgICAgICAgICAgY29uc3QgYXJyYXlCdWZmZXIgPSB5aWVsZCBibG9iLmFycmF5QnVmZmVyKCk7DQogICAgICAgICAgICAgICAgY29uc3QgYmFzZTY0ID0gZW5jb2RlKGFycmF5QnVmZmVyKTsNCiAgICAgICAgICAgICAgICBpZiAoIWxhc3RCbG9iTWFwLmhhcyhpZCkgJiYgKHlpZWxkIHRyYW5zcGFyZW50QmFzZTY0KSA9PT0gYmFzZTY0KSB7DQogICAgICAgICAgICAgICAgICAgIGxhc3RCbG9iTWFwLnNldChpZCwgYmFzZTY0KTsNCiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHdvcmtlci5wb3N0TWVzc2FnZSh7IGlkIH0pOw0KICAgICAgICAgICAgICAgIH0NCiAgICAgICAgICAgICAgICBpZiAobGFzdEJsb2JNYXAuZ2V0KGlkKSA9PT0gYmFzZTY0KQ0KICAgICAgICAgICAgICAgICAgICByZXR1cm4gd29ya2VyLnBvc3RNZXNzYWdlKHsgaWQgfSk7DQogICAgICAgICAgICAgICAgd29ya2VyLnBvc3RNZXNzYWdlKHsNCiAgICAgICAgICAgICAgICAgICAgaWQsDQogICAgICAgICAgICAgICAgICAgIHR5cGUsDQogICAgICAgICAgICAgICAgICAgIGJhc2U2NCwNCiAgICAgICAgICAgICAgICAgICAgd2lkdGgsDQogICAgICAgICAgICAgICAgICAgIGhlaWdodCwNCiAgICAgICAgICAgICAgICB9KTsNCiAgICAgICAgICAgICAgICBsYXN0QmxvYk1hcC5zZXQoaWQsIGJhc2U2NCk7DQogICAgICAgICAgICB9DQogICAgICAgICAgICBlbHNlIHsNCiAgICAgICAgICAgICAgICByZXR1cm4gd29ya2VyLnBvc3RNZXNzYWdlKHsgaWQ6IGUuZGF0YS5pZCB9KTsNCiAgICAgICAgICAgIH0NCiAgICAgICAgfSk7DQogICAgfTsKCn0pKCk7Cgo=",null,!1);class qu{constructor(n){this.pendingCanvasMutations=new Map,this.rafStamps={latestId:0,invokeId:null},this.frozen=!1,this.locked=!1,this.processMutation=(l,c)=>{(this.rafStamps.invokeId&&this.rafStamps.latestId!==this.rafStamps.invokeId||!this.rafStamps.invokeId)&&(this.rafStamps.invokeId=this.rafStamps.latestId),this.pendingCanvasMutations.has(l)||this.pendingCanvasMutations.set(l,[]),this.pendingCanvasMutations.get(l).push(c)};const{sampling:t="all",win:r,blockClass:a,blockSelector:i,recordCanvas:s,dataURLOptions:o}=n;this.mutationCb=n.mutationCb,this.mirror=n.mirror,s&&t==="all"&&this.initCanvasMutationObserver(r,a,i),s&&typeof t=="number"&&this.initCanvasFPSObserver(t,r,a,i,{dataURLOptions:o})}reset(){this.pendingCanvasMutations.clear(),this.resetObservers&&this.resetObservers()}freeze(){this.frozen=!0}unfreeze(){this.frozen=!1}lock(){this.locked=!0}unlock(){this.locked=!1}initCanvasFPSObserver(n,t,r,a,i){const s=Ui(t,r,a),o=new Map,l=new Ju;l.onmessage=p=>{const{id:v}=p.data;if(o.set(v,!1),!("base64"in p.data))return;const{base64:g,type:I,width:_,height:m}=p.data;this.mutationCb({id:v,type:xt["2D"],commands:[{property:"clearRect",args:[0,0,_,m]},{property:"drawImage",args:[{rr_type:"ImageBitmap",args:[{rr_type:"Blob",data:[{rr_type:"ArrayBuffer",base64:g}],type:I}]},0,0]}]})};const c=1e3/n;let u=0,h;const d=()=>{const p=[];return t.document.querySelectorAll("canvas").forEach(v=>{ce(v,r,a,!0)||p.push(v)}),p},f=p=>{if(u&&p-u<c){h=requestAnimationFrame(f);return}u=p,d().forEach(v=>Du(this,void 0,void 0,function*(){var g;const I=this.mirror.getId(v);if(o.get(I))return;if(o.set(I,!0),["webgl","webgl2"].includes(v.__context)){const m=v.getContext(v.__context);((g=m?.getContextAttributes())===null||g===void 0?void 0:g.preserveDrawingBuffer)===!1&&m?.clear(m.COLOR_BUFFER_BIT)}const _=yield createImageBitmap(v);l.postMessage({id:I,bitmap:_,width:v.width,height:v.height,dataURLOptions:i.dataURLOptions},[_])})),h=requestAnimationFrame(f)};h=requestAnimationFrame(f),this.resetObservers=()=>{s(),cancelAnimationFrame(h)}}initCanvasMutationObserver(n,t,r){this.startRAFTimestamping(),this.startPendingCanvasMutationFlusher();const a=Ui(n,t,r),i=Uu(this.processMutation.bind(this),n,t,r),s=zu(this.processMutation.bind(this),n,t,r,this.mirror);this.resetObservers=()=>{a(),i(),s()}}startPendingCanvasMutationFlusher(){requestAnimationFrame(()=>this.flushPendingCanvasMutations())}startRAFTimestamping(){const n=t=>{this.rafStamps.latestId=t,requestAnimationFrame(n)};requestAnimationFrame(n)}flushPendingCanvasMutations(){this.pendingCanvasMutations.forEach((n,t)=>{const r=this.mirror.getId(t);this.flushPendingCanvasMutationFor(t,r)}),requestAnimationFrame(()=>this.flushPendingCanvasMutations())}flushPendingCanvasMutationFor(n,t){if(this.frozen||this.locked)return;const r=this.pendingCanvasMutations.get(n);if(!r||t===-1)return;const a=r.map(s=>Nu(s,["type"])),{type:i}=r[0];this.mutationCb({id:t,type:i,commands:a}),this.pendingCanvasMutations.delete(n)}}class Qu{constructor(n){this.trackedLinkElements=new WeakSet,this.styleMirror=new pu,this.mutationCb=n.mutationCb,this.adoptedStyleSheetCb=n.adoptedStyleSheetCb}attachLinkElement(n,t){"_cssText"in t.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:t.id,attributes:t.attributes}]}),this.trackLinkElement(n)}trackLinkElement(n){this.trackedLinkElements.has(n)||(this.trackedLinkElements.add(n),this.trackStylesheetInLinkElement(n))}adoptStyleSheets(n,t){if(n.length===0)return;const r={id:t,styleIds:[]},a=[];for(const i of n){let s;if(this.styleMirror.has(i))s=this.styleMirror.getId(i);else{s=this.styleMirror.add(i);const o=Array.from(i.rules||CSSRule);a.push({styleId:s,rules:o.map((l,c)=>({rule:ii(l),index:c}))})}r.styleIds.push(s)}a.length>0&&(r.styles=a),this.adoptedStyleSheetCb(r)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(n){}}function q(e){return Object.assign(Object.assign({},e),{timestamp:Date.now()})}let j,Zn,Zr,Bn=!1;const Re=Pl();function Jt(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const{emit:n,checkoutEveryNms:t,checkoutEveryNth:r,blockClass:a="rr-block",blockSelector:i=null,ignoreClass:s="rr-ignore",maskTextClass:o="rr-mask",maskTextSelector:l=null,inlineStylesheet:c=!0,maskAllInputs:u,maskInputOptions:h,slimDOMOptions:d,maskInputFn:f,maskTextFn:p,hooks:v,packFn:g,sampling:I={},dataURLOptions:_={},mousemoveWait:m,recordCanvas:y=!1,recordCrossOriginIframes:S=!1,recordAfter:T=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:w=!1,collectFonts:k=!1,inlineImages:A=!1,plugins:C,keepIframeSrcFn:R=()=>!1,ignoreCSSAttributes:ee=new Set([])}=e,ue=S?window.parent===window:!0;let H=!1;if(!ue)try{window.parent.document,H=!1}catch{H=!0}if(ue&&!n)throw new Error("emit function is required");m!==void 0&&I.mousemove===void 0&&(I.mousemove=m),Re.reset();const te=u===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:h!==void 0?h:{password:!0},Se=d===!0||d==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:d==="all",headMetaDescKeywords:d==="all"}:d||{};hu();let Ge,Ne=0;const Ae=O=>{for(const fe of C||[])fe.eventProcessor&&(O=fe.eventProcessor(O));return g&&!H&&(O=g(O)),O};j=(O,fe)=>{var W;if(!((W=rt[0])===null||W===void 0)&&W.isFrozen()&&O.type!==F.FullSnapshot&&!(O.type===F.IncrementalSnapshot&&O.data.source===D.Mutation)&&rt.forEach(Q=>Q.unfreeze()),ue)n?.(Ae(O),fe);else if(H){const Q={type:"rrweb",event:Ae(O),origin:window.location.origin,isCheckout:fe};window.parent.postMessage(Q,"*")}if(O.type===F.FullSnapshot)Ge=O,Ne=0;else if(O.type===F.IncrementalSnapshot){if(O.data.source===D.Mutation&&O.data.isAttachIframe)return;Ne++;const Q=r&&Ne>=r,Ze=t&&O.timestamp-Ge.timestamp>t;(Q||Ze)&&Zn(!0)}};const de=O=>{j(q({type:F.IncrementalSnapshot,data:Object.assign({source:D.Mutation},O)}))},et=O=>j(q({type:F.IncrementalSnapshot,data:Object.assign({source:D.Scroll},O)})),Y=O=>j(q({type:F.IncrementalSnapshot,data:Object.assign({source:D.CanvasMutation},O)})),_n=O=>j(q({type:F.IncrementalSnapshot,data:Object.assign({source:D.AdoptedStyleSheet},O)})),De=new Qu({mutationCb:de,adoptedStyleSheetCb:_n}),Fe=new Ou({mirror:Re,mutationCb:de,stylesheetManager:De,recordCrossOriginIframes:S,wrappedEmit:j});for(const O of C||[])O.getMirror&&O.getMirror({nodeMirror:Re,crossOriginIframeMirror:Fe.crossOriginIframeMirror,crossOriginIframeStyleMirror:Fe.crossOriginIframeStyleMirror});Zr=new qu({recordCanvas:y,mutationCb:Y,win:window,blockClass:a,blockSelector:i,mirror:Re,sampling:I.canvas,dataURLOptions:_});const tt=new Mu({mutationCb:de,scrollCb:et,bypassOptions:{blockClass:a,blockSelector:i,maskTextClass:o,maskTextSelector:l,inlineStylesheet:c,maskInputOptions:te,dataURLOptions:_,maskTextFn:p,maskInputFn:f,recordCanvas:y,inlineImages:A,sampling:I,slimDOMOptions:Se,iframeManager:Fe,stylesheetManager:De,canvasManager:Zr,keepIframeSrcFn:R,processedNodeManager:Ri},mirror:Re});Zn=function(){let O=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;j(q({type:F.Meta,data:{href:window.location.href,width:gi(),height:pi()}}),O),De.reset(),tt.init(),rt.forEach(W=>W.lock());const fe=du(document,{mirror:Re,blockClass:a,blockSelector:i,maskTextClass:o,maskTextSelector:l,inlineStylesheet:c,maskAllInputs:te,maskTextFn:p,slimDOM:Se,dataURLOptions:_,recordCanvas:y,inlineImages:A,onSerialize:W=>{bi(W,Re)&&Fe.addIframe(W),yi(W,Re)&&De.trackLinkElement(W),Nr(W)&&tt.addShadowRoot(W.shadowRoot,document)},onIframeLoad:(W,Q)=>{Fe.attachIframe(W,Q),tt.observeAttachShadow(W)},onStylesheetLoad:(W,Q)=>{De.attachLinkElement(W,Q)},keepIframeSrcFn:R});if(!fe)return console.warn("Failed to snapshot the document");j(q({type:F.FullSnapshot,data:{node:fe,initialOffset:hi(window)}})),rt.forEach(W=>W.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&De.adoptStyleSheets(document.adoptedStyleSheets,Re.getId(document))};try{const O=[],fe=Q=>{var Ze;return Lu({mutationCb:de,mousemoveCb:(V,Wt)=>j(q({type:F.IncrementalSnapshot,data:{source:Wt,positions:V}})),mouseInteractionCb:V=>j(q({type:F.IncrementalSnapshot,data:Object.assign({source:D.MouseInteraction},V)})),scrollCb:et,viewportResizeCb:V=>j(q({type:F.IncrementalSnapshot,data:Object.assign({source:D.ViewportResize},V)})),inputCb:V=>j(q({type:F.IncrementalSnapshot,data:Object.assign({source:D.Input},V)})),mediaInteractionCb:V=>j(q({type:F.IncrementalSnapshot,data:Object.assign({source:D.MediaInteraction},V)})),styleSheetRuleCb:V=>j(q({type:F.IncrementalSnapshot,data:Object.assign({source:D.StyleSheetRule},V)})),styleDeclarationCb:V=>j(q({type:F.IncrementalSnapshot,data:Object.assign({source:D.StyleDeclaration},V)})),canvasMutationCb:Y,fontCb:V=>j(q({type:F.IncrementalSnapshot,data:Object.assign({source:D.Font},V)})),selectionCb:V=>{j(q({type:F.IncrementalSnapshot,data:Object.assign({source:D.Selection},V)}))},blockClass:a,ignoreClass:s,maskTextClass:o,maskTextSelector:l,maskInputOptions:te,inlineStylesheet:c,sampling:I,recordCanvas:y,inlineImages:A,userTriggeredOnInput:w,collectFonts:k,doc:Q,maskInputFn:f,maskTextFn:p,keepIframeSrcFn:R,blockSelector:i,slimDOMOptions:Se,dataURLOptions:_,mirror:Re,iframeManager:Fe,stylesheetManager:De,shadowDomManager:tt,processedNodeManager:Ri,canvasManager:Zr,ignoreCSSAttributes:ee,plugins:((Ze=C?.filter(V=>V.observer))===null||Ze===void 0?void 0:Ze.map(V=>({observer:V.observer,options:V.options,callback:Wt=>j(q({type:F.Plugin,data:{plugin:V.name,payload:Wt}}))})))||[]},v)};Fe.addLoadListener(Q=>{try{O.push(fe(Q.contentDocument))}catch(Ze){console.warn(Ze)}});const W=()=>{Zn(),O.push(fe(document)),Bn=!0};return document.readyState==="interactive"||document.readyState==="complete"?W():(O.push(se("DOMContentLoaded",()=>{j(q({type:F.DomContentLoaded,data:{}})),T==="DOMContentLoaded"&&W()})),O.push(se("load",()=>{j(q({type:F.Load,data:{}})),T==="load"&&W()},window))),()=>{O.forEach(Q=>Q()),Bn=!1}}catch(O){console.warn(O)}}Jt.addCustomEvent=(e,n)=>{if(!Bn)throw new Error("please add custom event after start recording");j(q({type:F.Custom,data:{tag:e,payload:n}}))},Jt.freezePage=()=>{rt.forEach(e=>e.freeze())},Jt.takeFullSnapshot=e=>{if(!Bn)throw new Error("please take full snapshot after start recording");Zn(e)},Jt.mirror=Re;/*! pako 2.1.0 https://github.com/nodeca/pako @license (MIT AND Zlib) */const $u=4,Vi=0,Pi=1,ed=2;function Lt(e){let n=e.length;for(;--n>=0;)e[n]=0}const td=0,Hi=1,nd=2,rd=3,ad=258,Br=29,qt=256,Qt=qt+1+Br,Ot=30,Ur=19,Gi=2*Qt+1,at=15,zr=16,id=7,Wr=256,Xi=16,ji=17,Yi=18,Vr=new Uint8Array([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0]),Un=new Uint8Array([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13]),od=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7]),Ki=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),sd=512,We=new Array((Qt+2)*2);Lt(We);const $t=new Array(Ot*2);Lt($t);const en=new Array(sd);Lt(en);const tn=new Array(ad-rd+1);Lt(tn);const Pr=new Array(Br);Lt(Pr);const zn=new Array(Ot);Lt(zn);function Hr(e,n,t,r,a){this.static_tree=e,this.extra_bits=n,this.extra_base=t,this.elems=r,this.max_length=a,this.has_stree=e&&e.length}let Ji,qi,Qi;function Gr(e,n){this.dyn_tree=e,this.max_code=0,this.stat_desc=n}const $i=e=>e<256?en[e]:en[256+(e>>>7)],nn=(e,n)=>{e.pending_buf[e.pending++]=n&255,e.pending_buf[e.pending++]=n>>>8&255},ge=(e,n,t)=>{e.bi_valid>zr-t?(e.bi_buf|=n<<e.bi_valid&65535,nn(e,e.bi_buf),e.bi_buf=n>>zr-e.bi_valid,e.bi_valid+=t-zr):(e.bi_buf|=n<<e.bi_valid&65535,e.bi_valid+=t)},Te=(e,n,t)=>{ge(e,t[n*2],t[n*2+1])},eo=(e,n)=>{let t=0;do t|=e&1,e>>>=1,t<<=1;while(--n>0);return t>>>1},cd=e=>{e.bi_valid===16?(nn(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=e.bi_buf&255,e.bi_buf>>=8,e.bi_valid-=8)},ld=(e,n)=>{const t=n.dyn_tree,r=n.max_code,a=n.stat_desc.static_tree,i=n.stat_desc.has_stree,s=n.stat_desc.extra_bits,o=n.stat_desc.extra_base,l=n.stat_desc.max_length;let c,u,h,d,f,p,v=0;for(d=0;d<=at;d++)e.bl_count[d]=0;for(t[e.heap[e.heap_max]*2+1]=0,c=e.heap_max+1;c<Gi;c++)u=e.heap[c],d=t[t[u*2+1]*2+1]+1,d>l&&(d=l,v++),t[u*2+1]=d,!(u>r)&&(e.bl_count[d]++,f=0,u>=o&&(f=s[u-o]),p=t[u*2],e.opt_len+=p*(d+f),i&&(e.static_len+=p*(a[u*2+1]+f)));if(v!==0){do{for(d=l-1;e.bl_count[d]===0;)d--;e.bl_count[d]--,e.bl_count[d+1]+=2,e.bl_count[l]--,v-=2}while(v>0);for(d=l;d!==0;d--)for(u=e.bl_count[d];u!==0;)h=e.heap[--c],!(h>r)&&(t[h*2+1]!==d&&(e.opt_len+=(d-t[h*2+1])*t[h*2],t[h*2+1]=d),u--)}},to=(e,n,t)=>{const r=new Array(at+1);let a=0,i,s;for(i=1;i<=at;i++)a=a+t[i-1]<<1,r[i]=a;for(s=0;s<=n;s++){let o=e[s*2+1];o!==0&&(e[s*2]=eo(r[o]++,o))}},ud=()=>{let e,n,t,r,a;const i=new Array(at+1);for(t=0,r=0;r<Br-1;r++)for(Pr[r]=t,e=0;e<1<<Vr[r];e++)tn[t++]=r;for(tn[t-1]=r,a=0,r=0;r<16;r++)for(zn[r]=a,e=0;e<1<<Un[r];e++)en[a++]=r;for(a>>=7;r<Ot;r++)for(zn[r]=a<<7,e=0;e<1<<Un[r]-7;e++)en[256+a++]=r;for(n=0;n<=at;n++)i[n]=0;for(e=0;e<=143;)We[e*2+1]=8,e++,i[8]++;for(;e<=255;)We[e*2+1]=9,e++,i[9]++;for(;e<=279;)We[e*2+1]=7,e++,i[7]++;for(;e<=287;)We[e*2+1]=8,e++,i[8]++;for(to(We,Qt+1,i),e=0;e<Ot;e++)$t[e*2+1]=5,$t[e*2]=eo(e,5);Ji=new Hr(We,Vr,qt+1,Qt,at),qi=new Hr($t,Un,0,Ot,at),Qi=new Hr(new Array(0),od,0,Ur,id)},no=e=>{let n;for(n=0;n<Qt;n++)e.dyn_ltree[n*2]=0;for(n=0;n<Ot;n++)e.dyn_dtree[n*2]=0;for(n=0;n<Ur;n++)e.bl_tree[n*2]=0;e.dyn_ltree[Wr*2]=1,e.opt_len=e.static_len=0,e.sym_next=e.matches=0},ro=e=>{e.bi_valid>8?nn(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0},ao=(e,n,t,r)=>{const a=n*2,i=t*2;return e[a]<e[i]||e[a]===e[i]&&r[n]<=r[t]},Xr=(e,n,t)=>{const r=e.heap[t];let a=t<<1;for(;a<=e.heap_len&&(a<e.heap_len&&ao(n,e.heap[a+1],e.heap[a],e.depth)&&a++,!ao(n,r,e.heap[a],e.depth));)e.heap[t]=e.heap[a],t=a,a<<=1;e.heap[t]=r},io=(e,n,t)=>{let r,a,i=0,s,o;if(e.sym_next!==0)do r=e.pending_buf[e.sym_buf+i++]&255,r+=(e.pending_buf[e.sym_buf+i++]&255)<<8,a=e.pending_buf[e.sym_buf+i++],r===0?Te(e,a,n):(s=tn[a],Te(e,s+qt+1,n),o=Vr[s],o!==0&&(a-=Pr[s],ge(e,a,o)),r--,s=$i(r),Te(e,s,t),o=Un[s],o!==0&&(r-=zn[s],ge(e,r,o)));while(i<e.sym_next);Te(e,Wr,n)},jr=(e,n)=>{const t=n.dyn_tree,r=n.stat_desc.static_tree,a=n.stat_desc.has_stree,i=n.stat_desc.elems;let s,o,l=-1,c;for(e.heap_len=0,e.heap_max=Gi,s=0;s<i;s++)t[s*2]!==0?(e.heap[++e.heap_len]=l=s,e.depth[s]=0):t[s*2+1]=0;for(;e.heap_len<2;)c=e.heap[++e.heap_len]=l<2?++l:0,t[c*2]=1,e.depth[c]=0,e.opt_len--,a&&(e.static_len-=r[c*2+1]);for(n.max_code=l,s=e.heap_len>>1;s>=1;s--)Xr(e,t,s);c=i;do s=e.heap[1],e.heap[1]=e.heap[e.heap_len--],Xr(e,t,1),o=e.heap[1],e.heap[--e.heap_max]=s,e.heap[--e.heap_max]=o,t[c*2]=t[s*2]+t[o*2],e.depth[c]=(e.depth[s]>=e.depth[o]?e.depth[s]:e.depth[o])+1,t[s*2+1]=t[o*2+1]=c,e.heap[1]=c++,Xr(e,t,1);while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],ld(e,n),to(t,l,e.bl_count)},oo=(e,n,t)=>{let r,a=-1,i,s=n[0*2+1],o=0,l=7,c=4;for(s===0&&(l=138,c=3),n[(t+1)*2+1]=65535,r=0;r<=t;r++)i=s,s=n[(r+1)*2+1],!(++o<l&&i===s)&&(o<c?e.bl_tree[i*2]+=o:i!==0?(i!==a&&e.bl_tree[i*2]++,e.bl_tree[Xi*2]++):o<=10?e.bl_tree[ji*2]++:e.bl_tree[Yi*2]++,o=0,a=i,s===0?(l=138,c=3):i===s?(l=6,c=3):(l=7,c=4))},so=(e,n,t)=>{let r,a=-1,i,s=n[0*2+1],o=0,l=7,c=4;for(s===0&&(l=138,c=3),r=0;r<=t;r++)if(i=s,s=n[(r+1)*2+1],!(++o<l&&i===s)){if(o<c)do Te(e,i,e.bl_tree);while(--o!==0);else i!==0?(i!==a&&(Te(e,i,e.bl_tree),o--),Te(e,Xi,e.bl_tree),ge(e,o-3,2)):o<=10?(Te(e,ji,e.bl_tree),ge(e,o-3,3)):(Te(e,Yi,e.bl_tree),ge(e,o-11,7));o=0,a=i,s===0?(l=138,c=3):i===s?(l=6,c=3):(l=7,c=4)}},dd=e=>{let n;for(oo(e,e.dyn_ltree,e.l_desc.max_code),oo(e,e.dyn_dtree,e.d_desc.max_code),jr(e,e.bl_desc),n=Ur-1;n>=3&&e.bl_tree[Ki[n]*2+1]===0;n--);return e.opt_len+=3*(n+1)+5+5+4,n},fd=(e,n,t,r)=>{let a;for(ge(e,n-257,5),ge(e,t-1,5),ge(e,r-4,4),a=0;a<r;a++)ge(e,e.bl_tree[Ki[a]*2+1],3);so(e,e.dyn_ltree,n-1),so(e,e.dyn_dtree,t-1)},hd=e=>{let n=4093624447,t;for(t=0;t<=31;t++,n>>>=1)if(n&1&&e.dyn_ltree[t*2]!==0)return Vi;if(e.dyn_ltree[9*2]!==0||e.dyn_ltree[10*2]!==0||e.dyn_ltree[13*2]!==0)return Pi;for(t=32;t<qt;t++)if(e.dyn_ltree[t*2]!==0)return Pi;return Vi};let co=!1;const pd=e=>{co||(ud(),co=!0),e.l_desc=new Gr(e.dyn_ltree,Ji),e.d_desc=new Gr(e.dyn_dtree,qi),e.bl_desc=new Gr(e.bl_tree,Qi),e.bi_buf=0,e.bi_valid=0,no(e)},lo=(e,n,t,r)=>{ge(e,(td<<1)+(r?1:0),3),ro(e),nn(e,t),nn(e,~t),t&&e.pending_buf.set(e.window.subarray(n,n+t),e.pending),e.pending+=t},gd=e=>{ge(e,Hi<<1,3),Te(e,Wr,We),cd(e)},md=(e,n,t,r)=>{let a,i,s=0;e.level>0?(e.strm.data_type===ed&&(e.strm.data_type=hd(e)),jr(e,e.l_desc),jr(e,e.d_desc),s=dd(e),a=e.opt_len+3+7>>>3,i=e.static_len+3+7>>>3,i<=a&&(a=i)):a=i=t+5,t+4<=a&&n!==-1?lo(e,n,t,r):e.strategy===$u||i===a?(ge(e,(Hi<<1)+(r?1:0),3),io(e,We,$t)):(ge(e,(nd<<1)+(r?1:0),3),fd(e,e.l_desc.max_code+1,e.d_desc.max_code+1,s+1),io(e,e.dyn_ltree,e.dyn_dtree)),no(e),r&&ro(e)},vd=(e,n,t)=>(e.pending_buf[e.sym_buf+e.sym_next++]=n,e.pending_buf[e.sym_buf+e.sym_next++]=n>>8,e.pending_buf[e.sym_buf+e.sym_next++]=t,n===0?e.dyn_ltree[t*2]++:(e.matches++,n--,e.dyn_ltree[(tn[t]+qt+1)*2]++,e.dyn_dtree[$i(n)*2]++),e.sym_next===e.sym_end);var bd=pd,yd=lo,Id=md,_d=vd,wd=gd,Cd={_tr_init:bd,_tr_stored_block:yd,_tr_flush_block:Id,_tr_tally:_d,_tr_align:wd},rn=(e,n,t,r)=>{let a=e&65535|0,i=e>>>16&65535|0,s=0;for(;t!==0;){s=t>2e3?2e3:t,t-=s;do a=a+n[r++]|0,i=i+a|0;while(--s);a%=65521,i%=65521}return a|i<<16|0};const Sd=()=>{let e,n=[];for(var t=0;t<256;t++){e=t;for(var r=0;r<8;r++)e=e&1?3988292384^e>>>1:e>>>1;n[t]=e}return n},Ad=new Uint32Array(Sd());var $=(e,n,t,r)=>{const a=Ad,i=r+t;e^=-1;for(let s=r;s<i;s++)e=e>>>8^a[(e^n[s])&255];return e^-1},it={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"},ot={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8};const{_tr_init:Ed,_tr_stored_block:Yr,_tr_flush_block:kd,_tr_tally:Ke,_tr_align:Rd}=Cd,{Z_NO_FLUSH:Je,Z_PARTIAL_FLUSH:xd,Z_FULL_FLUSH:Td,Z_FINISH:we,Z_BLOCK:uo,Z_OK:re,Z_STREAM_END:fo,Z_STREAM_ERROR:Le,Z_DATA_ERROR:Ld,Z_BUF_ERROR:Kr,Z_DEFAULT_COMPRESSION:Od,Z_FILTERED:Md,Z_HUFFMAN_ONLY:Wn,Z_RLE:Nd,Z_FIXED:Dd,Z_DEFAULT_STRATEGY:Fd,Z_UNKNOWN:Zd,Z_DEFLATED:Vn}=ot,Bd=9,Ud=15,zd=8,Wd=29,Jr=256+1+Wd,Vd=30,Pd=19,Hd=2*Jr+1,Gd=15,N=3,qe=258,Oe=qe+N+1,Xd=32,Mt=42,qr=57,Qr=69,$r=73,ea=91,ta=103,st=113,an=666,le=1,Nt=2,ct=3,Dt=4,jd=3,lt=(e,n)=>(e.msg=it[n],n),ho=e=>e*2-(e>4?9:0),Qe=e=>{let n=e.length;for(;--n>=0;)e[n]=0},Yd=e=>{let n,t,r,a=e.w_size;n=e.hash_size,r=n;do t=e.head[--r],e.head[r]=t>=a?t-a:0;while(--n);n=a,r=n;do t=e.prev[--r],e.prev[r]=t>=a?t-a:0;while(--n)};let $e=(e,n,t)=>(n<<e.hash_shift^t)&e.hash_mask;const be=e=>{const n=e.state;let t=n.pending;t>e.avail_out&&(t=e.avail_out),t!==0&&(e.output.set(n.pending_buf.subarray(n.pending_out,n.pending_out+t),e.next_out),e.next_out+=t,n.pending_out+=t,e.total_out+=t,e.avail_out-=t,n.pending-=t,n.pending===0&&(n.pending_out=0))},ye=(e,n)=>{kd(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,n),e.block_start=e.strstart,be(e.strm)},U=(e,n)=>{e.pending_buf[e.pending++]=n},on=(e,n)=>{e.pending_buf[e.pending++]=n>>>8&255,e.pending_buf[e.pending++]=n&255},na=(e,n,t,r)=>{let a=e.avail_in;return a>r&&(a=r),a===0?0:(e.avail_in-=a,n.set(e.input.subarray(e.next_in,e.next_in+a),t),e.state.wrap===1?e.adler=rn(e.adler,n,a,t):e.state.wrap===2&&(e.adler=$(e.adler,n,a,t)),e.next_in+=a,e.total_in+=a,a)},po=(e,n)=>{let t=e.max_chain_length,r=e.strstart,a,i,s=e.prev_length,o=e.nice_match;const l=e.strstart>e.w_size-Oe?e.strstart-(e.w_size-Oe):0,c=e.window,u=e.w_mask,h=e.prev,d=e.strstart+qe;let f=c[r+s-1],p=c[r+s];e.prev_length>=e.good_match&&(t>>=2),o>e.lookahead&&(o=e.lookahead);do if(a=n,!(c[a+s]!==p||c[a+s-1]!==f||c[a]!==c[r]||c[++a]!==c[r+1])){r+=2,a++;do;while(c[++r]===c[++a]&&c[++r]===c[++a]&&c[++r]===c[++a]&&c[++r]===c[++a]&&c[++r]===c[++a]&&c[++r]===c[++a]&&c[++r]===c[++a]&&c[++r]===c[++a]&&r<d);if(i=qe-(d-r),r=d-qe,i>s){if(e.match_start=n,s=i,i>=o)break;f=c[r+s-1],p=c[r+s]}}while((n=h[n&u])>l&&--t!==0);return s<=e.lookahead?s:e.lookahead},Ft=e=>{const n=e.w_size;let t,r,a;do{if(r=e.window_size-e.lookahead-e.strstart,e.strstart>=n+(n-Oe)&&(e.window.set(e.window.subarray(n,n+n-r),0),e.match_start-=n,e.strstart-=n,e.block_start-=n,e.insert>e.strstart&&(e.insert=e.strstart),Yd(e),r+=n),e.strm.avail_in===0)break;if(t=na(e.strm,e.window,e.strstart+e.lookahead,r),e.lookahead+=t,e.lookahead+e.insert>=N)for(a=e.strstart-e.insert,e.ins_h=e.window[a],e.ins_h=$e(e,e.ins_h,e.window[a+1]);e.insert&&(e.ins_h=$e(e,e.ins_h,e.window[a+N-1]),e.prev[a&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=a,a++,e.insert--,!(e.lookahead+e.insert<N)););}while(e.lookahead<Oe&&e.strm.avail_in!==0)},go=(e,n)=>{let t=e.pending_buf_size-5>e.w_size?e.w_size:e.pending_buf_size-5,r,a,i,s=0,o=e.strm.avail_in;do{if(r=65535,i=e.bi_valid+42>>3,e.strm.avail_out<i||(i=e.strm.avail_out-i,a=e.strstart-e.block_start,r>a+e.strm.avail_in&&(r=a+e.strm.avail_in),r>i&&(r=i),r<t&&(r===0&&n!==we||n===Je||r!==a+e.strm.avail_in)))break;s=n===we&&r===a+e.strm.avail_in?1:0,Yr(e,0,0,s),e.pending_buf[e.pending-4]=r,e.pending_buf[e.pending-3]=r>>8,e.pending_buf[e.pending-2]=~r,e.pending_buf[e.pending-1]=~r>>8,be(e.strm),a&&(a>r&&(a=r),e.strm.output.set(e.window.subarray(e.block_start,e.block_start+a),e.strm.next_out),e.strm.next_out+=a,e.strm.avail_out-=a,e.strm.total_out+=a,e.block_start+=a,r-=a),r&&(na(e.strm,e.strm.output,e.strm.next_out,r),e.strm.next_out+=r,e.strm.avail_out-=r,e.strm.total_out+=r)}while(s===0);return o-=e.strm.avail_in,o&&(o>=e.w_size?(e.matches=2,e.window.set(e.strm.input.subarray(e.strm.next_in-e.w_size,e.strm.next_in),0),e.strstart=e.w_size,e.insert=e.strstart):(e.window_size-e.strstart<=o&&(e.strstart-=e.w_size,e.window.set(e.window.subarray(e.w_size,e.w_size+e.strstart),0),e.matches<2&&e.matches++,e.insert>e.strstart&&(e.insert=e.strstart)),e.window.set(e.strm.input.subarray(e.strm.next_in-o,e.strm.next_in),e.strstart),e.strstart+=o,e.insert+=o>e.w_size-e.insert?e.w_size-e.insert:o),e.block_start=e.strstart),e.high_water<e.strstart&&(e.high_water=e.strstart),s?Dt:n!==Je&&n!==we&&e.strm.avail_in===0&&e.strstart===e.block_start?Nt:(i=e.window_size-e.strstart,e.strm.avail_in>i&&e.block_start>=e.w_size&&(e.block_start-=e.w_size,e.strstart-=e.w_size,e.window.set(e.window.subarray(e.w_size,e.w_size+e.strstart),0),e.matches<2&&e.matches++,i+=e.w_size,e.insert>e.strstart&&(e.insert=e.strstart)),i>e.strm.avail_in&&(i=e.strm.avail_in),i&&(na(e.strm,e.window,e.strstart,i),e.strstart+=i,e.insert+=i>e.w_size-e.insert?e.w_size-e.insert:i),e.high_water<e.strstart&&(e.high_water=e.strstart),i=e.bi_valid+42>>3,i=e.pending_buf_size-i>65535?65535:e.pending_buf_size-i,t=i>e.w_size?e.w_size:i,a=e.strstart-e.block_start,(a>=t||(a||n===we)&&n!==Je&&e.strm.avail_in===0&&a<=i)&&(r=a>i?i:a,s=n===we&&e.strm.avail_in===0&&r===a?1:0,Yr(e,e.block_start,r,s),e.block_start+=r,be(e.strm)),s?ct:le)},ra=(e,n)=>{let t,r;for(;;){if(e.lookahead<Oe){if(Ft(e),e.lookahead<Oe&&n===Je)return le;if(e.lookahead===0)break}if(t=0,e.lookahead>=N&&(e.ins_h=$e(e,e.ins_h,e.window[e.strstart+N-1]),t=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),t!==0&&e.strstart-t<=e.w_size-Oe&&(e.match_length=po(e,t)),e.match_length>=N)if(r=Ke(e,e.strstart-e.match_start,e.match_length-N),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=N){e.match_length--;do e.strstart++,e.ins_h=$e(e,e.ins_h,e.window[e.strstart+N-1]),t=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart;while(--e.match_length!==0);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=$e(e,e.ins_h,e.window[e.strstart+1]);else r=Ke(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(r&&(ye(e,!1),e.strm.avail_out===0))return le}return e.insert=e.strstart<N-1?e.strstart:N-1,n===we?(ye(e,!0),e.strm.avail_out===0?ct:Dt):e.sym_next&&(ye(e,!1),e.strm.avail_out===0)?le:Nt},Zt=(e,n)=>{let t,r,a;for(;;){if(e.lookahead<Oe){if(Ft(e),e.lookahead<Oe&&n===Je)return le;if(e.lookahead===0)break}if(t=0,e.lookahead>=N&&(e.ins_h=$e(e,e.ins_h,e.window[e.strstart+N-1]),t=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=N-1,t!==0&&e.prev_length<e.max_lazy_match&&e.strstart-t<=e.w_size-Oe&&(e.match_length=po(e,t),e.match_length<=5&&(e.strategy===Md||e.match_length===N&&e.strstart-e.match_start>4096)&&(e.match_length=N-1)),e.prev_length>=N&&e.match_length<=e.prev_length){a=e.strstart+e.lookahead-N,r=Ke(e,e.strstart-1-e.prev_match,e.prev_length-N),e.lookahead-=e.prev_length-1,e.prev_length-=2;do++e.strstart<=a&&(e.ins_h=$e(e,e.ins_h,e.window[e.strstart+N-1]),t=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart);while(--e.prev_length!==0);if(e.match_available=0,e.match_length=N-1,e.strstart++,r&&(ye(e,!1),e.strm.avail_out===0))return le}else if(e.match_available){if(r=Ke(e,0,e.window[e.strstart-1]),r&&ye(e,!1),e.strstart++,e.lookahead--,e.strm.avail_out===0)return le}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(r=Ke(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<N-1?e.strstart:N-1,n===we?(ye(e,!0),e.strm.avail_out===0?ct:Dt):e.sym_next&&(ye(e,!1),e.strm.avail_out===0)?le:Nt},Kd=(e,n)=>{let t,r,a,i;const s=e.window;for(;;){if(e.lookahead<=qe){if(Ft(e),e.lookahead<=qe&&n===Je)return le;if(e.lookahead===0)break}if(e.match_length=0,e.lookahead>=N&&e.strstart>0&&(a=e.strstart-1,r=s[a],r===s[++a]&&r===s[++a]&&r===s[++a])){i=e.strstart+qe;do;while(r===s[++a]&&r===s[++a]&&r===s[++a]&&r===s[++a]&&r===s[++a]&&r===s[++a]&&r===s[++a]&&r===s[++a]&&a<i);e.match_length=qe-(i-a),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=N?(t=Ke(e,1,e.match_length-N),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(t=Ke(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),t&&(ye(e,!1),e.strm.avail_out===0))return le}return e.insert=0,n===we?(ye(e,!0),e.strm.avail_out===0?ct:Dt):e.sym_next&&(ye(e,!1),e.strm.avail_out===0)?le:Nt},Jd=(e,n)=>{let t;for(;;){if(e.lookahead===0&&(Ft(e),e.lookahead===0)){if(n===Je)return le;break}if(e.match_length=0,t=Ke(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,t&&(ye(e,!1),e.strm.avail_out===0))return le}return e.insert=0,n===we?(ye(e,!0),e.strm.avail_out===0?ct:Dt):e.sym_next&&(ye(e,!1),e.strm.avail_out===0)?le:Nt};function Me(e,n,t,r,a){this.good_length=e,this.max_lazy=n,this.nice_length=t,this.max_chain=r,this.func=a}const sn=[new Me(0,0,0,0,go),new Me(4,4,8,4,ra),new Me(4,5,16,8,ra),new Me(4,6,32,32,ra),new Me(4,4,16,16,Zt),new Me(8,16,32,32,Zt),new Me(8,16,128,128,Zt),new Me(8,32,128,256,Zt),new Me(32,128,258,1024,Zt),new Me(32,258,258,4096,Zt)],qd=e=>{e.window_size=2*e.w_size,Qe(e.head),e.max_lazy_match=sn[e.level].max_lazy,e.good_match=sn[e.level].good_length,e.nice_match=sn[e.level].nice_length,e.max_chain_length=sn[e.level].max_chain,e.strstart=0,e.block_start=0,e.lookahead=0,e.insert=0,e.match_length=e.prev_length=N-1,e.match_available=0,e.ins_h=0};function Qd(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=Vn,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new Uint16Array(Hd*2),this.dyn_dtree=new Uint16Array((2*Vd+1)*2),this.bl_tree=new Uint16Array((2*Pd+1)*2),Qe(this.dyn_ltree),Qe(this.dyn_dtree),Qe(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new Uint16Array(Gd+1),this.heap=new Uint16Array(2*Jr+1),Qe(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Uint16Array(2*Jr+1),Qe(this.depth),this.sym_buf=0,this.lit_bufsize=0,this.sym_next=0,this.sym_end=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}const cn=e=>{if(!e)return 1;const n=e.state;return!n||n.strm!==e||n.status!==Mt&&n.status!==qr&&n.status!==Qr&&n.status!==$r&&n.status!==ea&&n.status!==ta&&n.status!==st&&n.status!==an?1:0},mo=e=>{if(cn(e))return lt(e,Le);e.total_in=e.total_out=0,e.data_type=Zd;const n=e.state;return n.pending=0,n.pending_out=0,n.wrap<0&&(n.wrap=-n.wrap),n.status=n.wrap===2?qr:n.wrap?Mt:st,e.adler=n.wrap===2?0:1,n.last_flush=-2,Ed(n),re},vo=e=>{const n=mo(e);return n===re&&qd(e.state),n},$d=(e,n)=>cn(e)||e.state.wrap!==2?Le:(e.state.gzhead=n,re),bo=(e,n,t,r,a,i)=>{if(!e)return Le;let s=1;if(n===Od&&(n=6),r<0?(s=0,r=-r):r>15&&(s=2,r-=16),a<1||a>Bd||t!==Vn||r<8||r>15||n<0||n>9||i<0||i>Dd||r===8&&s!==1)return lt(e,Le);r===8&&(r=9);const o=new Qd;return e.state=o,o.strm=e,o.status=Mt,o.wrap=s,o.gzhead=null,o.w_bits=r,o.w_size=1<<o.w_bits,o.w_mask=o.w_size-1,o.hash_bits=a+7,o.hash_size=1<<o.hash_bits,o.hash_mask=o.hash_size-1,o.hash_shift=~~((o.hash_bits+N-1)/N),o.window=new Uint8Array(o.w_size*2),o.head=new Uint16Array(o.hash_size),o.prev=new Uint16Array(o.w_size),o.lit_bufsize=1<<a+6,o.pending_buf_size=o.lit_bufsize*4,o.pending_buf=new Uint8Array(o.pending_buf_size),o.sym_buf=o.lit_bufsize,o.sym_end=(o.lit_bufsize-1)*3,o.level=n,o.strategy=i,o.method=t,vo(e)},ef=(e,n)=>bo(e,n,Vn,Ud,zd,Fd),tf=(e,n)=>{if(cn(e)||n>uo||n<0)return e?lt(e,Le):Le;const t=e.state;if(!e.output||e.avail_in!==0&&!e.input||t.status===an&&n!==we)return lt(e,e.avail_out===0?Kr:Le);const r=t.last_flush;if(t.last_flush=n,t.pending!==0){if(be(e),e.avail_out===0)return t.last_flush=-1,re}else if(e.avail_in===0&&ho(n)<=ho(r)&&n!==we)return lt(e,Kr);if(t.status===an&&e.avail_in!==0)return lt(e,Kr);if(t.status===Mt&&t.wrap===0&&(t.status=st),t.status===Mt){let a=Vn+(t.w_bits-8<<4)<<8,i=-1;if(t.strategy>=Wn||t.level<2?i=0:t.level<6?i=1:t.level===6?i=2:i=3,a|=i<<6,t.strstart!==0&&(a|=Xd),a+=31-a%31,on(t,a),t.strstart!==0&&(on(t,e.adler>>>16),on(t,e.adler&65535)),e.adler=1,t.status=st,be(e),t.pending!==0)return t.last_flush=-1,re}if(t.status===qr){if(e.adler=0,U(t,31),U(t,139),U(t,8),t.gzhead)U(t,(t.gzhead.text?1:0)+(t.gzhead.hcrc?2:0)+(t.gzhead.extra?4:0)+(t.gzhead.name?8:0)+(t.gzhead.comment?16:0)),U(t,t.gzhead.time&255),U(t,t.gzhead.time>>8&255),U(t,t.gzhead.time>>16&255),U(t,t.gzhead.time>>24&255),U(t,t.level===9?2:t.strategy>=Wn||t.level<2?4:0),U(t,t.gzhead.os&255),t.gzhead.extra&&t.gzhead.extra.length&&(U(t,t.gzhead.extra.length&255),U(t,t.gzhead.extra.length>>8&255)),t.gzhead.hcrc&&(e.adler=$(e.adler,t.pending_buf,t.pending,0)),t.gzindex=0,t.status=Qr;else if(U(t,0),U(t,0),U(t,0),U(t,0),U(t,0),U(t,t.level===9?2:t.strategy>=Wn||t.level<2?4:0),U(t,jd),t.status=st,be(e),t.pending!==0)return t.last_flush=-1,re}if(t.status===Qr){if(t.gzhead.extra){let a=t.pending,i=(t.gzhead.extra.length&65535)-t.gzindex;for(;t.pending+i>t.pending_buf_size;){let o=t.pending_buf_size-t.pending;if(t.pending_buf.set(t.gzhead.extra.subarray(t.gzindex,t.gzindex+o),t.pending),t.pending=t.pending_buf_size,t.gzhead.hcrc&&t.pending>a&&(e.adler=$(e.adler,t.pending_buf,t.pending-a,a)),t.gzindex+=o,be(e),t.pending!==0)return t.last_flush=-1,re;a=0,i-=o}let s=new Uint8Array(t.gzhead.extra);t.pending_buf.set(s.subarray(t.gzindex,t.gzindex+i),t.pending),t.pending+=i,t.gzhead.hcrc&&t.pending>a&&(e.adler=$(e.adler,t.pending_buf,t.pending-a,a)),t.gzindex=0}t.status=$r}if(t.status===$r){if(t.gzhead.name){let a=t.pending,i;do{if(t.pending===t.pending_buf_size){if(t.gzhead.hcrc&&t.pending>a&&(e.adler=$(e.adler,t.pending_buf,t.pending-a,a)),be(e),t.pending!==0)return t.last_flush=-1,re;a=0}t.gzindex<t.gzhead.name.length?i=t.gzhead.name.charCodeAt(t.gzindex++)&255:i=0,U(t,i)}while(i!==0);t.gzhead.hcrc&&t.pending>a&&(e.adler=$(e.adler,t.pending_buf,t.pending-a,a)),t.gzindex=0}t.status=ea}if(t.status===ea){if(t.gzhead.comment){let a=t.pending,i;do{if(t.pending===t.pending_buf_size){if(t.gzhead.hcrc&&t.pending>a&&(e.adler=$(e.adler,t.pending_buf,t.pending-a,a)),be(e),t.pending!==0)return t.last_flush=-1,re;a=0}t.gzindex<t.gzhead.comment.length?i=t.gzhead.comment.charCodeAt(t.gzindex++)&255:i=0,U(t,i)}while(i!==0);t.gzhead.hcrc&&t.pending>a&&(e.adler=$(e.adler,t.pending_buf,t.pending-a,a))}t.status=ta}if(t.status===ta){if(t.gzhead.hcrc){if(t.pending+2>t.pending_buf_size&&(be(e),t.pending!==0))return t.last_flush=-1,re;U(t,e.adler&255),U(t,e.adler>>8&255),e.adler=0}if(t.status=st,be(e),t.pending!==0)return t.last_flush=-1,re}if(e.avail_in!==0||t.lookahead!==0||n!==Je&&t.status!==an){let a=t.level===0?go(t,n):t.strategy===Wn?Jd(t,n):t.strategy===Nd?Kd(t,n):sn[t.level].func(t,n);if((a===ct||a===Dt)&&(t.status=an),a===le||a===ct)return e.avail_out===0&&(t.last_flush=-1),re;if(a===Nt&&(n===xd?Rd(t):n!==uo&&(Yr(t,0,0,!1),n===Td&&(Qe(t.head),t.lookahead===0&&(t.strstart=0,t.block_start=0,t.insert=0))),be(e),e.avail_out===0))return t.last_flush=-1,re}return n!==we?re:t.wrap<=0?fo:(t.wrap===2?(U(t,e.adler&255),U(t,e.adler>>8&255),U(t,e.adler>>16&255),U(t,e.adler>>24&255),U(t,e.total_in&255),U(t,e.total_in>>8&255),U(t,e.total_in>>16&255),U(t,e.total_in>>24&255)):(on(t,e.adler>>>16),on(t,e.adler&65535)),be(e),t.wrap>0&&(t.wrap=-t.wrap),t.pending!==0?re:fo)},nf=e=>{if(cn(e))return Le;const n=e.state.status;return e.state=null,n===st?lt(e,Ld):re},rf=(e,n)=>{let t=n.length;if(cn(e))return Le;const r=e.state,a=r.wrap;if(a===2||a===1&&r.status!==Mt||r.lookahead)return Le;if(a===1&&(e.adler=rn(e.adler,n,t,0)),r.wrap=0,t>=r.w_size){a===0&&(Qe(r.head),r.strstart=0,r.block_start=0,r.insert=0);let l=new Uint8Array(r.w_size);l.set(n.subarray(t-r.w_size,t),0),n=l,t=r.w_size}const i=e.avail_in,s=e.next_in,o=e.input;for(e.avail_in=t,e.next_in=0,e.input=n,Ft(r);r.lookahead>=N;){let l=r.strstart,c=r.lookahead-(N-1);do r.ins_h=$e(r,r.ins_h,r.window[l+N-1]),r.prev[l&r.w_mask]=r.head[r.ins_h],r.head[r.ins_h]=l,l++;while(--c);r.strstart=l,r.lookahead=N-1,Ft(r)}return r.strstart+=r.lookahead,r.block_start=r.strstart,r.insert=r.lookahead,r.lookahead=0,r.match_length=r.prev_length=N-1,r.match_available=0,e.next_in=s,e.input=o,e.avail_in=i,r.wrap=a,re};var af=ef,of=bo,sf=vo,cf=mo,lf=$d,uf=tf,df=nf,ff=rf,hf="pako deflate (from Nodeca project)",ln={deflateInit:af,deflateInit2:of,deflateReset:sf,deflateResetKeep:cf,deflateSetHeader:lf,deflate:uf,deflateEnd:df,deflateSetDictionary:ff,deflateInfo:hf};const pf=(e,n)=>Object.prototype.hasOwnProperty.call(e,n);var gf=function(e){const n=Array.prototype.slice.call(arguments,1);for(;n.length;){const t=n.shift();if(t){if(typeof t!="object")throw new TypeError(t+"must be non-object");for(const r in t)pf(t,r)&&(e[r]=t[r])}}return e},mf=e=>{let n=0;for(let r=0,a=e.length;r<a;r++)n+=e[r].length;const t=new Uint8Array(n);for(let r=0,a=0,i=e.length;r<i;r++){let s=e[r];t.set(s,a),a+=s.length}return t},Pn={assign:gf,flattenChunks:mf};let yo=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{yo=!1}const un=new Uint8Array(256);for(let e=0;e<256;e++)un[e]=e>=252?6:e>=248?5:e>=240?4:e>=224?3:e>=192?2:1;un[254]=un[254]=1;var vf=e=>{if(typeof TextEncoder=="function"&&TextEncoder.prototype.encode)return new TextEncoder().encode(e);let n,t,r,a,i,s=e.length,o=0;for(a=0;a<s;a++)t=e.charCodeAt(a),(t&64512)===55296&&a+1<s&&(r=e.charCodeAt(a+1),(r&64512)===56320&&(t=65536+(t-55296<<10)+(r-56320),a++)),o+=t<128?1:t<2048?2:t<65536?3:4;for(n=new Uint8Array(o),i=0,a=0;i<o;a++)t=e.charCodeAt(a),(t&64512)===55296&&a+1<s&&(r=e.charCodeAt(a+1),(r&64512)===56320&&(t=65536+(t-55296<<10)+(r-56320),a++)),t<128?n[i++]=t:t<2048?(n[i++]=192|t>>>6,n[i++]=128|t&63):t<65536?(n[i++]=224|t>>>12,n[i++]=128|t>>>6&63,n[i++]=128|t&63):(n[i++]=240|t>>>18,n[i++]=128|t>>>12&63,n[i++]=128|t>>>6&63,n[i++]=128|t&63);return n};const bf=(e,n)=>{if(n<65534&&e.subarray&&yo)return String.fromCharCode.apply(null,e.length===n?e:e.subarray(0,n));let t="";for(let r=0;r<n;r++)t+=String.fromCharCode(e[r]);return t};var yf=(e,n)=>{const t=n||e.length;if(typeof TextDecoder=="function"&&TextDecoder.prototype.decode)return new TextDecoder().decode(e.subarray(0,n));let r,a;const i=new Array(t*2);for(a=0,r=0;r<t;){let s=e[r++];if(s<128){i[a++]=s;continue}let o=un[s];if(o>4){i[a++]=65533,r+=o-1;continue}for(s&=o===2?31:o===3?15:7;o>1&&r<t;)s=s<<6|e[r++]&63,o--;if(o>1){i[a++]=65533;continue}s<65536?i[a++]=s:(s-=65536,i[a++]=55296|s>>10&1023,i[a++]=56320|s&1023)}return bf(i,a)},If=(e,n)=>{n=n||e.length,n>e.length&&(n=e.length);let t=n-1;for(;t>=0&&(e[t]&192)===128;)t--;return t<0||t===0?n:t+un[e[t]]>n?t:n},dn={string2buf:vf,buf2string:yf,utf8border:If};function _f(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}var Io=_f;const _o=Object.prototype.toString,{Z_NO_FLUSH:wf,Z_SYNC_FLUSH:Cf,Z_FULL_FLUSH:Sf,Z_FINISH:Af,Z_OK:Hn,Z_STREAM_END:Ef,Z_DEFAULT_COMPRESSION:kf,Z_DEFAULT_STRATEGY:Rf,Z_DEFLATED:xf}=ot;function fn(e){this.options=Pn.assign({level:kf,method:xf,chunkSize:16384,windowBits:15,memLevel:8,strategy:Rf},e||{});let n=this.options;n.raw&&n.windowBits>0?n.windowBits=-n.windowBits:n.gzip&&n.windowBits>0&&n.windowBits<16&&(n.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new Io,this.strm.avail_out=0;let t=ln.deflateInit2(this.strm,n.level,n.method,n.windowBits,n.memLevel,n.strategy);if(t!==Hn)throw new Error(it[t]);if(n.header&&ln.deflateSetHeader(this.strm,n.header),n.dictionary){let r;if(typeof n.dictionary=="string"?r=dn.string2buf(n.dictionary):_o.call(n.dictionary)==="[object ArrayBuffer]"?r=new Uint8Array(n.dictionary):r=n.dictionary,t=ln.deflateSetDictionary(this.strm,r),t!==Hn)throw new Error(it[t]);this._dict_set=!0}}fn.prototype.push=function(e,n){const t=this.strm,r=this.options.chunkSize;let a,i;if(this.ended)return!1;for(n===~~n?i=n:i=n===!0?Af:wf,typeof e=="string"?t.input=dn.string2buf(e):_o.call(e)==="[object ArrayBuffer]"?t.input=new Uint8Array(e):t.input=e,t.next_in=0,t.avail_in=t.input.length;;){if(t.avail_out===0&&(t.output=new Uint8Array(r),t.next_out=0,t.avail_out=r),(i===Cf||i===Sf)&&t.avail_out<=6){this.onData(t.output.subarray(0,t.next_out)),t.avail_out=0;continue}if(a=ln.deflate(t,i),a===Ef)return t.next_out>0&&this.onData(t.output.subarray(0,t.next_out)),a=ln.deflateEnd(this.strm),this.onEnd(a),this.ended=!0,a===Hn;if(t.avail_out===0){this.onData(t.output);continue}if(i>0&&t.next_out>0){this.onData(t.output.subarray(0,t.next_out)),t.avail_out=0;continue}if(t.avail_in===0)break}return!0},fn.prototype.onData=function(e){this.chunks.push(e)},fn.prototype.onEnd=function(e){e===Hn&&(this.result=Pn.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};function aa(e,n){const t=new fn(n);if(t.push(e,!0),t.err)throw t.msg||it[t.err];return t.result}function Tf(e,n){return n=n||{},n.raw=!0,aa(e,n)}function Lf(e,n){return n=n||{},n.gzip=!0,aa(e,n)}var Of=fn,Mf=aa,Nf=Tf,Df=Lf,Ff=ot,Zf={Deflate:Of,deflate:Mf,deflateRaw:Nf,gzip:Df,constants:Ff};const Gn=16209,Bf=16191;var Uf=function(n,t){let r,a,i,s,o,l,c,u,h,d,f,p,v,g,I,_,m,y,S,T,w,k,A,C;const R=n.state;r=n.next_in,A=n.input,a=r+(n.avail_in-5),i=n.next_out,C=n.output,s=i-(t-n.avail_out),o=i+(n.avail_out-257),l=R.dmax,c=R.wsize,u=R.whave,h=R.wnext,d=R.window,f=R.hold,p=R.bits,v=R.lencode,g=R.distcode,I=(1<<R.lenbits)-1,_=(1<<R.distbits)-1;e:do{p<15&&(f+=A[r++]<<p,p+=8,f+=A[r++]<<p,p+=8),m=v[f&I];t:for(;;){if(y=m>>>24,f>>>=y,p-=y,y=m>>>16&255,y===0)C[i++]=m&65535;else if(y&16){S=m&65535,y&=15,y&&(p<y&&(f+=A[r++]<<p,p+=8),S+=f&(1<<y)-1,f>>>=y,p-=y),p<15&&(f+=A[r++]<<p,p+=8,f+=A[r++]<<p,p+=8),m=g[f&_];n:for(;;){if(y=m>>>24,f>>>=y,p-=y,y=m>>>16&255,y&16){if(T=m&65535,y&=15,p<y&&(f+=A[r++]<<p,p+=8,p<y&&(f+=A[r++]<<p,p+=8)),T+=f&(1<<y)-1,T>l){n.msg="invalid distance too far back",R.mode=Gn;break e}if(f>>>=y,p-=y,y=i-s,T>y){if(y=T-y,y>u&&R.sane){n.msg="invalid distance too far back",R.mode=Gn;break e}if(w=0,k=d,h===0){if(w+=c-y,y<S){S-=y;do C[i++]=d[w++];while(--y);w=i-T,k=C}}else if(h<y){if(w+=c+h-y,y-=h,y<S){S-=y;do C[i++]=d[w++];while(--y);if(w=0,h<S){y=h,S-=y;do C[i++]=d[w++];while(--y);w=i-T,k=C}}}else if(w+=h-y,y<S){S-=y;do C[i++]=d[w++];while(--y);w=i-T,k=C}for(;S>2;)C[i++]=k[w++],C[i++]=k[w++],C[i++]=k[w++],S-=3;S&&(C[i++]=k[w++],S>1&&(C[i++]=k[w++]))}else{w=i-T;do C[i++]=C[w++],C[i++]=C[w++],C[i++]=C[w++],S-=3;while(S>2);S&&(C[i++]=C[w++],S>1&&(C[i++]=C[w++]))}}else if(y&64){n.msg="invalid distance code",R.mode=Gn;break e}else{m=g[(m&65535)+(f&(1<<y)-1)];continue n}break}}else if(y&64)if(y&32){R.mode=Bf;break e}else{n.msg="invalid literal/length code",R.mode=Gn;break e}else{m=v[(m&65535)+(f&(1<<y)-1)];continue t}break}}while(r<a&&i<o);S=p>>3,r-=S,p-=S<<3,f&=(1<<p)-1,n.next_in=r,n.next_out=i,n.avail_in=r<a?5+(a-r):5-(r-a),n.avail_out=i<o?257+(o-i):257-(i-o),R.hold=f,R.bits=p};const Bt=15,wo=852,Co=592,So=0,ia=1,Ao=2,zf=new Uint16Array([3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0]),Wf=new Uint8Array([16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78]),Vf=new Uint16Array([1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0]),Pf=new Uint8Array([16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64]);var hn=(e,n,t,r,a,i,s,o)=>{const l=o.bits;let c=0,u=0,h=0,d=0,f=0,p=0,v=0,g=0,I=0,_=0,m,y,S,T,w,k=null,A;const C=new Uint16Array(Bt+1),R=new Uint16Array(Bt+1);let ee=null,ue,H,te;for(c=0;c<=Bt;c++)C[c]=0;for(u=0;u<r;u++)C[n[t+u]]++;for(f=l,d=Bt;d>=1&&C[d]===0;d--);if(f>d&&(f=d),d===0)return a[i++]=1<<24|64<<16|0,a[i++]=1<<24|64<<16|0,o.bits=1,0;for(h=1;h<d&&C[h]===0;h++);for(f<h&&(f=h),g=1,c=1;c<=Bt;c++)if(g<<=1,g-=C[c],g<0)return-1;if(g>0&&(e===So||d!==1))return-1;for(R[1]=0,c=1;c<Bt;c++)R[c+1]=R[c]+C[c];for(u=0;u<r;u++)n[t+u]!==0&&(s[R[n[t+u]]++]=u);if(e===So?(k=ee=s,A=20):e===ia?(k=zf,ee=Wf,A=257):(k=Vf,ee=Pf,A=0),_=0,u=0,c=h,w=i,p=f,v=0,S=-1,I=1<<f,T=I-1,e===ia&&I>wo||e===Ao&&I>Co)return 1;for(;;){ue=c-v,s[u]+1<A?(H=0,te=s[u]):s[u]>=A?(H=ee[s[u]-A],te=k[s[u]-A]):(H=32+64,te=0),m=1<<c-v,y=1<<p,h=y;do y-=m,a[w+(_>>v)+y]=ue<<24|H<<16|te|0;while(y!==0);for(m=1<<c-1;_&m;)m>>=1;if(m!==0?(_&=m-1,_+=m):_=0,u++,--C[c]===0){if(c===d)break;c=n[t+s[u]]}if(c>f&&(_&T)!==S){for(v===0&&(v=f),w+=h,p=c-v,g=1<<p;p+v<d&&(g-=C[p+v],!(g<=0));)p++,g<<=1;if(I+=1<<p,e===ia&&I>wo||e===Ao&&I>Co)return 1;S=_&T,a[S]=f<<24|p<<16|w-i|0}}return _!==0&&(a[w+_]=c-v<<24|64<<16|0),o.bits=f,0};const Hf=0,Eo=1,ko=2,{Z_FINISH:Ro,Z_BLOCK:Gf,Z_TREES:Xn,Z_OK:ut,Z_STREAM_END:Xf,Z_NEED_DICT:jf,Z_STREAM_ERROR:Ce,Z_DATA_ERROR:xo,Z_MEM_ERROR:To,Z_BUF_ERROR:Yf,Z_DEFLATED:Lo}=ot,jn=16180,Oo=16181,Mo=16182,No=16183,Do=16184,Fo=16185,Zo=16186,Bo=16187,Uo=16188,zo=16189,Yn=16190,Ve=16191,oa=16192,Wo=16193,sa=16194,Vo=16195,Po=16196,Ho=16197,Go=16198,Kn=16199,Jn=16200,Xo=16201,jo=16202,Yo=16203,Ko=16204,Jo=16205,ca=16206,qo=16207,Qo=16208,X=16209,$o=16210,es=16211,Kf=852,Jf=592,qf=15,ts=e=>(e>>>24&255)+(e>>>8&65280)+((e&65280)<<8)+((e&255)<<24);function Qf(){this.strm=null,this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new Uint16Array(320),this.work=new Uint16Array(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}const dt=e=>{if(!e)return 1;const n=e.state;return!n||n.strm!==e||n.mode<jn||n.mode>es?1:0},ns=e=>{if(dt(e))return Ce;const n=e.state;return e.total_in=e.total_out=n.total=0,e.msg="",n.wrap&&(e.adler=n.wrap&1),n.mode=jn,n.last=0,n.havedict=0,n.flags=-1,n.dmax=32768,n.head=null,n.hold=0,n.bits=0,n.lencode=n.lendyn=new Int32Array(Kf),n.distcode=n.distdyn=new Int32Array(Jf),n.sane=1,n.back=-1,ut},rs=e=>{if(dt(e))return Ce;const n=e.state;return n.wsize=0,n.whave=0,n.wnext=0,ns(e)},as=(e,n)=>{let t;if(dt(e))return Ce;const r=e.state;return n<0?(t=0,n=-n):(t=(n>>4)+5,n<48&&(n&=15)),n&&(n<8||n>15)?Ce:(r.window!==null&&r.wbits!==n&&(r.window=null),r.wrap=t,r.wbits=n,rs(e))},is=(e,n)=>{if(!e)return Ce;const t=new Qf;e.state=t,t.strm=e,t.window=null,t.mode=jn;const r=as(e,n);return r!==ut&&(e.state=null),r},$f=e=>is(e,qf);let os=!0,la,ua;const eh=e=>{if(os){la=new Int32Array(512),ua=new Int32Array(32);let n=0;for(;n<144;)e.lens[n++]=8;for(;n<256;)e.lens[n++]=9;for(;n<280;)e.lens[n++]=7;for(;n<288;)e.lens[n++]=8;for(hn(Eo,e.lens,0,288,la,0,e.work,{bits:9}),n=0;n<32;)e.lens[n++]=5;hn(ko,e.lens,0,32,ua,0,e.work,{bits:5}),os=!1}e.lencode=la,e.lenbits=9,e.distcode=ua,e.distbits=5},ss=(e,n,t,r)=>{let a;const i=e.state;return i.window===null&&(i.wsize=1<<i.wbits,i.wnext=0,i.whave=0,i.window=new Uint8Array(i.wsize)),r>=i.wsize?(i.window.set(n.subarray(t-i.wsize,t),0),i.wnext=0,i.whave=i.wsize):(a=i.wsize-i.wnext,a>r&&(a=r),i.window.set(n.subarray(t-r,t-r+a),i.wnext),r-=a,r?(i.window.set(n.subarray(t-r,t),0),i.wnext=r,i.whave=i.wsize):(i.wnext+=a,i.wnext===i.wsize&&(i.wnext=0),i.whave<i.wsize&&(i.whave+=a))),0},th=(e,n)=>{let t,r,a,i,s,o,l,c,u,h,d,f,p,v,g=0,I,_,m,y,S,T,w,k;const A=new Uint8Array(4);let C,R;const ee=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(dt(e)||!e.output||!e.input&&e.avail_in!==0)return Ce;t=e.state,t.mode===Ve&&(t.mode=oa),s=e.next_out,a=e.output,l=e.avail_out,i=e.next_in,r=e.input,o=e.avail_in,c=t.hold,u=t.bits,h=o,d=l,k=ut;e:for(;;)switch(t.mode){case jn:if(t.wrap===0){t.mode=oa;break}for(;u<16;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}if(t.wrap&2&&c===35615){t.wbits===0&&(t.wbits=15),t.check=0,A[0]=c&255,A[1]=c>>>8&255,t.check=$(t.check,A,2,0),c=0,u=0,t.mode=Oo;break}if(t.head&&(t.head.done=!1),!(t.wrap&1)||(((c&255)<<8)+(c>>8))%31){e.msg="incorrect header check",t.mode=X;break}if((c&15)!==Lo){e.msg="unknown compression method",t.mode=X;break}if(c>>>=4,u-=4,w=(c&15)+8,t.wbits===0&&(t.wbits=w),w>15||w>t.wbits){e.msg="invalid window size",t.mode=X;break}t.dmax=1<<t.wbits,t.flags=0,e.adler=t.check=1,t.mode=c&512?zo:Ve,c=0,u=0;break;case Oo:for(;u<16;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}if(t.flags=c,(t.flags&255)!==Lo){e.msg="unknown compression method",t.mode=X;break}if(t.flags&57344){e.msg="unknown header flags set",t.mode=X;break}t.head&&(t.head.text=c>>8&1),t.flags&512&&t.wrap&4&&(A[0]=c&255,A[1]=c>>>8&255,t.check=$(t.check,A,2,0)),c=0,u=0,t.mode=Mo;case Mo:for(;u<32;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}t.head&&(t.head.time=c),t.flags&512&&t.wrap&4&&(A[0]=c&255,A[1]=c>>>8&255,A[2]=c>>>16&255,A[3]=c>>>24&255,t.check=$(t.check,A,4,0)),c=0,u=0,t.mode=No;case No:for(;u<16;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}t.head&&(t.head.xflags=c&255,t.head.os=c>>8),t.flags&512&&t.wrap&4&&(A[0]=c&255,A[1]=c>>>8&255,t.check=$(t.check,A,2,0)),c=0,u=0,t.mode=Do;case Do:if(t.flags&1024){for(;u<16;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}t.length=c,t.head&&(t.head.extra_len=c),t.flags&512&&t.wrap&4&&(A[0]=c&255,A[1]=c>>>8&255,t.check=$(t.check,A,2,0)),c=0,u=0}else t.head&&(t.head.extra=null);t.mode=Fo;case Fo:if(t.flags&1024&&(f=t.length,f>o&&(f=o),f&&(t.head&&(w=t.head.extra_len-t.length,t.head.extra||(t.head.extra=new Uint8Array(t.head.extra_len)),t.head.extra.set(r.subarray(i,i+f),w)),t.flags&512&&t.wrap&4&&(t.check=$(t.check,r,f,i)),o-=f,i+=f,t.length-=f),t.length))break e;t.length=0,t.mode=Zo;case Zo:if(t.flags&2048){if(o===0)break e;f=0;do w=r[i+f++],t.head&&w&&t.length<65536&&(t.head.name+=String.fromCharCode(w));while(w&&f<o);if(t.flags&512&&t.wrap&4&&(t.check=$(t.check,r,f,i)),o-=f,i+=f,w)break e}else t.head&&(t.head.name=null);t.length=0,t.mode=Bo;case Bo:if(t.flags&4096){if(o===0)break e;f=0;do w=r[i+f++],t.head&&w&&t.length<65536&&(t.head.comment+=String.fromCharCode(w));while(w&&f<o);if(t.flags&512&&t.wrap&4&&(t.check=$(t.check,r,f,i)),o-=f,i+=f,w)break e}else t.head&&(t.head.comment=null);t.mode=Uo;case Uo:if(t.flags&512){for(;u<16;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}if(t.wrap&4&&c!==(t.check&65535)){e.msg="header crc mismatch",t.mode=X;break}c=0,u=0}t.head&&(t.head.hcrc=t.flags>>9&1,t.head.done=!0),e.adler=t.check=0,t.mode=Ve;break;case zo:for(;u<32;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}e.adler=t.check=ts(c),c=0,u=0,t.mode=Yn;case Yn:if(t.havedict===0)return e.next_out=s,e.avail_out=l,e.next_in=i,e.avail_in=o,t.hold=c,t.bits=u,jf;e.adler=t.check=1,t.mode=Ve;case Ve:if(n===Gf||n===Xn)break e;case oa:if(t.last){c>>>=u&7,u-=u&7,t.mode=ca;break}for(;u<3;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}switch(t.last=c&1,c>>>=1,u-=1,c&3){case 0:t.mode=Wo;break;case 1:if(eh(t),t.mode=Kn,n===Xn){c>>>=2,u-=2;break e}break;case 2:t.mode=Po;break;case 3:e.msg="invalid block type",t.mode=X}c>>>=2,u-=2;break;case Wo:for(c>>>=u&7,u-=u&7;u<32;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}if((c&65535)!==(c>>>16^65535)){e.msg="invalid stored block lengths",t.mode=X;break}if(t.length=c&65535,c=0,u=0,t.mode=sa,n===Xn)break e;case sa:t.mode=Vo;case Vo:if(f=t.length,f){if(f>o&&(f=o),f>l&&(f=l),f===0)break e;a.set(r.subarray(i,i+f),s),o-=f,i+=f,l-=f,s+=f,t.length-=f;break}t.mode=Ve;break;case Po:for(;u<14;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}if(t.nlen=(c&31)+257,c>>>=5,u-=5,t.ndist=(c&31)+1,c>>>=5,u-=5,t.ncode=(c&15)+4,c>>>=4,u-=4,t.nlen>286||t.ndist>30){e.msg="too many length or distance symbols",t.mode=X;break}t.have=0,t.mode=Ho;case Ho:for(;t.have<t.ncode;){for(;u<3;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}t.lens[ee[t.have++]]=c&7,c>>>=3,u-=3}for(;t.have<19;)t.lens[ee[t.have++]]=0;if(t.lencode=t.lendyn,t.lenbits=7,C={bits:t.lenbits},k=hn(Hf,t.lens,0,19,t.lencode,0,t.work,C),t.lenbits=C.bits,k){e.msg="invalid code lengths set",t.mode=X;break}t.have=0,t.mode=Go;case Go:for(;t.have<t.nlen+t.ndist;){for(;g=t.lencode[c&(1<<t.lenbits)-1],I=g>>>24,_=g>>>16&255,m=g&65535,!(I<=u);){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}if(m<16)c>>>=I,u-=I,t.lens[t.have++]=m;else{if(m===16){for(R=I+2;u<R;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}if(c>>>=I,u-=I,t.have===0){e.msg="invalid bit length repeat",t.mode=X;break}w=t.lens[t.have-1],f=3+(c&3),c>>>=2,u-=2}else if(m===17){for(R=I+3;u<R;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}c>>>=I,u-=I,w=0,f=3+(c&7),c>>>=3,u-=3}else{for(R=I+7;u<R;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}c>>>=I,u-=I,w=0,f=11+(c&127),c>>>=7,u-=7}if(t.have+f>t.nlen+t.ndist){e.msg="invalid bit length repeat",t.mode=X;break}for(;f--;)t.lens[t.have++]=w}}if(t.mode===X)break;if(t.lens[256]===0){e.msg="invalid code -- missing end-of-block",t.mode=X;break}if(t.lenbits=9,C={bits:t.lenbits},k=hn(Eo,t.lens,0,t.nlen,t.lencode,0,t.work,C),t.lenbits=C.bits,k){e.msg="invalid literal/lengths set",t.mode=X;break}if(t.distbits=6,t.distcode=t.distdyn,C={bits:t.distbits},k=hn(ko,t.lens,t.nlen,t.ndist,t.distcode,0,t.work,C),t.distbits=C.bits,k){e.msg="invalid distances set",t.mode=X;break}if(t.mode=Kn,n===Xn)break e;case Kn:t.mode=Jn;case Jn:if(o>=6&&l>=258){e.next_out=s,e.avail_out=l,e.next_in=i,e.avail_in=o,t.hold=c,t.bits=u,Uf(e,d),s=e.next_out,a=e.output,l=e.avail_out,i=e.next_in,r=e.input,o=e.avail_in,c=t.hold,u=t.bits,t.mode===Ve&&(t.back=-1);break}for(t.back=0;g=t.lencode[c&(1<<t.lenbits)-1],I=g>>>24,_=g>>>16&255,m=g&65535,!(I<=u);){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}if(_&&!(_&240)){for(y=I,S=_,T=m;g=t.lencode[T+((c&(1<<y+S)-1)>>y)],I=g>>>24,_=g>>>16&255,m=g&65535,!(y+I<=u);){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}c>>>=y,u-=y,t.back+=y}if(c>>>=I,u-=I,t.back+=I,t.length=m,_===0){t.mode=Jo;break}if(_&32){t.back=-1,t.mode=Ve;break}if(_&64){e.msg="invalid literal/length code",t.mode=X;break}t.extra=_&15,t.mode=Xo;case Xo:if(t.extra){for(R=t.extra;u<R;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}t.length+=c&(1<<t.extra)-1,c>>>=t.extra,u-=t.extra,t.back+=t.extra}t.was=t.length,t.mode=jo;case jo:for(;g=t.distcode[c&(1<<t.distbits)-1],I=g>>>24,_=g>>>16&255,m=g&65535,!(I<=u);){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}if(!(_&240)){for(y=I,S=_,T=m;g=t.distcode[T+((c&(1<<y+S)-1)>>y)],I=g>>>24,_=g>>>16&255,m=g&65535,!(y+I<=u);){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}c>>>=y,u-=y,t.back+=y}if(c>>>=I,u-=I,t.back+=I,_&64){e.msg="invalid distance code",t.mode=X;break}t.offset=m,t.extra=_&15,t.mode=Yo;case Yo:if(t.extra){for(R=t.extra;u<R;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}t.offset+=c&(1<<t.extra)-1,c>>>=t.extra,u-=t.extra,t.back+=t.extra}if(t.offset>t.dmax){e.msg="invalid distance too far back",t.mode=X;break}t.mode=Ko;case Ko:if(l===0)break e;if(f=d-l,t.offset>f){if(f=t.offset-f,f>t.whave&&t.sane){e.msg="invalid distance too far back",t.mode=X;break}f>t.wnext?(f-=t.wnext,p=t.wsize-f):p=t.wnext-f,f>t.length&&(f=t.length),v=t.window}else v=a,p=s-t.offset,f=t.length;f>l&&(f=l),l-=f,t.length-=f;do a[s++]=v[p++];while(--f);t.length===0&&(t.mode=Jn);break;case Jo:if(l===0)break e;a[s++]=t.length,l--,t.mode=Jn;break;case ca:if(t.wrap){for(;u<32;){if(o===0)break e;o--,c|=r[i++]<<u,u+=8}if(d-=l,e.total_out+=d,t.total+=d,t.wrap&4&&d&&(e.adler=t.check=t.flags?$(t.check,a,d,s-d):rn(t.check,a,d,s-d)),d=l,t.wrap&4&&(t.flags?c:ts(c))!==t.check){e.msg="incorrect data check",t.mode=X;break}c=0,u=0}t.mode=qo;case qo:if(t.wrap&&t.flags){for(;u<32;){if(o===0)break e;o--,c+=r[i++]<<u,u+=8}if(t.wrap&4&&c!==(t.total&4294967295)){e.msg="incorrect length check",t.mode=X;break}c=0,u=0}t.mode=Qo;case Qo:k=Xf;break e;case X:k=xo;break e;case $o:return To;case es:default:return Ce}return e.next_out=s,e.avail_out=l,e.next_in=i,e.avail_in=o,t.hold=c,t.bits=u,(t.wsize||d!==e.avail_out&&t.mode<X&&(t.mode<ca||n!==Ro))&&ss(e,e.output,e.next_out,d-e.avail_out),h-=e.avail_in,d-=e.avail_out,e.total_in+=h,e.total_out+=d,t.total+=d,t.wrap&4&&d&&(e.adler=t.check=t.flags?$(t.check,a,d,e.next_out-d):rn(t.check,a,d,e.next_out-d)),e.data_type=t.bits+(t.last?64:0)+(t.mode===Ve?128:0)+(t.mode===Kn||t.mode===sa?256:0),(h===0&&d===0||n===Ro)&&k===ut&&(k=Yf),k},nh=e=>{if(dt(e))return Ce;let n=e.state;return n.window&&(n.window=null),e.state=null,ut},rh=(e,n)=>{if(dt(e))return Ce;const t=e.state;return t.wrap&2?(t.head=n,n.done=!1,ut):Ce},ah=(e,n)=>{const t=n.length;let r,a,i;return dt(e)||(r=e.state,r.wrap!==0&&r.mode!==Yn)?Ce:r.mode===Yn&&(a=1,a=rn(a,n,t,0),a!==r.check)?xo:(i=ss(e,n,t,t),i?(r.mode=$o,To):(r.havedict=1,ut))};var ih=rs,oh=as,sh=ns,ch=$f,lh=is,uh=th,dh=nh,fh=rh,hh=ah,ph="pako inflate (from Nodeca project)",Pe={inflateReset:ih,inflateReset2:oh,inflateResetKeep:sh,inflateInit:ch,inflateInit2:lh,inflate:uh,inflateEnd:dh,inflateGetHeader:fh,inflateSetDictionary:hh,inflateInfo:ph};function gh(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}var mh=gh;const cs=Object.prototype.toString,{Z_NO_FLUSH:vh,Z_FINISH:bh,Z_OK:pn,Z_STREAM_END:da,Z_NEED_DICT:fa,Z_STREAM_ERROR:yh,Z_DATA_ERROR:ls,Z_MEM_ERROR:Ih}=ot;function gn(e){this.options=Pn.assign({chunkSize:1024*64,windowBits:15,to:""},e||{});const n=this.options;n.raw&&n.windowBits>=0&&n.windowBits<16&&(n.windowBits=-n.windowBits,n.windowBits===0&&(n.windowBits=-15)),n.windowBits>=0&&n.windowBits<16&&!(e&&e.windowBits)&&(n.windowBits+=32),n.windowBits>15&&n.windowBits<48&&(n.windowBits&15||(n.windowBits|=15)),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new Io,this.strm.avail_out=0;let t=Pe.inflateInit2(this.strm,n.windowBits);if(t!==pn)throw new Error(it[t]);if(this.header=new mh,Pe.inflateGetHeader(this.strm,this.header),n.dictionary&&(typeof n.dictionary=="string"?n.dictionary=dn.string2buf(n.dictionary):cs.call(n.dictionary)==="[object ArrayBuffer]"&&(n.dictionary=new Uint8Array(n.dictionary)),n.raw&&(t=Pe.inflateSetDictionary(this.strm,n.dictionary),t!==pn)))throw new Error(it[t])}gn.prototype.push=function(e,n){const t=this.strm,r=this.options.chunkSize,a=this.options.dictionary;let i,s,o;if(this.ended)return!1;for(n===~~n?s=n:s=n===!0?bh:vh,cs.call(e)==="[object ArrayBuffer]"?t.input=new Uint8Array(e):t.input=e,t.next_in=0,t.avail_in=t.input.length;;){for(t.avail_out===0&&(t.output=new Uint8Array(r),t.next_out=0,t.avail_out=r),i=Pe.inflate(t,s),i===fa&&a&&(i=Pe.inflateSetDictionary(t,a),i===pn?i=Pe.inflate(t,s):i===ls&&(i=fa));t.avail_in>0&&i===da&&t.state.wrap>0&&e[t.next_in]!==0;)Pe.inflateReset(t),i=Pe.inflate(t,s);switch(i){case yh:case ls:case fa:case Ih:return this.onEnd(i),this.ended=!0,!1}if(o=t.avail_out,t.next_out&&(t.avail_out===0||i===da))if(this.options.to==="string"){let l=dn.utf8border(t.output,t.next_out),c=t.next_out-l,u=dn.buf2string(t.output,l);t.next_out=c,t.avail_out=r-c,c&&t.output.set(t.output.subarray(l,l+c),0),this.onData(u)}else this.onData(t.output.length===t.next_out?t.output:t.output.subarray(0,t.next_out));if(!(i===pn&&o===0)){if(i===da)return i=Pe.inflateEnd(this.strm),this.onEnd(i),this.ended=!0,!0;if(t.avail_in===0)break}}return!0},gn.prototype.onData=function(e){this.chunks.push(e)},gn.prototype.onEnd=function(e){e===pn&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=Pn.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};function ha(e,n){const t=new gn(n);if(t.push(e),t.err)throw t.msg||it[t.err];return t.result}function _h(e,n){return n=n||{},n.raw=!0,ha(e,n)}var wh=gn,Ch=ha,Sh=_h,Ah=ha,Eh=ot,kh={Inflate:wh,inflate:Ch,inflateRaw:Sh,ungzip:Ah,constants:Eh};const{Deflate:Rh,deflate:xh,deflateRaw:Th,gzip:Lh}=Zf,{Inflate:Oh,inflate:Mh,inflateRaw:Nh,ungzip:Dh}=kh;var Fh=Rh,Zh=xh,Bh=Th,Uh=Lh,zh=Oh,Wh=Mh,Vh=Nh,Ph=Dh,Hh=ot,us={Deflate:Fh,deflate:Zh,deflateRaw:Bh,gzip:Uh,Inflate:zh,inflate:Wh,inflateRaw:Vh,ungzip:Ph,constants:Hh};const ds="3.7.7",Gh=ds,Ut=typeof Buffer=="function",fs=typeof TextDecoder=="function"?new TextDecoder:void 0,hs=typeof TextEncoder=="function"?new TextEncoder:void 0,Xh="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",mn=Array.prototype.slice.call(Xh),qn=(e=>{let n={};return e.forEach((t,r)=>n[t]=r),n})(mn),jh=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/,ae=String.fromCharCode.bind(String),ps=typeof Uint8Array.from=="function"?Uint8Array.from.bind(Uint8Array):e=>new Uint8Array(Array.prototype.slice.call(e,0)),gs=e=>e.replace(/=/g,"").replace(/[+\/]/g,n=>n=="+"?"-":"_"),ms=e=>e.replace(/[^A-Za-z0-9\+\/]/g,""),vs=e=>{let n,t,r,a,i="";const s=e.length%3;for(let o=0;o<e.length;){if((t=e.charCodeAt(o++))>255||(r=e.charCodeAt(o++))>255||(a=e.charCodeAt(o++))>255)throw new TypeError("invalid character found");n=t<<16|r<<8|a,i+=mn[n>>18&63]+mn[n>>12&63]+mn[n>>6&63]+mn[n&63]}return s?i.slice(0,s-3)+"===".substring(s):i},pa=typeof btoa=="function"?e=>btoa(e):Ut?e=>Buffer.from(e,"binary").toString("base64"):vs,ga=Ut?e=>Buffer.from(e).toString("base64"):e=>{let t=[];for(let r=0,a=e.length;r<a;r+=4096)t.push(ae.apply(null,e.subarray(r,r+4096)));return pa(t.join(""))},Qn=(e,n=!1)=>n?gs(ga(e)):ga(e),Yh=e=>{if(e.length<2){var n=e.charCodeAt(0);return n<128?e:n<2048?ae(192|n>>>6)+ae(128|n&63):ae(224|n>>>12&15)+ae(128|n>>>6&63)+ae(128|n&63)}else{var n=65536+(e.charCodeAt(0)-55296)*1024+(e.charCodeAt(1)-56320);return ae(240|n>>>18&7)+ae(128|n>>>12&63)+ae(128|n>>>6&63)+ae(128|n&63)}},Kh=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,bs=e=>e.replace(Kh,Yh),ys=Ut?e=>Buffer.from(e,"utf8").toString("base64"):hs?e=>ga(hs.encode(e)):e=>pa(bs(e)),zt=(e,n=!1)=>n?gs(ys(e)):ys(e),Is=e=>zt(e,!0),Jh=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,qh=e=>{switch(e.length){case 4:var n=(7&e.charCodeAt(0))<<18|(63&e.charCodeAt(1))<<12|(63&e.charCodeAt(2))<<6|63&e.charCodeAt(3),t=n-65536;return ae((t>>>10)+55296)+ae((t&1023)+56320);case 3:return ae((15&e.charCodeAt(0))<<12|(63&e.charCodeAt(1))<<6|63&e.charCodeAt(2));default:return ae((31&e.charCodeAt(0))<<6|63&e.charCodeAt(1))}},_s=e=>e.replace(Jh,qh),ws=e=>{if(e=e.replace(/\s+/g,""),!jh.test(e))throw new TypeError("malformed base64.");e+="==".slice(2-(e.length&3));let n,t="",r,a;for(let i=0;i<e.length;)n=qn[e.charAt(i++)]<<18|qn[e.charAt(i++)]<<12|(r=qn[e.charAt(i++)])<<6|(a=qn[e.charAt(i++)]),t+=r===64?ae(n>>16&255):a===64?ae(n>>16&255,n>>8&255):ae(n>>16&255,n>>8&255,n&255);return t},ma=typeof atob=="function"?e=>atob(ms(e)):Ut?e=>Buffer.from(e,"base64").toString("binary"):ws,Cs=Ut?e=>ps(Buffer.from(e,"base64")):e=>ps(ma(e).split("").map(n=>n.charCodeAt(0))),Ss=e=>Cs(As(e)),Qh=Ut?e=>Buffer.from(e,"base64").toString("utf8"):fs?e=>fs.decode(Cs(e)):e=>_s(ma(e)),As=e=>ms(e.replace(/[-_]/g,n=>n=="-"?"+":"/")),va=e=>Qh(As(e)),$h=e=>{if(typeof e!="string")return!1;const n=e.replace(/\s+/g,"").replace(/={0,2}$/,"");return!/[^\s0-9a-zA-Z\+/]/.test(n)||!/[^\s0-9a-zA-Z\-_]/.test(n)},Es=e=>({value:e,enumerable:!1,writable:!0,configurable:!0}),ks=function(){const e=(n,t)=>Object.defineProperty(String.prototype,n,Es(t));e("fromBase64",function(){return va(this)}),e("toBase64",function(n){return zt(this,n)}),e("toBase64URI",function(){return zt(this,!0)}),e("toBase64URL",function(){return zt(this,!0)}),e("toUint8Array",function(){return Ss(this)})},Rs=function(){const e=(n,t)=>Object.defineProperty(Uint8Array.prototype,n,Es(t));e("toBase64",function(n){return Qn(this,n)}),e("toBase64URI",function(){return Qn(this,!0)}),e("toBase64URL",function(){return Qn(this,!0)})},$n={version:ds,VERSION:Gh,atob:ma,atobPolyfill:ws,btoa:pa,btoaPolyfill:vs,fromBase64:va,toBase64:zt,encode:zt,encodeURI:Is,encodeURL:Is,utob:bs,btou:_s,decode:va,isValid:$h,fromUint8Array:Qn,toUint8Array:Ss,extendString:ks,extendUint8Array:Rs,extendBuiltins:()=>{ks(),Rs()}};var ep=5e3,tp=3,He,xs=function(){function e(){this.eventList=[{scope:"".concat(B(),"-"),eventList:[]}],this.init()}return e.prototype.init=function(){var n=this;this.closeCallback=Jt({emit:function(t,r){var a=n.eventList[n.eventList.length-1];a.eventList.push(t),r&&(n.eventList.length>0&&(n.eventList[n.eventList.length-1].scope=a.scope+B()),n.eventList.length>tp&&n.eventList.shift(),n.eventList.push({scope:"".concat(B(),"-"),eventList:[]}))},recordCanvas:!0,checkoutEveryNms:ep})},e.prototype.close=function(){var n;(n=this.closeCallback)===null||n===void 0||n.call(this),this.closeCallback=void 0},e}();function np(){Rc(b.options,function(e,n){e.recordScreen!==n.recordScreen&&(e.recordScreen?He=new xs:(He?.close(),He=void 0))}),He=b.options.value.recordScreen?new xs:void 0}function rp(){var e;return(e=He?.eventList)!==null&&e!==void 0?e:[]}function ap(e){if(!e)return e;var n=typeof e!="string"&&typeof e!="number"?JSON.stringify(e):e,t=$n.encode(n),r=us.gzip(t),a=Array.from(r),i="";return a.forEach(function(s){i+=String.fromCharCode(s)}),$n.btoa(i)}function ip(e){var n=$n.atob(e),t=n.split("").map(function(u){return u.charCodeAt(0)}),r=new Uint8Array(t),a=us.ungzip(r),i="",s=8*1024,o;for(o=0;o<a.length/s;o++)i+=String.fromCharCode.apply(null,a.slice(o*s,(o+1)*s));i+=String.fromCharCode.apply(null,a.slice(o*s));var l=$n.decode(i),c="";try{c=JSON.parse(l)}catch(u){/Unexpected token o in JSON at position 0/.test(u)&&(c=l)}return c}var op=2e3,sp=2e4,er=5,ba=["errMessage","eventId","requestUrl"],cp=function(){function e(){this.cacheErrorA=[],this.cacheErrorB=[],this.throttleProxyAddCacheErrorA=Mc(this.proxyAddCacheErrorA,op),this.throttleProxyAddCacheErrorB=Da(this.proxyAddCacheErrorB,sp)}return e.prototype.proxyAddCacheErrorA=function(){var n,t=this.cacheErrorA.length;if(t){var r=ur.apply(void 0,ie([this.cacheErrorA],ba,!1)),a=r.filter(function(o){return o.length<er}),i=r.filter(function(o){return o.length>=er});if(a.length&&K.emit(a.flat(1/0)),i.length){var s=[];i.forEach(function(o){var l=o[0];l.batchError=!0,l.batchErrorLength=o.length,l.batchErrorLastHappenTime=o[o.length-1].triggerTime,s.push(l)}),(n=this.cacheErrorB).push.apply(n,s),this.throttleProxyAddCacheErrorB()}for(;t--;)this.cacheErrorA.shift()}},e.prototype.proxyAddCacheErrorB=function(){var n=this.cacheErrorB.length;if(n){for(var t=ur.apply(void 0,ie([this.cacheErrorB],ba,!1));n--;)this.cacheErrorB.shift();var r=[];t.forEach(function(a){var i=a[0];a.length>1&&(i.batchErrorLength=a.reduce(function(s,o){return s+=o.batchErrorLength},0),i.batchErrorLastHappenTime=a[a.length-1].triggerTime),r.push(i)}),K.emit(r)}},e.prototype.sendAllCacheError=function(){var n=this.cacheErrorA.concat(this.cacheErrorB),t=ur.apply(void 0,ie([n],ba,!1)),r=t.filter(function(s){return s.length<er}),a=t.filter(function(s){return s.length>=er});if(r.length&&K.emit(r.flat(1/0),!0),a.length){var i=[];a.forEach(function(s){var o=s[0];o.batchError=!0,o.batchErrorLength=s.length,o.batchErrorLastHappenTime=s[s.length-1].triggerTime,i.push(o)}),K.emit(i,!0)}},e.prototype.pushCacheErrorA=function(n){this.cacheErrorA.push(n),this.throttleProxyAddCacheErrorA(),this.cacheErrorA.length>=50&&(this.proxyAddCacheErrorA(),this.proxyAddCacheErrorB())},e}(),ya;function lp(){ya=new cp}function up(e){var n=e.map(function(t){if(t===null)return"null";if(t===void 0)return"undefined";if(typeof t=="string")return t;if(typeof t=="number"||typeof t=="boolean")return String(t);if(typeof t=="function")return"[Function: ".concat(t.name||"anonymous","]");if(t instanceof Error)return"".concat(t.name,": ").concat(t.message).concat(t.stack?`
`+t.stack:"");if(typeof t=="object")try{return JSON.stringify(t,null,2)}catch{return t.toString()}return String(t)});return n.join(" | ")}function Ts(e){var n=e.stack,t=n===void 0?"":n,r=e.message,a=r===void 0?"":r,i={eventId:b.SENDID.CODE,errMessage:a,errStack:t};if(t){var s=/^\s*at\s*([^(]+)\s*\((.+?):(\d+):(\d+)\)$/,o=/^\s*([^@]*)@(.+?):(\d+):(\d+)$/,l=t.replace(new RegExp("^[\\w\\s:]*".concat(a,`
`)),""),c=Za(zc(l.split(`
`),function(h){return h}),function(h){var d=h.match(s);if(d)return{triggerPageUrl:d[2],line:d[3],col:d[4]};var f=h.match(o);return f?{triggerPageUrl:f[2],line:f[3],col:f[4]}:{}}),u=c[0]||{};return x(x({},i),u)}return i}function vn(e){if(e instanceof Error){var n=e,t=n.message,r=n.stack,a=n.lineNumber,i=n.fileName,s=n.columnNumber;return i?{errMessage:t,errStack:r,eventId:b.SENDID.CODE,line:a,col:s,triggerPageUrl:i}:Ts(e)}return e.message?Ts(e):typeof e=="string"?{eventId:b.SENDID.REJECT,errMessage:e}:wn(e)?{eventId:b.SENDID.CONSOLEERROR,errMessage:up(e)}:{}}function dp(e){return e.reason!==void 0}function Ls(e){if(dp(e))return x({eventId:b.SENDID.CODE},vn(e.reason));var n=e.target;if(n instanceof HTMLElement&&n.nodeType===1){var t={initiatorType:n.nodeName.toLowerCase(),eventId:b.SENDID.RESOURCE,requestUrl:""};switch(n.nodeName.toLowerCase()){case"link":t.requestUrl=n.href;break;default:t.requestUrl=n.currentSrc||n.src}return t}if(e.error){var r=e.error;return r.fileName=r.filename||e.filename,r.columnNumber=r.colno||e.colno,r.lineNumber=r.lineno||e.lineno,x({eventId:b.SENDID.CODE},vn(r))}return{eventId:b.SENDID.CODE,line:L.event.errorLine,col:L.event.errorCharacter,errMessage:L.event.errorMessage,triggerPageUrl:L.event.errorUrl}}function Ia(e){if(!b.options.value.ignoreErrors.length)return!1;var n=e.errMessage||e.message;return n?(n=String(n),b.options.value.ignoreErrors.some(function(t){return rr(t)?t.test(n)?(gt("ignoreErrors\u62E6\u622A\u6210\u529F - \u622A\u6761\u4EF6:".concat(t," \u9519\u8BEF\u4FE1\u606F:").concat(n)),!0):!1:n===t?(gt("ignoreErrors\u62E6\u622A\u6210\u529F - \u622A\u6761\u4EF6:".concat(t," \u9519\u8BEF\u4FE1\u606F:").concat(n)),!0):!1})):!1}function fp(){var e=JSON.parse(JSON.stringify(rp()));return e.slice(-2).map(function(n){return n.eventList}).flat()}function tr(e,n){n===void 0&&(n=!1);var t=x(x({},e),{eventType:pe.ERROR,recordscreen:b.options.value.recordScreen?ap(fp()):null,triggerPageUrl:me(),triggerTime:B()});b.options.value.scopeError?ya.pushCacheErrorA(t):K.emit(t,n)}function hp(){b.options.value.error.core&&(b.options.value.scopeError&&(lp(),M.addEvent({type:E.BEFOREUNLOAD,callback:function(){ya.sendAllCacheError()}})),M.addEvent({type:E.ERROR,callback:function(e){var n=Ls(e);Ia(n)||tr(n)}}),M.addEvent({type:E.UNHANDLEDREJECTION,callback:function(e){var n=Ls(e);Ia(n)||tr(n)}}),M.addEvent({type:E.CONSOLEERROR,callback:function(e){var n=vn(e);Ia(n)||tr(x({eventId:b.SENDID.CODE},n))}}))}function bn(e,n){e===void 0&&(e={}),n===void 0&&(n=!1),tr(e,n)}function _a(e,n){return e.find(function(t){return t.hasAttribute&&t.hasAttribute(n)})}function Os(e){if(e.length>0){var n=["em","b","strong","span","img","i","code"],t=e.filter(function(r){var a=r.tagName;return n.indexOf(a.toLowerCase())>=0});return t.length===e.length}return!0}function Ms(e,n){if(n===void 0&&(n=""),!e)return n;var t=e.parentElement,r=e.id,a=e.tagName.toLowerCase(),i=n?">".concat(n):"";return!t||t===document.documentElement||t===document.body?"".concat(a).concat(i):r?"#".concat(r).concat(i):Ms(t,"".concat(a).concat(i))}var pp=function(){function e(n){n===void 0&&(n={});var t=this;this.eventId="",this.eventType="",this.title="",this.triggerPageUrl="",this.x=-1,this.y=-1,this.params={},this.elementPath="",this.triggerTime=-1,Object.keys(n).forEach(function(r){bt(r,n)&&(t[r]=n[r]||null)})}return e}();function gp(){M.addEvent({type:E.CLICK,callback:function(e){var n=new pp({eventType:pe.CLICK}),t=e.composedPath()?e.composedPath():e.target?mp(e.target):[],r=t.find(function(u){return u.hasAttribute&&(u.hasAttribute("data-warden-container")||u.hasAttribute("data-warden-event-id")||u.hasAttribute("data-warden-title"))});if(r){var a=document.documentElement,i=a.scrollTop,s=a.scrollLeft,o=e.target.getBoundingClientRect(),l=o.top,c=o.left;n.x=c+s,n.y=l+i,n.triggerTime=B(),n.triggerPageUrl=me(),n.title=vp(r),n.eventId=Ip(t),n.params=_p(t),n.elementPath=Ms(r).slice(-128),K.emit(n)}}})}function mp(e,n){if(n===void 0&&(n={includeSelf:!0,order:"asc"}),!e)return[];for(var t=n.includeSelf,r=n.order,a=t?e:e.parentElement,i=[];a;)i=r==="asc"?i.concat(a):[a].concat(i),a=a.parentElement;return i}function vp(e){var n=Ns(e);if(n)return n;for(var t=e.parentElement;t&&t!==document.body&&!t.hasAttribute("data-warden-container");)t=t.parentElement;var r=Ns(t);if(r)return r;var a=e.tagName;return!e.hasChildNodes()||a.toLowerCase()==="svg"?bp(e):yp(e)}function Ns(e){return e?e.hasAttribute("data-warden-title")?e.getAttribute("data-warden-title"):e.title:""}function bp(e){var n=e.tagName,t=e.textContent;if(n==="IMG")return e.getAttribute("alt")||null;if(n==="svg"){var r=ie([],Array(e.children),!0).find(function(a){return a.tagName==="use"});if(r)return r.getAttribute("xlink:href")||null}return t}function yp(e){var n=e.tagName,t=e.textContent;if(n==="A"){var r=Os(ie([],Array.from(e.children),!0));return r?t:e.getAttribute("href")||null}if(n==="BUTTON"){var a=e.getAttribute("name"),r=Os(ie([],Array.from(e.children),!0));return a||r?t:e.getAttribute("href")||null}var i=ie([],Array.from(e.children),!0).filter(function(){return e.hasChildNodes()}).length;return i>0?null:t}function Ip(e){e===void 0&&(e=[]);var n=_a(e,"data-warden-event-id");if(n)return n.getAttribute("data-warden-event-id");var t=_a(e,"title");if(t)return t.getAttribute("title");var r=_a(e,"data-warden-container");if(r){if(r.getAttribute("data-warden-event-id"))return r.getAttribute("data-warden-event-id");if(r.getAttribute("title"))return r.getAttribute("title");var a=r.getAttribute("data-warden-container");if(typeof a=="string"&&a)return a}return e[0].tagName.toLowerCase()}function _p(e){e===void 0&&(e=[]);for(var n=/^data-warden-/,t,r=-1,a=0;a<e.length;a++){var i=e[a],s=i&&i.attributes&&Array.from(i.attributes)||[];if(t=s.find(function(h){return h.nodeName.match(n)?h.nodeName.match(n):h.nodeName.indexOf("data-warden-container")!==-1}),t){r=a;break}}if(r<0)return{};var o=e[r],l=Array.from(o.attributes)||[],c={},u=["container","title","event-id"];return l.forEach(function(h){if(!(h.nodeName.indexOf("data-warden")<0)){var d=h.nodeName.replace(n,"");u.includes(d)||(c[d]=h.nodeValue)}}),c}function wp(){b.options.value.event.core&&gp()}function Cp(e,n){e===void 0&&(e={}),n===void 0&&(n=!1),K.emit(x(x({},e),{eventType:pe.CUSTOM,triggerTime:B(),triggerPageUrl:me()}),n)}var ft={performance:!!L.performance,getEntriesByType:!!(L.performance&&L.performance.getEntriesByType),PerformanceObserver:"PerformanceObserver"in L,MutationObserver:"MutationObserver"in L,PerformanceNavigationTiming:"PerformanceNavigationTiming"in L},Sp={initiatorType:"",transferSize:0,encodedBodySize:0,decodedBodySize:0,duration:0,redirectStart:0,redirectEnd:0,startTime:0,fetchStart:0,domainLookupStart:0,domainLookupEnd:0,connectStart:0,connectEnd:0,requestStart:0,responseStart:0,responseEnd:0,workerStart:0};function Ds(e){var n=["img","script","link","audio","video","css"],t=e.getEntriesByType("resource"),r=[];return t.forEach(function(a){var i=a.initiatorType,s=i===void 0?"":i;if(!(n.indexOf(s.toLowerCase())<0)){if(Sn.length){var o=Sn.findIndex(function(c){return c.src===a.name});if(o!==-1){Sn.splice(o,1);return}}var l={};Object.keys(Sp).forEach(function(c){bt(c,a)&&(l[c]=a[c])}),r.push(Vt(x(x({},l),{eventType:pe.PERFORMANCE,eventId:b.SENDID.RESOURCE,requestUrl:a.name,triggerTime:B(),triggerPageUrl:me()})))}}),r.length&&K.emit(r),r}function Ap(){var e=["img","script","link"],n=new MutationObserver(function(t){for(var r=function(i){var s=B(),o=t[i].addedNodes,l=o===void 0?[]:o;l.forEach(function(c){var u=c.nodeName;e.indexOf(u.toLowerCase())!==-1&&(Ie(c,E.LOAD,function(){K.emit(Vt({eventType:pe.PERFORMANCE,eventId:b.SENDID.RESOURCE,requestUrl:c.src||c.href,duration:B()-s,triggerTime:B(),triggerPageUrl:me()}))}),Ie(c,E.ERROR,function(){K.emit(Vt({eventType:pe.PERFORMANCE,eventId:b.SENDID.RESOURCE,requestUrl:c.src||c.href,responseStatus:"error",duration:B()-s,triggerTime:B(),triggerPageUrl:me()}))}))})},a=0;a<t.length;a+=1)r(a)});n.observe(L.document,{subtree:!0,childList:!0})}function Ep(){var e={},n=L.performance,t=n.timing;if(e.fmp=0,ft.getEntriesByType){var r=n.getEntriesByType("paint");if(r.length&&(e.fmp=r[r.length-1].startTime),ft.PerformanceNavigationTiming){var a=n.getEntriesByType("navigation")[0];a&&(t=a)}}e.fmp&&ft.PerformanceNavigationTiming&&(e.fmp-=t.fetchStart),e.tti=t.domInteractive-t.fetchStart,e.ready=t.domContentLoadedEventEnd-t.fetchStart,e.loadon=t.loadEventStart-t.fetchStart,e.firstbyte=t.responseStart-t.domainLookupStart,e.dns=t.domainLookupEnd-t.domainLookupStart,e.appcache=t.domainLookupStart-t.fetchStart,e.tcp=t.connectEnd-t.connectStart,e.ttfb=t.responseStart-t.requestStart,e.trans=t.responseEnd-t.responseStart,e.dom=t.domInteractive-t.responseEnd,e.res=t.loadEventStart-t.domContentLoadedEventEnd,e.ssllink=t.connectEnd-t.secureConnectionStart,e.redirect=t.redirectEnd-t.redirectStart,e.unloadTime=t.unloadEventEnd-t.unloadEventStart;var i=x(x({},e),{triggerPageUrl:me()});he.firstScreen=x({},i),K.emit(Vt(x(x({},i),{eventType:pe.PERFORMANCE,eventId:b.SENDID.PAGE})))}function Fs(){if(ft.performance&&b.options.value.performance.firstResource&&Ep(),ft.performance&&b.options.value.performance.core)if(Ds(L.performance),ft.PerformanceObserver){var e=new PerformanceObserver(Ds);e.observe({entryTypes:["resource"]})}else ft.MutationObserver&&Ap()}function kp(){!b.options.value.performance.firstResource&&!b.options.value.performance.core||(document.readyState==="complete"?Fs():M.addEvent({type:E.LOAD,callback:function(){Fs()}}))}function wa(e,n){e===void 0&&(e={}),n===void 0&&(n=!1);var t=x(x({},e),{triggerTime:B(),triggerPageUrl:me(),eventType:pe.PERFORMANCE});K.emit(Vt(t),n)}function Rp(){var e=this;M.addEvent({type:E.FETCH,callback:function(n){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];return ic(e,ie([n],t,!0),void 0,function(a,i,s,o,l){var c,u,h,d,f,p,v,g,I,_,m;return i===void 0&&(i={}),l===void 0&&(l={}),oc(this,function(y){switch(y.label){case 0:return c=i.method,u=c===void 0?"GET":c,h=i.body,d=h===void 0?{}:h,f=s.url,p=s.status,v=s.statusText,g=s.clone(),I=String(u).toLocaleLowerCase(),Bs(f)?[2]:p===200||p===304?b.options.value.performance.server?[4,g.json()]:[3,2]:[3,3];case 1:_=y.sent(),m=Zs(_),b.options.value.isParseDataCode&&!m.isSuccess?bn({eventId:b.SENDID.SERVER,errMessage:m.message,requestUrl:Fa(f),requestMethod:I,requestType:"xhr",responseStatus:m.code,params:u.toUpperCase()==="POST"?d:En(f)}):wa(x(x({eventId:b.SENDID.SERVER,requestUrl:f,triggerTime:o,duration:B()-o,responseStatus:p,requestMethod:I,requestType:"fetch"},l),{params:u.toUpperCase()==="POST"?d:En(f)})),y.label=2;case 2:return[3,4];case 3:b.options.value.error.server&&bn(x(x({eventId:b.SENDID.SERVER,triggerTime:o,duration:B()-o,errMessage:v,requestUrl:Fa(f),responseStatus:p,requestMethod:I,requestType:"fetch"},l),{params:u.toUpperCase()==="POST"?d:En(f)})),y.label=4;case 4:return[2]}})})}})}var xp=function(){function e(n){n===void 0&&(n={});var t=this;this.requestUrl="",this.requestMethod="",this.requestParams={},this.triggerTime=-1,Object.keys(n).forEach(function(r){bt(r,n)&&(t[r]=n[r]||null)})}return e}();function Tp(){var e=new xp;M.addEvent({type:E.XHROPEN,callback:function(n,t){e.requestMethod=String(n).toLocaleLowerCase(),e.requestUrl=t,e.requestParams=En(t)}}),M.addEvent({type:E.XHRSEND,callback:function(n,t){Ie(n,E.READYSTATECHANGE,function(){var r=n.readyState,a=n.status,i=n.responseURL,s=n.statusText,o=n.responseType===""||n.responseType==="text"?n.responseText:"";if(r===4){var l=i||e.requestUrl;if(Bs(l))return;if(a===200||a===304){if(b.options.value.performance.server||b.options.value.error.server){var c=Zs(o);b.options.value.isParseDataCode&&!c.isSuccess?bn({eventId:b.SENDID.SERVER,errMessage:c.message,requestUrl:l,requestMethod:e.requestMethod,requestType:"xhr",responseStatus:c.code,duration:B()-e.triggerTime,params:e.requestMethod==="post"?t:e.requestParams}):b.options.value.performance.server&&wa({eventId:b.SENDID.SERVER,requestUrl:l,requestMethod:e.requestMethod,requestType:"xhr",responseStatus:a,duration:B()-e.triggerTime,params:e.requestMethod==="post"?t:e.requestParams})}}else b.options.value.error.server&&bn({eventId:b.SENDID.SERVER,errMessage:s||o,requestUrl:l,requestMethod:e.requestMethod,requestType:"xhr",responseStatus:a,params:e.requestMethod==="post"?t:e.requestParams,duration:B()-e.triggerTime})}}),e.triggerTime=B()}})}function Zs(e){var n,t,r,a,i,s,o,l,c,u,h={code:"",message:"",isSuccess:!0};try{var d=JSON.parse(e);typeof d=="object"&&d[((t=(n=b.options.value)===null||n===void 0?void 0:n.parseDataOption)===null||t===void 0?void 0:t.codeName)||"code"]&&(h={code:d[((a=(r=b.options.value)===null||r===void 0?void 0:r.parseDataOption)===null||a===void 0?void 0:a.codeName)||"code"]||d.code,message:d[((s=(i=b.options.value)===null||i===void 0?void 0:i.parseDataOption)===null||s===void 0?void 0:s.messageName)||"message"]||d.message,isSuccess:d[((l=(o=b.options.value)===null||o===void 0?void 0:o.parseDataOption)===null||l===void 0?void 0:l.codeName)||"code"]===((u=(c=b.options.value)===null||c===void 0?void 0:c.parseDataOption)===null||u===void 0?void 0:u.successCode)})}catch{return h.isSuccess=!0,h}return h}function Bs(e){return!b.options.value.ignoreRequest.length||!e?!1:b.options.value.ignoreRequest.some(function(n){return rr(n)?!!n.test(e):e===n})}function Lp(){!b.options.value.performance.server&&!b.options.value.error.server||(Tp(),Rp())}var ht=me();function Op(){if(b.options.value.pv.core){var e=!1,n=!1;In({referer:document.referrer}),M.addEvent({type:E.HISTORYPUSHSTATE,callback:function(){n||(e=!1,In({action:"navigation"}))}}),M.addEvent({type:E.HISTORYREPLACESTATE,callback:function(){n=!0,e=!1,In({action:"navigation"}),setTimeout(function(){n=!1},100)}}),M.addEvent({type:E.HASHCHANGE,callback:function(){n||(e||In(),e=!1)}}),M.addEvent({type:E.POPSTATE,callback:function(){if(!n){if(L.location.hash!==""){var t=ht.indexOf("#")>0?ht.slice(0,ht.indexOf("#")):ht;if(L.location.href.slice(0,L.location.href.indexOf("#"))===t)return}e=!0,In()}}}),M.addEvent({type:E.BEFOREUNLOAD,callback:function(){var t=B()-Ca;Object.values(yn).length>0&&t>100&&K.emit(x(x({},yn),{durationTime:t}),!0)}})}}var Ca=B(),yn={};function In(e){e===void 0&&(e={});var n=e.referer,t=n===void 0?ht:n,r=e.action,a=e.params,i=e.title,s=r;s||(s=Gc[performance.navigation.type]||""),setTimeout(function(){ht=me();var o={eventType:pe.PV,eventId:St.pageId,triggerPageUrl:me(),referer:t,params:a,title:i||document.title,action:s,triggerTime:B()};K.emit(o);var l=B()-Ca;Ca=B(),Object.values(yn).length>0&&l>100&&K.emit(x(x({},yn),{durationTime:l})),yn=x(x({},o),{eventType:pe.PVDURATION})},i?0:17)}function Mp(e,n){e===void 0&&(e={}),n===void 0&&(n=!1),K.emit(x(x({referer:ht,title:document.title},e),{eventType:pe.PV,eventId:St.pageId,triggerPageUrl:me(),triggerTime:B()}),n)}var Np=function(){function e(){this.ioMap={},this.targetMap=[],this.options={root:null,rootMargin:"0px",threshold:.5}}return e.prototype.initObserver=function(n){var t=this;return new IntersectionObserver(function(r){r.forEach(function(a){if(a.isIntersecting){var i=t.targetMap.find(function(s){return s.target===a.target});i&&(i.showTime=B())}else{var i=t.targetMap.find(function(o){return o.target===a.target});if(i){if(!i.showTime)return;i.showEndTime=B(),t.sendEvent(i)}}})},x(x({},this.options),{threshold:n}))},e.prototype.sendEvent=function(n){K.emit(x({eventType:pe.INTERSECTION,triggerPageUrl:me()},n))},e.prototype.observe=function(n){var t=this,r=hr(n);r.forEach(function(a){var i=hr(a.target);Object.prototype.hasOwnProperty.call(t.ioMap,a.threshold)||(t.ioMap[a.threshold]=t.initObserver(a.threshold||.5)),i.forEach(function(s){var o=t.targetMap.findIndex(function(l){return l.target===s});o===-1&&(t.ioMap[a.threshold].observe(s),t.targetMap.push({target:s,threshold:a.threshold,observeTime:B(),params:a.params}))})})},e.prototype.unobserve=function(n){var t=this,r=hr(n);r.forEach(function(a){var i=t.targetMap.findIndex(function(o){return o.target===a});if(i!==-1){var s=t.ioMap[t.targetMap[i].threshold];s&&(t.targetMap.splice(i,1),s.unobserve(a))}})},e.prototype.disconnect=function(){for(var n in this.ioMap)if(Object.prototype.hasOwnProperty.call(this.ioMap,n)){var t=this.ioMap[n];t.disconnect()}this.targetMap=[],this.ioMap={}},e}(),nr;function Dp(){he.intersection=new Np,nr=he.intersection}function Us(e){return ip(e)}function zs(e){ne("beforePushEventList")&&b.options.value.beforePushEventList.push(e)}function Ws(e){ne("beforeSendData")&&b.options.value.beforeSendData.push(e)}function Vs(e){ne("afterSendData")&&b.options.value.afterSendData.push(e)}function Ps(e){ne("setUserUuid")&&(b.options.value.userUuid=e)}function Hs(){if(ne("getUserUuid"))return b.options.value.userUuid}function Gs(){if(ne("getSDKUserUuid"))return b.options.value.sdkUserUuid}function Xs(){if(ne("getBaseInfo"))return x(x({},he.baseInfo.base),{userUuid:b.options.value.userUuid})}function js(){if(ne("getFirstScreen"))return x({},he.firstScreen)}function Sa(e,n){if(e===void 0&&(e={}),n===void 0&&(n=!1),!!ne("traceError"))return bn(e,n)}function Ys(e,n){if(e===void 0&&(e={}),n===void 0&&(n=!1),!!ne("tracePerformance"))return wa(e,n)}function Ks(e,n){if(e===void 0&&(e={}),n===void 0&&(n=!1),!!ne("traceCustomEvent"))return Cp(e,n)}function Js(e,n){if(e===void 0&&(e={}),n===void 0&&(n=!1),!!ne("tracePageView"))return Mp(e,n)}function qs(){return ai().then(function(e){return e[0]})}function Qs(e){ne("intersectionObserver")&&nr.observe(e)}function $s(e){ne("intersectionUnobserve")&&nr.unobserve(e)}function ec(){ne("intersectionDisconnect")&&nr.disconnect()}function tc(){if(!(!ne("sendData")&&!b.options.value.localization)){var e=xr.getItem(mr);e&&(K.sendLocal(e),xr.removeItem(mr))}}function nc(e){!ne("localizationOverFlow")&&!b.options.value.localization||(b.options.value.localizationOverFlow=e)}function rc(){return pr(b.options.value)}var ac=Object.freeze({__proto__:null,afterSendData:Vs,beforePushEventList:zs,beforeSendData:Ws,getBaseInfo:Xs,getFirstScreen:js,getIPs:qs,getOptions:rc,getSDKUserUuid:Gs,getUserUuid:Hs,intersectionDisconnect:ec,intersectionObserver:Qs,intersectionUnobserve:$s,sendLocal:tc,setLocalizationOverFlow:nc,setUserUuid:Ps,traceCustomEvent:Ks,traceError:Sa,tracePageView:Js,tracePerformance:Ys,unzipRecordscreen:Us});function Aa(e){L.__webTracingInit__||Oc(e)&&(jc(),Zl(),Dl(),Ul(),hp(),wp(),Lp(),kp(),Op(),Dp(),b.options.value.recordScreen&&np(),L.__webTracingInit__=!0)}x(x({init:Aa},ac),{options:b.options});function Fp(e,n){var t=e.config.errorHandler;e.config.errorHandler=function(r,a,i){Xe(r);var s=x({eventId:b.SENDID.CODE},vn(r));Sa(s),t&&t.apply(null,[r,a,i])},Aa(n)}var Zp={install:Fp};b.afterSendData=Vs,b.beforePushEventList=zs,b.beforeSendData=Ws,b.default=Zp,b.exportMethods=ac,b.getBaseInfo=Xs,b.getFirstScreen=js,b.getIPs=qs,b.getOptions=rc,b.getSDKUserUuid=Gs,b.getUserUuid=Hs,b.init=Aa,b.intersectionDisconnect=ec,b.intersectionObserver=Qs,b.intersectionUnobserve=$s,b.logError=Xe,b.parseError=vn,b.sendLocal=tc,b.setLocalizationOverFlow=nc,b.setUserUuid=Ps,b.traceCustomEvent=Ks,b.traceError=Sa,b.tracePageView=Js,b.tracePerformance=Ys,b.unzipRecordscreen=Us,Object.defineProperty(b,"__esModule",{value:!0})})(this.WebTracing=this.WebTracing||{});