yxuse 3.0.38 → 3.0.40

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.
Files changed (59) hide show
  1. package/lib/api.cjs.js +1 -1
  2. package/lib/api.es.js +9 -9
  3. package/lib/app.cjs.js +1 -1
  4. package/lib/app.es.js +1 -1
  5. package/lib/components.cjs.js +1 -1
  6. package/lib/components.es.js +15 -17
  7. package/lib/directives.cjs.js +1 -1
  8. package/lib/directives.es.js +3 -3
  9. package/lib/hooks.cjs.js +1 -1
  10. package/lib/hooks.es.js +2 -2
  11. package/lib/index.cjs.js +1 -1
  12. package/lib/index.cjs10.js +1 -1
  13. package/lib/index.cjs11.js +1 -0
  14. package/lib/index.cjs11.js.gz +0 -0
  15. package/lib/index.cjs12.js +1 -0
  16. package/lib/index.cjs13.js +1 -0
  17. package/lib/index.cjs2.js +1 -42
  18. package/lib/index.cjs3.js +1 -1
  19. package/lib/index.cjs4.js +1 -1
  20. package/lib/index.cjs5.js +22 -1
  21. package/lib/index.cjs5.js.gz +0 -0
  22. package/lib/index.cjs6.js +1 -1
  23. package/lib/index.cjs6.js.gz +0 -0
  24. package/lib/index.cjs7.js +1 -3
  25. package/lib/index.cjs8.js +1 -1
  26. package/lib/index.cjs9.js +1 -1
  27. package/lib/index.es.js +49 -20
  28. package/lib/index.es10.js +313 -9
  29. package/lib/index.es10.js.gz +0 -0
  30. package/lib/index.es11.js +2390 -0
  31. package/lib/index.es11.js.gz +0 -0
  32. package/lib/index.es12.js +202 -0
  33. package/lib/index.es13.js +22 -0
  34. package/lib/index.es2.js +14 -8230
  35. package/lib/index.es3.js +59 -131
  36. package/lib/index.es4.js +47 -42
  37. package/lib/index.es5.js +11117 -35
  38. package/lib/index.es5.js.gz +0 -0
  39. package/lib/index.es6.js +1098 -300
  40. package/lib/index.es6.js.gz +0 -0
  41. package/lib/index.es7.js +17 -1669
  42. package/lib/index.es8.js +4 -15
  43. package/lib/index.es9.js +9 -20
  44. package/lib/theme.cjs.js +1 -1
  45. package/lib/theme.es.js +17 -20
  46. package/lib/translate.cjs.js +1 -1
  47. package/lib/translate.es.js +10 -13
  48. package/lib/utils.cjs.js +1 -1
  49. package/lib/utils.es.js +11 -11
  50. package/lib/yxIcon.cjs.js +1 -1
  51. package/lib/yxIcon.es.js +4 -4
  52. package/package.json +2 -1
  53. package/types/bc/index.d.ts +5 -0
  54. package/types/config/index.d.ts +3 -0
  55. package/types/index.d.ts +3 -2
  56. package/lib/index.cjs2.js.gz +0 -0
  57. package/lib/index.cjs7.js.gz +0 -0
  58. package/lib/index.es2.js.gz +0 -0
  59. package/lib/index.es7.js.gz +0 -0
