@vtj/pro 0.16.3 → 0.16.5

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 (27) hide show
  1. package/dist/@vtj/materials/assets/antdv/index.umd.js +2 -2
  2. package/dist/@vtj/materials/assets/charts/index.umd.js +2 -2
  3. package/dist/@vtj/materials/assets/element/index.umd.js +2 -2
  4. package/dist/@vtj/materials/assets/icons/index.umd.js +2 -2
  5. package/dist/@vtj/materials/assets/ui/index.umd.js +2 -2
  6. package/dist/@vtj/materials/assets/uni-h5/index.umd.js +2 -2
  7. package/dist/@vtj/materials/assets/uni-ui/index.umd.js +2 -2
  8. package/dist/@vtj/materials/assets/vant/index.umd.js +2 -2
  9. package/dist/@vtj/materials/deps/@vtj/charts/index.umd.js +2 -2
  10. package/dist/@vtj/materials/deps/@vtj/icons/index.umd.js +2 -2
  11. package/dist/@vtj/materials/deps/@vtj/ui/index.umd.js +2 -2
  12. package/dist/@vtj/materials/deps/@vtj/utils/index.umd.js +2 -2
  13. package/dist/assets/{Editor-DMaEPM3O-BODFmRgl.js → Editor-CdFOSqH8-CJFd0j7i.js} +67 -67
  14. package/dist/assets/{auth-C7OlyPVf.js → auth-VtqGNcT6.js} +1 -1
  15. package/dist/assets/{index-DG0xULFw.js → index-BA-Kqb-a.js} +2 -2
  16. package/dist/assets/{index-ZAhcLxjK.js → index-BfZ01t6O.js} +1 -1
  17. package/dist/assets/page-BL_cWhZL.js +2 -0
  18. package/dist/assets/preview-IOWQoYdk.js +2 -0
  19. package/dist/assets/utils-BZ_Pc90j.js +1 -0
  20. package/dist/index.html +3 -3
  21. package/dist/uni/assets/{index-Dbr5EyvL.js → index-COtCTLhP.js} +8 -8
  22. package/dist/uni/index.html +1 -1
  23. package/package.json +11 -11
  24. package/dist/assets/page-csONRDX6.js +0 -2
  25. package/dist/assets/preview-Djyu1-Yb.js +0 -2
  26. package/dist/assets/utils-BAP47J0F.js +0 -1
  27. /package/dist/assets/{Editor-DMaEPM3O-DMkAB_XD.css → Editor-CdFOSqH8-DMkAB_XD.css} +0 -0
@@ -46,29 +46,29 @@ function print() { __p += __j.call(arguments, '') }
46
46
  * Copyright (c) 2026, VTJ.PRO All rights reserved.
47
47
  * @name @vtj/core
48
48
  * @author CHC chenhuachun1549@dingtalk.com
49
- * @version 0.16.3
49
+ * @version 0.16.5
50
50
  * @license <a href="https://vtj.pro/license.html">MIT License</a>
