gc_mobile 1.0.9 → 1.0.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/libs/main.js CHANGED
@@ -46,12 +46,20 @@ const xe = ge, st = (t) => t == "dev" ? "https://test.ihotel.cn/gw/v1/platform-g
46
46
  corpId: pe
47
47
  }
48
48
  );
49
- v.data && ((p = v.data) == null ? void 0 : p.result) === 0 ? o({ userInfo: (c = v == null ? void 0 : v.data) == null ? void 0 : c.retVal, res: v }) : (ne.alert({
50
- title: (x = v == null ? void 0 : v.data) == null ? void 0 : x.msg
49
+ v.data && ((p = v.data) == null ? void 0 : p.result) === 0 ? o({ userInfo: (c = v == null ? void 0 : v.data) == null ? void 0 : c.retVal, res: v }) : (ne.showToast({
50
+ type: "fail",
51
+ duration: 2e3,
52
+ content: (x = v == null ? void 0 : v.data) == null ? void 0 : x.msg,
53
+ complete: () => {
54
+ }
51
55
  }), o({ res: v }));
52
56
  } else
53
- ne.alert({
54
- title: "未配置参数:corpId"
57
+ ne.showToast({
58
+ type: "fail",
59
+ duration: 2e3,
60
+ content: "未配置参数:corpId",
61
+ complete: () => {
62
+ }
55
63
  });
56
64
  });
57
65
  }, ct = {
package/libs/main.umd.cjs CHANGED
@@ -1,4 +1,4 @@
1
- (function(G,H){typeof exports=="object"&&typeof module<"u"?H(exports,require("lodash-es"),require("dingtalk-jsapi"),require("qs"),require("axios")):typeof define=="function"&&define.amd?define(["exports","lodash-es","dingtalk-jsapi","qs","axios"],H):(G=typeof globalThis<"u"?globalThis:G||self,H(G.Main={},G._,G.dd$1,G.qs,G.axios))})(this,function(G,H,ze,ne,Be){"use strict";function Ne(t){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const e in t)if(e!=="default"){const a=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(r,e,a.get?a:{enumerable:!0,get:()=>t[e]})}}return r.default=t,Object.freeze(r)}const oe=Ne(ze),le=window.navigator.userAgent.toLowerCase();let pe={code:"",name:"未知"};function Ue(){return typeof window<"u"&&typeof document<"u"&&typeof document.querySelector=="function"&&typeof navigator<"u"&&typeof XMLHttpRequest=="function"}const We=[{code:"weixin",name:"微信",value:/MicroMessenger/i.test(le)},{code:"wxmp",name:"微信小程序",value:/miniProgram/i.test(le)||window.__wxjs_environment==="miniprogram"},{code:"dd",name:"钉钉",value:/DingTalk/i.test(le)}],ke=t=>t.value,Ae=H.find(We,ke);Ae?pe=Ae:Ue()&&(pe={code:"h5",name:"H5"});const de=pe,Ke=t=>t=="dev"?"https://test.ihotel.cn/gw/v1/platform-gcding":t=="prod"?"https://smart.ihotel.cn/guardian/gw/v1/platform-gcding":t||"https://test.ihotel.cn/gw/v1/platform-gcding",Ge=ne.parse(location.search,{ignoreQueryPrefix:!0}),ve=H.get(Ge,"corpId"),Qe={dd:{login:async({appCode:t,apiPrefix:r})=>{const e=Ke(r);return new Promise(async a=>{var p,c,x;if(ve){const{code:o}=await oe.getAuthCode({corpId:ve}),v=await Be.post(`${e}/api/auth/queryAuthNoExternalCompatible`,{appCode:t,authCode:o,corpId:ve});v.data&&((p=v.data)==null?void 0:p.result)===0?a({userInfo:(c=v==null?void 0:v.data)==null?void 0:c.retVal,res:v}):(oe.alert({title:(x=v==null?void 0:v.data)==null?void 0:x.msg}),a({res:v}))}else oe.alert({title:"未配置参数:corpId"})})},dd:oe},h5:{login:()=>new Promise(async t=>{const{token:r}=ne.parse(location.search,{ignoreQueryPrefix:!0});t(r?{userInfo:{ucToken:r}}:{userInfo:null})})},wxmp:{login:()=>new Promise(t=>{const{token:r}=ne.parse(location.search,{ignoreQueryPrefix:!0});t(r?{userInfo:{ucToken:r}}:{userInfo:null})})},weixin:{login:()=>new Promise(t=>{const{token:r}=ne.parse(location.search,{ignoreQueryPrefix:!0});t(r?{userInfo:{ucToken:r}}:{userInfo:null})})}},Xe={setNavigationBarTitle:t=>{de.code==="dd"?(console.log("钉钉对象",oe),oe.setNavigationTitle(t)):de.code==="weixin"?wx.setNavigationBarTitle(t):document.title=t.title}},Ve=t=>{let r="";return H.mapKeys(t,(e,a)=>{a&&(H.isEmpty(e)?r+="&"+a:r+="&"+a+"="+e)}),r},Ze=(t,r)=>H.isEmpty(r)?t:(H.includes(t,"?")?t:t+"?")+r.substring(1),Ye=(t,r)=>H.isEmpty(r)?t:`${t}?${ne.stringify(r)}`;var W=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function he(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function Je(t){if(t.__esModule)return t;var r=t.default;if(typeof r=="function"){var e=function a(){return this instanceof a?Reflect.construct(r,arguments,this.constructor):r.apply(this,arguments)};e.prototype=r.prototype}else e={};return Object.defineProperty(e,"__esModule",{value:!0}),Object.keys(t).forEach(function(a){var p=Object.getOwnPropertyDescriptor(t,a);Object.defineProperty(e,a,p.get?p:{enumerable:!0,get:function(){return t[a]}})}),e}var me=Object.prototype.hasOwnProperty,ae=Array.isArray,V=function(){for(var t=[],r=0;r<256;++r)t.push("%"+((r<16?"0":"")+r.toString(16)).toUpperCase());return t}(),et=function(r){for(;r.length>1;){var e=r.pop(),a=e.obj[e.prop];if(ae(a)){for(var p=[],c=0;c<a.length;++c)typeof a[c]<"u"&&p.push(a[c]);e.obj[e.prop]=p}}},je=function(r,e){for(var a=e&&e.plainObjects?Object.create(null):{},p=0;p<r.length;++p)typeof r[p]<"u"&&(a[p]=r[p]);return a},tt=function t(r,e,a){if(!e)return r;if(typeof e!="object"){if(ae(r))r.push(e);else if(r&&typeof r=="object")(a&&(a.plainObjects||a.allowPrototypes)||!me.call(Object.prototype,e))&&(r[e]=!0);else return[r,e];return r}if(!r||typeof r!="object")return[r].concat(e);var p=r;return ae(r)&&!ae(e)&&(p=je(r,a)),ae(r)&&ae(e)?(e.forEach(function(c,x){if(me.call(r,x)){var o=r[x];o&&typeof o=="object"&&c&&typeof c=="object"?r[x]=t(o,c,a):r.push(c)}else r[x]=c}),r):Object.keys(e).reduce(function(c,x){var o=e[x];return me.call(c,x)?c[x]=t(c[x],o,a):c[x]=o,c},p)},rt=function(r,e){return Object.keys(e).reduce(function(a,p){return a[p]=e[p],a},r)},nt=function(t,r,e){var a=t.replace(/\+/g," ");if(e==="iso-8859-1")return a.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(a)}catch{return a}},ot=function(r,e,a){if(r.length===0)return r;var p=r;if(typeof r=="symbol"?p=Symbol.prototype.toString.call(r):typeof r!="string"&&(p=String(r)),a==="iso-8859-1")return escape(p).replace(/%u[0-9a-f]{4}/gi,function(v){return"%26%23"+parseInt(v.slice(2),16)+"%3B"});for(var c="",x=0;x<p.length;++x){var o=p.charCodeAt(x);if(o===45||o===46||o===95||o===126||o>=48&&o<=57||o>=65&&o<=90||o>=97&&o<=122){c+=p.charAt(x);continue}if(o<128){c=c+V[o];continue}if(o<2048){c=c+(V[192|o>>6]+V[128|o&63]);continue}if(o<55296||o>=57344){c=c+(V[224|o>>12]+V[128|o>>6&63]+V[128|o&63]);continue}x+=1,o=65536+((o&1023)<<10|p.charCodeAt(x)&1023),c+=V[240|o>>18]+V[128|o>>12&63]+V[128|o>>6&63]+V[128|o&63]}return c},at=function(r){for(var e=[{obj:{o:r},prop:"o"}],a=[],p=0;p<e.length;++p)for(var c=e[p],x=c.obj[c.prop],o=Object.keys(x),v=0;v<o.length;++v){var s=o[v],C=x[s];typeof C=="object"&&C!==null&&a.indexOf(C)===-1&&(e.push({obj:x,prop:s}),a.push(C))}return et(e),r},st=function(r){return Object.prototype.toString.call(r)==="[object RegExp]"},it=function(r){return!r||typeof r!="object"?!1:!!(r.constructor&&r.constructor.isBuffer&&r.constructor.isBuffer(r))},ft=function(r,e){return[].concat(r,e)},ct={arrayToObject:je,assign:rt,combine:ft,compact:at,decode:nt,encode:ot,isBuffer:it,isRegExp:st,merge:tt},fe=ct,ye=Object.prototype.hasOwnProperty,ht=Array.isArray,I={allowDots:!1,allowPrototypes:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:fe.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},ut=function(t){return t.replace(/&#(\d+);/g,function(r,e){return String.fromCharCode(parseInt(e,10))})},lt="utf8=%26%2310003%3B",pt="utf8=%E2%9C%93",dt=function(r,e){var a={},p=e.ignoreQueryPrefix?r.replace(/^\?/,""):r,c=e.parameterLimit===1/0?void 0:e.parameterLimit,x=p.split(e.delimiter,c),o=-1,v,s=e.charset;if(e.charsetSentinel)for(v=0;v<x.length;++v)x[v].indexOf("utf8=")===0&&(x[v]===pt?s="utf-8":x[v]===lt&&(s="iso-8859-1"),o=v,v=x.length);for(v=0;v<x.length;++v)if(v!==o){var C=x[v],O=C.indexOf("]="),w=O===-1?C.indexOf("="):O+1,m,b;w===-1?(m=e.decoder(C,I.decoder,s,"key"),b=e.strictNullHandling?null:""):(m=e.decoder(C.slice(0,w),I.decoder,s,"key"),b=e.decoder(C.slice(w+1),I.decoder,s,"value")),b&&e.interpretNumericEntities&&s==="iso-8859-1"&&(b=ut(b)),b&&typeof b=="string"&&e.comma&&b.indexOf(",")>-1&&(b=b.split(",")),C.indexOf("[]=")>-1&&(b=ht(b)?[b]:b),ye.call(a,m)?a[m]=fe.combine(a[m],b):a[m]=b}return a},vt=function(t,r,e){for(var a=r,p=t.length-1;p>=0;--p){var c,x=t[p];if(x==="[]"&&e.parseArrays)c=[].concat(a);else{c=e.plainObjects?Object.create(null):{};var o=x.charAt(0)==="["&&x.charAt(x.length-1)==="]"?x.slice(1,-1):x,v=parseInt(o,10);!e.parseArrays&&o===""?c={0:a}:!isNaN(v)&&x!==o&&String(v)===o&&v>=0&&e.parseArrays&&v<=e.arrayLimit?(c=[],c[v]=a):c[o]=a}a=c}return a},mt=function(r,e,a){if(r){var p=a.allowDots?r.replace(/\.([^.[]+)/g,"[$1]"):r,c=/(\[[^[\]]*])/,x=/(\[[^[\]]*])/g,o=a.depth>0&&c.exec(p),v=o?p.slice(0,o.index):p,s=[];if(v){if(!a.plainObjects&&ye.call(Object.prototype,v)&&!a.allowPrototypes)return;s.push(v)}for(var C=0;a.depth>0&&(o=x.exec(p))!==null&&C<a.depth;){if(C+=1,!a.plainObjects&&ye.call(Object.prototype,o[1].slice(1,-1))&&!a.allowPrototypes)return;s.push(o[1])}return o&&s.push("["+p.slice(o.index)+"]"),vt(s,e,a)}},yt=function(r){if(!r)return I;if(r.decoder!==null&&r.decoder!==void 0&&typeof r.decoder!="function")throw new TypeError("Decoder has to be a function.");if(typeof r.charset<"u"&&r.charset!=="utf-8"&&r.charset!=="iso-8859-1")throw new Error("The charset option must be either utf-8, iso-8859-1, or undefined");var e=typeof r.charset>"u"?I.charset:r.charset;return{allowDots:typeof r.allowDots>"u"?I.allowDots:!!r.allowDots,allowPrototypes:typeof r.allowPrototypes=="boolean"?r.allowPrototypes:I.allowPrototypes,arrayLimit:typeof r.arrayLimit=="number"?r.arrayLimit:I.arrayLimit,charset:e,charsetSentinel:typeof r.charsetSentinel=="boolean"?r.charsetSentinel:I.charsetSentinel,comma:typeof r.comma=="boolean"?r.comma:I.comma,decoder:typeof r.decoder=="function"?r.decoder:I.decoder,delimiter:typeof r.delimiter=="string"||fe.isRegExp(r.delimiter)?r.delimiter:I.delimiter,depth:typeof r.depth=="number"||r.depth===!1?+r.depth:I.depth,ignoreQueryPrefix:r.ignoreQueryPrefix===!0,interpretNumericEntities:typeof r.interpretNumericEntities=="boolean"?r.interpretNumericEntities:I.interpretNumericEntities,parameterLimit:typeof r.parameterLimit=="number"?r.parameterLimit:I.parameterLimit,parseArrays:r.parseArrays!==!1,plainObjects:typeof r.plainObjects=="boolean"?r.plainObjects:I.plainObjects,strictNullHandling:typeof r.strictNullHandling=="boolean"?r.strictNullHandling:I.strictNullHandling}},gt=function(t,r){var e=yt(r);if(t===""||t===null||typeof t>"u")return e.plainObjects?Object.create(null):{};for(var a=typeof t=="string"?dt(t,e):t,p=e.plainObjects?Object.create(null):{},c=Object.keys(a),x=0;x<c.length;++x){var o=c[x],v=mt(o,a[o],e);p=fe.merge(p,v,e)}return fe.compact(p)};const xt=he(gt);var ue={exports:{}};/*! https://mths.be/punycode v1.4.1 by @mathias */ue.exports,function(t,r){(function(e){var a=r&&!r.nodeType&&r,p=t&&!t.nodeType&&t,c=typeof W=="object"&&W;(c.global===c||c.window===c||c.self===c)&&(e=c);var x,o=2147483647,v=36,s=1,C=26,O=38,w=700,m=72,b=128,d="-",y=/^xn--/,j=/[^\x20-\x7E]/,n=/[\x2E\u3002\uFF0E\uFF61]/g,l={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},g=v-s,_=Math.floor,B=String.fromCharCode,P;function S(A){throw new RangeError(l[A])}function T(A,i){for(var f=A.length,h=[];f--;)h[f]=i(A[f]);return h}function E(A,i){var f=A.split("@"),h="";f.length>1&&(h=f[0]+"@",A=f[1]),A=A.replace(n,".");var u=A.split("."),L=T(u,i).join(".");return h+L}function F(A){for(var i=[],f=0,h=A.length,u,L;f<h;)u=A.charCodeAt(f++),u>=55296&&u<=56319&&f<h?(L=A.charCodeAt(f++),(L&64512)==56320?i.push(((u&1023)<<10)+(L&1023)+65536):(i.push(u),f--)):i.push(u);return i}function D(A){return T(A,function(i){var f="";return i>65535&&(i-=65536,f+=B(i>>>10&1023|55296),i=56320|i&1023),f+=B(i),f}).join("")}function R(A){return A-48<10?A-22:A-65<26?A-65:A-97<26?A-97:v}function z(A,i){return A+22+75*(A<26)-((i!=0)<<5)}function N(A,i,f){var h=0;for(A=f?_(A/w):A>>1,A+=_(A/i);A>g*C>>1;h+=v)A=_(A/g);return _(h+(g+1)*A/(A+O))}function M(A){var i=[],f=A.length,h,u=0,L=b,q=m,U,Q,Z,J,$,K,X,te,re;for(U=A.lastIndexOf(d),U<0&&(U=0),Q=0;Q<U;++Q)A.charCodeAt(Q)>=128&&S("not-basic"),i.push(A.charCodeAt(Q));for(Z=U>0?U+1:0;Z<f;){for(J=u,$=1,K=v;Z>=f&&S("invalid-input"),X=R(A.charCodeAt(Z++)),(X>=v||X>_((o-u)/$))&&S("overflow"),u+=X*$,te=K<=q?s:K>=q+C?C:K-q,!(X<te);K+=v)re=v-te,$>_(o/re)&&S("overflow"),$*=re;h=i.length+1,q=N(u-J,h,J==0),_(u/h)>o-L&&S("overflow"),L+=_(u/h),u%=h,i.splice(u++,0,L)}return D(i)}function k(A){var i,f,h,u,L,q,U,Q,Z,J,$,K=[],X,te,re,Oe;for(A=F(A),X=A.length,i=b,f=0,L=m,q=0;q<X;++q)$=A[q],$<128&&K.push(B($));for(h=u=K.length,u&&K.push(d);h<X;){for(U=o,q=0;q<X;++q)$=A[q],$>=i&&$<U&&(U=$);for(te=h+1,U-i>_((o-f)/te)&&S("overflow"),f+=(U-i)*te,i=U,q=0;q<X;++q)if($=A[q],$<i&&++f>o&&S("overflow"),$==i){for(Q=f,Z=v;J=Z<=L?s:Z>=L+C?C:Z-L,!(Q<J);Z+=v)Oe=Q-J,re=v-J,K.push(B(z(J+Oe%re,0))),Q=_(Oe/re);K.push(B(z(Q,0))),L=N(f,te,h==u),f=0,++h}++f,++i}return K.join("")}function ee(A){return E(A,function(i){return y.test(i)?M(i.slice(4).toLowerCase()):i})}function ie(A){return E(A,function(i){return j.test(i)?"xn--"+k(i):i})}if(x={version:"1.4.1",ucs2:{decode:F,encode:D},decode:M,encode:k,toASCII:ie,toUnicode:ee},a&&p)if(t.exports==a)p.exports=x;else for(P in x)x.hasOwnProperty(P)&&(a[P]=x[P]);else e.punycode=x})(W)}(ue,ue.exports);var wt=ue.exports,bt=wt;function Y(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}var _t=/^([a-z0-9.+-]+:)/i,Ct=/:[0-9]*$/,Ot=/^(\/\/?(?!\/)[^?\s]*)(\?[^\s]*)?$/,Bt=["<",">",'"',"`"," ","\r",`
1
+ (function(G,H){typeof exports=="object"&&typeof module<"u"?H(exports,require("lodash-es"),require("dingtalk-jsapi"),require("qs"),require("axios")):typeof define=="function"&&define.amd?define(["exports","lodash-es","dingtalk-jsapi","qs","axios"],H):(G=typeof globalThis<"u"?globalThis:G||self,H(G.Main={},G._,G.dd$1,G.qs,G.axios))})(this,function(G,H,ze,ne,Be){"use strict";function Ne(t){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const e in t)if(e!=="default"){const a=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(r,e,a.get?a:{enumerable:!0,get:()=>t[e]})}}return r.default=t,Object.freeze(r)}const oe=Ne(ze),le=window.navigator.userAgent.toLowerCase();let pe={code:"",name:"未知"};function Ue(){return typeof window<"u"&&typeof document<"u"&&typeof document.querySelector=="function"&&typeof navigator<"u"&&typeof XMLHttpRequest=="function"}const We=[{code:"weixin",name:"微信",value:/MicroMessenger/i.test(le)},{code:"wxmp",name:"微信小程序",value:/miniProgram/i.test(le)||window.__wxjs_environment==="miniprogram"},{code:"dd",name:"钉钉",value:/DingTalk/i.test(le)}],ke=t=>t.value,Ae=H.find(We,ke);Ae?pe=Ae:Ue()&&(pe={code:"h5",name:"H5"});const de=pe,Ke=t=>t=="dev"?"https://test.ihotel.cn/gw/v1/platform-gcding":t=="prod"?"https://smart.ihotel.cn/guardian/gw/v1/platform-gcding":t||"https://test.ihotel.cn/gw/v1/platform-gcding",Ge=ne.parse(location.search,{ignoreQueryPrefix:!0}),ve=H.get(Ge,"corpId"),Qe={dd:{login:async({appCode:t,apiPrefix:r})=>{const e=Ke(r);return new Promise(async a=>{var p,c,x;if(ve){const{code:o}=await oe.getAuthCode({corpId:ve}),v=await Be.post(`${e}/api/auth/queryAuthNoExternalCompatible`,{appCode:t,authCode:o,corpId:ve});v.data&&((p=v.data)==null?void 0:p.result)===0?a({userInfo:(c=v==null?void 0:v.data)==null?void 0:c.retVal,res:v}):(oe.showToast({type:"fail",duration:2e3,content:(x=v==null?void 0:v.data)==null?void 0:x.msg,complete:()=>{}}),a({res:v}))}else oe.showToast({type:"fail",duration:2e3,content:"未配置参数:corpId",complete:()=>{}})})},dd:oe},h5:{login:()=>new Promise(async t=>{const{token:r}=ne.parse(location.search,{ignoreQueryPrefix:!0});t(r?{userInfo:{ucToken:r}}:{userInfo:null})})},wxmp:{login:()=>new Promise(t=>{const{token:r}=ne.parse(location.search,{ignoreQueryPrefix:!0});t(r?{userInfo:{ucToken:r}}:{userInfo:null})})},weixin:{login:()=>new Promise(t=>{const{token:r}=ne.parse(location.search,{ignoreQueryPrefix:!0});t(r?{userInfo:{ucToken:r}}:{userInfo:null})})}},Xe={setNavigationBarTitle:t=>{de.code==="dd"?(console.log("钉钉对象",oe),oe.setNavigationTitle(t)):de.code==="weixin"?wx.setNavigationBarTitle(t):document.title=t.title}},Ve=t=>{let r="";return H.mapKeys(t,(e,a)=>{a&&(H.isEmpty(e)?r+="&"+a:r+="&"+a+"="+e)}),r},Ze=(t,r)=>H.isEmpty(r)?t:(H.includes(t,"?")?t:t+"?")+r.substring(1),Ye=(t,r)=>H.isEmpty(r)?t:`${t}?${ne.stringify(r)}`;var W=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function he(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function Je(t){if(t.__esModule)return t;var r=t.default;if(typeof r=="function"){var e=function a(){return this instanceof a?Reflect.construct(r,arguments,this.constructor):r.apply(this,arguments)};e.prototype=r.prototype}else e={};return Object.defineProperty(e,"__esModule",{value:!0}),Object.keys(t).forEach(function(a){var p=Object.getOwnPropertyDescriptor(t,a);Object.defineProperty(e,a,p.get?p:{enumerable:!0,get:function(){return t[a]}})}),e}var me=Object.prototype.hasOwnProperty,ae=Array.isArray,V=function(){for(var t=[],r=0;r<256;++r)t.push("%"+((r<16?"0":"")+r.toString(16)).toUpperCase());return t}(),et=function(r){for(;r.length>1;){var e=r.pop(),a=e.obj[e.prop];if(ae(a)){for(var p=[],c=0;c<a.length;++c)typeof a[c]<"u"&&p.push(a[c]);e.obj[e.prop]=p}}},je=function(r,e){for(var a=e&&e.plainObjects?Object.create(null):{},p=0;p<r.length;++p)typeof r[p]<"u"&&(a[p]=r[p]);return a},tt=function t(r,e,a){if(!e)return r;if(typeof e!="object"){if(ae(r))r.push(e);else if(r&&typeof r=="object")(a&&(a.plainObjects||a.allowPrototypes)||!me.call(Object.prototype,e))&&(r[e]=!0);else return[r,e];return r}if(!r||typeof r!="object")return[r].concat(e);var p=r;return ae(r)&&!ae(e)&&(p=je(r,a)),ae(r)&&ae(e)?(e.forEach(function(c,x){if(me.call(r,x)){var o=r[x];o&&typeof o=="object"&&c&&typeof c=="object"?r[x]=t(o,c,a):r.push(c)}else r[x]=c}),r):Object.keys(e).reduce(function(c,x){var o=e[x];return me.call(c,x)?c[x]=t(c[x],o,a):c[x]=o,c},p)},rt=function(r,e){return Object.keys(e).reduce(function(a,p){return a[p]=e[p],a},r)},nt=function(t,r,e){var a=t.replace(/\+/g," ");if(e==="iso-8859-1")return a.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(a)}catch{return a}},ot=function(r,e,a){if(r.length===0)return r;var p=r;if(typeof r=="symbol"?p=Symbol.prototype.toString.call(r):typeof r!="string"&&(p=String(r)),a==="iso-8859-1")return escape(p).replace(/%u[0-9a-f]{4}/gi,function(v){return"%26%23"+parseInt(v.slice(2),16)+"%3B"});for(var c="",x=0;x<p.length;++x){var o=p.charCodeAt(x);if(o===45||o===46||o===95||o===126||o>=48&&o<=57||o>=65&&o<=90||o>=97&&o<=122){c+=p.charAt(x);continue}if(o<128){c=c+V[o];continue}if(o<2048){c=c+(V[192|o>>6]+V[128|o&63]);continue}if(o<55296||o>=57344){c=c+(V[224|o>>12]+V[128|o>>6&63]+V[128|o&63]);continue}x+=1,o=65536+((o&1023)<<10|p.charCodeAt(x)&1023),c+=V[240|o>>18]+V[128|o>>12&63]+V[128|o>>6&63]+V[128|o&63]}return c},at=function(r){for(var e=[{obj:{o:r},prop:"o"}],a=[],p=0;p<e.length;++p)for(var c=e[p],x=c.obj[c.prop],o=Object.keys(x),v=0;v<o.length;++v){var s=o[v],C=x[s];typeof C=="object"&&C!==null&&a.indexOf(C)===-1&&(e.push({obj:x,prop:s}),a.push(C))}return et(e),r},st=function(r){return Object.prototype.toString.call(r)==="[object RegExp]"},it=function(r){return!r||typeof r!="object"?!1:!!(r.constructor&&r.constructor.isBuffer&&r.constructor.isBuffer(r))},ft=function(r,e){return[].concat(r,e)},ct={arrayToObject:je,assign:rt,combine:ft,compact:at,decode:nt,encode:ot,isBuffer:it,isRegExp:st,merge:tt},fe=ct,ye=Object.prototype.hasOwnProperty,ht=Array.isArray,I={allowDots:!1,allowPrototypes:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:fe.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},ut=function(t){return t.replace(/&#(\d+);/g,function(r,e){return String.fromCharCode(parseInt(e,10))})},lt="utf8=%26%2310003%3B",pt="utf8=%E2%9C%93",dt=function(r,e){var a={},p=e.ignoreQueryPrefix?r.replace(/^\?/,""):r,c=e.parameterLimit===1/0?void 0:e.parameterLimit,x=p.split(e.delimiter,c),o=-1,v,s=e.charset;if(e.charsetSentinel)for(v=0;v<x.length;++v)x[v].indexOf("utf8=")===0&&(x[v]===pt?s="utf-8":x[v]===lt&&(s="iso-8859-1"),o=v,v=x.length);for(v=0;v<x.length;++v)if(v!==o){var C=x[v],O=C.indexOf("]="),w=O===-1?C.indexOf("="):O+1,m,b;w===-1?(m=e.decoder(C,I.decoder,s,"key"),b=e.strictNullHandling?null:""):(m=e.decoder(C.slice(0,w),I.decoder,s,"key"),b=e.decoder(C.slice(w+1),I.decoder,s,"value")),b&&e.interpretNumericEntities&&s==="iso-8859-1"&&(b=ut(b)),b&&typeof b=="string"&&e.comma&&b.indexOf(",")>-1&&(b=b.split(",")),C.indexOf("[]=")>-1&&(b=ht(b)?[b]:b),ye.call(a,m)?a[m]=fe.combine(a[m],b):a[m]=b}return a},vt=function(t,r,e){for(var a=r,p=t.length-1;p>=0;--p){var c,x=t[p];if(x==="[]"&&e.parseArrays)c=[].concat(a);else{c=e.plainObjects?Object.create(null):{};var o=x.charAt(0)==="["&&x.charAt(x.length-1)==="]"?x.slice(1,-1):x,v=parseInt(o,10);!e.parseArrays&&o===""?c={0:a}:!isNaN(v)&&x!==o&&String(v)===o&&v>=0&&e.parseArrays&&v<=e.arrayLimit?(c=[],c[v]=a):c[o]=a}a=c}return a},mt=function(r,e,a){if(r){var p=a.allowDots?r.replace(/\.([^.[]+)/g,"[$1]"):r,c=/(\[[^[\]]*])/,x=/(\[[^[\]]*])/g,o=a.depth>0&&c.exec(p),v=o?p.slice(0,o.index):p,s=[];if(v){if(!a.plainObjects&&ye.call(Object.prototype,v)&&!a.allowPrototypes)return;s.push(v)}for(var C=0;a.depth>0&&(o=x.exec(p))!==null&&C<a.depth;){if(C+=1,!a.plainObjects&&ye.call(Object.prototype,o[1].slice(1,-1))&&!a.allowPrototypes)return;s.push(o[1])}return o&&s.push("["+p.slice(o.index)+"]"),vt(s,e,a)}},yt=function(r){if(!r)return I;if(r.decoder!==null&&r.decoder!==void 0&&typeof r.decoder!="function")throw new TypeError("Decoder has to be a function.");if(typeof r.charset<"u"&&r.charset!=="utf-8"&&r.charset!=="iso-8859-1")throw new Error("The charset option must be either utf-8, iso-8859-1, or undefined");var e=typeof r.charset>"u"?I.charset:r.charset;return{allowDots:typeof r.allowDots>"u"?I.allowDots:!!r.allowDots,allowPrototypes:typeof r.allowPrototypes=="boolean"?r.allowPrototypes:I.allowPrototypes,arrayLimit:typeof r.arrayLimit=="number"?r.arrayLimit:I.arrayLimit,charset:e,charsetSentinel:typeof r.charsetSentinel=="boolean"?r.charsetSentinel:I.charsetSentinel,comma:typeof r.comma=="boolean"?r.comma:I.comma,decoder:typeof r.decoder=="function"?r.decoder:I.decoder,delimiter:typeof r.delimiter=="string"||fe.isRegExp(r.delimiter)?r.delimiter:I.delimiter,depth:typeof r.depth=="number"||r.depth===!1?+r.depth:I.depth,ignoreQueryPrefix:r.ignoreQueryPrefix===!0,interpretNumericEntities:typeof r.interpretNumericEntities=="boolean"?r.interpretNumericEntities:I.interpretNumericEntities,parameterLimit:typeof r.parameterLimit=="number"?r.parameterLimit:I.parameterLimit,parseArrays:r.parseArrays!==!1,plainObjects:typeof r.plainObjects=="boolean"?r.plainObjects:I.plainObjects,strictNullHandling:typeof r.strictNullHandling=="boolean"?r.strictNullHandling:I.strictNullHandling}},gt=function(t,r){var e=yt(r);if(t===""||t===null||typeof t>"u")return e.plainObjects?Object.create(null):{};for(var a=typeof t=="string"?dt(t,e):t,p=e.plainObjects?Object.create(null):{},c=Object.keys(a),x=0;x<c.length;++x){var o=c[x],v=mt(o,a[o],e);p=fe.merge(p,v,e)}return fe.compact(p)};const xt=he(gt);var ue={exports:{}};/*! https://mths.be/punycode v1.4.1 by @mathias */ue.exports,function(t,r){(function(e){var a=r&&!r.nodeType&&r,p=t&&!t.nodeType&&t,c=typeof W=="object"&&W;(c.global===c||c.window===c||c.self===c)&&(e=c);var x,o=2147483647,v=36,s=1,C=26,O=38,w=700,m=72,b=128,d="-",y=/^xn--/,j=/[^\x20-\x7E]/,n=/[\x2E\u3002\uFF0E\uFF61]/g,l={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},g=v-s,_=Math.floor,B=String.fromCharCode,P;function S(A){throw new RangeError(l[A])}function T(A,i){for(var f=A.length,h=[];f--;)h[f]=i(A[f]);return h}function E(A,i){var f=A.split("@"),h="";f.length>1&&(h=f[0]+"@",A=f[1]),A=A.replace(n,".");var u=A.split("."),L=T(u,i).join(".");return h+L}function F(A){for(var i=[],f=0,h=A.length,u,L;f<h;)u=A.charCodeAt(f++),u>=55296&&u<=56319&&f<h?(L=A.charCodeAt(f++),(L&64512)==56320?i.push(((u&1023)<<10)+(L&1023)+65536):(i.push(u),f--)):i.push(u);return i}function D(A){return T(A,function(i){var f="";return i>65535&&(i-=65536,f+=B(i>>>10&1023|55296),i=56320|i&1023),f+=B(i),f}).join("")}function R(A){return A-48<10?A-22:A-65<26?A-65:A-97<26?A-97:v}function z(A,i){return A+22+75*(A<26)-((i!=0)<<5)}function N(A,i,f){var h=0;for(A=f?_(A/w):A>>1,A+=_(A/i);A>g*C>>1;h+=v)A=_(A/g);return _(h+(g+1)*A/(A+O))}function M(A){var i=[],f=A.length,h,u=0,L=b,q=m,U,Q,Z,J,$,K,X,te,re;for(U=A.lastIndexOf(d),U<0&&(U=0),Q=0;Q<U;++Q)A.charCodeAt(Q)>=128&&S("not-basic"),i.push(A.charCodeAt(Q));for(Z=U>0?U+1:0;Z<f;){for(J=u,$=1,K=v;Z>=f&&S("invalid-input"),X=R(A.charCodeAt(Z++)),(X>=v||X>_((o-u)/$))&&S("overflow"),u+=X*$,te=K<=q?s:K>=q+C?C:K-q,!(X<te);K+=v)re=v-te,$>_(o/re)&&S("overflow"),$*=re;h=i.length+1,q=N(u-J,h,J==0),_(u/h)>o-L&&S("overflow"),L+=_(u/h),u%=h,i.splice(u++,0,L)}return D(i)}function k(A){var i,f,h,u,L,q,U,Q,Z,J,$,K=[],X,te,re,Oe;for(A=F(A),X=A.length,i=b,f=0,L=m,q=0;q<X;++q)$=A[q],$<128&&K.push(B($));for(h=u=K.length,u&&K.push(d);h<X;){for(U=o,q=0;q<X;++q)$=A[q],$>=i&&$<U&&(U=$);for(te=h+1,U-i>_((o-f)/te)&&S("overflow"),f+=(U-i)*te,i=U,q=0;q<X;++q)if($=A[q],$<i&&++f>o&&S("overflow"),$==i){for(Q=f,Z=v;J=Z<=L?s:Z>=L+C?C:Z-L,!(Q<J);Z+=v)Oe=Q-J,re=v-J,K.push(B(z(J+Oe%re,0))),Q=_(Oe/re);K.push(B(z(Q,0))),L=N(f,te,h==u),f=0,++h}++f,++i}return K.join("")}function ee(A){return E(A,function(i){return y.test(i)?M(i.slice(4).toLowerCase()):i})}function ie(A){return E(A,function(i){return j.test(i)?"xn--"+k(i):i})}if(x={version:"1.4.1",ucs2:{decode:F,encode:D},decode:M,encode:k,toASCII:ie,toUnicode:ee},a&&p)if(t.exports==a)p.exports=x;else for(P in x)x.hasOwnProperty(P)&&(a[P]=x[P]);else e.punycode=x})(W)}(ue,ue.exports);var wt=ue.exports,bt=wt;function Y(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}var _t=/^([a-z0-9.+-]+:)/i,Ct=/:[0-9]*$/,Ot=/^(\/\/?(?!\/)[^?\s]*)(\?[^\s]*)?$/,Bt=["<",">",'"',"`"," ","\r",`
2
2
  `," "],At=["{","}","|","\\","^","`"].concat(Bt),ge=["'"].concat(At),Se=["%","/","?",";","#"].concat(ge),Pe=["/","?","#"],jt=255,Te=/^[+a-z0-9A-Z_-]{0,63}$/,St=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,Pt={javascript:!0,"javascript:":!0},xe={javascript:!0,"javascript:":!0},se={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},we=ne;function He(t,r,e){if(t&&typeof t=="object"&&t instanceof Y)return t;var a=new Y;return a.parse(t,r,e),a}Y.prototype.parse=function(t,r,e){if(typeof t!="string")throw new TypeError("Parameter 'url' must be a string, not "+typeof t);var a=t.indexOf("?"),p=a!==-1&&a<t.indexOf("#")?"?":"#",c=t.split(p),x=/\\/g;c[0]=c[0].replace(x,"/"),t=c.join(p);var o=t;if(o=o.trim(),!e&&t.split("#").length===1){var v=Ot.exec(o);if(v)return this.path=o,this.href=o,this.pathname=v[1],v[2]?(this.search=v[2],r?this.query=we.parse(this.search.substr(1)):this.query=this.search.substr(1)):r&&(this.search="",this.query={}),this}var s=_t.exec(o);if(s){s=s[0];var C=s.toLowerCase();this.protocol=C,o=o.substr(s.length)}if(e||s||o.match(/^\/\/[^@/]+@[^@/]+/)){var O=o.substr(0,2)==="//";O&&!(s&&xe[s])&&(o=o.substr(2),this.slashes=!0)}if(!xe[s]&&(O||s&&!se[s])){for(var w=-1,m=0;m<Pe.length;m++){var b=o.indexOf(Pe[m]);b!==-1&&(w===-1||b<w)&&(w=b)}var d,y;w===-1?y=o.lastIndexOf("@"):y=o.lastIndexOf("@",w),y!==-1&&(d=o.slice(0,y),o=o.slice(y+1),this.auth=decodeURIComponent(d)),w=-1;for(var m=0;m<Se.length;m++){var b=o.indexOf(Se[m]);b!==-1&&(w===-1||b<w)&&(w=b)}w===-1&&(w=o.length),this.host=o.slice(0,w),o=o.slice(w),this.parseHost(),this.hostname=this.hostname||"";var j=this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!j)for(var n=this.hostname.split(/\./),m=0,l=n.length;m<l;m++){var g=n[m];if(g&&!g.match(Te)){for(var _="",B=0,P=g.length;B<P;B++)g.charCodeAt(B)>127?_+="x":_+=g[B];if(!_.match(Te)){var S=n.slice(0,m),T=n.slice(m+1),E=g.match(St);E&&(S.push(E[1]),T.unshift(E[2])),T.length&&(o="/"+T.join(".")+o),this.hostname=S.join(".");break}}}this.hostname.length>jt?this.hostname="":this.hostname=this.hostname.toLowerCase(),j||(this.hostname=bt.toASCII(this.hostname));var F=this.port?":"+this.port:"",D=this.hostname||"";this.host=D+F,this.href+=this.host,j&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),o[0]!=="/"&&(o="/"+o))}if(!Pt[C])for(var m=0,l=ge.length;m<l;m++){var R=ge[m];if(o.indexOf(R)!==-1){var z=encodeURIComponent(R);z===R&&(z=escape(R)),o=o.split(R).join(z)}}var N=o.indexOf("#");N!==-1&&(this.hash=o.substr(N),o=o.slice(0,N));var M=o.indexOf("?");if(M!==-1?(this.search=o.substr(M),this.query=o.substr(M+1),r&&(this.query=we.parse(this.query)),o=o.slice(0,M)):r&&(this.search="",this.query={}),o&&(this.pathname=o),se[C]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){var F=this.pathname||"",k=this.search||"";this.path=F+k}return this.href=this.format(),this},Y.prototype.format=function(){var t=this.auth||"";t&&(t=encodeURIComponent(t),t=t.replace(/%3A/i,":"),t+="@");var r=this.protocol||"",e=this.pathname||"",a=this.hash||"",p=!1,c="";this.host?p=t+this.host:this.hostname&&(p=t+(this.hostname.indexOf(":")===-1?this.hostname:"["+this.hostname+"]"),this.port&&(p+=":"+this.port)),this.query&&typeof this.query=="object"&&Object.keys(this.query).length&&(c=we.stringify(this.query,{arrayFormat:"repeat",addQueryPrefix:!1}));var x=this.search||c&&"?"+c||"";return r&&r.substr(-1)!==":"&&(r+=":"),this.slashes||(!r||se[r])&&p!==!1?(p="//"+(p||""),e&&e.charAt(0)!=="/"&&(e="/"+e)):p||(p=""),a&&a.charAt(0)!=="#"&&(a="#"+a),x&&x.charAt(0)!=="?"&&(x="?"+x),e=e.replace(/[?#]/g,function(o){return encodeURIComponent(o)}),x=x.replace("#","%23"),r+p+e+x+a},Y.prototype.resolve=function(t){return this.resolveObject(He(t,!1,!0)).format()},Y.prototype.resolveObject=function(t){if(typeof t=="string"){var r=new Y;r.parse(t,!1,!0),t=r}for(var e=new Y,a=Object.keys(this),p=0;p<a.length;p++){var c=a[p];e[c]=this[c]}if(e.hash=t.hash,t.href==="")return e.href=e.format(),e;if(t.slashes&&!t.protocol){for(var x=Object.keys(t),o=0;o<x.length;o++){var v=x[o];v!=="protocol"&&(e[v]=t[v])}return se[e.protocol]&&e.hostname&&!e.pathname&&(e.pathname="/",e.path=e.pathname),e.href=e.format(),e}if(t.protocol&&t.protocol!==e.protocol){if(!se[t.protocol]){for(var s=Object.keys(t),C=0;C<s.length;C++){var O=s[C];e[O]=t[O]}return e.href=e.format(),e}if(e.protocol=t.protocol,!t.host&&!xe[t.protocol]){for(var l=(t.pathname||"").split("/");l.length&&!(t.host=l.shift()););t.host||(t.host=""),t.hostname||(t.hostname=""),l[0]!==""&&l.unshift(""),l.length<2&&l.unshift(""),e.pathname=l.join("/")}else e.pathname=t.pathname;if(e.search=t.search,e.query=t.query,e.host=t.host||"",e.auth=t.auth,e.hostname=t.hostname||t.host,e.port=t.port,e.pathname||e.search){var w=e.pathname||"",m=e.search||"";e.path=w+m}return e.slashes=e.slashes||t.slashes,e.href=e.format(),e}var b=e.pathname&&e.pathname.charAt(0)==="/",d=t.host||t.pathname&&t.pathname.charAt(0)==="/",y=d||b||e.host&&t.pathname,j=y,n=e.pathname&&e.pathname.split("/")||[],l=t.pathname&&t.pathname.split("/")||[],g=e.protocol&&!se[e.protocol];if(g&&(e.hostname="",e.port=null,e.host&&(n[0]===""?n[0]=e.host:n.unshift(e.host)),e.host="",t.protocol&&(t.hostname=null,t.port=null,t.host&&(l[0]===""?l[0]=t.host:l.unshift(t.host)),t.host=null),y=y&&(l[0]===""||n[0]==="")),d)e.host=t.host||t.host===""?t.host:e.host,e.hostname=t.hostname||t.hostname===""?t.hostname:e.hostname,e.search=t.search,e.query=t.query,n=l;else if(l.length)n||(n=[]),n.pop(),n=n.concat(l),e.search=t.search,e.query=t.query;else if(t.search!=null){if(g){e.host=n.shift(),e.hostname=e.host;var _=e.host&&e.host.indexOf("@")>0?e.host.split("@"):!1;_&&(e.auth=_.shift(),e.hostname=_.shift(),e.host=e.hostname)}return e.search=t.search,e.query=t.query,(e.pathname!==null||e.search!==null)&&(e.path=(e.pathname?e.pathname:"")+(e.search?e.search:"")),e.href=e.format(),e}if(!n.length)return e.pathname=null,e.search?e.path="/"+e.search:e.path=null,e.href=e.format(),e;for(var B=n.slice(-1)[0],P=(e.host||t.host||n.length>1)&&(B==="."||B==="..")||B==="",S=0,T=n.length;T>=0;T--)B=n[T],B==="."?n.splice(T,1):B===".."?(n.splice(T,1),S++):S&&(n.splice(T,1),S--);if(!y&&!j)for(;S--;S)n.unshift("..");y&&n[0]!==""&&(!n[0]||n[0].charAt(0)!=="/")&&n.unshift(""),P&&n.join("/").substr(-1)!=="/"&&n.push("");var E=n[0]===""||n[0]&&n[0].charAt(0)==="/";if(g){e.hostname=E?"":n.length?n.shift():"",e.host=e.hostname;var _=e.host&&e.host.indexOf("@")>0?e.host.split("@"):!1;_&&(e.auth=_.shift(),e.hostname=_.shift(),e.host=e.hostname)}return y=y||e.host&&n.length,y&&!E&&n.unshift(""),n.length>0?e.pathname=n.join("/"):(e.pathname=null,e.path=null),(e.pathname!==null||e.search!==null)&&(e.path=(e.pathname?e.pathname:"")+(e.search?e.search:"")),e.auth=t.auth||e.auth,e.slashes=e.slashes||t.slashes,e.href=e.format(),e},Y.prototype.parseHost=function(){var t=this.host,r=Ct.exec(t);r&&(r=r[0],r!==":"&&(this.port=r.substr(1)),t=t.substr(0,t.length-r.length)),t&&(this.hostname=t)};var Tt=He,Ee={exports:{}};function Ht(t){throw new Error('Could not dynamically require "'+t+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var be={exports:{}};const Et=Je(Object.freeze(Object.defineProperty({__proto__:null,default:{}},Symbol.toStringTag,{value:"Module"})));var Fe;function ce(){return Fe||(Fe=1,function(t,r){(function(e,a){t.exports=a()})(W,function(){var e=e||function(a,p){var c;if(typeof window<"u"&&window.crypto&&(c=window.crypto),typeof self<"u"&&self.crypto&&(c=self.crypto),typeof globalThis<"u"&&globalThis.crypto&&(c=globalThis.crypto),!c&&typeof window<"u"&&window.msCrypto&&(c=window.msCrypto),!c&&typeof W<"u"&&W.crypto&&(c=W.crypto),!c&&typeof Ht=="function")try{c=Et}catch{}var x=function(){if(c){if(typeof c.getRandomValues=="function")try{return c.getRandomValues(new Uint32Array(1))[0]}catch{}if(typeof c.randomBytes=="function")try{return c.randomBytes(4).readInt32LE()}catch{}}throw new Error("Native crypto module could not be used to get secure random number.")},o=Object.create||function(){function n(){}return function(l){var g;return n.prototype=l,g=new n,n.prototype=null,g}}(),v={},s=v.lib={},C=s.Base=function(){return{extend:function(n){var l=o(this);return n&&l.mixIn(n),(!l.hasOwnProperty("init")||this.init===l.init)&&(l.init=function(){l.$super.init.apply(this,arguments)}),l.init.prototype=l,l.$super=this,l},create:function(){var n=this.extend();return n.init.apply(n,arguments),n},init:function(){},mixIn:function(n){for(var l in n)n.hasOwnProperty(l)&&(this[l]=n[l]);n.hasOwnProperty("toString")&&(this.toString=n.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),O=s.WordArray=C.extend({init:function(n,l){n=this.words=n||[],l!=p?this.sigBytes=l:this.sigBytes=n.length*4},toString:function(n){return(n||m).stringify(this)},concat:function(n){var l=this.words,g=n.words,_=this.sigBytes,B=n.sigBytes;if(this.clamp(),_%4)for(var P=0;P<B;P++){var S=g[P>>>2]>>>24-P%4*8&255;l[_+P>>>2]|=S<<24-(_+P)%4*8}else for(var T=0;T<B;T+=4)l[_+T>>>2]=g[T>>>2];return this.sigBytes+=B,this},clamp:function(){var n=this.words,l=this.sigBytes;n[l>>>2]&=4294967295<<32-l%4*8,n.length=a.ceil(l/4)},clone:function(){var n=C.clone.call(this);return n.words=this.words.slice(0),n},random:function(n){for(var l=[],g=0;g<n;g+=4)l.push(x());return new O.init(l,n)}}),w=v.enc={},m=w.Hex={stringify:function(n){for(var l=n.words,g=n.sigBytes,_=[],B=0;B<g;B++){var P=l[B>>>2]>>>24-B%4*8&255;_.push((P>>>4).toString(16)),_.push((P&15).toString(16))}return _.join("")},parse:function(n){for(var l=n.length,g=[],_=0;_<l;_+=2)g[_>>>3]|=parseInt(n.substr(_,2),16)<<24-_%8*4;return new O.init(g,l/2)}},b=w.Latin1={stringify:function(n){for(var l=n.words,g=n.sigBytes,_=[],B=0;B<g;B++){var P=l[B>>>2]>>>24-B%4*8&255;_.push(String.fromCharCode(P))}return _.join("")},parse:function(n){for(var l=n.length,g=[],_=0;_<l;_++)g[_>>>2]|=(n.charCodeAt(_)&255)<<24-_%4*8;return new O.init(g,l)}},d=w.Utf8={stringify:function(n){try{return decodeURIComponent(escape(b.stringify(n)))}catch{throw new Error("Malformed UTF-8 data")}},parse:function(n){return b.parse(unescape(encodeURIComponent(n)))}},y=s.BufferedBlockAlgorithm=C.extend({reset:function(){this._data=new O.init,this._nDataBytes=0},_append:function(n){typeof n=="string"&&(n=d.parse(n)),this._data.concat(n),this._nDataBytes+=n.sigBytes},_process:function(n){var l,g=this._data,_=g.words,B=g.sigBytes,P=this.blockSize,S=P*4,T=B/S;n?T=a.ceil(T):T=a.max((T|0)-this._minBufferSize,0);var E=T*P,F=a.min(E*4,B);if(E){for(var D=0;D<E;D+=P)this._doProcessBlock(_,D);l=_.splice(0,E),g.sigBytes-=F}return new O.init(l,F)},clone:function(){var n=C.clone.call(this);return n._data=this._data.clone(),n},_minBufferSize:0});s.Hasher=y.extend({cfg:C.extend(),init:function(n){this.cfg=this.cfg.extend(n),this.reset()},reset:function(){y.reset.call(this),this._doReset()},update:function(n){return this._append(n),this._process(),this},finalize:function(n){n&&this._append(n);var l=this._doFinalize();return l},blockSize:16,_createHelper:function(n){return function(l,g){return new n.init(g).finalize(l)}},_createHmacHelper:function(n){return function(l,g){return new j.HMAC.init(n,g).finalize(l)}}});var j=v.algo={};return v}(Math);return e})}(be)),be.exports}var _e={exports:{}},Ie;function Ft(){return Ie||(Ie=1,function(t,r){(function(e,a){t.exports=a(ce())})(W,function(e){return function(a){var p=e,c=p.lib,x=c.WordArray,o=c.Hasher,v=p.algo,s=[],C=[];(function(){function m(j){for(var n=a.sqrt(j),l=2;l<=n;l++)if(!(j%l))return!1;return!0}function b(j){return(j-(j|0))*4294967296|0}for(var d=2,y=0;y<64;)m(d)&&(y<8&&(s[y]=b(a.pow(d,1/2))),C[y]=b(a.pow(d,1/3)),y++),d++})();var O=[],w=v.SHA256=o.extend({_doReset:function(){this._hash=new x.init(s.slice(0))},_doProcessBlock:function(m,b){for(var d=this._hash.words,y=d[0],j=d[1],n=d[2],l=d[3],g=d[4],_=d[5],B=d[6],P=d[7],S=0;S<64;S++){if(S<16)O[S]=m[b+S]|0;else{var T=O[S-15],E=(T<<25|T>>>7)^(T<<14|T>>>18)^T>>>3,F=O[S-2],D=(F<<15|F>>>17)^(F<<13|F>>>19)^F>>>10;O[S]=E+O[S-7]+D+O[S-16]}var R=g&_^~g&B,z=y&j^y&n^j&n,N=(y<<30|y>>>2)^(y<<19|y>>>13)^(y<<10|y>>>22),M=(g<<26|g>>>6)^(g<<21|g>>>11)^(g<<7|g>>>25),k=P+M+R+C[S]+O[S],ee=N+z;P=B,B=_,_=g,g=l+k|0,l=n,n=j,j=y,y=k+ee|0}d[0]=d[0]+y|0,d[1]=d[1]+j|0,d[2]=d[2]+n|0,d[3]=d[3]+l|0,d[4]=d[4]+g|0,d[5]=d[5]+_|0,d[6]=d[6]+B|0,d[7]=d[7]+P|0},_doFinalize:function(){var m=this._data,b=m.words,d=this._nDataBytes*8,y=m.sigBytes*8;return b[y>>>5]|=128<<24-y%32,b[(y+64>>>9<<4)+14]=a.floor(d/4294967296),b[(y+64>>>9<<4)+15]=d,m.sigBytes=b.length*4,this._process(),this._hash},clone:function(){var m=o.clone.call(this);return m._hash=this._hash.clone(),m}});p.SHA256=o._createHelper(w),p.HmacSHA256=o._createHmacHelper(w)}(Math),e.SHA256})}(_e)),_e.exports}var Ce={exports:{}},qe;function It(){return qe||(qe=1,function(t,r){(function(e,a){t.exports=a(ce())})(W,function(e){(function(){var a=e,p=a.lib,c=p.Base,x=a.enc,o=x.Utf8,v=a.algo;v.HMAC=c.extend({init:function(s,C){s=this._hasher=new s.init,typeof C=="string"&&(C=o.parse(C));var O=s.blockSize,w=O*4;C.sigBytes>w&&(C=s.finalize(C)),C.clamp();for(var m=this._oKey=C.clone(),b=this._iKey=C.clone(),d=m.words,y=b.words,j=0;j<O;j++)d[j]^=1549556828,y[j]^=909522486;m.sigBytes=b.sigBytes=w,this.reset()},reset:function(){var s=this._hasher;s.reset(),s.update(this._iKey)},update:function(s){return this._hasher.update(s),this},finalize:function(s){var C=this._hasher,O=C.finalize(s);C.reset();var w=C.finalize(this._oKey.clone().concat(O));return w}})})()})}(Ce)),Ce.exports}(function(t,r){(function(e,a,p){t.exports=a(ce(),Ft(),It())})(W,function(e){return e.HmacSHA256})})(Ee);var qt=Ee.exports;const $t=he(qt);var $e={exports:{}};(function(t,r){(function(e,a){t.exports=a(ce())})(W,function(e){return function(){var a=e,p=a.lib,c=p.WordArray,x=a.enc;x.Base64={stringify:function(v){var s=v.words,C=v.sigBytes,O=this._map;v.clamp();for(var w=[],m=0;m<C;m+=3)for(var b=s[m>>>2]>>>24-m%4*8&255,d=s[m+1>>>2]>>>24-(m+1)%4*8&255,y=s[m+2>>>2]>>>24-(m+2)%4*8&255,j=b<<16|d<<8|y,n=0;n<4&&m+n*.75<C;n++)w.push(O.charAt(j>>>6*(3-n)&63));var l=O.charAt(64);if(l)for(;w.length%4;)w.push(l);return w.join("")},parse:function(v){var s=v.length,C=this._map,O=this._reverseMap;if(!O){O=this._reverseMap=[];for(var w=0;w<C.length;w++)O[C.charCodeAt(w)]=w}var m=C.charAt(64);if(m){var b=v.indexOf(m);b!==-1&&(s=b)}return o(v,s,O)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="};function o(v,s,C){for(var O=[],w=0,m=0;m<s;m++)if(m%4){var b=C[v.charCodeAt(m-1)]<<m%4*2,d=C[v.charCodeAt(m)]>>>6-m%4*2,y=b|d;O[w>>>2]|=y<<24-w%4*8,w++}return c.create(O,w)}}(),e.enc.Base64})})($e);var Dt=$e.exports;const De=he(Dt);var Le={exports:{}};(function(t,r){(function(e,a){t.exports=a(ce())})(W,function(e){return function(a){var p=e,c=p.lib,x=c.WordArray,o=c.Hasher,v=p.algo,s=[];(function(){for(var d=0;d<64;d++)s[d]=a.abs(a.sin(d+1))*4294967296|0})();var C=v.MD5=o.extend({_doReset:function(){this._hash=new x.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(d,y){for(var j=0;j<16;j++){var n=y+j,l=d[n];d[n]=(l<<8|l>>>24)&16711935|(l<<24|l>>>8)&4278255360}var g=this._hash.words,_=d[y+0],B=d[y+1],P=d[y+2],S=d[y+3],T=d[y+4],E=d[y+5],F=d[y+6],D=d[y+7],R=d[y+8],z=d[y+9],N=d[y+10],M=d[y+11],k=d[y+12],ee=d[y+13],ie=d[y+14],A=d[y+15],i=g[0],f=g[1],h=g[2],u=g[3];i=O(i,f,h,u,_,7,s[0]),u=O(u,i,f,h,B,12,s[1]),h=O(h,u,i,f,P,17,s[2]),f=O(f,h,u,i,S,22,s[3]),i=O(i,f,h,u,T,7,s[4]),u=O(u,i,f,h,E,12,s[5]),h=O(h,u,i,f,F,17,s[6]),f=O(f,h,u,i,D,22,s[7]),i=O(i,f,h,u,R,7,s[8]),u=O(u,i,f,h,z,12,s[9]),h=O(h,u,i,f,N,17,s[10]),f=O(f,h,u,i,M,22,s[11]),i=O(i,f,h,u,k,7,s[12]),u=O(u,i,f,h,ee,12,s[13]),h=O(h,u,i,f,ie,17,s[14]),f=O(f,h,u,i,A,22,s[15]),i=w(i,f,h,u,B,5,s[16]),u=w(u,i,f,h,F,9,s[17]),h=w(h,u,i,f,M,14,s[18]),f=w(f,h,u,i,_,20,s[19]),i=w(i,f,h,u,E,5,s[20]),u=w(u,i,f,h,N,9,s[21]),h=w(h,u,i,f,A,14,s[22]),f=w(f,h,u,i,T,20,s[23]),i=w(i,f,h,u,z,5,s[24]),u=w(u,i,f,h,ie,9,s[25]),h=w(h,u,i,f,S,14,s[26]),f=w(f,h,u,i,R,20,s[27]),i=w(i,f,h,u,ee,5,s[28]),u=w(u,i,f,h,P,9,s[29]),h=w(h,u,i,f,D,14,s[30]),f=w(f,h,u,i,k,20,s[31]),i=m(i,f,h,u,E,4,s[32]),u=m(u,i,f,h,R,11,s[33]),h=m(h,u,i,f,M,16,s[34]),f=m(f,h,u,i,ie,23,s[35]),i=m(i,f,h,u,B,4,s[36]),u=m(u,i,f,h,T,11,s[37]),h=m(h,u,i,f,D,16,s[38]),f=m(f,h,u,i,N,23,s[39]),i=m(i,f,h,u,ee,4,s[40]),u=m(u,i,f,h,_,11,s[41]),h=m(h,u,i,f,S,16,s[42]),f=m(f,h,u,i,F,23,s[43]),i=m(i,f,h,u,z,4,s[44]),u=m(u,i,f,h,k,11,s[45]),h=m(h,u,i,f,A,16,s[46]),f=m(f,h,u,i,P,23,s[47]),i=b(i,f,h,u,_,6,s[48]),u=b(u,i,f,h,D,10,s[49]),h=b(h,u,i,f,ie,15,s[50]),f=b(f,h,u,i,E,21,s[51]),i=b(i,f,h,u,k,6,s[52]),u=b(u,i,f,h,S,10,s[53]),h=b(h,u,i,f,N,15,s[54]),f=b(f,h,u,i,B,21,s[55]),i=b(i,f,h,u,R,6,s[56]),u=b(u,i,f,h,A,10,s[57]),h=b(h,u,i,f,F,15,s[58]),f=b(f,h,u,i,ee,21,s[59]),i=b(i,f,h,u,T,6,s[60]),u=b(u,i,f,h,M,10,s[61]),h=b(h,u,i,f,P,15,s[62]),f=b(f,h,u,i,z,21,s[63]),g[0]=g[0]+i|0,g[1]=g[1]+f|0,g[2]=g[2]+h|0,g[3]=g[3]+u|0},_doFinalize:function(){var d=this._data,y=d.words,j=this._nDataBytes*8,n=d.sigBytes*8;y[n>>>5]|=128<<24-n%32;var l=a.floor(j/4294967296),g=j;y[(n+64>>>9<<4)+15]=(l<<8|l>>>24)&16711935|(l<<24|l>>>8)&4278255360,y[(n+64>>>9<<4)+14]=(g<<8|g>>>24)&16711935|(g<<24|g>>>8)&4278255360,d.sigBytes=(y.length+1)*4,this._process();for(var _=this._hash,B=_.words,P=0;P<4;P++){var S=B[P];B[P]=(S<<8|S>>>24)&16711935|(S<<24|S>>>8)&4278255360}return _},clone:function(){var d=o.clone.call(this);return d._hash=this._hash.clone(),d}});function O(d,y,j,n,l,g,_){var B=d+(y&j|~y&n)+l+_;return(B<<g|B>>>32-g)+y}function w(d,y,j,n,l,g,_){var B=d+(y&n|j&~n)+l+_;return(B<<g|B>>>32-g)+y}function m(d,y,j,n,l,g,_){var B=d+(y^j^n)+l+_;return(B<<g|B>>>32-g)+y}function b(d,y,j,n,l,g,_){var B=d+(j^(y|~n))+l+_;return(B<<g|B>>>32-g)+y}p.MD5=o._createHelper(C),p.HmacMD5=o._createHmacHelper(C)}(Math),e.MD5})})(Le);var Lt=Le.exports;const Rt=he(Lt),Re={sign:(t,r)=>De.stringify($t(t,r)),md5Content:t=>H.isEmpty(t)?"":De.stringify(Rt(t))},Mt=t=>{const r=H.sortBy(Object.keys(t));let e={};return H.map(r,a=>{H.isEmpty(t[a])?e[a]=null:H.isArray(t[a])?e[a]=t[a][0]:e[a]=t[a]}),e},zt={map:H.map,keys:H.keys,compact:H.compact,sortBy:H.sortBy,forEach:H.forEach},Nt=t=>{let r=t,e=H.mapValues(zt,p=>(...c)=>(r=p(r,...c),a));const a=Object.assign(e,{value:()=>r});return a},Me=t=>{const r=["X-Gw-Signature","X-Gw-Signature-headers","Accept","Content-MD5","Content-Type","Date"];let e="",a="",p=!0;return Nt(t).keys(t).map(c=>!H.includes(r,c)&&{value:t[c],key:H.toLower(c)}).compact().sortBy(c=>c.key).forEach(c=>{e+=`${c.key}:${c.value}
3
3
  `,p?a+=c.key:a+=","+c.key,p=!1}),{transformHeader:e,transformHeaderKeys:a}},Ut="application/x-www-form-urlencoded",Wt=(t,{appkey:r,appsecret:e,originQuery:a})=>{try{if(r&&e){const{method:p,url:c}=t;let x=a?Ye(c,a):c,o=H.get(t,"headers")||H.get(t,"header");const{Accept:v}=o,s=Tt(x,!0),C=s.query;let O="",w=C;if(o["Content-Type"]||(o["Content-Type"]="application/json"),o.Accept||(o.Accept="*/*"),t.body&&o["Content-Type"].indexOf(Ut)===-1)O=Re.md5Content(t.body),o["Content-MD5"]=O;else{let y=t.body;if(H.isString(y)){const j=xt(y);H.isEmpty(w)?w=j:w=Object.assign({},w,j)}}const m=Ze(s.pathname,Ve(Mt(w))),b=o["Content-Type"]?o["Content-Type"]:"";o["X-Gw-Key"]=r,o["X-Gw-Timestamp"]=H.toString(H.now()),o["X-Gw-Nonce"]=H.toString(H.random(1e12,9999999999999));const d=`${p}
4
4
  ${v||"*/*"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gc_mobile",
3
- "version": "1.0.9",
3
+ "version": "1.0.10",
4
4
  "type": "module",
5
5
  "files": [
6
6
  "example",
package/src/modules/dd.js CHANGED
@@ -24,14 +24,20 @@ export const login = async ({ appCode, apiPrefix }) => {
24
24
  if (res.data && res.data?.result === 0) {
25
25
  resolve({ userInfo: res?.data?.retVal, res });
26
26
  } else {
27
- dd.alert({
28
- title: res?.data?.msg
27
+ dd.showToast({
28
+ type: "fail",
29
+ duration: 2000,
30
+ content: res?.data?.msg,
31
+ complete: () => {}
29
32
  });
30
33
  resolve({ res });
31
34
  }
32
35
  } else {
33
- dd.alert({
34
- title: "未配置参数:corpId"
36
+ dd.showToast({
37
+ type: "fail",
38
+ duration: 2000,
39
+ content: "未配置参数:corpId",
40
+ complete: () => {}
35
41
  });
36
42
  }
37
43
  });