vendor.js 391.4 KB
"use strict";
/**
* @vue/shared v3.4.21
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/
function t(t,e){const n=new Set(t.split(","));return e?t=>n.has(t.toLowerCase()):t=>n.has(t)}const e={},n=[],r=()=>{},i=()=>!1,s=t=>111===t.charCodeAt(0)&&110===t.charCodeAt(1)&&(t.charCodeAt(2)>122||t.charCodeAt(2)<97),o=t=>t.startsWith("onUpdate:"),a=Object.assign,c=(t,e)=>{const n=t.indexOf(e);n>-1&&t.splice(n,1)},u=Object.prototype.hasOwnProperty,l=(t,e)=>u.call(t,e),h=Array.isArray,f=t=>"[object Map]"===w(t),d=t=>"[object Set]"===w(t),p=t=>"function"==typeof t,g=t=>"string"==typeof t,m=t=>"symbol"==typeof t,y=t=>null!==t&&"object"==typeof t,v=t=>(y(t)||p(t))&&p(t.then)&&p(t.catch),_=Object.prototype.toString,w=t=>_.call(t),S=t=>"[object Object]"===w(t),b=t=>g(t)&&"NaN"!==t&&"-"!==t[0]&&""+parseInt(t,10)===t,E=t(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),T=t=>{const e=Object.create(null);return n=>e[n]||(e[n]=t(n))},x=/-(\w)/g,I=T((t=>t.replace(x,((t,e)=>e?e.toUpperCase():"")))),D=/\B([A-Z])/g,A=T((t=>t.replace(D,"-$1").toLowerCase())),k=T((t=>t.charAt(0).toUpperCase()+t.slice(1))),O=T((t=>t?`on${k(t)}`:"")),R=(t,e)=>!Object.is(t,e),P=(t,e)=>{for(let n=0;n<t.length;n++)t[n](e)},M=t=>{const e=parseFloat(t);return isNaN(e)?t:e};function C(t){if(h(t)){const e={};for(let n=0;n<t.length;n++){const r=t[n],i=g(r)?j(r):C(r);if(i)for(const t in i)e[t]=i[t]}return e}if(g(t)||y(t))return t}const B=/;(?![^(]*\))/g,N=/:([^]+)/,L=/\/\*[^]*?\*\//g;function j(t){const e={};return t.replace(L,"").split(B).forEach((t=>{if(t){const n=t.split(N);n.length>1&&(e[n[0].trim()]=n[1].trim())}})),e}function V(t){let e="";if(g(t))e=t;else if(h(t))for(let n=0;n<t.length;n++){const r=V(t[n]);r&&(e+=r+" ")}else if(y(t))for(const n in t)t[n]&&(e+=n+" ");return e.trim()}const U=(t,e)=>e&&e.__v_isRef?U(t,e.value):f(e)?{[`Map(${e.size})`]:[...e.entries()].reduce(((t,[e,n],r)=>(t[$(e,r)+" =>"]=n,t)),{})}:d(e)?{[`Set(${e.size})`]:[...e.values()].map((t=>$(t)))}:m(e)?$(e):!y(e)||h(e)||S(e)?e:String(e),$=(t,e="")=>{var n;return m(t)?`Symbol(${null!=(n=t.description)?n:e})`:t};function H(t,e=null){let n;return(...r)=>(t&&(n=t.apply(e,r),t=null),n)}function q(t,e){if(!g(e))return;const n=(e=e.replace(/\[(\d+)\]/g,".$1")).split(".");let r=n[0];return t||(t={}),1===n.length?t[r]:q(t[r],n.slice(1).join("."))}function F(t){let e={};return S(t)&&Object.keys(t).sort().forEach((n=>{const r=n;e[r]=t[r]})),Object.keys(e)?e:t}const K=/:/g;const z=encodeURIComponent;function W(t,e=z){const n=t?Object.keys(t).map((n=>{let r=t[n];return void 0===typeof r||null===r?r="":S(r)&&(r=JSON.stringify(r)),e(n)+"="+e(r)})).filter((t=>t.length>0)).join("&"):null;return n?`?${n}`:""}const J=["onInit","onLoad","onShow","onHide","onUnload","onBackPress","onPageScroll","onTabItemTap","onReachBottom","onPullDownRefresh","onShareTimeline","onShareAppMessage","onShareChat","onAddToFavorites","onSaveExitState","onNavigationBarButtonTap","onNavigationBarSearchInputClicked","onNavigationBarSearchInputChanged","onNavigationBarSearchInputConfirmed","onNavigationBarSearchInputFocusChanged"];const G=["onShow","onHide","onLaunch","onError","onThemeChange","onPageNotFound","onUnhandledRejection","onExit","onInit","onLoad","onReady","onUnload","onResize","onBackPress","onPageScroll","onTabItemTap","onReachBottom","onPullDownRefresh","onShareTimeline","onAddToFavorites","onShareAppMessage","onShareChat","onSaveExitState","onNavigationBarButtonTap","onNavigationBarSearchInputClicked","onNavigationBarSearchInputChanged","onNavigationBarSearchInputConfirmed","onNavigationBarSearchInputFocusChanged"],Y=(()=>({onPageScroll:1,onShareAppMessage:2,onShareTimeline:4}))();function Z(t,e,n=!0){return!(n&&!p(e))&&(G.indexOf(t)>-1||0===t.indexOf("on"))}let X;const Q=[];const et=H(((t,e)=>e(t))),nt=function(){};nt.prototype={_id:1,on:function(t,e,n){var r=this.e||(this.e={});return(r[t]||(r[t]=[])).push({fn:e,ctx:n,_id:this._id}),this._id++},once:function(t,e,n){var r=this;function i(){r.off(t,i),e.apply(n,arguments)}return i._=e,this.on(t,i,n)},emit:function(t){for(var e=[].slice.call(arguments,1),n=((this.e||(this.e={}))[t]||[]).slice(),r=0,i=n.length;r<i;r++)n[r].fn.apply(n[r].ctx,e);return this},off:function(t,e){var n=this.e||(this.e={}),r=n[t],i=[];if(r&&e){for(var s=r.length-1;s>=0;s--)if(r[s].fn===e||r[s].fn._===e||r[s]._id===e){r.splice(s,1);break}i=r}return i.length?n[t]=i:delete n[t],this}};var rt=nt;const it=["{","}"];const st=/^(?:\d)+/,ot=/^(?:\w)+/;const at=Object.prototype.hasOwnProperty,ct=(t,e)=>at.call(t,e),ut=new class{constructor(){this._caches=Object.create(null)}interpolate(t,e,n=it){if(!e)return[t];let r=this._caches[t];return r||(r=function(t,[e,n]){const r=[];let i=0,s="";for(;i<t.length;){let o=t[i++];if(o===e){s&&r.push({type:"text",value:s}),s="";let e="";for(o=t[i++];void 0!==o&&o!==n;)e+=o,o=t[i++];const a=o===n,c=st.test(e)?"list":a&&ot.test(e)?"named":"unknown";r.push({value:e,type:c})}else s+=o}return s&&r.push({type:"text",value:s}),r}(t,n),this._caches[t]=r),function(t,e){const n=[];let r=0;const i=Array.isArray(e)?"list":(s=e,null!==s&&"object"==typeof s?"named":"unknown");var s;if("unknown"===i)return n;for(;r<t.length;){const s=t[r];switch(s.type){case"text":n.push(s.value);break;case"list":n.push(e[parseInt(s.value,10)]);break;case"named":"named"===i&&n.push(e[s.value])}r++}return n}(r,e)}};function lt(t,e){if(!t)return;if(t=t.trim().replace(/_/g,"-"),e&&e[t])return t;if("chinese"===(t=t.toLowerCase()))return"zh-Hans";if(0===t.indexOf("zh"))return t.indexOf("-hans")>-1?"zh-Hans":t.indexOf("-hant")>-1?"zh-Hant":(n=t,["-tw","-hk","-mo","-cht"].find((t=>-1!==n.indexOf(t)))?"zh-Hant":"zh-Hans");var n;let r=["en","fr","es"];e&&Object.keys(e).length>0&&(r=Object.keys(e));const i=function(t,e){return e.find((e=>0===t.indexOf(e)))}(t,r);return i||void 0}class ht{constructor({locale:t,fallbackLocale:e,messages:n,watcher:r,formater:i}){this.locale="en",this.fallbackLocale="en",this.message={},this.messages={},this.watchers=[],e&&(this.fallbackLocale=e),this.formater=i||ut,this.messages=n||{},this.setLocale(t||"en"),r&&this.watchLocale(r)}setLocale(t){const e=this.locale;this.locale=lt(t,this.messages)||this.fallbackLocale,this.messages[this.locale]||(this.messages[this.locale]={}),this.message=this.messages[this.locale],e!==this.locale&&this.watchers.forEach((t=>{t(this.locale,e)}))}getLocale(){return this.locale}watchLocale(t){const e=this.watchers.push(t)-1;return()=>{this.watchers.splice(e,1)}}add(t,e,n=!0){const r=this.messages[t];r?n?Object.assign(r,e):Object.keys(e).forEach((t=>{ct(r,t)||(r[t]=e[t])})):this.messages[t]=e}f(t,e,n){return this.formater.interpolate(t,e,n).join("")}t(t,e,n){let r=this.message;return"string"==typeof e?(e=lt(e,this.messages))&&(r=this.messages[e]):n=e,ct(r,t)?this.formater.interpolate(r[t],n).join(""):(console.warn(`Cannot translate the value of keypath ${t}. Use the value of keypath as default.`),t)}}function ft(t){return function(){try{return t.apply(t,arguments)}catch(ba){console.error(ba)}}}let dt=1;const pt={};function gt(t,e,n){if("number"==typeof t){const r=pt[t];if(r)return r.keepAlive||delete pt[t],r.callback(e,n)}return e}const mt="success",yt="fail",vt="complete";function _t(t,e={},{beforeAll:n,beforeSuccess:r}={}){S(e)||(e={});const{success:i,fail:s,complete:o}=function(t){const e={};for(const n in t){const r=t[n];p(r)&&(e[n]=ft(r),delete t[n])}return e}(e),a=p(i),c=p(s),u=p(o),l=dt++;return function(t,e,n,r=!1){pt[t]={name:e,keepAlive:r,callback:n}}(l,t,(l=>{(l=l||{}).errMsg=function(t,e){return t&&-1!==t.indexOf(":fail")?e+t.substring(t.indexOf(":fail")):e+":ok"}(l.errMsg,t),p(n)&&n(l),l.errMsg===t+":ok"?(p(r)&&r(l,e),a&&i(l)):c&&s(l),u&&o(l)})),l}const wt="success",St="fail",bt="complete",Et={},Tt={};function xt(t,e){return function(n){return t(n,e)||n}}function It(t,e,n){let r=!1;for(let i=0;i<t.length;i++){const s=t[i];if(r)r=Promise.resolve(xt(s,n));else{const t=s(e,n);if(v(t)&&(r=Promise.resolve(t)),!1===t)return{then(){},catch(){}}}}return r||{then:t=>t(e),catch(){}}}function Dt(t,e={}){return[wt,St,bt].forEach((n=>{const r=t[n];if(!h(r))return;const i=e[n];e[n]=function(t){It(r,t,e).then((t=>p(i)&&i(t)||t))}})),e}function At(t,e){const n=[];h(Et.returnValue)&&n.push(...Et.returnValue);const r=Tt[t];return r&&h(r.returnValue)&&n.push(...r.returnValue),n.forEach((t=>{e=t(e)||e})),e}function kt(t){const e=Object.create(null);Object.keys(Et).forEach((t=>{"returnValue"!==t&&(e[t]=Et[t].slice())}));const n=Tt[t];return n&&Object.keys(n).forEach((t=>{"returnValue"!==t&&(e[t]=(e[t]||[]).concat(n[t]))})),e}function Ot(t,e,n,r){const i=kt(t);if(i&&Object.keys(i).length){if(h(i.invoke)){return It(i.invoke,n).then((n=>e(Dt(kt(t),n),...r)))}return e(Dt(i,n),...r)}return e(n,...r)}function Rt(t,e){return(n={},...r)=>function(t){return!(!S(t)||![mt,yt,vt].find((e=>p(t[e]))))}(n)?At(t,Ot(t,e,n,r)):At(t,new Promise(((i,s)=>{Ot(t,e,a(n,{success:i,fail:s}),r)})))}function Pt(t,e,n,r={}){const i=e+":fail";let s="";return s=n?0===n.indexOf(i)?n:i+" "+n:i,delete r.errCode,gt(t,a({errMsg:s},r))}function Mt(t,e,n,r){const i=function(t,e){t[0]}(e);if(i)return i}function Ct(t,e,n,r){return n=>{const i=_t(t,n,r),s=Mt(0,[n]);return s?Pt(i,t,s):e(n,{resolve:e=>function(t,e,n){return gt(t,a(n||{},{errMsg:e+":ok"}))}(i,t,e),reject:(e,n)=>Pt(i,t,function(t){return!t||g(t)?t:t.stack?("undefined"!=typeof globalThis&&globalThis.harmonyChannel||console.error(t.message+"\n"+t.stack),t.message):t}(e),n)})}}function Bt(t,e,n,r){return function(t,e,n,r){return(...t)=>{const n=Mt(0,t);if(n)throw new Error(n);return e.apply(null,t)}}(0,e)}let Nt=!1,Lt=0,jt=0;const Vt=Bt(0,((t,e)=>{if(0===Lt&&function(){const{windowWidth:t,pixelRatio:e,platform:n}=Object.assign({},wx.getWindowInfo(),{platform:wx.getDeviceInfo().platform});Lt=t,jt=e,Nt="ios"===n}(),0===(t=Number(t)))return 0;let n=t/750*(e||Lt);return n<0&&(n=-n),n=Math.floor(n+1e-4),0===n&&(n=1!==jt&&Nt?.5:1),t<0?-n:n}));function Ut(t,e){Object.keys(e).forEach((n=>{p(e[n])&&(t[n]=function(t,e){const n=e?t?t.concat(e):h(e)?e:[e]:t;return n?function(t){const e=[];for(let n=0;n<t.length;n++)-1===e.indexOf(t[n])&&e.push(t[n]);return e}(n):n}(t[n],e[n]))}))}function $t(t,e){t&&e&&Object.keys(e).forEach((n=>{const r=t[n],i=e[n];h(r)&&p(i)&&c(r,i)}))}const Ht=Bt(0,((t,e)=>{g(t)&&S(e)?Ut(Tt[t]||(Tt[t]={}),e):S(t)&&Ut(Et,t)})),qt=Bt(0,((t,e)=>{g(t)?S(e)?$t(Tt[t],e):delete Tt[t]:S(t)&&$t(Et,t)}));const Ft=new class{constructor(){this.$emitter=new rt}on(t,e){return this.$emitter.on(t,e)}once(t,e){return this.$emitter.once(t,e)}off(t,e){t?this.$emitter.off(t,e):this.$emitter.e={}}emit(t,...e){this.$emitter.emit(t,...e)}},Kt=Bt(0,((t,e)=>(Ft.on(t,e),()=>Ft.off(t,e)))),zt=Bt(0,((t,e)=>(Ft.once(t,e),()=>Ft.off(t,e)))),Wt=Bt(0,((t,e)=>{h(t)||(t=t?[t]:[]),t.forEach((t=>Ft.off(t,e)))})),Jt=Bt(0,((t,...e)=>{Ft.emit(t,...e)}));let Gt,Yt,Zt;function Xt(t){try{return JSON.parse(t)}catch(ba){}return t}const Qt=[];function te(t,e){Qt.forEach((n=>{n(t,e)})),Qt.length=0}const ee=Rt(ne="getPushClientId",function(t,e,n,r){return Ct(t,e,0,r)}(ne,((t,{resolve:e,reject:n})=>{Promise.resolve().then((()=>{void 0===Zt&&(Zt=!1,Gt="",Yt="uniPush is not enabled"),Qt.push(((t,r)=>{t?e({cid:t}):n(r)})),void 0!==Gt&&te(Gt,Yt)}))}),0,re));var ne,re;const ie=[],se=/^\$|__f__|getLocale|setLocale|sendNativeEvent|restoreGlobal|requireGlobal|getCurrentSubNVue|getMenuButtonBoundingClientRect|^report|interceptors|Interceptor$|getSubNVueById|requireNativePlugin|upx2px|rpx2px|hideKeyboard|canIUse|^create|Sync$|Manager$|base64ToArrayBuffer|arrayBufferToBase64|getDeviceInfo|getAppBaseInfo|getWindowInfo|getSystemSetting|getAppAuthorizeSetting/,oe=/^create|Manager$/,ae=["createBLEConnection"],ce=["request","downloadFile","uploadFile","connectSocket"],ue=["createBLEConnection"],le=/^on|^off/;function he(t){return oe.test(t)&&-1===ae.indexOf(t)}function fe(t){return se.test(t)&&-1===ue.indexOf(t)}function de(t){return-1!==ce.indexOf(t)}function pe(t){return!(he(t)||fe(t)||function(t){return le.test(t)&&"onPush"!==t}(t))}function ge(t,e){return pe(t)&&p(e)?function(n={},...r){return p(n.success)||p(n.fail)||p(n.complete)?At(t,Ot(t,e,n,r)):At(t,new Promise(((i,s)=>{Ot(t,e,a({},n,{success:i,fail:s}),r)})))}:e}Promise.prototype.finally||(Promise.prototype.finally=function(t){const e=this.constructor;return this.then((n=>e.resolve(t&&t()).then((()=>n))),(n=>e.resolve(t&&t()).then((()=>{throw n}))))});const me=["success","fail","cancel","complete"];const ye=()=>{const t=p(getApp)&&getApp({allowDefault:!0});return t&&t.$vm?t.$vm.$locale:lt(wx.getAppBaseInfo().language)||"en"},ve=[];"undefined"!=typeof global&&(global.getLocale=ye);let _e;function we(t=wx){return function(e,n){_e=_e||t.getStorageSync("__DC_STAT_UUID"),_e||(_e=Date.now()+""+Math.floor(1e7*Math.random()),wx.setStorage({key:"__DC_STAT_UUID",data:_e})),n.deviceId=_e}}function Se(t,e){if(t.safeArea){const n=t.safeArea;e.safeAreaInsets={top:n.top,left:n.left,right:t.windowWidth-n.right,bottom:t.screenHeight-n.bottom}}}function be(t,e){let n="",r="";return n=t.split(" ")[0]||"",r=t.split(" ")[1]||"",{osName:n.toLocaleLowerCase(),osVersion:r}}function Ee(t,e){let n=t.deviceType||"phone";{const t={ipad:"pad",windows:"pc",mac:"pc"},r=Object.keys(t),i=e.toLocaleLowerCase();for(let e=0;e<r.length;e++){const s=r[e];if(-1!==i.indexOf(s)){n=t[s];break}}}return n}function Te(t){let e=t;return e&&(e=e.toLocaleLowerCase()),e}function xe(t){return ye?ye():t}function Ie(t){let e=t.hostName||"WeChat";return t.environment?e=t.environment:t.host&&t.host.env&&(e=t.host.env),e}const De={returnValue:(t,e)=>{Se(t,e),we()(t,e),function(t,e){const{brand:n="",model:r="",system:i="",language:s="",theme:o,version:c,platform:u,fontSizeSetting:l,SDKVersion:h,pixelRatio:f,deviceOrientation:d}=t,{osName:p,osVersion:g}=be(i);let m=c,y=Ee(t,r),v=Te(n),_=Ie(t),w=d,S=f,b=h;const E=(s||"").replace(/_/g,"-"),T={appId:"__UNI__65AAA9F",appName:"car-insurance",appVersion:"1.0.0",appVersionCode:"100",appLanguage:xe(E),uniCompileVersion:"4.45",uniCompilerVersion:"4.45",uniRuntimeVersion:"4.45",uniPlatform:"mp-weixin",deviceBrand:v,deviceModel:r,deviceType:y,devicePixelRatio:S,deviceOrientation:w,osName:p,osVersion:g,hostTheme:o,hostVersion:m,hostLanguage:E,hostName:_,hostSDKVersion:b,hostFontSizeSetting:l,windowTop:0,windowBottom:0,osLanguage:void 0,osTheme:void 0,ua:void 0,hostPackageName:void 0,browserName:void 0,browserVersion:void 0,isUniAppX:!1};a(e,T)}(t,e)}},Ae=De,ke={args(t,e){let n=parseInt(t.current);if(isNaN(n))return;const r=t.urls;if(!h(r))return;const i=r.length;return i?(n<0?n=0:n>=i&&(n=i-1),n>0?(e.current=r[n],e.urls=r.filter(((t,e)=>!(e<n)||t!==r[n]))):e.current=r[0],{indicator:!1,loop:!1}):void 0}},Oe={args(t,e){e.alertText=t.title}},Re={returnValue:(t,e)=>{const{brand:n,model:r,system:i="",platform:s=""}=t;let o=Ee(t,r),c=Te(n);we()(t,e);const{osName:u,osVersion:l}=be(i);e=F(a(e,{deviceType:o,deviceBrand:c,deviceModel:r,osName:u,osVersion:l}))}},Pe={returnValue:(t,e)=>{const{version:n,language:r,SDKVersion:i,theme:s}=t;let o=Ie(t),c=(r||"").replace(/_/g,"-");const u={hostVersion:n,hostLanguage:c,hostName:o,hostSDKVersion:i,hostTheme:s,appId:"__UNI__65AAA9F",appName:"car-insurance",appVersion:"1.0.0",appVersionCode:"100",appLanguage:xe(c),isUniAppX:!1,uniPlatform:"mp-weixin",uniCompileVersion:"4.45",uniCompilerVersion:"4.45",uniRuntimeVersion:"4.45"};a(e,u)}},Me={returnValue:(t,e)=>{Se(t,e),e=F(a(e,{windowTop:0,windowBottom:0}))}},Ce={args(t){const e=getApp({allowDefault:!0})||{};e.$vm?_i("onError",t,e.$vm.$):(wx.$onErrorHandlers||(wx.$onErrorHandlers=[]),wx.$onErrorHandlers.push(t))}},Be={args(t){const e=getApp({allowDefault:!0})||{};if(e.$vm){if(t.__weh){const n=e.$vm.$.onError;if(n){const e=n.indexOf(t.__weh);e>-1&&n.splice(e,1)}}}else{if(!wx.$onErrorHandlers)return;const e=wx.$onErrorHandlers.findIndex((e=>e===t));-1!==e&&wx.$onErrorHandlers.splice(e,1)}}},Ne={args(){if(wx.__uni_console__){if(wx.__uni_console_warned__)return;wx.__uni_console_warned__=!0,console.warn("开发模式下小程序日志回显会使用 socket 连接,为了避免冲突,建议使用 SocketTask 的方式去管理 WebSocket 或手动关闭日志回显功能。[详情](https://uniapp.dcloud.net.cn/tutorial/run/mp-log.html)")}}},Le=Ne,je={$on:Kt,$off:Wt,$once:zt,$emit:Jt,upx2px:Vt,rpx2px:Vt,interceptors:{},addInterceptor:Ht,removeInterceptor:qt,onCreateVueApp:function(t){if(X)return t(X);Q.push(t)},invokeCreateVueAppHook:function(t){X=t,Q.forEach((e=>e(t)))},getLocale:ye,setLocale:t=>{const e=p(getApp)&&getApp();if(!e)return!1;return e.$vm.$locale!==t&&(e.$vm.$locale=t,ve.forEach((e=>e({locale:t}))),!0)},onLocaleChange:t=>{-1===ve.indexOf(t)&&ve.push(t)},getPushClientId:ee,onPushMessage:t=>{-1===ie.indexOf(t)&&ie.push(t)},offPushMessage:t=>{if(t){const e=ie.indexOf(t);e>-1&&ie.splice(e,1)}else ie.length=0},invokePushCallback:function(t){if("enabled"===t.type)Zt=!0;else if("clientId"===t.type)Gt=t.cid,Yt=t.errMsg,te(Gt,t.errMsg);else if("pushMsg"===t.type){const e={type:"receive",data:Xt(t.message)};for(let t=0;t<ie.length;t++){if((0,ie[t])(e),e.stopped)break}}else"click"===t.type&&ie.forEach((e=>{e({type:"click",data:Xt(t.message)})}))},__f__:function(t,e,...n){e&&n.push(e),console[t].apply(console,n)}};const Ve=["qy","env","error","version","lanDebug","cloud","serviceMarket","router","worklet","__webpack_require_UNI_MP_PLUGIN__"],Ue=["lanDebug","router","worklet"],$e=wx.getLaunchOptionsSync?wx.getLaunchOptionsSync():null;function He(t){return(!$e||1154!==$e.scene||!Ue.includes(t))&&(Ve.indexOf(t)>-1||"function"==typeof wx[t])}function qe(){const t={};for(const e in wx)He(e)&&(t[e]=wx[e]);return"undefined"!=typeof globalThis&&"undefined"==typeof requireMiniProgram&&(globalThis.wx=t),t}const Fe=["__route__","__wxExparserNodeId__","__wxWebviewId__"],Ke=(ze={oauth:["weixin"],share:["weixin"],payment:["wxpay"],push:["weixin"]},function({service:t,success:e,fail:n,complete:r}){let i;ze[t]?(i={errMsg:"getProvider:ok",service:t,provider:ze[t]},p(e)&&e(i)):(i={errMsg:"getProvider:fail:服务["+t+"]不存在"},p(n)&&n(i)),p(r)&&r(i)});var ze;const We=qe();let Je=We.getAppBaseInfo&&We.getAppBaseInfo();Je||(Je=We.getSystemInfoSync());const Ge=Je?Je.host:null,Ye=Ge&&"SAAASDK"===Ge.env?We.miniapp.shareVideoMessage:We.shareVideoMessage;var Ze=Object.freeze({__proto__:null,createSelectorQuery:function(){const t=We.createSelectorQuery(),e=t.in;return t.in=function(t){return e.call(this,function(t){const e=Object.create(null);return Fe.forEach((n=>{e[n]=t[n]})),e}(t))},t},getProvider:Ke,shareVideoMessage:Ye});const Xe={args(t,e){t.compressedHeight&&!e.compressHeight&&(e.compressHeight=t.compressedHeight),t.compressedWidth&&!e.compressWidth&&(e.compressWidth=t.compressedWidth)}};var Qe=Object.freeze({__proto__:null,compressImage:Xe,getAppAuthorizeSetting:{returnValue:function(t,e){const{locationReducedAccuracy:n}=t;e.locationAccuracy="unsupported",!0===n?e.locationAccuracy="reduced":!1===n&&(e.locationAccuracy="full")}},getAppBaseInfo:Pe,getDeviceInfo:Re,getSystemInfo:De,getSystemInfoSync:Ae,getWindowInfo:Me,offError:Be,onError:Ce,onSocketMessage:Le,onSocketOpen:Ne,previewImage:ke,redirectTo:{},showActionSheet:Oe});const tn=qe();var en=function(t,e,n=wx){const r=function(t){function e(t,e,n){return function(i){return e(r(t,i,n))}}function n(t,n,r={},i={},s=!1){if(S(n)){const o=!0===s?n:{};p(r)&&(r=r(n,o)||{});for(const a in n)if(l(r,a)){let e=r[a];p(e)&&(e=e(n[a],n,o)),e?g(e)?o[e]=n[a]:S(e)&&(o[e.name?e.name:a]=e.value):console.warn(`微信小程序 ${t} 暂不支持 ${a}`)}else if(-1!==me.indexOf(a)){const r=n[a];p(r)&&(o[a]=e(t,r,i))}else s||l(o,a)||(o[a]=n[a]);return o}return p(n)&&(p(r)&&r(n,{}),n=e(t,n,i)),n}function r(e,r,i,s=!1){return p(t.returnValue)&&(r=t.returnValue(e,r)),n(e,r,i,{},s||!1)}return function(e,i){const s=l(t,e),o=s||p(t.returnValue)||he(e)||de(e),a=s||p(i);if(!s&&!i)return function(){console.error(`微信小程序 暂不支持${e}`)};if(!o||!a)return i;const c=t[e];return function(t,i){let s=c||{};p(c)&&(s=c(t));const o=[t=n(e,t,s.args,s.returnValue)];void 0!==i&&o.push(i);const a=wx[s.name||e].apply(wx,o);return(he(e)||de(e))&&a&&!a.__v_skip&&(a.__v_skip=!0),fe(e)?r(e,a,s.returnValue,he(e)):a}}}(e);return new Proxy({},{get:(e,i)=>l(e,i)?e[i]:l(t,i)?ge(i,t[i]):l(je,i)?ge(i,je[i]):ge(i,r(i,n[i]))})}(Ze,Qe,tn);let nn,rn;class sn{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this.parent=nn,!t&&nn&&(this.index=(nn.scopes||(nn.scopes=[])).push(this)-1)}get active(){return this._active}run(t){if(this._active){const e=nn;try{return nn=this,t()}finally{nn=e}}}on(){nn=this}off(){nn=this.parent}stop(t){if(this._active){let e,n;for(e=0,n=this.effects.length;e<n;e++)this.effects[e].stop();for(e=0,n=this.cleanups.length;e<n;e++)this.cleanups[e]();if(this.scopes)for(e=0,n=this.scopes.length;e<n;e++)this.scopes[e].stop(!0);if(!this.detached&&this.parent&&!t){const t=this.parent.scopes.pop();t&&t!==this&&(this.parent.scopes[this.index]=t,t.index=this.index)}this.parent=void 0,this._active=!1}}}function on(t){return new sn(t)}function an(){return nn}class cn{constructor(t,e,n,r){this.fn=t,this.trigger=e,this.scheduler=n,this.active=!0,this.deps=[],this._dirtyLevel=4,this._trackId=0,this._runnings=0,this._shouldSchedule=!1,this._depsLength=0,function(t,e=nn){e&&e.active&&e.effects.push(t)}(this,r)}get dirty(){if(2===this._dirtyLevel||3===this._dirtyLevel){this._dirtyLevel=1,gn();for(let t=0;t<this._depsLength;t++){const e=this.deps[t];if(e.computed&&(e.computed.value,this._dirtyLevel>=4))break}1===this._dirtyLevel&&(this._dirtyLevel=0),mn()}return this._dirtyLevel>=4}set dirty(t){this._dirtyLevel=t?4:0}run(){if(this._dirtyLevel=0,!this.active)return this.fn();let t=fn,e=rn;try{return fn=!0,rn=this,this._runnings++,un(this),this.fn()}finally{ln(this),this._runnings--,rn=e,fn=t}}stop(){var t;this.active&&(un(this),ln(this),null==(t=this.onStop)||t.call(this),this.active=!1)}}function un(t){t._trackId++,t._depsLength=0}function ln(t){if(t.deps.length>t._depsLength){for(let e=t._depsLength;e<t.deps.length;e++)hn(t.deps[e],t);t.deps.length=t._depsLength}}function hn(t,e){const n=t.get(e);void 0!==n&&e._trackId!==n&&(t.delete(e),0===t.size&&t.cleanup())}let fn=!0,dn=0;const pn=[];function gn(){pn.push(fn),fn=!1}function mn(){const t=pn.pop();fn=void 0===t||t}function yn(){dn++}function vn(){for(dn--;!dn&&wn.length;)wn.shift()()}function _n(t,e,n){if(e.get(t)!==t._trackId){e.set(t,t._trackId);const n=t.deps[t._depsLength];n!==e?(n&&hn(n,t),t.deps[t._depsLength++]=e):t._depsLength++}}const wn=[];function Sn(t,e,n){yn();for(const r of t.keys()){let n;r._dirtyLevel<e&&(null!=n?n:n=t.get(r)===r._trackId)&&(r._shouldSchedule||(r._shouldSchedule=0===r._dirtyLevel),r._dirtyLevel=e),r._shouldSchedule&&(null!=n?n:n=t.get(r)===r._trackId)&&(r.trigger(),r._runnings&&!r.allowRecurse||2===r._dirtyLevel||(r._shouldSchedule=!1,r.scheduler&&wn.push(r.scheduler)))}vn()}const bn=(t,e)=>{const n=new Map;return n.cleanup=t,n.computed=e,n},En=new WeakMap,Tn=Symbol(""),xn=Symbol("");function In(t,e,n){if(fn&&rn){let e=En.get(t);e||En.set(t,e=new Map);let r=e.get(n);r||e.set(n,r=bn((()=>e.delete(n)))),_n(rn,r)}}function Dn(t,e,n,r,i,s){const o=En.get(t);if(!o)return;let a=[];if("clear"===e)a=[...o.values()];else if("length"===n&&h(t)){const t=Number(r);o.forEach(((e,n)=>{("length"===n||!m(n)&&n>=t)&&a.push(e)}))}else switch(void 0!==n&&a.push(o.get(n)),e){case"add":h(t)?b(n)&&a.push(o.get("length")):(a.push(o.get(Tn)),f(t)&&a.push(o.get(xn)));break;case"delete":h(t)||(a.push(o.get(Tn)),f(t)&&a.push(o.get(xn)));break;case"set":f(t)&&a.push(o.get(Tn))}yn();for(const c of a)c&&Sn(c,4);vn()}const An=t("__proto__,__v_isRef,__isVue"),kn=new Set(Object.getOwnPropertyNames(Symbol).filter((t=>"arguments"!==t&&"caller"!==t)).map((t=>Symbol[t])).filter(m)),On=Rn();function Rn(){const t={};return["includes","indexOf","lastIndexOf"].forEach((e=>{t[e]=function(...t){const n=yr(this);for(let e=0,i=this.length;e<i;e++)In(n,0,e+"");const r=n[e](...t);return-1===r||!1===r?n[e](...t.map(yr)):r}})),["push","pop","shift","unshift","splice"].forEach((e=>{t[e]=function(...t){gn(),yn();const n=yr(this)[e].apply(this,t);return vn(),mn(),n}})),t}function Pn(t){const e=yr(this);return In(e,0,t),e.hasOwnProperty(t)}class Mn{constructor(t=!1,e=!1){this._isReadonly=t,this._isShallow=e}get(t,e,n){const r=this._isReadonly,i=this._isShallow;if("__v_isReactive"===e)return!r;if("__v_isReadonly"===e)return r;if("__v_isShallow"===e)return i;if("__v_raw"===e)return n===(r?i?ur:cr:i?ar:or).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(n)?t:void 0;const s=h(t);if(!r){if(s&&l(On,e))return Reflect.get(On,e,n);if("hasOwnProperty"===e)return Pn}const o=Reflect.get(t,e,n);return(m(e)?kn.has(e):An(e))?o:(r||In(t,0,e),i?o:Tr(o)?s&&b(e)?o:o.value:y(o)?r?fr(o):hr(o):o)}}class Cn extends Mn{constructor(t=!1){super(!1,t)}set(t,e,n,r){let i=t[e];if(!this._isShallow){const e=gr(i);if(mr(n)||gr(n)||(i=yr(i),n=yr(n)),!h(t)&&Tr(i)&&!Tr(n))return!e&&(i.value=n,!0)}const s=h(t)&&b(e)?Number(e)<t.length:l(t,e),o=Reflect.set(t,e,n,r);return t===yr(r)&&(s?R(n,i)&&Dn(t,"set",e,n):Dn(t,"add",e,n)),o}deleteProperty(t,e){const n=l(t,e);t[e];const r=Reflect.deleteProperty(t,e);return r&&n&&Dn(t,"delete",e,void 0),r}has(t,e){const n=Reflect.has(t,e);return m(e)&&kn.has(e)||In(t,0,e),n}ownKeys(t){return In(t,0,h(t)?"length":Tn),Reflect.ownKeys(t)}}class Bn extends Mn{constructor(t=!1){super(!0,t)}set(t,e){return!0}deleteProperty(t,e){return!0}}const Nn=new Cn,Ln=new Bn,jn=new Cn(!0),Vn=t=>t,Un=t=>Reflect.getPrototypeOf(t);function $n(t,e,n=!1,r=!1){const i=yr(t=t.__v_raw),s=yr(e);n||(R(e,s)&&In(i,0,e),In(i,0,s));const{has:o}=Un(i),a=r?Vn:n?wr:_r;return o.call(i,e)?a(t.get(e)):o.call(i,s)?a(t.get(s)):void(t!==i&&t.get(e))}function Hn(t,e=!1){const n=this.__v_raw,r=yr(n),i=yr(t);return e||(R(t,i)&&In(r,0,t),In(r,0,i)),t===i?n.has(t):n.has(t)||n.has(i)}function qn(t,e=!1){return t=t.__v_raw,!e&&In(yr(t),0,Tn),Reflect.get(t,"size",t)}function Fn(t){t=yr(t);const e=yr(this);return Un(e).has.call(e,t)||(e.add(t),Dn(e,"add",t,t)),this}function Kn(t,e){e=yr(e);const n=yr(this),{has:r,get:i}=Un(n);let s=r.call(n,t);s||(t=yr(t),s=r.call(n,t));const o=i.call(n,t);return n.set(t,e),s?R(e,o)&&Dn(n,"set",t,e):Dn(n,"add",t,e),this}function zn(t){const e=yr(this),{has:n,get:r}=Un(e);let i=n.call(e,t);i||(t=yr(t),i=n.call(e,t)),r&&r.call(e,t);const s=e.delete(t);return i&&Dn(e,"delete",t,void 0),s}function Wn(){const t=yr(this),e=0!==t.size,n=t.clear();return e&&Dn(t,"clear",void 0,void 0),n}function Jn(t,e){return function(n,r){const i=this,s=i.__v_raw,o=yr(s),a=e?Vn:t?wr:_r;return!t&&In(o,0,Tn),s.forEach(((t,e)=>n.call(r,a(t),a(e),i)))}}function Gn(t,e,n){return function(...r){const i=this.__v_raw,s=yr(i),o=f(s),a="entries"===t||t===Symbol.iterator&&o,c="keys"===t&&o,u=i[t](...r),l=n?Vn:e?wr:_r;return!e&&In(s,0,c?xn:Tn),{next(){const{value:t,done:e}=u.next();return e?{value:t,done:e}:{value:a?[l(t[0]),l(t[1])]:l(t),done:e}},[Symbol.iterator](){return this}}}}function Yn(t){return function(...e){return"delete"!==t&&("clear"===t?void 0:this)}}function Zn(){const t={get(t){return $n(this,t)},get size(){return qn(this)},has:Hn,add:Fn,set:Kn,delete:zn,clear:Wn,forEach:Jn(!1,!1)},e={get(t){return $n(this,t,!1,!0)},get size(){return qn(this)},has:Hn,add:Fn,set:Kn,delete:zn,clear:Wn,forEach:Jn(!1,!0)},n={get(t){return $n(this,t,!0)},get size(){return qn(this,!0)},has(t){return Hn.call(this,t,!0)},add:Yn("add"),set:Yn("set"),delete:Yn("delete"),clear:Yn("clear"),forEach:Jn(!0,!1)},r={get(t){return $n(this,t,!0,!0)},get size(){return qn(this,!0)},has(t){return Hn.call(this,t,!0)},add:Yn("add"),set:Yn("set"),delete:Yn("delete"),clear:Yn("clear"),forEach:Jn(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach((i=>{t[i]=Gn(i,!1,!1),n[i]=Gn(i,!0,!1),e[i]=Gn(i,!1,!0),r[i]=Gn(i,!0,!0)})),[t,n,e,r]}const[Xn,Qn,tr,er]=Zn();function nr(t,e){const n=e?t?er:tr:t?Qn:Xn;return(e,r,i)=>"__v_isReactive"===r?!t:"__v_isReadonly"===r?t:"__v_raw"===r?e:Reflect.get(l(n,r)&&r in e?n:e,r,i)}const rr={get:nr(!1,!1)},ir={get:nr(!1,!0)},sr={get:nr(!0,!1)},or=new WeakMap,ar=new WeakMap,cr=new WeakMap,ur=new WeakMap;function lr(t){return t.__v_skip||!Object.isExtensible(t)?0:function(t){switch(t){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}((t=>w(t).slice(8,-1))(t))}function hr(t){return gr(t)?t:dr(t,!1,Nn,rr,or)}function fr(t){return dr(t,!0,Ln,sr,cr)}function dr(t,e,n,r,i){if(!y(t))return t;if(t.__v_raw&&(!e||!t.__v_isReactive))return t;const s=i.get(t);if(s)return s;const o=lr(t);if(0===o)return t;const a=new Proxy(t,2===o?r:n);return i.set(t,a),a}function pr(t){return gr(t)?pr(t.__v_raw):!(!t||!t.__v_isReactive)}function gr(t){return!(!t||!t.__v_isReadonly)}function mr(t){return!(!t||!t.__v_isShallow)}function yr(t){const e=t&&t.__v_raw;return e?yr(e):t}function vr(t){return Object.isExtensible(t)&&((t,e,n)=>{Object.defineProperty(t,e,{configurable:!0,enumerable:!1,value:n})})(t,"__v_skip",!0),t}const _r=t=>y(t)?hr(t):t,wr=t=>y(t)?fr(t):t;class Sr{constructor(t,e,n,r){this.getter=t,this._setter=e,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this.effect=new cn((()=>t(this._value)),(()=>Er(this,2===this.effect._dirtyLevel?2:3))),this.effect.computed=this,this.effect.active=this._cacheable=!r,this.__v_isReadonly=n}get value(){const t=yr(this);return t._cacheable&&!t.effect.dirty||!R(t._value,t._value=t.effect.run())||Er(t,4),br(t),t.effect._dirtyLevel>=2&&Er(t,2),t._value}set value(t){this._setter(t)}get _dirty(){return this.effect.dirty}set _dirty(t){this.effect.dirty=t}}function br(t){var e;fn&&rn&&(t=yr(t),_n(rn,null!=(e=t.dep)?e:t.dep=bn((()=>t.dep=void 0),t instanceof Sr?t:void 0)))}function Er(t,e=4,n){const r=(t=yr(t)).dep;r&&Sn(r,e)}function Tr(t){return!(!t||!0!==t.__v_isRef)}function xr(t){return function(t,e){if(Tr(t))return t;return new Ir(t,e)}(t,!1)}class Ir{constructor(t,e){this.__v_isShallow=e,this.dep=void 0,this.__v_isRef=!0,this._rawValue=e?t:yr(t),this._value=e?t:_r(t)}get value(){return br(this),this._value}set value(t){const e=this.__v_isShallow||mr(t)||gr(t);t=e?t:yr(t),R(t,this._rawValue)&&(this._rawValue=t,this._value=e?t:_r(t),Er(this,4))}}function Dr(t){return Tr(t)?t.value:t}const Ar={get:(t,e,n)=>Dr(Reflect.get(t,e,n)),set:(t,e,n,r)=>{const i=t[e];return Tr(i)&&!Tr(n)?(i.value=n,!0):Reflect.set(t,e,n,r)}};function kr(t){return pr(t)?t:new Proxy(t,Ar)}class Or{constructor(t,e,n){this._object=t,this._key=e,this._defaultValue=n,this.__v_isRef=!0}get value(){const t=this._object[this._key];return void 0===t?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return t=yr(this._object),e=this._key,null==(n=En.get(t))?void 0:n.get(e);var t,e,n}}function Rr(t,e,n){const r=t[e];return Tr(r)?r:new Or(t,e,n)}function Pr(t,e,n,r){try{return r?t(...r):t()}catch(i){Cr(i,e,n)}}function Mr(t,e,n,r){if(p(t)){const i=Pr(t,e,n,r);return i&&v(i)&&i.catch((t=>{Cr(t,e,n)})),i}const i=[];for(let s=0;s<t.length;s++)i.push(Mr(t[s],e,n,r));return i}function Cr(t,e,n,r=!0){const i=e?e.vnode:null;if(e){let r=e.parent;const i=e.proxy,s=`https://vuejs.org/error-reference/#runtime-${n}`;for(;r;){const e=r.ec;if(e)for(let n=0;n<e.length;n++)if(!1===e[n](t,i,s))return;r=r.parent}const o=e.appContext.config.errorHandler;if(o)return void Pr(o,null,10,[t,i,s])}Br(t,n,i,r)}function Br(t,e,n,r=!0){console.error(t)}let Nr=!1,Lr=!1;const jr=[];let Vr=0;const Ur=[];let $r=null,Hr=0;const qr=Promise.resolve();let Fr=null;function Kr(t){const e=Fr||qr;return t?e.then(this?t.bind(this):t):e}function zr(t){jr.length&&jr.includes(t,Nr&&t.allowRecurse?Vr+1:Vr)||(null==t.id?jr.push(t):jr.splice(function(t){let e=Vr+1,n=jr.length;for(;e<n;){const r=e+n>>>1,i=jr[r],s=Yr(i);s<t||s===t&&i.pre?e=r+1:n=r}return e}(t.id),0,t),Wr())}function Wr(){Nr||Lr||(Lr=!0,Fr=qr.then(Xr))}function Jr(t){h(t)?Ur.push(...t):$r&&$r.includes(t,t.allowRecurse?Hr+1:Hr)||Ur.push(t),Wr()}function Gr(t,e,n=(Nr?Vr+1:0)){for(;n<jr.length;n++){const t=jr[n];t&&t.pre&&(jr.splice(n,1),n--,t())}}const Yr=t=>null==t.id?1/0:t.id,Zr=(t,e)=>{const n=Yr(t)-Yr(e);if(0===n){if(t.pre&&!e.pre)return-1;if(e.pre&&!t.pre)return 1}return n};function Xr(t){Lr=!1,Nr=!0,jr.sort(Zr);try{for(Vr=0;Vr<jr.length;Vr++){const t=jr[Vr];t&&!1!==t.active&&Pr(t,null,14)}}finally{Vr=0,jr.length=0,function(t){if(Ur.length){const t=[...new Set(Ur)].sort(((t,e)=>Yr(t)-Yr(e)));if(Ur.length=0,$r)return void $r.push(...t);for($r=t,Hr=0;Hr<$r.length;Hr++)$r[Hr]();$r=null,Hr=0}}(),Nr=!1,Fr=null,(jr.length||Ur.length)&&Xr()}}function Qr(t,n,...r){if(t.isUnmounted)return;const i=t.vnode.props||e;let s=r;const o=n.startsWith("update:"),a=o&&n.slice(7);if(a&&a in i){const t=`${"modelValue"===a?"model":a}Modifiers`,{number:n,trim:o}=i[t]||e;o&&(s=r.map((t=>g(t)?t.trim():t))),n&&(s=r.map(M))}let c,u=i[c=O(n)]||i[c=O(I(n))];!u&&o&&(u=i[c=O(A(n))]),u&&Mr(u,t,6,s);const l=i[c+"Once"];if(l){if(t.emitted){if(t.emitted[c])return}else t.emitted={};t.emitted[c]=!0,Mr(l,t,6,s)}}function ti(t,e,n=!1){const r=e.emitsCache,i=r.get(t);if(void 0!==i)return i;const s=t.emits;let o={},c=!1;if(!p(t)){const r=t=>{const n=ti(t,e,!0);n&&(c=!0,a(o,n))};!n&&e.mixins.length&&e.mixins.forEach(r),t.extends&&r(t.extends),t.mixins&&t.mixins.forEach(r)}return s||c?(h(s)?s.forEach((t=>o[t]=null)):a(o,s),y(t)&&r.set(t,o),o):(y(t)&&r.set(t,null),null)}function ei(t,e){return!(!t||!s(e))&&(e=e.slice(2).replace(/Once$/,""),l(t,e[0].toLowerCase()+e.slice(1))||l(t,A(e))||l(t,e))}let ni=null;function ri(t){const e=ni;return ni=t,t&&t.type.__scopeId,e}function ii(t,e){return t&&(t[e]||t[I(e)]||t[k(I(e))])}const si={};function oi(t,e,n){return ai(t,e,n)}function ai(t,n,{immediate:i,deep:s,flush:o,once:a,onTrack:u,onTrigger:l}=e){if(n&&a){const t=n;n=(...e)=>{t(...e),x()}}const f=as,d=t=>!0===s?t:li(t,!1===s?1:void 0);let g,m,y=!1,v=!1;if(Tr(t)?(g=()=>t.value,y=mr(t)):pr(t)?(g=()=>d(t),y=!0):h(t)?(v=!0,y=t.some((t=>pr(t)||mr(t))),g=()=>t.map((t=>Tr(t)?t.value:pr(t)?d(t):p(t)?Pr(t,f,2):void 0))):g=p(t)?n?()=>Pr(t,f,2):()=>(m&&m(),Mr(t,f,3,[_])):r,n&&s){const t=g;g=()=>li(t())}let _=t=>{m=E.onStop=()=>{Pr(t,f,4),m=E.onStop=void 0}},w=v?new Array(t.length).fill(si):si;const S=()=>{if(E.active&&E.dirty)if(n){const t=E.run();(s||y||(v?t.some(((t,e)=>R(t,w[e]))):R(t,w)))&&(m&&m(),Mr(n,f,3,[t,w===si?void 0:v&&w[0]===si?[]:w,_]),w=t)}else E.run()};let b;S.allowRecurse=!!n,"sync"===o?b=S:"post"===o?b=()=>ns(S,f&&f.suspense):(S.pre=!0,f&&(S.id=f.uid),b=()=>zr(S));const E=new cn(g,r,b),T=an(),x=()=>{E.stop(),T&&c(T.effects,E)};return n?i?S():w=E.run():"post"===o?ns(E.run.bind(E),f&&f.suspense):E.run(),x}function ci(t,e,n){const r=this.proxy,i=g(t)?t.includes(".")?ui(r,t):()=>r[t]:t.bind(r,r);let s;p(e)?s=e:(s=e.handler,n=e);const o=hs(this),a=ai(i,s.bind(r),n);return o(),a}function ui(t,e){const n=e.split(".");return()=>{let e=t;for(let t=0;t<n.length&&e;t++)e=e[n[t]];return e}}function li(t,e,n=0,r){if(!y(t)||t.__v_skip)return t;if(e&&e>0){if(n>=e)return t;n++}if((r=r||new Set).has(t))return t;if(r.add(t),Tr(t))li(t.value,e,n,r);else if(h(t))for(let i=0;i<t.length;i++)li(t[i],e,n,r);else if(d(t)||f(t))t.forEach((t=>{li(t,e,n,r)}));else if(S(t))for(const i in t)li(t[i],e,n,r);return t}function hi(){return{app:null,config:{isNativeTag:i,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let fi=0;let di=null;function pi(t,e,n=!1){const r=as||ni;if(r||di){const i=r?null==r.parent?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:di._context.provides;if(i&&t in i)return i[t];if(arguments.length>1)return n&&p(e)?e.call(r&&r.proxy):e}}function gi(t,e){yi(t,"a",e)}function mi(t,e){yi(t,"da",e)}function yi(t,e,n=as){const r=t.__wdc||(t.__wdc=()=>{let e=n;for(;e;){if(e.isDeactivated)return;e=e.parent}return t()});if(_i(e,r,n),n){let t=n.parent;for(;t&&t.parent;)t.parent.vnode.type.__isKeepAlive&&vi(r,e,n,t),t=t.parent}}function vi(t,e,n,r){const i=_i(e,t,r,!0);Ii((()=>{c(r[e],i)}),n)}function _i(t,e,n=as,r=!1){if(n){(function(t){return J.indexOf(t)>-1})(t)&&(n=n.root);const i=n[t]||(n[t]=[]),s=e.__weh||(e.__weh=(...r)=>{if(n.isUnmounted)return;gn();const i=hs(n),s=Mr(e,n,t,r);return i(),mn(),s});return r?i.unshift(s):i.push(s),s}}const wi=t=>(e,n=as)=>(!ps||"sp"===t)&&_i(t,((...t)=>e(...t)),n),Si=wi("bm"),bi=wi("m"),Ei=wi("bu"),Ti=wi("u"),xi=wi("bum"),Ii=wi("um"),Di=wi("sp"),Ai=wi("rtg"),ki=wi("rtc");function Oi(t,e=as){_i("ec",t,e)}const Ri=t=>t?ds(t)?ys(t)||t.proxy:Ri(t.parent):null,Pi=a(Object.create(null),{$:t=>t,$el:t=>t.__$el||(t.__$el={}),$data:t=>t.data,$props:t=>t.props,$attrs:t=>t.attrs,$slots:t=>t.slots,$refs:t=>t.refs,$parent:t=>Ri(t.parent),$root:t=>Ri(t.root),$emit:t=>t.emit,$options:t=>Ui(t),$forceUpdate:t=>t.f||(t.f=()=>{t.effect.dirty=!0,zr(t.update)}),$watch:t=>ci.bind(t)}),Mi=(t,n)=>t!==e&&!t.__isScriptSetup&&l(t,n),Ci={get({_:t},n){const{ctx:r,setupState:i,data:s,props:o,accessCache:a,type:c,appContext:u}=t;let h;if("$"!==n[0]){const c=a[n];if(void 0!==c)switch(c){case 1:return i[n];case 2:return s[n];case 4:return r[n];case 3:return o[n]}else{if(Mi(i,n))return a[n]=1,i[n];if(s!==e&&l(s,n))return a[n]=2,s[n];if((h=t.propsOptions[0])&&l(h,n))return a[n]=3,o[n];if(r!==e&&l(r,n))return a[n]=4,r[n];Ni&&(a[n]=0)}}const f=Pi[n];let d,p;return f?("$attrs"===n&&In(t,0,n),f(t)):(d=c.__cssModules)&&(d=d[n])?d:r!==e&&l(r,n)?(a[n]=4,r[n]):(p=u.config.globalProperties,l(p,n)?p[n]:void 0)},set({_:t},n,r){const{data:i,setupState:s,ctx:o}=t;return Mi(s,n)?(s[n]=r,!0):i!==e&&l(i,n)?(i[n]=r,!0):!l(t.props,n)&&(("$"!==n[0]||!(n.slice(1)in t))&&(o[n]=r,!0))},has({_:{data:t,setupState:n,accessCache:r,ctx:i,appContext:s,propsOptions:o}},a){let c;return!!r[a]||t!==e&&l(t,a)||Mi(n,a)||(c=o[0])&&l(c,a)||l(i,a)||l(Pi,a)||l(s.config.globalProperties,a)},defineProperty(t,e,n){return null!=n.get?t._.accessCache[e]=0:l(n,"value")&&this.set(t,e,n.value,null),Reflect.defineProperty(t,e,n)}};function Bi(t){return h(t)?t.reduce(((t,e)=>(t[e]=null,t)),{}):t}let Ni=!0;function Li(t){const e=Ui(t),n=t.proxy,i=t.ctx;Ni=!1,e.beforeCreate&&ji(e.beforeCreate,t,"bc");const{data:s,computed:o,methods:a,watch:c,provide:u,inject:l,created:f,beforeMount:d,mounted:g,beforeUpdate:m,updated:v,activated:_,deactivated:w,beforeDestroy:S,beforeUnmount:b,destroyed:E,unmounted:T,render:x,renderTracked:I,renderTriggered:D,errorCaptured:A,serverPrefetch:k,expose:O,inheritAttrs:R,components:P,directives:M,filters:C}=e;if(l&&function(t,e,n=r){h(t)&&(t=Fi(t));for(const r in t){const n=t[r];let i;i=y(n)?"default"in n?pi(n.from||r,n.default,!0):pi(n.from||r):pi(n),Tr(i)?Object.defineProperty(e,r,{enumerable:!0,configurable:!0,get:()=>i.value,set:t=>i.value=t}):e[r]=i}}(l,i,null),a)for(const r in a){const t=a[r];p(t)&&(i[r]=t.bind(n))}if(s){const e=s.call(n,n);y(e)&&(t.data=hr(e))}if(Ni=!0,o)for(const h in o){const t=o[h],e=p(t)?t.bind(n,n):p(t.get)?t.get.bind(n,n):r,s=!p(t)&&p(t.set)?t.set.bind(n):r,a=vs({get:e,set:s});Object.defineProperty(i,h,{enumerable:!0,configurable:!0,get:()=>a.value,set:t=>a.value=t})}if(c)for(const r in c)Vi(c[r],i,n,r);function B(t,e){h(e)?e.forEach((e=>t(e.bind(n)))):e&&t(e.bind(n))}if(function(){if(u){const t=p(u)?u.call(n):u;Reflect.ownKeys(t).forEach((e=>{!function(t,e){if(as){let n=as.provides;const r=as.parent&&as.parent.provides;r===n&&(n=as.provides=Object.create(r)),n[t]=e,"app"===as.type.mpType&&as.appContext.app.provide(t,e)}}(e,t[e])}))}}(),f&&ji(f,t,"c"),B(Si,d),B(bi,g),B(Ei,m),B(Ti,v),B(gi,_),B(mi,w),B(Oi,A),B(ki,I),B(Ai,D),B(xi,b),B(Ii,T),B(Di,k),h(O))if(O.length){const e=t.exposed||(t.exposed={});O.forEach((t=>{Object.defineProperty(e,t,{get:()=>n[t],set:e=>n[t]=e})}))}else t.exposed||(t.exposed={});x&&t.render===r&&(t.render=x),null!=R&&(t.inheritAttrs=R),P&&(t.components=P),M&&(t.directives=M),t.ctx.$onApplyOptions&&t.ctx.$onApplyOptions(e,t,n)}function ji(t,e,n){Mr(h(t)?t.map((t=>t.bind(e.proxy))):t.bind(e.proxy),e,n)}function Vi(t,e,n,r){const i=r.includes(".")?ui(n,r):()=>n[r];if(g(t)){const n=e[t];p(n)&&oi(i,n)}else if(p(t))oi(i,t.bind(n));else if(y(t))if(h(t))t.forEach((t=>Vi(t,e,n,r)));else{const r=p(t.handler)?t.handler.bind(n):e[t.handler];p(r)&&oi(i,r,t)}}function Ui(t){const e=t.type,{mixins:n,extends:r}=e,{mixins:i,optionsCache:s,config:{optionMergeStrategies:o}}=t.appContext,a=s.get(e);let c;return a?c=a:i.length||n||r?(c={},i.length&&i.forEach((t=>$i(c,t,o,!0))),$i(c,e,o)):c=e,y(e)&&s.set(e,c),c}function $i(t,e,n,r=!1){const{mixins:i,extends:s}=e;s&&$i(t,s,n,!0),i&&i.forEach((e=>$i(t,e,n,!0)));for(const o in e)if(r&&"expose"===o);else{const r=Hi[o]||n&&n[o];t[o]=r?r(t[o],e[o]):e[o]}return t}const Hi={data:qi,props:Wi,emits:Wi,methods:zi,computed:zi,beforeCreate:Ki,created:Ki,beforeMount:Ki,mounted:Ki,beforeUpdate:Ki,updated:Ki,beforeDestroy:Ki,beforeUnmount:Ki,destroyed:Ki,unmounted:Ki,activated:Ki,deactivated:Ki,errorCaptured:Ki,serverPrefetch:Ki,components:zi,directives:zi,watch:function(t,e){if(!t)return e;if(!e)return t;const n=a(Object.create(null),t);for(const r in e)n[r]=Ki(t[r],e[r]);return n},provide:qi,inject:function(t,e){return zi(Fi(t),Fi(e))}};function qi(t,e){return e?t?function(){return a(p(t)?t.call(this,this):t,p(e)?e.call(this,this):e)}:e:t}function Fi(t){if(h(t)){const e={};for(let n=0;n<t.length;n++)e[t[n]]=t[n];return e}return t}function Ki(t,e){return t?[...new Set([].concat(t,e))]:e}function zi(t,e){return t?a(Object.create(null),t,e):e}function Wi(t,e){return t?h(t)&&h(e)?[...new Set([...t,...e])]:a(Object.create(null),Bi(t),Bi(null!=e?e:{})):e}function Ji(t,e,n,r=!1){const i={},s={};t.propsDefaults=Object.create(null),Gi(t,e,i,s);for(const o in t.propsOptions[0])o in i||(i[o]=void 0);n?t.props=r?i:dr(i,!1,jn,ir,ar):t.type.props?t.props=i:t.props=s,t.attrs=s}function Gi(t,n,r,i){const[s,o]=t.propsOptions;let a,c=!1;if(n)for(let e in n){if(E(e))continue;const u=n[e];let h;s&&l(s,h=I(e))?o&&o.includes(h)?(a||(a={}))[h]=u:r[h]=u:ei(t.emitsOptions,e)||e in i&&u===i[e]||(i[e]=u,c=!0)}if(o){const n=yr(r),i=a||e;for(let e=0;e<o.length;e++){const a=o[e];r[a]=Yi(s,n,a,i[a],t,!l(i,a))}}return c}function Yi(t,e,n,r,i,s){const o=t[n];if(null!=o){const t=l(o,"default");if(t&&void 0===r){const t=o.default;if(o.type!==Function&&!o.skipFactory&&p(t)){const{propsDefaults:s}=i;if(n in s)r=s[n];else{const o=hs(i);r=s[n]=t.call(null,e),o()}}else r=t}o[0]&&(s&&!t?r=!1:!o[1]||""!==r&&r!==A(n)||(r=!0))}return r}function Zi(t,r,i=!1){const s=r.propsCache,o=s.get(t);if(o)return o;const c=t.props,u={},f=[];let d=!1;if(!p(t)){const e=t=>{d=!0;const[e,n]=Zi(t,r,!0);a(u,e),n&&f.push(...n)};!i&&r.mixins.length&&r.mixins.forEach(e),t.extends&&e(t.extends),t.mixins&&t.mixins.forEach(e)}if(!c&&!d)return y(t)&&s.set(t,n),n;if(h(c))for(let n=0;n<c.length;n++){const t=I(c[n]);Xi(t)&&(u[t]=e)}else if(c)for(const e in c){const t=I(e);if(Xi(t)){const n=c[e],r=u[t]=h(n)||p(n)?{type:n}:a({},n);if(r){const e=es(Boolean,r.type),n=es(String,r.type);r[0]=e>-1,r[1]=n<0||e<n,(e>-1||l(r,"default"))&&f.push(t)}}}const g=[u,f];return y(t)&&s.set(t,g),g}function Xi(t){return"$"!==t[0]&&!E(t)}function Qi(t){if(null===t)return"null";if("function"==typeof t)return t.name||"";if("object"==typeof t){return t.constructor&&t.constructor.name||""}return""}function ts(t,e){return Qi(t)===Qi(e)}function es(t,e){return h(e)?e.findIndex((e=>ts(e,t))):p(e)&&ts(e,t)?0:-1}const ns=Jr;function rs(t){return t?pr(e=t)||gr(e)||"__vInternal"in t?a({},t):t:null;var e}const is=hi();let ss=0;function os(t,n,r){const i=t.type,s=(n?n.appContext:t.appContext)||is,o={uid:ss++,vnode:t,type:i,parent:n,appContext:s,root:null,next:null,subTree:null,effect:null,update:null,scope:new sn(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:n?n.provides:Object.create(s.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Zi(i,s),emitsOptions:ti(i,s),emit:null,emitted:null,propsDefaults:e,inheritAttrs:i.inheritAttrs,ctx:e,data:e,props:e,attrs:e,slots:e,refs:e,setupState:e,setupContext:null,attrsProxy:null,slotsProxy:null,suspense:r,suspenseId:r?r.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null,$uniElements:new Map,$templateUniElementRefs:[],$templateUniElementStyles:{},$eS:{}};return o.ctx={_:o},o.root=n?n.root:o,o.emit=Qr.bind(null,o),t.ce&&t.ce(o),o}let as=null;const cs=()=>as||ni;let us,ls;us=t=>{as=t},ls=t=>{ps=t};const hs=t=>{const e=as;return us(t),t.scope.on(),()=>{t.scope.off(),us(e)}},fs=()=>{as&&as.scope.off(),us(null)};function ds(t){return 4&t.vnode.shapeFlag}let ps=!1;function gs(t,e=!1){e&&ls(e);const{props:n}=t.vnode,r=ds(t);Ji(t,n,r,e);const i=r?function(t,e){const n=t.type;t.accessCache=Object.create(null),t.proxy=vr(new Proxy(t.ctx,Ci));const{setup:r}=n;if(r){const e=t.setupContext=r.length>1?function(t){const e=e=>{t.exposed=e||{}};return{get attrs(){return function(t){return t.attrsProxy||(t.attrsProxy=new Proxy(t.attrs,{get:(e,n)=>(In(t,0,"$attrs"),e[n])}))}(t)},slots:t.slots,emit:t.emit,expose:e}}(t):null,n=hs(t);gn();const i=Pr(r,t,0,[t.props,e]);mn(),n(),v(i)?i.then(fs,fs):function(t,e,n){p(e)?t.render=e:y(e)&&(t.setupState=kr(e));ms(t)}(t,i)}else ms(t)}(t):void 0;return e&&ls(!1),i}function ms(t,e,n){const i=t.type;t.render||(t.render=i.render||r);{const e=hs(t);gn();try{Li(t)}finally{mn(),e()}}}function ys(t){if(t.exposed)return t.exposeProxy||(t.exposeProxy=new Proxy(kr(vr(t.exposed)),{get:(e,n)=>n in e?e[n]:t.proxy[n],has:(t,e)=>e in t||e in Pi}))}const vs=(t,e)=>{const n=function(t,e,n=!1){let i,s;const o=p(t);return o?(i=t,s=r):(i=t.get,s=t.set),new Sr(i,s,o||!s,n)}(t,0,ps);return n},_s="3.4.21";function ws(t){return Dr(t)}const Ss="[object Array]",bs="[object Object]";function Es(t,e){const n={};return Ts(t,e),xs(t,e,"",n),n}function Ts(t,e){if((t=ws(t))===e)return;const n=w(t),r=w(e);if(n==bs&&r==bs)for(let i in e){const n=t[i];void 0===n?t[i]=null:Ts(n,e[i])}else n==Ss&&r==Ss&&t.length>=e.length&&e.forEach(((e,n)=>{Ts(t[n],e)}))}function xs(t,e,n,r){if((t=ws(t))===e)return;const i=w(t),s=w(e);if(i==bs)if(s!=bs||Object.keys(t).length<Object.keys(e).length)Is(r,n,t);else for(let o in t){const i=ws(t[o]),s=e[o],a=w(i),c=w(s);if(a!=Ss&&a!=bs)i!=s&&Is(r,(""==n?"":n+".")+o,i);else if(a==Ss)c!=Ss||i.length<s.length?Is(r,(""==n?"":n+".")+o,i):i.forEach(((t,e)=>{xs(t,s[e],(""==n?"":n+".")+o+"["+e+"]",r)}));else if(a==bs)if(c!=bs||Object.keys(i).length<Object.keys(s).length)Is(r,(""==n?"":n+".")+o,i);else for(let t in i)xs(i[t],s[t],(""==n?"":n+".")+o+"."+t,r)}else i==Ss?s!=Ss||t.length<e.length?Is(r,n,t):t.forEach(((t,i)=>{xs(t,e[i],n+"["+i+"]",r)})):Is(r,n,t)}function Is(t,e,n){t[e]=n}function Ds(t){const e=t.ctx.__next_tick_callbacks;if(e&&e.length){const t=e.slice(0);e.length=0;for(let e=0;e<t.length;e++)t[e]()}}function As(t,e){const n=t.ctx;if(!n.__next_tick_pending&&!function(t){return jr.includes(t.update)}(t))return Kr(e&&e.bind(t.proxy));let r;return n.__next_tick_callbacks||(n.__next_tick_callbacks=[]),n.__next_tick_callbacks.push((()=>{e?Pr(e.bind(t.proxy),t,14):r&&r(t.proxy)})),new Promise((t=>{r=t}))}function ks(t,e){const n=typeof(t=ws(t));if("object"===n&&null!==t){let n=e.get(t);if(void 0!==n)return n;if(h(t)){const r=t.length;n=new Array(r),e.set(t,n);for(let i=0;i<r;i++)n[i]=ks(t[i],e)}else{n={},e.set(t,n);for(const r in t)l(t,r)&&(n[r]=ks(t[r],e))}return n}if("symbol"!==n)return t}function Os(t){return ks(t,"undefined"!=typeof WeakMap?new WeakMap:new Map)}function Rs(t,e,n){if(!e)return;(e=Os(e)).$eS=t.$eS||{};const r=t.ctx,i=r.mpType;if("page"===i||"component"===i){e.r0=1;const i=r.$scope,s=Object.keys(e),o=Es(e,n||function(t,e){const n=t.data,r=Object.create(null);return e.forEach((t=>{r[t]=n[t]})),r}(i,s));Object.keys(o).length?(r.__next_tick_pending=!0,i.setData(o,(()=>{r.__next_tick_pending=!1,Ds(t)})),Gr()):Ds(t)}}function Ps(t,e,n){e.appContext.config.globalProperties.$applyOptions(t,e,n);const r=t.computed;if(r){const t=Object.keys(r);if(t.length){const n=e.ctx;n.$computedKeys||(n.$computedKeys=[]),n.$computedKeys.push(...t)}}delete e.ctx.$onApplyOptions}function Ms(t,e=!1){const{setupState:n,$templateRefs:r,$templateUniElementRefs:i,ctx:{$scope:s,$mpPlatform:o}}=t;if("mp-alipay"===o)return;if(!s||!r&&!i)return;if(e)return r&&r.forEach((t=>Cs(t,null,n))),void(i&&i.forEach((t=>Cs(t,null,n))));const a="mp-baidu"===o||"mp-toutiao"===o,c=t=>{if(0===t.length)return[];const e=(s.selectAllComponents(".r")||[]).concat(s.selectAllComponents(".r-i-f")||[]);return t.filter((t=>{const r=function(t,e){const n=t.find((t=>t&&(t.properties||t.props).uI===e));if(n){const t=n.$vm;return t?ys(t.$)||t:function(t){y(t)&&vr(t);return t}(n)}return null}(e,t.i);return!(!a||null!==r)||(Cs(t,r,n),!1)}))},u=()=>{if(r){const e=c(r);e.length&&t.proxy&&t.proxy.$scope&&t.proxy.$scope.setData({r1:1},(()=>{c(e)}))}};i&&i.length&&As(t,(()=>{i.forEach((t=>{h(t.v)?t.v.forEach((e=>{Cs(t,e,n)})):Cs(t,t.v,n)}))})),s._$setRef?s._$setRef(u):As(t,u)}function Cs({r:t,f:e},n,r){if(p(t))t(n,{});else{const i=g(t),s=Tr(t);if(i||s)if(e){if(!s)return;h(t.value)||(t.value=[]);const e=t.value;if(-1===e.indexOf(n)){if(e.push(n),!n)return;n.$&&xi((()=>c(e,n)),n.$)}}else i?l(r,t)&&(r[t]=n):Tr(t)&&(t.value=n)}}const Bs=Jr;function Ns(t,e){const n=t.component=os(t,e.parentComponent,null);return n.ctx.$onApplyOptions=Ps,n.ctx.$children=[],"app"===e.mpType&&(n.render=r),e.onBeforeSetup&&e.onBeforeSetup(n,e),gs(n),e.parentComponent&&n.proxy&&e.parentComponent.ctx.$children.push(ys(n)||n.proxy),function(t){const e=Vs.bind(t);t.$updateScopedSlots=()=>Kr((()=>zr(e)));const n=()=>{if(t.isMounted){const{next:e,bu:n,u:r}=t;Us(t,!1),gn(),Gr(),mn(),n&&P(n),Us(t,!0),Rs(t,Ls(t)),r&&Bs(r)}else xi((()=>{Ms(t,!0)}),t),Rs(t,Ls(t))},i=t.effect=new cn(n,r,(()=>zr(s)),t.scope),s=t.update=()=>{i.dirty&&i.run()};s.id=t.uid,Us(t,!0),s()}(n),n.proxy}function Ls(t){const{type:e,vnode:n,proxy:r,withProxy:i,props:o,propsOptions:[a],slots:c,attrs:u,emit:l,render:h,renderCache:f,data:d,setupState:p,ctx:g,uid:m,appContext:{app:{config:{globalProperties:{pruneComponentPropsCache:y}}}},inheritAttrs:v}=t;let _;t.$uniElementIds=new Map,t.$templateRefs=[],t.$templateUniElementRefs=[],t.$templateUniElementStyles={},t.$ei=0,y(m),t.__counter=0===t.__counter?1:0;const w=ri(t);try{if(4&n.shapeFlag){js(v,o,a,u);const t=i||r;_=h.call(t,t,f,o,p,d,g)}else{js(v,o,a,e.props?u:(t=>{let e;for(const n in t)("class"===n||"style"===n||s(n))&&((e||(e={}))[n]=t[n]);return e})(u));const t=e;_=t.length>1?t(o,{attrs:u,slots:c,emit:l}):t(o,null)}}catch(S){Cr(S,t,1),_=!1}return Ms(t),ri(w),_}function js(t,e,n,r){if(e&&r&&!1!==t){const t=Object.keys(r).filter((t=>"class"!==t&&"style"!==t));if(!t.length)return;n&&t.some(o)?t.forEach((t=>{o(t)&&t.slice(9)in n||(e[t]=r[t])})):t.forEach((t=>e[t]=r[t]))}}function Vs(){const t=this.$scopedSlotsData;if(!t||0===t.length)return;const e=this.ctx.$scope,n=e.data,r=Object.create(null);t.forEach((({path:t,index:e,data:i})=>{const s=q(n,t),o=g(e)?`${t}.${e}`:`${t}[${e}]`;if(void 0===s||void 0===s[e])r[o]=i;else{const t=Es(i,s[e]);Object.keys(t).forEach((e=>{r[o+"."+e]=t[e]}))}})),t.length=0,Object.keys(r).length&&e.setData(r)}function Us({effect:t,update:e},n){t.allowRecurse=e.allowRecurse=n}const $s=function(t,e=null){p(t)||(t=a({},t)),null==e||y(e)||(e=null);const n=hi(),r=new WeakSet,i=n.app={_uid:fi++,_component:t,_props:e,_container:null,_context:n,_instance:null,version:_s,get config(){return n.config},set config(t){},use:(t,...e)=>(r.has(t)||(t&&p(t.install)?(r.add(t),t.install(i,...e)):p(t)&&(r.add(t),t(i,...e))),i),mixin:t=>(n.mixins.includes(t)||n.mixins.push(t),i),component:(t,e)=>e?(n.components[t]=e,i):n.components[t],directive:(t,e)=>e?(n.directives[t]=e,i):n.directives[t],mount(){},unmount(){},provide:(t,e)=>(n.provides[t]=e,i),runWithContext(t){const e=di;di=i;try{return t()}finally{di=e}}};return i};function Hs(t,e=null){("undefined"!=typeof window?window:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof global?global:"undefined"!=typeof my?my:void 0).__VUE__=!0;const n=$s(t,e),i=n._context;i.config.globalProperties.$nextTick=function(t){return As(this.$,t)};const s=t=>(t.appContext=i,t.shapeFlag=6,t),o=function(t,e){return Ns(s(t),e)},a=function(t){return t&&function(t){const{bum:e,scope:n,update:r,um:i}=t;e&&P(e);{const e=t.parent;if(e){const n=e.ctx.$children,r=ys(t)||t.proxy,i=n.indexOf(r);i>-1&&n.splice(i,1)}}n.stop(),r&&(r.active=!1),i&&Bs(i),Bs((()=>{t.isUnmounted=!0}))}(t.$)};return n.mount=function(){t.render=r;const e=Ns(s({type:t}),{mpType:"app",mpInstance:null,parentComponent:null,slots:[],props:null});return n._instance=e.$,e.$app=n,e.$createComponent=o,e.$destroyComponent=a,i.$appInstance=e,e},n.unmount=function(){},n}function qs(t,e,n,r){p(e)&&_i(t,e.bind(n),r)}function Fs(t,e,n){!function(t,e,n){const r=t.mpType||n.$mpType;r&&"component"!==r&&Object.keys(t).forEach((r=>{if(Z(r,t[r],!1)){const i=t[r];h(i)?i.forEach((t=>qs(r,t,n,e))):qs(r,i,n,e)}}))}(t,e,n)}function Ks(t,e,n){return t[e]=n}function zs(t,...e){const n=this[t];return n?n(...e):(console.error(`method ${t} not found`),null)}function Ws(t){const e=t.config.errorHandler;return function(n,r,i){e&&e(n,r,i);const s=t._instance;if(!s||!s.proxy)throw n;s.onError?s.proxy.$callHook("onError",n):Br(n,0,r&&r.$.vnode,!1)}}function Js(t,e){return t?[...new Set([].concat(t,e))]:e}let Gs;const Ys="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",Zs=/^(?:[A-Za-z\d+/]{4})*?(?:[A-Za-z\d+/]{2}(?:==)?|[A-Za-z\d+/]{3}=?)?$/;function Xs(){const t=en.getStorageSync("uni_id_token")||"",e=t.split(".");if(!t||3!==e.length)return{uid:null,role:[],permission:[],tokenExpired:0};let n;try{n=JSON.parse((r=e[1],decodeURIComponent(Gs(r).split("").map((function(t){return"%"+("00"+t.charCodeAt(0).toString(16)).slice(-2)})).join(""))))}catch(i){throw new Error("获取当前用户信息出错,详细错误信息为:"+i.message)}var r;return n.tokenExpired=1e3*n.exp,delete n.exp,delete n.iat,n}function Qs(t){const e=t.config;var n;e.errorHandler=et(t,Ws),n=e.optionMergeStrategies,G.forEach((t=>{n[t]=Js}));const r=e.globalProperties;!function(t){t.uniIDHasRole=function(t){const{role:e}=Xs();return e.indexOf(t)>-1},t.uniIDHasPermission=function(t){const{permission:e}=Xs();return this.uniIDHasRole("admin")||e.indexOf(t)>-1},t.uniIDTokenValid=function(){const{tokenExpired:t}=Xs();return t>Date.now()}}(r),r.$set=Ks,r.$applyOptions=Fs,r.$callMethod=zs,en.invokeCreateVueAppHook(t)}Gs="function"!=typeof atob?function(t){if(t=String(t).replace(/[\t\n\f\r ]+/g,""),!Zs.test(t))throw new Error("Failed to execute 'atob' on 'Window': The string to be decoded is not correctly encoded.");var e;t+="==".slice(2-(3&t.length));for(var n,r,i="",s=0;s<t.length;)e=Ys.indexOf(t.charAt(s++))<<18|Ys.indexOf(t.charAt(s++))<<12|(n=Ys.indexOf(t.charAt(s++)))<<6|(r=Ys.indexOf(t.charAt(s++))),i+=64===n?String.fromCharCode(e>>16&255):64===r?String.fromCharCode(e>>16&255,e>>8&255):String.fromCharCode(e>>16&255,e>>8&255,255&e);return i}:atob;const to=Object.create(null);function eo(t){delete to[t]}function no(t){if(!t)return;const[e,n]=t.split(",");return to[e]?to[e][parseInt(n)]:void 0}var ro={install(t){Qs(t),t.config.globalProperties.pruneComponentPropsCache=eo;const e=t.mount;t.mount=function(n){const r=e.call(t,n),i=function(){const t="createApp";if("undefined"!=typeof global&&void 0!==global[t])return global[t];if("undefined"!=typeof my)return my[t]}();return i?i(r):"undefined"!=typeof createMiniProgramApp&&createMiniProgramApp(r),r}}};function io(t){return g(t)?t:function(t){let e="";if(!t||g(t))return e;for(const n in t)e+=`${n.startsWith("--")?n:A(n)}:${t[n]};`;return e}(C(t))}function so(t,e){const n=cs(),i=n.ctx,s=void 0===e||"mp-weixin"!==i.$mpPlatform&&"mp-qq"!==i.$mpPlatform&&"mp-xhs"!==i.$mpPlatform||!g(e)&&"number"!=typeof e?"":"_"+e,o="e"+n.$ei+++s,c=i.$scope;if(!t)return delete c[o],o;const u=c[o];return u?u.value=t:c[o]=function(t,e){const n=t=>{var i;(i=t).type&&i.target&&(i.preventDefault=r,i.stopPropagation=r,i.stopImmediatePropagation=r,l(i,"detail")||(i.detail={}),l(i,"markerId")&&(i.detail="object"==typeof i.detail?i.detail:{},i.detail.markerId=i.markerId),S(i.detail)&&l(i.detail,"checked")&&!l(i.detail,"value")&&(i.detail.value=i.detail.checked),S(i.detail)&&(i.target=a({},i.target,i.detail)));let s=[t];e&&e.ctx.$getTriggerEventDetail&&"number"==typeof t.detail&&(t.detail=e.ctx.$getTriggerEventDetail(t.detail)),t.detail&&t.detail.__args__&&(s=t.detail.__args__);const o=n.value,c=()=>Mr(function(t,e){if(h(e)){const n=t.stopImmediatePropagation;return t.stopImmediatePropagation=()=>{n&&n.call(t),t._stopped=!0},e.map((t=>e=>!e._stopped&&t(e)))}return e}(t,o),e,5,s),u=t.target,f=!!u&&(!!u.dataset&&"true"===String(u.dataset.eventsync));if(!oo.includes(t.type)||f){const e=c();if("input"===t.type&&(h(e)||v(e)))return;return e}setTimeout(c)};return n.value=t,n}(t,n),o}const oo=["tap","longpress","longtap","transitionend","animationstart","animationiteration","animationend","touchforcechange"];function ao(t,e={},n){const r=cs(),{parent:i,isMounted:s,ctx:{$scope:o}}=r,a=(o.properties||o.props).uI;if(!a)return;if(!i&&!s)return void bi((()=>{ao(t,e,n)}),r);const c=function(t,e){let n=e.parent;for(;n;){const e=n.$ssi;if(e&&e[t])return e[t];n=n.parent}}(a,r);c&&c(t,e,n)}const co=function(t,e=null){return t&&(t.mpType="app"),Hs(t,e).use(ro)};const uo=["externalClasses"];const lo=/_(.*)_worklet_factory_/;function ho(t,e){const n=t.$children;for(let i=n.length-1;i>=0;i--){const t=n[i];if(t.$scope._$vueId===e)return t}let r;for(let i=n.length-1;i>=0;i--)if(r=ho(n[i],e),r)return r}const fo=["createSelectorQuery","createIntersectionObserver","selectAllComponents","selectComponent"];function po(t,e){const n=t.ctx;n.mpType=e.mpType,n.$mpType=e.mpType,n.$mpPlatform="mp-weixin",n.$scope=e.mpInstance,Object.defineProperties(n,{virtualHostId:{get(){const t=this.$scope.data.virtualHostId;return void 0===t?"":t}}}),n.$mp={},n._self={},t.slots={},h(e.slots)&&e.slots.length&&(e.slots.forEach((e=>{t.slots[e]=!0})),t.slots.d&&(t.slots.default=!0)),n.getOpenerEventChannel=function(){return e.mpInstance.getOpenerEventChannel()},n.$hasHook=go,n.$callHook=mo,t.emit=function(t,e){return function(n,...r){const i=e.$scope;if(i&&n){const t={__args__:r};i.triggerEvent(n,t)}return t.apply(this,[n,...r])}}(t.emit,n)}function go(t){const e=this.$[t];return!(!e||!e.length)}function mo(t,e){"mounted"===t&&(mo.call(this,"bm"),this.$.isMounted=!0,t="m");const n=this.$[t];return n&&((t,e)=>{let n;for(let r=0;r<t.length;r++)n=t[r](e);return n})(n,e)}const yo=["onLoad","onShow","onHide","onUnload","onResize","onTabItemTap","onReachBottom","onPullDownRefresh","onAddToFavorites"];function vo(t,e=new Set){if(t){Object.keys(t).forEach((n=>{Z(n,t[n])&&e.add(n)}));{const{extends:n,mixins:r}=t;r&&r.forEach((t=>vo(t,e))),n&&vo(n,e)}}return e}function _o(t,e,n){-1!==n.indexOf(e)||l(t,e)||(t[e]=function(t){return this.$vm&&this.$vm.$callHook(e,t)})}const wo=["onReady"];function So(t,e,n=wo){e.forEach((e=>_o(t,e,n)))}function bo(t,e,n=wo){vo(e).forEach((e=>_o(t,e,n)))}const Eo=H((()=>{const t=[],e=p(getApp)&&getApp({allowDefault:!0});if(e&&e.$vm&&e.$vm.$){const n=e.$vm.$.appContext.mixins;if(h(n)){const e=Object.keys(Y);n.forEach((n=>{e.forEach((e=>{l(n,e)&&!t.includes(e)&&t.push(e)}))}))}}return t}));const To=["onShow","onHide","onError","onThemeChange","onPageNotFound","onUnhandledRejection"];function xo(t,e){const n=t.$,r={globalData:t.$options&&t.$options.globalData||{},$vm:t,onLaunch(e){this.$vm=t;const r=n.ctx;this.$vm&&r.$scope&&r.$callHook||(po(n,{mpType:"app",mpInstance:this,slots:[]}),r.globalData=this.globalData,t.$callHook("onLaunch",e))}},i=wx.$onErrorHandlers;i&&(i.forEach((t=>{_i("onError",t,n)})),i.length=0),function(t){const e=xr(lt(wx.getAppBaseInfo().language)||"en");Object.defineProperty(t,"$locale",{get:()=>e.value,set(t){e.value=t}})}(t);const s=t.$.type;So(r,To),bo(r,s);{const t=s.methods;t&&a(r,t)}return r}function Io(t,e){if(p(t.onLaunch)){const e=wx.getLaunchOptionsSync&&wx.getLaunchOptionsSync();t.onLaunch(e)}p(t.onShow)&&wx.onAppShow&&wx.onAppShow((t=>{e.$callHook("onShow",t)})),p(t.onHide)&&wx.onAppHide&&wx.onAppHide((t=>{e.$callHook("onHide",t)}))}const Do=["eO","uR","uRIF","uI","uT","uP","uS"];function Ao(t){t.properties||(t.properties={}),a(t.properties,function(t,e=!1){const n={};if(!e){let t=function(t){const e=Object.create(null);t&&t.forEach((t=>{e[t]=!0})),this.setData({$slots:e})};Do.forEach((t=>{n[t]={type:null,value:""}})),n.uS={type:null,value:[]},n.uS.observer=t}return t.behaviors&&t.behaviors.includes("wx://form-field")&&(t.properties&&t.properties.name||(n.name={type:null,value:""}),t.properties&&t.properties.value||(n.value={type:null,value:""})),n}(t),function(t){const e={};return t&&t.virtualHost&&(e.virtualHostStyle={type:null,value:""},e.virtualHostClass={type:null,value:""},e.virtualHostHidden={type:null,value:""},e.virtualHostId={type:null,value:""}),e}(t.options))}const ko=[String,Number,Boolean,Object,Array,null];function Oo(t,e){const n=function(t,e){return h(t)&&1===t.length?t[0]:t}(t);return-1!==ko.indexOf(n)?n:null}function Ro(t,e){return(e?function(t){const e={};S(t)&&Object.keys(t).forEach((n=>{-1===Do.indexOf(n)&&(e[n]=t[n])}));return e}(t):no(t.uP))||{}}function Po(t){const e=function(){const t=this.properties.uP;t&&(this.$vm?function(t,e){const n=yr(e.props),r=no(t)||{};Mo(n,r)&&(!function(t,e,n,r){const{props:i,attrs:s,vnode:{patchFlag:o}}=t,a=yr(i),[c]=t.propsOptions;let u=!1;if(!(r||o>0)||16&o){let r;Gi(t,e,i,s)&&(u=!0);for(const s in a)e&&(l(e,s)||(r=A(s))!==s&&l(e,r))||(c?!n||void 0===n[s]&&void 0===n[r]||(i[s]=Yi(c,a,s,void 0,t,!0)):delete i[s]);if(s!==a)for(const t in s)e&&l(e,t)||(delete s[t],u=!0)}else if(8&o){const n=t.vnode.dynamicProps;for(let r=0;r<n.length;r++){let o=n[r];if(ei(t.emitsOptions,o))continue;const h=e[o];if(c)if(l(s,o))h!==s[o]&&(s[o]=h,u=!0);else{const e=I(o);i[e]=Yi(c,a,e,h,t,!1)}else h!==s[o]&&(s[o]=h,u=!0)}}u&&Dn(t,"set","$attrs")}(e,r,n,!1),i=e.update,jr.indexOf(i)>-1&&function(t){const e=jr.indexOf(t);e>Vr&&jr.splice(e,1)}(e.update),e.update());var i}(t,this.$vm.$):"m"===this.properties.uT&&function(t,e){const n=e.properties,r=no(t)||{};Mo(n,r,!1)&&e.setData(r)}(t,this))};t.observers||(t.observers={}),t.observers.uP=e}function Mo(t,e,n=!0){const r=Object.keys(e);if(n&&r.length!==Object.keys(t).length)return!0;for(let i=0;i<r.length;i++){const n=r[i];if(e[n]!==t[n])return!0}return!1}function Co(t,e){t.data={},t.behaviors=function(t){const e=t.behaviors;let n=t.props;n||(t.props=n=[]);const r=[];return h(e)&&e.forEach((t=>{r.push(t.replace("uni://","wx://")),"uni://form-field"===t&&(h(n)?(n.push("name"),n.push("modelValue")):(n.name={type:String,default:""},n.modelValue={type:[String,Number,Boolean,Array,Object,Date],default:""}))})),r}(e)}function Bo(t,{parse:e,mocks:n,isPage:r,isPageInProject:i,initRelation:s,handleLink:o,initLifetimes:c}){t=t.default||t;const u={multipleSlots:!0,addGlobalClass:!0,pureDataPattern:/^uP$/};h(t.mixins)&&t.mixins.forEach((t=>{y(t.options)&&a(u,t.options)})),t.options&&a(u,t.options);const f={options:u,lifetimes:c({mocks:n,isPage:r,initRelation:s,vueOptions:t}),pageLifetimes:{show(){this.$vm&&this.$vm.$callHook("onPageShow")},hide(){this.$vm&&this.$vm.$callHook("onPageHide")},resize(t){this.$vm&&this.$vm.$callHook("onPageResize",t)}},methods:{__l:o}};var d,p,g,m;return Co(f,t),Ao(f),Po(f),function(t,e){uo.forEach((n=>{l(e,n)&&(t[n]=e[n])}))}(f,t),d=f.methods,p=t.wxsCallMethods,h(p)&&p.forEach((t=>{d[t]=function(e){return this.$vm[t](e)}})),g=f.methods,(m=t.methods)&&Object.keys(m).forEach((t=>{const e=t.match(lo);if(e){const n=e[1];g[t]=m[t],g[n]=m[n]}})),e&&e(f,{handleLink:o}),f}let No,Lo;function jo(){return getApp().$vm}function Vo(t,e){const{parse:n,mocks:r,isPage:i,initRelation:s,handleLink:o,initLifetimes:a}=e,c=Bo(t,{mocks:r,isPage:i,isPageInProject:!0,initRelation:s,handleLink:o,initLifetimes:a});!function({properties:t},e){h(e)?e.forEach((e=>{t[e]={type:String,value:""}})):S(e)&&Object.keys(e).forEach((n=>{const r=e[n];if(S(r)){let e=r.default;p(e)&&(e=e());const i=r.type;r.type=Oo(i),t[n]={type:r.type,value:e}}else t[n]={type:Oo(r)}}))}(c,(t.default||t).props);const u=c.methods;return u.onLoad=function(t){var e;return this.options=t,this.$page={fullPath:(e=this.route+W(t),function(t){return 0===t.indexOf("/")}(e)?e:"/"+e)},this.$vm&&this.$vm.$callHook("onLoad",t)},So(u,yo),bo(u,t),function(t,e){if(!e)return;Object.keys(Y).forEach((n=>{e&Y[n]&&_o(t,n,[])}))}(u,t.__runtimeHooks),So(u,Eo()),n&&n(c,{handleLink:o}),c}const Uo=Page,$o=Component;function Ho(t){const e=t.triggerEvent,n=function(n,...r){return e.apply(t,[(i=n,I(i.replace(K,"-"))),...r]);var i};try{t.triggerEvent=n}catch(r){t._triggerEvent=n}}function qo(t,e,n){const r=e[t];e[t]=r?function(...t){return Ho(this),r.apply(this,t)}:function(){Ho(this)}}Page=function(t){return qo("onLoad",t),Uo(t)},Component=function(t){qo("created",t);return t.properties&&t.properties.uP||(Ao(t),Po(t)),$o(t)};var Fo=Object.freeze({__proto__:null,handleLink:function(t){const e=t.detail||t.value,n=e.vuePid;let r;n&&(r=ho(this.$vm,n)),r||(r=this.$vm),e.parent=r},initLifetimes:function({mocks:t,isPage:e,initRelation:n,vueOptions:r}){return{attached(){let i=this.properties;!function(t,e){if(!t)return;const n=t.split(","),r=n.length;1===r?e._$vueId=n[0]:2===r&&(e._$vueId=n[0],e._$vuePid=n[1])}(i.uI,this);const s={vuePid:this._$vuePid};n(this,s);const o=this,a=e(o);let c=i;this.$vm=function(t,e){No||(No=jo().$createComponent);const n=No(t,e);return ys(n.$)||n}({type:r,props:Ro(c,a)},{mpType:a?"page":"component",mpInstance:o,slots:i.uS||{},parentComponent:s.parent&&s.parent.$,onBeforeSetup(e,n){!function(t,e){Object.defineProperty(t,"refs",{get(){const t={};return function(t,e,n){t.selectAllComponents(e).forEach((t=>{const e=t.properties.uR;n[e]=t.$vm||t}))}(e,".r",t),e.selectAllComponents(".r-i-f").forEach((e=>{const n=e.properties.uR;n&&(t[n]||(t[n]=[]),t[n].push(e.$vm||e))})),t}})}(e,o),function(t,e,n){const r=t.ctx;n.forEach((n=>{l(e,n)&&(t[n]=r[n]=e[n])}))}(e,o,t),function(t,e){po(t,e);const n=t.ctx;fo.forEach((t=>{n[t]=function(...e){const r=n.$scope;if(r&&r[t])return r[t].apply(r,e)}}))}(e,n)}}),a||function(t){const e=t.$options;h(e.behaviors)&&e.behaviors.includes("uni://form-field")&&t.$watch("modelValue",(()=>{t.$scope&&t.$scope.setData({name:t.name,value:t.modelValue})}),{immediate:!0})}(this.$vm)},ready(){this.$vm&&(this.$vm.$callHook("mounted"),this.$vm.$callHook("onReady"))},detached(){var t;this.$vm&&(eo(this.$vm.$.uid),t=this.$vm,Lo||(Lo=jo().$destroyComponent),Lo(t))}}},initRelation:function(t,e){t.triggerEvent("__l",e)},isPage:function(t){return!!t.route},mocks:["__route__","__wxExparserNodeId__","__wxWebviewId__"]});const Ko=function(t){return App(xo(t))},zo=(Wo=Fo,function(t){return Component(Vo(t,Wo))});var Wo;const Jo=function(t){return function(e){return Component(Bo(e,t))}}(Fo),Go=function(t){Io(xo(t),t)},Yo=function(t){const e=xo(t),n=p(getApp)&&getApp({allowDefault:!0});if(!n)return;t.$.ctx.$scope=n;const r=n.globalData;r&&Object.keys(e.globalData).forEach((t=>{l(r,t)||(r[t]=e.globalData[t])})),Object.keys(e).forEach((t=>{l(n,t)||(n[t]=e[t])})),Io(e,t)};function Zo(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}wx.createApp=global.createApp=Ko,wx.createPage=zo,wx.createComponent=Jo,wx.createPluginApp=global.createPluginApp=Go,wx.createSubpackageApp=global.createSubpackageApp=Yo;var Xo,Qo={exports:{}};
/*! For license information please see gtpush-min.js.LICENSE.txt */self,Xo=()=>(()=>{var t={4736:(t,e,n)=>{var r;t=n.nmd(t);var i=function(t){var e=1e7,n=9007199254740992,r=f(n),s="0123456789abcdefghijklmnopqrstuvwxyz",o="function"==typeof BigInt;function a(t,e,n,r){return void 0===t?a[0]:void 0===e||10==+e&&!n?G(t):F(t,e,n,r)}function c(t,e){this.value=t,this.sign=e,this.isSmall=!1}function u(t){this.value=t,this.sign=t<0,this.isSmall=!0}function l(t){this.value=t}function h(t){return-n<t&&t<n}function f(t){return t<1e7?[t]:t<1e14?[t%1e7,Math.floor(t/1e7)]:[t%1e7,Math.floor(t/1e7)%1e7,Math.floor(t/1e14)]}function d(t){p(t);var n=t.length;if(n<4&&O(t,r)<0)switch(n){case 0:return 0;case 1:return t[0];case 2:return t[0]+t[1]*e;default:return t[0]+(t[1]+t[2]*e)*e}return t}function p(t){for(var e=t.length;0===t[--e];);t.length=e+1}function g(t){for(var e=new Array(t),n=-1;++n<t;)e[n]=0;return e}function m(t){return t>0?Math.floor(t):Math.ceil(t)}function y(t,n){var r,i,s=t.length,o=n.length,a=new Array(s),c=0,u=e;for(i=0;i<o;i++)c=(r=t[i]+n[i]+c)>=u?1:0,a[i]=r-c*u;for(;i<s;)c=(r=t[i]+c)===u?1:0,a[i++]=r-c*u;return c>0&&a.push(c),a}function v(t,e){return t.length>=e.length?y(t,e):y(e,t)}function _(t,n){var r,i,s=t.length,o=new Array(s),a=e;for(i=0;i<s;i++)r=t[i]-a+n,n=Math.floor(r/a),o[i]=r-n*a,n+=1;for(;n>0;)o[i++]=n%a,n=Math.floor(n/a);return o}function w(t,n){var r,i,s=t.length,o=n.length,a=new Array(s),c=0,u=e;for(r=0;r<o;r++)(i=t[r]-c-n[r])<0?(i+=u,c=1):c=0,a[r]=i;for(r=o;r<s;r++){if(!((i=t[r]-c)<0)){a[r++]=i;break}i+=u,a[r]=i}for(;r<s;r++)a[r]=t[r];return p(a),a}function S(t,n,r){var i,s,o=t.length,a=new Array(o),l=-n,h=e;for(i=0;i<o;i++)s=t[i]+l,l=Math.floor(s/h),s%=h,a[i]=s<0?s+h:s;return"number"==typeof(a=d(a))?(r&&(a=-a),new u(a)):new c(a,r)}function b(t,n){var r,i,s,o,a=t.length,c=n.length,u=g(a+c),l=e;for(s=0;s<a;++s){o=t[s];for(var h=0;h<c;++h)r=o*n[h]+u[s+h],i=Math.floor(r/l),u[s+h]=r-i*l,u[s+h+1]+=i}return p(u),u}function E(t,n){var r,i,s=t.length,o=new Array(s),a=e,c=0;for(i=0;i<s;i++)r=t[i]*n+c,c=Math.floor(r/a),o[i]=r-c*a;for(;c>0;)o[i++]=c%a,c=Math.floor(c/a);return o}function T(t,e){for(var n=[];e-- >0;)n.push(0);return n.concat(t)}function x(t,e){var n=Math.max(t.length,e.length);if(n<=30)return b(t,e);n=Math.ceil(n/2);var r=t.slice(n),i=t.slice(0,n),s=e.slice(n),o=e.slice(0,n),a=x(i,o),c=x(r,s),u=x(v(i,r),v(o,s)),l=v(v(a,T(w(w(u,a),c),n)),T(c,2*n));return p(l),l}function I(t,n,r){return new c(t<e?E(n,t):b(n,f(t)),r)}function D(t){var n,r,i,s,o=t.length,a=g(o+o),c=e;for(i=0;i<o;i++){r=0-(s=t[i])*s;for(var u=i;u<o;u++)n=s*t[u]*2+a[i+u]+r,r=Math.floor(n/c),a[i+u]=n-r*c;a[i+o]=r}return p(a),a}function A(t,e){var n,r,i,s,o=t.length,a=g(o);for(i=0,n=o-1;n>=0;--n)i=(s=1e7*i+t[n])-(r=m(s/e))*e,a[n]=0|r;return[a,0|i]}function k(t,n){var r,i=G(n);if(o)return[new l(t.value/i.value),new l(t.value%i.value)];var s,h=t.value,y=i.value;if(0===y)throw new Error("Cannot divide by zero");if(t.isSmall)return i.isSmall?[new u(m(h/y)),new u(h%y)]:[a[0],t];if(i.isSmall){if(1===y)return[t,a[0]];if(-1==y)return[t.negate(),a[0]];var v=Math.abs(y);if(v<e){s=d((r=A(h,v))[0]);var _=r[1];return t.sign&&(_=-_),"number"==typeof s?(t.sign!==i.sign&&(s=-s),[new u(s),new u(_)]):[new c(s,t.sign!==i.sign),new u(_)]}y=f(v)}var S=O(h,y);if(-1===S)return[a[0],t];if(0===S)return[a[t.sign===i.sign?1:-1],a[0]];r=h.length+y.length<=200?function(t,n){var r,i,s,o,a,c,u,l=t.length,h=n.length,f=e,p=g(n.length),m=n[h-1],y=Math.ceil(f/(2*m)),v=E(t,y),_=E(n,y);for(v.length<=l&&v.push(0),_.push(0),m=_[h-1],i=l-h;i>=0;i--){for(r=f-1,v[i+h]!==m&&(r=Math.floor((v[i+h]*f+v[i+h-1])/m)),s=0,o=0,c=_.length,a=0;a<c;a++)s+=r*_[a],u=Math.floor(s/f),o+=v[i+a]-(s-u*f),s=u,o<0?(v[i+a]=o+f,o=-1):(v[i+a]=o,o=0);for(;0!==o;){for(r-=1,s=0,a=0;a<c;a++)(s+=v[i+a]-f+_[a])<0?(v[i+a]=s+f,s=0):(v[i+a]=s,s=1);o+=s}p[i]=r}return v=A(v,y)[0],[d(p),d(v)]}(h,y):function(t,n){for(var r,i,s,o,a,c=t.length,u=n.length,l=[],h=[],f=e;c;)if(h.unshift(t[--c]),p(h),O(h,n)<0)l.push(0);else{s=h[(i=h.length)-1]*f+h[i-2],o=n[u-1]*f+n[u-2],i>u&&(s=(s+1)*f),r=Math.ceil(s/o);do{if(O(a=E(n,r),h)<=0)break;r--}while(r);l.push(r),h=w(h,a)}return l.reverse(),[d(l),d(h)]}(h,y),s=r[0];var b=t.sign!==i.sign,T=r[1],x=t.sign;return"number"==typeof s?(b&&(s=-s),s=new u(s)):s=new c(s,b),"number"==typeof T?(x&&(T=-T),T=new u(T)):T=new c(T,x),[s,T]}function O(t,e){if(t.length!==e.length)return t.length>e.length?1:-1;for(var n=t.length-1;n>=0;n--)if(t[n]!==e[n])return t[n]>e[n]?1:-1;return 0}function R(t){var e=t.abs();return!e.isUnit()&&(!!(e.equals(2)||e.equals(3)||e.equals(5))||!(e.isEven()||e.isDivisibleBy(3)||e.isDivisibleBy(5))&&(!!e.lesser(49)||void 0))}function P(t,e){for(var n,r,s,o=t.prev(),a=o,c=0;a.isEven();)a=a.divide(2),c++;t:for(r=0;r<e.length;r++)if(!t.lesser(e[r])&&!(s=i(e[r]).modPow(a,t)).isUnit()&&!s.equals(o)){for(n=c-1;0!=n;n--){if((s=s.square().mod(t)).isUnit())return!1;if(s.equals(o))continue t}return!1}return!0}c.prototype=Object.create(a.prototype),u.prototype=Object.create(a.prototype),l.prototype=Object.create(a.prototype),c.prototype.add=function(t){var e=G(t);if(this.sign!==e.sign)return this.subtract(e.negate());var n=this.value,r=e.value;return e.isSmall?new c(_(n,Math.abs(r)),this.sign):new c(v(n,r),this.sign)},c.prototype.plus=c.prototype.add,u.prototype.add=function(t){var e=G(t),n=this.value;if(n<0!==e.sign)return this.subtract(e.negate());var r=e.value;if(e.isSmall){if(h(n+r))return new u(n+r);r=f(Math.abs(r))}return new c(_(r,Math.abs(n)),n<0)},u.prototype.plus=u.prototype.add,l.prototype.add=function(t){return new l(this.value+G(t).value)},l.prototype.plus=l.prototype.add,c.prototype.subtract=function(t){var e=G(t);if(this.sign!==e.sign)return this.add(e.negate());var n=this.value,r=e.value;return e.isSmall?S(n,Math.abs(r),this.sign):function(t,e,n){var r;return O(t,e)>=0?r=w(t,e):(r=w(e,t),n=!n),"number"==typeof(r=d(r))?(n&&(r=-r),new u(r)):new c(r,n)}(n,r,this.sign)},c.prototype.minus=c.prototype.subtract,u.prototype.subtract=function(t){var e=G(t),n=this.value;if(n<0!==e.sign)return this.add(e.negate());var r=e.value;return e.isSmall?new u(n-r):S(r,Math.abs(n),n>=0)},u.prototype.minus=u.prototype.subtract,l.prototype.subtract=function(t){return new l(this.value-G(t).value)},l.prototype.minus=l.prototype.subtract,c.prototype.negate=function(){return new c(this.value,!this.sign)},u.prototype.negate=function(){var t=this.sign,e=new u(-this.value);return e.sign=!t,e},l.prototype.negate=function(){return new l(-this.value)},c.prototype.abs=function(){return new c(this.value,!1)},u.prototype.abs=function(){return new u(Math.abs(this.value))},l.prototype.abs=function(){return new l(this.value>=0?this.value:-this.value)},c.prototype.multiply=function(t){var n,r=G(t),i=this.value,s=r.value,o=this.sign!==r.sign;if(r.isSmall){if(0===s)return a[0];if(1===s)return this;if(-1===s)return this.negate();if((n=Math.abs(s))<e)return new c(E(i,n),o);s=f(n)}return function(t,e){return-.012*t-.012*e+15e-6*t*e>0}(i.length,s.length)?new c(x(i,s),o):new c(b(i,s),o)},c.prototype.times=c.prototype.multiply,u.prototype._multiplyBySmall=function(t){return h(t.value*this.value)?new u(t.value*this.value):I(Math.abs(t.value),f(Math.abs(this.value)),this.sign!==t.sign)},c.prototype._multiplyBySmall=function(t){return 0===t.value?a[0]:1===t.value?this:-1===t.value?this.negate():I(Math.abs(t.value),this.value,this.sign!==t.sign)},u.prototype.multiply=function(t){return G(t)._multiplyBySmall(this)},u.prototype.times=u.prototype.multiply,l.prototype.multiply=function(t){return new l(this.value*G(t).value)},l.prototype.times=l.prototype.multiply,c.prototype.square=function(){return new c(D(this.value),!1)},u.prototype.square=function(){var t=this.value*this.value;return h(t)?new u(t):new c(D(f(Math.abs(this.value))),!1)},l.prototype.square=function(t){return new l(this.value*this.value)},c.prototype.divmod=function(t){var e=k(this,t);return{quotient:e[0],remainder:e[1]}},l.prototype.divmod=u.prototype.divmod=c.prototype.divmod,c.prototype.divide=function(t){return k(this,t)[0]},l.prototype.over=l.prototype.divide=function(t){return new l(this.value/G(t).value)},u.prototype.over=u.prototype.divide=c.prototype.over=c.prototype.divide,c.prototype.mod=function(t){return k(this,t)[1]},l.prototype.mod=l.prototype.remainder=function(t){return new l(this.value%G(t).value)},u.prototype.remainder=u.prototype.mod=c.prototype.remainder=c.prototype.mod,c.prototype.pow=function(t){var e,n,r,i=G(t),s=this.value,o=i.value;if(0===o)return a[1];if(0===s)return a[0];if(1===s)return a[1];if(-1===s)return i.isEven()?a[1]:a[-1];if(i.sign)return a[0];if(!i.isSmall)throw new Error("The exponent "+i.toString()+" is too large.");if(this.isSmall&&h(e=Math.pow(s,o)))return new u(m(e));for(n=this,r=a[1];!0&o&&(r=r.times(n),--o),0!==o;)o/=2,n=n.square();return r},u.prototype.pow=c.prototype.pow,l.prototype.pow=function(t){var e=G(t),n=this.value,r=e.value,i=BigInt(0),s=BigInt(1),o=BigInt(2);if(r===i)return a[1];if(n===i)return a[0];if(n===s)return a[1];if(n===BigInt(-1))return e.isEven()?a[1]:a[-1];if(e.isNegative())return new l(i);for(var c=this,u=a[1];(r&s)===s&&(u=u.times(c),--r),r!==i;)r/=o,c=c.square();return u},c.prototype.modPow=function(t,e){if(t=G(t),(e=G(e)).isZero())throw new Error("Cannot take modPow with modulus 0");var n=a[1],r=this.mod(e);for(t.isNegative()&&(t=t.multiply(a[-1]),r=r.modInv(e));t.isPositive();){if(r.isZero())return a[0];t.isOdd()&&(n=n.multiply(r).mod(e)),t=t.divide(2),r=r.square().mod(e)}return n},l.prototype.modPow=u.prototype.modPow=c.prototype.modPow,c.prototype.compareAbs=function(t){var e=G(t),n=this.value,r=e.value;return e.isSmall?1:O(n,r)},u.prototype.compareAbs=function(t){var e=G(t),n=Math.abs(this.value),r=e.value;return e.isSmall?n===(r=Math.abs(r))?0:n>r?1:-1:-1},l.prototype.compareAbs=function(t){var e=this.value,n=G(t).value;return(e=e>=0?e:-e)===(n=n>=0?n:-n)?0:e>n?1:-1},c.prototype.compare=function(t){if(t===1/0)return-1;if(t===-1/0)return 1;var e=G(t),n=this.value,r=e.value;return this.sign!==e.sign?e.sign?1:-1:e.isSmall?this.sign?-1:1:O(n,r)*(this.sign?-1:1)},c.prototype.compareTo=c.prototype.compare,u.prototype.compare=function(t){if(t===1/0)return-1;if(t===-1/0)return 1;var e=G(t),n=this.value,r=e.value;return e.isSmall?n==r?0:n>r?1:-1:n<0!==e.sign?n<0?-1:1:n<0?1:-1},u.prototype.compareTo=u.prototype.compare,l.prototype.compare=function(t){if(t===1/0)return-1;if(t===-1/0)return 1;var e=this.value,n=G(t).value;return e===n?0:e>n?1:-1},l.prototype.compareTo=l.prototype.compare,c.prototype.equals=function(t){return 0===this.compare(t)},l.prototype.eq=l.prototype.equals=u.prototype.eq=u.prototype.equals=c.prototype.eq=c.prototype.equals,c.prototype.notEquals=function(t){return 0!==this.compare(t)},l.prototype.neq=l.prototype.notEquals=u.prototype.neq=u.prototype.notEquals=c.prototype.neq=c.prototype.notEquals,c.prototype.greater=function(t){return this.compare(t)>0},l.prototype.gt=l.prototype.greater=u.prototype.gt=u.prototype.greater=c.prototype.gt=c.prototype.greater,c.prototype.lesser=function(t){return this.compare(t)<0},l.prototype.lt=l.prototype.lesser=u.prototype.lt=u.prototype.lesser=c.prototype.lt=c.prototype.lesser,c.prototype.greaterOrEquals=function(t){return this.compare(t)>=0},l.prototype.geq=l.prototype.greaterOrEquals=u.prototype.geq=u.prototype.greaterOrEquals=c.prototype.geq=c.prototype.greaterOrEquals,c.prototype.lesserOrEquals=function(t){return this.compare(t)<=0},l.prototype.leq=l.prototype.lesserOrEquals=u.prototype.leq=u.prototype.lesserOrEquals=c.prototype.leq=c.prototype.lesserOrEquals,c.prototype.isEven=function(){return 0==(1&this.value[0])},u.prototype.isEven=function(){return 0==(1&this.value)},l.prototype.isEven=function(){return(this.value&BigInt(1))===BigInt(0)},c.prototype.isOdd=function(){return 1==(1&this.value[0])},u.prototype.isOdd=function(){return 1==(1&this.value)},l.prototype.isOdd=function(){return(this.value&BigInt(1))===BigInt(1)},c.prototype.isPositive=function(){return!this.sign},u.prototype.isPositive=function(){return this.value>0},l.prototype.isPositive=u.prototype.isPositive,c.prototype.isNegative=function(){return this.sign},u.prototype.isNegative=function(){return this.value<0},l.prototype.isNegative=u.prototype.isNegative,c.prototype.isUnit=function(){return!1},u.prototype.isUnit=function(){return 1===Math.abs(this.value)},l.prototype.isUnit=function(){return this.abs().value===BigInt(1)},c.prototype.isZero=function(){return!1},u.prototype.isZero=function(){return 0===this.value},l.prototype.isZero=function(){return this.value===BigInt(0)},c.prototype.isDivisibleBy=function(t){var e=G(t);return!e.isZero()&&(!!e.isUnit()||(0===e.compareAbs(2)?this.isEven():this.mod(e).isZero()))},l.prototype.isDivisibleBy=u.prototype.isDivisibleBy=c.prototype.isDivisibleBy,c.prototype.isPrime=function(e){var n=R(this);if(n!==t)return n;var r=this.abs(),s=r.bitLength();if(s<=64)return P(r,[2,3,5,7,11,13,17,19,23,29,31,37]);for(var o=Math.log(2)*s.toJSNumber(),a=Math.ceil(!0===e?2*Math.pow(o,2):o),c=[],u=0;u<a;u++)c.push(i(u+2));return P(r,c)},l.prototype.isPrime=u.prototype.isPrime=c.prototype.isPrime,c.prototype.isProbablePrime=function(e,n){var r=R(this);if(r!==t)return r;for(var s=this.abs(),o=e===t?5:e,a=[],c=0;c<o;c++)a.push(i.randBetween(2,s.minus(2),n));return P(s,a)},l.prototype.isProbablePrime=u.prototype.isProbablePrime=c.prototype.isProbablePrime,c.prototype.modInv=function(t){for(var e,n,r,s=i.zero,o=i.one,a=G(t),c=this.abs();!c.isZero();)e=a.divide(c),n=s,r=a,s=o,a=c,o=n.subtract(e.multiply(o)),c=r.subtract(e.multiply(c));if(!a.isUnit())throw new Error(this.toString()+" and "+t.toString()+" are not co-prime");return-1===s.compare(0)&&(s=s.add(t)),this.isNegative()?s.negate():s},l.prototype.modInv=u.prototype.modInv=c.prototype.modInv,c.prototype.next=function(){var t=this.value;return this.sign?S(t,1,this.sign):new c(_(t,1),this.sign)},u.prototype.next=function(){var t=this.value;return t+1<n?new u(t+1):new c(r,!1)},l.prototype.next=function(){return new l(this.value+BigInt(1))},c.prototype.prev=function(){var t=this.value;return this.sign?new c(_(t,1),!0):S(t,1,this.sign)},u.prototype.prev=function(){var t=this.value;return t-1>-n?new u(t-1):new c(r,!0)},l.prototype.prev=function(){return new l(this.value-BigInt(1))};for(var M=[1];2*M[M.length-1]<=e;)M.push(2*M[M.length-1]);var C=M.length,B=M[C-1];function N(t){return Math.abs(t)<=e}function L(t,e,n){e=G(e);for(var r=t.isNegative(),s=e.isNegative(),o=r?t.not():t,a=s?e.not():e,c=0,u=0,l=null,h=null,f=[];!o.isZero()||!a.isZero();)c=(l=k(o,B))[1].toJSNumber(),r&&(c=B-1-c),u=(h=k(a,B))[1].toJSNumber(),s&&(u=B-1-u),o=l[0],a=h[0],f.push(n(c,u));for(var d=0!==n(r?1:0,s?1:0)?i(-1):i(0),p=f.length-1;p>=0;p-=1)d=d.multiply(B).add(i(f[p]));return d}c.prototype.shiftLeft=function(t){var e=G(t).toJSNumber();if(!N(e))throw new Error(String(e)+" is too large for shifting.");if(e<0)return this.shiftRight(-e);var n=this;if(n.isZero())return n;for(;e>=C;)n=n.multiply(B),e-=C-1;return n.multiply(M[e])},l.prototype.shiftLeft=u.prototype.shiftLeft=c.prototype.shiftLeft,c.prototype.shiftRight=function(t){var e,n=G(t).toJSNumber();if(!N(n))throw new Error(String(n)+" is too large for shifting.");if(n<0)return this.shiftLeft(-n);for(var r=this;n>=C;){if(r.isZero()||r.isNegative()&&r.isUnit())return r;r=(e=k(r,B))[1].isNegative()?e[0].prev():e[0],n-=C-1}return(e=k(r,M[n]))[1].isNegative()?e[0].prev():e[0]},l.prototype.shiftRight=u.prototype.shiftRight=c.prototype.shiftRight,c.prototype.not=function(){return this.negate().prev()},l.prototype.not=u.prototype.not=c.prototype.not,c.prototype.and=function(t){return L(this,t,(function(t,e){return t&e}))},l.prototype.and=u.prototype.and=c.prototype.and,c.prototype.or=function(t){return L(this,t,(function(t,e){return t|e}))},l.prototype.or=u.prototype.or=c.prototype.or,c.prototype.xor=function(t){return L(this,t,(function(t,e){return t^e}))},l.prototype.xor=u.prototype.xor=c.prototype.xor;var j=1<<30;function V(t){var n=t.value,r="number"==typeof n?n|j:"bigint"==typeof n?n|BigInt(j):n[0]+n[1]*e|1073758208;return r&-r}function U(t,e){if(e.compareTo(t)<=0){var n=U(t,e.square(e)),r=n.p,s=n.e,o=r.multiply(e);return o.compareTo(t)<=0?{p:o,e:2*s+1}:{p:r,e:2*s}}return{p:i(1),e:0}}function $(t,e){return t=G(t),e=G(e),t.greater(e)?t:e}function H(t,e){return t=G(t),e=G(e),t.lesser(e)?t:e}function q(t,e){if(t=G(t).abs(),e=G(e).abs(),t.equals(e))return t;if(t.isZero())return e;if(e.isZero())return t;for(var n,r,i=a[1];t.isEven()&&e.isEven();)n=H(V(t),V(e)),t=t.divide(n),e=e.divide(n),i=i.multiply(n);for(;t.isEven();)t=t.divide(V(t));do{for(;e.isEven();)e=e.divide(V(e));t.greater(e)&&(r=e,e=t,t=r),e=e.subtract(t)}while(!e.isZero());return i.isUnit()?t:t.multiply(i)}c.prototype.bitLength=function(){var t=this;return t.compareTo(i(0))<0&&(t=t.negate().subtract(i(1))),0===t.compareTo(i(0))?i(0):i(U(t,i(2)).e).add(i(1))},l.prototype.bitLength=u.prototype.bitLength=c.prototype.bitLength;var F=function(t,e,n,r){n=n||s,t=String(t),r||(t=t.toLowerCase(),n=n.toLowerCase());var i,o=t.length,a=Math.abs(e),c={};for(i=0;i<n.length;i++)c[n[i]]=i;for(i=0;i<o;i++)if("-"!==(h=t[i])&&h in c&&c[h]>=a){if("1"===h&&1===a)continue;throw new Error(h+" is not a valid digit in base "+e+".")}e=G(e);var u=[],l="-"===t[0];for(i=l?1:0;i<t.length;i++){var h;if((h=t[i])in c)u.push(G(c[h]));else{if("<"!==h)throw new Error(h+" is not a valid character");var f=i;do{i++}while(">"!==t[i]&&i<t.length);u.push(G(t.slice(f+1,i)))}}return K(u,e,l)};function K(t,e,n){var r,i=a[0],s=a[1];for(r=t.length-1;r>=0;r--)i=i.add(t[r].times(s)),s=s.times(e);return n?i.negate():i}function z(t,e){if((e=i(e)).isZero()){if(t.isZero())return{value:[0],isNegative:!1};throw new Error("Cannot convert nonzero numbers to base 0.")}if(e.equals(-1)){if(t.isZero())return{value:[0],isNegative:!1};if(t.isNegative())return{value:[].concat.apply([],Array.apply(null,Array(-t.toJSNumber())).map(Array.prototype.valueOf,[1,0])),isNegative:!1};var n=Array.apply(null,Array(t.toJSNumber()-1)).map(Array.prototype.valueOf,[0,1]);return n.unshift([1]),{value:[].concat.apply([],n),isNegative:!1}}var r=!1;if(t.isNegative()&&e.isPositive()&&(r=!0,t=t.abs()),e.isUnit())return t.isZero()?{value:[0],isNegative:!1}:{value:Array.apply(null,Array(t.toJSNumber())).map(Number.prototype.valueOf,1),isNegative:r};for(var s,o=[],a=t;a.isNegative()||a.compareAbs(e)>=0;){s=a.divmod(e),a=s.quotient;var c=s.remainder;c.isNegative()&&(c=e.minus(c).abs(),a=a.next()),o.push(c.toJSNumber())}return o.push(a.toJSNumber()),{value:o.reverse(),isNegative:r}}function W(t,e,n){var r=z(t,e);return(r.isNegative?"-":"")+r.value.map((function(t){return function(t,e){return t<(e=e||s).length?e[t]:"<"+t+">"}(t,n)})).join("")}function J(t){if(h(+t)){var e=+t;if(e===m(e))return o?new l(BigInt(e)):new u(e);throw new Error("Invalid integer: "+t)}var n="-"===t[0];n&&(t=t.slice(1));var r=t.split(/e/i);if(r.length>2)throw new Error("Invalid integer: "+r.join("e"));if(2===r.length){var i=r[1];if("+"===i[0]&&(i=i.slice(1)),(i=+i)!==m(i)||!h(i))throw new Error("Invalid integer: "+i+" is not a valid exponent.");var s=r[0],a=s.indexOf(".");if(a>=0&&(i-=s.length-a-1,s=s.slice(0,a)+s.slice(a+1)),i<0)throw new Error("Cannot include negative exponent part for integers");t=s+=new Array(i+1).join("0")}if(!/^([0-9][0-9]*)$/.test(t))throw new Error("Invalid integer: "+t);if(o)return new l(BigInt(n?"-"+t:t));for(var f=[],d=t.length,g=d-7;d>0;)f.push(+t.slice(g,d)),(g-=7)<0&&(g=0),d-=7;return p(f),new c(f,n)}function G(t){return"number"==typeof t?function(t){if(o)return new l(BigInt(t));if(h(t)){if(t!==m(t))throw new Error(t+" is not an integer.");return new u(t)}return J(t.toString())}(t):"string"==typeof t?J(t):"bigint"==typeof t?new l(t):t}c.prototype.toArray=function(t){return z(this,t)},u.prototype.toArray=function(t){return z(this,t)},l.prototype.toArray=function(t){return z(this,t)},c.prototype.toString=function(e,n){if(e===t&&(e=10),10!==e)return W(this,e,n);for(var r,i=this.value,s=i.length,o=String(i[--s]);--s>=0;)r=String(i[s]),o+="0000000".slice(r.length)+r;return(this.sign?"-":"")+o},u.prototype.toString=function(e,n){return e===t&&(e=10),10!=e?W(this,e,n):String(this.value)},l.prototype.toString=u.prototype.toString,l.prototype.toJSON=c.prototype.toJSON=u.prototype.toJSON=function(){return this.toString()},c.prototype.valueOf=function(){return parseInt(this.toString(),10)},c.prototype.toJSNumber=c.prototype.valueOf,u.prototype.valueOf=function(){return this.value},u.prototype.toJSNumber=u.prototype.valueOf,l.prototype.valueOf=l.prototype.toJSNumber=function(){return parseInt(this.toString(),10)};for(var Y=0;Y<1e3;Y++)a[Y]=G(Y),Y>0&&(a[-Y]=G(-Y));return a.one=a[1],a.zero=a[0],a.minusOne=a[-1],a.max=$,a.min=H,a.gcd=q,a.lcm=function(t,e){return t=G(t).abs(),e=G(e).abs(),t.divide(q(t,e)).multiply(e)},a.isInstance=function(t){return t instanceof c||t instanceof u||t instanceof l},a.randBetween=function(t,n,r){t=G(t),n=G(n);var i=r||Math.random,s=H(t,n),o=$(t,n).subtract(s).add(1);if(o.isSmall)return s.add(Math.floor(i()*o));for(var c=z(o,e).value,u=[],l=!0,h=0;h<c.length;h++){var f=l?c[h]+(h+1<c.length?c[h+1]/e:0):e,d=m(i()*f);u.push(d),d<c[h]&&(l=!1)}return s.add(a.fromArray(u,e,!1))},a.fromArray=function(t,e,n){return K(t.map(G),G(e||10),n)},a}();t.hasOwnProperty("exports")&&(t.exports=i),void 0!==(r=function(){return i}.call(e,n,e,t))&&(t.exports=r)},452:function(t,e,n){var r;t.exports=(r=n(8249),n(8269),n(8214),n(888),n(5109),function(){var t=r,e=t.lib.BlockCipher,n=t.algo,i=[],s=[],o=[],a=[],c=[],u=[],l=[],h=[],f=[],d=[];!function(){for(var t=[],e=0;e<256;e++)t[e]=e<128?e<<1:e<<1^283;var n=0,r=0;for(e=0;e<256;e++){var p=r^r<<1^r<<2^r<<3^r<<4;p=p>>>8^255&p^99,i[n]=p,s[p]=n;var g=t[n],m=t[g],y=t[m],v=257*t[p]^16843008*p;o[n]=v<<24|v>>>8,a[n]=v<<16|v>>>16,c[n]=v<<8|v>>>24,u[n]=v,v=16843009*y^65537*m^257*g^16843008*n,l[p]=v<<24|v>>>8,h[p]=v<<16|v>>>16,f[p]=v<<8|v>>>24,d[p]=v,n?(n=g^t[t[t[y^g]]],r^=t[t[r]]):n=r=1}}();var p=[0,1,2,4,8,16,32,64,128,27,54],g=n.AES=e.extend({_doReset:function(){if(!this._nRounds||this._keyPriorReset!==this._key){for(var t=this._keyPriorReset=this._key,e=t.words,n=t.sigBytes/4,r=4*((this._nRounds=n+6)+1),s=this._keySchedule=[],o=0;o<r;o++)o<n?s[o]=e[o]:(u=s[o-1],o%n?n>6&&o%n==4&&(u=i[u>>>24]<<24|i[u>>>16&255]<<16|i[u>>>8&255]<<8|i[255&u]):(u=i[(u=u<<8|u>>>24)>>>24]<<24|i[u>>>16&255]<<16|i[u>>>8&255]<<8|i[255&u],u^=p[o/n|0]<<24),s[o]=s[o-n]^u);for(var a=this._invKeySchedule=[],c=0;c<r;c++){if(o=r-c,c%4)var u=s[o];else u=s[o-4];a[c]=c<4||o<=4?u:l[i[u>>>24]]^h[i[u>>>16&255]]^f[i[u>>>8&255]]^d[i[255&u]]}}},encryptBlock:function(t,e){this._doCryptBlock(t,e,this._keySchedule,o,a,c,u,i)},decryptBlock:function(t,e){var n=t[e+1];t[e+1]=t[e+3],t[e+3]=n,this._doCryptBlock(t,e,this._invKeySchedule,l,h,f,d,s),n=t[e+1],t[e+1]=t[e+3],t[e+3]=n},_doCryptBlock:function(t,e,n,r,i,s,o,a){for(var c=this._nRounds,u=t[e]^n[0],l=t[e+1]^n[1],h=t[e+2]^n[2],f=t[e+3]^n[3],d=4,p=1;p<c;p++){var g=r[u>>>24]^i[l>>>16&255]^s[h>>>8&255]^o[255&f]^n[d++],m=r[l>>>24]^i[h>>>16&255]^s[f>>>8&255]^o[255&u]^n[d++],y=r[h>>>24]^i[f>>>16&255]^s[u>>>8&255]^o[255&l]^n[d++],v=r[f>>>24]^i[u>>>16&255]^s[l>>>8&255]^o[255&h]^n[d++];u=g,l=m,h=y,f=v}g=(a[u>>>24]<<24|a[l>>>16&255]<<16|a[h>>>8&255]<<8|a[255&f])^n[d++],m=(a[l>>>24]<<24|a[h>>>16&255]<<16|a[f>>>8&255]<<8|a[255&u])^n[d++],y=(a[h>>>24]<<24|a[f>>>16&255]<<16|a[u>>>8&255]<<8|a[255&l])^n[d++],v=(a[f>>>24]<<24|a[u>>>16&255]<<16|a[l>>>8&255]<<8|a[255&h])^n[d++],t[e]=g,t[e+1]=m,t[e+2]=y,t[e+3]=v},keySize:8});t.AES=e._createHelper(g)}(),r.AES)},5109:function(t,e,n){var r;t.exports=(r=n(8249),n(888),void(r.lib.Cipher||function(t){var e=r,n=e.lib,i=n.Base,s=n.WordArray,o=n.BufferedBlockAlgorithm,a=e.enc;a.Utf8;var c=a.Base64,u=e.algo.EvpKDF,l=n.Cipher=o.extend({cfg:i.extend(),createEncryptor:function(t,e){return this.create(this._ENC_XFORM_MODE,t,e)},createDecryptor:function(t,e){return this.create(this._DEC_XFORM_MODE,t,e)},init:function(t,e,n){this.cfg=this.cfg.extend(n),this._xformMode=t,this._key=e,this.reset()},reset:function(){o.reset.call(this),this._doReset()},process:function(t){return this._append(t),this._process()},finalize:function(t){return t&&this._append(t),this._doFinalize()},keySize:4,ivSize:4,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function t(t){return"string"==typeof t?_:y}return function(e){return{encrypt:function(n,r,i){return t(r).encrypt(e,n,r,i)},decrypt:function(n,r,i){return t(r).decrypt(e,n,r,i)}}}}()});n.StreamCipher=l.extend({_doFinalize:function(){return this._process(!0)},blockSize:1});var h=e.mode={},f=n.BlockCipherMode=i.extend({createEncryptor:function(t,e){return this.Encryptor.create(t,e)},createDecryptor:function(t,e){return this.Decryptor.create(t,e)},init:function(t,e){this._cipher=t,this._iv=e}}),d=h.CBC=function(){var e=f.extend();function n(e,n,r){var i,s=this._iv;s?(i=s,this._iv=t):i=this._prevBlock;for(var o=0;o<r;o++)e[n+o]^=i[o]}return e.Encryptor=e.extend({processBlock:function(t,e){var r=this._cipher,i=r.blockSize;n.call(this,t,e,i),r.encryptBlock(t,e),this._prevBlock=t.slice(e,e+i)}}),e.Decryptor=e.extend({processBlock:function(t,e){var r=this._cipher,i=r.blockSize,s=t.slice(e,e+i);r.decryptBlock(t,e),n.call(this,t,e,i),this._prevBlock=s}}),e}(),p=(e.pad={}).Pkcs7={pad:function(t,e){for(var n=4*e,r=n-t.sigBytes%n,i=r<<24|r<<16|r<<8|r,o=[],a=0;a<r;a+=4)o.push(i);var c=s.create(o,r);t.concat(c)},unpad:function(t){var e=255&t.words[t.sigBytes-1>>>2];t.sigBytes-=e}};n.BlockCipher=l.extend({cfg:l.cfg.extend({mode:d,padding:p}),reset:function(){var t;l.reset.call(this);var e=this.cfg,n=e.iv,r=e.mode;this._xformMode==this._ENC_XFORM_MODE?t=r.createEncryptor:(t=r.createDecryptor,this._minBufferSize=1),this._mode&&this._mode.__creator==t?this._mode.init(this,n&&n.words):(this._mode=t.call(r,this,n&&n.words),this._mode.__creator=t)},_doProcessBlock:function(t,e){this._mode.processBlock(t,e)},_doFinalize:function(){var t,e=this.cfg.padding;return this._xformMode==this._ENC_XFORM_MODE?(e.pad(this._data,this.blockSize),t=this._process(!0)):(t=this._process(!0),e.unpad(t)),t},blockSize:4});var g=n.CipherParams=i.extend({init:function(t){this.mixIn(t)},toString:function(t){return(t||this.formatter).stringify(this)}}),m=(e.format={}).OpenSSL={stringify:function(t){var e=t.ciphertext,n=t.salt;return(n?s.create([1398893684,1701076831]).concat(n).concat(e):e).toString(c)},parse:function(t){var e,n=c.parse(t),r=n.words;return 1398893684==r[0]&&1701076831==r[1]&&(e=s.create(r.slice(2,4)),r.splice(0,4),n.sigBytes-=16),g.create({ciphertext:n,salt:e})}},y=n.SerializableCipher=i.extend({cfg:i.extend({format:m}),encrypt:function(t,e,n,r){r=this.cfg.extend(r);var i=t.createEncryptor(n,r),s=i.finalize(e),o=i.cfg;return g.create({ciphertext:s,key:n,iv:o.iv,algorithm:t,mode:o.mode,padding:o.padding,blockSize:t.blockSize,formatter:r.format})},decrypt:function(t,e,n,r){return r=this.cfg.extend(r),e=this._parse(e,r.format),t.createDecryptor(n,r).finalize(e.ciphertext)},_parse:function(t,e){return"string"==typeof t?e.parse(t,this):t}}),v=(e.kdf={}).OpenSSL={execute:function(t,e,n,r){r||(r=s.random(8));var i=u.create({keySize:e+n}).compute(t,r),o=s.create(i.words.slice(e),4*n);return i.sigBytes=4*e,g.create({key:i,iv:o,salt:r})}},_=n.PasswordBasedCipher=y.extend({cfg:y.cfg.extend({kdf:v}),encrypt:function(t,e,n,r){var i=(r=this.cfg.extend(r)).kdf.execute(n,t.keySize,t.ivSize);r.iv=i.iv;var s=y.encrypt.call(this,t,e,i.key,r);return s.mixIn(i),s},decrypt:function(t,e,n,r){r=this.cfg.extend(r),e=this._parse(e,r.format);var i=r.kdf.execute(n,t.keySize,t.ivSize,e.salt);return r.iv=i.iv,y.decrypt.call(this,t,e,i.key,r)}})}()))},8249:function(t,e,n){var r;t.exports=(r=r||function(t,e){var r;if("undefined"!=typeof window&&window.crypto&&(r=window.crypto),"undefined"!=typeof self&&self.crypto&&(r=self.crypto),"undefined"!=typeof globalThis&&globalThis.crypto&&(r=globalThis.crypto),!r&&"undefined"!=typeof window&&window.msCrypto&&(r=window.msCrypto),!r&&void 0!==n.g&&n.g.crypto&&(r=n.g.crypto),!r)try{r=n(2480)}catch(m){}var i=function(){if(r){if("function"==typeof r.getRandomValues)try{return r.getRandomValues(new Uint32Array(1))[0]}catch(m){}if("function"==typeof r.randomBytes)try{return r.randomBytes(4).readInt32LE()}catch(m){}}throw new Error("Native crypto module could not be used to get secure random number.")},s=Object.create||function(){function t(){}return function(e){var n;return t.prototype=e,n=new t,t.prototype=null,n}}(),o={},a=o.lib={},c=a.Base=function(){return{extend:function(t){var e=s(this);return t&&e.mixIn(t),e.hasOwnProperty("init")&&this.init!==e.init||(e.init=function(){e.$super.init.apply(this,arguments)}),e.init.prototype=e,e.$super=this,e},create:function(){var t=this.extend();return t.init.apply(t,arguments),t},init:function(){},mixIn:function(t){for(var e in t)t.hasOwnProperty(e)&&(this[e]=t[e]);t.hasOwnProperty("toString")&&(this.toString=t.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),u=a.WordArray=c.extend({init:function(t,n){t=this.words=t||[],this.sigBytes=n!=e?n:4*t.length},toString:function(t){return(t||h).stringify(this)},concat:function(t){var e=this.words,n=t.words,r=this.sigBytes,i=t.sigBytes;if(this.clamp(),r%4)for(var s=0;s<i;s++){var o=n[s>>>2]>>>24-s%4*8&255;e[r+s>>>2]|=o<<24-(r+s)%4*8}else for(var a=0;a<i;a+=4)e[r+a>>>2]=n[a>>>2];return this.sigBytes+=i,this},clamp:function(){var e=this.words,n=this.sigBytes;e[n>>>2]&=4294967295<<32-n%4*8,e.length=t.ceil(n/4)},clone:function(){var t=c.clone.call(this);return t.words=this.words.slice(0),t},random:function(t){for(var e=[],n=0;n<t;n+=4)e.push(i());return new u.init(e,t)}}),l=o.enc={},h=l.Hex={stringify:function(t){for(var e=t.words,n=t.sigBytes,r=[],i=0;i<n;i++){var s=e[i>>>2]>>>24-i%4*8&255;r.push((s>>>4).toString(16)),r.push((15&s).toString(16))}return r.join("")},parse:function(t){for(var e=t.length,n=[],r=0;r<e;r+=2)n[r>>>3]|=parseInt(t.substr(r,2),16)<<24-r%8*4;return new u.init(n,e/2)}},f=l.Latin1={stringify:function(t){for(var e=t.words,n=t.sigBytes,r=[],i=0;i<n;i++){var s=e[i>>>2]>>>24-i%4*8&255;r.push(String.fromCharCode(s))}return r.join("")},parse:function(t){for(var e=t.length,n=[],r=0;r<e;r++)n[r>>>2]|=(255&t.charCodeAt(r))<<24-r%4*8;return new u.init(n,e)}},d=l.Utf8={stringify:function(t){try{return decodeURIComponent(escape(f.stringify(t)))}catch(e){throw new Error("Malformed UTF-8 data")}},parse:function(t){return f.parse(unescape(encodeURIComponent(t)))}},p=a.BufferedBlockAlgorithm=c.extend({reset:function(){this._data=new u.init,this._nDataBytes=0},_append:function(t){"string"==typeof t&&(t=d.parse(t)),this._data.concat(t),this._nDataBytes+=t.sigBytes},_process:function(e){var n,r=this._data,i=r.words,s=r.sigBytes,o=this.blockSize,a=s/(4*o),c=(a=e?t.ceil(a):t.max((0|a)-this._minBufferSize,0))*o,l=t.min(4*c,s);if(c){for(var h=0;h<c;h+=o)this._doProcessBlock(i,h);n=i.splice(0,c),r.sigBytes-=l}return new u.init(n,l)},clone:function(){var t=c.clone.call(this);return t._data=this._data.clone(),t},_minBufferSize:0});a.Hasher=p.extend({cfg:c.extend(),init:function(t){this.cfg=this.cfg.extend(t),this.reset()},reset:function(){p.reset.call(this),this._doReset()},update:function(t){return this._append(t),this._process(),this},finalize:function(t){return t&&this._append(t),this._doFinalize()},blockSize:16,_createHelper:function(t){return function(e,n){return new t.init(n).finalize(e)}},_createHmacHelper:function(t){return function(e,n){return new g.HMAC.init(t,n).finalize(e)}}});var g=o.algo={};return o}(Math),r)},8269:function(t,e,n){var r;t.exports=(r=n(8249),function(){var t=r,e=t.lib.WordArray;function n(t,n,r){for(var i=[],s=0,o=0;o<n;o++)if(o%4){var a=r[t.charCodeAt(o-1)]<<o%4*2|r[t.charCodeAt(o)]>>>6-o%4*2;i[s>>>2]|=a<<24-s%4*8,s++}return e.create(i,s)}t.enc.Base64={stringify:function(t){var e=t.words,n=t.sigBytes,r=this._map;t.clamp();for(var i=[],s=0;s<n;s+=3)for(var o=(e[s>>>2]>>>24-s%4*8&255)<<16|(e[s+1>>>2]>>>24-(s+1)%4*8&255)<<8|e[s+2>>>2]>>>24-(s+2)%4*8&255,a=0;a<4&&s+.75*a<n;a++)i.push(r.charAt(o>>>6*(3-a)&63));var c=r.charAt(64);if(c)for(;i.length%4;)i.push(c);return i.join("")},parse:function(t){var e=t.length,r=this._map,i=this._reverseMap;if(!i){i=this._reverseMap=[];for(var s=0;s<r.length;s++)i[r.charCodeAt(s)]=s}var o=r.charAt(64);if(o){var a=t.indexOf(o);-1!==a&&(e=a)}return n(t,e,i)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="}}(),r.enc.Base64)},3786:function(t,e,n){var r;t.exports=(r=n(8249),function(){var t=r,e=t.lib.WordArray;function n(t,n,r){for(var i=[],s=0,o=0;o<n;o++)if(o%4){var a=r[t.charCodeAt(o-1)]<<o%4*2|r[t.charCodeAt(o)]>>>6-o%4*2;i[s>>>2]|=a<<24-s%4*8,s++}return e.create(i,s)}t.enc.Base64url={stringify:function(t,e=!0){var n=t.words,r=t.sigBytes,i=e?this._safe_map:this._map;t.clamp();for(var s=[],o=0;o<r;o+=3)for(var a=(n[o>>>2]>>>24-o%4*8&255)<<16|(n[o+1>>>2]>>>24-(o+1)%4*8&255)<<8|n[o+2>>>2]>>>24-(o+2)%4*8&255,c=0;c<4&&o+.75*c<r;c++)s.push(i.charAt(a>>>6*(3-c)&63));var u=i.charAt(64);if(u)for(;s.length%4;)s.push(u);return s.join("")},parse:function(t,e=!0){var r=t.length,i=e?this._safe_map:this._map,s=this._reverseMap;if(!s){s=this._reverseMap=[];for(var o=0;o<i.length;o++)s[i.charCodeAt(o)]=o}var a=i.charAt(64);if(a){var c=t.indexOf(a);-1!==c&&(r=c)}return n(t,r,s)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_safe_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"}}(),r.enc.Base64url)},298:function(t,e,n){var r;t.exports=(r=n(8249),function(){var t=r,e=t.lib.WordArray,n=t.enc;function i(t){return t<<8&4278255360|t>>>8&16711935}n.Utf16=n.Utf16BE={stringify:function(t){for(var e=t.words,n=t.sigBytes,r=[],i=0;i<n;i+=2){var s=e[i>>>2]>>>16-i%4*8&65535;r.push(String.fromCharCode(s))}return r.join("")},parse:function(t){for(var n=t.length,r=[],i=0;i<n;i++)r[i>>>1]|=t.charCodeAt(i)<<16-i%2*16;return e.create(r,2*n)}},n.Utf16LE={stringify:function(t){for(var e=t.words,n=t.sigBytes,r=[],s=0;s<n;s+=2){var o=i(e[s>>>2]>>>16-s%4*8&65535);r.push(String.fromCharCode(o))}return r.join("")},parse:function(t){for(var n=t.length,r=[],s=0;s<n;s++)r[s>>>1]|=i(t.charCodeAt(s)<<16-s%2*16);return e.create(r,2*n)}}}(),r.enc.Utf16)},888:function(t,e,n){var r,i,s,o,a,c,u,l;t.exports=(l=n(8249),n(2783),n(9824),i=(r=l).lib,s=i.Base,o=i.WordArray,a=r.algo,c=a.MD5,u=a.EvpKDF=s.extend({cfg:s.extend({keySize:4,hasher:c,iterations:1}),init:function(t){this.cfg=this.cfg.extend(t)},compute:function(t,e){for(var n,r=this.cfg,i=r.hasher.create(),s=o.create(),a=s.words,c=r.keySize,u=r.iterations;a.length<c;){n&&i.update(n),n=i.update(t).finalize(e),i.reset();for(var l=1;l<u;l++)n=i.finalize(n),i.reset();s.concat(n)}return s.sigBytes=4*c,s}}),r.EvpKDF=function(t,e,n){return u.create(n).compute(t,e)},l.EvpKDF)},2209:function(t,e,n){var r,i,s,o;t.exports=(o=n(8249),n(5109),i=(r=o).lib.CipherParams,s=r.enc.Hex,r.format.Hex={stringify:function(t){return t.ciphertext.toString(s)},parse:function(t){var e=s.parse(t);return i.create({ciphertext:e})}},o.format.Hex)},9824:function(t,e,n){var r,i,s,o;t.exports=(o=n(8249),i=(r=o).lib.Base,s=r.enc.Utf8,void(r.algo.HMAC=i.extend({init:function(t,e){t=this._hasher=new t.init,"string"==typeof e&&(e=s.parse(e));var n=t.blockSize,r=4*n;e.sigBytes>r&&(e=t.finalize(e)),e.clamp();for(var i=this._oKey=e.clone(),o=this._iKey=e.clone(),a=i.words,c=o.words,u=0;u<n;u++)a[u]^=1549556828,c[u]^=909522486;i.sigBytes=o.sigBytes=r,this.reset()},reset:function(){var t=this._hasher;t.reset(),t.update(this._iKey)},update:function(t){return this._hasher.update(t),this},finalize:function(t){var e=this._hasher,n=e.finalize(t);return e.reset(),e.finalize(this._oKey.clone().concat(n))}})))},1354:function(t,e,n){var r;t.exports=(r=n(8249),n(4938),n(4433),n(298),n(8269),n(3786),n(8214),n(2783),n(2153),n(7792),n(34),n(7460),n(3327),n(706),n(9824),n(2112),n(888),n(5109),n(8568),n(4242),n(9968),n(7660),n(1148),n(3615),n(2807),n(1077),n(6475),n(6991),n(2209),n(452),n(4253),n(1857),n(4454),n(3974),r)},4433:function(t,e,n){var r;t.exports=(r=n(8249),function(){if("function"==typeof ArrayBuffer){var t=r.lib.WordArray,e=t.init,n=t.init=function(t){if(t instanceof ArrayBuffer&&(t=new Uint8Array(t)),(t instanceof Int8Array||"undefined"!=typeof Uint8ClampedArray&&t instanceof Uint8ClampedArray||t instanceof Int16Array||t instanceof Uint16Array||t instanceof Int32Array||t instanceof Uint32Array||t instanceof Float32Array||t instanceof Float64Array)&&(t=new Uint8Array(t.buffer,t.byteOffset,t.byteLength)),t instanceof Uint8Array){for(var n=t.byteLength,r=[],i=0;i<n;i++)r[i>>>2]|=t[i]<<24-i%4*8;e.call(this,r,n)}else e.apply(this,arguments)};n.prototype=t}}(),r.lib.WordArray)},8214:function(t,e,n){var r;t.exports=(r=n(8249),function(t){var e=r,n=e.lib,i=n.WordArray,s=n.Hasher,o=e.algo,a=[];!function(){for(var e=0;e<64;e++)a[e]=4294967296*t.abs(t.sin(e+1))|0}();var c=o.MD5=s.extend({_doReset:function(){this._hash=new i.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(t,e){for(var n=0;n<16;n++){var r=e+n,i=t[r];t[r]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var s=this._hash.words,o=t[e+0],c=t[e+1],d=t[e+2],p=t[e+3],g=t[e+4],m=t[e+5],y=t[e+6],v=t[e+7],_=t[e+8],w=t[e+9],S=t[e+10],b=t[e+11],E=t[e+12],T=t[e+13],x=t[e+14],I=t[e+15],D=s[0],A=s[1],k=s[2],O=s[3];D=u(D,A,k,O,o,7,a[0]),O=u(O,D,A,k,c,12,a[1]),k=u(k,O,D,A,d,17,a[2]),A=u(A,k,O,D,p,22,a[3]),D=u(D,A,k,O,g,7,a[4]),O=u(O,D,A,k,m,12,a[5]),k=u(k,O,D,A,y,17,a[6]),A=u(A,k,O,D,v,22,a[7]),D=u(D,A,k,O,_,7,a[8]),O=u(O,D,A,k,w,12,a[9]),k=u(k,O,D,A,S,17,a[10]),A=u(A,k,O,D,b,22,a[11]),D=u(D,A,k,O,E,7,a[12]),O=u(O,D,A,k,T,12,a[13]),k=u(k,O,D,A,x,17,a[14]),D=l(D,A=u(A,k,O,D,I,22,a[15]),k,O,c,5,a[16]),O=l(O,D,A,k,y,9,a[17]),k=l(k,O,D,A,b,14,a[18]),A=l(A,k,O,D,o,20,a[19]),D=l(D,A,k,O,m,5,a[20]),O=l(O,D,A,k,S,9,a[21]),k=l(k,O,D,A,I,14,a[22]),A=l(A,k,O,D,g,20,a[23]),D=l(D,A,k,O,w,5,a[24]),O=l(O,D,A,k,x,9,a[25]),k=l(k,O,D,A,p,14,a[26]),A=l(A,k,O,D,_,20,a[27]),D=l(D,A,k,O,T,5,a[28]),O=l(O,D,A,k,d,9,a[29]),k=l(k,O,D,A,v,14,a[30]),D=h(D,A=l(A,k,O,D,E,20,a[31]),k,O,m,4,a[32]),O=h(O,D,A,k,_,11,a[33]),k=h(k,O,D,A,b,16,a[34]),A=h(A,k,O,D,x,23,a[35]),D=h(D,A,k,O,c,4,a[36]),O=h(O,D,A,k,g,11,a[37]),k=h(k,O,D,A,v,16,a[38]),A=h(A,k,O,D,S,23,a[39]),D=h(D,A,k,O,T,4,a[40]),O=h(O,D,A,k,o,11,a[41]),k=h(k,O,D,A,p,16,a[42]),A=h(A,k,O,D,y,23,a[43]),D=h(D,A,k,O,w,4,a[44]),O=h(O,D,A,k,E,11,a[45]),k=h(k,O,D,A,I,16,a[46]),D=f(D,A=h(A,k,O,D,d,23,a[47]),k,O,o,6,a[48]),O=f(O,D,A,k,v,10,a[49]),k=f(k,O,D,A,x,15,a[50]),A=f(A,k,O,D,m,21,a[51]),D=f(D,A,k,O,E,6,a[52]),O=f(O,D,A,k,p,10,a[53]),k=f(k,O,D,A,S,15,a[54]),A=f(A,k,O,D,c,21,a[55]),D=f(D,A,k,O,_,6,a[56]),O=f(O,D,A,k,I,10,a[57]),k=f(k,O,D,A,y,15,a[58]),A=f(A,k,O,D,T,21,a[59]),D=f(D,A,k,O,g,6,a[60]),O=f(O,D,A,k,b,10,a[61]),k=f(k,O,D,A,d,15,a[62]),A=f(A,k,O,D,w,21,a[63]),s[0]=s[0]+D|0,s[1]=s[1]+A|0,s[2]=s[2]+k|0,s[3]=s[3]+O|0},_doFinalize:function(){var e=this._data,n=e.words,r=8*this._nDataBytes,i=8*e.sigBytes;n[i>>>5]|=128<<24-i%32;var s=t.floor(r/4294967296),o=r;n[15+(i+64>>>9<<4)]=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8),n[14+(i+64>>>9<<4)]=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),e.sigBytes=4*(n.length+1),this._process();for(var a=this._hash,c=a.words,u=0;u<4;u++){var l=c[u];c[u]=16711935&(l<<8|l>>>24)|4278255360&(l<<24|l>>>8)}return a},clone:function(){var t=s.clone.call(this);return t._hash=this._hash.clone(),t}});function u(t,e,n,r,i,s,o){var a=t+(e&n|~e&r)+i+o;return(a<<s|a>>>32-s)+e}function l(t,e,n,r,i,s,o){var a=t+(e&r|n&~r)+i+o;return(a<<s|a>>>32-s)+e}function h(t,e,n,r,i,s,o){var a=t+(e^n^r)+i+o;return(a<<s|a>>>32-s)+e}function f(t,e,n,r,i,s,o){var a=t+(n^(e|~r))+i+o;return(a<<s|a>>>32-s)+e}e.MD5=s._createHelper(c),e.HmacMD5=s._createHmacHelper(c)}(Math),r.MD5)},8568:function(t,e,n){var r;t.exports=(r=n(8249),n(5109),r.mode.CFB=function(){var t=r.lib.BlockCipherMode.extend();function e(t,e,n,r){var i,s=this._iv;s?(i=s.slice(0),this._iv=void 0):i=this._prevBlock,r.encryptBlock(i,0);for(var o=0;o<n;o++)t[e+o]^=i[o]}return t.Encryptor=t.extend({processBlock:function(t,n){var r=this._cipher,i=r.blockSize;e.call(this,t,n,i,r),this._prevBlock=t.slice(n,n+i)}}),t.Decryptor=t.extend({processBlock:function(t,n){var r=this._cipher,i=r.blockSize,s=t.slice(n,n+i);e.call(this,t,n,i,r),this._prevBlock=s}}),t}(),r.mode.CFB)},9968:function(t,e,n){var r;t.exports=(r=n(8249),n(5109),r.mode.CTRGladman=function(){var t=r.lib.BlockCipherMode.extend();function e(t){if(255==(t>>24&255)){var e=t>>16&255,n=t>>8&255,r=255&t;255===e?(e=0,255===n?(n=0,255===r?r=0:++r):++n):++e,t=0,t+=e<<16,t+=n<<8,t+=r}else t+=1<<24;return t}function n(t){return 0===(t[0]=e(t[0]))&&(t[1]=e(t[1])),t}var i=t.Encryptor=t.extend({processBlock:function(t,e){var r=this._cipher,i=r.blockSize,s=this._iv,o=this._counter;s&&(o=this._counter=s.slice(0),this._iv=void 0),n(o);var a=o.slice(0);r.encryptBlock(a,0);for(var c=0;c<i;c++)t[e+c]^=a[c]}});return t.Decryptor=i,t}(),r.mode.CTRGladman)},4242:function(t,e,n){var r,i,s;t.exports=(s=n(8249),n(5109),s.mode.CTR=(r=s.lib.BlockCipherMode.extend(),i=r.Encryptor=r.extend({processBlock:function(t,e){var n=this._cipher,r=n.blockSize,i=this._iv,s=this._counter;i&&(s=this._counter=i.slice(0),this._iv=void 0);var o=s.slice(0);n.encryptBlock(o,0),s[r-1]=s[r-1]+1|0;for(var a=0;a<r;a++)t[e+a]^=o[a]}}),r.Decryptor=i,r),s.mode.CTR)},1148:function(t,e,n){var r,i;t.exports=(i=n(8249),n(5109),i.mode.ECB=((r=i.lib.BlockCipherMode.extend()).Encryptor=r.extend({processBlock:function(t,e){this._cipher.encryptBlock(t,e)}}),r.Decryptor=r.extend({processBlock:function(t,e){this._cipher.decryptBlock(t,e)}}),r),i.mode.ECB)},7660:function(t,e,n){var r,i,s;t.exports=(s=n(8249),n(5109),s.mode.OFB=(r=s.lib.BlockCipherMode.extend(),i=r.Encryptor=r.extend({processBlock:function(t,e){var n=this._cipher,r=n.blockSize,i=this._iv,s=this._keystream;i&&(s=this._keystream=i.slice(0),this._iv=void 0),n.encryptBlock(s,0);for(var o=0;o<r;o++)t[e+o]^=s[o]}}),r.Decryptor=i,r),s.mode.OFB)},3615:function(t,e,n){var r;t.exports=(r=n(8249),n(5109),r.pad.AnsiX923={pad:function(t,e){var n=t.sigBytes,r=4*e,i=r-n%r,s=n+i-1;t.clamp(),t.words[s>>>2]|=i<<24-s%4*8,t.sigBytes+=i},unpad:function(t){var e=255&t.words[t.sigBytes-1>>>2];t.sigBytes-=e}},r.pad.Ansix923)},2807:function(t,e,n){var r;t.exports=(r=n(8249),n(5109),r.pad.Iso10126={pad:function(t,e){var n=4*e,i=n-t.sigBytes%n;t.concat(r.lib.WordArray.random(i-1)).concat(r.lib.WordArray.create([i<<24],1))},unpad:function(t){var e=255&t.words[t.sigBytes-1>>>2];t.sigBytes-=e}},r.pad.Iso10126)},1077:function(t,e,n){var r;t.exports=(r=n(8249),n(5109),r.pad.Iso97971={pad:function(t,e){t.concat(r.lib.WordArray.create([2147483648],1)),r.pad.ZeroPadding.pad(t,e)},unpad:function(t){r.pad.ZeroPadding.unpad(t),t.sigBytes--}},r.pad.Iso97971)},6991:function(t,e,n){var r;t.exports=(r=n(8249),n(5109),r.pad.NoPadding={pad:function(){},unpad:function(){}},r.pad.NoPadding)},6475:function(t,e,n){var r;t.exports=(r=n(8249),n(5109),r.pad.ZeroPadding={pad:function(t,e){var n=4*e;t.clamp(),t.sigBytes+=n-(t.sigBytes%n||n)},unpad:function(t){var e=t.words,n=t.sigBytes-1;for(n=t.sigBytes-1;n>=0;n--)if(e[n>>>2]>>>24-n%4*8&255){t.sigBytes=n+1;break}}},r.pad.ZeroPadding)},2112:function(t,e,n){var r,i,s,o,a,c,u,l,h;t.exports=(h=n(8249),n(2783),n(9824),i=(r=h).lib,s=i.Base,o=i.WordArray,a=r.algo,c=a.SHA1,u=a.HMAC,l=a.PBKDF2=s.extend({cfg:s.extend({keySize:4,hasher:c,iterations:1}),init:function(t){this.cfg=this.cfg.extend(t)},compute:function(t,e){for(var n=this.cfg,r=u.create(n.hasher,t),i=o.create(),s=o.create([1]),a=i.words,c=s.words,l=n.keySize,h=n.iterations;a.length<l;){var f=r.update(e).finalize(s);r.reset();for(var d=f.words,p=d.length,g=f,m=1;m<h;m++){g=r.finalize(g),r.reset();for(var y=g.words,v=0;v<p;v++)d[v]^=y[v]}i.concat(f),c[0]++}return i.sigBytes=4*l,i}}),r.PBKDF2=function(t,e,n){return l.create(n).compute(t,e)},h.PBKDF2)},3974:function(t,e,n){var r;t.exports=(r=n(8249),n(8269),n(8214),n(888),n(5109),function(){var t=r,e=t.lib.StreamCipher,n=t.algo,i=[],s=[],o=[],a=n.RabbitLegacy=e.extend({_doReset:function(){var t=this._key.words,e=this.cfg.iv,n=this._X=[t[0],t[3]<<16|t[2]>>>16,t[1],t[0]<<16|t[3]>>>16,t[2],t[1]<<16|t[0]>>>16,t[3],t[2]<<16|t[1]>>>16],r=this._C=[t[2]<<16|t[2]>>>16,4294901760&t[0]|65535&t[1],t[3]<<16|t[3]>>>16,4294901760&t[1]|65535&t[2],t[0]<<16|t[0]>>>16,4294901760&t[2]|65535&t[3],t[1]<<16|t[1]>>>16,4294901760&t[3]|65535&t[0]];this._b=0;for(var i=0;i<4;i++)c.call(this);for(i=0;i<8;i++)r[i]^=n[i+4&7];if(e){var s=e.words,o=s[0],a=s[1],u=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),l=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),h=u>>>16|4294901760&l,f=l<<16|65535&u;for(r[0]^=u,r[1]^=h,r[2]^=l,r[3]^=f,r[4]^=u,r[5]^=h,r[6]^=l,r[7]^=f,i=0;i<4;i++)c.call(this)}},_doProcessBlock:function(t,e){var n=this._X;c.call(this),i[0]=n[0]^n[5]>>>16^n[3]<<16,i[1]=n[2]^n[7]>>>16^n[5]<<16,i[2]=n[4]^n[1]>>>16^n[7]<<16,i[3]=n[6]^n[3]>>>16^n[1]<<16;for(var r=0;r<4;r++)i[r]=16711935&(i[r]<<8|i[r]>>>24)|4278255360&(i[r]<<24|i[r]>>>8),t[e+r]^=i[r]},blockSize:4,ivSize:2});function c(){for(var t=this._X,e=this._C,n=0;n<8;n++)s[n]=e[n];for(e[0]=e[0]+1295307597+this._b|0,e[1]=e[1]+3545052371+(e[0]>>>0<s[0]>>>0?1:0)|0,e[2]=e[2]+886263092+(e[1]>>>0<s[1]>>>0?1:0)|0,e[3]=e[3]+1295307597+(e[2]>>>0<s[2]>>>0?1:0)|0,e[4]=e[4]+3545052371+(e[3]>>>0<s[3]>>>0?1:0)|0,e[5]=e[5]+886263092+(e[4]>>>0<s[4]>>>0?1:0)|0,e[6]=e[6]+1295307597+(e[5]>>>0<s[5]>>>0?1:0)|0,e[7]=e[7]+3545052371+(e[6]>>>0<s[6]>>>0?1:0)|0,this._b=e[7]>>>0<s[7]>>>0?1:0,n=0;n<8;n++){var r=t[n]+e[n],i=65535&r,a=r>>>16,c=((i*i>>>17)+i*a>>>15)+a*a,u=((4294901760&r)*r|0)+((65535&r)*r|0);o[n]=c^u}t[0]=o[0]+(o[7]<<16|o[7]>>>16)+(o[6]<<16|o[6]>>>16)|0,t[1]=o[1]+(o[0]<<8|o[0]>>>24)+o[7]|0,t[2]=o[2]+(o[1]<<16|o[1]>>>16)+(o[0]<<16|o[0]>>>16)|0,t[3]=o[3]+(o[2]<<8|o[2]>>>24)+o[1]|0,t[4]=o[4]+(o[3]<<16|o[3]>>>16)+(o[2]<<16|o[2]>>>16)|0,t[5]=o[5]+(o[4]<<8|o[4]>>>24)+o[3]|0,t[6]=o[6]+(o[5]<<16|o[5]>>>16)+(o[4]<<16|o[4]>>>16)|0,t[7]=o[7]+(o[6]<<8|o[6]>>>24)+o[5]|0}t.RabbitLegacy=e._createHelper(a)}(),r.RabbitLegacy)},4454:function(t,e,n){var r;t.exports=(r=n(8249),n(8269),n(8214),n(888),n(5109),function(){var t=r,e=t.lib.StreamCipher,n=t.algo,i=[],s=[],o=[],a=n.Rabbit=e.extend({_doReset:function(){for(var t=this._key.words,e=this.cfg.iv,n=0;n<4;n++)t[n]=16711935&(t[n]<<8|t[n]>>>24)|4278255360&(t[n]<<24|t[n]>>>8);var r=this._X=[t[0],t[3]<<16|t[2]>>>16,t[1],t[0]<<16|t[3]>>>16,t[2],t[1]<<16|t[0]>>>16,t[3],t[2]<<16|t[1]>>>16],i=this._C=[t[2]<<16|t[2]>>>16,4294901760&t[0]|65535&t[1],t[3]<<16|t[3]>>>16,4294901760&t[1]|65535&t[2],t[0]<<16|t[0]>>>16,4294901760&t[2]|65535&t[3],t[1]<<16|t[1]>>>16,4294901760&t[3]|65535&t[0]];for(this._b=0,n=0;n<4;n++)c.call(this);for(n=0;n<8;n++)i[n]^=r[n+4&7];if(e){var s=e.words,o=s[0],a=s[1],u=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),l=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),h=u>>>16|4294901760&l,f=l<<16|65535&u;for(i[0]^=u,i[1]^=h,i[2]^=l,i[3]^=f,i[4]^=u,i[5]^=h,i[6]^=l,i[7]^=f,n=0;n<4;n++)c.call(this)}},_doProcessBlock:function(t,e){var n=this._X;c.call(this),i[0]=n[0]^n[5]>>>16^n[3]<<16,i[1]=n[2]^n[7]>>>16^n[5]<<16,i[2]=n[4]^n[1]>>>16^n[7]<<16,i[3]=n[6]^n[3]>>>16^n[1]<<16;for(var r=0;r<4;r++)i[r]=16711935&(i[r]<<8|i[r]>>>24)|4278255360&(i[r]<<24|i[r]>>>8),t[e+r]^=i[r]},blockSize:4,ivSize:2});function c(){for(var t=this._X,e=this._C,n=0;n<8;n++)s[n]=e[n];for(e[0]=e[0]+1295307597+this._b|0,e[1]=e[1]+3545052371+(e[0]>>>0<s[0]>>>0?1:0)|0,e[2]=e[2]+886263092+(e[1]>>>0<s[1]>>>0?1:0)|0,e[3]=e[3]+1295307597+(e[2]>>>0<s[2]>>>0?1:0)|0,e[4]=e[4]+3545052371+(e[3]>>>0<s[3]>>>0?1:0)|0,e[5]=e[5]+886263092+(e[4]>>>0<s[4]>>>0?1:0)|0,e[6]=e[6]+1295307597+(e[5]>>>0<s[5]>>>0?1:0)|0,e[7]=e[7]+3545052371+(e[6]>>>0<s[6]>>>0?1:0)|0,this._b=e[7]>>>0<s[7]>>>0?1:0,n=0;n<8;n++){var r=t[n]+e[n],i=65535&r,a=r>>>16,c=((i*i>>>17)+i*a>>>15)+a*a,u=((4294901760&r)*r|0)+((65535&r)*r|0);o[n]=c^u}t[0]=o[0]+(o[7]<<16|o[7]>>>16)+(o[6]<<16|o[6]>>>16)|0,t[1]=o[1]+(o[0]<<8|o[0]>>>24)+o[7]|0,t[2]=o[2]+(o[1]<<16|o[1]>>>16)+(o[0]<<16|o[0]>>>16)|0,t[3]=o[3]+(o[2]<<8|o[2]>>>24)+o[1]|0,t[4]=o[4]+(o[3]<<16|o[3]>>>16)+(o[2]<<16|o[2]>>>16)|0,t[5]=o[5]+(o[4]<<8|o[4]>>>24)+o[3]|0,t[6]=o[6]+(o[5]<<16|o[5]>>>16)+(o[4]<<16|o[4]>>>16)|0,t[7]=o[7]+(o[6]<<8|o[6]>>>24)+o[5]|0}t.Rabbit=e._createHelper(a)}(),r.Rabbit)},1857:function(t,e,n){var r;t.exports=(r=n(8249),n(8269),n(8214),n(888),n(5109),function(){var t=r,e=t.lib.StreamCipher,n=t.algo,i=n.RC4=e.extend({_doReset:function(){for(var t=this._key,e=t.words,n=t.sigBytes,r=this._S=[],i=0;i<256;i++)r[i]=i;i=0;for(var s=0;i<256;i++){var o=i%n,a=e[o>>>2]>>>24-o%4*8&255;s=(s+r[i]+a)%256;var c=r[i];r[i]=r[s],r[s]=c}this._i=this._j=0},_doProcessBlock:function(t,e){t[e]^=s.call(this)},keySize:8,ivSize:0});function s(){for(var t=this._S,e=this._i,n=this._j,r=0,i=0;i<4;i++){n=(n+t[e=(e+1)%256])%256;var s=t[e];t[e]=t[n],t[n]=s,r|=t[(t[e]+t[n])%256]<<24-8*i}return this._i=e,this._j=n,r}t.RC4=e._createHelper(i);var o=n.RC4Drop=i.extend({cfg:i.cfg.extend({drop:192}),_doReset:function(){i._doReset.call(this);for(var t=this.cfg.drop;t>0;t--)s.call(this)}});t.RC4Drop=e._createHelper(o)}(),r.RC4)},706:function(t,e,n){var r;t.exports=(r=n(8249),function(t){var e=r,n=e.lib,i=n.WordArray,s=n.Hasher,o=e.algo,a=i.create([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13]),c=i.create([5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11]),u=i.create([11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6]),l=i.create([8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]),h=i.create([0,1518500249,1859775393,2400959708,2840853838]),f=i.create([1352829926,1548603684,1836072691,2053994217,0]),d=o.RIPEMD160=s.extend({_doReset:function(){this._hash=i.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(t,e){for(var n=0;n<16;n++){var r=e+n,i=t[r];t[r]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var s,o,d,w,S,b,E,T,x,I,D,A=this._hash.words,k=h.words,O=f.words,R=a.words,P=c.words,M=u.words,C=l.words;for(b=s=A[0],E=o=A[1],T=d=A[2],x=w=A[3],I=S=A[4],n=0;n<80;n+=1)D=s+t[e+R[n]]|0,D+=n<16?p(o,d,w)+k[0]:n<32?g(o,d,w)+k[1]:n<48?m(o,d,w)+k[2]:n<64?y(o,d,w)+k[3]:v(o,d,w)+k[4],D=(D=_(D|=0,M[n]))+S|0,s=S,S=w,w=_(d,10),d=o,o=D,D=b+t[e+P[n]]|0,D+=n<16?v(E,T,x)+O[0]:n<32?y(E,T,x)+O[1]:n<48?m(E,T,x)+O[2]:n<64?g(E,T,x)+O[3]:p(E,T,x)+O[4],D=(D=_(D|=0,C[n]))+I|0,b=I,I=x,x=_(T,10),T=E,E=D;D=A[1]+d+x|0,A[1]=A[2]+w+I|0,A[2]=A[3]+S+b|0,A[3]=A[4]+s+E|0,A[4]=A[0]+o+T|0,A[0]=D},_doFinalize:function(){var t=this._data,e=t.words,n=8*this._nDataBytes,r=8*t.sigBytes;e[r>>>5]|=128<<24-r%32,e[14+(r+64>>>9<<4)]=16711935&(n<<8|n>>>24)|4278255360&(n<<24|n>>>8),t.sigBytes=4*(e.length+1),this._process();for(var i=this._hash,s=i.words,o=0;o<5;o++){var a=s[o];s[o]=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8)}return i},clone:function(){var t=s.clone.call(this);return t._hash=this._hash.clone(),t}});function p(t,e,n){return t^e^n}function g(t,e,n){return t&e|~t&n}function m(t,e,n){return(t|~e)^n}function y(t,e,n){return t&n|e&~n}function v(t,e,n){return t^(e|~n)}function _(t,e){return t<<e|t>>>32-e}e.RIPEMD160=s._createHelper(d),e.HmacRIPEMD160=s._createHmacHelper(d)}(),r.RIPEMD160)},2783:function(t,e,n){var r,i,s,o,a,c,u,l;t.exports=(l=n(8249),i=(r=l).lib,s=i.WordArray,o=i.Hasher,a=r.algo,c=[],u=a.SHA1=o.extend({_doReset:function(){this._hash=new s.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(t,e){for(var n=this._hash.words,r=n[0],i=n[1],s=n[2],o=n[3],a=n[4],u=0;u<80;u++){if(u<16)c[u]=0|t[e+u];else{var l=c[u-3]^c[u-8]^c[u-14]^c[u-16];c[u]=l<<1|l>>>31}var h=(r<<5|r>>>27)+a+c[u];h+=u<20?1518500249+(i&s|~i&o):u<40?1859775393+(i^s^o):u<60?(i&s|i&o|s&o)-1894007588:(i^s^o)-899497514,a=o,o=s,s=i<<30|i>>>2,i=r,r=h}n[0]=n[0]+r|0,n[1]=n[1]+i|0,n[2]=n[2]+s|0,n[3]=n[3]+o|0,n[4]=n[4]+a|0},_doFinalize:function(){var t=this._data,e=t.words,n=8*this._nDataBytes,r=8*t.sigBytes;return e[r>>>5]|=128<<24-r%32,e[14+(r+64>>>9<<4)]=Math.floor(n/4294967296),e[15+(r+64>>>9<<4)]=n,t.sigBytes=4*e.length,this._process(),this._hash},clone:function(){var t=o.clone.call(this);return t._hash=this._hash.clone(),t}}),r.SHA1=o._createHelper(u),r.HmacSHA1=o._createHmacHelper(u),l.SHA1)},7792:function(t,e,n){var r,i,s,o,a,c;t.exports=(c=n(8249),n(2153),i=(r=c).lib.WordArray,s=r.algo,o=s.SHA256,a=s.SHA224=o.extend({_doReset:function(){this._hash=new i.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var t=o._doFinalize.call(this);return t.sigBytes-=4,t}}),r.SHA224=o._createHelper(a),r.HmacSHA224=o._createHmacHelper(a),c.SHA224)},2153:function(t,e,n){var r;t.exports=(r=n(8249),function(t){var e=r,n=e.lib,i=n.WordArray,s=n.Hasher,o=e.algo,a=[],c=[];!function(){function e(e){for(var n=t.sqrt(e),r=2;r<=n;r++)if(!(e%r))return!1;return!0}function n(t){return 4294967296*(t-(0|t))|0}for(var r=2,i=0;i<64;)e(r)&&(i<8&&(a[i]=n(t.pow(r,.5))),c[i]=n(t.pow(r,1/3)),i++),r++}();var u=[],l=o.SHA256=s.extend({_doReset:function(){this._hash=new i.init(a.slice(0))},_doProcessBlock:function(t,e){for(var n=this._hash.words,r=n[0],i=n[1],s=n[2],o=n[3],a=n[4],l=n[5],h=n[6],f=n[7],d=0;d<64;d++){if(d<16)u[d]=0|t[e+d];else{var p=u[d-15],g=(p<<25|p>>>7)^(p<<14|p>>>18)^p>>>3,m=u[d-2],y=(m<<15|m>>>17)^(m<<13|m>>>19)^m>>>10;u[d]=g+u[d-7]+y+u[d-16]}var v=r&i^r&s^i&s,_=(r<<30|r>>>2)^(r<<19|r>>>13)^(r<<10|r>>>22),w=f+((a<<26|a>>>6)^(a<<21|a>>>11)^(a<<7|a>>>25))+(a&l^~a&h)+c[d]+u[d];f=h,h=l,l=a,a=o+w|0,o=s,s=i,i=r,r=w+(_+v)|0}n[0]=n[0]+r|0,n[1]=n[1]+i|0,n[2]=n[2]+s|0,n[3]=n[3]+o|0,n[4]=n[4]+a|0,n[5]=n[5]+l|0,n[6]=n[6]+h|0,n[7]=n[7]+f|0},_doFinalize:function(){var e=this._data,n=e.words,r=8*this._nDataBytes,i=8*e.sigBytes;return n[i>>>5]|=128<<24-i%32,n[14+(i+64>>>9<<4)]=t.floor(r/4294967296),n[15+(i+64>>>9<<4)]=r,e.sigBytes=4*n.length,this._process(),this._hash},clone:function(){var t=s.clone.call(this);return t._hash=this._hash.clone(),t}});e.SHA256=s._createHelper(l),e.HmacSHA256=s._createHmacHelper(l)}(Math),r.SHA256)},3327:function(t,e,n){var r;t.exports=(r=n(8249),n(4938),function(t){var e=r,n=e.lib,i=n.WordArray,s=n.Hasher,o=e.x64.Word,a=e.algo,c=[],u=[],l=[];!function(){for(var t=1,e=0,n=0;n<24;n++){c[t+5*e]=(n+1)*(n+2)/2%64;var r=(2*t+3*e)%5;t=e%5,e=r}for(t=0;t<5;t++)for(e=0;e<5;e++)u[t+5*e]=e+(2*t+3*e)%5*5;for(var i=1,s=0;s<24;s++){for(var a=0,h=0,f=0;f<7;f++){if(1&i){var d=(1<<f)-1;d<32?h^=1<<d:a^=1<<d-32}128&i?i=i<<1^113:i<<=1}l[s]=o.create(a,h)}}();var h=[];!function(){for(var t=0;t<25;t++)h[t]=o.create()}();var f=a.SHA3=s.extend({cfg:s.cfg.extend({outputLength:512}),_doReset:function(){for(var t=this._state=[],e=0;e<25;e++)t[e]=new o.init;this.blockSize=(1600-2*this.cfg.outputLength)/32},_doProcessBlock:function(t,e){for(var n=this._state,r=this.blockSize/2,i=0;i<r;i++){var s=t[e+2*i],o=t[e+2*i+1];s=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8),o=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),(A=n[i]).high^=o,A.low^=s}for(var a=0;a<24;a++){for(var f=0;f<5;f++){for(var d=0,p=0,g=0;g<5;g++)d^=(A=n[f+5*g]).high,p^=A.low;var m=h[f];m.high=d,m.low=p}for(f=0;f<5;f++){var y=h[(f+4)%5],v=h[(f+1)%5],_=v.high,w=v.low;for(d=y.high^(_<<1|w>>>31),p=y.low^(w<<1|_>>>31),g=0;g<5;g++)(A=n[f+5*g]).high^=d,A.low^=p}for(var S=1;S<25;S++){var b=(A=n[S]).high,E=A.low,T=c[S];T<32?(d=b<<T|E>>>32-T,p=E<<T|b>>>32-T):(d=E<<T-32|b>>>64-T,p=b<<T-32|E>>>64-T);var x=h[u[S]];x.high=d,x.low=p}var I=h[0],D=n[0];for(I.high=D.high,I.low=D.low,f=0;f<5;f++)for(g=0;g<5;g++){var A=n[S=f+5*g],k=h[S],O=h[(f+1)%5+5*g],R=h[(f+2)%5+5*g];A.high=k.high^~O.high&R.high,A.low=k.low^~O.low&R.low}A=n[0];var P=l[a];A.high^=P.high,A.low^=P.low}},_doFinalize:function(){var e=this._data,n=e.words;this._nDataBytes;var r=8*e.sigBytes,s=32*this.blockSize;n[r>>>5]|=1<<24-r%32,n[(t.ceil((r+1)/s)*s>>>5)-1]|=128,e.sigBytes=4*n.length,this._process();for(var o=this._state,a=this.cfg.outputLength/8,c=a/8,u=[],l=0;l<c;l++){var h=o[l],f=h.high,d=h.low;f=16711935&(f<<8|f>>>24)|4278255360&(f<<24|f>>>8),d=16711935&(d<<8|d>>>24)|4278255360&(d<<24|d>>>8),u.push(d),u.push(f)}return new i.init(u,a)},clone:function(){for(var t=s.clone.call(this),e=t._state=this._state.slice(0),n=0;n<25;n++)e[n]=e[n].clone();return t}});e.SHA3=s._createHelper(f),e.HmacSHA3=s._createHmacHelper(f)}(Math),r.SHA3)},7460:function(t,e,n){var r,i,s,o,a,c,u,l;t.exports=(l=n(8249),n(4938),n(34),i=(r=l).x64,s=i.Word,o=i.WordArray,a=r.algo,c=a.SHA512,u=a.SHA384=c.extend({_doReset:function(){this._hash=new o.init([new s.init(3418070365,3238371032),new s.init(1654270250,914150663),new s.init(2438529370,812702999),new s.init(355462360,4144912697),new s.init(1731405415,4290775857),new s.init(2394180231,1750603025),new s.init(3675008525,1694076839),new s.init(1203062813,3204075428)])},_doFinalize:function(){var t=c._doFinalize.call(this);return t.sigBytes-=16,t}}),r.SHA384=c._createHelper(u),r.HmacSHA384=c._createHmacHelper(u),l.SHA384)},34:function(t,e,n){var r;t.exports=(r=n(8249),n(4938),function(){var t=r,e=t.lib.Hasher,n=t.x64,i=n.Word,s=n.WordArray,o=t.algo;function a(){return i.create.apply(i,arguments)}var c=[a(1116352408,3609767458),a(1899447441,602891725),a(3049323471,3964484399),a(3921009573,2173295548),a(961987163,4081628472),a(1508970993,3053834265),a(2453635748,2937671579),a(2870763221,3664609560),a(3624381080,2734883394),a(310598401,1164996542),a(607225278,1323610764),a(1426881987,3590304994),a(1925078388,4068182383),a(2162078206,991336113),a(2614888103,633803317),a(3248222580,3479774868),a(3835390401,2666613458),a(4022224774,944711139),a(264347078,2341262773),a(604807628,2007800933),a(770255983,1495990901),a(1249150122,1856431235),a(1555081692,3175218132),a(1996064986,2198950837),a(2554220882,3999719339),a(2821834349,766784016),a(2952996808,2566594879),a(3210313671,3203337956),a(3336571891,1034457026),a(3584528711,2466948901),a(113926993,3758326383),a(338241895,168717936),a(666307205,1188179964),a(773529912,1546045734),a(1294757372,1522805485),a(1396182291,2643833823),a(1695183700,2343527390),a(1986661051,1014477480),a(2177026350,1206759142),a(2456956037,344077627),a(2730485921,1290863460),a(2820302411,3158454273),a(3259730800,3505952657),a(3345764771,106217008),a(3516065817,3606008344),a(3600352804,1432725776),a(4094571909,1467031594),a(275423344,851169720),a(430227734,3100823752),a(506948616,1363258195),a(659060556,3750685593),a(883997877,3785050280),a(958139571,3318307427),a(1322822218,3812723403),a(1537002063,2003034995),a(1747873779,3602036899),a(1955562222,1575990012),a(2024104815,1125592928),a(2227730452,2716904306),a(2361852424,442776044),a(2428436474,593698344),a(2756734187,3733110249),a(3204031479,2999351573),a(3329325298,3815920427),a(3391569614,3928383900),a(3515267271,566280711),a(3940187606,3454069534),a(4118630271,4000239992),a(116418474,1914138554),a(174292421,2731055270),a(289380356,3203993006),a(460393269,320620315),a(685471733,587496836),a(852142971,1086792851),a(1017036298,365543100),a(1126000580,2618297676),a(1288033470,3409855158),a(1501505948,4234509866),a(1607167915,987167468),a(1816402316,1246189591)],u=[];!function(){for(var t=0;t<80;t++)u[t]=a()}();var l=o.SHA512=e.extend({_doReset:function(){this._hash=new s.init([new i.init(1779033703,4089235720),new i.init(3144134277,2227873595),new i.init(1013904242,4271175723),new i.init(2773480762,1595750129),new i.init(1359893119,2917565137),new i.init(2600822924,725511199),new i.init(528734635,4215389547),new i.init(1541459225,327033209)])},_doProcessBlock:function(t,e){for(var n=this._hash.words,r=n[0],i=n[1],s=n[2],o=n[3],a=n[4],l=n[5],h=n[6],f=n[7],d=r.high,p=r.low,g=i.high,m=i.low,y=s.high,v=s.low,_=o.high,w=o.low,S=a.high,b=a.low,E=l.high,T=l.low,x=h.high,I=h.low,D=f.high,A=f.low,k=d,O=p,R=g,P=m,M=y,C=v,B=_,N=w,L=S,j=b,V=E,U=T,$=x,H=I,q=D,F=A,K=0;K<80;K++){var z,W,J=u[K];if(K<16)W=J.high=0|t[e+2*K],z=J.low=0|t[e+2*K+1];else{var G=u[K-15],Y=G.high,Z=G.low,X=(Y>>>1|Z<<31)^(Y>>>8|Z<<24)^Y>>>7,Q=(Z>>>1|Y<<31)^(Z>>>8|Y<<24)^(Z>>>7|Y<<25),tt=u[K-2],et=tt.high,nt=tt.low,rt=(et>>>19|nt<<13)^(et<<3|nt>>>29)^et>>>6,it=(nt>>>19|et<<13)^(nt<<3|et>>>29)^(nt>>>6|et<<26),st=u[K-7],ot=st.high,at=st.low,ct=u[K-16],ut=ct.high,lt=ct.low;W=(W=(W=X+ot+((z=Q+at)>>>0<Q>>>0?1:0))+rt+((z+=it)>>>0<it>>>0?1:0))+ut+((z+=lt)>>>0<lt>>>0?1:0),J.high=W,J.low=z}var ht,ft=L&V^~L&$,dt=j&U^~j&H,pt=k&R^k&M^R&M,gt=O&P^O&C^P&C,mt=(k>>>28|O<<4)^(k<<30|O>>>2)^(k<<25|O>>>7),yt=(O>>>28|k<<4)^(O<<30|k>>>2)^(O<<25|k>>>7),vt=(L>>>14|j<<18)^(L>>>18|j<<14)^(L<<23|j>>>9),_t=(j>>>14|L<<18)^(j>>>18|L<<14)^(j<<23|L>>>9),wt=c[K],St=wt.high,bt=wt.low,Et=q+vt+((ht=F+_t)>>>0<F>>>0?1:0),Tt=yt+gt;q=$,F=H,$=V,H=U,V=L,U=j,L=B+(Et=(Et=(Et=Et+ft+((ht+=dt)>>>0<dt>>>0?1:0))+St+((ht+=bt)>>>0<bt>>>0?1:0))+W+((ht+=z)>>>0<z>>>0?1:0))+((j=N+ht|0)>>>0<N>>>0?1:0)|0,B=M,N=C,M=R,C=P,R=k,P=O,k=Et+(mt+pt+(Tt>>>0<yt>>>0?1:0))+((O=ht+Tt|0)>>>0<ht>>>0?1:0)|0}p=r.low=p+O,r.high=d+k+(p>>>0<O>>>0?1:0),m=i.low=m+P,i.high=g+R+(m>>>0<P>>>0?1:0),v=s.low=v+C,s.high=y+M+(v>>>0<C>>>0?1:0),w=o.low=w+N,o.high=_+B+(w>>>0<N>>>0?1:0),b=a.low=b+j,a.high=S+L+(b>>>0<j>>>0?1:0),T=l.low=T+U,l.high=E+V+(T>>>0<U>>>0?1:0),I=h.low=I+H,h.high=x+$+(I>>>0<H>>>0?1:0),A=f.low=A+F,f.high=D+q+(A>>>0<F>>>0?1:0)},_doFinalize:function(){var t=this._data,e=t.words,n=8*this._nDataBytes,r=8*t.sigBytes;return e[r>>>5]|=128<<24-r%32,e[30+(r+128>>>10<<5)]=Math.floor(n/4294967296),e[31+(r+128>>>10<<5)]=n,t.sigBytes=4*e.length,this._process(),this._hash.toX32()},clone:function(){var t=e.clone.call(this);return t._hash=this._hash.clone(),t},blockSize:32});t.SHA512=e._createHelper(l),t.HmacSHA512=e._createHmacHelper(l)}(),r.SHA512)},4253:function(t,e,n){var r;t.exports=(r=n(8249),n(8269),n(8214),n(888),n(5109),function(){var t=r,e=t.lib,n=e.WordArray,i=e.BlockCipher,s=t.algo,o=[57,49,41,33,25,17,9,1,58,50,42,34,26,18,10,2,59,51,43,35,27,19,11,3,60,52,44,36,63,55,47,39,31,23,15,7,62,54,46,38,30,22,14,6,61,53,45,37,29,21,13,5,28,20,12,4],a=[14,17,11,24,1,5,3,28,15,6,21,10,23,19,12,4,26,8,16,7,27,20,13,2,41,52,31,37,47,55,30,40,51,45,33,48,44,49,39,56,34,53,46,42,50,36,29,32],c=[1,2,4,6,8,10,12,14,15,17,19,21,23,25,27,28],u=[{0:8421888,268435456:32768,536870912:8421378,805306368:2,1073741824:512,1342177280:8421890,1610612736:8389122,1879048192:8388608,2147483648:514,2415919104:8389120,2684354560:33280,2952790016:8421376,3221225472:32770,3489660928:8388610,3758096384:0,4026531840:33282,134217728:0,402653184:8421890,671088640:33282,939524096:32768,1207959552:8421888,1476395008:512,1744830464:8421378,2013265920:2,2281701376:8389120,2550136832:33280,2818572288:8421376,3087007744:8389122,3355443200:8388610,3623878656:32770,3892314112:514,4160749568:8388608,1:32768,268435457:2,536870913:8421888,805306369:8388608,1073741825:8421378,1342177281:33280,1610612737:512,1879048193:8389122,2147483649:8421890,2415919105:8421376,2684354561:8388610,2952790017:33282,3221225473:514,3489660929:8389120,3758096385:32770,4026531841:0,134217729:8421890,402653185:8421376,671088641:8388608,939524097:512,1207959553:32768,1476395009:8388610,1744830465:2,2013265921:33282,2281701377:32770,2550136833:8389122,2818572289:514,3087007745:8421888,3355443201:8389120,3623878657:0,3892314113:33280,4160749569:8421378},{0:1074282512,16777216:16384,33554432:524288,50331648:1074266128,67108864:1073741840,83886080:1074282496,100663296:1073758208,117440512:16,134217728:540672,150994944:1073758224,167772160:1073741824,184549376:540688,201326592:524304,218103808:0,234881024:16400,251658240:1074266112,8388608:1073758208,25165824:540688,41943040:16,58720256:1073758224,75497472:1074282512,92274688:1073741824,109051904:524288,125829120:1074266128,142606336:524304,159383552:0,176160768:16384,192937984:1074266112,209715200:1073741840,226492416:540672,243269632:1074282496,260046848:16400,268435456:0,285212672:1074266128,301989888:1073758224,318767104:1074282496,335544320:1074266112,352321536:16,369098752:540688,385875968:16384,402653184:16400,419430400:524288,436207616:524304,452984832:1073741840,469762048:540672,486539264:1073758208,503316480:1073741824,520093696:1074282512,276824064:540688,293601280:524288,310378496:1074266112,327155712:16384,343932928:1073758208,360710144:1074282512,377487360:16,394264576:1073741824,411041792:1074282496,427819008:1073741840,444596224:1073758224,461373440:524304,478150656:0,494927872:16400,511705088:1074266128,528482304:540672},{0:260,1048576:0,2097152:67109120,3145728:65796,4194304:65540,5242880:67108868,6291456:67174660,7340032:67174400,8388608:67108864,9437184:67174656,10485760:65792,11534336:67174404,12582912:67109124,13631488:65536,14680064:4,15728640:256,524288:67174656,1572864:67174404,2621440:0,3670016:67109120,4718592:67108868,5767168:65536,6815744:65540,7864320:260,8912896:4,9961472:256,11010048:67174400,12058624:65796,13107200:65792,14155776:67109124,15204352:67174660,16252928:67108864,16777216:67174656,17825792:65540,18874368:65536,19922944:67109120,20971520:256,22020096:67174660,23068672:67108868,24117248:0,25165824:67109124,26214400:67108864,27262976:4,28311552:65792,29360128:67174400,30408704:260,31457280:65796,32505856:67174404,17301504:67108864,18350080:260,19398656:67174656,20447232:0,21495808:65540,22544384:67109120,23592960:256,24641536:67174404,25690112:65536,26738688:67174660,27787264:65796,28835840:67108868,29884416:67109124,30932992:67174400,31981568:4,33030144:65792},{0:2151682048,65536:2147487808,131072:4198464,196608:2151677952,262144:0,327680:4198400,393216:2147483712,458752:4194368,524288:2147483648,589824:4194304,655360:64,720896:2147487744,786432:2151678016,851968:4160,917504:4096,983040:2151682112,32768:2147487808,98304:64,163840:2151678016,229376:2147487744,294912:4198400,360448:2151682112,425984:0,491520:2151677952,557056:4096,622592:2151682048,688128:4194304,753664:4160,819200:2147483648,884736:4194368,950272:4198464,1015808:2147483712,1048576:4194368,1114112:4198400,1179648:2147483712,1245184:0,1310720:4160,1376256:2151678016,1441792:2151682048,1507328:2147487808,1572864:2151682112,1638400:2147483648,1703936:2151677952,1769472:4198464,1835008:2147487744,1900544:4194304,1966080:64,2031616:4096,1081344:2151677952,1146880:2151682112,1212416:0,1277952:4198400,1343488:4194368,1409024:2147483648,1474560:2147487808,1540096:64,1605632:2147483712,1671168:4096,1736704:2147487744,1802240:2151678016,1867776:4160,1933312:2151682048,1998848:4194304,2064384:4198464},{0:128,4096:17039360,8192:262144,12288:536870912,16384:537133184,20480:16777344,24576:553648256,28672:262272,32768:16777216,36864:537133056,40960:536871040,45056:553910400,49152:553910272,53248:0,57344:17039488,61440:553648128,2048:17039488,6144:553648256,10240:128,14336:17039360,18432:262144,22528:537133184,26624:553910272,30720:536870912,34816:537133056,38912:0,43008:553910400,47104:16777344,51200:536871040,55296:553648128,59392:16777216,63488:262272,65536:262144,69632:128,73728:536870912,77824:553648256,81920:16777344,86016:553910272,90112:537133184,94208:16777216,98304:553910400,102400:553648128,106496:17039360,110592:537133056,114688:262272,118784:536871040,122880:0,126976:17039488,67584:553648256,71680:16777216,75776:17039360,79872:537133184,83968:536870912,88064:17039488,92160:128,96256:553910272,100352:262272,104448:553910400,108544:0,112640:553648128,116736:16777344,120832:262144,124928:537133056,129024:536871040},{0:268435464,256:8192,512:270532608,768:270540808,1024:268443648,1280:2097152,1536:2097160,1792:268435456,2048:0,2304:268443656,2560:2105344,2816:8,3072:270532616,3328:2105352,3584:8200,3840:270540800,128:270532608,384:270540808,640:8,896:2097152,1152:2105352,1408:268435464,1664:268443648,1920:8200,2176:2097160,2432:8192,2688:268443656,2944:270532616,3200:0,3456:270540800,3712:2105344,3968:268435456,4096:268443648,4352:270532616,4608:270540808,4864:8200,5120:2097152,5376:268435456,5632:268435464,5888:2105344,6144:2105352,6400:0,6656:8,6912:270532608,7168:8192,7424:268443656,7680:270540800,7936:2097160,4224:8,4480:2105344,4736:2097152,4992:268435464,5248:268443648,5504:8200,5760:270540808,6016:270532608,6272:270540800,6528:270532616,6784:8192,7040:2105352,7296:2097160,7552:0,7808:268435456,8064:268443656},{0:1048576,16:33555457,32:1024,48:1049601,64:34604033,80:0,96:1,112:34603009,128:33555456,144:1048577,160:33554433,176:34604032,192:34603008,208:1025,224:1049600,240:33554432,8:34603009,24:0,40:33555457,56:34604032,72:1048576,88:33554433,104:33554432,120:1025,136:1049601,152:33555456,168:34603008,184:1048577,200:1024,216:34604033,232:1,248:1049600,256:33554432,272:1048576,288:33555457,304:34603009,320:1048577,336:33555456,352:34604032,368:1049601,384:1025,400:34604033,416:1049600,432:1,448:0,464:34603008,480:33554433,496:1024,264:1049600,280:33555457,296:34603009,312:1,328:33554432,344:1048576,360:1025,376:34604032,392:33554433,408:34603008,424:0,440:34604033,456:1049601,472:1024,488:33555456,504:1048577},{0:134219808,1:131072,2:134217728,3:32,4:131104,5:134350880,6:134350848,7:2048,8:134348800,9:134219776,10:133120,11:134348832,12:2080,13:0,14:134217760,15:133152,2147483648:2048,2147483649:134350880,2147483650:134219808,2147483651:134217728,2147483652:134348800,2147483653:133120,2147483654:133152,2147483655:32,2147483656:134217760,2147483657:2080,2147483658:131104,2147483659:134350848,2147483660:0,2147483661:134348832,2147483662:134219776,2147483663:131072,16:133152,17:134350848,18:32,19:2048,20:134219776,21:134217760,22:134348832,23:131072,24:0,25:131104,26:134348800,27:134219808,28:134350880,29:133120,30:2080,31:134217728,2147483664:131072,2147483665:2048,2147483666:134348832,2147483667:133152,2147483668:32,2147483669:134348800,2147483670:134217728,2147483671:134219808,2147483672:134350880,2147483673:134217760,2147483674:134219776,2147483675:0,2147483676:133120,2147483677:2080,2147483678:131104,2147483679:134350848}],l=[4160749569,528482304,33030144,2064384,129024,8064,504,2147483679],h=s.DES=i.extend({_doReset:function(){for(var t=this._key.words,e=[],n=0;n<56;n++){var r=o[n]-1;e[n]=t[r>>>5]>>>31-r%32&1}for(var i=this._subKeys=[],s=0;s<16;s++){var u=i[s]=[],l=c[s];for(n=0;n<24;n++)u[n/6|0]|=e[(a[n]-1+l)%28]<<31-n%6,u[4+(n/6|0)]|=e[28+(a[n+24]-1+l)%28]<<31-n%6;for(u[0]=u[0]<<1|u[0]>>>31,n=1;n<7;n++)u[n]=u[n]>>>4*(n-1)+3;u[7]=u[7]<<5|u[7]>>>27}var h=this._invSubKeys=[];for(n=0;n<16;n++)h[n]=i[15-n]},encryptBlock:function(t,e){this._doCryptBlock(t,e,this._subKeys)},decryptBlock:function(t,e){this._doCryptBlock(t,e,this._invSubKeys)},_doCryptBlock:function(t,e,n){this._lBlock=t[e],this._rBlock=t[e+1],f.call(this,4,252645135),f.call(this,16,65535),d.call(this,2,858993459),d.call(this,8,16711935),f.call(this,1,1431655765);for(var r=0;r<16;r++){for(var i=n[r],s=this._lBlock,o=this._rBlock,a=0,c=0;c<8;c++)a|=u[c][((o^i[c])&l[c])>>>0];this._lBlock=o,this._rBlock=s^a}var h=this._lBlock;this._lBlock=this._rBlock,this._rBlock=h,f.call(this,1,1431655765),d.call(this,8,16711935),d.call(this,2,858993459),f.call(this,16,65535),f.call(this,4,252645135),t[e]=this._lBlock,t[e+1]=this._rBlock},keySize:2,ivSize:2,blockSize:2});function f(t,e){var n=(this._lBlock>>>t^this._rBlock)&e;this._rBlock^=n,this._lBlock^=n<<t}function d(t,e){var n=(this._rBlock>>>t^this._lBlock)&e;this._lBlock^=n,this._rBlock^=n<<t}t.DES=i._createHelper(h);var p=s.TripleDES=i.extend({_doReset:function(){var t=this._key.words;if(2!==t.length&&4!==t.length&&t.length<6)throw new Error("Invalid key length - 3DES requires the key length to be 64, 128, 192 or >192.");var e=t.slice(0,2),r=t.length<4?t.slice(0,2):t.slice(2,4),i=t.length<6?t.slice(0,2):t.slice(4,6);this._des1=h.createEncryptor(n.create(e)),this._des2=h.createEncryptor(n.create(r)),this._des3=h.createEncryptor(n.create(i))},encryptBlock:function(t,e){this._des1.encryptBlock(t,e),this._des2.decryptBlock(t,e),this._des3.encryptBlock(t,e)},decryptBlock:function(t,e){this._des3.decryptBlock(t,e),this._des2.encryptBlock(t,e),this._des1.decryptBlock(t,e)},keySize:6,ivSize:2,blockSize:2});t.TripleDES=i._createHelper(p)}(),r.TripleDES)},4938:function(t,e,n){var r,i,s,o,a,c,u;t.exports=(u=n(8249),s=(i=u).lib,o=s.Base,a=s.WordArray,(c=i.x64={}).Word=o.extend({init:function(t,e){this.high=t,this.low=e}}),c.WordArray=o.extend({init:function(t,e){t=this.words=t||[],this.sigBytes=e!=r?e:8*t.length},toX32:function(){for(var t=this.words,e=t.length,n=[],r=0;r<e;r++){var i=t[r];n.push(i.high),n.push(i.low)}return a.create(n,this.sigBytes)},clone:function(){for(var t=o.clone.call(this),e=t.words=this.words.slice(0),n=e.length,r=0;r<n;r++)e[r]=e[r].clone();return t}}),u)},4198:(t,e)=>{var n;Object.defineProperty(e,"__esModule",{value:!0}),e.ErrorCode=void 0,(n=e.ErrorCode||(e.ErrorCode={}))[n.SUCCESS=0]="SUCCESS",n[n.CLIENT_ID_NOT_FOUND=1]="CLIENT_ID_NOT_FOUND",n[n.OPERATION_TOO_OFTEN=2]="OPERATION_TOO_OFTEN",n[n.REPEAT_MESSAGE=3]="REPEAT_MESSAGE",n[n.TIME_OUT=4]="TIME_OUT"},9021:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};const i=r(n(6893)),s=r(n(7555)),o=r(n(6379)),a=r(n(529));var c,u;(u=c||(c={})).setDebugMode=function(t){a.default.debugMode=t,a.default.info(`setDebugMode: ${t}`)},u.init=function(t){try{s.default.init(t)}catch(e){a.default.error("init error",e)}},u.setSocketServer=function(t){try{if(!t.url)throw new Error("invalid url");if(!t.key||!t.keyId)throw new Error("invalid key or keyId");o.default.socketUrl=t.url,o.default.publicKeyId=t.keyId,o.default.publicKey=t.key}catch(e){a.default.error("setSocketServer error",e)}},u.enableSocket=function(t){try{s.default.enableSocket(t)}catch(e){a.default.error("enableSocket error",e)}},u.getVersion=function(){return i.default.SDK_VERSION},t.exports=c},9478:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(529)),s=r(n(496)),o=r(n(3555)),a=r(n(1929)),c=r(n(4379)),u=r(n(6899)),l=r(n(776)),h=r(n(2002)),f=r(n(5807)),d=r(n(9704)),p=r(n(6545)),g=r(n(3680)),m=r(n(7706)),y=r(n(4486)),v=r(n(5867)),_=r(n(7006));var w;!function(t){let e,n,r;function w(){let t;try{void 0!==en?(e=new p.default,n=new g.default,r=new m.default):"undefined"!=typeof tt?(e=new h.default,n=new f.default,r=new d.default):"undefined"!=typeof my?(e=new s.default,n=new o.default,r=new a.default):void 0!==tn?(e=new y.default,n=new v.default,r=new _.default):"undefined"!=typeof window&&(e=new c.default,n=new u.default,r=new l.default)}catch(w){i.default.error(`init am error: ${w}`),t=w}if(e&&n&&r||"undefined"!=typeof window&&(e=new c.default,n=new u.default,r=new l.default),!e||!n||!r)throw new Error(`init am error: no api impl found, ${t}`)}t.getDevice=function(){return e||w(),e},t.getStorage=function(){return n||w(),n},t.getWebSocket=function(){return r||w(),r}}(w||(w={})),e.default=w},4685:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(9478));var s,o;(o=s||(s={})).os=function(){return i.default.getDevice().os()},o.osVersion=function(){return i.default.getDevice().osVersion()},o.model=function(){return i.default.getDevice().model()},o.brand=function(){return i.default.getDevice().brand()},o.platform=function(){return i.default.getDevice().platform()},o.platformVersion=function(){return i.default.getDevice().platformVersion()},o.platformId=function(){return i.default.getDevice().platformId()},o.language=function(){return i.default.getDevice().language()},o.userAgent=function(){let t=i.default.getDevice().userAgent;return t?t():""},o.getNetworkType=function(t){i.default.getDevice().getNetworkType(t)},o.onNetworkStatusChange=function(t){i.default.getDevice().onNetworkStatusChange(t)},e.default=s},7002:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(6379)),s=r(n(1386)),o=r(n(4054)),a=n(2918),c=r(n(7167)),u=r(n(529)),l=r(n(9478)),h=r(n(8506));var f;!function(t){let e,n=!1,r=!1,f=!1,d=[],p=0;function g(){return n&&r}function m(e=0){t.allowReconnect&&_()&&setTimeout((function(){y()}),e)}function y(){if(t.allowReconnect=!0,!_())return;if(!function(){var t=d.length;let e=(new Date).getTime();if(t>0)for(var n=t-1;n>=0;n--)if(e-d[n]>5e3){d.splice(0,n+1);break}return t=d.length,d.push(e),!(t>=10&&(u.default.error("connect failed, connection limit reached"),1))}())return;f=!0;let n=i.default.socketUrl;try{let t=h.default.getSync(h.default.KEY_REDIRECT_SERVER,"");if(t){let e=a.RedirectServerData.parse(t),r=e.addressList[0].split(","),i=r[0],s=Number(r[1]);(new Date).getTime()-e.time<1e3*s&&(n=i)}}catch(s){}e=l.default.getWebSocket().connect({url:n,success:function(){r=!0,v()},fail:function(){r=!1,S(),m(100)}}),e.onOpen(b),e.onClose(x),e.onError(T),e.onMessage(E)}function v(){r&&n&&(f=!1,s.default.create().send(),c.default.getInstance().start())}function _(){return i.default.networkConnected?f?(u.default.warn("connecting"),!1):!g()||(u.default.warn("already connected"),!1):(u.default.error("connect failed, network is not available"),!1)}function w(t=""){null==e||e.close({code:1e3,reason:t,success:function(t){},fail:function(t){}}),S()}function S(t){var e;r=!1,n=!1,f=!1,c.default.getInstance().cancel(),i.default.online&&(i.default.online=!1,null===(e=i.default.onlineState)||void 0===e||e.call(i.default.onlineState,{online:i.default.online}))}t.allowReconnect=!0,t.isAvailable=g,t.enableSocket=function(e){let n=(new Date).getTime();n-p<1e3?u.default.warn(`enableSocket ${e} fail: this function can only be called once a second`):(p=n,t.allowReconnect=e,e?t.reconnect(10):t.close(`enableSocket ${e}`))},t.reconnect=m,t.connect=y,t.close=w,t.send=function(t){if(!n||!n)throw new Error("socket not connect");null==e||e.send({data:t,success:function(t){},fail:function(t){}})};let b=function(t){n=!0,v()},E=function(t){try{t.data,c.default.getInstance().refresh(),o.default.receiveMessage(t.data)}catch(e){}},T=function(t){w("socket error")},x=function(t){S()}}(f||(f={})),e.default=f},8506:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(9478));var s,o;(o=s||(s={})).KEY_APPID="getui_appid",o.KEY_CID="getui_cid",o.KEY_SESSION="getui_session",o.KEY_REGID="getui_regid",o.KEY_SOCKET_URL="getui_socket_url",o.KEY_DEVICE_ID="getui_deviceid",o.KEY_ADD_PHONE_INFO_TIME="getui_api_time",o.KEY_BIND_ALIAS_TIME="getui_ba_time",o.KEY_SET_TAG_TIME="getui_st_time",o.KEY_REDIRECT_SERVER="getui_redirect_server",o.KEY_LAST_CONNECT_TIME="getui_last_connect_time",o.set=function(t){i.default.getStorage().set(t)},o.setSync=function(t,e){i.default.getStorage().setSync(t,e)},o.get=function(t){i.default.getStorage().get(t)},o.getSync=function(t,e){let n=i.default.getStorage().getSync(t);return n||e},e.default=s},496:function(t,e,n){const r=(this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}})(n(3854));t.exports=class{constructor(){this.systemInfo=my.getSystemInfoSync()}os(){return r.default.getStr(this.systemInfo,"platform")}osVersion(){return r.default.getStr(this.systemInfo,"system")}model(){return r.default.getStr(this.systemInfo,"model")}brand(){return r.default.getStr(this.systemInfo,"brand")}platform(){return"MP-ALIPAY"}platformVersion(){return r.default.getStr(this.systemInfo,"app")+" "+r.default.getStr(this.systemInfo,"version")}platformId(){return my.getAppIdSync()}language(){return r.default.getStr(this.systemInfo,"language")}getNetworkType(t){my.getNetworkType({success:e=>{var n;null===(n=t.success)||void 0===n||n.call(t.success,{networkType:e.networkType})},fail:()=>{var e;null===(e=t.fail)||void 0===e||e.call(t.fail,"")}})}onNetworkStatusChange(t){my.onNetworkStatusChange(t)}}},3555:t=>{t.exports=class{set(t){my.setStorage({key:t.key,data:t.data,success:t.success,fail:t.fail})}setSync(t,e){my.setStorageSync({key:t,data:e})}get(t){my.getStorage({key:t.key,success:t.success,fail:t.fail,complete:t.complete})}getSync(t){return my.getStorageSync({key:t}).data}}},1929:t=>{t.exports=class{connect(t){return my.connectSocket({url:t.url,header:t.header,method:t.method,success:t.success,fail:t.fail,complete:t.complete}),{onOpen:my.onSocketOpen,send:my.sendSocketMessage,onMessage:t=>{my.onSocketMessage.call(my.onSocketMessage,(e=>{t.call(t,{data:e?e.data:""})}))},onError:my.onSocketError,onClose:my.onSocketClose,close:my.closeSocket}}}},4379:(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default=class{os(){let t=window.navigator.userAgent.toLowerCase();return t.indexOf("android")>0||t.indexOf("adr")>0?"android":t.match(/\(i[^;]+;( u;)? cpu.+mac os x/)?"ios":t.indexOf("windows")>0||t.indexOf("win32")>0||t.indexOf("win64")>0?"windows":t.indexOf("macintosh")>0||t.indexOf("mac os")>0?"mac os":t.indexOf("linux")>0||t.indexOf("unix")>0?"linux":"other"}osVersion(){let t=window.navigator.userAgent.toLowerCase(),e=t.substring(t.indexOf(";")+1).trim();return e.indexOf(";")>0?e.substring(0,e.indexOf(";")).trim():e.substring(0,e.indexOf(")")).trim()}model(){return""}brand(){return""}platform(){return"H5"}platformVersion(){return""}platformId(){return""}language(){return window.navigator.language}userAgent(){return window.navigator.userAgent}getNetworkType(t){var e;null===(e=t.success)||void 0===e||e.call(t.success,{networkType:window.navigator.onLine?"unknown":"none"})}onNetworkStatusChange(t){}}},6899:(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default=class{set(t){var e;window.localStorage.setItem(t.key,t.data),null===(e=t.success)||void 0===e||e.call(t.success,"")}setSync(t,e){window.localStorage.setItem(t,e)}get(t){var e;let n=window.localStorage.getItem(t.key);null===(e=t.success)||void 0===e||e.call(t.success,n)}getSync(t){return window.localStorage.getItem(t)}}},776:(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default=class{connect(t){let e=new WebSocket(t.url);return{send:t=>{var n,r;try{e.send(t.data),null===(n=t.success)||void 0===n||n.call(t.success,{errMsg:""})}catch(i){null===(r=t.fail)||void 0===r||r.call(t.fail,{errMsg:i+""})}},close:t=>{var n,r;try{e.close(t.code,t.reason),null===(n=t.success)||void 0===n||n.call(t.success,{errMsg:""})}catch(i){null===(r=t.fail)||void 0===r||r.call(t.fail,{errMsg:i+""})}},onOpen:n=>{e.onopen=e=>{var r;null===(r=t.success)||void 0===r||r.call(t.success,""),n({header:""})}},onError:n=>{e.onerror=e=>{var r;null===(r=t.fail)||void 0===r||r.call(t.fail,""),n({errMsg:""})}},onMessage:t=>{e.onmessage=e=>{t({data:e.data})}},onClose:t=>{e.onclose=e=>{t(e)}}}}}},2002:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(3854));e.default=class{constructor(){this.systemInfo=tt.getSystemInfoSync()}os(){return i.default.getStr(this.systemInfo,"platform")}osVersion(){return i.default.getStr(this.systemInfo,"system")}model(){return i.default.getStr(this.systemInfo,"model")}brand(){return i.default.getStr(this.systemInfo,"brand")}platform(){return"MP-TOUTIAO"}platformVersion(){return i.default.getStr(this.systemInfo,"appName")+" "+i.default.getStr(this.systemInfo,"version")}language(){return""}platformId(){return""}getNetworkType(t){tt.getNetworkType(t)}onNetworkStatusChange(t){tt.onNetworkStatusChange(t)}}},5807:(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default=class{set(t){tt.setStorage(t)}setSync(t,e){tt.setStorageSync(t,e)}get(t){tt.getStorage(t)}getSync(t){return tt.getStorageSync(t)}}},9704:(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default=class{connect(t){let e=tt.connectSocket({url:t.url,header:t.header,protocols:t.protocols,success:t.success,fail:t.fail,complete:t.complete});return{onOpen:e.onOpen,send:e.send,onMessage:e.onMessage,onError:e.onError,onClose:e.onClose,close:e.close}}}},6545:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(3854));e.default=class{constructor(){try{this.systemInfo=en.getSystemInfoSync(),this.accountInfo=en.getAccountInfoSync()}catch(t){}}os(){return i.default.getStr(this.systemInfo,"platform")}model(){return i.default.getStr(this.systemInfo,"model")}brand(){return i.default.getStr(this.systemInfo,"brand")}osVersion(){return i.default.getStr(this.systemInfo,"system")}platform(){let t="";return t="MP-WEIXIN","MP-WEIXIN"}platformVersion(){return this.systemInfo?this.systemInfo.version:""}platformId(){return this.accountInfo?this.accountInfo.miniProgram.appId:""}language(){var t;return(null===(t=this.systemInfo)||void 0===t?void 0:t.language)?this.systemInfo.language:""}userAgent(){return window?window.navigator.userAgent:""}getNetworkType(t){en.getNetworkType(t)}onNetworkStatusChange(t){en.onNetworkStatusChange(t)}}},3680:(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default=class{set(t){en.setStorage(t)}setSync(t,e){en.setStorageSync(t,e)}get(t){en.getStorage(t)}getSync(t){return en.getStorageSync(t)}}},7706:(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default=class{connect(t){let e=en.connectSocket(t);return{send:t=>{null==e||e.send(t)},close:t=>{null==e||e.close(t)},onOpen:t=>{null==e||e.onOpen(t)},onError:t=>{null==e||e.onError(t)},onMessage:t=>{null==e||e.onMessage(t)},onClose:t=>{null==e||e.onClose(t)}}}}},4486:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(3854));e.default=class{constructor(){this.systemInfo=tn.getSystemInfoSync()}os(){return i.default.getStr(this.systemInfo,"platform")}osVersion(){return i.default.getStr(this.systemInfo,"system")}model(){return i.default.getStr(this.systemInfo,"model")}brand(){return i.default.getStr(this.systemInfo,"brand")}platform(){return"MP-WEIXIN"}platformVersion(){return i.default.getStr(this.systemInfo,"version")}language(){return i.default.getStr(this.systemInfo,"language")}platformId(){return tn.canIUse("getAccountInfoSync")?tn.getAccountInfoSync().miniProgram.appId:""}getNetworkType(t){tn.getNetworkType({success:e=>{var n;null===(n=t.success)||void 0===n||n.call(t.success,{networkType:e.networkType})},fail:t.fail})}onNetworkStatusChange(t){tn.onNetworkStatusChange(t)}}},5867:(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default=class{set(t){tn.setStorage(t)}setSync(t,e){tn.setStorageSync(t,e)}get(t){tn.getStorage(t)}getSync(t){return tn.getStorageSync(t)}}},7006:(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default=class{connect(t){let e=tn.connectSocket({url:t.url,header:t.header,protocols:t.protocols,success:t.success,fail:t.fail,complete:t.complete});return{onOpen:e.onOpen,send:e.send,onMessage:e.onMessage,onError:e.onError,onClose:e.onClose,close:e.close}}}},6893:(t,e)=>{var n,r;Object.defineProperty(e,"__esModule",{value:!0}),(r=n||(n={})).SDK_VERSION="GTMP-2.0.4.dcloud",r.DEFAULT_SOCKET_URL="wss://wshzn.gepush.com:5223/nws",r.SOCKET_PROTOCOL_VERSION="1.0",r.SERVER_PUBLIC_KEY="MHwwDQYJKoZIhvcNAQEBBQADawAwaAJhAJp1rROuvBF7sBSnvLaesj2iFhMcY8aXyLvpnNLKs2wjL3JmEnyr++SlVa35liUlzi83tnAFkn3A9GB7pHBNzawyUkBh8WUhq5bnFIkk2RaDa6+5MpG84DEv52p7RR+aWwIDAQAB",r.SERVER_PUBLIC_KEY_ID="69d747c4b9f641baf4004be4297e9f3b",r.ID_U_2_G=!0,e.default=n},7555:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(7002)),s=r(n(529)),o=r(n(6379));class a{static init(t){var e;if(!this.inited)try{this.checkAppid(t.appid),this.inited=!0,s.default.info(`init: appid=${t.appid}`),o.default.init(t),i.default.connect()}catch(n){throw this.inited=!1,null===(e=t.onError)||void 0===e||e.call(t.onError,{error:n}),n}}static enableSocket(t){this.checkInit(),i.default.enableSocket(t)}static checkInit(){if(!this.inited)throw new Error("not init, please invoke init method firstly")}static checkAppid(t){if(null==t||null==t||""==t.trim())throw new Error(`invalid appid ${t}`)}}a.inited=!1,e.default=a},6379:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(6667)),s=r(n(8506)),o=r(n(6893)),a=r(n(7002)),c=r(n(529)),u=r(n(4685)),l=r(n(2323));class h{static init(t){var e;o.default.ID_U_2_G?this.appid=l.default.to_getui(t.appid):this.appid=t.appid,this.onError=t.onError,this.onClientId=t.onClientId,this.onlineState=t.onlineState,this.onPushMsg=t.onPushMsg,this.appid!=s.default.getSync(s.default.KEY_APPID,this.appid)&&(c.default.info("appid changed, clear session and cid"),s.default.setSync(s.default.KEY_CID,""),s.default.setSync(s.default.KEY_SESSION,"")),s.default.setSync(s.default.KEY_APPID,this.appid),this.cid=s.default.getSync(s.default.KEY_CID,this.cid),this.cid&&(null===(e=this.onClientId)||void 0===e||e.call(this.onClientId,{cid:h.cid})),this.session=s.default.getSync(s.default.KEY_SESSION,this.session),this.deviceId=s.default.getSync(s.default.KEY_DEVICE_ID,this.deviceId),this.regId=s.default.getSync(s.default.KEY_REGID,this.regId),this.regId||(this.regId=this.createRegId(),s.default.set({key:s.default.KEY_REGID,data:this.regId})),this.socketUrl=s.default.getSync(s.default.KEY_SOCKET_URL,this.socketUrl);let n=this;u.default.getNetworkType({success:t=>{n.networkType=t.networkType,n.networkConnected="none"!=n.networkType&&""!=n.networkType}}),u.default.onNetworkStatusChange((t=>{n.networkConnected=t.isConnected,n.networkType=t.networkType,n.networkConnected&&a.default.reconnect(100)}))}static createRegId(){return`M-V${i.default.md5Hex(this.getUuid())}-${(new Date).getTime()}`}static getUuid(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(t){let e=16*Math.random()|0;return("x"===t?e:3&e|8).toString(16)}))}}h.appid="",h.cid="",h.regId="",h.session="",h.deviceId="",h.packetId=1,h.online=!1,h.socketUrl=o.default.DEFAULT_SOCKET_URL,h.publicKeyId=o.default.SERVER_PUBLIC_KEY_ID,h.publicKey=o.default.SERVER_PUBLIC_KEY,h.lastAliasTime=0,h.networkConnected=!0,h.networkType="none",e.default=h},9586:function(t,e,n){var r,i,s=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const o=s(n(661)),a=n(4198),c=s(n(6379));class u extends o.default{constructor(){super(...arguments),this.actionMsgData=new l}static initActionMsg(t,...e){return super.initMsg(t),t.command=o.default.Command.CLIENT_MSG,t.data=t.actionMsgData=l.create(),t}static parseActionMsg(t,e){return super.parseMsg(t,e),t.actionMsgData=l.parse(t.data),t}send(){setTimeout((()=>{var t;(u.waitingLoginMsgMap.has(this.actionMsgData.msgId)||u.waitingResponseMsgMap.has(this.actionMsgData.msgId))&&(u.waitingLoginMsgMap.delete(this.actionMsgData.msgId),u.waitingResponseMsgMap.delete(this.actionMsgData.msgId),null===(t=this.callback)||void 0===t||t.call(this.callback,{resultCode:a.ErrorCode.TIME_OUT,message:"waiting time out"}))}),1e4),c.default.online?(this.actionMsgData.msgAction!=u.ClientAction.RECEIVED&&u.waitingResponseMsgMap.set(this.actionMsgData.msgId,this),super.send()):u.waitingLoginMsgMap.set(this.actionMsgData.msgId,this)}receive(){}static sendWaitingMessages(){let t,e=this.waitingLoginMsgMap.keys();for(;t=e.next(),!t.done;){let e=this.waitingLoginMsgMap.get(t.value);this.waitingLoginMsgMap.delete(t.value),null==e||e.send()}}static getWaitingResponseMessage(t){return u.waitingResponseMsgMap.get(t)}static removeWaitingResponseMessage(t){let e=u.waitingResponseMsgMap.get(t);return e&&u.waitingResponseMsgMap.delete(t),e}}u.ServerAction=((r=class{}).PUSH_MESSAGE="pushmessage",r.REDIRECT_SERVER="redirect_server",r.ADD_PHONE_INFO_RESULT="addphoneinfo",r.SET_MODE_RESULT="set_mode_result",r.SET_TAG_RESULT="settag_result",r.BIND_ALIAS_RESULT="response_bind",r.UNBIND_ALIAS_RESULT="response_unbind",r.FEED_BACK_RESULT="pushmessage_feedback",r.RECEIVED="received",r),u.ClientAction=((i=class{}).ADD_PHONE_INFO="addphoneinfo",i.SET_MODE="set_mode",i.FEED_BACK="pushmessage_feedback",i.SET_TAGS="set_tag",i.BIND_ALIAS="bind_alias",i.UNBIND_ALIAS="unbind_alias",i.RECEIVED="received",i),u.waitingLoginMsgMap=new Map,u.waitingResponseMsgMap=new Map;class l{constructor(){this.appId="",this.cid="",this.msgId="",this.msgAction="",this.msgData="",this.msgExtraData=""}static create(){let t=new l;return t.appId=c.default.appid,t.cid=c.default.cid,t.msgId=(2147483647&(new Date).getTime()).toString(),t}static parse(t){let e=new l,n=JSON.parse(t);return e.appId=n.appId,e.cid=n.cid,e.msgId=n.msgId,e.msgAction=n.msgAction,e.msgData=n.msgData,e.msgExtraData=n.msgExtraData,e}}e.default=u},4516:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(4685)),s=r(n(8506)),o=r(n(6893)),a=n(4198),c=r(n(9586)),u=r(n(6379));class l extends c.default{constructor(){super(...arguments),this.addPhoneInfoData=new h}static create(){let t=new l;return super.initActionMsg(t),t.callback=e=>{e.resultCode!=a.ErrorCode.SUCCESS&&e.resultCode!=a.ErrorCode.REPEAT_MESSAGE?setTimeout((function(){t.send()}),3e4):s.default.set({key:s.default.KEY_ADD_PHONE_INFO_TIME,data:(new Date).getTime()})},t.actionMsgData.msgAction=c.default.ClientAction.ADD_PHONE_INFO,t.addPhoneInfoData=h.create(),t.actionMsgData.msgData=JSON.stringify(t.addPhoneInfoData),t}send(){(new Date).getTime()-s.default.getSync(s.default.KEY_ADD_PHONE_INFO_TIME,0)<864e5||super.send()}}class h{constructor(){this.model="",this.brand="",this.system_version="",this.version="",this.deviceid="",this.type=""}static create(){let t=new h;return t.model=i.default.model(),t.brand=i.default.brand(),t.system_version=i.default.osVersion(),t.version=o.default.SDK_VERSION,t.device_token="",t.imei="",t.oaid="",t.mac="",t.idfa="",t.type="MINIPROGRAM",t.deviceid=`${t.type}-${u.default.deviceId}`,t.extra={os:i.default.os(),platform:i.default.platform(),platformVersion:i.default.platformVersion(),platformId:i.default.platformId(),language:i.default.language(),userAgent:i.default.userAgent()},t}}e.default=l},8723:function(t,e,n){var r,i,s=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const o=s(n(6379)),a=n(4198),c=s(n(9586));class u extends c.default{constructor(){super(...arguments),this.feedbackData=new l}static create(t,e){let n=new u;return super.initActionMsg(n),n.callback=t=>{t.resultCode!=a.ErrorCode.SUCCESS&&t.resultCode!=a.ErrorCode.REPEAT_MESSAGE&&setTimeout((function(){n.send()}),3e4)},n.feedbackData=l.create(t,e),n.actionMsgData.msgAction=c.default.ClientAction.FEED_BACK,n.actionMsgData.msgData=JSON.stringify(n.feedbackData),n}send(){super.send()}}u.ActionId=((r=class{}).RECEIVE="0",r.MP_RECEIVE="210000",r.WEB_RECEIVE="220000",r.BEGIN="1",r),u.RESULT=((i=class{}).OK="ok",i);class l{constructor(){this.messageid="",this.appkey="",this.appid="",this.taskid="",this.actionid="",this.result="",this.timestamp=""}static create(t,e){let n=new l;return n.messageid=t.pushMessageData.messageid,n.appkey=t.pushMessageData.appKey,n.appid=o.default.appid,n.taskid=t.pushMessageData.taskId,n.actionid=e,n.result=u.RESULT.OK,n.timestamp=(new Date).getTime().toString(),n}}e.default=u},6362:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(661));class s extends i.default{static create(){let t=new s;return super.initMsg(t),t.command=i.default.Command.HEART_BEAT,t}}e.default=s},1386:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(6667)),s=r(n(6379)),o=r(n(661));class a extends o.default{constructor(){super(...arguments),this.keyNegotiateData=new c}static create(){let t=new a;return super.initMsg(t),t.command=o.default.Command.KEY_NEGOTIATE,i.default.resetKey(),t.data=t.keyNegotiateData=c.create(),t}send(){super.send()}}class c{constructor(){this.appId="",this.rsaPublicKeyId="",this.algorithm="",this.secretKey="",this.iv=""}static create(){let t=new c;return t.appId=s.default.appid,t.rsaPublicKeyId=s.default.publicKeyId,t.algorithm="AES",t.secretKey=i.default.getEncryptedSecretKey(),t.iv=i.default.getEncryptedIV(),t}}e.default=a},1280:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(661)),s=r(n(6667)),o=r(n(8858)),a=r(n(529)),c=r(n(6379));class u extends i.default{constructor(){super(...arguments),this.keyNegotiateResultData=new l}static parse(t){let e=new u;return super.parseMsg(e,t),e.keyNegotiateResultData=l.parse(e.data),e}receive(){var t,e;if(0!=this.keyNegotiateResultData.errorCode)return a.default.error(`key negotiate fail: ${this.data}`),void(null===(t=c.default.onError)||void 0===t||t.call(c.default.onError,{error:`key negotiate fail: ${this.data}`}));let n=this.keyNegotiateResultData.encryptType.split("/");if(!s.default.algorithmMap.has(n[0].trim().toLowerCase())||!s.default.modeMap.has(n[1].trim().toLowerCase())||!s.default.paddingMap.has(n[2].trim().toLowerCase()))return a.default.error(`key negotiate fail: ${this.data}`),void(null===(e=c.default.onError)||void 0===e||e.call(c.default.onError,{error:`key negotiate fail: ${this.data}`}));s.default.setEncryptParams(n[0].trim().toLowerCase(),n[1].trim().toLowerCase(),n[2].trim().toLowerCase()),o.default.create().send()}}class l{constructor(){this.errorCode=-1,this.errorMsg="",this.encryptType=""}static parse(t){let e=new l,n=JSON.parse(t);return e.errorCode=n.errorCode,e.errorMsg=n.errorMsg,e.encryptType=n.encryptType,e}}e.default=u},8858:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(6379)),s=r(n(6667)),o=r(n(661)),a=r(n(4534));class c extends o.default{constructor(){super(...arguments),this.loginData=new u}static create(){let t=new c;return super.initMsg(t),t.command=o.default.Command.LOGIN,t.data=t.loginData=u.create(),t}send(){this.loginData.session&&i.default.cid==s.default.md5Hex(this.loginData.session)?super.send():a.default.create().send()}}class u{constructor(){this.appId="",this.session=""}static create(){let t=new u;return t.appId=i.default.appid,t.session=i.default.session,t}}e.default=c},1606:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(8506)),s=r(n(661)),o=r(n(6379)),a=r(n(9586)),c=r(n(4516)),u=r(n(8858));class l extends s.default{constructor(){super(...arguments),this.loginResultData=new h}static parse(t){let e=new l;return super.parseMsg(e,t),e.loginResultData=h.parse(e.data),e}receive(){var t;if(0!=this.loginResultData.errorCode)return this.data,o.default.session=o.default.cid="",i.default.setSync(i.default.KEY_CID,""),i.default.setSync(i.default.KEY_SESSION,""),void u.default.create().send();o.default.online||(o.default.online=!0,null===(t=o.default.onlineState)||void 0===t||t.call(o.default.onlineState,{online:o.default.online})),a.default.sendWaitingMessages(),c.default.create().send()}}class h{constructor(){this.errorCode=-1,this.errorMsg="",this.session=""}static parse(t){let e=new h,n=JSON.parse(t);return e.errorCode=n.errorCode,e.errorMsg=n.errorMsg,e.session=n.session,e}}e.default=l},661:function(t,e,n){var r,i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const s=i(n(9593)),o=i(n(7002)),a=i(n(6893)),c=i(n(6379));class u{constructor(){this.version="",this.command=0,this.packetId=0,this.timeStamp=0,this.data="",this.signature=""}static initMsg(t,...e){return t.version=a.default.SOCKET_PROTOCOL_VERSION,t.command=0,t.timeStamp=(new Date).getTime(),t}static parseMsg(t,e){let n=JSON.parse(e);return t.version=n.version,t.command=n.command,t.packetId=n.packetId,t.timeStamp=n.timeStamp,t.data=n.data,t.signature=n.signature,t}stringify(){return JSON.stringify(this,["version","command","packetId","timeStamp","data","signature"])}send(){o.default.isAvailable()&&(this.packetId=c.default.packetId++,this.temp?this.data=this.temp:this.temp=this.data,this.data=JSON.stringify(this.data),this.stringify(),this.command!=u.Command.HEART_BEAT&&(s.default.sign(this),this.data&&this.command!=u.Command.KEY_NEGOTIATE&&s.default.encrypt(this)),o.default.send(this.stringify()))}}u.Command=((r=class{}).HEART_BEAT=0,r.KEY_NEGOTIATE=1,r.KEY_NEGOTIATE_RESULT=16,r.REGISTER=2,r.REGISTER_RESULT=32,r.LOGIN=3,r.LOGIN_RESULT=48,r.LOGOUT=4,r.LOGOUT_RESULT=64,r.CLIENT_MSG=5,r.SERVER_MSG=80,r.SERVER_CLOSE=96,r.REDIRECT_SERVER=112,r),e.default=u},9593:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(6667));var s,o;(o=s||(s={})).encrypt=function(t){t.data=i.default.encrypt(t.data)},o.decrypt=function(t){t.data=i.default.decrypt(t.data)},o.sign=function(t){t.signature=i.default.sha256(`${t.timeStamp}${t.packetId}${t.command}${t.data}`)},o.verify=function(t){let e=i.default.sha256(`${t.timeStamp}${t.packetId}${t.command}${t.data}`);if(t.signature!=e)throw new Error("msg signature vierfy failed")},e.default=s},4054:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(1280)),s=r(n(1606)),o=r(n(661)),a=r(n(1277)),c=r(n(910)),u=r(n(9538)),l=r(n(9479)),h=r(n(6755)),f=r(n(2918)),d=r(n(9586)),p=r(n(9510)),g=r(n(4626)),m=r(n(7562)),y=r(n(9593)),v=r(n(9586)),_=r(n(9519)),w=r(n(8947));e.default=class{static receiveMessage(t){let e=o.default.parseMsg(new o.default,t);if(e.command!=o.default.Command.HEART_BEAT)switch(e.command!=o.default.Command.KEY_NEGOTIATE_RESULT&&e.command!=o.default.Command.SERVER_CLOSE&&e.command!=o.default.Command.REDIRECT_SERVER&&y.default.decrypt(e),e.command!=o.default.Command.SERVER_CLOSE&&e.command!=o.default.Command.REDIRECT_SERVER&&y.default.verify(e),e.command){case o.default.Command.KEY_NEGOTIATE_RESULT:i.default.parse(e.stringify()).receive();break;case o.default.Command.REGISTER_RESULT:a.default.parse(e.stringify()).receive();break;case o.default.Command.LOGIN_RESULT:s.default.parse(e.stringify()).receive();break;case o.default.Command.SERVER_MSG:this.receiveActionMsg(e.stringify());break;case o.default.Command.SERVER_CLOSE:w.default.parse(e.stringify()).receive();break;case o.default.Command.REDIRECT_SERVER:f.default.parse(e.stringify()).receive()}}static receiveActionMsg(t){let e=v.default.parseActionMsg(new v.default,t);if(e.actionMsgData.msgAction!=d.default.ServerAction.RECEIVED&&e.actionMsgData.msgAction!=d.default.ServerAction.REDIRECT_SERVER){let t=JSON.parse(e.actionMsgData.msgData);_.default.create(t.id).send()}switch(e.actionMsgData.msgAction){case d.default.ServerAction.PUSH_MESSAGE:h.default.parse(t).receive();break;case d.default.ServerAction.ADD_PHONE_INFO_RESULT:c.default.parse(t).receive();break;case d.default.ServerAction.SET_MODE_RESULT:p.default.parse(t).receive();break;case d.default.ServerAction.SET_TAG_RESULT:g.default.parse(t).receive();break;case d.default.ServerAction.BIND_ALIAS_RESULT:u.default.parse(t).receive();break;case d.default.ServerAction.UNBIND_ALIAS_RESULT:m.default.parse(t).receive();break;case d.default.ServerAction.FEED_BACK_RESULT:l.default.parse(t).receive();break;case d.default.ServerAction.RECEIVED:_.default.parse(t).receive()}}}},9519:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=n(4198),s=r(n(6379)),o=r(n(9586));class a extends o.default{constructor(){super(...arguments),this.receivedData=new c}static create(t){let e=new a;return super.initActionMsg(e),e.callback=t=>{t.resultCode!=i.ErrorCode.SUCCESS&&t.resultCode!=i.ErrorCode.REPEAT_MESSAGE&&setTimeout((function(){e.send()}),3e3)},e.actionMsgData.msgAction=o.default.ClientAction.RECEIVED,e.receivedData=c.create(t),e.actionMsgData.msgData=JSON.stringify(e.receivedData),e}static parse(t){let e=new a;return super.parseActionMsg(e,t),e.receivedData=c.parse(e.data),e}receive(){var t;let e=o.default.getWaitingResponseMessage(this.actionMsgData.msgId);(e&&e.actionMsgData.msgAction==o.default.ClientAction.ADD_PHONE_INFO||e&&e.actionMsgData.msgAction==o.default.ClientAction.FEED_BACK)&&(o.default.removeWaitingResponseMessage(e.actionMsgData.msgId),null===(t=e.callback)||void 0===t||t.call(e.callback,{resultCode:i.ErrorCode.SUCCESS,message:"received"}))}send(){super.send()}}class c{constructor(){this.msgId="",this.cid=""}static create(t){let e=new c;return e.cid=s.default.cid,e.msgId=t,e}static parse(t){let e=new c,n=JSON.parse(t);return e.cid=n.cid,e.msgId=n.msgId,e}}e.default=a},2918:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.RedirectServerData=void 0;const i=r(n(7002)),s=r(n(8506)),o=r(n(661));class a extends o.default{constructor(){super(...arguments),this.redirectServerData=new c}static parse(t){let e=new a;return super.parseMsg(e,t),e.redirectServerData=c.parse(e.data),e}receive(){this.redirectServerData,s.default.setSync(s.default.KEY_REDIRECT_SERVER,JSON.stringify(this.redirectServerData)),i.default.close("redirect server"),i.default.reconnect(this.redirectServerData.delay)}}class c{constructor(){this.addressList=[],this.delay=0,this.loc="",this.conf="",this.time=0}static parse(t){let e=new c,n=JSON.parse(t);return e.addressList=n.addressList,e.delay=n.delay,e.loc=n.loc,e.conf=n.conf,e.time=n.time?n.time:(new Date).getTime(),e}}e.RedirectServerData=c,e.default=a},4534:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(6379)),s=r(n(661));class o extends s.default{constructor(){super(...arguments),this.registerData=new a}static create(){let t=new o;return super.initMsg(t),t.command=s.default.Command.REGISTER,t.data=t.registerData=a.create(),t}send(){super.send()}}class a{constructor(){this.appId="",this.regId=""}static create(){let t=new a;return t.appId=i.default.appid,t.regId=i.default.regId,t}}e.default=o},1277:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(661)),s=r(n(8506)),o=r(n(6379)),a=r(n(8858)),c=r(n(529));class u extends i.default{constructor(){super(...arguments),this.registerResultData=new l}static parse(t){let e=new u;return super.parseMsg(e,t),e.registerResultData=l.parse(e.data),e}receive(){var t,e;if(0!=this.registerResultData.errorCode||!this.registerResultData.cid||!this.registerResultData.session)return c.default.error(`register fail: ${this.data}`),void(null===(t=o.default.onError)||void 0===t||t.call(o.default.onError,{error:`register fail: ${this.data}`}));o.default.cid!=this.registerResultData.cid&&s.default.setSync(s.default.KEY_ADD_PHONE_INFO_TIME,0),o.default.cid=this.registerResultData.cid,null===(e=o.default.onClientId)||void 0===e||e.call(o.default.onClientId,{cid:o.default.cid}),s.default.set({key:s.default.KEY_CID,data:o.default.cid}),o.default.session=this.registerResultData.session,s.default.set({key:s.default.KEY_SESSION,data:o.default.session}),o.default.deviceId=this.registerResultData.deviceId,s.default.set({key:s.default.KEY_DEVICE_ID,data:o.default.deviceId}),a.default.create().send()}}class l{constructor(){this.errorCode=-1,this.errorMsg="",this.cid="",this.session="",this.deviceId="",this.regId=""}static parse(t){let e=new l,n=JSON.parse(t);return e.errorCode=n.errorCode,e.errorMsg=n.errorMsg,e.cid=n.cid,e.session=n.session,e.deviceId=n.deviceId,e.regId=n.regId,e}}e.default=u},8947:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(7002)),s=r(n(529)),o=r(n(661));class a extends o.default{constructor(){super(...arguments),this.serverCloseData=new c}static parse(t){let e=new a;return super.parseMsg(e,t),e.serverCloseData=c.parse(e.data),e}receive(){JSON.stringify(this.serverCloseData);let t=`server close ${this.serverCloseData.code}`;20==this.serverCloseData.code||23==this.serverCloseData.code||24==this.serverCloseData.code?(i.default.allowReconnect=!1,i.default.close(t)):21==this.serverCloseData.code?this.safeClose21(t):(i.default.allowReconnect=!0,i.default.close(t),i.default.reconnect(10))}safeClose21(t){try{if("undefined"!=typeof document&&document.hasFocus()&&"visible"==document.visibilityState)return i.default.allowReconnect=!0,i.default.close(t),void i.default.reconnect(10);i.default.allowReconnect=!1,i.default.close(t)}catch(e){s.default.error("ServerClose t1",e),i.default.allowReconnect=!1,i.default.close(`${t} error`)}}}class c{constructor(){this.code=-1,this.msg=""}static parse(t){let e=new c,n=JSON.parse(t);return e.code=n.code,e.msg=n.msg,e}}e.default=a},910:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(8506)),s=r(n(9586));class o extends s.default{constructor(){super(...arguments),this.addPhoneInfoResultData=new a}static parse(t){let e=new o;return super.parseActionMsg(e,t),e.addPhoneInfoResultData=a.parse(e.actionMsgData.msgData),e}receive(){var t;this.addPhoneInfoResultData;let e=s.default.removeWaitingResponseMessage(this.actionMsgData.msgId);e&&(null===(t=e.callback)||void 0===t||t.call(e.callback,{resultCode:this.addPhoneInfoResultData.errorCode,message:this.addPhoneInfoResultData.errorMsg})),i.default.set({key:i.default.KEY_ADD_PHONE_INFO_TIME,data:(new Date).getTime()})}}class a{constructor(){this.errorCode=-1,this.errorMsg=""}static parse(t){let e=new a,n=JSON.parse(t);return e.errorCode=n.errorCode,e.errorMsg=n.errorMsg,e}}e.default=o},9538:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(8506)),s=r(n(529)),o=r(n(9586));class a extends o.default{constructor(){super(...arguments),this.bindAliasResultData=new c}static parse(t){let e=new a;return super.parseActionMsg(e,t),e.bindAliasResultData=c.parse(e.actionMsgData.msgData),e}receive(){var t;s.default.info("bind alias result",this.bindAliasResultData);let e=o.default.removeWaitingResponseMessage(this.actionMsgData.msgId);e&&(null===(t=e.callback)||void 0===t||t.call(e.callback,{resultCode:this.bindAliasResultData.errorCode,message:this.bindAliasResultData.errorMsg})),i.default.set({key:i.default.KEY_BIND_ALIAS_TIME,data:(new Date).getTime()})}}class c{constructor(){this.errorCode=-1,this.errorMsg=""}static parse(t){let e=new c,n=JSON.parse(t);return e.errorCode=n.errorCode,e.errorMsg=n.errorMsg,e}}e.default=a},9479:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=n(4198),s=r(n(9586));class o extends s.default{constructor(){super(...arguments),this.feedbackResultData=new a}static parse(t){let e=new o;return super.parseActionMsg(e,t),e.feedbackResultData=a.parse(e.actionMsgData.msgData),e}receive(){var t;this.feedbackResultData;let e=s.default.removeWaitingResponseMessage(this.actionMsgData.msgId);e&&(null===(t=e.callback)||void 0===t||t.call(e.callback,{resultCode:i.ErrorCode.SUCCESS,message:"received"}))}}class a{constructor(){this.actionId="",this.taskId="",this.result=""}static parse(t){let e=new a,n=JSON.parse(t);return e.actionId=n.actionId,e.taskId=n.taskId,e.result=n.result,e}}e.default=o},6755:function(t,e,n){var r,i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const s=i(n(6379)),o=i(n(9586)),a=i(n(8723));class c extends o.default{constructor(){super(...arguments),this.pushMessageData=new u}static parse(t){let e=new c;return super.parseActionMsg(e,t),e.pushMessageData=u.parse(e.actionMsgData.msgData),e}receive(){var t;this.pushMessageData,this.pushMessageData.appId==s.default.appid&&this.pushMessageData.messageid&&this.pushMessageData.taskId||this.stringify(),a.default.create(this,a.default.ActionId.RECEIVE).send(),a.default.create(this,a.default.ActionId.MP_RECEIVE).send(),this.actionMsgData.msgExtraData&&s.default.onPushMsg&&(null===(t=s.default.onPushMsg)||void 0===t||t.call(s.default.onPushMsg,{message:this.actionMsgData.msgExtraData}))}}class u{constructor(){this.id="",this.appKey="",this.appId="",this.messageid="",this.taskId="",this.actionChain=[],this.cdnType=""}static parse(t){let e=new u,n=JSON.parse(t);return e.id=n.id,e.appKey=n.appKey,e.appId=n.appId,e.messageid=n.messageid,e.taskId=n.taskId,e.actionChain=n.actionChain,e.cdnType=n.cdnType,e}}(r=class{}).GO_TO="goto",r.TRANSMIT="transmit",e.default=c},9510:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(9586));class s extends i.default{constructor(){super(...arguments),this.setModeResultData=new o}static parse(t){let e=new s;return super.parseActionMsg(e,t),e.setModeResultData=o.parse(e.actionMsgData.msgData),e}receive(){var t;this.setModeResultData;let e=i.default.removeWaitingResponseMessage(this.actionMsgData.msgId);e&&(null===(t=e.callback)||void 0===t||t.call(e.callback,{resultCode:this.setModeResultData.errorCode,message:this.setModeResultData.errorMsg}))}}class o{constructor(){this.errorCode=-1,this.errorMsg=""}static parse(t){let e=new o,n=JSON.parse(t);return e.errorCode=n.errorCode,e.errorMsg=n.errorMsg,e}}e.default=s},4626:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(8506)),s=r(n(529)),o=r(n(9586));class a extends o.default{constructor(){super(...arguments),this.setTagResultData=new c}static parse(t){let e=new a;return super.parseActionMsg(e,t),e.setTagResultData=c.parse(e.actionMsgData.msgData),e}receive(){var t;s.default.info("set tag result",this.setTagResultData);let e=o.default.removeWaitingResponseMessage(this.actionMsgData.msgId);e&&(null===(t=e.callback)||void 0===t||t.call(e.callback,{resultCode:this.setTagResultData.errorCode,message:this.setTagResultData.errorMsg})),i.default.set({key:i.default.KEY_SET_TAG_TIME,data:(new Date).getTime()})}}class c{constructor(){this.errorCode=0,this.errorMsg=""}static parse(t){let e=new c,n=JSON.parse(t);return e.errorCode=n.errorCode,e.errorMsg=n.errorMsg,e}}e.default=a},7562:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(8506)),s=r(n(529)),o=r(n(9586));class a extends o.default{constructor(){super(...arguments),this.unbindAliasResultData=new c}static parse(t){let e=new a;return super.parseActionMsg(e,t),e.unbindAliasResultData=c.parse(e.actionMsgData.msgData),e}receive(){var t;s.default.info("unbind alias result",this.unbindAliasResultData);let e=o.default.removeWaitingResponseMessage(this.actionMsgData.msgId);e&&(null===(t=e.callback)||void 0===t||t.call(e.callback,{resultCode:this.unbindAliasResultData.errorCode,message:this.unbindAliasResultData.errorMsg})),i.default.set({key:i.default.KEY_BIND_ALIAS_TIME,data:(new Date).getTime()})}}class c{constructor(){this.errorCode=-1,this.errorMsg=""}static parse(t){let e=new c,n=JSON.parse(t);return e.errorCode=n.errorCode,e.errorMsg=n.errorMsg,e}}e.default=a},8227:(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default=class{constructor(t){this.delay=10,this.delay=t}start(){this.cancel();let t=this;this.timer=setInterval((function(){t.run()}),this.delay)}cancel(){this.timer&&clearInterval(this.timer)}}},7167:function(t,e,n){var r,i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const s=i(n(6362)),o=i(n(8227));class a extends o.default{static getInstance(){return a.InstanceHolder.instance}run(){s.default.create().send()}refresh(){this.delay=6e4,this.start()}}a.INTERVAL=6e4,a.InstanceHolder=((r=class{}).instance=new a(a.INTERVAL),r),e.default=a},2323:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(4736)),s=r(n(6667));var o;!function(t){let e=(0,i.default)("9223372036854775808");function n(t){t>=e&&(t=e.multiply(2).minus(t));let n="";for(;t>(0,i.default)(0);t=t.divide(62))n+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz".charAt(Number(t.divmod(62).remainder));return n}t.to_getui=function(t){let e=function(t){let e=function(t){let e=t.length;if(e%2!=0)return[];let n=new Array;for(let r=0;r<e;r+=2)n.push(parseInt(t.substring(r,r+2),16));return n}(s.default.md5Hex(t));return e[6]&=15,e[6]|=48,e[8]&=63,e[8]|=128,e}(t),r=function(t){let e=(0,i.default)(0),n=(0,i.default)(0);for(let r=0;r<8;r++)e=e.multiply(256).plus((0,i.default)(255&t[r]));for(let r=8;r<16;r++)n=n.multiply(256).plus((0,i.default)(255&t[r]));return[e,n]}(e),o=r[1],a=r[0];return n(o)+n(a)}}(o||(o={})),e.default=o},6667:function(t,e,n){var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});const i=r(n(2620)),s=r(n(1354)),o=r(n(6379));var a;!function(t){let e,n,r,a,c=new i.default,u=s.default.mode.CBC,l=s.default.pad.Pkcs7,h=s.default.AES;t.algorithmMap=new Map([["aes",s.default.AES]]),t.modeMap=new Map([["cbc",s.default.mode.CBC],["cfb",s.default.mode.CFB],["cfb128",s.default.mode.CFB],["ecb",s.default.mode.ECB],["ofb",s.default.mode.OFB]]),t.paddingMap=new Map([["nopadding",s.default.pad.NoPadding],["pkcs7",s.default.pad.Pkcs7]]),t.resetKey=function(){e=s.default.MD5((new Date).getTime().toString()),n=s.default.MD5(e),c.setPublicKey(o.default.publicKey),e.toString(s.default.enc.Hex),n.toString(s.default.enc.Hex),r=c.encrypt(e.toString(s.default.enc.Hex)),a=c.encrypt(n.toString(s.default.enc.Hex))},t.setEncryptParams=function(e,n,r){h=t.algorithmMap.get(e),u=t.modeMap.get(n),l=t.paddingMap.get(r)},t.encrypt=function(t){return h.encrypt(t,e,{iv:n,mode:u,padding:l}).toString()},t.decrypt=function(t){return h.decrypt(t,e,{iv:n,mode:u,padding:l}).toString(s.default.enc.Utf8)},t.sha256=function(t){return s.default.SHA256(t).toString(s.default.enc.Base64)},t.md5Hex=function(t){return s.default.MD5(t).toString(s.default.enc.Hex)},t.getEncryptedSecretKey=function(){return r||""},t.getEncryptedIV=function(){return a||""}}(a||(a={})),e.default=a},529:(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0});class n{static info(...t){this.debugMode&&console.info("[GtPush]",t)}static warn(...t){console.warn("[GtPush]",t)}static error(...t){console.error("[GtPush]",t)}}n.debugMode=!1,e.default=n},3854:(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default=class{static getStr(t,e){try{return t&&void 0!==t[e]?t[e]:""}catch(n){}return""}}},2620:(t,e,n)=>{function r(t){return"0123456789abcdefghijklmnopqrstuvwxyz".charAt(t)}function i(t,e){return t&e}function s(t,e){return t|e}function o(t,e){return t^e}function a(t,e){return t&~e}function c(t){if(0==t)return-1;var e=0;return 0==(65535&t)&&(t>>=16,e+=16),0==(255&t)&&(t>>=8,e+=8),0==(15&t)&&(t>>=4,e+=4),0==(3&t)&&(t>>=2,e+=2),0==(1&t)&&++e,e}function u(t){for(var e=0;0!=t;)t&=t-1,++e;return e}n.r(e),n.d(e,{JSEncrypt:()=>tt,default:()=>et});var l,h="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";function f(t){var e,n,r="";for(e=0;e+3<=t.length;e+=3)n=parseInt(t.substring(e,e+3),16),r+=h.charAt(n>>6)+h.charAt(63&n);for(e+1==t.length?(n=parseInt(t.substring(e,e+1),16),r+=h.charAt(n<<2)):e+2==t.length&&(n=parseInt(t.substring(e,e+2),16),r+=h.charAt(n>>2)+h.charAt((3&n)<<4));(3&r.length)>0;)r+="=";return r}var d,p=function(t){var e;if(void 0===l){var n="0123456789ABCDEF",r=" \f\n\r\t \u2028\u2029";for(l={},e=0;e<16;++e)l[n.charAt(e)]=e;for(n=n.toLowerCase(),e=10;e<16;++e)l[n.charAt(e)]=e;for(e=0;e<r.length;++e)l[r.charAt(e)]=-1}var i=[],s=0,o=0;for(e=0;e<t.length;++e){var a=t.charAt(e);if("="==a)break;if(-1!=(a=l[a])){if(void 0===a)throw new Error("Illegal character at offset "+e);s|=a,++o>=2?(i[i.length]=s,s=0,o=0):s<<=4}}if(o)throw new Error("Hex encoding incomplete: 4 bits missing");return i},g={decode:function(t){var e;if(void 0===d){var n="= \f\n\r\t \u2028\u2029";for(d=Object.create(null),e=0;e<64;++e)d["ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(e)]=e;for(d["-"]=62,d._=63,e=0;e<n.length;++e)d[n.charAt(e)]=-1}var r=[],i=0,s=0;for(e=0;e<t.length;++e){var o=t.charAt(e);if("="==o)break;if(-1!=(o=d[o])){if(void 0===o)throw new Error("Illegal character at offset "+e);i|=o,++s>=4?(r[r.length]=i>>16,r[r.length]=i>>8&255,r[r.length]=255&i,i=0,s=0):i<<=6}}switch(s){case 1:throw new Error("Base64 encoding incomplete: at least 2 bits missing");case 2:r[r.length]=i>>10;break;case 3:r[r.length]=i>>16,r[r.length]=i>>8&255}return r},re:/-----BEGIN [^-]+-----([A-Za-z0-9+\/=\s]+)-----END [^-]+-----|begin-base64[^\n]+\n([A-Za-z0-9+\/=\s]+)====/,unarmor:function(t){var e=g.re.exec(t);if(e)if(e[1])t=e[1];else{if(!e[2])throw new Error("RegExp out of sync");t=e[2]}return g.decode(t)}},m=1e13,y=function(){function t(t){this.buf=[+t||0]}return t.prototype.mulAdd=function(t,e){var n,r,i=this.buf,s=i.length;for(n=0;n<s;++n)(r=i[n]*t+e)<m?e=0:r-=(e=0|r/m)*m,i[n]=r;e>0&&(i[n]=e)},t.prototype.sub=function(t){var e,n,r=this.buf,i=r.length;for(e=0;e<i;++e)(n=r[e]-t)<0?(n+=m,t=1):t=0,r[e]=n;for(;0===r[r.length-1];)r.pop()},t.prototype.toString=function(t){if(10!=(t||10))throw new Error("only base 10 is supported");for(var e=this.buf,n=e[e.length-1].toString(),r=e.length-2;r>=0;--r)n+=(m+e[r]).toString().substring(1);return n},t.prototype.valueOf=function(){for(var t=this.buf,e=0,n=t.length-1;n>=0;--n)e=e*m+t[n];return e},t.prototype.simplify=function(){var t=this.buf;return 1==t.length?t[0]:this},t}(),v=/^(\d\d)(0[1-9]|1[0-2])(0[1-9]|[12]\d|3[01])([01]\d|2[0-3])(?:([0-5]\d)(?:([0-5]\d)(?:[.,](\d{1,3}))?)?)?(Z|[-+](?:[0]\d|1[0-2])([0-5]\d)?)?$/,_=/^(\d\d\d\d)(0[1-9]|1[0-2])(0[1-9]|[12]\d|3[01])([01]\d|2[0-3])(?:([0-5]\d)(?:([0-5]\d)(?:[.,](\d{1,3}))?)?)?(Z|[-+](?:[0]\d|1[0-2])([0-5]\d)?)?$/;function w(t,e){return t.length>e&&(t=t.substring(0,e)+"…"),t}var S,b=function(){function t(e,n){this.hexDigits="0123456789ABCDEF",e instanceof t?(this.enc=e.enc,this.pos=e.pos):(this.enc=e,this.pos=n)}return t.prototype.get=function(t){if(void 0===t&&(t=this.pos++),t>=this.enc.length)throw new Error("Requesting byte offset "+t+" on a stream of length "+this.enc.length);return"string"==typeof this.enc?this.enc.charCodeAt(t):this.enc[t]},t.prototype.hexByte=function(t){return this.hexDigits.charAt(t>>4&15)+this.hexDigits.charAt(15&t)},t.prototype.hexDump=function(t,e,n){for(var r="",i=t;i<e;++i)if(r+=this.hexByte(this.get(i)),!0!==n)switch(15&i){case 7:r+="  ";break;case 15:r+="\n";break;default:r+=" "}return r},t.prototype.isASCII=function(t,e){for(var n=t;n<e;++n){var r=this.get(n);if(r<32||r>176)return!1}return!0},t.prototype.parseStringISO=function(t,e){for(var n="",r=t;r<e;++r)n+=String.fromCharCode(this.get(r));return n},t.prototype.parseStringUTF=function(t,e){for(var n="",r=t;r<e;){var i=this.get(r++);n+=i<128?String.fromCharCode(i):i>191&&i<224?String.fromCharCode((31&i)<<6|63&this.get(r++)):String.fromCharCode((15&i)<<12|(63&this.get(r++))<<6|63&this.get(r++))}return n},t.prototype.parseStringBMP=function(t,e){for(var n,r,i="",s=t;s<e;)n=this.get(s++),r=this.get(s++),i+=String.fromCharCode(n<<8|r);return i},t.prototype.parseTime=function(t,e,n){var r=this.parseStringISO(t,e),i=(n?v:_).exec(r);return i?(n&&(i[1]=+i[1],i[1]+=+i[1]<70?2e3:1900),r=i[1]+"-"+i[2]+"-"+i[3]+" "+i[4],i[5]&&(r+=":"+i[5],i[6]&&(r+=":"+i[6],i[7]&&(r+="."+i[7]))),i[8]&&(r+=" UTC","Z"!=i[8]&&(r+=i[8],i[9]&&(r+=":"+i[9]))),r):"Unrecognized time: "+r},t.prototype.parseInteger=function(t,e){for(var n,r=this.get(t),i=r>127,s=i?255:0,o="";r==s&&++t<e;)r=this.get(t);if(0==(n=e-t))return i?-1:0;if(n>4){for(o=r,n<<=3;0==(128&(+o^s));)o=+o<<1,--n;o="("+n+" bit)\n"}i&&(r-=256);for(var a=new y(r),c=t+1;c<e;++c)a.mulAdd(256,this.get(c));return o+a.toString()},t.prototype.parseBitString=function(t,e,n){for(var r=this.get(t),i="("+((e-t-1<<3)-r)+" bit)\n",s="",o=t+1;o<e;++o){for(var a=this.get(o),c=o==e-1?r:0,u=7;u>=c;--u)s+=a>>u&1?"1":"0";if(s.length>n)return i+w(s,n)}return i+s},t.prototype.parseOctetString=function(t,e,n){if(this.isASCII(t,e))return w(this.parseStringISO(t,e),n);var r=e-t,i="("+r+" byte)\n";r>(n/=2)&&(e=t+n);for(var s=t;s<e;++s)i+=this.hexByte(this.get(s));return r>n&&(i+="…"),i},t.prototype.parseOID=function(t,e,n){for(var r="",i=new y,s=0,o=t;o<e;++o){var a=this.get(o);if(i.mulAdd(128,127&a),s+=7,!(128&a)){if(""===r)if((i=i.simplify())instanceof y)i.sub(80),r="2."+i.toString();else{var c=i<80?i<40?0:1:2;r=c+"."+(i-40*c)}else r+="."+i.toString();if(r.length>n)return w(r,n);i=new y,s=0}}return s>0&&(r+=".incomplete"),r},t}(),E=function(){function t(t,e,n,r,i){if(!(r instanceof T))throw new Error("Invalid tag value.");this.stream=t,this.header=e,this.length=n,this.tag=r,this.sub=i}return t.prototype.typeName=function(){switch(this.tag.tagClass){case 0:switch(this.tag.tagNumber){case 0:return"EOC";case 1:return"BOOLEAN";case 2:return"INTEGER";case 3:return"BIT_STRING";case 4:return"OCTET_STRING";case 5:return"NULL";case 6:return"OBJECT_IDENTIFIER";case 7:return"ObjectDescriptor";case 8:return"EXTERNAL";case 9:return"REAL";case 10:return"ENUMERATED";case 11:return"EMBEDDED_PDV";case 12:return"UTF8String";case 16:return"SEQUENCE";case 17:return"SET";case 18:return"NumericString";case 19:return"PrintableString";case 20:return"TeletexString";case 21:return"VideotexString";case 22:return"IA5String";case 23:return"UTCTime";case 24:return"GeneralizedTime";case 25:return"GraphicString";case 26:return"VisibleString";case 27:return"GeneralString";case 28:return"UniversalString";case 30:return"BMPString"}return"Universal_"+this.tag.tagNumber.toString();case 1:return"Application_"+this.tag.tagNumber.toString();case 2:return"["+this.tag.tagNumber.toString()+"]";case 3:return"Private_"+this.tag.tagNumber.toString()}},t.prototype.content=function(t){if(void 0===this.tag)return null;void 0===t&&(t=1/0);var e=this.posContent(),n=Math.abs(this.length);if(!this.tag.isUniversal())return null!==this.sub?"("+this.sub.length+" elem)":this.stream.parseOctetString(e,e+n,t);switch(this.tag.tagNumber){case 1:return 0===this.stream.get(e)?"false":"true";case 2:return this.stream.parseInteger(e,e+n);case 3:return this.sub?"("+this.sub.length+" elem)":this.stream.parseBitString(e,e+n,t);case 4:return this.sub?"("+this.sub.length+" elem)":this.stream.parseOctetString(e,e+n,t);case 6:return this.stream.parseOID(e,e+n,t);case 16:case 17:return null!==this.sub?"("+this.sub.length+" elem)":"(no elem)";case 12:return w(this.stream.parseStringUTF(e,e+n),t);case 18:case 19:case 20:case 21:case 22:case 26:return w(this.stream.parseStringISO(e,e+n),t);case 30:return w(this.stream.parseStringBMP(e,e+n),t);case 23:case 24:return this.stream.parseTime(e,e+n,23==this.tag.tagNumber)}return null},t.prototype.toString=function(){return this.typeName()+"@"+this.stream.pos+"[header:"+this.header+",length:"+this.length+",sub:"+(null===this.sub?"null":this.sub.length)+"]"},t.prototype.toPrettyString=function(t){void 0===t&&(t="");var e=t+this.typeName()+" @"+this.stream.pos;if(this.length>=0&&(e+="+"),e+=this.length,this.tag.tagConstructed?e+=" (constructed)":!this.tag.isUniversal()||3!=this.tag.tagNumber&&4!=this.tag.tagNumber||null===this.sub||(e+=" (encapsulates)"),e+="\n",null!==this.sub){t+="  ";for(var n=0,r=this.sub.length;n<r;++n)e+=this.sub[n].toPrettyString(t)}return e},t.prototype.posStart=function(){return this.stream.pos},t.prototype.posContent=function(){return this.stream.pos+this.header},t.prototype.posEnd=function(){return this.stream.pos+this.header+Math.abs(this.length)},t.prototype.toHexString=function(){return this.stream.hexDump(this.posStart(),this.posEnd(),!0)},t.decodeLength=function(t){var e=t.get(),n=127&e;if(n==e)return n;if(n>6)throw new Error("Length over 48 bits not supported at position "+(t.pos-1));if(0===n)return null;e=0;for(var r=0;r<n;++r)e=256*e+t.get();return e},t.prototype.getHexStringValue=function(){var t=this.toHexString(),e=2*this.header,n=2*this.length;return t.substr(e,n)},t.decode=function(e){var n;n=e instanceof b?e:new b(e,0);var r=new b(n),i=new T(n),s=t.decodeLength(n),o=n.pos,a=o-r.pos,c=null,u=function(){var e=[];if(null!==s){for(var r=o+s;n.pos<r;)e[e.length]=t.decode(n);if(n.pos!=r)throw new Error("Content size is not correct for container starting at offset "+o)}else try{for(;;){var i=t.decode(n);if(i.tag.isEOC())break;e[e.length]=i}s=o-n.pos}catch(a){throw new Error("Exception while decoding undefined length content: "+a)}return e};if(i.tagConstructed)c=u();else if(i.isUniversal()&&(3==i.tagNumber||4==i.tagNumber))try{if(3==i.tagNumber&&0!=n.get())throw new Error("BIT STRINGs with unused bits cannot encapsulate.");c=u();for(var l=0;l<c.length;++l)if(c[l].tag.isEOC())throw new Error("EOC is not supposed to be actual content.")}catch(h){c=null}if(null===c){if(null===s)throw new Error("We can't skip over an invalid tag with undefined length at offset "+o);n.pos=o+Math.abs(s)}return new t(r,a,s,i,c)},t}(),T=function(){function t(t){var e=t.get();if(this.tagClass=e>>6,this.tagConstructed=0!=(32&e),this.tagNumber=31&e,31==this.tagNumber){var n=new y;do{e=t.get(),n.mulAdd(128,127&e)}while(128&e);this.tagNumber=n.simplify()}}return t.prototype.isUniversal=function(){return 0===this.tagClass},t.prototype.isEOC=function(){return 0===this.tagClass&&0===this.tagNumber},t}(),x=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97,101,103,107,109,113,127,131,137,139,149,151,157,163,167,173,179,181,191,193,197,199,211,223,227,229,233,239,241,251,257,263,269,271,277,281,283,293,307,311,313,317,331,337,347,349,353,359,367,373,379,383,389,397,401,409,419,421,431,433,439,443,449,457,461,463,467,479,487,491,499,503,509,521,523,541,547,557,563,569,571,577,587,593,599,601,607,613,617,619,631,641,643,647,653,659,661,673,677,683,691,701,709,719,727,733,739,743,751,757,761,769,773,787,797,809,811,821,823,827,829,839,853,857,859,863,877,881,883,887,907,911,919,929,937,941,947,953,967,971,977,983,991,997],I=(1<<26)/x[x.length-1],D=function(){function t(t,e,n){null!=t&&("number"==typeof t?this.fromNumber(t,e,n):null==e&&"string"!=typeof t?this.fromString(t,256):this.fromString(t,e))}return t.prototype.toString=function(t){if(this.s<0)return"-"+this.negate().toString(t);var e;if(16==t)e=4;else if(8==t)e=3;else if(2==t)e=1;else if(32==t)e=5;else{if(4!=t)return this.toRadix(t);e=2}var n,i=(1<<e)-1,s=!1,o="",a=this.t,c=this.DB-a*this.DB%e;if(a-- >0)for(c<this.DB&&(n=this[a]>>c)>0&&(s=!0,o=r(n));a>=0;)c<e?(n=(this[a]&(1<<c)-1)<<e-c,n|=this[--a]>>(c+=this.DB-e)):(n=this[a]>>(c-=e)&i,c<=0&&(c+=this.DB,--a)),n>0&&(s=!0),s&&(o+=r(n));return s?o:"0"},t.prototype.negate=function(){var e=P();return t.ZERO.subTo(this,e),e},t.prototype.abs=function(){return this.s<0?this.negate():this},t.prototype.compareTo=function(t){var e=this.s-t.s;if(0!=e)return e;var n=this.t;if(0!=(e=n-t.t))return this.s<0?-e:e;for(;--n>=0;)if(0!=(e=this[n]-t[n]))return e;return 0},t.prototype.bitLength=function(){return this.t<=0?0:this.DB*(this.t-1)+U(this[this.t-1]^this.s&this.DM)},t.prototype.mod=function(e){var n=P();return this.abs().divRemTo(e,null,n),this.s<0&&n.compareTo(t.ZERO)>0&&e.subTo(n,n),n},t.prototype.modPowInt=function(t,e){var n;return n=t<256||e.isEven()?new k(e):new O(e),this.exp(t,n)},t.prototype.clone=function(){var t=P();return this.copyTo(t),t},t.prototype.intValue=function(){if(this.s<0){if(1==this.t)return this[0]-this.DV;if(0==this.t)return-1}else{if(1==this.t)return this[0];if(0==this.t)return 0}return(this[1]&(1<<32-this.DB)-1)<<this.DB|this[0]},t.prototype.byteValue=function(){return 0==this.t?this.s:this[0]<<24>>24},t.prototype.shortValue=function(){return 0==this.t?this.s:this[0]<<16>>16},t.prototype.signum=function(){return this.s<0?-1:this.t<=0||1==this.t&&this[0]<=0?0:1},t.prototype.toByteArray=function(){var t=this.t,e=[];e[0]=this.s;var n,r=this.DB-t*this.DB%8,i=0;if(t-- >0)for(r<this.DB&&(n=this[t]>>r)!=(this.s&this.DM)>>r&&(e[i++]=n|this.s<<this.DB-r);t>=0;)r<8?(n=(this[t]&(1<<r)-1)<<8-r,n|=this[--t]>>(r+=this.DB-8)):(n=this[t]>>(r-=8)&255,r<=0&&(r+=this.DB,--t)),0!=(128&n)&&(n|=-256),0==i&&(128&this.s)!=(128&n)&&++i,(i>0||n!=this.s)&&(e[i++]=n);return e},t.prototype.equals=function(t){return 0==this.compareTo(t)},t.prototype.min=function(t){return this.compareTo(t)<0?this:t},t.prototype.max=function(t){return this.compareTo(t)>0?this:t},t.prototype.and=function(t){var e=P();return this.bitwiseTo(t,i,e),e},t.prototype.or=function(t){var e=P();return this.bitwiseTo(t,s,e),e},t.prototype.xor=function(t){var e=P();return this.bitwiseTo(t,o,e),e},t.prototype.andNot=function(t){var e=P();return this.bitwiseTo(t,a,e),e},t.prototype.not=function(){for(var t=P(),e=0;e<this.t;++e)t[e]=this.DM&~this[e];return t.t=this.t,t.s=~this.s,t},t.prototype.shiftLeft=function(t){var e=P();return t<0?this.rShiftTo(-t,e):this.lShiftTo(t,e),e},t.prototype.shiftRight=function(t){var e=P();return t<0?this.lShiftTo(-t,e):this.rShiftTo(t,e),e},t.prototype.getLowestSetBit=function(){for(var t=0;t<this.t;++t)if(0!=this[t])return t*this.DB+c(this[t]);return this.s<0?this.t*this.DB:-1},t.prototype.bitCount=function(){for(var t=0,e=this.s&this.DM,n=0;n<this.t;++n)t+=u(this[n]^e);return t},t.prototype.testBit=function(t){var e=Math.floor(t/this.DB);return e>=this.t?0!=this.s:0!=(this[e]&1<<t%this.DB)},t.prototype.setBit=function(t){return this.changeBit(t,s)},t.prototype.clearBit=function(t){return this.changeBit(t,a)},t.prototype.flipBit=function(t){return this.changeBit(t,o)},t.prototype.add=function(t){var e=P();return this.addTo(t,e),e},t.prototype.subtract=function(t){var e=P();return this.subTo(t,e),e},t.prototype.multiply=function(t){var e=P();return this.multiplyTo(t,e),e},t.prototype.divide=function(t){var e=P();return this.divRemTo(t,e,null),e},t.prototype.remainder=function(t){var e=P();return this.divRemTo(t,null,e),e},t.prototype.divideAndRemainder=function(t){var e=P(),n=P();return this.divRemTo(t,e,n),[e,n]},t.prototype.modPow=function(t,e){var n,r,i=t.bitLength(),s=V(1);if(i<=0)return s;n=i<18?1:i<48?3:i<144?4:i<768?5:6,r=i<8?new k(e):e.isEven()?new R(e):new O(e);var o=[],a=3,c=n-1,u=(1<<n)-1;if(o[1]=r.convert(this),n>1){var l=P();for(r.sqrTo(o[1],l);a<=u;)o[a]=P(),r.mulTo(l,o[a-2],o[a]),a+=2}var h,f,d=t.t-1,p=!0,g=P();for(i=U(t[d])-1;d>=0;){for(i>=c?h=t[d]>>i-c&u:(h=(t[d]&(1<<i+1)-1)<<c-i,d>0&&(h|=t[d-1]>>this.DB+i-c)),a=n;0==(1&h);)h>>=1,--a;if((i-=a)<0&&(i+=this.DB,--d),p)o[h].copyTo(s),p=!1;else{for(;a>1;)r.sqrTo(s,g),r.sqrTo(g,s),a-=2;a>0?r.sqrTo(s,g):(f=s,s=g,g=f),r.mulTo(g,o[h],s)}for(;d>=0&&0==(t[d]&1<<i);)r.sqrTo(s,g),f=s,s=g,g=f,--i<0&&(i=this.DB-1,--d)}return r.revert(s)},t.prototype.modInverse=function(e){var n=e.isEven();if(this.isEven()&&n||0==e.signum())return t.ZERO;for(var r=e.clone(),i=this.clone(),s=V(1),o=V(0),a=V(0),c=V(1);0!=r.signum();){for(;r.isEven();)r.rShiftTo(1,r),n?(s.isEven()&&o.isEven()||(s.addTo(this,s),o.subTo(e,o)),s.rShiftTo(1,s)):o.isEven()||o.subTo(e,o),o.rShiftTo(1,o);for(;i.isEven();)i.rShiftTo(1,i),n?(a.isEven()&&c.isEven()||(a.addTo(this,a),c.subTo(e,c)),a.rShiftTo(1,a)):c.isEven()||c.subTo(e,c),c.rShiftTo(1,c);r.compareTo(i)>=0?(r.subTo(i,r),n&&s.subTo(a,s),o.subTo(c,o)):(i.subTo(r,i),n&&a.subTo(s,a),c.subTo(o,c))}return 0!=i.compareTo(t.ONE)?t.ZERO:c.compareTo(e)>=0?c.subtract(e):c.signum()<0?(c.addTo(e,c),c.signum()<0?c.add(e):c):c},t.prototype.pow=function(t){return this.exp(t,new A)},t.prototype.gcd=function(t){var e=this.s<0?this.negate():this.clone(),n=t.s<0?t.negate():t.clone();if(e.compareTo(n)<0){var r=e;e=n,n=r}var i=e.getLowestSetBit(),s=n.getLowestSetBit();if(s<0)return e;for(i<s&&(s=i),s>0&&(e.rShiftTo(s,e),n.rShiftTo(s,n));e.signum()>0;)(i=e.getLowestSetBit())>0&&e.rShiftTo(i,e),(i=n.getLowestSetBit())>0&&n.rShiftTo(i,n),e.compareTo(n)>=0?(e.subTo(n,e),e.rShiftTo(1,e)):(n.subTo(e,n),n.rShiftTo(1,n));return s>0&&n.lShiftTo(s,n),n},t.prototype.isProbablePrime=function(t){var e,n=this.abs();if(1==n.t&&n[0]<=x[x.length-1]){for(e=0;e<x.length;++e)if(n[0]==x[e])return!0;return!1}if(n.isEven())return!1;for(e=1;e<x.length;){for(var r=x[e],i=e+1;i<x.length&&r<I;)r*=x[i++];for(r=n.modInt(r);e<i;)if(r%x[e++]==0)return!1}return n.millerRabin(t)},t.prototype.copyTo=function(t){for(var e=this.t-1;e>=0;--e)t[e]=this[e];t.t=this.t,t.s=this.s},t.prototype.fromInt=function(t){this.t=1,this.s=t<0?-1:0,t>0?this[0]=t:t<-1?this[0]=t+this.DV:this.t=0},t.prototype.fromString=function(e,n){var r;if(16==n)r=4;else if(8==n)r=3;else if(256==n)r=8;else if(2==n)r=1;else if(32==n)r=5;else{if(4!=n)return void this.fromRadix(e,n);r=2}this.t=0,this.s=0;for(var i=e.length,s=!1,o=0;--i>=0;){var a=8==r?255&+e[i]:j(e,i);a<0?"-"==e.charAt(i)&&(s=!0):(s=!1,0==o?this[this.t++]=a:o+r>this.DB?(this[this.t-1]|=(a&(1<<this.DB-o)-1)<<o,this[this.t++]=a>>this.DB-o):this[this.t-1]|=a<<o,(o+=r)>=this.DB&&(o-=this.DB))}8==r&&0!=(128&+e[0])&&(this.s=-1,o>0&&(this[this.t-1]|=(1<<this.DB-o)-1<<o)),this.clamp(),s&&t.ZERO.subTo(this,this)},t.prototype.clamp=function(){for(var t=this.s&this.DM;this.t>0&&this[this.t-1]==t;)--this.t},t.prototype.dlShiftTo=function(t,e){var n;for(n=this.t-1;n>=0;--n)e[n+t]=this[n];for(n=t-1;n>=0;--n)e[n]=0;e.t=this.t+t,e.s=this.s},t.prototype.drShiftTo=function(t,e){for(var n=t;n<this.t;++n)e[n-t]=this[n];e.t=Math.max(this.t-t,0),e.s=this.s},t.prototype.lShiftTo=function(t,e){for(var n=t%this.DB,r=this.DB-n,i=(1<<r)-1,s=Math.floor(t/this.DB),o=this.s<<n&this.DM,a=this.t-1;a>=0;--a)e[a+s+1]=this[a]>>r|o,o=(this[a]&i)<<n;for(a=s-1;a>=0;--a)e[a]=0;e[s]=o,e.t=this.t+s+1,e.s=this.s,e.clamp()},t.prototype.rShiftTo=function(t,e){e.s=this.s;var n=Math.floor(t/this.DB);if(n>=this.t)e.t=0;else{var r=t%this.DB,i=this.DB-r,s=(1<<r)-1;e[0]=this[n]>>r;for(var o=n+1;o<this.t;++o)e[o-n-1]|=(this[o]&s)<<i,e[o-n]=this[o]>>r;r>0&&(e[this.t-n-1]|=(this.s&s)<<i),e.t=this.t-n,e.clamp()}},t.prototype.subTo=function(t,e){for(var n=0,r=0,i=Math.min(t.t,this.t);n<i;)r+=this[n]-t[n],e[n++]=r&this.DM,r>>=this.DB;if(t.t<this.t){for(r-=t.s;n<this.t;)r+=this[n],e[n++]=r&this.DM,r>>=this.DB;r+=this.s}else{for(r+=this.s;n<t.t;)r-=t[n],e[n++]=r&this.DM,r>>=this.DB;r-=t.s}e.s=r<0?-1:0,r<-1?e[n++]=this.DV+r:r>0&&(e[n++]=r),e.t=n,e.clamp()},t.prototype.multiplyTo=function(e,n){var r=this.abs(),i=e.abs(),s=r.t;for(n.t=s+i.t;--s>=0;)n[s]=0;for(s=0;s<i.t;++s)n[s+r.t]=r.am(0,i[s],n,s,0,r.t);n.s=0,n.clamp(),this.s!=e.s&&t.ZERO.subTo(n,n)},t.prototype.squareTo=function(t){for(var e=this.abs(),n=t.t=2*e.t;--n>=0;)t[n]=0;for(n=0;n<e.t-1;++n){var r=e.am(n,e[n],t,2*n,0,1);(t[n+e.t]+=e.am(n+1,2*e[n],t,2*n+1,r,e.t-n-1))>=e.DV&&(t[n+e.t]-=e.DV,t[n+e.t+1]=1)}t.t>0&&(t[t.t-1]+=e.am(n,e[n],t,2*n,0,1)),t.s=0,t.clamp()},t.prototype.divRemTo=function(e,n,r){var i=e.abs();if(!(i.t<=0)){var s=this.abs();if(s.t<i.t)return null!=n&&n.fromInt(0),void(null!=r&&this.copyTo(r));null==r&&(r=P());var o=P(),a=this.s,c=e.s,u=this.DB-U(i[i.t-1]);u>0?(i.lShiftTo(u,o),s.lShiftTo(u,r)):(i.copyTo(o),s.copyTo(r));var l=o.t,h=o[l-1];if(0!=h){var f=h*(1<<this.F1)+(l>1?o[l-2]>>this.F2:0),d=this.FV/f,p=(1<<this.F1)/f,g=1<<this.F2,m=r.t,y=m-l,v=null==n?P():n;for(o.dlShiftTo(y,v),r.compareTo(v)>=0&&(r[r.t++]=1,r.subTo(v,r)),t.ONE.dlShiftTo(l,v),v.subTo(o,o);o.t<l;)o[o.t++]=0;for(;--y>=0;){var _=r[--m]==h?this.DM:Math.floor(r[m]*d+(r[m-1]+g)*p);if((r[m]+=o.am(0,_,r,y,0,l))<_)for(o.dlShiftTo(y,v),r.subTo(v,r);r[m]<--_;)r.subTo(v,r)}null!=n&&(r.drShiftTo(l,n),a!=c&&t.ZERO.subTo(n,n)),r.t=l,r.clamp(),u>0&&r.rShiftTo(u,r),a<0&&t.ZERO.subTo(r,r)}}},t.prototype.invDigit=function(){if(this.t<1)return 0;var t=this[0];if(0==(1&t))return 0;var e=3&t;return(e=(e=(e=(e=e*(2-(15&t)*e)&15)*(2-(255&t)*e)&255)*(2-((65535&t)*e&65535))&65535)*(2-t*e%this.DV)%this.DV)>0?this.DV-e:-e},t.prototype.isEven=function(){return 0==(this.t>0?1&this[0]:this.s)},t.prototype.exp=function(e,n){if(e>4294967295||e<1)return t.ONE;var r=P(),i=P(),s=n.convert(this),o=U(e)-1;for(s.copyTo(r);--o>=0;)if(n.sqrTo(r,i),(e&1<<o)>0)n.mulTo(i,s,r);else{var a=r;r=i,i=a}return n.revert(r)},t.prototype.chunkSize=function(t){return Math.floor(Math.LN2*this.DB/Math.log(t))},t.prototype.toRadix=function(t){if(null==t&&(t=10),0==this.signum()||t<2||t>36)return"0";var e=this.chunkSize(t),n=Math.pow(t,e),r=V(n),i=P(),s=P(),o="";for(this.divRemTo(r,i,s);i.signum()>0;)o=(n+s.intValue()).toString(t).substr(1)+o,i.divRemTo(r,i,s);return s.intValue().toString(t)+o},t.prototype.fromRadix=function(e,n){this.fromInt(0),null==n&&(n=10);for(var r=this.chunkSize(n),i=Math.pow(n,r),s=!1,o=0,a=0,c=0;c<e.length;++c){var u=j(e,c);u<0?"-"==e.charAt(c)&&0==this.signum()&&(s=!0):(a=n*a+u,++o>=r&&(this.dMultiply(i),this.dAddOffset(a,0),o=0,a=0))}o>0&&(this.dMultiply(Math.pow(n,o)),this.dAddOffset(a,0)),s&&t.ZERO.subTo(this,this)},t.prototype.fromNumber=function(e,n,r){if("number"==typeof n)if(e<2)this.fromInt(1);else for(this.fromNumber(e,r),this.testBit(e-1)||this.bitwiseTo(t.ONE.shiftLeft(e-1),s,this),this.isEven()&&this.dAddOffset(1,0);!this.isProbablePrime(n);)this.dAddOffset(2,0),this.bitLength()>e&&this.subTo(t.ONE.shiftLeft(e-1),this);else{var i=[],o=7&e;i.length=1+(e>>3),n.nextBytes(i),o>0?i[0]&=(1<<o)-1:i[0]=0,this.fromString(i,256)}},t.prototype.bitwiseTo=function(t,e,n){var r,i,s=Math.min(t.t,this.t);for(r=0;r<s;++r)n[r]=e(this[r],t[r]);if(t.t<this.t){for(i=t.s&this.DM,r=s;r<this.t;++r)n[r]=e(this[r],i);n.t=this.t}else{for(i=this.s&this.DM,r=s;r<t.t;++r)n[r]=e(i,t[r]);n.t=t.t}n.s=e(this.s,t.s),n.clamp()},t.prototype.changeBit=function(e,n){var r=t.ONE.shiftLeft(e);return this.bitwiseTo(r,n,r),r},t.prototype.addTo=function(t,e){for(var n=0,r=0,i=Math.min(t.t,this.t);n<i;)r+=this[n]+t[n],e[n++]=r&this.DM,r>>=this.DB;if(t.t<this.t){for(r+=t.s;n<this.t;)r+=this[n],e[n++]=r&this.DM,r>>=this.DB;r+=this.s}else{for(r+=this.s;n<t.t;)r+=t[n],e[n++]=r&this.DM,r>>=this.DB;r+=t.s}e.s=r<0?-1:0,r>0?e[n++]=r:r<-1&&(e[n++]=this.DV+r),e.t=n,e.clamp()},t.prototype.dMultiply=function(t){this[this.t]=this.am(0,t-1,this,0,0,this.t),++this.t,this.clamp()},t.prototype.dAddOffset=function(t,e){if(0!=t){for(;this.t<=e;)this[this.t++]=0;for(this[e]+=t;this[e]>=this.DV;)this[e]-=this.DV,++e>=this.t&&(this[this.t++]=0),++this[e]}},t.prototype.multiplyLowerTo=function(t,e,n){var r=Math.min(this.t+t.t,e);for(n.s=0,n.t=r;r>0;)n[--r]=0;for(var i=n.t-this.t;r<i;++r)n[r+this.t]=this.am(0,t[r],n,r,0,this.t);for(i=Math.min(t.t,e);r<i;++r)this.am(0,t[r],n,r,0,e-r);n.clamp()},t.prototype.multiplyUpperTo=function(t,e,n){--e;var r=n.t=this.t+t.t-e;for(n.s=0;--r>=0;)n[r]=0;for(r=Math.max(e-this.t,0);r<t.t;++r)n[this.t+r-e]=this.am(e-r,t[r],n,0,0,this.t+r-e);n.clamp(),n.drShiftTo(1,n)},t.prototype.modInt=function(t){if(t<=0)return 0;var e=this.DV%t,n=this.s<0?t-1:0;if(this.t>0)if(0==e)n=this[0]%t;else for(var r=this.t-1;r>=0;--r)n=(e*n+this[r])%t;return n},t.prototype.millerRabin=function(e){var n=this.subtract(t.ONE),r=n.getLowestSetBit();if(r<=0)return!1;var i=n.shiftRight(r);(e=e+1>>1)>x.length&&(e=x.length);for(var s=P(),o=0;o<e;++o){s.fromInt(x[Math.floor(Math.random()*x.length)]);var a=s.modPow(i,this);if(0!=a.compareTo(t.ONE)&&0!=a.compareTo(n)){for(var c=1;c++<r&&0!=a.compareTo(n);)if(0==(a=a.modPowInt(2,this)).compareTo(t.ONE))return!1;if(0!=a.compareTo(n))return!1}}return!0},t.prototype.square=function(){var t=P();return this.squareTo(t),t},t.prototype.gcda=function(t,e){var n=this.s<0?this.negate():this.clone(),r=t.s<0?t.negate():t.clone();if(n.compareTo(r)<0){var i=n;n=r,r=i}var s=n.getLowestSetBit(),o=r.getLowestSetBit();if(o<0)e(n);else{s<o&&(o=s),o>0&&(n.rShiftTo(o,n),r.rShiftTo(o,r));var a=function(){(s=n.getLowestSetBit())>0&&n.rShiftTo(s,n),(s=r.getLowestSetBit())>0&&r.rShiftTo(s,r),n.compareTo(r)>=0?(n.subTo(r,n),n.rShiftTo(1,n)):(r.subTo(n,r),r.rShiftTo(1,r)),n.signum()>0?setTimeout(a,0):(o>0&&r.lShiftTo(o,r),setTimeout((function(){e(r)}),0))};setTimeout(a,10)}},t.prototype.fromNumberAsync=function(e,n,r,i){if("number"==typeof n)if(e<2)this.fromInt(1);else{this.fromNumber(e,r),this.testBit(e-1)||this.bitwiseTo(t.ONE.shiftLeft(e-1),s,this),this.isEven()&&this.dAddOffset(1,0);var o=this,a=function(){o.dAddOffset(2,0),o.bitLength()>e&&o.subTo(t.ONE.shiftLeft(e-1),o),o.isProbablePrime(n)?setTimeout((function(){i()}),0):setTimeout(a,0)};setTimeout(a,0)}else{var c=[],u=7&e;c.length=1+(e>>3),n.nextBytes(c),u>0?c[0]&=(1<<u)-1:c[0]=0,this.fromString(c,256)}},t}(),A=function(){function t(){}return t.prototype.convert=function(t){return t},t.prototype.revert=function(t){return t},t.prototype.mulTo=function(t,e,n){t.multiplyTo(e,n)},t.prototype.sqrTo=function(t,e){t.squareTo(e)},t}(),k=function(){function t(t){this.m=t}return t.prototype.convert=function(t){return t.s<0||t.compareTo(this.m)>=0?t.mod(this.m):t},t.prototype.revert=function(t){return t},t.prototype.reduce=function(t){t.divRemTo(this.m,null,t)},t.prototype.mulTo=function(t,e,n){t.multiplyTo(e,n),this.reduce(n)},t.prototype.sqrTo=function(t,e){t.squareTo(e),this.reduce(e)},t}(),O=function(){function t(t){this.m=t,this.mp=t.invDigit(),this.mpl=32767&this.mp,this.mph=this.mp>>15,this.um=(1<<t.DB-15)-1,this.mt2=2*t.t}return t.prototype.convert=function(t){var e=P();return t.abs().dlShiftTo(this.m.t,e),e.divRemTo(this.m,null,e),t.s<0&&e.compareTo(D.ZERO)>0&&this.m.subTo(e,e),e},t.prototype.revert=function(t){var e=P();return t.copyTo(e),this.reduce(e),e},t.prototype.reduce=function(t){for(;t.t<=this.mt2;)t[t.t++]=0;for(var e=0;e<this.m.t;++e){var n=32767&t[e],r=n*this.mpl+((n*this.mph+(t[e]>>15)*this.mpl&this.um)<<15)&t.DM;for(t[n=e+this.m.t]+=this.m.am(0,r,t,e,0,this.m.t);t[n]>=t.DV;)t[n]-=t.DV,t[++n]++}t.clamp(),t.drShiftTo(this.m.t,t),t.compareTo(this.m)>=0&&t.subTo(this.m,t)},t.prototype.mulTo=function(t,e,n){t.multiplyTo(e,n),this.reduce(n)},t.prototype.sqrTo=function(t,e){t.squareTo(e),this.reduce(e)},t}(),R=function(){function t(t){this.m=t,this.r2=P(),this.q3=P(),D.ONE.dlShiftTo(2*t.t,this.r2),this.mu=this.r2.divide(t)}return t.prototype.convert=function(t){if(t.s<0||t.t>2*this.m.t)return t.mod(this.m);if(t.compareTo(this.m)<0)return t;var e=P();return t.copyTo(e),this.reduce(e),e},t.prototype.revert=function(t){return t},t.prototype.reduce=function(t){for(t.drShiftTo(this.m.t-1,this.r2),t.t>this.m.t+1&&(t.t=this.m.t+1,t.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);t.compareTo(this.r2)<0;)t.dAddOffset(1,this.m.t+1);for(t.subTo(this.r2,t);t.compareTo(this.m)>=0;)t.subTo(this.m,t)},t.prototype.mulTo=function(t,e,n){t.multiplyTo(e,n),this.reduce(n)},t.prototype.sqrTo=function(t,e){t.squareTo(e),this.reduce(e)},t}();function P(){return new D(null)}function M(t,e){return new D(t,e)}var C="undefined"!=typeof navigator;C&&"Microsoft Internet Explorer"==navigator.appName?(D.prototype.am=function(t,e,n,r,i,s){for(var o=32767&e,a=e>>15;--s>=0;){var c=32767&this[t],u=this[t++]>>15,l=a*c+u*o;i=((c=o*c+((32767&l)<<15)+n[r]+(1073741823&i))>>>30)+(l>>>15)+a*u+(i>>>30),n[r++]=1073741823&c}return i},S=30):C&&"Netscape"!=navigator.appName?(D.prototype.am=function(t,e,n,r,i,s){for(;--s>=0;){var o=e*this[t++]+n[r]+i;i=Math.floor(o/67108864),n[r++]=67108863&o}return i},S=26):(D.prototype.am=function(t,e,n,r,i,s){for(var o=16383&e,a=e>>14;--s>=0;){var c=16383&this[t],u=this[t++]>>14,l=a*c+u*o;i=((c=o*c+((16383&l)<<14)+n[r]+i)>>28)+(l>>14)+a*u,n[r++]=268435455&c}return i},S=28),D.prototype.DB=S,D.prototype.DM=(1<<S)-1,D.prototype.DV=1<<S,D.prototype.FV=Math.pow(2,52),D.prototype.F1=52-S,D.prototype.F2=2*S-52;var B,N,L=[];for(B="0".charCodeAt(0),N=0;N<=9;++N)L[B++]=N;for(B="a".charCodeAt(0),N=10;N<36;++N)L[B++]=N;for(B="A".charCodeAt(0),N=10;N<36;++N)L[B++]=N;function j(t,e){var n=L[t.charCodeAt(e)];return null==n?-1:n}function V(t){var e=P();return e.fromInt(t),e}function U(t){var e,n=1;return 0!=(e=t>>>16)&&(t=e,n+=16),0!=(e=t>>8)&&(t=e,n+=8),0!=(e=t>>4)&&(t=e,n+=4),0!=(e=t>>2)&&(t=e,n+=2),0!=(e=t>>1)&&(t=e,n+=1),n}D.ZERO=V(0),D.ONE=V(1);var $,H,q=function(){function t(){this.i=0,this.j=0,this.S=[]}return t.prototype.init=function(t){var e,n,r;for(e=0;e<256;++e)this.S[e]=e;for(n=0,e=0;e<256;++e)n=n+this.S[e]+t[e%t.length]&255,r=this.S[e],this.S[e]=this.S[n],this.S[n]=r;this.i=0,this.j=0},t.prototype.next=function(){var t;return this.i=this.i+1&255,this.j=this.j+this.S[this.i]&255,t=this.S[this.i],this.S[this.i]=this.S[this.j],this.S[this.j]=t,this.S[t+this.S[this.i]&255]},t}(),F=null;function K(){if(null==$){for($=new q;H<256;){var t=Math.floor(65536*Math.random());F[H++]=255&t}for($.init(F),H=0;H<F.length;++H)F[H]=0;H=0}return $.next()}null==F&&(F=[],H=0);var z=function(){function t(){}return t.prototype.nextBytes=function(t){for(var e=0;e<t.length;++e)t[e]=K()},t}(),W=function(){function t(){this.n=null,this.e=0,this.d=null,this.p=null,this.q=null,this.dmp1=null,this.dmq1=null,this.coeff=null}return t.prototype.doPublic=function(t){return t.modPowInt(this.e,this.n)},t.prototype.doPrivate=function(t){if(null==this.p||null==this.q)return t.modPow(this.d,this.n);for(var e=t.mod(this.p).modPow(this.dmp1,this.p),n=t.mod(this.q).modPow(this.dmq1,this.q);e.compareTo(n)<0;)e=e.add(this.p);return e.subtract(n).multiply(this.coeff).mod(this.p).multiply(this.q).add(n)},t.prototype.setPublic=function(t,e){null!=t&&null!=e&&t.length>0&&e.length>0?(this.n=M(t,16),this.e=parseInt(e,16)):console.error("Invalid RSA public key")},t.prototype.encrypt=function(t){var e=this.n.bitLength()+7>>3,n=function(t,e){if(e<t.length+11)return console.error("Message too long for RSA"),null;for(var n=[],r=t.length-1;r>=0&&e>0;){var i=t.charCodeAt(r--);i<128?n[--e]=i:i>127&&i<2048?(n[--e]=63&i|128,n[--e]=i>>6|192):(n[--e]=63&i|128,n[--e]=i>>6&63|128,n[--e]=i>>12|224)}n[--e]=0;for(var s=new z,o=[];e>2;){for(o[0]=0;0==o[0];)s.nextBytes(o);n[--e]=o[0]}return n[--e]=2,n[--e]=0,new D(n)}(t,e);if(null==n)return null;var r=this.doPublic(n);if(null==r)return null;for(var i=r.toString(16),s=i.length,o=0;o<2*e-s;o++)i="0"+i;return i},t.prototype.setPrivate=function(t,e,n){null!=t&&null!=e&&t.length>0&&e.length>0?(this.n=M(t,16),this.e=parseInt(e,16),this.d=M(n,16)):console.error("Invalid RSA private key")},t.prototype.setPrivateEx=function(t,e,n,r,i,s,o,a){null!=t&&null!=e&&t.length>0&&e.length>0?(this.n=M(t,16),this.e=parseInt(e,16),this.d=M(n,16),this.p=M(r,16),this.q=M(i,16),this.dmp1=M(s,16),this.dmq1=M(o,16),this.coeff=M(a,16)):console.error("Invalid RSA private key")},t.prototype.generate=function(t,e){var n=new z,r=t>>1;this.e=parseInt(e,16);for(var i=new D(e,16);;){for(;this.p=new D(t-r,1,n),0!=this.p.subtract(D.ONE).gcd(i).compareTo(D.ONE)||!this.p.isProbablePrime(10););for(;this.q=new D(r,1,n),0!=this.q.subtract(D.ONE).gcd(i).compareTo(D.ONE)||!this.q.isProbablePrime(10););if(this.p.compareTo(this.q)<=0){var s=this.p;this.p=this.q,this.q=s}var o=this.p.subtract(D.ONE),a=this.q.subtract(D.ONE),c=o.multiply(a);if(0==c.gcd(i).compareTo(D.ONE)){this.n=this.p.multiply(this.q),this.d=i.modInverse(c),this.dmp1=this.d.mod(o),this.dmq1=this.d.mod(a),this.coeff=this.q.modInverse(this.p);break}}},t.prototype.decrypt=function(t){var e=M(t,16),n=this.doPrivate(e);return null==n?null:function(t,e){for(var n=t.toByteArray(),r=0;r<n.length&&0==n[r];)++r;if(n.length-r!=e-1||2!=n[r])return null;for(++r;0!=n[r];)if(++r>=n.length)return null;for(var i="";++r<n.length;){var s=255&n[r];s<128?i+=String.fromCharCode(s):s>191&&s<224?(i+=String.fromCharCode((31&s)<<6|63&n[r+1]),++r):(i+=String.fromCharCode((15&s)<<12|(63&n[r+1])<<6|63&n[r+2]),r+=2)}return i}(n,this.n.bitLength()+7>>3)},t.prototype.generateAsync=function(t,e,n){var r=new z,i=t>>1;this.e=parseInt(e,16);var s=new D(e,16),o=this,a=function(){var e=function(){if(o.p.compareTo(o.q)<=0){var t=o.p;o.p=o.q,o.q=t}var e=o.p.subtract(D.ONE),r=o.q.subtract(D.ONE),i=e.multiply(r);0==i.gcd(s).compareTo(D.ONE)?(o.n=o.p.multiply(o.q),o.d=s.modInverse(i),o.dmp1=o.d.mod(e),o.dmq1=o.d.mod(r),o.coeff=o.q.modInverse(o.p),setTimeout((function(){n()}),0)):setTimeout(a,0)},c=function(){o.q=P(),o.q.fromNumberAsync(i,1,r,(function(){o.q.subtract(D.ONE).gcda(s,(function(t){0==t.compareTo(D.ONE)&&o.q.isProbablePrime(10)?setTimeout(e,0):setTimeout(c,0)}))}))},u=function(){o.p=P(),o.p.fromNumberAsync(t-i,1,r,(function(){o.p.subtract(D.ONE).gcda(s,(function(t){0==t.compareTo(D.ONE)&&o.p.isProbablePrime(10)?setTimeout(c,0):setTimeout(u,0)}))}))};setTimeout(u,0)};setTimeout(a,0)},t.prototype.sign=function(t,e,n){var r=function(t){return J[t]||""}(n),i=function(t,e){if(e<t.length+22)return console.error("Message too long for RSA"),null;for(var n=e-t.length-6,r="",i=0;i<n;i+=2)r+="ff";return M("0001"+r+"00"+t,16)}(r+e(t).toString(),this.n.bitLength()/4);if(null==i)return null;var s=this.doPrivate(i);if(null==s)return null;var o=s.toString(16);return 0==(1&o.length)?o:"0"+o},t.prototype.verify=function(t,e,n){var r=M(e,16),i=this.doPublic(r);if(null==i)return null;var s=function(t){for(var e in J)if(J.hasOwnProperty(e)){var n=J[e],r=n.length;if(t.substr(0,r)==n)return t.substr(r)}return t}(i.toString(16).replace(/^1f+00/,""));return s==n(t).toString()},t.prototype.encryptLong=function(t){var e=this,n="",r=(this.n.bitLength()+7>>3)-11;return this.setSplitChn(t,r).forEach((function(t){n+=e.encrypt(t)})),n},t.prototype.decryptLong=function(t){var e="",n=this.n.bitLength()+7>>3,r=2*n;if(t.length>r){for(var i=t.match(new RegExp(".{1,"+r+"}","g"))||[],s=[],o=0;o<i.length;o++){var a=M(i[o],16),c=this.doPrivate(a);if(null==c)return null;s.push(c)}e=function(t,e){for(var n=[],r=0;r<t.length;r++){for(var i=t[r].toByteArray(),s=0;s<i.length&&0==i[s];)++s;if(i.length-s!=e-1||2!=i[s])return null;for(++s;0!=i[s];)if(++s>=i.length)return null;n=n.concat(i.slice(s+1))}for(var o=n,a=-1,c="";++a<o.length;){var u=255&o[a];u<128?c+=String.fromCharCode(u):u>191&&u<224?(c+=String.fromCharCode((31&u)<<6|63&o[a+1]),++a):(c+=String.fromCharCode((15&u)<<12|(63&o[a+1])<<6|63&o[a+2]),a+=2)}return c}(s,n)}else e=this.decrypt(t);return e},t.prototype.setSplitChn=function(t,e,n){void 0===n&&(n=[]);for(var r=t.split(""),i=0,s=0;s<r.length;s++){var o=r[s].charCodeAt(0);if((i+=o<=127?1:o<=2047?2:o<=65535?3:4)>e){var a=t.substring(0,s);return n.push(a),this.setSplitChn(t.substring(s),e,n)}}return n.push(t),n},t}(),J={md2:"3020300c06082a864886f70d020205000410",md5:"3020300c06082a864886f70d020505000410",sha1:"3021300906052b0e03021a05000414",sha224:"302d300d06096086480165030402040500041c",sha256:"3031300d060960864801650304020105000420",sha384:"3041300d060960864801650304020205000430",sha512:"3051300d060960864801650304020305000440",ripemd160:"3021300906052b2403020105000414"},G={};G.lang={extend:function(t,e,n){if(!e||!t)throw new Error("YAHOO.lang.extend failed, please check that all dependencies are included.");var r=function(){};if(r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t,t.superclass=e.prototype,e.prototype.constructor==Object.prototype.constructor&&(e.prototype.constructor=e),n){var i;for(i in n)t.prototype[i]=n[i];var s=function(){},o=["toString","valueOf"];try{/MSIE/.test(navigator.userAgent)&&(s=function(t,e){for(i=0;i<o.length;i+=1){var n=o[i],r=e[n];"function"==typeof r&&r!=Object.prototype[n]&&(t[n]=r)}})}catch(a){}s(t.prototype,n)}}};var Y={};void 0!==Y.asn1&&Y.asn1||(Y.asn1={}),Y.asn1.ASN1Util=new function(){this.integerToByteHex=function(t){var e=t.toString(16);return e.length%2==1&&(e="0"+e),e},this.bigIntToMinTwosComplementsHex=function(t){var e=t.toString(16);if("-"!=e.substr(0,1))e.length%2==1?e="0"+e:e.match(/^[0-7]/)||(e="00"+e);else{var n=e.substr(1).length;n%2==1?n+=1:e.match(/^[0-7]/)||(n+=2);for(var r="",i=0;i<n;i++)r+="f";e=new D(r,16).xor(t).add(D.ONE).toString(16).replace(/^-/,"")}return e},this.getPEMStringFromHex=function(t,e){return hextopem(t,e)},this.newObject=function(t){var e=Y.asn1,n=e.DERBoolean,r=e.DERInteger,i=e.DERBitString,s=e.DEROctetString,o=e.DERNull,a=e.DERObjectIdentifier,c=e.DEREnumerated,u=e.DERUTF8String,l=e.DERNumericString,h=e.DERPrintableString,f=e.DERTeletexString,d=e.DERIA5String,p=e.DERUTCTime,g=e.DERGeneralizedTime,m=e.DERSequence,y=e.DERSet,v=e.DERTaggedObject,_=e.ASN1Util.newObject,w=Object.keys(t);if(1!=w.length)throw"key of param shall be only one.";var S=w[0];if(-1==":bool:int:bitstr:octstr:null:oid:enum:utf8str:numstr:prnstr:telstr:ia5str:utctime:gentime:seq:set:tag:".indexOf(":"+S+":"))throw"undefined key: "+S;if("bool"==S)return new n(t[S]);if("int"==S)return new r(t[S]);if("bitstr"==S)return new i(t[S]);if("octstr"==S)return new s(t[S]);if("null"==S)return new o(t[S]);if("oid"==S)return new a(t[S]);if("enum"==S)return new c(t[S]);if("utf8str"==S)return new u(t[S]);if("numstr"==S)return new l(t[S]);if("prnstr"==S)return new h(t[S]);if("telstr"==S)return new f(t[S]);if("ia5str"==S)return new d(t[S]);if("utctime"==S)return new p(t[S]);if("gentime"==S)return new g(t[S]);if("seq"==S){for(var b=t[S],E=[],T=0;T<b.length;T++){var x=_(b[T]);E.push(x)}return new m({array:E})}if("set"==S){for(b=t[S],E=[],T=0;T<b.length;T++)x=_(b[T]),E.push(x);return new y({array:E})}if("tag"==S){var I=t[S];if("[object Array]"===Object.prototype.toString.call(I)&&3==I.length){var D=_(I[2]);return new v({tag:I[0],explicit:I[1],obj:D})}var A={};if(void 0!==I.explicit&&(A.explicit=I.explicit),void 0!==I.tag&&(A.tag=I.tag),void 0===I.obj)throw"obj shall be specified for 'tag'.";return A.obj=_(I.obj),new v(A)}},this.jsonToASN1HEX=function(t){return this.newObject(t).getEncodedHex()}},Y.asn1.ASN1Util.oidHexToInt=function(t){for(var e="",n=parseInt(t.substr(0,2),16),r=(e=Math.floor(n/40)+"."+n%40,""),i=2;i<t.length;i+=2){var s=("00000000"+parseInt(t.substr(i,2),16).toString(2)).slice(-8);r+=s.substr(1,7),"0"==s.substr(0,1)&&(e=e+"."+new D(r,2).toString(10),r="")}return e},Y.asn1.ASN1Util.oidIntToHex=function(t){var e=function(t){var e=t.toString(16);return 1==e.length&&(e="0"+e),e},n=function(t){var n="",r=new D(t,10).toString(2),i=7-r.length%7;7==i&&(i=0);for(var s="",o=0;o<i;o++)s+="0";for(r=s+r,o=0;o<r.length-1;o+=7){var a=r.substr(o,7);o!=r.length-7&&(a="1"+a),n+=e(parseInt(a,2))}return n};if(!t.match(/^[0-9.]+$/))throw"malformed oid string: "+t;var r="",i=t.split("."),s=40*parseInt(i[0])+parseInt(i[1]);r+=e(s),i.splice(0,2);for(var o=0;o<i.length;o++)r+=n(i[o]);return r},Y.asn1.ASN1Object=function(){this.getLengthHexFromValue=function(){if(void 0===this.hV||null==this.hV)throw"this.hV is null or undefined.";if(this.hV.length%2==1)throw"value hex must be even length: n="+"".length+",v="+this.hV;var t=this.hV.length/2,e=t.toString(16);if(e.length%2==1&&(e="0"+e),t<128)return e;var n=e.length/2;if(n>15)throw"ASN.1 length too long to represent by 8x: n = "+t.toString(16);return(128+n).toString(16)+e},this.getEncodedHex=function(){return(null==this.hTLV||this.isModified)&&(this.hV=this.getFreshValueHex(),this.hL=this.getLengthHexFromValue(),this.hTLV=this.hT+this.hL+this.hV,this.isModified=!1),this.hTLV},this.getValueHex=function(){return this.getEncodedHex(),this.hV},this.getFreshValueHex=function(){return""}},Y.asn1.DERAbstractString=function(t){Y.asn1.DERAbstractString.superclass.constructor.call(this),this.getString=function(){return this.s},this.setString=function(t){this.hTLV=null,this.isModified=!0,this.s=t,this.hV=stohex(this.s)},this.setStringHex=function(t){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=t},this.getFreshValueHex=function(){return this.hV},void 0!==t&&("string"==typeof t?this.setString(t):void 0!==t.str?this.setString(t.str):void 0!==t.hex&&this.setStringHex(t.hex))},G.lang.extend(Y.asn1.DERAbstractString,Y.asn1.ASN1Object),Y.asn1.DERAbstractTime=function(t){Y.asn1.DERAbstractTime.superclass.constructor.call(this),this.localDateToUTC=function(t){return utc=t.getTime()+6e4*t.getTimezoneOffset(),new Date(utc)},this.formatDate=function(t,e,n){var r=this.zeroPadding,i=this.localDateToUTC(t),s=String(i.getFullYear());"utc"==e&&(s=s.substr(2,2));var o=s+r(String(i.getMonth()+1),2)+r(String(i.getDate()),2)+r(String(i.getHours()),2)+r(String(i.getMinutes()),2)+r(String(i.getSeconds()),2);if(!0===n){var a=i.getMilliseconds();if(0!=a){var c=r(String(a),3);o=o+"."+(c=c.replace(/[0]+$/,""))}}return o+"Z"},this.zeroPadding=function(t,e){return t.length>=e?t:new Array(e-t.length+1).join("0")+t},this.getString=function(){return this.s},this.setString=function(t){this.hTLV=null,this.isModified=!0,this.s=t,this.hV=stohex(t)},this.setByDateValue=function(t,e,n,r,i,s){var o=new Date(Date.UTC(t,e-1,n,r,i,s,0));this.setByDate(o)},this.getFreshValueHex=function(){return this.hV}},G.lang.extend(Y.asn1.DERAbstractTime,Y.asn1.ASN1Object),Y.asn1.DERAbstractStructured=function(t){Y.asn1.DERAbstractString.superclass.constructor.call(this),this.setByASN1ObjectArray=function(t){this.hTLV=null,this.isModified=!0,this.asn1Array=t},this.appendASN1Object=function(t){this.hTLV=null,this.isModified=!0,this.asn1Array.push(t)},this.asn1Array=new Array,void 0!==t&&void 0!==t.array&&(this.asn1Array=t.array)},G.lang.extend(Y.asn1.DERAbstractStructured,Y.asn1.ASN1Object),Y.asn1.DERBoolean=function(){Y.asn1.DERBoolean.superclass.constructor.call(this),this.hT="01",this.hTLV="0101ff"},G.lang.extend(Y.asn1.DERBoolean,Y.asn1.ASN1Object),Y.asn1.DERInteger=function(t){Y.asn1.DERInteger.superclass.constructor.call(this),this.hT="02",this.setByBigInteger=function(t){this.hTLV=null,this.isModified=!0,this.hV=Y.asn1.ASN1Util.bigIntToMinTwosComplementsHex(t)},this.setByInteger=function(t){var e=new D(String(t),10);this.setByBigInteger(e)},this.setValueHex=function(t){this.hV=t},this.getFreshValueHex=function(){return this.hV},void 0!==t&&(void 0!==t.bigint?this.setByBigInteger(t.bigint):void 0!==t.int?this.setByInteger(t.int):"number"==typeof t?this.setByInteger(t):void 0!==t.hex&&this.setValueHex(t.hex))},G.lang.extend(Y.asn1.DERInteger,Y.asn1.ASN1Object),Y.asn1.DERBitString=function(t){if(void 0!==t&&void 0!==t.obj){var e=Y.asn1.ASN1Util.newObject(t.obj);t.hex="00"+e.getEncodedHex()}Y.asn1.DERBitString.superclass.constructor.call(this),this.hT="03",this.setHexValueIncludingUnusedBits=function(t){this.hTLV=null,this.isModified=!0,this.hV=t},this.setUnusedBitsAndHexValue=function(t,e){if(t<0||7<t)throw"unused bits shall be from 0 to 7: u = "+t;var n="0"+t;this.hTLV=null,this.isModified=!0,this.hV=n+e},this.setByBinaryString=function(t){var e=8-(t=t.replace(/0+$/,"")).length%8;8==e&&(e=0);for(var n=0;n<=e;n++)t+="0";var r="";for(n=0;n<t.length-1;n+=8){var i=t.substr(n,8),s=parseInt(i,2).toString(16);1==s.length&&(s="0"+s),r+=s}this.hTLV=null,this.isModified=!0,this.hV="0"+e+r},this.setByBooleanArray=function(t){for(var e="",n=0;n<t.length;n++)1==t[n]?e+="1":e+="0";this.setByBinaryString(e)},this.newFalseArray=function(t){for(var e=new Array(t),n=0;n<t;n++)e[n]=!1;return e},this.getFreshValueHex=function(){return this.hV},void 0!==t&&("string"==typeof t&&t.toLowerCase().match(/^[0-9a-f]+$/)?this.setHexValueIncludingUnusedBits(t):void 0!==t.hex?this.setHexValueIncludingUnusedBits(t.hex):void 0!==t.bin?this.setByBinaryString(t.bin):void 0!==t.array&&this.setByBooleanArray(t.array))},G.lang.extend(Y.asn1.DERBitString,Y.asn1.ASN1Object),Y.asn1.DEROctetString=function(t){if(void 0!==t&&void 0!==t.obj){var e=Y.asn1.ASN1Util.newObject(t.obj);t.hex=e.getEncodedHex()}Y.asn1.DEROctetString.superclass.constructor.call(this,t),this.hT="04"},G.lang.extend(Y.asn1.DEROctetString,Y.asn1.DERAbstractString),Y.asn1.DERNull=function(){Y.asn1.DERNull.superclass.constructor.call(this),this.hT="05",this.hTLV="0500"},G.lang.extend(Y.asn1.DERNull,Y.asn1.ASN1Object),Y.asn1.DERObjectIdentifier=function(t){var e=function(t){var e=t.toString(16);return 1==e.length&&(e="0"+e),e},n=function(t){var n="",r=new D(t,10).toString(2),i=7-r.length%7;7==i&&(i=0);for(var s="",o=0;o<i;o++)s+="0";for(r=s+r,o=0;o<r.length-1;o+=7){var a=r.substr(o,7);o!=r.length-7&&(a="1"+a),n+=e(parseInt(a,2))}return n};Y.asn1.DERObjectIdentifier.superclass.constructor.call(this),this.hT="06",this.setValueHex=function(t){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=t},this.setValueOidString=function(t){if(!t.match(/^[0-9.]+$/))throw"malformed oid string: "+t;var r="",i=t.split("."),s=40*parseInt(i[0])+parseInt(i[1]);r+=e(s),i.splice(0,2);for(var o=0;o<i.length;o++)r+=n(i[o]);this.hTLV=null,this.isModified=!0,this.s=null,this.hV=r},this.setValueName=function(t){var e=Y.asn1.x509.OID.name2oid(t);if(""===e)throw"DERObjectIdentifier oidName undefined: "+t;this.setValueOidString(e)},this.getFreshValueHex=function(){return this.hV},void 0!==t&&("string"==typeof t?t.match(/^[0-2].[0-9.]+$/)?this.setValueOidString(t):this.setValueName(t):void 0!==t.oid?this.setValueOidString(t.oid):void 0!==t.hex?this.setValueHex(t.hex):void 0!==t.name&&this.setValueName(t.name))},G.lang.extend(Y.asn1.DERObjectIdentifier,Y.asn1.ASN1Object),Y.asn1.DEREnumerated=function(t){Y.asn1.DEREnumerated.superclass.constructor.call(this),this.hT="0a",this.setByBigInteger=function(t){this.hTLV=null,this.isModified=!0,this.hV=Y.asn1.ASN1Util.bigIntToMinTwosComplementsHex(t)},this.setByInteger=function(t){var e=new D(String(t),10);this.setByBigInteger(e)},this.setValueHex=function(t){this.hV=t},this.getFreshValueHex=function(){return this.hV},void 0!==t&&(void 0!==t.int?this.setByInteger(t.int):"number"==typeof t?this.setByInteger(t):void 0!==t.hex&&this.setValueHex(t.hex))},G.lang.extend(Y.asn1.DEREnumerated,Y.asn1.ASN1Object),Y.asn1.DERUTF8String=function(t){Y.asn1.DERUTF8String.superclass.constructor.call(this,t),this.hT="0c"},G.lang.extend(Y.asn1.DERUTF8String,Y.asn1.DERAbstractString),Y.asn1.DERNumericString=function(t){Y.asn1.DERNumericString.superclass.constructor.call(this,t),this.hT="12"},G.lang.extend(Y.asn1.DERNumericString,Y.asn1.DERAbstractString),Y.asn1.DERPrintableString=function(t){Y.asn1.DERPrintableString.superclass.constructor.call(this,t),this.hT="13"},G.lang.extend(Y.asn1.DERPrintableString,Y.asn1.DERAbstractString),Y.asn1.DERTeletexString=function(t){Y.asn1.DERTeletexString.superclass.constructor.call(this,t),this.hT="14"},G.lang.extend(Y.asn1.DERTeletexString,Y.asn1.DERAbstractString),Y.asn1.DERIA5String=function(t){Y.asn1.DERIA5String.superclass.constructor.call(this,t),this.hT="16"},G.lang.extend(Y.asn1.DERIA5String,Y.asn1.DERAbstractString),Y.asn1.DERUTCTime=function(t){Y.asn1.DERUTCTime.superclass.constructor.call(this,t),this.hT="17",this.setByDate=function(t){this.hTLV=null,this.isModified=!0,this.date=t,this.s=this.formatDate(this.date,"utc"),this.hV=stohex(this.s)},this.getFreshValueHex=function(){return void 0===this.date&&void 0===this.s&&(this.date=new Date,this.s=this.formatDate(this.date,"utc"),this.hV=stohex(this.s)),this.hV},void 0!==t&&(void 0!==t.str?this.setString(t.str):"string"==typeof t&&t.match(/^[0-9]{12}Z$/)?this.setString(t):void 0!==t.hex?this.setStringHex(t.hex):void 0!==t.date&&this.setByDate(t.date))},G.lang.extend(Y.asn1.DERUTCTime,Y.asn1.DERAbstractTime),Y.asn1.DERGeneralizedTime=function(t){Y.asn1.DERGeneralizedTime.superclass.constructor.call(this,t),this.hT="18",this.withMillis=!1,this.setByDate=function(t){this.hTLV=null,this.isModified=!0,this.date=t,this.s=this.formatDate(this.date,"gen",this.withMillis),this.hV=stohex(this.s)},this.getFreshValueHex=function(){return void 0===this.date&&void 0===this.s&&(this.date=new Date,this.s=this.formatDate(this.date,"gen",this.withMillis),this.hV=stohex(this.s)),this.hV},void 0!==t&&(void 0!==t.str?this.setString(t.str):"string"==typeof t&&t.match(/^[0-9]{14}Z$/)?this.setString(t):void 0!==t.hex?this.setStringHex(t.hex):void 0!==t.date&&this.setByDate(t.date),!0===t.millis&&(this.withMillis=!0))},G.lang.extend(Y.asn1.DERGeneralizedTime,Y.asn1.DERAbstractTime),Y.asn1.DERSequence=function(t){Y.asn1.DERSequence.superclass.constructor.call(this,t),this.hT="30",this.getFreshValueHex=function(){for(var t="",e=0;e<this.asn1Array.length;e++)t+=this.asn1Array[e].getEncodedHex();return this.hV=t,this.hV}},G.lang.extend(Y.asn1.DERSequence,Y.asn1.DERAbstractStructured),Y.asn1.DERSet=function(t){Y.asn1.DERSet.superclass.constructor.call(this,t),this.hT="31",this.sortFlag=!0,this.getFreshValueHex=function(){for(var t=new Array,e=0;e<this.asn1Array.length;e++){var n=this.asn1Array[e];t.push(n.getEncodedHex())}return 1==this.sortFlag&&t.sort(),this.hV=t.join(""),this.hV},void 0!==t&&void 0!==t.sortflag&&0==t.sortflag&&(this.sortFlag=!1)},G.lang.extend(Y.asn1.DERSet,Y.asn1.DERAbstractStructured),Y.asn1.DERTaggedObject=function(t){Y.asn1.DERTaggedObject.superclass.constructor.call(this),this.hT="a0",this.hV="",this.isExplicit=!0,this.asn1Object=null,this.setASN1Object=function(t,e,n){this.hT=e,this.isExplicit=t,this.asn1Object=n,this.isExplicit?(this.hV=this.asn1Object.getEncodedHex(),this.hTLV=null,this.isModified=!0):(this.hV=null,this.hTLV=n.getEncodedHex(),this.hTLV=this.hTLV.replace(/^../,e),this.isModified=!1)},this.getFreshValueHex=function(){return this.hV},void 0!==t&&(void 0!==t.tag&&(this.hT=t.tag),void 0!==t.explicit&&(this.isExplicit=t.explicit),void 0!==t.obj&&(this.asn1Object=t.obj,this.setASN1Object(this.isExplicit,this.hT,this.asn1Object)))},G.lang.extend(Y.asn1.DERTaggedObject,Y.asn1.ASN1Object);var Z=function(){var t=function(e,n){return(t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(e,n)};return function(e,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),X=function(t){function e(n){var r=t.call(this)||this;return n&&("string"==typeof n?r.parseKey(n):(e.hasPrivateKeyProperty(n)||e.hasPublicKeyProperty(n))&&r.parsePropertiesFrom(n)),r}return Z(e,t),e.prototype.parseKey=function(t){try{var e=0,n=0,r=/^\s*(?:[0-9A-Fa-f][0-9A-Fa-f]\s*)+$/.test(t)?p(t):g.unarmor(t),i=E.decode(r);if(3===i.sub.length&&(i=i.sub[2].sub[0]),9===i.sub.length){e=i.sub[1].getHexStringValue(),this.n=M(e,16),n=i.sub[2].getHexStringValue(),this.e=parseInt(n,16);var s=i.sub[3].getHexStringValue();this.d=M(s,16);var o=i.sub[4].getHexStringValue();this.p=M(o,16);var a=i.sub[5].getHexStringValue();this.q=M(a,16);var c=i.sub[6].getHexStringValue();this.dmp1=M(c,16);var u=i.sub[7].getHexStringValue();this.dmq1=M(u,16);var l=i.sub[8].getHexStringValue();this.coeff=M(l,16)}else{if(2!==i.sub.length)return!1;var h=i.sub[1].sub[0];e=h.sub[0].getHexStringValue(),this.n=M(e,16),n=h.sub[1].getHexStringValue(),this.e=parseInt(n,16)}return!0}catch(f){return!1}},e.prototype.getPrivateBaseKey=function(){var t={array:[new Y.asn1.DERInteger({int:0}),new Y.asn1.DERInteger({bigint:this.n}),new Y.asn1.DERInteger({int:this.e}),new Y.asn1.DERInteger({bigint:this.d}),new Y.asn1.DERInteger({bigint:this.p}),new Y.asn1.DERInteger({bigint:this.q}),new Y.asn1.DERInteger({bigint:this.dmp1}),new Y.asn1.DERInteger({bigint:this.dmq1}),new Y.asn1.DERInteger({bigint:this.coeff})]};return new Y.asn1.DERSequence(t).getEncodedHex()},e.prototype.getPrivateBaseKeyB64=function(){return f(this.getPrivateBaseKey())},e.prototype.getPublicBaseKey=function(){var t=new Y.asn1.DERSequence({array:[new Y.asn1.DERObjectIdentifier({oid:"1.2.840.113549.1.1.1"}),new Y.asn1.DERNull]}),e=new Y.asn1.DERSequence({array:[new Y.asn1.DERInteger({bigint:this.n}),new Y.asn1.DERInteger({int:this.e})]}),n=new Y.asn1.DERBitString({hex:"00"+e.getEncodedHex()});return new Y.asn1.DERSequence({array:[t,n]}).getEncodedHex()},e.prototype.getPublicBaseKeyB64=function(){return f(this.getPublicBaseKey())},e.wordwrap=function(t,e){if(!t)return t;var n="(.{1,"+(e=e||64)+"})( +|$\n?)|(.{1,"+e+"})";return t.match(RegExp(n,"g")).join("\n")},e.prototype.getPrivateKey=function(){var t="-----BEGIN RSA PRIVATE KEY-----\n";return t+=e.wordwrap(this.getPrivateBaseKeyB64())+"\n",t+="-----END RSA PRIVATE KEY-----"},e.prototype.getPublicKey=function(){var t="-----BEGIN PUBLIC KEY-----\n";return t+=e.wordwrap(this.getPublicBaseKeyB64())+"\n",t+="-----END PUBLIC KEY-----"},e.hasPublicKeyProperty=function(t){return(t=t||{}).hasOwnProperty("n")&&t.hasOwnProperty("e")},e.hasPrivateKeyProperty=function(t){return(t=t||{}).hasOwnProperty("n")&&t.hasOwnProperty("e")&&t.hasOwnProperty("d")&&t.hasOwnProperty("p")&&t.hasOwnProperty("q")&&t.hasOwnProperty("dmp1")&&t.hasOwnProperty("dmq1")&&t.hasOwnProperty("coeff")},e.prototype.parsePropertiesFrom=function(t){this.n=t.n,this.e=t.e,t.hasOwnProperty("d")&&(this.d=t.d,this.p=t.p,this.q=t.q,this.dmp1=t.dmp1,this.dmq1=t.dmq1,this.coeff=t.coeff)},e}(W);const Q="3.2.1";var tt=function(){function t(t){void 0===t&&(t={}),t=t||{},this.default_key_size=t.default_key_size?parseInt(t.default_key_size,10):1024,this.default_public_exponent=t.default_public_exponent||"010001",this.log=t.log||!1,this.key=null}return t.prototype.setKey=function(t){this.log&&this.key&&console.warn("A key was already set, overriding existing."),this.key=new X(t)},t.prototype.setPrivateKey=function(t){this.setKey(t)},t.prototype.setPublicKey=function(t){this.setKey(t)},t.prototype.decrypt=function(t){try{return this.getKey().decrypt(t)}catch(e){return!1}},t.prototype.encrypt=function(t){try{return this.getKey().encrypt(t)}catch(e){return!1}},t.prototype.encryptLong=function(t){try{return f(this.getKey().encryptLong(t))}catch(e){return!1}},t.prototype.decryptLong=function(t){try{return this.getKey().decryptLong(t)}catch(e){return!1}},t.prototype.sign=function(t,e,n){try{return f(this.getKey().sign(t,e,n))}catch(r){return!1}},t.prototype.verify=function(t,e,n){try{return this.getKey().verify(t,function(t){var e,n="",i=0,s=0;for(e=0;e<t.length&&"="!=t.charAt(e);++e){var o=h.indexOf(t.charAt(e));o<0||(0==i?(n+=r(o>>2),s=3&o,i=1):1==i?(n+=r(s<<2|o>>4),s=15&o,i=2):2==i?(n+=r(s),n+=r(o>>2),s=3&o,i=3):(n+=r(s<<2|o>>4),n+=r(15&o),i=0))}return 1==i&&(n+=r(s<<2)),n}(e),n)}catch(i){return!1}},t.prototype.getKey=function(t){if(!this.key){if(this.key=new X,t&&"[object Function]"==={}.toString.call(t))return void this.key.generateAsync(this.default_key_size,this.default_public_exponent,t);this.key.generate(this.default_key_size,this.default_public_exponent)}return this.key},t.prototype.getPrivateKey=function(){return this.getKey().getPrivateKey()},t.prototype.getPrivateKeyB64=function(){return this.getKey().getPrivateBaseKeyB64()},t.prototype.getPublicKey=function(){return this.getKey().getPublicKey()},t.prototype.getPublicKeyB64=function(){return this.getKey().getPublicBaseKeyB64()},t.version=Q,t}();const et=tt},2480:()=>{}},e={};function n(r){var i=e[r];if(void 0!==i)return i.exports;var s=e[r]={id:r,loaded:!1,exports:{}};return t[r].call(s.exports,s,s.exports,n),s.loaded=!0,s.exports}return n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.nmd=t=>(t.paths=[],t.children||(t.children=[]),t),n(9021)})();var ta=Zo(Qo.exports=Xo());en.invokePushCallback({type:"enabled"});"function"==typeof en.onAppShow&&en.onAppShow((()=>{ta.enableSocket(!0)})),ta.init({appid:"__UNI__65AAA9F",onError:t=>{console.error(t.error);const e={type:"clientId",cid:"",errMsg:t.error};en.invokePushCallback(e)},onClientId:t=>{const e={type:"clientId",cid:t.cid};en.invokePushCallback(e)},onlineState:t=>{const e={type:"lineState",online:t.online};en.invokePushCallback(e)},onPushMsg:t=>{const e={type:"pushMsg",message:t.message};en.invokePushCallback(e)}});const ea=t=>(e,n=cs())=>{!ps&&_i(t,e,n)},na=ea("onShow"),ra=ea("onLaunch"),ia=ea("onLoad"),sa=ea("onReady"),oa=ea("onPullDownRefresh");
/*!
 * pinia v2.1.7
 * (c) 2023 Eduardo San Martin Morote
 * @license MIT
 */
let aa;const ca=t=>aa=t,ua=Symbol();function la(t){return t&&"object"==typeof t&&"[object Object]"===Object.prototype.toString.call(t)&&"function"!=typeof t.toJSON}var ha,fa;(fa=ha||(ha={})).direct="direct",fa.patchObject="patch object",fa.patchFunction="patch function";const da=()=>{};function pa(t,e,n,r=da){t.push(e);const i=()=>{const n=t.indexOf(e);n>-1&&(t.splice(n,1),r())};return!n&&an()&&function(t){nn&&nn.cleanups.push(t)}(i),i}function ga(t,...e){t.slice().forEach((t=>{t(...e)}))}const ma=t=>t();function ya(t,e){t instanceof Map&&e instanceof Map&&e.forEach(((e,n)=>t.set(n,e))),t instanceof Set&&e instanceof Set&&e.forEach(t.add,t);for(const n in e){if(!e.hasOwnProperty(n))continue;const r=e[n],i=t[n];la(i)&&la(r)&&t.hasOwnProperty(n)&&!Tr(r)&&!pr(r)?t[n]=ya(i,r):t[n]=r}return t}const va=Symbol();const{assign:_a}=Object;function wa(t,e,n,r){const{state:i,actions:s,getters:o}=e,a=n.state.value[t];let c;return c=Sa(t,(function(){a||(n.state.value[t]=i?i():{});const e=function(t){const e=h(t)?new Array(t.length):{};for(const n in t)e[n]=Rr(t,n);return e}(n.state.value[t]);return _a(e,s,Object.keys(o||{}).reduce(((e,r)=>(e[r]=vr(vs((()=>{ca(n);const e=n._s.get(t);return o[r].call(e,e)}))),e)),{}))}),e,n,r,!0),c}function Sa(t,e,n={},r,i,s){let o;const a=_a({actions:{}},n),c={deep:!0};let u,l,h,f=[],d=[];const p=r.state.value[t];let g;function m(e){let n;u=l=!1,"function"==typeof e?(e(r.state.value[t]),n={type:ha.patchFunction,storeId:t,events:h}):(ya(r.state.value[t],e),n={type:ha.patchObject,payload:e,storeId:t,events:h});const i=g=Symbol();Kr().then((()=>{g===i&&(u=!0)})),l=!0,ga(f,n,r.state.value[t])}s||p||(r.state.value[t]={}),xr({});const y=s?function(){const{state:t}=n,e=t?t():{};this.$patch((t=>{_a(t,e)}))}:da;function v(e,n){return function(){ca(r);const i=Array.from(arguments),s=[],o=[];function a(t){s.push(t)}function c(t){o.push(t)}let u;ga(d,{args:i,name:e,store:_,after:a,onError:c});try{u=n.apply(this&&this.$id===t?this:_,i)}catch(l){throw ga(o,l),l}return u instanceof Promise?u.then((t=>(ga(s,t),t))).catch((t=>(ga(o,t),Promise.reject(t)))):(ga(s,u),u)}}const _=hr({_p:r,$id:t,$onAction:pa.bind(null,d),$patch:m,$reset:y,$subscribe(e,n={}){const i=pa(f,e,n.detached,(()=>s())),s=o.run((()=>oi((()=>r.state.value[t]),(r=>{("sync"===n.flush?l:u)&&e({storeId:t,type:ha.direct,events:h},r)}),_a({},c,n))));return i},$dispose:function(){o.stop(),f=[],d=[],r._s.delete(t)}});r._s.set(t,_);const w=(r._a&&r._a.runWithContext||ma)((()=>r._e.run((()=>(o=on()).run(e)))));for(const E in w){const e=w[E];if(Tr(e)&&(!Tr(b=e)||!b.effect)||pr(e))s||(!p||la(S=e)&&S.hasOwnProperty(va)||(Tr(e)?e.value=p[E]:ya(e,p[E])),r.state.value[t][E]=e);else if("function"==typeof e){const t=v(E,e);w[E]=t,a.actions[E]=e}}var S,b;return _a(_,w),_a(yr(_),w),Object.defineProperty(_,"$state",{get:()=>r.state.value[t],set:t=>{m((e=>{_a(e,t)}))}}),r._p.forEach((t=>{_a(_,o.run((()=>t({store:_,app:r._a,pinia:r,options:a}))))})),p&&s&&n.hydrate&&n.hydrate(_.$state,p),u=!0,l=!0,_}var ba;
/*! For license information please see jsencrypt.min.js.LICENSE.txt */window,ba=()=>(()=>{var t={155:t=>{var e,n,r=t.exports={};function i(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function o(t){if(e===setTimeout)return setTimeout(t,0);if((e===i||!e)&&setTimeout)return e=setTimeout,setTimeout(t,0);try{return e(t,0)}catch(n){try{return e.call(null,t,0)}catch(r){return e.call(this,t,0)}}}!function(){try{e="function"==typeof setTimeout?setTimeout:i}catch(t){e=i}try{n="function"==typeof clearTimeout?clearTimeout:s}catch(t){n=s}}();var a,c=[],u=!1,l=-1;function h(){u&&a&&(u=!1,a.length?c=a.concat(c):l=-1,c.length&&f())}function f(){if(!u){var t=o(h);u=!0;for(var e=c.length;e;){for(a=c,c=[];++l<e;)a&&a[l].run();l=-1,e=c.length}a=null,u=!1,function(t){if(n===clearTimeout)return clearTimeout(t);if((n===s||!n)&&clearTimeout)return n=clearTimeout,clearTimeout(t);try{n(t)}catch(e){try{return n.call(null,t)}catch(r){return n.call(this,t)}}}(t)}}function d(t,e){this.fun=t,this.array=e}function p(){}r.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];c.push(new d(t,e)),1!==c.length||u||o(f)},d.prototype.run=function(){this.fun.apply(null,this.array)},r.title="browser",r.browser=!0,r.env={},r.argv=[],r.version="",r.versions={},r.on=p,r.addListener=p,r.once=p,r.off=p,r.removeListener=p,r.removeAllListeners=p,r.emit=p,r.prependListener=p,r.prependOnceListener=p,r.listeners=function(t){return[]},r.binding=function(t){throw new Error("process.binding is not supported")},r.cwd=function(){return"/"},r.chdir=function(t){throw new Error("process.chdir is not supported")},r.umask=function(){return 0}}},e={};function n(r){var i=e[r];if(void 0!==i)return i.exports;var s=e[r]={exports:{}};return t[r](s,s.exports,n),s.exports}n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e);var r={};return(()=>{function t(t){return"0123456789abcdefghijklmnopqrstuvwxyz".charAt(t)}function e(t,e){return t&e}function i(t,e){return t|e}function s(t,e){return t^e}function o(t,e){return t&~e}function a(t){if(0==t)return-1;var e=0;return 0==(65535&t)&&(t>>=16,e+=16),0==(255&t)&&(t>>=8,e+=8),0==(15&t)&&(t>>=4,e+=4),0==(3&t)&&(t>>=2,e+=2),0==(1&t)&&++e,e}function c(t){for(var e=0;0!=t;)t&=t-1,++e;return e}n.d(r,{default:()=>ot});var u,l="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";function h(t){var e,n,r="";for(e=0;e+3<=t.length;e+=3)n=parseInt(t.substring(e,e+3),16),r+=l.charAt(n>>6)+l.charAt(63&n);for(e+1==t.length?(n=parseInt(t.substring(e,e+1),16),r+=l.charAt(n<<2)):e+2==t.length&&(n=parseInt(t.substring(e,e+2),16),r+=l.charAt(n>>2)+l.charAt((3&n)<<4));(3&r.length)>0;)r+="=";return r}function f(e){var n,r="",i=0,s=0;for(n=0;n<e.length&&"="!=e.charAt(n);++n){var o=l.indexOf(e.charAt(n));o<0||(0==i?(r+=t(o>>2),s=3&o,i=1):1==i?(r+=t(s<<2|o>>4),s=15&o,i=2):2==i?(r+=t(s),r+=t(o>>2),s=3&o,i=3):(r+=t(s<<2|o>>4),r+=t(15&o),i=0))}return 1==i&&(r+=t(s<<2)),r}var d,p={decode:function(t){var e;if(void 0===d){var n="= \f\n\r\t \u2028\u2029";for(d=Object.create(null),e=0;e<64;++e)d["ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(e)]=e;for(d["-"]=62,d._=63,e=0;e<n.length;++e)d[n.charAt(e)]=-1}var r=[],i=0,s=0;for(e=0;e<t.length;++e){var o=t.charAt(e);if("="==o)break;if(-1!=(o=d[o])){if(void 0===o)throw new Error("Illegal character at offset "+e);i|=o,++s>=4?(r[r.length]=i>>16,r[r.length]=i>>8&255,r[r.length]=255&i,i=0,s=0):i<<=6}}switch(s){case 1:throw new Error("Base64 encoding incomplete: at least 2 bits missing");case 2:r[r.length]=i>>10;break;case 3:r[r.length]=i>>16,r[r.length]=i>>8&255}return r},re:/-----BEGIN [^-]+-----([A-Za-z0-9+\/=\s]+)-----END [^-]+-----|begin-base64[^\n]+\n([A-Za-z0-9+\/=\s]+)====/,unarmor:function(t){var e=p.re.exec(t);if(e)if(e[1])t=e[1];else{if(!e[2])throw new Error("RegExp out of sync");t=e[2]}return p.decode(t)}},g=1e13,m=function(){function t(t){this.buf=[+t||0]}return t.prototype.mulAdd=function(t,e){var n,r,i=this.buf,s=i.length;for(n=0;n<s;++n)(r=i[n]*t+e)<g?e=0:r-=(e=0|r/g)*g,i[n]=r;e>0&&(i[n]=e)},t.prototype.sub=function(t){var e,n,r=this.buf,i=r.length;for(e=0;e<i;++e)(n=r[e]-t)<0?(n+=g,t=1):t=0,r[e]=n;for(;0===r[r.length-1];)r.pop()},t.prototype.toString=function(t){if(10!=(t||10))throw new Error("only base 10 is supported");for(var e=this.buf,n=e[e.length-1].toString(),r=e.length-2;r>=0;--r)n+=(g+e[r]).toString().substring(1);return n},t.prototype.valueOf=function(){for(var t=this.buf,e=0,n=t.length-1;n>=0;--n)e=e*g+t[n];return e},t.prototype.simplify=function(){var t=this.buf;return 1==t.length?t[0]:this},t}(),y=/^(\d\d)(0[1-9]|1[0-2])(0[1-9]|[12]\d|3[01])([01]\d|2[0-3])(?:([0-5]\d)(?:([0-5]\d)(?:[.,](\d{1,3}))?)?)?(Z|[-+](?:[0]\d|1[0-2])([0-5]\d)?)?$/,v=/^(\d\d\d\d)(0[1-9]|1[0-2])(0[1-9]|[12]\d|3[01])([01]\d|2[0-3])(?:([0-5]\d)(?:([0-5]\d)(?:[.,](\d{1,3}))?)?)?(Z|[-+](?:[0]\d|1[0-2])([0-5]\d)?)?$/;function _(t,e){return t.length>e&&(t=t.substring(0,e)+"…"),t}var w,S=function(){function t(e,n){this.hexDigits="0123456789ABCDEF",e instanceof t?(this.enc=e.enc,this.pos=e.pos):(this.enc=e,this.pos=n)}return t.prototype.get=function(t){if(void 0===t&&(t=this.pos++),t>=this.enc.length)throw new Error("Requesting byte offset ".concat(t," on a stream of length ").concat(this.enc.length));return"string"==typeof this.enc?this.enc.charCodeAt(t):this.enc[t]},t.prototype.hexByte=function(t){return this.hexDigits.charAt(t>>4&15)+this.hexDigits.charAt(15&t)},t.prototype.hexDump=function(t,e,n){for(var r="",i=t;i<e;++i)if(r+=this.hexByte(this.get(i)),!0!==n)switch(15&i){case 7:r+="  ";break;case 15:r+="\n";break;default:r+=" "}return r},t.prototype.isASCII=function(t,e){for(var n=t;n<e;++n){var r=this.get(n);if(r<32||r>176)return!1}return!0},t.prototype.parseStringISO=function(t,e){for(var n="",r=t;r<e;++r)n+=String.fromCharCode(this.get(r));return n},t.prototype.parseStringUTF=function(t,e){for(var n="",r=t;r<e;){var i=this.get(r++);n+=i<128?String.fromCharCode(i):i>191&&i<224?String.fromCharCode((31&i)<<6|63&this.get(r++)):String.fromCharCode((15&i)<<12|(63&this.get(r++))<<6|63&this.get(r++))}return n},t.prototype.parseStringBMP=function(t,e){for(var n,r,i="",s=t;s<e;)n=this.get(s++),r=this.get(s++),i+=String.fromCharCode(n<<8|r);return i},t.prototype.parseTime=function(t,e,n){var r=this.parseStringISO(t,e),i=(n?y:v).exec(r);return i?(n&&(i[1]=+i[1],i[1]+=+i[1]<70?2e3:1900),r=i[1]+"-"+i[2]+"-"+i[3]+" "+i[4],i[5]&&(r+=":"+i[5],i[6]&&(r+=":"+i[6],i[7]&&(r+="."+i[7]))),i[8]&&(r+=" UTC","Z"!=i[8]&&(r+=i[8],i[9]&&(r+=":"+i[9]))),r):"Unrecognized time: "+r},t.prototype.parseInteger=function(t,e){for(var n,r=this.get(t),i=r>127,s=i?255:0,o="";r==s&&++t<e;)r=this.get(t);if(0==(n=e-t))return i?-1:0;if(n>4){for(o=r,n<<=3;0==(128&(+o^s));)o=+o<<1,--n;o="("+n+" bit)\n"}i&&(r-=256);for(var a=new m(r),c=t+1;c<e;++c)a.mulAdd(256,this.get(c));return o+a.toString()},t.prototype.parseBitString=function(t,e,n){for(var r=this.get(t),i="("+((e-t-1<<3)-r)+" bit)\n",s="",o=t+1;o<e;++o){for(var a=this.get(o),c=o==e-1?r:0,u=7;u>=c;--u)s+=a>>u&1?"1":"0";if(s.length>n)return i+_(s,n)}return i+s},t.prototype.parseOctetString=function(t,e,n){if(this.isASCII(t,e))return _(this.parseStringISO(t,e),n);var r=e-t,i="("+r+" byte)\n";r>(n/=2)&&(e=t+n);for(var s=t;s<e;++s)i+=this.hexByte(this.get(s));return r>n&&(i+="…"),i},t.prototype.parseOID=function(t,e,n){for(var r="",i=new m,s=0,o=t;o<e;++o){var a=this.get(o);if(i.mulAdd(128,127&a),s+=7,!(128&a)){if(""===r)if((i=i.simplify())instanceof m)i.sub(80),r="2."+i.toString();else{var c=i<80?i<40?0:1:2;r=c+"."+(i-40*c)}else r+="."+i.toString();if(r.length>n)return _(r,n);i=new m,s=0}}return s>0&&(r+=".incomplete"),r},t}(),b=function(){function t(t,e,n,r,i){if(!(r instanceof E))throw new Error("Invalid tag value.");this.stream=t,this.header=e,this.length=n,this.tag=r,this.sub=i}return t.prototype.typeName=function(){switch(this.tag.tagClass){case 0:switch(this.tag.tagNumber){case 0:return"EOC";case 1:return"BOOLEAN";case 2:return"INTEGER";case 3:return"BIT_STRING";case 4:return"OCTET_STRING";case 5:return"NULL";case 6:return"OBJECT_IDENTIFIER";case 7:return"ObjectDescriptor";case 8:return"EXTERNAL";case 9:return"REAL";case 10:return"ENUMERATED";case 11:return"EMBEDDED_PDV";case 12:return"UTF8String";case 16:return"SEQUENCE";case 17:return"SET";case 18:return"NumericString";case 19:return"PrintableString";case 20:return"TeletexString";case 21:return"VideotexString";case 22:return"IA5String";case 23:return"UTCTime";case 24:return"GeneralizedTime";case 25:return"GraphicString";case 26:return"VisibleString";case 27:return"GeneralString";case 28:return"UniversalString";case 30:return"BMPString"}return"Universal_"+this.tag.tagNumber.toString();case 1:return"Application_"+this.tag.tagNumber.toString();case 2:return"["+this.tag.tagNumber.toString()+"]";case 3:return"Private_"+this.tag.tagNumber.toString()}},t.prototype.content=function(t){if(void 0===this.tag)return null;void 0===t&&(t=1/0);var e=this.posContent(),n=Math.abs(this.length);if(!this.tag.isUniversal())return null!==this.sub?"("+this.sub.length+" elem)":this.stream.parseOctetString(e,e+n,t);switch(this.tag.tagNumber){case 1:return 0===this.stream.get(e)?"false":"true";case 2:return this.stream.parseInteger(e,e+n);case 3:return this.sub?"("+this.sub.length+" elem)":this.stream.parseBitString(e,e+n,t);case 4:return this.sub?"("+this.sub.length+" elem)":this.stream.parseOctetString(e,e+n,t);case 6:return this.stream.parseOID(e,e+n,t);case 16:case 17:return null!==this.sub?"("+this.sub.length+" elem)":"(no elem)";case 12:return _(this.stream.parseStringUTF(e,e+n),t);case 18:case 19:case 20:case 21:case 22:case 26:return _(this.stream.parseStringISO(e,e+n),t);case 30:return _(this.stream.parseStringBMP(e,e+n),t);case 23:case 24:return this.stream.parseTime(e,e+n,23==this.tag.tagNumber)}return null},t.prototype.toString=function(){return this.typeName()+"@"+this.stream.pos+"[header:"+this.header+",length:"+this.length+",sub:"+(null===this.sub?"null":this.sub.length)+"]"},t.prototype.toPrettyString=function(t){void 0===t&&(t="");var e=t+this.typeName()+" @"+this.stream.pos;if(this.length>=0&&(e+="+"),e+=this.length,this.tag.tagConstructed?e+=" (constructed)":!this.tag.isUniversal()||3!=this.tag.tagNumber&&4!=this.tag.tagNumber||null===this.sub||(e+=" (encapsulates)"),e+="\n",null!==this.sub){t+="  ";for(var n=0,r=this.sub.length;n<r;++n)e+=this.sub[n].toPrettyString(t)}return e},t.prototype.posStart=function(){return this.stream.pos},t.prototype.posContent=function(){return this.stream.pos+this.header},t.prototype.posEnd=function(){return this.stream.pos+this.header+Math.abs(this.length)},t.prototype.toHexString=function(){return this.stream.hexDump(this.posStart(),this.posEnd(),!0)},t.decodeLength=function(t){var e=t.get(),n=127&e;if(n==e)return n;if(n>6)throw new Error("Length over 48 bits not supported at position "+(t.pos-1));if(0===n)return null;e=0;for(var r=0;r<n;++r)e=256*e+t.get();return e},t.prototype.getHexStringValue=function(){var t=this.toHexString(),e=2*this.header,n=2*this.length;return t.substr(e,n)},t.decode=function(e){var n;n=e instanceof S?e:new S(e,0);var r=new S(n),i=new E(n),s=t.decodeLength(n),o=n.pos,a=o-r.pos,c=null,u=function(){var e=[];if(null!==s){for(var r=o+s;n.pos<r;)e[e.length]=t.decode(n);if(n.pos!=r)throw new Error("Content size is not correct for container starting at offset "+o)}else try{for(;;){var i=t.decode(n);if(i.tag.isEOC())break;e[e.length]=i}s=o-n.pos}catch(a){throw new Error("Exception while decoding undefined length content: "+a)}return e};if(i.tagConstructed)c=u();else if(i.isUniversal()&&(3==i.tagNumber||4==i.tagNumber))try{if(3==i.tagNumber&&0!=n.get())throw new Error("BIT STRINGs with unused bits cannot encapsulate.");c=u();for(var l=0;l<c.length;++l)if(c[l].tag.isEOC())throw new Error("EOC is not supposed to be actual content.")}catch(h){c=null}if(null===c){if(null===s)throw new Error("We can't skip over an invalid tag with undefined length at offset "+o);n.pos=o+Math.abs(s)}return new t(r,a,s,i,c)},t}(),E=function(){function t(t){var e=t.get();if(this.tagClass=e>>6,this.tagConstructed=0!=(32&e),this.tagNumber=31&e,31==this.tagNumber){var n=new m;do{e=t.get(),n.mulAdd(128,127&e)}while(128&e);this.tagNumber=n.simplify()}}return t.prototype.isUniversal=function(){return 0===this.tagClass},t.prototype.isEOC=function(){return 0===this.tagClass&&0===this.tagNumber},t}(),T=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97,101,103,107,109,113,127,131,137,139,149,151,157,163,167,173,179,181,191,193,197,199,211,223,227,229,233,239,241,251,257,263,269,271,277,281,283,293,307,311,313,317,331,337,347,349,353,359,367,373,379,383,389,397,401,409,419,421,431,433,439,443,449,457,461,463,467,479,487,491,499,503,509,521,523,541,547,557,563,569,571,577,587,593,599,601,607,613,617,619,631,641,643,647,653,659,661,673,677,683,691,701,709,719,727,733,739,743,751,757,761,769,773,787,797,809,811,821,823,827,829,839,853,857,859,863,877,881,883,887,907,911,919,929,937,941,947,953,967,971,977,983,991,997],x=(1<<26)/T[T.length-1],I=function(){function n(t,e,n){null!=t&&("number"==typeof t?this.fromNumber(t,e,n):null==e&&"string"!=typeof t?this.fromString(t,256):this.fromString(t,e))}return n.prototype.toString=function(e){if(this.s<0)return"-"+this.negate().toString(e);var n;if(16==e)n=4;else if(8==e)n=3;else if(2==e)n=1;else if(32==e)n=5;else{if(4!=e)return this.toRadix(e);n=2}var r,i=(1<<n)-1,s=!1,o="",a=this.t,c=this.DB-a*this.DB%n;if(a-- >0)for(c<this.DB&&(r=this[a]>>c)>0&&(s=!0,o=t(r));a>=0;)c<n?(r=(this[a]&(1<<c)-1)<<n-c,r|=this[--a]>>(c+=this.DB-n)):(r=this[a]>>(c-=n)&i,c<=0&&(c+=this.DB,--a)),r>0&&(s=!0),s&&(o+=t(r));return s?o:"0"},n.prototype.negate=function(){var t=R();return n.ZERO.subTo(this,t),t},n.prototype.abs=function(){return this.s<0?this.negate():this},n.prototype.compareTo=function(t){var e=this.s-t.s;if(0!=e)return e;var n=this.t;if(0!=(e=n-t.t))return this.s<0?-e:e;for(;--n>=0;)if(0!=(e=this[n]-t[n]))return e;return 0},n.prototype.bitLength=function(){return this.t<=0?0:this.DB*(this.t-1)+V(this[this.t-1]^this.s&this.DM)},n.prototype.mod=function(t){var e=R();return this.abs().divRemTo(t,null,e),this.s<0&&e.compareTo(n.ZERO)>0&&t.subTo(e,e),e},n.prototype.modPowInt=function(t,e){var n;return n=t<256||e.isEven()?new A(e):new k(e),this.exp(t,n)},n.prototype.clone=function(){var t=R();return this.copyTo(t),t},n.prototype.intValue=function(){if(this.s<0){if(1==this.t)return this[0]-this.DV;if(0==this.t)return-1}else{if(1==this.t)return this[0];if(0==this.t)return 0}return(this[1]&(1<<32-this.DB)-1)<<this.DB|this[0]},n.prototype.byteValue=function(){return 0==this.t?this.s:this[0]<<24>>24},n.prototype.shortValue=function(){return 0==this.t?this.s:this[0]<<16>>16},n.prototype.signum=function(){return this.s<0?-1:this.t<=0||1==this.t&&this[0]<=0?0:1},n.prototype.toByteArray=function(){var t=this.t,e=[];e[0]=this.s;var n,r=this.DB-t*this.DB%8,i=0;if(t-- >0)for(r<this.DB&&(n=this[t]>>r)!=(this.s&this.DM)>>r&&(e[i++]=n|this.s<<this.DB-r);t>=0;)r<8?(n=(this[t]&(1<<r)-1)<<8-r,n|=this[--t]>>(r+=this.DB-8)):(n=this[t]>>(r-=8)&255,r<=0&&(r+=this.DB,--t)),0!=(128&n)&&(n|=-256),0==i&&(128&this.s)!=(128&n)&&++i,(i>0||n!=this.s)&&(e[i++]=n);return e},n.prototype.equals=function(t){return 0==this.compareTo(t)},n.prototype.min=function(t){return this.compareTo(t)<0?this:t},n.prototype.max=function(t){return this.compareTo(t)>0?this:t},n.prototype.and=function(t){var n=R();return this.bitwiseTo(t,e,n),n},n.prototype.or=function(t){var e=R();return this.bitwiseTo(t,i,e),e},n.prototype.xor=function(t){var e=R();return this.bitwiseTo(t,s,e),e},n.prototype.andNot=function(t){var e=R();return this.bitwiseTo(t,o,e),e},n.prototype.not=function(){for(var t=R(),e=0;e<this.t;++e)t[e]=this.DM&~this[e];return t.t=this.t,t.s=~this.s,t},n.prototype.shiftLeft=function(t){var e=R();return t<0?this.rShiftTo(-t,e):this.lShiftTo(t,e),e},n.prototype.shiftRight=function(t){var e=R();return t<0?this.lShiftTo(-t,e):this.rShiftTo(t,e),e},n.prototype.getLowestSetBit=function(){for(var t=0;t<this.t;++t)if(0!=this[t])return t*this.DB+a(this[t]);return this.s<0?this.t*this.DB:-1},n.prototype.bitCount=function(){for(var t=0,e=this.s&this.DM,n=0;n<this.t;++n)t+=c(this[n]^e);return t},n.prototype.testBit=function(t){var e=Math.floor(t/this.DB);return e>=this.t?0!=this.s:0!=(this[e]&1<<t%this.DB)},n.prototype.setBit=function(t){return this.changeBit(t,i)},n.prototype.clearBit=function(t){return this.changeBit(t,o)},n.prototype.flipBit=function(t){return this.changeBit(t,s)},n.prototype.add=function(t){var e=R();return this.addTo(t,e),e},n.prototype.subtract=function(t){var e=R();return this.subTo(t,e),e},n.prototype.multiply=function(t){var e=R();return this.multiplyTo(t,e),e},n.prototype.divide=function(t){var e=R();return this.divRemTo(t,e,null),e},n.prototype.remainder=function(t){var e=R();return this.divRemTo(t,null,e),e},n.prototype.divideAndRemainder=function(t){var e=R(),n=R();return this.divRemTo(t,e,n),[e,n]},n.prototype.modPow=function(t,e){var n,r,i=t.bitLength(),s=j(1);if(i<=0)return s;n=i<18?1:i<48?3:i<144?4:i<768?5:6,r=i<8?new A(e):e.isEven()?new O(e):new k(e);var o=[],a=3,c=n-1,u=(1<<n)-1;if(o[1]=r.convert(this),n>1){var l=R();for(r.sqrTo(o[1],l);a<=u;)o[a]=R(),r.mulTo(l,o[a-2],o[a]),a+=2}var h,f,d=t.t-1,p=!0,g=R();for(i=V(t[d])-1;d>=0;){for(i>=c?h=t[d]>>i-c&u:(h=(t[d]&(1<<i+1)-1)<<c-i,d>0&&(h|=t[d-1]>>this.DB+i-c)),a=n;0==(1&h);)h>>=1,--a;if((i-=a)<0&&(i+=this.DB,--d),p)o[h].copyTo(s),p=!1;else{for(;a>1;)r.sqrTo(s,g),r.sqrTo(g,s),a-=2;a>0?r.sqrTo(s,g):(f=s,s=g,g=f),r.mulTo(g,o[h],s)}for(;d>=0&&0==(t[d]&1<<i);)r.sqrTo(s,g),f=s,s=g,g=f,--i<0&&(i=this.DB-1,--d)}return r.revert(s)},n.prototype.modInverse=function(t){var e=t.isEven();if(this.isEven()&&e||0==t.signum())return n.ZERO;for(var r=t.clone(),i=this.clone(),s=j(1),o=j(0),a=j(0),c=j(1);0!=r.signum();){for(;r.isEven();)r.rShiftTo(1,r),e?(s.isEven()&&o.isEven()||(s.addTo(this,s),o.subTo(t,o)),s.rShiftTo(1,s)):o.isEven()||o.subTo(t,o),o.rShiftTo(1,o);for(;i.isEven();)i.rShiftTo(1,i),e?(a.isEven()&&c.isEven()||(a.addTo(this,a),c.subTo(t,c)),a.rShiftTo(1,a)):c.isEven()||c.subTo(t,c),c.rShiftTo(1,c);r.compareTo(i)>=0?(r.subTo(i,r),e&&s.subTo(a,s),o.subTo(c,o)):(i.subTo(r,i),e&&a.subTo(s,a),c.subTo(o,c))}return 0!=i.compareTo(n.ONE)?n.ZERO:c.compareTo(t)>=0?c.subtract(t):c.signum()<0?(c.addTo(t,c),c.signum()<0?c.add(t):c):c},n.prototype.pow=function(t){return this.exp(t,new D)},n.prototype.gcd=function(t){var e=this.s<0?this.negate():this.clone(),n=t.s<0?t.negate():t.clone();if(e.compareTo(n)<0){var r=e;e=n,n=r}var i=e.getLowestSetBit(),s=n.getLowestSetBit();if(s<0)return e;for(i<s&&(s=i),s>0&&(e.rShiftTo(s,e),n.rShiftTo(s,n));e.signum()>0;)(i=e.getLowestSetBit())>0&&e.rShiftTo(i,e),(i=n.getLowestSetBit())>0&&n.rShiftTo(i,n),e.compareTo(n)>=0?(e.subTo(n,e),e.rShiftTo(1,e)):(n.subTo(e,n),n.rShiftTo(1,n));return s>0&&n.lShiftTo(s,n),n},n.prototype.isProbablePrime=function(t){var e,n=this.abs();if(1==n.t&&n[0]<=T[T.length-1]){for(e=0;e<T.length;++e)if(n[0]==T[e])return!0;return!1}if(n.isEven())return!1;for(e=1;e<T.length;){for(var r=T[e],i=e+1;i<T.length&&r<x;)r*=T[i++];for(r=n.modInt(r);e<i;)if(r%T[e++]==0)return!1}return n.millerRabin(t)},n.prototype.copyTo=function(t){for(var e=this.t-1;e>=0;--e)t[e]=this[e];t.t=this.t,t.s=this.s},n.prototype.fromInt=function(t){this.t=1,this.s=t<0?-1:0,t>0?this[0]=t:t<-1?this[0]=t+this.DV:this.t=0},n.prototype.fromString=function(t,e){var r;if(16==e)r=4;else if(8==e)r=3;else if(256==e)r=8;else if(2==e)r=1;else if(32==e)r=5;else{if(4!=e)return void this.fromRadix(t,e);r=2}this.t=0,this.s=0;for(var i=t.length,s=!1,o=0;--i>=0;){var a=8==r?255&+t[i]:L(t,i);a<0?"-"==t.charAt(i)&&(s=!0):(s=!1,0==o?this[this.t++]=a:o+r>this.DB?(this[this.t-1]|=(a&(1<<this.DB-o)-1)<<o,this[this.t++]=a>>this.DB-o):this[this.t-1]|=a<<o,(o+=r)>=this.DB&&(o-=this.DB))}8==r&&0!=(128&+t[0])&&(this.s=-1,o>0&&(this[this.t-1]|=(1<<this.DB-o)-1<<o)),this.clamp(),s&&n.ZERO.subTo(this,this)},n.prototype.clamp=function(){for(var t=this.s&this.DM;this.t>0&&this[this.t-1]==t;)--this.t},n.prototype.dlShiftTo=function(t,e){var n;for(n=this.t-1;n>=0;--n)e[n+t]=this[n];for(n=t-1;n>=0;--n)e[n]=0;e.t=this.t+t,e.s=this.s},n.prototype.drShiftTo=function(t,e){for(var n=t;n<this.t;++n)e[n-t]=this[n];e.t=Math.max(this.t-t,0),e.s=this.s},n.prototype.lShiftTo=function(t,e){for(var n=t%this.DB,r=this.DB-n,i=(1<<r)-1,s=Math.floor(t/this.DB),o=this.s<<n&this.DM,a=this.t-1;a>=0;--a)e[a+s+1]=this[a]>>r|o,o=(this[a]&i)<<n;for(a=s-1;a>=0;--a)e[a]=0;e[s]=o,e.t=this.t+s+1,e.s=this.s,e.clamp()},n.prototype.rShiftTo=function(t,e){e.s=this.s;var n=Math.floor(t/this.DB);if(n>=this.t)e.t=0;else{var r=t%this.DB,i=this.DB-r,s=(1<<r)-1;e[0]=this[n]>>r;for(var o=n+1;o<this.t;++o)e[o-n-1]|=(this[o]&s)<<i,e[o-n]=this[o]>>r;r>0&&(e[this.t-n-1]|=(this.s&s)<<i),e.t=this.t-n,e.clamp()}},n.prototype.subTo=function(t,e){for(var n=0,r=0,i=Math.min(t.t,this.t);n<i;)r+=this[n]-t[n],e[n++]=r&this.DM,r>>=this.DB;if(t.t<this.t){for(r-=t.s;n<this.t;)r+=this[n],e[n++]=r&this.DM,r>>=this.DB;r+=this.s}else{for(r+=this.s;n<t.t;)r-=t[n],e[n++]=r&this.DM,r>>=this.DB;r-=t.s}e.s=r<0?-1:0,r<-1?e[n++]=this.DV+r:r>0&&(e[n++]=r),e.t=n,e.clamp()},n.prototype.multiplyTo=function(t,e){var r=this.abs(),i=t.abs(),s=r.t;for(e.t=s+i.t;--s>=0;)e[s]=0;for(s=0;s<i.t;++s)e[s+r.t]=r.am(0,i[s],e,s,0,r.t);e.s=0,e.clamp(),this.s!=t.s&&n.ZERO.subTo(e,e)},n.prototype.squareTo=function(t){for(var e=this.abs(),n=t.t=2*e.t;--n>=0;)t[n]=0;for(n=0;n<e.t-1;++n){var r=e.am(n,e[n],t,2*n,0,1);(t[n+e.t]+=e.am(n+1,2*e[n],t,2*n+1,r,e.t-n-1))>=e.DV&&(t[n+e.t]-=e.DV,t[n+e.t+1]=1)}t.t>0&&(t[t.t-1]+=e.am(n,e[n],t,2*n,0,1)),t.s=0,t.clamp()},n.prototype.divRemTo=function(t,e,r){var i=t.abs();if(!(i.t<=0)){var s=this.abs();if(s.t<i.t)return null!=e&&e.fromInt(0),void(null!=r&&this.copyTo(r));null==r&&(r=R());var o=R(),a=this.s,c=t.s,u=this.DB-V(i[i.t-1]);u>0?(i.lShiftTo(u,o),s.lShiftTo(u,r)):(i.copyTo(o),s.copyTo(r));var l=o.t,h=o[l-1];if(0!=h){var f=h*(1<<this.F1)+(l>1?o[l-2]>>this.F2:0),d=this.FV/f,p=(1<<this.F1)/f,g=1<<this.F2,m=r.t,y=m-l,v=null==e?R():e;for(o.dlShiftTo(y,v),r.compareTo(v)>=0&&(r[r.t++]=1,r.subTo(v,r)),n.ONE.dlShiftTo(l,v),v.subTo(o,o);o.t<l;)o[o.t++]=0;for(;--y>=0;){var _=r[--m]==h?this.DM:Math.floor(r[m]*d+(r[m-1]+g)*p);if((r[m]+=o.am(0,_,r,y,0,l))<_)for(o.dlShiftTo(y,v),r.subTo(v,r);r[m]<--_;)r.subTo(v,r)}null!=e&&(r.drShiftTo(l,e),a!=c&&n.ZERO.subTo(e,e)),r.t=l,r.clamp(),u>0&&r.rShiftTo(u,r),a<0&&n.ZERO.subTo(r,r)}}},n.prototype.invDigit=function(){if(this.t<1)return 0;var t=this[0];if(0==(1&t))return 0;var e=3&t;return(e=(e=(e=(e=e*(2-(15&t)*e)&15)*(2-(255&t)*e)&255)*(2-((65535&t)*e&65535))&65535)*(2-t*e%this.DV)%this.DV)>0?this.DV-e:-e},n.prototype.isEven=function(){return 0==(this.t>0?1&this[0]:this.s)},n.prototype.exp=function(t,e){if(t>4294967295||t<1)return n.ONE;var r=R(),i=R(),s=e.convert(this),o=V(t)-1;for(s.copyTo(r);--o>=0;)if(e.sqrTo(r,i),(t&1<<o)>0)e.mulTo(i,s,r);else{var a=r;r=i,i=a}return e.revert(r)},n.prototype.chunkSize=function(t){return Math.floor(Math.LN2*this.DB/Math.log(t))},n.prototype.toRadix=function(t){if(null==t&&(t=10),0==this.signum()||t<2||t>36)return"0";var e=this.chunkSize(t),n=Math.pow(t,e),r=j(n),i=R(),s=R(),o="";for(this.divRemTo(r,i,s);i.signum()>0;)o=(n+s.intValue()).toString(t).substr(1)+o,i.divRemTo(r,i,s);return s.intValue().toString(t)+o},n.prototype.fromRadix=function(t,e){this.fromInt(0),null==e&&(e=10);for(var r=this.chunkSize(e),i=Math.pow(e,r),s=!1,o=0,a=0,c=0;c<t.length;++c){var u=L(t,c);u<0?"-"==t.charAt(c)&&0==this.signum()&&(s=!0):(a=e*a+u,++o>=r&&(this.dMultiply(i),this.dAddOffset(a,0),o=0,a=0))}o>0&&(this.dMultiply(Math.pow(e,o)),this.dAddOffset(a,0)),s&&n.ZERO.subTo(this,this)},n.prototype.fromNumber=function(t,e,r){if("number"==typeof e)if(t<2)this.fromInt(1);else for(this.fromNumber(t,r),this.testBit(t-1)||this.bitwiseTo(n.ONE.shiftLeft(t-1),i,this),this.isEven()&&this.dAddOffset(1,0);!this.isProbablePrime(e);)this.dAddOffset(2,0),this.bitLength()>t&&this.subTo(n.ONE.shiftLeft(t-1),this);else{var s=[],o=7&t;s.length=1+(t>>3),e.nextBytes(s),o>0?s[0]&=(1<<o)-1:s[0]=0,this.fromString(s,256)}},n.prototype.bitwiseTo=function(t,e,n){var r,i,s=Math.min(t.t,this.t);for(r=0;r<s;++r)n[r]=e(this[r],t[r]);if(t.t<this.t){for(i=t.s&this.DM,r=s;r<this.t;++r)n[r]=e(this[r],i);n.t=this.t}else{for(i=this.s&this.DM,r=s;r<t.t;++r)n[r]=e(i,t[r]);n.t=t.t}n.s=e(this.s,t.s),n.clamp()},n.prototype.changeBit=function(t,e){var r=n.ONE.shiftLeft(t);return this.bitwiseTo(r,e,r),r},n.prototype.addTo=function(t,e){for(var n=0,r=0,i=Math.min(t.t,this.t);n<i;)r+=this[n]+t[n],e[n++]=r&this.DM,r>>=this.DB;if(t.t<this.t){for(r+=t.s;n<this.t;)r+=this[n],e[n++]=r&this.DM,r>>=this.DB;r+=this.s}else{for(r+=this.s;n<t.t;)r+=t[n],e[n++]=r&this.DM,r>>=this.DB;r+=t.s}e.s=r<0?-1:0,r>0?e[n++]=r:r<-1&&(e[n++]=this.DV+r),e.t=n,e.clamp()},n.prototype.dMultiply=function(t){this[this.t]=this.am(0,t-1,this,0,0,this.t),++this.t,this.clamp()},n.prototype.dAddOffset=function(t,e){if(0!=t){for(;this.t<=e;)this[this.t++]=0;for(this[e]+=t;this[e]>=this.DV;)this[e]-=this.DV,++e>=this.t&&(this[this.t++]=0),++this[e]}},n.prototype.multiplyLowerTo=function(t,e,n){var r=Math.min(this.t+t.t,e);for(n.s=0,n.t=r;r>0;)n[--r]=0;for(var i=n.t-this.t;r<i;++r)n[r+this.t]=this.am(0,t[r],n,r,0,this.t);for(i=Math.min(t.t,e);r<i;++r)this.am(0,t[r],n,r,0,e-r);n.clamp()},n.prototype.multiplyUpperTo=function(t,e,n){--e;var r=n.t=this.t+t.t-e;for(n.s=0;--r>=0;)n[r]=0;for(r=Math.max(e-this.t,0);r<t.t;++r)n[this.t+r-e]=this.am(e-r,t[r],n,0,0,this.t+r-e);n.clamp(),n.drShiftTo(1,n)},n.prototype.modInt=function(t){if(t<=0)return 0;var e=this.DV%t,n=this.s<0?t-1:0;if(this.t>0)if(0==e)n=this[0]%t;else for(var r=this.t-1;r>=0;--r)n=(e*n+this[r])%t;return n},n.prototype.millerRabin=function(t){var e=this.subtract(n.ONE),r=e.getLowestSetBit();if(r<=0)return!1;var i=e.shiftRight(r);(t=t+1>>1)>T.length&&(t=T.length);for(var s=R(),o=0;o<t;++o){s.fromInt(T[Math.floor(Math.random()*T.length)]);var a=s.modPow(i,this);if(0!=a.compareTo(n.ONE)&&0!=a.compareTo(e)){for(var c=1;c++<r&&0!=a.compareTo(e);)if(0==(a=a.modPowInt(2,this)).compareTo(n.ONE))return!1;if(0!=a.compareTo(e))return!1}}return!0},n.prototype.square=function(){var t=R();return this.squareTo(t),t},n.prototype.gcda=function(t,e){var n=this.s<0?this.negate():this.clone(),r=t.s<0?t.negate():t.clone();if(n.compareTo(r)<0){var i=n;n=r,r=i}var s=n.getLowestSetBit(),o=r.getLowestSetBit();if(o<0)e(n);else{s<o&&(o=s),o>0&&(n.rShiftTo(o,n),r.rShiftTo(o,r));var a=function(){(s=n.getLowestSetBit())>0&&n.rShiftTo(s,n),(s=r.getLowestSetBit())>0&&r.rShiftTo(s,r),n.compareTo(r)>=0?(n.subTo(r,n),n.rShiftTo(1,n)):(r.subTo(n,r),r.rShiftTo(1,r)),n.signum()>0?setTimeout(a,0):(o>0&&r.lShiftTo(o,r),setTimeout((function(){e(r)}),0))};setTimeout(a,10)}},n.prototype.fromNumberAsync=function(t,e,r,s){if("number"==typeof e)if(t<2)this.fromInt(1);else{this.fromNumber(t,r),this.testBit(t-1)||this.bitwiseTo(n.ONE.shiftLeft(t-1),i,this),this.isEven()&&this.dAddOffset(1,0);var o=this,a=function(){o.dAddOffset(2,0),o.bitLength()>t&&o.subTo(n.ONE.shiftLeft(t-1),o),o.isProbablePrime(e)?setTimeout((function(){s()}),0):setTimeout(a,0)};setTimeout(a,0)}else{var c=[],u=7&t;c.length=1+(t>>3),e.nextBytes(c),u>0?c[0]&=(1<<u)-1:c[0]=0,this.fromString(c,256)}},n}(),D=function(){function t(){}return t.prototype.convert=function(t){return t},t.prototype.revert=function(t){return t},t.prototype.mulTo=function(t,e,n){t.multiplyTo(e,n)},t.prototype.sqrTo=function(t,e){t.squareTo(e)},t}(),A=function(){function t(t){this.m=t}return t.prototype.convert=function(t){return t.s<0||t.compareTo(this.m)>=0?t.mod(this.m):t},t.prototype.revert=function(t){return t},t.prototype.reduce=function(t){t.divRemTo(this.m,null,t)},t.prototype.mulTo=function(t,e,n){t.multiplyTo(e,n),this.reduce(n)},t.prototype.sqrTo=function(t,e){t.squareTo(e),this.reduce(e)},t}(),k=function(){function t(t){this.m=t,this.mp=t.invDigit(),this.mpl=32767&this.mp,this.mph=this.mp>>15,this.um=(1<<t.DB-15)-1,this.mt2=2*t.t}return t.prototype.convert=function(t){var e=R();return t.abs().dlShiftTo(this.m.t,e),e.divRemTo(this.m,null,e),t.s<0&&e.compareTo(I.ZERO)>0&&this.m.subTo(e,e),e},t.prototype.revert=function(t){var e=R();return t.copyTo(e),this.reduce(e),e},t.prototype.reduce=function(t){for(;t.t<=this.mt2;)t[t.t++]=0;for(var e=0;e<this.m.t;++e){var n=32767&t[e],r=n*this.mpl+((n*this.mph+(t[e]>>15)*this.mpl&this.um)<<15)&t.DM;for(t[n=e+this.m.t]+=this.m.am(0,r,t,e,0,this.m.t);t[n]>=t.DV;)t[n]-=t.DV,t[++n]++}t.clamp(),t.drShiftTo(this.m.t,t),t.compareTo(this.m)>=0&&t.subTo(this.m,t)},t.prototype.mulTo=function(t,e,n){t.multiplyTo(e,n),this.reduce(n)},t.prototype.sqrTo=function(t,e){t.squareTo(e),this.reduce(e)},t}(),O=function(){function t(t){this.m=t,this.r2=R(),this.q3=R(),I.ONE.dlShiftTo(2*t.t,this.r2),this.mu=this.r2.divide(t)}return t.prototype.convert=function(t){if(t.s<0||t.t>2*this.m.t)return t.mod(this.m);if(t.compareTo(this.m)<0)return t;var e=R();return t.copyTo(e),this.reduce(e),e},t.prototype.revert=function(t){return t},t.prototype.reduce=function(t){for(t.drShiftTo(this.m.t-1,this.r2),t.t>this.m.t+1&&(t.t=this.m.t+1,t.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);t.compareTo(this.r2)<0;)t.dAddOffset(1,this.m.t+1);for(t.subTo(this.r2,t);t.compareTo(this.m)>=0;)t.subTo(this.m,t)},t.prototype.mulTo=function(t,e,n){t.multiplyTo(e,n),this.reduce(n)},t.prototype.sqrTo=function(t,e){t.squareTo(e),this.reduce(e)},t}();function R(){return new I(null)}function P(t,e){return new I(t,e)}var M="undefined"!=typeof navigator;M&&"Microsoft Internet Explorer"==navigator.appName?(I.prototype.am=function(t,e,n,r,i,s){for(var o=32767&e,a=e>>15;--s>=0;){var c=32767&this[t],u=this[t++]>>15,l=a*c+u*o;i=((c=o*c+((32767&l)<<15)+n[r]+(1073741823&i))>>>30)+(l>>>15)+a*u+(i>>>30),n[r++]=1073741823&c}return i},w=30):M&&"Netscape"!=navigator.appName?(I.prototype.am=function(t,e,n,r,i,s){for(;--s>=0;){var o=e*this[t++]+n[r]+i;i=Math.floor(o/67108864),n[r++]=67108863&o}return i},w=26):(I.prototype.am=function(t,e,n,r,i,s){for(var o=16383&e,a=e>>14;--s>=0;){var c=16383&this[t],u=this[t++]>>14,l=a*c+u*o;i=((c=o*c+((16383&l)<<14)+n[r]+i)>>28)+(l>>14)+a*u,n[r++]=268435455&c}return i},w=28),I.prototype.DB=w,I.prototype.DM=(1<<w)-1,I.prototype.DV=1<<w,I.prototype.FV=Math.pow(2,52),I.prototype.F1=52-w,I.prototype.F2=2*w-52;var C,B,N=[];for(C="0".charCodeAt(0),B=0;B<=9;++B)N[C++]=B;for(C="a".charCodeAt(0),B=10;B<36;++B)N[C++]=B;for(C="A".charCodeAt(0),B=10;B<36;++B)N[C++]=B;function L(t,e){var n=N[t.charCodeAt(e)];return null==n?-1:n}function j(t){var e=R();return e.fromInt(t),e}function V(t){var e,n=1;return 0!=(e=t>>>16)&&(t=e,n+=16),0!=(e=t>>8)&&(t=e,n+=8),0!=(e=t>>4)&&(t=e,n+=4),0!=(e=t>>2)&&(t=e,n+=2),0!=(e=t>>1)&&(t=e,n+=1),n}I.ZERO=j(0),I.ONE=j(1);var U,$,H=function(){function t(){this.i=0,this.j=0,this.S=[]}return t.prototype.init=function(t){var e,n,r;for(e=0;e<256;++e)this.S[e]=e;for(n=0,e=0;e<256;++e)n=n+this.S[e]+t[e%t.length]&255,r=this.S[e],this.S[e]=this.S[n],this.S[n]=r;this.i=0,this.j=0},t.prototype.next=function(){var t;return this.i=this.i+1&255,this.j=this.j+this.S[this.i]&255,t=this.S[this.i],this.S[this.i]=this.S[this.j],this.S[this.j]=t,this.S[t+this.S[this.i]&255]},t}(),q=null;if(null==q){q=[],$=0;var F=void 0;if("undefined"!=typeof window&&window.crypto&&window.crypto.getRandomValues){var K=new Uint32Array(256);for(window.crypto.getRandomValues(K),F=0;F<K.length;++F)q[$++]=255&K[F]}var z=0,W=function(t){if((z=z||0)>=256||$>=256)window.removeEventListener?window.removeEventListener("mousemove",W,!1):window.detachEvent&&window.detachEvent("onmousemove",W);else try{var e=t.x+t.y;q[$++]=255&e,z+=1}catch(n){}};"undefined"!=typeof window&&(window.addEventListener?window.addEventListener("mousemove",W,!1):window.attachEvent&&window.attachEvent("onmousemove",W))}function J(){if(null==U){for(U=new H;$<256;){var t=Math.floor(65536*Math.random());q[$++]=255&t}for(U.init(q),$=0;$<q.length;++$)q[$]=0;$=0}return U.next()}var G=function(){function t(){}return t.prototype.nextBytes=function(t){for(var e=0;e<t.length;++e)t[e]=J()},t}(),Y=function(){function t(){this.n=null,this.e=0,this.d=null,this.p=null,this.q=null,this.dmp1=null,this.dmq1=null,this.coeff=null}return t.prototype.doPublic=function(t){return t.modPowInt(this.e,this.n)},t.prototype.doPrivate=function(t){if(null==this.p||null==this.q)return t.modPow(this.d,this.n);for(var e=t.mod(this.p).modPow(this.dmp1,this.p),n=t.mod(this.q).modPow(this.dmq1,this.q);e.compareTo(n)<0;)e=e.add(this.p);return e.subtract(n).multiply(this.coeff).mod(this.p).multiply(this.q).add(n)},t.prototype.setPublic=function(t,e){null!=t&&null!=e&&t.length>0&&e.length>0?(this.n=P(t,16),this.e=parseInt(e,16)):console.error("Invalid RSA public key")},t.prototype.encrypt=function(t){var e=this.n.bitLength()+7>>3,n=function(t,e){if(e<t.length+11)return console.error("Message too long for RSA"),null;for(var n=[],r=t.length-1;r>=0&&e>0;){var i=t.charCodeAt(r--);i<128?n[--e]=i:i>127&&i<2048?(n[--e]=63&i|128,n[--e]=i>>6|192):(n[--e]=63&i|128,n[--e]=i>>6&63|128,n[--e]=i>>12|224)}n[--e]=0;for(var s=new G,o=[];e>2;){for(o[0]=0;0==o[0];)s.nextBytes(o);n[--e]=o[0]}return n[--e]=2,n[--e]=0,new I(n)}(t,e);if(null==n)return null;var r=this.doPublic(n);if(null==r)return null;for(var i=r.toString(16),s=i.length,o=0;o<2*e-s;o++)i="0"+i;return i},t.prototype.setPrivate=function(t,e,n){null!=t&&null!=e&&t.length>0&&e.length>0?(this.n=P(t,16),this.e=parseInt(e,16),this.d=P(n,16)):console.error("Invalid RSA private key")},t.prototype.setPrivateEx=function(t,e,n,r,i,s,o,a){null!=t&&null!=e&&t.length>0&&e.length>0?(this.n=P(t,16),this.e=parseInt(e,16),this.d=P(n,16),this.p=P(r,16),this.q=P(i,16),this.dmp1=P(s,16),this.dmq1=P(o,16),this.coeff=P(a,16)):console.error("Invalid RSA private key")},t.prototype.generate=function(t,e){var n=new G,r=t>>1;this.e=parseInt(e,16);for(var i=new I(e,16);;){for(;this.p=new I(t-r,1,n),0!=this.p.subtract(I.ONE).gcd(i).compareTo(I.ONE)||!this.p.isProbablePrime(10););for(;this.q=new I(r,1,n),0!=this.q.subtract(I.ONE).gcd(i).compareTo(I.ONE)||!this.q.isProbablePrime(10););if(this.p.compareTo(this.q)<=0){var s=this.p;this.p=this.q,this.q=s}var o=this.p.subtract(I.ONE),a=this.q.subtract(I.ONE),c=o.multiply(a);if(0==c.gcd(i).compareTo(I.ONE)){this.n=this.p.multiply(this.q),this.d=i.modInverse(c),this.dmp1=this.d.mod(o),this.dmq1=this.d.mod(a),this.coeff=this.q.modInverse(this.p);break}}},t.prototype.decrypt=function(t){var e=P(t,16),n=this.doPrivate(e);return null==n?null:function(t,e){for(var n=t.toByteArray(),r=0;r<n.length&&0==n[r];)++r;if(n.length-r!=e-1||2!=n[r])return null;for(++r;0!=n[r];)if(++r>=n.length)return null;for(var i="";++r<n.length;){var s=255&n[r];s<128?i+=String.fromCharCode(s):s>191&&s<224?(i+=String.fromCharCode((31&s)<<6|63&n[r+1]),++r):(i+=String.fromCharCode((15&s)<<12|(63&n[r+1])<<6|63&n[r+2]),r+=2)}return i}(n,this.n.bitLength()+7>>3)},t.prototype.generateAsync=function(t,e,n){var r=new G,i=t>>1;this.e=parseInt(e,16);var s=new I(e,16),o=this,a=function(){var e=function(){if(o.p.compareTo(o.q)<=0){var t=o.p;o.p=o.q,o.q=t}var e=o.p.subtract(I.ONE),r=o.q.subtract(I.ONE),i=e.multiply(r);0==i.gcd(s).compareTo(I.ONE)?(o.n=o.p.multiply(o.q),o.d=s.modInverse(i),o.dmp1=o.d.mod(e),o.dmq1=o.d.mod(r),o.coeff=o.q.modInverse(o.p),setTimeout((function(){n()}),0)):setTimeout(a,0)},c=function(){o.q=R(),o.q.fromNumberAsync(i,1,r,(function(){o.q.subtract(I.ONE).gcda(s,(function(t){0==t.compareTo(I.ONE)&&o.q.isProbablePrime(10)?setTimeout(e,0):setTimeout(c,0)}))}))},u=function(){o.p=R(),o.p.fromNumberAsync(t-i,1,r,(function(){o.p.subtract(I.ONE).gcda(s,(function(t){0==t.compareTo(I.ONE)&&o.p.isProbablePrime(10)?setTimeout(c,0):setTimeout(u,0)}))}))};setTimeout(u,0)};setTimeout(a,0)},t.prototype.sign=function(t,e,n){var r=function(t,e){if(e<t.length+22)return console.error("Message too long for RSA"),null;for(var n=e-t.length-6,r="",i=0;i<n;i+=2)r+="ff";return P("0001"+r+"00"+t,16)}((Z[n]||"")+e(t).toString(),this.n.bitLength()/4);if(null==r)return null;var i=this.doPrivate(r);if(null==i)return null;var s=i.toString(16);return 0==(1&s.length)?s:"0"+s},t.prototype.verify=function(t,e,n){var r=P(e,16),i=this.doPublic(r);return null==i?null:function(t){for(var e in Z)if(Z.hasOwnProperty(e)){var n=Z[e],r=n.length;if(t.substr(0,r)==n)return t.substr(r)}return t}(i.toString(16).replace(/^1f+00/,""))==n(t).toString()},t}(),Z={md2:"3020300c06082a864886f70d020205000410",md5:"3020300c06082a864886f70d020505000410",sha1:"3021300906052b0e03021a05000414",sha224:"302d300d06096086480165030402040500041c",sha256:"3031300d060960864801650304020105000420",sha384:"3041300d060960864801650304020205000430",sha512:"3051300d060960864801650304020305000440",ripemd160:"3021300906052b2403020105000414"},X={};X.lang={extend:function(t,e,n){if(!e||!t)throw new Error("YAHOO.lang.extend failed, please check that all dependencies are included.");var r=function(){};if(r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t,t.superclass=e.prototype,e.prototype.constructor==Object.prototype.constructor&&(e.prototype.constructor=e),n){var i;for(i in n)t.prototype[i]=n[i];var s=function(){},o=["toString","valueOf"];try{/MSIE/.test(navigator.userAgent)&&(s=function(t,e){for(i=0;i<o.length;i+=1){var n=o[i],r=e[n];"function"==typeof r&&r!=Object.prototype[n]&&(t[n]=r)}})}catch(a){}s(t.prototype,n)}}};var Q={};void 0!==Q.asn1&&Q.asn1||(Q.asn1={}),Q.asn1.ASN1Util=new function(){this.integerToByteHex=function(t){var e=t.toString(16);return e.length%2==1&&(e="0"+e),e},this.bigIntToMinTwosComplementsHex=function(t){var e=t.toString(16);if("-"!=e.substr(0,1))e.length%2==1?e="0"+e:e.match(/^[0-7]/)||(e="00"+e);else{var n=e.substr(1).length;n%2==1?n+=1:e.match(/^[0-7]/)||(n+=2);for(var r="",i=0;i<n;i++)r+="f";e=new I(r,16).xor(t).add(I.ONE).toString(16).replace(/^-/,"")}return e},this.getPEMStringFromHex=function(t,e){return hextopem(t,e)},this.newObject=function(t){var e=Q.asn1,n=e.DERBoolean,r=e.DERInteger,i=e.DERBitString,s=e.DEROctetString,o=e.DERNull,a=e.DERObjectIdentifier,c=e.DEREnumerated,u=e.DERUTF8String,l=e.DERNumericString,h=e.DERPrintableString,f=e.DERTeletexString,d=e.DERIA5String,p=e.DERUTCTime,g=e.DERGeneralizedTime,m=e.DERSequence,y=e.DERSet,v=e.DERTaggedObject,_=e.ASN1Util.newObject,w=Object.keys(t);if(1!=w.length)throw"key of param shall be only one.";var S=w[0];if(-1==":bool:int:bitstr:octstr:null:oid:enum:utf8str:numstr:prnstr:telstr:ia5str:utctime:gentime:seq:set:tag:".indexOf(":"+S+":"))throw"undefined key: "+S;if("bool"==S)return new n(t[S]);if("int"==S)return new r(t[S]);if("bitstr"==S)return new i(t[S]);if("octstr"==S)return new s(t[S]);if("null"==S)return new o(t[S]);if("oid"==S)return new a(t[S]);if("enum"==S)return new c(t[S]);if("utf8str"==S)return new u(t[S]);if("numstr"==S)return new l(t[S]);if("prnstr"==S)return new h(t[S]);if("telstr"==S)return new f(t[S]);if("ia5str"==S)return new d(t[S]);if("utctime"==S)return new p(t[S]);if("gentime"==S)return new g(t[S]);if("seq"==S){for(var b=t[S],E=[],T=0;T<b.length;T++){var x=_(b[T]);E.push(x)}return new m({array:E})}if("set"==S){for(b=t[S],E=[],T=0;T<b.length;T++)x=_(b[T]),E.push(x);return new y({array:E})}if("tag"==S){var I=t[S];if("[object Array]"===Object.prototype.toString.call(I)&&3==I.length){var D=_(I[2]);return new v({tag:I[0],explicit:I[1],obj:D})}var A={};if(void 0!==I.explicit&&(A.explicit=I.explicit),void 0!==I.tag&&(A.tag=I.tag),void 0===I.obj)throw"obj shall be specified for 'tag'.";return A.obj=_(I.obj),new v(A)}},this.jsonToASN1HEX=function(t){return this.newObject(t).getEncodedHex()}},Q.asn1.ASN1Util.oidHexToInt=function(t){for(var e="",n=parseInt(t.substr(0,2),16),r=(e=Math.floor(n/40)+"."+n%40,""),i=2;i<t.length;i+=2){var s=("00000000"+parseInt(t.substr(i,2),16).toString(2)).slice(-8);r+=s.substr(1,7),"0"==s.substr(0,1)&&(e=e+"."+new I(r,2).toString(10),r="")}return e},Q.asn1.ASN1Util.oidIntToHex=function(t){var e=function(t){var e=t.toString(16);return 1==e.length&&(e="0"+e),e},n=function(t){var n="",r=new I(t,10).toString(2),i=7-r.length%7;7==i&&(i=0);for(var s="",o=0;o<i;o++)s+="0";for(r=s+r,o=0;o<r.length-1;o+=7){var a=r.substr(o,7);o!=r.length-7&&(a="1"+a),n+=e(parseInt(a,2))}return n};if(!t.match(/^[0-9.]+$/))throw"malformed oid string: "+t;var r="",i=t.split("."),s=40*parseInt(i[0])+parseInt(i[1]);r+=e(s),i.splice(0,2);for(var o=0;o<i.length;o++)r+=n(i[o]);return r},Q.asn1.ASN1Object=function(){this.getLengthHexFromValue=function(){if(void 0===this.hV||null==this.hV)throw"this.hV is null or undefined.";if(this.hV.length%2==1)throw"value hex must be even length: n="+"".length+",v="+this.hV;var t=this.hV.length/2,e=t.toString(16);if(e.length%2==1&&(e="0"+e),t<128)return e;var n=e.length/2;if(n>15)throw"ASN.1 length too long to represent by 8x: n = "+t.toString(16);return(128+n).toString(16)+e},this.getEncodedHex=function(){return(null==this.hTLV||this.isModified)&&(this.hV=this.getFreshValueHex(),this.hL=this.getLengthHexFromValue(),this.hTLV=this.hT+this.hL+this.hV,this.isModified=!1),this.hTLV},this.getValueHex=function(){return this.getEncodedHex(),this.hV},this.getFreshValueHex=function(){return""}},Q.asn1.DERAbstractString=function(t){Q.asn1.DERAbstractString.superclass.constructor.call(this),this.getString=function(){return this.s},this.setString=function(t){this.hTLV=null,this.isModified=!0,this.s=t,this.hV=stohex(this.s)},this.setStringHex=function(t){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=t},this.getFreshValueHex=function(){return this.hV},void 0!==t&&("string"==typeof t?this.setString(t):void 0!==t.str?this.setString(t.str):void 0!==t.hex&&this.setStringHex(t.hex))},X.lang.extend(Q.asn1.DERAbstractString,Q.asn1.ASN1Object),Q.asn1.DERAbstractTime=function(t){Q.asn1.DERAbstractTime.superclass.constructor.call(this),this.localDateToUTC=function(t){return utc=t.getTime()+6e4*t.getTimezoneOffset(),new Date(utc)},this.formatDate=function(t,e,n){var r=this.zeroPadding,i=this.localDateToUTC(t),s=String(i.getFullYear());"utc"==e&&(s=s.substr(2,2));var o=s+r(String(i.getMonth()+1),2)+r(String(i.getDate()),2)+r(String(i.getHours()),2)+r(String(i.getMinutes()),2)+r(String(i.getSeconds()),2);if(!0===n){var a=i.getMilliseconds();if(0!=a){var c=r(String(a),3);o=o+"."+(c=c.replace(/[0]+$/,""))}}return o+"Z"},this.zeroPadding=function(t,e){return t.length>=e?t:new Array(e-t.length+1).join("0")+t},this.getString=function(){return this.s},this.setString=function(t){this.hTLV=null,this.isModified=!0,this.s=t,this.hV=stohex(t)},this.setByDateValue=function(t,e,n,r,i,s){var o=new Date(Date.UTC(t,e-1,n,r,i,s,0));this.setByDate(o)},this.getFreshValueHex=function(){return this.hV}},X.lang.extend(Q.asn1.DERAbstractTime,Q.asn1.ASN1Object),Q.asn1.DERAbstractStructured=function(t){Q.asn1.DERAbstractString.superclass.constructor.call(this),this.setByASN1ObjectArray=function(t){this.hTLV=null,this.isModified=!0,this.asn1Array=t},this.appendASN1Object=function(t){this.hTLV=null,this.isModified=!0,this.asn1Array.push(t)},this.asn1Array=new Array,void 0!==t&&void 0!==t.array&&(this.asn1Array=t.array)},X.lang.extend(Q.asn1.DERAbstractStructured,Q.asn1.ASN1Object),Q.asn1.DERBoolean=function(){Q.asn1.DERBoolean.superclass.constructor.call(this),this.hT="01",this.hTLV="0101ff"},X.lang.extend(Q.asn1.DERBoolean,Q.asn1.ASN1Object),Q.asn1.DERInteger=function(t){Q.asn1.DERInteger.superclass.constructor.call(this),this.hT="02",this.setByBigInteger=function(t){this.hTLV=null,this.isModified=!0,this.hV=Q.asn1.ASN1Util.bigIntToMinTwosComplementsHex(t)},this.setByInteger=function(t){var e=new I(String(t),10);this.setByBigInteger(e)},this.setValueHex=function(t){this.hV=t},this.getFreshValueHex=function(){return this.hV},void 0!==t&&(void 0!==t.bigint?this.setByBigInteger(t.bigint):void 0!==t.int?this.setByInteger(t.int):"number"==typeof t?this.setByInteger(t):void 0!==t.hex&&this.setValueHex(t.hex))},X.lang.extend(Q.asn1.DERInteger,Q.asn1.ASN1Object),Q.asn1.DERBitString=function(t){if(void 0!==t&&void 0!==t.obj){var e=Q.asn1.ASN1Util.newObject(t.obj);t.hex="00"+e.getEncodedHex()}Q.asn1.DERBitString.superclass.constructor.call(this),this.hT="03",this.setHexValueIncludingUnusedBits=function(t){this.hTLV=null,this.isModified=!0,this.hV=t},this.setUnusedBitsAndHexValue=function(t,e){if(t<0||7<t)throw"unused bits shall be from 0 to 7: u = "+t;var n="0"+t;this.hTLV=null,this.isModified=!0,this.hV=n+e},this.setByBinaryString=function(t){var e=8-(t=t.replace(/0+$/,"")).length%8;8==e&&(e=0);for(var n=0;n<=e;n++)t+="0";var r="";for(n=0;n<t.length-1;n+=8){var i=t.substr(n,8),s=parseInt(i,2).toString(16);1==s.length&&(s="0"+s),r+=s}this.hTLV=null,this.isModified=!0,this.hV="0"+e+r},this.setByBooleanArray=function(t){for(var e="",n=0;n<t.length;n++)1==t[n]?e+="1":e+="0";this.setByBinaryString(e)},this.newFalseArray=function(t){for(var e=new Array(t),n=0;n<t;n++)e[n]=!1;return e},this.getFreshValueHex=function(){return this.hV},void 0!==t&&("string"==typeof t&&t.toLowerCase().match(/^[0-9a-f]+$/)?this.setHexValueIncludingUnusedBits(t):void 0!==t.hex?this.setHexValueIncludingUnusedBits(t.hex):void 0!==t.bin?this.setByBinaryString(t.bin):void 0!==t.array&&this.setByBooleanArray(t.array))},X.lang.extend(Q.asn1.DERBitString,Q.asn1.ASN1Object),Q.asn1.DEROctetString=function(t){if(void 0!==t&&void 0!==t.obj){var e=Q.asn1.ASN1Util.newObject(t.obj);t.hex=e.getEncodedHex()}Q.asn1.DEROctetString.superclass.constructor.call(this,t),this.hT="04"},X.lang.extend(Q.asn1.DEROctetString,Q.asn1.DERAbstractString),Q.asn1.DERNull=function(){Q.asn1.DERNull.superclass.constructor.call(this),this.hT="05",this.hTLV="0500"},X.lang.extend(Q.asn1.DERNull,Q.asn1.ASN1Object),Q.asn1.DERObjectIdentifier=function(t){var e=function(t){var e=t.toString(16);return 1==e.length&&(e="0"+e),e},n=function(t){var n="",r=new I(t,10).toString(2),i=7-r.length%7;7==i&&(i=0);for(var s="",o=0;o<i;o++)s+="0";for(r=s+r,o=0;o<r.length-1;o+=7){var a=r.substr(o,7);o!=r.length-7&&(a="1"+a),n+=e(parseInt(a,2))}return n};Q.asn1.DERObjectIdentifier.superclass.constructor.call(this),this.hT="06",this.setValueHex=function(t){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=t},this.setValueOidString=function(t){if(!t.match(/^[0-9.]+$/))throw"malformed oid string: "+t;var r="",i=t.split("."),s=40*parseInt(i[0])+parseInt(i[1]);r+=e(s),i.splice(0,2);for(var o=0;o<i.length;o++)r+=n(i[o]);this.hTLV=null,this.isModified=!0,this.s=null,this.hV=r},this.setValueName=function(t){var e=Q.asn1.x509.OID.name2oid(t);if(""===e)throw"DERObjectIdentifier oidName undefined: "+t;this.setValueOidString(e)},this.getFreshValueHex=function(){return this.hV},void 0!==t&&("string"==typeof t?t.match(/^[0-2].[0-9.]+$/)?this.setValueOidString(t):this.setValueName(t):void 0!==t.oid?this.setValueOidString(t.oid):void 0!==t.hex?this.setValueHex(t.hex):void 0!==t.name&&this.setValueName(t.name))},X.lang.extend(Q.asn1.DERObjectIdentifier,Q.asn1.ASN1Object),Q.asn1.DEREnumerated=function(t){Q.asn1.DEREnumerated.superclass.constructor.call(this),this.hT="0a",this.setByBigInteger=function(t){this.hTLV=null,this.isModified=!0,this.hV=Q.asn1.ASN1Util.bigIntToMinTwosComplementsHex(t)},this.setByInteger=function(t){var e=new I(String(t),10);this.setByBigInteger(e)},this.setValueHex=function(t){this.hV=t},this.getFreshValueHex=function(){return this.hV},void 0!==t&&(void 0!==t.int?this.setByInteger(t.int):"number"==typeof t?this.setByInteger(t):void 0!==t.hex&&this.setValueHex(t.hex))},X.lang.extend(Q.asn1.DEREnumerated,Q.asn1.ASN1Object),Q.asn1.DERUTF8String=function(t){Q.asn1.DERUTF8String.superclass.constructor.call(this,t),this.hT="0c"},X.lang.extend(Q.asn1.DERUTF8String,Q.asn1.DERAbstractString),Q.asn1.DERNumericString=function(t){Q.asn1.DERNumericString.superclass.constructor.call(this,t),this.hT="12"},X.lang.extend(Q.asn1.DERNumericString,Q.asn1.DERAbstractString),Q.asn1.DERPrintableString=function(t){Q.asn1.DERPrintableString.superclass.constructor.call(this,t),this.hT="13"},X.lang.extend(Q.asn1.DERPrintableString,Q.asn1.DERAbstractString),Q.asn1.DERTeletexString=function(t){Q.asn1.DERTeletexString.superclass.constructor.call(this,t),this.hT="14"},X.lang.extend(Q.asn1.DERTeletexString,Q.asn1.DERAbstractString),Q.asn1.DERIA5String=function(t){Q.asn1.DERIA5String.superclass.constructor.call(this,t),this.hT="16"},X.lang.extend(Q.asn1.DERIA5String,Q.asn1.DERAbstractString),Q.asn1.DERUTCTime=function(t){Q.asn1.DERUTCTime.superclass.constructor.call(this,t),this.hT="17",this.setByDate=function(t){this.hTLV=null,this.isModified=!0,this.date=t,this.s=this.formatDate(this.date,"utc"),this.hV=stohex(this.s)},this.getFreshValueHex=function(){return void 0===this.date&&void 0===this.s&&(this.date=new Date,this.s=this.formatDate(this.date,"utc"),this.hV=stohex(this.s)),this.hV},void 0!==t&&(void 0!==t.str?this.setString(t.str):"string"==typeof t&&t.match(/^[0-9]{12}Z$/)?this.setString(t):void 0!==t.hex?this.setStringHex(t.hex):void 0!==t.date&&this.setByDate(t.date))},X.lang.extend(Q.asn1.DERUTCTime,Q.asn1.DERAbstractTime),Q.asn1.DERGeneralizedTime=function(t){Q.asn1.DERGeneralizedTime.superclass.constructor.call(this,t),this.hT="18",this.withMillis=!1,this.setByDate=function(t){this.hTLV=null,this.isModified=!0,this.date=t,this.s=this.formatDate(this.date,"gen",this.withMillis),this.hV=stohex(this.s)},this.getFreshValueHex=function(){return void 0===this.date&&void 0===this.s&&(this.date=new Date,this.s=this.formatDate(this.date,"gen",this.withMillis),this.hV=stohex(this.s)),this.hV},void 0!==t&&(void 0!==t.str?this.setString(t.str):"string"==typeof t&&t.match(/^[0-9]{14}Z$/)?this.setString(t):void 0!==t.hex?this.setStringHex(t.hex):void 0!==t.date&&this.setByDate(t.date),!0===t.millis&&(this.withMillis=!0))},X.lang.extend(Q.asn1.DERGeneralizedTime,Q.asn1.DERAbstractTime),Q.asn1.DERSequence=function(t){Q.asn1.DERSequence.superclass.constructor.call(this,t),this.hT="30",this.getFreshValueHex=function(){for(var t="",e=0;e<this.asn1Array.length;e++)t+=this.asn1Array[e].getEncodedHex();return this.hV=t,this.hV}},X.lang.extend(Q.asn1.DERSequence,Q.asn1.DERAbstractStructured),Q.asn1.DERSet=function(t){Q.asn1.DERSet.superclass.constructor.call(this,t),this.hT="31",this.sortFlag=!0,this.getFreshValueHex=function(){for(var t=new Array,e=0;e<this.asn1Array.length;e++){var n=this.asn1Array[e];t.push(n.getEncodedHex())}return 1==this.sortFlag&&t.sort(),this.hV=t.join(""),this.hV},void 0!==t&&void 0!==t.sortflag&&0==t.sortflag&&(this.sortFlag=!1)},X.lang.extend(Q.asn1.DERSet,Q.asn1.DERAbstractStructured),Q.asn1.DERTaggedObject=function(t){Q.asn1.DERTaggedObject.superclass.constructor.call(this),this.hT="a0",this.hV="",this.isExplicit=!0,this.asn1Object=null,this.setASN1Object=function(t,e,n){this.hT=e,this.isExplicit=t,this.asn1Object=n,this.isExplicit?(this.hV=this.asn1Object.getEncodedHex(),this.hTLV=null,this.isModified=!0):(this.hV=null,this.hTLV=n.getEncodedHex(),this.hTLV=this.hTLV.replace(/^../,e),this.isModified=!1)},this.getFreshValueHex=function(){return this.hV},void 0!==t&&(void 0!==t.tag&&(this.hT=t.tag),void 0!==t.explicit&&(this.isExplicit=t.explicit),void 0!==t.obj&&(this.asn1Object=t.obj,this.setASN1Object(this.isExplicit,this.hT,this.asn1Object)))},X.lang.extend(Q.asn1.DERTaggedObject,Q.asn1.ASN1Object);var tt,et,nt=(tt=function(t,e){return(tt=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}tt(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),rt=function(t){function e(n){var r=t.call(this)||this;return n&&("string"==typeof n?r.parseKey(n):(e.hasPrivateKeyProperty(n)||e.hasPublicKeyProperty(n))&&r.parsePropertiesFrom(n)),r}return nt(e,t),e.prototype.parseKey=function(t){try{var e=0,n=0,r=/^\s*(?:[0-9A-Fa-f][0-9A-Fa-f]\s*)+$/.test(t)?function(t){var e;if(void 0===u){var n="0123456789ABCDEF",r=" \f\n\r\t \u2028\u2029";for(u={},e=0;e<16;++e)u[n.charAt(e)]=e;for(n=n.toLowerCase(),e=10;e<16;++e)u[n.charAt(e)]=e;for(e=0;e<r.length;++e)u[r.charAt(e)]=-1}var i=[],s=0,o=0;for(e=0;e<t.length;++e){var a=t.charAt(e);if("="==a)break;if(-1!=(a=u[a])){if(void 0===a)throw new Error("Illegal character at offset "+e);s|=a,++o>=2?(i[i.length]=s,s=0,o=0):s<<=4}}if(o)throw new Error("Hex encoding incomplete: 4 bits missing");return i}(t):p.unarmor(t),i=b.decode(r);if(3===i.sub.length&&(i=i.sub[2].sub[0]),9===i.sub.length){e=i.sub[1].getHexStringValue(),this.n=P(e,16),n=i.sub[2].getHexStringValue(),this.e=parseInt(n,16);var s=i.sub[3].getHexStringValue();this.d=P(s,16);var o=i.sub[4].getHexStringValue();this.p=P(o,16);var a=i.sub[5].getHexStringValue();this.q=P(a,16);var c=i.sub[6].getHexStringValue();this.dmp1=P(c,16);var l=i.sub[7].getHexStringValue();this.dmq1=P(l,16);var h=i.sub[8].getHexStringValue();this.coeff=P(h,16)}else{if(2!==i.sub.length)return!1;if(i.sub[0].sub){var f=i.sub[1].sub[0];e=f.sub[0].getHexStringValue(),this.n=P(e,16),n=f.sub[1].getHexStringValue(),this.e=parseInt(n,16)}else e=i.sub[0].getHexStringValue(),this.n=P(e,16),n=i.sub[1].getHexStringValue(),this.e=parseInt(n,16)}return!0}catch(d){return!1}},e.prototype.getPrivateBaseKey=function(){var t={array:[new Q.asn1.DERInteger({int:0}),new Q.asn1.DERInteger({bigint:this.n}),new Q.asn1.DERInteger({int:this.e}),new Q.asn1.DERInteger({bigint:this.d}),new Q.asn1.DERInteger({bigint:this.p}),new Q.asn1.DERInteger({bigint:this.q}),new Q.asn1.DERInteger({bigint:this.dmp1}),new Q.asn1.DERInteger({bigint:this.dmq1}),new Q.asn1.DERInteger({bigint:this.coeff})]};return new Q.asn1.DERSequence(t).getEncodedHex()},e.prototype.getPrivateBaseKeyB64=function(){return h(this.getPrivateBaseKey())},e.prototype.getPublicBaseKey=function(){var t=new Q.asn1.DERSequence({array:[new Q.asn1.DERObjectIdentifier({oid:"1.2.840.113549.1.1.1"}),new Q.asn1.DERNull]}),e=new Q.asn1.DERSequence({array:[new Q.asn1.DERInteger({bigint:this.n}),new Q.asn1.DERInteger({int:this.e})]}),n=new Q.asn1.DERBitString({hex:"00"+e.getEncodedHex()});return new Q.asn1.DERSequence({array:[t,n]}).getEncodedHex()},e.prototype.getPublicBaseKeyB64=function(){return h(this.getPublicBaseKey())},e.wordwrap=function(t,e){if(!t)return t;var n="(.{1,"+(e=e||64)+"})( +|$\n?)|(.{1,"+e+"})";return t.match(RegExp(n,"g")).join("\n")},e.prototype.getPrivateKey=function(){var t="-----BEGIN RSA PRIVATE KEY-----\n";return(t+=e.wordwrap(this.getPrivateBaseKeyB64())+"\n")+"-----END RSA PRIVATE KEY-----"},e.prototype.getPublicKey=function(){var t="-----BEGIN PUBLIC KEY-----\n";return(t+=e.wordwrap(this.getPublicBaseKeyB64())+"\n")+"-----END PUBLIC KEY-----"},e.hasPublicKeyProperty=function(t){return(t=t||{}).hasOwnProperty("n")&&t.hasOwnProperty("e")},e.hasPrivateKeyProperty=function(t){return(t=t||{}).hasOwnProperty("n")&&t.hasOwnProperty("e")&&t.hasOwnProperty("d")&&t.hasOwnProperty("p")&&t.hasOwnProperty("q")&&t.hasOwnProperty("dmp1")&&t.hasOwnProperty("dmq1")&&t.hasOwnProperty("coeff")},e.prototype.parsePropertiesFrom=function(t){this.n=t.n,this.e=t.e,t.hasOwnProperty("d")&&(this.d=t.d,this.p=t.p,this.q=t.q,this.dmp1=t.dmp1,this.dmq1=t.dmq1,this.coeff=t.coeff)},e}(Y),it=n(155),st=void 0!==it?null===(et=it.env)||void 0===et?void 0:"3.3.1":void 0;const ot=function(){function t(t){void 0===t&&(t={}),t=t||{},this.default_key_size=t.default_key_size?parseInt(t.default_key_size,10):1024,this.default_public_exponent=t.default_public_exponent||"010001",this.log=t.log||!1,this.key=null}return t.prototype.setKey=function(t){this.log&&this.key&&console.warn("A key was already set, overriding existing."),this.key=new rt(t)},t.prototype.setPrivateKey=function(t){this.setKey(t)},t.prototype.setPublicKey=function(t){this.setKey(t)},t.prototype.decrypt=function(t){try{return this.getKey().decrypt(f(t))}catch(e){return!1}},t.prototype.encrypt=function(t){try{return h(this.getKey().encrypt(t))}catch(e){return!1}},t.prototype.sign=function(t,e,n){try{return h(this.getKey().sign(t,e,n))}catch(r){return!1}},t.prototype.verify=function(t,e,n){try{return this.getKey().verify(t,f(e),n)}catch(r){return!1}},t.prototype.getKey=function(t){if(!this.key){if(this.key=new rt,t&&"[object Function]"==={}.toString.call(t))return void this.key.generateAsync(this.default_key_size,this.default_public_exponent,t);this.key.generate(this.default_key_size,this.default_public_exponent)}return this.key},t.prototype.getPrivateKey=function(){return this.getKey().getPrivateKey()},t.prototype.getPrivateKeyB64=function(){return this.getKey().getPrivateBaseKeyB64()},t.prototype.getPublicKey=function(){return this.getKey().getPublicKey()},t.prototype.getPublicKeyB64=function(){return this.getKey().getPublicBaseKeyB64()},t.version=st,t}()})(),r.default})(),ba();const Ea={pages:[{path:"pages/realName/realName",style:{navigationBarTitleText:"实名页面",navigationStyle:"custom"}},{path:"pages/login/login",style:{navigationBarTitleText:"登录页面",navigationStyle:"custom"}},{path:"pages/index/index",style:{navigationBarTitleText:"客户首页",navigationStyle:"custom",enablePullDownRefresh:!0}},{path:"pages/my/my",style:{navigationBarTitleText:"客户信息",navigationStyle:"custom"}},{path:"pages/carDetail/carDetail",style:{navigationBarTitleText:"车辆信息",navigationBarBackgroundColor:"#FFFFFF",navigationStyle:"custom"}},{path:"pages/privacy/privacy",style:{navigationBarTitleText:"隐私政策"}},{path:"pages/companyHome/companyHome",style:{navigationBarTitleText:"公司员工首页",navigationStyle:"custom",enablePullDownRefresh:!0}},{path:"pages/companyMy/companyMy",style:{navigationBarTitleText:"公司员工信息",navigationStyle:"custom"}},{path:"pages/ownerDetail/ownerDetail",style:{navigationBarTitleText:"车主信息",navigationStyle:"custom"}},{path:"pages/societyHome/societyHome",style:{navigationBarTitleText:"协会员工首页",navigationStyle:"custom",enablePullDownRefresh:!0}},{path:"pages/societyMy/societyMy",style:{navigationBarTitleText:"协会员工信息",navigationStyle:"custom"}},{path:"pages/employeeRealName/employeeRealName",style:{navigationBarTitleText:"员工实名页面",navigationStyle:"custom"}},{path:"pages/societyOrder/societyOrder",style:{navigationBarTitleText:"协会保单页",navigationStyle:"custom",enablePullDownRefresh:!0}}],tabBar:{color:"#707070",selectedColor:"#3680FE",borderStyle:"black",backgroundColor:"#ffffff",list:[{pagePath:"pages/index/index",iconPath:"static/tabbarIcon/car.png",selectedIconPath:"static/tabbarIcon/car-active.png",text:"车辆管理"},{pagePath:"pages/my/my",iconPath:"static/tabbarIcon/my.png",selectedIconPath:"static/tabbarIcon/my-active.png",text:"我的"}]},easycom:{autoscan:!0,custom:{"^u--(.*)":"@/uni_modules/uview-plus/components/u-$1/u-$1.vue","^up-(.*)":"@/uni_modules/uview-plus/components/u-$1/u-$1.vue","^u-([^-].*)":"@/uni_modules/uview-plus/components/u-$1/u-$1.vue"}},globalStyle:{navigationBarTextStyle:"black",navigationBarTitleText:"uni-app",navigationBarBackgroundColor:"#F8F8F8",backgroundColor:"#F8F8F8"},uniIdRouter:{},condition:{current:0,list:[{name:"test",path:"pages/login/login",query:""}]}};function Ta(t,e,n){return t(n={path:e,exports:{},require:function(t,e){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==e&&n.path)}},n.exports),n.exports}var xa=Ta((function(t,e){var n;t.exports=(n=n||function(t,e){var n=Object.create||function(){function t(){}return function(e){var n;return t.prototype=e,n=new t,t.prototype=null,n}}(),r={},i=r.lib={},s=i.Base={extend:function(t){var e=n(this);return t&&e.mixIn(t),e.hasOwnProperty("init")&&this.init!==e.init||(e.init=function(){e.$super.init.apply(this,arguments)}),e.init.prototype=e,e.$super=this,e},create:function(){var t=this.extend();return t.init.apply(t,arguments),t},init:function(){},mixIn:function(t){for(var e in t)t.hasOwnProperty(e)&&(this[e]=t[e]);t.hasOwnProperty("toString")&&(this.toString=t.toString)},clone:function(){return this.init.prototype.extend(this)}},o=i.WordArray=s.extend({init:function(t,e){t=this.words=t||[],this.sigBytes=null!=e?e:4*t.length},toString:function(t){return(t||c).stringify(this)},concat:function(t){var e=this.words,n=t.words,r=this.sigBytes,i=t.sigBytes;if(this.clamp(),r%4)for(var s=0;s<i;s++){var o=n[s>>>2]>>>24-s%4*8&255;e[r+s>>>2]|=o<<24-(r+s)%4*8}else for(s=0;s<i;s+=4)e[r+s>>>2]=n[s>>>2];return this.sigBytes+=i,this},clamp:function(){var e=this.words,n=this.sigBytes;e[n>>>2]&=4294967295<<32-n%4*8,e.length=t.ceil(n/4)},clone:function(){var t=s.clone.call(this);return t.words=this.words.slice(0),t},random:function(e){for(var n,r=[],i=function(e){var n=987654321,r=4294967295;return function(){var i=((n=36969*(65535&n)+(n>>16)&r)<<16)+(e=18e3*(65535&e)+(e>>16)&r)&r;return i/=4294967296,(i+=.5)*(t.random()>.5?1:-1)}},s=0;s<e;s+=4){var a=i(4294967296*(n||t.random()));n=987654071*a(),r.push(4294967296*a()|0)}return new o.init(r,e)}}),a=r.enc={},c=a.Hex={stringify:function(t){for(var e=t.words,n=t.sigBytes,r=[],i=0;i<n;i++){var s=e[i>>>2]>>>24-i%4*8&255;r.push((s>>>4).toString(16)),r.push((15&s).toString(16))}return r.join("")},parse:function(t){for(var e=t.length,n=[],r=0;r<e;r+=2)n[r>>>3]|=parseInt(t.substr(r,2),16)<<24-r%8*4;return new o.init(n,e/2)}},u=a.Latin1={stringify:function(t){for(var e=t.words,n=t.sigBytes,r=[],i=0;i<n;i++){var s=e[i>>>2]>>>24-i%4*8&255;r.push(String.fromCharCode(s))}return r.join("")},parse:function(t){for(var e=t.length,n=[],r=0;r<e;r++)n[r>>>2]|=(255&t.charCodeAt(r))<<24-r%4*8;return new o.init(n,e)}},l=a.Utf8={stringify:function(t){try{return decodeURIComponent(escape(u.stringify(t)))}catch(e){throw new Error("Malformed UTF-8 data")}},parse:function(t){return u.parse(unescape(encodeURIComponent(t)))}},h=i.BufferedBlockAlgorithm=s.extend({reset:function(){this._data=new o.init,this._nDataBytes=0},_append:function(t){"string"==typeof t&&(t=l.parse(t)),this._data.concat(t),this._nDataBytes+=t.sigBytes},_process:function(e){var n=this._data,r=n.words,i=n.sigBytes,s=this.blockSize,a=i/(4*s),c=(a=e?t.ceil(a):t.max((0|a)-this._minBufferSize,0))*s,u=t.min(4*c,i);if(c){for(var l=0;l<c;l+=s)this._doProcessBlock(r,l);var h=r.splice(0,c);n.sigBytes-=u}return new o.init(h,u)},clone:function(){var t=s.clone.call(this);return t._data=this._data.clone(),t},_minBufferSize:0});i.Hasher=h.extend({cfg:s.extend(),init:function(t){this.cfg=this.cfg.extend(t),this.reset()},reset:function(){h.reset.call(this),this._doReset()},update:function(t){return this._append(t),this._process(),this},finalize:function(t){return t&&this._append(t),this._doFinalize()},blockSize:16,_createHelper:function(t){return function(e,n){return new t.init(n).finalize(e)}},_createHmacHelper:function(t){return function(e,n){return new f.HMAC.init(t,n).finalize(e)}}});var f=r.algo={};return r}(Math),n)})),Ia=xa,Da=(Ta((function(t,e){var n;t.exports=(n=Ia,function(t){var e=n,r=e.lib,i=r.WordArray,s=r.Hasher,o=e.algo,a=[];!function(){for(var e=0;e<64;e++)a[e]=4294967296*t.abs(t.sin(e+1))|0}();var c=o.MD5=s.extend({_doReset:function(){this._hash=new i.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(t,e){for(var n=0;n<16;n++){var r=e+n,i=t[r];t[r]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var s=this._hash.words,o=t[e+0],c=t[e+1],d=t[e+2],p=t[e+3],g=t[e+4],m=t[e+5],y=t[e+6],v=t[e+7],_=t[e+8],w=t[e+9],S=t[e+10],b=t[e+11],E=t[e+12],T=t[e+13],x=t[e+14],I=t[e+15],D=s[0],A=s[1],k=s[2],O=s[3];D=u(D,A,k,O,o,7,a[0]),O=u(O,D,A,k,c,12,a[1]),k=u(k,O,D,A,d,17,a[2]),A=u(A,k,O,D,p,22,a[3]),D=u(D,A,k,O,g,7,a[4]),O=u(O,D,A,k,m,12,a[5]),k=u(k,O,D,A,y,17,a[6]),A=u(A,k,O,D,v,22,a[7]),D=u(D,A,k,O,_,7,a[8]),O=u(O,D,A,k,w,12,a[9]),k=u(k,O,D,A,S,17,a[10]),A=u(A,k,O,D,b,22,a[11]),D=u(D,A,k,O,E,7,a[12]),O=u(O,D,A,k,T,12,a[13]),k=u(k,O,D,A,x,17,a[14]),D=l(D,A=u(A,k,O,D,I,22,a[15]),k,O,c,5,a[16]),O=l(O,D,A,k,y,9,a[17]),k=l(k,O,D,A,b,14,a[18]),A=l(A,k,O,D,o,20,a[19]),D=l(D,A,k,O,m,5,a[20]),O=l(O,D,A,k,S,9,a[21]),k=l(k,O,D,A,I,14,a[22]),A=l(A,k,O,D,g,20,a[23]),D=l(D,A,k,O,w,5,a[24]),O=l(O,D,A,k,x,9,a[25]),k=l(k,O,D,A,p,14,a[26]),A=l(A,k,O,D,_,20,a[27]),D=l(D,A,k,O,T,5,a[28]),O=l(O,D,A,k,d,9,a[29]),k=l(k,O,D,A,v,14,a[30]),D=h(D,A=l(A,k,O,D,E,20,a[31]),k,O,m,4,a[32]),O=h(O,D,A,k,_,11,a[33]),k=h(k,O,D,A,b,16,a[34]),A=h(A,k,O,D,x,23,a[35]),D=h(D,A,k,O,c,4,a[36]),O=h(O,D,A,k,g,11,a[37]),k=h(k,O,D,A,v,16,a[38]),A=h(A,k,O,D,S,23,a[39]),D=h(D,A,k,O,T,4,a[40]),O=h(O,D,A,k,o,11,a[41]),k=h(k,O,D,A,p,16,a[42]),A=h(A,k,O,D,y,23,a[43]),D=h(D,A,k,O,w,4,a[44]),O=h(O,D,A,k,E,11,a[45]),k=h(k,O,D,A,I,16,a[46]),D=f(D,A=h(A,k,O,D,d,23,a[47]),k,O,o,6,a[48]),O=f(O,D,A,k,v,10,a[49]),k=f(k,O,D,A,x,15,a[50]),A=f(A,k,O,D,m,21,a[51]),D=f(D,A,k,O,E,6,a[52]),O=f(O,D,A,k,p,10,a[53]),k=f(k,O,D,A,S,15,a[54]),A=f(A,k,O,D,c,21,a[55]),D=f(D,A,k,O,_,6,a[56]),O=f(O,D,A,k,I,10,a[57]),k=f(k,O,D,A,y,15,a[58]),A=f(A,k,O,D,T,21,a[59]),D=f(D,A,k,O,g,6,a[60]),O=f(O,D,A,k,b,10,a[61]),k=f(k,O,D,A,d,15,a[62]),A=f(A,k,O,D,w,21,a[63]),s[0]=s[0]+D|0,s[1]=s[1]+A|0,s[2]=s[2]+k|0,s[3]=s[3]+O|0},_doFinalize:function(){var e=this._data,n=e.words,r=8*this._nDataBytes,i=8*e.sigBytes;n[i>>>5]|=128<<24-i%32;var s=t.floor(r/4294967296),o=r;n[15+(i+64>>>9<<4)]=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8),n[14+(i+64>>>9<<4)]=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),e.sigBytes=4*(n.length+1),this._process();for(var a=this._hash,c=a.words,u=0;u<4;u++){var l=c[u];c[u]=16711935&(l<<8|l>>>24)|4278255360&(l<<24|l>>>8)}return a},clone:function(){var t=s.clone.call(this);return t._hash=this._hash.clone(),t}});function u(t,e,n,r,i,s,o){var a=t+(e&n|~e&r)+i+o;return(a<<s|a>>>32-s)+e}function l(t,e,n,r,i,s,o){var a=t+(e&r|n&~r)+i+o;return(a<<s|a>>>32-s)+e}function h(t,e,n,r,i,s,o){var a=t+(e^n^r)+i+o;return(a<<s|a>>>32-s)+e}function f(t,e,n,r,i,s,o){var a=t+(n^(e|~r))+i+o;return(a<<s|a>>>32-s)+e}e.MD5=s._createHelper(c),e.HmacMD5=s._createHmacHelper(c)}(Math),n.MD5)})),Ta((function(t,e){var n,r,i;t.exports=(r=(n=Ia).lib.Base,i=n.enc.Utf8,void(n.algo.HMAC=r.extend({init:function(t,e){t=this._hasher=new t.init,"string"==typeof e&&(e=i.parse(e));var n=t.blockSize,r=4*n;e.sigBytes>r&&(e=t.finalize(e)),e.clamp();for(var s=this._oKey=e.clone(),o=this._iKey=e.clone(),a=s.words,c=o.words,u=0;u<n;u++)a[u]^=1549556828,c[u]^=909522486;s.sigBytes=o.sigBytes=r,this.reset()},reset:function(){var t=this._hasher;t.reset(),t.update(this._iKey)},update:function(t){return this._hasher.update(t),this},finalize:function(t){var e=this._hasher,n=e.finalize(t);return e.reset(),e.finalize(this._oKey.clone().concat(n))}})))})),Ta((function(t,e){t.exports=Ia.HmacMD5}))),Aa=Ta((function(t,e){t.exports=Ia.enc.Utf8})),ka=Ta((function(t,e){var n,r,i;t.exports=(i=(r=n=Ia).lib.WordArray,r.enc.Base64={stringify:function(t){var e=t.words,n=t.sigBytes,r=this._map;t.clamp();for(var i=[],s=0;s<n;s+=3)for(var o=(e[s>>>2]>>>24-s%4*8&255)<<16|(e[s+1>>>2]>>>24-(s+1)%4*8&255)<<8|e[s+2>>>2]>>>24-(s+2)%4*8&255,a=0;a<4&&s+.75*a<n;a++)i.push(r.charAt(o>>>6*(3-a)&63));var c=r.charAt(64);if(c)for(;i.length%4;)i.push(c);return i.join("")},parse:function(t){var e=t.length,n=this._map,r=this._reverseMap;if(!r){r=this._reverseMap=[];for(var s=0;s<n.length;s++)r[n.charCodeAt(s)]=s}var o=n.charAt(64);if(o){var a=t.indexOf(o);-1!==a&&(e=a)}return function(t,e,n){for(var r=[],s=0,o=0;o<e;o++)if(o%4){var a=n[t.charCodeAt(o-1)]<<o%4*2,c=n[t.charCodeAt(o)]>>>6-o%4*2;r[s>>>2]|=(a|c)<<24-s%4*8,s++}return i.create(r,s)}(t,e,r)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="},n.enc.Base64)}));const Oa="uni_id_token",Ra="uni_id_token_expired",Pa="FUNCTION",Ma="OBJECT",Ca="CLIENT_DB",Ba="pending",Na="rejected";function La(t){return Object.prototype.toString.call(t).slice(8,-1).toLowerCase()}function ja(t){return"object"===La(t)}function Va(t){return"function"==typeof t}function Ua(t){return function(){try{return t.apply(t,arguments)}catch(e){console.error(e)}}}const $a="REJECTED",Ha="NOT_PENDING";class qa{constructor({createPromise:t,retryRule:e=$a}={}){this.createPromise=t,this.status=null,this.promise=null,this.retryRule=e}get needRetry(){if(!this.status)return!0;switch(this.retryRule){case $a:return this.status===Na;case Ha:return this.status!==Ba}}exec(){return this.needRetry?(this.status=Ba,this.promise=this.createPromise().then((t=>(this.status="fulfilled",Promise.resolve(t))),(t=>(this.status=Na,Promise.reject(t)))),this.promise):this.promise}}function Fa(t){return t&&"string"==typeof t?JSON.parse(t):t}const Ka=Fa([]),za="mp-weixin";Fa("");const Wa=Fa("[]")||[];let Ja="";try{Ja="__UNI__65AAA9F"}catch(ba){}let Ga={};function Ya(t,e={}){var n,r;return n=Ga,r=t,Object.prototype.hasOwnProperty.call(n,r)||(Ga[t]=e),Ga[t]}const Za=["invoke","success","fail","complete"],Xa=Ya("_globalUniCloudInterceptor");function Qa(t,e){Xa[t]||(Xa[t]={}),ja(e)&&Object.keys(e).forEach((n=>{Za.indexOf(n)>-1&&function(t,e,n){let r=Xa[t][e];r||(r=Xa[t][e]=[]),-1===r.indexOf(n)&&Va(n)&&r.push(n)}(t,n,e[n])}))}function tc(t,e){Xa[t]||(Xa[t]={}),ja(e)?Object.keys(e).forEach((n=>{Za.indexOf(n)>-1&&function(t,e,n){const r=Xa[t][e];if(!r)return;const i=r.indexOf(n);i>-1&&r.splice(i,1)}(t,n,e[n])})):delete Xa[t]}function ec(t,e){return t&&0!==t.length?t.reduce(((t,n)=>t.then((()=>n(e)))),Promise.resolve()):Promise.resolve()}function nc(t,e){return Xa[t]&&Xa[t][e]||[]}function rc(t){Qa("callObject",t)}const ic=Ya("_globalUniCloudListener"),sc="response",oc="needLogin",ac="refreshToken",cc="clientdb",uc="cloudfunction",lc="cloudobject";function hc(t){return ic[t]||(ic[t]=[]),ic[t]}function fc(t,e){const n=hc(t);n.includes(e)||n.push(e)}function dc(t,e){const n=hc(t),r=n.indexOf(e);-1!==r&&n.splice(r,1)}function pc(t,e){const n=hc(t);for(let r=0;r<n.length;r++)(0,n[r])(e)}let gc,mc=!1;function yc(){return gc||(gc=new Promise((t=>{mc&&t(),function e(){if("function"==typeof getCurrentPages){const e=getCurrentPages();e&&e[0]&&(mc=!0,t())}mc||setTimeout((()=>{e()}),30)}()})),gc)}function vc(t){const e={};for(const n in t){const r=t[n];Va(r)&&(e[n]=Ua(r))}return e}class _c extends Error{constructor(t){super(t.message),this.errMsg=t.message||t.errMsg||"unknown system error",this.code=this.errCode=t.code||t.errCode||"SYSTEM_ERROR",this.errSubject=this.subject=t.subject||t.errSubject,this.cause=t.cause,this.requestId=t.requestId}toJson(t=0){if(!(t>=10))return t++,{errCode:this.errCode,errMsg:this.errMsg,errSubject:this.errSubject,cause:this.cause&&this.cause.toJson?this.cause.toJson(t):this.cause}}}var wc={request:t=>en.request(t),uploadFile:t=>en.uploadFile(t),setStorageSync:(t,e)=>en.setStorageSync(t,e),getStorageSync:t=>en.getStorageSync(t),removeStorageSync:t=>en.removeStorageSync(t),clearStorageSync:()=>en.clearStorageSync(),connectSocket:t=>en.connectSocket(t)};function Sc(t){return t&&Sc(t.__v_raw)||t}function bc(){return{token:wc.getStorageSync(Oa)||wc.getStorageSync("uniIdToken"),tokenExpired:wc.getStorageSync(Ra)}}function Ec({token:t,tokenExpired:e}={}){t&&wc.setStorageSync(Oa,t),e&&wc.setStorageSync(Ra,e)}let Tc,xc;function Ic(){return Tc||(Tc=en.getSystemInfoSync()),Tc}function Dc(){let t,e;try{if(en.getLaunchOptionsSync){if(en.getLaunchOptionsSync.toString().indexOf("not yet implemented")>-1)return;const{scene:n,channel:r}=en.getLaunchOptionsSync();t=r,e=n}}catch(n){}return{channel:t,scene:e}}let Ac={};function kc(){const t=en.getLocale&&en.getLocale()||"en";if(xc)return{...Ac,...xc,locale:t,LOCALE:t};const e=Ic(),{deviceId:n,osName:r,uniPlatform:i,appId:s}=e,o=["appId","appLanguage","appName","appVersion","appVersionCode","appWgtVersion","browserName","browserVersion","deviceBrand","deviceId","deviceModel","deviceType","osName","osVersion","romName","romVersion","ua","hostName","hostVersion","uniPlatform","uniRuntimeVersion","uniRuntimeVersionCode","uniCompilerVersion","uniCompilerVersionCode"];for(const a in e)Object.hasOwnProperty.call(e,a)&&-1===o.indexOf(a)&&delete e[a];return xc={PLATFORM:i,OS:r,APPID:s,DEVICEID:n,...Dc(),...e},{...Ac,...xc,locale:t,LOCALE:t}}var Oc=function(t,e){let n="";return Object.keys(t).sort().forEach((function(e){t[e]&&(n=n+"&"+e+"="+t[e])})),n=n.slice(1),Da(n,e).toString()},Rc=function(t,e){return new Promise(((n,r)=>{e(Object.assign(t,{complete(t){t||(t={});const e=t.data&&t.data.header&&t.data.header["x-serverless-request-id"]||t.header&&t.header["request-id"];if(!t.statusCode||t.statusCode>=400){const n=t.data&&t.data.error&&t.data.error.code||"SYS_ERR",i=t.data&&t.data.error&&t.data.error.message||t.errMsg||"request:fail";return r(new _c({code:n,message:i,requestId:e}))}const i=t.data;if(i.error)return r(new _c({code:i.error.code,message:i.error.message,requestId:e}));i.result=i.data,i.requestId=e,delete i.data,n(i)}}))}))},Pc=function(t){return ka.stringify(Aa.parse(t))},Mc={init(t){const e=new class{constructor(t){["spaceId","clientSecret"].forEach((e=>{if(!Object.prototype.hasOwnProperty.call(t,e))throw new Error(`${e} required`)})),this.config=Object.assign({},{endpoint:0===t.spaceId.indexOf("mp-")?"https://api.next.bspapp.com":"https://api.bspapp.com"},t),this.config.provider="aliyun",this.config.requestUrl=this.config.endpoint+"/client",this.config.envType=this.config.envType||"public",this.config.accessTokenKey="access_token_"+this.config.spaceId,this.adapter=wc,this._getAccessTokenPromiseHub=new qa({createPromise:()=>this.requestAuth(this.setupRequest({method:"serverless.auth.user.anonymousAuthorize",params:"{}"},"auth")).then((t=>{if(!t.result||!t.result.accessToken)throw new _c({code:"AUTH_FAILED",message:"获取accessToken失败"});this.setAccessToken(t.result.accessToken)})),retryRule:Ha})}get hasAccessToken(){return!!this.accessToken}setAccessToken(t){this.accessToken=t}requestWrapped(t){return Rc(t,this.adapter.request)}requestAuth(t){return this.requestWrapped(t)}request(t,e){return Promise.resolve().then((()=>this.hasAccessToken?e?this.requestWrapped(t):this.requestWrapped(t).catch((e=>new Promise(((t,n)=>{!e||"GATEWAY_INVALID_TOKEN"!==e.code&&"InvalidParameter.InvalidToken"!==e.code?n(e):t()})).then((()=>this.getAccessToken())).then((()=>{const e=this.rebuildRequest(t);return this.request(e,!0)})))):this.getAccessToken().then((()=>{const e=this.rebuildRequest(t);return this.request(e,!0)}))))}rebuildRequest(t){const e=Object.assign({},t);return e.data.token=this.accessToken,e.header["x-basement-token"]=this.accessToken,e.header["x-serverless-sign"]=Oc(e.data,this.config.clientSecret),e}setupRequest(t,e){const n=Object.assign({},t,{spaceId:this.config.spaceId,timestamp:Date.now()}),r={"Content-Type":"application/json"};return"auth"!==e&&(n.token=this.accessToken,r["x-basement-token"]=this.accessToken),r["x-serverless-sign"]=Oc(n,this.config.clientSecret),{url:this.config.requestUrl,method:"POST",data:n,dataType:"json",header:r}}getAccessToken(){return this._getAccessTokenPromiseHub.exec()}async authorize(){await this.getAccessToken()}callFunction(t){const e={method:"serverless.function.runtime.invoke",params:JSON.stringify({functionTarget:t.name,functionArgs:t.data||{}})};return this.request({...this.setupRequest(e),timeout:t.timeout})}getOSSUploadOptionsFromPath(t){const e={method:"serverless.file.resource.generateProximalSign",params:JSON.stringify(t)};return this.request(this.setupRequest(e))}uploadFileToOSS({url:t,formData:e,name:n,filePath:r,fileType:i,onUploadProgress:s}){return new Promise(((o,a)=>{const c=this.adapter.uploadFile({url:t,formData:e,name:n,filePath:r,fileType:i,header:{"X-OSS-server-side-encrpytion":"AES256"},success(t){t&&t.statusCode<400?o(t):a(new _c({code:"UPLOAD_FAILED",message:"文件上传失败"}))},fail(t){a(new _c({code:t.code||"UPLOAD_FAILED",message:t.message||t.errMsg||"文件上传失败"}))}});"function"==typeof s&&c&&"function"==typeof c.onProgressUpdate&&c.onProgressUpdate((t=>{s({loaded:t.totalBytesSent,total:t.totalBytesExpectedToSend})}))}))}reportOSSUpload(t){const e={method:"serverless.file.resource.report",params:JSON.stringify(t)};return this.request(this.setupRequest(e))}async uploadFile({filePath:t,cloudPath:e,fileType:n="image",cloudPathAsRealPath:r=!1,onUploadProgress:i,config:s}){if("string"!==La(e))throw new _c({code:"INVALID_PARAM",message:"cloudPath必须为字符串类型"});if(!(e=e.trim()))throw new _c({code:"INVALID_PARAM",message:"cloudPath不可为空"});if(/:\/\//.test(e))throw new _c({code:"INVALID_PARAM",message:"cloudPath不合法"});const o=s&&s.envType||this.config.envType;if(r&&("/"!==e[0]&&(e="/"+e),e.indexOf("\\")>-1))throw new _c({code:"INVALID_PARAM",message:"使用cloudPath作为路径时,cloudPath不可包含“\\”"});const a=(await this.getOSSUploadOptionsFromPath({env:o,filename:r?e.split("/").pop():e,fileId:r?e:void 0})).result,c="https://"+a.cdnDomain+"/"+a.ossPath,{securityToken:u,accessKeyId:l,signature:h,host:f,ossPath:d,id:p,policy:g,ossCallbackUrl:m}=a,y={"Cache-Control":"max-age=2592000","Content-Disposition":"attachment",OSSAccessKeyId:l,Signature:h,host:f,id:p,key:d,policy:g,success_action_status:200};if(u&&(y["x-oss-security-token"]=u),m){const t=JSON.stringify({callbackUrl:m,callbackBody:JSON.stringify({fileId:p,spaceId:this.config.spaceId}),callbackBodyType:"application/json"});y.callback=Pc(t)}const v={url:"https://"+a.host,formData:y,fileName:"file",name:"file",filePath:t,fileType:n};if(await this.uploadFileToOSS(Object.assign({},v,{onUploadProgress:i})),m)return{success:!0,filePath:t,fileID:c};if((await this.reportOSSUpload({id:p})).success)return{success:!0,filePath:t,fileID:c};throw new _c({code:"UPLOAD_FAILED",message:"文件上传失败"})}getTempFileURL({fileList:t}={}){return new Promise(((e,n)=>{Array.isArray(t)&&0!==t.length||n(new _c({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"})),e({fileList:t.map((t=>({fileID:t,tempFileURL:t})))})}))}async getFileInfo({fileList:t}={}){if(!Array.isArray(t)||0===t.length)throw new _c({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"});const e={method:"serverless.file.resource.info",params:JSON.stringify({id:t.map((t=>t.split("?")[0])).join(",")})};return{fileList:(await this.request(this.setupRequest(e))).result}}}(t),n={signInAnonymously:function(){return e.authorize()},getLoginState:function(){return Promise.resolve(!1)}};return e.auth=function(){return n},e.customAuth=e.auth,e}};const Cc="undefined"!=typeof location&&"http:"===location.protocol?"http:":"https:";var Bc;!function(t){t.local="local",t.none="none",t.session="session"}(Bc||(Bc={}));var Nc=function(){},Lc=Ta((function(t,e){var n;t.exports=(n=Ia,function(t){var e=n,r=e.lib,i=r.WordArray,s=r.Hasher,o=e.algo,a=[],c=[];!function(){function e(e){for(var n=t.sqrt(e),r=2;r<=n;r++)if(!(e%r))return!1;return!0}function n(t){return 4294967296*(t-(0|t))|0}for(var r=2,i=0;i<64;)e(r)&&(i<8&&(a[i]=n(t.pow(r,.5))),c[i]=n(t.pow(r,1/3)),i++),r++}();var u=[],l=o.SHA256=s.extend({_doReset:function(){this._hash=new i.init(a.slice(0))},_doProcessBlock:function(t,e){for(var n=this._hash.words,r=n[0],i=n[1],s=n[2],o=n[3],a=n[4],l=n[5],h=n[6],f=n[7],d=0;d<64;d++){if(d<16)u[d]=0|t[e+d];else{var p=u[d-15],g=(p<<25|p>>>7)^(p<<14|p>>>18)^p>>>3,m=u[d-2],y=(m<<15|m>>>17)^(m<<13|m>>>19)^m>>>10;u[d]=g+u[d-7]+y+u[d-16]}var v=r&i^r&s^i&s,_=(r<<30|r>>>2)^(r<<19|r>>>13)^(r<<10|r>>>22),w=f+((a<<26|a>>>6)^(a<<21|a>>>11)^(a<<7|a>>>25))+(a&l^~a&h)+c[d]+u[d];f=h,h=l,l=a,a=o+w|0,o=s,s=i,i=r,r=w+(_+v)|0}n[0]=n[0]+r|0,n[1]=n[1]+i|0,n[2]=n[2]+s|0,n[3]=n[3]+o|0,n[4]=n[4]+a|0,n[5]=n[5]+l|0,n[6]=n[6]+h|0,n[7]=n[7]+f|0},_doFinalize:function(){var e=this._data,n=e.words,r=8*this._nDataBytes,i=8*e.sigBytes;return n[i>>>5]|=128<<24-i%32,n[14+(i+64>>>9<<4)]=t.floor(r/4294967296),n[15+(i+64>>>9<<4)]=r,e.sigBytes=4*n.length,this._process(),this._hash},clone:function(){var t=s.clone.call(this);return t._hash=this._hash.clone(),t}});e.SHA256=s._createHelper(l),e.HmacSHA256=s._createHmacHelper(l)}(Math),n.SHA256)})),jc=Lc,Vc=Ta((function(t,e){t.exports=Ia.HmacSHA256}));const Uc=()=>{let t;if(!Promise){t=()=>{},t.promise={};const e=()=>{throw new _c({message:'Your Node runtime does support ES6 Promises. Set "global.Promise" to your preferred implementation of promises.'})};return Object.defineProperty(t.promise,"then",{get:e}),Object.defineProperty(t.promise,"catch",{get:e}),t}const e=new Promise(((e,n)=>{t=(t,r)=>t?n(t):e(r)}));return t.promise=e,t};function $c(t){return void 0===t}function Hc(t){return"[object Null]"===Object.prototype.toString.call(t)}function qc(t=""){return t.replace(/([\s\S]+)\s+(请前往云开发AI小助手查看问题:.*)/,"$1")}function Fc(t=32){let e="";for(let n=0;n<t;n++)e+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789".charAt(Math.floor(62*Math.random()));return e}var Kc;!function(t){t.WEB="web",t.WX_MP="wx_mp"}(Kc||(Kc={}));const zc={adapter:null,runtime:void 0},Wc=["anonymousUuidKey"];class Jc extends Nc{constructor(){super(),zc.adapter.root.tcbObject||(zc.adapter.root.tcbObject={})}setItem(t,e){zc.adapter.root.tcbObject[t]=e}getItem(t){return zc.adapter.root.tcbObject[t]}removeItem(t){delete zc.adapter.root.tcbObject[t]}clear(){delete zc.adapter.root.tcbObject}}function Gc(t,e){switch(t){case"local":return e.localStorage||new Jc;case"none":return new Jc;default:return e.sessionStorage||new Jc}}class Yc{constructor(t){if(!this._storage){this._persistence=zc.adapter.primaryStorage||t.persistence,this._storage=Gc(this._persistence,zc.adapter);const e=`access_token_${t.env}`,n=`access_token_expire_${t.env}`,r=`refresh_token_${t.env}`,i=`anonymous_uuid_${t.env}`,s=`login_type_${t.env}`,o="device_id",a=`token_type_${t.env}`,c=`user_info_${t.env}`;this.keys={accessTokenKey:e,accessTokenExpireKey:n,refreshTokenKey:r,anonymousUuidKey:i,loginTypeKey:s,userInfoKey:c,deviceIdKey:o,tokenTypeKey:a}}}updatePersistence(t){if(t===this._persistence)return;const e="local"===this._persistence;this._persistence=t;const n=Gc(t,zc.adapter);for(const r in this.keys){const t=this.keys[r];if(e&&Wc.includes(r))continue;const i=this._storage.getItem(t);$c(i)||Hc(i)||(n.setItem(t,i),this._storage.removeItem(t))}this._storage=n}setStore(t,e,n){if(!this._storage)return;const r={version:n||"localCachev1",content:e},i=JSON.stringify(r);try{this._storage.setItem(t,i)}catch(s){throw s}}getStore(t,e){try{if(!this._storage)return}catch(r){return""}e=e||"localCachev1";const n=this._storage.getItem(t);return n&&n.indexOf(e)>=0?JSON.parse(n).content:""}removeStore(t){this._storage.removeItem(t)}}const Zc={},Xc={};function Qc(t){return Zc[t]}class tu{constructor(t,e){this.data=e||null,this.name=t}}class eu extends tu{constructor(t,e){super("error",{error:t,data:e}),this.error=t}}const nu=new class{constructor(){this._listeners={}}on(t,e){return n=t,r=e,(i=this._listeners)[n]=i[n]||[],i[n].push(r),this;var n,r,i}off(t,e){return function(t,e,n){if(n&&n[t]){const r=n[t].indexOf(e);-1!==r&&n[t].splice(r,1)}}(t,e,this._listeners),this}fire(t,e){if(t instanceof eu)return console.error(t.error),this;const n="string"==typeof t?new tu(t,e||{}):t,r=n.name;if(this._listens(r)){n.target=this;const t=this._listeners[r]?[...this._listeners[r]]:[];for(const e of t)e.call(this,n)}return this}_listens(t){return this._listeners[t]&&this._listeners[t].length>0}};function ru(t,e){nu.on(t,e)}function iu(t,e={}){nu.fire(t,e)}function su(t,e){nu.off(t,e)}const ou="loginStateChanged",au="loginStateExpire",cu="loginTypeChanged",uu="anonymousConverted",lu="refreshAccessToken";var hu;!function(t){t.ANONYMOUS="ANONYMOUS",t.WECHAT="WECHAT",t.WECHAT_PUBLIC="WECHAT-PUBLIC",t.WECHAT_OPEN="WECHAT-OPEN",t.CUSTOM="CUSTOM",t.EMAIL="EMAIL",t.USERNAME="USERNAME",t.NULL="NULL"}(hu||(hu={}));class fu{constructor(){this._fnPromiseMap=new Map}async run(t,e){let n=this._fnPromiseMap.get(t);return n||(n=new Promise((async(n,r)=>{try{await this._runIdlePromise();const r=e();n(await r)}catch(i){r(i)}finally{this._fnPromiseMap.delete(t)}})),this._fnPromiseMap.set(t,n)),n}_runIdlePromise(){return Promise.resolve()}}class du{constructor(t){this._singlePromise=new fu,this._cache=Qc(t.env),this._baseURL=`https://${t.env}.ap-shanghai.tcb-api.tencentcloudapi.com`,this._reqClass=new zc.adapter.reqClass({timeout:t.timeout,timeoutMsg:`请求在${t.timeout/1e3}s内未完成,已中断`,restrictedMethods:["post"]})}_getDeviceId(){if(this._deviceID)return this._deviceID;const{deviceIdKey:t}=this._cache.keys;let e=this._cache.getStore(t);return"string"==typeof e&&e.length>=16&&e.length<=48||(e=Fc(),this._cache.setStore(t,e)),this._deviceID=e,e}async _request(t,e,n={}){const r={"x-request-id":Fc(),"x-device-id":this._getDeviceId()};if(n.withAccessToken){const{tokenTypeKey:t}=this._cache.keys,e=await this.getAccessToken(),n=this._cache.getStore(t);r.authorization=`${n} ${e}`}return this._reqClass["get"===n.method?"get":"post"]({url:`${this._baseURL}${t}`,data:e,headers:r})}async _fetchAccessToken(){const{loginTypeKey:t,accessTokenKey:e,accessTokenExpireKey:n,tokenTypeKey:r}=this._cache.keys,i=this._cache.getStore(t);if(i&&i!==hu.ANONYMOUS)throw new _c({code:"INVALID_OPERATION",message:"非匿名登录不支持刷新 access token"});const s=await this._singlePromise.run("fetchAccessToken",(async()=>(await this._request("/auth/v1/signin/anonymously",{},{method:"post"})).data)),{access_token:o,expires_in:a,token_type:c}=s;return this._cache.setStore(r,c),this._cache.setStore(e,o),this._cache.setStore(n,Date.now()+1e3*a),o}isAccessTokenExpired(t,e){let n=!0;return t&&e&&(n=e<Date.now()),n}async getAccessToken(){const{accessTokenKey:t,accessTokenExpireKey:e}=this._cache.keys,n=this._cache.getStore(t),r=this._cache.getStore(e);return this.isAccessTokenExpired(n,r)?this._fetchAccessToken():n}async refreshAccessToken(){const{accessTokenKey:t,accessTokenExpireKey:e,loginTypeKey:n}=this._cache.keys;return this._cache.removeStore(t),this._cache.removeStore(e),this._cache.setStore(n,hu.ANONYMOUS),this.getAccessToken()}async getUserInfo(){return this._singlePromise.run("getUserInfo",(async()=>(await this._request("/auth/v1/user/me",{},{withAccessToken:!0,method:"get"})).data))}}const pu=["auth.getJwt","auth.logout","auth.signInWithTicket","auth.signInAnonymously","auth.signIn","auth.fetchAccessTokenWithRefreshToken","auth.signUpWithEmailAndPassword","auth.activateEndUserMail","auth.sendPasswordResetEmail","auth.resetPasswordWithToken","auth.isUsernameRegistered"],gu={"X-SDK-Version":"1.3.5"};function mu(t,e,n){const r=t[e];t[e]=function(e){const i={},s={};n.forEach((n=>{const{data:r,headers:o}=n.call(t,e);Object.assign(i,r),Object.assign(s,o)}));const o=e.data;return o&&(()=>{var t;if(t=o,"[object FormData]"!==Object.prototype.toString.call(t))e.data={...o,...i};else for(const e in i)o.append(e,i[e])})(),e.headers={...e.headers||{},...s},r.call(t,e)}}function yu(){const t=Math.random().toString(16).slice(2);return{data:{seqId:t},headers:{...gu,"x-seqid":t}}}class vu{constructor(t={}){var e;this.config=t,this._reqClass=new zc.adapter.reqClass({timeout:this.config.timeout,timeoutMsg:`请求在${this.config.timeout/1e3}s内未完成,已中断`,restrictedMethods:["post"]}),this._cache=Qc(this.config.env),this._localCache=(e=this.config.env,Xc[e]),this.oauth=new du(this.config),mu(this._reqClass,"post",[yu]),mu(this._reqClass,"upload",[yu]),mu(this._reqClass,"download",[yu])}async post(t){return await this._reqClass.post(t)}async upload(t){return await this._reqClass.upload(t)}async download(t){return await this._reqClass.download(t)}async refreshAccessToken(){let t,e;this._refreshAccessTokenPromise||(this._refreshAccessTokenPromise=this._refreshAccessToken());try{t=await this._refreshAccessTokenPromise}catch(n){e=n}if(this._refreshAccessTokenPromise=null,this._shouldRefreshAccessTokenHook=null,e)throw e;return t}async _refreshAccessToken(){const{accessTokenKey:t,accessTokenExpireKey:e,refreshTokenKey:n,loginTypeKey:r,anonymousUuidKey:i}=this._cache.keys;this._cache.removeStore(t),this._cache.removeStore(e);let s=this._cache.getStore(n);if(!s)throw new _c({message:"未登录CloudBase"});const o={refresh_token:s},a=await this.request("auth.fetchAccessTokenWithRefreshToken",o);if(a.data.code){const{code:t}=a.data;if("SIGN_PARAM_INVALID"===t||"REFRESH_TOKEN_EXPIRED"===t||"INVALID_REFRESH_TOKEN"===t){if(this._cache.getStore(r)===hu.ANONYMOUS&&"INVALID_REFRESH_TOKEN"===t){const t=this._cache.getStore(i),e=this._cache.getStore(n),r=await this.send("auth.signInAnonymously",{anonymous_uuid:t,refresh_token:e});return this.setRefreshToken(r.refresh_token),this._refreshAccessToken()}iu(au),this._cache.removeStore(n)}throw new _c({code:a.data.code,message:`刷新access token失败:${a.data.code}`})}if(a.data.access_token)return iu(lu),this._cache.setStore(t,a.data.access_token),this._cache.setStore(e,a.data.access_token_expire+Date.now()),{accessToken:a.data.access_token,accessTokenExpire:a.data.access_token_expire};a.data.refresh_token&&(this._cache.removeStore(n),this._cache.setStore(n,a.data.refresh_token),this._refreshAccessToken())}async getAccessToken(){const{accessTokenKey:t,accessTokenExpireKey:e,refreshTokenKey:n}=this._cache.keys;if(!this._cache.getStore(n))throw new _c({message:"refresh token不存在,登录状态异常"});let r=this._cache.getStore(t),i=this._cache.getStore(e),s=!0;return this._shouldRefreshAccessTokenHook&&!(await this._shouldRefreshAccessTokenHook(r,i))&&(s=!1),(!r||!i||i<Date.now())&&s?this.refreshAccessToken():{accessToken:r,accessTokenExpire:i}}async request(t,e,n){const r=`x-tcb-trace_${this.config.env}`;let i="application/x-www-form-urlencoded";const s={action:t,env:this.config.env,dataVersion:"2019-08-16",...e};let o;if(-1===pu.indexOf(t)&&(this._cache.keys,s.access_token=await this.oauth.getAccessToken()),"storage.uploadFile"===t){o=new FormData;for(let t in o)o.hasOwnProperty(t)&&void 0!==o[t]&&o.append(t,s[t]);i="multipart/form-data"}else{i="application/json",o={};for(let t in s)void 0!==s[t]&&(o[t]=s[t])}let a={headers:{"content-type":i}};n&&n.timeout&&(a.timeout=n.timeout),n&&n.onUploadProgress&&(a.onUploadProgress=n.onUploadProgress);const c=this._localCache.getStore(r);c&&(a.headers["X-TCB-Trace"]=c);const{parse:u,inQuery:l,search:h}=e;let f={env:this.config.env};u&&(f.parse=!0),l&&(f={...l,...f});let d=function(t,e,n={}){const r=/\?/.test(e);let i="";for(let s in n)""===i?!r&&(e+="?"):i+="&",i+=`${s}=${encodeURIComponent(n[s])}`;return/^http(s)?\:\/\//.test(e+=i)?e:`${t}${e}`}(Cc,"//tcb-api.tencentcloudapi.com/web",f);h&&(d+=h);const p=await this.post({url:d,data:o,...a}),g=p.header&&p.header["x-tcb-trace"];if(g&&this._localCache.setStore(r,g),200!==Number(p.status)&&200!==Number(p.statusCode)||!p.data)throw new _c({code:"NETWORK_ERROR",message:"network request error"});return p}async send(t,e={},n={}){const r=await this.request(t,e,{...n,onUploadProgress:e.onUploadProgress});if(("ACCESS_TOKEN_DISABLED"===r.data.code||"ACCESS_TOKEN_EXPIRED"===r.data.code)&&-1===pu.indexOf(t)){await this.oauth.refreshAccessToken();const r=await this.request(t,e,{...n,onUploadProgress:e.onUploadProgress});if(r.data.code)throw new _c({code:r.data.code,message:qc(r.data.message)});return r.data}if(r.data.code)throw new _c({code:r.data.code,message:qc(r.data.message)});return r.data}setRefreshToken(t){const{accessTokenKey:e,accessTokenExpireKey:n,refreshTokenKey:r}=this._cache.keys;this._cache.removeStore(e),this._cache.removeStore(n),this._cache.setStore(r,t)}}const _u={};function wu(t){return _u[t]}class Su{constructor(t){this.config=t,this._cache=Qc(t.env),this._request=wu(t.env)}setRefreshToken(t){const{accessTokenKey:e,accessTokenExpireKey:n,refreshTokenKey:r}=this._cache.keys;this._cache.removeStore(e),this._cache.removeStore(n),this._cache.setStore(r,t)}setAccessToken(t,e){const{accessTokenKey:n,accessTokenExpireKey:r}=this._cache.keys;this._cache.setStore(n,t),this._cache.setStore(r,e)}async refreshUserInfo(){const{data:t}=await this._request.send("auth.getUserInfo",{});return this.setLocalUserInfo(t),t}setLocalUserInfo(t){const{userInfoKey:e}=this._cache.keys;this._cache.setStore(e,t)}}class bu{constructor(t){if(!t)throw new _c({code:"PARAM_ERROR",message:"envId is not defined"});this._envId=t,this._cache=Qc(this._envId),this._request=wu(this._envId),this.setUserInfo()}linkWithTicket(t){if("string"!=typeof t)throw new _c({code:"PARAM_ERROR",message:"ticket must be string"});return this._request.send("auth.linkWithTicket",{ticket:t})}linkWithRedirect(t){t.signInWithRedirect()}updatePassword(t,e){return this._request.send("auth.updatePassword",{oldPassword:e,newPassword:t})}updateEmail(t){return this._request.send("auth.updateEmail",{newEmail:t})}updateUsername(t){if("string"!=typeof t)throw new _c({code:"PARAM_ERROR",message:"username must be a string"});return this._request.send("auth.updateUsername",{username:t})}async getLinkedUidList(){const{data:t}=await this._request.send("auth.getLinkedUidList",{});let e=!1;const{users:n}=t;return n.forEach((t=>{t.wxOpenId&&t.wxPublicId&&(e=!0)})),{users:n,hasPrimaryUid:e}}setPrimaryUid(t){return this._request.send("auth.setPrimaryUid",{uid:t})}unlink(t){return this._request.send("auth.unlink",{platform:t})}async update(t){const{nickName:e,gender:n,avatarUrl:r,province:i,country:s,city:o}=t,{data:a}=await this._request.send("auth.updateUserInfo",{nickName:e,gender:n,avatarUrl:r,province:i,country:s,city:o});this.setLocalUserInfo(a)}async refresh(){const t=await this._request.oauth.getUserInfo();return this.setLocalUserInfo(t),t}setUserInfo(){const{userInfoKey:t}=this._cache.keys,e=this._cache.getStore(t);["uid","loginType","openid","wxOpenId","wxPublicId","unionId","qqMiniOpenId","email","hasPassword","customUserId","nickName","gender","avatarUrl"].forEach((t=>{this[t]=e[t]})),this.location={country:e.country,province:e.province,city:e.city}}setLocalUserInfo(t){const{userInfoKey:e}=this._cache.keys;this._cache.setStore(e,t),this.setUserInfo()}}class Eu{constructor(t){if(!t)throw new _c({code:"PARAM_ERROR",message:"envId is not defined"});this._cache=Qc(t);const{refreshTokenKey:e,accessTokenKey:n,accessTokenExpireKey:r}=this._cache.keys,i=this._cache.getStore(e),s=this._cache.getStore(n),o=this._cache.getStore(r);this.credential={refreshToken:i,accessToken:s,accessTokenExpire:o},this.user=new bu(t)}get isAnonymousAuth(){return this.loginType===hu.ANONYMOUS}get isCustomAuth(){return this.loginType===hu.CUSTOM}get isWeixinAuth(){return this.loginType===hu.WECHAT||this.loginType===hu.WECHAT_OPEN||this.loginType===hu.WECHAT_PUBLIC}get loginType(){return this._cache.getStore(this._cache.keys.loginTypeKey)}}class Tu extends Su{async signIn(){this._cache.updatePersistence("local"),await this._request.oauth.getAccessToken(),iu(ou),iu(cu,{env:this.config.env,loginType:hu.ANONYMOUS,persistence:"local"});const t=new Eu(this.config.env);return await t.user.refresh(),t}async linkAndRetrieveDataWithTicket(t){const{anonymousUuidKey:e,refreshTokenKey:n}=this._cache.keys,r=this._cache.getStore(e),i=this._cache.getStore(n),s=await this._request.send("auth.linkAndRetrieveDataWithTicket",{anonymous_uuid:r,refresh_token:i,ticket:t});if(s.refresh_token)return this._clearAnonymousUUID(),this.setRefreshToken(s.refresh_token),await this._request.refreshAccessToken(),iu(uu,{env:this.config.env}),iu(cu,{loginType:hu.CUSTOM,persistence:"local"}),{credential:{refreshToken:s.refresh_token}};throw new _c({message:"匿名转化失败"})}_setAnonymousUUID(t){const{anonymousUuidKey:e,loginTypeKey:n}=this._cache.keys;this._cache.removeStore(e),this._cache.setStore(e,t),this._cache.setStore(n,hu.ANONYMOUS)}_clearAnonymousUUID(){this._cache.removeStore(this._cache.keys.anonymousUuidKey)}}class xu extends Su{async signIn(t){if("string"!=typeof t)throw new _c({code:"PARAM_ERROR",message:"ticket must be a string"});const{refreshTokenKey:e}=this._cache.keys,n=await this._request.send("auth.signInWithTicket",{ticket:t,refresh_token:this._cache.getStore(e)||""});if(n.refresh_token)return this.setRefreshToken(n.refresh_token),await this._request.refreshAccessToken(),iu(ou),iu(cu,{env:this.config.env,loginType:hu.CUSTOM,persistence:this.config.persistence}),await this.refreshUserInfo(),new Eu(this.config.env);throw new _c({message:"自定义登录失败"})}}class Iu extends Su{async signIn(t,e){if("string"!=typeof t)throw new _c({code:"PARAM_ERROR",message:"email must be a string"});const{refreshTokenKey:n}=this._cache.keys,r=await this._request.send("auth.signIn",{loginType:"EMAIL",email:t,password:e,refresh_token:this._cache.getStore(n)||""}),{refresh_token:i,access_token:s,access_token_expire:o}=r;if(i)return this.setRefreshToken(i),s&&o?this.setAccessToken(s,o):await this._request.refreshAccessToken(),await this.refreshUserInfo(),iu(ou),iu(cu,{env:this.config.env,loginType:hu.EMAIL,persistence:this.config.persistence}),new Eu(this.config.env);throw r.code?new _c({code:r.code,message:`邮箱登录失败: ${r.message}`}):new _c({message:"邮箱登录失败"})}async activate(t){return this._request.send("auth.activateEndUserMail",{token:t})}async resetPasswordWithToken(t,e){return this._request.send("auth.resetPasswordWithToken",{token:t,newPassword:e})}}class Du extends Su{async signIn(t,e){if("string"!=typeof t)throw new _c({code:"PARAM_ERROR",message:"username must be a string"});"string"!=typeof e&&(e="",console.warn("password is empty"));const{refreshTokenKey:n}=this._cache.keys,r=await this._request.send("auth.signIn",{loginType:hu.USERNAME,username:t,password:e,refresh_token:this._cache.getStore(n)||""}),{refresh_token:i,access_token_expire:s,access_token:o}=r;if(i)return this.setRefreshToken(i),o&&s?this.setAccessToken(o,s):await this._request.refreshAccessToken(),await this.refreshUserInfo(),iu(ou),iu(cu,{env:this.config.env,loginType:hu.USERNAME,persistence:this.config.persistence}),new Eu(this.config.env);throw r.code?new _c({code:r.code,message:`用户名密码登录失败: ${r.message}`}):new _c({message:"用户名密码登录失败"})}}class Au{constructor(t){this.config=t,this._cache=Qc(t.env),this._request=wu(t.env),this._onAnonymousConverted=this._onAnonymousConverted.bind(this),this._onLoginTypeChanged=this._onLoginTypeChanged.bind(this),ru(cu,this._onLoginTypeChanged)}get currentUser(){const t=this.hasLoginState();return t&&t.user||null}get loginType(){return this._cache.getStore(this._cache.keys.loginTypeKey)}anonymousAuthProvider(){return new Tu(this.config)}customAuthProvider(){return new xu(this.config)}emailAuthProvider(){return new Iu(this.config)}usernameAuthProvider(){return new Du(this.config)}async signInAnonymously(){return new Tu(this.config).signIn()}async signInWithEmailAndPassword(t,e){return new Iu(this.config).signIn(t,e)}signInWithUsernameAndPassword(t,e){return new Du(this.config).signIn(t,e)}async linkAndRetrieveDataWithTicket(t){return this._anonymousAuthProvider||(this._anonymousAuthProvider=new Tu(this.config)),ru(uu,this._onAnonymousConverted),await this._anonymousAuthProvider.linkAndRetrieveDataWithTicket(t)}async signOut(){if(this.loginType===hu.ANONYMOUS)throw new _c({message:"匿名用户不支持登出操作"});const{refreshTokenKey:t,accessTokenKey:e,accessTokenExpireKey:n}=this._cache.keys,r=this._cache.getStore(t);if(!r)return;const i=await this._request.send("auth.logout",{refresh_token:r});return this._cache.removeStore(t),this._cache.removeStore(e),this._cache.removeStore(n),iu(ou),iu(cu,{env:this.config.env,loginType:hu.NULL,persistence:this.config.persistence}),i}async signUpWithEmailAndPassword(t,e){return this._request.send("auth.signUpWithEmailAndPassword",{email:t,password:e})}async sendPasswordResetEmail(t){return this._request.send("auth.sendPasswordResetEmail",{email:t})}onLoginStateChanged(t){ru(ou,(()=>{const e=this.hasLoginState();t.call(this,e)}));const e=this.hasLoginState();t.call(this,e)}onLoginStateExpired(t){ru(au,t.bind(this))}onAccessTokenRefreshed(t){ru(lu,t.bind(this))}onAnonymousConverted(t){ru(uu,t.bind(this))}onLoginTypeChanged(t){ru(cu,(()=>{const e=this.hasLoginState();t.call(this,e)}))}async getAccessToken(){return{accessToken:(await this._request.getAccessToken()).accessToken,env:this.config.env}}hasLoginState(){const{accessTokenKey:t,accessTokenExpireKey:e}=this._cache.keys,n=this._cache.getStore(t),r=this._cache.getStore(e);return this._request.oauth.isAccessTokenExpired(n,r)?null:new Eu(this.config.env)}async isUsernameRegistered(t){if("string"!=typeof t)throw new _c({code:"PARAM_ERROR",message:"username must be a string"});const{data:e}=await this._request.send("auth.isUsernameRegistered",{username:t});return e&&e.isRegistered}getLoginState(){return Promise.resolve(this.hasLoginState())}async signInWithTicket(t){return new xu(this.config).signIn(t)}shouldRefreshAccessToken(t){this._request._shouldRefreshAccessTokenHook=t.bind(this)}getUserInfo(){return this._request.send("auth.getUserInfo",{}).then((t=>t.code?t:{...t.data,requestId:t.seqId}))}getAuthHeader(){const{refreshTokenKey:t,accessTokenKey:e}=this._cache.keys,n=this._cache.getStore(t);return{"x-cloudbase-credentials":this._cache.getStore(e)+"/@@/"+n}}_onAnonymousConverted(t){const{env:e}=t.data;e===this.config.env&&this._cache.updatePersistence(this.config.persistence)}_onLoginTypeChanged(t){const{loginType:e,persistence:n,env:r}=t.data;r===this.config.env&&(this._cache.updatePersistence(n),this._cache.setStore(this._cache.keys.loginTypeKey,e))}}const ku=function(t,e){e=e||Uc();const n=wu(this.config.env),{cloudPath:r,filePath:i,onUploadProgress:s,fileType:o="image"}=t;return n.send("storage.getUploadMetadata",{path:r}).then((t=>{const{data:{url:a,authorization:c,token:u,fileId:l,cosFileId:h},requestId:f}=t,d={key:r,signature:c,"x-cos-meta-fileid":h,success_action_status:"201","x-cos-security-token":u};n.upload({url:a,data:d,file:i,name:r,fileType:o,onUploadProgress:s}).then((t=>{201===t.statusCode?e(null,{fileID:l,requestId:f}):e(new _c({code:"STORAGE_REQUEST_FAIL",message:`STORAGE_REQUEST_FAIL: ${t.data}`}))})).catch((t=>{e(t)}))})).catch((t=>{e(t)})),e.promise},Ou=function(t,e){e=e||Uc();const n=wu(this.config.env),{cloudPath:r}=t;return n.send("storage.getUploadMetadata",{path:r}).then((t=>{e(null,t)})).catch((t=>{e(t)})),e.promise},Ru=function({fileList:t},e){if(e=e||Uc(),!t||!Array.isArray(t))return{code:"INVALID_PARAM",message:"fileList必须是非空的数组"};for(let r of t)if(!r||"string"!=typeof r)return{code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"};const n={fileid_list:t};return wu(this.config.env).send("storage.batchDeleteFile",n).then((t=>{t.code?e(null,t):e(null,{fileList:t.data.delete_list,requestId:t.requestId})})).catch((t=>{e(t)})),e.promise},Pu=function({fileList:t},e){e=e||Uc(),t&&Array.isArray(t)||e(null,{code:"INVALID_PARAM",message:"fileList必须是非空的数组"});let n=[];for(let i of t)"object"==typeof i?(i.hasOwnProperty("fileID")&&i.hasOwnProperty("maxAge")||e(null,{code:"INVALID_PARAM",message:"fileList的元素必须是包含fileID和maxAge的对象"}),n.push({fileid:i.fileID,max_age:i.maxAge})):"string"==typeof i?n.push({fileid:i}):e(null,{code:"INVALID_PARAM",message:"fileList的元素必须是字符串"});const r={file_list:n};return wu(this.config.env).send("storage.batchGetDownloadUrl",r).then((t=>{t.code?e(null,t):e(null,{fileList:t.data.download_list,requestId:t.requestId})})).catch((t=>{e(t)})),e.promise},Mu=async function({fileID:t},e){const n=(await Pu.call(this,{fileList:[{fileID:t,maxAge:600}]})).fileList[0];if("SUCCESS"!==n.code)return e?e(n):new Promise((t=>{t(n)}));const r=wu(this.config.env);let i=n.download_url;if(i=encodeURI(i),!e)return r.download({url:i});e(await r.download({url:i}))},Cu=function({name:t,data:e,query:n,parse:r,search:i,timeout:s},o){const a=o||Uc();let c;try{c=e?JSON.stringify(e):""}catch(l){return Promise.reject(l)}if(!t)return Promise.reject(new _c({code:"PARAM_ERROR",message:"函数名不能为空"}));const u={inQuery:n,parse:r,search:i,function_name:t,request_data:c};return wu(this.config.env).send("functions.invokeFunction",u,{timeout:s}).then((t=>{if(t.code)a(null,t);else{let n=t.data.response_data;if(r)a(null,{result:n,requestId:t.requestId});else try{n=JSON.parse(t.data.response_data),a(null,{result:n,requestId:t.requestId})}catch(e){a(new _c({message:"response data must be json"}))}}return a.promise})).catch((t=>{a(t)})),a.promise},Bu={timeout:15e3,persistence:"session"},Nu={};class Lu{constructor(t){this.config=t||this.config,this.authObj=void 0}init(t){switch(zc.adapter||(this.requestClient=new zc.adapter.reqClass({timeout:t.timeout||5e3,timeoutMsg:`请求在${(t.timeout||5e3)/1e3}s内未完成,已中断`})),this.config={...Bu,...t},!0){case this.config.timeout>6e5:console.warn("timeout大于可配置上限[10分钟],已重置为上限数值"),this.config.timeout=6e5;break;case this.config.timeout<100:console.warn("timeout小于可配置下限[100ms],已重置为下限数值"),this.config.timeout=100}return new Lu(this.config)}auth({persistence:t}={}){if(this.authObj)return this.authObj;const e=t||zc.adapter.primaryStorage||Bu.persistence;var n;return e!==this.config.persistence&&(this.config.persistence=e),function(t){const{env:e}=t;Zc[e]=new Yc(t),Xc[e]=new Yc({...t,persistence:"local"})}(this.config),n=this.config,_u[n.env]=new vu(n),this.authObj=new Au(this.config),this.authObj}on(t,e){return ru.apply(this,[t,e])}off(t,e){return su.apply(this,[t,e])}callFunction(t,e){return Cu.apply(this,[t,e])}deleteFile(t,e){return Ru.apply(this,[t,e])}getTempFileURL(t,e){return Pu.apply(this,[t,e])}downloadFile(t,e){return Mu.apply(this,[t,e])}uploadFile(t,e){return ku.apply(this,[t,e])}getUploadMetadata(t,e){return Ou.apply(this,[t,e])}registerExtension(t){Nu[t.name]=t}async invokeExtension(t,e){const n=Nu[t];if(!n)throw new _c({message:`扩展${t} 必须先注册`});return await n.invoke(e,this)}useAdapters(t){const{adapter:e,runtime:n}=function(t){const e=(n=t,"[object Array]"===Object.prototype.toString.call(n)?t:[t]);var n;for(const r of e){const{isMatch:t,genAdapter:e,runtime:n}=r;if(t())return{adapter:e(),runtime:n}}}(t)||{};e&&(zc.adapter=e),n&&(zc.runtime=n)}}var ju=new Lu;function Vu(t,e,n){void 0===n&&(n={});var r=/\?/.test(e),i="";for(var s in n)""===i?!r&&(e+="?"):i+="&",i+=s+"="+encodeURIComponent(n[s]);return/^http(s)?:\/\//.test(e+=i)?e:""+t+e}class Uu{get(t){const{url:e,data:n,headers:r,timeout:i}=t;return new Promise(((t,s)=>{wc.request({url:Vu("https:",e),data:n,method:"GET",header:r,timeout:i,success(e){t(e)},fail(t){s(t)}})}))}post(t){const{url:e,data:n,headers:r,timeout:i}=t;return new Promise(((t,s)=>{wc.request({url:Vu("https:",e),data:n,method:"POST",header:r,timeout:i,success(e){t(e)},fail(t){s(t)}})}))}upload(t){return new Promise(((e,n)=>{const{url:r,file:i,data:s,headers:o,fileType:a}=t,c=wc.uploadFile({url:Vu("https:",r),name:"file",formData:Object.assign({},s),filePath:i,fileType:a,header:o,success(t){const n={statusCode:t.statusCode,data:t.data||{}};200===t.statusCode&&s.success_action_status&&(n.statusCode=parseInt(s.success_action_status,10)),e(n)},fail(t){n(new Error(t.errMsg||"uploadFile:fail"))}});"function"==typeof t.onUploadProgress&&c&&"function"==typeof c.onProgressUpdate&&c.onProgressUpdate((e=>{t.onUploadProgress({loaded:e.totalBytesSent,total:e.totalBytesExpectedToSend})}))}))}}const $u={setItem(t,e){wc.setStorageSync(t,e)},getItem:t=>wc.getStorageSync(t),removeItem(t){wc.removeStorageSync(t)},clear(){wc.clearStorageSync()}};var Hu={genAdapter:function(){return{root:{},reqClass:Uu,localStorage:$u,primaryStorage:"local"}},isMatch:function(){return!0},runtime:"uni_app"};ju.useAdapters(Hu);const qu=ju,Fu=qu.init;qu.init=function(t){t.env=t.spaceId;const e=Fu.call(this,t);e.config.provider="tencent",e.config.spaceId=t.spaceId;const n=e.auth;return e.auth=function(t){const e=n.call(this,t);return["linkAndRetrieveDataWithTicket","signInAnonymously","signOut","getAccessToken","getLoginState","signInWithTicket","getUserInfo"].forEach((t=>{var n;e[t]=(n=e[t],function(t){t=t||{};const{success:e,fail:r,complete:i}=vc(t);if(!(e||r||i))return n.call(this,t);n.call(this,t).then((t=>{e&&e(t),i&&i(t)}),(t=>{r&&r(t),i&&i(t)}))}).bind(e)})),e},e.customAuth=e.auth,e};var Ku=qu;async function zu(t,e){const n=`http://${t}:${e}/system/ping`;try{const t=await(r={url:n,timeout:500},new Promise(((t,e)=>{wc.request({...r,success(e){t(e)},fail(t){e(t)}})})));return!(!t.data||0!==t.data.code)}catch(i){return!1}var r}const Wu={"serverless.file.resource.generateProximalSign":"storage/generate-proximal-sign","serverless.file.resource.report":"storage/report","serverless.file.resource.delete":"storage/delete","serverless.file.resource.getTempFileURL":"storage/get-temp-file-url"};var Ju={init(t){const e=new class{constructor(t){if(["spaceId","clientSecret"].forEach((e=>{if(!Object.prototype.hasOwnProperty.call(t,e))throw new Error(`${e} required`)})),!t.endpoint)throw new Error("集群空间未配置ApiEndpoint,配置后需要重新关联服务空间后生效");this.config=Object.assign({},t),this.config.provider="dcloud",this.config.requestUrl=this.config.endpoint+"/client",this.config.envType=this.config.envType||"public",this.adapter=wc}async request(t,e=!0){return t=this.setupRequest(t),Promise.resolve().then((()=>Rc(t,this.adapter.request)))}requestLocal(t){return new Promise(((e,n)=>{this.adapter.request(Object.assign(t,{complete(t){if(t||(t={}),!t.statusCode||t.statusCode>=400){const e=t.data&&t.data.code||"SYS_ERR",r=t.data&&t.data.message||"request:fail";return n(new _c({code:e,message:r}))}e({success:!0,result:t.data})}}))}))}setupRequest(t){const e=Object.assign({},t,{spaceId:this.config.spaceId,timestamp:Date.now()}),n={"Content-Type":"application/json"};n["x-serverless-sign"]=Oc(e,this.config.clientSecret);const r=kc();n["x-client-info"]=encodeURIComponent(JSON.stringify(r));const{token:i}=bc();return n["x-client-token"]=i,{url:this.config.requestUrl,method:"POST",data:e,dataType:"json",header:JSON.parse(JSON.stringify(n))}}async setupLocalRequest(t){const e=kc(),{token:n}=bc(),r=Object.assign({},t,{spaceId:this.config.spaceId,timestamp:Date.now(),clientInfo:e,token:n}),{address:i,servePort:s}=this.__dev__&&this.__dev__.debugInfo||{},{address:o}=await async function(t,e){let n;for(let r=0;r<t.length;r++){const i=t[r];if(await zu(i,e)){n=i;break}}return{address:n,port:e}}(i,s);return{url:`http://${o}:${s}/${Wu[t.method]}`,method:"POST",data:r,dataType:"json",header:JSON.parse(JSON.stringify({"Content-Type":"application/json"}))}}callFunction(t){const e={method:"serverless.function.runtime.invoke",params:JSON.stringify({functionTarget:t.name,functionArgs:t.data||{}})};return this.request(e,!1)}getUploadFileOptions(t){const e={method:"serverless.file.resource.generateProximalSign",params:JSON.stringify(t)};return this.request(e)}reportUploadFile(t){const e={method:"serverless.file.resource.report",params:JSON.stringify(t)};return this.request(e)}uploadFile({filePath:t,cloudPath:e,fileType:n="image",onUploadProgress:r}){if(!e)throw new _c({code:"CLOUDPATH_REQUIRED",message:"cloudPath不可为空"});let i;return this.getUploadFileOptions({cloudPath:e}).then((e=>{const{url:s,formData:o,name:a}=e.result;return i=e.result.fileUrl,new Promise(((e,i)=>{const c=this.adapter.uploadFile({url:s,formData:o,name:a,filePath:t,fileType:n,success(t){t&&t.statusCode<400?e(t):i(new _c({code:"UPLOAD_FAILED",message:"文件上传失败"}))},fail(t){i(new _c({code:t.code||"UPLOAD_FAILED",message:t.message||t.errMsg||"文件上传失败"}))}});"function"==typeof r&&c&&"function"==typeof c.onProgressUpdate&&c.onProgressUpdate((t=>{r({loaded:t.totalBytesSent,total:t.totalBytesExpectedToSend})}))}))})).then((()=>this.reportUploadFile({cloudPath:e}))).then((e=>new Promise(((n,r)=>{e.success?n({success:!0,filePath:t,fileID:i}):r(new _c({code:"UPLOAD_FAILED",message:"文件上传失败"}))}))))}deleteFile({fileList:t}){const e={method:"serverless.file.resource.delete",params:JSON.stringify({fileList:t})};return this.request(e).then((t=>{if(t.success)return t.result;throw new _c({code:"DELETE_FILE_FAILED",message:"删除文件失败"})}))}getTempFileURL({fileList:t,maxAge:e}={}){if(!Array.isArray(t)||0===t.length)throw new _c({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"});const n={method:"serverless.file.resource.getTempFileURL",params:JSON.stringify({fileList:t,maxAge:e})};return this.request(n).then((t=>{if(t.success)return{fileList:t.result.fileList.map((t=>({fileID:t.fileID,tempFileURL:t.tempFileURL})))};throw new _c({code:"GET_TEMP_FILE_URL_FAILED",message:"获取临时文件链接失败"})}))}}(t),n={signInAnonymously:function(){return Promise.resolve()},getLoginState:function(){return Promise.resolve(!1)}};return e.auth=function(){return n},e.customAuth=e.auth,e}},Gu=Ta((function(t,e){t.exports=Ia.enc.Hex}));function Yu(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(t){var e=16*Math.random()|0;return("x"===t?e:3&e|8).toString(16)}))}function Zu(t="",e={}){const{data:n,functionName:r,method:i,headers:s,signHeaderKeys:o=[],config:a}=e,c=String(Date.now()),u=Yu(),l=Object.assign({},s,{"x-from-app-id":a.spaceAppId,"x-from-env-id":a.spaceId,"x-to-env-id":a.spaceId,"x-from-instance-id":c,"x-from-function-name":r,"x-client-timestamp":c,"x-alipay-source":"client","x-request-id":u,"x-alipay-callid":u,"x-trace-id":u}),h=["x-from-app-id","x-from-env-id","x-to-env-id","x-from-instance-id","x-from-function-name","x-client-timestamp"].concat(o),[f="",d=""]=t.split("?")||[],p=function(t){const e="HMAC-SHA256",n=t.signedHeaders.join(";"),r=t.signedHeaders.map((e=>`${e.toLowerCase()}:${t.headers[e]}\n`)).join(""),i=jc(t.body).toString(Gu),s=`${t.method.toUpperCase()}\n${t.path}\n${t.query}\n${r}\n${n}\n${i}\n`,o=jc(s).toString(Gu),a=`${e}\n${t.timestamp}\n${o}\n`,c=Vc(a,t.secretKey).toString(Gu);return`${e} Credential=${t.secretId}, SignedHeaders=${n}, Signature=${c}`}({path:f,query:d,method:i,headers:l,timestamp:c,body:JSON.stringify(n),secretId:a.accessKey,secretKey:a.secretKey,signedHeaders:h.sort()});return{url:`${a.endpoint}${t}`,headers:Object.assign({},l,{Authorization:p})}}function Xu({url:t,data:e,method:n="POST",headers:r={},timeout:i}){return new Promise(((s,o)=>{wc.request({url:t,method:n,data:"object"==typeof e?JSON.stringify(e):e,header:r,dataType:"json",timeout:i,complete:(t={})=>{const e=r["x-trace-id"]||"";if(!t.statusCode||t.statusCode>=400){const{message:n,errMsg:r,trace_id:i}=t.data||{};return o(new _c({code:"SYS_ERR",message:n||r||"request:fail",requestId:i||e}))}s({status:t.statusCode,data:t.data,headers:t.header,requestId:e})}})}))}function Qu(t,e){const{path:n,data:r,method:i="GET"}=t,{url:s,headers:o}=Zu(n,{functionName:"",data:r,method:i,headers:{"x-alipay-cloud-mode":"oss","x-data-api-type":"oss","x-expire-timestamp":Date.now()+6e4},signHeaderKeys:["x-data-api-type","x-expire-timestamp"],config:e});return Xu({url:s,data:r,method:i,headers:o}).then((t=>{const e=t.data||{};if(!e.success)throw new _c({code:t.errCode,message:t.errMsg,requestId:t.requestId});return e.data||{}})).catch((t=>{throw new _c({code:t.errCode,message:t.errMsg,requestId:t.requestId})}))}function tl(t=""){const e=t.trim().replace(/^cloud:\/\//,""),n=e.indexOf("/");if(n<=0)throw new _c({code:"INVALID_PARAM",message:"fileID不合法"});const r=e.substring(0,n),i=e.substring(n+1);return r!==this.config.spaceId&&console.warn("file ".concat(t," does not belong to env ").concat(this.config.spaceId)),i}function el(t=""){return"cloud://".concat(this.config.spaceId,"/").concat(t.replace(/^\/+/,""))}class nl{constructor(t){this.config=t}signedURL(t,e={}){const n=`/ws/function/${t}`,r=this.config.wsEndpoint.replace(/^ws(s)?:\/\//,""),i=Object.assign({},e,{accessKeyId:this.config.accessKey,signatureNonce:Yu(),timestamp:""+Date.now()}),s=[n,["accessKeyId","authorization","signatureNonce","timestamp"].sort().map((function(t){return i[t]?"".concat(t,"=").concat(i[t]):null})).filter(Boolean).join("&"),`host:${r}`].join("\n"),o=["HMAC-SHA256",jc(s).toString(Gu)].join("\n"),a=Vc(o,this.config.secretKey).toString(Gu),c=Object.keys(i).map((t=>`${t}=${encodeURIComponent(i[t])}`)).join("&");return`${this.config.wsEndpoint}${n}?${c}&signature=${a}`}}var rl={init:t=>{t.provider="alipay";const e=new class{constructor(t){if(["spaceId","spaceAppId","accessKey","secretKey"].forEach((e=>{if(!Object.prototype.hasOwnProperty.call(t,e))throw new Error(`${e} required`)})),t.endpoint){if("string"!=typeof t.endpoint)throw new Error("endpoint must be string");if(!/^https:\/\//.test(t.endpoint))throw new Error("endpoint must start with https://");t.endpoint=t.endpoint.replace(/\/$/,"")}this.config=Object.assign({},t,{endpoint:t.endpoint||`https://${t.spaceId}.api-hz.cloudbasefunction.cn`,wsEndpoint:t.wsEndpoint||`wss://${t.spaceId}.api-hz.cloudbasefunction.cn`}),this._websocket=new nl(this.config)}callFunction(t){return function(t,e){const{name:n,data:r,async:i=!1,timeout:s}=t,o="POST",a={"x-to-function-name":n};i&&(a["x-function-invoke-type"]="async");const{url:c,headers:u}=Zu("/functions/invokeFunction",{functionName:n,data:r,method:o,headers:a,signHeaderKeys:["x-to-function-name"],config:e});return Xu({url:c,data:r,method:o,headers:u,timeout:s}).then((t=>{let e=0;if(i){const n=t.data||{};e="200"===n.errCode?0:n.errCode,t.data=n.data||{},t.errMsg=n.errMsg}if(0!==e)throw new _c({code:e,message:t.errMsg,requestId:t.requestId});return{errCode:e,success:0===e,requestId:t.requestId,result:t.data}})).catch((t=>{throw new _c({code:t.errCode,message:t.errMsg,requestId:t.requestId})}))}(t,this.config)}uploadFileToOSS({url:t,filePath:e,fileType:n,formData:r,onUploadProgress:i}){return new Promise(((s,o)=>{const a=wc.uploadFile({url:t,filePath:e,fileType:n,formData:r,name:"file",success(t){t&&t.statusCode<400?s(t):o(new _c({code:"UPLOAD_FAILED",message:"文件上传失败"}))},fail(t){o(new _c({code:t.code||"UPLOAD_FAILED",message:t.message||t.errMsg||"文件上传失败"}))}});"function"==typeof i&&a&&"function"==typeof a.onProgressUpdate&&a.onProgressUpdate((t=>{i({loaded:t.totalBytesSent,total:t.totalBytesExpectedToSend})}))}))}async uploadFile({filePath:t,cloudPath:e="",fileType:n="image",onUploadProgress:r}){if("string"!==La(e))throw new _c({code:"INVALID_PARAM",message:"cloudPath必须为字符串类型"});if(!(e=e.trim()))throw new _c({code:"INVALID_PARAM",message:"cloudPath不可为空"});if(/:\/\//.test(e))throw new _c({code:"INVALID_PARAM",message:"cloudPath不合法"});const i=await Qu({path:"/".concat(e.replace(/^\//,""),"?post_url")},this.config),{file_id:s,upload_url:o,form_data:a}=i,c=a&&a.reduce(((t,e)=>(t[e.key]=e.value,t)),{});return this.uploadFileToOSS({url:o,filePath:t,fileType:n,formData:c,onUploadProgress:r}).then((()=>({fileID:s})))}async getTempFileURL({fileList:t}){return new Promise(((e,n)=>{(!t||t.length<0)&&e({code:"INVALID_PARAM",message:"fileList不能为空数组"}),t.length>50&&e({code:"INVALID_PARAM",message:"fileList数组长度不能超过50"});const r=[];for(const s of t){let t;"string"!==La(s)&&e({code:"INVALID_PARAM",message:"fileList的元素必须是非空的字符串"});try{t=tl.call(this,s)}catch(i){console.warn(i.errCode,i.errMsg),t=s}r.push({file_id:t,expire:600})}Qu({path:"/?download_url",data:{file_list:r},method:"POST"},this.config).then((t=>{const{file_list:n=[]}=t;e({fileList:n.map((t=>({fileID:el.call(this,t.file_id),tempFileURL:t.download_url})))})})).catch((t=>n(t)))}))}async connectWebSocket(t){const{name:e,query:n}=t;return wc.connectSocket({url:this._websocket.signedURL(e,n),complete:()=>{}})}}(t);return e.auth=function(){return{signInAnonymously:function(){return Promise.resolve()},getLoginState:function(){return Promise.resolve(!0)}}},e}};function il({data:t}){let e;e=kc();const n=JSON.parse(JSON.stringify(t||{}));if(Object.assign(n,{clientInfo:e}),!n.uniIdToken){const{token:t}=bc();t&&(n.uniIdToken=t)}return n}const sl=[{rule:/fc_function_not_found|FUNCTION_NOT_FOUND/,content:",云函数[{functionName}]在云端不存在,请检查此云函数名称是否正确以及该云函数是否已上传到服务空间",mode:"append"}];var ol=/[\\^$.*+?()[\]{}|]/g,al=RegExp(ol.source);function cl(t,e,n){return t.replace(new RegExp((r=e)&&al.test(r)?r.replace(ol,"\\$&"):r,"g"),n);var r}const ul="request",ll="response",hl="both",fl="_globalUniCloudStatus",dl={code:2e4,message:"System error"},pl={code:20101,message:"Invalid client"};function gl(t){const{errSubject:e,subject:n,errCode:r,errMsg:i,code:s,message:o,cause:a}=t||{};return new _c({subject:e||n||"uni-secure-network",code:r||s||dl.code,message:i||o,cause:a})}let ml;function yl({secretType:t}={}){return t===ul||t===ll||t===hl}function vl({functionName:t,result:e,logPvd:n}){}function _l(t){const e=t.callFunction,n=function(n){const r=n.name;n.data=il.call(t,{data:n.data});const i={aliyun:"aliyun",tencent:"tcb",tcb:"tcb",alipay:"alipay",dcloud:"dcloud"}[this.config.provider],s=yl(n)||false;return e.call(this,n).then((t=>(t.errCode=0,!s&&vl.call(this,{functionName:r,result:t,logPvd:i}),Promise.resolve(t))),(t=>(!s&&vl.call(this,{functionName:r,result:t,logPvd:i}),t&&t.message&&(t.message=function({message:t="",extraInfo:e={},formatter:n=[]}={}){for(let r=0;r<n.length;r++){const{rule:i,content:s,mode:o}=n[r],a=t.match(i);if(!a)continue;let c=s;for(let t=1;t<a.length;t++)c=cl(c,`{$${t}}`,a[t]);for(const t in e)c=cl(c,`{${t}}`,e[t]);return"replace"===o?c:t+c}return t}({message:`[${n.name}]: ${t.message}`,formatter:sl,extraInfo:{functionName:r}})),Promise.reject(t))))};t.callFunction=function(e){const{provider:r,spaceId:i}=t.config,s=e.name;let o,a;return e.data=e.data||{},o=n,o=o.bind(t),a=function({name:t,data:e={}}){return"uni-id-co"===t&&"secureNetworkHandshakeByWeixin"===e.method}(e)?o.call(t,e):yl(e)?new ml({secretType:e.secretType,uniCloudIns:t}).wrapEncryptDataCallFunction(n.bind(t))(e):function({provider:t,spaceId:e,functionName:n}={}){const{appId:r,uniPlatform:i,osName:s}=Ic();let o=i;"app"===i&&(o=s);const a=function({provider:t,spaceId:e}={}){const n=Ka;if(!n)return{};t=function(t){return"tencent"===t?"tcb":t}(t);const r=n.find((n=>n.provider===t&&n.spaceId===e));return r&&r.config}({provider:t,spaceId:e});if(!a||!a.accessControl||!a.accessControl.enable)return!1;const c=a.accessControl.function||{},u=Object.keys(c);if(0===u.length)return!0;const l=function(t,e){let n,r,i;for(let s=0;s<t.length;s++){const o=t[s];o!==e?"*"!==o?o.split(",").map((t=>t.trim())).indexOf(e)>-1&&(r=o):i=o:n=o}return n||r||i}(u,n);if(!l)return!1;if((c[l]||[]).find(((t={})=>t.appId===r&&(t.platform||"").toLowerCase()===o.toLowerCase())))return!0;throw console.error(`此应用[appId: ${r}, platform: ${o}]不在云端配置的允许访问的应用列表内,参考:https://uniapp.dcloud.net.cn/uniCloud/secure-network.html#verify-client`),gl(pl)}({provider:r,spaceId:i,functionName:s})?new ml({secretType:e.secretType,uniCloudIns:t}).wrapVerifyClientCallFunction(n.bind(t))(e):o(e),Object.defineProperty(a,"result",{get:()=>(console.warn("当前返回结果为Promise类型,不可直接访问其result属性,详情请参考:https://uniapp.dcloud.net.cn/uniCloud/faq?id=promise"),{})}),a.then((t=>("undefined"!=typeof UTSJSONObject&&(t.result=new UTSJSONObject(t.result)),t)))}}ml=class{constructor(){throw gl({message:`Platform ${za} is not enabled, please check whether secure network module is enabled in your manifest.json`})}};const wl=Symbol("CLIENT_DB_INTERNAL");function Sl(t,e){return t.then="DoNotReturnProxyWithAFunctionNamedThen",t._internalType=wl,t.inspect=null,t.__v_raw=void 0,new Proxy(t,{get(t,n,r){if("_uniClient"===n)return null;if("symbol"==typeof n)return t[n];if(n in t||"string"!=typeof n){const e=t[n];return"function"==typeof e?e.bind(t):e}return e.get(t,n,r)}})}function bl(t){return{on:(e,n)=>{t[e]=t[e]||[],t[e].indexOf(n)>-1||t[e].push(n)},off:(e,n)=>{t[e]=t[e]||[];const r=t[e].indexOf(n);-1!==r&&t[e].splice(r,1)}}}const El=["db.Geo","db.command","command.aggregate"];function Tl(t,e){return El.indexOf(`${t}.${e}`)>-1}function xl(t){switch(La(t=Sc(t))){case"array":return t.map((t=>xl(t)));case"object":return t._internalType===wl||Object.keys(t).forEach((e=>{t[e]=xl(t[e])})),t;case"regexp":return{$regexp:{source:t.source,flags:t.flags}};case"date":return{$date:t.toISOString()};default:return t}}function Il(t){return t&&t.content&&t.content.$method}class Dl{constructor(t,e,n){this.content=t,this.prevStage=e||null,this.udb=null,this._database=n}toJSON(){let t=this;const e=[t.content];for(;t.prevStage;)t=t.prevStage,e.push(t.content);return{$db:e.reverse().map((t=>({$method:t.$method,$param:xl(t.$param)})))}}toString(){return JSON.stringify(this.toJSON())}getAction(){const t=this.toJSON().$db.find((t=>"action"===t.$method));return t&&t.$param&&t.$param[0]}getCommand(){return{$db:this.toJSON().$db.filter((t=>"action"!==t.$method))}}get isAggregate(){let t=this;for(;t;){const e=Il(t),n=Il(t.prevStage);if("aggregate"===e&&"collection"===n||"pipeline"===e)return!0;t=t.prevStage}return!1}get isCommand(){let t=this;for(;t;){if("command"===Il(t))return!0;t=t.prevStage}return!1}get isAggregateCommand(){let t=this;for(;t;){const e=Il(t),n=Il(t.prevStage);if("aggregate"===e&&"command"===n)return!0;t=t.prevStage}return!1}getNextStageFn(t){const e=this;return function(){return Al({$method:t,$param:xl(Array.from(arguments))},e,e._database)}}get count(){return this.isAggregate?this.getNextStageFn("count"):function(){return this._send("count",Array.from(arguments))}}get remove(){return this.isCommand?this.getNextStageFn("remove"):function(){return this._send("remove",Array.from(arguments))}}get(){return this._send("get",Array.from(arguments))}get add(){return this.isCommand?this.getNextStageFn("add"):function(){return this._send("add",Array.from(arguments))}}update(){return this._send("update",Array.from(arguments))}end(){return this._send("end",Array.from(arguments))}get set(){return this.isCommand?this.getNextStageFn("set"):function(){throw new Error("JQL禁止使用set方法")}}_send(t,e){const n=this.getAction(),r=this.getCommand();return r.$db.push({$method:t,$param:xl(e)}),this._database._callCloudFunction({action:n,command:r})}}function Al(t,e,n){return Sl(new Dl(t,e,n),{get(t,e){let r="db";return t&&t.content&&(r=t.content.$method),Tl(r,e)?Al({$method:e},t,n):function(){return Al({$method:e,$param:xl(Array.from(arguments))},t,n)}}})}function kl({path:t,method:e}){return class{constructor(){this.param=Array.from(arguments)}toJSON(){return{$newDb:[...t.map((t=>({$method:t}))),{$method:e,$param:this.param}]}}toString(){return JSON.stringify(this.toJSON())}}}function Ol(t,e={}){return Sl(new t(e),{get:(t,e)=>Tl("db",e)?Al({$method:e},null,t):function(){return Al({$method:e,$param:xl(Array.from(arguments))},null,t)}})}class Rl extends class{constructor({uniClient:t={},isJQL:e=!1}={}){this._uniClient=t,this._authCallBacks={},this._dbCallBacks={},t._isDefault&&(this._dbCallBacks=Ya("_globalUniCloudDatabaseCallback")),e||(this.auth=bl(this._authCallBacks)),this._isJQL=e,Object.assign(this,bl(this._dbCallBacks)),this.env=Sl({},{get:(t,e)=>({$env:e})}),this.Geo=Sl({},{get:(t,e)=>kl({path:["Geo"],method:e})}),this.serverDate=kl({path:[],method:"serverDate"}),this.RegExp=kl({path:[],method:"RegExp"})}getCloudEnv(t){if("string"!=typeof t||!t.trim())throw new Error("getCloudEnv参数错误");return{$env:t.replace("$cloudEnv_","")}}_callback(t,e){const n=this._dbCallBacks;n[t]&&n[t].forEach((t=>{t(...e)}))}_callbackAuth(t,e){const n=this._authCallBacks;n[t]&&n[t].forEach((t=>{t(...e)}))}multiSend(){const t=Array.from(arguments),e=t.map((t=>{const e=t.getAction(),n=t.getCommand();if("getTemp"!==n.$db[n.$db.length-1].$method)throw new Error("multiSend只支持子命令内使用getTemp");return{action:e,command:n}}));return this._callCloudFunction({multiCommand:e,queryList:t})}}{_parseResult(t){return this._isJQL?t.result:t}_callCloudFunction({action:t,command:e,multiCommand:n,queryList:r}){function i(t,e){if(n&&r)for(let n=0;n<r.length;n++){const i=r[n];i.udb&&"function"==typeof i.udb.setResult&&(e?i.udb.setResult(e):i.udb.setResult(t.result.dataList[n]))}}const s=this,o=this._isJQL?"databaseForJQL":"database";function a(t){return s._callback("error",[t]),ec(nc(o,"fail"),t).then((()=>ec(nc(o,"complete"),t))).then((()=>(i(null,t),pc(sc,{type:cc,content:t}),Promise.reject(t))))}const c=ec(nc(o,"invoke")),u=this._uniClient;return c.then((()=>u.callFunction({name:"DCloud-clientDB",type:Ca,data:{action:t,command:e,multiCommand:n}}))).then((t=>{const{code:e,message:n,token:r,tokenExpired:c,systemInfo:u=[]}=t.result;if(u)for(let i=0;i<u.length;i++){const{level:t,message:e,detail:n}=u[i];let r="[System Info]"+e;n&&(r=`${r}\n详细信息:${n}`),(console[t]||console.log)(r)}if(e)return a(new _c({code:e,message:n,requestId:t.requestId}));t.result.errCode=t.result.errCode||t.result.code,t.result.errMsg=t.result.errMsg||t.result.message,r&&c&&(Ec({token:r,tokenExpired:c}),this._callbackAuth("refreshToken",[{token:r,tokenExpired:c}]),this._callback("refreshToken",[{token:r,tokenExpired:c}]),pc(ac,{token:r,tokenExpired:c}));const l=[{prop:"affectedDocs",tips:"affectedDocs不再推荐使用,请使用inserted/deleted/updated/data.length替代"},{prop:"code",tips:"code不再推荐使用,请使用errCode替代"},{prop:"message",tips:"message不再推荐使用,请使用errMsg替代"}];for(let i=0;i<l.length;i++){const{prop:e,tips:n}=l[i];if(e in t.result){const r=t.result[e];Object.defineProperty(t.result,e,{get:()=>(console.warn(n),r)})}}return h=t,ec(nc(o,"success"),h).then((()=>ec(nc(o,"complete"),h))).then((()=>{i(h,null);const t=s._parseResult(h);return pc(sc,{type:cc,content:t}),Promise.resolve(t)}));var h}),(t=>(/fc_function_not_found|FUNCTION_NOT_FOUND/g.test(t.message)&&console.warn("clientDB未初始化,请在web控制台保存一次schema以开启clientDB"),a(new _c({code:t.code||"SYSTEM_ERROR",message:t.message,requestId:t.requestId})))))}}const Pl="token无效,跳转登录页面",Ml="token过期,跳转登录页面",Cl={TOKEN_INVALID_TOKEN_EXPIRED:Ml,TOKEN_INVALID_INVALID_CLIENTID:Pl,TOKEN_INVALID:Pl,TOKEN_INVALID_WRONG_TOKEN:Pl,TOKEN_INVALID_ANONYMOUS_USER:Pl},Bl={"uni-id-token-expired":Ml,"uni-id-check-token-failed":Pl,"uni-id-token-not-exist":Pl,"uni-id-check-device-feature-failed":Pl};function Nl(t,e){let n="";return n=t?`${t}/${e}`:e,n.replace(/^\//,"")}function Ll(t=[],e=""){const n=[],r=[];return t.forEach((t=>{!0===t.needLogin?n.push(Nl(e,t.path)):!1===t.needLogin&&r.push(Nl(e,t.path))})),{needLoginPage:n,notNeedLoginPage:r}}function jl(t){return t.split("?")[0].replace(/^\//,"")}function Vl(){return function(t){let e=t&&t.$page&&t.$page.fullPath||"";return e?("/"!==e.charAt(0)&&(e="/"+e),e):e}(function(){const t=getCurrentPages();return t[t.length-1]}())}function Ul(){return jl(Vl())}function $l(t="",e={}){if(!t)return!1;if(!(e&&e.list&&e.list.length))return!1;const n=e.list,r=jl(t);return n.some((t=>t.pagePath===r))}const Hl=!!Ea.uniIdRouter,{loginPage:ql,routerNeedLogin:Fl,resToLogin:Kl,needLoginPage:zl,notNeedLoginPage:Wl,loginPageInTabBar:Jl}=function({pages:t=[],subPackages:e=[],uniIdRouter:n={},tabBar:r={}}=Ea){const{loginPage:i,needLogin:s=[],resToLogin:o=!0}=n,{needLoginPage:a,notNeedLoginPage:c}=Ll(t),{needLoginPage:u,notNeedLoginPage:l}=function(t=[]){const e=[],n=[];return t.forEach((t=>{const{root:r,pages:i=[]}=t,{needLoginPage:s,notNeedLoginPage:o}=Ll(i,r);e.push(...s),n.push(...o)})),{needLoginPage:e,notNeedLoginPage:n}}(e);return{loginPage:i,routerNeedLogin:s,resToLogin:o,needLoginPage:[...a,...u],notNeedLoginPage:[...c,...l],loginPageInTabBar:$l(i,r)}}();if(zl.indexOf(ql)>-1)throw new Error(`Login page [${ql}] should not be "needLogin", please check your pages.json`);function Gl(t){const e=Ul();if("/"===t.charAt(0))return t;const[n,r]=t.split("?"),i=n.replace(/^\//,"").split("/"),s=e.split("/");s.pop();for(let o=0;o<i.length;o++){const t=i[o];".."===t?s.pop():"."!==t&&s.push(t)}return""===s[0]&&s.shift(),"/"+s.join("/")+(r?"?"+r:"")}function Yl({redirect:t}){const e=jl(t),n=jl(ql);return Ul()!==n&&e!==n}function Zl({api:t,redirect:e}={}){if(!e||!Yl({redirect:e}))return;const n=(i=e,"/"!==(r=ql).charAt(0)&&(r="/"+r),i?r.indexOf("?")>-1?r+`&uniIdRedirectUrl=${encodeURIComponent(i)}`:r+`?uniIdRedirectUrl=${encodeURIComponent(i)}`:r);var r,i;Jl?"navigateTo"!==t&&"redirectTo"!==t||(t="switchTab"):"switchTab"===t&&(t="navigateTo");const s={navigateTo:en.navigateTo,redirectTo:en.redirectTo,switchTab:en.switchTab,reLaunch:en.reLaunch};setTimeout((()=>{s[t]({url:n})}),0)}function Xl({url:t}={}){const e={abortLoginPageJump:!1,autoToLoginPage:!1},n=function(){const{token:t,tokenExpired:e}=bc();let n;if(t){if(e<Date.now()){const t="uni-id-token-expired";n={errCode:t,errMsg:Bl[t]}}}else{const t="uni-id-check-token-failed";n={errCode:t,errMsg:Bl[t]}}return n}();if(function(t){const e=jl(Gl(t));return!(Wl.indexOf(e)>-1)&&(zl.indexOf(e)>-1||Fl.some((e=>{return n=t,new RegExp(e).test(n);var n})))}(t)&&n){if(n.uniIdRedirectUrl=t,hc(oc).length>0)return setTimeout((()=>{pc(oc,n)}),0),e.abortLoginPageJump=!0,e;e.autoToLoginPage=!0}return e}function Ql(){!function(){const t=Vl(),{abortLoginPageJump:e,autoToLoginPage:n}=Xl({url:t});e||n&&Zl({api:"redirectTo",redirect:t})}();const t=["navigateTo","redirectTo","reLaunch","switchTab"];for(let e=0;e<t.length;e++){const n=t[e];en.addInterceptor(n,{invoke(t){const{abortLoginPageJump:e,autoToLoginPage:r}=Xl({url:t.url});return e?t:r?(Zl({api:n,redirect:Gl(t.url)}),!1):t}})}}function th(){this.onResponse((t=>{const{type:e,content:n}=t;let r=!1;switch(e){case"cloudobject":r=function(t){if("object"!=typeof t)return!1;const{errCode:e}=t||{};return e in Bl}(n);break;case"clientdb":r=function(t){if("object"!=typeof t)return!1;const{errCode:e}=t||{};return e in Cl}(n)}r&&function(t={}){const e=hc(oc);yc().then((()=>{const n=Vl();if(n&&Yl({redirect:n}))return e.length>0?pc(oc,Object.assign({uniIdRedirectUrl:n},t)):void(ql&&Zl({api:"navigateTo",redirect:n}))}))}(n)}))}function eh(t){var e;(e=t).onResponse=function(t){fc(sc,t)},e.offResponse=function(t){dc(sc,t)},function(t){t.onNeedLogin=function(t){fc(oc,t)},t.offNeedLogin=function(t){dc(oc,t)},Hl&&(Ya(fl).needLoginInit||(Ya(fl).needLoginInit=!0,yc().then((()=>{Ql.call(t)})),Kl&&th.call(t)))}(t),function(t){t.onRefreshToken=function(t){fc(ac,t)},t.offRefreshToken=function(t){dc(ac,t)}}(t)}let nh;const rh="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",ih=/^(?:[A-Za-z\d+/]{4})*?(?:[A-Za-z\d+/]{2}(?:==)?|[A-Za-z\d+/]{3}=?)?$/;function sh(){const t=bc().token||"",e=t.split(".");if(!t||3!==e.length)return{uid:null,role:[],permission:[],tokenExpired:0};let n;try{n=JSON.parse((r=e[1],decodeURIComponent(nh(r).split("").map((function(t){return"%"+("00"+t.charCodeAt(0).toString(16)).slice(-2)})).join(""))))}catch(i){throw new Error("获取当前用户信息出错,详细错误信息为:"+i.message)}var r;return n.tokenExpired=1e3*n.exp,delete n.exp,delete n.iat,n}nh="function"!=typeof atob?function(t){if(t=String(t).replace(/[\t\n\f\r ]+/g,""),!ih.test(t))throw new Error("Failed to execute 'atob' on 'Window': The string to be decoded is not correctly encoded.");var e;t+="==".slice(2-(3&t.length));for(var n,r,i="",s=0;s<t.length;)e=rh.indexOf(t.charAt(s++))<<18|rh.indexOf(t.charAt(s++))<<12|(n=rh.indexOf(t.charAt(s++)))<<6|(r=rh.indexOf(t.charAt(s++))),i+=64===n?String.fromCharCode(e>>16&255):64===r?String.fromCharCode(e>>16&255,e>>8&255):String.fromCharCode(e>>16&255,e>>8&255,255&e);return i}:atob;var oh=Ta((function(t,e){Object.defineProperty(e,"__esModule",{value:!0});const n="chooseAndUploadFile:ok",r="chooseAndUploadFile:fail";function i(t,e){return t.tempFiles.forEach(((t,n)=>{t.name||(t.name=t.path.substring(t.path.lastIndexOf("/")+1)),e&&(t.fileType=e),t.cloudPath=Date.now()+"_"+n+t.name.substring(t.name.lastIndexOf("."))})),t.tempFilePaths||(t.tempFilePaths=t.tempFiles.map((t=>t.path))),t}function s(t,e,{onChooseFile:r,onUploadProgress:i}){return e.then((t=>{if(r){const e=r(t);if(void 0!==e)return Promise.resolve(e).then((e=>void 0===e?t:e))}return t})).then((e=>!1===e?{errMsg:n,tempFilePaths:[],tempFiles:[]}:function(t,e,r=5,i){(e=Object.assign({},e)).errMsg=n;const s=e.tempFiles,o=s.length;let a=0;return new Promise((n=>{for(;a<r;)c();function c(){const r=a++;if(r>=o)return void(!s.find((t=>!t.url&&!t.errMsg))&&n(e));const u=s[r];t.uploadFile({provider:u.provider,filePath:u.path,cloudPath:u.cloudPath,fileType:u.fileType,cloudPathAsRealPath:u.cloudPathAsRealPath,onUploadProgress(t){t.index=r,t.tempFile=u,t.tempFilePath=u.path,i&&i(t)}}).then((t=>{u.url=t.fileID,r<o&&c()})).catch((t=>{u.errMsg=t.errMsg||t.message,r<o&&c()}))}}))}(t,e,5,i)))}e.initChooseAndUploadFile=function(t){return function(e={type:"all"}){return"image"===e.type?s(t,function(t){const{count:e,sizeType:n,sourceType:s=["album","camera"],extension:o}=t;return new Promise(((t,a)=>{en.chooseImage({count:e,sizeType:n,sourceType:s,extension:o,success(e){t(i(e,"image"))},fail(t){a({errMsg:t.errMsg.replace("chooseImage:fail",r)})}})}))}(e),e):"video"===e.type?s(t,function(t){const{camera:e,compressed:n,maxDuration:s,sourceType:o=["album","camera"],extension:a}=t;return new Promise(((t,c)=>{en.chooseVideo({camera:e,compressed:n,maxDuration:s,sourceType:o,extension:a,success(e){const{tempFilePath:n,duration:r,size:s,height:o,width:a}=e;t(i({errMsg:"chooseVideo:ok",tempFilePaths:[n],tempFiles:[{name:e.tempFile&&e.tempFile.name||"",path:n,size:s,type:e.tempFile&&e.tempFile.type||"",width:a,height:o,duration:r,fileType:"video",cloudPath:""}]},"video"))},fail(t){c({errMsg:t.errMsg.replace("chooseVideo:fail",r)})}})}))}(e),e):s(t,function(t){const{count:e,extension:n}=t;return new Promise(((t,s)=>{let o=en.chooseFile;if(void 0!==tn&&"function"==typeof tn.chooseMessageFile&&(o=tn.chooseMessageFile),"function"!=typeof o)return s({errMsg:r+" 请指定 type 类型,该平台仅支持选择 image 或 video。"});o({type:"all",count:e,extension:n,success(e){t(i(e))},fail(t){s({errMsg:t.errMsg.replace("chooseFile:fail",r)})}})}))}(e),e)}}})),ah=function(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}(oh);const ch="manual";function uh(t){return{props:{localdata:{type:Array,default:()=>[]},options:{type:[Object,Array],default:()=>({})},spaceInfo:{type:Object,default:()=>({})},collection:{type:[String,Array],default:""},action:{type:String,default:""},field:{type:String,default:""},orderby:{type:String,default:""},where:{type:[String,Object],default:""},pageData:{type:String,default:"add"},pageCurrent:{type:Number,default:1},pageSize:{type:Number,default:20},getcount:{type:[Boolean,String],default:!1},gettree:{type:[Boolean,String],default:!1},gettreepath:{type:[Boolean,String],default:!1},startwith:{type:String,default:""},limitlevel:{type:Number,default:10},groupby:{type:String,default:""},groupField:{type:String,default:""},distinct:{type:[Boolean,String],default:!1},foreignKey:{type:String,default:""},loadtime:{type:String,default:"auto"},manual:{type:Boolean,default:!1}},data:()=>({mixinDatacomLoading:!1,mixinDatacomHasMore:!1,mixinDatacomResData:[],mixinDatacomErrorMessage:"",mixinDatacomPage:{},mixinDatacomError:null}),created(){this.mixinDatacomPage={current:this.pageCurrent,size:this.pageSize,count:0},this.$watch((()=>{var t=[];return["pageCurrent","pageSize","localdata","collection","action","field","orderby","where","getont","getcount","gettree","groupby","groupField","distinct"].forEach((e=>{t.push(this[e])})),t}),((t,e)=>{if(this.loadtime===ch)return;let n=!1;const r=[];for(let i=2;i<t.length;i++)t[i]!==e[i]&&(r.push(t[i]),n=!0);t[0]!==e[0]&&(this.mixinDatacomPage.current=this.pageCurrent),this.mixinDatacomPage.size=this.pageSize,this.onMixinDatacomPropsChange(n,r)}))},methods:{onMixinDatacomPropsChange(t,e){},mixinDatacomEasyGet({getone:t=!1,success:e,fail:n}={}){this.mixinDatacomLoading||(this.mixinDatacomLoading=!0,this.mixinDatacomErrorMessage="",this.mixinDatacomError=null,this.mixinDatacomGet().then((n=>{this.mixinDatacomLoading=!1;const{data:r,count:i}=n.result;this.getcount&&(this.mixinDatacomPage.count=i),this.mixinDatacomHasMore=r.length<this.pageSize;const s=t?r.length?r[0]:void 0:r;this.mixinDatacomResData=s,e&&e(s)})).catch((t=>{this.mixinDatacomLoading=!1,this.mixinDatacomErrorMessage=t,this.mixinDatacomError=t,n&&n(t)})))},mixinDatacomGet(e={}){let n;e=e||{},n="undefined"!=typeof __uniX&&__uniX?t.databaseForJQL(this.spaceInfo):t.database(this.spaceInfo);const r=e.action||this.action;r&&(n=n.action(r));const i=e.collection||this.collection;n=Array.isArray(i)?n.collection(...i):n.collection(i);const s=e.where||this.where;s&&Object.keys(s).length&&(n=n.where(s));const o=e.field||this.field;o&&(n=n.field(o));const a=e.foreignKey||this.foreignKey;a&&(n=n.foreignKey(a));const c=e.groupby||this.groupby;c&&(n=n.groupBy(c));const u=e.groupField||this.groupField;u&&(n=n.groupField(u)),!0===(void 0!==e.distinct?e.distinct:this.distinct)&&(n=n.distinct());const l=e.orderby||this.orderby;l&&(n=n.orderBy(l));const h=void 0!==e.pageCurrent?e.pageCurrent:this.mixinDatacomPage.current,f=void 0!==e.pageSize?e.pageSize:this.mixinDatacomPage.size,d=void 0!==e.getcount?e.getcount:this.getcount,p=void 0!==e.gettree?e.gettree:this.gettree,g=void 0!==e.gettreepath?e.gettreepath:this.gettreepath,m={getCount:d},y={limitLevel:void 0!==e.limitlevel?e.limitlevel:this.limitlevel,startWith:void 0!==e.startwith?e.startwith:this.startwith};return p&&(m.getTree=y),g&&(m.getTreePath=y),n=n.skip(f*(h-1)).limit(f).get(m),n}}}}function lh(t){return Ya("_globalUniCloudSecureNetworkCache__{spaceId}".replace("{spaceId}",t.config.spaceId))}async function hh({openid:t,callLoginByWeixin:e=!1}={}){const n=lh(this);if(t&&e)throw new Error("[SecureNetwork] openid and callLoginByWeixin cannot be passed at the same time");if(t)return n.mpWeixinOpenid=t,{};const r=await new Promise(((t,e)=>{en.login({success(e){t(e.code)},fail(t){e(new Error(t.errMsg))}})})),i=this.importObject("uni-id-co",{customUI:!0});return await i.secureNetworkHandshakeByWeixin({code:r,callLoginByWeixin:e}),n.mpWeixinCode=r,{code:r}}async function fh(t){const e=lh(this);return e.initPromise||(e.initPromise=hh.call(this,t).then((t=>t)).catch((t=>{throw delete e.initPromise,t}))),e.initPromise}function dh(t){Ac=t}function ph(t){const e={getSystemInfo:en.getSystemInfo,getPushClientId:en.getPushClientId};return function(n){return new Promise(((r,i)=>{e[t]({...n,success(t){r(t)},fail(t){i(t)}})}))}}class gh extends class{constructor(){this._callback={}}addListener(t,e){this._callback[t]||(this._callback[t]=[]),this._callback[t].push(e)}on(t,e){return this.addListener(t,e)}removeListener(t,e){if(!e)throw new Error('The "listener" argument must be of type function. Received undefined');const n=this._callback[t];if(!n)return;const r=function(t,e){for(let n=t.length-1;n>=0;n--)if(t[n]===e)return n;return-1}(n,e);n.splice(r,1)}off(t,e){return this.removeListener(t,e)}removeAllListener(t){delete this._callback[t]}emit(t,...e){const n=this._callback[t];if(n)for(let r=0;r<n.length;r++)n[r](...e)}}{constructor(){super(),this._uniPushMessageCallback=this._receivePushMessage.bind(this),this._currentMessageId=-1,this._payloadQueue=[]}init(){return Promise.all([ph("getSystemInfo")(),ph("getPushClientId")()]).then((([{appId:t}={},{cid:e}={}]=[])=>{if(!t)throw new Error("Invalid appId, please check the manifest.json file");if(!e)throw new Error("Invalid push client id");this._appId=t,this._pushClientId=e,this._seqId=Date.now()+"-"+Math.floor(9e5*Math.random()+1e5),this.emit("open"),this._initMessageListener()}),(t=>{throw this.emit("error",t),this.close(),t}))}async open(){return this.init()}_isUniCloudSSE(t){if("receive"!==t.type)return!1;const e=t&&t.data&&t.data.payload;return!(!e||"UNI_CLOUD_SSE"!==e.channel||e.seqId!==this._seqId)}_receivePushMessage(t){if(!this._isUniCloudSSE(t))return;const e=t&&t.data&&t.data.payload,{action:n,messageId:r,message:i}=e;this._payloadQueue.push({action:n,messageId:r,message:i}),this._consumMessage()}_consumMessage(){for(;;){const t=this._payloadQueue.find((t=>t.messageId===this._currentMessageId+1));if(!t)break;this._currentMessageId++,this._parseMessagePayload(t)}}_parseMessagePayload(t){const{action:e,messageId:n,message:r}=t;"end"===e?this._end({messageId:n,message:r}):"message"===e&&this._appendMessage({messageId:n,message:r})}_appendMessage({messageId:t,message:e}={}){this.emit("message",e)}_end({messageId:t,message:e}={}){this.emit("end",e),this.close()}_initMessageListener(){en.onPushMessage(this._uniPushMessageCallback)}_destroy(){en.offPushMessage(this._uniPushMessageCallback)}toJSON(){return{appId:this._appId,pushClientId:this._pushClientId,seqId:this._seqId}}close(){this._destroy(),this.emit("close")}}const mh={tcb:Ku,tencent:Ku,aliyun:Mc,private:Ju,dcloud:Ju,alipay:rl};let yh=new class{init(t){let e={};const n=mh[t.provider];if(!n)throw new Error("未提供正确的provider参数");var r;return e=n.init(t),function(t){t._initPromiseHub||(t._initPromiseHub=new qa({createPromise:function(){let e=Promise.resolve();e=new Promise((t=>{setTimeout((()=>{t()}),1)}));const n=t.auth();return e.then((()=>n.getLoginState())).then((t=>t?Promise.resolve():n.signInAnonymously()))}}))}(e),_l(e),function(t){const e=t.uploadFile;t.uploadFile=function(t){return e.call(this,t)}}(e),(r=e).database=function(t){if(t&&Object.keys(t).length>0)return r.init(t).database();if(this._database)return this._database;const e=Ol(Rl,{uniClient:r});return this._database=e,e},r.databaseForJQL=function(t){if(t&&Object.keys(t).length>0)return r.init(t).databaseForJQL();if(this._databaseForJQL)return this._databaseForJQL;const e=Ol(Rl,{uniClient:r,isJQL:!0});return this._databaseForJQL=e,e},function(t){t.getCurrentUserInfo=sh,t.chooseAndUploadFile=ah.initChooseAndUploadFile(t),Object.assign(t,{get mixinDatacom(){return uh(t)}}),t.SSEChannel=gh,t.initSecureNetworkByWeixin=function(t){return function({openid:e,callLoginByWeixin:n=!1}={}){return fh.call(t,{openid:e,callLoginByWeixin:n})}}(t),t.setCustomClientInfo=dh,t.importObject=function(e){return function(n,r={}){r=function(t,e={}){return t.customUI=e.customUI||t.customUI,t.parseSystemError=e.parseSystemError||t.parseSystemError,Object.assign(t.loadingOptions,e.loadingOptions),Object.assign(t.errorOptions,e.errorOptions),"object"==typeof e.secretMethods&&(t.secretMethods=e.secretMethods),t}({customUI:!1,loadingOptions:{title:"加载中...",mask:!0},errorOptions:{type:"modal",retry:!1}},r);const{customUI:i,loadingOptions:s,errorOptions:o,parseSystemError:a}=r,c=!i;return new Proxy({},{get(i,u){switch(u){case"toString":return"[object UniCloudObject]";case"toJSON":return{}}return function({fn:t,interceptorName:e,getCallbackArgs:n}={}){return async function(...r){const i=n?n({params:r}):{};let s,o;try{return await ec(nc(e,"invoke"),{...i}),s=await t(...r),await ec(nc(e,"success"),{...i,result:s}),s}catch(a){throw o=a,await ec(nc(e,"fail"),{...i,error:o}),o}finally{await ec(nc(e,"complete"),o?{...i,error:o}:{...i,result:s})}}}({fn:async function i(...l){let h;c&&en.showLoading({title:s.title,mask:s.mask});const f={name:n,type:Ma,data:{method:u,params:l}};"object"==typeof r.secretMethods&&function(t,e){const n=e.data.method,r=t.secretMethods||{},i=r[n]||r["*"];i&&(e.secretType=i)}(r,f);let d=!1;try{h=await e.callFunction(f)}catch(t){d=!0,h={result:new _c(t)}}const{errSubject:p,errCode:g,errMsg:m,newToken:y}=h.result||{};if(c&&en.hideLoading(),y&&y.token&&y.tokenExpired&&(Ec(y),pc(ac,{...y})),g){let t=m;if(d&&a&&(t=(await a({objectName:n,methodName:u,params:l,errSubject:p,errCode:g,errMsg:m})).errMsg||m),c)if("toast"===o.type)en.showToast({title:t,icon:"none"});else{if("modal"!==o.type)throw new Error(`Invalid errorOptions.type: ${o.type}`);{const{confirm:e}=await async function({title:t,content:e,showCancel:n,cancelText:r,confirmText:i}={}){return new Promise(((s,o)=>{en.showModal({title:t,content:e,showCancel:n,cancelText:r,confirmText:i,success(t){s(t)},fail(){s({confirm:!1,cancel:!0})}})}))}({title:"提示",content:t,showCancel:o.retry,cancelText:"取消",confirmText:o.retry?"重试":"确定"});if(o.retry&&e)return i(...l)}}const e=new _c({subject:p,code:g,message:m,requestId:h.requestId});throw e.detail=h.result,pc(sc,{type:lc,content:e}),e}return pc(sc,{type:lc,content:h.result}),h.result},interceptorName:"callObject",getCallbackArgs:function({params:t}={}){return{objectName:n,methodName:u,params:t}}})}})}}(t)}(e),["callFunction","uploadFile","deleteFile","getTempFileURL","downloadFile","chooseAndUploadFile"].forEach((t=>{if(!e[t])return;const n=e[t];e[t]=function(){return n.apply(e,Array.from(arguments))},e[t]=function(t,e){return function(n){let r=!1;if("callFunction"===e){const t=n&&n.type||Pa;r=t!==Pa}const i="callFunction"===e&&!r,s=this._initPromiseHub.exec();n=n||{};const{success:o,fail:a,complete:c}=vc(n),u=s.then((()=>r?Promise.resolve():ec(nc(e,"invoke"),n))).then((()=>t.call(this,n))).then((t=>r?Promise.resolve(t):ec(nc(e,"success"),t).then((()=>ec(nc(e,"complete"),t))).then((()=>(i&&pc(sc,{type:uc,content:t}),Promise.resolve(t))))),(t=>r?Promise.reject(t):ec(nc(e,"fail"),t).then((()=>ec(nc(e,"complete"),t))).then((()=>(pc(sc,{type:uc,content:t}),Promise.reject(t))))));if(!(o||a||c))return u;u.then((t=>{o&&o(t),c&&c(t),i&&pc(sc,{type:uc,content:t})}),(t=>{a&&a(t),c&&c(t),i&&pc(sc,{type:uc,content:t})}))}}(e[t],t).bind(e)})),e.init=this.init,e}};(()=>{const t=Wa;let e={};if(t&&1===t.length)e=t[0],yh=yh.init(e),yh._isDefault=!0;else{const e=["auth","callFunction","uploadFile","deleteFile","getTempFileURL","downloadFile","database","getCurrentUSerInfo","importObject"];let n;n=t&&t.length>0?"应用有多个服务空间,请通过uniCloud.init方法指定要使用的服务空间":"应用未关联服务空间,请在uniCloud目录右键关联服务空间",e.forEach((t=>{yh[t]=function(){return console.error(n),Promise.reject(new _c({code:"SYS_ERR",message:n}))}}))}Object.assign(yh,{get mixinDatacom(){return uh(yh)}}),eh(yh),yh.addInterceptor=Qa,yh.removeInterceptor=tc,yh.interceptObject=rc})();var vh=yh;exports._export_sfc=(t,e)=>{const n=t.__vccOpts||t;for(const[r,i]of e)n[r]=i;return n},exports.computed=vs,exports.createPinia=function(){const t=on(!0),e=t.run((()=>xr({})));let n=[],r=[];const i=vr({install(t){ca(i),i._a=t,t.provide(ua,i),t.config.globalProperties.$pinia=i,r.forEach((t=>n.push(t))),r=[]},use(t){return this._a?n.push(t):r.push(t),this},_p:n,_a:null,_e:t,_s:new Map,state:e});return i},exports.createSSRApp=co,exports.defineStore=function(t,e,n){let r,i;const s="function"==typeof e;function o(t,n){(t=t||(!!(as||ni||di)?pi(ua,null):null))&&ca(t),(t=aa)._s.has(r)||(s?Sa(r,e,i,t):wa(r,i,t));return t._s.get(r)}return"string"==typeof t?(r=t,i=s?n:e):(i=t,r=t.id),o.$id=r,o},exports.e=(t,...e)=>a(t,...e),exports.er=vh,exports.f=(t,e)=>function(t,e){let n;if(h(t)||g(t)){n=new Array(t.length);for(let r=0,i=t.length;r<i;r++)n[r]=e(t[r],r,r)}else if("number"==typeof t){n=new Array(t);for(let r=0;r<t;r++)n[r]=e(r+1,r,r)}else if(y(t))if(t[Symbol.iterator])n=Array.from(t,((t,n)=>e(t,n,n)));else{const r=Object.keys(t);n=new Array(r.length);for(let i=0,s=r.length;i<s;i++){const s=r[i];n[i]=e(t[s],s,i)}}else n=[];return n}(t,e),exports.index=en,exports.initVueI18n=function(t,e={},n,r){if("string"!=typeof t){const n=[e,t];t=n[0],e=n[1]}"string"!=typeof t&&(t=void 0!==en&&en.getLocale?en.getLocale():"undefined"!=typeof global&&global.getLocale?global.getLocale():"en"),"string"!=typeof n&&(n="undefined"!=typeof __uniConfig&&__uniConfig.fallbackLocale||"en");const i=new ht({locale:t,fallbackLocale:n,messages:e,watcher:r});let s=(t,e)=>{if("function"!=typeof getApp)s=function(t,e){return i.t(t,e)};else{let t=!1;s=function(e,n){const r=getApp().$vm;return r&&(r.$locale,t||(t=!0,function(t,e){t.$watchLocale?t.$watchLocale((t=>{e.setLocale(t)})):t.$watch((()=>t.$locale),(t=>{e.setLocale(t)}))}(r,i))),i.t(e,n)}}return s(t,e)};return{i18n:i,f:(t,e,n)=>i.f(t,e,n),t:(t,e)=>s(t,e),add:(t,e,n=!0)=>i.add(t,e,n),watch:t=>i.watchLocale(t),getLocale:()=>i.getLocale(),setLocale:t=>i.setLocale(t)}},exports.n=t=>V(t),exports.nextTick$1=Kr,exports.o=(t,e)=>so(t,e),exports.onLaunch=ra,exports.onLoad=ia,exports.onPullDownRefresh=oa,exports.onReady=sa,exports.onShow=na,exports.p=t=>function(t){const{uid:e,__counter:n}=cs();return e+","+((to[e]||(to[e]=[])).push(rs(t))-1)+","+n}(t),exports.r=(t,e,n)=>ao(t,e,n),exports.reactive=hr,exports.ref=xr,exports.resolveComponent=function(t,e){return function(t,e,n=!0,r=!1){const i=ni||as;if(i){const n=i.type;if("components"===t){const t=function(t,e=!0){return p(t)?t.displayName||t.name:t.name||e&&t.__name}(n,!1);if(t&&(t===e||t===I(e)||t===k(I(e))))return n}const s=ii(i[t]||n[t],e)||ii(i.appContext[t],e);return!s&&r?n:s}}("components",t,!0,e)||t},exports.s=t=>io(t),exports.sr=(t,e,n)=>function(t,e,n={}){const{$templateRefs:r}=cs();r.push({i:e,r:t,k:n.k,f:n.f})}(t,e,n),exports.t=t=>(t=>g(t)?t:null==t?"":h(t)||y(t)&&(t.toString===_||!p(t.toString))?JSON.stringify(t,U,2):String(t))(t),exports.unref=Dr,exports.useCssVars=function(t){const e=cs();e&&function(t,e){t.ctx.__cssVars=()=>{const n=e(t.proxy),r={};for(const t in n)r[`--${t}`]=n[t];return r}}(e,t)},exports.wx$1=tn;