var h=Object.defineProperty;var g=Object.getOwnPropertySymbols;var T=Object.prototype.hasOwnProperty,f=Object.prototype.propertyIsEnumerable;var p=(t,a,s)=>a in t?h(t,a,{enumerable:!0,configurable:!0,writable:!0,value:s}):t[a]=s,_=(t,a)=>{for(var s in a||(a={}))T.call(a,s)&&p(t,s,a[s]);if(g)for(var s of g(a))f.call(a,s)&&p(t,s,a[s]);return t};var c=(t,a,s)=>p(t,typeof a!="symbol"?a+"":a,s);var S=(t,a,s)=>new Promise((o,n)=>{var e=r=>{try{i(s.next(r))}catch(l){n(l)}},E=r=>{try{i(s.throw(r))}catch(l){n(l)}},i=r=>r.done?o(r.value):Promise.resolve(r.value).then(e,E);i((s=s.apply(t,a)).next())});import{aA as d}from"./vue-CWi9lEhc.js";import{d as A,g as I,m as O,b,r as m,e as V,l as P,p as R,D as y,s as M,G as N,f as B,t as D,K as L,h as K,j,k,u as v,Q as w,n as x,o as G,q as H,v as W,w as Y,x as U,z as F,B as C,W as $,F as z,H as J,S as X,J as Z,L as q,N as Q,O as aa,P as sa,T as ea,U as ta,V as ra,X as na,Y as ia,Z as oa,_ as la,a0 as ca,a1 as _a,a2 as Ea,a3 as pa,a4 as ga,a5 as Sa,a6 as ua,a7 as ha,a8 as Ta,a9 as fa,aa as da,ab as Aa,ac as Ia,ad as Oa,ae as ba,af as ma,ag as Va,ah as Pa,ai as Ra,aj as ya,ak as Ma,al as Na,am as Ba,an as Da,ao as La,ap as Ka,c as ja,aq as ka,ar as va,as as wa,at as xa,au as Ga,av as Ha,aw as Wa,ax as Ya,ay as Ua,az as Fa,aA as Ca}from"./Editor-BYRlEJ7f-DrA-LA5d.js";import{E as $a,a as za,b as Ja,c as Xa}from"./element-plus-ByPIA5X9.js";const Za=Object.freeze(Object.defineProperty({__proto__:null,API_METHOD_TYPES:A,ActionMenu:I,Assets:O,Binder:b,Box:m,Designer:V,DevTools:P,EVENT_MODIFIERS:R,Editor:y,Engine:M,EventBinder:N,GET_TOKENS_LINK:B,Icon:D,Item:L,KEYBOARD_EVENT_LIST:K,MAX_TOKENS:j,MOBILE_SIZE:k,MOUSE_EVENT_LIST:v,NAME_REGEX:w,NPM_REGISTRY_URL:x,OpenApi:G,PAD_SIZE:H,Panel:W,REPORT_API:Y,RegionType:U,RegionWrapper:F,Renderer:C,SAVE_BLOCK_FILE_FINISH:$,SESSION_ID_KEY:z,STATE_KEY:J,SetterView:X,SetterWrapper:Z,Simulator:q,Skeleton:Q,SkeletonWrapper:aa,SlotsPicker:sa,State:ea,Tabs:ta,VERSION_REGEX:ra,VTJ_DESIGNER_VERSION:na,VUE_DEVTOOLS_FRAME_STATE_KEY:ia,VUE_DEVTOOLS_OVERLAY_PATH:oa,VUE_DEVTOOLS_PATH:la,VariableBinder:ca,Viewer:_a,Viewport:Ea,WidgetGroup:pa,WidgetWrapper:ga,alert:Sa,builtInDeps:ua,builtInMaterials:ha,builtInSetters:Ta,builtInWidgets:fa,confirm:da,createSlotsPicker:Aa,defaultSetter:Ia,depsManager:Oa,engineKey:ba,expressionValidate:ma,getClassProperties:Va,message:Pa,normalizedStyle:Ra,notify:ya,proxyContext:Ma,readJsonFile:Na,regions:Ba,setterManager:Da,setters:La,useEngine:Ka,widgetManager:ja,widgets:ka},Symbol.toStringTag,{value:"Module"}));class es{constructor(a){c(this,"urls",[]);c(this,"library","");c(this,"params",[]);c(this,"__BASE_PATH__","/");this.config=a;const s=_(_(_({},Ha),Za),Ga),o={Vue:d,__VTJ_PRO__:s,VtjUtils:xa,VtjIcons:wa,VtjUI:va,ElementPlus:$a};for(const[l,u]of Object.entries(o))window[l]=u;const{extension:n,__BASE_PATH__:e="/"}=a||{},{urls:E=[],library:i,params:r=[]}=n||{};i&&(this.urls=E,this.library=i,this.params=r,this.__BASE_PATH__=e)}load(){return S(this,null,function*(){let a={};if(this.library){const s=this.__BASE_PATH__,o=this.urls.filter(e=>Wa(e)).map(e=>`${s}${e}`),n=this.urls.filter(e=>Ya(e)).map(e=>`${s}${e}`);if(Ua(o),n.length){const e=yield Fa(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"];return Ca(this.config,a)}}function ts(){return Xa.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"})}function rs(t,a="",s="warning"){Ja({title:a,message:t,type:s})}function ns(t,a){return za.alert(t,a)}export{es as E,ns as a,ts as l,rs as n};