package/lib/index.cjs7.js CHANGED
@@ -1,3 +1 @@
1
- "use strict";var rt=Object.defineProperty;var Se=Object.getOwnPropertySymbols;var st=Object.prototype.hasOwnProperty,ot=Object.prototype.propertyIsEnumerable;var Z=(e,t,n)=>t in e?rt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_=(e,t)=>{for(var n in t||(t={}))st.call(t,n)&&Z(e,n,t[n]);if(Se)for(var n of Se(t))ot.call(t,n)&&Z(e,n,t[n]);return e};var ee=(e,t,n)=>(Z(e,typeof t!="symbol"?t+"":t,n),n);var j=(e,t,n)=>new Promise((r,s)=>{var i=l=>{try{c(n.next(l))}catch(u){s(u)}},o=l=>{try{c(n.throw(l))}catch(u){s(u)}},c=l=>l.done?r(l.value):Promise.resolve(l.value).then(i,o);c((n=n.apply(e,t)).next())});const S=require("element-plus");function Ue(e,t){return function(){return e.apply(t,arguments)}}const{toString:_e}=Object.prototype,{getPrototypeOf:le}=Object,fe=(e=>t=>{const n=_e.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),A=e=>(e=e.toLowerCase(),t=>fe(t)===e),G=e=>t=>typeof t===e,{isArray:L}=Array,D=G("undefined");function it(e){return e!==null&&!D(e)&&e.constructor!==null&&!D(e.constructor)&&N(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Be=A("ArrayBuffer");function at(e){let t;return typeof ArrayBuffer!="undefined"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Be(e.buffer),t}const ct=G("string"),N=G("function"),Fe=G("number"),de=e=>e!==null&&typeof e=="object",ut=e=>e===!0||e===!1,H=e=>{if(fe(e)!=="object")return!1;const t=le(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},lt=A("Date"),ft=A("File"),dt=A("Blob"),pt=A("FileList"),ht=e=>de(e)&&N(e.pipe),mt=e=>{const t="[object FormData]";return e&&(typeof FormData=="function"&&e instanceof FormData||_e.call(e)===t||N(e.toString)&&e.toString()===t)},Et=A("URLSearchParams"),yt=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function k(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e=="undefined")return;let r,s;if(typeof e!="object"&&(e=[e]),L(e))for(r=0,s=e.length;r<s;r++)t.call(null,e[r],r,e);else{const i=n?Object.getOwnPropertyNames(e):Object.keys(e),o=i.length;let c;for(r=0;r<o;r++)c=i[r],t.call(null,e[c],c,e)}}function De(e,t){t=t.toLowerCase();const n=Object.keys(e);let r=n.length,s;for(;r-- >0;)if(s=n[r],t===s.toLowerCase())return s;return null}const ke=typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:typeof window!="undefined"?window:global,Me=e=>!D(e)&&e!==ke;function oe(){const{caseless:e}=Me(this)&&this||{},t={},n=(r,s)=>{const i=e&&De(t,s)||s;H(t[i])&&H(r)?t[i]=oe(t[i],r):H(r)?t[i]=oe({},r):L(r)?t[i]=r.slice():t[i]=r};for(let r=0,s=arguments.length;r<s;r++)arguments[r]&&k(arguments[r],n);return t}const wt=(e,t,n,{allOwnKeys:r}={})=>(k(t,(s,i)=>{n&&N(s)?e[i]=Ue(s,n):e[i]=s},{allOwnKeys:r}),e),St=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),bt=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},gt=(e,t,n,r)=>{let s,i,o;const c={};if(t=t||{},e==null)return t;do{for(s=Object.getOwnPropertyNames(e),i=s.length;i-- >0;)o=s[i],(!r||r(o,e,t))&&!c[o]&&(t[o]=e[o],c[o]=!0);e=n!==!1&&le(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},Rt=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},Ot=e=>{if(!e)return null;if(L(e))return e;let t=e.length;if(!Fe(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},At=(e=>t=>e&&t instanceof e)(typeof Uint8Array!="undefined"&&le(Uint8Array)),Tt=(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let s;for(;(s=r.next())&&!s.done;){const i=s.value;t.call(e,i[0],i[1])}},Nt=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},Pt=A("HTMLFormElement"),Ct=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,s){return r.toUpperCase()+s}),be=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),xt=A("RegExp"),Ie=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};k(n,(s,i)=>{t(s,i,e)!==!1&&(r[i]=s)}),Object.defineProperties(e,r)},Lt=e=>{Ie(e,(t,n)=>{if(N(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(N(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},Ut=(e,t)=>{const n={},r=s=>{s.forEach(i=>{n[i]=!0})};return L(e)?r(e):r(String(e).split(t)),n},_t=()=>{},Bt=(e,t)=>(e=+e,Number.isFinite(e)?e:t),te="abcdefghijklmnopqrstuvwxyz",ge="0123456789",je={DIGIT:ge,ALPHA:te,ALPHA_DIGIT:te+te.toUpperCase()+ge},Ft=(e=16,t=je.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n};function Dt(e){return!!(e&&N(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const kt=e=>{const t=new Array(10),n=(r,s)=>{if(de(r)){if(t.indexOf(r)>=0)return;if(!("toJSON"in r)){t[s]=r;const i=L(r)?[]:{};return k(r,(o,c)=>{const l=n(o,s+1);!D(l)&&(i[c]=l)}),t[s]=void 0,i}}return r};return n(e,0)},a={isArray:L,isArrayBuffer:Be,isBuffer:it,isFormData:mt,isArrayBufferView:at,isString:ct,isNumber:Fe,isBoolean:ut,isObject:de,isPlainObject:H,isUndefined:D,isDate:lt,isFile:ft,isBlob:dt,isRegExp:xt,isFunction:N,isStream:ht,isURLSearchParams:Et,isTypedArray:At,isFileList:pt,forEach:k,merge:oe,extend:wt,trim:yt,stripBOM:St,inherits:bt,toFlatObject:gt,kindOf:fe,kindOfTest:A,endsWith:Rt,toArray:Ot,forEachEntry:Tt,matchAll:Nt,isHTMLForm:Pt,hasOwnProperty:be,hasOwnProp:be,reduceDescriptors:Ie,freezeMethods:Lt,toObjectSet:Ut,toCamelCase:Ct,noop:_t,toFiniteNumber:Bt,findKey:De,global:ke,isContextDefined:Me,ALPHABET:je,generateString:Ft,isSpecCompliantForm:Dt,toJSONObject:kt};function m(e,t,n,r,s){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),s&&(this.response=s)}a.inherits(m,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:a.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const He=m.prototype,qe={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{qe[e]={value:e}});Object.defineProperties(m,qe);Object.defineProperty(He,"isAxiosError",{value:!0});m.from=(e,t,n,r,s,i)=>{const o=Object.create(He);return a.toFlatObject(e,o,function(l){return l!==Error.prototype},c=>c!=="isAxiosError"),m.call(o,e.message,t,n,r,s),o.cause=e,o.name=e.name,i&&Object.assign(o,i),o};const Mt=null;function ie(e){return a.isPlainObject(e)||a.isArray(e)}function Je(e){return a.endsWith(e,"[]")?e.slice(0,-2):e}function Re(e,t,n){return e?e.concat(t).map(function(s,i){return s=Je(s),!n&&i?"["+s+"]":s}).join(n?".":""):t}function It(e){return a.isArray(e)&&!e.some(ie)}const jt=a.toFlatObject(a,{},null,function(t){return/^is[A-Z]/.test(t)});function $(e,t,n){if(!a.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=a.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(h,R){return!a.isUndefined(R[h])});const r=n.metaTokens,s=n.visitor||f,i=n.dots,o=n.indexes,l=(n.Blob||typeof Blob!="undefined"&&Blob)&&a.isSpecCompliantForm(t);if(!a.isFunction(s))throw new TypeError("visitor must be a function");function u(d){if(d===null)return"";if(a.isDate(d))return d.toISOString();if(!l&&a.isBlob(d))throw new m("Blob is not supported. Use a Buffer instead.");return a.isArrayBuffer(d)||a.isTypedArray(d)?l&&typeof Blob=="function"?new Blob([d]):Buffer.from(d):d}function f(d,h,R){let b=d;if(d&&!R&&typeof d=="object"){if(a.endsWith(h,"{}"))h=r?h:h.slice(0,-2),d=JSON.stringify(d);else if(a.isArray(d)&&It(d)||(a.isFileList(d)||a.endsWith(h,"[]"))&&(b=a.toArray(d)))return h=Je(h),b.forEach(function(I,nt){!(a.isUndefined(I)||I===null)&&t.append(o===!0?Re([h],nt,i):o===null?h:h+"[]",u(I))}),!1}return ie(d)?!0:(t.append(Re(R,h,i),u(d)),!1)}const p=[],w=Object.assign(jt,{defaultVisitor:f,convertValue:u,isVisitable:ie});function E(d,h){if(!a.isUndefined(d)){if(p.indexOf(d)!==-1)throw Error("Circular reference detected in "+h.join("."));p.push(d),a.forEach(d,function(b,P){(!(a.isUndefined(b)||b===null)&&s.call(t,b,a.isString(P)?P.trim():P,h,w))===!0&&E(b,h?h.concat(P):[P])}),p.pop()}}if(!a.isObject(e))throw new TypeError("data must be an object");return E(e),t}function Oe(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function pe(e,t){this._pairs=[],e&&$(e,this,t)}const ze=pe.prototype;ze.append=function(t,n){this._pairs.push([t,n])};ze.toString=function(t){const n=t?function(r){return t.call(this,r,Oe)}:Oe;return this._pairs.map(function(s){return n(s[0])+"="+n(s[1])},"").join("&")};function Ht(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Ve(e,t,n){if(!t)return e;const r=n&&n.encode||Ht,s=n&&n.serialize;let i;if(s?i=s(t,n):i=a.isURLSearchParams(t)?t.toString():new pe(t,n).toString(r),i){const o=e.indexOf("#");o!==-1&&(e=e.slice(0,o)),e+=(e.indexOf("?")===-1?"?":"&")+i}return e}class Ae{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){a.forEach(this.handlers,function(r){r!==null&&t(r)})}}const Ge={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},qt=typeof URLSearchParams!="undefined"?URLSearchParams:pe,Jt=typeof FormData!="undefined"?FormData:null,zt=(()=>{let e;return typeof navigator!="undefined"&&((e=navigator.product)==="ReactNative"||e==="NativeScript"||e==="NS")?!1:typeof window!="undefined"&&typeof document!="undefined"})(),Vt=typeof WorkerGlobalScope!="undefined"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",g={isBrowser:!0,classes:{URLSearchParams:qt,FormData:Jt,Blob},isStandardBrowserEnv:zt,isStandardBrowserWebWorkerEnv:Vt,protocols:["http","https","file","blob","url","data"]};function Gt(e,t){return $(e,new g.classes.URLSearchParams,Object.assign({visitor:function(n,r,s,i){return g.isNode&&a.isBuffer(n)?(this.append(r,n.toString("base64")),!1):i.defaultVisitor.apply(this,arguments)}},t))}function $t(e){return a.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function vt(e){const t={},n=Object.keys(e);let r;const s=n.length;let i;for(r=0;r<s;r++)i=n[r],t[i]=e[i];return t}function $e(e){function t(n,r,s,i){let o=n[i++];const c=Number.isFinite(+o),l=i>=n.length;return o=!o&&a.isArray(s)?s.length:o,l?(a.hasOwnProp(s,o)?s[o]=[s[o],r]:s[o]=r,!c):((!s[o]||!a.isObject(s[o]))&&(s[o]=[]),t(n,r,s[o],i)&&a.isArray(s[o])&&(s[o]=vt(s[o])),!c)}if(a.isFormData(e)&&a.isFunction(e.entries)){const n={};return a.forEachEntry(e,(r,s)=>{t($t(r),s,n,0)}),n}return null}const Kt={"Content-Type":void 0};function Wt(e,t,n){if(a.isString(e))try{return(t||JSON.parse)(e),a.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const v={transitional:Ge,adapter:["xhr","http"],transformRequest:[function(t,n){const r=n.getContentType()||"",s=r.indexOf("application/json")>-1,i=a.isObject(t);if(i&&a.isHTMLForm(t)&&(t=new FormData(t)),a.isFormData(t))return s&&s?JSON.stringify($e(t)):t;if(a.isArrayBuffer(t)||a.isBuffer(t)||a.isStream(t)||a.isFile(t)||a.isBlob(t))return t;if(a.isArrayBufferView(t))return t.buffer;if(a.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let c;if(i){if(r.indexOf("application/x-www-form-urlencoded")>-1)return Gt(t,this.formSerializer).toString();if((c=a.isFileList(t))||r.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return $(c?{"files[]":t}:t,l&&new l,this.formSerializer)}}return i||s?(n.setContentType("application/json",!1),Wt(t)):t}],transformResponse:[function(t){const n=this.transitional||v.transitional,r=n&&n.forcedJSONParsing,s=this.responseType==="json";if(t&&a.isString(t)&&(r&&!this.responseType||s)){const o=!(n&&n.silentJSONParsing)&&s;try{return JSON.parse(t)}catch(c){if(o)throw c.name==="SyntaxError"?m.from(c,m.ERR_BAD_RESPONSE,this,null,this.response):c}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:g.classes.FormData,Blob:g.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};a.forEach(["delete","get","head"],function(t){v.headers[t]={}});a.forEach(["post","put","patch"],function(t){v.headers[t]=a.merge(Kt)});const he=v,Xt=a.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Qt=e=>{const t={};let n,r,s;return e&&e.split(`
2
- `).forEach(function(o){s=o.indexOf(":"),n=o.substring(0,s).trim().toLowerCase(),r=o.substring(s+1).trim(),!(!n||t[n]&&Xt[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},Te=Symbol("internals");function B(e){return e&&String(e).trim().toLowerCase()}function q(e){return e===!1||e==null?e:a.isArray(e)?e.map(q):String(e)}function Yt(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}function Zt(e){return/^[-_a-zA-Z]+$/.test(e.trim())}function ne(e,t,n,r,s){if(a.isFunction(r))return r.call(this,t,n);if(s&&(t=n),!!a.isString(t)){if(a.isString(r))return t.indexOf(r)!==-1;if(a.isRegExp(r))return r.test(t)}}function en(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function tn(e,t){const n=a.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(s,i,o){return this[r].call(this,t,s,i,o)},configurable:!0})})}class K{constructor(t){t&&this.set(t)}set(t,n,r){const s=this;function i(c,l,u){const f=B(l);if(!f)throw new Error("header name must be a non-empty string");const p=a.findKey(s,f);(!p||s[p]===void 0||u===!0||u===void 0&&s[p]!==!1)&&(s[p||l]=q(c))}const o=(c,l)=>a.forEach(c,(u,f)=>i(u,f,l));return a.isPlainObject(t)||t instanceof this.constructor?o(t,n):a.isString(t)&&(t=t.trim())&&!Zt(t)?o(Qt(t),n):t!=null&&i(n,t,r),this}get(t,n){if(t=B(t),t){const r=a.findKey(this,t);if(r){const s=this[r];if(!n)return s;if(n===!0)return Yt(s);if(a.isFunction(n))return n.call(this,s,r);if(a.isRegExp(n))return n.exec(s);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=B(t),t){const r=a.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||ne(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let s=!1;function i(o){if(o=B(o),o){const c=a.findKey(r,o);c&&(!n||ne(r,r[c],c,n))&&(delete r[c],s=!0)}}return a.isArray(t)?t.forEach(i):i(t),s}clear(t){const n=Object.keys(this);let r=n.length,s=!1;for(;r--;){const i=n[r];(!t||ne(this,this[i],i,t,!0))&&(delete this[i],s=!0)}return s}normalize(t){const n=this,r={};return a.forEach(this,(s,i)=>{const o=a.findKey(r,i);if(o){n[o]=q(s),delete n[i];return}const c=t?en(i):String(i).trim();c!==i&&delete n[i],n[c]=q(s),r[c]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return a.forEach(this,(r,s)=>{r!=null&&r!==!1&&(n[s]=t&&a.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(`
3
- `)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(s=>r.set(s)),r}static accessor(t){const r=(this[Te]=this[Te]={accessors:{}}).accessors,s=this.prototype;function i(o){const c=B(o);r[c]||(tn(s,o),r[c]=!0)}return a.isArray(t)?t.forEach(i):i(t),this}}K.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);a.freezeMethods(K.prototype);a.freezeMethods(K);const O=K;function re(e,t){const n=this||he,r=t||n,s=O.from(r.headers);let i=r.data;return a.forEach(e,function(c){i=c.call(n,i,s.normalize(),t?t.status:void 0)}),s.normalize(),i}function ve(e){return!!(e&&e.__CANCEL__)}function M(e,t,n){m.call(this,e==null?"canceled":e,m.ERR_CANCELED,t,n),this.name="CanceledError"}a.inherits(M,m,{__CANCEL__:!0});function nn(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new m("Request failed with status code "+n.status,[m.ERR_BAD_REQUEST,m.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}const rn=g.isStandardBrowserEnv?function(){return{write:function(n,r,s,i,o,c){const l=[];l.push(n+"="+encodeURIComponent(r)),a.isNumber(s)&&l.push("expires="+new Date(s).toGMTString()),a.isString(i)&&l.push("path="+i),a.isString(o)&&l.push("domain="+o),c===!0&&l.push("secure"),document.cookie=l.join("; ")},read:function(n){const r=document.cookie.match(new RegExp("(^|;\\s*)("+n+")=([^;]*)"));return r?decodeURIComponent(r[3]):null},remove:function(n){this.write(n,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}();function sn(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function on(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}function Ke(e,t){return e&&!sn(t)?on(e,t):t}const an=g.isStandardBrowserEnv?function(){const t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");let r;function s(i){let o=i;return t&&(n.setAttribute("href",o),o=n.href),n.setAttribute("href",o),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return r=s(window.location.href),function(o){const c=a.isString(o)?s(o):o;return c.protocol===r.protocol&&c.host===r.host}}():function(){return function(){return!0}}();function cn(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function un(e,t){e=e||10;const n=new Array(e),r=new Array(e);let s=0,i=0,o;return t=t!==void 0?t:1e3,function(l){const u=Date.now(),f=r[i];o||(o=u),n[s]=l,r[s]=u;let p=i,w=0;for(;p!==s;)w+=n[p++],p=p%e;if(s=(s+1)%e,s===i&&(i=(i+1)%e),u-o<t)return;const E=f&&u-f;return E?Math.round(w*1e3/E):void 0}}function Ne(e,t){let n=0;const r=un(50,250);return s=>{const i=s.loaded,o=s.lengthComputable?s.total:void 0,c=i-n,l=r(c),u=i<=o;n=i;const f={loaded:i,total:o,progress:o?i/o:void 0,bytes:c,rate:l||void 0,estimated:l&&o&&u?(o-i)/l:void 0,event:s};f[t?"download":"upload"]=!0,e(f)}}const ln=typeof XMLHttpRequest!="undefined",fn=ln&&function(e){return new Promise(function(n,r){let s=e.data;const i=O.from(e.headers).normalize(),o=e.responseType;let c;function l(){e.cancelToken&&e.cancelToken.unsubscribe(c),e.signal&&e.signal.removeEventListener("abort",c)}a.isFormData(s)&&(g.isStandardBrowserEnv||g.isStandardBrowserWebWorkerEnv)&&i.setContentType(!1);let u=new XMLHttpRequest;if(e.auth){const E=e.auth.username||"",d=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";i.set("Authorization","Basic "+btoa(E+":"+d))}const f=Ke(e.baseURL,e.url);u.open(e.method.toUpperCase(),Ve(f,e.params,e.paramsSerializer),!0),u.timeout=e.timeout;function p(){if(!u)return;const E=O.from("getAllResponseHeaders"in u&&u.getAllResponseHeaders()),h={data:!o||o==="text"||o==="json"?u.responseText:u.response,status:u.status,statusText:u.statusText,headers:E,config:e,request:u};nn(function(b){n(b),l()},function(b){r(b),l()},h),u=null}if("onloadend"in u?u.onloadend=p:u.onreadystatechange=function(){!u||u.readyState!==4||u.status===0&&!(u.responseURL&&u.responseURL.indexOf("file:")===0)||setTimeout(p)},u.onabort=function(){u&&(r(new m("Request aborted",m.ECONNABORTED,e,u)),u=null)},u.onerror=function(){r(new m("Network Error",m.ERR_NETWORK,e,u)),u=null},u.ontimeout=function(){let d=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const h=e.transitional||Ge;e.timeoutErrorMessage&&(d=e.timeoutErrorMessage),r(new m(d,h.clarifyTimeoutError?m.ETIMEDOUT:m.ECONNABORTED,e,u)),u=null},g.isStandardBrowserEnv){const E=(e.withCredentials||an(f))&&e.xsrfCookieName&&rn.read(e.xsrfCookieName);E&&i.set(e.xsrfHeaderName,E)}s===void 0&&i.setContentType(null),"setRequestHeader"in u&&a.forEach(i.toJSON(),function(d,h){u.setRequestHeader(h,d)}),a.isUndefined(e.withCredentials)||(u.withCredentials=!!e.withCredentials),o&&o!=="json"&&(u.responseType=e.responseType),typeof e.onDownloadProgress=="function"&&u.addEventListener("progress",Ne(e.onDownloadProgress,!0)),typeof e.onUploadProgress=="function"&&u.upload&&u.upload.addEventListener("progress",Ne(e.onUploadProgress)),(e.cancelToken||e.signal)&&(c=E=>{u&&(r(!E||E.type?new M(null,e,u):E),u.abort(),u=null)},e.cancelToken&&e.cancelToken.subscribe(c),e.signal&&(e.signal.aborted?c():e.signal.addEventListener("abort",c)));const w=cn(f);if(w&&g.protocols.indexOf(w)===-1){r(new m("Unsupported protocol "+w+":",m.ERR_BAD_REQUEST,e));return}u.send(s||null)})},J={http:Mt,xhr:fn};a.forEach(J,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch(n){}Object.defineProperty(e,"adapterName",{value:t})}});const dn={getAdapter:e=>{e=a.isArray(e)?e:[e];const{length:t}=e;let n,r;for(let s=0;s<t&&(n=e[s],!(r=a.isString(n)?J[n.toLowerCase()]:n));s++);if(!r)throw r===!1?new m(`Adapter ${n} is not supported by the environment`,"ERR_NOT_SUPPORT"):new Error(a.hasOwnProp(J,n)?`Adapter '${n}' is not available in the build`:`Unknown adapter '${n}'`);if(!a.isFunction(r))throw new TypeError("adapter is not a function");return r},adapters:J};function se(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new M(null,e)}function Pe(e){return se(e),e.headers=O.from(e.headers),e.data=re.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),dn.getAdapter(e.adapter||he.adapter)(e).then(function(r){return se(e),r.data=re.call(e,e.transformResponse,r),r.headers=O.from(r.headers),r},function(r){return ve(r)||(se(e),r&&r.response&&(r.response.data=re.call(e,e.transformResponse,r.response),r.response.headers=O.from(r.response.headers))),Promise.reject(r)})}const Ce=e=>e instanceof O?e.toJSON():e;function x(e,t){t=t||{};const n={};function r(u,f,p){return a.isPlainObject(u)&&a.isPlainObject(f)?a.merge.call({caseless:p},u,f):a.isPlainObject(f)?a.merge({},f):a.isArray(f)?f.slice():f}function s(u,f,p){if(a.isUndefined(f)){if(!a.isUndefined(u))return r(void 0,u,p)}else return r(u,f,p)}function i(u,f){if(!a.isUndefined(f))return r(void 0,f)}function o(u,f){if(a.isUndefined(f)){if(!a.isUndefined(u))return r(void 0,u)}else return r(void 0,f)}function c(u,f,p){if(p in t)return r(u,f);if(p in e)return r(void 0,u)}const l={url:i,method:i,data:i,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,adapter:o,responseType:o,xsrfCookieName:o,xsrfHeaderName:o,onUploadProgress:o,onDownloadProgress:o,decompress:o,maxContentLength:o,maxBodyLength:o,beforeRedirect:o,transport:o,httpAgent:o,httpsAgent:o,cancelToken:o,socketPath:o,responseEncoding:o,validateStatus:c,headers:(u,f)=>s(Ce(u),Ce(f),!0)};return a.forEach(Object.keys(e).concat(Object.keys(t)),function(f){const p=l[f]||s,w=p(e[f],t[f],f);a.isUndefined(w)&&p!==c||(n[f]=w)}),n}const We="1.3.3",me={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{me[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const xe={};me.transitional=function(t,n,r){function s(i,o){return"[Axios v"+We+"] Transitional option '"+i+"'"+o+(r?". "+r:"")}return(i,o,c)=>{if(t===!1)throw new m(s(o," has been removed"+(n?" in "+n:"")),m.ERR_DEPRECATED);return n&&!xe[o]&&(xe[o]=!0,console.warn(s(o," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(i,o,c):!0}};function pn(e,t,n){if(typeof e!="object")throw new m("options must be an object",m.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let s=r.length;for(;s-- >0;){const i=r[s],o=t[i];if(o){const c=e[i],l=c===void 0||o(c,i,e);if(l!==!0)throw new m("option "+i+" must be "+l,m.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new m("Unknown option "+i,m.ERR_BAD_OPTION)}}const ae={assertOptions:pn,validators:me},T=ae.validators;class V{constructor(t){this.defaults=t,this.interceptors={request:new Ae,response:new Ae}}request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=x(this.defaults,n);const{transitional:r,paramsSerializer:s,headers:i}=n;r!==void 0&&ae.assertOptions(r,{silentJSONParsing:T.transitional(T.boolean),forcedJSONParsing:T.transitional(T.boolean),clarifyTimeoutError:T.transitional(T.boolean)},!1),s!==void 0&&ae.assertOptions(s,{encode:T.function,serialize:T.function},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let o;o=i&&a.merge(i.common,i[n.method]),o&&a.forEach(["delete","get","head","post","put","patch","common"],d=>{delete i[d]}),n.headers=O.concat(o,i);const c=[];let l=!0;this.interceptors.request.forEach(function(h){typeof h.runWhen=="function"&&h.runWhen(n)===!1||(l=l&&h.synchronous,c.unshift(h.fulfilled,h.rejected))});const u=[];this.interceptors.response.forEach(function(h){u.push(h.fulfilled,h.rejected)});let f,p=0,w;if(!l){const d=[Pe.bind(this),void 0];for(d.unshift.apply(d,c),d.push.apply(d,u),w=d.length,f=Promise.resolve(n);p<w;)f=f.then(d[p++],d[p++]);return f}w=c.length;let E=n;for(p=0;p<w;){const d=c[p++],h=c[p++];try{E=d(E)}catch(R){h.call(this,R);break}}try{f=Pe.call(this,E)}catch(d){return Promise.reject(d)}for(p=0,w=u.length;p<w;)f=f.then(u[p++],u[p++]);return f}getUri(t){t=x(this.defaults,t);const n=Ke(t.baseURL,t.url);return Ve(n,t.params,t.paramsSerializer)}}a.forEach(["delete","get","head","options"],function(t){V.prototype[t]=function(n,r){return this.request(x(r||{},{method:t,url:n,data:(r||{}).data}))}});a.forEach(["post","put","patch"],function(t){function n(r){return function(i,o,c){return this.request(x(c||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:i,data:o}))}}V.prototype[t]=n(),V.prototype[t+"Form"]=n(!0)});const z=V;class Ee{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(i){n=i});const r=this;this.promise.then(s=>{if(!r._listeners)return;let i=r._listeners.length;for(;i-- >0;)r._listeners[i](s);r._listeners=null}),this.promise.then=s=>{let i;const o=new Promise(c=>{r.subscribe(c),i=c}).then(s);return o.cancel=function(){r.unsubscribe(i)},o},t(function(i,o,c){r.reason||(r.reason=new M(i,o,c),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}static source(){let t;return{token:new Ee(function(s){t=s}),cancel:t}}}const hn=Ee;function mn(e){return function(n){return e.apply(null,n)}}function En(e){return a.isObject(e)&&e.isAxiosError===!0}const ce={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(ce).forEach(([e,t])=>{ce[t]=e});const yn=ce;function Xe(e){const t=new z(e),n=Ue(z.prototype.request,t);return a.extend(n,z.prototype,t,{allOwnKeys:!0}),a.extend(n,t,null,{allOwnKeys:!0}),n.create=function(s){return Xe(x(e,s))},n}const y=Xe(he);y.Axios=z;y.CanceledError=M;y.CancelToken=hn;y.isCancel=ve;y.VERSION=We;y.toFormData=$;y.AxiosError=m;y.Cancel=y.CanceledError;y.all=function(t){return Promise.all(t)};y.spread=mn;y.isAxiosError=En;y.mergeConfig=x;y.AxiosHeaders=O;y.formToJSON=e=>$e(a.isHTMLForm(e)?new FormData(e):e);y.HttpStatusCode=yn;y.default=y;const wn={LOGIN_URL:`${window.location.origin}/ttc/cloud/#/login`,HOME_URL:`${window.location.origin}/ttc/cloud/#/cloud`,INTEGRATED_BASE_URL:"/gateway/integrated-management/api/v1"},ye={ttc:wn},Sn=(e="ttc")=>Y.get(`${ye[e].INTEGRATED_BASE_URL}/account/auth/route/list`),bn=(e="ttc")=>Y.get(`${ye[e].INTEGRATED_BASE_URL}/account/home/menu`),we=(e="ttc")=>{Q({token:""})},W=(e="ttc")=>{var s;const t=`${e}GlobalState`,n=(s=localStorage.getItem(t))!=null?s:"{}";return JSON.parse(n)?JSON.parse(n).token:null},Qe=(r,...s)=>j(exports,[r,...s],function*({userName:e,password:t},n="ttc"){const i=U("loginApiUrl"),{data:o}=yield Y.post(i,{userName:e,password:t});o.tokenValue&&S.ElMessage.success("登录成功"),Q({token:o.tokenValue,userInfo:o})}),gn=(e="ttc")=>{var s;const t=`${e}GlobalState`,n=(s=localStorage.getItem(t))!=null?s:"{}";return JSON.parse(n)?JSON.parse(n).userInfo:null},Rn=()=>j(exports,null,function*(){return W()?yield bn():[]}),X=()=>{if(Ze()){we();const e=location.pathname;if(console.log("跳转至登录页",e,e.includes(C())),e.includes(C()))return;console.log("跳转至登录页",C()),location.replace(C())}else{console.log("开发环境!!!");const e=window.prompt("当前系统处于开发环境,当前登录过期,请输入登录账号","");if(e!==null){const t=window.prompt("请输入登录密码","");(t===null||t=="")&&window.prompt("请输入登录密码",""),Qe({userName:e,password:t})}}},On=()=>{window.location.replace(Ye())},C=()=>U("loginUrl"),Ye=()=>U("homeUrl"),Q=e=>{var r;const t=(r=localStorage.getItem("ttcGlobalState"))!=null?r:"{}",n=_(_({},JSON.parse(t)),e);localStorage.setItem("ttcGlobalState",JSON.stringify(n))},U=e=>{var n,r;return(r=JSON.parse((n=localStorage.getItem("ttcGlobalState"))!=null?n:"{}")[e])!=null?r:""},Ze=()=>U("environment")==="production",An=(e,t=!0,n)=>j(exports,null,function*(){if(!W()&&t)return X();try{const{data:r}=yield Sn(n),s=r.filter(c=>c.routeTag.includes(e)),i=s.filter(c=>c.routeType==="VIEW"),o=s.filter(c=>c.routeType==="BTN");return sessionStorage.setItem("ttcUserBtnList",JSON.stringify(o.map(c=>c.routeTag))),{userMenuList:i,userBtnList:o}}catch(r){}}),Tn=(e,t,n)=>{let r=[];return e.forEach(s=>{const i=`/src/views${s.routeView}/config.ts`,o=`/src/views${s.routeView}/index.vue`;if(t[o]&&n[i]){const c=n[i],l={path:s.routeView,name:s.routeView.split("/")[1],meta:{title:c.title,icon:c.icon},component:t[o]};r.push(l)}}),r},et=e=>{var n;if(!e)return!1;const t=(n=sessionStorage.getItem("ttcUserBtnList"))!=null?n:"[]";return JSON.parse(t).includes(e)},Nn=Object.freeze(Object.defineProperty({__proto__:null,autoLogin:Qe,getHomeUrl:Ye,getLoginUrl:C,getSystemConfig:U,getToken:W,getUserInfo:gn,getUserIsHaveBtnPower:et,getUserPermissions:An,getUserRouteList:Rn,getUserRouter:Tn,isProduction:Ze,jumpToHome:On,jumpToLogin:X,removeToken:we,setSystemConfig:Q},Symbol.toStringTag,{value:"Module"}));let tt;const Pn={lock:!0,text:"加载中...",fullscreen:!0,background:"rgba(0, 0, 0, 0.6)"},Cn=()=>{tt=S.ElLoading.service(Pn)},xn=()=>{tt.close()};let F=0;const Ln=()=>{F===0&&Cn(),F++},Le=()=>{F<=0||(F--,F===0&&xn())};var ue=(e=>(e[e.SUCCESS=200]="SUCCESS",e[e.ERROR=500]="ERROR",e[e.OVERDUE=401]="OVERDUE",e[e.TIMEOUT=3e4]="TIMEOUT",e))(ue||{});const Un={timeout:3e4,withCredentials:!0},_n=(e,t)=>{switch(e){case 400:S.ElMessage.error(t||"请求失败!请您稍后重试");break;case 401:location.href.includes(C())||(S.ElMessage.error(t||"登录失效!请您重新登录"),X());break;case 403:S.ElMessage.error(t||"当前账号无权限访问!");break;case 404:S.ElMessage.error("你所访问的资源不存在!");break;case 405:S.ElMessage.error(t||"请求方式错误!请您稍后重试");break;case 408:S.ElMessage.error(t||"请求超时!请您稍后重试");break;case 500:S.ElMessage.error(t||"服务异常!");break;case 502:S.ElMessage.error("网关错误!");break;case 503:S.ElMessage.error("服务不可用!");break;case 504:S.ElMessage.error("网关超时!");break;default:S.ElMessage.error("请求失败!")}};class Bn{constructor(t){ee(this,"service");ee(this,"customResMap");this.service=y.create(t),this.setupInterceptors(),this.customResMap={}}setupInterceptors(){this.service.interceptors.request.use(t=>{var n;return(n=t.headers)!=null&&n.noLoading||Ln(),t.headers.token=W(),t!=null&&t.customResHandler&&(t!=null&&t.url)&&(this.customResMap[t==null?void 0:t.url]=t.customResHandler),t},t=>Promise.reject(t)),this.service.interceptors.response.use(t=>{const{data:n,config:r}=t;return Le(),r.url&&this.customResMap[r.url]?this.customResMap[r.url](n):(n.code==ue.OVERDUE?this.handleOverdueResponse(n):n.code!==ue.SUCCESS&&this.handleErrorResponse(n),n)},t=>{Le();const{config:n}=t;return n!=null&&n.url&&this.customResMap[n.url]&&this.customResMap[n.url](t.response),t.message.includes("timeout")?S.ElMessage.error("请求超时!请稍后重试"):t.message.includes("Network Error")&&S.ElMessage.error("网络错误!请稍后重试"),t.response&&_n(t.response.status),window.navigator.onLine||S.ElNotification({title:"提示",message:"当前网络似乎开小差了",type:"warning",duration:5e3}),Promise.reject(t)})}handleOverdueResponse(t){return we(),X(),S.ElNotification({title:"登录过期提醒",message:t.resultMsg||"当前登录失效",type:"warning",duration:5e3}),Promise.reject(t)}handleErrorResponse(t){return S.ElMessage.error(t.resultMsg),Promise.reject(t)}get(t,n,r={}){return this.service.get(t,_({params:n},r))}post(t,n,r={}){return this.service.post(t,n,r)}put(t,n,r={}){return this.service.put(t,n,r)}delete(t,n,r={}){return this.service.delete(t,_({params:n},r))}}const Y=new Bn(Un);exports.URL=ye;exports.getSystemConfig=U;exports.getUserIsHaveBtnPower=et;exports.http=Y;exports.index=Nn;exports.setSystemConfig=Q;
1
+ "use strict";const e=require("./index.cjs11.js"),t={mounted(e,t){r(e,t)}},r=(t,r)=>{const o=r.value;return e.getUserIsHaveBtnPower(o)?"":t.remove()},o={auth:t},s={install:function(e){Object.keys(o).forEach((t=>{e.directive(t,o[t])}))}},i=Object.freeze(Object.defineProperty({__proto__:null,default:s},Symbol.toStringTag,{value:"Module"}));exports.directives=i,exports.directives$1=s;
package/lib/index.cjs8.js CHANGED
@@ -1 +1 @@
1
- "use strict";const e=require("./index.cjs7.js"),i=(t,o)=>e.http.post(`${e.URL.ttc.INTEGRATED_BASE_URL}/file/upload`,t,o),r=()=>e.http.get(`${e.URL.ttc.INTEGRATED_BASE_URL}/resource/group/list`,{},{headers:{noLoading:!0}}),s=(t,o)=>e.http.get(`${e.URL.ttc.INTEGRATED_BASE_URL}/resource/file/list/${o}/${t}`,{},{headers:{noLoading:!0}}),u=Object.freeze(Object.defineProperty({__proto__:null,getGroupListApi:r,getResourceListApi:s,uploadResourceApi:i},Symbol.toStringTag,{value:"Module"}));exports.getGroupListApi=r;exports.getResourceListApi=s;exports.index=u;exports.uploadResourceApi=i;
1
+ "use strict";const e=require("./index.cjs10.js"),o=Object.freeze(Object.defineProperty({__proto__:null,useTime:e.useTime},Symbol.toStringTag,{value:"Module"}));exports.yxHooks=o;
package/lib/index.cjs9.js CHANGED
@@ -1 +1 @@
1
- "use strict";const i=require("./index.cjs7.js"),s={mounted(t,e){n(t,e)}},n=(t,e)=>{const c=e.value;return i.getUserIsHaveBtnPower(c)?"":t.remove()},r={auth:s},o={install:function(t){Object.keys(r).forEach(e=>{t.directive(e,r[e])})}},u=Object.freeze(Object.defineProperty({__proto__:null,default:o},Symbol.toStringTag,{value:"Module"}));exports.directives=u;exports.directives$1=o;
1
+ "use strict";const e=(e="isWebApp")=>{const t=new URLSearchParams(window.location.href.split("?")[1]),r=Object.fromEntries(t.entries());return!(!r[e]||!+r[e])},t=Object.freeze(Object.defineProperty({__proto__:null,isWebApp:e},Symbol.toStringTag,{value:"Module"}));exports.app=t,exports.isWebApp=e;
package/lib/index.es.js CHANGED
@@ -1,24 +1,53 @@
1
- import { u as m } from "./index.es3.js";
2
- import { y as x } from "./index.es4.js";
3
- import { b as n } from "./index.es5.js";
4
- import { B as y, y as l, w as b, x as c, z as A, A as B } from "./index.es2.js";
5
- import "./index.es9.js";
6
- import { u as h } from "./index.es6.js";
7
- import { i as z } from "./index.es10.js";
8
- import "./index.es7.js";
1
+ import { u as utils2 } from "./index.es2.js";
2
+ import { y as yxIcon2 } from "./index.es3.js";
3
+ import { a as api2 } from "./index.es4.js";
4
+ import { g as getWordByYxI18nThesaurus, t as theme2, B as BC, a as translate2 } from "./index.es5.js";
5
+ import { b } from "./index.es5.js";
6
+ import { c as components2 } from "./index.es6.js";
7
+ import { d as directives } from "./index.es7.js";
8
+ import { y as yxHooks } from "./index.es8.js";
9
+ import { a as app } from "./index.es9.js";
10
+ import { i } from "./index.es9.js";
11
+ import { u } from "./index.es10.js";
12
+ import "./index.es11.js";
9
13
  import "element-plus";
10
- import "./index.es8.js";
14
+ import "./index.es12.js";
15
+ import "./index.es13.js";
11
16
  import "vue";
17
+ const index$1 = {
18
+ install: (app2) => {
19
+ app2.config.globalProperties.$yx18n = (key) => {
20
+ return getWordByYxI18nThesaurus(key);
21
+ };
22
+ }
23
+ };
24
+ const yxi18n2 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
25
+ __proto__: null,
26
+ default: index$1
27
+ }, Symbol.toStringTag, { value: "Module" }));
28
+ const index = {
29
+ utils: utils2,
30
+ api: api2,
31
+ app,
32
+ theme: theme2,
33
+ components: components2,
34
+ directives,
35
+ BC,
36
+ translate: translate2,
37
+ yxi18n: yxi18n2,
38
+ yxHooks,
39
+ yxIcon: yxIcon2
40
+ };
12
41
  export {
13
- y as BC,
14
- n as api,
15
- l as components,
16
- b as default,
17
- z as isWebApp,
18
- c as theme,
19
- A as translate,
20
- h as useTime,
21
- m as utils,
22
- x as yxIcon,
23
- B as yxi18n
42
+ b as BC,
43
+ api2 as api,
44
+ components2 as components,
45
+ index as default,
46
+ i as isWebApp,
47
+ theme2 as theme,
48
+ translate2 as translate,
49
+ u as useTime,
50
+ utils2 as utils,
51
+ yxIcon2 as yxIcon,
52
+ yxi18n2 as yxi18n
24
53
  };
package/lib/index.es10.js CHANGED
@@ -1,11 +1,315 @@
1
- const o = (e = "isWebApp") => {
2
- const r = new URLSearchParams(window.location.href.split("?")[1]), t = Object.fromEntries(r.entries());
3
- return !!(t[e] && +t[e]);
4
- }, s = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5
- __proto__: null,
6
- isWebApp: o
7
- }, Symbol.toStringTag, { value: "Module" }));
1
+ import { ref } from "vue";
2
+ var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
3
+ function getDefaultExportFromCjs(x) {
4
+ return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default") ? x["default"] : x;
5
+ }
6
+ var dayjs_min = { exports: {} };
7
+ (function(module, exports) {
8
+ !function(t, e) {
9
+ module.exports = e();
10
+ }(commonjsGlobal, function() {
11
+ var t = 1e3, e = 6e4, n = 36e5, r = "millisecond", i = "second", s = "minute", u = "hour", a = "day", o = "week", c = "month", f = "quarter", h = "year", d = "date", l = "Invalid Date", $ = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, y = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, M = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(t2) {
12
+ var e2 = ["th", "st", "nd", "rd"], n2 = t2 % 100;
13
+ return "[" + t2 + (e2[(n2 - 20) % 10] || e2[n2] || e2[0]) + "]";
14
+ } }, m = function(t2, e2, n2) {
15
+ var r2 = String(t2);
16
+ return !r2 || r2.length >= e2 ? t2 : "" + Array(e2 + 1 - r2.length).join(n2) + t2;
17
+ }, v = { s: m, z: function(t2) {
18
+ var e2 = -t2.utcOffset(), n2 = Math.abs(e2), r2 = Math.floor(n2 / 60), i2 = n2 % 60;
19
+ return (e2 <= 0 ? "+" : "-") + m(r2, 2, "0") + ":" + m(i2, 2, "0");
20
+ }, m: function t2(e2, n2) {
21
+ if (e2.date() < n2.date())
22
+ return -t2(n2, e2);
23
+ var r2 = 12 * (n2.year() - e2.year()) + (n2.month() - e2.month()), i2 = e2.clone().add(r2, c), s2 = n2 - i2 < 0, u2 = e2.clone().add(r2 + (s2 ? -1 : 1), c);
24
+ return +(-(r2 + (n2 - i2) / (s2 ? i2 - u2 : u2 - i2)) || 0);
25
+ }, a: function(t2) {
26
+ return t2 < 0 ? Math.ceil(t2) || 0 : Math.floor(t2);
27
+ }, p: function(t2) {
28
+ return { M: c, y: h, w: o, d: a, D: d, h: u, m: s, s: i, ms: r, Q: f }[t2] || String(t2 || "").toLowerCase().replace(/s$/, "");
29
+ }, u: function(t2) {
30
+ return void 0 === t2;
31
+ } }, g = "en", D = {};
32
+ D[g] = M;
33
+ var p = "$isDayjsObject", S = function(t2) {
34
+ return t2 instanceof _ || !(!t2 || !t2[p]);
35
+ }, w = function t2(e2, n2, r2) {
36
+ var i2;
37
+ if (!e2)
38
+ return g;
39
+ if ("string" == typeof e2) {
40
+ var s2 = e2.toLowerCase();
41
+ D[s2] && (i2 = s2), n2 && (D[s2] = n2, i2 = s2);
42
+ var u2 = e2.split("-");
43
+ if (!i2 && u2.length > 1)
44
+ return t2(u2[0]);
45
+ } else {
46
+ var a2 = e2.name;
47
+ D[a2] = e2, i2 = a2;
48
+ }
49
+ return !r2 && i2 && (g = i2), i2 || !r2 && g;
50
+ }, O = function(t2, e2) {
51
+ if (S(t2))
52
+ return t2.clone();
53
+ var n2 = "object" == typeof e2 ? e2 : {};
54
+ return n2.date = t2, n2.args = arguments, new _(n2);
55
+ }, b = v;
56
+ b.l = w, b.i = S, b.w = function(t2, e2) {
57
+ return O(t2, { locale: e2.$L, utc: e2.$u, x: e2.$x, $offset: e2.$offset });
58
+ };
59
+ var _ = function() {
60
+ function M2(t2) {
61
+ this.$L = w(t2.locale, null, true), this.parse(t2), this.$x = this.$x || t2.x || {}, this[p] = true;
62
+ }
63
+ var m2 = M2.prototype;
64
+ return m2.parse = function(t2) {
65
+ this.$d = function(t3) {
66
+ var e2 = t3.date, n2 = t3.utc;
67
+ if (null === e2)
68
+ return /* @__PURE__ */ new Date(NaN);
69
+ if (b.u(e2))
70
+ return /* @__PURE__ */ new Date();
71
+ if (e2 instanceof Date)
72
+ return new Date(e2);
73
+ if ("string" == typeof e2 && !/Z$/i.test(e2)) {
74
+ var r2 = e2.match($);
75
+ if (r2) {
76
+ var i2 = r2[2] - 1 || 0, s2 = (r2[7] || "0").substring(0, 3);
77
+ return n2 ? new Date(Date.UTC(r2[1], i2, r2[3] || 1, r2[4] || 0, r2[5] || 0, r2[6] || 0, s2)) : new Date(r2[1], i2, r2[3] || 1, r2[4] || 0, r2[5] || 0, r2[6] || 0, s2);
78
+ }
79
+ }
80
+ return new Date(e2);
81
+ }(t2), this.init();
82
+ }, m2.init = function() {
83
+ var t2 = this.$d;
84
+ this.$y = t2.getFullYear(), this.$M = t2.getMonth(), this.$D = t2.getDate(), this.$W = t2.getDay(), this.$H = t2.getHours(), this.$m = t2.getMinutes(), this.$s = t2.getSeconds(), this.$ms = t2.getMilliseconds();
85
+ }, m2.$utils = function() {
86
+ return b;
87
+ }, m2.isValid = function() {
88
+ return !(this.$d.toString() === l);
89
+ }, m2.isSame = function(t2, e2) {
90
+ var n2 = O(t2);
91
+ return this.startOf(e2) <= n2 && n2 <= this.endOf(e2);
92
+ }, m2.isAfter = function(t2, e2) {
93
+ return O(t2) < this.startOf(e2);
94
+ }, m2.isBefore = function(t2, e2) {
95
+ return this.endOf(e2) < O(t2);
96
+ }, m2.$g = function(t2, e2, n2) {
97
+ return b.u(t2) ? this[e2] : this.set(n2, t2);
98
+ }, m2.unix = function() {
99
+ return Math.floor(this.valueOf() / 1e3);
100
+ }, m2.valueOf = function() {
101
+ return this.$d.getTime();
102
+ }, m2.startOf = function(t2, e2) {
103
+ var n2 = this, r2 = !!b.u(e2) || e2, f2 = b.p(t2), l2 = function(t3, e3) {
104
+ var i2 = b.w(n2.$u ? Date.UTC(n2.$y, e3, t3) : new Date(n2.$y, e3, t3), n2);
105
+ return r2 ? i2 : i2.endOf(a);
106
+ }, $2 = function(t3, e3) {
107
+ return b.w(n2.toDate()[t3].apply(n2.toDate("s"), (r2 ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(e3)), n2);
108
+ }, y2 = this.$W, M3 = this.$M, m3 = this.$D, v2 = "set" + (this.$u ? "UTC" : "");
109
+ switch (f2) {
110
+ case h:
111
+ return r2 ? l2(1, 0) : l2(31, 11);
112
+ case c:
113
+ return r2 ? l2(1, M3) : l2(0, M3 + 1);
114
+ case o:
115
+ var g2 = this.$locale().weekStart || 0, D2 = (y2 < g2 ? y2 + 7 : y2) - g2;
116
+ return l2(r2 ? m3 - D2 : m3 + (6 - D2), M3);
117
+ case a:
118
+ case d:
119
+ return $2(v2 + "Hours", 0);
120
+ case u:
121
+ return $2(v2 + "Minutes", 1);
122
+ case s:
123
+ return $2(v2 + "Seconds", 2);
124
+ case i:
125
+ return $2(v2 + "Milliseconds", 3);
126
+ default:
127
+ return this.clone();
128
+ }
129
+ }, m2.endOf = function(t2) {
130
+ return this.startOf(t2, false);
131
+ }, m2.$set = function(t2, e2) {
132
+ var n2, o2 = b.p(t2), f2 = "set" + (this.$u ? "UTC" : ""), l2 = (n2 = {}, n2[a] = f2 + "Date", n2[d] = f2 + "Date", n2[c] = f2 + "Month", n2[h] = f2 + "FullYear", n2[u] = f2 + "Hours", n2[s] = f2 + "Minutes", n2[i] = f2 + "Seconds", n2[r] = f2 + "Milliseconds", n2)[o2], $2 = o2 === a ? this.$D + (e2 - this.$W) : e2;
133
+ if (o2 === c || o2 === h) {
134
+ var y2 = this.clone().set(d, 1);
135
+ y2.$d[l2]($2), y2.init(), this.$d = y2.set(d, Math.min(this.$D, y2.daysInMonth())).$d;
136
+ } else
137
+ l2 && this.$d[l2]($2);
138
+ return this.init(), this;
139
+ }, m2.set = function(t2, e2) {
140
+ return this.clone().$set(t2, e2);
141
+ }, m2.get = function(t2) {
142
+ return this[b.p(t2)]();
143
+ }, m2.add = function(r2, f2) {
144
+ var d2, l2 = this;
145
+ r2 = Number(r2);
146
+ var $2 = b.p(f2), y2 = function(t2) {
147
+ var e2 = O(l2);
148
+ return b.w(e2.date(e2.date() + Math.round(t2 * r2)), l2);
149
+ };
150
+ if ($2 === c)
151
+ return this.set(c, this.$M + r2);
152
+ if ($2 === h)
153
+ return this.set(h, this.$y + r2);
154
+ if ($2 === a)
155
+ return y2(1);
156
+ if ($2 === o)
157
+ return y2(7);
158
+ var M3 = (d2 = {}, d2[s] = e, d2[u] = n, d2[i] = t, d2)[$2] || 1, m3 = this.$d.getTime() + r2 * M3;
159
+ return b.w(m3, this);
160
+ }, m2.subtract = function(t2, e2) {
161
+ return this.add(-1 * t2, e2);
162
+ }, m2.format = function(t2) {
163
+ var e2 = this, n2 = this.$locale();
164
+ if (!this.isValid())
165
+ return n2.invalidDate || l;
166
+ var r2 = t2 || "YYYY-MM-DDTHH:mm:ssZ", i2 = b.z(this), s2 = this.$H, u2 = this.$m, a2 = this.$M, o2 = n2.weekdays, c2 = n2.months, f2 = n2.meridiem, h2 = function(t3, n3, i3, s3) {
167
+ return t3 && (t3[n3] || t3(e2, r2)) || i3[n3].slice(0, s3);
168
+ }, d2 = function(t3) {
169
+ return b.s(s2 % 12 || 12, t3, "0");
170
+ }, $2 = f2 || function(t3, e3, n3) {
171
+ var r3 = t3 < 12 ? "AM" : "PM";
172
+ return n3 ? r3.toLowerCase() : r3;
173
+ };
174
+ return r2.replace(y, function(t3, r3) {
175
+ return r3 || function(t4) {
176
+ switch (t4) {
177
+ case "YY":
178
+ return String(e2.$y).slice(-2);
179
+ case "YYYY":
180
+ return b.s(e2.$y, 4, "0");
181
+ case "M":
182
+ return a2 + 1;
183
+ case "MM":
184
+ return b.s(a2 + 1, 2, "0");
185
+ case "MMM":
186
+ return h2(n2.monthsShort, a2, c2, 3);
187
+ case "MMMM":
188
+ return h2(c2, a2);
189
+ case "D":
190
+ return e2.$D;
191
+ case "DD":
192
+ return b.s(e2.$D, 2, "0");
193
+ case "d":
194
+ return String(e2.$W);
195
+ case "dd":
196
+ return h2(n2.weekdaysMin, e2.$W, o2, 2);
197
+ case "ddd":
198
+ return h2(n2.weekdaysShort, e2.$W, o2, 3);
199
+ case "dddd":
200
+ return o2[e2.$W];
201
+ case "H":
202
+ return String(s2);
203
+ case "HH":
204
+ return b.s(s2, 2, "0");
205
+ case "h":
206
+ return d2(1);
207
+ case "hh":
208
+ return d2(2);
209
+ case "a":
210
+ return $2(s2, u2, true);
211
+ case "A":
212
+ return $2(s2, u2, false);
213
+ case "m":
214
+ return String(u2);
215
+ case "mm":
216
+ return b.s(u2, 2, "0");
217
+ case "s":
218
+ return String(e2.$s);
219
+ case "ss":
220
+ return b.s(e2.$s, 2, "0");
221
+ case "SSS":
222
+ return b.s(e2.$ms, 3, "0");
223
+ case "Z":
224
+ return i2;
225
+ }
226
+ return null;
227
+ }(t3) || i2.replace(":", "");
228
+ });
229
+ }, m2.utcOffset = function() {
230
+ return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
231
+ }, m2.diff = function(r2, d2, l2) {
232
+ var $2, y2 = this, M3 = b.p(d2), m3 = O(r2), v2 = (m3.utcOffset() - this.utcOffset()) * e, g2 = this - m3, D2 = function() {
233
+ return b.m(y2, m3);
234
+ };
235
+ switch (M3) {
236
+ case h:
237
+ $2 = D2() / 12;
238
+ break;
239
+ case c:
240
+ $2 = D2();
241
+ break;
242
+ case f:
243
+ $2 = D2() / 3;
244
+ break;
245
+ case o:
246
+ $2 = (g2 - v2) / 6048e5;
247
+ break;
248
+ case a:
249
+ $2 = (g2 - v2) / 864e5;
250
+ break;
251
+ case u:
252
+ $2 = g2 / n;
253
+ break;
254
+ case s:
255
+ $2 = g2 / e;
256
+ break;
257
+ case i:
258
+ $2 = g2 / t;
259
+ break;
260
+ default:
261
+ $2 = g2;
262
+ }
263
+ return l2 ? $2 : b.a($2);
264
+ }, m2.daysInMonth = function() {
265
+ return this.endOf(c).$D;
266
+ }, m2.$locale = function() {
267
+ return D[this.$L];
268
+ }, m2.locale = function(t2, e2) {
269
+ if (!t2)
270
+ return this.$L;
271
+ var n2 = this.clone(), r2 = w(t2, e2, true);
272
+ return r2 && (n2.$L = r2), n2;
273
+ }, m2.clone = function() {
274
+ return b.w(this.$d, this);
275
+ }, m2.toDate = function() {
276
+ return new Date(this.valueOf());
277
+ }, m2.toJSON = function() {
278
+ return this.isValid() ? this.toISOString() : null;
279
+ }, m2.toISOString = function() {
280
+ return this.$d.toISOString();
281
+ }, m2.toString = function() {
282
+ return this.$d.toUTCString();
283
+ }, M2;
284
+ }(), k = _.prototype;
285
+ return O.prototype = k, [["$ms", r], ["$s", i], ["$m", s], ["$H", u], ["$W", a], ["$M", c], ["$y", h], ["$D", d]].forEach(function(t2) {
286
+ k[t2[1]] = function(e2) {
287
+ return this.$g(e2, t2[0], t2[1]);
288
+ };
289
+ }), O.extend = function(t2, e2) {
290
+ return t2.$i || (t2(e2, _, O), t2.$i = true), O;
291
+ }, O.locale = w, O.isDayjs = S, O.unix = function(t2) {
292
+ return O(1e3 * t2);
293
+ }, O.en = D[g], O.Ls = D, O.p = {}, O;
294
+ });
295
+ })(dayjs_min);
296
+ var dayjs_minExports = dayjs_min.exports;
297
+ const dayjs = /* @__PURE__ */ getDefaultExportFromCjs(dayjs_minExports);
298
+ const time = ref("");
299
+ let _timer;
300
+ const useTime = () => {
301
+ const timedExecution = () => {
302
+ _timer = setTimeout(() => {
303
+ time.value = dayjs().format("YYYY-MM-DD HH:mm:ss");
304
+ _timer && clearTimeout(_timer);
305
+ timedExecution();
306
+ }, 1e3);
307
+ };
308
+ timedExecution();
309
+ return { time };
310
+ };
8
311
  export {
9
- s as a,
10
- o as i
312
+ commonjsGlobal as c,
313
+ getDefaultExportFromCjs as g,
314
+ useTime as u
11
315
  };
Binary file