51
51
  */const sg="VueMaterial",og="VueRouterMaterial",ag={[sg]:["Transition","TransitionGroup","KeepAlive","Teleport","Suspense"],[og]:["RouterView","RouterLink"]};let ug=class{constructor(){q(this,"listeners",[]);q(this,"isReady",!1)}triggerReady(){this.isReady=!0;for(const t of this.listeners)t();this.listeners=[]}ready(t){this.isReady?t():this.listeners.push(t)}resetReady(){this.isReady=!1}};var cg=Object.defineProperty,lg=(r,t,e)=>t in r?cg(r,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):r[t]=e,lt=(r,t,e)=>lg(r,typeof t!="symbol"?t+"":t,e);(function(){if(typeof window>"u"||typeof EventTarget>"u")return;const r=EventTarget.prototype.addEventListener;EventTarget.prototype.addEventListener=function(t,e,n){typeof n!="boolean"&&(n=n||{},n.passive=!1),r.call(this,t,e,n)}})();function So(r,t){return function(){return r.apply(t,arguments)}}const{toString:fg}=Object.prototype,{getPrototypeOf:Sn}=Object,{iterator:ir,toStringTag:To}=Symbol,sr=(r=>t=>{const e=fg.call(t);return r[e]||(r[e]=e.slice(8,-1).toLowerCase())})(Object.create(null)),yt=r=>(r=r.toLowerCase(),t=>sr(t)===r),or=r=>t=>typeof t===r,{isArray:ce}=Array,se=or("undefined");function Te(r){return r!==null&&!se(r)&&r.constructor!==null&&!se(r.constructor)&&ut(r.constructor.isBuffer)&&r.constructor.isBuffer(r)}const Ro=yt("ArrayBuffer");function hg(r){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(r):t=r&&r.buffer&&Ro(r.buffer),t}const pg=or("string"),ut=or("function"),xo=or("number"),Re=r=>r!==null&&typeof r=="object",dg=r=>r===!0||r===!1,He=r=>{if(sr(r)!=="object")return!1;const t=Sn(r);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(To in r)&&!(ir in r)},gg=r=>{if(!Re(r)||Te(r))return!1;try{return Object.keys(r).length===0&&Object.getPrototypeOf(r)===Object.prototype}catch(t){return!1}},vg=yt("Date"),mg=yt("File"),yg=yt("Blob"),bg=yt("FileList"),_g=r=>Re(r)&&ut(r.pipe),wg=r=>{let t;return r&&(typeof FormData=="function"&&r instanceof FormData||ut(r.append)&&((t=sr(r))==="formdata"||t==="object"&&ut(r.toString)&&r.toString()==="[object FormData]"))},Eg=yt("URLSearchParams"),[Sg,Tg,Rg,xg]=["ReadableStream","Request","Response","Headers"].map(yt),Ag=r=>r.trim?r.trim():r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function xe(r,t,{allOwnKeys:e=!1}={}){if(r===null||typeof r>"u")return;let n,i;if(typeof r!="object"&&(r=[r]),ce(r))for(n=0,i=r.length;n<i;n++)t.call(null,r[n],n,r);else{if(Te(r))return;const s=e?Object.getOwnPropertyNames(r):Object.keys(r),o=s.length;let u;for(n=0;n<o;n++)u=s[n],t.call(null,r[u],u,r)}}function Ao(r,t){if(Te(r))return null;t=t.toLowerCase();const e=Object.keys(r);let n=e.length,i;for(;n-- >0;)if(i=e[n],t===i.toLowerCase())return i;return null}const Lt=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Oo=r=>!se(r)&&r!==Lt;function Yr(){const{caseless:r,skipUndefined:t}=Oo(this)&&this||{},e={},n=(i,s)=>{const o=r&&Ao(e,s)||s;He(e[o])&&He(i)?e[o]=Yr(e[o],i):He(i)?e[o]=Yr({},i):ce(i)?e[o]=i.slice():(!t||!se(i))&&(e[o]=i)};for(let i=0,s=arguments.length;i<s;i++)arguments[i]&&xe(arguments[i],n);return e}const Og=(r,t,e,{allOwnKeys:n}={})=>(xe(t,(i,s)=>{e&&ut(i)?Object.defineProperty(r,s,{value:So(i,e),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(r,s,{value:i,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:n}),r),$g=r=>(r.charCodeAt(0)===65279&&(r=r.slice(1)),r),Dg=(r,t,e,n)=>{r.prototype=Object.create(t.prototype,n),Object.defineProperty(r.prototype,"constructor",{value:r,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(r,"super",{value:t.prototype}),e&&Object.assign(r.prototype,e)},Cg=(r,t,e,n)=>{let i,s,o;const u={};if(t=t||{},r==null)return t;do{for(i=Object.getOwnPropertyNames(r),s=i.length;s-- >0;)o=i[s],(!n||n(o,r,t))&&!u[o]&&(t[o]=r[o],u[o]=!0);r=e!==!1&&Sn(r)}while(r&&(!e||e(r,t))&&r!==Object.prototype);return t},Bg=(r,t,e)=>{r=String(r),(e===void 0||e>r.length)&&(e=r.length),e-=t.length;const n=r.indexOf(t,e);return n!==-1&&n===e},jg=r=>{if(!r)return null;if(ce(r))return r;let t=r.length;if(!xo(t))return null;const e=new Array(t);for(;t-- >0;)e[t]=r[t];return e},Pg=(r=>t=>r&&t instanceof r)(typeof Uint8Array<"u"&&Sn(Uint8Array)),Ng=(r,t)=>{const e=(r&&r[ir]).call(r);let n;for(;(n=e.next())&&!n.done;){const i=n.value;t.call(r,i[0],i[1])}},Ig=(r,t)=>{let e;const n=[];for(;(e=r.exec(t))!==null;)n.push(e);return n},Mg=yt("HTMLFormElement"),Fg=r=>r.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(t,e,n){return e.toUpperCase()+n}),Ni=(({hasOwnProperty:r})=>(t,e)=>r.call(t,e))(Object.prototype),Ug=yt("RegExp"),$o=(r,t)=>{const e=Object.getOwnPropertyDescriptors(r),n={};xe(e,(i,s)=>{let o;(o=t(i,s,r))!==!1&&(n[s]=o||i)}),Object.defineProperties(r,n)},Lg=r=>{$o(r,(t,e)=>{if(ut(r)&&["arguments","caller","callee"].indexOf(e)!==-1)return!1;const n=r[e];if(ut(n)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+e+"'")})}})},kg=(r,t)=>{const e={},n=i=>{i.forEach(s=>{e[s]=!0})};return ce(r)?n(r):n(String(r).split(t)),e},Hg=()=>{},Vg=(r,t)=>r!=null&&Number.isFinite(r=+r)?r:t;function qg(r){return!!(r&&ut(r.append)&&r[To]==="FormData"&&r[ir])}const zg=r=>{const t=new Array(10),e=(n,i)=>{if(Re(n)){if(t.indexOf(n)>=0)return;if(Te(n))return n;if(!("toJSON"in n)){t[i]=n;const s=ce(n)?[]:{};return xe(n,(o,u)=>{const l=e(o,i+1);!se(l)&&(s[u]=l)}),t[i]=void 0,s}}return n};return e(r,0)},Wg=yt("AsyncFunction"),Kg=r=>r&&(Re(r)||ut(r))&&ut(r.then)&&ut(r.catch),Do=((r,t)=>r?setImmediate:t?((e,n)=>(Lt.addEventListener("message",({source:i,data:s})=>{i===Lt&&s===e&&n.length&&n.shift()()},!1),i=>{n.push(i),Lt.postMessage(e,"*")}))(`axios@${Math.random()}`,[]):e=>setTimeout(e))(typeof setImmediate=="function",ut(Lt.postMessage)),Jg=typeof queueMicrotask<"u"?queueMicrotask.bind(Lt):typeof process<"u"&&process.nextTick||Do,Gg=r=>r!=null&&ut(r[ir]),x={isArray:ce,isArrayBuffer:Ro,isBuffer:Te,isFormData:wg,isArrayBufferView:hg,isString:pg,isNumber:xo,isBoolean:dg,isObject:Re,isPlainObject:He,isEmptyObject:gg,isReadableStream:Sg,isRequest:Tg,isResponse:Rg,isHeaders:xg,isUndefined:se,isDate:vg,isFile:mg,isBlob:yg,isRegExp:Ug,isFunction:ut,isStream:_g,isURLSearchParams:Eg,isTypedArray:Pg,isFileList:bg,forEach:xe,merge:Yr,extend:Og,trim:Ag,stripBOM:$g,inherits:Dg,toFlatObject:Cg,kindOf:sr,kindOfTest:yt,endsWith:Bg,toArray:jg,forEachEntry:Ng,matchAll:Ig,isHTMLForm:Mg,hasOwnProperty:Ni,hasOwnProp:Ni,reduceDescriptors:$o,freezeMethods:Lg,toObjectSet:kg,toCamelCase:Fg,noop:Hg,toFiniteNumber:Vg,findKey:Ao,global:Lt,isContextDefined:Oo,isSpecCompliantForm:qg,toJSONObject:zg,isAsyncFn:Wg,isThenable:Kg,setImmediate:Do,asap:Jg,isIterable:Gg};let W=class Co extends Error{static from(t,e,n,i,s,o){const u=new Co(t.message,e||t.code,n,i,s);return u.cause=t,u.name=t.name,o&&Object.assign(u,o),u}constructor(t,e,n,i,s){super(t),this.name="AxiosError",this.isAxiosError=!0,e&&(this.code=e),n&&(this.config=n),i&&(this.request=i),s&&(this.response=s,this.status=s.status)}toJSON(){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:x.toJSONObject(this.config),code:this.code,status:this.status}}};W.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";W.ERR_BAD_OPTION="ERR_BAD_OPTION";W.ECONNABORTED="ECONNABORTED";W.ETIMEDOUT="ETIMEDOUT";W.ERR_NETWORK="ERR_NETWORK";W.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";W.ERR_DEPRECATED="ERR_DEPRECATED";W.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";W.ERR_BAD_REQUEST="ERR_BAD_REQUEST";W.ERR_CANCELED="ERR_CANCELED";W.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";W.ERR_INVALID_URL="ERR_INVALID_URL";const Yg=null;function Zr(r){return x.isPlainObject(r)||x.isArray(r)}function Bo(r){return x.endsWith(r,"[]")?r.slice(0,-2):r}function Ii(r,t,e){return r?r.concat(t).map(function(n,i){return n=Bo(n),!e&&i?"["+n+"]":n}).join(e?".":""):t}function Zg(r){return x.isArray(r)&&!r.some(Zr)}const Qg=x.toFlatObject(x,{},null,function(r){return/^is[A-Z]/.test(r)});function ar(r,t,e){if(!x.isObject(r))throw new TypeError("target must be an object");t=t||new FormData,e=x.toFlatObject(e,{metaTokens:!0,dots:!1,indexes:!1},!1,function(p,d){return!x.isUndefined(d[p])});const n=e.metaTokens,i=e.visitor||a,s=e.dots,o=e.indexes,u=(e.Blob||typeof Blob<"u"&&Blob)&&x.isSpecCompliantForm(t);if(!x.isFunction(i))throw new TypeError("visitor must be a function");function l(p){if(p===null)return"";if(x.isDate(p))return p.toISOString();if(x.isBoolean(p))return p.toString();if(!u&&x.isBlob(p))throw new W("Blob is not supported. Use a Buffer instead.");return x.isArrayBuffer(p)||x.isTypedArray(p)?u&&typeof Blob=="function"?new Blob([p]):Buffer.from(p):p}function a(p,d,g){let b=p;if(p&&!g&&typeof p=="object"){if(x.endsWith(d,"{}"))d=n?d:d.slice(0,-2),p=JSON.stringify(p);else if(x.isArray(p)&&Zg(p)||(x.isFileList(p)||x.endsWith(d,"[]"))&&(b=x.toArray(p)))return d=Bo(d),b.forEach(function(w,m){!(x.isUndefined(w)||w===null)&&t.append(o===!0?Ii([d],m,s):o===null?d:d+"[]",l(w))}),!1}return Zr(p)?!0:(t.append(Ii(g,d,s),l(p)),!1)}const c=[],f=Object.assign(Qg,{defaultVisitor:a,convertValue:l,isVisitable:Zr});function h(p,d){if(!x.isUndefined(p)){if(c.indexOf(p)!==-1)throw Error("Circular reference detected in "+d.join("."));c.push(p),x.forEach(p,function(g,b){(!(x.isUndefined(g)||g===null)&&i.call(t,g,x.isString(b)?b.trim():b,d,f))===!0&&h(g,d?d.concat(b):[b])}),c.pop()}}if(!x.isObject(r))throw new TypeError("data must be an object");return h(r),t}function Mi(r){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(r).replace(/[!'()~]|%20|%00/g,function(e){return t[e]})}function Tn(r,t){this._pairs=[],r&&ar(r,this,t)}const jo=Tn.prototype;jo.append=function(r,t){this._pairs.push([r,t])};jo.toString=function(r){const t=r?function(e){return r.call(this,e,Mi)}:Mi;return this._pairs.map(function(e){return t(e[0])+"="+t(e[1])},"").join("&")};function Xg(r){return encodeURIComponent(r).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Po(r,t,e){if(!t)return r;const n=e&&e.encode||Xg,i=x.isFunction(e)?{serialize:e}:e,s=i&&i.serialize;let o;if(s?o=s(t,i):o=x.isURLSearchParams(t)?t.toString():new Tn(t,i).toString(n),o){const u=r.indexOf("#");u!==-1&&(r=r.slice(0,u)),r+=(r.indexOf("?")===-1?"?":"&")+o}return r}class Fi{constructor(){this.handlers=[]}use(t,e,n){return this.handlers.push({fulfilled:t,rejected:e,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){x.forEach(this.handlers,function(e){e!==null&&t(e)})}}const No={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},tv=typeof URLSearchParams<"u"?URLSearchParams:Tn,ev=typeof FormData<"u"?FormData:null,rv=typeof Blob<"u"?Blob:null,nv={isBrowser:!0,classes:{URLSearchParams:tv,FormData:ev,Blob:rv},protocols:["http","https","file","blob","url","data"]},Rn=typeof window<"u"&&typeof document<"u",Qr=typeof navigator=="object"&&navigator||void 0,iv=Rn&&(!Qr||["ReactNative","NativeScript","NS"].indexOf(Qr.product)<0),sv=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",ov=Rn&&window.location.href||"http://localhost",av=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Rn,hasStandardBrowserEnv:iv,hasStandardBrowserWebWorkerEnv:sv,navigator:Qr,origin:ov},Symbol.toStringTag,{value:"Module"})),nt=H(H({},av),nv);function uv(r,t){return ar(r,new nt.classes.URLSearchParams,H({visitor:function(e,n,i,s){return nt.isNode&&x.isBuffer(e)?(this.append(n,e.toString("base64")),!1):s.defaultVisitor.apply(this,arguments)}},t))}function cv(r){return x.matchAll(/\w+|\[(\w*)]/g,r).map(t=>t[0]==="[]"?"":t[1]||t[0])}function lv(r){const t={},e=Object.keys(r);let n;const i=e.length;let s;for(n=0;n<i;n++)s=e[n],t[s]=r[s];return t}function Io(r){function t(e,n,i,s){let o=e[s++];if(o==="__proto__")return!0;const u=Number.isFinite(+o),l=s>=e.length;return o=!o&&x.isArray(i)?i.length:o,l?(x.hasOwnProp(i,o)?i[o]=[i[o],n]:i[o]=n,!u):((!i[o]||!x.isObject(i[o]))&&(i[o]=[]),t(e,n,i[o],s)&&x.isArray(i[o])&&(i[o]=lv(i[o])),!u)}if(x.isFormData(r)&&x.isFunction(r.entries)){const e={};return x.forEachEntry(r,(n,i)=>{t(cv(n),i,e,0)}),e}return null}function fv(r,t,e){if(x.isString(r))try{return(t||JSON.parse)(r),x.trim(r)}catch(n){if(n.name!=="SyntaxError")throw n}return(e||JSON.stringify)(r)}const Ae={transitional:No,adapter:["xhr","http","fetch"],transformRequest:[function(r,t){const e=t.getContentType()||"",n=e.indexOf("application/json")>-1,i=x.isObject(r);if(i&&x.isHTMLForm(r)&&(r=new FormData(r)),x.isFormData(r))return n?JSON.stringify(Io(r)):r;if(x.isArrayBuffer(r)||x.isBuffer(r)||x.isStream(r)||x.isFile(r)||x.isBlob(r)||x.isReadableStream(r))return r;if(x.isArrayBufferView(r))return r.buffer;if(x.isURLSearchParams(r))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),r.toString();let s;if(i){if(e.indexOf("application/x-www-form-urlencoded")>-1)return uv(r,this.formSerializer).toString();if((s=x.isFileList(r))||e.indexOf("multipart/form-data")>-1){const o=this.env&&this.env.FormData;return ar(s?{"files[]":r}:r,o&&new o,this.formSerializer)}}return i||n?(t.setContentType("application/json",!1),fv(r)):r}],transformResponse:[function(r){const t=this.transitional||Ae.transitional,e=t&&t.forcedJSONParsing,n=this.responseType==="json";if(x.isResponse(r)||x.isReadableStream(r))return r;if(r&&x.isString(r)&&(e&&!this.responseType||n)){const i=!(t&&t.silentJSONParsing)&&n;try{return JSON.parse(r,this.parseReviver)}catch(s){if(i)throw s.name==="SyntaxError"?W.from(s,W.ERR_BAD_RESPONSE,this,null,this.response):s}}return r}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:nt.classes.FormData,Blob:nt.classes.Blob},validateStatus:function(r){return r>=200&&r<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};x.forEach(["delete","get","head","post","put","patch"],r=>{Ae.headers[r]={}});const hv=x.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"]),pv=r=>{const t={};let e,n,i;return r&&r.split(`
52
52
  `).forEach(function(s){i=s.indexOf(":"),e=s.substring(0,i).trim().toLowerCase(),n=s.substring(i+1).trim(),!(!e||t[e]&&hv[e])&&(e==="set-cookie"?t[e]?t[e].push(n):t[e]=[n]:t[e]=t[e]?t[e]+", "+n:n)}),t},Ui=Symbol("internals");function de(r){return r&&String(r).trim().toLowerCase()}function Ve(r){return r===!1||r==null?r:x.isArray(r)?r.map(Ve):String(r)}function dv(r){const t=Object.create(null),e=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=e.exec(r);)t[n[1]]=n[2];return t}const gv=r=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(r.trim());function Ar(r,t,e,n,i){if(x.isFunction(n))return n.call(this,t,e);if(i&&(t=e),!!x.isString(t)){if(x.isString(n))return t.indexOf(n)!==-1;if(x.isRegExp(n))return n.test(t)}}function vv(r){return r.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,e,n)=>e.toUpperCase()+n)}function mv(r,t){const e=x.toCamelCase(" "+t);["get","set","has"].forEach(n=>{Object.defineProperty(r,n+e,{value:function(i,s,o){return this[n].call(this,t,i,s,o)},configurable:!0})})}let ct=class{constructor(t){t&&this.set(t)}set(t,e,n){const i=this;function s(u,l,a){const c=de(l);if(!c)throw new Error("header name must be a non-empty string");const f=x.findKey(i,c);(!f||i[f]===void 0||a===!0||a===void 0&&i[f]!==!1)&&(i[f||l]=Ve(u))}const o=(u,l)=>x.forEach(u,(a,c)=>s(a,c,l));if(x.isPlainObject(t)||t instanceof this.constructor)o(t,e);else if(x.isString(t)&&(t=t.trim())&&!gv(t))o(pv(t),e);else if(x.isObject(t)&&x.isIterable(t)){let u={},l,a;for(const c of t){if(!x.isArray(c))throw TypeError("Object iterator must return a key-value pair");u[a=c[0]]=(l=u[a])?x.isArray(l)?[...l,c[1]]:[l,c[1]]:c[1]}o(u,e)}else t!=null&&s(e,t,n);return this}get(t,e){if(t=de(t),t){const n=x.findKey(this,t);if(n){const i=this[n];if(!e)return i;if(e===!0)return dv(i);if(x.isFunction(e))return e.call(this,i,n);if(x.isRegExp(e))return e.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,e){if(t=de(t),t){const n=x.findKey(this,t);return!!(n&&this[n]!==void 0&&(!e||Ar(this,this[n],n,e)))}return!1}delete(t,e){const n=this;let i=!1;function s(o){if(o=de(o),o){const u=x.findKey(n,o);u&&(!e||Ar(n,n[u],u,e))&&(delete n[u],i=!0)}}return x.isArray(t)?t.forEach(s):s(t),i}clear(t){const e=Object.keys(this);let n=e.length,i=!1;for(;n--;){const s=e[n];(!t||Ar(this,this[s],s,t,!0))&&(delete this[s],i=!0)}return i}normalize(t){const e=this,n={};return x.forEach(this,(i,s)=>{const o=x.findKey(n,s);if(o){e[o]=Ve(i),delete e[s];return}const u=t?vv(s):String(s).trim();u!==s&&delete e[s],e[u]=Ve(i),n[u]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const e=Object.create(null);return x.forEach(this,(n,i)=>{n!=null&&n!==!1&&(e[i]=t&&x.isArray(n)?n.join(", "):n)}),e}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,e])=>t+": "+e).join(`
53
53
  `)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...e){const n=new this(t);return e.forEach(i=>n.set(i)),n}static accessor(t){const e=(this[Ui]=this[Ui]={accessors:{}}).accessors,n=this.prototype;function i(s){const o=de(s);e[o]||(mv(n,s),e[o]=!0)}return x.isArray(t)?t.forEach(i):i(t),this}};ct.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);x.reduceDescriptors(ct.prototype,({value:r},t)=>{let e=t[0].toUpperCase()+t.slice(1);return{get:()=>r,set(n){this[e]=n}}});x.freezeMethods(ct);function Or(r,t){const e=this||Ae,n=t||e,i=ct.from(n.headers);let s=n.data;return x.forEach(r,function(o){s=o.call(e,s,i.normalize(),t?t.status:void 0)}),i.normalize(),s}function Mo(r){return!!(r&&r.__CANCEL__)}let Oe=class extends W{constructor(t,e,n){super(t!=null?t:"canceled",W.ERR_CANCELED,e,n),this.name="CanceledError",this.__CANCEL__=!0}};function Fo(r,t,e){const n=e.config.validateStatus;!e.status||!n||n(e.status)?r(e):t(new W("Request failed with status code "+e.status,[W.ERR_BAD_REQUEST,W.ERR_BAD_RESPONSE][Math.floor(e.status/100)-4],e.config,e.request,e))}function yv(r){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(r);return t&&t[1]||""}function bv(r,t){r=r||10;const e=new Array(r),n=new Array(r);let i=0,s=0,o;return t=t!==void 0?t:1e3,function(u){const l=Date.now(),a=n[s];o||(o=l),e[i]=u,n[i]=l;let c=s,f=0;for(;c!==i;)f+=e[c++],c=c%r;if(i=(i+1)%r,i===s&&(s=(s+1)%r),l-o<t)return;const h=a&&l-a;return h?Math.round(f*1e3/h):void 0}}function _v(r,t){let e=0,n=1e3/t,i,s;const o=(u,l=Date.now())=>{e=l,i=null,s&&(clearTimeout(s),s=null),r(...u)};return[(...u)=>{const l=Date.now(),a=l-e;a>=n?o(u,l):(i=u,s||(s=setTimeout(()=>{s=null,o(i)},n-a)))},()=>i&&o(i)]}const Qe=(r,t,e=3)=>{let n=0;const i=bv(50,250);return _v(s=>{const o=s.loaded,u=s.lengthComputable?s.total:void 0,l=o-n,a=i(l),c=o<=u;n=o;const f={loaded:o,total:u,progress:u?o/u:void 0,bytes:l,rate:a||void 0,estimated:a&&u&&c?(u-o)/a:void 0,event:s,lengthComputable:u!=null,[t?"download":"upload"]:!0};r(f)},e)},Li=(r,t)=>{const e=r!=null;return[n=>t[0]({lengthComputable:e,total:r,loaded:n}),t[1]]},ki=r=>(...t)=>x.asap(()=>r(...t)),wv=nt.hasStandardBrowserEnv?((r,t)=>e=>(e=new URL(e,nt.origin),r.protocol===e.protocol&&r.host===e.host&&(t||r.port===e.port)))(new URL(nt.origin),nt.navigator&&/(msie|trident)/i.test(nt.navigator.userAgent)):()=>!0,Ev=nt.hasStandardBrowserEnv?{write(r,t,e,n,i,s,o){if(typeof document>"u")return;const u=[`${r}=${encodeURIComponent(t)}`];x.isNumber(e)&&u.push(`expires=${new Date(e).toUTCString()}`),x.isString(n)&&u.push(`path=${n}`),x.isString(i)&&u.push(`domain=${i}`),s===!0&&u.push("secure"),x.isString(o)&&u.push(`SameSite=${o}`),document.cookie=u.join("; ")},read(r){if(typeof document>"u")return null;const t=document.cookie.match(new RegExp("(?:^|; )"+r+"=([^;]*)"));return t?decodeURIComponent(t[1]):null},remove(r){this.write(r,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function Sv(r){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(r)}function Tv(r,t){return t?r.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):r}function Uo(r,t,e){let n=!Sv(t);return r&&(n||e==!1)?Tv(r,t):t}const Hi=r=>r instanceof ct?H({},r):r;function zt(r,t){t=t||{};const e={};function n(a,c,f,h){return x.isPlainObject(a)&&x.isPlainObject(c)?x.merge.call({caseless:h},a,c):x.isPlainObject(c)?x.merge({},c):x.isArray(c)?c.slice():c}function i(a,c,f,h){if(x.isUndefined(c)){if(!x.isUndefined(a))return n(void 0,a,f,h)}else return n(a,c,f,h)}function s(a,c){if(!x.isUndefined(c))return n(void 0,c)}function o(a,c){if(x.isUndefined(c)){if(!x.isUndefined(a))return n(void 0,a)}else return n(void 0,c)}function u(a,c,f){if(f in t)return n(a,c);if(f in r)return n(void 0,a)}const l={url:s,method:s,data:s,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,withXSRFToken: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:u,headers:(a,c,f)=>i(Hi(a),Hi(c),f,!0)};return x.forEach(Object.keys(H(H({},r),t)),function(a){const c=l[a]||i,f=c(r[a],t[a],a);x.isUndefined(f)&&c!==u||(e[a]=f)}),e}const Lo=r=>{const t=zt({},r);let{data:e,withXSRFToken:n,xsrfHeaderName:i,xsrfCookieName:s,headers:o,auth:u}=t;if(t.headers=o=ct.from(o),t.url=Po(Uo(t.baseURL,t.url,t.allowAbsoluteUrls),r.params,r.paramsSerializer),u&&o.set("Authorization","Basic "+btoa((u.username||"")+":"+(u.password?unescape(encodeURIComponent(u.password)):""))),x.isFormData(e)){if(nt.hasStandardBrowserEnv||nt.hasStandardBrowserWebWorkerEnv)o.setContentType(void 0);else if(x.isFunction(e.getHeaders)){const l=e.getHeaders(),a=["content-type","content-length"];Object.entries(l).forEach(([c,f])=>{a.includes(c.toLowerCase())&&o.set(c,f)})}}if(nt.hasStandardBrowserEnv&&(n&&x.isFunction(n)&&(n=n(t)),n||n!==!1&&wv(t.url))){const l=i&&s&&Ev.read(s);l&&o.set(i,l)}return t},Rv=typeof XMLHttpRequest<"u",xv=Rv&&function(r){return new Promise(function(t,e){const n=Lo(r);let i=n.data;const s=ct.from(n.headers).normalize();let{responseType:o,onUploadProgress:u,onDownloadProgress:l}=n,a,c,f,h,p;function d(){h&&h(),p&&p(),n.cancelToken&&n.cancelToken.unsubscribe(a),n.signal&&n.signal.removeEventListener("abort",a)}let g=new XMLHttpRequest;g.open(n.method.toUpperCase(),n.url,!0),g.timeout=n.timeout;function b(){if(!g)return;const m=ct.from("getAllResponseHeaders"in g&&g.getAllResponseHeaders()),y={data:!o||o==="text"||o==="json"?g.responseText:g.response,status:g.status,statusText:g.statusText,headers:m,config:r,request:g};Fo(function(_){t(_),d()},function(_){e(_),d()},y),g=null}"onloadend"in g?g.onloadend=b:g.onreadystatechange=function(){!g||g.readyState!==4||g.status===0&&!(g.responseURL&&g.responseURL.indexOf("file:")===0)||setTimeout(b)},g.onabort=function(){g&&(e(new W("Request aborted",W.ECONNABORTED,r,g)),g=null)},g.onerror=function(m){const y=m&&m.message?m.message:"Network Error",_=new W(y,W.ERR_NETWORK,r,g);_.event=m||null,e(_),g=null},g.ontimeout=function(){let m=n.timeout?"timeout of "+n.timeout+"ms exceeded":"timeout exceeded";const y=n.transitional||No;n.timeoutErrorMessage&&(m=n.timeoutErrorMessage),e(new W(m,y.clarifyTimeoutError?W.ETIMEDOUT:W.ECONNABORTED,r,g)),g=null},i===void 0&&s.setContentType(null),"setRequestHeader"in g&&x.forEach(s.toJSON(),function(m,y){g.setRequestHeader(y,m)}),x.isUndefined(n.withCredentials)||(g.withCredentials=!!n.withCredentials),o&&o!=="json"&&(g.responseType=n.responseType),l&&([f,p]=Qe(l,!0),g.addEventListener("progress",f)),u&&g.upload&&([c,h]=Qe(u),g.upload.addEventListener("progress",c),g.upload.addEventListener("loadend",h)),(n.cancelToken||n.signal)&&(a=m=>{g&&(e(!m||m.type?new Oe(null,r,g):m),g.abort(),g=null)},n.cancelToken&&n.cancelToken.subscribe(a),n.signal&&(n.signal.aborted?a():n.signal.addEventListener("abort",a)));const w=yv(n.url);if(w&&nt.protocols.indexOf(w)===-1){e(new W("Unsupported protocol "+w+":",W.ERR_BAD_REQUEST,r));return}g.send(i||null)})},Av=(r,t)=>{const{length:e}=r=r?r.filter(Boolean):[];if(t||e){let n=new AbortController,i;const s=function(a){if(!i){i=!0,u();const c=a instanceof Error?a:this.reason;n.abort(c instanceof W?c:new Oe(c instanceof Error?c.message:c))}};let o=t&&setTimeout(()=>{o=null,s(new W(`timeout of ${t}ms exceeded`,W.ETIMEDOUT))},t);const u=()=>{r&&(o&&clearTimeout(o),o=null,r.forEach(a=>{a.unsubscribe?a.unsubscribe(s):a.removeEventListener("abort",s)}),r=null)};r.forEach(a=>a.addEventListener("abort",s));const{signal:l}=n;return l.unsubscribe=()=>x.asap(u),l}},Ov=function*(r,t){let e=r.byteLength;if(e<t){yield r;return}let n=0,i;for(;n<e;)i=n+t,yield r.slice(n,i),n=i},$v=function(r,t){return pr(this,null,function*(){try{for(var e=Dn(Dv(r)),n,i,s;n=!(i=yield new Mt(e.next())).done;n=!1){const o=i.value;yield*dr(Ov(o,t))}}catch(i){s=[i]}finally{try{n&&(i=e.return)&&(yield new Mt(i.call(e)))}finally{if(s)throw s[0]}}})},Dv=function(r){return pr(this,null,function*(){if(r[Symbol.asyncIterator]){yield*dr(r);return}const t=r.getReader();try{for(;;){const{done:e,value:n}=yield new Mt(t.read());if(e)break;yield n}}finally{yield new Mt(t.cancel())}})},Vi=(r,t,e,n)=>{const i=$v(r,t);let s=0,o,u=a=>{o||(o=!0,n&&n(a))};return new ReadableStream({pull(a){return U(this,null,function*(){try{const{done:c,value:f}=yield i.next();if(c){u(),a.close();return}let h=f.byteLength;if(e){let p=s+=h;e(p)}a.enqueue(new Uint8Array(f))}catch(c){throw u(c),c}})},cancel(a){return u(a),i.return()}},{highWaterMark:2})},qi=64*1024,{isFunction:Me}=x,Cv=(({Request:r,Response:t})=>({Request:r,Response:t}))(x.global),{ReadableStream:zi,TextEncoder:Wi}=x.global,Ki=(r,...t)=>{try{return!!r(...t)}catch(e){return!1}},Bv=r=>{r=x.merge.call({skipUndefined:!0},Cv,r);const{fetch:t,Request:e,Response:n}=r,i=t?Me(t):typeof fetch=="function",s=Me(e),o=Me(n);if(!i)return!1;const u=i&&Me(zi),l=i&&(typeof Wi=="function"?(d=>g=>d.encode(g))(new Wi):d=>U(null,null,function*(){return new Uint8Array(yield new e(d).arrayBuffer())})),a=s&&u&&Ki(()=>{let d=!1;const g=new e(nt.origin,{body:new zi,method:"POST",get duplex(){return d=!0,"half"}}).headers.has("Content-Type");return d&&!g}),c=o&&u&&Ki(()=>x.isReadableStream(new n("").body)),f={stream:c&&(d=>d.body)};i&&["text","arrayBuffer","blob","formData","stream"].forEach(d=>{!f[d]&&(f[d]=(g,b)=>{let w=g&&g[d];if(w)return w.call(g);throw new W(`Response type '${d}' is not supported`,W.ERR_NOT_SUPPORT,b)})});const h=d=>U(null,null,function*(){if(d==null)return 0;if(x.isBlob(d))return d.size;if(x.isSpecCompliantForm(d))return(yield new e(nt.origin,{method:"POST",body:d}).arrayBuffer()).byteLength;if(x.isArrayBufferView(d)||x.isArrayBuffer(d))return d.byteLength;if(x.isURLSearchParams(d)&&(d=d+""),x.isString(d))return(yield l(d)).byteLength}),p=(d,g)=>U(null,null,function*(){const b=x.toFiniteNumber(d.getContentLength());return b!=null?b:h(g)});return d=>U(null,null,function*(){let{url:g,method:b,data:w,signal:m,cancelToken:y,timeout:_,onDownloadProgress:S,onUploadProgress:v,responseType:T,headers:A,withCredentials:L="same-origin",fetchOptions:E}=Lo(d),R=t||fetch;T=T?(T+"").toLowerCase():"text";let M=Av([m,y&&y.toAbortSignal()],_),C=null;const I=M&&M.unsubscribe&&(()=>{M.unsubscribe()});let j;try{if(v&&a&&b!=="get"&&b!=="head"&&(j=yield p(A,w))!==0){let O=new e(g,{method:"POST",body:w,duplex:"half"}),D;if(x.isFormData(w)&&(D=O.headers.get("content-type"))&&A.setContentType(D),O.body){const[P,N]=Li(j,Qe(ki(v)));w=Vi(O.body,qi,P,N)}}x.isString(L)||(L=L?"include":"omit");const $=s&&"credentials"in e.prototype,k=et(H({},E),{signal:M,method:b.toUpperCase(),headers:A.normalize().toJSON(),body:w,duplex:"half",credentials:$?L:void 0});C=s&&new e(g,k);let F=yield s?R(C,E):R(g,k);const V=c&&(T==="stream"||T==="response");if(c&&(S||V&&I)){const O={};["status","statusText","headers"].forEach(it=>{O[it]=F[it]});const D=x.toFiniteNumber(F.headers.get("content-length")),[P,N]=S&&Li(D,Qe(ki(S),!0))||[];F=new n(Vi(F.body,qi,P,()=>{N&&N(),I&&I()}),O)}T=T||"text";let z=yield f[x.findKey(f,T)||"text"](F,d);return!V&&I&&I(),yield new Promise((O,D)=>{Fo(O,D,{data:z,headers:ct.from(F.headers),status:F.status,statusText:F.statusText,config:d,request:C})})}catch($){throw I&&I(),$&&$.name==="TypeError"&&/Load failed|fetch/i.test($.message)?Object.assign(new W("Network Error",W.ERR_NETWORK,d,C),{cause:$.cause||$}):W.from($,$&&$.code,d,C)}})},jv=new Map,ko=r=>{let t=r&&r.env||{};const{fetch:e,Request:n,Response:i}=t,s=[n,i,e];let o=s.length,u=o,l,a,c=jv;for(;u--;)l=s[u],a=c.get(l),a===void 0&&c.set(l,a=u?new Map:Bv(t)),c=a;return a};ko();const xn={http:Yg,xhr:xv,fetch:{get:ko}};x.forEach(xn,(r,t)=>{if(r){try{Object.defineProperty(r,"name",{value:t})}catch(e){}Object.defineProperty(r,"adapterName",{value:t})}});const Ji=r=>`- ${r}`,Pv=r=>x.isFunction(r)||r===null||r===!1;function Nv(r,t){r=x.isArray(r)?r:[r];const{length:e}=r;let n,i;const s={};for(let o=0;o<e;o++){n=r[o];let u;if(i=n,!Pv(n)&&(i=xn[(u=String(n)).toLowerCase()],i===void 0))throw new W(`Unknown adapter '${u}'`);if(i&&(x.isFunction(i)||(i=i.get(t))))break;s[u||"#"+o]=i}if(!i){const o=Object.entries(s).map(([l,a])=>`adapter ${l} `+(a===!1?"is not supported by the environment":"is not available in the build"));let u=e?o.length>1?`since :
54
54
  `+o.map(Ji).join(`
55
55
  `):" "+Ji(o[0]):"as no adapter specified";throw new W("There is no suitable adapter to dispatch the request "+u,"ERR_NOT_SUPPORT")}return i}const Ho={getAdapter:Nv,adapters:xn};function $r(r){if(r.cancelToken&&r.cancelToken.throwIfRequested(),r.signal&&r.signal.aborted)throw new Oe(null,r)}function Gi(r){return $r(r),r.headers=ct.from(r.headers),r.data=Or.call(r,r.transformRequest),["post","put","patch"].indexOf(r.method)!==-1&&r.headers.setContentType("application/x-www-form-urlencoded",!1),Ho.getAdapter(r.adapter||Ae.adapter,r)(r).then(function(t){return $r(r),t.data=Or.call(r,r.transformResponse,t),t.headers=ct.from(t.headers),t},function(t){return Mo(t)||($r(r),t&&t.response&&(t.response.data=Or.call(r,r.transformResponse,t.response),t.response.headers=ct.from(t.response.headers))),Promise.reject(t)})}const Vo="1.13.4",ur={};["object","boolean","number","function","string","symbol"].forEach((r,t)=>{ur[r]=function(e){return typeof e===r||"a"+(t<1?"n ":" ")+r}});const Yi={};ur.transitional=function(r,t,e){function n(i,s){return"[Axios v"+Vo+"] Transitional option '"+i+"'"+s+(e?". "+e:"")}return(i,s,o)=>{if(r===!1)throw new W(n(s," has been removed"+(t?" in "+t:"")),W.ERR_DEPRECATED);return t&&!Yi[s]&&(Yi[s]=!0,console.warn(n(s," has been deprecated since v"+t+" and will be removed in the near future"))),r?r(i,s,o):!0}};ur.spelling=function(r){return(t,e)=>(console.warn(`${e} is likely a misspelling of ${r}`),!0)};function Iv(r,t,e){if(typeof r!="object")throw new W("options must be an object",W.ERR_BAD_OPTION_VALUE);const n=Object.keys(r);let i=n.length;for(;i-- >0;){const s=n[i],o=t[s];if(o){const u=r[s],l=u===void 0||o(u,s,r);if(l!==!0)throw new W("option "+s+" must be "+l,W.ERR_BAD_OPTION_VALUE);continue}if(e!==!0)throw new W("Unknown option "+s,W.ERR_BAD_OPTION)}}const qe={assertOptions:Iv,validators:ur},bt=qe.validators;let kt=class{constructor(t){this.defaults=t||{},this.interceptors={request:new Fi,response:new Fi}}request(t,e){return U(this,null,function*(){try{return yield this._request(t,e)}catch(n){if(n instanceof Error){let i={};Error.captureStackTrace?Error.captureStackTrace(i):i=new Error;const s=i.stack?i.stack.replace(/^.+\n/,""):"";try{n.stack?s&&!String(n.stack).endsWith(s.replace(/^.+\n.+\n/,""))&&(n.stack+=`
56
- `+s):n.stack=s}catch(o){}}throw n}})}_request(t,e){typeof t=="string"?(e=e||{},e.url=t):e=t||{},e=zt(this.defaults,e);const{transitional:n,paramsSerializer:i,headers:s}=e;n!==void 0&&qe.assertOptions(n,{silentJSONParsing:bt.transitional(bt.boolean),forcedJSONParsing:bt.transitional(bt.boolean),clarifyTimeoutError:bt.transitional(bt.boolean)},!1),i!=null&&(x.isFunction(i)?e.paramsSerializer={serialize:i}:qe.assertOptions(i,{encode:bt.function,serialize:bt.function},!0)),e.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?e.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:e.allowAbsoluteUrls=!0),qe.assertOptions(e,{baseUrl:bt.spelling("baseURL"),withXsrfToken:bt.spelling("withXSRFToken")},!0),e.method=(e.method||this.defaults.method||"get").toLowerCase();let o=s&&x.merge(s.common,s[e.method]);s&&x.forEach(["delete","get","head","post","put","patch","common"],d=>{delete s[d]}),e.headers=ct.concat(o,s);const u=[];let l=!0;this.interceptors.request.forEach(function(d){typeof d.runWhen=="function"&&d.runWhen(e)===!1||(l=l&&d.synchronous,u.unshift(d.fulfilled,d.rejected))});const a=[];this.interceptors.response.forEach(function(d){a.push(d.fulfilled,d.rejected)});let c,f=0,h;if(!l){const d=[Gi.bind(this),void 0];for(d.unshift(...u),d.push(...a),h=d.length,c=Promise.resolve(e);f<h;)c=c.then(d[f++],d[f++]);return c}h=u.length;let p=e;for(;f<h;){const d=u[f++],g=u[f++];try{p=d(p)}catch(b){g.call(this,b);break}}try{c=Gi.call(this,p)}catch(d){return Promise.reject(d)}for(f=0,h=a.length;f<h;)c=c.then(a[f++],a[f++]);return c}getUri(t){t=zt(this.defaults,t);const e=Uo(t.baseURL,t.url,t.allowAbsoluteUrls);return Po(e,t.params,t.paramsSerializer)}};x.forEach(["delete","get","head","options"],function(r){kt.prototype[r]=function(t,e){return this.request(zt(e||{},{method:r,url:t,data:(e||{}).data}))}});x.forEach(["post","put","patch"],function(r){function t(e){return function(n,i,s){return this.request(zt(s||{},{method:r,headers:e?{"Content-Type":"multipart/form-data"}:{},url:n,data:i}))}}kt.prototype[r]=t(),kt.prototype[r+"Form"]=t(!0)});let Mv=class qo{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let e;this.promise=new Promise(function(i){e=i});const n=this;this.promise.then(i=>{if(!n._listeners)return;let s=n._listeners.length;for(;s-- >0;)n._listeners[s](i);n._listeners=null}),this.promise.then=i=>{let s;const o=new Promise(u=>{n.subscribe(u),s=u}).then(i);return o.cancel=function(){n.unsubscribe(s)},o},t(function(i,s,o){n.reason||(n.reason=new Oe(i,s,o),e(n.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 e=this._listeners.indexOf(t);e!==-1&&this._listeners.splice(e,1)}toAbortSignal(){const t=new AbortController,e=n=>{t.abort(n)};return this.subscribe(e),t.signal.unsubscribe=()=>this.unsubscribe(e),t.signal}static source(){let t;return{token:new qo(function(e){t=e}),cancel:t}}};function Fv(r){return function(t){return r.apply(null,t)}}function Uv(r){return x.isObject(r)&&r.isAxiosError===!0}const Xr={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,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(Xr).forEach(([r,t])=>{Xr[t]=r});function zo(r){const t=new kt(r),e=So(kt.prototype.request,t);return x.extend(e,kt.prototype,t,{allOwnKeys:!0}),x.extend(e,t,null,{allOwnKeys:!0}),e.create=function(n){return zo(zt(r,n))},e}const Q=zo(Ae);Q.Axios=kt;Q.CanceledError=Oe;Q.CancelToken=Mv;Q.isCancel=Mo;Q.VERSION=Vo;Q.toFormData=ar;Q.AxiosError=W;Q.Cancel=Q.CanceledError;Q.all=function(r){return Promise.all(r)};Q.spread=Fv;Q.isAxiosError=Uv;Q.mergeConfig=zt;Q.AxiosHeaders=ct;Q.formToJSON=r=>Io(x.isHTMLForm(r)?new FormData(r):r);Q.getAdapter=Ho.getAdapter;Q.HttpStatusCode=Xr;Q.default=Q;const{Axios:S0,AxiosError:T0,CanceledError:R0,isCancel:x0,CancelToken:A0,VERSION:O0,all:$0,Cancel:D0,isAxiosError:C0,spread:B0,toFormData:j0,AxiosHeaders:P0,HttpStatusCode:N0,formToJSON:I0,getAdapter:M0,mergeConfig:F0}=Q,Lv={form:"application/x-www-form-urlencoded",json:"application/json",data:"multipart/form-data"},kv=["put","post","patch"],Zi="Local-Request-Id",Hv=100,Vv=300;class qv{constructor(t={}){lt(this,"axios"),lt(this,"settings"),lt(this,"records",{}),lt(this,"isLoading",!1),lt(this,"stopSkipWarn"),lt(this,"showLoading"),lt(this,"showError"),this.settings=Object.assign({type:"form"},t.settings||{});const e=xr(t,["settings","query"]);this.axios=Q.create(ge({headers:{"Content-Type":"application/x-www-form-urlencoded"},timeout:120*1e3},e)),this.setupSkipWarn(this.settings),this.showLoading=bn(this.openLoading.bind(this),Hv),this.showError=Kp(this._showError.bind(this),Vv,{leading:!0,trailing:!1})}setConfig(t={}){this.settings=ge(this.settings,t.settings||{});const e=xr(t,["settings","query"]);this.axios.defaults=ge(this.axios.defaults,e),this.setupSkipWarn(this.settings)}cancel(t,e="请求已取消"){if(t){const n=this.records[t];if(!n)return;n.source.cancel(e)}else for(const n of Object.values(this.records))n.source.cancel(e)}createHeaders(t,e,n){const i=e.injectHeaders?typeof e.headers=="function"?e.headers(t,n,e):e.headers||{}:{},s=H(H({"Content-Type":Lv[e.type||"form"]},n.headers),i);return e.skipWarn&&(s[Zi]=t),s}isJsonType(t){return Object.entries(t).some(([e,n])=>e.toLowerCase()==="content-type"&&String(n).includes("application/json"))}toFormData(t,e="data"){if(t instanceof FormData||t instanceof URLSearchParams)return t;const n=e==="data"?new FormData:new URLSearchParams;return Object.entries(t).forEach(([i,s])=>{n.append(i,s)}),n}createSendData(t,e,n,i,s={}){const{type:o,skipWarn:u}=t,{name:l="skipWarn"}=u||{};let{data:a,params:c={},method:f="get"}=e;const h=i?{[l]:!0}:{};return kv.includes(f.toLowerCase())?(a=Object.assign(a||{},h),a=o!=="json"||!this.isJsonType(n)?this.toFormData(a,o):a,c=H({},s)):o==="form"?c=H(H(H({},a||{}),s),h):(a&&(o!=="json"||!this.isJsonType(n))&&(a=this.toFormData(a,o)),c=H(H({},s),h)),{data:a,params:c}}createUrl(t){let{url:e,params:n}=t;if(e){let i=Ye(e)?new URL(e).origin:"";const s=i?e.replace(i,""):e;try{const o=Jd(s,{encode:encodeURIComponent});return i+o(n||{})}catch(o){console.warn("createUrl","pathToRegexpCompile error",e)}}return e}openLoading(t){const{loading:e,showLoading:n}=t;e&&n&&Object.keys(this.records).length>0&&(this.isLoading=!0,n())}closeLoading(t){const{loading:e,hideLoading:n}=t;if(!e)return;this.isLoading=!1;const i=Object.keys(this.records);n&&i.length===0&&(this.isLoading=!1,n())}_showError(t,e){var s;const{failMessage:n,showError:i}=t;if(n&&i){const o=(s=e==null?void 0:e.response)==null?void 0:s.data,u=(o==null?void 0:o.message)||(o==null?void 0:o.msg)||(e==null?void 0:e.message)||(e==null?void 0:e.msg)||"未知错误";i(u,e)}}validResponse(t,e){const{validSuccess:n,validate:i}=t;return n&&i?!!i(e):!0}isSkipWarnResponse(t){return!!t.promise}send(t={},e=!1){const n=ge({},this.settings,t.settings||{}),i=t.query||{},s=xr(t,["settings","query"]),o=Vd(!1),u=Q.CancelToken.source();this.records[o]={settings:n,config:s,source:u};const l=this.createUrl(s),a=this.createHeaders(o,n,s),{data:c,params:f}=this.createSendData(n,s,a,e,i);return this.showLoading(n),new Promise((h,p)=>{this.axios(et(H({cancelToken:u.token},s),{url:l,headers:a,data:c,params:f})).then(d=>{var g;return this.isSkipWarnResponse(d)?h(d.promise):this.validResponse(n,d)?h(n.originResponse?d:(g=d.data)==null?void 0:g.data):(this.showError(n,d.data),p(d.data))}).catch(d=>(this.showError(n,d),p(d))).finally(()=>{delete this.records[o],this.closeLoading(n)})})}useResponse(t,e){const{response:n}=this.axios.interceptors,i=n.use(t,e);return()=>n.eject(i)}useRequest(t,e){const{request:n}=this.axios.interceptors,i=n.use(t,e);return()=>n.eject(i)}setupSkipWarn(t){if(this.stopSkipWarn&&(this.stopSkipWarn(),this.stopSkipWarn=void 0),!t.skipWarn)return;const{code:e,executor:n,callback:i,complete:s}=t.skipWarn;this.stopSkipWarn=this.useResponse(o=>{const u=(o.config.headers||{})[Zi],l=this.records[u];if(!l)return o;const{data:a}=o;if(!a||typeof a!="object")return o;if((a==null?void 0:a.code)===e){i&&i(o);const c=new Promise(n).then(()=>this.send(et(H({},l.config),{settings:l.settings}),!0));c.catch(f=>f).finally(()=>{s&&s()}),o.promise=c}return o})}}function An(r={}){const t=new qv(r),e=t.send.bind(t),n=t.cancel.bind(t),i=t.setConfig.bind(t),s=t.useRequest.bind(t),o=t.useResponse.bind(t);return Object.assign(e,et(H({},t),{instance:t,send:e,cancel:n,setConfig:i,useRequest:s,useResponse:o}))}const tn=An({settings:{injectHeaders:!0,loading:!0,originResponse:!0}}),en=typeof window<"u";function zv(r){const t={};return r?(r.forEach((e,n)=>{t[n]=typeof e=="string"?decodeURIComponent(e):e}),t):{}}class Wo{constructor(t={}){lt(this,"options",{type:"cache",expired:0,prefix:"__VTJ_"}),lt(this,"caches",{}),lt(this,"types"),this.types={local:en?window.localStorage:this.caches,session:en?window.sessionStorage:this.caches,cache:this.caches},this.config(t)}config(t={}){this.options=Object.assign(this.options,t)}save(t,e,n={}){const{type:i,expired:s,prefix:o}=H(H({},this.options),n),u=Date.now(),l=o+t,a=this.types[i]||this.caches,c={value:e,timestamp:u,expired:s};a===this.caches?a[l]=c:a.setItem(l,JSON.stringify(c))}get(t,e={}){const{type:n,prefix:i}=H(H({},this.options),e),s=i+t,o=this.types[n]||this.caches;let u;if(o===this.caches)u=o[s];else{const f=o.getItem(s);if(f)try{u=JSON.parse(f)}catch(h){console.warn("[Storage] JSON.parse",h)}}if(!u)return null;const{value:l,timestamp:a,expired:c}=u;return c>0&&a+c<Date.now()?(this.remove(t,e),null):l}remove(t,e={}){const{type:n,prefix:i}=H(H({},this.options),e),s=this.types[n]||this.caches,o=i+t;s===this.caches?delete s[o]:s.removeItem(o)}clear(t={}){const{type:e}=H(H({},this.options),t),n=this.types[e]||this.caches;n===this.caches?this.caches={}:n.clear()}}const Dr=new Wo;function Ko(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}var ze={exports:{}},Wv=ze.exports,Qi;function Kv(){return Qi||(Qi=1,(function(r,t){(function(e,n){n(t,r)})(Wv,function(e,n){var i={timeout:5e3,jsonpCallback:"callback"};function s(){return"jsonp_"+Date.now()+"_"+Math.ceil(Math.random()*1e5)}function o(a){try{delete window[a]}catch(c){window[a]=void 0}}function u(a){var c=document.getElementById(a);c&&document.getElementsByTagName("head")[0].removeChild(c)}function l(a){var c=arguments.length<=1||arguments[1]===void 0?{}:arguments[1],f=a,h=c.timeout||i.timeout,p=c.jsonpCallback||i.jsonpCallback,d=void 0;return new Promise(function(g,b){var w=c.jsonpCallbackFunction||s(),m=p+"_"+w;window[w]=function(_){g({ok:!0,json:function(){return Promise.resolve(_)}}),d&&clearTimeout(d),u(m),o(w)},f+=f.indexOf("?")===-1?"?":"&";var y=document.createElement("script");y.setAttribute("src",""+f+p+"="+w),c.charset&&y.setAttribute("charset",c.charset),c.nonce&&y.setAttribute("nonce",c.nonce),c.referrerPolicy&&y.setAttribute("referrerPolicy",c.referrerPolicy),c.crossorigin&&y.setAttribute("crossorigin","true"),y.id=m,document.getElementsByTagName("head")[0].appendChild(y),d=setTimeout(function(){b(new Error("JSONP request to "+a+" timed out")),o(w),u(m),window[w]=function(){o(w)}},h),y.onerror=function(){b(new Error("JSONP request to "+a+" failed")),o(w),u(m),d&&clearTimeout(d)}})}n.exports=l})})(ze,ze.exports)),ze.exports}var Jv=Kv();const Gv=Ko(Jv);function Yv(r){if(en){const{protocol:t,host:e,pathname:n}=location;return`${t}//${e}${r?n:""}`}else return null}function Zv(r=""){const t=r.match(mo);return t?t[0]:""}function Jo(r){const t=[];for(const e in r)Object.prototype.hasOwnProperty.call(r,e)&&t.push([e,encodeURIComponent(r[e])].join("="));return t.join("&")}function rn(r,t,e){const n={};r=(r||location.search).replace(/^[^]*\?/,""),t=t||"&",e=e||"=";let i;const s=new RegExp("(?:^|\\"+t+")([^\\"+e+"\\"+t+"]+)(?:\\"+e+"([^\\"+t+"]*))?","g");for(;(i=s.exec(r))!==null;)i[1]!==r&&(n[decodeURIComponent(i[1])]=decodeURIComponent(i[2]||""));return n}function Go(r,t){t=typeof t=="string"?rn(t):t;const e=r.split("?")[0],n=rn(r),i=Object.assign({},n,t),s=Jo(i);return s?[e,s].join("?"):r}const We=Object.freeze(Object.defineProperty({__proto__:null,append:Go,getCurrentHost:Yv,getHost:Zv,parse:rn,stringify:Jo},Symbol.toStringTag,{value:"Module"}));function Yo(e){return U(this,arguments,function*(r,t={}){const{query:n={}}=t;r.includes("${")&&(r=zp(r)(n||{}));const i=Go(r,n);return yield(yield Gv(i,t)).json()})}var Cr,Xi;function Qv(){if(Xi)return Cr;Xi=1,Cr=function(n,i,s){var o=document.head||document.getElementsByTagName("head")[0],u=document.createElement("script");typeof i=="function"&&(s=i,i={}),i=i||{},s=s||function(){},u.type=i.type||"text/javascript",u.charset=i.charset||"utf8",u.async="async"in i?!!i.async:!0,u.src=n,i.attrs&&r(u,i.attrs),i.text&&(u.text=""+i.text);var l="onload"in u?t:e;l(u,s),u.onload||t(u,s),o.appendChild(u)};function r(n,i){for(var s in i)n.setAttribute(s,i[s])}function t(n,i){n.onload=function(){this.onerror=this.onload=null,i(null,n)},n.onerror=function(){this.onerror=this.onload=null,i(new Error("Failed to load "+this.src),n)}}function e(n,i){n.onreadystatechange=function(){this.readyState!="complete"&&this.readyState!="loaded"||(this.onreadystatechange=null,i(null,n))}}return Cr}var Xv=Qv();const tm=Ko(Xv);function ts(r,t={}){return new Promise((e,n)=>{const{library:i}=t;tm(r,t,(s,o)=>{s?n(s):e(i?window[i]:void 0)})})}const es={debug:-1,log:0,info:0,warn:1,error:2},em=function(r,t,e,n){return function(...i){if(t&&es[t]<=es[r]&&console[r].apply&&(n==="*"||e.startsWith(n)))return console[r].apply(console,rm(i,e))}};function rm(r,t){return t!=="*"&&(typeof r[0]=="string"?r[0]=`[${t}] ${r[0]}`:r=["["+t+"]"].concat(r)),r}function nm(r,t){if(!r)return{targetLevel:t.level,targetBizName:t.bizName};if(~r.indexOf(":")){const e=r.split(":");return{targetLevel:e[0],targetBizName:e[1]}}return{targetLevel:r,targetBizName:"*"}}const im={level:"warn",bizName:"*"};class sm{constructor(t){lt(this,"config"),lt(this,"options"),this.options=H(H({},im),t);const e=typeof location<"u"?location:{},n=(/__(?:logConf|logLevel)__=([^#/&]*)/.exec(e.href)||[])[1];this.config=nm(n,t)}_log(t){const{targetLevel:e,targetBizName:n}=this.config,{bizName:i}=this.options;return em(t,e,i,n)}debug(...t){return this._log("debug")(...t)}log(...t){return this._log("log")(...t)}info(...t){return this._log("info")(...t)}warn(...t){return this._log("warn")(...t)}error(...t){return this._log("error")(...t)}}function om(r){return new sm(r)}const ie=om({level:"log",bizName:"VTJ"});/*! js-cookie v3.0.5 | MIT */function Fe(r){for(var t=1;t<arguments.length;t++){var e=arguments[t];for(var n in e)r[n]=e[n]}return r}var am={read:function(r){return r[0]==='"'&&(r=r.slice(1,-1)),r.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(r){return encodeURIComponent(r).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}};function nn(r,t){function e(i,s,o){if(!(typeof document>"u")){o=Fe({},t,o),typeof o.expires=="number"&&(o.expires=new Date(Date.now()+o.expires*864e5)),o.expires&&(o.expires=o.expires.toUTCString()),i=encodeURIComponent(i).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var u="";for(var l in o)o[l]&&(u+="; "+l,o[l]!==!0&&(u+="="+o[l].split(";")[0]));return document.cookie=i+"="+r.write(s,i)+u}}function n(i){if(!(typeof document>"u"||arguments.length&&!i)){for(var s=document.cookie?document.cookie.split("; "):[],o={},u=0;u<s.length;u++){var l=s[u].split("="),a=l.slice(1).join("=");try{var c=decodeURIComponent(l[0]);if(o[c]=r.read(a,c),i===c)break}catch(f){}}return i?o[i]:o}}return Object.create({set:e,get:n,remove:function(i,s){e(i,"",Fe({},s,{expires:-1}))},withAttributes:function(i){return nn(this.converter,Fe({},this.attributes,i))},withConverter:function(i){return nn(Fe({},this.converter,i),this.attributes)}},{attributes:{value:Object.freeze(t)},converter:{value:Object.freeze(r)}})}var On=nn(am,{path:"/"});function um(r,t,e){On.set(r,t,e)}function cm(r){return On.get(r)}function lm(r,t){On.remove(r,t)}const Br=Object.freeze(Object.defineProperty({__proto__:null,get:cm,remove:lm,set:um},Symbol.toStringTag,{value:"Module"}));/**!
56
+ `+s):n.stack=s}catch(o){}}throw n}})}_request(t,e){typeof t=="string"?(e=e||{},e.url=t):e=t||{},e=zt(this.defaults,e);const{transitional:n,paramsSerializer:i,headers:s}=e;n!==void 0&&qe.assertOptions(n,{silentJSONParsing:bt.transitional(bt.boolean),forcedJSONParsing:bt.transitional(bt.boolean),clarifyTimeoutError:bt.transitional(bt.boolean)},!1),i!=null&&(x.isFunction(i)?e.paramsSerializer={serialize:i}:qe.assertOptions(i,{encode:bt.function,serialize:bt.function},!0)),e.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?e.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:e.allowAbsoluteUrls=!0),qe.assertOptions(e,{baseUrl:bt.spelling("baseURL"),withXsrfToken:bt.spelling("withXSRFToken")},!0),e.method=(e.method||this.defaults.method||"get").toLowerCase();let o=s&&x.merge(s.common,s[e.method]);s&&x.forEach(["delete","get","head","post","put","patch","common"],d=>{delete s[d]}),e.headers=ct.concat(o,s);const u=[];let l=!0;this.interceptors.request.forEach(function(d){typeof d.runWhen=="function"&&d.runWhen(e)===!1||(l=l&&d.synchronous,u.unshift(d.fulfilled,d.rejected))});const a=[];this.interceptors.response.forEach(function(d){a.push(d.fulfilled,d.rejected)});let c,f=0,h;if(!l){const d=[Gi.bind(this),void 0];for(d.unshift(...u),d.push(...a),h=d.length,c=Promise.resolve(e);f<h;)c=c.then(d[f++],d[f++]);return c}h=u.length;let p=e;for(;f<h;){const d=u[f++],g=u[f++];try{p=d(p)}catch(b){g.call(this,b);break}}try{c=Gi.call(this,p)}catch(d){return Promise.reject(d)}for(f=0,h=a.length;f<h;)c=c.then(a[f++],a[f++]);return c}getUri(t){t=zt(this.defaults,t);const e=Uo(t.baseURL,t.url,t.allowAbsoluteUrls);return Po(e,t.params,t.paramsSerializer)}};x.forEach(["delete","get","head","options"],function(r){kt.prototype[r]=function(t,e){return this.request(zt(e||{},{method:r,url:t,data:(e||{}).data}))}});x.forEach(["post","put","patch"],function(r){function t(e){return function(n,i,s){return this.request(zt(s||{},{method:r,headers:e?{"Content-Type":"multipart/form-data"}:{},url:n,data:i}))}}kt.prototype[r]=t(),kt.prototype[r+"Form"]=t(!0)});let Mv=class qo{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let e;this.promise=new Promise(function(i){e=i});const n=this;this.promise.then(i=>{if(!n._listeners)return;let s=n._listeners.length;for(;s-- >0;)n._listeners[s](i);n._listeners=null}),this.promise.then=i=>{let s;const o=new Promise(u=>{n.subscribe(u),s=u}).then(i);return o.cancel=function(){n.unsubscribe(s)},o},t(function(i,s,o){n.reason||(n.reason=new Oe(i,s,o),e(n.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 e=this._listeners.indexOf(t);e!==-1&&this._listeners.splice(e,1)}toAbortSignal(){const t=new AbortController,e=n=>{t.abort(n)};return this.subscribe(e),t.signal.unsubscribe=()=>this.unsubscribe(e),t.signal}static source(){let t;return{token:new qo(function(e){t=e}),cancel:t}}};function Fv(r){return function(t){return r.apply(null,t)}}function Uv(r){return x.isObject(r)&&r.isAxiosError===!0}const Xr={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,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(Xr).forEach(([r,t])=>{Xr[t]=r});function zo(r){const t=new kt(r),e=So(kt.prototype.request,t);return x.extend(e,kt.prototype,t,{allOwnKeys:!0}),x.extend(e,t,null,{allOwnKeys:!0}),e.create=function(n){return zo(zt(r,n))},e}const Q=zo(Ae);Q.Axios=kt;Q.CanceledError=Oe;Q.CancelToken=Mv;Q.isCancel=Mo;Q.VERSION=Vo;Q.toFormData=ar;Q.AxiosError=W;Q.Cancel=Q.CanceledError;Q.all=function(r){return Promise.all(r)};Q.spread=Fv;Q.isAxiosError=Uv;Q.mergeConfig=zt;Q.AxiosHeaders=ct;Q.formToJSON=r=>Io(x.isHTMLForm(r)?new FormData(r):r);Q.getAdapter=Ho.getAdapter;Q.HttpStatusCode=Xr;Q.default=Q;const{Axios:T0,AxiosError:R0,CanceledError:x0,isCancel:A0,CancelToken:O0,VERSION:$0,all:D0,Cancel:C0,isAxiosError:B0,spread:j0,toFormData:P0,AxiosHeaders:N0,HttpStatusCode:I0,formToJSON:M0,getAdapter:F0,mergeConfig:U0}=Q,Lv={form:"application/x-www-form-urlencoded",json:"application/json",data:"multipart/form-data"},kv=["put","post","patch"],Zi="Local-Request-Id",Hv=100,Vv=300;class qv{constructor(t={}){lt(this,"axios"),lt(this,"settings"),lt(this,"records",{}),lt(this,"isLoading",!1),lt(this,"stopSkipWarn"),lt(this,"showLoading"),lt(this,"showError"),this.settings=Object.assign({type:"form"},t.settings||{});const e=xr(t,["settings","query"]);this.axios=Q.create(ge({headers:{"Content-Type":"application/x-www-form-urlencoded"},timeout:120*1e3},e)),this.setupSkipWarn(this.settings),this.showLoading=bn(this.openLoading.bind(this),Hv),this.showError=Kp(this._showError.bind(this),Vv,{leading:!0,trailing:!1})}setConfig(t={}){this.settings=ge(this.settings,t.settings||{});const e=xr(t,["settings","query"]);this.axios.defaults=ge(this.axios.defaults,e),this.setupSkipWarn(this.settings)}cancel(t,e="请求已取消"){if(t){const n=this.records[t];if(!n)return;n.source.cancel(e)}else for(const n of Object.values(this.records))n.source.cancel(e)}createHeaders(t,e,n){const i=e.injectHeaders?typeof e.headers=="function"?e.headers(t,n,e):e.headers||{}:{},s=H(H({"Content-Type":Lv[e.type||"form"]},n.headers),i);return e.skipWarn&&(s[Zi]=t),s}isJsonType(t){return Object.entries(t).some(([e,n])=>e.toLowerCase()==="content-type"&&String(n).includes("application/json"))}toFormData(t,e="data"){if(t instanceof FormData||t instanceof URLSearchParams)return t;const n=e==="data"?new FormData:new URLSearchParams;return Object.entries(t).forEach(([i,s])=>{n.append(i,s)}),n}createSendData(t,e,n,i,s={}){const{type:o,skipWarn:u}=t,{name:l="skipWarn"}=u||{};let{data:a,params:c={},method:f="get"}=e;const h=i?{[l]:!0}:{};return kv.includes(f.toLowerCase())?(a=Object.assign(a||{},h),a=o!=="json"||!this.isJsonType(n)?this.toFormData(a,o):a,c=H({},s)):o==="form"?c=H(H(H({},a||{}),s),h):(a&&(o!=="json"||!this.isJsonType(n))&&(a=this.toFormData(a,o)),c=H(H({},s),h)),{data:a,params:c}}createUrl(t){let{url:e,params:n}=t;if(e){let i=Ye(e)?new URL(e).origin:"";const s=i?e.replace(i,""):e;try{const o=Jd(s,{encode:encodeURIComponent});return i+o(n||{})}catch(o){console.warn("createUrl","pathToRegexpCompile error",e)}}return e}openLoading(t){const{loading:e,showLoading:n}=t;e&&n&&Object.keys(this.records).length>0&&(this.isLoading=!0,n())}closeLoading(t){const{loading:e,hideLoading:n}=t;if(!e)return;this.isLoading=!1;const i=Object.keys(this.records);n&&i.length===0&&(this.isLoading=!1,n())}_showError(t,e){var s;const{failMessage:n,showError:i}=t;if(n&&i){const o=(s=e==null?void 0:e.response)==null?void 0:s.data,u=(o==null?void 0:o.message)||(o==null?void 0:o.msg)||(e==null?void 0:e.message)||(e==null?void 0:e.msg)||"未知错误";i(u,e)}}validResponse(t,e){const{validSuccess:n,validate:i}=t;return n&&i?!!i(e):!0}isSkipWarnResponse(t){return!!t.promise}send(t={},e=!1){const n=ge({},this.settings,t.settings||{}),i=t.query||{},s=xr(t,["settings","query"]),o=Vd(!1),u=Q.CancelToken.source();this.records[o]={settings:n,config:s,source:u};const l=this.createUrl(s),a=this.createHeaders(o,n,s),{data:c,params:f}=this.createSendData(n,s,a,e,i);return this.showLoading(n),new Promise((h,p)=>{this.axios(et(H({cancelToken:u.token},s),{url:l,headers:a,data:c,params:f})).then(d=>{var g;return this.isSkipWarnResponse(d)?h(d.promise):this.validResponse(n,d)?h(n.originResponse?d:(g=d.data)==null?void 0:g.data):(this.showError(n,d.data),p(d.data))}).catch(d=>(this.showError(n,d),p(d))).finally(()=>{delete this.records[o],this.closeLoading(n)})})}useResponse(t,e){const{response:n}=this.axios.interceptors,i=n.use(t,e);return()=>n.eject(i)}useRequest(t,e){const{request:n}=this.axios.interceptors,i=n.use(t,e);return()=>n.eject(i)}setupSkipWarn(t){if(this.stopSkipWarn&&(this.stopSkipWarn(),this.stopSkipWarn=void 0),!t.skipWarn)return;const{code:e,executor:n,callback:i,complete:s}=t.skipWarn;this.stopSkipWarn=this.useResponse(o=>{const u=(o.config.headers||{})[Zi],l=this.records[u];if(!l)return o;const{data:a}=o;if(!a||typeof a!="object")return o;if((a==null?void 0:a.code)===e){i&&i(o);const c=new Promise(n).then(()=>this.send(et(H({},l.config),{settings:l.settings}),!0));c.catch(f=>f).finally(()=>{s&&s()}),o.promise=c}return o})}}function An(r={}){const t=new qv(r),e=t.send.bind(t),n=t.cancel.bind(t),i=t.setConfig.bind(t),s=t.useRequest.bind(t),o=t.useResponse.bind(t);return Object.assign(e,et(H({},t),{instance:t,send:e,cancel:n,setConfig:i,useRequest:s,useResponse:o}))}const tn=An({settings:{injectHeaders:!0,loading:!0,originResponse:!0}}),en=typeof window<"u";function zv(r){const t={};return r?(r.forEach((e,n)=>{t[n]=typeof e=="string"?decodeURIComponent(e):e}),t):{}}class Wo{constructor(t={}){lt(this,"options",{type:"cache",expired:0,prefix:"__VTJ_"}),lt(this,"caches",{}),lt(this,"types"),this.types={local:en?window.localStorage:this.caches,session:en?window.sessionStorage:this.caches,cache:this.caches},this.config(t)}config(t={}){this.options=Object.assign(this.options,t)}save(t,e,n={}){const{type:i,expired:s,prefix:o}=H(H({},this.options),n),u=Date.now(),l=o+t,a=this.types[i]||this.caches,c={value:e,timestamp:u,expired:s};a===this.caches?a[l]=c:a.setItem(l,JSON.stringify(c))}get(t,e={}){const{type:n,prefix:i}=H(H({},this.options),e),s=i+t,o=this.types[n]||this.caches;let u;if(o===this.caches)u=o[s];else{const f=o.getItem(s);if(f)try{u=JSON.parse(f)}catch(h){console.warn("[Storage] JSON.parse",h)}}if(!u)return null;const{value:l,timestamp:a,expired:c}=u;return c>0&&a+c<Date.now()?(this.remove(t,e),null):l}remove(t,e={}){const{type:n,prefix:i}=H(H({},this.options),e),s=this.types[n]||this.caches,o=i+t;s===this.caches?delete s[o]:s.removeItem(o)}clear(t={}){const{type:e}=H(H({},this.options),t),n=this.types[e]||this.caches;n===this.caches?this.caches={}:n.clear()}}const Dr=new Wo;function Ko(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}var ze={exports:{}},Wv=ze.exports,Qi;function Kv(){return Qi||(Qi=1,(function(r,t){(function(e,n){n(t,r)})(Wv,function(e,n){var i={timeout:5e3,jsonpCallback:"callback"};function s(){return"jsonp_"+Date.now()+"_"+Math.ceil(Math.random()*1e5)}function o(a){try{delete window[a]}catch(c){window[a]=void 0}}function u(a){var c=document.getElementById(a);c&&document.getElementsByTagName("head")[0].removeChild(c)}function l(a){var c=arguments.length<=1||arguments[1]===void 0?{}:arguments[1],f=a,h=c.timeout||i.timeout,p=c.jsonpCallback||i.jsonpCallback,d=void 0;return new Promise(function(g,b){var w=c.jsonpCallbackFunction||s(),m=p+"_"+w;window[w]=function(_){g({ok:!0,json:function(){return Promise.resolve(_)}}),d&&clearTimeout(d),u(m),o(w)},f+=f.indexOf("?")===-1?"?":"&";var y=document.createElement("script");y.setAttribute("src",""+f+p+"="+w),c.charset&&y.setAttribute("charset",c.charset),c.nonce&&y.setAttribute("nonce",c.nonce),c.referrerPolicy&&y.setAttribute("referrerPolicy",c.referrerPolicy),c.crossorigin&&y.setAttribute("crossorigin","true"),y.id=m,document.getElementsByTagName("head")[0].appendChild(y),d=setTimeout(function(){b(new Error("JSONP request to "+a+" timed out")),o(w),u(m),window[w]=function(){o(w)}},h),y.onerror=function(){b(new Error("JSONP request to "+a+" failed")),o(w),u(m),d&&clearTimeout(d)}})}n.exports=l})})(ze,ze.exports)),ze.exports}var Jv=Kv();const Gv=Ko(Jv);function Yv(r){if(en){const{protocol:t,host:e,pathname:n}=location;return`${t}//${e}${r?n:""}`}else return null}function Zv(r=""){const t=r.match(mo);return t?t[0]:""}function Jo(r){const t=[];for(const e in r)Object.prototype.hasOwnProperty.call(r,e)&&t.push([e,encodeURIComponent(r[e])].join("="));return t.join("&")}function rn(r,t,e){const n={};r=(r||location.search).replace(/^[^]*\?/,""),t=t||"&",e=e||"=";let i;const s=new RegExp("(?:^|\\"+t+")([^\\"+e+"\\"+t+"]+)(?:\\"+e+"([^\\"+t+"]*))?","g");for(;(i=s.exec(r))!==null;)i[1]!==r&&(n[decodeURIComponent(i[1])]=decodeURIComponent(i[2]||""));return n}function Go(r,t){t=typeof t=="string"?rn(t):t;const e=r.split("?")[0],n=rn(r),i=Object.assign({},n,t),s=Jo(i);return s?[e,s].join("?"):r}const We=Object.freeze(Object.defineProperty({__proto__:null,append:Go,getCurrentHost:Yv,getHost:Zv,parse:rn,stringify:Jo},Symbol.toStringTag,{value:"Module"}));function Yo(e){return U(this,arguments,function*(r,t={}){const{query:n={}}=t;r.includes("${")&&(r=zp(r)(n||{}));const i=Go(r,n);return yield(yield Gv(i,t)).json()})}var Cr,Xi;function Qv(){if(Xi)return Cr;Xi=1,Cr=function(n,i,s){var o=document.head||document.getElementsByTagName("head")[0],u=document.createElement("script");typeof i=="function"&&(s=i,i={}),i=i||{},s=s||function(){},u.type=i.type||"text/javascript",u.charset=i.charset||"utf8",u.async="async"in i?!!i.async:!0,u.src=n,i.attrs&&r(u,i.attrs),i.text&&(u.text=""+i.text);var l="onload"in u?t:e;l(u,s),u.onload||t(u,s),o.appendChild(u)};function r(n,i){for(var s in i)n.setAttribute(s,i[s])}function t(n,i){n.onload=function(){this.onerror=this.onload=null,i(null,n)},n.onerror=function(){this.onerror=this.onload=null,i(new Error("Failed to load "+this.src),n)}}function e(n,i){n.onreadystatechange=function(){this.readyState!="complete"&&this.readyState!="loaded"||(this.onreadystatechange=null,i(null,n))}}return Cr}var Xv=Qv();const tm=Ko(Xv);function ts(r,t={}){return new Promise((e,n)=>{const{library:i}=t;tm(r,t,(s,o)=>{s?n(s):e(i?window[i]:void 0)})})}const es={debug:-1,log:0,info:0,warn:1,error:2},em=function(r,t,e,n){return function(...i){if(t&&es[t]<=es[r]&&console[r].apply&&(n==="*"||e.startsWith(n)))return console[r].apply(console,rm(i,e))}};function rm(r,t){return t!=="*"&&(typeof r[0]=="string"?r[0]=`[${t}] ${r[0]}`:r=["["+t+"]"].concat(r)),r}function nm(r,t){if(!r)return{targetLevel:t.level,targetBizName:t.bizName};if(~r.indexOf(":")){const e=r.split(":");return{targetLevel:e[0],targetBizName:e[1]}}return{targetLevel:r,targetBizName:"*"}}const im={level:"warn",bizName:"*"};class sm{constructor(t){lt(this,"config"),lt(this,"options"),this.options=H(H({},im),t);const e=typeof location<"u"?location:{},n=(/__(?:logConf|logLevel)__=([^#/&]*)/.exec(e.href)||[])[1];this.config=nm(n,t)}_log(t){const{targetLevel:e,targetBizName:n}=this.config,{bizName:i}=this.options;return em(t,e,i,n)}debug(...t){return this._log("debug")(...t)}log(...t){return this._log("log")(...t)}info(...t){return this._log("info")(...t)}warn(...t){return this._log("warn")(...t)}error(...t){return this._log("error")(...t)}}function om(r){return new sm(r)}const ie=om({level:"log",bizName:"VTJ"});/*! js-cookie v3.0.5 | MIT */function Fe(r){for(var t=1;t<arguments.length;t++){var e=arguments[t];for(var n in e)r[n]=e[n]}return r}var am={read:function(r){return r[0]==='"'&&(r=r.slice(1,-1)),r.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(r){return encodeURIComponent(r).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}};function nn(r,t){function e(i,s,o){if(!(typeof document>"u")){o=Fe({},t,o),typeof o.expires=="number"&&(o.expires=new Date(Date.now()+o.expires*864e5)),o.expires&&(o.expires=o.expires.toUTCString()),i=encodeURIComponent(i).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var u="";for(var l in o)o[l]&&(u+="; "+l,o[l]!==!0&&(u+="="+o[l].split(";")[0]));return document.cookie=i+"="+r.write(s,i)+u}}function n(i){if(!(typeof document>"u"||arguments.length&&!i)){for(var s=document.cookie?document.cookie.split("; "):[],o={},u=0;u<s.length;u++){var l=s[u].split("="),a=l.slice(1).join("=");try{var c=decodeURIComponent(l[0]);if(o[c]=r.read(a,c),i===c)break}catch(f){}}return i?o[i]:o}}return Object.create({set:e,get:n,remove:function(i,s){e(i,"",Fe({},s,{expires:-1}))},withAttributes:function(i){return nn(this.converter,Fe({},this.attributes,i))},withConverter:function(i){return nn(Fe({},this.converter,i),this.attributes)}},{attributes:{value:Object.freeze(t)},converter:{value:Object.freeze(r)}})}var On=nn(am,{path:"/"});function um(r,t,e){On.set(r,t,e)}function cm(r){return On.get(r)}function lm(r,t){On.remove(r,t)}const Br=Object.freeze(Object.defineProperty({__proto__:null,get:cm,remove:lm,set:um},Symbol.toStringTag,{value:"Module"}));/**!
57
57
  * Copyright (c) 2026, VTJ.PRO All rights reserved.
58
58
  * @name @vtj/renderer
59
59
  * @author CHC chenhuachun1549@dingtalk.com
60
- * @version 0.16.3
60
+ * @version 0.16.5
61
61
  * @license <a href="https://vtj.pro/license.html">MIT License</a>
62
- */const jr="0.16.3";var X=(r=>(r.Runtime="Runtime",r.Design="Design",r.Raw="Raw",r.VNode="VNode",r))(X||{});const rs=["$el","$emit","$nextTick","$parent","$root","$attrs","$slots","$watch","$props","$options","$forceUpdate"],fm=["vIf","vElseIf","vElse","vShow","vModel","vFor","vBind","vHtml"],hm={String,Number,Boolean,Array,Object,Function,Date},Ke="VtjPage",Pr="VtjHomepage",pm="html,body,base,head,link,meta,style,title,address,article,aside,footer,header,hgroup,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot,svg".split(","),dm="component,slot".split(",");function Ue(r,t){return r.map(e=>Ye(e)||e.startsWith("/")?e:`${t}${e}`)}function cr(r){return/\.css$/.test(r)}function lr(r){return/\.js$/.test(r)}function gm(r){return/\.json$/.test(r)}function vm(r,t=!1){return t&&r.endsWith(".prod.js")?r.replace(".prod.js",".js"):r}function mm(r,t,e=!1){const n=r.filter(h=>!!h.enabled),i=[],s=[],o=[],u=[],l={},a={},c=[],f={};return n.forEach(({urls:h,assetsUrl:p,library:d,assetsLibrary:g,localeLibrary:b})=>{h==null||h.forEach(w=>{lr(w)&&i.push(vm(w,e)),cr(w)&&s.push(w)}),d&&(u.push(d),l[d]=Ue(h||[],t),b&&(a[d]=b)),p&&o.push(p),g&&c.push(g),d&&g&&(f[g]=d)}),{scripts:Ue(i,t),css:Ue(s,t),materials:Ue(o,t),libraryExports:u,materialExports:zd(c),materialMapLibrary:f,libraryMap:l,libraryLocaleMap:a}}function ym(r,t){var s;const{name:e,parent:n,alias:i}=r;return n?(s=t[n])==null?void 0:s[i||e]:t[i||e]}function bm(r=[]){const t=r.filter(n=>cr(n)),e=r.filter(n=>lr(n));return{css:t,js:e}}function _m(r,t){const e=a=>{const c=[];let f=0;for(;f<a.length;){if(/\s/.test(a[f])){f++;continue}if(a.substring(f,f+2)==="/*"){const w=a.indexOf("*/",f+2);if(w!==-1){f=w+2;continue}}if(a[f]==="@"){const w=f;for(;f<a.length&&a[f]!=="{"&&a[f]!==";";)f++;const m=a.substring(w,f).trim(),y=m.includes("@keyframes");if(a[f]===";")c.push({type:"simple-at-rule",content:a.substring(w,f+1)}),f++;else if(a[f]==="{"){const _=f+1;let S=1;for(f++;f<a.length&&S>0;)a[f]==="{"?S++:a[f]==="}"&&S--,f++;const v=a.substring(w,f),T=a.substring(_,f-1);c.push({type:y?"keyframes":"at-rule",rule:m,content:v,inner:T})}continue}const h=f;for(;f<a.length&&a[f]!=="{";)f++;if(f>=a.length)break;const p=a.substring(h,f).trim();if(!p){f++;continue}const d=f+1;let g=1;for(f++;f<a.length&&g>0;)a[f]==="{"?g++:a[f]==="}"&&g--,f++;const b=a.substring(d,f-1);c.push({type:"rule",selector:p,content:b.trim()})}return c},n=a=>{const c=a.trim();return/^(from|to|\d+(\.\d+)?%)$/.test(c)},i=a=>a.replace(/::v-deep\(/g,":deep(").replace(/::v-deep\s+/g,":deep(").replace(/\/deep\//g," ").replace(/>>>/g," ").replace(/(.*?):deep\(([^)]+)\)/g,(c,f,h)=>{const p=f.trim(),d=h.trim();return p?`${p}[${t}] ${d}`:d}),s=a=>{const c=a.trim();if(!c||c.includes(`[${t}]`)||/^(:root|:host|html|body)(\s|$|:|\.|\#|\[)/.test(c)||n(c))return c;const f=c.match(/^(.+?)((?:::?[\w-]+(?:\([^)]*\))?)*)\s*$/);if(f){const[,h,p=""]=f,d=h.trim();return d?`${d}[${t}]${p}`:c}return`${c}[${t}]`},o=a=>i(a).split(",").map(c=>s(c)).filter(c=>c.trim()).join(", "),u=a=>a.map(c=>{switch(c.type){case"simple-at-rule":return c.content;case"keyframes":return c.content;case"at-rule":try{const h=e(c.inner),p=u(h);return`${c.rule} { ${p} }`}catch(h){return c.content}case"rule":if(!c.selector||!c.content)return"";const f=o(c.selector);return f.trim()?`${f} { ${c.content} }`:"";default:return""}}).filter(c=>c.trim()).join(" "),l=a=>a.replace(/\s*{\s*/g," { ").replace(/\s*}\s*/g," } ").replace(/\s*;\s*/g,"; ").replace(/\s*,\s*/g,", ").replace(/\s+/g," ").replace(/^\s+|\s+$/g,"").replace(/\s*}\s*}/g," } }").trim();try{const a=r.replace(/\/\*(?!\s*!)[\s\S]*?\*\//g,"").replace(/^\s+|\s+$/gm,"").replace(/\n\s*\n/g,`
62
+ */const jr="0.16.5";var X=(r=>(r.Runtime="Runtime",r.Design="Design",r.Raw="Raw",r.VNode="VNode",r))(X||{});const rs=["$el","$emit","$nextTick","$parent","$root","$attrs","$slots","$watch","$props","$options","$forceUpdate"],fm=["vIf","vElseIf","vElse","vShow","vModel","vFor","vBind","vHtml"],hm={String,Number,Boolean,Array,Object,Function,Date},Ke="VtjPage",Pr="VtjHomepage",pm="html,body,base,head,link,meta,style,title,address,article,aside,footer,header,hgroup,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot,svg".split(","),dm="component,slot".split(",");function Ue(r,t){return r.map(e=>Ye(e)||e.startsWith("/")?e:`${t}${e}`)}function cr(r){return/\.css$/.test(r)}function lr(r){return/\.js$/.test(r)}function gm(r){return/\.json$/.test(r)}function vm(r,t=!1){return t&&r.endsWith(".prod.js")?r.replace(".prod.js",".js"):r}function mm(r,t,e=!1){const n=r.filter(h=>!!h.enabled),i=[],s=[],o=[],u=[],l={},a={},c=[],f={};return n.forEach(({urls:h,assetsUrl:p,library:d,assetsLibrary:g,localeLibrary:b})=>{h==null||h.forEach(w=>{lr(w)&&i.push(vm(w,e)),cr(w)&&s.push(w)}),d&&(u.push(d),l[d]=Ue(h||[],t),b&&(a[d]=b)),p&&o.push(p),g&&c.push(g),d&&g&&(f[g]=d)}),{scripts:Ue(i,t),css:Ue(s,t),materials:Ue(o,t),libraryExports:u,materialExports:zd(c),materialMapLibrary:f,libraryMap:l,libraryLocaleMap:a}}function ym(r,t){var s;const{name:e,parent:n,alias:i}=r;return n?(s=t[n])==null?void 0:s[i||e]:t[i||e]}function bm(r=[]){const t=r.filter(n=>cr(n)),e=r.filter(n=>lr(n));return{css:t,js:e}}function _m(r,t){const e=a=>{const c=[];let f=0;for(;f<a.length;){if(/\s/.test(a[f])){f++;continue}if(a.substring(f,f+2)==="/*"){const w=a.indexOf("*/",f+2);if(w!==-1){f=w+2;continue}}if(a[f]==="@"){const w=f;for(;f<a.length&&a[f]!=="{"&&a[f]!==";";)f++;const m=a.substring(w,f).trim(),y=m.includes("@keyframes");if(a[f]===";")c.push({type:"simple-at-rule",content:a.substring(w,f+1)}),f++;else if(a[f]==="{"){const _=f+1;let S=1;for(f++;f<a.length&&S>0;)a[f]==="{"?S++:a[f]==="}"&&S--,f++;const v=a.substring(w,f),T=a.substring(_,f-1);c.push({type:y?"keyframes":"at-rule",rule:m,content:v,inner:T})}continue}const h=f;for(;f<a.length&&a[f]!=="{";)f++;if(f>=a.length)break;const p=a.substring(h,f).trim();if(!p){f++;continue}const d=f+1;let g=1;for(f++;f<a.length&&g>0;)a[f]==="{"?g++:a[f]==="}"&&g--,f++;const b=a.substring(d,f-1);c.push({type:"rule",selector:p,content:b.trim()})}return c},n=a=>{const c=a.trim();return/^(from|to|\d+(\.\d+)?%)$/.test(c)},i=a=>a.replace(/::v-deep\(/g,":deep(").replace(/::v-deep\s+/g,":deep(").replace(/\/deep\//g," ").replace(/>>>/g," ").replace(/(.*?):deep\(([^)]+)\)/g,(c,f,h)=>{const p=f.trim(),d=h.trim();return p?`${p}[${t}] ${d}`:d}),s=a=>{const c=a.trim();if(!c||c.includes(`[${t}]`)||/^(:root|:host|html|body)(\s|$|:|\.|\#|\[)/.test(c)||n(c))return c;const f=c.match(/^(.+?)((?:::?[\w-]+(?:\([^)]*\))?)*)\s*$/);if(f){const[,h,p=""]=f,d=h.trim();return d?`${d}[${t}]${p}`:c}return`${c}[${t}]`},o=a=>i(a).split(",").map(c=>s(c)).filter(c=>c.trim()).join(", "),u=a=>a.map(c=>{switch(c.type){case"simple-at-rule":return c.content;case"keyframes":return c.content;case"at-rule":try{const h=e(c.inner),p=u(h);return`${c.rule} { ${p} }`}catch(h){return c.content}case"rule":if(!c.selector||!c.content)return"";const f=o(c.selector);return f.trim()?`${f} { ${c.content} }`:"";default:return""}}).filter(c=>c.trim()).join(" "),l=a=>a.replace(/\s*{\s*/g," { ").replace(/\s*}\s*/g," } ").replace(/\s*;\s*/g,"; ").replace(/\s*,\s*/g,", ").replace(/\s+/g," ").replace(/^\s+|\s+$/g,"").replace(/\s*}\s*}/g," } }").trim();try{const a=r.replace(/\/\*(?!\s*!)[\s\S]*?\*\//g,"").replace(/^\s+|\s+$/gm,"").replace(/\n\s*\n/g,`
63
63
  `),c=e(a),f=u(c);return l(f)}catch(a){return console.error("CSS scoping failed:",a),console.error("Input CSS:",r),r.replace(/\/\*[\s\S]*?\*\//g,"").replace(/(@keyframes\s+[^{]+\s*{[^{}]*(?:{[^}]*}[^{}]*)*})/g,c=>c).replace(/([^{}@]+)(?=\s*{)/g,c=>{const f=c.trim();return!f||f.startsWith("@")||f.includes(`[${t}]`)||n(f)?c:`${f}[${t}]`})}}const wm=750;function Em(r,t,e){let n;typeof r<"u"?n=r.innerWidth||r.document.documentElement.clientWidth:(console.warn("无法获取屏幕宽度,使用默认值375"),n=375);const i=wm;return t*n/i}function Sm(r,t){let e=!1,n=!1,i=!1,s="";for(let o=0;o<t.length;o++){const u=t[o];if(u==="'"&&!n&&!i?e=!e:u==='"'&&!e&&!i?n=!n:t.substr(o,4).toLowerCase()==="url("&&!e&&!n?i=!0:u===")"&&i&&(i=!1),!e&&!n&&!i){const l=t.substr(o).match(/^(-?\d+(?:\.\d+)?)\s*rpx/);if(l){const a=l[1],c=parseFloat(a),f=`${Em(r,c).toFixed(6).replace(/\.?0+$/,"")}px`;s+=f,o+=l[0].length-1;continue}}s+=u}return s}function Zo(r){return jt(r)?r:JSON.stringify(r)}function fr(r,t,e,n=!1){const i=r.CSSStyleSheet,s=n?`data-v-${t}`:t,o=r.__uniConfig?Sm(r,e):e,u=n?_m(o,s):o;if(i.prototype.replaceSync){const l=new i;l.id=t,l.replaceSync(u);const a=r.document,c=a.adoptedStyleSheets,f=Array.from(c).filter(h=>h.id!==t);a.adoptedStyleSheets=[...f,l]}else{const l=r.document;let a=l.getElementById(t);a?a.innerHTML=u:(a=l.createElement("style"),a.id=t,a.innerHTML=u,l.head.appendChild(a))}}function Tm(r,t){return U(this,null,function*(){const e=yield window.fetch(t).then(n=>n.text()).catch(()=>"");e&&fr(window,r,e)})}function Qo(r,t=window){const e=t.document,n=t.document.head;for(const i of r)if(!e.getElementById(i)){const s=e.createElement("link");s.rel="stylesheet",s.id=i,s.href=i,n.appendChild(s)}}function Xo(n,i){return U(this,arguments,function*(r,t,e=window){const s=e.document,o=e.document.head;let u=e[t];return u?u.default||u:new Promise((l,a)=>{for(const c of r){const f=s.createElement("script");f.src=c,f.onload=()=>{u=e[t],u?l(u.default||u):a(null)},f.onerror=h=>{a(h)},o.appendChild(f)}})})}function Rm(r){return Vt(r)&&Object.getOwnPropertyNames(r.prototype||{}).length===0||Vt(r==null?void 0:r.install)}function xm(r){return dm.includes(r)}function Am(r){return pm.includes(r)}function we(r=window){const t=window==null?void 0:window.Mock;if(t)return t;const e=r==null?void 0:r.Mock;if(e&&window)return window.Mock=e,e}function Ee(r,t,e=!1,n=!1,i=!1){var s;try{const o=['"use strict";',"var __self = arguments[0];"];o.push("return ");let u=(r.value||"").trim();i||(u=u.replace(/this(\W|$)/g,(a,c)=>`__self${c}`)),u=o.join(`
64
64
  `)+u;const l=i?`
65
65
  ${u}
66
- `:`with(${e?"{}":"$scope || {}"}) { ${u} }`;return new Function("$scope",l)(t)}catch(o){if(ie.error("parseExpression.error",o,r,(s=t==null?void 0:t.__self)!=null?s:t),n)throw o}}function ht(r,t,e=!1,n=!1,i=!1){var o;const s=Ee(r,t,e,n,i);if(typeof s!="function"&&(ie.error("parseFunction.error","not a function",r,(o=t==null?void 0:t.__self)!=null?o:t),n))throw new Error(`"${r.value}" not a function`);return s}function vt(r){return r&&r.type==="JSExpression"}function pt(r){return typeof r=="object"&&r&&r.type==="JSFunction"}const Om={session:!1,authKey:"Authorization",storageKey:"ACCESS_STORAGE",storagePrefix:"__VTJ_",unauthorized:void 0,auth:"/#/login",redirectParam:"r",unauthorizedCode:401,unauthorizedMessage:"登录已经失效,请重新登录!",noPermissionMessage:"无权限访问该页面",appName:"",statusKey:"code"},$m=Symbol("access");class ta{constructor(t){q(this,"options");q(this,"data",null);q(this,"mode",X.Raw);q(this,"interceptResponse",!0);q(this,"isTipShowing",!1);this.options=Object.assign({},Om,t),this.loadData()}enableIntercept(){this.interceptResponse=!0}disableIntercept(){this.interceptResponse=!1}connect(t){const{mode:e,router:n,request:i}=t;this.mode=e,n&&this.mode!==X.Design&&this.setGuard(n),i&&this.setRequest(i)}login(t){const{storageKey:e,storagePrefix:n,session:i,authKey:s}=this.options;this.setData(t),this.data&&(Dr.save(e,t,{type:"local",prefix:n}),i&&Br.set(s,this.data.token))}clear(){const{storageKey:t,storagePrefix:e,session:n,authKey:i}=this.options;this.data=null,Dr.remove(t,{type:"local",prefix:e}),n&&Br.remove(i)}logout(){this.clear(),this.toLogin()}getData(){return this.data?this.data:(this.loadData(),this.data)}getToken(){var t;return this.data||this.loadData(),(t=this.data)==null?void 0:t.token}can(t){const{appName:e}=this.options,{permissions:n={}}=this.data||{};return typeof t=="function"?t(n):Pi(t).every(i=>n[i]||n[e+"."+i])}some(t){const{appName:e}=this.options,{permissions:n={}}=this.data||{};return Pi(t).some(i=>n[i]||n[e+"."+i])}install(t){t.config.globalProperties.$access=this,t.provide($m,this)}isAuthPath(t){const{auth:e,isAuth:n}=this.options;if(n)return n(t);if(t.path&&typeof e=="string"){const i=e.split("#")[1]||e;return t.path===i}return!1}toLogin(){const{auth:t,redirectParam:e}=this.options;if(!t)return;const n=e?`?${e}=${encodeURIComponent(location.href)}`:"";typeof t=="function"?t(n):location.href=e?`${t}${n}`:t}setData(t){const{privateKey:e}=this.options;if(Array.isArray(t)&&e){const n=t.map(i=>ji(i,e));try{this.data=JSON.parse(n.join(""))}catch(i){console.warn(i)}return}if(typeof t=="string")try{const n=e?ji(t,e):t;n?this.data=JSON.parse(n):console.warn("RSA解密失败或登录信息缺失")}catch(n){console.warn(n)}else this.data=t}loadData(){const{storageKey:t,storagePrefix:e}=this.options,n=Dr.get(t,{type:"local",prefix:e});this.setData(n||null)}isLogined(){const{session:t,authKey:e}=this.options;return t&&e?!!Br.get(e):!!this.getToken()}hasRoutePermission(t){if(t.name===Ke){const e=t.params.id;return e&&this.can(e)}return t.meta.__vtj__?this.can(t.meta.__vtj__):t.meta.permission?this.can(t.meta.permission):!0}setGuard(t){t.beforeEach((e,n,i)=>this.guard(e,i))}guard(t,e){return U(this,null,function*(){if(this.isWhiteList(t)||this.isAuthPath(t))return e();if(this.isLogined()){if(this.hasRoutePermission(t))return e();{const{noPermissionMessage:n="无权限访问",unauthorized:i=!1}=this.options;return yield this.showTip(n),Vt(i)?(i(),e(!1)):jt(i)?e(i):e(!1)}}e(!1),yield Ze(0),this.toLogin()})}isWhiteList(t){const{whiteList:e}=this.options;return e?Array.isArray(e)?e.some(n=>t.fullPath.startsWith(n)):e(t):!1}isUnauthorized(t){var i;const{unauthorizedCode:e=401,statusKey:n="code"}=this.options;return t.status===e||((i=t.data)==null?void 0:i[n])===e}showUnauthorizedAlert(t){return U(this,null,function*(){const{unauthorizedMessage:e="登录已失效"}=this.options;this.isUnauthorized(t)&&(yield this.showTip(e))&&this.toLogin()})}showTip(t){return U(this,null,function*(){var n,i;const{alert:e}=this.options;return this.isTipShowing?!1:e?(this.isTipShowing=!0,yield Ze(150),yield(i=(n=e(t,{title:"提示",type:"warning"}))==null?void 0:n.catch(()=>!0))==null?void 0:i.finally(()=>{this.isTipShowing=!1})):(window.alert(t),!0)})}setRequest(t){t.useRequest(e=>{var n,i;return(n=this.data)!=null&&n.token&&(e.headers[this.options.authKey]=(i=this.data)==null?void 0:i.token),e}),t.useResponse(e=>U(this,null,function*(){return this.interceptResponse&&(yield this.showUnauthorizedAlert(e)),e}),e=>U(this,null,function*(){if(!this.interceptResponse)return Promise.reject(e);const n=e.response||e||{};return yield this.showUnauthorizedAlert(n),Promise.reject(e)}))}}function Dm(r={}){const{notify:t,loading:e,settings:n={},Startup:i,access:s,useTitle:o,alert:u}=r;let l=null;return{request:An({settings:H({type:"form",validSuccess:!0,originResponse:!1,loading:!0,validate:a=>{var c,f;return((c=a.data)==null?void 0:c.code)===0||!!((f=a.data)!=null&&f.success)},failMessage:!0,showError:a=>{t&&t(a||"未知错误")},showLoading:()=>{l&&l.close(),e&&(l=e())},hideLoading:()=>{l&&(l.close(),l=null)}},n)}),jsonp:Yo,notify:t,loading:e,useTitle:o,alert:u,startupComponent:i,access:s?new ta(H({alert:u},s)):void 0}}function Cm(r,t){const{jsonp:e,request:n}=t;if(r.method==="jsonp")return(i={})=>e(r.url,et(H({},r.jsonpOptions),{query:i}));{const i=r.headers?Ee(r.headers,{},!0):void 0,s={url:r.url,method:r.method,settings:et(H({},r.settings),{headers:i})};return(o,u)=>(delete s.data,n.send(ge(s,u||{},{data:o})))}}function Bm(r,t){const{metaQuery:e}=t;if(!e)return;const{code:n,queryCode:i}=r;return(s,o)=>{if(!e){console.warn("adapter.metaQuery is not defined!");return}return e(n,i,s,o)}}function jm(r=[],t=[],e){const n={};for(const i of r){const s=Cm(i,e);n[i.id]=s,n[i.name]=s}for(const i of t)n[i.id]=Bm(i,e);return n}function Pm(){return U(this,arguments,function*(r=[],t=window){const e=we(t);e&&(ea(t),r.forEach(n=>Im(e,n)))})}function Nm(r,t=window){const e=pt(r.mockTemplate)&&r.mockTemplate.value?ht(r.mockTemplate,{},!0):void 0,n=we(t);return(...i)=>U(null,null,function*(){let s={};if(e)try{s=yield e.apply(e,i)}catch(o){ie.warn("模拟数据模版异常",o)}return n==null?void 0:n.mock(s)})}function Im(r,t){if(!t.mock)return;const{url:e,mockTemplate:n}=t;if(e&&n)try{const i=Ye(e)?new URL(e).pathname:e,s=En(`(.*)${i}(.*)`),o=Yd(i,{decode:decodeURIComponent}),u=Ee(n,{},!0);r.mock(s,l=>{var p;const a=We.parse(l.url)||{},c=l.body instanceof FormData?zv(l.body):l.body,f=Ye(l.url)?new URL(l.url).pathname:l.url.split("?")[0],h=(p=o(f))==null?void 0:p.params;Object.assign(l,{data:c,params:h,query:a});try{return r.mock(u(l))}catch(d){return console.warn("[mockApi]",s,l,d),null}})}catch(i){console.warn("mockApi",i)}}function ea(r=window){const t=we(r);t&&(t._mocked={})}class Mm{constructor(t){q(this,"__id",null);q(this,"__mode");q(this,"__instance",null);q(this,"__contextRefs",{});q(this,"__refs",{});q(this,"context",{});q(this,"state",{});q(this,"props",{});q(this,"$props",{});q(this,"$refs",{});q(this,"$el",null);q(this,"$emit",null);q(this,"$nextTick",null);q(this,"$parent",null);q(this,"$root",null);q(this,"$attrs",null);q(this,"$slots",null);q(this,"$watch",null);q(this,"$options",null);q(this,"$forceUpdate",null);q(this,"$components",{});q(this,"$libs",{});q(this,"$apis",{});q(this,"$provider",null);q(this,"__transform",{});const{mode:e,dsl:n,attrs:i}=t;this.__mode=e,n&&(this.__id=n.id||null,this.__transform=n.transform||{}),i&&Object.assign(this,i)}setup(t,e=Xe){const n=e.getCurrentInstance();if(!n)return;this.__refs={},this.$refs={},this.context={},this.__contextRefs={},this.__instance=n.proxy;const i=n.appContext.config.globalProperties;Object.assign(this,i),Object.assign(this,t||{}),this.__proxy(),e.onMounted(()=>{this.__proxy()}),e.onUnmounted(()=>{this.__cleanup()}),e.onBeforeUpdate(()=>{this.__reset()})}__proxy(){this.__instance&&rs.forEach(t=>{var e;this[t]=(e=this.__instance)==null?void 0:e[t]})}__cleanup(){rs.forEach(t=>{this[t]=null}),this.__reset()}__reset(){this.__refs={},this.$refs={},this.__contextRefs={},this.context={}}__parseFunction(t){var e;if(t)if(this.__mode===X.Runtime){const{id:n,type:i}=t,s=n&&(e=this.__transform[n])!=null?e:t.value;return ht({type:i,value:s},this)}else return ht(t,this)}__parseExpression(t){var e;if(t)if(this.__mode===X.Runtime){const{id:n,type:i}=t,s=n&&(e=this.__transform[n])!=null?e:t.value;return Ee({type:i,value:s},this)}else return Ee(t,this)}__ref(t=null,e){if(this.__mode!==X.VNode)return t&&t!==this.__id&&(this.__contextRefs[t]=this),n=>U(this,null,function*(){var s,o;yield Ze(0);let i=(n==null?void 0:n.$vtjEl)||(n==null?void 0:n.$el)||((o=(s=n==null?void 0:n._)==null?void 0:s.vnode)==null?void 0:o.el)||n;if(!i){typeof e=="string"&&(delete this.$refs[e],t&&delete this.__refs[t]);return}return i.nodeType===3&&i.nextSibling&&(i=i.nextSibling),i.__vtj__=t,X.Design===this.__mode&&(i.__context__=this,i.draggable=!0),t&&(this.__refs[t]=this.__getRefEl(this.__refs,t,n)),typeof e=="function"?e(n):e&&(this.$refs[e]=this.__getRefEl(this.$refs,e,n)),n})}__getRefEl(t,e,n){const i=t[e];if(i&&n!==i){const s=new Set([].concat(i,n));return Array.from(s)}else return n}__clone(t={}){const e=H(H({},this.context),t),n=et(H({},e),{context:e});return n.context.__proto__=this.context,n.__proto__=this,n}}function sn(r){var f,p;const{Vue:t=Xe,mode:e=X.Runtime,components:n={},libs:i={},apis:s={},loader:o}=r,u=t.computed(()=>r.dsl),l={$components:n,$libs:i,$apis:s},a=new Mm({mode:e,dsl:u.value,attrs:l}),c=t.defineComponent(H({name:u.value.name,__scopeId:u.value.id?`data-v-${u.value.id}`:void 0,props:H({},Um((f=u.value.props)!=null?f:[],a)),setup(d){return U(this,null,function*(){var _,S,v,T;a.$props=d,a.props=d,u.value.id&&fr(r.window||window,u.value.id,u.value.css||"",!0),a.state=Lm(t,(_=u.value.state)!=null?_:{},a);const g=km(t,(S=u.value.computed)!=null?S:{},a),b=Hm((v=u.value.methods)!=null?v:{},a),w=Vm(t,u.value.inject,a);for(const[A,L]of Object.entries(w||{}))w[A]=t.inject(A,L);const m=qm(u.value.dataSources||{},a),y=H(H(H(H({},w),g),b),m);return a.setup(y,t),zm(t,(T=u.value.watch)!=null?T:[],a),H(H({vtj:a,state:a.state},g),b)})},emits:Fm(u.value.emits),expose:["vtj",...u.value.expose||[]],render(){if(!u.value.nodes)return null;const d=u.value.nodes||[];return d.length===1?oe(d[0],a,t,o,d):d.map(g=>oe(g,a,t,o,d))}},Wm((p=u.value.lifeCycles)!=null?p:{},a)));return{renderer:t.markRaw(c),context:a}}function Fm(r=[]){return r.map(t=>jt(t)?t:t.name)}function Um(r=[],t){const e=n=>n?(Array.isArray(n)?n:[n]).map(i=>hm[i]):void 0;return r.map(n=>jt(n)?{name:n}:{name:n.name,type:n.type,required:n.required,default:vt(n.default)?t.__parseExpression(n.default):n.default}).reduce((n,i)=>(n[i.name]={type:e(i.type),required:i.required,default:i.default},n),{})}function Lm(r,t,e){return r.reactive(Object.keys(t||{}).reduce((n,i)=>{let s=t[i];return vt(s)?s=e.__parseExpression(s):pt(s)&&(s=e.__parseFunction(s)),n[i]=s,n},{}))}function km(r,t,e){return Object.entries(t!=null?t:{}).reduce((n,[i,s])=>(n[i]=r.computed(e.__parseFunction(s)),n),{})}function Hm(r,t){return Object.entries(r!=null?r:{}).reduce((e,[n,i])=>(e[n]=t.__parseFunction(i),e),{})}function Vm(r,t=[],e){return t.reduce((n,i)=>{var a;const{name:s,from:o}=i||{};i.default;const u=vt(o)?e.__parseExpression(o)||s:o!=null?o:s,l=vt(i.default)?e.__parseExpression(i.default):(a=i.default)!=null?a:null;return n[s]=r.inject(u,l),n},{})}function qm(r,t){return Object.keys(r).reduce((e,n)=>{const i=r[n];if(i.type==="mock")e[n]=Nm(i);else if(i.ref){const s=t.$apis[i.ref],o=pt(i.transform)?i.transform.value?t.__parseFunction(i.transform):void 0:i.transform;e[n]=(...u)=>U(null,null,function*(){const l=yield s.apply(t,u);return o?o(l):l})}return e},{})}function zm(r,t=[],e){t.forEach(n=>{r.watch(e.__parseExpression(n.source),e.__parseFunction(n.handler),{deep:n.deep,immediate:n.immediate})})}function Wm(r,t){return Object.entries(r!=null?r:{}).reduce((e,[n,i])=>{const s=t.__parseFunction(i);return e[n]=()=>U(null,null,function*(){Vt(s)&&(yield Ze(0),yield s())}),e},{})}const Km=new ig;let Nr=[],Xt={};const Jm=r=>r;function ra(e){return U(this,arguments,function*(r,t=window){const{urls:n=[],library:i}=r,s=n.filter(u=>lr(u));if(s.length===0||!i)return null;const o=n.filter(u=>cr(u));return o.length&&Qo(o,t),yield Xo(s,i,t).catch(u=>(console.warn("loadScriptUrl error",s,i,u),null))})}function on(r){const{getDsl:t,getDslByUrl:e,options:n}=r;return n.window&&(Nr.forEach(i=>{delete n.window[i]}),Nr=[]),(i,s,o=Xe)=>{if(!s||typeof s=="string")return i;if(s.type==="Schema"&&s.id)return o.defineAsyncComponent(()=>U(null,null,function*(){const u=Xt[s.id]||(yield Km.add(s.id,()=>t(s.id)));return u&&(u.name=i,Xt[s.id]=u),u?sn(et(H({},n),{Vue:o,dsl:fi(u),mode:X.Runtime,loader:on(r)})).renderer:null}));if(s.type==="UrlSchema"&&s.url)return o.defineAsyncComponent(()=>U(null,null,function*(){const u=Xt[s.url]||(yield e(s.url));return u&&(u.name=i,Xt[s.url]=u),u?sn(et(H({},n),{Vue:o,dsl:fi(u),mode:X.Runtime,loader:on(r)})).renderer:null}));if(s.type==="Plugin"){let u=s.library?Xt[s.library]:null;return u||(s.library&&Nr.push(s.library),u=Xt[s.library||Symbol()]=o.defineAsyncComponent(()=>U(null,null,function*(){return(yield ra(s,n.window))||(console.warn("getPlugin result is null",s),null)})),u)}return i}}function oe(r,t,e=Xe,n=Jm,i=[],s=!1){var y;if(!r||!r.name||r.invisible)return null;const o=(y=e.getCurrentInstance())==null?void 0:y.appContext,{id:u=null,directives:l=[]}=r,{vIf:a,vElseIf:c,vElse:f,vFor:h,vShow:p,vModels:d,vBind:g,vHtml:b,others:w}=na(l);if(!s&&(c||f))return null;if(a&&!Ym(a,t))return ty(r,t,e,n,i);const m=(_,S=0)=>{var j,$,k,F;const v=_.$components,T=(()=>{var z,O,D,P;if(r.name==="component")return Zm(_,(z=r.props)==null?void 0:z.is);if(r.name==="slot")return r.name;const V=n(r.name,r.from,e);return jt(V)?xm(V)||Am(V)?V:(P=(D=v[V])!=null?D:(O=o==null?void 0:o.app)==null?void 0:O.component(V))!=null?P:V:V})(),A=Qm(u,(j=r.props)!=null?j:{},_),L=Xm(e,($=r.events)!=null?$:{},_);if(r.name==="slot")return ey(e,r,A,_,n);g&&Object.assign(A,_.__parseExpression(g.value)),p&&(A.style=Object.assign((k=A.style)!=null?k:{},ny(p,_))),b&&Object.assign(A,iy(b,_)),d.forEach(V=>{Object.assign(A,sy(e,V,_))});const E=oy(e,(F=r.children)!=null?F:[],_,n,r),R=_!=null&&_.__id?`data-v-${_.__id}`:void 0,M=R?{[R]:""}:{};let C=e.createVNode(T,H(H(H({key:`${u}_${S}`},M),A),L),E);const I=o?Gm(o,w,_):[];return I.length&&(C=e.withDirectives(C,I)),C};return h?cy(h,m,t):m(t)}function Gm(r,t,e){const n=r.app;return t.map(i=>{const s=typeof i.name=="string"?n.directive(i.name):e.__parseExpression(i.name);if(!s)return null;const o=[s];return i.value&&o.push(e.__parseExpression(i.value)),i.arg&&o.push(i.arg),i.modifiers&&o.push(i.modifiers),o}).filter(i=>!!i)}function na(r=[]){const t=r.find(c=>Tt(c.name)==="vIf"),e=r.find(c=>Tt(c.name)==="vElseIf"),n=r.find(c=>Tt(c.name)==="vElse"),i=r.find(c=>Tt(c.name)==="vFor"),s=r.find(c=>Tt(c.name)==="vShow"),o=r.find(c=>Tt(c.name)==="vBind"),u=r.find(c=>Tt(c.name)==="vHtml"),l=r.filter(c=>Tt(c.name)==="vModel"),a=r.filter(c=>!fm.includes(Tt(c.name)));return{vIf:t,vElseIf:e,vElse:n,vFor:i,vShow:s,vModels:l,vBind:o,others:a,vHtml:u}}function Ym(r,t){return!!t.__parseExpression(r.value)}function Zm(r,t){return t?vt(t)?r.__parseExpression(t):t:"div"}function Qm(r,t,e){const n=an(t,e);return n.ref=e.__ref(r,n.ref),n}function an(r,t){return vt(r)?t.__parseExpression(r):pt(r)?t.__parseFunction(r):Array.isArray(r)?r.map(e=>an(e,t)):typeof r=="object"?Object.keys(r||{}).reduce((e,n)=>{let i=r[n];return e[n]=an(i,t),e},{}):r}function Xm(r,t,e){const n=["passive","capture","once"],i={capture:"Capture",once:"Once",passive:"OnceCapture"};return Object.keys(t||{}).reduce((s,o)=>{const u=t[o],l=ia(u.modifiers),a=l.find(h=>n.includes(h)),c="on"+Ms(o)+(a&&i[a]||""),f=e.__parseFunction(u.handler);return f&&(s[c]=r.withModifiers(f,l)),s},{})}function ty(r,t,e,n,i=[]){let s=i.findIndex(o=>o.id===r.id);for(let o=++s;o<i.length;o++){const{directives:u=[]}=i[o],{vElseIf:l,vElse:a}=na(u);if(l){if(t.__parseExpression(l.value))return oe(i[o],t,e,n,i,!0);continue}if(a)return oe(i[o],t,e,n,i,!0)}return null}function ia(r={},t=!1){const e=Object.keys(r);return t?e.map(n=>"."+n):e}function ey(r,t,e,n,i){var l;const{children:s}=t,o=ry(t,n),u=(l=n.$slots)==null?void 0:l[o.name];return u?u(e):s?jt(s)?r.createTextVNode(s):vt(s)?r.createTextVNode(Zo(n.__parseExpression(s))):Array.isArray(s)?s.map(a=>oe(a,n,r,i,s)):null:null}function ry(r,t){const{props:e}=r,n=(e==null?void 0:e.name)||"default";return{name:vt(n)?t.__parseExpression(n):n,params:[]}}function ny(r,t){return t.__parseExpression(r.value)?{}:{display:"none"}}function iy(r,t){return{innerHTML:t.__parseExpression(r.value)||""}}function sy(r,t,e){var u;const n={type:"JSFunction",value:(u=t.value)!=null&&u.value?`(v) => {
66
+ `:`with(${e?"{}":"$scope || {}"}) { ${u} }`;return new Function("$scope",l)(t)}catch(o){if(ie.error("parseExpression.error",o,r,(s=t==null?void 0:t.__self)!=null?s:t),n)throw o}}function ht(r,t,e=!1,n=!1,i=!1){var o;const s=Ee(r,t,e,n,i);if(typeof s!="function"&&(ie.error("parseFunction.error","not a function",r,(o=t==null?void 0:t.__self)!=null?o:t),n))throw new Error(`"${r.value}" not a function`);return s}function vt(r){return r&&r.type==="JSExpression"}function pt(r){return typeof r=="object"&&r&&r.type==="JSFunction"}const Om={session:!1,authKey:"Authorization",storageKey:"ACCESS_STORAGE",storagePrefix:"__VTJ_",unauthorized:void 0,auth:"/#/login",redirectParam:"r",unauthorizedCode:401,unauthorizedMessage:"登录已经失效,请重新登录!",noPermissionMessage:"无权限访问该页面",appName:"",statusKey:"code"},$m=Symbol("access");class ta{constructor(t){q(this,"options");q(this,"data",null);q(this,"mode",X.Raw);q(this,"interceptResponse",!0);q(this,"isTipShowing",!1);this.options=Object.assign({},Om,t),this.loadData()}enableIntercept(){this.interceptResponse=!0}disableIntercept(){this.interceptResponse=!1}connect(t){const{mode:e,router:n,request:i}=t;this.mode=e,n&&this.mode!==X.Design&&this.setGuard(n),i&&this.setRequest(i)}login(t){const{storageKey:e,storagePrefix:n,session:i,authKey:s}=this.options;this.setData(t),this.data&&(Dr.save(e,t,{type:"local",prefix:n}),i&&Br.set(s,this.data.token))}clear(){const{storageKey:t,storagePrefix:e,session:n,authKey:i}=this.options;this.data=null,Dr.remove(t,{type:"local",prefix:e}),n&&Br.remove(i)}logout(){this.clear(),this.toLogin()}getData(){return this.data?this.data:(this.loadData(),this.data)}getToken(){var t;return this.data||this.loadData(),(t=this.data)==null?void 0:t.token}can(t){const{appName:e}=this.options,{permissions:n={}}=this.data||{};return typeof t=="function"?t(n):Pi(t).every(i=>n[i]||n[e+"."+i])}some(t){const{appName:e}=this.options,{permissions:n={}}=this.data||{};return Pi(t).some(i=>n[i]||n[e+"."+i])}install(t){t.config.globalProperties.$access=this,t.provide($m,this)}isAuthPath(t){const{auth:e,isAuth:n}=this.options;if(n)return n(t);if(t.path&&typeof e=="string"){const i=e.split("#")[1]||e;return t.path===i}return!1}toLogin(){const{auth:t,redirectParam:e}=this.options;if(!t)return;const n=e?`?${e}=${encodeURIComponent(location.href)}`:"";typeof t=="function"?t(n):location.href=e?`${t}${n}`:t}setData(t){const{privateKey:e}=this.options;if(Array.isArray(t)&&e){const n=t.map(i=>ji(i,e));try{this.data=JSON.parse(n.join(""))}catch(i){console.warn(i)}return}if(typeof t=="string")try{const n=e?ji(t,e):t;n?this.data=JSON.parse(n):console.warn("RSA解密失败或登录信息缺失")}catch(n){console.warn(n)}else this.data=t}loadData(){const{storageKey:t,storagePrefix:e}=this.options,n=Dr.get(t,{type:"local",prefix:e});this.setData(n||null)}isLogined(){const{session:t,authKey:e}=this.options;return t&&e?!!Br.get(e):!!this.getToken()}hasRoutePermission(t){if(t.name===Ke){const e=t.params.id;return e&&this.can(e)}return t.meta.__vtj__?this.can(t.meta.__vtj__):t.meta.permission?this.can(t.meta.permission):!0}setGuard(t){t.beforeEach((e,n,i)=>this.guard(e,i))}guard(t,e){return U(this,null,function*(){if(this.isWhiteList(t)||this.isAuthPath(t))return e();if(this.isLogined()){if(this.hasRoutePermission(t))return e();{const{noPermissionMessage:n="无权限访问",unauthorized:i=!1}=this.options;return yield this.showTip(n),Vt(i)?(i(),e(!1)):jt(i)?e(i):e(!1)}}e(!1),yield Ze(0),this.toLogin()})}isWhiteList(t){const{whiteList:e}=this.options;return e?Array.isArray(e)?e.some(n=>t.fullPath.startsWith(n)):e(t):!1}isUnauthorized(t){var i;const{unauthorizedCode:e=401,statusKey:n="code"}=this.options;return t.status===e||((i=t.data)==null?void 0:i[n])===e}showUnauthorizedAlert(t){return U(this,null,function*(){const{unauthorizedMessage:e="登录已失效"}=this.options;this.isUnauthorized(t)&&(yield this.showTip(e))&&this.toLogin()})}showTip(t){return U(this,null,function*(){var n,i;const{alert:e}=this.options;return this.isTipShowing?!1:e?(this.isTipShowing=!0,yield Ze(150),yield(i=(n=e(t,{title:"提示",type:"warning"}))==null?void 0:n.catch(()=>!0))==null?void 0:i.finally(()=>{this.isTipShowing=!1})):(window.alert(t),!0)})}setRequest(t){t.useRequest(e=>{var n,i;return(n=this.data)!=null&&n.token&&(e.headers[this.options.authKey]=(i=this.data)==null?void 0:i.token),e}),t.useResponse(e=>U(this,null,function*(){return this.interceptResponse&&(yield this.showUnauthorizedAlert(e)),e}),e=>U(this,null,function*(){if(!this.interceptResponse)return Promise.reject(e);const n=e.response||e||{};return yield this.showUnauthorizedAlert(n),Promise.reject(e)}))}}function Dm(r={}){const{notify:t,loading:e,settings:n={},Startup:i,access:s,useTitle:o,alert:u}=r;let l=null;return{request:An({settings:H({type:"form",validSuccess:!0,originResponse:!1,loading:!0,validate:a=>{var c,f;return((c=a.data)==null?void 0:c.code)===0||!!((f=a.data)!=null&&f.success)},failMessage:!0,showError:a=>{t&&t(a||"未知错误")},showLoading:()=>{l&&l.close(),e&&(l=e())},hideLoading:()=>{l&&(l.close(),l=null)}},n)}),jsonp:Yo,notify:t,loading:e,useTitle:o,alert:u,startupComponent:i,access:s?new ta(H({alert:u},s)):void 0}}function Cm(r,t){const{jsonp:e,request:n}=t;if(r.method==="jsonp")return(i={})=>e(r.url,et(H({},r.jsonpOptions),{query:i}));{const i=r.headers?Ee(r.headers,{},!0):void 0,s={url:r.url,method:r.method,settings:et(H({},r.settings),{headers:i})};return(o,u)=>(delete s.data,n.send(ge(s,u||{},{data:o})))}}function Bm(r,t){const{metaQuery:e}=t;if(!e)return;const{code:n,queryCode:i}=r;return(s,o)=>{if(!e){console.warn("adapter.metaQuery is not defined!");return}return e(n,i,s,o)}}function jm(r=[],t=[],e){const n={};for(const i of r){const s=Cm(i,e);n[i.id]=s,n[i.name]=s}for(const i of t)n[i.id]=Bm(i,e);return n}function Pm(){return U(this,arguments,function*(r=[],t=window){const e=we(t);e&&(ea(t),r.forEach(n=>Im(e,n)))})}function Nm(r,t=window){const e=pt(r.mockTemplate)&&r.mockTemplate.value?ht(r.mockTemplate,{},!0):void 0,n=we(t);return(...i)=>U(null,null,function*(){let s={};if(e)try{s=yield e.apply(e,i)}catch(o){ie.warn("模拟数据模版异常",o)}return n==null?void 0:n.mock(s)})}function Im(r,t){if(!t.mock)return;const{url:e,mockTemplate:n}=t;if(e&&n)try{const i=Ye(e)?new URL(e).pathname:e,s=En(`(.*)${i}(.*)`),o=Yd(i,{decode:decodeURIComponent}),u=Ee(n,{},!0);r.mock(s,l=>{var p;const a=We.parse(l.url)||{},c=l.body instanceof FormData?zv(l.body):l.body,f=Ye(l.url)?new URL(l.url).pathname:l.url.split("?")[0],h=(p=o(f))==null?void 0:p.params;Object.assign(l,{data:c,params:h,query:a});try{return r.mock(u(l))}catch(d){return console.warn("[mockApi]",s,l,d),null}})}catch(i){console.warn("mockApi",i)}}function ea(r=window){const t=we(r);t&&(t._mocked={})}class Mm{constructor(t){q(this,"__id",null);q(this,"__mode");q(this,"__instance",null);q(this,"__contextRefs",{});q(this,"__refs",{});q(this,"context",{});q(this,"state",{});q(this,"props",{});q(this,"$props",{});q(this,"$refs",{});q(this,"$el",null);q(this,"$emit",null);q(this,"$nextTick",null);q(this,"$parent",null);q(this,"$root",null);q(this,"$attrs",null);q(this,"$slots",null);q(this,"$watch",null);q(this,"$options",null);q(this,"$forceUpdate",null);q(this,"$components",{});q(this,"$libs",{});q(this,"$apis",{});q(this,"$provider",null);q(this,"__transform",{});const{mode:e,dsl:n,attrs:i}=t;this.__mode=e,n&&(this.__id=n.id||null,this.__transform=n.transform||{}),i&&Object.assign(this,i)}setup(t,e=Xe){const n=e.getCurrentInstance();if(!n)return;this.__refs={},this.$refs={},this.context={},this.__contextRefs={},this.__instance=n.proxy;const i=n.appContext.config.globalProperties;Object.assign(this,i),Object.assign(this,t||{}),this.__proxy(),e.onMounted(()=>{this.__proxy()}),e.onUnmounted(()=>{this.__cleanup()}),e.onBeforeUpdate(()=>{this.__reset()})}__proxy(){this.__instance&&rs.forEach(t=>{var e;this[t]=(e=this.__instance)==null?void 0:e[t]})}__cleanup(){rs.forEach(t=>{this[t]=null}),this.__reset()}__reset(){this.__refs={},this.$refs={},this.__contextRefs={},this.context={}}__parseFunction(t){var e;if(t)if(this.__mode===X.Runtime){const{id:n,type:i}=t,s=n&&(e=this.__transform[n])!=null?e:t.value;return ht({type:i,value:s},this)}else return ht(t,this)}__parseExpression(t){var e;if(t)if(this.__mode===X.Runtime){const{id:n,type:i}=t,s=n&&(e=this.__transform[n])!=null?e:t.value;return Ee({type:i,value:s},this)}else return Ee(t,this)}__ref(t=null,e){if(this.__mode!==X.VNode)return t&&t!==this.__id&&(this.__contextRefs[t]=this),n=>U(this,null,function*(){var s,o;yield Ze(0);let i=(n==null?void 0:n.$vtjEl)||(n==null?void 0:n.$el)||((o=(s=n==null?void 0:n._)==null?void 0:s.vnode)==null?void 0:o.el)||n;if(!i){typeof e=="string"&&(delete this.$refs[e],t&&delete this.__refs[t]);return}return i.nodeType===3&&i.nextSibling&&(i=i.nextSibling),i.__vtj__=t,X.Design===this.__mode&&(i.__context__=this,i.draggable=!0),t&&(this.__refs[t]=this.__getRefEl(this.__refs,t,n)),typeof e=="function"?e(n):e&&(this.$refs[e]=this.__getRefEl(this.$refs,e,n)),n})}__getRefEl(t,e,n){const i=t[e];if(i&&n!==i){const s=new Set([].concat(i,n));return Array.from(s)}else return n}__clone(t={}){const e=H(H({},this.context),t),n=et(H({},e),{context:e});return n.context.__proto__=this.context,n.__proto__=this,n}}function sn(r){var f,p;const{Vue:t=Xe,mode:e=X.Runtime,components:n={},libs:i={},apis:s={},loader:o}=r,u=t.computed(()=>r.dsl),l={$components:n,$libs:i,$apis:s},a=new Mm({mode:e,dsl:u.value,attrs:l}),c=t.defineComponent(H({name:u.value.name,__scopeId:u.value.id?`data-v-${u.value.id}`:void 0,props:H({},Um((f=u.value.props)!=null?f:[],a)),setup(d){return U(this,null,function*(){var _,S,v,T;a.$props=d,a.props=d,u.value.id&&fr(r.window||window,u.value.id,u.value.css||"",!0),a.state=Lm(t,(_=u.value.state)!=null?_:{},a);const g=km(t,(S=u.value.computed)!=null?S:{},a),b=Hm((v=u.value.methods)!=null?v:{},a),w=Vm(t,u.value.inject,a);for(const[A,L]of Object.entries(w||{}))w[A]=t.inject(A,L);const m=qm(u.value.dataSources||{},a),y=H(H(H(H({},w),g),b),m);return a.setup(y,t),zm(t,(T=u.value.watch)!=null?T:[],a),H(H({vtj:a,state:a.state},g),b)})},emits:Fm(u.value.emits),expose:["vtj",...u.value.expose||[]],render(){if(!u.value.nodes)return null;const d=u.value.nodes||[];return d.length===1?oe(d[0],a,t,o,d):d.map(g=>oe(g,a,t,o,d))}},Wm((p=u.value.lifeCycles)!=null?p:{},a)));return{renderer:t.markRaw(c),context:a}}function Fm(r=[]){return r.map(t=>jt(t)?t:t.name)}function Um(r=[],t){const e=n=>n?(Array.isArray(n)?n:[n]).map(i=>hm[i]):void 0;return r.map(n=>jt(n)?{name:n}:{name:n.name,type:n.type,required:n.required,default:vt(n.default)?t.__parseExpression(n.default):n.default}).reduce((n,i)=>(n[i.name]={type:e(i.type),required:i.required,default:i.default},n),{})}function Lm(r,t,e){return r.reactive(Object.keys(t||{}).reduce((n,i)=>{let s=t[i];return vt(s)?s=e.__parseExpression(s):pt(s)&&(s=e.__parseFunction(s)),n[i]=s,n},{}))}function km(r,t,e){return Object.entries(t!=null?t:{}).reduce((n,[i,s])=>(n[i]=r.computed(e.__parseFunction(s)),n),{})}function Hm(r,t){return Object.entries(r!=null?r:{}).reduce((e,[n,i])=>(e[n]=t.__parseFunction(i),e),{})}function Vm(r,t=[],e){return t.reduce((n,i)=>{var a;const{name:s,from:o}=i||{};i.default;const u=vt(o)?e.__parseExpression(o)||s:o!=null?o:s,l=vt(i.default)?e.__parseExpression(i.default):(a=i.default)!=null?a:null;return n[s]=r.inject(u,l),n},{})}function qm(r,t){return Object.keys(r).reduce((e,n)=>{const i=r[n];if(i.type==="mock")e[n]=Nm(i);else if(i.ref){const s=t.$apis[i.ref],o=pt(i.transform)?i.transform.value?t.__parseFunction(i.transform):void 0:i.transform;e[n]=(...u)=>U(null,null,function*(){const l=yield s.apply(t,u);return o?o(l):l})}return e},{})}function zm(r,t=[],e){t.forEach(n=>{r.watch(e.__parseExpression(n.source),e.__parseFunction(n.handler),{deep:n.deep,immediate:n.immediate})})}function Wm(r,t){return Object.entries(r!=null?r:{}).reduce((e,[n,i])=>{const s=t.__parseFunction(i);return e[n]=()=>U(null,null,function*(){Vt(s)&&(yield Ze(0),yield s())}),e},{})}const Km=new ig;let Nr=[],Xt={};const Jm=r=>r;function ra(e){return U(this,arguments,function*(r,t=window){const{urls:n=[],library:i}=r,s=n.filter(u=>lr(u));if(s.length===0||!i)return null;const o=n.filter(u=>cr(u));return o.length&&Qo(o,t),yield Xo(s,i,t).catch(u=>(console.warn("loadScriptUrl error",s,i,u),null))})}function on(r){const{getDsl:t,getDslByUrl:e,options:n}=r;return n.window&&(Nr.forEach(i=>{delete n.window[i]}),Nr=[]),(i,s,o=Xe)=>{if(!s||typeof s=="string")return i;if(s.type==="Schema"&&s.id)return o.defineAsyncComponent(()=>U(null,null,function*(){const u=Xt[s.id]||(yield Km.add(s.id,()=>t(s.id)));return u&&(u.name=i,Xt[s.id]=u),u?sn(et(H({},n),{Vue:o,dsl:fi(u),mode:X.Runtime,loader:on(r)})).renderer:null}));if(s.type==="UrlSchema"&&s.url)return o.defineAsyncComponent(()=>U(null,null,function*(){const u=Xt[s.url]||(yield e(s.url));return u&&(u.name=i,Xt[s.url]=u),u?sn(et(H({},n),{Vue:o,dsl:fi(u),mode:X.Runtime,loader:on(r)})).renderer:null}));if(s.type==="Plugin"){let u=s.library?Xt[s.library]:null;return u||(s.library&&Nr.push(s.library),u=Xt[s.library||Symbol()]=o.defineAsyncComponent(()=>U(null,null,function*(){return(yield ra(s,n.window))||(console.warn("getPlugin result is null",s),null)})),u)}return i}}function oe(r,t,e=Xe,n=Jm,i=[],s=!1){var y;if(!r||!r.name||r.invisible)return null;const o=(y=e.getCurrentInstance())==null?void 0:y.appContext,{id:u=null,directives:l=[]}=r,{vIf:a,vElseIf:c,vElse:f,vFor:h,vShow:p,vModels:d,vBind:g,vHtml:b,others:w}=na(l);if(!s&&(c||f))return null;if(a&&!Ym(a,t))return ey(r,t,e,n,i);const m=(_,S=0)=>{var j,$,k,F;const v=_.$components,T=(()=>{var z,O,D,P;if(r.name==="component")return Zm(_,(z=r.props)==null?void 0:z.is);if(r.name==="slot")return r.name;const V=n(r.name,r.from,e);return jt(V)?xm(V)||Am(V)?V:(P=(D=v[V])!=null?D:(O=o==null?void 0:o.app)==null?void 0:O.component(V))!=null?P:V:V})(),A=Qm(u,(j=r.props)!=null?j:{},_),L=ty(e,($=r.events)!=null?$:{},_);if(r.name==="slot")return ry(e,r,A,_,n);g&&Object.assign(A,_.__parseExpression(g.value)),p&&(A.style=Object.assign((k=A.style)!=null?k:{},iy(p,_))),b&&Object.assign(A,sy(b,_)),d.forEach(V=>{Object.assign(A,oy(e,V,_))});const E=ay(e,(F=r.children)!=null?F:[],_,n,r),R=_!=null&&_.__id?`data-v-${_.__id}`:void 0,M=R?{[R]:""}:{};let C=e.createVNode(T,H(H(H({key:`${u}_${S}`},M),A),L),E);const I=o?Gm(o,w,_):[];return I.length&&(C=e.withDirectives(C,I)),C};return h?ly(h,m,t):m(t)}function Gm(r,t,e){const n=r.app;return t.map(i=>{const s=typeof i.name=="string"?n.directive(i.name):e.__parseExpression(i.name);if(!s)return null;const o=[s];return i.value&&o.push(e.__parseExpression(i.value)),i.arg&&o.push(i.arg),i.modifiers&&o.push(i.modifiers),o}).filter(i=>!!i)}function na(r=[]){const t=r.find(c=>Tt(c.name)==="vIf"),e=r.find(c=>Tt(c.name)==="vElseIf"),n=r.find(c=>Tt(c.name)==="vElse"),i=r.find(c=>Tt(c.name)==="vFor"),s=r.find(c=>Tt(c.name)==="vShow"),o=r.find(c=>Tt(c.name)==="vBind"),u=r.find(c=>Tt(c.name)==="vHtml"),l=r.filter(c=>Tt(c.name)==="vModel"),a=r.filter(c=>!fm.includes(Tt(c.name)));return{vIf:t,vElseIf:e,vElse:n,vFor:i,vShow:s,vModels:l,vBind:o,others:a,vHtml:u}}function Ym(r,t){return!!t.__parseExpression(r.value)}function Zm(r,t){return t?vt(t)?r.__parseExpression(t):t:"div"}function Qm(r,t,e){const n=an(t,e);return n.ref=e.__ref(r,n.ref),n}function an(r,t){return vt(r)?t.__parseExpression(r):pt(r)?t.__parseFunction(r):Array.isArray(r)?r.map(e=>an(e,t)):typeof r=="object"?Object.keys(r||{}).reduce((e,n)=>{let i=r[n];return e[n]=an(i,t),e},{}):r}function Xm(r,t){return e=>{var n;((n=e==null?void 0:e.key)==null?void 0:n.toLowerCase())===t.toLowerCase()&&r(e)}}function ty(r,t,e){const n=["passive","capture","once"],i={capture:"Capture",once:"Once",passive:"OnceCapture"};return Object.keys(t||{}).reduce((s,o)=>{const u=t[o],l=ia(u.modifiers),a=l.find(h=>n.includes(h)),c="on"+Ms(o)+(a&&i[a]||""),f=e.__parseFunction(u.handler);return f&&(s[c]=r.withModifiers(l.includes("enter")?Xm(f,"enter"):f,l)),s},{})}function ey(r,t,e,n,i=[]){let s=i.findIndex(o=>o.id===r.id);for(let o=++s;o<i.length;o++){const{directives:u=[]}=i[o],{vElseIf:l,vElse:a}=na(u);if(l){if(t.__parseExpression(l.value))return oe(i[o],t,e,n,i,!0);continue}if(a)return oe(i[o],t,e,n,i,!0)}return null}function ia(r={},t=!1){const e=Object.keys(r);return t?e.map(n=>"."+n):e}function ry(r,t,e,n,i){var l;const{children:s}=t,o=ny(t,n),u=(l=n.$slots)==null?void 0:l[o.name];return u?u(e):s?jt(s)?r.createTextVNode(s):vt(s)?r.createTextVNode(Zo(n.__parseExpression(s))):Array.isArray(s)?s.map(a=>oe(a,n,r,i,s)):null:null}function ny(r,t){const{props:e}=r,n=(e==null?void 0:e.name)||"default";return{name:vt(n)?t.__parseExpression(n):n,params:[]}}function iy(r,t){return t.__parseExpression(r.value)?{}:{display:"none"}}function sy(r,t){return{innerHTML:t.__parseExpression(r.value)||""}}function oy(r,t,e){var u;const n={type:"JSFunction",value:(u=t.value)!=null&&u.value?`(v) => {
67
67
  ${t.value.value} = v;
68
- }`:"(v) => {}"},i=e.__parseFunction(n),s=ia(vt(t.modifiers)?e.__parseExpression(t.modifiers):t.modifiers),o=vt(t.arg)?e.__parseExpression(t.arg):t.arg||"modelValue";return{[o]:e.__parseExpression(t.value),[`onUpdate:${o}`]:s.length&&i?r.withModifiers(i,s):i}}function oy(r,t,e,n,i){if(!t)return null;if(jt(t))return{default:()=>t};if(vt(t))return{default:()=>Zo(e.__parseExpression(t))};if(Array.isArray(t)&&t.length>0){const s=ay(t),o=(u,l)=>!u||!i?{}:i!=null&&i.id&&Object.keys(u).length?l?{[l]:u}:{[`scope_${i.id}`]:u}:l?{[l]:Object.create(null)}:{};return Object.entries(s).reduce((u,[l,{nodes:a,params:c,scope:f}])=>(u[l]=h=>{const p=c.length?Wd(h!=null?h:{},c):o(h,f);return a.map(d=>oe(d,e.__clone(p),r,n,a))},u),{})}return null}function ay(r){const t={};for(const e of r){const n=uy(e.slot),i=n.name;t[i]?(t[i].nodes.push(e),t[i].params=t[i].params.concat(n.params),t[i].scope=n.scope||""):t[i]={nodes:[e],params:n.params,scope:n.scope||""}}return t}function uy(r="default"){return jt(r)?{name:r,params:[],scope:""}:H({params:[],scope:""},r)}function cy(r,t,e){const{value:n,iterator:i}=r,{item:s="item",index:o="index"}=i||{};let u=e.__parseExpression(n)||[];return Number.isInteger(u)&&(u=new Array(u).fill(!0).map((l,a)=>a+1)),Array.isArray(u)?u.map((l,a)=>t(e.__clone({[s]:l,[o]:a}),a)):(console.warn("[vForRender]:",`${n==null?void 0:n.value} is not a Arrary`),[])}const Ir=ss({name:"VtjPageContainer",setup(){return U(this,null,function*(){const r=_y(),t=ya(),e=t.meta.__vtj__||t.params.id,n=e?r.getPage(e):r.getHomepage(),i=n?yield r.getRenderComponent(n.id):null,s=va(Symbol());if(n){Object.assign(t.meta,n.meta||{},{cache:n.cache});const{useTitle:o}=r==null?void 0:r.adapter;if(o){const u=t.meta.title||n.title||"VTJ.PRO";o(u)}}return{provider:r,component:i,file:n,query:t.query,meta:t.meta,sid:s,route:t}})},render(){const{component:r,query:t,sid:e}=this;return r?Fr(r,et(H({},t),{key:e})):Fr("div","页面不存在")},activated(){this.meta.cache===!1&&(this.sid=Symbol())}}),ly=ss({name:"VtjStartupContainer",render(){return Fr("div","page not found!")}});function un(r,t,e=[]){const n=[];for(const i of e){const{id:s,title:o,icon:u,children:l,hidden:a,layout:c}=i;if(c){const f=un(r,t,l||[]);n.push(...f)}else{const f={id:s,title:o,icon:u,hidden:a,url:`${r}/${t}/${s}`,children:l&&l.length?un(r,t,l):void 0};n.push(f)}}return n}function Mr(r,t){const{id:e,title:n,meta:i}=r,{name:s="page",prefix:o="",component:u,routeMeta:l}=t;return{name:e,path:`${o}${s}/${e}`,component:u,meta:et(H(H({title:n},l),i),{__vtj__:e})}}function cn(r){const{name:t="page",prefix:e="",pages:n=[],component:i,loader:s,routeMeta:o,homepage:u}=r,l=[];for(const a of n){const{id:c,title:f,dir:h,layout:p,children:d,meta:g}=a;if(h){const b=cn({name:t,prefix:e,component:i,routeMeta:o,homepage:u,loader:s,pages:d||[]});l.push(...b)}else if(p){const b=cn({name:t,prefix:e,component:i,routeMeta:o,homepage:u,loader:s,pages:d||[]}),w={name:`layout_${c}`,path:e,component:()=>s(c),meta:et(H(H({title:f},o),g),{__vtj__:c}),children:b};l.push(w),l.push(Mr(a,r))}else if(l.push(Mr(a,r)),u===c){const b=Mr(a,r);b.path="",b.name=`home_${c}`,l.push(b)}}return l}function fy(r={},t){const{css:e,store:n,enhance:i}=r,{window:s,app:o,library:u={},adapter:l,mode:a}=t,{Pinia:c}=u;o.config.globalProperties.$libs=u,fr(s,"global-css",e||""),c&&n&&hy(n,o,c),dy(o,l,r),!l.access&&r.access&&py(r.access,o,a,l),gy(o,r),i&&vy(i,o,u)}function hy(r,t,e){const n=e.createPinia();if(t.use(n),pt(r)&&r.value){const i=ht(r,{},!1,!1,!0),s=e.defineStore("$store",i(t)||{});t.config.globalProperties.$store=s()}}function py(r,t,e,n){if(pt(r)&&r.value){const i=ht(r,{},!1,!1,!0),{alert:s,request:o}=n,u=new ta(H({alert:s,storagePrefix:"__VTJ_APP_"},i(t))),l=t.config.globalProperties.$router;u.connect({mode:e,router:l,request:o}),t.use(u)}}function dy(r,t,e){if(!t.request)return;const{axios:n,request:i,response:s}=e;if(n&&pt(n)&&n.value){const o=ht(n,{},!1,!1,!0);t.request.setConfig(o(r))}if(i&&pt(i)&&i.value){const o=ht(i,{},!1,!1,!0),u=t.request;u.__unReq&&u.__unReq(),u.__unReq=t.request.useRequest(l=>o(l,r))}if(s&&pt(s)&&s.value){const o=ht(s,{},!1,!1,!0),u=t.request;u.__unRes&&u.__unRes(),u.__unRes=t.request.useResponse(l=>o(l,r))}}function gy(r,t){const{beforeEach:e,afterEach:n}=t,i=r.config.globalProperties.$router;if(e&&pt(e)&&e.value){const s=ht(e,{},!1,!1,!0);i&&i.beforeEach((o,u,l)=>s(o,u,l,r))}if(n&&pt(n)&&n.value){const s=ht(n,{},!1,!1,!0);i&&i.afterEach((o,u,l)=>s(o,u,l,r))}}function vy(r,t,e={}){pt(r)&&r.value&&ht(r,{},!1,!1,!0)(t,e)}function my(r,t,e){if(!r||!t||!e)return;const{VueI18n:n}=t;if(n){const{locale:i,fallbackLocale:s,messages:o=[]}=e,u={};for(let a of o){const c=Object.keys(a).filter(f=>f!=="key");for(const f of c)u[f]||(u[f]={}),u[f][a.key]=a[f]}const l=n.createI18n({legacy:!1,locale:i,fallbackLocale:s,messages:u});r.use(l)}}const sa=Symbol("Provider");class yy extends ug{constructor(e){super();q(this,"mode");q(this,"globals",{});q(this,"modules",{});q(this,"adapter",{request:tn,jsonp:Yo});q(this,"apis",{});q(this,"dependencies",{});q(this,"materials",{});q(this,"library",{});q(this,"libraryLocales",{});q(this,"libraryLocaleMap",{});q(this,"service");q(this,"project",null);q(this,"components",{});q(this,"nodeEnv","development");q(this,"env",{});q(this,"router",null);q(this,"materialPath","./");q(this,"urlDslCaches",{});q(this,"errorHandler",null);this.options=e;const{service:n,mode:i=X.Raw,dependencies:s,materials:o,project:u={},adapter:l={},globals:a={},modules:c={},router:f=null,materialPath:h="./",nodeEnv:p="development"}=e;this.mode=i,this.modules=c,this.service=n,this.router=f,this.materialPath=h,this.nodeEnv=p,s&&(this.dependencies=s),o&&(this.materials=o),Object.assign(this.globals,a),Object.assign(this.adapter,l);const{access:d,request:g}=this.adapter;d&&d.connect({mode:i,router:f,request:g}),u&&i!==X.Design?this.load(u):this.project=u}createMock(e){return(...n)=>U(null,null,function*(){var s;let i={};if(e)try{i=yield e.apply(e,n)}catch(o){ie.warn("模拟数据模版异常",o)}return(s=we())==null?void 0:s.mock(i)})}load(e){return U(this,null,function*(){const{vtjDir:n=".vtj"}=this.options,i=this.modules[`${n}/projects/${e.id}.json`]||this.modules[`/src/${n}/projects/${e.id}.json`];if(this.project=i?yield i():yield this.service.init(e),!this.project)throw new Error("project is null");const{apis:s=[],meta:o=[],env:u=[]}=this.project,l=window;l&&(l.CKEDITOR_VERSION=void 0),this.initEnv(u),this.mode===X.Raw?yield this.loadDependencies(l):yield this.loadAssets(l),this.initMock(l),this.apis=jm(s,o,this.adapter),ea(l),Pm(s,l),e.platform!=="uniapp"&&this.initRouter(),this.triggerReady()})}initMock(e){const n=we(e);n&&n.setup({timeout:"50-500"})}loadDependencies(){return U(this,arguments,function*(e={}){const n=Object.entries(this.dependencies);for(const[i,s]of n)e[i]||(e[i]=this.library[i]=yield s())})}loadAssets(){return U(this,arguments,function*(e={}){const{dependencies:n=[]}=this.project,{dependencies:i,library:s,components:o,materialPath:u,nodeEnv:l,libraryLocales:a}=this,{libraryExports:c,libraryMap:f,materials:h,materialExports:p,materialMapLibrary:d,libraryLocaleMap:g}=mm(n,u,l==="development");Object.assign(this.libraryLocaleMap,g);for(const b of c){const w=i[b],m=e[b];if(m)s[b]=m;else if(w)e[b]=s[b]=yield w();else{const _=f[b]||[];for(const S of _)cr(S)&&(yield Tm(S,We.append(S,{v:jr}))),lr(S)&&(yield ts(We.append(S,{v:jr})));s[b]=e[b]}const y=g[b];if(y){const _=i[y];a[y]=_?yield _():e[y]}}if(l==="development"){for(const w of h)yield ts(We.append(w,{v:jr}));const b=this.materials||{};for(const w of p){const m=e[d[w]],y=(m==null?void 0:m.default)||m,_=ag[w];if(_)y&&_.forEach(S=>{o[S]=y[S]});else{const S=b[w]?(yield b[w]()).default:e[w];S&&y&&(S.components||[]).forEach(v=>{o[v.name]=ym(v,y)})}}}})}initRouter(){const{router:e,project:n,options:i,adapter:s}=this;if(!e)return;const o=(n==null?void 0:n.platform)==="uniapp"?"pages":"page",{routeAppendTo:u,pageRouteName:l=o,routeMeta:a}=i,c=u?"":"/",f={path:`${c}${l}/:id`,name:Ke,component:Ir},h={path:c,name:Pr,component:n!=null&&n.homepage?Ir:s.startupComponent||ly,meta:a};if(e.hasRoute(Ke)&&e.removeRoute(Ke),e.hasRoute(Pr)&&e.removeRoute(Pr),i.enableStaticRoute){const p=(n==null?void 0:n.pages)||[];cn({name:l,prefix:c,pages:p,component:Ir,loader:this.getRenderComponent.bind(this),homepage:n==null?void 0:n.homepage}).forEach(d=>{u?e.addRoute(u,d):e.addRoute(d)}),n!=null&&n.homepage||(u?e.addRoute(u,h):e.addRoute(h))}else u?(e.addRoute(u,f),e.addRoute(u,h)):(e.addRoute(f),e.addRoute(h))}setErrorHandler(e){e.config.errorHandler=bn((n,i,s)=>{const o=i==null?void 0:i.$options.name,u=typeof n=="string"?n:(n==null?void 0:n.message)||(n==null?void 0:n.msg)||"未知错误",l=`[ ${o} ] ${u} ${s}`;["getComputedStyle","ResizeObserver"].some(a=>l.includes(a))||(console.error("[VTJ Error]:",{err:n,instance:i,info:s},n==null?void 0:n.stack),this.errorHandler&&this.errorHandler(n),this.adapter.notify&&this.adapter.notify(l,"组件渲染错误","error"))},300)}install(e){var u,l,a,c;const{libraryLocaleMap:n,libraryLocales:i}=this,{libraryOptions:s={}}=this.options,o=e.config.globalProperties.installed||{};for(const[f,h]of Object.entries(this.library))if(!o[f]&&Rm(h)){const p={locale:i[n[f]]},d=s[f]||{},g=H(H({},p),d);e.use(h,g),o[f]=!0}e.provide(sa,this),e.config.globalProperties.$provider=this,e.config.globalProperties.$request=(u=this.adapter)==null?void 0:u.request,this.options.install&&e.use(this.options.install),this.adapter.access&&e.use(this.adapter.access),((l=this.project)==null?void 0:l.platform)!=="uniapp"&&this.mode!==X.Design&&this.initGlobals(((a=this.project)==null?void 0:a.globals)||{},{app:e,window,adapter:this.adapter,library:this.library,mode:this.mode}),this.mode!==X.Design&&((c=this.project)!=null&&c.i18n)&&this.initI18n(e,this.library,this.project.i18n),this.options.enhance&&e.use(this.options.enhance,this),this.mode===X.Design&&this.setErrorHandler(e),e.config.globalProperties.installed=o}getFile(e){const{blocks:n=[]}=this.project||{};return this.getPage(e)||n.find(i=>i.id===e)||null}getPage(e){const{pages:n=[]}=this.project||{},i=(s,o=[])=>{for(const u of o){if(u.id===s)return u;if(u.children&&u.children.length){const l=i(s,u.children);if(l)return l}}};return i(e,n)||null}getMenus(e="page",n=""){var i;return un(n,e,((i=this.project)==null?void 0:i.pages)||[])}getHomepage(){const{homepage:e}=this.project||{};return e?this.getPage(e):null}getDsl(e){return U(this,null,function*(){const{vtjDir:n=".vtj"}=this.options,i=this.modules[`${n}/files/${e}.json`]||this.modules[`/src/${n}/files/${e}.json`];return i?yield i():this.service.getFile(e,this.project||void 0).catch(()=>null)})}getDslByUrl(e){return U(this,null,function*(){return this.urlDslCaches[e]||(this.adapter.request?this.urlDslCaches[e]=this.adapter.request.send({url:e,method:"get",settings:{validSuccess:!1,originResponse:!0}}).then(i=>i.data).catch(()=>null):null)})}createDslRenderer(e,n={}){const{library:i,components:s,mode:o,apis:u}=this,l=H({mode:o,Vue:i.Vue,components:s,libs:i,apis:u,window},n),a=on({getDsl:c=>U(this,null,function*(){return(yield this.getDsl(c))||null}),getDslByUrl:c=>U(this,null,function*(){return(yield this.getDslByUrl(c))||null}),options:l});return sn(et(H({},l),{dsl:e,loader:a}))}getRenderComponent(e,n){return U(this,null,function*(){var o;const i=this.getFile(e);if(!i)return ie.warn(`Can not find file: ${e}`),null;if(n&&n(i),this.mode===X.Raw){const{vtjRawDir:u=".vtj/vue"}=this.options,l=`${u}/${e}.vue`,a=this.modules[l]||this.modules[`/src/pages/${e}.vue`];return a?(o=yield a())==null?void 0:o.default:this.nodeEnv==="development"&&this.adapter.startupComponent||null}const s=yield this.getDsl(i.id);return s?this.createDslRenderer(s).renderer:(ie.warn(`Can not find dsl: ${e}`),null)})}defineUrlSchemaComponent(e,n){return Cn(()=>U(this,null,function*(){const i=yield this.getDslByUrl(e);return i?(i.name=n||i.name,this.createDslRenderer(i).renderer):null}))}definePluginComponent(e){return Cn(()=>U(null,null,function*(){return yield ra(e,window)}))}initGlobals(e,n){const i=Object.assign({adapter:this.adapter,window},n);fy(e,i)}initI18n(e,n,i){my(e,n,i)}initEnv(e=[]){this.env=e.reduce((n,i)=>(n[i.name]=i[this.nodeEnv],n),{})}}function by(r){const t=new yy(r);return{provider:t,onReady:e=>t.ready(e)}}function _y(r={}){const t=ma(sa,null);if(!t)throw new Error("Can not find provider");if(t.nodeEnv==="development"){const{id:e,version:n}=r;e&&n&&U(null,null,function*(){const i=yield t.getDsl(e);(i==null?void 0:i.__VERSION__)!==n&&t.adapter.notify&&t.adapter.notify(`[ ${i==null?void 0:i.name} ] 组件源码版本与运行时版本不一致,请重新发布组件`,"版本不一致","warning")})}return t}function wy(r,t=""){return U(this,null,function*(){const{name:e,urls:n=[]}=r||{},i=n.map(u=>t+u),{css:s,js:o}=bm(i);if(s.length&&Qo(s),o.length)return yield Xo(o,e).catch(()=>{})})}const oa={type:"json",validSuccess:!0,originResponse:!1,failMessage:!0,validate:r=>{var t;return((t=r.data)==null?void 0:t.code)===0}},Ey=(r,t="/__vtj__/api/:type.json")=>(e,n,i)=>r.send({url:t,method:"post",params:{type:e},query:i,data:{type:e,data:n},settings:oa}),Sy=(r,t="/__vtj__/api/uploader.json")=>(e,n)=>U(null,null,function*(){return yield r.send({url:t,method:"post",data:{files:e,projectId:n},settings:et(H({},oa),{type:"data"})}).then(i=>i&&i[0]?i[0]:null).catch(()=>null)});function Ty(r){return An({settings:{type:"json",validSuccess:!0,originResponse:!1,failMessage:!0,validate:t=>{var e;return((e=t.data)==null?void 0:e.code)===0},showError:t=>{r&&r(t||"未知错误")}}})}class Ry{constructor(t=tn){q(this,"api");q(this,"pluginCaches",{});q(this,"uploader");this.req=t,this.api=Ey(t),this.uploader=Sy(t)}getExtension(){return U(this,null,function*(){console.log("BaseService.getExtension")})}init(t){return U(this,null,function*(){return console.log("BaseService.init",t),{}})}saveProject(t,e){return U(this,null,function*(){return!!(yield this.api("saveProject",t,{type:e}).catch(()=>!1))})}saveMaterials(t,e){return U(this,null,function*(){return console.log("BaseService.saveMaterials",t,e),!1})}saveFile(t){return U(this,null,function*(){return console.log("BaseService.saveFile",t),!1})}getFile(t){return U(this,null,function*(){return console.log("BaseService.getFile",t),{}})}removeFile(t){return U(this,null,function*(){return console.log("BaseService.removeFile",t),!1})}saveHistory(t){return U(this,null,function*(){return console.log("BaseService.saveHistory",t),!1})}removeHistory(t){return U(this,null,function*(){return console.log("BaseService.removeHistory",t),!1})}getHistory(t){return U(this,null,function*(){return console.log("BaseService.getHistory",t),{}})}getHistoryItem(t,e){return U(this,null,function*(){return console.log("BaseService.getHistoryItem",t,e),{}})}saveHistoryItem(t,e){return U(this,null,function*(){return console.log("BaseService.saveHistoryItem",t,e),!1})}removeHistoryItem(t,e){return U(this,null,function*(){return console.log("BaseService.removeHistoryItem",t,e),!1})}publish(t){return U(this,null,function*(){return!!(yield this.api("publish",t).catch(()=>!1))})}publishFile(t,e){return U(this,null,function*(){return!!(yield this.api("publishFile",{project:t,file:e}).catch(()=>!1))})}genVueContent(t,e){return U(this,null,function*(){return yield this.api("genVueContent",{project:t,dsl:e}).catch(()=>"")})}parseVue(t,e){return U(this,null,function*(){return yield this.api("parseVue",H({project:t},e))})}createRawPage(t){return U(this,null,function*(){return yield this.api("createRawPage",t).catch(()=>"")})}removeRawPage(t){return U(this,null,function*(){return yield this.api("removeRawPage",t).catch(()=>"")})}uploadStaticFile(t,e){return U(this,null,function*(){return yield this.uploader(t,e).catch(()=>null)})}getStaticFiles(t){return U(this,null,function*(){return yield this.api("getStaticFiles",t).catch(()=>[])})}removeStaticFile(t,e){return U(this,null,function*(){return yield this.api("removeStaticFile",{name:t,projectId:e}).catch(()=>"")})}clearStaticFiles(t){return U(this,null,function*(){return yield this.api("clearStaticFiles",t).catch(()=>"")})}getPluginMaterial(t){return U(this,null,function*(){const{urls:e=[]}=t,n=e.filter(s=>gm(s))[0];return n?this.pluginCaches[n]||(this.pluginCaches[n]=tn.send({url:n,method:"get",settings:{validSuccess:!1,originResponse:!0}}).then(s=>s.data).catch(()=>null)):null})}genSource(t){return U(this,null,function*(){return console.log("BaseService.genSource",t),""})}}new Wo({type:"local",expired:0,prefix:"__VTJ_"});class xy extends Ry{constructor(){super(...arguments);q(this,"getFileCaches",{})}getExtension(){return U(this,null,function*(){return yield this.api("getExtension",{}).catch(()=>{})})}init(e){return U(this,null,function*(){return(yield this.api("init",e).catch(()=>null))||{}})}saveProject(e,n){return U(this,null,function*(){return!!(yield this.api("saveProject",e,{type:n}).catch(()=>!1))})}saveMaterials(e,n){return U(this,null,function*(){return!!(yield this.api("saveMaterials",{project:e,materials:qd(n)}).catch(()=>!1))})}saveFile(e){return U(this,null,function*(){return!!(yield this.api("saveFile",e).catch(()=>!1))})}getFile(e){return U(this,null,function*(){return this.getFileCaches[e]||(this.getFileCaches[e]=this.api("getFile",e).catch(()=>null)).finally(()=>{delete this.getFileCaches[e]})})}removeFile(e){return U(this,null,function*(){return!!(yield this.api("removeFile",e).catch(()=>!1))})}saveHistory(e){return U(this,null,function*(){return!!(yield this.api("saveHistory",e).catch(()=>!1))})}removeHistory(e){return U(this,null,function*(){return!!(yield this.api("removeHistory",e).catch(()=>!1))})}getHistory(e){return U(this,null,function*(){return(yield this.api("getHistory",e).catch(()=>null))||{}})}getHistoryItem(e,n){return U(this,null,function*(){return(yield this.api("getHistoryItem",{fId:e,id:n}).catch(()=>null))||{}})}saveHistoryItem(e,n){return U(this,null,function*(){return!!(yield this.api("saveHistoryItem",{fId:e,item:n}).catch(()=>!1))})}removeHistoryItem(e,n){return U(this,null,function*(){return!!(yield this.api("removeHistoryItem",{fId:e,ids:n}).catch(()=>!1))})}}/**!
68
+ }`:"(v) => {}"},i=e.__parseFunction(n),s=ia(vt(t.modifiers)?e.__parseExpression(t.modifiers):t.modifiers),o=vt(t.arg)?e.__parseExpression(t.arg):t.arg||"modelValue";return{[o]:e.__parseExpression(t.value),[`onUpdate:${o}`]:s.length&&i?r.withModifiers(i,s):i}}function ay(r,t,e,n,i){if(!t)return null;if(jt(t))return{default:()=>t};if(vt(t))return{default:()=>Zo(e.__parseExpression(t))};if(Array.isArray(t)&&t.length>0){const s=uy(t),o=(u,l)=>!u||!i?{}:i!=null&&i.id&&Object.keys(u).length?l?{[l]:u}:{[`scope_${i.id}`]:u}:l?{[l]:Object.create(null)}:{};return Object.entries(s).reduce((u,[l,{nodes:a,params:c,scope:f}])=>(u[l]=h=>{const p=c.length?Wd(h!=null?h:{},c):o(h,f);return a.map(d=>oe(d,e.__clone(p),r,n,a))},u),{})}return null}function uy(r){const t={};for(const e of r){const n=cy(e.slot),i=n.name;t[i]?(t[i].nodes.push(e),t[i].params=t[i].params.concat(n.params),t[i].scope=n.scope||""):t[i]={nodes:[e],params:n.params,scope:n.scope||""}}return t}function cy(r="default"){return jt(r)?{name:r,params:[],scope:""}:H({params:[],scope:""},r)}function ly(r,t,e){const{value:n,iterator:i}=r,{item:s="item",index:o="index"}=i||{};let u=e.__parseExpression(n)||[];return Number.isInteger(u)&&(u=new Array(u).fill(!0).map((l,a)=>a+1)),Array.isArray(u)?u.map((l,a)=>t(e.__clone({[s]:l,[o]:a}),a)):(console.warn("[vForRender]:",`${n==null?void 0:n.value} is not a Arrary`),[])}const Ir=ss({name:"VtjPageContainer",setup(){return U(this,null,function*(){const r=wy(),t=ya(),e=t.meta.__vtj__||t.params.id,n=e?r.getPage(e):r.getHomepage(),i=n?yield r.getRenderComponent(n.id):null,s=va(Symbol());if(n){Object.assign(t.meta,n.meta||{},{cache:n.cache});const{useTitle:o}=r==null?void 0:r.adapter;if(o){const u=t.meta.title||n.title||"VTJ.PRO";o(u)}}return{provider:r,component:i,file:n,query:t.query,meta:t.meta,sid:s,route:t}})},render(){const{component:r,query:t,sid:e}=this;return r?Fr(r,et(H({},t),{key:e})):Fr("div","页面不存在")},activated(){this.meta.cache===!1&&(this.sid=Symbol())}}),fy=ss({name:"VtjStartupContainer",render(){return Fr("div","page not found!")}});function un(r,t,e=[]){const n=[];for(const i of e){const{id:s,title:o,icon:u,children:l,hidden:a,layout:c}=i;if(c){const f=un(r,t,l||[]);n.push(...f)}else{const f={id:s,title:o,icon:u,hidden:a,url:`${r}/${t}/${s}`,children:l&&l.length?un(r,t,l):void 0};n.push(f)}}return n}function Mr(r,t){const{id:e,title:n,meta:i}=r,{name:s="page",prefix:o="",component:u,routeMeta:l}=t;return{name:e,path:`${o}${s}/${e}`,component:u,meta:et(H(H({title:n},l),i),{__vtj__:e})}}function cn(r){const{name:t="page",prefix:e="",pages:n=[],component:i,loader:s,routeMeta:o,homepage:u}=r,l=[];for(const a of n){const{id:c,title:f,dir:h,layout:p,children:d,meta:g}=a;if(h){const b=cn({name:t,prefix:e,component:i,routeMeta:o,homepage:u,loader:s,pages:d||[]});l.push(...b)}else if(p){const b=cn({name:t,prefix:e,component:i,routeMeta:o,homepage:u,loader:s,pages:d||[]}),w={name:`layout_${c}`,path:e,component:()=>s(c),meta:et(H(H({title:f},o),g),{__vtj__:c}),children:b};l.push(w),l.push(Mr(a,r))}else if(l.push(Mr(a,r)),u===c){const b=Mr(a,r);b.path="",b.name=`home_${c}`,l.push(b)}}return l}function hy(r={},t){const{css:e,store:n,enhance:i}=r,{window:s,app:o,library:u={},adapter:l,mode:a}=t,{Pinia:c}=u;o.config.globalProperties.$libs=u,fr(s,"global-css",e||""),c&&n&&py(n,o,c),gy(o,l,r),!l.access&&r.access&&dy(r.access,o,a,l),vy(o,r),i&&my(i,o,u)}function py(r,t,e){const n=e.createPinia();if(t.use(n),pt(r)&&r.value){const i=ht(r,{},!1,!1,!0),s=e.defineStore("$store",i(t)||{});t.config.globalProperties.$store=s()}}function dy(r,t,e,n){if(pt(r)&&r.value){const i=ht(r,{},!1,!1,!0),{alert:s,request:o}=n,u=new ta(H({alert:s,storagePrefix:"__VTJ_APP_"},i(t))),l=t.config.globalProperties.$router;u.connect({mode:e,router:l,request:o}),t.use(u)}}function gy(r,t,e){if(!t.request)return;const{axios:n,request:i,response:s}=e;if(n&&pt(n)&&n.value){const o=ht(n,{},!1,!1,!0);t.request.setConfig(o(r))}if(i&&pt(i)&&i.value){const o=ht(i,{},!1,!1,!0),u=t.request;u.__unReq&&u.__unReq(),u.__unReq=t.request.useRequest(l=>o(l,r))}if(s&&pt(s)&&s.value){const o=ht(s,{},!1,!1,!0),u=t.request;u.__unRes&&u.__unRes(),u.__unRes=t.request.useResponse(l=>o(l,r))}}function vy(r,t){const{beforeEach:e,afterEach:n}=t,i=r.config.globalProperties.$router;if(e&&pt(e)&&e.value){const s=ht(e,{},!1,!1,!0);i&&i.beforeEach((o,u,l)=>s(o,u,l,r))}if(n&&pt(n)&&n.value){const s=ht(n,{},!1,!1,!0);i&&i.afterEach((o,u,l)=>s(o,u,l,r))}}function my(r,t,e={}){pt(r)&&r.value&&ht(r,{},!1,!1,!0)(t,e)}function yy(r,t,e){if(!r||!t||!e)return;const{VueI18n:n}=t;if(n){const{locale:i,fallbackLocale:s,messages:o=[]}=e,u={};for(let a of o){const c=Object.keys(a).filter(f=>f!=="key");for(const f of c)u[f]||(u[f]={}),u[f][a.key]=a[f]}const l=n.createI18n({legacy:!1,locale:i,fallbackLocale:s,messages:u});r.use(l)}}const sa=Symbol("Provider");class by extends ug{constructor(e){super();q(this,"mode");q(this,"globals",{});q(this,"modules",{});q(this,"adapter",{request:tn,jsonp:Yo});q(this,"apis",{});q(this,"dependencies",{});q(this,"materials",{});q(this,"library",{});q(this,"libraryLocales",{});q(this,"libraryLocaleMap",{});q(this,"service");q(this,"project",null);q(this,"components",{});q(this,"nodeEnv","development");q(this,"env",{});q(this,"router",null);q(this,"materialPath","./");q(this,"urlDslCaches",{});q(this,"errorHandler",null);this.options=e;const{service:n,mode:i=X.Raw,dependencies:s,materials:o,project:u={},adapter:l={},globals:a={},modules:c={},router:f=null,materialPath:h="./",nodeEnv:p="development"}=e;this.mode=i,this.modules=c,this.service=n,this.router=f,this.materialPath=h,this.nodeEnv=p,s&&(this.dependencies=s),o&&(this.materials=o),Object.assign(this.globals,a),Object.assign(this.adapter,l);const{access:d,request:g}=this.adapter;d&&d.connect({mode:i,router:f,request:g}),u&&i!==X.Design?this.load(u):this.project=u}createMock(e){return(...n)=>U(null,null,function*(){var s;let i={};if(e)try{i=yield e.apply(e,n)}catch(o){ie.warn("模拟数据模版异常",o)}return(s=we())==null?void 0:s.mock(i)})}load(e){return U(this,null,function*(){const{vtjDir:n=".vtj"}=this.options,i=this.modules[`${n}/projects/${e.id}.json`]||this.modules[`/src/${n}/projects/${e.id}.json`];if(this.project=i?yield i():yield this.service.init(e),!this.project)throw new Error("project is null");const{apis:s=[],meta:o=[],env:u=[]}=this.project,l=window;l&&(l.CKEDITOR_VERSION=void 0),this.initEnv(u),this.mode===X.Raw?yield this.loadDependencies(l):yield this.loadAssets(l),this.initMock(l),this.apis=jm(s,o,this.adapter),ea(l),Pm(s,l),e.platform!=="uniapp"&&this.initRouter(),this.triggerReady()})}initMock(e){const n=we(e);n&&n.setup({timeout:"50-500"})}loadDependencies(){return U(this,arguments,function*(e={}){const n=Object.entries(this.dependencies);for(const[i,s]of n)e[i]||(e[i]=this.library[i]=yield s())})}loadAssets(){return U(this,arguments,function*(e={}){const{dependencies:n=[]}=this.project,{dependencies:i,library:s,components:o,materialPath:u,nodeEnv:l,libraryLocales:a}=this,{libraryExports:c,libraryMap:f,materials:h,materialExports:p,materialMapLibrary:d,libraryLocaleMap:g}=mm(n,u,l==="development");Object.assign(this.libraryLocaleMap,g);for(const b of c){const w=i[b],m=e[b];if(m)s[b]=m;else if(w)e[b]=s[b]=yield w();else{const _=f[b]||[];for(const S of _)cr(S)&&(yield Tm(S,We.append(S,{v:jr}))),lr(S)&&(yield ts(We.append(S,{v:jr})));s[b]=e[b]}const y=g[b];if(y){const _=i[y];a[y]=_?yield _():e[y]}}if(l==="development"){for(const w of h)yield ts(We.append(w,{v:jr}));const b=this.materials||{};for(const w of p){const m=e[d[w]],y=(m==null?void 0:m.default)||m,_=ag[w];if(_)y&&_.forEach(S=>{o[S]=y[S]});else{const S=b[w]?(yield b[w]()).default:e[w];S&&y&&(S.components||[]).forEach(v=>{o[v.name]=ym(v,y)})}}}})}initRouter(){const{router:e,project:n,options:i,adapter:s}=this;if(!e)return;const o=(n==null?void 0:n.platform)==="uniapp"?"pages":"page",{routeAppendTo:u,pageRouteName:l=o,routeMeta:a}=i,c=u?"":"/",f={path:`${c}${l}/:id`,name:Ke,component:Ir},h={path:c,name:Pr,component:n!=null&&n.homepage?Ir:s.startupComponent||fy,meta:a};if(e.hasRoute(Ke)&&e.removeRoute(Ke),e.hasRoute(Pr)&&e.removeRoute(Pr),i.enableStaticRoute){const p=(n==null?void 0:n.pages)||[];cn({name:l,prefix:c,pages:p,component:Ir,loader:this.getRenderComponent.bind(this),homepage:n==null?void 0:n.homepage}).forEach(d=>{u?e.addRoute(u,d):e.addRoute(d)}),n!=null&&n.homepage||(u?e.addRoute(u,h):e.addRoute(h))}else u?(e.addRoute(u,f),e.addRoute(u,h)):(e.addRoute(f),e.addRoute(h))}setErrorHandler(e){e.config.errorHandler=bn((n,i,s)=>{const o=i==null?void 0:i.$options.name,u=typeof n=="string"?n:(n==null?void 0:n.message)||(n==null?void 0:n.msg)||"未知错误",l=`[ ${o} ] ${u} ${s}`;["getComputedStyle","ResizeObserver"].some(a=>l.includes(a))||(console.error("[VTJ Error]:",{err:n,instance:i,info:s},n==null?void 0:n.stack),this.errorHandler&&this.errorHandler(n),this.adapter.notify&&this.adapter.notify(l,"组件渲染错误","error"))},300)}install(e){var u,l,a,c;const{libraryLocaleMap:n,libraryLocales:i}=this,{libraryOptions:s={}}=this.options,o=e.config.globalProperties.installed||{};for(const[f,h]of Object.entries(this.library))if(!o[f]&&Rm(h)){const p={locale:i[n[f]]},d=s[f]||{},g=H(H({},p),d);e.use(h,g),o[f]=!0}e.provide(sa,this),e.config.globalProperties.$provider=this,e.config.globalProperties.$request=(u=this.adapter)==null?void 0:u.request,this.options.install&&e.use(this.options.install),this.adapter.access&&e.use(this.adapter.access),((l=this.project)==null?void 0:l.platform)!=="uniapp"&&this.mode!==X.Design&&this.initGlobals(((a=this.project)==null?void 0:a.globals)||{},{app:e,window,adapter:this.adapter,library:this.library,mode:this.mode}),this.mode!==X.Design&&((c=this.project)!=null&&c.i18n)&&this.initI18n(e,this.library,this.project.i18n),this.options.enhance&&e.use(this.options.enhance,this),this.mode===X.Design&&this.setErrorHandler(e),e.config.globalProperties.installed=o}getFile(e){const{blocks:n=[]}=this.project||{};return this.getPage(e)||n.find(i=>i.id===e)||null}getPage(e){const{pages:n=[]}=this.project||{},i=(s,o=[])=>{for(const u of o){if(u.id===s)return u;if(u.children&&u.children.length){const l=i(s,u.children);if(l)return l}}};return i(e,n)||null}getMenus(e="page",n=""){var i;return un(n,e,((i=this.project)==null?void 0:i.pages)||[])}getHomepage(){const{homepage:e}=this.project||{};return e?this.getPage(e):null}getDsl(e){return U(this,null,function*(){const{vtjDir:n=".vtj"}=this.options,i=this.modules[`${n}/files/${e}.json`]||this.modules[`/src/${n}/files/${e}.json`];return i?yield i():this.service.getFile(e,this.project||void 0).catch(()=>null)})}getDslByUrl(e){return U(this,null,function*(){return this.urlDslCaches[e]||(this.adapter.request?this.urlDslCaches[e]=this.adapter.request.send({url:e,method:"get",settings:{validSuccess:!1,originResponse:!0}}).then(i=>i.data).catch(()=>null):null)})}createDslRenderer(e,n={}){const{library:i,components:s,mode:o,apis:u}=this,l=H({mode:o,Vue:i.Vue,components:s,libs:i,apis:u,window},n),a=on({getDsl:c=>U(this,null,function*(){return(yield this.getDsl(c))||null}),getDslByUrl:c=>U(this,null,function*(){return(yield this.getDslByUrl(c))||null}),options:l});return sn(et(H({},l),{dsl:e,loader:a}))}getRenderComponent(e,n){return U(this,null,function*(){var o;const i=this.getFile(e);if(!i)return ie.warn(`Can not find file: ${e}`),null;if(n&&n(i),this.mode===X.Raw){const{vtjRawDir:u=".vtj/vue"}=this.options,l=`${u}/${e}.vue`,a=this.modules[l]||this.modules[`/src/pages/${e}.vue`];return a?(o=yield a())==null?void 0:o.default:this.nodeEnv==="development"&&this.adapter.startupComponent||null}const s=yield this.getDsl(i.id);return s?this.createDslRenderer(s).renderer:(ie.warn(`Can not find dsl: ${e}`),null)})}defineUrlSchemaComponent(e,n){return Cn(()=>U(this,null,function*(){const i=yield this.getDslByUrl(e);return i?(i.name=n||i.name,this.createDslRenderer(i).renderer):null}))}definePluginComponent(e){return Cn(()=>U(null,null,function*(){return yield ra(e,window)}))}initGlobals(e,n){const i=Object.assign({adapter:this.adapter,window},n);hy(e,i)}initI18n(e,n,i){yy(e,n,i)}initEnv(e=[]){this.env=e.reduce((n,i)=>(n[i.name]=i[this.nodeEnv],n),{})}}function _y(r){const t=new by(r);return{provider:t,onReady:e=>t.ready(e)}}function wy(r={}){const t=ma(sa,null);if(!t)throw new Error("Can not find provider");if(t.nodeEnv==="development"){const{id:e,version:n}=r;e&&n&&U(null,null,function*(){const i=yield t.getDsl(e);(i==null?void 0:i.__VERSION__)!==n&&t.adapter.notify&&t.adapter.notify(`[ ${i==null?void 0:i.name} ] 组件源码版本与运行时版本不一致,请重新发布组件`,"版本不一致","warning")})}return t}function Ey(r,t=""){return U(this,null,function*(){const{name:e,urls:n=[]}=r||{},i=n.map(u=>t+u),{css:s,js:o}=bm(i);if(s.length&&Qo(s),o.length)return yield Xo(o,e).catch(()=>{})})}const oa={type:"json",validSuccess:!0,originResponse:!1,failMessage:!0,validate:r=>{var t;return((t=r.data)==null?void 0:t.code)===0}},Sy=(r,t="/__vtj__/api/:type.json")=>(e,n,i)=>r.send({url:t,method:"post",params:{type:e},query:i,data:{type:e,data:n},settings:oa}),Ty=(r,t="/__vtj__/api/uploader.json")=>(e,n)=>U(null,null,function*(){return yield r.send({url:t,method:"post",data:{files:e,projectId:n},settings:et(H({},oa),{type:"data"})}).then(i=>i&&i[0]?i[0]:null).catch(()=>null)});function Ry(r){return An({settings:{type:"json",validSuccess:!0,originResponse:!1,failMessage:!0,validate:t=>{var e;return((e=t.data)==null?void 0:e.code)===0},showError:t=>{r&&r(t||"未知错误")}}})}class xy{constructor(t=tn){q(this,"api");q(this,"pluginCaches",{});q(this,"uploader");this.req=t,this.api=Sy(t),this.uploader=Ty(t)}getExtension(){return U(this,null,function*(){console.log("BaseService.getExtension")})}init(t){return U(this,null,function*(){return console.log("BaseService.init",t),{}})}saveProject(t,e){return U(this,null,function*(){return!!(yield this.api("saveProject",t,{type:e}).catch(()=>!1))})}saveMaterials(t,e){return U(this,null,function*(){return console.log("BaseService.saveMaterials",t,e),!1})}saveFile(t){return U(this,null,function*(){return console.log("BaseService.saveFile",t),!1})}getFile(t){return U(this,null,function*(){return console.log("BaseService.getFile",t),{}})}removeFile(t){return U(this,null,function*(){return console.log("BaseService.removeFile",t),!1})}saveHistory(t){return U(this,null,function*(){return console.log("BaseService.saveHistory",t),!1})}removeHistory(t){return U(this,null,function*(){return console.log("BaseService.removeHistory",t),!1})}getHistory(t){return U(this,null,function*(){return console.log("BaseService.getHistory",t),{}})}getHistoryItem(t,e){return U(this,null,function*(){return console.log("BaseService.getHistoryItem",t,e),{}})}saveHistoryItem(t,e){return U(this,null,function*(){return console.log("BaseService.saveHistoryItem",t,e),!1})}removeHistoryItem(t,e){return U(this,null,function*(){return console.log("BaseService.removeHistoryItem",t,e),!1})}publish(t){return U(this,null,function*(){return!!(yield this.api("publish",t).catch(()=>!1))})}publishFile(t,e){return U(this,null,function*(){return!!(yield this.api("publishFile",{project:t,file:e}).catch(()=>!1))})}genVueContent(t,e){return U(this,null,function*(){return yield this.api("genVueContent",{project:t,dsl:e}).catch(()=>"")})}parseVue(t,e){return U(this,null,function*(){return yield this.api("parseVue",H({project:t},e))})}createRawPage(t){return U(this,null,function*(){return yield this.api("createRawPage",t).catch(()=>"")})}removeRawPage(t){return U(this,null,function*(){return yield this.api("removeRawPage",t).catch(()=>"")})}uploadStaticFile(t,e){return U(this,null,function*(){return yield this.uploader(t,e).catch(()=>null)})}getStaticFiles(t){return U(this,null,function*(){return yield this.api("getStaticFiles",t).catch(()=>[])})}removeStaticFile(t,e){return U(this,null,function*(){return yield this.api("removeStaticFile",{name:t,projectId:e}).catch(()=>"")})}clearStaticFiles(t){return U(this,null,function*(){return yield this.api("clearStaticFiles",t).catch(()=>"")})}getPluginMaterial(t){return U(this,null,function*(){const{urls:e=[]}=t,n=e.filter(s=>gm(s))[0];return n?this.pluginCaches[n]||(this.pluginCaches[n]=tn.send({url:n,method:"get",settings:{validSuccess:!1,originResponse:!0}}).then(s=>s.data).catch(()=>null)):null})}genSource(t){return U(this,null,function*(){return console.log("BaseService.genSource",t),""})}}new Wo({type:"local",expired:0,prefix:"__VTJ_"});class Ay extends xy{constructor(){super(...arguments);q(this,"getFileCaches",{})}getExtension(){return U(this,null,function*(){return yield this.api("getExtension",{}).catch(()=>{})})}init(e){return U(this,null,function*(){return(yield this.api("init",e).catch(()=>null))||{}})}saveProject(e,n){return U(this,null,function*(){return!!(yield this.api("saveProject",e,{type:n}).catch(()=>!1))})}saveMaterials(e,n){return U(this,null,function*(){return!!(yield this.api("saveMaterials",{project:e,materials:qd(n)}).catch(()=>!1))})}saveFile(e){return U(this,null,function*(){return!!(yield this.api("saveFile",e).catch(()=>!1))})}getFile(e){return U(this,null,function*(){return this.getFileCaches[e]||(this.getFileCaches[e]=this.api("getFile",e).catch(()=>null)).finally(()=>{delete this.getFileCaches[e]})})}removeFile(e){return U(this,null,function*(){return!!(yield this.api("removeFile",e).catch(()=>!1))})}saveHistory(e){return U(this,null,function*(){return!!(yield this.api("saveHistory",e).catch(()=>!1))})}removeHistory(e){return U(this,null,function*(){return!!(yield this.api("removeHistory",e).catch(()=>!1))})}getHistory(e){return U(this,null,function*(){return(yield this.api("getHistory",e).catch(()=>null))||{}})}getHistoryItem(e,n){return U(this,null,function*(){return(yield this.api("getHistoryItem",{fId:e,id:n}).catch(()=>null))||{}})}saveHistoryItem(e,n){return U(this,null,function*(){return!!(yield this.api("saveHistoryItem",{fId:e,item:n}).catch(()=>!1))})}removeHistoryItem(e,n){return U(this,null,function*(){return!!(yield this.api("removeHistoryItem",{fId:e,ids:n}).catch(()=>!1))})}}/**!
69
69
  * Copyright (c) 2026, VTJ.PRO All rights reserved.
70
70
  * @name @vtj/uni
71
71
  * @author CHC chenhuachun1549@dingtalk.com
72
- * @version 0.16.3
72
+ * @version 0.16.5
73
73
  * @license <a href="https://vtj.pro/license.html">MIT License</a>
74
- */const Ay=["onLaunch","onShow","onHide","onError","onPageNotFound","onUnhandledRejection","onThemeChange","onPageNotFound","onUniNViewMessage","onExit"],ns="/pages",Oy="VTJ",$y="__UNI__1FC118B",Dy="VTJ移动跨端项目",Cy="1.0.0",By="100",jy=!1,Py={},Ny={enable:!1},Iy="3",My={name:Oy,appid:$y,description:Dy,versionName:Cy,versionCode:By,transformPx:jy,"app-plus":{usingComponents:!0,nvueStyleCompiler:"uni-app",compilerVersion:3,splashscreen:{alwaysShowBeforeRender:!0,waiting:!0,autoclose:!0,delay:0},modules:{},distribute:{android:{permissions:['<uses-permission android:name="android.permission.CHANGE_NETWORK_STATE"/>','<uses-permission android:name="android.permission.MOUNT_UNMOUNT_FILESYSTEMS"/>','<uses-permission android:name="android.permission.VIBRATE"/>','<uses-permission android:name="android.permission.READ_LOGS"/>','<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>','<uses-feature android:name="android.hardware.camera.autofocus"/>','<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>','<uses-permission android:name="android.permission.CAMERA"/>','<uses-permission android:name="android.permission.GET_ACCOUNTS"/>','<uses-permission android:name="android.permission.READ_PHONE_STATE"/>','<uses-permission android:name="android.permission.CHANGE_WIFI_STATE"/>','<uses-permission android:name="android.permission.WAKE_LOCK"/>','<uses-permission android:name="android.permission.FLASHLIGHT"/>','<uses-feature android:name="android.hardware.camera"/>','<uses-permission android:name="android.permission.WRITE_SETTINGS"/>']},ios:{},sdkConfigs:{},icons:{android:{hdpi:"src/static/logo.png",xhdpi:"src/static/logo.png",xxhdpi:"src/static/logo.png",xxxhdpi:"src/static/logo.png"}}}},quickapp:Py,"mp-weixin":{appid:"",setting:{urlCheck:!1},usingComponents:!0},"mp-alipay":{usingComponents:!0},"mp-baidu":{usingComponents:!0},"mp-toutiao":{usingComponents:!0},uniStatistics:Ny,vueVersion:Iy},Fy=[],Uy={navigationBarTextStyle:"black",navigationBarTitleText:"uni-app",navigationBarBackgroundColor:"#F8F8F8",backgroundColor:"#F8F8F8"},Ly={autoscan:!0,custom:{"^uni-(.*)":"@dcloudio/uni-ui/lib/uni-$1/uni-$1.vue"}},ky={pages:Fy,globalStyle:Uy,easycom:Ly};function Hy(r){let{manifestJson:t={},pagesJson:e={},routes:n=[]}=r;const i=n.map(s=>{const{path:o,style:u,needLogin:l}=s;return{path:o,style:u,needLogin:l}});return et(H({},r),{manifestJson:Object.assign({},My,t),pagesJson:Object.assign({},ky,e,{pages:i})})}const ln={navigationBarBackgroundColor:"backgroundColor",navigationBarTextStyle:"titleColor",navigationBarTitleText:"titleText",navigationStyle:"style",titleImage:"titleImage",titlePenetrate:"titlePenetrate",transparentTitle:"transparentTitle"};function aa(r){const t={},e={black:"#000000",white:"#ffffff"};for(const n in r)ln[n]&&(t[ln[n]]=n==="navigationBarTextStyle"?e[r[n]]||e.black:r[n]);return t}function Vy(r){const t={};for(const e in r)ln[e]||(t[e]=r[e]);return t}function qy(r){var t,e;return((e=(t=r.h5)==null?void 0:t.router)==null?void 0:e.mode)||"hash"}function zy(r){var t,e,n;return{topWindow:!!((t=r.topWindow)!=null&&t.path),leftWindow:!!((e=r.leftWindow)!=null&&e.path),rightWindow:!!((n=r.rightWindow)!=null&&n.path)}}function Wy(r){const{pagesJson:t={}}=r,{globalStyle:e,pages:n=[]}=t;return!!(e!=null&&e.enablePullDownRefresh||n.find(i=>{var s;return!!((s=i.style)!=null&&s.enablePullDownRefresh)}))}function Ky(r){const{pagesJson:t={}}=r,{globalStyle:e,pages:n=[]}=t;let i=!1;return(e==null?void 0:e.navigationStyle)==="custom"?(i=!0,n.find(s=>{var o;return((o=s.style)==null?void 0:o.navigationStyle)==="default"})&&(i=!1)):n.every(s=>{var o;return((o=s.style)==null?void 0:o.navigationStyle)==="custom"})&&(i=!0),i}function Jy(r){var u;const t=Ky(r),e={navigationBar:!1,navigationBarButtons:!1,navigationBarSearchInput:!1,navigationBarTransparent:!1},{pagesJson:n={}}=r,{globalStyle:i,pages:s=[]}=n;if(t)return e;e.navigationBar=!0;const o=(u=i==null?void 0:i.h5)==null?void 0:u.titleNView;return s.find(l=>{var a,c,f;return!!((f=(c=(a=l.style)==null?void 0:a.h5)==null?void 0:c.titleNView)!=null&&f.buttons.length)})&&(e.navigationBarButtons=!0),(o!=null&&o.searchInput||s.find(l=>{var a,c,f;return!!((f=(c=(a=l.style)==null?void 0:a.h5)==null?void 0:c.titleNView)!=null&&f.searchInput)}))&&(e.navigationBarSearchInput=!0),((o==null?void 0:o.type)==="transparent"||s.find(l=>{var a,c,f;return((f=(c=(a=l.style)==null?void 0:a.h5)==null?void 0:c.titleNView)==null?void 0:f.type)==="transparent"}))&&(e.navigationBarTransparent=!0),e}function Gy(r,t=window){var h,p,d,g;const{pagesJson:e={},manifestJson:n={}}=r,{topWindow:i,leftWindow:s,rightWindow:o}=zy(e),{navigationBar:u,navigationBarButtons:l,navigationBarSearchInput:a,navigationBarTransparent:c}=Jy(r),f={__VUE_OPTIONS_API__:!0,__VUE_PROD_DEVTOOLS__:!1,__VUE_PROD_HYDRATION_MISMATCH_DETAILS__:!1,__UNI_FEATURE_WX__:!1,__UNI_FEATURE_WXS__:!1,__UNI_FEATURE_RPX__:!1,__UNI_FEATURE_PROMISE__:!1,__UNI_FEATURE_LONGPRESS__:!1,__UNI_FEATURE_I18N_EN__:!1,__UNI_FEATURE_I18N_ES__:!1,__UNI_FEATURE_I18N_FR__:!1,__UNI_FEATURE_I18N_ZH_HANS__:!0,__UNI_FEATURE_I18N_ZH_HANT__:!1,__UNI_FEATURE_UNI_CLOUD__:!1,__UNI_FEATURE_I18N_LOCALE__:!1,__UNI_FEATURE_NVUE__:!1,__UNI_FEATURE_ROUTER_MODE__:qy(n),__UNI_FEATURE_PAGES__:!!((h=e.pages)!=null&&h.length),__UNI_FEATURE_TABBAR__:!!((d=(p=e.tabBar)==null?void 0:p.list)!=null&&d.length),__UNI_FEATURE_TABBAR_MIDBUTTON__:!!((g=e.tabBar)!=null&&g.midButton),__UNI_FEATURE_TOPWINDOW__:i,__UNI_FEATURE_LEFTWINDOW__:s,__UNI_FEATURE_RIGHTWINDOW__:o,__UNI_FEATURE_RESPONSIVE__:!1,__UNI_FEATURE_NAVIGATIONBAR__:u,__UNI_FEATURE_PULL_DOWN_REFRESH__:Wy(r),__UNI_FEATURE_NAVIGATIONBAR_BUTTONS__:l,__UNI_FEATURE_NAVIGATIONBAR_SEARCHINPUT__:a,__UNI_FEATURE_NAVIGATIONBAR_TRANSPARENT__:c};Object.entries(f).forEach(([b,w])=>{t[b]=w})}const Yy="4.76";function Zy(r,t=window){var f,h;const{pagesJson:e={},manifestJson:n={}}=r,{easycom:i={}}=e,{appid:s="",name:o="",versionCode:u="",versionName:l=""}=n,a=e.globalStyle,c=((f=n.h5)==null?void 0:f.router)||{};t.__uniConfig={easycom:i,globalStyle:et(H({},Vy(a)),{navigationBar:aa(a),isNVue:!1}),compilerVersion:Yy,appId:s,appName:o,appVersion:l,appVersionCode:String(u),async:H({loading:"AsyncLoading",error:"AsyncError",delay:200,timeout:6e4,suspensible:!0},((h=n.h5)==null?void 0:h.async)||{}),debug:!1,networkTimeout:H({request:6e4,connectSocket:6e4,uploadFile:6e4,downloadFile:6e4},n.networkTimeout||{}),sdkConfigs:{},nvue:{"flex-direction":"column"},locale:"",fallbackLocale:"",locales:{},router:H({mode:"hash",base:"/",assets:"assets",routerBase:c.base||"/"},c),darkmode:!1,themeConfig:{},tabBar:e.tabBar?H({position:"bottom",color:"#7A7E83",selectedColor:"#3cc51f",borderStyle:"black",blurEffect:"none",fontSize:"10px",iconWidth:"24px",spacing:"3px",height:"50px",backgroundColor:"#ffffff",selectedIndex:0,shown:!0},e.tabBar):void 0}}function Qy(r,t=window){const{UniServiceJSBridge:e,UniViewJSBridge:n,getApp:i,uni:s,getCurrentPages:o,upx2px:u,setupPage:l}=r;t.UniServiceJSBridge=e,t.UniViewJSBridge=n,t.getApp=i,t.uni=s,t.wx=s,t.getCurrentPages=o,t.upx2px=u,t.__setupPage=a=>l(a)}function Xy(r,t,e){const{openBlock:n,createBlock:i,withCtx:s,createVNode:o}=r,{PageComponent:u,setupPage:l,getApp:a}=t;return{mpType:"page",setup(){return U(this,null,function*(){var g,b;const f=((b=(g=a())==null?void 0:g.$route)==null?void 0:b.query)||{},{loader:h,component:p}=e,d=h?yield h(e):p||{};return()=>(n(),i(u,null,{page:s(()=>[o(l(d),Object.assign({},f,{ref:"page"}),null,512)]),_:1}))})}}}function t0(r,t,e){var p;const{path:n,style:i={},meta:s={},home:o,id:u}=t,l=((p=r.tabBar)==null?void 0:p.list)||[],a=l.findIndex(d=>{var g;return d.pagePath===n||((g=d.pagePath)==null?void 0:g.endsWith(u))}),c=l[a],f=!!c,h=e===0;return H({isTabBar:f,tabBarIndex:a,isQuit:o!=null?o:h,isEntry:o!=null?o:h,navigationBar:H({type:"default"},aa(i)),isNVue:!1,route:c?c.pagePath:n},s)}function e0(r,t,e,n,i=window){const s=e.map((o,u)=>{const l=t0(n,o,u),a=Xy(r,t,o),{path:c}=o;return{path:c,alias:c,meta:l,component:{render(){return r.h(r.Suspense,[r.h(a)])}}}});i.__uniRoutes=s,i.__uniLayout={}}function r0(r,t,e=window){fr(e,String(r),t)}function n0(r,t){t&&["View","ScrollView","Swiper","MovableArea","MovableView","CoverView","CoverImage","Icon","Text","RichText","Progress","Button","CheckboxGroup","Checkbox","Editor","Form","Input","Label","Picker","PickerView","RadioGroup","Radio","Slider","Switch","Textarea","Navigator","Image","Video","Map","Canvas","WebView","PickerViewColumn","ResizeSensor","SwiperItem"].forEach(e=>{const n=t[e];r.component(e,n)})}function i0(r){const t=Hy(r),{Vue:e,App:n,UniH5:i,routes:s=[],pagesJson:o={},manifestJson:u={},window:l,css:a=""}=t;if(!i)return e.createApp(n);const{plugin:c,setupApp:f}=i;Gy(t,l),Zy(t,l),Qy(i,l),e0(e,i,s,o,l),r0(u.appid||Date.now(),a,l);const h=e.createApp(f(n));return h.use(n0,i),h.use(c),h}function s0(r,t){const e={};return Object.entries(r).forEach(([n,i])=>{Ay.includes(n)&&i&&(e[n]=t(i))}),e}function is(r,t){return()=>U(null,null,function*(){const e=yield r.getDsl(t);if(e){const{renderer:n}=r.createDslRenderer(e);return n}return null})}function o0(n){return U(this,arguments,function*(r,t=!1,e=ns){var u,l,a;const i=((u=r.project)==null?void 0:u.pages)||[],s=[];for(const c of i){const f=((l=r.project)==null?void 0:l.homepage)===c.id;s.push({id:c.id,path:`${e}/${c.id}`,loader:is(r,c.id),style:H({navigationBarTitleText:c.title},c.style),needLogin:c.needLogin,home:f})}const o=s.find(c=>!!c.home)||s[0];if(o){const c=e===ns?"/":e;s.unshift(et(H({},o),{path:c}))}if(t){const c=((a=r.project)==null?void 0:a.blocks)||[];for(const f of c)s.push({id:f.id,path:`${e}/${f.id}`,loader:is(r,f.id),style:{navigationStyle:"custom"}})}return s})}function a0(){var r;return(r=window.uni)!=null&&r.showLoading&&window.uni.showLoading({title:"加载中...",mask:!0}),{close:()=>{var t;(t=window.uni)!=null&&t.hideLoading&&window.uni.hideLoading()}}}function ua(r,t="",e="warning"){return U(this,null,function*(){var n;return(n=window.uni)!=null&&n.showModal?window.uni.showModal({title:t,content:r,showCancel:!1}):(window.alert(r),!0)})}function u0(r=X.Runtime){let t={};r===X.Runtime?t=Object.assign({}):t=Object.assign({});let e={};for(const[n,i]of Object.entries(t))e[n]=()=>Promise.resolve(i);return e}const c0=Dm({loading:a0,notify:ua}),ca=new xy(Ty(ua)),l0=u0(),{provider:f0,onReady:h0}=by({nodeEnv:"production",mode:X.Runtime,modules:l0,materialPath:"../",adapter:c0,service:ca,dependencies:{Vue:()=>jn(()=>import("./@dcloudio-uni-h5-vue-Bz74xAG0.js").then(r=>r.z),__vite__mapDeps([0,1,2]),import.meta.url),VueRouter:()=>jn(()=>import("./vue-router-JeNoEIlG.js"),__vite__mapDeps([3,0,1,2]),import.meta.url)}}),p0=r=>U(null,null,function*(){const t=(yield ca.getExtension().catch(()=>null))||{},e=top||window,n=yield wy(t.enhance,e.location.pathname),{Vue:i,UniH5:s}=window,o=r.project;if(!o)return;const u=o.uniConfig||{},l=s0(u,d=>ht(d,window,!1,!0)),{manifestJson:a,pagesJson:c,css:f}=u,h=yield o0(r,!0),p=i0({Vue:i,App:l,UniH5:s,routes:h,css:f,manifestJson:a,pagesJson:c});p.use(r),n&&p.use(n,r),p.mount(document.body)});h0(()=>p0(f0));
74
+ */const Oy=["onLaunch","onShow","onHide","onError","onPageNotFound","onUnhandledRejection","onThemeChange","onPageNotFound","onUniNViewMessage","onExit"],ns="/pages",$y="VTJ",Dy="__UNI__1FC118B",Cy="VTJ移动跨端项目",By="1.0.0",jy="100",Py=!1,Ny={},Iy={enable:!1},My="3",Fy={name:$y,appid:Dy,description:Cy,versionName:By,versionCode:jy,transformPx:Py,"app-plus":{usingComponents:!0,nvueStyleCompiler:"uni-app",compilerVersion:3,splashscreen:{alwaysShowBeforeRender:!0,waiting:!0,autoclose:!0,delay:0},modules:{},distribute:{android:{permissions:['<uses-permission android:name="android.permission.CHANGE_NETWORK_STATE"/>','<uses-permission android:name="android.permission.MOUNT_UNMOUNT_FILESYSTEMS"/>','<uses-permission android:name="android.permission.VIBRATE"/>','<uses-permission android:name="android.permission.READ_LOGS"/>','<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>','<uses-feature android:name="android.hardware.camera.autofocus"/>','<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>','<uses-permission android:name="android.permission.CAMERA"/>','<uses-permission android:name="android.permission.GET_ACCOUNTS"/>','<uses-permission android:name="android.permission.READ_PHONE_STATE"/>','<uses-permission android:name="android.permission.CHANGE_WIFI_STATE"/>','<uses-permission android:name="android.permission.WAKE_LOCK"/>','<uses-permission android:name="android.permission.FLASHLIGHT"/>','<uses-feature android:name="android.hardware.camera"/>','<uses-permission android:name="android.permission.WRITE_SETTINGS"/>']},ios:{},sdkConfigs:{},icons:{android:{hdpi:"src/static/logo.png",xhdpi:"src/static/logo.png",xxhdpi:"src/static/logo.png",xxxhdpi:"src/static/logo.png"}}}},quickapp:Ny,"mp-weixin":{appid:"",setting:{urlCheck:!1},usingComponents:!0},"mp-alipay":{usingComponents:!0},"mp-baidu":{usingComponents:!0},"mp-toutiao":{usingComponents:!0},uniStatistics:Iy,vueVersion:My},Uy=[],Ly={navigationBarTextStyle:"black",navigationBarTitleText:"uni-app",navigationBarBackgroundColor:"#F8F8F8",backgroundColor:"#F8F8F8"},ky={autoscan:!0,custom:{"^uni-(.*)":"@dcloudio/uni-ui/lib/uni-$1/uni-$1.vue"}},Hy={pages:Uy,globalStyle:Ly,easycom:ky};function Vy(r){let{manifestJson:t={},pagesJson:e={},routes:n=[]}=r;const i=n.map(s=>{const{path:o,style:u,needLogin:l}=s;return{path:o,style:u,needLogin:l}});return et(H({},r),{manifestJson:Object.assign({},Fy,t),pagesJson:Object.assign({},Hy,e,{pages:i})})}const ln={navigationBarBackgroundColor:"backgroundColor",navigationBarTextStyle:"titleColor",navigationBarTitleText:"titleText",navigationStyle:"style",titleImage:"titleImage",titlePenetrate:"titlePenetrate",transparentTitle:"transparentTitle"};function aa(r){const t={},e={black:"#000000",white:"#ffffff"};for(const n in r)ln[n]&&(t[ln[n]]=n==="navigationBarTextStyle"?e[r[n]]||e.black:r[n]);return t}function qy(r){const t={};for(const e in r)ln[e]||(t[e]=r[e]);return t}function zy(r){var t,e;return((e=(t=r.h5)==null?void 0:t.router)==null?void 0:e.mode)||"hash"}function Wy(r){var t,e,n;return{topWindow:!!((t=r.topWindow)!=null&&t.path),leftWindow:!!((e=r.leftWindow)!=null&&e.path),rightWindow:!!((n=r.rightWindow)!=null&&n.path)}}function Ky(r){const{pagesJson:t={}}=r,{globalStyle:e,pages:n=[]}=t;return!!(e!=null&&e.enablePullDownRefresh||n.find(i=>{var s;return!!((s=i.style)!=null&&s.enablePullDownRefresh)}))}function Jy(r){const{pagesJson:t={}}=r,{globalStyle:e,pages:n=[]}=t;let i=!1;return(e==null?void 0:e.navigationStyle)==="custom"?(i=!0,n.find(s=>{var o;return((o=s.style)==null?void 0:o.navigationStyle)==="default"})&&(i=!1)):n.every(s=>{var o;return((o=s.style)==null?void 0:o.navigationStyle)==="custom"})&&(i=!0),i}function Gy(r){var u;const t=Jy(r),e={navigationBar:!1,navigationBarButtons:!1,navigationBarSearchInput:!1,navigationBarTransparent:!1},{pagesJson:n={}}=r,{globalStyle:i,pages:s=[]}=n;if(t)return e;e.navigationBar=!0;const o=(u=i==null?void 0:i.h5)==null?void 0:u.titleNView;return s.find(l=>{var a,c,f;return!!((f=(c=(a=l.style)==null?void 0:a.h5)==null?void 0:c.titleNView)!=null&&f.buttons.length)})&&(e.navigationBarButtons=!0),(o!=null&&o.searchInput||s.find(l=>{var a,c,f;return!!((f=(c=(a=l.style)==null?void 0:a.h5)==null?void 0:c.titleNView)!=null&&f.searchInput)}))&&(e.navigationBarSearchInput=!0),((o==null?void 0:o.type)==="transparent"||s.find(l=>{var a,c,f;return((f=(c=(a=l.style)==null?void 0:a.h5)==null?void 0:c.titleNView)==null?void 0:f.type)==="transparent"}))&&(e.navigationBarTransparent=!0),e}function Yy(r,t=window){var h,p,d,g;const{pagesJson:e={},manifestJson:n={}}=r,{topWindow:i,leftWindow:s,rightWindow:o}=Wy(e),{navigationBar:u,navigationBarButtons:l,navigationBarSearchInput:a,navigationBarTransparent:c}=Gy(r),f={__VUE_OPTIONS_API__:!0,__VUE_PROD_DEVTOOLS__:!1,__VUE_PROD_HYDRATION_MISMATCH_DETAILS__:!1,__UNI_FEATURE_WX__:!1,__UNI_FEATURE_WXS__:!1,__UNI_FEATURE_RPX__:!1,__UNI_FEATURE_PROMISE__:!1,__UNI_FEATURE_LONGPRESS__:!1,__UNI_FEATURE_I18N_EN__:!1,__UNI_FEATURE_I18N_ES__:!1,__UNI_FEATURE_I18N_FR__:!1,__UNI_FEATURE_I18N_ZH_HANS__:!0,__UNI_FEATURE_I18N_ZH_HANT__:!1,__UNI_FEATURE_UNI_CLOUD__:!1,__UNI_FEATURE_I18N_LOCALE__:!1,__UNI_FEATURE_NVUE__:!1,__UNI_FEATURE_ROUTER_MODE__:zy(n),__UNI_FEATURE_PAGES__:!!((h=e.pages)!=null&&h.length),__UNI_FEATURE_TABBAR__:!!((d=(p=e.tabBar)==null?void 0:p.list)!=null&&d.length),__UNI_FEATURE_TABBAR_MIDBUTTON__:!!((g=e.tabBar)!=null&&g.midButton),__UNI_FEATURE_TOPWINDOW__:i,__UNI_FEATURE_LEFTWINDOW__:s,__UNI_FEATURE_RIGHTWINDOW__:o,__UNI_FEATURE_RESPONSIVE__:!1,__UNI_FEATURE_NAVIGATIONBAR__:u,__UNI_FEATURE_PULL_DOWN_REFRESH__:Ky(r),__UNI_FEATURE_NAVIGATIONBAR_BUTTONS__:l,__UNI_FEATURE_NAVIGATIONBAR_SEARCHINPUT__:a,__UNI_FEATURE_NAVIGATIONBAR_TRANSPARENT__:c};Object.entries(f).forEach(([b,w])=>{t[b]=w})}const Zy="4.76";function Qy(r,t=window){var f,h;const{pagesJson:e={},manifestJson:n={}}=r,{easycom:i={}}=e,{appid:s="",name:o="",versionCode:u="",versionName:l=""}=n,a=e.globalStyle,c=((f=n.h5)==null?void 0:f.router)||{};t.__uniConfig={easycom:i,globalStyle:et(H({},qy(a)),{navigationBar:aa(a),isNVue:!1}),compilerVersion:Zy,appId:s,appName:o,appVersion:l,appVersionCode:String(u),async:H({loading:"AsyncLoading",error:"AsyncError",delay:200,timeout:6e4,suspensible:!0},((h=n.h5)==null?void 0:h.async)||{}),debug:!1,networkTimeout:H({request:6e4,connectSocket:6e4,uploadFile:6e4,downloadFile:6e4},n.networkTimeout||{}),sdkConfigs:{},nvue:{"flex-direction":"column"},locale:"",fallbackLocale:"",locales:{},router:H({mode:"hash",base:"/",assets:"assets",routerBase:c.base||"/"},c),darkmode:!1,themeConfig:{},tabBar:e.tabBar?H({position:"bottom",color:"#7A7E83",selectedColor:"#3cc51f",borderStyle:"black",blurEffect:"none",fontSize:"10px",iconWidth:"24px",spacing:"3px",height:"50px",backgroundColor:"#ffffff",selectedIndex:0,shown:!0},e.tabBar):void 0}}function Xy(r,t=window){const{UniServiceJSBridge:e,UniViewJSBridge:n,getApp:i,uni:s,getCurrentPages:o,upx2px:u,setupPage:l}=r;t.UniServiceJSBridge=e,t.UniViewJSBridge=n,t.getApp=i,t.uni=s,t.wx=s,t.getCurrentPages=o,t.upx2px=u,t.__setupPage=a=>l(a)}function t0(r,t,e){const{openBlock:n,createBlock:i,withCtx:s,createVNode:o}=r,{PageComponent:u,setupPage:l,getApp:a}=t;return{mpType:"page",setup(){return U(this,null,function*(){var g,b;const f=((b=(g=a())==null?void 0:g.$route)==null?void 0:b.query)||{},{loader:h,component:p}=e,d=h?yield h(e):p||{};return()=>(n(),i(u,null,{page:s(()=>[o(l(d),Object.assign({},f,{ref:"page"}),null,512)]),_:1}))})}}}function e0(r,t,e){var p;const{path:n,style:i={},meta:s={},home:o,id:u}=t,l=((p=r.tabBar)==null?void 0:p.list)||[],a=l.findIndex(d=>{var g;return d.pagePath===n||((g=d.pagePath)==null?void 0:g.endsWith(u))}),c=l[a],f=!!c,h=e===0;return H({isTabBar:f,tabBarIndex:a,isQuit:o!=null?o:h,isEntry:o!=null?o:h,navigationBar:H({type:"default"},aa(i)),isNVue:!1,route:c?c.pagePath:n},s)}function r0(r,t,e,n,i=window){const s=e.map((o,u)=>{const l=e0(n,o,u),a=t0(r,t,o),{path:c}=o;return{path:c,alias:c,meta:l,component:{render(){return r.h(r.Suspense,[r.h(a)])}}}});i.__uniRoutes=s,i.__uniLayout={}}function n0(r,t,e=window){fr(e,String(r),t)}function i0(r,t){t&&["View","ScrollView","Swiper","MovableArea","MovableView","CoverView","CoverImage","Icon","Text","RichText","Progress","Button","CheckboxGroup","Checkbox","Editor","Form","Input","Label","Picker","PickerView","RadioGroup","Radio","Slider","Switch","Textarea","Navigator","Image","Video","Map","Canvas","WebView","PickerViewColumn","ResizeSensor","SwiperItem"].forEach(e=>{const n=t[e];r.component(e,n)})}function s0(r){const t=Vy(r),{Vue:e,App:n,UniH5:i,routes:s=[],pagesJson:o={},manifestJson:u={},window:l,css:a=""}=t;if(!i)return e.createApp(n);const{plugin:c,setupApp:f}=i;Yy(t,l),Qy(t,l),Xy(i,l),r0(e,i,s,o,l),n0(u.appid||Date.now(),a,l);const h=e.createApp(f(n));return h.use(i0,i),h.use(c),h}function o0(r,t){const e={};return Object.entries(r).forEach(([n,i])=>{Oy.includes(n)&&i&&(e[n]=t(i))}),e}function is(r,t){return()=>U(null,null,function*(){const e=yield r.getDsl(t);if(e){const{renderer:n}=r.createDslRenderer(e);return n}return null})}function a0(n){return U(this,arguments,function*(r,t=!1,e=ns){var u,l,a;const i=((u=r.project)==null?void 0:u.pages)||[],s=[];for(const c of i){const f=((l=r.project)==null?void 0:l.homepage)===c.id;s.push({id:c.id,path:`${e}/${c.id}`,loader:is(r,c.id),style:H({navigationBarTitleText:c.title},c.style),needLogin:c.needLogin,home:f})}const o=s.find(c=>!!c.home)||s[0];if(o){const c=e===ns?"/":e;s.unshift(et(H({},o),{path:c}))}if(t){const c=((a=r.project)==null?void 0:a.blocks)||[];for(const f of c)s.push({id:f.id,path:`${e}/${f.id}`,loader:is(r,f.id),style:{navigationStyle:"custom"}})}return s})}function u0(){var r;return(r=window.uni)!=null&&r.showLoading&&window.uni.showLoading({title:"加载中...",mask:!0}),{close:()=>{var t;(t=window.uni)!=null&&t.hideLoading&&window.uni.hideLoading()}}}function ua(r,t="",e="warning"){return U(this,null,function*(){var n;return(n=window.uni)!=null&&n.showModal?window.uni.showModal({title:t,content:r,showCancel:!1}):(window.alert(r),!0)})}function c0(r=X.Runtime){let t={};r===X.Runtime?t=Object.assign({}):t=Object.assign({});let e={};for(const[n,i]of Object.entries(t))e[n]=()=>Promise.resolve(i);return e}const l0=Dm({loading:u0,notify:ua}),ca=new Ay(Ry(ua)),f0=c0(),{provider:h0,onReady:p0}=_y({nodeEnv:"production",mode:X.Runtime,modules:f0,materialPath:"../",adapter:l0,service:ca,dependencies:{Vue:()=>jn(()=>import("./@dcloudio-uni-h5-vue-Bz74xAG0.js").then(r=>r.z),__vite__mapDeps([0,1,2]),import.meta.url),VueRouter:()=>jn(()=>import("./vue-router-JeNoEIlG.js"),__vite__mapDeps([3,0,1,2]),import.meta.url)}}),d0=r=>U(null,null,function*(){const t=(yield ca.getExtension().catch(()=>null))||{},e=top||window,n=yield Ey(t.enhance,e.location.pathname),{Vue:i,UniH5:s}=window,o=r.project;if(!o)return;const u=o.uniConfig||{},l=o0(u,d=>ht(d,window,!1,!0)),{manifestJson:a,pagesJson:c,css:f}=u,h=yield a0(r,!0),p=s0({Vue:i,App:l,UniH5:s,routes:h,css:f,manifestJson:a,pagesJson:c});p.use(r),n&&p.use(n,r),p.mount(document.body)});p0(()=>d0(h0));
@@ -44,7 +44,7 @@
44
44
  <title></title>
45
45
  <!--preload-links-->
46
46
  <!--app-context-->
47
- <script type="module" crossorigin src="./assets/index-Dbr5EyvL.js"></script>
47
+ <script type="module" crossorigin src="./assets/index-COtCTLhP.js"></script>
48
48
  <link rel="modulepreload" crossorigin href="./assets/vue-DefuvV9N.js">
49
49
  <link rel="modulepreload" crossorigin href="./assets/@dcloudio-uni-shared-bWpOwtAM.js">
50
50
  <link rel="modulepreload" crossorigin href="./assets/@dcloudio-uni-h5-vue-Bz74xAG0.js">
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@vtj/pro",
3
3
  "private": false,
4
- "version": "0.16.3",
4
+ "version": "0.16.5",
5
5
  "keywords": [
6
6
  "低代码引擎",
7
7
  "LowCode Engine",
@@ -21,22 +21,22 @@
21
21
  "license": "MIT",
22
22
  "type": "module",
23
23
  "dependencies": {
24
- "@vtj/core": "~0.16.3",
25
- "@vtj/renderer": "~0.16.3",
26
- "@vtj/designer": "~0.16.3",
27
- "@vtj/local": "~0.16.3",
28
- "@vtj/uni": "~0.16.3",
29
- "@vtj/materials": "~0.16.3"
24
+ "@vtj/designer": "~0.16.5",
25
+ "@vtj/core": "~0.16.5",
26
+ "@vtj/local": "~0.16.5",
27
+ "@vtj/renderer": "~0.16.5",
28
+ "@vtj/materials": "~0.16.5",
29
+ "@vtj/uni": "~0.16.5"
30
30
  },
31
31
  "devDependencies": {
32
32
  "vite-plugin-vue-devtools": "~8.0.2",
33
33
  "vue": "~3.5.5",
34
34
  "vue-router": "~4.6.0",
35
- "@vtj/charts": "~0.16.3",
35
+ "@vtj/charts": "~0.16.5",
36
+ "@vtj/ui": "~0.16.5",
37
+ "@vtj/utils": "~0.16.5",
36
38
  "@vtj/cli": "~0.12.18",
37
- "@vtj/utils": "~0.16.3",
38
- "@vtj/ui": "~0.16.3",
39
- "@vtj/icons": "~0.16.3"
39
+ "@vtj/icons": "~0.16.5"
40
40
  },
41
41
  "exports": {
42
42
  "./vite": {
@@ -1,2 +0,0 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./vue-router-BEDJn_dq.js","./vue-C7aOYzfv.js"])))=>i.map(i=>d[i]);
2
- var g=Object.defineProperty;var y=Object.getOwnPropertySymbols;var A=Object.prototype.hasOwnProperty,h=Object.prototype.propertyIsEnumerable;var R=(o,t,e)=>t in o?g(o,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):o[t]=e,E=(o,t)=>{for(var e in t||(t={}))A.call(t,e)&&R(o,e,t[e]);if(y)for(var e of y(t))h.call(t,e)&&R(o,e,t[e]);return o};var c=(o,t,e)=>new Promise((_,s)=>{var u=r=>{try{p(e.next(r))}catch(i){s(i)}},d=r=>{try{p(e.throw(r))}catch(i){s(i)}},p=r=>r.done?_(r.value):Promise.resolve(r.value).then(u,d);p((e=e.apply(o,t)).next())});import{_ as w}from"./monaco-editor-Bgo-w-Z8.js";import{useRoute as P}from"./vue-router-BEDJn_dq.js";import"./element-plus-Cnk22g0r.js";import"./vxe-4LaZMynM.js";import{M as k,k as I,R as V,I as B,w as T,Y as D,E as L}from"./Editor-DMaEPM3O-BODFmRgl.js";import{a as M,n as x,l as O,E as S}from"./utils-BAP47J0F.js";import{x as Y}from"./@vueuse-DBbmvAan.js";import{j,az as C,K as z,l as H,A as K,B as N,r as b,o as q,g as F}from"./vue-C7aOYzfv.js";import"./shared-ClTq60Az.js";import"./dayjs-BGdj-UA2.js";import"./@element-plus-icons-vue-Cpi46I3H.js";import"./lodash-es-B2U1jVvD.js";import"./html2canvas-DNSjNh3_.js";import"./mockjs-D39zwwe_.js";import"./marked-Dt4xUbva.js";const it=j({__name:"page",setup(o){return c(this,null,function*(){let t,e;const _=new k(I(x)),s=([t,e]=C(()=>_.getExtension().catch(()=>null)),t=yield t,e(),t),u=V({loading:O,notify:x,useTitle:Y,alert:M,access:s==null?void 0:s.access}),d=s?([t,e]=C(()=>new S(s).load()),t=yield t,e(),t):{},{__BASE_PATH__:p="/"}=s||{},{provider:r,onReady:i}=B({mode:T.Runtime,service:_,materialPath:p,adapter:E(E({},u),d.adapter),dependencies:{Vue:()=>w(()=>import("./vue-C7aOYzfv.js").then(a=>a.aA),[],import.meta.url),VueRouter:()=>w(()=>import("./vue-router-BEDJn_dq.js"),__vite__mapDeps([0,1]),import.meta.url)}}),l=P(),f=b(),n=F(),v=a=>c(null,null,function*(){f.value=yield r.getRenderComponent(l.params.id.toString(),m=>{L(a,l,m)})});return i(()=>c(null,null,function*(){const a=n==null?void 0:n.appContext.app;a&&(a.use(D),a.use(r),v(a))})),z(()=>l.params.id,a=>c(null,null,function*(){if(a){const m=n==null?void 0:n.appContext.app;if(!m)return;v(m)}})),(a,m)=>f.value?(q(),H(K(f.value),{key:0})):N("",!0)})}});export{it as default};
@@ -1,2 +0,0 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./vue-router-BEDJn_dq.js","./vue-C7aOYzfv.js"])))=>i.map(i=>d[i]);
2
- var A=Object.defineProperty;var E=Object.getOwnPropertySymbols;var C=Object.prototype.hasOwnProperty,g=Object.prototype.propertyIsEnumerable;var w=(o,e,t)=>e in o?A(o,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):o[e]=t,d=(o,e)=>{for(var t in e||(e={}))C.call(e,t)&&w(o,t,e[t]);if(E)for(var t of E(e))g.call(e,t)&&w(o,t,e[t]);return o};var f=(o,e,t)=>new Promise((c,s)=>{var _=a=>{try{i(t.next(a))}catch(p){s(p)}},n=a=>{try{i(t.throw(a))}catch(p){s(p)}},i=a=>a.done?c(a.value):Promise.resolve(a.value).then(_,n);i((t=t.apply(o,e)).next())});import{_ as R}from"./monaco-editor-Bgo-w-Z8.js";import{useRoute as k}from"./vue-router-BEDJn_dq.js";import"./element-plus-Cnk22g0r.js";import"./vxe-4LaZMynM.js";import{M as I,k as P,R as V,I as B,w as T,F as D,Y as F,E as L}from"./Editor-DMaEPM3O-BODFmRgl.js";import{a as M,n as h,l as O,E as S}from"./utils-BAP47J0F.js";import{x as Y}from"./@vueuse-DBbmvAan.js";import{j,az as x,l as z,A as H,B as N,r as b,o as q,g as G}from"./vue-C7aOYzfv.js";import"./shared-ClTq60Az.js";import"./dayjs-BGdj-UA2.js";import"./@element-plus-icons-vue-Cpi46I3H.js";import"./lodash-es-B2U1jVvD.js";import"./html2canvas-DNSjNh3_.js";import"./mockjs-D39zwwe_.js";import"./marked-Dt4xUbva.js";const pe=j({__name:"preview",setup(o){return f(this,null,function*(){let e,t;const c=new I(P(h)),s=([e,t]=x(()=>c.getExtension().catch(()=>null)),e=yield e,t(),e||{}),_=V({loading:O,notify:h,useTitle:Y,alert:M,access:s==null?void 0:s.access}),n=s?([e,t]=x(()=>new S(s).load()),e=yield e,t(),e):{},{__BASE_PATH__:i="/"}=s||{},{provider:a,onReady:p}=B({mode:T.Runtime,service:c,materialPath:i,adapter:d(d({},_),n.adapter),dependencies:{Vue:()=>R(()=>import("./vue-C7aOYzfv.js").then(m=>m.aA),[],import.meta.url),VueRouter:()=>R(()=>import("./vue-router-BEDJn_dq.js"),__vite__mapDeps([0,1]),import.meta.url)}}),v=k(),u=b(),l=G();return p(()=>f(null,null,function*(){const m=yield D(s.enhance),r=l==null?void 0:l.appContext.app;r&&(n.install&&n.install(r),m&&r.use(m,a),r.use(F),r.use(a),u.value=yield a.getRenderComponent(v.params.id.toString(),y=>{L(r,v,y)}))})),(m,r)=>u.value?(q(),z(H(u.value),{key:0})):N("",!0)})}});export{pe as default};
@@ -1 +0,0 @@
1
- var g=Object.defineProperty;var S=Object.getOwnPropertySymbols;var m=Object.prototype.hasOwnProperty,u=Object.prototype.propertyIsEnumerable;var T=(t,a,s)=>a in t?g(t,a,{enumerable:!0,configurable:!0,writable:!0,value:s}):t[a]=s,l=(t,a)=>{for(var s in a||(a={}))m.call(a,s)&&T(t,s,a[s]);if(S)for(var s of S(a))u.call(a,s)&&T(t,s,a[s]);return t};var E=(t,a,s)=>T(t,typeof a!="symbol"?a+"":a,s);var p=(t,a,s)=>new Promise((o,n)=>{var e=r=>{try{i(s.next(r))}catch(_){n(_)}},c=r=>{try{i(s.throw(r))}catch(_){n(_)}},i=r=>r.done?o(r.value):Promise.resolve(r.value).then(e,c);i((s=s.apply(t,a)).next())});import{aA as d}from"./vue-C7aOYzfv.js";import{J as A,S as I,a as f,b as V,c as h,e as b,f as P,C as R,G as y,g as N,N as B,h as D,q as L,Q as M,v as k,i as x,H as K,O as H,U as w,j as C,A as U,K as Y,D as G,z as v,x as W,W as j,l as F,m as $,n as J,o as Z,B as z,p as X,r as q,s as Q,t as aa,u as sa,y as ea,L as ta,T as ra,_ as na,V as ia,X as oa,$ as _a,a0 as Ea,a1 as la,a2 as ca,a3 as Ta,a4 as Sa,a5 as pa,a6 as Oa,a7 as ga,a8 as ma,a9 as ua,aa as da,ab as Aa,ac as Ia,ad as fa,ae as Va,af as ha,ag as ba,ah as Pa,ai as Ra,aj as ya,ak as Na,al as Ba,am as Da,an as La,ao as Ma,ap as ka,aq as xa,ar as Ka,as as Ha,at as wa,au as Ca,av as Ua,Z as Ya,aw as Ga,ax as va,ay as Wa,az as ja,aA as Fa,aB as $a,aC as Ja,aD as Za}from"./Editor-DMaEPM3O-BODFmRgl.js";import{E as za,a as Xa,b as qa}from"./element-plus-Cnk22g0r.js";const Qa=Object.freeze(Object.defineProperty({__proto__:null,API_METHOD_TYPES:A,ActionMenu:I,Assets:f,Binder:V,Box:h,CodeIncrementalUpdater:b,DEVTOOLS_DEP:P,Designer:R,EVENT_MODIFIERS:y,Editor:N,Engine:B,EventBinder:D,GET_TOKENS_LINK:L,HOT_KEYS_DEP:M,Icon:k,Item:x,KEYBOARD_EVENT_LIST:K,MAX_TOKENS:H,MOBILE_SIZE:w,MOUSE_EVENT_LIST:C,NAME_REGEX:U,NPM_REGISTRY_URL:Y,OpenApi:G,PAD_SIZE:v,Panel:W,REPORT_API:j,RegionType:F,RegionWrapper:$,Renderer:J,SAVE_BLOCK_FILE_FINISH:Z,SESSION_ID_KEY:z,STATE_KEY:X,SetterView:q,SetterWrapper:Q,Simulator:aa,Skeleton:sa,SkeletonWrapper:ea,SlotsPicker:ta,State:ra,TOOL_CONFIGS:na,Tabs:ia,ToolRegistry:oa,VERSION_REGEX:_a,VTJ_DESIGNER_VERSION:Ea,VUE_DEVTOOLS_FRAME_STATE_KEY:la,VUE_DEVTOOLS_OVERLAY_PATH:ca,VUE_DEVTOOLS_PATH:Ta,VariableBinder:Sa,Viewer:pa,Viewport:Oa,WidgetGroup:ga,WidgetWrapper:ma,alert:ua,builtInDeps:da,builtInMaterials:Aa,builtInSetters:Ia,builtInWidgets:fa,codeIncrementalUpdater:Va,confirm:ha,createSlotsPicker:ba,defaultSetter:Pa,depsManager:Ra,engineKey:ya,expressionValidate:Na,getClassProperties:Ba,loading:Da,message:La,normalizedStyle:Ma,notify:ka,proxyContext:xa,readJsonFile:Ka,regions:Ha,setterManager:wa,setters:Ca,useEngine:Ua,widgetManager:Ya,widgets:Ga},Symbol.toStringTag,{value:"Module"}));class rs{constructor(a){E(this,"urls",[]);E(this,"library","");E(this,"params",[]);E(this,"__BASE_PATH__","/");this.config=a;const s=l(l(l({},Wa),Qa),va),o={Vue:d,__VTJ_PRO__:s};for(const[_,O]of Object.entries(o))window[_]=O;const{extension:n,__BASE_PATH__:e="/"}=a||{},{urls:c=[],library:i,params:r=[]}=n||{};i&&(this.urls=c,this.library=i,this.params=r,this.__BASE_PATH__=e)}load(){return p(this,null,function*(){let a={};if(this.library){const s=this.__BASE_PATH__,o=this.urls.filter(e=>ja(e)).map(e=>`${s}${e}`),n=this.urls.filter(e=>Fa(e)).map(e=>`${s}${e}`);if($a(o),n.length){const e=yield Ja(n,this.library).catch(()=>null);e&&typeof e=="function"?a=e.call(e,this.config,...this.params):a=e||{}}}return Object.assign({},this.getEngineOptions(),a)})}getEngineOptions(){const a=["materialPath","pageBasePath","pageRouteName","remote","checkVersion","noMask","auth"];return Za(this.config,a)}}function ns(){return qa.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"})}function is(t,a="",s="warning"){Xa({title:a,message:t,type:s})}function os(t,a){return za.alert(t,a)}export{rs as E,os as a,ns as l,is as n};