lw-cdp-ui 1.2.21 → 1.2.22

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.
@@ -1,18 +1,18 @@
1
- (function(he,Me){typeof exports=="object"&&typeof module<"u"?Me(exports,require("element-plus"),require("vue"),require("vuedraggable"),require("dayjs"),require("@logicflow/core"),require("@logicflow/extension")):typeof define=="function"&&define.amd?define(["exports","element-plus","vue","vuedraggable","dayjs","@logicflow/core","@logicflow/extension"],Me):(he=typeof globalThis<"u"?globalThis:he||self,Me(he.LwCdpUi={},he.ElementPlus,he.Vue,he.Vuedraggable,he.dayjs,he.LogicFlowCore,he.LogicFlowExtension))})(this,function(he,Me,e,Gt,$e,lm,zi){"use strict";var Rx=Object.defineProperty;var Ax=(he,Me,e)=>Me in he?Rx(he,Me,{enumerable:!0,configurable:!0,writable:!0,value:e}):he[Me]=e;var Cn=(he,Me,e)=>Ax(he,typeof Me!="symbol"?Me+"":Me,e);const im={mounted(t,n){t.$value=n.value,t.handler=()=>{const o=document.createElement("textarea");o.readOnly="readonly",o.style.position="absolute",o.style.left="-9999px",o.value=t.$value,document.body.appendChild(o),o.select(),o.setSelectionRange(0,o.value.length),document.execCommand("Copy")&&Me.ElMessage.success("复制成功"),document.body.removeChild(o)},t.addEventListener("click",t.handler)},updated(t,n){t.$value=n.value},unmounted(t){t.removeEventListener("click",t.handler)}},sm={mounted(t,n){let o=localStorage.getItem("userAuthInfo");o=JSON.parse(o);const{menus:a,authorities:r}=o,l=n.value;if(!l)return!0;let i=!1;Array.isArray(l)?i=l.some(s=>[...a,...r].includes(s)):typeof l=="string"&&(i=[...a,...r].includes(l)),i||t.parentNode&&t.parentNode.removeChild(t)}},le=(t,n)=>{const o=t.__vccOpts||t;for(const[a,r]of n)o[a]=r;return o},cm={name:"NavMenu",props:["navMenus"],data(){return{}},methods:{hasChildren(t){return t.children&&!t.children.every(n=>n.meta.hidden)}}},dm={key:0,style:{padding:"20px"}},um=["href"];function hm(t,n,o,a,r,l){const i=e.resolveComponent("el-alert"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("el-menu-item"),f=e.resolveComponent("NavMenu",!0),p=e.resolveComponent("el-sub-menu");return e.openBlock(),e.createElementBlock(e.Fragment,null,[o.navMenus.length<=0?(e.openBlock(),e.createElementBlock("div",dm,[e.createVNode(i,{title:"无子集菜单",center:"",type:"info",closable:!1})])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.navMenus,m=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:m},[l.hasChildren(m)?(e.openBlock(),e.createBlock(p,{key:1,index:m.path},{title:e.withCtx(()=>[m.meta&&m.meta.icon?(e.openBlock(),e.createBlock(s,{key:0},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(m.meta.icon||"el-icon-menu")))]),_:2},1024)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(m.meta.title),1)]),default:e.withCtx(()=>[e.createVNode(f,{navMenus:m.children},null,8,["navMenus"])]),_:2},1032,["index"])):(e.openBlock(),e.createBlock(d,{key:0,index:m.path},{title:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(m.meta.title),1)]),default:e.withCtx(()=>[m.meta&&m.meta.type=="link"?(e.openBlock(),e.createElementBlock("a",{key:0,href:m.path,target:"_blank",onClick:e.withModifiers(()=>{},["stop"])},null,8,um)):e.createCommentVNode("",!0),m.meta&&m.meta.icon?(e.openBlock(),e.createBlock(s,{key:1},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(m.meta.icon||"el-icon-menu")))]),_:2},1024)):e.createCommentVNode("",!0)]),_:2},1032,["index"]))],64))),128))],64)}const Hi=le(cm,[["render",hm]]),Yt="/static/images/logo.svg",fm={components:{NavMenu:Hi},data(){return{nav:!1,menu:[]}},computed:{},created(){var t=this.$router.sc_getMenu();this.menu=this.filterUrl(t)},watch:{},methods:{showMobileNav(t){var n=t.currentTarget.getAttribute("drag-flag");if(n=="true")return!1;this.nav=!0},select(){this.$refs.mobileNavBox.handleClose()},filterUrl(t){var n=[];return t&&t.forEach(o=>{if(o.meta=o.meta?o.meta:{},o.meta.hidden||o.meta.type=="button")return!1;o.meta.type=="iframe"&&(o.path=`/i/${o.name}`),o.children&&o.children.length>0&&(o.children=this.filterUrl(o.children)),n.push(o)}),n}},directives:{drag(t){let n=t,o="",a="";n.onmousedown=function(r){let l=r.clientX-n.offsetLeft,i=r.clientY-n.offsetTop;return document.onmousemove=function(s){n.setAttribute("drag-flag",!0),o=new Date().getTime();let d=s.clientX-l,f=s.clientY-i;f>0&&f<document.body.clientHeight-50&&(n.style.top=f+"px"),d>0&&d<document.body.clientWidth-50&&(n.style.left=d+"px")},document.onmouseup=function(){a=new Date().getTime(),a-o>200&&n.setAttribute("drag-flag",!1),document.onmousemove=null,document.onmouseup=null},!1}}}},pm={class:"logo-bar"};function mm(t,n,o,a,r,l){const i=e.resolveComponent("el-icon-menu"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("el-header"),f=e.resolveComponent("NavMenu"),p=e.resolveComponent("el-menu"),m=e.resolveComponent("el-scrollbar"),_=e.resolveComponent("el-main"),C=e.resolveComponent("el-container"),k=e.resolveComponent("el-drawer"),S=e.resolveDirective("drag");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.withDirectives((e.openBlock(),e.createElementBlock("div",{ref:"",class:"mobile-nav-button",onClick:n[0]||(n[0]=B=>l.showMobileNav(B)),draggable:"false"},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i)]),_:1})])),[[S]]),e.createVNode(k,{ref:"mobileNavBox",title:"移动端菜单",size:240,modelValue:r.nav,"onUpdate:modelValue":n[1]||(n[1]=B=>r.nav=B),direction:"ltr","with-header":!1,"destroy-on-close":""},{default:e.withCtx(()=>[e.createVNode(C,{class:"mobile-nav"},{default:e.withCtx(()=>[e.createVNode(d,null,{default:e.withCtx(()=>[e.createElementVNode("div",pm,[n[2]||(n[2]=e.createElementVNode("img",{class:"logo",src:Yt},null,-1)),e.createElementVNode("span",null,e.toDisplayString(t.$config.APP_NAME),1)])]),_:1}),e.createVNode(_,null,{default:e.withCtx(()=>[e.createVNode(m,null,{default:e.withCtx(()=>[e.createVNode(p,{"default-active":t.$route.meta.active||t.$route.fullPath,onSelect:l.select,router:"","background-color":"#212d3d","text-color":"#fff","active-text-color":"#409EFF"},{default:e.withCtx(()=>[e.createVNode(f,{navMenus:r.menu},null,8,["navMenus"])]),_:1},8,["default-active","onSelect"])]),_:1})]),_:1})]),_:1})]),_:1},8,["modelValue"])],64)}const gm=le(fm,[["render",mm],["__scopeId","data-v-dd6bdb07"]]),bm={name:"layoutAside",props:{},data(){return{popVisible:!1,grantedApplications:[]}},mounted(){let{grantedApplications:t}=this.$tool.data.get("userAuthInfo");this.grantedApplications=t,document.addEventListener("click",this.handleDocumentClick)},beforeDestroy(){document.removeEventListener("click",this.handleDocumentClick)},methods:{handleDocumentClick(t){let n=document.getElementById("popover");this.popVisible&&t.target!==n&&!n.contains(t.target)&&(this.popVisible=!1)},openMneu(){window.location.href="/#/passport-application"},switchMenu(t){window.location.href=t.url},closePopover(){this.$refs.popoverRef.hide()}}},ym={class:"layout-aside"},_m={class:"app-content"},km={class:"app-title"},wm=["onClick"];function Vm(t,n,o,a,r,l){const i=e.resolveComponent("el-icon"),s=e.resolveComponent("el-icon-close"),d=e.resolveComponent("el-divider"),f=e.resolveComponent("el-popover");return e.openBlock(),e.createElementBlock("div",ym,[n[1]||(n[1]=e.createElementVNode("img",{class:"logo",src:Yt,alt:""},null,-1)),e.createVNode(f,{placement:"right",width:180,trigger:"click","show-arrow":!1,offset:3,"popper-class":"app-popper",ref:"popoverRef"},{reference:e.withCtx(()=>[e.createElementVNode("p",null,[e.createVNode(i,{class:"menu-btn"},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent("el-icon-grid")))]),_:1})])]),default:e.withCtx(()=>[e.createElementVNode("div",_m,[e.createElementVNode("div",km,[e.createElementVNode("span",{class:"open",onClick:n[0]||(n[0]=(...p)=>l.openMneu&&l.openMneu(...p))},"应用中心"),e.createVNode(i,{class:"iconClose",onClick:l.closePopover},{default:e.withCtx(()=>[e.createVNode(s)]),_:1},8,["onClick"])]),e.createVNode(d,{style:{margin:"5px 0"}}),r.grantedApplications.length>0?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(r.grantedApplications,p=>(e.openBlock(),e.createElementBlock("div",{class:"menu-item",onClick:m=>l.switchMenu(p),key:p.resourceId},[e.createElementVNode("i",{class:e.normalizeClass(["iconfont",p.icon]),style:{"margin-right":"5px"}},null,2),e.createTextVNode(" "+e.toDisplayString(p.name),1)],8,wm))),128)):e.createCommentVNode("",!0)])]),_:1},512)])}const Cm=le(bm,[["render",Vm]]),xm={data(){return{breadList:[]}},created(){this.getBreadcrumb()},watch:{$route(){this.getBreadcrumb()}},methods:{getBreadcrumb(){let t=this.$route.meta.breadcrumb;this.breadList=t}}},Nm={class:"adminui-topbar"},Bm={class:"left-panel"},Sm={style:{"font-size":"12px"}},Em={class:"right-panel"};function Tm(t,n,o,a,r,l){const i=e.resolveComponent("el-icon"),s=e.resolveComponent("el-breadcrumb-item"),d=e.resolveComponent("el-breadcrumb");return e.openBlock(),e.createElementBlock("div",Nm,[e.createElementVNode("div",Bm,[e.createVNode(d,{"separator-icon":"el-icon-arrow-right",class:"hidden-sm-and-down"},{default:e.withCtx(()=>[e.createVNode(e.TransitionGroup,{name:"breadcrumb"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.breadList,f=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:f.title},[f.path!="/"&&!f.meta.hiddenBreadcrumb?(e.openBlock(),e.createBlock(s,{key:f.meta.title},{default:e.withCtx(()=>[f.meta.icon?(e.openBlock(),e.createBlock(i,{key:0,class:"icon"},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(f.meta.icon)))]),_:2},1024)):e.createCommentVNode("",!0),e.createElementVNode("span",Sm,e.toDisplayString(f.meta.title),1)]),_:2},1024)):e.createCommentVNode("",!0)],64))),128))]),_:1})]),_:1})]),n[0]||(n[0]=e.createElementVNode("div",{class:"center-panel"},null,-1)),e.createElementVNode("div",Em,[e.renderSlot(t.$slots,"default",{},void 0,!0)])])}const Im=le(xm,[["render",Tm],["__scopeId","data-v-c198cd76"]]),Dm={name:"tags",components:{draggable:Gt},data(){return{contextMenuVisible:!1,contextMenuItem:null,left:0,top:0,tipVisible:!1,tipDisplayed:!1,menu:this.$router.sc_getMenu()}},props:{tagShowID:{type:Boolean,default:!1}},computed:{tagList(){return this.$store.state.viewTags.viewTags}},watch:{scrollInit(){const t=this.$refs.tags;t&&t.addEventListener("scroll",()=>{t.scrollLeft>0?this.tipDisplayed=!0:this.tipDisplayed=!1})},$route(t){this.addViewTags(t)},contextMenuVisible(t){var n=this,o=function(a){let r=document.getElementById("contextmenu");r&&!r.contains(a.target)&&n.closeMenu()};t?document.body.addEventListener("click",a=>o(a)):document.body.removeEventListener("click",a=>o(a))}},created(){this.init(),this.$store.state.viewTags.closeTagAndJump=this.closeTagAndJump},mounted(){this.scrollInit()},methods:{init(){let t=this.$tool.data.get("RouteTags")||[];t.length>0&&t.forEach((n,o)=>{var a=this.treeFind(this.menu,r=>r.path==n.path);a&&this.addViewTags(n)}),this.addViewTags(this.$route)},treeFind(t,n){for(const o of t){if(n(o))return o;if(o.children){const a=this.treeFind(o.children,n);if(a)return a}}return null},changeTages(t){this.$tool.data.set("RouteTags",this.$store.state.viewTags.viewTags)},addViewTags(t){t.name&&!t.meta.fullpage&&(delete t.redirectedFrom,t={...t,matched:[]},this.$store.commit("pushViewTags",t),this.$store.commit("pushKeepLive",t.name),this.$tool.data.set("RouteTags",this.$store.state.viewTags.viewTags)),this.$nextTick(()=>{const n=document.querySelector(".context-menu-list");n&&n.scrollWidth>n.clientWidth&&(n.querySelector(".active").scrollIntoView(),this.tipDisplayed||(this.tipVisible=!0))})},isActive(t){return t.fullPath===this.$route.fullPath},closeSelectedTag(t,n=!0){let o=this.menu[0];if(o.children&&(o=o.children[0]),this.tagList.length==1&&o.path==this.$route.fullPath)return!1;if(this.$store.commit("removeViewTags",t),this.$store.commit("removeIframeList",t),this.$store.commit("removeKeepLive",t.name),this.$tool.data.set("RouteTags",this.$store.state.viewTags.viewTags),n&&this.isActive(t)){const a=this.tagList.slice(-1)[0];a?this.$router.push(a):this.$router.push("/")}},openContextMenu(t,n){this.contextMenuItem=n,this.contextMenuVisible=!0,this.left=t.clientX+1,this.top=t.clientY+1,this.$nextTick(()=>{let o=document.getElementById("contextmenu");document.body.offsetWidth-t.clientX<o.offsetWidth&&(this.left=document.body.offsetWidth-o.offsetWidth+1,this.top=t.clientY+1)})},closeMenu(){this.contextMenuItem=null,this.contextMenuVisible=!1},refreshTab(){var t=this.contextMenuItem;this.contextMenuVisible=!1,this.$route.fullPath!=t.fullPath&&this.$router.push({path:t.fullPath,query:t.query}),this.$store.commit("refreshIframe",t),this.$store.commit("removeKeepLive",t.name),this.$store.commit("setRouteShow",!0),this.$nextTick(()=>{this.$store.commit("pushKeepLive",t.name),this.$store.commit("setRouteShow",!1)})},closeTabs(){var t=this.contextMenuItem;t.meta.affix||(this.closeSelectedTag(t),this.contextMenuVisible=!1)},closeOtherTabs(){var t=this.contextMenuItem;this.$route.fullPath!=t.fullPath&&this.$router.push({path:t.fullPath,query:t.query});var n=[...this.tagList];n.forEach(o=>{if(o.meta&&o.meta.affix||t.fullPath==o.fullPath)return!0;this.closeSelectedTag(o,!1)}),this.contextMenuVisible=!1},maximize(){var t=this.contextMenuItem;this.contextMenuVisible=!1,this.$route.fullPath!=t.fullPath&&this.$router.push({path:t.fullPath,query:t.query}),document.getElementById("app").classList.add("main-maximize")},openWindow(){var t=this.contextMenuItem,n=t.href||"/";t.meta.affix||this.closeSelectedTag(t),window.open(n),this.contextMenuVisible=!1},scrollInit(){const t=document.querySelector(".context-menu-list");t.addEventListener("mousewheel",n,!1)||t.addEventListener("DOMMouseScroll",n,!1);function n(o){const a=o.wheelDelta||o.detail,r=1,l=-1;let i=0;a==3||a<0&&a!=-3?i=r*50:i=l*50,t.scrollLeft+=i}},hideTip(){this.tipVisible=!1,this.tipDisplayed=!0},closeTagAndJump(t,n){this.$store.commit("removeKeepLive",n),this.closeSelectedTag(this.$route,!1),this.$router.push(t)},getIdName(t){var n;if((n=t.query)!=null&&n.id&&this.tagShowID){let o=t.meta.title;return o.includes(":")||o.includes(":")?t.meta.title:`${t.meta.title}:${t.query.id}`}else return t.meta.title}}},Fm={class:"adminui-tags"},qm=["onContextmenu"];function Rm(t,n,o,a,r,l){const i=e.resolveComponent("el-icon-close"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("router-link"),f=e.resolveComponent("draggable"),p=e.resolveComponent("el-icon-refresh"),m=e.resolveComponent("el-icon-folder-delete"),_=e.resolveComponent("el-icon-full-screen"),C=e.resolveComponent("el-icon-copy-document");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",Fm,[e.createVNode(f,{modelValue:t.$store.state.viewTags.viewTags,"onUpdate:modelValue":n[0]||(n[0]=k=>t.$store.state.viewTags.viewTags=k),onChange:l.changeTages,class:"context-menu-list",ref:"tags",itemKey:"name"},{item:e.withCtx(({element:k,index:S})=>[(e.openBlock(),e.createElementBlock("li",{key:k,class:e.normalizeClass([l.isActive(k)?"active":"",k.meta.affix?"affix":""]),onContextmenu:e.withModifiers(B=>l.openContextMenu(B,k),["prevent"])},[e.createVNode(d,{to:k},{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(l.getIdName(k)),1),k.meta.affix?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(s,{key:0,onClick:e.withModifiers(B=>l.closeSelectedTag(k),["prevent","stop"])},{default:e.withCtx(()=>[e.createVNode(i)]),_:2},1032,["onClick"]))]),_:2},1032,["to"])],42,qm))]),_:1},8,["modelValue","onChange"])]),e.createVNode(e.Transition,{name:"el-zoom-in-top"},{default:e.withCtx(()=>[r.contextMenuVisible?(e.openBlock(),e.createElementBlock("ul",{key:0,style:e.normalizeStyle({left:r.left+"px",top:r.top+"px"}),class:"contextmenu",id:"contextmenu"},[e.createElementVNode("li",{onClick:n[1]||(n[1]=k=>l.refreshTab())},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(p)]),_:1}),n[6]||(n[6]=e.createTextVNode("刷新"))]),n[11]||(n[11]=e.createElementVNode("hr",null,null,-1)),e.createElementVNode("li",{onClick:n[2]||(n[2]=k=>l.closeTabs()),class:e.normalizeClass(r.contextMenuItem.meta.affix?"disabled":"")},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i)]),_:1}),n[7]||(n[7]=e.createTextVNode("关闭标签 "))],2),e.createElementVNode("li",{onClick:n[3]||(n[3]=k=>l.closeOtherTabs())},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(m)]),_:1}),n[8]||(n[8]=e.createTextVNode("关闭其他标签 "))]),n[12]||(n[12]=e.createElementVNode("hr",null,null,-1)),e.createElementVNode("li",{onClick:n[4]||(n[4]=k=>l.maximize())},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(_)]),_:1}),n[9]||(n[9]=e.createTextVNode("最大化"))]),e.createElementVNode("li",{onClick:n[5]||(n[5]=k=>l.openWindow())},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(C)]),_:1}),n[10]||(n[10]=e.createTextVNode("在新的窗口中打开 "))])],4)):e.createCommentVNode("",!0)]),_:1})],64)}const Am=le(Dm,[["render",Rm]]),Om={data(){return{buName:"",buList:[]}},props:{isInitialized:{type:Boolean,default:!0}},methods:{async changeBusinessUnit(t){let n=this.buList.find(o=>o.code===t);if(this.buName=n.name,this.$store.commit("setRouteShow",!0),this.$tool.data.set("buCode",t),this.$tool.data.set("tenantId",n.tenantId),this.$bus.$emit("changeBu",{buCode:t,tenantId:n.tenantId}),this.isInitialized){let o=await this.$api.auth.initialized();this.$tool.data.set("zoneInitialized",o),o||this.$router.push(this.$config.INIT_URL)}this.$store.commit("clearKeepLive"),this.$store.commit("setRouteShow",!1)}},async created(){this.buList=this.$tool.data.get("buList")||[];let t=this.$tool.data.get("buCode");if(!this.buList.length){let a=await this.$api.auth.bu()||[];this.$tool.data.set("buList",a),this.buList=a,this.$tool.data.set("buCode",a[0].code),t=a[0].code}let n=this.buList.find(o=>o.code===t);this.buName=n?n.name:"",this.changeBusinessUnit(t)}},vm={class:"bu-list"};function Pm(t,n,o,a,r,l){const i=e.resolveComponent("el-icon-help"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("el-dropdown-item"),f=e.resolveComponent("el-dropdown-menu"),p=e.resolveComponent("el-dropdown");return e.openBlock(),e.createElementBlock("div",{class:"screen panel-item hidden-sm-and-down",onClick:n[0]||(n[0]=(...m)=>t.screen&&t.screen(...m))},[e.createVNode(p,{onCommand:l.changeBusinessUnit},{dropdown:e.withCtx(()=>[e.createVNode(f,null,{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.buList,m=>(e.openBlock(),e.createBlock(d,{key:m.id,command:m.code},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(m.name),1)]),_:2},1032,["command"]))),128))]),_:1})]),default:e.withCtx(()=>[e.createElementVNode("div",vm,[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i)]),_:1}),e.createTextVNode(e.toDisplayString(r.buName),1)])]),_:1},8,["onCommand"])])}const Lm={props:{isShowBu:{type:Boolean,default:!0},isInitialized:{type:Boolean,default:!0}},components:{bu:le(Om,[["render",Pm],["__scopeId","data-v-e0d2e0bb"]])},data(){return{userName:"",userNameF:"",searchVisible:!1,tasksVisible:!1,msg:!1}},created(){this.$store.state.user=this.$tool.data.get("userAuthInfo")},methods:{handleUser(t){t=="uc"&&this.$router.push({path:"/user"}),t=="cmd"&&this.$router.push({path:"/cmd"}),t=="clearCache"&&this.$confirm("清除缓存会将系统初始化,包括登录状态、主题、语言设置等,是否继续?","提示",{type:"info"}).then(()=>{this.$tool.data.clear(),window.location.href="/#/passport-login"}).catch(()=>{}),t=="outLogin"&&this.$confirm("确认是否退出当前用户?","提示",{type:"warning",confirmButtonText:"退出",confirmButtonClass:"el-button--danger"}).then(()=>{this.$store.commit("clearViewTags"),this.$store.commit("clearKeepLive"),this.$store.commit("clearIframeList"),window.location.href="/#/passport-login"}).catch(()=>{})},screen(){var t=document.documentElement;this.$tool.screen(t)},showMsg(){this.msg=!0},search(){this.searchVisible=!0},tasks(){this.tasksVisible=!0}}},Mm={class:"user-bar"},Um={class:"user-avatar"},jm={class:"user-body"},zm={class:"user-name"};function Hm(t,n,o,a,r,l){const i=e.resolveComponent("bu"),s=e.resolveComponent("el-avatar"),d=e.resolveComponent("el-dropdown-item"),f=e.resolveComponent("el-dropdown-menu"),p=e.resolveComponent("el-dropdown");return e.openBlock(),e.createElementBlock("div",Mm,[e.renderSlot(t.$slots,"userbarActionBox",{},void 0,!0),o.isShowBu?(e.openBlock(),e.createBlock(i,{key:0,isInitialized:o.isInitialized},null,8,["isInitialized"])):e.createCommentVNode("",!0),e.createVNode(p,{class:"user panel-item",trigger:"click",onCommand:l.handleUser},{dropdown:e.withCtx(()=>[e.createVNode(f,null,{default:e.withCtx(()=>[e.createVNode(d,{command:"uc"},{default:e.withCtx(()=>[e.createElementVNode("div",jm,[e.createVNode(s,{size:30,src:t.$store.state.user.img||"/static/images/empty.jpg"},null,8,["src"]),e.createElementVNode("div",zm,[e.createElementVNode("label",null,e.toDisplayString(t.$store.state.user.realName),1),e.createElementVNode("label",null,e.toDisplayString(t.$store.state.user.username),1)])])]),_:1}),e.createVNode(d,{command:"clearCache"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("layout.clearCache")),1)]),_:1}),e.createVNode(d,{divided:"",command:"outLogin"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("layout.outLogin")),1)]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createElementVNode("div",Um,[e.createVNode(s,{size:30,src:t.$store.state.user.img||"/static/images/empty.jpg"},null,8,["src"])])]),_:1},8,["onCommand"])])}const Km=le(Lm,[["render",Hm],["__scopeId","data-v-4e135de2"]]),Ki={HexToRgb(t){t=t.replace("#","");let n=t.match(/../g);for(let o=0;o<3;o++)n[o]=parseInt(n[o],16);return n},RgbToHex(t,n,o){let a=[t.toString(16),n.toString(16),o.toString(16)];for(let r=0;r<3;r++)a[r].length===1&&(a[r]="0"+a[r]);return"#"+a.join("")},darken(t,n){let o=this.HexToRgb(t);for(let a=0;a<3;a++)o[a]=Math.floor(o[a]*(1-n));return this.RgbToHex(o[0],o[1],o[2])},lighten(t,n){let o=this.HexToRgb(t);for(let a=0;a<3;a++)o[a]=Math.floor((255-o[a])*n+o[a]);return this.RgbToHex(o[0],o[1],o[2])}},Gm={data(){return{config:{lang:this.$tool.data.get("APP_LANG")||this.$config.LANG},lang:[{name:"简体中文",value:"zh-cn"},{name:"English",value:"en-us"}]}},watch:{"config.lang"(t){this.$i18n.locale=t,this.$i18n.fallbackLocale=t,this.$tool.data.remove("RouteTags"),this.$tool.data.set("APP_LANG",t),location.reload()}},methods:{configLang(t){this.config.lang=t.value}},computed:{curLang(){return this.lang.find(n=>n.value===this.config.lang).name}}};function Ym(t,n,o,a,r,l){const i=e.resolveComponent("el-button"),s=e.resolveComponent("el-dropdown-item"),d=e.resolveComponent("el-dropdown-menu"),f=e.resolveComponent("el-dropdown");return e.openBlock(),e.createBlock(f,{trigger:"click",placement:"bottom-end",onCommand:l.configLang},{dropdown:e.withCtx(()=>[e.createVNode(d,null,{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.lang,p=>(e.openBlock(),e.createBlock(s,{key:p.value,command:p,class:e.normalizeClass({selected:r.config.lang==p.value})},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(p.name),1)]),_:2},1032,["command","class"]))),128))]),_:1})]),default:e.withCtx(()=>[e.createVNode(i,{link:""},{icon:e.withCtx(()=>n[0]||(n[0]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",role:"img",width:"1em",height:"1em",preserveAspectRatio:"xMidYMid meet",viewBox:"0 0 512 512"},[e.createElementVNode("path",{d:"M478.33 433.6l-90-218a22 22 0 0 0-40.67 0l-90 218a22 22 0 1 0 40.67 16.79L316.66 406h102.67l18.33 44.39A22 22 0 0 0 458 464a22 22 0 0 0 20.32-30.4zM334.83 362L368 281.65L401.17 362z",fill:"currentColor"}),e.createElementVNode("path",{d:"M267.84 342.92a22 22 0 0 0-4.89-30.7c-.2-.15-15-11.13-36.49-34.73c39.65-53.68 62.11-114.75 71.27-143.49H330a22 22 0 0 0 0-44H214V70a22 22 0 0 0-44 0v20H54a22 22 0 0 0 0 44h197.25c-9.52 26.95-27.05 69.5-53.79 108.36c-31.41-41.68-43.08-68.65-43.17-68.87a22 22 0 0 0-40.58 17c.58 1.38 14.55 34.23 52.86 83.93c.92 1.19 1.83 2.35 2.74 3.51c-39.24 44.35-77.74 71.86-93.85 80.74a22 22 0 1 0 21.07 38.63c2.16-1.18 48.6-26.89 101.63-85.59c22.52 24.08 38 35.44 38.93 36.1a22 22 0 0 0 30.75-4.9z",fill:"currentColor"})],-1)])),default:e.withCtx(()=>[e.createTextVNode(" "+e.toDisplayString(l.curLang),1)]),_:1})]),_:1},8,["onCommand"])}const Gi=le(Gm,[["render",Ym]]),$m={components:{Lang:Gi},data(){return{layout:this.$store.state.global.layout,menuIsCollapse:this.$store.state.global.menuIsCollapse,layoutTags:this.$store.state.global.layoutTags,dark:this.$tool.data.get("APP_THEME"),colorList:["#409EFF","#009688","#536dfe","#ff5c93","#c62f2f","#fd726d"],colorPrimary:this.$tool.data.get("APP_COLOR")||this.$config.COLOR||"#409EFF"}},watch:{layout(t){this.$store.commit("SET_layout",t)},menuIsCollapse(t){this.$store.commit("TOGGLE_menuIsCollapse"),t?this.$tool.data.set("APP_menuIsCollapse","true"):this.$tool.data.remove("APP_menuIsCollapse")},layoutTags(t){this.$store.commit("TOGGLE_layoutTags"),t?this.$tool.data.remove("APP_LAYOUTTAGS"):this.$tool.data.set("APP_LAYOUTTAGS","hide")},dark(t){document.body.setAttribute("data-theme",t),this.$tool.data.set("APP_THEME",t)},colorPrimary(t){document.documentElement.style.setProperty("--el-color-primary",t);for(let n=1;n<=9;n++)document.documentElement.style.setProperty(`--el-color-primary-light-${n}`,Ki.lighten(t,n/10));for(let n=1;n<=9;n++)document.documentElement.style.setProperty(`--el-color-primary-dark-${n}`,Ki.darken(t,n/10));this.$tool.data.set("APP_COLOR",t)}}};function Wm(t,n,o,a,r,l){const i=e.resolveComponent("el-divider"),s=e.resolveComponent("el-switch"),d=e.resolveComponent("el-form-item"),f=e.resolveComponent("el-color-picker"),p=e.resolveComponent("el-option"),m=e.resolveComponent("el-select"),_=e.resolveComponent("Lang"),C=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(C,{ref:"form","label-width":"120px","label-position":"left",style:{padding:"0 20px"}},{default:e.withCtx(()=>[e.createVNode(i),e.createVNode(d,{label:t.$t("user.nightmode")},{default:e.withCtx(()=>[e.createVNode(s,{modelValue:r.dark,"onUpdate:modelValue":n[0]||(n[0]=k=>r.dark=k),"active-value":"dark","inactive-value":"default"},null,8,["modelValue"])]),_:1},8,["label"]),e.createVNode(i),e.createVNode(d,{label:t.$t("user.color")},{default:e.withCtx(()=>[e.createVNode(f,{modelValue:r.colorPrimary,"onUpdate:modelValue":n[1]||(n[1]=k=>r.colorPrimary=k),predefine:r.colorList},{default:e.withCtx(()=>n[5]||(n[5]=[e.createTextVNode(">")])),_:1},8,["modelValue","predefine"])]),_:1},8,["label"]),e.createVNode(i),e.createVNode(d,{label:t.$t("user.layout")},{default:e.withCtx(()=>[e.createVNode(m,{modelValue:r.layout,"onUpdate:modelValue":n[2]||(n[2]=k=>r.layout=k),placeholder:"请选择"},{default:e.withCtx(()=>[e.createVNode(p,{label:"默认",value:"default"}),e.createVNode(p,{label:"通栏",value:"header"}),e.createVNode(p,{label:"经典",value:"menu"}),e.createVNode(p,{label:"功能坞",value:"dock"})]),_:1},8,["modelValue"])]),_:1},8,["label"]),e.createVNode(d,{label:t.$t("user.menu")},{default:e.withCtx(()=>[e.createVNode(s,{modelValue:r.menuIsCollapse,"onUpdate:modelValue":n[3]||(n[3]=k=>r.menuIsCollapse=k)},null,8,["modelValue"])]),_:1},8,["label"]),e.createVNode(d,{label:t.$t("user.tag")},{default:e.withCtx(()=>[e.createVNode(s,{modelValue:r.layoutTags,"onUpdate:modelValue":n[4]||(n[4]=k=>r.layoutTags=k)},null,8,["modelValue"])]),_:1},8,["label"]),e.createVNode(i),e.createVNode(d,{label:t.$t("user.lang")},{default:e.withCtx(()=>[e.createVNode(_)]),_:1},8,["label"])]),_:1},512)}const Jm=le($m,[["render",Wm]]),Zm={data(){return{}},watch:{$route(t){this.push(t)}},created(){this.push(this.$route)},computed:{iframeList(){return this.$store.state.iframe.iframeList},ismobile(){return this.$store.state.global.ismobile},layoutTags(){return this.$store.state.global.layoutTags}},mounted(){},methods:{push(t){t.meta.type=="iframe"?this.ismobile||!this.layoutTags?this.$store.commit("setIframeList",t):this.$store.commit("pushIframeList",t):(this.ismobile||!this.layoutTags)&&this.$store.commit("clearIframeList")}}},Xm={class:"iframe-pages"},Qm=["src"];function eg(t,n,o,a,r,l){return e.withDirectives((e.openBlock(),e.createElementBlock("div",Xm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.iframeList,i=>e.withDirectives((e.openBlock(),e.createElementBlock("iframe",{key:i.meta.url,src:i.meta.url,frameborder:"0"},null,8,Qm)),[[e.vShow,t.$route.meta.url==i.meta.url]])),128))],512)),[[e.vShow,t.$route.meta.type=="iframe"]])}const tg={name:"lwLayout",props:{isShowBu:{type:Boolean,default:!0},isInitialized:{type:Boolean,default:!0},tagShowID:{type:Boolean,default:!1}},components:{Aside:Cm,SideM:gm,Topbar:Im,Tags:Am,NavMenu:Hi,userbar:Km,setting:Jm,iframeView:le(Zm,[["render",eg],["__scopeId","data-v-91dc7bba"]])},data(){return{settingDialog:!1,changeMenu:!1,menu:[],nextMenu:[],pmenu:{},active:""}},computed:{ismobile(){return this.$store.state.global.ismobile},layout(){return this.$store.state.global.layout},layoutTags(){return this.$store.state.global.layoutTags},menuIsCollapse(){return this.$store.state.global.menuIsCollapse}},beforeCreate(){this.$bus.$on("setMenu",o=>{this.changeMenu=!0,this.menu=this.filterUrl(o)}),this.$tool.data.get("APP_LAYOUTTAGS")&&(this.$store.state.global.layoutTags=!1);let n=this.$tool.data.get("APP_menuIsCollapse");this.$store.state.global.menuIsCollapse=!!n},async created(){if(this.$tool.data.get("MENUCOMBINED")&&this.$tool.data.set("MENUCOMBINEDNMAE",this.$config.APP_NAME),this.onLayoutResize(),window.addEventListener("resize",this.onLayoutResize),this.getUserInfo(),!this.changeMenu){var n=this.$router.sc_getMenu();this.menu=this.filterUrl(n)}this.showThis(),this.$store.commit("LOAD_USER_FROM_LOCAL_STORAGE")},watch:{async $route(){this.showThis()},"$i18n.locale"(){var t=this.$router.sc_getMenu();this.menu=this.filterUrl(t)},layout:{handler(t){document.body.setAttribute("data-layout",t)},immediate:!0}},methods:{async getUserInfo(){let t=await this.$api.auth.bu();this.$tool.data.set("buList",t);let n=await this.$api.auth.user();this.$tool.data.set("tenantId",n.userAuthInfo.tenantId),this.$tool.data.set("userAuthInfo",n.userAuthInfo),this.$tool.data.set("MenuPath",n.userAuthInfo.grantedApplications),this.$store.state.user=n.userAuthInfo},openSetting(){this.settingDialog=!0},onLayoutResize(){this.$store.commit("SET_ismobile",document.body.clientWidth<992)},showThis(){this.pmenu=this.$route.meta.breadcrumb?this.$route.meta.breadcrumb[0]:{},this.nextMenu=this.filterUrl(this.pmenu.children),this.$nextTick(()=>{this.active=this.$route.meta.active||this.$route.fullPath})},showMenu(t){this.pmenu=t,this.nextMenu=this.filterUrl(t.children),(!t.children||t.children.length==0)&&t.component&&this.$router.push({path:t.path})},filterUrl(t){var n=[];return t&&t.forEach(o=>{if(o.meta=o.meta?o.meta:{},o.meta.hidden||o.meta.type=="button")return!1;o.meta.type=="iframe"&&(o.path=`/i/${o.name}`),o.children&&o.children.length>0&&(o.children=this.filterUrl(o.children)),n.push(o)}),this.changeMenu=!1,n},exitMaximize(){document.getElementById("app").classList.remove("main-maximize")}}},ng={class:"adminui-header"},og={class:"adminui-header-left"},rg={class:"logo-bar"},ag={key:0,class:"nav"},lg=["onClick"],ig={class:"adminui-header-right"},sg={class:"aminui-wrapper"},cg={key:0,class:"adminui-side-top"},dg={class:"adminui-side-scroll"},ug={class:"aminui-body el-container"},hg={class:"adminui-main",id:"adminui-main"},fg={key:1,class:"aminui-body-menu"},pg={class:"aminui-side-split-left"},mg={class:"aminui-wrapper"},gg={class:"aminui-title-name"},bg={class:"adminui-side-scroll"},yg={class:"aminui-body el-container"},_g={class:"aminui-body-menu-top"},kg={class:"top-bar-title"},wg={class:"title"},Vg={class:"adminui-main",id:"adminui-main"},Cg={class:"adminui-header"},xg={class:"adminui-header-left"},Ng={class:"logo-bar"},Bg={class:"adminui-header-right"},Sg={key:0,class:"adminui-header-menu"},Eg={class:"aminui-wrapper"},Tg={class:"aminui-body el-container"},Ig={class:"adminui-main",id:"adminui-main"},Dg={key:3,class:"aminui-wrapper"},Fg={key:0,class:"aminui-side-split"},qg={class:"aminui-side-split-top"},Rg={class:"adminui-side-split-scroll"},Ag=["onClick"],Og={key:0,class:"adminui-side-top"},vg={class:"adminui-side-scroll"},Pg={class:"aminui-body el-container"},Lg={class:"adminui-main",id:"adminui-main"};function Mg(t,n,o,a,r,l){const i=e.resolveComponent("el-icon"),s=e.resolveComponent("userbar"),d=e.resolveComponent("NavMenu"),f=e.resolveComponent("el-menu"),p=e.resolveComponent("el-scrollbar"),m=e.resolveComponent("el-icon-expand"),_=e.resolveComponent("el-icon-fold"),C=e.resolveComponent("Side-m"),k=e.resolveComponent("Topbar"),S=e.resolveComponent("Tags"),B=e.resolveComponent("router-view"),q=e.resolveComponent("iframe-view"),F=e.resolveComponent("Aside"),V=e.resolveComponent("el-icon-close"),j=e.resolveComponent("el-icon-brush-filled"),U=e.resolveComponent("setting"),L=e.resolveComponent("el-drawer");return e.openBlock(),e.createElementBlock(e.Fragment,null,[l.layout=="header"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("header",ng,[e.createElementVNode("div",og,[e.createElementVNode("div",rg,[n[6]||(n[6]=e.createElementVNode("img",{class:"logo",src:Yt},null,-1)),e.createElementVNode("span",null,e.toDisplayString(t.$config.APP_NAME),1)]),l.ismobile?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("ul",ag,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.menu,A=>(e.openBlock(),e.createElementBlock("li",{key:A,class:e.normalizeClass(r.pmenu.path==A.path?"active":""),onClick:z=>l.showMenu(A)},[e.createVNode(i,null,{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(A.meta.icon||"el-icon-menu")))]),_:2},1024),e.createElementVNode("span",null,e.toDisplayString(A.meta.title),1)],10,lg))),128))]))]),e.createElementVNode("div",ig,[e.createVNode(s,{isShowBu:o.isShowBu,isInitialized:o.isInitialized},{userbarActionBox:e.withCtx(()=>[e.renderSlot(t.$slots,"userbarActionBox")]),_:3},8,["isShowBu","isInitialized"])])]),e.createElementVNode("section",sg,[!l.ismobile&&r.nextMenu.length>0||!r.pmenu.component?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(l.menuIsCollapse?"aminui-side isCollapse":"aminui-side")},[l.menuIsCollapse?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",cg,[e.createElementVNode("h2",null,e.toDisplayString(r.pmenu.meta.title),1)])),e.createElementVNode("div",dg,[e.createVNode(p,null,{default:e.withCtx(()=>[e.createVNode(f,{"default-active":r.active,router:"",collapse:l.menuIsCollapse,"unique-opened":t.$config.MENU_UNIQUE_OPENED},{default:e.withCtx(()=>[e.createVNode(d,{navMenus:r.nextMenu},null,8,["navMenus"])]),_:1},8,["default-active","collapse","unique-opened"])]),_:1})]),e.createElementVNode("div",{class:"adminui-side-bottom",onClick:n[0]||(n[0]=A=>t.$store.commit("TOGGLE_menuIsCollapse"))},[e.createVNode(i,null,{default:e.withCtx(()=>[l.menuIsCollapse?(e.openBlock(),e.createBlock(m,{key:0})):(e.openBlock(),e.createBlock(_,{key:1}))]),_:1})])],2)):e.createCommentVNode("",!0),l.ismobile?(e.openBlock(),e.createBlock(C,{key:1})):e.createCommentVNode("",!0),e.createElementVNode("div",ug,[l.ismobile?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(k,{key:0})),!l.ismobile&&l.layoutTags?(e.openBlock(),e.createBlock(S,{key:1,tagShowID:o.tagShowID},null,8,["tagShowID"])):e.createCommentVNode("",!0),e.createElementVNode("div",hg,[e.renderSlot(t.$slots,"routerView",{},()=>[e.createVNode(B,null,{default:e.withCtx(({Component:A})=>[(e.openBlock(),e.createBlock(e.KeepAlive,{include:this.$store.state.keepAlive.keepLiveRoute},[t.$store.state.keepAlive.routeShow?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(A),{key:t.$route.fullPath})):e.createCommentVNode("",!0)],1032,["include"]))]),_:1})]),e.createVNode(q)])])])],64)):l.layout=="menu"?(e.openBlock(),e.createElementBlock("section",fg,[e.createElementVNode("div",pg,[e.createVNode(F)]),e.createElementVNode("section",mg,[l.ismobile?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(l.menuIsCollapse?"aminui-side isCollapse":"aminui-side")},[e.createElementVNode("div",gg,e.toDisplayString(l.menuIsCollapse?t.$config.APP_NAME.charAt(0):t.$config.APP_NAME),1),e.createElementVNode("div",bg,[e.createVNode(p,null,{default:e.withCtx(()=>[e.createVNode(f,{"default-active":r.active,router:"",collapse:l.menuIsCollapse,"unique-opened":t.$config.MENU_UNIQUE_OPENED},{default:e.withCtx(()=>[e.createVNode(d,{navMenus:r.menu},null,8,["navMenus"])]),_:1},8,["default-active","collapse","unique-opened"])]),_:1})]),e.createElementVNode("div",{class:"adminui-side-bottom",onClick:n[1]||(n[1]=A=>t.$store.commit("TOGGLE_menuIsCollapse"))},[e.createVNode(i,null,{default:e.withCtx(()=>[l.menuIsCollapse?(e.openBlock(),e.createBlock(m,{key:0})):(e.openBlock(),e.createBlock(_,{key:1}))]),_:1})])],2)),l.ismobile?(e.openBlock(),e.createBlock(C,{key:1})):e.createCommentVNode("",!0),e.createElementVNode("div",yg,[e.createElementVNode("div",_g,[e.createElementVNode("div",kg,[e.createElementVNode("span",wg,e.toDisplayString(t.$t("layout.topbar"))+":",1),l.ismobile?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(k,{key:0}))]),e.createVNode(s,{isShowBu:o.isShowBu,isInitialized:o.isInitialized},{userbarActionBox:e.withCtx(()=>[e.renderSlot(t.$slots,"userbarActionBox")]),_:3},8,["isShowBu","isInitialized"])]),!l.ismobile&&l.layoutTags?(e.openBlock(),e.createBlock(S,{key:0,tagShowID:o.tagShowID},null,8,["tagShowID"])):e.createCommentVNode("",!0),e.createElementVNode("div",Vg,[e.renderSlot(t.$slots,"routerView",{},()=>[e.createVNode(B,null,{default:e.withCtx(({Component:A})=>[(e.openBlock(),e.createBlock(e.KeepAlive,{include:this.$store.state.keepAlive.keepLiveRoute},[t.$store.state.keepAlive.routeShow?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(A),{key:t.$route.fullPath})):e.createCommentVNode("",!0)],1032,["include"]))]),_:1})]),e.createVNode(q)])])])])):l.layout=="dock"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createElementVNode("header",Cg,[e.createElementVNode("div",xg,[e.createElementVNode("div",Ng,[n[7]||(n[7]=e.createElementVNode("img",{class:"logo",src:Yt},null,-1)),e.createElementVNode("span",null,e.toDisplayString(t.$config.APP_NAME),1)])]),e.createElementVNode("div",Bg,[l.ismobile?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",Sg,[e.createVNode(f,{mode:"horizontal","default-active":r.active,router:"","background-color":"#222b45","text-color":"#fff","active-text-color":"var(--el-color-primary)"},{default:e.withCtx(()=>[e.createVNode(d,{navMenus:r.menu},null,8,["navMenus"])]),_:1},8,["default-active"])])),l.ismobile?(e.openBlock(),e.createBlock(C,{key:1})):e.createCommentVNode("",!0),e.createVNode(s,{isShowBu:o.isShowBu,isInitialized:o.isInitialized},{userbarActionBox:e.withCtx(()=>[e.renderSlot(t.$slots,"userbarActionBox")]),_:3},8,["isShowBu","isInitialized"])])]),e.createElementVNode("section",Eg,[e.createElementVNode("div",Tg,[!l.ismobile&&l.layoutTags?(e.openBlock(),e.createBlock(S,{key:0,tagShowID:o.tagShowID},null,8,["tagShowID"])):e.createCommentVNode("",!0),e.createElementVNode("div",Ig,[e.renderSlot(t.$slots,"routerView",{},()=>[e.createVNode(B,null,{default:e.withCtx(({Component:A})=>[(e.openBlock(),e.createBlock(e.KeepAlive,{include:this.$store.state.keepAlive.keepLiveRoute},[t.$store.state.keepAlive.routeShow?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(A),{key:t.$route.fullPath})):e.createCommentVNode("",!0)],1032,["include"]))]),_:1})]),e.createVNode(q)])])])],64)):(e.openBlock(),e.createElementBlock("section",Dg,[l.ismobile?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",Fg,[e.createElementVNode("div",qg,[e.createVNode(F)]),e.createElementVNode("div",Rg,[e.createVNode(p,null,{default:e.withCtx(()=>[e.createElementVNode("ul",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.menu,A=>(e.openBlock(),e.createElementBlock("li",{key:A,class:e.normalizeClass(r.pmenu.path==A.path?"active":""),onClick:z=>l.showMenu(A)},[e.createVNode(i,null,{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(A.meta.icon||t.el-t.icon-r.menu)))]),_:2},1024),e.createElementVNode("p",null,e.toDisplayString(A.meta.title),1)],10,Ag))),128))])]),_:1})])])),!l.ismobile&&r.nextMenu.length>0||!r.pmenu.component?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(l.menuIsCollapse?"aminui-side isCollapse":"aminui-side")},[l.menuIsCollapse?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",Og,[e.createElementVNode("h2",null,e.toDisplayString(r.pmenu.meta.title),1)])),e.createElementVNode("div",vg,[e.createVNode(p,null,{default:e.withCtx(()=>[e.createVNode(f,{"default-active":r.active,router:"",collapse:l.menuIsCollapse,"unique-opened":t.$config.MENU_UNIQUE_OPENED},{default:e.withCtx(()=>[e.createVNode(d,{navMenus:r.nextMenu},null,8,["navMenus"])]),_:1},8,["default-active","collapse","unique-opened"])]),_:1})]),e.createElementVNode("div",{class:"adminui-side-bottom",onClick:n[2]||(n[2]=A=>t.$store.commit("TOGGLE_menuIsCollapse"))},[e.createVNode(i,null,{default:e.withCtx(()=>[l.menuIsCollapse?(e.openBlock(),e.createBlock(m,{key:0})):(e.openBlock(),e.createBlock(_,{key:1}))]),_:1})])],2)):e.createCommentVNode("",!0),l.ismobile?(e.openBlock(),e.createBlock(C,{key:2})):e.createCommentVNode("",!0),e.createElementVNode("div",Pg,[e.createVNode(k,null,{default:e.withCtx(()=>[e.createVNode(s,{isShowBu:o.isShowBu,isInitialized:o.isInitialized},{userbarActionBox:e.withCtx(()=>[e.renderSlot(t.$slots,"userbarActionBox")]),_:3},8,["isShowBu","isInitialized"])]),_:3}),!l.ismobile&&l.layoutTags?(e.openBlock(),e.createBlock(S,{key:0,tagShowID:o.tagShowID},null,8,["tagShowID"])):e.createCommentVNode("",!0),e.createElementVNode("div",Lg,[e.renderSlot(t.$slots,"routerView",{},()=>[e.createVNode(B,null,{default:e.withCtx(({Component:A})=>[(e.openBlock(),e.createBlock(e.KeepAlive,{include:this.$store.state.keepAlive.keepLiveRoute},[t.$store.state.keepAlive.routeShow?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(A),{key:t.$route.fullPath})):e.createCommentVNode("",!0)],1032,["include"]))]),_:1})]),e.createVNode(q)])])])),e.createElementVNode("div",{class:"main-maximize-exit",onClick:n[3]||(n[3]=(...A)=>l.exitMaximize&&l.exitMaximize(...A))},[e.createVNode(i,null,{default:e.withCtx(()=>[e.createVNode(V)]),_:1})]),e.createElementVNode("div",{class:"layout-setting",onClick:n[4]||(n[4]=(...A)=>l.openSetting&&l.openSetting(...A))},[e.createVNode(i,null,{default:e.withCtx(()=>[e.createVNode(j)]),_:1})]),e.createVNode(L,{title:"布局实时演示",modelValue:r.settingDialog,"onUpdate:modelValue":n[5]||(n[5]=A=>r.settingDialog=A),size:400,"append-to-body":"","destroy-on-close":""},{default:e.withCtx(()=>[e.createVNode(U)]),_:1},8,["modelValue"])],64)}const Yi=le(tg,[["render",Mg]]);var $t=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function $i(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Wi={exports:{}};/*! For license information please see jsencrypt.min.js.LICENSE.txt */(function(t,n){(function(o,a){t.exports=a()})(window,()=>(()=>{var o={155:i=>{var s,d,f=i.exports={};function p(){throw new Error("setTimeout has not been defined")}function m(){throw new Error("clearTimeout has not been defined")}function _(U){if(s===setTimeout)return setTimeout(U,0);if((s===p||!s)&&setTimeout)return s=setTimeout,setTimeout(U,0);try{return s(U,0)}catch{try{return s.call(null,U,0)}catch{return s.call(this,U,0)}}}(function(){try{s=typeof setTimeout=="function"?setTimeout:p}catch{s=p}try{d=typeof clearTimeout=="function"?clearTimeout:m}catch{d=m}})();var C,k=[],S=!1,B=-1;function q(){S&&C&&(S=!1,C.length?k=C.concat(k):B=-1,k.length&&F())}function F(){if(!S){var U=_(q);S=!0;for(var L=k.length;L;){for(C=k,k=[];++B<L;)C&&C[B].run();B=-1,L=k.length}C=null,S=!1,function(A){if(d===clearTimeout)return clearTimeout(A);if((d===m||!d)&&clearTimeout)return d=clearTimeout,clearTimeout(A);try{return d(A)}catch{try{return d.call(null,A)}catch{return d.call(this,A)}}}(U)}}function V(U,L){this.fun=U,this.array=L}function j(){}f.nextTick=function(U){var L=new Array(arguments.length-1);if(arguments.length>1)for(var A=1;A<arguments.length;A++)L[A-1]=arguments[A];k.push(new V(U,L)),k.length!==1||S||_(F)},V.prototype.run=function(){this.fun.apply(null,this.array)},f.title="browser",f.browser=!0,f.env={},f.argv=[],f.version="",f.versions={},f.on=j,f.addListener=j,f.once=j,f.off=j,f.removeListener=j,f.removeAllListeners=j,f.emit=j,f.prependListener=j,f.prependOnceListener=j,f.listeners=function(U){return[]},f.binding=function(U){throw new Error("process.binding is not supported")},f.cwd=function(){return"/"},f.chdir=function(U){throw new Error("process.chdir is not supported")},f.umask=function(){return 0}}},a={};function r(i){var s=a[i];if(s!==void 0)return s.exports;var d=a[i]={exports:{}};return o[i](d,d.exports,r),d.exports}r.d=(i,s)=>{for(var d in s)r.o(s,d)&&!r.o(i,d)&&Object.defineProperty(i,d,{enumerable:!0,get:s[d]})},r.o=(i,s)=>Object.prototype.hasOwnProperty.call(i,s);var l={};return(()=>{r.d(l,{default:()=>nt});var i="0123456789abcdefghijklmnopqrstuvwxyz";function s(b){return i.charAt(b)}function d(b,c){return b&c}function f(b,c){return b|c}function p(b,c){return b^c}function m(b,c){return b&~c}function _(b){if(b==0)return-1;var c=0;return!(65535&b)&&(b>>=16,c+=16),!(255&b)&&(b>>=8,c+=8),!(15&b)&&(b>>=4,c+=4),!(3&b)&&(b>>=2,c+=2),!(1&b)&&++c,c}function C(b){for(var c=0;b!=0;)b&=b-1,++c;return c}var k,S="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",B="=";function q(b){var c,u,g="";for(c=0;c+3<=b.length;c+=3)u=parseInt(b.substring(c,c+3),16),g+=S.charAt(u>>6)+S.charAt(63&u);for(c+1==b.length?(u=parseInt(b.substring(c,c+1),16),g+=S.charAt(u<<2)):c+2==b.length&&(u=parseInt(b.substring(c,c+2),16),g+=S.charAt(u>>2)+S.charAt((3&u)<<4));(3&g.length)>0;)g+=B;return g}function F(b){var c,u="",g=0,y=0;for(c=0;c<b.length&&b.charAt(c)!=B;++c){var w=S.indexOf(b.charAt(c));w<0||(g==0?(u+=s(w>>2),y=3&w,g=1):g==1?(u+=s(y<<2|w>>4),y=15&w,g=2):g==2?(u+=s(y),u+=s(w>>2),y=3&w,g=3):(u+=s(y<<2|w>>4),u+=s(15&w),g=0))}return g==1&&(u+=s(y<<2)),u}var V,j={decode:function(b){var c;if(V===void 0){var u=`= \f
2
- \r  \u2028\u2029`;for(V=Object.create(null),c=0;c<64;++c)V["ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(c)]=c;for(V["-"]=62,V._=63,c=0;c<u.length;++c)V[u.charAt(c)]=-1}var g=[],y=0,w=0;for(c=0;c<b.length;++c){var N=b.charAt(c);if(N=="=")break;if((N=V[N])!=-1){if(N===void 0)throw new Error("Illegal character at offset "+c);y|=N,++w>=4?(g[g.length]=y>>16,g[g.length]=y>>8&255,g[g.length]=255&y,y=0,w=0):y<<=6}}switch(w){case 1:throw new Error("Base64 encoding incomplete: at least 2 bits missing");case 2:g[g.length]=y>>10;break;case 3:g[g.length]=y>>16,g[g.length]=y>>8&255}return g},re:/-----BEGIN [^-]+-----([A-Za-z0-9+\/=\s]+)-----END [^-]+-----|begin-base64[^\n]+\n([A-Za-z0-9+\/=\s]+)====/,unarmor:function(b){var c=j.re.exec(b);if(c)if(c[1])b=c[1];else{if(!c[2])throw new Error("RegExp out of sync");b=c[2]}return j.decode(b)}},U=1e13,L=function(){function b(c){this.buf=[+c||0]}return b.prototype.mulAdd=function(c,u){var g,y,w=this.buf,N=w.length;for(g=0;g<N;++g)(y=w[g]*c+u)<U?u=0:y-=(u=0|y/U)*U,w[g]=y;u>0&&(w[g]=u)},b.prototype.sub=function(c){var u,g,y=this.buf,w=y.length;for(u=0;u<w;++u)(g=y[u]-c)<0?(g+=U,c=1):c=0,y[u]=g;for(;y[y.length-1]===0;)y.pop()},b.prototype.toString=function(c){if((c||10)!=10)throw new Error("only base 10 is supported");for(var u=this.buf,g=u[u.length-1].toString(),y=u.length-2;y>=0;--y)g+=(U+u[y]).toString().substring(1);return g},b.prototype.valueOf=function(){for(var c=this.buf,u=0,g=c.length-1;g>=0;--g)u=u*U+c[g];return u},b.prototype.simplify=function(){var c=this.buf;return c.length==1?c[0]:this},b}(),A="…",z=/^(\d\d)(0[1-9]|1[0-2])(0[1-9]|[12]\d|3[01])([01]\d|2[0-3])(?:([0-5]\d)(?:([0-5]\d)(?:[.,](\d{1,3}))?)?)?(Z|[-+](?:[0]\d|1[0-2])([0-5]\d)?)?$/,Y=/^(\d\d\d\d)(0[1-9]|1[0-2])(0[1-9]|[12]\d|3[01])([01]\d|2[0-3])(?:([0-5]\d)(?:([0-5]\d)(?:[.,](\d{1,3}))?)?)?(Z|[-+](?:[0]\d|1[0-2])([0-5]\d)?)?$/;function $(b,c){return b.length>c&&(b=b.substring(0,c)+A),b}var H,X=function(){function b(c,u){this.hexDigits="0123456789ABCDEF",c instanceof b?(this.enc=c.enc,this.pos=c.pos):(this.enc=c,this.pos=u)}return b.prototype.get=function(c){if(c===void 0&&(c=this.pos++),c>=this.enc.length)throw new Error("Requesting byte offset ".concat(c," on a stream of length ").concat(this.enc.length));return typeof this.enc=="string"?this.enc.charCodeAt(c):this.enc[c]},b.prototype.hexByte=function(c){return this.hexDigits.charAt(c>>4&15)+this.hexDigits.charAt(15&c)},b.prototype.hexDump=function(c,u,g){for(var y="",w=c;w<u;++w)if(y+=this.hexByte(this.get(w)),g!==!0)switch(15&w){case 7:y+=" ";break;case 15:y+=`
3
- `;break;default:y+=" "}return y},b.prototype.isASCII=function(c,u){for(var g=c;g<u;++g){var y=this.get(g);if(y<32||y>176)return!1}return!0},b.prototype.parseStringISO=function(c,u){for(var g="",y=c;y<u;++y)g+=String.fromCharCode(this.get(y));return g},b.prototype.parseStringUTF=function(c,u){for(var g="",y=c;y<u;){var w=this.get(y++);g+=w<128?String.fromCharCode(w):w>191&&w<224?String.fromCharCode((31&w)<<6|63&this.get(y++)):String.fromCharCode((15&w)<<12|(63&this.get(y++))<<6|63&this.get(y++))}return g},b.prototype.parseStringBMP=function(c,u){for(var g,y,w="",N=c;N<u;)g=this.get(N++),y=this.get(N++),w+=String.fromCharCode(g<<8|y);return w},b.prototype.parseTime=function(c,u,g){var y=this.parseStringISO(c,u),w=(g?z:Y).exec(y);return w?(g&&(w[1]=+w[1],w[1]+=+w[1]<70?2e3:1900),y=w[1]+"-"+w[2]+"-"+w[3]+" "+w[4],w[5]&&(y+=":"+w[5],w[6]&&(y+=":"+w[6],w[7]&&(y+="."+w[7]))),w[8]&&(y+=" UTC",w[8]!="Z"&&(y+=w[8],w[9]&&(y+=":"+w[9]))),y):"Unrecognized time: "+y},b.prototype.parseInteger=function(c,u){for(var g,y=this.get(c),w=y>127,N=w?255:0,E="";y==N&&++c<u;)y=this.get(c);if((g=u-c)==0)return w?-1:0;if(g>4){for(E=y,g<<=3;!(128&(+E^N));)E=+E<<1,--g;E="("+g+` bit)
4
- `}w&&(y-=256);for(var I=new L(y),M=c+1;M<u;++M)I.mulAdd(256,this.get(M));return E+I.toString()},b.prototype.parseBitString=function(c,u,g){for(var y=this.get(c),w="("+((u-c-1<<3)-y)+` bit)
5
- `,N="",E=c+1;E<u;++E){for(var I=this.get(E),M=E==u-1?y:0,W=7;W>=M;--W)N+=I>>W&1?"1":"0";if(N.length>g)return w+$(N,g)}return w+N},b.prototype.parseOctetString=function(c,u,g){if(this.isASCII(c,u))return $(this.parseStringISO(c,u),g);var y=u-c,w="("+y+` byte)
6
- `;y>(g/=2)&&(u=c+g);for(var N=c;N<u;++N)w+=this.hexByte(this.get(N));return y>g&&(w+=A),w},b.prototype.parseOID=function(c,u,g){for(var y="",w=new L,N=0,E=c;E<u;++E){var I=this.get(E);if(w.mulAdd(128,127&I),N+=7,!(128&I)){if(y==="")if((w=w.simplify())instanceof L)w.sub(80),y="2."+w.toString();else{var M=w<80?w<40?0:1:2;y=M+"."+(w-40*M)}else y+="."+w.toString();if(y.length>g)return $(y,g);w=new L,N=0}}return N>0&&(y+=".incomplete"),y},b}(),ie=function(){function b(c,u,g,y,w){if(!(y instanceof R))throw new Error("Invalid tag value.");this.stream=c,this.header=u,this.length=g,this.tag=y,this.sub=w}return b.prototype.typeName=function(){switch(this.tag.tagClass){case 0:switch(this.tag.tagNumber){case 0:return"EOC";case 1:return"BOOLEAN";case 2:return"INTEGER";case 3:return"BIT_STRING";case 4:return"OCTET_STRING";case 5:return"NULL";case 6:return"OBJECT_IDENTIFIER";case 7:return"ObjectDescriptor";case 8:return"EXTERNAL";case 9:return"REAL";case 10:return"ENUMERATED";case 11:return"EMBEDDED_PDV";case 12:return"UTF8String";case 16:return"SEQUENCE";case 17:return"SET";case 18:return"NumericString";case 19:return"PrintableString";case 20:return"TeletexString";case 21:return"VideotexString";case 22:return"IA5String";case 23:return"UTCTime";case 24:return"GeneralizedTime";case 25:return"GraphicString";case 26:return"VisibleString";case 27:return"GeneralString";case 28:return"UniversalString";case 30:return"BMPString"}return"Universal_"+this.tag.tagNumber.toString();case 1:return"Application_"+this.tag.tagNumber.toString();case 2:return"["+this.tag.tagNumber.toString()+"]";case 3:return"Private_"+this.tag.tagNumber.toString()}},b.prototype.content=function(c){if(this.tag===void 0)return null;c===void 0&&(c=1/0);var u=this.posContent(),g=Math.abs(this.length);if(!this.tag.isUniversal())return this.sub!==null?"("+this.sub.length+" elem)":this.stream.parseOctetString(u,u+g,c);switch(this.tag.tagNumber){case 1:return this.stream.get(u)===0?"false":"true";case 2:return this.stream.parseInteger(u,u+g);case 3:return this.sub?"("+this.sub.length+" elem)":this.stream.parseBitString(u,u+g,c);case 4:return this.sub?"("+this.sub.length+" elem)":this.stream.parseOctetString(u,u+g,c);case 6:return this.stream.parseOID(u,u+g,c);case 16:case 17:return this.sub!==null?"("+this.sub.length+" elem)":"(no elem)";case 12:return $(this.stream.parseStringUTF(u,u+g),c);case 18:case 19:case 20:case 21:case 22:case 26:return $(this.stream.parseStringISO(u,u+g),c);case 30:return $(this.stream.parseStringBMP(u,u+g),c);case 23:case 24:return this.stream.parseTime(u,u+g,this.tag.tagNumber==23)}return null},b.prototype.toString=function(){return this.typeName()+"@"+this.stream.pos+"[header:"+this.header+",length:"+this.length+",sub:"+(this.sub===null?"null":this.sub.length)+"]"},b.prototype.toPrettyString=function(c){c===void 0&&(c="");var u=c+this.typeName()+" @"+this.stream.pos;if(this.length>=0&&(u+="+"),u+=this.length,this.tag.tagConstructed?u+=" (constructed)":!this.tag.isUniversal()||this.tag.tagNumber!=3&&this.tag.tagNumber!=4||this.sub===null||(u+=" (encapsulates)"),u+=`
7
- `,this.sub!==null){c+=" ";for(var g=0,y=this.sub.length;g<y;++g)u+=this.sub[g].toPrettyString(c)}return u},b.prototype.posStart=function(){return this.stream.pos},b.prototype.posContent=function(){return this.stream.pos+this.header},b.prototype.posEnd=function(){return this.stream.pos+this.header+Math.abs(this.length)},b.prototype.toHexString=function(){return this.stream.hexDump(this.posStart(),this.posEnd(),!0)},b.decodeLength=function(c){var u=c.get(),g=127&u;if(g==u)return g;if(g>6)throw new Error("Length over 48 bits not supported at position "+(c.pos-1));if(g===0)return null;u=0;for(var y=0;y<g;++y)u=256*u+c.get();return u},b.prototype.getHexStringValue=function(){var c=this.toHexString(),u=2*this.header,g=2*this.length;return c.substr(u,g)},b.decode=function(c){var u;u=c instanceof X?c:new X(c,0);var g=new X(u),y=new R(u),w=b.decodeLength(u),N=u.pos,E=N-g.pos,I=null,M=function(){var de=[];if(w!==null){for(var te=N+w;u.pos<te;)de[de.length]=b.decode(u);if(u.pos!=te)throw new Error("Content size is not correct for container starting at offset "+N)}else try{for(;;){var ge=b.decode(u);if(ge.tag.isEOC())break;de[de.length]=ge}w=N-u.pos}catch(fe){throw new Error("Exception while decoding undefined length content: "+fe)}return de};if(y.tagConstructed)I=M();else if(y.isUniversal()&&(y.tagNumber==3||y.tagNumber==4))try{if(y.tagNumber==3&&u.get()!=0)throw new Error("BIT STRINGs with unused bits cannot encapsulate.");I=M();for(var W=0;W<I.length;++W)if(I[W].tag.isEOC())throw new Error("EOC is not supposed to be actual content.")}catch{I=null}if(I===null){if(w===null)throw new Error("We can't skip over an invalid tag with undefined length at offset "+N);u.pos=N+Math.abs(w)}return new b(g,E,w,y,I)},b}(),R=function(){function b(c){var u=c.get();if(this.tagClass=u>>6,this.tagConstructed=(32&u)!=0,this.tagNumber=31&u,this.tagNumber==31){var g=new L;do u=c.get(),g.mulAdd(128,127&u);while(128&u);this.tagNumber=g.simplify()}}return b.prototype.isUniversal=function(){return this.tagClass===0},b.prototype.isEOC=function(){return this.tagClass===0&&this.tagNumber===0},b}(),ne=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97,101,103,107,109,113,127,131,137,139,149,151,157,163,167,173,179,181,191,193,197,199,211,223,227,229,233,239,241,251,257,263,269,271,277,281,283,293,307,311,313,317,331,337,347,349,353,359,367,373,379,383,389,397,401,409,419,421,431,433,439,443,449,457,461,463,467,479,487,491,499,503,509,521,523,541,547,557,563,569,571,577,587,593,599,601,607,613,617,619,631,641,643,647,653,659,661,673,677,683,691,701,709,719,727,733,739,743,751,757,761,769,773,787,797,809,811,821,823,827,829,839,853,857,859,863,877,881,883,887,907,911,919,929,937,941,947,953,967,971,977,983,991,997],h=(1<<26)/ne[ne.length-1],T=function(){function b(c,u,g){c!=null&&(typeof c=="number"?this.fromNumber(c,u,g):u==null&&typeof c!="string"?this.fromString(c,256):this.fromString(c,u))}return b.prototype.toString=function(c){if(this.s<0)return"-"+this.negate().toString(c);var u;if(c==16)u=4;else if(c==8)u=3;else if(c==2)u=1;else if(c==32)u=5;else{if(c!=4)return this.toRadix(c);u=2}var g,y=(1<<u)-1,w=!1,N="",E=this.t,I=this.DB-E*this.DB%u;if(E-- >0)for(I<this.DB&&(g=this[E]>>I)>0&&(w=!0,N=s(g));E>=0;)I<u?(g=(this[E]&(1<<I)-1)<<u-I,g|=this[--E]>>(I+=this.DB-u)):(g=this[E]>>(I-=u)&y,I<=0&&(I+=this.DB,--E)),g>0&&(w=!0),w&&(N+=s(g));return w?N:"0"},b.prototype.negate=function(){var c=Z();return b.ZERO.subTo(this,c),c},b.prototype.abs=function(){return this.s<0?this.negate():this},b.prototype.compareTo=function(c){var u=this.s-c.s;if(u!=0)return u;var g=this.t;if((u=g-c.t)!=0)return this.s<0?-u:u;for(;--g>=0;)if((u=this[g]-c[g])!=0)return u;return 0},b.prototype.bitLength=function(){return this.t<=0?0:this.DB*(this.t-1)+qe(this[this.t-1]^this.s&this.DM)},b.prototype.mod=function(c){var u=Z();return this.abs().divRemTo(c,null,u),this.s<0&&u.compareTo(b.ZERO)>0&&c.subTo(u,u),u},b.prototype.modPowInt=function(c,u){var g;return g=c<256||u.isEven()?new Ce(u):new G(u),this.exp(c,g)},b.prototype.clone=function(){var c=Z();return this.copyTo(c),c},b.prototype.intValue=function(){if(this.s<0){if(this.t==1)return this[0]-this.DV;if(this.t==0)return-1}else{if(this.t==1)return this[0];if(this.t==0)return 0}return(this[1]&(1<<32-this.DB)-1)<<this.DB|this[0]},b.prototype.byteValue=function(){return this.t==0?this.s:this[0]<<24>>24},b.prototype.shortValue=function(){return this.t==0?this.s:this[0]<<16>>16},b.prototype.signum=function(){return this.s<0?-1:this.t<=0||this.t==1&&this[0]<=0?0:1},b.prototype.toByteArray=function(){var c=this.t,u=[];u[0]=this.s;var g,y=this.DB-c*this.DB%8,w=0;if(c-- >0)for(y<this.DB&&(g=this[c]>>y)!=(this.s&this.DM)>>y&&(u[w++]=g|this.s<<this.DB-y);c>=0;)y<8?(g=(this[c]&(1<<y)-1)<<8-y,g|=this[--c]>>(y+=this.DB-8)):(g=this[c]>>(y-=8)&255,y<=0&&(y+=this.DB,--c)),128&g&&(g|=-256),w==0&&(128&this.s)!=(128&g)&&++w,(w>0||g!=this.s)&&(u[w++]=g);return u},b.prototype.equals=function(c){return this.compareTo(c)==0},b.prototype.min=function(c){return this.compareTo(c)<0?this:c},b.prototype.max=function(c){return this.compareTo(c)>0?this:c},b.prototype.and=function(c){var u=Z();return this.bitwiseTo(c,d,u),u},b.prototype.or=function(c){var u=Z();return this.bitwiseTo(c,f,u),u},b.prototype.xor=function(c){var u=Z();return this.bitwiseTo(c,p,u),u},b.prototype.andNot=function(c){var u=Z();return this.bitwiseTo(c,m,u),u},b.prototype.not=function(){for(var c=Z(),u=0;u<this.t;++u)c[u]=this.DM&~this[u];return c.t=this.t,c.s=~this.s,c},b.prototype.shiftLeft=function(c){var u=Z();return c<0?this.rShiftTo(-c,u):this.lShiftTo(c,u),u},b.prototype.shiftRight=function(c){var u=Z();return c<0?this.lShiftTo(-c,u):this.rShiftTo(c,u),u},b.prototype.getLowestSetBit=function(){for(var c=0;c<this.t;++c)if(this[c]!=0)return c*this.DB+_(this[c]);return this.s<0?this.t*this.DB:-1},b.prototype.bitCount=function(){for(var c=0,u=this.s&this.DM,g=0;g<this.t;++g)c+=C(this[g]^u);return c},b.prototype.testBit=function(c){var u=Math.floor(c/this.DB);return u>=this.t?this.s!=0:(this[u]&1<<c%this.DB)!=0},b.prototype.setBit=function(c){return this.changeBit(c,f)},b.prototype.clearBit=function(c){return this.changeBit(c,m)},b.prototype.flipBit=function(c){return this.changeBit(c,p)},b.prototype.add=function(c){var u=Z();return this.addTo(c,u),u},b.prototype.subtract=function(c){var u=Z();return this.subTo(c,u),u},b.prototype.multiply=function(c){var u=Z();return this.multiplyTo(c,u),u},b.prototype.divide=function(c){var u=Z();return this.divRemTo(c,u,null),u},b.prototype.remainder=function(c){var u=Z();return this.divRemTo(c,null,u),u},b.prototype.divideAndRemainder=function(c){var u=Z(),g=Z();return this.divRemTo(c,u,g),[u,g]},b.prototype.modPow=function(c,u){var g,y,w=c.bitLength(),N=xe(1);if(w<=0)return N;g=w<18?1:w<48?3:w<144?4:w<768?5:6,y=w<8?new Ce(u):u.isEven()?new Te(u):new G(u);var E=[],I=3,M=g-1,W=(1<<g)-1;if(E[1]=y.convert(this),g>1){var de=Z();for(y.sqrTo(E[1],de);I<=W;)E[I]=Z(),y.mulTo(de,E[I-2],E[I]),I+=2}var te,ge,fe=c.t-1,ue=!0,be=Z();for(w=qe(c[fe])-1;fe>=0;){for(w>=M?te=c[fe]>>w-M&W:(te=(c[fe]&(1<<w+1)-1)<<M-w,fe>0&&(te|=c[fe-1]>>this.DB+w-M)),I=g;!(1&te);)te>>=1,--I;if((w-=I)<0&&(w+=this.DB,--fe),ue)E[te].copyTo(N),ue=!1;else{for(;I>1;)y.sqrTo(N,be),y.sqrTo(be,N),I-=2;I>0?y.sqrTo(N,be):(ge=N,N=be,be=ge),y.mulTo(be,E[te],N)}for(;fe>=0&&!(c[fe]&1<<w);)y.sqrTo(N,be),ge=N,N=be,be=ge,--w<0&&(w=this.DB-1,--fe)}return y.revert(N)},b.prototype.modInverse=function(c){var u=c.isEven();if(this.isEven()&&u||c.signum()==0)return b.ZERO;for(var g=c.clone(),y=this.clone(),w=xe(1),N=xe(0),E=xe(0),I=xe(1);g.signum()!=0;){for(;g.isEven();)g.rShiftTo(1,g),u?(w.isEven()&&N.isEven()||(w.addTo(this,w),N.subTo(c,N)),w.rShiftTo(1,w)):N.isEven()||N.subTo(c,N),N.rShiftTo(1,N);for(;y.isEven();)y.rShiftTo(1,y),u?(E.isEven()&&I.isEven()||(E.addTo(this,E),I.subTo(c,I)),E.rShiftTo(1,E)):I.isEven()||I.subTo(c,I),I.rShiftTo(1,I);g.compareTo(y)>=0?(g.subTo(y,g),u&&w.subTo(E,w),N.subTo(I,N)):(y.subTo(g,y),u&&E.subTo(w,E),I.subTo(N,I))}return y.compareTo(b.ONE)!=0?b.ZERO:I.compareTo(c)>=0?I.subtract(c):I.signum()<0?(I.addTo(c,I),I.signum()<0?I.add(c):I):I},b.prototype.pow=function(c){return this.exp(c,new x)},b.prototype.gcd=function(c){var u=this.s<0?this.negate():this.clone(),g=c.s<0?c.negate():c.clone();if(u.compareTo(g)<0){var y=u;u=g,g=y}var w=u.getLowestSetBit(),N=g.getLowestSetBit();if(N<0)return u;for(w<N&&(N=w),N>0&&(u.rShiftTo(N,u),g.rShiftTo(N,g));u.signum()>0;)(w=u.getLowestSetBit())>0&&u.rShiftTo(w,u),(w=g.getLowestSetBit())>0&&g.rShiftTo(w,g),u.compareTo(g)>=0?(u.subTo(g,u),u.rShiftTo(1,u)):(g.subTo(u,g),g.rShiftTo(1,g));return N>0&&g.lShiftTo(N,g),g},b.prototype.isProbablePrime=function(c){var u,g=this.abs();if(g.t==1&&g[0]<=ne[ne.length-1]){for(u=0;u<ne.length;++u)if(g[0]==ne[u])return!0;return!1}if(g.isEven())return!1;for(u=1;u<ne.length;){for(var y=ne[u],w=u+1;w<ne.length&&y<h;)y*=ne[w++];for(y=g.modInt(y);u<w;)if(y%ne[u++]==0)return!1}return g.millerRabin(c)},b.prototype.copyTo=function(c){for(var u=this.t-1;u>=0;--u)c[u]=this[u];c.t=this.t,c.s=this.s},b.prototype.fromInt=function(c){this.t=1,this.s=c<0?-1:0,c>0?this[0]=c:c<-1?this[0]=c+this.DV:this.t=0},b.prototype.fromString=function(c,u){var g;if(u==16)g=4;else if(u==8)g=3;else if(u==256)g=8;else if(u==2)g=1;else if(u==32)g=5;else{if(u!=4)return void this.fromRadix(c,u);g=2}this.t=0,this.s=0;for(var y=c.length,w=!1,N=0;--y>=0;){var E=g==8?255&+c[y]:we(c,y);E<0?c.charAt(y)=="-"&&(w=!0):(w=!1,N==0?this[this.t++]=E:N+g>this.DB?(this[this.t-1]|=(E&(1<<this.DB-N)-1)<<N,this[this.t++]=E>>this.DB-N):this[this.t-1]|=E<<N,(N+=g)>=this.DB&&(N-=this.DB))}g==8&&128&+c[0]&&(this.s=-1,N>0&&(this[this.t-1]|=(1<<this.DB-N)-1<<N)),this.clamp(),w&&b.ZERO.subTo(this,this)},b.prototype.clamp=function(){for(var c=this.s&this.DM;this.t>0&&this[this.t-1]==c;)--this.t},b.prototype.dlShiftTo=function(c,u){var g;for(g=this.t-1;g>=0;--g)u[g+c]=this[g];for(g=c-1;g>=0;--g)u[g]=0;u.t=this.t+c,u.s=this.s},b.prototype.drShiftTo=function(c,u){for(var g=c;g<this.t;++g)u[g-c]=this[g];u.t=Math.max(this.t-c,0),u.s=this.s},b.prototype.lShiftTo=function(c,u){for(var g=c%this.DB,y=this.DB-g,w=(1<<y)-1,N=Math.floor(c/this.DB),E=this.s<<g&this.DM,I=this.t-1;I>=0;--I)u[I+N+1]=this[I]>>y|E,E=(this[I]&w)<<g;for(I=N-1;I>=0;--I)u[I]=0;u[N]=E,u.t=this.t+N+1,u.s=this.s,u.clamp()},b.prototype.rShiftTo=function(c,u){u.s=this.s;var g=Math.floor(c/this.DB);if(g>=this.t)u.t=0;else{var y=c%this.DB,w=this.DB-y,N=(1<<y)-1;u[0]=this[g]>>y;for(var E=g+1;E<this.t;++E)u[E-g-1]|=(this[E]&N)<<w,u[E-g]=this[E]>>y;y>0&&(u[this.t-g-1]|=(this.s&N)<<w),u.t=this.t-g,u.clamp()}},b.prototype.subTo=function(c,u){for(var g=0,y=0,w=Math.min(c.t,this.t);g<w;)y+=this[g]-c[g],u[g++]=y&this.DM,y>>=this.DB;if(c.t<this.t){for(y-=c.s;g<this.t;)y+=this[g],u[g++]=y&this.DM,y>>=this.DB;y+=this.s}else{for(y+=this.s;g<c.t;)y-=c[g],u[g++]=y&this.DM,y>>=this.DB;y-=c.s}u.s=y<0?-1:0,y<-1?u[g++]=this.DV+y:y>0&&(u[g++]=y),u.t=g,u.clamp()},b.prototype.multiplyTo=function(c,u){var g=this.abs(),y=c.abs(),w=g.t;for(u.t=w+y.t;--w>=0;)u[w]=0;for(w=0;w<y.t;++w)u[w+g.t]=g.am(0,y[w],u,w,0,g.t);u.s=0,u.clamp(),this.s!=c.s&&b.ZERO.subTo(u,u)},b.prototype.squareTo=function(c){for(var u=this.abs(),g=c.t=2*u.t;--g>=0;)c[g]=0;for(g=0;g<u.t-1;++g){var y=u.am(g,u[g],c,2*g,0,1);(c[g+u.t]+=u.am(g+1,2*u[g],c,2*g+1,y,u.t-g-1))>=u.DV&&(c[g+u.t]-=u.DV,c[g+u.t+1]=1)}c.t>0&&(c[c.t-1]+=u.am(g,u[g],c,2*g,0,1)),c.s=0,c.clamp()},b.prototype.divRemTo=function(c,u,g){var y=c.abs();if(!(y.t<=0)){var w=this.abs();if(w.t<y.t)return u!=null&&u.fromInt(0),void(g!=null&&this.copyTo(g));g==null&&(g=Z());var N=Z(),E=this.s,I=c.s,M=this.DB-qe(y[y.t-1]);M>0?(y.lShiftTo(M,N),w.lShiftTo(M,g)):(y.copyTo(N),w.copyTo(g));var W=N.t,de=N[W-1];if(de!=0){var te=de*(1<<this.F1)+(W>1?N[W-2]>>this.F2:0),ge=this.FV/te,fe=(1<<this.F1)/te,ue=1<<this.F2,be=g.t,Ae=be-W,D=u??Z();for(N.dlShiftTo(Ae,D),g.compareTo(D)>=0&&(g[g.t++]=1,g.subTo(D,g)),b.ONE.dlShiftTo(W,D),D.subTo(N,N);N.t<W;)N[N.t++]=0;for(;--Ae>=0;){var Ve=g[--be]==de?this.DM:Math.floor(g[be]*ge+(g[be-1]+ue)*fe);if((g[be]+=N.am(0,Ve,g,Ae,0,W))<Ve)for(N.dlShiftTo(Ae,D),g.subTo(D,g);g[be]<--Ve;)g.subTo(D,g)}u!=null&&(g.drShiftTo(W,u),E!=I&&b.ZERO.subTo(u,u)),g.t=W,g.clamp(),M>0&&g.rShiftTo(M,g),E<0&&b.ZERO.subTo(g,g)}}},b.prototype.invDigit=function(){if(this.t<1)return 0;var c=this[0];if(!(1&c))return 0;var u=3&c;return(u=(u=(u=(u=u*(2-(15&c)*u)&15)*(2-(255&c)*u)&255)*(2-((65535&c)*u&65535))&65535)*(2-c*u%this.DV)%this.DV)>0?this.DV-u:-u},b.prototype.isEven=function(){return(this.t>0?1&this[0]:this.s)==0},b.prototype.exp=function(c,u){if(c>4294967295||c<1)return b.ONE;var g=Z(),y=Z(),w=u.convert(this),N=qe(c)-1;for(w.copyTo(g);--N>=0;)if(u.sqrTo(g,y),(c&1<<N)>0)u.mulTo(y,w,g);else{var E=g;g=y,y=E}return u.revert(g)},b.prototype.chunkSize=function(c){return Math.floor(Math.LN2*this.DB/Math.log(c))},b.prototype.toRadix=function(c){if(c==null&&(c=10),this.signum()==0||c<2||c>36)return"0";var u=this.chunkSize(c),g=Math.pow(c,u),y=xe(g),w=Z(),N=Z(),E="";for(this.divRemTo(y,w,N);w.signum()>0;)E=(g+N.intValue()).toString(c).substr(1)+E,w.divRemTo(y,w,N);return N.intValue().toString(c)+E},b.prototype.fromRadix=function(c,u){this.fromInt(0),u==null&&(u=10);for(var g=this.chunkSize(u),y=Math.pow(u,g),w=!1,N=0,E=0,I=0;I<c.length;++I){var M=we(c,I);M<0?c.charAt(I)=="-"&&this.signum()==0&&(w=!0):(E=u*E+M,++N>=g&&(this.dMultiply(y),this.dAddOffset(E,0),N=0,E=0))}N>0&&(this.dMultiply(Math.pow(u,N)),this.dAddOffset(E,0)),w&&b.ZERO.subTo(this,this)},b.prototype.fromNumber=function(c,u,g){if(typeof u=="number")if(c<2)this.fromInt(1);else for(this.fromNumber(c,g),this.testBit(c-1)||this.bitwiseTo(b.ONE.shiftLeft(c-1),f,this),this.isEven()&&this.dAddOffset(1,0);!this.isProbablePrime(u);)this.dAddOffset(2,0),this.bitLength()>c&&this.subTo(b.ONE.shiftLeft(c-1),this);else{var y=[],w=7&c;y.length=1+(c>>3),u.nextBytes(y),w>0?y[0]&=(1<<w)-1:y[0]=0,this.fromString(y,256)}},b.prototype.bitwiseTo=function(c,u,g){var y,w,N=Math.min(c.t,this.t);for(y=0;y<N;++y)g[y]=u(this[y],c[y]);if(c.t<this.t){for(w=c.s&this.DM,y=N;y<this.t;++y)g[y]=u(this[y],w);g.t=this.t}else{for(w=this.s&this.DM,y=N;y<c.t;++y)g[y]=u(w,c[y]);g.t=c.t}g.s=u(this.s,c.s),g.clamp()},b.prototype.changeBit=function(c,u){var g=b.ONE.shiftLeft(c);return this.bitwiseTo(g,u,g),g},b.prototype.addTo=function(c,u){for(var g=0,y=0,w=Math.min(c.t,this.t);g<w;)y+=this[g]+c[g],u[g++]=y&this.DM,y>>=this.DB;if(c.t<this.t){for(y+=c.s;g<this.t;)y+=this[g],u[g++]=y&this.DM,y>>=this.DB;y+=this.s}else{for(y+=this.s;g<c.t;)y+=c[g],u[g++]=y&this.DM,y>>=this.DB;y+=c.s}u.s=y<0?-1:0,y>0?u[g++]=y:y<-1&&(u[g++]=this.DV+y),u.t=g,u.clamp()},b.prototype.dMultiply=function(c){this[this.t]=this.am(0,c-1,this,0,0,this.t),++this.t,this.clamp()},b.prototype.dAddOffset=function(c,u){if(c!=0){for(;this.t<=u;)this[this.t++]=0;for(this[u]+=c;this[u]>=this.DV;)this[u]-=this.DV,++u>=this.t&&(this[this.t++]=0),++this[u]}},b.prototype.multiplyLowerTo=function(c,u,g){var y=Math.min(this.t+c.t,u);for(g.s=0,g.t=y;y>0;)g[--y]=0;for(var w=g.t-this.t;y<w;++y)g[y+this.t]=this.am(0,c[y],g,y,0,this.t);for(w=Math.min(c.t,u);y<w;++y)this.am(0,c[y],g,y,0,u-y);g.clamp()},b.prototype.multiplyUpperTo=function(c,u,g){--u;var y=g.t=this.t+c.t-u;for(g.s=0;--y>=0;)g[y]=0;for(y=Math.max(u-this.t,0);y<c.t;++y)g[this.t+y-u]=this.am(u-y,c[y],g,0,0,this.t+y-u);g.clamp(),g.drShiftTo(1,g)},b.prototype.modInt=function(c){if(c<=0)return 0;var u=this.DV%c,g=this.s<0?c-1:0;if(this.t>0)if(u==0)g=this[0]%c;else for(var y=this.t-1;y>=0;--y)g=(u*g+this[y])%c;return g},b.prototype.millerRabin=function(c){var u=this.subtract(b.ONE),g=u.getLowestSetBit();if(g<=0)return!1;var y=u.shiftRight(g);(c=c+1>>1)>ne.length&&(c=ne.length);for(var w=Z(),N=0;N<c;++N){w.fromInt(ne[Math.floor(Math.random()*ne.length)]);var E=w.modPow(y,this);if(E.compareTo(b.ONE)!=0&&E.compareTo(u)!=0){for(var I=1;I++<g&&E.compareTo(u)!=0;)if((E=E.modPowInt(2,this)).compareTo(b.ONE)==0)return!1;if(E.compareTo(u)!=0)return!1}}return!0},b.prototype.square=function(){var c=Z();return this.squareTo(c),c},b.prototype.gcda=function(c,u){var g=this.s<0?this.negate():this.clone(),y=c.s<0?c.negate():c.clone();if(g.compareTo(y)<0){var w=g;g=y,y=w}var N=g.getLowestSetBit(),E=y.getLowestSetBit();if(E<0)u(g);else{N<E&&(E=N),E>0&&(g.rShiftTo(E,g),y.rShiftTo(E,y));var I=function(){(N=g.getLowestSetBit())>0&&g.rShiftTo(N,g),(N=y.getLowestSetBit())>0&&y.rShiftTo(N,y),g.compareTo(y)>=0?(g.subTo(y,g),g.rShiftTo(1,g)):(y.subTo(g,y),y.rShiftTo(1,y)),g.signum()>0?setTimeout(I,0):(E>0&&y.lShiftTo(E,y),setTimeout(function(){u(y)},0))};setTimeout(I,10)}},b.prototype.fromNumberAsync=function(c,u,g,y){if(typeof u=="number")if(c<2)this.fromInt(1);else{this.fromNumber(c,g),this.testBit(c-1)||this.bitwiseTo(b.ONE.shiftLeft(c-1),f,this),this.isEven()&&this.dAddOffset(1,0);var w=this,N=function(){w.dAddOffset(2,0),w.bitLength()>c&&w.subTo(b.ONE.shiftLeft(c-1),w),w.isProbablePrime(u)?setTimeout(function(){y()},0):setTimeout(N,0)};setTimeout(N,0)}else{var E=[],I=7&c;E.length=1+(c>>3),u.nextBytes(E),I>0?E[0]&=(1<<I)-1:E[0]=0,this.fromString(E,256)}},b}(),x=function(){function b(){}return b.prototype.convert=function(c){return c},b.prototype.revert=function(c){return c},b.prototype.mulTo=function(c,u,g){c.multiplyTo(u,g)},b.prototype.sqrTo=function(c,u){c.squareTo(u)},b}(),Ce=function(){function b(c){this.m=c}return b.prototype.convert=function(c){return c.s<0||c.compareTo(this.m)>=0?c.mod(this.m):c},b.prototype.revert=function(c){return c},b.prototype.reduce=function(c){c.divRemTo(this.m,null,c)},b.prototype.mulTo=function(c,u,g){c.multiplyTo(u,g),this.reduce(g)},b.prototype.sqrTo=function(c,u){c.squareTo(u),this.reduce(u)},b}(),G=function(){function b(c){this.m=c,this.mp=c.invDigit(),this.mpl=32767&this.mp,this.mph=this.mp>>15,this.um=(1<<c.DB-15)-1,this.mt2=2*c.t}return b.prototype.convert=function(c){var u=Z();return c.abs().dlShiftTo(this.m.t,u),u.divRemTo(this.m,null,u),c.s<0&&u.compareTo(T.ZERO)>0&&this.m.subTo(u,u),u},b.prototype.revert=function(c){var u=Z();return c.copyTo(u),this.reduce(u),u},b.prototype.reduce=function(c){for(;c.t<=this.mt2;)c[c.t++]=0;for(var u=0;u<this.m.t;++u){var g=32767&c[u],y=g*this.mpl+((g*this.mph+(c[u]>>15)*this.mpl&this.um)<<15)&c.DM;for(c[g=u+this.m.t]+=this.m.am(0,y,c,u,0,this.m.t);c[g]>=c.DV;)c[g]-=c.DV,c[++g]++}c.clamp(),c.drShiftTo(this.m.t,c),c.compareTo(this.m)>=0&&c.subTo(this.m,c)},b.prototype.mulTo=function(c,u,g){c.multiplyTo(u,g),this.reduce(g)},b.prototype.sqrTo=function(c,u){c.squareTo(u),this.reduce(u)},b}(),Te=function(){function b(c){this.m=c,this.r2=Z(),this.q3=Z(),T.ONE.dlShiftTo(2*c.t,this.r2),this.mu=this.r2.divide(c)}return b.prototype.convert=function(c){if(c.s<0||c.t>2*this.m.t)return c.mod(this.m);if(c.compareTo(this.m)<0)return c;var u=Z();return c.copyTo(u),this.reduce(u),u},b.prototype.revert=function(c){return c},b.prototype.reduce=function(c){for(c.drShiftTo(this.m.t-1,this.r2),c.t>this.m.t+1&&(c.t=this.m.t+1,c.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);c.compareTo(this.r2)<0;)c.dAddOffset(1,this.m.t+1);for(c.subTo(this.r2,c);c.compareTo(this.m)>=0;)c.subTo(this.m,c)},b.prototype.mulTo=function(c,u,g){c.multiplyTo(u,g),this.reduce(g)},b.prototype.sqrTo=function(c,u){c.squareTo(u),this.reduce(u)},b}();function Z(){return new T(null)}function P(b,c){return new T(b,c)}var J=typeof navigator<"u";J&&navigator.appName=="Microsoft Internet Explorer"?(T.prototype.am=function(b,c,u,g,y,w){for(var N=32767&c,E=c>>15;--w>=0;){var I=32767&this[b],M=this[b++]>>15,W=E*I+M*N;y=((I=N*I+((32767&W)<<15)+u[g]+(1073741823&y))>>>30)+(W>>>15)+E*M+(y>>>30),u[g++]=1073741823&I}return y},H=30):J&&navigator.appName!="Netscape"?(T.prototype.am=function(b,c,u,g,y,w){for(;--w>=0;){var N=c*this[b++]+u[g]+y;y=Math.floor(N/67108864),u[g++]=67108863&N}return y},H=26):(T.prototype.am=function(b,c,u,g,y,w){for(var N=16383&c,E=c>>14;--w>=0;){var I=16383&this[b],M=this[b++]>>14,W=E*I+M*N;y=((I=N*I+((16383&W)<<14)+u[g]+y)>>28)+(W>>14)+E*M,u[g++]=268435455&I}return y},H=28),T.prototype.DB=H,T.prototype.DM=(1<<H)-1,T.prototype.DV=1<<H,T.prototype.FV=Math.pow(2,52),T.prototype.F1=52-H,T.prototype.F2=2*H-52;var ee,ce,ye=[];for(ee=48,ce=0;ce<=9;++ce)ye[ee++]=ce;for(ee=97,ce=10;ce<36;++ce)ye[ee++]=ce;for(ee=65,ce=10;ce<36;++ce)ye[ee++]=ce;function we(b,c){var u=ye[b.charCodeAt(c)];return u??-1}function xe(b){var c=Z();return c.fromInt(b),c}function qe(b){var c,u=1;return(c=b>>>16)!=0&&(b=c,u+=16),(c=b>>8)!=0&&(b=c,u+=8),(c=b>>4)!=0&&(b=c,u+=4),(c=b>>2)!=0&&(b=c,u+=2),(c=b>>1)!=0&&(b=c,u+=1),u}T.ZERO=xe(0),T.ONE=xe(1);var Re,Ne,Ge=function(){function b(){this.i=0,this.j=0,this.S=[]}return b.prototype.init=function(c){var u,g,y;for(u=0;u<256;++u)this.S[u]=u;for(g=0,u=0;u<256;++u)g=g+this.S[u]+c[u%c.length]&255,y=this.S[u],this.S[u]=this.S[g],this.S[g]=y;this.i=0,this.j=0},b.prototype.next=function(){var c;return this.i=this.i+1&255,this.j=this.j+this.S[this.i]&255,c=this.S[this.i],this.S[this.i]=this.S[this.j],this.S[this.j]=c,this.S[c+this.S[this.i]&255]},b}(),je=256,ae=null;if(ae==null){ae=[],Ne=0;var v=void 0;if(typeof window<"u"&&window.crypto&&window.crypto.getRandomValues){var Q=new Uint32Array(256);for(window.crypto.getRandomValues(Q),v=0;v<Q.length;++v)ae[Ne++]=255&Q[v]}var Be=0,Ie=function(b){if((Be=Be||0)>=256||Ne>=je)window.removeEventListener?window.removeEventListener("mousemove",Ie,!1):window.detachEvent&&window.detachEvent("onmousemove",Ie);else try{var c=b.x+b.y;ae[Ne++]=255&c,Be+=1}catch{}};typeof window<"u"&&(window.addEventListener?window.addEventListener("mousemove",Ie,!1):window.attachEvent&&window.attachEvent("onmousemove",Ie))}function dt(){if(Re==null){for(Re=new Ge;Ne<je;){var b=Math.floor(65536*Math.random());ae[Ne++]=255&b}for(Re.init(ae),Ne=0;Ne<ae.length;++Ne)ae[Ne]=0;Ne=0}return Re.next()}var ve=function(){function b(){}return b.prototype.nextBytes=function(c){for(var u=0;u<c.length;++u)c[u]=dt()},b}(),Fe=function(){function b(){this.n=null,this.e=0,this.d=null,this.p=null,this.q=null,this.dmp1=null,this.dmq1=null,this.coeff=null}return b.prototype.doPublic=function(c){return c.modPowInt(this.e,this.n)},b.prototype.doPrivate=function(c){if(this.p==null||this.q==null)return c.modPow(this.d,this.n);for(var u=c.mod(this.p).modPow(this.dmp1,this.p),g=c.mod(this.q).modPow(this.dmq1,this.q);u.compareTo(g)<0;)u=u.add(this.p);return u.subtract(g).multiply(this.coeff).mod(this.p).multiply(this.q).add(g)},b.prototype.setPublic=function(c,u){c!=null&&u!=null&&c.length>0&&u.length>0?(this.n=P(c,16),this.e=parseInt(u,16)):console.error("Invalid RSA public key")},b.prototype.encrypt=function(c){var u=this.n.bitLength()+7>>3,g=function(I,M){if(M<I.length+11)return console.error("Message too long for RSA"),null;for(var W=[],de=I.length-1;de>=0&&M>0;){var te=I.charCodeAt(de--);te<128?W[--M]=te:te>127&&te<2048?(W[--M]=63&te|128,W[--M]=te>>6|192):(W[--M]=63&te|128,W[--M]=te>>6&63|128,W[--M]=te>>12|224)}W[--M]=0;for(var ge=new ve,fe=[];M>2;){for(fe[0]=0;fe[0]==0;)ge.nextBytes(fe);W[--M]=fe[0]}return W[--M]=2,W[--M]=0,new T(W)}(c,u);if(g==null)return null;var y=this.doPublic(g);if(y==null)return null;for(var w=y.toString(16),N=w.length,E=0;E<2*u-N;E++)w="0"+w;return w},b.prototype.setPrivate=function(c,u,g){c!=null&&u!=null&&c.length>0&&u.length>0?(this.n=P(c,16),this.e=parseInt(u,16),this.d=P(g,16)):console.error("Invalid RSA private key")},b.prototype.setPrivateEx=function(c,u,g,y,w,N,E,I){c!=null&&u!=null&&c.length>0&&u.length>0?(this.n=P(c,16),this.e=parseInt(u,16),this.d=P(g,16),this.p=P(y,16),this.q=P(w,16),this.dmp1=P(N,16),this.dmq1=P(E,16),this.coeff=P(I,16)):console.error("Invalid RSA private key")},b.prototype.generate=function(c,u){var g=new ve,y=c>>1;this.e=parseInt(u,16);for(var w=new T(u,16);;){for(;this.p=new T(c-y,1,g),this.p.subtract(T.ONE).gcd(w).compareTo(T.ONE)!=0||!this.p.isProbablePrime(10););for(;this.q=new T(y,1,g),this.q.subtract(T.ONE).gcd(w).compareTo(T.ONE)!=0||!this.q.isProbablePrime(10););if(this.p.compareTo(this.q)<=0){var N=this.p;this.p=this.q,this.q=N}var E=this.p.subtract(T.ONE),I=this.q.subtract(T.ONE),M=E.multiply(I);if(M.gcd(w).compareTo(T.ONE)==0){this.n=this.p.multiply(this.q),this.d=w.modInverse(M),this.dmp1=this.d.mod(E),this.dmq1=this.d.mod(I),this.coeff=this.q.modInverse(this.p);break}}},b.prototype.decrypt=function(c){var u=P(c,16),g=this.doPrivate(u);return g==null?null:function(y,w){for(var N=y.toByteArray(),E=0;E<N.length&&N[E]==0;)++E;if(N.length-E!=w-1||N[E]!=2)return null;for(++E;N[E]!=0;)if(++E>=N.length)return null;for(var I="";++E<N.length;){var M=255&N[E];M<128?I+=String.fromCharCode(M):M>191&&M<224?(I+=String.fromCharCode((31&M)<<6|63&N[E+1]),++E):(I+=String.fromCharCode((15&M)<<12|(63&N[E+1])<<6|63&N[E+2]),E+=2)}return I}(g,this.n.bitLength()+7>>3)},b.prototype.generateAsync=function(c,u,g){var y=new ve,w=c>>1;this.e=parseInt(u,16);var N=new T(u,16),E=this,I=function(){var M=function(){if(E.p.compareTo(E.q)<=0){var te=E.p;E.p=E.q,E.q=te}var ge=E.p.subtract(T.ONE),fe=E.q.subtract(T.ONE),ue=ge.multiply(fe);ue.gcd(N).compareTo(T.ONE)==0?(E.n=E.p.multiply(E.q),E.d=N.modInverse(ue),E.dmp1=E.d.mod(ge),E.dmq1=E.d.mod(fe),E.coeff=E.q.modInverse(E.p),setTimeout(function(){g()},0)):setTimeout(I,0)},W=function(){E.q=Z(),E.q.fromNumberAsync(w,1,y,function(){E.q.subtract(T.ONE).gcda(N,function(te){te.compareTo(T.ONE)==0&&E.q.isProbablePrime(10)?setTimeout(M,0):setTimeout(W,0)})})},de=function(){E.p=Z(),E.p.fromNumberAsync(c-w,1,y,function(){E.p.subtract(T.ONE).gcda(N,function(te){te.compareTo(T.ONE)==0&&E.p.isProbablePrime(10)?setTimeout(W,0):setTimeout(de,0)})})};setTimeout(de,0)};setTimeout(I,0)},b.prototype.sign=function(c,u,g){var y=function(E,I){if(I<E.length+22)return console.error("Message too long for RSA"),null;for(var M=I-E.length-6,W="",de=0;de<M;de+=2)W+="ff";return P("0001"+W+"00"+E,16)}((_e[g]||"")+u(c).toString(),this.n.bitLength()/4);if(y==null)return null;var w=this.doPrivate(y);if(w==null)return null;var N=w.toString(16);return 1&N.length?"0"+N:N},b.prototype.verify=function(c,u,g){var y=P(u,16),w=this.doPublic(y);return w==null?null:function(N){for(var E in _e)if(_e.hasOwnProperty(E)){var I=_e[E],M=I.length;if(N.substr(0,M)==I)return N.substr(M)}return N}(w.toString(16).replace(/^1f+00/,""))==g(c).toString()},b}(),_e={md2:"3020300c06082a864886f70d020205000410",md5:"3020300c06082a864886f70d020505000410",sha1:"3021300906052b0e03021a05000414",sha224:"302d300d06096086480165030402040500041c",sha256:"3031300d060960864801650304020105000420",sha384:"3041300d060960864801650304020205000430",sha512:"3051300d060960864801650304020305000440",ripemd160:"3021300906052b2403020105000414"},pe={};pe.lang={extend:function(b,c,u){if(!c||!b)throw new Error("YAHOO.lang.extend failed, please check that all dependencies are included.");var g=function(){};if(g.prototype=c.prototype,b.prototype=new g,b.prototype.constructor=b,b.superclass=c.prototype,c.prototype.constructor==Object.prototype.constructor&&(c.prototype.constructor=c),u){var y;for(y in u)b.prototype[y]=u[y];var w=function(){},N=["toString","valueOf"];try{/MSIE/.test(navigator.userAgent)&&(w=function(E,I){for(y=0;y<N.length;y+=1){var M=N[y],W=I[M];typeof W=="function"&&W!=Object.prototype[M]&&(E[M]=W)}})}catch{}w(b.prototype,u)}}};var O={};O.asn1!==void 0&&O.asn1||(O.asn1={}),O.asn1.ASN1Util=new function(){this.integerToByteHex=function(b){var c=b.toString(16);return c.length%2==1&&(c="0"+c),c},this.bigIntToMinTwosComplementsHex=function(b){var c=b.toString(16);if(c.substr(0,1)!="-")c.length%2==1?c="0"+c:c.match(/^[0-7]/)||(c="00"+c);else{var u=c.substr(1).length;u%2==1?u+=1:c.match(/^[0-7]/)||(u+=2);for(var g="",y=0;y<u;y++)g+="f";c=new T(g,16).xor(b).add(T.ONE).toString(16).replace(/^-/,"")}return c},this.getPEMStringFromHex=function(b,c){return hextopem(b,c)},this.newObject=function(b){var c=O.asn1,u=c.DERBoolean,g=c.DERInteger,y=c.DERBitString,w=c.DEROctetString,N=c.DERNull,E=c.DERObjectIdentifier,I=c.DEREnumerated,M=c.DERUTF8String,W=c.DERNumericString,de=c.DERPrintableString,te=c.DERTeletexString,ge=c.DERIA5String,fe=c.DERUTCTime,ue=c.DERGeneralizedTime,be=c.DERSequence,Ae=c.DERSet,D=c.DERTaggedObject,Ve=c.ASN1Util.newObject,De=Object.keys(b);if(De.length!=1)throw"key of param shall be only one.";var oe=De[0];if(":bool:int:bitstr:octstr:null:oid:enum:utf8str:numstr:prnstr:telstr:ia5str:utctime:gentime:seq:set:tag:".indexOf(":"+oe+":")==-1)throw"undefined key: "+oe;if(oe=="bool")return new u(b[oe]);if(oe=="int")return new g(b[oe]);if(oe=="bitstr")return new y(b[oe]);if(oe=="octstr")return new w(b[oe]);if(oe=="null")return new N(b[oe]);if(oe=="oid")return new E(b[oe]);if(oe=="enum")return new I(b[oe]);if(oe=="utf8str")return new M(b[oe]);if(oe=="numstr")return new W(b[oe]);if(oe=="prnstr")return new de(b[oe]);if(oe=="telstr")return new te(b[oe]);if(oe=="ia5str")return new ge(b[oe]);if(oe=="utctime")return new fe(b[oe]);if(oe=="gentime")return new ue(b[oe]);if(oe=="seq"){for(var bt=b[oe],yt=[],ot=0;ot<bt.length;ot++){var qt=Ve(bt[ot]);yt.push(qt)}return new be({array:yt})}if(oe=="set"){for(bt=b[oe],yt=[],ot=0;ot<bt.length;ot++)qt=Ve(bt[ot]),yt.push(qt);return new Ae({array:yt})}if(oe=="tag"){var Le=b[oe];if(Object.prototype.toString.call(Le)==="[object Array]"&&Le.length==3){var Vn=Ve(Le[2]);return new D({tag:Le[0],explicit:Le[1],obj:Vn})}var Bt={};if(Le.explicit!==void 0&&(Bt.explicit=Le.explicit),Le.tag!==void 0&&(Bt.tag=Le.tag),Le.obj===void 0)throw"obj shall be specified for 'tag'.";return Bt.obj=Ve(Le.obj),new D(Bt)}},this.jsonToASN1HEX=function(b){return this.newObject(b).getEncodedHex()}},O.asn1.ASN1Util.oidHexToInt=function(b){for(var c="",u=parseInt(b.substr(0,2),16),g=(c=Math.floor(u/40)+"."+u%40,""),y=2;y<b.length;y+=2){var w=("00000000"+parseInt(b.substr(y,2),16).toString(2)).slice(-8);g+=w.substr(1,7),w.substr(0,1)=="0"&&(c=c+"."+new T(g,2).toString(10),g="")}return c},O.asn1.ASN1Util.oidIntToHex=function(b){var c=function(E){var I=E.toString(16);return I.length==1&&(I="0"+I),I},u=function(E){var I="",M=new T(E,10).toString(2),W=7-M.length%7;W==7&&(W=0);for(var de="",te=0;te<W;te++)de+="0";for(M=de+M,te=0;te<M.length-1;te+=7){var ge=M.substr(te,7);te!=M.length-7&&(ge="1"+ge),I+=c(parseInt(ge,2))}return I};if(!b.match(/^[0-9.]+$/))throw"malformed oid string: "+b;var g="",y=b.split("."),w=40*parseInt(y[0])+parseInt(y[1]);g+=c(w),y.splice(0,2);for(var N=0;N<y.length;N++)g+=u(y[N]);return g},O.asn1.ASN1Object=function(){this.getLengthHexFromValue=function(){if(this.hV===void 0||this.hV==null)throw"this.hV is null or undefined.";if(this.hV.length%2==1)throw"value hex must be even length: n=0,v="+this.hV;var b=this.hV.length/2,c=b.toString(16);if(c.length%2==1&&(c="0"+c),b<128)return c;var u=c.length/2;if(u>15)throw"ASN.1 length too long to represent by 8x: n = "+b.toString(16);return(128+u).toString(16)+c},this.getEncodedHex=function(){return(this.hTLV==null||this.isModified)&&(this.hV=this.getFreshValueHex(),this.hL=this.getLengthHexFromValue(),this.hTLV=this.hT+this.hL+this.hV,this.isModified=!1),this.hTLV},this.getValueHex=function(){return this.getEncodedHex(),this.hV},this.getFreshValueHex=function(){return""}},O.asn1.DERAbstractString=function(b){O.asn1.DERAbstractString.superclass.constructor.call(this),this.getString=function(){return this.s},this.setString=function(c){this.hTLV=null,this.isModified=!0,this.s=c,this.hV=stohex(this.s)},this.setStringHex=function(c){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=c},this.getFreshValueHex=function(){return this.hV},b!==void 0&&(typeof b=="string"?this.setString(b):b.str!==void 0?this.setString(b.str):b.hex!==void 0&&this.setStringHex(b.hex))},pe.lang.extend(O.asn1.DERAbstractString,O.asn1.ASN1Object),O.asn1.DERAbstractTime=function(b){O.asn1.DERAbstractTime.superclass.constructor.call(this),this.localDateToUTC=function(c){return utc=c.getTime()+6e4*c.getTimezoneOffset(),new Date(utc)},this.formatDate=function(c,u,g){var y=this.zeroPadding,w=this.localDateToUTC(c),N=String(w.getFullYear());u=="utc"&&(N=N.substr(2,2));var E=N+y(String(w.getMonth()+1),2)+y(String(w.getDate()),2)+y(String(w.getHours()),2)+y(String(w.getMinutes()),2)+y(String(w.getSeconds()),2);if(g===!0){var I=w.getMilliseconds();if(I!=0){var M=y(String(I),3);E=E+"."+(M=M.replace(/[0]+$/,""))}}return E+"Z"},this.zeroPadding=function(c,u){return c.length>=u?c:new Array(u-c.length+1).join("0")+c},this.getString=function(){return this.s},this.setString=function(c){this.hTLV=null,this.isModified=!0,this.s=c,this.hV=stohex(c)},this.setByDateValue=function(c,u,g,y,w,N){var E=new Date(Date.UTC(c,u-1,g,y,w,N,0));this.setByDate(E)},this.getFreshValueHex=function(){return this.hV}},pe.lang.extend(O.asn1.DERAbstractTime,O.asn1.ASN1Object),O.asn1.DERAbstractStructured=function(b){O.asn1.DERAbstractString.superclass.constructor.call(this),this.setByASN1ObjectArray=function(c){this.hTLV=null,this.isModified=!0,this.asn1Array=c},this.appendASN1Object=function(c){this.hTLV=null,this.isModified=!0,this.asn1Array.push(c)},this.asn1Array=new Array,b!==void 0&&b.array!==void 0&&(this.asn1Array=b.array)},pe.lang.extend(O.asn1.DERAbstractStructured,O.asn1.ASN1Object),O.asn1.DERBoolean=function(){O.asn1.DERBoolean.superclass.constructor.call(this),this.hT="01",this.hTLV="0101ff"},pe.lang.extend(O.asn1.DERBoolean,O.asn1.ASN1Object),O.asn1.DERInteger=function(b){O.asn1.DERInteger.superclass.constructor.call(this),this.hT="02",this.setByBigInteger=function(c){this.hTLV=null,this.isModified=!0,this.hV=O.asn1.ASN1Util.bigIntToMinTwosComplementsHex(c)},this.setByInteger=function(c){var u=new T(String(c),10);this.setByBigInteger(u)},this.setValueHex=function(c){this.hV=c},this.getFreshValueHex=function(){return this.hV},b!==void 0&&(b.bigint!==void 0?this.setByBigInteger(b.bigint):b.int!==void 0?this.setByInteger(b.int):typeof b=="number"?this.setByInteger(b):b.hex!==void 0&&this.setValueHex(b.hex))},pe.lang.extend(O.asn1.DERInteger,O.asn1.ASN1Object),O.asn1.DERBitString=function(b){if(b!==void 0&&b.obj!==void 0){var c=O.asn1.ASN1Util.newObject(b.obj);b.hex="00"+c.getEncodedHex()}O.asn1.DERBitString.superclass.constructor.call(this),this.hT="03",this.setHexValueIncludingUnusedBits=function(u){this.hTLV=null,this.isModified=!0,this.hV=u},this.setUnusedBitsAndHexValue=function(u,g){if(u<0||7<u)throw"unused bits shall be from 0 to 7: u = "+u;var y="0"+u;this.hTLV=null,this.isModified=!0,this.hV=y+g},this.setByBinaryString=function(u){var g=8-(u=u.replace(/0+$/,"")).length%8;g==8&&(g=0);for(var y=0;y<=g;y++)u+="0";var w="";for(y=0;y<u.length-1;y+=8){var N=u.substr(y,8),E=parseInt(N,2).toString(16);E.length==1&&(E="0"+E),w+=E}this.hTLV=null,this.isModified=!0,this.hV="0"+g+w},this.setByBooleanArray=function(u){for(var g="",y=0;y<u.length;y++)u[y]==1?g+="1":g+="0";this.setByBinaryString(g)},this.newFalseArray=function(u){for(var g=new Array(u),y=0;y<u;y++)g[y]=!1;return g},this.getFreshValueHex=function(){return this.hV},b!==void 0&&(typeof b=="string"&&b.toLowerCase().match(/^[0-9a-f]+$/)?this.setHexValueIncludingUnusedBits(b):b.hex!==void 0?this.setHexValueIncludingUnusedBits(b.hex):b.bin!==void 0?this.setByBinaryString(b.bin):b.array!==void 0&&this.setByBooleanArray(b.array))},pe.lang.extend(O.asn1.DERBitString,O.asn1.ASN1Object),O.asn1.DEROctetString=function(b){if(b!==void 0&&b.obj!==void 0){var c=O.asn1.ASN1Util.newObject(b.obj);b.hex=c.getEncodedHex()}O.asn1.DEROctetString.superclass.constructor.call(this,b),this.hT="04"},pe.lang.extend(O.asn1.DEROctetString,O.asn1.DERAbstractString),O.asn1.DERNull=function(){O.asn1.DERNull.superclass.constructor.call(this),this.hT="05",this.hTLV="0500"},pe.lang.extend(O.asn1.DERNull,O.asn1.ASN1Object),O.asn1.DERObjectIdentifier=function(b){var c=function(g){var y=g.toString(16);return y.length==1&&(y="0"+y),y},u=function(g){var y="",w=new T(g,10).toString(2),N=7-w.length%7;N==7&&(N=0);for(var E="",I=0;I<N;I++)E+="0";for(w=E+w,I=0;I<w.length-1;I+=7){var M=w.substr(I,7);I!=w.length-7&&(M="1"+M),y+=c(parseInt(M,2))}return y};O.asn1.DERObjectIdentifier.superclass.constructor.call(this),this.hT="06",this.setValueHex=function(g){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=g},this.setValueOidString=function(g){if(!g.match(/^[0-9.]+$/))throw"malformed oid string: "+g;var y="",w=g.split("."),N=40*parseInt(w[0])+parseInt(w[1]);y+=c(N),w.splice(0,2);for(var E=0;E<w.length;E++)y+=u(w[E]);this.hTLV=null,this.isModified=!0,this.s=null,this.hV=y},this.setValueName=function(g){var y=O.asn1.x509.OID.name2oid(g);if(y==="")throw"DERObjectIdentifier oidName undefined: "+g;this.setValueOidString(y)},this.getFreshValueHex=function(){return this.hV},b!==void 0&&(typeof b=="string"?b.match(/^[0-2].[0-9.]+$/)?this.setValueOidString(b):this.setValueName(b):b.oid!==void 0?this.setValueOidString(b.oid):b.hex!==void 0?this.setValueHex(b.hex):b.name!==void 0&&this.setValueName(b.name))},pe.lang.extend(O.asn1.DERObjectIdentifier,O.asn1.ASN1Object),O.asn1.DEREnumerated=function(b){O.asn1.DEREnumerated.superclass.constructor.call(this),this.hT="0a",this.setByBigInteger=function(c){this.hTLV=null,this.isModified=!0,this.hV=O.asn1.ASN1Util.bigIntToMinTwosComplementsHex(c)},this.setByInteger=function(c){var u=new T(String(c),10);this.setByBigInteger(u)},this.setValueHex=function(c){this.hV=c},this.getFreshValueHex=function(){return this.hV},b!==void 0&&(b.int!==void 0?this.setByInteger(b.int):typeof b=="number"?this.setByInteger(b):b.hex!==void 0&&this.setValueHex(b.hex))},pe.lang.extend(O.asn1.DEREnumerated,O.asn1.ASN1Object),O.asn1.DERUTF8String=function(b){O.asn1.DERUTF8String.superclass.constructor.call(this,b),this.hT="0c"},pe.lang.extend(O.asn1.DERUTF8String,O.asn1.DERAbstractString),O.asn1.DERNumericString=function(b){O.asn1.DERNumericString.superclass.constructor.call(this,b),this.hT="12"},pe.lang.extend(O.asn1.DERNumericString,O.asn1.DERAbstractString),O.asn1.DERPrintableString=function(b){O.asn1.DERPrintableString.superclass.constructor.call(this,b),this.hT="13"},pe.lang.extend(O.asn1.DERPrintableString,O.asn1.DERAbstractString),O.asn1.DERTeletexString=function(b){O.asn1.DERTeletexString.superclass.constructor.call(this,b),this.hT="14"},pe.lang.extend(O.asn1.DERTeletexString,O.asn1.DERAbstractString),O.asn1.DERIA5String=function(b){O.asn1.DERIA5String.superclass.constructor.call(this,b),this.hT="16"},pe.lang.extend(O.asn1.DERIA5String,O.asn1.DERAbstractString),O.asn1.DERUTCTime=function(b){O.asn1.DERUTCTime.superclass.constructor.call(this,b),this.hT="17",this.setByDate=function(c){this.hTLV=null,this.isModified=!0,this.date=c,this.s=this.formatDate(this.date,"utc"),this.hV=stohex(this.s)},this.getFreshValueHex=function(){return this.date===void 0&&this.s===void 0&&(this.date=new Date,this.s=this.formatDate(this.date,"utc"),this.hV=stohex(this.s)),this.hV},b!==void 0&&(b.str!==void 0?this.setString(b.str):typeof b=="string"&&b.match(/^[0-9]{12}Z$/)?this.setString(b):b.hex!==void 0?this.setStringHex(b.hex):b.date!==void 0&&this.setByDate(b.date))},pe.lang.extend(O.asn1.DERUTCTime,O.asn1.DERAbstractTime),O.asn1.DERGeneralizedTime=function(b){O.asn1.DERGeneralizedTime.superclass.constructor.call(this,b),this.hT="18",this.withMillis=!1,this.setByDate=function(c){this.hTLV=null,this.isModified=!0,this.date=c,this.s=this.formatDate(this.date,"gen",this.withMillis),this.hV=stohex(this.s)},this.getFreshValueHex=function(){return this.date===void 0&&this.s===void 0&&(this.date=new Date,this.s=this.formatDate(this.date,"gen",this.withMillis),this.hV=stohex(this.s)),this.hV},b!==void 0&&(b.str!==void 0?this.setString(b.str):typeof b=="string"&&b.match(/^[0-9]{14}Z$/)?this.setString(b):b.hex!==void 0?this.setStringHex(b.hex):b.date!==void 0&&this.setByDate(b.date),b.millis===!0&&(this.withMillis=!0))},pe.lang.extend(O.asn1.DERGeneralizedTime,O.asn1.DERAbstractTime),O.asn1.DERSequence=function(b){O.asn1.DERSequence.superclass.constructor.call(this,b),this.hT="30",this.getFreshValueHex=function(){for(var c="",u=0;u<this.asn1Array.length;u++)c+=this.asn1Array[u].getEncodedHex();return this.hV=c,this.hV}},pe.lang.extend(O.asn1.DERSequence,O.asn1.DERAbstractStructured),O.asn1.DERSet=function(b){O.asn1.DERSet.superclass.constructor.call(this,b),this.hT="31",this.sortFlag=!0,this.getFreshValueHex=function(){for(var c=new Array,u=0;u<this.asn1Array.length;u++){var g=this.asn1Array[u];c.push(g.getEncodedHex())}return this.sortFlag==1&&c.sort(),this.hV=c.join(""),this.hV},b!==void 0&&b.sortflag!==void 0&&b.sortflag==0&&(this.sortFlag=!1)},pe.lang.extend(O.asn1.DERSet,O.asn1.DERAbstractStructured),O.asn1.DERTaggedObject=function(b){O.asn1.DERTaggedObject.superclass.constructor.call(this),this.hT="a0",this.hV="",this.isExplicit=!0,this.asn1Object=null,this.setASN1Object=function(c,u,g){this.hT=u,this.isExplicit=c,this.asn1Object=g,this.isExplicit?(this.hV=this.asn1Object.getEncodedHex(),this.hTLV=null,this.isModified=!0):(this.hV=null,this.hTLV=g.getEncodedHex(),this.hTLV=this.hTLV.replace(/^../,u),this.isModified=!1)},this.getFreshValueHex=function(){return this.hV},b!==void 0&&(b.tag!==void 0&&(this.hT=b.tag),b.explicit!==void 0&&(this.isExplicit=b.explicit),b.obj!==void 0&&(this.asn1Object=b.obj,this.setASN1Object(this.isExplicit,this.hT,this.asn1Object)))},pe.lang.extend(O.asn1.DERTaggedObject,O.asn1.ASN1Object);var Ye,Ze,Pe=(Ye=function(b,c){return Ye=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,g){u.__proto__=g}||function(u,g){for(var y in g)Object.prototype.hasOwnProperty.call(g,y)&&(u[y]=g[y])},Ye(b,c)},function(b,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");function u(){this.constructor=b}Ye(b,c),b.prototype=c===null?Object.create(c):(u.prototype=c.prototype,new u)}),Xe=function(b){function c(u){var g=b.call(this)||this;return u&&(typeof u=="string"?g.parseKey(u):(c.hasPrivateKeyProperty(u)||c.hasPublicKeyProperty(u))&&g.parsePropertiesFrom(u)),g}return Pe(c,b),c.prototype.parseKey=function(u){try{var g=0,y=0,w=/^\s*(?:[0-9A-Fa-f][0-9A-Fa-f]\s*)+$/.test(u)?function(fe){var ue;if(k===void 0){var be="0123456789ABCDEF",Ae=` \f
8
- \r  \u2028\u2029`;for(k={},ue=0;ue<16;++ue)k[be.charAt(ue)]=ue;for(be=be.toLowerCase(),ue=10;ue<16;++ue)k[be.charAt(ue)]=ue;for(ue=0;ue<Ae.length;++ue)k[Ae.charAt(ue)]=-1}var D=[],Ve=0,De=0;for(ue=0;ue<fe.length;++ue){var oe=fe.charAt(ue);if(oe=="=")break;if((oe=k[oe])!=-1){if(oe===void 0)throw new Error("Illegal character at offset "+ue);Ve|=oe,++De>=2?(D[D.length]=Ve,Ve=0,De=0):Ve<<=4}}if(De)throw new Error("Hex encoding incomplete: 4 bits missing");return D}(u):j.unarmor(u),N=ie.decode(w);if(N.sub.length===3&&(N=N.sub[2].sub[0]),N.sub.length===9){g=N.sub[1].getHexStringValue(),this.n=P(g,16),y=N.sub[2].getHexStringValue(),this.e=parseInt(y,16);var E=N.sub[3].getHexStringValue();this.d=P(E,16);var I=N.sub[4].getHexStringValue();this.p=P(I,16);var M=N.sub[5].getHexStringValue();this.q=P(M,16);var W=N.sub[6].getHexStringValue();this.dmp1=P(W,16);var de=N.sub[7].getHexStringValue();this.dmq1=P(de,16);var te=N.sub[8].getHexStringValue();this.coeff=P(te,16)}else{if(N.sub.length!==2)return!1;if(N.sub[0].sub){var ge=N.sub[1].sub[0];g=ge.sub[0].getHexStringValue(),this.n=P(g,16),y=ge.sub[1].getHexStringValue(),this.e=parseInt(y,16)}else g=N.sub[0].getHexStringValue(),this.n=P(g,16),y=N.sub[1].getHexStringValue(),this.e=parseInt(y,16)}return!0}catch{return!1}},c.prototype.getPrivateBaseKey=function(){var u={array:[new O.asn1.DERInteger({int:0}),new O.asn1.DERInteger({bigint:this.n}),new O.asn1.DERInteger({int:this.e}),new O.asn1.DERInteger({bigint:this.d}),new O.asn1.DERInteger({bigint:this.p}),new O.asn1.DERInteger({bigint:this.q}),new O.asn1.DERInteger({bigint:this.dmp1}),new O.asn1.DERInteger({bigint:this.dmq1}),new O.asn1.DERInteger({bigint:this.coeff})]};return new O.asn1.DERSequence(u).getEncodedHex()},c.prototype.getPrivateBaseKeyB64=function(){return q(this.getPrivateBaseKey())},c.prototype.getPublicBaseKey=function(){var u=new O.asn1.DERSequence({array:[new O.asn1.DERObjectIdentifier({oid:"1.2.840.113549.1.1.1"}),new O.asn1.DERNull]}),g=new O.asn1.DERSequence({array:[new O.asn1.DERInteger({bigint:this.n}),new O.asn1.DERInteger({int:this.e})]}),y=new O.asn1.DERBitString({hex:"00"+g.getEncodedHex()});return new O.asn1.DERSequence({array:[u,y]}).getEncodedHex()},c.prototype.getPublicBaseKeyB64=function(){return q(this.getPublicBaseKey())},c.wordwrap=function(u,g){if(!u)return u;var y="(.{1,"+(g=g||64)+`})( +|$
1
+ (function(he,Me){typeof exports=="object"&&typeof module<"u"?Me(exports,require("element-plus"),require("vue"),require("vuedraggable"),require("dayjs"),require("@logicflow/core"),require("@logicflow/extension")):typeof define=="function"&&define.amd?define(["exports","element-plus","vue","vuedraggable","dayjs","@logicflow/core","@logicflow/extension"],Me):(he=typeof globalThis<"u"?globalThis:he||self,Me(he.LwCdpUi={},he.ElementPlus,he.Vue,he.Vuedraggable,he.dayjs,he.LogicFlowCore,he.LogicFlowExtension))})(this,function(he,Me,e,Gt,$e,lm,zi){"use strict";var Ax=Object.defineProperty;var Rx=(he,Me,e)=>Me in he?Ax(he,Me,{enumerable:!0,configurable:!0,writable:!0,value:e}):he[Me]=e;var Cn=(he,Me,e)=>Rx(he,typeof Me!="symbol"?Me+"":Me,e);const im={mounted(t,n){t.$value=n.value,t.handler=()=>{const o=document.createElement("textarea");o.readOnly="readonly",o.style.position="absolute",o.style.left="-9999px",o.value=t.$value,document.body.appendChild(o),o.select(),o.setSelectionRange(0,o.value.length),document.execCommand("Copy")&&Me.ElMessage.success("复制成功"),document.body.removeChild(o)},t.addEventListener("click",t.handler)},updated(t,n){t.$value=n.value},unmounted(t){t.removeEventListener("click",t.handler)}},sm={mounted(t,n){let o=localStorage.getItem("userAuthInfo");o=JSON.parse(o);const{menus:a,authorities:r}=o,l=n.value;if(!l)return!0;let i=!1;Array.isArray(l)?i=l.some(s=>[...a,...r].includes(s)):typeof l=="string"&&(i=[...a,...r].includes(l)),i||t.parentNode&&t.parentNode.removeChild(t)}},le=(t,n)=>{const o=t.__vccOpts||t;for(const[a,r]of n)o[a]=r;return o},cm={name:"NavMenu",props:["navMenus"],data(){return{}},methods:{hasChildren(t){return t.children&&!t.children.every(n=>n.meta.hidden)}}},dm={key:0,style:{padding:"20px"}},um=["href"];function hm(t,n,o,a,r,l){const i=e.resolveComponent("el-alert"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("el-menu-item"),h=e.resolveComponent("NavMenu",!0),f=e.resolveComponent("el-sub-menu");return e.openBlock(),e.createElementBlock(e.Fragment,null,[o.navMenus.length<=0?(e.openBlock(),e.createElementBlock("div",dm,[e.createVNode(i,{title:"无子集菜单",center:"",type:"info",closable:!1})])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.navMenus,p=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:p},[l.hasChildren(p)?(e.openBlock(),e.createBlock(f,{key:1,index:p.path},{title:e.withCtx(()=>[p.meta&&p.meta.icon?(e.openBlock(),e.createBlock(s,{key:0},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(p.meta.icon||"el-icon-menu")))]),_:2},1024)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(p.meta.title),1)]),default:e.withCtx(()=>[e.createVNode(h,{navMenus:p.children},null,8,["navMenus"])]),_:2},1032,["index"])):(e.openBlock(),e.createBlock(d,{key:0,index:p.path},{title:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(p.meta.title),1)]),default:e.withCtx(()=>[p.meta&&p.meta.type=="link"?(e.openBlock(),e.createElementBlock("a",{key:0,href:p.path,target:"_blank",onClick:e.withModifiers(()=>{},["stop"])},null,8,um)):e.createCommentVNode("",!0),p.meta&&p.meta.icon?(e.openBlock(),e.createBlock(s,{key:1},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(p.meta.icon||"el-icon-menu")))]),_:2},1024)):e.createCommentVNode("",!0)]),_:2},1032,["index"]))],64))),128))],64)}const Hi=le(cm,[["render",hm]]),Yt="/static/images/logo.svg",fm={components:{NavMenu:Hi},data(){return{nav:!1,menu:[]}},computed:{},created(){var t=this.$router.sc_getMenu();this.menu=this.filterUrl(t)},watch:{},methods:{showMobileNav(t){var n=t.currentTarget.getAttribute("drag-flag");if(n=="true")return!1;this.nav=!0},select(){this.$refs.mobileNavBox.handleClose()},filterUrl(t){var n=[];return t&&t.forEach(o=>{if(o.meta=o.meta?o.meta:{},o.meta.hidden||o.meta.type=="button")return!1;o.meta.type=="iframe"&&(o.path=`/i/${o.name}`),o.children&&o.children.length>0&&(o.children=this.filterUrl(o.children)),n.push(o)}),n}},directives:{drag(t){let n=t,o="",a="";n.onmousedown=function(r){let l=r.clientX-n.offsetLeft,i=r.clientY-n.offsetTop;return document.onmousemove=function(s){n.setAttribute("drag-flag",!0),o=new Date().getTime();let d=s.clientX-l,h=s.clientY-i;h>0&&h<document.body.clientHeight-50&&(n.style.top=h+"px"),d>0&&d<document.body.clientWidth-50&&(n.style.left=d+"px")},document.onmouseup=function(){a=new Date().getTime(),a-o>200&&n.setAttribute("drag-flag",!1),document.onmousemove=null,document.onmouseup=null},!1}}}},pm={class:"logo-bar"};function mm(t,n,o,a,r,l){const i=e.resolveComponent("el-icon-menu"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("el-header"),h=e.resolveComponent("NavMenu"),f=e.resolveComponent("el-menu"),p=e.resolveComponent("el-scrollbar"),_=e.resolveComponent("el-main"),C=e.resolveComponent("el-container"),k=e.resolveComponent("el-drawer"),B=e.resolveDirective("drag");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.withDirectives((e.openBlock(),e.createElementBlock("div",{ref:"",class:"mobile-nav-button",onClick:n[0]||(n[0]=N=>l.showMobileNav(N)),draggable:"false"},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i)]),_:1})])),[[B]]),e.createVNode(k,{ref:"mobileNavBox",title:"移动端菜单",size:240,modelValue:r.nav,"onUpdate:modelValue":n[1]||(n[1]=N=>r.nav=N),direction:"ltr","with-header":!1,"destroy-on-close":""},{default:e.withCtx(()=>[e.createVNode(C,{class:"mobile-nav"},{default:e.withCtx(()=>[e.createVNode(d,null,{default:e.withCtx(()=>[e.createElementVNode("div",pm,[n[2]||(n[2]=e.createElementVNode("img",{class:"logo",src:Yt},null,-1)),e.createElementVNode("span",null,e.toDisplayString(t.$config.APP_NAME),1)])]),_:1}),e.createVNode(_,null,{default:e.withCtx(()=>[e.createVNode(p,null,{default:e.withCtx(()=>[e.createVNode(f,{"default-active":t.$route.meta.active||t.$route.fullPath,onSelect:l.select,router:"","background-color":"#212d3d","text-color":"#fff","active-text-color":"#409EFF"},{default:e.withCtx(()=>[e.createVNode(h,{navMenus:r.menu},null,8,["navMenus"])]),_:1},8,["default-active","onSelect"])]),_:1})]),_:1})]),_:1})]),_:1},8,["modelValue"])],64)}const gm=le(fm,[["render",mm],["__scopeId","data-v-dd6bdb07"]]),bm={name:"layoutAside",props:{},data(){return{popVisible:!1,grantedApplications:[]}},mounted(){let{grantedApplications:t}=this.$tool.data.get("userAuthInfo");this.grantedApplications=t,document.addEventListener("click",this.handleDocumentClick)},beforeDestroy(){document.removeEventListener("click",this.handleDocumentClick)},methods:{handleDocumentClick(t){let n=document.getElementById("popover");this.popVisible&&t.target!==n&&!n.contains(t.target)&&(this.popVisible=!1)},openMneu(){window.location.href="/#/passport-application"},switchMenu(t){window.location.href=t.url},closePopover(){this.$refs.popoverRef.hide()}}},ym={class:"layout-aside"},_m={class:"app-content"},km={class:"app-title"},wm=["onClick"];function Vm(t,n,o,a,r,l){const i=e.resolveComponent("el-icon"),s=e.resolveComponent("el-icon-close"),d=e.resolveComponent("el-divider"),h=e.resolveComponent("el-popover");return e.openBlock(),e.createElementBlock("div",ym,[n[1]||(n[1]=e.createElementVNode("img",{class:"logo",src:Yt,alt:""},null,-1)),e.createVNode(h,{placement:"right",width:180,trigger:"click","show-arrow":!1,offset:3,"popper-class":"app-popper",ref:"popoverRef"},{reference:e.withCtx(()=>[e.createElementVNode("p",null,[e.createVNode(i,{class:"menu-btn"},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent("el-icon-grid")))]),_:1})])]),default:e.withCtx(()=>[e.createElementVNode("div",_m,[e.createElementVNode("div",km,[e.createElementVNode("span",{class:"open",onClick:n[0]||(n[0]=(...f)=>l.openMneu&&l.openMneu(...f))},"应用中心"),e.createVNode(i,{class:"iconClose",onClick:l.closePopover},{default:e.withCtx(()=>[e.createVNode(s)]),_:1},8,["onClick"])]),e.createVNode(d,{style:{margin:"5px 0"}}),r.grantedApplications.length>0?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(r.grantedApplications,f=>(e.openBlock(),e.createElementBlock("div",{class:"menu-item",onClick:p=>l.switchMenu(f),key:f.resourceId},[e.createElementVNode("i",{class:e.normalizeClass(["iconfont",f.icon]),style:{"margin-right":"5px"}},null,2),e.createTextVNode(" "+e.toDisplayString(f.name),1)],8,wm))),128)):e.createCommentVNode("",!0)])]),_:1},512)])}const Cm=le(bm,[["render",Vm]]),xm={data(){return{breadList:[]}},created(){this.getBreadcrumb()},watch:{$route(){this.getBreadcrumb()}},methods:{getBreadcrumb(){let t=this.$route.meta.breadcrumb;this.breadList=t}}},Nm={class:"adminui-topbar"},Bm={class:"left-panel"},Sm={style:{"font-size":"12px"}},Em={class:"right-panel"};function Tm(t,n,o,a,r,l){const i=e.resolveComponent("el-icon"),s=e.resolveComponent("el-breadcrumb-item"),d=e.resolveComponent("el-breadcrumb");return e.openBlock(),e.createElementBlock("div",Nm,[e.createElementVNode("div",Bm,[e.createVNode(d,{"separator-icon":"el-icon-arrow-right",class:"hidden-sm-and-down"},{default:e.withCtx(()=>[e.createVNode(e.TransitionGroup,{name:"breadcrumb"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.breadList,h=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:h.title},[h.path!="/"&&!h.meta.hiddenBreadcrumb?(e.openBlock(),e.createBlock(s,{key:h.meta.title},{default:e.withCtx(()=>[h.meta.icon?(e.openBlock(),e.createBlock(i,{key:0,class:"icon"},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(h.meta.icon)))]),_:2},1024)):e.createCommentVNode("",!0),e.createElementVNode("span",Sm,e.toDisplayString(h.meta.title),1)]),_:2},1024)):e.createCommentVNode("",!0)],64))),128))]),_:1})]),_:1})]),n[0]||(n[0]=e.createElementVNode("div",{class:"center-panel"},null,-1)),e.createElementVNode("div",Em,[e.renderSlot(t.$slots,"default",{},void 0,!0)])])}const Im=le(xm,[["render",Tm],["__scopeId","data-v-c198cd76"]]),Dm={name:"tags",components:{draggable:Gt},data(){return{contextMenuVisible:!1,contextMenuItem:null,left:0,top:0,tipVisible:!1,tipDisplayed:!1,menu:this.$router.sc_getMenu()}},props:{tagShowID:{type:Boolean,default:!1}},computed:{tagList(){return this.$store.state.viewTags.viewTags}},watch:{scrollInit(){const t=this.$refs.tags;t&&t.addEventListener("scroll",()=>{t.scrollLeft>0?this.tipDisplayed=!0:this.tipDisplayed=!1})},$route(t){this.addViewTags(t)},contextMenuVisible(t){var n=this,o=function(a){let r=document.getElementById("contextmenu");r&&!r.contains(a.target)&&n.closeMenu()};t?document.body.addEventListener("click",a=>o(a)):document.body.removeEventListener("click",a=>o(a))}},created(){this.init(),this.$store.state.viewTags.closeTagAndJump=this.closeTagAndJump},mounted(){this.scrollInit()},methods:{init(){let t=this.$tool.data.get("RouteTags")||[];t.length>0&&t.forEach((n,o)=>{var a=this.treeFind(this.menu,r=>r.path==n.path);a&&this.addViewTags(n)}),this.addViewTags(this.$route)},treeFind(t,n){for(const o of t){if(n(o))return o;if(o.children){const a=this.treeFind(o.children,n);if(a)return a}}return null},changeTages(t){this.$tool.data.set("RouteTags",this.$store.state.viewTags.viewTags)},addViewTags(t){t.name&&!t.meta.fullpage&&(delete t.redirectedFrom,t={...t,matched:[]},this.$store.commit("pushViewTags",t),this.$store.commit("pushKeepLive",t.name),this.$tool.data.set("RouteTags",this.$store.state.viewTags.viewTags)),this.$nextTick(()=>{const n=document.querySelector(".context-menu-list");n&&n.scrollWidth>n.clientWidth&&(n.querySelector(".active").scrollIntoView(),this.tipDisplayed||(this.tipVisible=!0))})},isActive(t){return t.fullPath===this.$route.fullPath},closeSelectedTag(t,n=!0){let o=this.menu[0];if(o.children&&(o=o.children[0]),this.tagList.length==1&&o.path==this.$route.fullPath)return!1;if(this.$store.commit("removeViewTags",t),this.$store.commit("removeIframeList",t),this.$store.commit("removeKeepLive",t.name),this.$tool.data.set("RouteTags",this.$store.state.viewTags.viewTags),n&&this.isActive(t)){const a=this.tagList.slice(-1)[0];a?this.$router.push(a):this.$router.push("/")}},openContextMenu(t,n){this.contextMenuItem=n,this.contextMenuVisible=!0,this.left=t.clientX+1,this.top=t.clientY+1,this.$nextTick(()=>{let o=document.getElementById("contextmenu");document.body.offsetWidth-t.clientX<o.offsetWidth&&(this.left=document.body.offsetWidth-o.offsetWidth+1,this.top=t.clientY+1)})},closeMenu(){this.contextMenuItem=null,this.contextMenuVisible=!1},refreshTab(){var t=this.contextMenuItem;this.contextMenuVisible=!1,this.$route.fullPath!=t.fullPath&&this.$router.push({path:t.fullPath,query:t.query}),this.$store.commit("refreshIframe",t),this.$store.commit("removeKeepLive",t.name),this.$store.commit("setRouteShow",!0),this.$nextTick(()=>{this.$store.commit("pushKeepLive",t.name),this.$store.commit("setRouteShow",!1)})},closeTabs(){var t=this.contextMenuItem;t.meta.affix||(this.closeSelectedTag(t),this.contextMenuVisible=!1)},closeOtherTabs(){var t=this.contextMenuItem;this.$route.fullPath!=t.fullPath&&this.$router.push({path:t.fullPath,query:t.query});var n=[...this.tagList];n.forEach(o=>{if(o.meta&&o.meta.affix||t.fullPath==o.fullPath)return!0;this.closeSelectedTag(o,!1)}),this.contextMenuVisible=!1},maximize(){var t=this.contextMenuItem;this.contextMenuVisible=!1,this.$route.fullPath!=t.fullPath&&this.$router.push({path:t.fullPath,query:t.query}),document.getElementById("app").classList.add("main-maximize")},openWindow(){var t=this.contextMenuItem,n=t.href||"/";t.meta.affix||this.closeSelectedTag(t),window.open(n),this.contextMenuVisible=!1},scrollInit(){const t=document.querySelector(".context-menu-list");t.addEventListener("mousewheel",n,!1)||t.addEventListener("DOMMouseScroll",n,!1);function n(o){const a=o.wheelDelta||o.detail,r=1,l=-1;let i=0;a==3||a<0&&a!=-3?i=r*50:i=l*50,t.scrollLeft+=i}},hideTip(){this.tipVisible=!1,this.tipDisplayed=!0},closeTagAndJump(t,n){this.$store.commit("removeKeepLive",n),this.closeSelectedTag(this.$route,!1),this.$router.push(t)},getIdName(t){var n;if((n=t.query)!=null&&n.id&&this.tagShowID){let o=t.meta.title;return o.includes(":")||o.includes(":")?t.meta.title:`${t.meta.title}:${t.query.id}`}else return t.meta.title}}},Fm={class:"adminui-tags"},qm=["onContextmenu"];function Am(t,n,o,a,r,l){const i=e.resolveComponent("el-icon-close"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("router-link"),h=e.resolveComponent("draggable"),f=e.resolveComponent("el-icon-refresh"),p=e.resolveComponent("el-icon-folder-delete"),_=e.resolveComponent("el-icon-full-screen"),C=e.resolveComponent("el-icon-copy-document");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",Fm,[e.createVNode(h,{modelValue:t.$store.state.viewTags.viewTags,"onUpdate:modelValue":n[0]||(n[0]=k=>t.$store.state.viewTags.viewTags=k),onChange:l.changeTages,class:"context-menu-list",ref:"tags",itemKey:"name"},{item:e.withCtx(({element:k,index:B})=>[(e.openBlock(),e.createElementBlock("li",{key:k,class:e.normalizeClass([l.isActive(k)?"active":"",k.meta.affix?"affix":""]),onContextmenu:e.withModifiers(N=>l.openContextMenu(N,k),["prevent"])},[e.createVNode(d,{to:k},{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(l.getIdName(k)),1),k.meta.affix?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(s,{key:0,onClick:e.withModifiers(N=>l.closeSelectedTag(k),["prevent","stop"])},{default:e.withCtx(()=>[e.createVNode(i)]),_:2},1032,["onClick"]))]),_:2},1032,["to"])],42,qm))]),_:1},8,["modelValue","onChange"])]),e.createVNode(e.Transition,{name:"el-zoom-in-top"},{default:e.withCtx(()=>[r.contextMenuVisible?(e.openBlock(),e.createElementBlock("ul",{key:0,style:e.normalizeStyle({left:r.left+"px",top:r.top+"px"}),class:"contextmenu",id:"contextmenu"},[e.createElementVNode("li",{onClick:n[1]||(n[1]=k=>l.refreshTab())},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(f)]),_:1}),n[6]||(n[6]=e.createTextVNode("刷新"))]),n[11]||(n[11]=e.createElementVNode("hr",null,null,-1)),e.createElementVNode("li",{onClick:n[2]||(n[2]=k=>l.closeTabs()),class:e.normalizeClass(r.contextMenuItem.meta.affix?"disabled":"")},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i)]),_:1}),n[7]||(n[7]=e.createTextVNode("关闭标签 "))],2),e.createElementVNode("li",{onClick:n[3]||(n[3]=k=>l.closeOtherTabs())},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(p)]),_:1}),n[8]||(n[8]=e.createTextVNode("关闭其他标签 "))]),n[12]||(n[12]=e.createElementVNode("hr",null,null,-1)),e.createElementVNode("li",{onClick:n[4]||(n[4]=k=>l.maximize())},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(_)]),_:1}),n[9]||(n[9]=e.createTextVNode("最大化"))]),e.createElementVNode("li",{onClick:n[5]||(n[5]=k=>l.openWindow())},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(C)]),_:1}),n[10]||(n[10]=e.createTextVNode("在新的窗口中打开 "))])],4)):e.createCommentVNode("",!0)]),_:1})],64)}const Rm=le(Dm,[["render",Am]]),Om={data(){return{buName:"",buList:[]}},props:{isInitialized:{type:Boolean,default:!0}},methods:{async changeBusinessUnit(t){let n=this.buList.find(o=>o.code===t);if(this.buName=n.name,this.$store.commit("setRouteShow",!0),this.$tool.data.set("buCode",t),this.$tool.data.set("tenantId",n.tenantId),this.$bus.$emit("changeBu",{buCode:t,tenantId:n.tenantId}),this.isInitialized){let o=await this.$api.auth.initialized();this.$tool.data.set("zoneInitialized",o),o||this.$router.push(this.$config.INIT_URL)}this.$store.commit("clearKeepLive"),this.$store.commit("setRouteShow",!1)}},async created(){this.buList=this.$tool.data.get("buList")||[];let t=this.$tool.data.get("buCode");if(!this.buList.length){let a=await this.$api.auth.bu()||[];this.$tool.data.set("buList",a),this.buList=a,this.$tool.data.set("buCode",a[0].code),t=a[0].code}let n=this.buList.find(o=>o.code===t);this.buName=n?n.name:"",this.changeBusinessUnit(t)}},vm={class:"bu-list"};function Pm(t,n,o,a,r,l){const i=e.resolveComponent("el-icon-help"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("el-dropdown-item"),h=e.resolveComponent("el-dropdown-menu"),f=e.resolveComponent("el-dropdown");return e.openBlock(),e.createElementBlock("div",{class:"screen panel-item hidden-sm-and-down",onClick:n[0]||(n[0]=(...p)=>t.screen&&t.screen(...p))},[e.createVNode(f,{onCommand:l.changeBusinessUnit},{dropdown:e.withCtx(()=>[e.createVNode(h,null,{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.buList,p=>(e.openBlock(),e.createBlock(d,{key:p.id,command:p.code},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(p.name),1)]),_:2},1032,["command"]))),128))]),_:1})]),default:e.withCtx(()=>[e.createElementVNode("div",vm,[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i)]),_:1}),e.createTextVNode(e.toDisplayString(r.buName),1)])]),_:1},8,["onCommand"])])}const Lm={props:{isShowBu:{type:Boolean,default:!0},isInitialized:{type:Boolean,default:!0}},components:{bu:le(Om,[["render",Pm],["__scopeId","data-v-e0d2e0bb"]])},data(){return{userName:"",userNameF:"",searchVisible:!1,tasksVisible:!1,msg:!1}},created(){this.$store.state.user=this.$tool.data.get("userAuthInfo")},methods:{handleUser(t){t=="uc"&&this.$router.push({path:"/user"}),t=="cmd"&&this.$router.push({path:"/cmd"}),t=="clearCache"&&this.$confirm("清除缓存会将系统初始化,包括登录状态、主题、语言设置等,是否继续?","提示",{type:"info"}).then(()=>{this.$tool.data.clear(),window.location.href="/#/passport-login"}).catch(()=>{}),t=="outLogin"&&this.$confirm("确认是否退出当前用户?","提示",{type:"warning",confirmButtonText:"退出",confirmButtonClass:"el-button--danger"}).then(()=>{this.$store.commit("clearViewTags"),this.$store.commit("clearKeepLive"),this.$store.commit("clearIframeList"),window.location.href="/#/passport-login"}).catch(()=>{})},screen(){var t=document.documentElement;this.$tool.screen(t)},showMsg(){this.msg=!0},search(){this.searchVisible=!0},tasks(){this.tasksVisible=!0}}},Mm={class:"user-bar"},Um={class:"user-avatar"},jm={class:"user-body"},zm={class:"user-name"};function Hm(t,n,o,a,r,l){const i=e.resolveComponent("bu"),s=e.resolveComponent("el-avatar"),d=e.resolveComponent("el-dropdown-item"),h=e.resolveComponent("el-dropdown-menu"),f=e.resolveComponent("el-dropdown");return e.openBlock(),e.createElementBlock("div",Mm,[e.renderSlot(t.$slots,"userbarActionBox",{},void 0,!0),o.isShowBu?(e.openBlock(),e.createBlock(i,{key:0,isInitialized:o.isInitialized},null,8,["isInitialized"])):e.createCommentVNode("",!0),e.createVNode(f,{class:"user panel-item",trigger:"click",onCommand:l.handleUser},{dropdown:e.withCtx(()=>[e.createVNode(h,null,{default:e.withCtx(()=>[e.createVNode(d,{command:"uc"},{default:e.withCtx(()=>[e.createElementVNode("div",jm,[e.createVNode(s,{size:30,src:t.$store.state.user.img||"/static/images/empty.jpg"},null,8,["src"]),e.createElementVNode("div",zm,[e.createElementVNode("label",null,e.toDisplayString(t.$store.state.user.realName),1),e.createElementVNode("label",null,e.toDisplayString(t.$store.state.user.username),1)])])]),_:1}),e.createVNode(d,{command:"clearCache"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("layout.clearCache")),1)]),_:1}),e.createVNode(d,{divided:"",command:"outLogin"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("layout.outLogin")),1)]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createElementVNode("div",Um,[e.createVNode(s,{size:30,src:t.$store.state.user.img||"/static/images/empty.jpg"},null,8,["src"])])]),_:1},8,["onCommand"])])}const Km=le(Lm,[["render",Hm],["__scopeId","data-v-4e135de2"]]),Ki={HexToRgb(t){t=t.replace("#","");let n=t.match(/../g);for(let o=0;o<3;o++)n[o]=parseInt(n[o],16);return n},RgbToHex(t,n,o){let a=[t.toString(16),n.toString(16),o.toString(16)];for(let r=0;r<3;r++)a[r].length===1&&(a[r]="0"+a[r]);return"#"+a.join("")},darken(t,n){let o=this.HexToRgb(t);for(let a=0;a<3;a++)o[a]=Math.floor(o[a]*(1-n));return this.RgbToHex(o[0],o[1],o[2])},lighten(t,n){let o=this.HexToRgb(t);for(let a=0;a<3;a++)o[a]=Math.floor((255-o[a])*n+o[a]);return this.RgbToHex(o[0],o[1],o[2])}},Gm={data(){return{config:{lang:this.$tool.data.get("APP_LANG")||this.$config.LANG},lang:[{name:"简体中文",value:"zh-cn"},{name:"English",value:"en-us"}]}},watch:{"config.lang"(t){this.$i18n.locale=t,this.$i18n.fallbackLocale=t,this.$tool.data.remove("RouteTags"),this.$tool.data.set("APP_LANG",t),location.reload()}},methods:{configLang(t){this.config.lang=t.value}},computed:{curLang(){return this.lang.find(n=>n.value===this.config.lang).name}}};function Ym(t,n,o,a,r,l){const i=e.resolveComponent("el-button"),s=e.resolveComponent("el-dropdown-item"),d=e.resolveComponent("el-dropdown-menu"),h=e.resolveComponent("el-dropdown");return e.openBlock(),e.createBlock(h,{trigger:"click",placement:"bottom-end",onCommand:l.configLang},{dropdown:e.withCtx(()=>[e.createVNode(d,null,{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.lang,f=>(e.openBlock(),e.createBlock(s,{key:f.value,command:f,class:e.normalizeClass({selected:r.config.lang==f.value})},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(f.name),1)]),_:2},1032,["command","class"]))),128))]),_:1})]),default:e.withCtx(()=>[e.createVNode(i,{link:""},{icon:e.withCtx(()=>n[0]||(n[0]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",role:"img",width:"1em",height:"1em",preserveAspectRatio:"xMidYMid meet",viewBox:"0 0 512 512"},[e.createElementVNode("path",{d:"M478.33 433.6l-90-218a22 22 0 0 0-40.67 0l-90 218a22 22 0 1 0 40.67 16.79L316.66 406h102.67l18.33 44.39A22 22 0 0 0 458 464a22 22 0 0 0 20.32-30.4zM334.83 362L368 281.65L401.17 362z",fill:"currentColor"}),e.createElementVNode("path",{d:"M267.84 342.92a22 22 0 0 0-4.89-30.7c-.2-.15-15-11.13-36.49-34.73c39.65-53.68 62.11-114.75 71.27-143.49H330a22 22 0 0 0 0-44H214V70a22 22 0 0 0-44 0v20H54a22 22 0 0 0 0 44h197.25c-9.52 26.95-27.05 69.5-53.79 108.36c-31.41-41.68-43.08-68.65-43.17-68.87a22 22 0 0 0-40.58 17c.58 1.38 14.55 34.23 52.86 83.93c.92 1.19 1.83 2.35 2.74 3.51c-39.24 44.35-77.74 71.86-93.85 80.74a22 22 0 1 0 21.07 38.63c2.16-1.18 48.6-26.89 101.63-85.59c22.52 24.08 38 35.44 38.93 36.1a22 22 0 0 0 30.75-4.9z",fill:"currentColor"})],-1)])),default:e.withCtx(()=>[e.createTextVNode(" "+e.toDisplayString(l.curLang),1)]),_:1})]),_:1},8,["onCommand"])}const Gi=le(Gm,[["render",Ym]]),$m={components:{Lang:Gi},data(){return{layout:this.$store.state.global.layout,menuIsCollapse:this.$store.state.global.menuIsCollapse,layoutTags:this.$store.state.global.layoutTags,dark:this.$tool.data.get("APP_THEME"),colorList:["#409EFF","#009688","#536dfe","#ff5c93","#c62f2f","#fd726d"],colorPrimary:this.$tool.data.get("APP_COLOR")||this.$config.COLOR||"#409EFF"}},watch:{layout(t){this.$store.commit("SET_layout",t)},menuIsCollapse(t){this.$store.commit("TOGGLE_menuIsCollapse"),t?this.$tool.data.set("APP_menuIsCollapse","true"):this.$tool.data.remove("APP_menuIsCollapse")},layoutTags(t){this.$store.commit("TOGGLE_layoutTags"),t?this.$tool.data.remove("APP_LAYOUTTAGS"):this.$tool.data.set("APP_LAYOUTTAGS","hide")},dark(t){document.body.setAttribute("data-theme",t),this.$tool.data.set("APP_THEME",t)},colorPrimary(t){document.documentElement.style.setProperty("--el-color-primary",t);for(let n=1;n<=9;n++)document.documentElement.style.setProperty(`--el-color-primary-light-${n}`,Ki.lighten(t,n/10));for(let n=1;n<=9;n++)document.documentElement.style.setProperty(`--el-color-primary-dark-${n}`,Ki.darken(t,n/10));this.$tool.data.set("APP_COLOR",t)}}};function Wm(t,n,o,a,r,l){const i=e.resolveComponent("el-divider"),s=e.resolveComponent("el-switch"),d=e.resolveComponent("el-form-item"),h=e.resolveComponent("el-color-picker"),f=e.resolveComponent("el-option"),p=e.resolveComponent("el-select"),_=e.resolveComponent("Lang"),C=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(C,{ref:"form","label-width":"120px","label-position":"left",style:{padding:"0 20px"}},{default:e.withCtx(()=>[e.createVNode(i),e.createVNode(d,{label:t.$t("user.nightmode")},{default:e.withCtx(()=>[e.createVNode(s,{modelValue:r.dark,"onUpdate:modelValue":n[0]||(n[0]=k=>r.dark=k),"active-value":"dark","inactive-value":"default"},null,8,["modelValue"])]),_:1},8,["label"]),e.createVNode(i),e.createVNode(d,{label:t.$t("user.color")},{default:e.withCtx(()=>[e.createVNode(h,{modelValue:r.colorPrimary,"onUpdate:modelValue":n[1]||(n[1]=k=>r.colorPrimary=k),predefine:r.colorList},{default:e.withCtx(()=>n[5]||(n[5]=[e.createTextVNode(">")])),_:1},8,["modelValue","predefine"])]),_:1},8,["label"]),e.createVNode(i),e.createVNode(d,{label:t.$t("user.layout")},{default:e.withCtx(()=>[e.createVNode(p,{modelValue:r.layout,"onUpdate:modelValue":n[2]||(n[2]=k=>r.layout=k),placeholder:"请选择"},{default:e.withCtx(()=>[e.createVNode(f,{label:"默认",value:"default"}),e.createVNode(f,{label:"通栏",value:"header"}),e.createVNode(f,{label:"经典",value:"menu"}),e.createVNode(f,{label:"功能坞",value:"dock"})]),_:1},8,["modelValue"])]),_:1},8,["label"]),e.createVNode(d,{label:t.$t("user.menu")},{default:e.withCtx(()=>[e.createVNode(s,{modelValue:r.menuIsCollapse,"onUpdate:modelValue":n[3]||(n[3]=k=>r.menuIsCollapse=k)},null,8,["modelValue"])]),_:1},8,["label"]),e.createVNode(d,{label:t.$t("user.tag")},{default:e.withCtx(()=>[e.createVNode(s,{modelValue:r.layoutTags,"onUpdate:modelValue":n[4]||(n[4]=k=>r.layoutTags=k)},null,8,["modelValue"])]),_:1},8,["label"]),e.createVNode(i),e.createVNode(d,{label:t.$t("user.lang")},{default:e.withCtx(()=>[e.createVNode(_)]),_:1},8,["label"])]),_:1},512)}const Jm=le($m,[["render",Wm]]),Zm={data(){return{}},watch:{$route(t){this.push(t)}},created(){this.push(this.$route)},computed:{iframeList(){return this.$store.state.iframe.iframeList},ismobile(){return this.$store.state.global.ismobile},layoutTags(){return this.$store.state.global.layoutTags}},mounted(){},methods:{push(t){t.meta.type=="iframe"?this.ismobile||!this.layoutTags?this.$store.commit("setIframeList",t):this.$store.commit("pushIframeList",t):(this.ismobile||!this.layoutTags)&&this.$store.commit("clearIframeList")}}},Xm={class:"iframe-pages"},Qm=["src"];function eg(t,n,o,a,r,l){return e.withDirectives((e.openBlock(),e.createElementBlock("div",Xm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.iframeList,i=>e.withDirectives((e.openBlock(),e.createElementBlock("iframe",{key:i.meta.url,src:i.meta.url,frameborder:"0"},null,8,Qm)),[[e.vShow,t.$route.meta.url==i.meta.url]])),128))],512)),[[e.vShow,t.$route.meta.type=="iframe"]])}const tg={name:"lwLayout",props:{isShowBu:{type:Boolean,default:!0},isInitialized:{type:Boolean,default:!0},tagShowID:{type:Boolean,default:!1}},components:{Aside:Cm,SideM:gm,Topbar:Im,Tags:Rm,NavMenu:Hi,userbar:Km,setting:Jm,iframeView:le(Zm,[["render",eg],["__scopeId","data-v-91dc7bba"]])},data(){return{settingDialog:!1,changeMenu:!1,menu:[],nextMenu:[],pmenu:{},active:""}},computed:{ismobile(){return this.$store.state.global.ismobile},layout(){return this.$store.state.global.layout},layoutTags(){return this.$store.state.global.layoutTags},menuIsCollapse(){return this.$store.state.global.menuIsCollapse}},beforeCreate(){this.$bus.$on("setMenu",o=>{this.changeMenu=!0,this.menu=this.filterUrl(o)}),this.$tool.data.get("APP_LAYOUTTAGS")&&(this.$store.state.global.layoutTags=!1);let n=this.$tool.data.get("APP_menuIsCollapse");this.$store.state.global.menuIsCollapse=!!n},async created(){if(this.$tool.data.get("MENUCOMBINED")&&this.$tool.data.set("MENUCOMBINEDNMAE",this.$config.APP_NAME),this.onLayoutResize(),window.addEventListener("resize",this.onLayoutResize),this.getUserInfo(),!this.changeMenu){var n=this.$router.sc_getMenu();this.menu=this.filterUrl(n)}this.showThis(),this.$store.commit("LOAD_USER_FROM_LOCAL_STORAGE")},watch:{async $route(){this.showThis()},"$i18n.locale"(){var t=this.$router.sc_getMenu();this.menu=this.filterUrl(t)},layout:{handler(t){document.body.setAttribute("data-layout",t)},immediate:!0}},methods:{async getUserInfo(){let t=await this.$api.auth.bu();this.$tool.data.set("buList",t);let n=await this.$api.auth.user();this.$tool.data.set("tenantId",n.userAuthInfo.tenantId),this.$tool.data.set("userAuthInfo",n.userAuthInfo),this.$tool.data.set("MenuPath",n.userAuthInfo.grantedApplications),this.$store.state.user=n.userAuthInfo},openSetting(){this.settingDialog=!0},onLayoutResize(){this.$store.commit("SET_ismobile",document.body.clientWidth<992)},showThis(){this.pmenu=this.$route.meta.breadcrumb?this.$route.meta.breadcrumb[0]:{},this.nextMenu=this.filterUrl(this.pmenu.children),this.$nextTick(()=>{this.active=this.$route.meta.active||this.$route.fullPath})},showMenu(t){this.pmenu=t,this.nextMenu=this.filterUrl(t.children),(!t.children||t.children.length==0)&&t.component&&this.$router.push({path:t.path})},filterUrl(t){var n=[];return t&&t.forEach(o=>{if(o.meta=o.meta?o.meta:{},o.meta.hidden||o.meta.type=="button")return!1;o.meta.type=="iframe"&&(o.path=`/i/${o.name}`),o.children&&o.children.length>0&&(o.children=this.filterUrl(o.children)),n.push(o)}),this.changeMenu=!1,n},exitMaximize(){document.getElementById("app").classList.remove("main-maximize")}}},ng={class:"adminui-header"},og={class:"adminui-header-left"},rg={class:"logo-bar"},ag={key:0,class:"nav"},lg=["onClick"],ig={class:"adminui-header-right"},sg={class:"aminui-wrapper"},cg={key:0,class:"adminui-side-top"},dg={class:"adminui-side-scroll"},ug={class:"aminui-body el-container"},hg={class:"adminui-main",id:"adminui-main"},fg={key:1,class:"aminui-body-menu"},pg={class:"aminui-side-split-left"},mg={class:"aminui-wrapper"},gg={class:"aminui-title-name"},bg={class:"adminui-side-scroll"},yg={class:"aminui-body el-container"},_g={class:"aminui-body-menu-top"},kg={class:"top-bar-title"},wg={class:"title"},Vg={class:"adminui-main",id:"adminui-main"},Cg={class:"adminui-header"},xg={class:"adminui-header-left"},Ng={class:"logo-bar"},Bg={class:"adminui-header-right"},Sg={key:0,class:"adminui-header-menu"},Eg={class:"aminui-wrapper"},Tg={class:"aminui-body el-container"},Ig={class:"adminui-main",id:"adminui-main"},Dg={key:3,class:"aminui-wrapper"},Fg={key:0,class:"aminui-side-split"},qg={class:"aminui-side-split-top"},Ag={class:"adminui-side-split-scroll"},Rg=["onClick"],Og={key:0,class:"adminui-side-top"},vg={class:"adminui-side-scroll"},Pg={class:"aminui-body el-container"},Lg={class:"adminui-main",id:"adminui-main"};function Mg(t,n,o,a,r,l){const i=e.resolveComponent("el-icon"),s=e.resolveComponent("userbar"),d=e.resolveComponent("NavMenu"),h=e.resolveComponent("el-menu"),f=e.resolveComponent("el-scrollbar"),p=e.resolveComponent("el-icon-expand"),_=e.resolveComponent("el-icon-fold"),C=e.resolveComponent("Side-m"),k=e.resolveComponent("Topbar"),B=e.resolveComponent("Tags"),N=e.resolveComponent("router-view"),q=e.resolveComponent("iframe-view"),F=e.resolveComponent("Aside"),V=e.resolveComponent("el-icon-close"),j=e.resolveComponent("el-icon-brush-filled"),U=e.resolveComponent("setting"),L=e.resolveComponent("el-drawer");return e.openBlock(),e.createElementBlock(e.Fragment,null,[l.layout=="header"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("header",ng,[e.createElementVNode("div",og,[e.createElementVNode("div",rg,[n[6]||(n[6]=e.createElementVNode("img",{class:"logo",src:Yt},null,-1)),e.createElementVNode("span",null,e.toDisplayString(t.$config.APP_NAME),1)]),l.ismobile?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("ul",ag,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.menu,R=>(e.openBlock(),e.createElementBlock("li",{key:R,class:e.normalizeClass(r.pmenu.path==R.path?"active":""),onClick:H=>l.showMenu(R)},[e.createVNode(i,null,{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(R.meta.icon||"el-icon-menu")))]),_:2},1024),e.createElementVNode("span",null,e.toDisplayString(R.meta.title),1)],10,lg))),128))]))]),e.createElementVNode("div",ig,[e.createVNode(s,{isShowBu:o.isShowBu,isInitialized:o.isInitialized},{userbarActionBox:e.withCtx(()=>[e.renderSlot(t.$slots,"userbarActionBox")]),_:3},8,["isShowBu","isInitialized"])])]),e.createElementVNode("section",sg,[!l.ismobile&&r.nextMenu.length>0||!r.pmenu.component?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(l.menuIsCollapse?"aminui-side isCollapse":"aminui-side")},[l.menuIsCollapse?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",cg,[e.createElementVNode("h2",null,e.toDisplayString(r.pmenu.meta.title),1)])),e.createElementVNode("div",dg,[e.createVNode(f,null,{default:e.withCtx(()=>[e.createVNode(h,{"default-active":r.active,router:"",collapse:l.menuIsCollapse,"unique-opened":t.$config.MENU_UNIQUE_OPENED},{default:e.withCtx(()=>[e.createVNode(d,{navMenus:r.nextMenu},null,8,["navMenus"])]),_:1},8,["default-active","collapse","unique-opened"])]),_:1})]),e.createElementVNode("div",{class:"adminui-side-bottom",onClick:n[0]||(n[0]=R=>t.$store.commit("TOGGLE_menuIsCollapse"))},[e.createVNode(i,null,{default:e.withCtx(()=>[l.menuIsCollapse?(e.openBlock(),e.createBlock(p,{key:0})):(e.openBlock(),e.createBlock(_,{key:1}))]),_:1})])],2)):e.createCommentVNode("",!0),l.ismobile?(e.openBlock(),e.createBlock(C,{key:1})):e.createCommentVNode("",!0),e.createElementVNode("div",ug,[l.ismobile?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(k,{key:0})),!l.ismobile&&l.layoutTags?(e.openBlock(),e.createBlock(B,{key:1,tagShowID:o.tagShowID},null,8,["tagShowID"])):e.createCommentVNode("",!0),e.createElementVNode("div",hg,[e.renderSlot(t.$slots,"routerView",{},()=>[e.createVNode(N,null,{default:e.withCtx(({Component:R})=>[(e.openBlock(),e.createBlock(e.KeepAlive,{include:this.$store.state.keepAlive.keepLiveRoute},[t.$store.state.keepAlive.routeShow?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(R),{key:t.$route.fullPath})):e.createCommentVNode("",!0)],1032,["include"]))]),_:1})]),e.createVNode(q)])])])],64)):l.layout=="menu"?(e.openBlock(),e.createElementBlock("section",fg,[e.createElementVNode("div",pg,[e.createVNode(F)]),e.createElementVNode("section",mg,[l.ismobile?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(l.menuIsCollapse?"aminui-side isCollapse":"aminui-side")},[e.createElementVNode("div",gg,e.toDisplayString(l.menuIsCollapse?t.$config.APP_NAME.charAt(0):t.$config.APP_NAME),1),e.createElementVNode("div",bg,[e.createVNode(f,null,{default:e.withCtx(()=>[e.createVNode(h,{"default-active":r.active,router:"",collapse:l.menuIsCollapse,"unique-opened":t.$config.MENU_UNIQUE_OPENED},{default:e.withCtx(()=>[e.createVNode(d,{navMenus:r.menu},null,8,["navMenus"])]),_:1},8,["default-active","collapse","unique-opened"])]),_:1})]),e.createElementVNode("div",{class:"adminui-side-bottom",onClick:n[1]||(n[1]=R=>t.$store.commit("TOGGLE_menuIsCollapse"))},[e.createVNode(i,null,{default:e.withCtx(()=>[l.menuIsCollapse?(e.openBlock(),e.createBlock(p,{key:0})):(e.openBlock(),e.createBlock(_,{key:1}))]),_:1})])],2)),l.ismobile?(e.openBlock(),e.createBlock(C,{key:1})):e.createCommentVNode("",!0),e.createElementVNode("div",yg,[e.createElementVNode("div",_g,[e.createElementVNode("div",kg,[e.createElementVNode("span",wg,e.toDisplayString(t.$t("layout.topbar"))+":",1),l.ismobile?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(k,{key:0}))]),e.createVNode(s,{isShowBu:o.isShowBu,isInitialized:o.isInitialized},{userbarActionBox:e.withCtx(()=>[e.renderSlot(t.$slots,"userbarActionBox")]),_:3},8,["isShowBu","isInitialized"])]),!l.ismobile&&l.layoutTags?(e.openBlock(),e.createBlock(B,{key:0,tagShowID:o.tagShowID},null,8,["tagShowID"])):e.createCommentVNode("",!0),e.createElementVNode("div",Vg,[e.renderSlot(t.$slots,"routerView",{},()=>[e.createVNode(N,null,{default:e.withCtx(({Component:R})=>[(e.openBlock(),e.createBlock(e.KeepAlive,{include:this.$store.state.keepAlive.keepLiveRoute},[t.$store.state.keepAlive.routeShow?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(R),{key:t.$route.fullPath})):e.createCommentVNode("",!0)],1032,["include"]))]),_:1})]),e.createVNode(q)])])])])):l.layout=="dock"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createElementVNode("header",Cg,[e.createElementVNode("div",xg,[e.createElementVNode("div",Ng,[n[7]||(n[7]=e.createElementVNode("img",{class:"logo",src:Yt},null,-1)),e.createElementVNode("span",null,e.toDisplayString(t.$config.APP_NAME),1)])]),e.createElementVNode("div",Bg,[l.ismobile?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",Sg,[e.createVNode(h,{mode:"horizontal","default-active":r.active,router:"","background-color":"#222b45","text-color":"#fff","active-text-color":"var(--el-color-primary)"},{default:e.withCtx(()=>[e.createVNode(d,{navMenus:r.menu},null,8,["navMenus"])]),_:1},8,["default-active"])])),l.ismobile?(e.openBlock(),e.createBlock(C,{key:1})):e.createCommentVNode("",!0),e.createVNode(s,{isShowBu:o.isShowBu,isInitialized:o.isInitialized},{userbarActionBox:e.withCtx(()=>[e.renderSlot(t.$slots,"userbarActionBox")]),_:3},8,["isShowBu","isInitialized"])])]),e.createElementVNode("section",Eg,[e.createElementVNode("div",Tg,[!l.ismobile&&l.layoutTags?(e.openBlock(),e.createBlock(B,{key:0,tagShowID:o.tagShowID},null,8,["tagShowID"])):e.createCommentVNode("",!0),e.createElementVNode("div",Ig,[e.renderSlot(t.$slots,"routerView",{},()=>[e.createVNode(N,null,{default:e.withCtx(({Component:R})=>[(e.openBlock(),e.createBlock(e.KeepAlive,{include:this.$store.state.keepAlive.keepLiveRoute},[t.$store.state.keepAlive.routeShow?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(R),{key:t.$route.fullPath})):e.createCommentVNode("",!0)],1032,["include"]))]),_:1})]),e.createVNode(q)])])])],64)):(e.openBlock(),e.createElementBlock("section",Dg,[l.ismobile?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",Fg,[e.createElementVNode("div",qg,[e.createVNode(F)]),e.createElementVNode("div",Ag,[e.createVNode(f,null,{default:e.withCtx(()=>[e.createElementVNode("ul",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.menu,R=>(e.openBlock(),e.createElementBlock("li",{key:R,class:e.normalizeClass(r.pmenu.path==R.path?"active":""),onClick:H=>l.showMenu(R)},[e.createVNode(i,null,{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(R.meta.icon||t.el-t.icon-r.menu)))]),_:2},1024),e.createElementVNode("p",null,e.toDisplayString(R.meta.title),1)],10,Rg))),128))])]),_:1})])])),!l.ismobile&&r.nextMenu.length>0||!r.pmenu.component?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(l.menuIsCollapse?"aminui-side isCollapse":"aminui-side")},[l.menuIsCollapse?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",Og,[e.createElementVNode("h2",null,e.toDisplayString(r.pmenu.meta.title),1)])),e.createElementVNode("div",vg,[e.createVNode(f,null,{default:e.withCtx(()=>[e.createVNode(h,{"default-active":r.active,router:"",collapse:l.menuIsCollapse,"unique-opened":t.$config.MENU_UNIQUE_OPENED},{default:e.withCtx(()=>[e.createVNode(d,{navMenus:r.nextMenu},null,8,["navMenus"])]),_:1},8,["default-active","collapse","unique-opened"])]),_:1})]),e.createElementVNode("div",{class:"adminui-side-bottom",onClick:n[2]||(n[2]=R=>t.$store.commit("TOGGLE_menuIsCollapse"))},[e.createVNode(i,null,{default:e.withCtx(()=>[l.menuIsCollapse?(e.openBlock(),e.createBlock(p,{key:0})):(e.openBlock(),e.createBlock(_,{key:1}))]),_:1})])],2)):e.createCommentVNode("",!0),l.ismobile?(e.openBlock(),e.createBlock(C,{key:2})):e.createCommentVNode("",!0),e.createElementVNode("div",Pg,[e.createVNode(k,null,{default:e.withCtx(()=>[e.createVNode(s,{isShowBu:o.isShowBu,isInitialized:o.isInitialized},{userbarActionBox:e.withCtx(()=>[e.renderSlot(t.$slots,"userbarActionBox")]),_:3},8,["isShowBu","isInitialized"])]),_:3}),!l.ismobile&&l.layoutTags?(e.openBlock(),e.createBlock(B,{key:0,tagShowID:o.tagShowID},null,8,["tagShowID"])):e.createCommentVNode("",!0),e.createElementVNode("div",Lg,[e.renderSlot(t.$slots,"routerView",{},()=>[e.createVNode(N,null,{default:e.withCtx(({Component:R})=>[(e.openBlock(),e.createBlock(e.KeepAlive,{include:this.$store.state.keepAlive.keepLiveRoute},[t.$store.state.keepAlive.routeShow?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(R),{key:t.$route.fullPath})):e.createCommentVNode("",!0)],1032,["include"]))]),_:1})]),e.createVNode(q)])])])),e.createElementVNode("div",{class:"main-maximize-exit",onClick:n[3]||(n[3]=(...R)=>l.exitMaximize&&l.exitMaximize(...R))},[e.createVNode(i,null,{default:e.withCtx(()=>[e.createVNode(V)]),_:1})]),e.createElementVNode("div",{class:"layout-setting",onClick:n[4]||(n[4]=(...R)=>l.openSetting&&l.openSetting(...R))},[e.createVNode(i,null,{default:e.withCtx(()=>[e.createVNode(j)]),_:1})]),e.createVNode(L,{title:"布局实时演示",modelValue:r.settingDialog,"onUpdate:modelValue":n[5]||(n[5]=R=>r.settingDialog=R),size:400,"append-to-body":"","destroy-on-close":""},{default:e.withCtx(()=>[e.createVNode(U)]),_:1},8,["modelValue"])],64)}const Yi=le(tg,[["render",Mg]]);var $t=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function $i(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Wi={exports:{}};/*! For license information please see jsencrypt.min.js.LICENSE.txt */(function(t,n){(function(o,a){t.exports=a()})(window,()=>(()=>{var o={155:i=>{var s,d,h=i.exports={};function f(){throw new Error("setTimeout has not been defined")}function p(){throw new Error("clearTimeout has not been defined")}function _(U){if(s===setTimeout)return setTimeout(U,0);if((s===f||!s)&&setTimeout)return s=setTimeout,setTimeout(U,0);try{return s(U,0)}catch{try{return s.call(null,U,0)}catch{return s.call(this,U,0)}}}(function(){try{s=typeof setTimeout=="function"?setTimeout:f}catch{s=f}try{d=typeof clearTimeout=="function"?clearTimeout:p}catch{d=p}})();var C,k=[],B=!1,N=-1;function q(){B&&C&&(B=!1,C.length?k=C.concat(k):N=-1,k.length&&F())}function F(){if(!B){var U=_(q);B=!0;for(var L=k.length;L;){for(C=k,k=[];++N<L;)C&&C[N].run();N=-1,L=k.length}C=null,B=!1,function(R){if(d===clearTimeout)return clearTimeout(R);if((d===p||!d)&&clearTimeout)return d=clearTimeout,clearTimeout(R);try{return d(R)}catch{try{return d.call(null,R)}catch{return d.call(this,R)}}}(U)}}function V(U,L){this.fun=U,this.array=L}function j(){}h.nextTick=function(U){var L=new Array(arguments.length-1);if(arguments.length>1)for(var R=1;R<arguments.length;R++)L[R-1]=arguments[R];k.push(new V(U,L)),k.length!==1||B||_(F)},V.prototype.run=function(){this.fun.apply(null,this.array)},h.title="browser",h.browser=!0,h.env={},h.argv=[],h.version="",h.versions={},h.on=j,h.addListener=j,h.once=j,h.off=j,h.removeListener=j,h.removeAllListeners=j,h.emit=j,h.prependListener=j,h.prependOnceListener=j,h.listeners=function(U){return[]},h.binding=function(U){throw new Error("process.binding is not supported")},h.cwd=function(){return"/"},h.chdir=function(U){throw new Error("process.chdir is not supported")},h.umask=function(){return 0}}},a={};function r(i){var s=a[i];if(s!==void 0)return s.exports;var d=a[i]={exports:{}};return o[i](d,d.exports,r),d.exports}r.d=(i,s)=>{for(var d in s)r.o(s,d)&&!r.o(i,d)&&Object.defineProperty(i,d,{enumerable:!0,get:s[d]})},r.o=(i,s)=>Object.prototype.hasOwnProperty.call(i,s);var l={};return(()=>{r.d(l,{default:()=>nt});var i="0123456789abcdefghijklmnopqrstuvwxyz";function s(b){return i.charAt(b)}function d(b,c){return b&c}function h(b,c){return b|c}function f(b,c){return b^c}function p(b,c){return b&~c}function _(b){if(b==0)return-1;var c=0;return!(65535&b)&&(b>>=16,c+=16),!(255&b)&&(b>>=8,c+=8),!(15&b)&&(b>>=4,c+=4),!(3&b)&&(b>>=2,c+=2),!(1&b)&&++c,c}function C(b){for(var c=0;b!=0;)b&=b-1,++c;return c}var k,B="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",N="=";function q(b){var c,u,g="";for(c=0;c+3<=b.length;c+=3)u=parseInt(b.substring(c,c+3),16),g+=B.charAt(u>>6)+B.charAt(63&u);for(c+1==b.length?(u=parseInt(b.substring(c,c+1),16),g+=B.charAt(u<<2)):c+2==b.length&&(u=parseInt(b.substring(c,c+2),16),g+=B.charAt(u>>2)+B.charAt((3&u)<<4));(3&g.length)>0;)g+=N;return g}function F(b){var c,u="",g=0,y=0;for(c=0;c<b.length&&b.charAt(c)!=N;++c){var w=B.indexOf(b.charAt(c));w<0||(g==0?(u+=s(w>>2),y=3&w,g=1):g==1?(u+=s(y<<2|w>>4),y=15&w,g=2):g==2?(u+=s(y),u+=s(w>>2),y=3&w,g=3):(u+=s(y<<2|w>>4),u+=s(15&w),g=0))}return g==1&&(u+=s(y<<2)),u}var V,j={decode:function(b){var c;if(V===void 0){var u=`= \f
2
+ \r  \u2028\u2029`;for(V=Object.create(null),c=0;c<64;++c)V["ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(c)]=c;for(V["-"]=62,V._=63,c=0;c<u.length;++c)V[u.charAt(c)]=-1}var g=[],y=0,w=0;for(c=0;c<b.length;++c){var x=b.charAt(c);if(x=="=")break;if((x=V[x])!=-1){if(x===void 0)throw new Error("Illegal character at offset "+c);y|=x,++w>=4?(g[g.length]=y>>16,g[g.length]=y>>8&255,g[g.length]=255&y,y=0,w=0):y<<=6}}switch(w){case 1:throw new Error("Base64 encoding incomplete: at least 2 bits missing");case 2:g[g.length]=y>>10;break;case 3:g[g.length]=y>>16,g[g.length]=y>>8&255}return g},re:/-----BEGIN [^-]+-----([A-Za-z0-9+\/=\s]+)-----END [^-]+-----|begin-base64[^\n]+\n([A-Za-z0-9+\/=\s]+)====/,unarmor:function(b){var c=j.re.exec(b);if(c)if(c[1])b=c[1];else{if(!c[2])throw new Error("RegExp out of sync");b=c[2]}return j.decode(b)}},U=1e13,L=function(){function b(c){this.buf=[+c||0]}return b.prototype.mulAdd=function(c,u){var g,y,w=this.buf,x=w.length;for(g=0;g<x;++g)(y=w[g]*c+u)<U?u=0:y-=(u=0|y/U)*U,w[g]=y;u>0&&(w[g]=u)},b.prototype.sub=function(c){var u,g,y=this.buf,w=y.length;for(u=0;u<w;++u)(g=y[u]-c)<0?(g+=U,c=1):c=0,y[u]=g;for(;y[y.length-1]===0;)y.pop()},b.prototype.toString=function(c){if((c||10)!=10)throw new Error("only base 10 is supported");for(var u=this.buf,g=u[u.length-1].toString(),y=u.length-2;y>=0;--y)g+=(U+u[y]).toString().substring(1);return g},b.prototype.valueOf=function(){for(var c=this.buf,u=0,g=c.length-1;g>=0;--g)u=u*U+c[g];return u},b.prototype.simplify=function(){var c=this.buf;return c.length==1?c[0]:this},b}(),R="…",H=/^(\d\d)(0[1-9]|1[0-2])(0[1-9]|[12]\d|3[01])([01]\d|2[0-3])(?:([0-5]\d)(?:([0-5]\d)(?:[.,](\d{1,3}))?)?)?(Z|[-+](?:[0]\d|1[0-2])([0-5]\d)?)?$/,W=/^(\d\d\d\d)(0[1-9]|1[0-2])(0[1-9]|[12]\d|3[01])([01]\d|2[0-3])(?:([0-5]\d)(?:([0-5]\d)(?:[.,](\d{1,3}))?)?)?(Z|[-+](?:[0]\d|1[0-2])([0-5]\d)?)?$/;function J(b,c){return b.length>c&&(b=b.substring(0,c)+R),b}var K,ee=function(){function b(c,u){this.hexDigits="0123456789ABCDEF",c instanceof b?(this.enc=c.enc,this.pos=c.pos):(this.enc=c,this.pos=u)}return b.prototype.get=function(c){if(c===void 0&&(c=this.pos++),c>=this.enc.length)throw new Error("Requesting byte offset ".concat(c," on a stream of length ").concat(this.enc.length));return typeof this.enc=="string"?this.enc.charCodeAt(c):this.enc[c]},b.prototype.hexByte=function(c){return this.hexDigits.charAt(c>>4&15)+this.hexDigits.charAt(15&c)},b.prototype.hexDump=function(c,u,g){for(var y="",w=c;w<u;++w)if(y+=this.hexByte(this.get(w)),g!==!0)switch(15&w){case 7:y+=" ";break;case 15:y+=`
3
+ `;break;default:y+=" "}return y},b.prototype.isASCII=function(c,u){for(var g=c;g<u;++g){var y=this.get(g);if(y<32||y>176)return!1}return!0},b.prototype.parseStringISO=function(c,u){for(var g="",y=c;y<u;++y)g+=String.fromCharCode(this.get(y));return g},b.prototype.parseStringUTF=function(c,u){for(var g="",y=c;y<u;){var w=this.get(y++);g+=w<128?String.fromCharCode(w):w>191&&w<224?String.fromCharCode((31&w)<<6|63&this.get(y++)):String.fromCharCode((15&w)<<12|(63&this.get(y++))<<6|63&this.get(y++))}return g},b.prototype.parseStringBMP=function(c,u){for(var g,y,w="",x=c;x<u;)g=this.get(x++),y=this.get(x++),w+=String.fromCharCode(g<<8|y);return w},b.prototype.parseTime=function(c,u,g){var y=this.parseStringISO(c,u),w=(g?H:W).exec(y);return w?(g&&(w[1]=+w[1],w[1]+=+w[1]<70?2e3:1900),y=w[1]+"-"+w[2]+"-"+w[3]+" "+w[4],w[5]&&(y+=":"+w[5],w[6]&&(y+=":"+w[6],w[7]&&(y+="."+w[7]))),w[8]&&(y+=" UTC",w[8]!="Z"&&(y+=w[8],w[9]&&(y+=":"+w[9]))),y):"Unrecognized time: "+y},b.prototype.parseInteger=function(c,u){for(var g,y=this.get(c),w=y>127,x=w?255:0,S="";y==x&&++c<u;)y=this.get(c);if((g=u-c)==0)return w?-1:0;if(g>4){for(S=y,g<<=3;!(128&(+S^x));)S=+S<<1,--g;S="("+g+` bit)
4
+ `}w&&(y-=256);for(var I=new L(y),M=c+1;M<u;++M)I.mulAdd(256,this.get(M));return S+I.toString()},b.prototype.parseBitString=function(c,u,g){for(var y=this.get(c),w="("+((u-c-1<<3)-y)+` bit)
5
+ `,x="",S=c+1;S<u;++S){for(var I=this.get(S),M=S==u-1?y:0,Z=7;Z>=M;--Z)x+=I>>Z&1?"1":"0";if(x.length>g)return w+J(x,g)}return w+x},b.prototype.parseOctetString=function(c,u,g){if(this.isASCII(c,u))return J(this.parseStringISO(c,u),g);var y=u-c,w="("+y+` byte)
6
+ `;y>(g/=2)&&(u=c+g);for(var x=c;x<u;++x)w+=this.hexByte(this.get(x));return y>g&&(w+=R),w},b.prototype.parseOID=function(c,u,g){for(var y="",w=new L,x=0,S=c;S<u;++S){var I=this.get(S);if(w.mulAdd(128,127&I),x+=7,!(128&I)){if(y==="")if((w=w.simplify())instanceof L)w.sub(80),y="2."+w.toString();else{var M=w<80?w<40?0:1:2;y=M+"."+(w-40*M)}else y+="."+w.toString();if(y.length>g)return J(y,g);w=new L,x=0}}return x>0&&(y+=".incomplete"),y},b}(),ie=function(){function b(c,u,g,y,w){if(!(y instanceof O))throw new Error("Invalid tag value.");this.stream=c,this.header=u,this.length=g,this.tag=y,this.sub=w}return b.prototype.typeName=function(){switch(this.tag.tagClass){case 0:switch(this.tag.tagNumber){case 0:return"EOC";case 1:return"BOOLEAN";case 2:return"INTEGER";case 3:return"BIT_STRING";case 4:return"OCTET_STRING";case 5:return"NULL";case 6:return"OBJECT_IDENTIFIER";case 7:return"ObjectDescriptor";case 8:return"EXTERNAL";case 9:return"REAL";case 10:return"ENUMERATED";case 11:return"EMBEDDED_PDV";case 12:return"UTF8String";case 16:return"SEQUENCE";case 17:return"SET";case 18:return"NumericString";case 19:return"PrintableString";case 20:return"TeletexString";case 21:return"VideotexString";case 22:return"IA5String";case 23:return"UTCTime";case 24:return"GeneralizedTime";case 25:return"GraphicString";case 26:return"VisibleString";case 27:return"GeneralString";case 28:return"UniversalString";case 30:return"BMPString"}return"Universal_"+this.tag.tagNumber.toString();case 1:return"Application_"+this.tag.tagNumber.toString();case 2:return"["+this.tag.tagNumber.toString()+"]";case 3:return"Private_"+this.tag.tagNumber.toString()}},b.prototype.content=function(c){if(this.tag===void 0)return null;c===void 0&&(c=1/0);var u=this.posContent(),g=Math.abs(this.length);if(!this.tag.isUniversal())return this.sub!==null?"("+this.sub.length+" elem)":this.stream.parseOctetString(u,u+g,c);switch(this.tag.tagNumber){case 1:return this.stream.get(u)===0?"false":"true";case 2:return this.stream.parseInteger(u,u+g);case 3:return this.sub?"("+this.sub.length+" elem)":this.stream.parseBitString(u,u+g,c);case 4:return this.sub?"("+this.sub.length+" elem)":this.stream.parseOctetString(u,u+g,c);case 6:return this.stream.parseOID(u,u+g,c);case 16:case 17:return this.sub!==null?"("+this.sub.length+" elem)":"(no elem)";case 12:return J(this.stream.parseStringUTF(u,u+g),c);case 18:case 19:case 20:case 21:case 22:case 26:return J(this.stream.parseStringISO(u,u+g),c);case 30:return J(this.stream.parseStringBMP(u,u+g),c);case 23:case 24:return this.stream.parseTime(u,u+g,this.tag.tagNumber==23)}return null},b.prototype.toString=function(){return this.typeName()+"@"+this.stream.pos+"[header:"+this.header+",length:"+this.length+",sub:"+(this.sub===null?"null":this.sub.length)+"]"},b.prototype.toPrettyString=function(c){c===void 0&&(c="");var u=c+this.typeName()+" @"+this.stream.pos;if(this.length>=0&&(u+="+"),u+=this.length,this.tag.tagConstructed?u+=" (constructed)":!this.tag.isUniversal()||this.tag.tagNumber!=3&&this.tag.tagNumber!=4||this.sub===null||(u+=" (encapsulates)"),u+=`
7
+ `,this.sub!==null){c+=" ";for(var g=0,y=this.sub.length;g<y;++g)u+=this.sub[g].toPrettyString(c)}return u},b.prototype.posStart=function(){return this.stream.pos},b.prototype.posContent=function(){return this.stream.pos+this.header},b.prototype.posEnd=function(){return this.stream.pos+this.header+Math.abs(this.length)},b.prototype.toHexString=function(){return this.stream.hexDump(this.posStart(),this.posEnd(),!0)},b.decodeLength=function(c){var u=c.get(),g=127&u;if(g==u)return g;if(g>6)throw new Error("Length over 48 bits not supported at position "+(c.pos-1));if(g===0)return null;u=0;for(var y=0;y<g;++y)u=256*u+c.get();return u},b.prototype.getHexStringValue=function(){var c=this.toHexString(),u=2*this.header,g=2*this.length;return c.substr(u,g)},b.decode=function(c){var u;u=c instanceof ee?c:new ee(c,0);var g=new ee(u),y=new O(u),w=b.decodeLength(u),x=u.pos,S=x-g.pos,I=null,M=function(){var de=[];if(w!==null){for(var ne=x+w;u.pos<ne;)de[de.length]=b.decode(u);if(u.pos!=ne)throw new Error("Content size is not correct for container starting at offset "+x)}else try{for(;;){var be=b.decode(u);if(be.tag.isEOC())break;de[de.length]=be}w=x-u.pos}catch(fe){throw new Error("Exception while decoding undefined length content: "+fe)}return de};if(y.tagConstructed)I=M();else if(y.isUniversal()&&(y.tagNumber==3||y.tagNumber==4))try{if(y.tagNumber==3&&u.get()!=0)throw new Error("BIT STRINGs with unused bits cannot encapsulate.");I=M();for(var Z=0;Z<I.length;++Z)if(I[Z].tag.isEOC())throw new Error("EOC is not supposed to be actual content.")}catch{I=null}if(I===null){if(w===null)throw new Error("We can't skip over an invalid tag with undefined length at offset "+x);u.pos=x+Math.abs(w)}return new b(g,S,w,y,I)},b}(),O=function(){function b(c){var u=c.get();if(this.tagClass=u>>6,this.tagConstructed=(32&u)!=0,this.tagNumber=31&u,this.tagNumber==31){var g=new L;do u=c.get(),g.mulAdd(128,127&u);while(128&u);this.tagNumber=g.simplify()}}return b.prototype.isUniversal=function(){return this.tagClass===0},b.prototype.isEOC=function(){return this.tagClass===0&&this.tagNumber===0},b}(),E=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97,101,103,107,109,113,127,131,137,139,149,151,157,163,167,173,179,181,191,193,197,199,211,223,227,229,233,239,241,251,257,263,269,271,277,281,283,293,307,311,313,317,331,337,347,349,353,359,367,373,379,383,389,397,401,409,419,421,431,433,439,443,449,457,461,463,467,479,487,491,499,503,509,521,523,541,547,557,563,569,571,577,587,593,599,601,607,613,617,619,631,641,643,647,653,659,661,673,677,683,691,701,709,719,727,733,739,743,751,757,761,769,773,787,797,809,811,821,823,827,829,839,853,857,859,863,877,881,883,887,907,911,919,929,937,941,947,953,967,971,977,983,991,997],m=(1<<26)/E[E.length-1],A=function(){function b(c,u,g){c!=null&&(typeof c=="number"?this.fromNumber(c,u,g):u==null&&typeof c!="string"?this.fromString(c,256):this.fromString(c,u))}return b.prototype.toString=function(c){if(this.s<0)return"-"+this.negate().toString(c);var u;if(c==16)u=4;else if(c==8)u=3;else if(c==2)u=1;else if(c==32)u=5;else{if(c!=4)return this.toRadix(c);u=2}var g,y=(1<<u)-1,w=!1,x="",S=this.t,I=this.DB-S*this.DB%u;if(S-- >0)for(I<this.DB&&(g=this[S]>>I)>0&&(w=!0,x=s(g));S>=0;)I<u?(g=(this[S]&(1<<I)-1)<<u-I,g|=this[--S]>>(I+=this.DB-u)):(g=this[S]>>(I-=u)&y,I<=0&&(I+=this.DB,--S)),g>0&&(w=!0),w&&(x+=s(g));return w?x:"0"},b.prototype.negate=function(){var c=Q();return b.ZERO.subTo(this,c),c},b.prototype.abs=function(){return this.s<0?this.negate():this},b.prototype.compareTo=function(c){var u=this.s-c.s;if(u!=0)return u;var g=this.t;if((u=g-c.t)!=0)return this.s<0?-u:u;for(;--g>=0;)if((u=this[g]-c[g])!=0)return u;return 0},b.prototype.bitLength=function(){return this.t<=0?0:this.DB*(this.t-1)+ke(this[this.t-1]^this.s&this.DM)},b.prototype.mod=function(c){var u=Q();return this.abs().divRemTo(c,null,u),this.s<0&&u.compareTo(b.ZERO)>0&&c.subTo(u,u),u},b.prototype.modPowInt=function(c,u){var g;return g=c<256||u.isEven()?new qe(u):new Y(u),this.exp(c,g)},b.prototype.clone=function(){var c=Q();return this.copyTo(c),c},b.prototype.intValue=function(){if(this.s<0){if(this.t==1)return this[0]-this.DV;if(this.t==0)return-1}else{if(this.t==1)return this[0];if(this.t==0)return 0}return(this[1]&(1<<32-this.DB)-1)<<this.DB|this[0]},b.prototype.byteValue=function(){return this.t==0?this.s:this[0]<<24>>24},b.prototype.shortValue=function(){return this.t==0?this.s:this[0]<<16>>16},b.prototype.signum=function(){return this.s<0?-1:this.t<=0||this.t==1&&this[0]<=0?0:1},b.prototype.toByteArray=function(){var c=this.t,u=[];u[0]=this.s;var g,y=this.DB-c*this.DB%8,w=0;if(c-- >0)for(y<this.DB&&(g=this[c]>>y)!=(this.s&this.DM)>>y&&(u[w++]=g|this.s<<this.DB-y);c>=0;)y<8?(g=(this[c]&(1<<y)-1)<<8-y,g|=this[--c]>>(y+=this.DB-8)):(g=this[c]>>(y-=8)&255,y<=0&&(y+=this.DB,--c)),128&g&&(g|=-256),w==0&&(128&this.s)!=(128&g)&&++w,(w>0||g!=this.s)&&(u[w++]=g);return u},b.prototype.equals=function(c){return this.compareTo(c)==0},b.prototype.min=function(c){return this.compareTo(c)<0?this:c},b.prototype.max=function(c){return this.compareTo(c)>0?this:c},b.prototype.and=function(c){var u=Q();return this.bitwiseTo(c,d,u),u},b.prototype.or=function(c){var u=Q();return this.bitwiseTo(c,h,u),u},b.prototype.xor=function(c){var u=Q();return this.bitwiseTo(c,f,u),u},b.prototype.andNot=function(c){var u=Q();return this.bitwiseTo(c,p,u),u},b.prototype.not=function(){for(var c=Q(),u=0;u<this.t;++u)c[u]=this.DM&~this[u];return c.t=this.t,c.s=~this.s,c},b.prototype.shiftLeft=function(c){var u=Q();return c<0?this.rShiftTo(-c,u):this.lShiftTo(c,u),u},b.prototype.shiftRight=function(c){var u=Q();return c<0?this.lShiftTo(-c,u):this.rShiftTo(c,u),u},b.prototype.getLowestSetBit=function(){for(var c=0;c<this.t;++c)if(this[c]!=0)return c*this.DB+_(this[c]);return this.s<0?this.t*this.DB:-1},b.prototype.bitCount=function(){for(var c=0,u=this.s&this.DM,g=0;g<this.t;++g)c+=C(this[g]^u);return c},b.prototype.testBit=function(c){var u=Math.floor(c/this.DB);return u>=this.t?this.s!=0:(this[u]&1<<c%this.DB)!=0},b.prototype.setBit=function(c){return this.changeBit(c,h)},b.prototype.clearBit=function(c){return this.changeBit(c,p)},b.prototype.flipBit=function(c){return this.changeBit(c,f)},b.prototype.add=function(c){var u=Q();return this.addTo(c,u),u},b.prototype.subtract=function(c){var u=Q();return this.subTo(c,u),u},b.prototype.multiply=function(c){var u=Q();return this.multiplyTo(c,u),u},b.prototype.divide=function(c){var u=Q();return this.divRemTo(c,u,null),u},b.prototype.remainder=function(c){var u=Q();return this.divRemTo(c,null,u),u},b.prototype.divideAndRemainder=function(c){var u=Q(),g=Q();return this.divRemTo(c,u,g),[u,g]},b.prototype.modPow=function(c,u){var g,y,w=c.bitLength(),x=pe(1);if(w<=0)return x;g=w<18?1:w<48?3:w<144?4:w<768?5:6,y=w<8?new qe(u):u.isEven()?new Te(u):new Y(u);var S=[],I=3,M=g-1,Z=(1<<g)-1;if(S[1]=y.convert(this),g>1){var de=Q();for(y.sqrTo(S[1],de);I<=Z;)S[I]=Q(),y.mulTo(de,S[I-2],S[I]),I+=2}var ne,be,fe=c.t-1,ue=!0,ye=Q();for(w=ke(c[fe])-1;fe>=0;){for(w>=M?ne=c[fe]>>w-M&Z:(ne=(c[fe]&(1<<w+1)-1)<<M-w,fe>0&&(ne|=c[fe-1]>>this.DB+w-M)),I=g;!(1&ne);)ne>>=1,--I;if((w-=I)<0&&(w+=this.DB,--fe),ue)S[ne].copyTo(x),ue=!1;else{for(;I>1;)y.sqrTo(x,ye),y.sqrTo(ye,x),I-=2;I>0?y.sqrTo(x,ye):(be=x,x=ye,ye=be),y.mulTo(ye,S[ne],x)}for(;fe>=0&&!(c[fe]&1<<w);)y.sqrTo(x,ye),be=x,x=ye,ye=be,--w<0&&(w=this.DB-1,--fe)}return y.revert(x)},b.prototype.modInverse=function(c){var u=c.isEven();if(this.isEven()&&u||c.signum()==0)return b.ZERO;for(var g=c.clone(),y=this.clone(),w=pe(1),x=pe(0),S=pe(0),I=pe(1);g.signum()!=0;){for(;g.isEven();)g.rShiftTo(1,g),u?(w.isEven()&&x.isEven()||(w.addTo(this,w),x.subTo(c,x)),w.rShiftTo(1,w)):x.isEven()||x.subTo(c,x),x.rShiftTo(1,x);for(;y.isEven();)y.rShiftTo(1,y),u?(S.isEven()&&I.isEven()||(S.addTo(this,S),I.subTo(c,I)),S.rShiftTo(1,S)):I.isEven()||I.subTo(c,I),I.rShiftTo(1,I);g.compareTo(y)>=0?(g.subTo(y,g),u&&w.subTo(S,w),x.subTo(I,x)):(y.subTo(g,y),u&&S.subTo(w,S),I.subTo(x,I))}return y.compareTo(b.ONE)!=0?b.ZERO:I.compareTo(c)>=0?I.subtract(c):I.signum()<0?(I.addTo(c,I),I.signum()<0?I.add(c):I):I},b.prototype.pow=function(c){return this.exp(c,new T)},b.prototype.gcd=function(c){var u=this.s<0?this.negate():this.clone(),g=c.s<0?c.negate():c.clone();if(u.compareTo(g)<0){var y=u;u=g,g=y}var w=u.getLowestSetBit(),x=g.getLowestSetBit();if(x<0)return u;for(w<x&&(x=w),x>0&&(u.rShiftTo(x,u),g.rShiftTo(x,g));u.signum()>0;)(w=u.getLowestSetBit())>0&&u.rShiftTo(w,u),(w=g.getLowestSetBit())>0&&g.rShiftTo(w,g),u.compareTo(g)>=0?(u.subTo(g,u),u.rShiftTo(1,u)):(g.subTo(u,g),g.rShiftTo(1,g));return x>0&&g.lShiftTo(x,g),g},b.prototype.isProbablePrime=function(c){var u,g=this.abs();if(g.t==1&&g[0]<=E[E.length-1]){for(u=0;u<E.length;++u)if(g[0]==E[u])return!0;return!1}if(g.isEven())return!1;for(u=1;u<E.length;){for(var y=E[u],w=u+1;w<E.length&&y<m;)y*=E[w++];for(y=g.modInt(y);u<w;)if(y%E[u++]==0)return!1}return g.millerRabin(c)},b.prototype.copyTo=function(c){for(var u=this.t-1;u>=0;--u)c[u]=this[u];c.t=this.t,c.s=this.s},b.prototype.fromInt=function(c){this.t=1,this.s=c<0?-1:0,c>0?this[0]=c:c<-1?this[0]=c+this.DV:this.t=0},b.prototype.fromString=function(c,u){var g;if(u==16)g=4;else if(u==8)g=3;else if(u==256)g=8;else if(u==2)g=1;else if(u==32)g=5;else{if(u!=4)return void this.fromRadix(c,u);g=2}this.t=0,this.s=0;for(var y=c.length,w=!1,x=0;--y>=0;){var S=g==8?255&+c[y]:_e(c,y);S<0?c.charAt(y)=="-"&&(w=!0):(w=!1,x==0?this[this.t++]=S:x+g>this.DB?(this[this.t-1]|=(S&(1<<this.DB-x)-1)<<x,this[this.t++]=S>>this.DB-x):this[this.t-1]|=S<<x,(x+=g)>=this.DB&&(x-=this.DB))}g==8&&128&+c[0]&&(this.s=-1,x>0&&(this[this.t-1]|=(1<<this.DB-x)-1<<x)),this.clamp(),w&&b.ZERO.subTo(this,this)},b.prototype.clamp=function(){for(var c=this.s&this.DM;this.t>0&&this[this.t-1]==c;)--this.t},b.prototype.dlShiftTo=function(c,u){var g;for(g=this.t-1;g>=0;--g)u[g+c]=this[g];for(g=c-1;g>=0;--g)u[g]=0;u.t=this.t+c,u.s=this.s},b.prototype.drShiftTo=function(c,u){for(var g=c;g<this.t;++g)u[g-c]=this[g];u.t=Math.max(this.t-c,0),u.s=this.s},b.prototype.lShiftTo=function(c,u){for(var g=c%this.DB,y=this.DB-g,w=(1<<y)-1,x=Math.floor(c/this.DB),S=this.s<<g&this.DM,I=this.t-1;I>=0;--I)u[I+x+1]=this[I]>>y|S,S=(this[I]&w)<<g;for(I=x-1;I>=0;--I)u[I]=0;u[x]=S,u.t=this.t+x+1,u.s=this.s,u.clamp()},b.prototype.rShiftTo=function(c,u){u.s=this.s;var g=Math.floor(c/this.DB);if(g>=this.t)u.t=0;else{var y=c%this.DB,w=this.DB-y,x=(1<<y)-1;u[0]=this[g]>>y;for(var S=g+1;S<this.t;++S)u[S-g-1]|=(this[S]&x)<<w,u[S-g]=this[S]>>y;y>0&&(u[this.t-g-1]|=(this.s&x)<<w),u.t=this.t-g,u.clamp()}},b.prototype.subTo=function(c,u){for(var g=0,y=0,w=Math.min(c.t,this.t);g<w;)y+=this[g]-c[g],u[g++]=y&this.DM,y>>=this.DB;if(c.t<this.t){for(y-=c.s;g<this.t;)y+=this[g],u[g++]=y&this.DM,y>>=this.DB;y+=this.s}else{for(y+=this.s;g<c.t;)y-=c[g],u[g++]=y&this.DM,y>>=this.DB;y-=c.s}u.s=y<0?-1:0,y<-1?u[g++]=this.DV+y:y>0&&(u[g++]=y),u.t=g,u.clamp()},b.prototype.multiplyTo=function(c,u){var g=this.abs(),y=c.abs(),w=g.t;for(u.t=w+y.t;--w>=0;)u[w]=0;for(w=0;w<y.t;++w)u[w+g.t]=g.am(0,y[w],u,w,0,g.t);u.s=0,u.clamp(),this.s!=c.s&&b.ZERO.subTo(u,u)},b.prototype.squareTo=function(c){for(var u=this.abs(),g=c.t=2*u.t;--g>=0;)c[g]=0;for(g=0;g<u.t-1;++g){var y=u.am(g,u[g],c,2*g,0,1);(c[g+u.t]+=u.am(g+1,2*u[g],c,2*g+1,y,u.t-g-1))>=u.DV&&(c[g+u.t]-=u.DV,c[g+u.t+1]=1)}c.t>0&&(c[c.t-1]+=u.am(g,u[g],c,2*g,0,1)),c.s=0,c.clamp()},b.prototype.divRemTo=function(c,u,g){var y=c.abs();if(!(y.t<=0)){var w=this.abs();if(w.t<y.t)return u!=null&&u.fromInt(0),void(g!=null&&this.copyTo(g));g==null&&(g=Q());var x=Q(),S=this.s,I=c.s,M=this.DB-ke(y[y.t-1]);M>0?(y.lShiftTo(M,x),w.lShiftTo(M,g)):(y.copyTo(x),w.copyTo(g));var Z=x.t,de=x[Z-1];if(de!=0){var ne=de*(1<<this.F1)+(Z>1?x[Z-2]>>this.F2:0),be=this.FV/ne,fe=(1<<this.F1)/ne,ue=1<<this.F2,ye=g.t,Re=ye-Z,D=u??Q();for(x.dlShiftTo(Re,D),g.compareTo(D)>=0&&(g[g.t++]=1,g.subTo(D,g)),b.ONE.dlShiftTo(Z,D),D.subTo(x,x);x.t<Z;)x[x.t++]=0;for(;--Re>=0;){var Ce=g[--ye]==de?this.DM:Math.floor(g[ye]*be+(g[ye-1]+ue)*fe);if((g[ye]+=x.am(0,Ce,g,Re,0,Z))<Ce)for(x.dlShiftTo(Re,D),g.subTo(D,g);g[ye]<--Ce;)g.subTo(D,g)}u!=null&&(g.drShiftTo(Z,u),S!=I&&b.ZERO.subTo(u,u)),g.t=Z,g.clamp(),M>0&&g.rShiftTo(M,g),S<0&&b.ZERO.subTo(g,g)}}},b.prototype.invDigit=function(){if(this.t<1)return 0;var c=this[0];if(!(1&c))return 0;var u=3&c;return(u=(u=(u=(u=u*(2-(15&c)*u)&15)*(2-(255&c)*u)&255)*(2-((65535&c)*u&65535))&65535)*(2-c*u%this.DV)%this.DV)>0?this.DV-u:-u},b.prototype.isEven=function(){return(this.t>0?1&this[0]:this.s)==0},b.prototype.exp=function(c,u){if(c>4294967295||c<1)return b.ONE;var g=Q(),y=Q(),w=u.convert(this),x=ke(c)-1;for(w.copyTo(g);--x>=0;)if(u.sqrTo(g,y),(c&1<<x)>0)u.mulTo(y,w,g);else{var S=g;g=y,y=S}return u.revert(g)},b.prototype.chunkSize=function(c){return Math.floor(Math.LN2*this.DB/Math.log(c))},b.prototype.toRadix=function(c){if(c==null&&(c=10),this.signum()==0||c<2||c>36)return"0";var u=this.chunkSize(c),g=Math.pow(c,u),y=pe(g),w=Q(),x=Q(),S="";for(this.divRemTo(y,w,x);w.signum()>0;)S=(g+x.intValue()).toString(c).substr(1)+S,w.divRemTo(y,w,x);return x.intValue().toString(c)+S},b.prototype.fromRadix=function(c,u){this.fromInt(0),u==null&&(u=10);for(var g=this.chunkSize(u),y=Math.pow(u,g),w=!1,x=0,S=0,I=0;I<c.length;++I){var M=_e(c,I);M<0?c.charAt(I)=="-"&&this.signum()==0&&(w=!0):(S=u*S+M,++x>=g&&(this.dMultiply(y),this.dAddOffset(S,0),x=0,S=0))}x>0&&(this.dMultiply(Math.pow(u,x)),this.dAddOffset(S,0)),w&&b.ZERO.subTo(this,this)},b.prototype.fromNumber=function(c,u,g){if(typeof u=="number")if(c<2)this.fromInt(1);else for(this.fromNumber(c,g),this.testBit(c-1)||this.bitwiseTo(b.ONE.shiftLeft(c-1),h,this),this.isEven()&&this.dAddOffset(1,0);!this.isProbablePrime(u);)this.dAddOffset(2,0),this.bitLength()>c&&this.subTo(b.ONE.shiftLeft(c-1),this);else{var y=[],w=7&c;y.length=1+(c>>3),u.nextBytes(y),w>0?y[0]&=(1<<w)-1:y[0]=0,this.fromString(y,256)}},b.prototype.bitwiseTo=function(c,u,g){var y,w,x=Math.min(c.t,this.t);for(y=0;y<x;++y)g[y]=u(this[y],c[y]);if(c.t<this.t){for(w=c.s&this.DM,y=x;y<this.t;++y)g[y]=u(this[y],w);g.t=this.t}else{for(w=this.s&this.DM,y=x;y<c.t;++y)g[y]=u(w,c[y]);g.t=c.t}g.s=u(this.s,c.s),g.clamp()},b.prototype.changeBit=function(c,u){var g=b.ONE.shiftLeft(c);return this.bitwiseTo(g,u,g),g},b.prototype.addTo=function(c,u){for(var g=0,y=0,w=Math.min(c.t,this.t);g<w;)y+=this[g]+c[g],u[g++]=y&this.DM,y>>=this.DB;if(c.t<this.t){for(y+=c.s;g<this.t;)y+=this[g],u[g++]=y&this.DM,y>>=this.DB;y+=this.s}else{for(y+=this.s;g<c.t;)y+=c[g],u[g++]=y&this.DM,y>>=this.DB;y+=c.s}u.s=y<0?-1:0,y>0?u[g++]=y:y<-1&&(u[g++]=this.DV+y),u.t=g,u.clamp()},b.prototype.dMultiply=function(c){this[this.t]=this.am(0,c-1,this,0,0,this.t),++this.t,this.clamp()},b.prototype.dAddOffset=function(c,u){if(c!=0){for(;this.t<=u;)this[this.t++]=0;for(this[u]+=c;this[u]>=this.DV;)this[u]-=this.DV,++u>=this.t&&(this[this.t++]=0),++this[u]}},b.prototype.multiplyLowerTo=function(c,u,g){var y=Math.min(this.t+c.t,u);for(g.s=0,g.t=y;y>0;)g[--y]=0;for(var w=g.t-this.t;y<w;++y)g[y+this.t]=this.am(0,c[y],g,y,0,this.t);for(w=Math.min(c.t,u);y<w;++y)this.am(0,c[y],g,y,0,u-y);g.clamp()},b.prototype.multiplyUpperTo=function(c,u,g){--u;var y=g.t=this.t+c.t-u;for(g.s=0;--y>=0;)g[y]=0;for(y=Math.max(u-this.t,0);y<c.t;++y)g[this.t+y-u]=this.am(u-y,c[y],g,0,0,this.t+y-u);g.clamp(),g.drShiftTo(1,g)},b.prototype.modInt=function(c){if(c<=0)return 0;var u=this.DV%c,g=this.s<0?c-1:0;if(this.t>0)if(u==0)g=this[0]%c;else for(var y=this.t-1;y>=0;--y)g=(u*g+this[y])%c;return g},b.prototype.millerRabin=function(c){var u=this.subtract(b.ONE),g=u.getLowestSetBit();if(g<=0)return!1;var y=u.shiftRight(g);(c=c+1>>1)>E.length&&(c=E.length);for(var w=Q(),x=0;x<c;++x){w.fromInt(E[Math.floor(Math.random()*E.length)]);var S=w.modPow(y,this);if(S.compareTo(b.ONE)!=0&&S.compareTo(u)!=0){for(var I=1;I++<g&&S.compareTo(u)!=0;)if((S=S.modPowInt(2,this)).compareTo(b.ONE)==0)return!1;if(S.compareTo(u)!=0)return!1}}return!0},b.prototype.square=function(){var c=Q();return this.squareTo(c),c},b.prototype.gcda=function(c,u){var g=this.s<0?this.negate():this.clone(),y=c.s<0?c.negate():c.clone();if(g.compareTo(y)<0){var w=g;g=y,y=w}var x=g.getLowestSetBit(),S=y.getLowestSetBit();if(S<0)u(g);else{x<S&&(S=x),S>0&&(g.rShiftTo(S,g),y.rShiftTo(S,y));var I=function(){(x=g.getLowestSetBit())>0&&g.rShiftTo(x,g),(x=y.getLowestSetBit())>0&&y.rShiftTo(x,y),g.compareTo(y)>=0?(g.subTo(y,g),g.rShiftTo(1,g)):(y.subTo(g,y),y.rShiftTo(1,y)),g.signum()>0?setTimeout(I,0):(S>0&&y.lShiftTo(S,y),setTimeout(function(){u(y)},0))};setTimeout(I,10)}},b.prototype.fromNumberAsync=function(c,u,g,y){if(typeof u=="number")if(c<2)this.fromInt(1);else{this.fromNumber(c,g),this.testBit(c-1)||this.bitwiseTo(b.ONE.shiftLeft(c-1),h,this),this.isEven()&&this.dAddOffset(1,0);var w=this,x=function(){w.dAddOffset(2,0),w.bitLength()>c&&w.subTo(b.ONE.shiftLeft(c-1),w),w.isProbablePrime(u)?setTimeout(function(){y()},0):setTimeout(x,0)};setTimeout(x,0)}else{var S=[],I=7&c;S.length=1+(c>>3),u.nextBytes(S),I>0?S[0]&=(1<<I)-1:S[0]=0,this.fromString(S,256)}},b}(),T=function(){function b(){}return b.prototype.convert=function(c){return c},b.prototype.revert=function(c){return c},b.prototype.mulTo=function(c,u,g){c.multiplyTo(u,g)},b.prototype.sqrTo=function(c,u){c.squareTo(u)},b}(),qe=function(){function b(c){this.m=c}return b.prototype.convert=function(c){return c.s<0||c.compareTo(this.m)>=0?c.mod(this.m):c},b.prototype.revert=function(c){return c},b.prototype.reduce=function(c){c.divRemTo(this.m,null,c)},b.prototype.mulTo=function(c,u,g){c.multiplyTo(u,g),this.reduce(g)},b.prototype.sqrTo=function(c,u){c.squareTo(u),this.reduce(u)},b}(),Y=function(){function b(c){this.m=c,this.mp=c.invDigit(),this.mpl=32767&this.mp,this.mph=this.mp>>15,this.um=(1<<c.DB-15)-1,this.mt2=2*c.t}return b.prototype.convert=function(c){var u=Q();return c.abs().dlShiftTo(this.m.t,u),u.divRemTo(this.m,null,u),c.s<0&&u.compareTo(A.ZERO)>0&&this.m.subTo(u,u),u},b.prototype.revert=function(c){var u=Q();return c.copyTo(u),this.reduce(u),u},b.prototype.reduce=function(c){for(;c.t<=this.mt2;)c[c.t++]=0;for(var u=0;u<this.m.t;++u){var g=32767&c[u],y=g*this.mpl+((g*this.mph+(c[u]>>15)*this.mpl&this.um)<<15)&c.DM;for(c[g=u+this.m.t]+=this.m.am(0,y,c,u,0,this.m.t);c[g]>=c.DV;)c[g]-=c.DV,c[++g]++}c.clamp(),c.drShiftTo(this.m.t,c),c.compareTo(this.m)>=0&&c.subTo(this.m,c)},b.prototype.mulTo=function(c,u,g){c.multiplyTo(u,g),this.reduce(g)},b.prototype.sqrTo=function(c,u){c.squareTo(u),this.reduce(u)},b}(),Te=function(){function b(c){this.m=c,this.r2=Q(),this.q3=Q(),A.ONE.dlShiftTo(2*c.t,this.r2),this.mu=this.r2.divide(c)}return b.prototype.convert=function(c){if(c.s<0||c.t>2*this.m.t)return c.mod(this.m);if(c.compareTo(this.m)<0)return c;var u=Q();return c.copyTo(u),this.reduce(u),u},b.prototype.revert=function(c){return c},b.prototype.reduce=function(c){for(c.drShiftTo(this.m.t-1,this.r2),c.t>this.m.t+1&&(c.t=this.m.t+1,c.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);c.compareTo(this.r2)<0;)c.dAddOffset(1,this.m.t+1);for(c.subTo(this.r2,c);c.compareTo(this.m)>=0;)c.subTo(this.m,c)},b.prototype.mulTo=function(c,u,g){c.multiplyTo(u,g),this.reduce(g)},b.prototype.sqrTo=function(c,u){c.squareTo(u),this.reduce(u)},b}();function Q(){return new A(null)}function ce(b,c){return new A(b,c)}var Ae=typeof navigator<"u";Ae&&navigator.appName=="Microsoft Internet Explorer"?(A.prototype.am=function(b,c,u,g,y,w){for(var x=32767&c,S=c>>15;--w>=0;){var I=32767&this[b],M=this[b++]>>15,Z=S*I+M*x;y=((I=x*I+((32767&Z)<<15)+u[g]+(1073741823&y))>>>30)+(Z>>>15)+S*M+(y>>>30),u[g++]=1073741823&I}return y},K=30):Ae&&navigator.appName!="Netscape"?(A.prototype.am=function(b,c,u,g,y,w){for(;--w>=0;){var x=c*this[b++]+u[g]+y;y=Math.floor(x/67108864),u[g++]=67108863&x}return y},K=26):(A.prototype.am=function(b,c,u,g,y,w){for(var x=16383&c,S=c>>14;--w>=0;){var I=16383&this[b],M=this[b++]>>14,Z=S*I+M*x;y=((I=x*I+((16383&Z)<<14)+u[g]+y)>>28)+(Z>>14)+S*M,u[g++]=268435455&I}return y},K=28),A.prototype.DB=K,A.prototype.DM=(1<<K)-1,A.prototype.DV=1<<K,A.prototype.FV=Math.pow(2,52),A.prototype.F1=52-K,A.prototype.F2=2*K-52;var z,$,X=[];for(z=48,$=0;$<=9;++$)X[z++]=$;for(z=97,$=10;$<36;++$)X[z++]=$;for(z=65,$=10;$<36;++$)X[z++]=$;function _e(b,c){var u=X[b.charCodeAt(c)];return u??-1}function pe(b){var c=Q();return c.fromInt(b),c}function ke(b){var c,u=1;return(c=b>>>16)!=0&&(b=c,u+=16),(c=b>>8)!=0&&(b=c,u+=8),(c=b>>4)!=0&&(b=c,u+=4),(c=b>>2)!=0&&(b=c,u+=2),(c=b>>1)!=0&&(b=c,u+=1),u}A.ZERO=pe(0),A.ONE=pe(1);var Se,xe,Ge=function(){function b(){this.i=0,this.j=0,this.S=[]}return b.prototype.init=function(c){var u,g,y;for(u=0;u<256;++u)this.S[u]=u;for(g=0,u=0;u<256;++u)g=g+this.S[u]+c[u%c.length]&255,y=this.S[u],this.S[u]=this.S[g],this.S[g]=y;this.i=0,this.j=0},b.prototype.next=function(){var c;return this.i=this.i+1&255,this.j=this.j+this.S[this.i]&255,c=this.S[this.i],this.S[this.i]=this.S[this.j],this.S[this.j]=c,this.S[c+this.S[this.i]&255]},b}(),je=256,ae=null;if(ae==null){ae=[],xe=0;var P=void 0;if(typeof window<"u"&&window.crypto&&window.crypto.getRandomValues){var te=new Uint32Array(256);for(window.crypto.getRandomValues(te),P=0;P<te.length;++P)ae[xe++]=255&te[P]}var Ne=0,Ie=function(b){if((Ne=Ne||0)>=256||xe>=je)window.removeEventListener?window.removeEventListener("mousemove",Ie,!1):window.detachEvent&&window.detachEvent("onmousemove",Ie);else try{var c=b.x+b.y;ae[xe++]=255&c,Ne+=1}catch{}};typeof window<"u"&&(window.addEventListener?window.addEventListener("mousemove",Ie,!1):window.attachEvent&&window.attachEvent("onmousemove",Ie))}function dt(){if(Se==null){for(Se=new Ge;xe<je;){var b=Math.floor(65536*Math.random());ae[xe++]=255&b}for(Se.init(ae),xe=0;xe<ae.length;++xe)ae[xe]=0;xe=0}return Se.next()}var ve=function(){function b(){}return b.prototype.nextBytes=function(c){for(var u=0;u<c.length;++u)c[u]=dt()},b}(),Fe=function(){function b(){this.n=null,this.e=0,this.d=null,this.p=null,this.q=null,this.dmp1=null,this.dmq1=null,this.coeff=null}return b.prototype.doPublic=function(c){return c.modPowInt(this.e,this.n)},b.prototype.doPrivate=function(c){if(this.p==null||this.q==null)return c.modPow(this.d,this.n);for(var u=c.mod(this.p).modPow(this.dmp1,this.p),g=c.mod(this.q).modPow(this.dmq1,this.q);u.compareTo(g)<0;)u=u.add(this.p);return u.subtract(g).multiply(this.coeff).mod(this.p).multiply(this.q).add(g)},b.prototype.setPublic=function(c,u){c!=null&&u!=null&&c.length>0&&u.length>0?(this.n=ce(c,16),this.e=parseInt(u,16)):console.error("Invalid RSA public key")},b.prototype.encrypt=function(c){var u=this.n.bitLength()+7>>3,g=function(I,M){if(M<I.length+11)return console.error("Message too long for RSA"),null;for(var Z=[],de=I.length-1;de>=0&&M>0;){var ne=I.charCodeAt(de--);ne<128?Z[--M]=ne:ne>127&&ne<2048?(Z[--M]=63&ne|128,Z[--M]=ne>>6|192):(Z[--M]=63&ne|128,Z[--M]=ne>>6&63|128,Z[--M]=ne>>12|224)}Z[--M]=0;for(var be=new ve,fe=[];M>2;){for(fe[0]=0;fe[0]==0;)be.nextBytes(fe);Z[--M]=fe[0]}return Z[--M]=2,Z[--M]=0,new A(Z)}(c,u);if(g==null)return null;var y=this.doPublic(g);if(y==null)return null;for(var w=y.toString(16),x=w.length,S=0;S<2*u-x;S++)w="0"+w;return w},b.prototype.setPrivate=function(c,u,g){c!=null&&u!=null&&c.length>0&&u.length>0?(this.n=ce(c,16),this.e=parseInt(u,16),this.d=ce(g,16)):console.error("Invalid RSA private key")},b.prototype.setPrivateEx=function(c,u,g,y,w,x,S,I){c!=null&&u!=null&&c.length>0&&u.length>0?(this.n=ce(c,16),this.e=parseInt(u,16),this.d=ce(g,16),this.p=ce(y,16),this.q=ce(w,16),this.dmp1=ce(x,16),this.dmq1=ce(S,16),this.coeff=ce(I,16)):console.error("Invalid RSA private key")},b.prototype.generate=function(c,u){var g=new ve,y=c>>1;this.e=parseInt(u,16);for(var w=new A(u,16);;){for(;this.p=new A(c-y,1,g),this.p.subtract(A.ONE).gcd(w).compareTo(A.ONE)!=0||!this.p.isProbablePrime(10););for(;this.q=new A(y,1,g),this.q.subtract(A.ONE).gcd(w).compareTo(A.ONE)!=0||!this.q.isProbablePrime(10););if(this.p.compareTo(this.q)<=0){var x=this.p;this.p=this.q,this.q=x}var S=this.p.subtract(A.ONE),I=this.q.subtract(A.ONE),M=S.multiply(I);if(M.gcd(w).compareTo(A.ONE)==0){this.n=this.p.multiply(this.q),this.d=w.modInverse(M),this.dmp1=this.d.mod(S),this.dmq1=this.d.mod(I),this.coeff=this.q.modInverse(this.p);break}}},b.prototype.decrypt=function(c){var u=ce(c,16),g=this.doPrivate(u);return g==null?null:function(y,w){for(var x=y.toByteArray(),S=0;S<x.length&&x[S]==0;)++S;if(x.length-S!=w-1||x[S]!=2)return null;for(++S;x[S]!=0;)if(++S>=x.length)return null;for(var I="";++S<x.length;){var M=255&x[S];M<128?I+=String.fromCharCode(M):M>191&&M<224?(I+=String.fromCharCode((31&M)<<6|63&x[S+1]),++S):(I+=String.fromCharCode((15&M)<<12|(63&x[S+1])<<6|63&x[S+2]),S+=2)}return I}(g,this.n.bitLength()+7>>3)},b.prototype.generateAsync=function(c,u,g){var y=new ve,w=c>>1;this.e=parseInt(u,16);var x=new A(u,16),S=this,I=function(){var M=function(){if(S.p.compareTo(S.q)<=0){var ne=S.p;S.p=S.q,S.q=ne}var be=S.p.subtract(A.ONE),fe=S.q.subtract(A.ONE),ue=be.multiply(fe);ue.gcd(x).compareTo(A.ONE)==0?(S.n=S.p.multiply(S.q),S.d=x.modInverse(ue),S.dmp1=S.d.mod(be),S.dmq1=S.d.mod(fe),S.coeff=S.q.modInverse(S.p),setTimeout(function(){g()},0)):setTimeout(I,0)},Z=function(){S.q=Q(),S.q.fromNumberAsync(w,1,y,function(){S.q.subtract(A.ONE).gcda(x,function(ne){ne.compareTo(A.ONE)==0&&S.q.isProbablePrime(10)?setTimeout(M,0):setTimeout(Z,0)})})},de=function(){S.p=Q(),S.p.fromNumberAsync(c-w,1,y,function(){S.p.subtract(A.ONE).gcda(x,function(ne){ne.compareTo(A.ONE)==0&&S.p.isProbablePrime(10)?setTimeout(Z,0):setTimeout(de,0)})})};setTimeout(de,0)};setTimeout(I,0)},b.prototype.sign=function(c,u,g){var y=function(S,I){if(I<S.length+22)return console.error("Message too long for RSA"),null;for(var M=I-S.length-6,Z="",de=0;de<M;de+=2)Z+="ff";return ce("0001"+Z+"00"+S,16)}((we[g]||"")+u(c).toString(),this.n.bitLength()/4);if(y==null)return null;var w=this.doPrivate(y);if(w==null)return null;var x=w.toString(16);return 1&x.length?"0"+x:x},b.prototype.verify=function(c,u,g){var y=ce(u,16),w=this.doPublic(y);return w==null?null:function(x){for(var S in we)if(we.hasOwnProperty(S)){var I=we[S],M=I.length;if(x.substr(0,M)==I)return x.substr(M)}return x}(w.toString(16).replace(/^1f+00/,""))==g(c).toString()},b}(),we={md2:"3020300c06082a864886f70d020205000410",md5:"3020300c06082a864886f70d020505000410",sha1:"3021300906052b0e03021a05000414",sha224:"302d300d06096086480165030402040500041c",sha256:"3031300d060960864801650304020105000420",sha384:"3041300d060960864801650304020205000430",sha512:"3051300d060960864801650304020305000440",ripemd160:"3021300906052b2403020105000414"},me={};me.lang={extend:function(b,c,u){if(!c||!b)throw new Error("YAHOO.lang.extend failed, please check that all dependencies are included.");var g=function(){};if(g.prototype=c.prototype,b.prototype=new g,b.prototype.constructor=b,b.superclass=c.prototype,c.prototype.constructor==Object.prototype.constructor&&(c.prototype.constructor=c),u){var y;for(y in u)b.prototype[y]=u[y];var w=function(){},x=["toString","valueOf"];try{/MSIE/.test(navigator.userAgent)&&(w=function(S,I){for(y=0;y<x.length;y+=1){var M=x[y],Z=I[M];typeof Z=="function"&&Z!=Object.prototype[M]&&(S[M]=Z)}})}catch{}w(b.prototype,u)}}};var v={};v.asn1!==void 0&&v.asn1||(v.asn1={}),v.asn1.ASN1Util=new function(){this.integerToByteHex=function(b){var c=b.toString(16);return c.length%2==1&&(c="0"+c),c},this.bigIntToMinTwosComplementsHex=function(b){var c=b.toString(16);if(c.substr(0,1)!="-")c.length%2==1?c="0"+c:c.match(/^[0-7]/)||(c="00"+c);else{var u=c.substr(1).length;u%2==1?u+=1:c.match(/^[0-7]/)||(u+=2);for(var g="",y=0;y<u;y++)g+="f";c=new A(g,16).xor(b).add(A.ONE).toString(16).replace(/^-/,"")}return c},this.getPEMStringFromHex=function(b,c){return hextopem(b,c)},this.newObject=function(b){var c=v.asn1,u=c.DERBoolean,g=c.DERInteger,y=c.DERBitString,w=c.DEROctetString,x=c.DERNull,S=c.DERObjectIdentifier,I=c.DEREnumerated,M=c.DERUTF8String,Z=c.DERNumericString,de=c.DERPrintableString,ne=c.DERTeletexString,be=c.DERIA5String,fe=c.DERUTCTime,ue=c.DERGeneralizedTime,ye=c.DERSequence,Re=c.DERSet,D=c.DERTaggedObject,Ce=c.ASN1Util.newObject,De=Object.keys(b);if(De.length!=1)throw"key of param shall be only one.";var oe=De[0];if(":bool:int:bitstr:octstr:null:oid:enum:utf8str:numstr:prnstr:telstr:ia5str:utctime:gentime:seq:set:tag:".indexOf(":"+oe+":")==-1)throw"undefined key: "+oe;if(oe=="bool")return new u(b[oe]);if(oe=="int")return new g(b[oe]);if(oe=="bitstr")return new y(b[oe]);if(oe=="octstr")return new w(b[oe]);if(oe=="null")return new x(b[oe]);if(oe=="oid")return new S(b[oe]);if(oe=="enum")return new I(b[oe]);if(oe=="utf8str")return new M(b[oe]);if(oe=="numstr")return new Z(b[oe]);if(oe=="prnstr")return new de(b[oe]);if(oe=="telstr")return new ne(b[oe]);if(oe=="ia5str")return new be(b[oe]);if(oe=="utctime")return new fe(b[oe]);if(oe=="gentime")return new ue(b[oe]);if(oe=="seq"){for(var bt=b[oe],yt=[],ot=0;ot<bt.length;ot++){var qt=Ce(bt[ot]);yt.push(qt)}return new ye({array:yt})}if(oe=="set"){for(bt=b[oe],yt=[],ot=0;ot<bt.length;ot++)qt=Ce(bt[ot]),yt.push(qt);return new Re({array:yt})}if(oe=="tag"){var Le=b[oe];if(Object.prototype.toString.call(Le)==="[object Array]"&&Le.length==3){var Vn=Ce(Le[2]);return new D({tag:Le[0],explicit:Le[1],obj:Vn})}var Bt={};if(Le.explicit!==void 0&&(Bt.explicit=Le.explicit),Le.tag!==void 0&&(Bt.tag=Le.tag),Le.obj===void 0)throw"obj shall be specified for 'tag'.";return Bt.obj=Ce(Le.obj),new D(Bt)}},this.jsonToASN1HEX=function(b){return this.newObject(b).getEncodedHex()}},v.asn1.ASN1Util.oidHexToInt=function(b){for(var c="",u=parseInt(b.substr(0,2),16),g=(c=Math.floor(u/40)+"."+u%40,""),y=2;y<b.length;y+=2){var w=("00000000"+parseInt(b.substr(y,2),16).toString(2)).slice(-8);g+=w.substr(1,7),w.substr(0,1)=="0"&&(c=c+"."+new A(g,2).toString(10),g="")}return c},v.asn1.ASN1Util.oidIntToHex=function(b){var c=function(S){var I=S.toString(16);return I.length==1&&(I="0"+I),I},u=function(S){var I="",M=new A(S,10).toString(2),Z=7-M.length%7;Z==7&&(Z=0);for(var de="",ne=0;ne<Z;ne++)de+="0";for(M=de+M,ne=0;ne<M.length-1;ne+=7){var be=M.substr(ne,7);ne!=M.length-7&&(be="1"+be),I+=c(parseInt(be,2))}return I};if(!b.match(/^[0-9.]+$/))throw"malformed oid string: "+b;var g="",y=b.split("."),w=40*parseInt(y[0])+parseInt(y[1]);g+=c(w),y.splice(0,2);for(var x=0;x<y.length;x++)g+=u(y[x]);return g},v.asn1.ASN1Object=function(){this.getLengthHexFromValue=function(){if(this.hV===void 0||this.hV==null)throw"this.hV is null or undefined.";if(this.hV.length%2==1)throw"value hex must be even length: n=0,v="+this.hV;var b=this.hV.length/2,c=b.toString(16);if(c.length%2==1&&(c="0"+c),b<128)return c;var u=c.length/2;if(u>15)throw"ASN.1 length too long to represent by 8x: n = "+b.toString(16);return(128+u).toString(16)+c},this.getEncodedHex=function(){return(this.hTLV==null||this.isModified)&&(this.hV=this.getFreshValueHex(),this.hL=this.getLengthHexFromValue(),this.hTLV=this.hT+this.hL+this.hV,this.isModified=!1),this.hTLV},this.getValueHex=function(){return this.getEncodedHex(),this.hV},this.getFreshValueHex=function(){return""}},v.asn1.DERAbstractString=function(b){v.asn1.DERAbstractString.superclass.constructor.call(this),this.getString=function(){return this.s},this.setString=function(c){this.hTLV=null,this.isModified=!0,this.s=c,this.hV=stohex(this.s)},this.setStringHex=function(c){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=c},this.getFreshValueHex=function(){return this.hV},b!==void 0&&(typeof b=="string"?this.setString(b):b.str!==void 0?this.setString(b.str):b.hex!==void 0&&this.setStringHex(b.hex))},me.lang.extend(v.asn1.DERAbstractString,v.asn1.ASN1Object),v.asn1.DERAbstractTime=function(b){v.asn1.DERAbstractTime.superclass.constructor.call(this),this.localDateToUTC=function(c){return utc=c.getTime()+6e4*c.getTimezoneOffset(),new Date(utc)},this.formatDate=function(c,u,g){var y=this.zeroPadding,w=this.localDateToUTC(c),x=String(w.getFullYear());u=="utc"&&(x=x.substr(2,2));var S=x+y(String(w.getMonth()+1),2)+y(String(w.getDate()),2)+y(String(w.getHours()),2)+y(String(w.getMinutes()),2)+y(String(w.getSeconds()),2);if(g===!0){var I=w.getMilliseconds();if(I!=0){var M=y(String(I),3);S=S+"."+(M=M.replace(/[0]+$/,""))}}return S+"Z"},this.zeroPadding=function(c,u){return c.length>=u?c:new Array(u-c.length+1).join("0")+c},this.getString=function(){return this.s},this.setString=function(c){this.hTLV=null,this.isModified=!0,this.s=c,this.hV=stohex(c)},this.setByDateValue=function(c,u,g,y,w,x){var S=new Date(Date.UTC(c,u-1,g,y,w,x,0));this.setByDate(S)},this.getFreshValueHex=function(){return this.hV}},me.lang.extend(v.asn1.DERAbstractTime,v.asn1.ASN1Object),v.asn1.DERAbstractStructured=function(b){v.asn1.DERAbstractString.superclass.constructor.call(this),this.setByASN1ObjectArray=function(c){this.hTLV=null,this.isModified=!0,this.asn1Array=c},this.appendASN1Object=function(c){this.hTLV=null,this.isModified=!0,this.asn1Array.push(c)},this.asn1Array=new Array,b!==void 0&&b.array!==void 0&&(this.asn1Array=b.array)},me.lang.extend(v.asn1.DERAbstractStructured,v.asn1.ASN1Object),v.asn1.DERBoolean=function(){v.asn1.DERBoolean.superclass.constructor.call(this),this.hT="01",this.hTLV="0101ff"},me.lang.extend(v.asn1.DERBoolean,v.asn1.ASN1Object),v.asn1.DERInteger=function(b){v.asn1.DERInteger.superclass.constructor.call(this),this.hT="02",this.setByBigInteger=function(c){this.hTLV=null,this.isModified=!0,this.hV=v.asn1.ASN1Util.bigIntToMinTwosComplementsHex(c)},this.setByInteger=function(c){var u=new A(String(c),10);this.setByBigInteger(u)},this.setValueHex=function(c){this.hV=c},this.getFreshValueHex=function(){return this.hV},b!==void 0&&(b.bigint!==void 0?this.setByBigInteger(b.bigint):b.int!==void 0?this.setByInteger(b.int):typeof b=="number"?this.setByInteger(b):b.hex!==void 0&&this.setValueHex(b.hex))},me.lang.extend(v.asn1.DERInteger,v.asn1.ASN1Object),v.asn1.DERBitString=function(b){if(b!==void 0&&b.obj!==void 0){var c=v.asn1.ASN1Util.newObject(b.obj);b.hex="00"+c.getEncodedHex()}v.asn1.DERBitString.superclass.constructor.call(this),this.hT="03",this.setHexValueIncludingUnusedBits=function(u){this.hTLV=null,this.isModified=!0,this.hV=u},this.setUnusedBitsAndHexValue=function(u,g){if(u<0||7<u)throw"unused bits shall be from 0 to 7: u = "+u;var y="0"+u;this.hTLV=null,this.isModified=!0,this.hV=y+g},this.setByBinaryString=function(u){var g=8-(u=u.replace(/0+$/,"")).length%8;g==8&&(g=0);for(var y=0;y<=g;y++)u+="0";var w="";for(y=0;y<u.length-1;y+=8){var x=u.substr(y,8),S=parseInt(x,2).toString(16);S.length==1&&(S="0"+S),w+=S}this.hTLV=null,this.isModified=!0,this.hV="0"+g+w},this.setByBooleanArray=function(u){for(var g="",y=0;y<u.length;y++)u[y]==1?g+="1":g+="0";this.setByBinaryString(g)},this.newFalseArray=function(u){for(var g=new Array(u),y=0;y<u;y++)g[y]=!1;return g},this.getFreshValueHex=function(){return this.hV},b!==void 0&&(typeof b=="string"&&b.toLowerCase().match(/^[0-9a-f]+$/)?this.setHexValueIncludingUnusedBits(b):b.hex!==void 0?this.setHexValueIncludingUnusedBits(b.hex):b.bin!==void 0?this.setByBinaryString(b.bin):b.array!==void 0&&this.setByBooleanArray(b.array))},me.lang.extend(v.asn1.DERBitString,v.asn1.ASN1Object),v.asn1.DEROctetString=function(b){if(b!==void 0&&b.obj!==void 0){var c=v.asn1.ASN1Util.newObject(b.obj);b.hex=c.getEncodedHex()}v.asn1.DEROctetString.superclass.constructor.call(this,b),this.hT="04"},me.lang.extend(v.asn1.DEROctetString,v.asn1.DERAbstractString),v.asn1.DERNull=function(){v.asn1.DERNull.superclass.constructor.call(this),this.hT="05",this.hTLV="0500"},me.lang.extend(v.asn1.DERNull,v.asn1.ASN1Object),v.asn1.DERObjectIdentifier=function(b){var c=function(g){var y=g.toString(16);return y.length==1&&(y="0"+y),y},u=function(g){var y="",w=new A(g,10).toString(2),x=7-w.length%7;x==7&&(x=0);for(var S="",I=0;I<x;I++)S+="0";for(w=S+w,I=0;I<w.length-1;I+=7){var M=w.substr(I,7);I!=w.length-7&&(M="1"+M),y+=c(parseInt(M,2))}return y};v.asn1.DERObjectIdentifier.superclass.constructor.call(this),this.hT="06",this.setValueHex=function(g){this.hTLV=null,this.isModified=!0,this.s=null,this.hV=g},this.setValueOidString=function(g){if(!g.match(/^[0-9.]+$/))throw"malformed oid string: "+g;var y="",w=g.split("."),x=40*parseInt(w[0])+parseInt(w[1]);y+=c(x),w.splice(0,2);for(var S=0;S<w.length;S++)y+=u(w[S]);this.hTLV=null,this.isModified=!0,this.s=null,this.hV=y},this.setValueName=function(g){var y=v.asn1.x509.OID.name2oid(g);if(y==="")throw"DERObjectIdentifier oidName undefined: "+g;this.setValueOidString(y)},this.getFreshValueHex=function(){return this.hV},b!==void 0&&(typeof b=="string"?b.match(/^[0-2].[0-9.]+$/)?this.setValueOidString(b):this.setValueName(b):b.oid!==void 0?this.setValueOidString(b.oid):b.hex!==void 0?this.setValueHex(b.hex):b.name!==void 0&&this.setValueName(b.name))},me.lang.extend(v.asn1.DERObjectIdentifier,v.asn1.ASN1Object),v.asn1.DEREnumerated=function(b){v.asn1.DEREnumerated.superclass.constructor.call(this),this.hT="0a",this.setByBigInteger=function(c){this.hTLV=null,this.isModified=!0,this.hV=v.asn1.ASN1Util.bigIntToMinTwosComplementsHex(c)},this.setByInteger=function(c){var u=new A(String(c),10);this.setByBigInteger(u)},this.setValueHex=function(c){this.hV=c},this.getFreshValueHex=function(){return this.hV},b!==void 0&&(b.int!==void 0?this.setByInteger(b.int):typeof b=="number"?this.setByInteger(b):b.hex!==void 0&&this.setValueHex(b.hex))},me.lang.extend(v.asn1.DEREnumerated,v.asn1.ASN1Object),v.asn1.DERUTF8String=function(b){v.asn1.DERUTF8String.superclass.constructor.call(this,b),this.hT="0c"},me.lang.extend(v.asn1.DERUTF8String,v.asn1.DERAbstractString),v.asn1.DERNumericString=function(b){v.asn1.DERNumericString.superclass.constructor.call(this,b),this.hT="12"},me.lang.extend(v.asn1.DERNumericString,v.asn1.DERAbstractString),v.asn1.DERPrintableString=function(b){v.asn1.DERPrintableString.superclass.constructor.call(this,b),this.hT="13"},me.lang.extend(v.asn1.DERPrintableString,v.asn1.DERAbstractString),v.asn1.DERTeletexString=function(b){v.asn1.DERTeletexString.superclass.constructor.call(this,b),this.hT="14"},me.lang.extend(v.asn1.DERTeletexString,v.asn1.DERAbstractString),v.asn1.DERIA5String=function(b){v.asn1.DERIA5String.superclass.constructor.call(this,b),this.hT="16"},me.lang.extend(v.asn1.DERIA5String,v.asn1.DERAbstractString),v.asn1.DERUTCTime=function(b){v.asn1.DERUTCTime.superclass.constructor.call(this,b),this.hT="17",this.setByDate=function(c){this.hTLV=null,this.isModified=!0,this.date=c,this.s=this.formatDate(this.date,"utc"),this.hV=stohex(this.s)},this.getFreshValueHex=function(){return this.date===void 0&&this.s===void 0&&(this.date=new Date,this.s=this.formatDate(this.date,"utc"),this.hV=stohex(this.s)),this.hV},b!==void 0&&(b.str!==void 0?this.setString(b.str):typeof b=="string"&&b.match(/^[0-9]{12}Z$/)?this.setString(b):b.hex!==void 0?this.setStringHex(b.hex):b.date!==void 0&&this.setByDate(b.date))},me.lang.extend(v.asn1.DERUTCTime,v.asn1.DERAbstractTime),v.asn1.DERGeneralizedTime=function(b){v.asn1.DERGeneralizedTime.superclass.constructor.call(this,b),this.hT="18",this.withMillis=!1,this.setByDate=function(c){this.hTLV=null,this.isModified=!0,this.date=c,this.s=this.formatDate(this.date,"gen",this.withMillis),this.hV=stohex(this.s)},this.getFreshValueHex=function(){return this.date===void 0&&this.s===void 0&&(this.date=new Date,this.s=this.formatDate(this.date,"gen",this.withMillis),this.hV=stohex(this.s)),this.hV},b!==void 0&&(b.str!==void 0?this.setString(b.str):typeof b=="string"&&b.match(/^[0-9]{14}Z$/)?this.setString(b):b.hex!==void 0?this.setStringHex(b.hex):b.date!==void 0&&this.setByDate(b.date),b.millis===!0&&(this.withMillis=!0))},me.lang.extend(v.asn1.DERGeneralizedTime,v.asn1.DERAbstractTime),v.asn1.DERSequence=function(b){v.asn1.DERSequence.superclass.constructor.call(this,b),this.hT="30",this.getFreshValueHex=function(){for(var c="",u=0;u<this.asn1Array.length;u++)c+=this.asn1Array[u].getEncodedHex();return this.hV=c,this.hV}},me.lang.extend(v.asn1.DERSequence,v.asn1.DERAbstractStructured),v.asn1.DERSet=function(b){v.asn1.DERSet.superclass.constructor.call(this,b),this.hT="31",this.sortFlag=!0,this.getFreshValueHex=function(){for(var c=new Array,u=0;u<this.asn1Array.length;u++){var g=this.asn1Array[u];c.push(g.getEncodedHex())}return this.sortFlag==1&&c.sort(),this.hV=c.join(""),this.hV},b!==void 0&&b.sortflag!==void 0&&b.sortflag==0&&(this.sortFlag=!1)},me.lang.extend(v.asn1.DERSet,v.asn1.DERAbstractStructured),v.asn1.DERTaggedObject=function(b){v.asn1.DERTaggedObject.superclass.constructor.call(this),this.hT="a0",this.hV="",this.isExplicit=!0,this.asn1Object=null,this.setASN1Object=function(c,u,g){this.hT=u,this.isExplicit=c,this.asn1Object=g,this.isExplicit?(this.hV=this.asn1Object.getEncodedHex(),this.hTLV=null,this.isModified=!0):(this.hV=null,this.hTLV=g.getEncodedHex(),this.hTLV=this.hTLV.replace(/^../,u),this.isModified=!1)},this.getFreshValueHex=function(){return this.hV},b!==void 0&&(b.tag!==void 0&&(this.hT=b.tag),b.explicit!==void 0&&(this.isExplicit=b.explicit),b.obj!==void 0&&(this.asn1Object=b.obj,this.setASN1Object(this.isExplicit,this.hT,this.asn1Object)))},me.lang.extend(v.asn1.DERTaggedObject,v.asn1.ASN1Object);var Ye,Ze,Pe=(Ye=function(b,c){return Ye=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,g){u.__proto__=g}||function(u,g){for(var y in g)Object.prototype.hasOwnProperty.call(g,y)&&(u[y]=g[y])},Ye(b,c)},function(b,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");function u(){this.constructor=b}Ye(b,c),b.prototype=c===null?Object.create(c):(u.prototype=c.prototype,new u)}),Xe=function(b){function c(u){var g=b.call(this)||this;return u&&(typeof u=="string"?g.parseKey(u):(c.hasPrivateKeyProperty(u)||c.hasPublicKeyProperty(u))&&g.parsePropertiesFrom(u)),g}return Pe(c,b),c.prototype.parseKey=function(u){try{var g=0,y=0,w=/^\s*(?:[0-9A-Fa-f][0-9A-Fa-f]\s*)+$/.test(u)?function(fe){var ue;if(k===void 0){var ye="0123456789ABCDEF",Re=` \f
8
+ \r  \u2028\u2029`;for(k={},ue=0;ue<16;++ue)k[ye.charAt(ue)]=ue;for(ye=ye.toLowerCase(),ue=10;ue<16;++ue)k[ye.charAt(ue)]=ue;for(ue=0;ue<Re.length;++ue)k[Re.charAt(ue)]=-1}var D=[],Ce=0,De=0;for(ue=0;ue<fe.length;++ue){var oe=fe.charAt(ue);if(oe=="=")break;if((oe=k[oe])!=-1){if(oe===void 0)throw new Error("Illegal character at offset "+ue);Ce|=oe,++De>=2?(D[D.length]=Ce,Ce=0,De=0):Ce<<=4}}if(De)throw new Error("Hex encoding incomplete: 4 bits missing");return D}(u):j.unarmor(u),x=ie.decode(w);if(x.sub.length===3&&(x=x.sub[2].sub[0]),x.sub.length===9){g=x.sub[1].getHexStringValue(),this.n=ce(g,16),y=x.sub[2].getHexStringValue(),this.e=parseInt(y,16);var S=x.sub[3].getHexStringValue();this.d=ce(S,16);var I=x.sub[4].getHexStringValue();this.p=ce(I,16);var M=x.sub[5].getHexStringValue();this.q=ce(M,16);var Z=x.sub[6].getHexStringValue();this.dmp1=ce(Z,16);var de=x.sub[7].getHexStringValue();this.dmq1=ce(de,16);var ne=x.sub[8].getHexStringValue();this.coeff=ce(ne,16)}else{if(x.sub.length!==2)return!1;if(x.sub[0].sub){var be=x.sub[1].sub[0];g=be.sub[0].getHexStringValue(),this.n=ce(g,16),y=be.sub[1].getHexStringValue(),this.e=parseInt(y,16)}else g=x.sub[0].getHexStringValue(),this.n=ce(g,16),y=x.sub[1].getHexStringValue(),this.e=parseInt(y,16)}return!0}catch{return!1}},c.prototype.getPrivateBaseKey=function(){var u={array:[new v.asn1.DERInteger({int:0}),new v.asn1.DERInteger({bigint:this.n}),new v.asn1.DERInteger({int:this.e}),new v.asn1.DERInteger({bigint:this.d}),new v.asn1.DERInteger({bigint:this.p}),new v.asn1.DERInteger({bigint:this.q}),new v.asn1.DERInteger({bigint:this.dmp1}),new v.asn1.DERInteger({bigint:this.dmq1}),new v.asn1.DERInteger({bigint:this.coeff})]};return new v.asn1.DERSequence(u).getEncodedHex()},c.prototype.getPrivateBaseKeyB64=function(){return q(this.getPrivateBaseKey())},c.prototype.getPublicBaseKey=function(){var u=new v.asn1.DERSequence({array:[new v.asn1.DERObjectIdentifier({oid:"1.2.840.113549.1.1.1"}),new v.asn1.DERNull]}),g=new v.asn1.DERSequence({array:[new v.asn1.DERInteger({bigint:this.n}),new v.asn1.DERInteger({int:this.e})]}),y=new v.asn1.DERBitString({hex:"00"+g.getEncodedHex()});return new v.asn1.DERSequence({array:[u,y]}).getEncodedHex()},c.prototype.getPublicBaseKeyB64=function(){return q(this.getPublicBaseKey())},c.wordwrap=function(u,g){if(!u)return u;var y="(.{1,"+(g=g||64)+`})( +|$
9
9
  ?)|(.{1,`+g+"})";return u.match(RegExp(y,"g")).join(`
10
10
  `)},c.prototype.getPrivateKey=function(){var u=`-----BEGIN RSA PRIVATE KEY-----
11
11
  `;return(u+=c.wordwrap(this.getPrivateBaseKeyB64())+`
12
12
  `)+"-----END RSA PRIVATE KEY-----"},c.prototype.getPublicKey=function(){var u=`-----BEGIN PUBLIC KEY-----
13
13
  `;return(u+=c.wordwrap(this.getPublicBaseKeyB64())+`
14
- `)+"-----END PUBLIC KEY-----"},c.hasPublicKeyProperty=function(u){return(u=u||{}).hasOwnProperty("n")&&u.hasOwnProperty("e")},c.hasPrivateKeyProperty=function(u){return(u=u||{}).hasOwnProperty("n")&&u.hasOwnProperty("e")&&u.hasOwnProperty("d")&&u.hasOwnProperty("p")&&u.hasOwnProperty("q")&&u.hasOwnProperty("dmp1")&&u.hasOwnProperty("dmq1")&&u.hasOwnProperty("coeff")},c.prototype.parsePropertiesFrom=function(u){this.n=u.n,this.e=u.e,u.hasOwnProperty("d")&&(this.d=u.d,this.p=u.p,this.q=u.q,this.dmp1=u.dmp1,this.dmq1=u.dmq1,this.coeff=u.coeff)},c}(Fe),Qe=r(155),ut=Qe!==void 0?(Ze=Qe.env)===null||Ze===void 0?void 0:"3.3.2":void 0;const nt=function(){function b(c){c===void 0&&(c={}),c=c||{},this.default_key_size=c.default_key_size?parseInt(c.default_key_size,10):1024,this.default_public_exponent=c.default_public_exponent||"010001",this.log=c.log||!1,this.key=null}return b.prototype.setKey=function(c){this.log&&this.key&&console.warn("A key was already set, overriding existing."),this.key=new Xe(c)},b.prototype.setPrivateKey=function(c){this.setKey(c)},b.prototype.setPublicKey=function(c){this.setKey(c)},b.prototype.decrypt=function(c){try{return this.getKey().decrypt(F(c))}catch{return!1}},b.prototype.encrypt=function(c){try{return q(this.getKey().encrypt(c))}catch{return!1}},b.prototype.sign=function(c,u,g){try{return q(this.getKey().sign(c,u,g))}catch{return!1}},b.prototype.verify=function(c,u,g){try{return this.getKey().verify(c,F(u),g)}catch{return!1}},b.prototype.getKey=function(c){if(!this.key){if(this.key=new Xe,c&&{}.toString.call(c)==="[object Function]")return void this.key.generateAsync(this.default_key_size,this.default_public_exponent,c);this.key.generate(this.default_key_size,this.default_public_exponent)}return this.key},b.prototype.getPrivateKey=function(){return this.getKey().getPrivateKey()},b.prototype.getPrivateKeyB64=function(){return this.getKey().getPrivateBaseKeyB64()},b.prototype.getPublicKey=function(){return this.getKey().getPublicKey()},b.prototype.getPublicKeyB64=function(){return this.getKey().getPublicBaseKeyB64()},b.version=ut,b}()})(),l.default})())})(Wi);var Ug=Wi.exports;const jg=$i(Ug),zg="/static/images/logo1.svg",Hg="/static/images/register.svg",Kg="/static/images/login.svg",Gg={name:"lwLogin",props:{isInitialized:{type:Boolean,default:!0},isCombined:{type:Boolean,default:!0},isEncryption:{type:Boolean,default:!0}},components:{Lang:Gi},data(){return{isRegistered:!1,ruleForm:{user:"",password:"",role:0,autologin:!1},registForm:{},rules:{user:[{required:!0,message:this.t("loginPage.userError"),trigger:"blur"}],password:[{required:!0,message:this.t("loginPage.PWError"),trigger:"blur"}],name:[{required:!0,message:this.t("loginPage.enterTitle"),trigger:"blur"}],phone:[{required:!0,message:this.t("loginPage.enterPhone"),trigger:"blur"},{pattern:/^[1]([3-9])[0-9]{9}$/,message:this.t("loginPage.correctPhone"),trigger:"blur"}],company:[{required:!0,message:this.t("loginPage.enterCompany"),trigger:"blur"}],position:[{required:!0,message:this.t("loginPage.selectPosition"),trigger:"change"}],description:[{required:!0,message:this.t("loginPage.selectPurpose"),trigger:"change"}]},optionsDescription:[{name:this.t("purposes.findSolution"),id:"1"},{name:this.t("purposes.compareProducts"),id:"2"},{name:this.t("purposes.other"),id:"3"}],optionsCompany:[{name:this.t("positions.techStaff"),id:"1"},{name:this.t("positions.businessStaff"),id:"2"},{name:this.t("positions.researchStaff"),id:"3"},{name:this.t("positions.marketingStaff"),id:"4"},{name:this.t("positions.operationStaff"),id:"5"},{name:this.t("positions.otherStaff"),id:"6"}],islogin:!1}},created:function(){this.$store.commit("clearViewTags"),this.$store.commit("clearKeepLive"),this.$store.commit("clearIframeList")},methods:{encrypt(t,n){const o=new jg;return o.setPublicKey(t),o.encrypt(n)},async login(){if(!await this.$refs.loginForm.validate().catch(()=>{}))return!1;let n={username:this.ruleForm.user,password:this.ruleForm.password};if(this.isEncryption){const s=await this.$api.auth.key();n={username:this.encrypt(s,this.ruleForm.user),password:this.encrypt(s,this.ruleForm.password)}}let o=await this.$api.auth.token(n);this.$tool.data.set("TOKEN",o),this.islogin=!0;let a=await this.$api.auth.bu();this.$tool.data.set("buList",a);let r=this.$tool.data.get("buCode");a.find(s=>s.code==r)||this.$tool.data.set("buCode",a[0].code);let i=await this.$api.auth.user();if(this.$tool.data.set("tenantId",i.userAuthInfo.tenantId),this.$tool.data.set("userAuthInfo",i.userAuthInfo),this.$tool.data.set("MenuPath",i.userAuthInfo.grantedApplications),this.$store.state.user=i.userAuthInfo,sessionStorage.setItem("easyweb_session_passport_current_user",JSON.stringify({v:i})),sessionStorage.setItem("easyweb_session_passport_bu",JSON.stringify({v:a[0]})),sessionStorage.setItem("easyweb_session_passport_bu_list",JSON.stringify({v:a})),document.cookie=`Authorization=Bearer ${o}`,i.combined||this.isCombined){let s=await this.$api.auth.menu();this.$tool.data.set("MENUCOMBINED",s),this.$tool.data.set("MENUCOMBINEDNMAE",this.$config.APP_NAME)}else this.$tool.data.remove("MENUCOMBINED"),this.$tool.data.remove("MENUCOMBINEDNMAE");if(this.isInitialized){let s=await this.$api.auth.initialized();this.$tool.data.set("zoneInitialized",s),s?this.$router.push(this.$config.DASHBOARD_URL):this.$router.push(this.$config.INIT_URL)}else this.$router.push(this.$config.DASHBOARD_URL);this.$message.success(this.t("loginPage.loginSuccess")),this.islogin=!1},async apply(){if(!await this.$refs.registForm.validate().catch(()=>{}))return!1;await this.$api.auth.apply(this.registForm),this.$message.success(this.t("loginPage.applySuccess"))}}},Yg={class:"login_bg"},$g={class:"video-container"},Wg={class:"img",src:Hg},Jg={class:"img",src:Kg},Zg={class:"login_main"},Xg={class:"login_registered"},Qg={class:"login-form"},eb={class:"title-name"},tb={class:"login_config"},nb={class:"login-form"},ob={class:"title-name"};function rb(t,n,o,a,r,l){const i=e.resolveComponent("el-button"),s=e.resolveComponent("el-form-item"),d=e.resolveComponent("el-input"),f=e.resolveComponent("el-option"),p=e.resolveComponent("el-select"),m=e.resolveComponent("el-form"),_=e.resolveComponent("Lang"),C=e.resolveComponent("el-checkbox"),k=e.resolveComponent("el-col"),S=e.resolveComponent("el-row");return e.openBlock(),e.createElementBlock("div",Yg,[e.createElementVNode("div",$g,[e.renderSlot(t.$slots,"logo",{},()=>[n[10]||(n[10]=e.createElementVNode("img",{class:"logo",src:zg},null,-1))],!0),e.renderSlot(t.$slots,"registerBg",{},()=>[e.withDirectives(e.createElementVNode("img",Wg,null,512),[[e.vShow,r.isRegistered]])],!0),e.renderSlot(t.$slots,"loginBg",{},()=>[e.withDirectives(e.createElementVNode("img",Jg,null,512),[[e.vShow,!r.isRegistered]])],!0)]),e.createElementVNode("div",Zg,[r.isRegistered?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("div",Xg,[e.createVNode(i,{type:"primary",link:"",onClick:n[0]||(n[0]=B=>r.isRegistered=!1)},{default:e.withCtx(()=>n[11]||(n[11]=[e.createElementVNode("i",{class:"iconfont icon-quit"},null,-1)])),_:1})]),e.createElementVNode("div",Qg,[e.createVNode(m,{ref:"registForm",class:"form-body",model:r.registForm,rules:r.rules,"label-width":"0",size:"large"},{default:e.withCtx(()=>[e.createVNode(s,null,{default:e.withCtx(()=>[e.createElementVNode("div",eb,[e.renderSlot(t.$slots,"titleRegister",{},()=>[e.createTextVNode(e.toDisplayString(t.$t("loginPage.trialRequest")),1)],!0)])]),_:3}),e.createVNode(s,{prop:"name"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:r.registForm.name,"onUpdate:modelValue":n[1]||(n[1]=B=>r.registForm.name=B),"prefix-icon":"el-icon-user",clearable:"",placeholder:t.$t("loginPage.enterTitle")},null,8,["modelValue","placeholder"])]),_:1}),e.createVNode(s,{prop:"phone"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:r.registForm.phone,"onUpdate:modelValue":n[2]||(n[2]=B=>r.registForm.phone=B),"prefix-icon":"el-icon-iphone",clearable:"",maxlength:"11",placeholder:t.$t("loginPage.enterPhone")},null,8,["modelValue","placeholder"])]),_:1}),e.createVNode(s,{prop:"company"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:r.registForm.company,"onUpdate:modelValue":n[3]||(n[3]=B=>r.registForm.company=B),"prefix-icon":"el-icon-office-building",clearable:"",placeholder:t.$t("loginPage.enterCompany")},null,8,["modelValue","placeholder"])]),_:1}),e.createVNode(s,{prop:"position"},{default:e.withCtx(()=>[e.createVNode(p,{modelValue:r.registForm.position,"onUpdate:modelValue":n[4]||(n[4]=B=>r.registForm.position=B),placeholder:t.$t("loginPage.selectPosition")},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.optionsCompany,B=>(e.openBlock(),e.createBlock(f,{key:B.id,label:B.name,value:B.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue","placeholder"])]),_:1}),e.createVNode(s,{prop:"description"},{default:e.withCtx(()=>[e.createVNode(p,{modelValue:r.registForm.description,"onUpdate:modelValue":n[5]||(n[5]=B=>r.registForm.description=B),placeholder:t.$t("loginPage.selectPurpose")},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.optionsDescription,B=>(e.openBlock(),e.createBlock(f,{key:B.id,label:B.name,value:B.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue","placeholder"])]),_:1}),e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i,{type:"primary",style:{width:"100%"},loading:r.islogin,onClick:l.apply},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("loginPage.trialRequest")),1)]),_:1},8,["loading","onClick"])]),_:1})]),_:3},8,["model","rules"])])],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",tb,[e.createVNode(_)]),e.createElementVNode("div",nb,[e.createVNode(m,{ref:"loginForm",class:"form-body",model:r.ruleForm,rules:r.rules,"label-width":"0",size:"large"},{default:e.withCtx(()=>[e.createVNode(s,null,{default:e.withCtx(()=>[e.createElementVNode("div",ob,[e.renderSlot(t.$slots,"title",{},()=>[e.createTextVNode(e.toDisplayString(t.$t("loginPage.accountLogin")),1)],!0)])]),_:3}),e.createVNode(s,{prop:"user"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:r.ruleForm.user,"onUpdate:modelValue":n[6]||(n[6]=B=>r.ruleForm.user=B),"prefix-icon":"el-icon-user",clearable:"",placeholder:t.$t("loginPage.userPlaceholder")},null,8,["modelValue","placeholder"])]),_:1}),e.createVNode(s,{prop:"password"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:r.ruleForm.password,"onUpdate:modelValue":n[7]||(n[7]=B=>r.ruleForm.password=B),"prefix-icon":"el-icon-lock",clearable:"","show-password":"",placeholder:t.$t("loginPage.PWPlaceholder")},null,8,["modelValue","placeholder"])]),_:1}),e.createVNode(s,{style:{"margin-bottom":"10px"}},{default:e.withCtx(()=>[e.createVNode(S,null,{default:e.withCtx(()=>[e.createVNode(k,{span:12},{default:e.withCtx(()=>[e.createVNode(C,{label:t.$t("loginPage.rememberMe"),modelValue:r.ruleForm.autologin,"onUpdate:modelValue":n[8]||(n[8]=B=>r.ruleForm.autologin=B)},null,8,["label","modelValue"])]),_:1}),e.createVNode(k,{span:12,style:{"text-align":"right"}},{default:e.withCtx(()=>[e.createVNode(i,{type:"primary",text:""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("loginPage.forgetPassword"))+"? ",1)]),_:1})]),_:1})]),_:1})]),_:1}),e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i,{type:"primary",style:{width:"100%"},loading:r.islogin,onClick:l.login},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("loginPage.signIn")),1)]),_:1},8,["loading","onClick"])]),_:1}),e.createVNode(s,null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("loginPage.noAccount"))+" ",1),e.createVNode(i,{type:"primary",link:"",onClick:n[9]||(n[9]=B=>r.isRegistered=!0)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("loginPage.trialRequest")),1)]),_:1})]),_:1})]),_:3},8,["model","rules"])])],64))])])}const Ji=le(Gg,[["render",rb],["__scopeId","data-v-45056e2f"]]),ab={emits:["update:modelValue","change"],name:"Input",props:{disabled:{type:Boolean,default:!1},modelValue:{type:[String,Number],default:""},item:{type:Object,default:()=>({})}},data(){return{value:this.modelValue}},watch:{modelValue(t){this.value=t},value(t){(this.item.filter??!1)&&(t=t.replace(/ /g,",").replace(/\,/g,",").replace(/\,/g,",").replace(/\n/g,",")),this.$emit("update:modelValue",t),this.$emit("change",t)}}};function lb(t,n,o,a,r,l){const i=e.resolveComponent("el-input");return e.openBlock(),e.createElementBlock("div",null,[e.createVNode(i,{type:o.item.type||"text",disabled:o.item.disabled,placeholder:o.item.label||t.$t("lwSearch.please_input"),maxlength:o.item.maxlength,minlength:o.item.minlength,"show-word-limit":o.item.showWordLimit,autosize:o.item.autosize||{minRows:2},"allow-clear":"",clearable:"",modelValue:r.value,"onUpdate:modelValue":n[0]||(n[0]=s=>r.value=s)},null,8,["type","disabled","placeholder","maxlength","minlength","show-word-limit","autosize","modelValue"])])}const ib=le(ab,[["render",lb]]),sb={name:"Select",props:{disabled:{type:Boolean,default:!1},modelValue:{type:[String,Number,Boolean,Object],default:""},item:{type:Object,default:()=>({})}},data(){return{value:this.modelValue}},watch:{modelValue(t){this.value=t},value(t){this.$emit("update:modelValue",t),this.$emit("change",t),this.callback(t,this.item)}},methods:{callback(t,n){n.callback&&n.callback(t)}}};function cb(t,n,o,a,r,l){const i=e.resolveComponent("el-tooltip"),s=e.resolveComponent("el-option"),d=e.resolveComponent("el-select");return e.openBlock(),e.createElementBlock("div",null,[e.createVNode(d,{disabled:o.item.disabled,placeholder:o.item.label||"请选择","popper-append-to-body":o.item.appendToBody,modelValue:r.value,"onUpdate:modelValue":n[0]||(n[0]=f=>r.value=f),clearable:"",filterable:"",multiple:o.item.multiple,"collapse-tags":"","allow-search":"",size:"",style:{width:"100%"}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.item.options,(f,p)=>(e.openBlock(),e.createBlock(s,{disabled:f.disabled,key:o.item.key?o.item.key:o.item.valueKey?f[o.item.valueKey]+f[o.item.labelKey]+p:f.code+f.name+p,label:o.item.isCodeAndName?(o.item.valueKey?f[o.item.valueKey]:f.code)+" - "+(o.item.labelKey?f[o.item.labelKey]:f.name):o.item.labelKey?f[o.item.labelKey]:f.name,value:o.item.valueKey?f[o.item.valueKey]:f.code},{default:e.withCtx(()=>[e.createVNode(i,{content:o.item.isCodeAndName?(o.item.valueKey?f[o.item.valueKey]:f.code)+" - "+(o.item.labelKey?f[o.item.labelKey]:f.name):o.item.labelKey?f[o.item.labelKey]:f.name},{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(o.item.isCodeAndName?(o.item.valueKey?f[o.item.valueKey]:f.code)+" - "+(o.item.labelKey?f[o.item.labelKey]:f.name):o.item.labelKey?f[o.item.labelKey]:f.name),1)]),_:2},1032,["content"])]),_:2},1032,["disabled","label","value"]))),128))]),_:1},8,["disabled","placeholder","popper-append-to-body","modelValue","multiple"])])}const db=le(sb,[["render",cb]]),ub={emits:["update:modelValue","change"],name:"Date",props:{disabled:{type:Boolean,default(){return!1}},modelValue:{default(){return""}},item:{type:Object,default(){return{}}},disabledDate:{type:Function,default(){return null}},propValueFormat:{type:String,default(){return null}}},setup(t,n){const o=e.reactive({}),a=e.computed(()=>t.propValueFormat?t.propValueFormat:t.item.valueFormat?t.item.valueFormat:t.item.dateSection||t.item.withZero?"YYYY-MM-DD 00:00:00":t.item.withLast?"YYYY-MM-DD 23:59:59":"YYYY-MM-DD"),r=e.computed({get(){return t.modelValue},set(l){n.emit("update:modelValue",l),n.emit("change",l)}});return{...e.toRefs(o),valueFormat:a,value:r}}};function hb(t,n,o,a,r,l){const i=e.resolveComponent("el-date-picker");return e.openBlock(),e.createElementBlock("div",null,[e.createVNode(i,{type:o.item.type||"date",disabled:o.item.disabled,format:o.item.format||"YYYY-MM-DD","value-format":o.item.valueFormat,placeholder:o.item.placeholder||t.$t("lwSearch.please_select"),"range-separator":o.item.rangeSeparator||t.$t("lwSearch.monthRange.rangeSeparator"),"start-placeholder":o.item.startPlaceholder||t.$t("lwSearch.monthRange.startPlaceholder"),"end-placeholder":o.item.endPlaceholder||t.$t("lwSearch.monthRange.endPlaceholder"),clearable:"",modelValue:a.value,"onUpdate:modelValue":n[0]||(n[0]=s=>a.value=s),"disabled-date":o.disabledDate,style:{width:"100%"}},null,8,["type","disabled","format","value-format","placeholder","range-separator","start-placeholder","end-placeholder","modelValue","disabled-date"])])}const fb=le(ub,[["render",hb]]),pb={emits:["update:modelValue","change"],name:"Date",props:{disabled:{type:Boolean,default:!1},modelValue:{type:[String,Array],default:""},item:{type:Object,default:()=>({})}},setup(t,n){const o=e.reactive({isSidebarShow:!1,activeName:"single",isPanelShow:!1,value:[],shortcuts:[{text:"",value:""}]});e.watch(()=>t.modelValue,p=>{p?(o.activeName=Array.isArray(p)?"range":"single",o.value=Array.isArray(p)?p:p.split(",")):o.value=[]},{deep:!0}),e.watch(()=>o.value,p=>{const m=o.activeName==="single"?p.join(","):p;m!==t.modelValue&&(n.emit("update:modelValue",m),n.emit("change",m))},{deep:!0,immediate:!0});const a=e.computed(()=>o.value.join(",")),r=()=>{o.isPanelShow=!o.isPanelShow},l=()=>{e.nextTick(()=>{o.isSidebarShow=!0})},i=()=>{e.nextTick(()=>{o.isPanelShow=!1})},s=p=>{o.value.splice(p,1)},d=()=>{o.isSidebarShow=!1,e.nextTick(()=>{o.isPanelShow=!1})},f=()=>{o.value=[]};return{...e.toRefs(o),togglePanel:r,handleTabClick:l,pickerChange:i,deleteSingleDate:s,pickerBlur:d,handleClear:f,displayValue:a}}},mb={class:"dates-container"},gb={class:"dates-panel"},bb={class:"panel-label"},yb={class:"dates-side"},_b={class:"sidebar-list"},kb={class:"text"},wb=["onClick"],Vb={class:"panel-label"},Cb={class:"dates-side-top"},xb={class:"sidebar-list"},Nb={class:"item"},Bb={class:"text"};function Sb(t,n,o,a,r,l){const i=e.resolveComponent("el-icon-calendar"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("el-input"),f=e.resolveComponent("el-date-picker"),p=e.resolveComponent("Close"),m=e.resolveComponent("el-tab-pane"),_=e.resolveComponent("el-icon-close"),C=e.resolveComponent("el-tabs");return e.openBlock(),e.createElementBlock("div",mb,[e.createVNode(d,{class:"default-input",size:"small",type:"text",disabled:o.item.disabled,placeholder:o.item.placeholder||"请选择",clearable:"","model-value":a.displayValue,onClear:a.handleClear,onClick:a.togglePanel,style:{width:"100%"}},{suffix:e.withCtx(()=>[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i)]),_:1})]),_:1},8,["disabled","placeholder","model-value","onClear","onClick"]),e.withDirectives(e.createElementVNode("div",gb,[e.createVNode(C,{modelValue:t.activeName,"onUpdate:modelValue":n[3]||(n[3]=k=>t.activeName=k),class:"dates-panel-tabs",onTabClick:a.handleTabClick},{default:e.withCtx(()=>[e.createVNode(m,{label:"单日",name:"single"},{default:e.withCtx(()=>[e.createElementVNode("div",bb,[n[5]||(n[5]=e.createElementVNode("span",null,"单日",-1)),e.createVNode(f,{size:"small",type:o.item.singleType||"date",disabled:o.item.disabled,format:o.item.format||"yyyy-MM-dd","value-format":o.item.valueFormat||"yyyy-MM-dd",placeholder:o.item.placeholder||t.$t("lwSearch.please_select"),shortcuts:t.shortcuts,modelValue:t.value,"onUpdate:modelValue":n[0]||(n[0]=k=>t.value=k),clearable:!1,onBlur:a.pickerBlur,onChange:a.pickerChange,ref:"singlePicker","popper-class":"single-picker single-picker-"+o.item.prop},null,8,["type","disabled","format","value-format","placeholder","shortcuts","modelValue","onBlur","onChange","popper-class"]),t.isSidebarShow&&t.activeName==="single"?(e.openBlock(),e.createBlock(e.Teleport,{key:0,to:".single-picker-"+o.item.prop+" .el-picker-panel__sidebar"},[e.createElementVNode("div",yb,[n[4]||(n[4]=e.createElementVNode("div",{class:"sidebar-title"},"所选时间列表",-1)),e.createElementVNode("div",_b,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.value,(k,S)=>(e.openBlock(),e.createElementBlock("div",{class:"item",key:S},[e.createElementVNode("div",kb,e.toDisplayString(k),1),e.createElementVNode("div",{class:"button",onClick:B=>a.deleteSingleDate(S)},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(p)]),_:1})],8,wb)]))),128))])])],8,["to"])):e.createCommentVNode("",!0)])]),_:1}),e.createVNode(m,{label:"日期范围",name:"range"},{default:e.withCtx(()=>[e.createElementVNode("div",Vb,[n[6]||(n[6]=e.createElementVNode("span",null,"日期范围",-1)),e.createVNode(f,{size:"small",type:o.item.rangeType||"daterange",disabled:o.item.disabled,format:o.item.format||"yyyy-MM-dd","value-format":o.item.valueFormat||"yyyy-MM-dd",placeholder:o.item.placeholder||t.$t("lwSearch.please_select"),"unlink-panels":o.item.unlinkPanels??!1,shortcuts:t.shortcuts,modelValue:t.value,"onUpdate:modelValue":n[1]||(n[1]=k=>t.value=k),clearable:!1,onBlur:a.pickerBlur,onChange:a.pickerChange,ref:"rangePicker","popper-class":"range-picker range-picker-"+o.item.prop},null,8,["type","disabled","format","value-format","placeholder","unlink-panels","shortcuts","modelValue","onBlur","onChange","popper-class"]),t.isSidebarShow&&t.activeName==="range"?(e.openBlock(),e.createBlock(e.Teleport,{key:0,to:".range-picker-"+o.item.prop+" .el-picker-panel__sidebar"},[e.createElementVNode("div",Cb,[e.createElementVNode("div",xb,[e.withDirectives(e.createElementVNode("div",Nb,[e.createElementVNode("div",Bb,e.toDisplayString(t.value[0])+"~"+e.toDisplayString(t.value[1]),1),e.createElementVNode("div",{class:"button",onClick:n[2]||(n[2]=(...k)=>a.handleClear&&a.handleClear(...k))},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(_)]),_:1})])],512),[[e.vShow,t.value.length===2]])])])],8,["to"])):e.createCommentVNode("",!0)])]),_:1})]),_:1},8,["modelValue","onTabClick"])],512),[[e.vShow,t.isPanelShow]])])}const Eb=le(pb,[["render",Sb]]),Tb={emits:["update:modelValue","change"],name:"dateRange",props:{disabled:{type:Boolean,default(){return!1}},modelValue:{default(){return[]}},item:{type:Object,default(){return{}}},disabledDate:{type:Function,default(){return null}},propValueFormat:{type:String,default(){return null}}},setup(t,n){const o=e.reactive({}),a=e.computed(()=>t.propValueFormat?t.propValueFormat:t.item.valueFormat?t.item.valueFormat:t.item.dateSection||t.item.withZero?"YYYY-MM-DD 00:00:00":t.item.withLast?"YYYY-MM-DD 23:59:59":"YYYY-MM-DD"),r=e.computed({get(){return t.modelValue},set(i){n.emit("update:modelValue",i),n.emit("change",i)}}),l=i=>{const s=new Date;return s.setHours(i),s.setMinutes(0),s.setSeconds(0),s};return{...e.toRefs(o),defaultTime:l,valueFormat:a,value:r}}};function Ib(t,n,o,a,r,l){const i=e.resolveComponent("el-date-picker");return e.openBlock(),e.createElementBlock("div",null,[e.createVNode(i,{showTime:o.item.showTime,format:o.item.format||"YYYY-MM-DD HH:mm:ss","value-format":o.item.valueFormat,clearable:"",modelValue:a.value,"onUpdate:modelValue":n[0]||(n[0]=s=>a.value=s),style:{width:"100%"},type:"datetimerange","start-placeholder":t.$t("lwSearch.dateRange.startPlaceholder"),"end-placeholder":t.$t("lwSearch.dateRange.endPlaceholder"),"default-time":o.item.defaultTime||a.defaultTime(0),size:""},null,8,["showTime","format","value-format","modelValue","start-placeholder","end-placeholder","default-time"])])}const Db={components:{SearchInput:ib,SearchSelect:db,SearchDate:fb,SearchDates:Eb,SearchDateRange:le(Tb,[["render",Ib]])},name:"lwSearch",props:{options:{type:Array,default:()=>[]},modelValue:{type:Object,default:()=>({})},labelWidth:{type:String,default:"70px"},labelPosition:{type:String,default:"left"},columnNumber:{type:Number,default:4},isSave:{type:Boolean,default:!1},isCloud:{type:Boolean,default:!1},saveKey:{type:String,default:""},isExpand:{type:Boolean,default:!1},expandNumber:{type:Number,default:4},hasExpandAll:{type:Boolean,default:!1},hideLabel:{type:Boolean,default:!1},labelAlign:{type:String,default:"right"}},data(){return{form:{},defaultForm:{},isExpandStatus:!1,isChange:!1,saveList:[],saveFormName:"",isSaveShow:!1,isSelectShow:!1,selectForm:"",currentExpandNumber:4,isExpandAll:!0,currentTemplate:{},variantList:[],varianId:[],systemName:"shopManagement"}},watch:{modelValue:{handler(t){JSON.stringify(t)!==JSON.stringify(this.form)&&(this.form=JSON.parse(JSON.stringify(t)))},deep:!0},form:{handler(t){JSON.stringify(t)!==JSON.stringify(this.modelValue)&&this.$emit("update:modelValue",t)},deep:!0}},mounted(){this.isExpandStatus=this.isExpand,this.currentExpandNumber=this.expandNumber||this.columnNumber,this.form=JSON.parse(JSON.stringify(this.modelValue)),this.defaultForm=JSON.stringify(this.defaultForm)==="{}"?JSON.parse(JSON.stringify(this.modelValue)):this.defaultForm},methods:{setComponent(t){return{input:"SearchInput",select:"SearchSelect",date:"SearchDate",dates:"SearchDates",dateRange:"SearchDateRange"}[t]||"SearchInput"},submitForm(t){this.$refs[t]&&this.$refs[t].validate(n=>{n&&this.$emit("search")})},resetForm(t){this.$refs[t]&&(this.$refs[t].resetFields(),this.form=JSON.parse(JSON.stringify(this.defaultForm)),this.form.size=this.modelValue.size,this.$emit("reset"))},handleChangeHide(t){t===!1&&(this.isChange=!1,this.isSaveShow=!1,this.isSelectShow=!1,this.saveFormName="",this.selectForm="")},handleSaveSearchForm(){if(this.saveKey&&this.isSave){if(Object.keys(this.form).length===0){this.$message.error("搜索条件为空!");return}let t=Object.assign({},this.form,{searchSaveName:this.saveFormName,id:$e().valueOf()+Math.random()+""}),n={route:this.$route.name,system:this.systemName,variant:[t]},o=this.variantList.find(a=>a.route===this.$route.name);o?o.variant.push(t):this.variantList.push(n),this.isCloud?(this.varianId,JSON.parse(sessionStorage.userAuthInfo).username,this.systemName,this.saveKey,JSON.stringify(this.variantList)):localStorage.setItem("variantList",JSON.stringify(this.variantList))}},handleSearchSelect(t){let n=this.saveList.find(o=>o.id===t);if(n){let o=JSON.parse(JSON.stringify(n));delete o.id,delete o.searchSaveName,this.$emit("update:modelValue",o)}},handleDeleteSearchList(t){JSON.parse(JSON.stringify(this.saveList)).splice(t,1),this.saveKey&&this.isSave},disabledDate(t,n,o=""){if(o){if(n==="prev")return $e(t.getTime()).isAfter($e(o),"day");if(n==="next")return $e(t.getTime()).isBefore($e(o),"day")}},expandAll(){this.isExpandAll=!this.isExpandAll}}},Fb={id:"search-wrap"},qb={class:"search-content"};function Rb(t,n,o,a,r,l){const i=e.resolveComponent("el-col"),s=e.resolveComponent("el-row"),d=e.resolveComponent("el-form-item"),f=e.resolveComponent("el-button"),p=e.resolveComponent("el-form");return e.openBlock(),e.createElementBlock("div",Fb,[e.createElementVNode("div",qb,[e.createVNode(p,{ref:"searchForm",model:r.form,onSubmit:n[3]||(n[3]=e.withModifiers(()=>{},["prevent"])),"label-align":o.labelAlign,style:{width:"100%"}},{default:e.withCtx(()=>[e.createVNode(s,{class:e.normalizeClass(o.options.length-o.expandNumber===0?"expand-row":o.options.length-o.expandNumber<o.columnNumber?"":r.isExpandStatus?o.options.length%o.columnNumber===0?"expand-row":"":o.options.length>=o.expandNumber?"expand-row":""),type:"flex",justify:"start",gutter:10},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.options,(m,_)=>(e.openBlock(),e.createBlock(i,{key:m.prop,class:e.normalizeClass(!r.isExpandStatus&&m.isExpand||o.options.length-o.expandNumber<o.columnNumber?"":!r.isExpandStatus&&_>o.expandNumber-1?"hide":""),span:o.columnNumber?24/o.columnNumber:m.span||8},{default:e.withCtx(()=>[e.createVNode(d,{"label-width":o.hideLabel?0:o.labelWidth,required:m.required,label:o.hideLabel?"":t.$t(m.label)},{default:e.withCtx(()=>[m.dateSection&&m.prop&&m.prop.length===2?(e.openBlock(),e.createBlock(s,{key:0,gutter:10,class:"date-section"},{default:e.withCtx(()=>[e.createVNode(i,{span:12,style:{width:"45%",flex:"0 0 45%"}},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(l.setComponent(m.renderType)),{disabled:m.disabled,item:m,modelValue:r.form[m.prop[0]],"onUpdate:modelValue":C=>r.form[m.prop[0]]=C,"disabled-date":C=>l.disabledDate(C,"prev",r.form[m.prop[1]]),propValueFormat:m.valueFormat||"YYYY-MM-DD 00:00:00"},null,8,["disabled","item","modelValue","onUpdate:modelValue","disabled-date","propValueFormat"]))]),_:2},1024),n[4]||(n[4]=e.createElementVNode("span",{class:"date-section-line"}," - ",-1)),e.createVNode(i,{span:12,style:{width:"45%",flex:"0 0 45%"}},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(l.setComponent(m.renderType)),{disabled:m.disabled,item:m,modelValue:r.form[m.prop[1]],"onUpdate:modelValue":C=>r.form[m.prop[1]]=C,"disabled-date":C=>l.disabledDate(C,"next",r.form[m.prop[0]]),propValueFormat:m.valueFormat||"YYYY-MM-DD 23:59:59"},null,8,["disabled","item","modelValue","onUpdate:modelValue","disabled-date","propValueFormat"]))]),_:2},1024)]),_:2},1024)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(l.setComponent(m.renderType)),{key:1,modelValue:r.form[m.prop],"onUpdate:modelValue":C=>r.form[m.prop]=C,disabled:m.disabled,item:m,style:{width:"100%"}},null,8,["modelValue","onUpdate:modelValue","disabled","item"]))]),_:2},1032,["label-width","required","label"])]),_:2},1032,["class","span"]))),128))]),_:1},8,["class"]),e.createElementVNode("div",{class:"control",style:e.normalizeStyle({bottom:o.options.length%o.columnNumber===0?"0px":"10px"})},[e.createVNode(f,{class:"reset",onClick:n[0]||(n[0]=m=>l.resetForm("searchForm"))},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("btn.reset")),1)]),_:1}),e.createVNode(f,{class:"submit",type:"primary",onClick:n[1]||(n[1]=m=>l.submitForm("searchForm"))},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("btn.query")),1)]),_:1}),e.createElementVNode("div",{class:e.normalizeClass(o.options.length-o.expandNumber>=o.columnNumber?"expand-button":"hidden"),onClick:n[2]||(n[2]=m=>r.isExpandStatus=!r.isExpandStatus)},[e.createElementVNode("span",null,e.toDisplayString(r.isExpandStatus?"收起":"展开"),1)],2)],4)]),_:1},8,["model","label-align"])])])}const Zi=le(Db,[["render",Rb],["__scopeId","data-v-153d358b"]]),Ab={class:"svg-icon"},Ob=["xlink:href"],Xi=le({__name:"index",props:{name:{type:String,required:!0}},setup(t){const n=t,o=e.computed(()=>`#${n.name}`);return(a,r)=>(e.openBlock(),e.createElementBlock("svg",Ab,[e.createElementVNode("use",{"xlink:href":o.value},null,8,Ob)]))}},[["__scopeId","data-v-d1f88c15"]]);function vb(){const t=e.ref(!1),n=l=>{l.requestFullscreen?l.requestFullscreen():l.mozRequestFullScreen?l.mozRequestFullScreen():l.webkitRequestFullscreen?l.webkitRequestFullscreen():l.msRequestFullscreen&&l.msRequestFullscreen()},o=()=>{document.exitFullscreen?document.exitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitExitFullscreen?document.webkitExitFullscreen():document.msExitFullscreen&&document.msExitFullscreen()},a=()=>{t.value?o():n(document.documentElement)},r=()=>{t.value=!!(document.fullscreenElement||document.mozFullScreenElement||document.webkitFullscreenElement||document.msFullscreenElement)};return e.onMounted(()=>{document.addEventListener("fullscreenchange",r),document.addEventListener("webkitfullscreenchange",r),document.addEventListener("mozfullscreenchange",r),document.addEventListener("MSFullscreenChange",r)}),e.onUnmounted(()=>{document.removeEventListener("fullscreenchange",r),document.removeEventListener("webkitfullscreenchange",r),document.removeEventListener("mozfullscreenchange",r),document.removeEventListener("MSFullscreenChange",r)}),{isFullscreen:t,toggle:a}}const Pb={name:"lwTable",props:{refName:{type:String,default:"multipleTableRef"},tableName:{type:String,default:""},isRadio:{type:Boolean,default:!1},bordered:{type:Boolean,default:!0},stripe:{type:Boolean,default:!1},summaryMethod:{type:Function,default:()=>[]},rowKey:{type:String,default:"id"},defaultSelectData:{type:Array,default:()=>[]},searchParams:{type:Object,default:()=>({page:1,size:20})},selectStatus:{type:Function,default:()=>!0},pageSizes:{type:Array,default:()=>[10,20,30,40,50]},isShowPagination:{type:Boolean,default:!0},tableData:{type:Array,default:[]},totalCount:{type:Number,default:0},tableColumns:{type:Array,default:[]},hoverable:{type:Boolean,default:!0},defaultExpandAll:{type:Boolean,default:!1},isSetting:{type:Boolean,default:!1},saveKey:{type:String,default:""},orderPage:{type:Boolean,default:!1},tableSize:{type:String,default:"large"},loading:{type:Boolean,default:!1},rowSelection:{type:Boolean,default:!1},selectedKeys:{type:Array},selectDatas:{type:Array},hideTool:{type:Boolean,default:!0},virtualListProps:{type:Object,default:void 0},draggable:{type:Object},maxHeight:{type:String,default:"calc(100vh - 270px)"}},setup(t,n){const o=e.ref(),{proxy:{$bus:a,$tool:r}}=e.getCurrentInstance(),{isFullscreen:l,toggle:i}=vb(),s=e.reactive({dialogVisible:!1,tableSettingTitle:"选择字段",tableHeaderListAll:[],checkedList:[],defaultProps:{children:"children",label:"label"},num:0,endFixed:!1,filterHeader:[],tableSize:t.tableSize,checkedKeys:[],treeData:[],allCheck:!0,lastColumsFixed:!0,tableHeaders:[],fixNum:0}),d=()=>{let P=t.tableColumns;s.checkedKeys=[];let J=[];P.forEach((ee,ce)=>{ee.key||(ee.key=r.getUUID()),(ee.checked||ee.checked==null)&&(s.checkedKeys.push(ee.key),J.push(ee))}),s.treeData=P,s.tableHeaders=J};e.onBeforeMount(async()=>{window.addEventListener("resize",()=>{let P=document.mozFullScreen||document.fullScreen||document.webkitIsFullScreen||document.webkitRequestFullScreen||document.mozRequestFullScreen||document.msFullscreenEnabled;P===void 0&&(P=!1),P==!1&&a.$emit("tableFullScreen",!1)})}),e.watch(()=>t.tableColumns,P=>{d()},{deep:!0,immediate:!0});const f=e.ref([]),p=e.ref([]),m=e.ref([]);e.watch(()=>t.tableData,P=>{const J=[...P,...m.value],ee={},ce=J.reduce((ye,we)=>(ee[we[t.rowKey]]||(ee[we[t.rowKey]]=ye.push(we)),ye),[]);m.value=ce||[]},{deep:!0,immediate:!0}),e.watch(()=>t.selectedKeys,P=>{if(f.value=P,p.value=[],m.value.length&&P){const ee=[...m.value.filter(we=>P.includes(we[t.rowKey])),...p.value],ce={},ye=ee.reduce((we,xe)=>(ce[xe[t.rowKey]]||(ce[xe[t.rowKey]]=we.push(xe)),we),[]);p.value=ye||[],n.emit("update:selectDatas",ye)}},{deep:!0,immediate:!0});const _=P=>{n.emit("draggable",P)},C=P=>{n.emit("multipleSelection",P)},k=P=>{n.emit("currentChange",P)},S=P=>{t.searchParams.size=P,n.emit("getTableData")},B=P=>{t.searchParams.page=P-1,n.emit("getTableData",t.searchParams.page)},q=()=>{B(1)},F=(P,J)=>{o.value.toggleRowSelection(P,J)},V=(P,J)=>{o.value.clearSelection()},j=(P,J,ee)=>ee!=="inner",U=P=>P.data.label.indexOf("Level three 3-1-1")===-1,L=()=>{s.tableSettingTitle="选择字段",s.dialogVisible=!0},A=()=>{if(s.checkedList.length===0){Message.error("选择字段不可以为空!");return}s.tableSettingTitle="排序",s.treeData=[];let P=0;JSON.parse(JSON.stringify(s.checkedList)).forEach((ee,ce)=>{t.tableHeader.forEach(ye=>{if(ee===ye.label){let we={label:ee,children:[],index:ce,fixed:ye.fixed?ye.fixed:""};s.treeData.push(we),ye.fixed==="left"?P++:ye.fixed==="right"&&(s.endFixed=!0)}}),s.num=P})},z=()=>{s.tableSettingTitle="选择字段"},Y=()=>{if(s.num>2&&s.endFixed||s.num>3&&!s.endFixed){Message.error("固定列最多只能选择3列!");return}s.tableHeaderList=[],s.treeData.forEach((J,ee)=>{s.num>0&&s.num>ee?J.fixed="left":s.endFixed&&ee===s.treeData.length-1?J.fixed="right":J.fixed="",s.tableHeaderList.push(J)}),s.dialogVisible=!1;let P={userId:1,json:s.tableHeaderList};localStorage.setItem("userTable",JSON.stringify(P))},$=P=>{let J=(process.env.NODE_ENV==="development"||process.env.NODE_ENV==="test")&&location.hostname!=="localhost"?location.origin+P:"http://dev.yihai.lianwei.com.cn"+P;window.open(J,"_blank")},H=({column:P,prop:J,order:ee})=>{t.searchParams.sortField=J==null?void 0:J.split(",")[0],t.searchParams.sortType=ee;const ce={...t.searchParams};n.emit("getTableData",ce)},X=P=>{n.emit("getHeader",P)},ie=P=>{s.tableSize=P},R=P=>{P?(s.tableHeaders=JSON.parse(JSON.stringify(t.tableColumns)),s.tableHeaders.forEach((J,ee)=>{J.key||(J.key=r.getUUID()),s.checkedKeys.push(J.key)})):(s.tableHeaders=[],s.checkedKeys=[]),s.treeData.forEach(J=>{J.checked=P})},ne=()=>{let P=s.treeData.filter(J=>s.checkedKeys.includes(J.key));s.tableHeaders=P},h=()=>{a.$emit("tableFullScreen",!l.value),i()},T=()=>{let P=s.fixNum;P>0?s.tableHeaders.forEach((J,ee)=>{ee<P&&(J.fixed="left",J.width=J.width??"120")}):s.tableHeaders.forEach(J=>{J.fixed==="left"&&delete J.fixed})},x=P=>{o.value.selectAll(P),n.emit("update:selectedKeys",P?t.tableData.map(J=>J.id):[])},Ce=(P,J)=>{o.value.select(P,J);const ee=[...t.selectedKeys];n.emit("update:selectedKeys",J?ee.push(P):ee.filter(ce=>ce!==P))},G=P=>{n.emit("update:selectedKeys",P?t.tableData.map(J=>J[t.rowKey]):[])},Te=(P,J,ee)=>{n.emit("update:selectedKeys",P)},Z=(P,J,{property:ee})=>{};return{...e.toRefs(s),refresh:q,dayjs:$e,handleChange:_,handleSelectionChange:C,handleCurrentChange:k,sizeChange:S,currentChange:B,multipleTable:o,allowDrop:j,allowDrag:U,tableSetting:L,next:A,prev:z,tableHeaderConfirm:Y,toggleRowChange:F,clearTableSelection:V,download:$,sortChange:H,getHeader:X,handleSelect:ie,checkAll:R,tableToggleFullScreen:h,isFullscreen:l,treeCheck:ne,fixNumChange:T,setSelectAll:x,setSelect:Ce,selectedKeysForm:f,selectGoodsDatas:p,selectAll:G,select:Te,changeColWidth:Z}}},Lb={class:"baseTablePage-wrap"},Mb={style:{"max-width":"300px",display:"inline-block"}},Ub={key:0},jb={key:1},zb={key:1},Hb=["innerHTML","onClick"],Kb=["innerHTML"],Gb={key:2},Yb={key:3},$b={key:0},Wb={key:4},Jb={style:{"margin-bottom":"5px"}},Zb={key:5},Xb={key:6},Qb={key:7},ey=["src"],ty={key:8},ny={key:9},oy={key:10},ry=["onClick"],ay={key:1},ly=["onClick"],iy={key:11},sy={key:0,class:"pagination-block"},cy={class:"tool-block"},dy={class:"dropdown-trigger"},uy={class:"fix-num"};function hy(t,n,o,a,r,l){const i=e.resolveComponent("el-table-column"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("el-tooltip"),f=e.resolveComponent("el-tag"),p=e.resolveComponent("el-button"),m=e.resolveComponent("el-icon-more-filled"),_=e.resolveComponent("el-dropdown-item"),C=e.resolveComponent("el-dropdown-menu"),k=e.resolveComponent("el-dropdown"),S=e.resolveComponent("el-image"),B=e.resolveComponent("el-option"),q=e.resolveComponent("el-select"),F=e.resolveComponent("el-switch"),V=e.resolveComponent("el-progress"),j=e.resolveComponent("el-table"),U=e.resolveComponent("el-icon-refresh"),L=e.resolveComponent("el-icon-set-up"),A=e.resolveComponent("el-icon-setting"),z=e.resolveComponent("el-checkbox"),Y=e.resolveComponent("el-checkbox-group"),$=e.resolveComponent("el-input-number"),H=e.resolveComponent("el-popover"),X=e.resolveComponent("el-icon-full-screen"),ie=e.resolveComponent("el-pagination"),R=e.resolveDirective("auth"),ne=e.resolveDirective("loading");return e.openBlock(),e.createElementBlock("div",Lb,[e.withDirectives((e.openBlock(),e.createBlock(j,{ref:"multipleTable","column-resizable":"",columns:t.tableHeaders,stripe:t.stripe,data:t.tableData,"row-key":t.rowKey,hoverable:t.hoverable,"default-expand-all-rows":t.defaultExpandAll,size:t.tableSize,"highlight-current-row":"","max-height":t.maxHeight,"scrollbar-always-on":"",scroll:{x:"100%",y:"100%"},"virtual-list-props":t.virtualListProps,onCurrentChange:t.handleCurrentChange,onSelectionChange:t.handleSelectionChange},{default:e.withCtx(()=>[t.rowSelection?(e.openBlock(),e.createBlock(i,{key:0,fixed:"left",type:"selection",width:"55"})):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.tableHeaders,h=>(e.openBlock(),e.createBlock(i,{label:h.title,prop:h.dataIndex,width:h.width,"min-width":h.minWidth,align:h.align??"center",fixed:h.fixed,sortable:h.sortable,"show-overflow-tooltip":h.tooltip,key:h},{header:e.withCtx(({column:T,$index:x})=>[h!=null&&h.header?e.renderSlot(t.$slots,h.header,{key:1,scope:{column:T,$index:x,t:h}},()=>[e.createVNode(f,{type:"danger"},{default:e.withCtx(()=>[e.createTextVNode(" ["+e.toDisplayString(t.item.header)+"]没有这个自定义表头 ",1)]),_:1})],!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(h.title)+" ",1),h.tips?(e.openBlock(),e.createBlock(d,{key:0},{content:e.withCtx(()=>[e.createElementVNode("span",Mb,e.toDisplayString(h.tips),1)]),default:e.withCtx(()=>[e.createVNode(s,null,{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(h.icon||"el-icon-question-filled")))]),_:2},1024)]),_:2},1024)):e.createCommentVNode("",!0)],64))]),default:e.withCtx(T=>[h!=null&&h.operation?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[h.operation.filter(x=>!(x!=null&&x.isShow)||x.isShow(T.row)).length<=3?(e.openBlock(),e.createElementBlock("div",Ub,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.operation.filter(x=>!(x!=null&&x.isShow)||x.isShow(T.row)),x=>(e.openBlock(),e.createElementBlock("span",{key:x},[x.icon?e.withDirectives((e.openBlock(),e.createBlock(d,{key:0,content:x.label,placement:"top"},{default:e.withCtx(()=>[e.createVNode(p,{type:"primary",size:"small",onClick:Ce=>x.clickFun(t.row,t.$index,t.tableData),disabled:x.disabled?x.disabled(T.row):!1,icon:x.icon,circle:""},null,8,["onClick","disabled","icon"])]),_:2},1032,["content"])),[[R,x.auth]]):e.withDirectives((e.openBlock(),e.createBlock(p,{key:1,type:"primary",text:"",size:"small",onClick:Ce=>x.clickFun(T.row,T.$index,t.tableData),disabled:x.disabled?x.disabled(T.row):!1},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(x.label),1)]),_:2},1032,["onClick","disabled"])),[[R,x.auth]])]))),128))])):(e.openBlock(),e.createElementBlock("div",jb,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.operation.filter(x=>!x.isShow||x.isShow(T.row)).slice(0,2),x=>(e.openBlock(),e.createElementBlock("span",{key:x},[x.icon?e.withDirectives((e.openBlock(),e.createBlock(d,{key:0,content:x.label,placement:"top"},{default:e.withCtx(()=>[e.createVNode(p,{type:"primary",size:"small",onClick:Ce=>x.clickFun(T.row,T.$index,t.tableData),disabled:x.disabled?x.disabled(T.row):!1,icon:x.icon,circle:""},null,8,["onClick","disabled","icon"])]),_:2},1032,["content"])),[[R,x.auth]]):e.withDirectives((e.openBlock(),e.createBlock(p,{key:1,type:"primary",text:"",size:"small",onClick:Ce=>x.clickFun(T.row,T.$index,t.tableData),disabled:x.disabled?x.disabled(T.row):!1},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(x.label),1)]),_:2},1032,["onClick","disabled"])),[[R,x.auth]])]))),128)),e.createVNode(k,null,{dropdown:e.withCtx(()=>[e.createVNode(C,null,{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.operation.filter(x=>!x.isShow||x.isShow(T.row)).slice(2),x=>e.withDirectives((e.openBlock(),e.createBlock(_,{key:x,onClick:Ce=>x.clickFun(T.row,T.$index,t.tableData)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(x.label),1)]),_:2},1032,["onClick"])),[[R,x.auth]])),128))]),_:2},1024)]),default:e.withCtx(()=>[e.createVNode(p,{size:"small",type:"primary",link:""},{default:e.withCtx(()=>[e.createVNode(s,{class:"more-btn",size:"16"},{default:e.withCtx(()=>[e.createVNode(m)]),_:1})]),_:1})]),_:2},1024)]))],64)):h.eleRender?(e.openBlock(),e.createElementBlock("div",zb,[h!=null&&h.clickFun?(e.openBlock(),e.createElementBlock("span",{key:0,innerHTML:h.eleRender(T.row,T.$index),onClick:x=>h.clickFun(T.row,T.$index,t.tableData)},null,8,Hb)):(e.openBlock(),e.createElementBlock("span",{key:1,innerHTML:h.eleRender(T.row,T.$index)},null,8,Kb))])):h.type==="img"?(e.openBlock(),e.createElementBlock("div",Gb,[e.createVNode(S,{style:{height:"28px"},fit:"cover","max-scale":7,"min-scale":.2,"z-index":99,"preview-teleported":!0,previewSrcList:[T.row[h.dataIndex]],src:T.row[h.dataIndex]?T.row[h.dataIndex]:"/static/images/empty.jpg"},null,8,["previewSrcList","src"])])):!h.switch&&h.options&&h.options.length>0?(e.openBlock(),e.createElementBlock("div",Yb,[T.row.isEdit&&h.canEdit?(e.openBlock(),e.createBlock(q,{key:0,class:"select-select number","value-key":h.editValue||"code",modelValue:T.row[h.editSource],"onUpdate:modelValue":x=>T.row[h.editSource]=x,placeholder:"","allow-clear":"","allow-search":"","filter-option":"",onChange:x=>{h.callback(x,T.row)}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.options,x=>(e.openBlock(),e.createBlock(B,{value:x,key:x},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(h.editValue?x[h.editValue]:x.name),1)]),_:2},1032,["value"]))),128))]),_:2},1032,["value-key","modelValue","onUpdate:modelValue","onChange"])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(h.options,(x,Ce)=>(e.openBlock(),e.createElementBlock("span",{key:x+Ce},[T.row[h.dataIndex]==x[h.editValue||"code"]?(e.openBlock(),e.createElementBlock("span",$b,[x.statusColor?(e.openBlock(),e.createElementBlock("span",{key:0,style:e.normalizeStyle(`background-color: ${x.statusColor}; border-radius: 100%; padding: 4px; display: inline-block; margin-right: 5px;`)},null,4)):e.createCommentVNode("",!0),e.createTextVNode(e.toDisplayString(h.editValue?x[h.editValue]:x.name),1)])):e.createCommentVNode("",!0)]))),128))])):h.type==="startToEnd"?(e.openBlock(),e.createElementBlock("div",Wb,[e.createElementVNode("div",Jb,[n[3]||(n[3]=e.createElementVNode("span",{class:"start-span"},"起",-1)),e.createTextVNode(" "+e.toDisplayString(T.row[h.dataIndexList[0]]?t.dayjs(T.row[h.dataIndexList[0]]).format("YYYY-MM-DD HH:mm:ss"):"--"),1)]),e.createElementVNode("div",null,[n[4]||(n[4]=e.createElementVNode("span",{class:"end-span"},"止",-1)),e.createTextVNode(" "+e.toDisplayString(T.row[h.dataIndexList[1]]?t.dayjs(T.row[h.dataIndexList[1]]).format("YYYY-MM-DD HH:mm:ss"):"--"),1)])])):h.dataType?(e.openBlock(),e.createElementBlock("div",Zb,e.toDisplayString(t.$fermitTime(T.row[h.dataIndex])),1)):h.switch?(e.openBlock(),e.createElementBlock("div",Xb,[e.createVNode(F,{"inline-prompt":h.isShowMessage,"active-text":h.isShowMessage?h.activeText:"","inactive-text":h.isShowMessage?h.inactiveText:"",style:{"--el-switch-on-color":"var(--el-color-primary)","--el-switch-off-color":"#c6c6c6"},modelValue:T.row[h.dataIndex],"onUpdate:modelValue":x=>T.row[h.dataIndex]=x,"active-value":h.activeValue??!0,"inactive-value":h.inactiveValue??!1,disabled:h.disabled?h.disabled(T.row):!1,onChange:x=>{h.clickFun(x,T.row)}},null,8,["inline-prompt","active-text","inactive-text","modelValue","onUpdate:modelValue","active-value","inactive-value","disabled","onChange"])])):h.isVideo?(e.openBlock(),e.createElementBlock("div",Qb,[e.createElementVNode("video",{width:"40",src:T.row[h.dataIndex],style:{margin:"5px 0"}},null,8,ey)])):h.pictureCard?(e.openBlock(),e.createElementBlock("div",ty,[e.createVNode(S,{width:"40",src:T.row[h.dataIndex],style:{margin:"5px 0"}},null,8,["src"])])):h.arrayList?(e.openBlock(),e.createElementBlock("div",ny,[e.createElementVNode("span",null,e.toDisplayString(T.row[h.dataIndex]!==null&&T.row[h.dataIndex].length>0?T.row[h.dataIndex].toString():""),1)])):h.skip?(e.openBlock(),e.createElementBlock("span",oy,[T.row[h.dataIndex]&&T.row[h.dataIndex].toString().split(",").length>1?(e.openBlock(),e.createBlock(d,{key:0},{content:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(T.row[h.dataIndex].split(","),(x,Ce)=>(e.openBlock(),e.createElementBlock("div",{key:Ce,style:e.normalizeStyle(`color: ${t.theme}; cursor: pointer`),onClick:G=>h.clickFun?h.clickFun(x,T.row,T.$index):()=>{}},e.toDisplayString(x),13,ry))),128))]),default:e.withCtx(()=>[e.createElementVNode("span",{style:e.normalizeStyle(`color: ${t.theme};cursor: pointer;width: 100%;display: inline-block;white-space: nowrap;overflow: hidden;text-overflow: ellipsis;`)},e.toDisplayString(T.row[h.dataIndex]?T.row[h.dataIndex]:""),5)]),_:2},1024)):(e.openBlock(),e.createElementBlock("span",ay,[e.createElementVNode("span",{style:{color:"var(--el-color-primary)",cursor:"pointer","text-decoration":"underline"},onClick:x=>h.clickFun?h.clickFun(T.row[h.dataIndex],T.row,T.$index):()=>{}},e.toDisplayString(T.row[h.dataIndex]||T.row[h.dataIndex]===0?T.row[h.dataIndex]:""),9,ly)]))])):h.isProgress?(e.openBlock(),e.createElementBlock("span",iy,[e.createVNode(V,{percentage:T.row[h.dataIndex],color:"var(--el-color-primary)"},null,8,["percentage"])])):h.slot?e.renderSlot(t.$slots,h.component,{key:12,row:T.row},()=>[e.createVNode(f,{type:"danger"},{default:e.withCtx(()=>[e.createTextVNode("["+e.toDisplayString(h.component)+"] 没有这个默认组件也未自定义插槽内容",1)]),_:2},1024)],!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:13},[e.createTextVNode(e.toDisplayString(T.row[h.dataIndex]?T.row[h.dataIndex]:T.row[h.dataIndex]===0?"0":""),1)],64))]),_:2},1032,["label","prop","width","min-width","align","fixed","sortable","show-overflow-tooltip"]))),128))]),_:3},8,["columns","stripe","data","row-key","hoverable","default-expand-all-rows","size","max-height","virtual-list-props","onCurrentChange","onSelectionChange"])),[[ne,t.loading]]),t.isShowPagination?(e.openBlock(),e.createElementBlock("div",sy,[e.createElementVNode("div",cy,[t.hideTool?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(d,{content:t.$t("btn.refresh")},{default:e.withCtx(()=>[e.createVNode(s,{size:"20",onClick:t.refresh},{default:e.withCtx(()=>[e.createVNode(U)]),_:1},8,["onClick"])]),_:1},8,["content"]),e.createVNode(k,{onCommand:t.handleSelect},{dropdown:e.withCtx(()=>[e.createVNode(C,null,{default:e.withCtx(()=>[e.createVNode(_,{command:"small"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("lwTable.tools.lineHeight.mini")),1)]),_:1}),e.createVNode(_,{command:"medium"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("lwTable.tools.lineHeight.small")),1)]),_:1}),e.createVNode(_,{command:"large"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("lwTable.tools.lineHeight.medium")),1)]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createElementVNode("span",dy,[e.createVNode(d,{content:t.$t("lwTable.tools.lineHeightName")},{default:e.withCtx(()=>[e.createVNode(s,{size:"20"},{default:e.withCtx(()=>[e.createVNode(L)]),_:1})]),_:1},8,["content"])])]),_:1},8,["onCommand"]),e.createVNode(H,{placement:"top-start",title:t.$t("lwTable.tools.columnsSetting"),width:400,trigger:"hover"},{reference:e.withCtx(()=>[e.createVNode(s,{size:"20"},{default:e.withCtx(()=>[e.createVNode(A)]),_:1})]),default:e.withCtx(()=>[e.createVNode(z,{modelValue:t.allCheck,"onUpdate:modelValue":n[0]||(n[0]=h=>t.allCheck=h),onChange:t.checkAll},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("lwTable.tools.allCheck"))+","+e.toDisplayString(t.$t("lwTable.tools.hasChecked"))+e.toDisplayString(t.checkedKeys.length)+"/"+e.toDisplayString(t.treeData.length),1)]),_:1},8,["modelValue","onChange"]),e.createVNode(Y,{modelValue:t.checkedKeys,"onUpdate:modelValue":n[1]||(n[1]=h=>t.checkedKeys=h),onChange:t.treeCheck},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.treeData,h=>(e.openBlock(),e.createBlock(z,{key:h.key,label:h.title,value:h.key},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(h.title),1)]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue","onChange"]),e.createElementVNode("div",uy,[e.createTextVNode(e.toDisplayString(t.$t("lwTable.tools.table_before"))+" ",1),e.createVNode($,{modelValue:t.fixNum,"onUpdate:modelValue":n[2]||(n[2]=h=>t.fixNum=h),onChange:t.fixNumChange,min:0,max:10,size:"small"},null,8,["modelValue","onChange"]),e.createTextVNode(" "+e.toDisplayString(t.$t("lwTable.tools.column_fixed")),1)])]),_:1},8,["title"]),e.createVNode(d,{content:t.isFullscreen?t.$t("lwTable.tools.cancel"):t.$t("lwTable.tools.fullScreen")},{default:e.withCtx(()=>[t.isFullscreen?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(s,{key:0,class:"icon-fullscreen",onClick:t.tableToggleFullScreen},{default:e.withCtx(()=>[e.createVNode(X)]),_:1},8,["onClick"])),t.isFullscreen?(e.openBlock(),e.createBlock(s,{key:1,class:"icon-fullscreen-exit",onClick:t.tableToggleFullScreen},{default:e.withCtx(()=>[e.createVNode(X)]),_:1},8,["onClick"])):e.createCommentVNode("",!0)]),_:1},8,["content"])],64))]),e.createVNode(ie,{background:"",size:"small","current-page":parseFloat(t.searchParams.page).toString()=="NaN"?1:t.searchParams.page,"page-size":t.searchParams.size?t.searchParams.size:10,layout:"total, prev, pager, next, sizes, jumper",total:t.totalCount,"page-sizes":t.pageSizes,onSizeChange:t.sizeChange,onCurrentChange:t.currentChange},null,8,["current-page","page-size","total","page-sizes","onSizeChange","onCurrentChange"])])):e.createCommentVNode("",!0)])}const Qi=le(Pb,[["render",hy],["__scopeId","data-v-6c4a8459"]]),fy={name:"lwUpload",props:{modelValue:{type:[String,Array,Boolean,Object],default:""},height:{type:Number,default:148},width:{type:Number,default:148},title:{type:String,default:""},tip:{type:String,default:""},icon:{type:String,default:"el-icon-plus"},action:{type:String,default:()=>{}},apiObj:{type:[Object,Function],default:()=>{}},name:{type:String,default:"file"},data:{type:Object,default:()=>{}},accept:{type:String,default:"image/gif, image/jpeg, image/png"},maxSize:{type:Number,default:10},limit:{type:Number,default:1},autoUpload:{type:Boolean,default:!0},showFileList:{type:Boolean,default:!1},multiple:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},round:{type:Boolean,default:!1},onSuccess:{type:Function,default:()=>!0},returnFile:{type:[Object,String],default:{url:"url",code:"code",fileName:"fileName",src:"src",type:"type",name:"name",size:"size",tempCropperFile:"tempCropperFile"}},parseData:{type:Function,default:t=>({code:200,fileName:t.fileName,src:t.previewInfo.url,msg:t.message})}},data(){return{value:"",file:null,fileList:[],cropperDialogVisible:!1,cropperFile:null}},computed:{style(){return{width:this.width+"px",height:this.height+"px"}}},watch:{modelValue(t){this.value=t,this.newFile(t)},value(t){this.$emit("update:modelValue",t)}},mounted(){this.value=this.modelValue,this.newFile(this.modelValue)},methods:{newFile(t){this.multiple?this.fileList=t||[]:this.fileList=t?[t]:[],t?this.file={status:"success",url:t}:this.file=null},handleRemove(t){this.fileList.splice(t,1),this.clearFiles()},clearFiles(){var t;URL.revokeObjectURL((t=this.file)==null?void 0:t.tempFile),this.multiple?this.value=this.fileList:this.value="",this.file=null,this.$nextTick(()=>{var n;(n=this.$refs.uploader)==null||n.clearFiles()})},change(t,n){if(n.length>1&&n.splice(0,1),t.status=="ready")return this.accept.replace(/\s/g,"").split(",").includes(t.raw.type)?(this.cropperFile=t,this.cropperFile.tempCropperFile=URL.createObjectURL(t.raw),this.cropperDialogVisible=!0,!1):(this.$notify.warning({title:"上传文件警告",message:"选择的文件非图像类文件"}),!1);this.file=t,t.status=="ready"&&(t.tempFile=URL.createObjectURL(t.raw))},before(t){if(!this.accept.replace(/\s/g,"").split(",").includes(t.type))return this.$notify.warning({title:"上传文件错误",message:"选择的文件类型不对"}),this.clearFiles(),!1;if(!(t.size/1024/1024<this.maxSize))return this.$message.warning(`上传文件大小不能超过 ${this.maxSize}MB!`),this.clearFiles(),!1},handleExceed(t){const n=t[0];n.uid=this.$tool.getUUID("file, 16"),this.$refs.uploader.handleStart(n)},success(t,n){n.type=n.raw.type,URL.revokeObjectURL(n.tempFile),delete n.tempFile,delete n.percentage,delete n.raw,delete n.response,delete n.uid;var o=this.onSuccess(t,n);if(o!=null&&o==!1)return this.$nextTick(()=>{this.file=null,this.value=""}),!1;var a=this.parseData(t);n.url=a.src;let r={...a,...n};if(typeof this.returnFile=="object"){let l=Object.entries(this.returnFile).reduce((i,[s,d])=>(r[s]!==void 0&&(i[d]=r[s]),i),{});this.fileList.push(l)}else this.fileList.push(r[this.returnFile]);this.multiple?this.value=this.fileList:this.value=n.url},error(t){this.$nextTick(()=>{delete this.file.percentage}),this.$notify.error({title:"上传文件未成功",message:t})},request(t){let n=this.apiObj||this.$api.auth.upload;const o=new FormData;o.append(t.filename,t.file),o.append("fileName",t.file.name);for(const a in t.data)o.append(a,t.data[a]);n(o,{onUploadProgress:a=>{var r;(r=this.file)!=null&&r.percentage&&(this.file.percentage=parseInt(a.loaded/a.total*100|0,10))}}).then(a=>{var r=this.parseData(a);r.code==200?t.onSuccess(a):t.onError(r.msg||"未知错误")}).catch(a=>{t.onError(a)})},getShowValue(t){return this.multiple&&typeof this.returnFile=="object"?t[this.returnFile[Object.keys(this.returnFile)[0]]]:t}}},py={class:"view-img-list"},my=["src"],gy={key:2,class:"lw-upload__img-actions"},by=["onClick"],yy={class:"el-upload--picture-card"},_y={class:"file-empty"},ky={key:0},wy={key:0,class:"el-upload__tip"};function Vy(t,n,o,a,r,l){const i=e.resolveComponent("el-image"),s=e.resolveComponent("el-icon-delete"),d=e.resolveComponent("el-icon"),f=e.resolveComponent("el-progress"),p=e.resolveComponent("el-upload");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["lw-upload",{"lw-upload-round":o.round}])},[e.createElementVNode("div",py,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.fileList,(m,_)=>(e.openBlock(),e.createElementBlock("div",{class:"lw-upload__img",style:e.normalizeStyle(l.style)},[o.accept.indexOf("image")>-1?(e.openBlock(),e.createBlock(i,{key:0,class:"image",src:l.getShowValue(m),"preview-src-list":r.fileList,fit:"cover","hide-on-click-modal":"","append-to-body":"","z-index":9999},{placeholder:e.withCtx(()=>n[0]||(n[0]=[e.createElementVNode("div",{class:"lw-upload__img-slot"}," Loading... ",-1)])),_:2},1032,["src","preview-src-list"])):e.createCommentVNode("",!0),o.accept.indexOf("video")>-1?(e.openBlock(),e.createElementBlock("video",{key:1,src:l.getShowValue(m),controls:""},null,8,my)):e.createCommentVNode("",!0),o.disabled?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",gy,[e.createElementVNode("span",{class:"del",onClick:C=>l.handleRemove(_)},[e.createVNode(d,null,{default:e.withCtx(()=>[e.createVNode(s)]),_:1})],8,by)]))],4))),256)),r.fileList.length<o.limit?(e.openBlock(),e.createBlock(p,{key:0,class:"uploader",style:e.normalizeStyle(l.style),ref:"uploader","auto-upload":o.autoUpload,disabled:o.disabled,"show-file-list":o.showFileList,action:o.action,name:o.name,data:o.data,accept:o.accept,limit:o.limit,"http-request":l.request,"on-change":l.change,"before-upload":l.before,"on-success":l.success,"on-error":l.error,"on-exceed":l.handleExceed},{default:e.withCtx(()=>[e.renderSlot(t.$slots,"default",{},()=>{var m;return[e.createElementVNode("div",yy,[e.createElementVNode("div",_y,[e.createVNode(d,null,{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.icon)))]),_:1}),o.title?(e.openBlock(),e.createElementBlock("h4",ky,e.toDisplayString(o.title),1)):e.createCommentVNode("",!0)]),(m=r.file)!=null&&m.percentage?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(l.style),class:"lw-upload__progress"},[e.createVNode(f,{percentage:r.file.percentage,"text-inside":!0,"stroke-width":16},null,8,["percentage"])],4)):e.createCommentVNode("",!0)])]},!0)]),_:3},8,["style","auto-upload","disabled","show-file-list","action","name","data","accept","limit","http-request","on-change","before-upload","on-success","on-error","on-exceed"])):e.createCommentVNode("",!0)]),o.tip?(e.openBlock(),e.createElementBlock("div",wy,e.toDisplayString(o.tip),1)):e.createCommentVNode("",!0)],2)}const St=le(fy,[["render",Vy],["__scopeId","data-v-e6bbc2dd"]]),Cy={components:{lwUpload:St},props:{modelValue:{type:Object,default:()=>{}},config:{type:Object,default:()=>{}},loading:{type:Boolean,default:!1},isView:{type:Boolean,default:!1}},data(){return{form:{},tagValue:"",tagVisible:!1,renderLoading:!1}},watch:{modelValue(t,n){this.hasConfig&&this.hasValue&&this.deepMerge(this.form,JSON.parse(JSON.stringify(t)))},config(){this.render()},form:{handler(t){this.$emit("update:modelValue",t)},deep:!0}},computed:{hasConfig(){return Object.keys(this.config).length>0},hasValue(){return Object.keys(this.modelValue).length>0}},mounted(){this.hasConfig&&this.render()},methods:{render(){this.form={},this.config.formItems.forEach(t=>{var n,o,a;if(t.component=="checkbox"||t.component=="upload")if(t.name){const r={};t==null||t.options.items.forEach(l=>{r[l.name]=l.value}),this.form[t.name]=r}else(n=t==null?void 0:t.options)!=null&&n.items&&(t==null||t.options.items.forEach(r=>{this.form[r.name]=r.value}));else(o=t==null?void 0:t.options)!=null&&o.name?(this.form[t.name]||(this.form[t.name]={}),this.form[t.name][(a=t==null?void 0:t.options)==null?void 0:a.name]=t.value):t.name&&(this.form[t.name]=t.value)}),this.hasValue&&(this.form=this.deepMerge(this.form,this.modelValue))},deepMerge(t,n){for(let o in n)if(n.hasOwnProperty(o)){const a=t[o]!==null&&t[o]!==void 0,r=n[o]!==null&&n[o]!==void 0;a&&typeof t[o]=="object"&&!Array.isArray(t[o])&&r&&typeof n[o]=="object"&&!Array.isArray(n[o])?t[o]=this.deepMerge(t[o],n[o]):r?t[o]=n[o]:r||delete t[o]}return t},hideHandle(t){return typeof t.hideHandle=="string"?new Function("form",`return ${t==null?void 0:t.hideHandle.replace(/\$/g,"form")}`)(this.form):typeof t.hideHandle=="boolean"?t.hideHandle:!1},rulesHandle(t){if(t.requiredHandle)try{const o=new Function("form",`return ${t.requiredHandle.replace(/\$/g,"form")}`)(this.form),a=t.rules.find(r=>"required"in r);a&&(a.required=o)}catch(n){console.error("Error requiredHandle function:",n)}return t.rules},validate(t,n){return this.$refs.form.validate(t,n)},scrollToField(t){return this.$refs.form.scrollToField(t)},resetFields(){return this.$refs.form.resetFields()},submit(){this.$emit("submit",this.form)},tagClose(t,n){n.splice(n.indexOf(t),1)},tagInputConfirm(t,n){var o;this.tagValue&&((o=t==null?void 0:t.options)!=null&&o.name?(n[t.name]=n[t.name]||{},n[t.name][t==null?void 0:t.options.name]=n[t.name][t==null?void 0:t.options.name]||[],n[t.name][t==null?void 0:t.options.name].push(this.tagValue)):(n[t.name]=n[t.name]||[],n[t.name].push(this.tagValue))),this.tagVisible=!1,this.tagValue=""},getPropName(t){var n;return t.component=="checkbox"||t.component=="upload"?t.name?`${t.name}.${t==null?void 0:t.options.items[0].name}`:t==null?void 0:t.options.items[0].name:(n=t==null?void 0:t.options)!=null&&n.name?`${t.name}.${t==null?void 0:t.options.name}`:t.name}}},xy={key:0,class:"title-name"},Ny={key:0,style:{"margin-right":"5px"}},By={key:1,style:{"margin-right":"5px"}},Sy={key:13,class:"tags-list"},Ey={key:15,class:"el-form-item-msg"};function Ty(t,n,o,a,r,l){const i=e.resolveComponent("el-skeleton"),s=e.resolveComponent("el-icon-question-filled"),d=e.resolveComponent("el-icon"),f=e.resolveComponent("el-tooltip"),p=e.resolveComponent("el-input"),m=e.resolveComponent("lw-upload"),_=e.resolveComponent("el-checkbox"),C=e.resolveComponent("el-checkbox-group"),k=e.resolveComponent("el-switch"),S=e.resolveComponent("el-option"),B=e.resolveComponent("el-select"),q=e.resolveComponent("el-cascader"),F=e.resolveComponent("el-date-picker"),V=e.resolveComponent("el-input-number"),j=e.resolveComponent("el-radio"),U=e.resolveComponent("el-radio-group"),L=e.resolveComponent("el-color-picker"),A=e.resolveComponent("el-rate"),z=e.resolveComponent("el-slider"),Y=e.resolveComponent("el-tag"),$=e.resolveComponent("el-button"),H=e.resolveComponent("el-form-item"),X=e.resolveComponent("el-col"),ie=e.resolveComponent("el-row"),R=e.resolveComponent("el-form"),ne=e.resolveDirective("loading");return r.renderLoading||Object.keys(r.form).length==0?(e.openBlock(),e.createBlock(i,{key:0,animated:""})):e.withDirectives((e.openBlock(),e.createBlock(R,{key:1,ref:"form",model:r.form,"label-width":o.config.labelWidth,"label-position":t.$i18n.locale=="en-us"?"top":o.config.labelPosition,disabled:o.isView,"element-loading-text":"Loading..."},{default:e.withCtx(()=>[e.createVNode(ie,{gutter:15},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.config.formItems,(h,T)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:T},[l.hideHandle(h)?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(X,{key:0,span:h.span||24},{default:e.withCtx(()=>[h.component=="divider"?(e.openBlock(),e.createElementBlock("div",xy,[e.createTextVNode(e.toDisplayString(h.label)+" ",1),h.tips?(e.openBlock(),e.createBlock(f,{key:0,content:h.tips},{default:e.withCtx(()=>[e.createVNode(d,null,{default:e.withCtx(()=>[e.createVNode(s)]),_:1})]),_:2},1032,["content"])):e.createCommentVNode("",!0)])):(e.openBlock(),e.createBlock(H,{key:1,prop:l.getPropName(h),rules:l.rulesHandle(h)},{label:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(h.label)+" ",1),h.tips?(e.openBlock(),e.createBlock(f,{key:0,content:h.tips},{default:e.withCtx(()=>[e.createVNode(d,null,{default:e.withCtx(()=>[e.createVNode(s)]),_:1})]),_:2},1032,["content"])):e.createCommentVNode("",!0)]),default:e.withCtx(()=>{var x,Ce,G,Te,Z,P,J,ee,ce,ye,we,xe,qe,Re,Ne,Ge,je,ae,v,Q,Be,Ie,dt,ve,Fe,_e,pe,O,Ye,Ze,Pe,Xe,Qe,ut,nt,b,c,u,g,y,w,N,E,I,M,W,de,te,ge,fe,ue,be,Ae;return[h.component=="input"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[(x=h==null?void 0:h.options)!=null&&x.name?(e.openBlock(),e.createBlock(p,{key:0,modelValue:r.form[h.name][h==null?void 0:h.options.name],"onUpdate:modelValue":D=>r.form[h.name][h==null?void 0:h.options.name]=D,placeholder:(Ce=h==null?void 0:h.options)==null?void 0:Ce.placeholder,clearable:"",type:h==null?void 0:h.options.type,disabled:(G=h==null?void 0:h.options)==null?void 0:G.disabled,autocomplete:((Te=h==null?void 0:h.options)==null?void 0:Te.autocomplete)||"off",maxlength:h==null?void 0:h.options.maxlength,"show-word-limit":""},e.createSlots({_:2},[h!=null&&h.options.prepend?{name:"prepend",fn:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(h==null?void 0:h.options.prepend),1)]),key:"0"}:void 0,h!=null&&h.options.append?{name:"append",fn:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(h==null?void 0:h.options.append),1)]),key:"1"}:void 0]),1032,["modelValue","onUpdate:modelValue","placeholder","type","disabled","autocomplete","maxlength"])):(e.openBlock(),e.createBlock(p,{key:1,modelValue:r.form[h.name],"onUpdate:modelValue":D=>r.form[h.name]=D,placeholder:(Z=h==null?void 0:h.options)==null?void 0:Z.placeholder,clearable:"",type:h==null?void 0:h.options.type,disabled:(P=h==null?void 0:h.options)==null?void 0:P.disabled,maxlength:h==null?void 0:h.options.maxlength,"show-word-limit":""},e.createSlots({_:2},[h!=null&&h.options.prepend?{name:"prepend",fn:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(h==null?void 0:h.options.prepend),1)]),key:"0"}:void 0,h!=null&&h.options.append?{name:"append",fn:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(h==null?void 0:h.options.append),1)]),key:"1"}:void 0]),1032,["modelValue","onUpdate:modelValue","placeholder","type","disabled","maxlength"]))],64)):h.component=="upload"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(h==null?void 0:h.options.items,(D,Ve)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:Ve},[h.name?(e.openBlock(),e.createElementBlock("div",Ny,[e.createVNode(m,{modelValue:r.form[h.name][D.name],"onUpdate:modelValue":De=>r.form[h.name][D.name]=De,maxSize:D.maxSize,accept:D.accept,title:D.label,parseData:h.parseData,disabled:D==null?void 0:D.disabled,multiple:D==null?void 0:D.multiple,limit:D==null?void 0:D.limit,returnFile:D==null?void 0:D.returnFile,tip:D==null?void 0:D.tip,apiObj:h.apiObj},null,8,["modelValue","onUpdate:modelValue","maxSize","accept","title","parseData","disabled","multiple","limit","returnFile","tip","apiObj"])])):(e.openBlock(),e.createElementBlock("div",By,[e.createVNode(m,{modelValue:r.form[D.name],"onUpdate:modelValue":De=>r.form[D.name]=De,maxSize:D.maxSize,accept:D.accept,title:D.label,parseData:h.parseData,disabled:D==null?void 0:D.disabled,multiple:D==null?void 0:D.multiple,limit:D==null?void 0:D.limit,returnFile:D==null?void 0:D.returnFile,tip:D==null?void 0:D.tip,apiObj:h.apiObj},null,8,["modelValue","onUpdate:modelValue","maxSize","accept","title","parseData","disabled","multiple","limit","returnFile","tip","apiObj"])]))],64))),128)):h.component=="checkbox"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[h.name?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(h==null?void 0:h.options.items,(D,Ve)=>(e.openBlock(),e.createBlock(_,{modelValue:r.form[h.name][D.name],"onUpdate:modelValue":De=>r.form[h.name][D.name]=De,label:D.label,key:Ve},null,8,["modelValue","onUpdate:modelValue","label"]))),128)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(h==null?void 0:h.options.items,(D,Ve)=>(e.openBlock(),e.createBlock(_,{modelValue:r.form[D.name],"onUpdate:modelValue":De=>r.form[D.name]=De,label:D.label,key:Ve},null,8,["modelValue","onUpdate:modelValue","label"]))),128))],64)):h.component=="checkboxGroup"?(e.openBlock(),e.createBlock(C,{key:3,modelValue:r.form[h.name],"onUpdate:modelValue":D=>r.form[h.name]=D},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h==null?void 0:h.options.items,D=>(e.openBlock(),e.createBlock(_,{key:D.value,label:D.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(D.label),1)]),_:2},1032,["label"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue"])):h.component=="switch"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[(J=h==null?void 0:h.options)!=null&&J.name?(e.openBlock(),e.createBlock(k,{key:0,modelValue:r.form[h.name][h==null?void 0:h.options.name],"onUpdate:modelValue":D=>r.form[h.name][h==null?void 0:h.options.name]=D,"inline-prompt":"","active-text":(ee=h==null?void 0:h.options)==null?void 0:ee.activeText,"inactive-text":(ce=h==null?void 0:h.options)==null?void 0:ce.inactiveText},null,8,["modelValue","onUpdate:modelValue","active-text","inactive-text"])):(e.openBlock(),e.createBlock(k,{key:1,modelValue:r.form[h.name],"onUpdate:modelValue":D=>r.form[h.name]=D,"inline-prompt":"","active-text":(ye=h==null?void 0:h.options)==null?void 0:ye.activeText,"inactive-text":(we=h==null?void 0:h.options)==null?void 0:we.inactiveText},null,8,["modelValue","onUpdate:modelValue","active-text","inactive-text"]))],64)):h.component=="select"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[(xe=h==null?void 0:h.options)!=null&&xe.name?(e.openBlock(),e.createBlock(B,{key:0,modelValue:r.form[h.name][h==null?void 0:h.options.name],"onUpdate:modelValue":D=>r.form[h.name][h==null?void 0:h.options.name]=D,multiple:(qe=h==null?void 0:h.options)==null?void 0:qe.multiple,"allow-create":(Re=h==null?void 0:h.options)==null?void 0:Re.allowCreate,"default-first-option":"",placeholder:((Ne=h==null?void 0:h.options)==null?void 0:Ne.placeholder)||"",clearable:(Ge=h==null?void 0:h.options)==null?void 0:Ge.clearable,disabled:(je=h==null?void 0:h.options)==null?void 0:je.disabled,filterable:"",style:{width:"100%"}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h==null?void 0:h.options.items,D=>(e.openBlock(),e.createBlock(S,{key:D.value,label:D.label,value:D.value},null,8,["label","value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","multiple","allow-create","placeholder","clearable","disabled"])):(e.openBlock(),e.createBlock(B,{key:1,modelValue:r.form[h.name],"onUpdate:modelValue":D=>r.form[h.name]=D,multiple:(ae=h==null?void 0:h.options)==null?void 0:ae.multiple,"allow-create":(v=h==null?void 0:h.options)==null?void 0:v.allowCreate,"default-first-option":"",placeholder:((Q=h==null?void 0:h.options)==null?void 0:Q.placeholder)||"",clearable:(Be=h==null?void 0:h.options)==null?void 0:Be.clearable,disabled:(Ie=h==null?void 0:h.options)==null?void 0:Ie.disabled,filterable:"",style:{width:"100%"}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h==null?void 0:h.options.items,D=>(e.openBlock(),e.createBlock(S,{key:D.value,label:D.label,value:D.value},null,8,["label","value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","multiple","allow-create","placeholder","clearable","disabled"]))],64)):h.component=="cascader"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:6},[(dt=h==null?void 0:h.options)!=null&&dt.name?(e.openBlock(),e.createBlock(q,{key:0,modelValue:r.form[h.name][h==null?void 0:h.options.name],"onUpdate:modelValue":D=>r.form[h.name][h==null?void 0:h.options.name]=D,style:{width:"100%"},options:h==null?void 0:h.options.items,clearable:""},null,8,["modelValue","onUpdate:modelValue","options"])):(e.openBlock(),e.createBlock(q,{key:1,modelValue:r.form[h.name],"onUpdate:modelValue":D=>r.form[h.name]=D,style:{width:"100%"},options:h==null?void 0:h.options.items,clearable:""},null,8,["modelValue","onUpdate:modelValue","options"]))],64)):h.component=="date"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:7},[(ve=h==null?void 0:h.options)!=null&&ve.name?(e.openBlock(),e.createBlock(F,{key:0,modelValue:r.form[h.name][h==null?void 0:h.options.name],"onUpdate:modelValue":D=>r.form[h.name][h==null?void 0:h.options.name]=D,style:{width:"100%"},type:h==null?void 0:h.options.type,"start-placeholder":h==null?void 0:h.options.startPlaceholder,"end-placeholder":h==null?void 0:h.options.endPlaceholder,shortcuts:h==null?void 0:h.options.shortcuts,"disabled-date":(Fe=h==null?void 0:h.options)==null?void 0:Fe.disabledDate,"default-time":h==null?void 0:h.options.defaultTime,disabled:(_e=h==null?void 0:h.options)==null?void 0:_e.disabled,"value-format":h==null?void 0:h.options.valueFormat,format:h==null?void 0:h.options.format,placeholder:(h==null?void 0:h.options.placeholder)||"请选择"},null,8,["modelValue","onUpdate:modelValue","type","start-placeholder","end-placeholder","shortcuts","disabled-date","default-time","disabled","value-format","format","placeholder"])):(e.openBlock(),e.createBlock(F,{key:1,modelValue:r.form[h.name],"onUpdate:modelValue":D=>r.form[h.name]=D,style:{width:"100%"},type:h==null?void 0:h.options.type,"start-placeholder":h==null?void 0:h.options.startPlaceholder,"end-placeholder":h==null?void 0:h.options.endPlaceholder,shortcuts:h==null?void 0:h.options.shortcuts,"disabled-date":(pe=h==null?void 0:h.options)==null?void 0:pe.disabledDate,"default-time":h==null?void 0:h.options.defaultTime,disabled:(O=h==null?void 0:h.options)==null?void 0:O.disabled,"value-format":h==null?void 0:h.options.valueFormat,format:h==null?void 0:h.options.format,placeholder:(h==null?void 0:h.options.placeholder)||"请选择"},null,8,["modelValue","onUpdate:modelValue","type","start-placeholder","end-placeholder","shortcuts","disabled-date","default-time","disabled","value-format","format","placeholder"]))],64)):h.component=="number"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:8},[(Ye=h==null?void 0:h.options)!=null&&Ye.name?(e.openBlock(),e.createBlock(V,{key:0,modelValue:r.form[h.name][h==null?void 0:h.options.name],"onUpdate:modelValue":D=>r.form[h.name][h==null?void 0:h.options.name]=D,disabled:(Ze=h==null?void 0:h.options)==null?void 0:Ze.disabled,min:(Pe=h==null?void 0:h.options)==null?void 0:Pe.min,max:(Xe=h==null?void 0:h.options)==null?void 0:Xe.max,step:((Qe=h==null?void 0:h.options)==null?void 0:Qe.step)||1,precision:(ut=h==null?void 0:h.options)==null?void 0:ut.precision,placeholder:((nt=h==null?void 0:h.options)==null?void 0:nt.placeholder)||"","controls-position":((b=h==null?void 0:h.options)==null?void 0:b.controlsPosition)||"right"},e.createSlots({_:2},[(c=h==null?void 0:h.options)!=null&&c.suffix?{name:"suffix",fn:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(h==null?void 0:h.options.suffix),1)]),key:"0"}:void 0]),1032,["modelValue","onUpdate:modelValue","disabled","min","max","step","precision","placeholder","controls-position"])):(e.openBlock(),e.createBlock(V,{key:1,modelValue:r.form[h.name],"onUpdate:modelValue":D=>r.form[h.name]=D,disabled:(u=h==null?void 0:h.options)==null?void 0:u.disabled,min:(g=h==null?void 0:h.options)==null?void 0:g.min,max:(y=h==null?void 0:h.options)==null?void 0:y.max,step:((w=h==null?void 0:h.options)==null?void 0:w.step)||1,precision:(N=h==null?void 0:h.options)==null?void 0:N.precision,placeholder:((E=h==null?void 0:h.options)==null?void 0:E.placeholder)||"","controls-position":((I=h==null?void 0:h.options)==null?void 0:I.controlsPosition)||"right"},e.createSlots({_:2},[(M=h==null?void 0:h.options)!=null&&M.suffix?{name:"suffix",fn:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(h==null?void 0:h.options.suffix),1)]),key:"0"}:void 0]),1032,["modelValue","onUpdate:modelValue","disabled","min","max","step","precision","placeholder","controls-position"]))],64)):h.component=="radio"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:9},[(W=h==null?void 0:h.options)!=null&&W.name?(e.openBlock(),e.createBlock(U,{key:0,modelValue:r.form[h.name][h==null?void 0:h.options.name],"onUpdate:modelValue":D=>r.form[h.name][h==null?void 0:h.options.name]=D,disabled:(de=h==null?void 0:h.options)==null?void 0:de.disabled},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h==null?void 0:h.options.items,D=>(e.openBlock(),e.createBlock(j,{key:D.value,value:D.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(D.label),1)]),_:2},1032,["value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","disabled"])):(e.openBlock(),e.createBlock(U,{key:1,modelValue:r.form[h.name],"onUpdate:modelValue":D=>r.form[h.name]=D,disabled:(te=h==null?void 0:h.options)==null?void 0:te.disabled},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h==null?void 0:h.options.items,D=>(e.openBlock(),e.createBlock(j,{key:D.value,value:D.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(D.label),1)]),_:2},1032,["value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","disabled"]))],64)):h.component=="color"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:10},[(ge=h==null?void 0:h.options)!=null&&ge.name?(e.openBlock(),e.createBlock(L,{key:0,modelValue:r.form[h.name][h==null?void 0:h.options.name],"onUpdate:modelValue":D=>r.form[h.name][h==null?void 0:h.options.name]=D},null,8,["modelValue","onUpdate:modelValue"])):(e.openBlock(),e.createBlock(L,{key:1,modelValue:r.form[h.name],"onUpdate:modelValue":D=>r.form[h.name]=D},null,8,["modelValue","onUpdate:modelValue"]))],64)):h.component=="rate"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:11},[(fe=h==null?void 0:h.options)!=null&&fe.name?(e.openBlock(),e.createBlock(A,{key:0,style:{"margin-top":"6px"},modelValue:r.form[h.name][h==null?void 0:h.options.name],"onUpdate:modelValue":D=>r.form[h.name][h==null?void 0:h.options.name]=D},null,8,["modelValue","onUpdate:modelValue"])):(e.openBlock(),e.createBlock(A,{key:1,style:{"margin-top":"6px"},modelValue:r.form[h.name],"onUpdate:modelValue":D=>r.form[h.name]=D},null,8,["modelValue","onUpdate:modelValue"]))],64)):h.component=="slider"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:12},[(ue=h==null?void 0:h.options)!=null&&ue.name?(e.openBlock(),e.createBlock(z,{key:0,modelValue:r.form[h.name][h==null?void 0:h.options.name],"onUpdate:modelValue":D=>r.form[h.name][h==null?void 0:h.options.name]=D,marks:h==null?void 0:h.options.marks},null,8,["modelValue","onUpdate:modelValue","marks"])):(e.openBlock(),e.createBlock(z,{key:1,modelValue:r.form[h.name],"onUpdate:modelValue":D=>r.form[h.name]=D,marks:h==null?void 0:h.options.marks},null,8,["modelValue","onUpdate:modelValue","marks"]))],64)):h.component=="tags"?(e.openBlock(),e.createElementBlock("div",Sy,[(be=h==null?void 0:h.options)!=null&&be.name?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(r.form[h.name][(Ae=h==null?void 0:h.options)==null?void 0:Ae.name],D=>(e.openBlock(),e.createBlock(Y,{key:D,closable:"","disable-transitions":!1,onClose:Ve=>l.tagClose(D,r.form[h.name][h==null?void 0:h.options.name])},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(D),1)]),_:2},1032,["onClose"]))),128)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(r.form[h.name],D=>(e.openBlock(),e.createBlock(Y,{key:D,closable:"","disable-transitions":!1,onClose:Ve=>l.tagClose(D,r.form[h.name])},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(D),1)]),_:2},1032,["onClose"]))),128)),r.tagVisible?(e.openBlock(),e.createBlock(p,{key:2,modelValue:r.tagValue,"onUpdate:modelValue":n[0]||(n[0]=D=>r.tagValue=D),class:"w-20",size:"small",onKeyup:e.withKeys(D=>l.tagInputConfirm(h,r.form),["enter"]),onBlur:D=>l.tagInputConfirm(h,r.form)},null,8,["modelValue","onKeyup","onBlur"])):(e.openBlock(),e.createBlock($,{key:3,class:"button-new-tag",size:"small",onClick:n[1]||(n[1]=D=>r.tagVisible=!0)},{default:e.withCtx(()=>n[2]||(n[2]=[e.createTextVNode(" + 添加 ")])),_:1}))])):e.renderSlot(t.$slots,h.component,{key:14,itemCur:h,formCur:r.form},()=>[e.createVNode(Y,{type:"danger"},{default:e.withCtx(()=>[e.createTextVNode("["+e.toDisplayString(h.component)+"] 没有这个默认组件也未自定义插槽内容",1)]),_:2},1024)],!0),h.message?(e.openBlock(),e.createElementBlock("div",Ey,e.toDisplayString(h.message),1)):e.createCommentVNode("",!0)]}),_:2},1032,["prop","rules"]))]),_:2},1032,["span"]))],64))),128)),e.createVNode(X,{span:24},{default:e.withCtx(()=>[e.createVNode(H,null,{default:e.withCtx(()=>[e.renderSlot(t.$slots,"default",{},()=>[e.createVNode($,{type:"primary",onClick:l.submit},{default:e.withCtx(()=>n[3]||(n[3]=[e.createTextVNode("提交")])),_:1},8,["onClick"])],!0)]),_:3})]),_:3})]),_:3})]),_:3},8,["model","label-width","label-position","disabled"])),[[ne,o.loading]])}const es=le(Cy,[["render",Ty],["__scopeId","data-v-8b6b742d"]]),Iy={name:"FormItem",data(){return{tagVisible:{},dataForm:{},objItem:{},tagValue:""}},components:{lwUpload:St},props:{item:{type:Object,default:()=>{}},index:{type:Number,default:0},form:{type:Object,default:()=>{}}},watch:{item:{handler(t){this.objItem=t},immediate:!0,deep:!0},form:{handler(t){var n,o;this.item.component==="checkbox"||this.item.component==="upload"?(o=(n=this.objItem.options)==null?void 0:n.items)==null||o.forEach(a=>{a.value=this.flattenObject(this.form,a.name,a.value)}):this.objItem.value=this.flattenObject(this.form,this.item.name,this.objItem.value)},immediate:!0,deep:!0},objItem:{handler(t){var n,o;t.component==="checkbox"||t.component==="upload"?(o=(n=t.options)==null?void 0:n.items)==null||o.forEach(a=>{this.unflattenObject(this.form,a.name,a.value)}):this.unflattenObject(this.form,t.name,t.value)},deep:!0}},methods:{flattenObject(t,n,o=""){if(!n||!t)return!1;const a=n.split(".");let r=t;for(let l=0;l<a.length;l++)r[a[l]]===void 0&&(r[a[l]]=l===a.length-1?o:{}),r=r[a[l]];return r},unflattenObject(t,n,o){if(!n||!t)return!1;const a=n.split(".");a.forEach((r,l)=>{l===a.length-1?t[r]=o:((!t[r]||typeof t[r]!="object")&&(t[r]={}),t=t[r])})},tagClose(t,n){n.splice(n.indexOf(t),1)},tagInputConfirm(t,n){this.tagValue&&(n=n||[],n.push(this.tagValue)),this.tagVisible[t.name]=!1,this.tagValue=""},getPropName(t){return t.component=="checkbox"||t.component=="upload"?t==null?void 0:t.options.items[0].name:t.name},rulesHandle(t){if(t.requiredHandle)try{const o=new Function("form",`return ${t.requiredHandle.replace(/\$/g,"form")}`)(this.form),a=t.rules.find(r=>"required"in r);a&&(a.required=o)}catch(n){console.error("Error requiredHandle function:",n)}return t.rules}}},Dy=["id","data-index"],Fy={style:{"max-width":"300px",display:"inline-block"}},qy={key:14,class:"tags-list"},Ry={key:16,class:"el-form-item-msg"};function Ay(t,n,o,a,r,l){var X;const i=e.resolveComponent("el-icon-question-filled"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("el-tooltip"),f=e.resolveComponent("el-input"),p=e.resolveComponent("lw-upload"),m=e.resolveComponent("el-checkbox"),_=e.resolveComponent("el-checkbox-group"),C=e.resolveComponent("el-switch"),k=e.resolveComponent("el-option"),S=e.resolveComponent("el-select"),B=e.resolveComponent("el-tree-select"),q=e.resolveComponent("el-cascader"),F=e.resolveComponent("el-date-picker"),V=e.resolveComponent("el-input-number"),j=e.resolveComponent("el-radio"),U=e.resolveComponent("el-radio-group"),L=e.resolveComponent("el-color-picker"),A=e.resolveComponent("el-rate"),z=e.resolveComponent("el-slider"),Y=e.resolveComponent("el-tag"),$=e.resolveComponent("el-button"),H=e.resolveComponent("el-form-item");return o.item.component=="divider"?(e.openBlock(),e.createElementBlock("div",{key:0,class:"title-name title-name-divider",id:"divider-"+o.index,"data-index":o.index},[e.createTextVNode(e.toDisplayString(o.item.label)+" ",1),o.item.tips?(e.openBlock(),e.createBlock(d,{key:0},{content:e.withCtx(()=>[e.createElementVNode("span",Fy,e.toDisplayString(o.item.tips),1)]),default:e.withCtx(()=>[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i)]),_:1})]),_:1})):e.createCommentVNode("",!0)],8,Dy)):(e.openBlock(),e.createBlock(H,{key:1,class:e.normalizeClass({"form-item-name-null":!((X=o.item)!=null&&X.label)}),prop:l.getPropName(o.item),rules:l.rulesHandle(o.item)},{label:e.withCtx(()=>{var ie;return[e.createTextVNode(e.toDisplayString(o.item.label)+" ",1),o.item.tips?(e.openBlock(),e.createBlock(d,{key:0,"raw-content":(ie=o.item)==null?void 0:ie.rawContent,content:o.item.tips},{default:e.withCtx(()=>[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i)]),_:1})]),_:1},8,["raw-content","content"])):e.createCommentVNode("",!0)]}),default:e.withCtx(()=>{var ie,R,ne,h,T,x,Ce,G,Te,Z,P,J,ee,ce,ye,we,xe,qe,Re,Ne,Ge,je,ae,v,Q,Be,Ie,dt,ve,Fe,_e,pe,O,Ye,Ze,Pe,Xe,Qe,ut,nt,b,c,u,g,y,w,N,E,I,M,W,de,te,ge,fe,ue,be,Ae,D,Ve,De,oe,bt,yt,ot,qt,Le,Vn,Bt,Up,jp,zp,Hp,Kp,Gp,Yp,$p,Wp,Jp,Zp,Xp,Qp,em,tm,nm,om,rm,am;return[o.item.component=="input"?(e.openBlock(),e.createBlock(f,{key:0,modelValue:r.objItem.value,"onUpdate:modelValue":n[0]||(n[0]=K=>r.objItem.value=K),placeholder:(R=(ie=o.item)==null?void 0:ie.options)==null?void 0:R.placeholder,clearable:"",type:(h=(ne=o.item)==null?void 0:ne.options)==null?void 0:h.type,disabled:(x=(T=o.item)==null?void 0:T.options)==null?void 0:x.disabled,autocomplete:((G=(Ce=o.item)==null?void 0:Ce.options)==null?void 0:G.autocomplete)||"off",maxlength:(Z=(Te=o.item)==null?void 0:Te.options)==null?void 0:Z.maxlength,"show-word-limit":""},e.createSlots({_:2},[(J=(P=o.item)==null?void 0:P.options)!=null&&J.prepend?{name:"prepend",fn:e.withCtx(()=>{var K;return[e.createTextVNode(e.toDisplayString((K=o.item)==null?void 0:K.options.prepend),1)]}),key:"0"}:void 0,(ce=(ee=o.item)==null?void 0:ee.options)!=null&&ce.append?{name:"append",fn:e.withCtx(()=>{var K;return[e.createTextVNode(e.toDisplayString((K=o.item)==null?void 0:K.options.append),1)]}),key:"1"}:void 0]),1032,["modelValue","placeholder","type","disabled","autocomplete","maxlength"])):o.item.component=="upload"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList((ye=r.objItem)==null?void 0:ye.options.items,(K,Ee)=>(e.openBlock(),e.createBlock(p,{key:Ee,modelValue:K.value,"onUpdate:modelValue":ji=>K.value=ji,height:o.item.height,width:o.item.width,maxSize:K.maxSize,accept:K.accept,title:K.label,parseData:o.item.parseData,disabled:K==null?void 0:K.disabled,multiple:K==null?void 0:K.multiple,limit:K==null?void 0:K.limit,returnFile:K==null?void 0:K.returnFile,tip:K==null?void 0:K.tip,apiObj:o.item.apiObj},null,8,["modelValue","onUpdate:modelValue","height","width","maxSize","accept","title","parseData","disabled","multiple","limit","returnFile","tip","apiObj"]))),128)):o.item.component=="checkbox"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList((we=r.objItem)==null?void 0:we.options.items,(K,Ee)=>(e.openBlock(),e.createBlock(m,{modelValue:K.value,"onUpdate:modelValue":ji=>K.value=ji,label:K.label,key:Ee},null,8,["modelValue","onUpdate:modelValue","label"]))),128)):o.item.component=="checkboxGroup"?(e.openBlock(),e.createBlock(_,{key:3,modelValue:r.objItem.value,"onUpdate:modelValue":n[1]||(n[1]=K=>r.objItem.value=K)},{default:e.withCtx(()=>{var K;return[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((K=o.item)==null?void 0:K.options.items,Ee=>(e.openBlock(),e.createBlock(m,{key:Ee.value,value:Ee.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(Ee.label),1)]),_:2},1032,["value"]))),128))]}),_:1},8,["modelValue"])):o.item.component=="switch"?(e.openBlock(),e.createBlock(C,{key:4,modelValue:r.objItem.value,"onUpdate:modelValue":n[2]||(n[2]=K=>r.objItem.value=K),"inline-prompt":"","active-text":(qe=(xe=o.item)==null?void 0:xe.options)==null?void 0:qe.activeText,"inactive-text":(Ne=(Re=o.item)==null?void 0:Re.options)==null?void 0:Ne.inactiveText},null,8,["modelValue","active-text","inactive-text"])):o.item.component=="select"?(e.openBlock(),e.createBlock(S,{key:5,modelValue:r.objItem.value,"onUpdate:modelValue":n[3]||(n[3]=K=>r.objItem.value=K),multiple:(je=(Ge=o.item)==null?void 0:Ge.options)==null?void 0:je.multiple,"allow-create":(v=(ae=o.item)==null?void 0:ae.options)==null?void 0:v.allowCreate,"default-first-option":"",placeholder:((Be=(Q=o.item)==null?void 0:Q.options)==null?void 0:Be.placeholder)||"",clearable:(dt=(Ie=o.item)==null?void 0:Ie.options)==null?void 0:dt.clearable,"collapse-tags":(Fe=(ve=o.item)==null?void 0:ve.options)==null?void 0:Fe.collapseTags,"collapse-tags-tooltip":(pe=(_e=o.item)==null?void 0:_e.options)==null?void 0:pe.collapseTagsTooltip,disabled:(O=o.item)==null?void 0:O.options.disabled,filterable:"",style:{width:"100%"}},{default:e.withCtx(()=>{var K;return[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((K=o.item)==null?void 0:K.options.items,Ee=>(e.openBlock(),e.createBlock(k,{key:Ee.value,label:Ee.label,value:Ee.value},null,8,["label","value"]))),128))]}),_:1},8,["modelValue","multiple","allow-create","placeholder","clearable","collapse-tags","collapse-tags-tooltip","disabled"])):o.item.component=="treeSelect"?(e.openBlock(),e.createBlock(B,{key:6,modelValue:r.objItem.value,"onUpdate:modelValue":n[4]||(n[4]=K=>r.objItem.value=K),props:(Ze=(Ye=o.item)==null?void 0:Ye.options)==null?void 0:Ze.props,"node-Key":(Xe=(Pe=o.item)==null?void 0:Pe.options)==null?void 0:Xe.nodeKey,multiple:(ut=(Qe=o.item)==null?void 0:Qe.options)==null?void 0:ut.multiple,"check-Strictly":(b=(nt=o.item)==null?void 0:nt.options)==null?void 0:b.checkStrictly,data:(u=(c=o.item)==null?void 0:c.options)==null?void 0:u.items},null,8,["modelValue","props","node-Key","multiple","check-Strictly","data"])):o.item.component=="cascader"?(e.openBlock(),e.createBlock(q,{key:7,modelValue:r.objItem.value,"onUpdate:modelValue":n[5]||(n[5]=K=>r.objItem.value=K),style:{width:"100%"},props:(y=(g=o.item)==null?void 0:g.options)==null?void 0:y.props,separator:(N=(w=o.item)==null?void 0:w.options)==null?void 0:N.separator,disabled:(I=(E=o.item)==null?void 0:E.options)==null?void 0:I.disabled,options:(M=o.item)==null?void 0:M.options.items,clearable:""},null,8,["modelValue","props","separator","disabled","options"])):o.item.component=="date"?(e.openBlock(),e.createBlock(F,{key:8,modelValue:r.objItem.value,"onUpdate:modelValue":n[6]||(n[6]=K=>r.objItem.value=K),style:{width:"100%"},type:(de=(W=o.item)==null?void 0:W.options)==null?void 0:de.type,"start-placeholder":(ge=(te=o.item)==null?void 0:te.options)==null?void 0:ge.startPlaceholder,"end-placeholder":(ue=(fe=o.item)==null?void 0:fe.options)==null?void 0:ue.endPlaceholder,shortcuts:(Ae=(be=o.item)==null?void 0:be.options)==null?void 0:Ae.shortcuts,"disabled-date":(Ve=(D=o.item)==null?void 0:D.options)==null?void 0:Ve.disabledDate,"default-time":(oe=(De=o.item)==null?void 0:De.options)==null?void 0:oe.defaultTime,disabled:(yt=(bt=o.item)==null?void 0:bt.options)==null?void 0:yt.disabled,"value-format":(qt=(ot=o.item)==null?void 0:ot.options)==null?void 0:qt.valueFormat,format:(Vn=(Le=o.item)==null?void 0:Le.options)==null?void 0:Vn.format,placeholder:((Up=(Bt=o.item)==null?void 0:Bt.options)==null?void 0:Up.placeholder)||"请选择"},null,8,["modelValue","type","start-placeholder","end-placeholder","shortcuts","disabled-date","default-time","disabled","value-format","format","placeholder"])):o.item.component=="number"?(e.openBlock(),e.createBlock(V,{key:9,modelValue:r.objItem.value,"onUpdate:modelValue":n[7]||(n[7]=K=>r.objItem.value=K),disabled:(zp=(jp=o.item)==null?void 0:jp.options)==null?void 0:zp.disabled,min:(Kp=(Hp=o.item)==null?void 0:Hp.options)==null?void 0:Kp.min,max:(Yp=(Gp=o.item)==null?void 0:Gp.options)==null?void 0:Yp.max,step:((Wp=($p=o.item)==null?void 0:$p.options)==null?void 0:Wp.step)||1,precision:(Zp=(Jp=o.item)==null?void 0:Jp.options)==null?void 0:Zp.precision,placeholder:((Qp=(Xp=o.item)==null?void 0:Xp.options)==null?void 0:Qp.placeholder)||"","controls-position":((tm=(em=o.item)==null?void 0:em.options)==null?void 0:tm.controlsPosition)||"right"},e.createSlots({_:2},[(om=(nm=o.item)==null?void 0:nm.options)!=null&&om.suffix?{name:"suffix",fn:e.withCtx(()=>{var K;return[e.createElementVNode("span",null,e.toDisplayString((K=o.item)==null?void 0:K.options.suffix),1)]}),key:"0"}:void 0]),1032,["modelValue","disabled","min","max","step","precision","placeholder","controls-position"])):o.item.component=="radio"?(e.openBlock(),e.createBlock(U,{key:10,modelValue:r.objItem.value,"onUpdate:modelValue":n[8]||(n[8]=K=>r.objItem.value=K),disabled:(rm=o.item)==null?void 0:rm.options.disabled},{default:e.withCtx(()=>{var K;return[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((K=o.item)==null?void 0:K.options.items,Ee=>(e.openBlock(),e.createBlock(j,{key:Ee.value,value:Ee.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(Ee.label),1)]),_:2},1032,["value"]))),128))]}),_:1},8,["modelValue","disabled"])):o.item.component=="color"?(e.openBlock(),e.createBlock(L,{key:11,modelValue:r.objItem.value,"onUpdate:modelValue":n[9]||(n[9]=K=>r.objItem.value=K)},null,8,["modelValue"])):o.item.component=="rate"?(e.openBlock(),e.createBlock(A,{key:12,style:{"margin-top":"6px"},modelValue:r.objItem.value,"onUpdate:modelValue":n[10]||(n[10]=K=>r.objItem.value=K)},null,8,["modelValue"])):o.item.component=="slider"?(e.openBlock(),e.createBlock(z,{key:13,modelValue:r.objItem.value,"onUpdate:modelValue":n[11]||(n[11]=K=>r.objItem.value=K),marks:(am=o.item)==null?void 0:am.options.marks},null,8,["modelValue","marks"])):o.item.component=="tags"?(e.openBlock(),e.createElementBlock("div",qy,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.objItem.value,K=>(e.openBlock(),e.createBlock(Y,{key:K,closable:"","disable-transitions":!1,onClose:Ee=>l.tagClose(K,r.objItem.value)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(K),1)]),_:2},1032,["onClose"]))),128)),r.tagVisible[o.item.name]?(e.openBlock(),e.createBlock(f,{key:0,modelValue:r.tagValue,"onUpdate:modelValue":n[12]||(n[12]=K=>r.tagValue=K),class:"w-20",size:"small",onKeyup:n[13]||(n[13]=e.withKeys(K=>l.tagInputConfirm(o.item,r.objItem.value),["enter"])),onBlur:n[14]||(n[14]=K=>l.tagInputConfirm(o.item,r.objItem.value))},null,8,["modelValue"])):(e.openBlock(),e.createBlock($,{key:1,class:"button-new-tag",size:"small",onClick:n[15]||(n[15]=K=>r.tagVisible[o.item.name]=!0)},{default:e.withCtx(()=>{var K,Ee;return[e.createTextVNode(" + "+e.toDisplayString(((Ee=(K=o.item)==null?void 0:K.options)==null?void 0:Ee.addText)||"添加"),1)]}),_:1}))])):e.renderSlot(t.$slots,o.item.component,{key:15,itemCur:o.item,formCur:o.form},()=>[e.createVNode(Y,{type:"danger"},{default:e.withCtx(()=>[e.createTextVNode("["+e.toDisplayString(o.item.component)+"] 没有这个默认组件也未自定义插槽内容",1)]),_:1})],!0),o.item.message?(e.openBlock(),e.createElementBlock("div",Ry,e.toDisplayString(o.item.message),1)):e.createCommentVNode("",!0)]}),_:3},8,["class","prop","rules"]))}const ts=le(Iy,[["render",Ay],["__scopeId","data-v-9b3043e5"]]),Oy={components:{FormItem:ts},props:{modelValue:{type:Object,default:()=>{}},config:{type:Object,default:()=>{}},loading:{type:Boolean,default:!1},isView:{type:Boolean,default:!1},showMenu:{type:Boolean,default:!1}},data(){return{form:{},affixIndex:0,isChange:!0,scrollObserverEnabled:!0,renderLoading:!1}},watch:{modelValue:{handler(t,n){this.hasConfig&&this.isChange&&(this.form=t)},deep:!0},config:{handler(t){this.render(t),this.showMenu&&this.$nextTick(()=>{this.handleScroll()}),this.$emit("update:config",t)},immediate:!0,deep:!0}},computed:{hasConfig(){return Object.keys(this.config).length>0},hasValue(){return Object.keys(this.modelValue).length>0}},mounted(){this.hasConfig&&this.render()},beforeDestroy(){},methods:{render(t=this.config){function n(a,r){const l={};return a.forEach(i=>{var d,f,p,m;if((i.component==="checkbox"||i.component==="upload")&&((f=(d=i.options)==null?void 0:d.items)==null||f.forEach(_=>{if(!(_!=null&&_.name))return!1;l[_.name]=(r==null?void 0:r[_.name])??_.value})),!(i!=null&&i.name))return!1;let s=r==null?void 0:r[i.name];i.component==="list"?l[i.name]=((p=i.value)==null?void 0:p.map((_,C)=>(s?s=(r==null?void 0:r[i.name][C])||{}:s=[],n(_,s))))||[]:i.component==="object"?l[i.name]=n(i.value,s||{}):i.component==="number"?l[i.name]=s??(i.value!==void 0?Number(i.value):((m=i.options)==null?void 0:m.min)||0):l[i.name]=s??i.value}),l}let o=n(t.formItems,this.modelValue);o={...this.modelValue,...o},this.form=this.parseNestedObject(o),this.$emit("update:modelValue",this.form)},parseNestedObject(t){const n={};for(const[o,a]of Object.entries(t)){const r=o.split(".");let l=n;r.forEach((i,s)=>{l[i]||(l[i]=s===r.length-1?a:{}),l=l[i]}),delete t[o]}return n},hideHandle(t){return typeof(t==null?void 0:t.hideHandle)=="string"?new Function("form",`return ${t==null?void 0:t.hideHandle.replace(/\$/g,"form")}`)(this.form):typeof(t==null?void 0:t.hideHandle)=="boolean"?t.hideHandle:!1},validate(t,n){return this.$refs.form.validate(t,n)},clearValidate(t,n){return this.$refs.form.clearValidate()},scrollToField(t){return this.$refs.form.scrollToField(t)},resetFields(){return this.$refs.form.resetFields()},submit(){this.$emit("submit",this.form)},clickAffix(t){this.affixIndex=t;const n=document.getElementById("divider-"+t);n&&n.scrollIntoView({behavior:"smooth",block:"start"}),this.scrollObserverEnabled=!1,setTimeout(()=>{this.scrollObserverEnabled=!0},500)},handleScroll(){const t=document.querySelectorAll(".title-name-divider"),n=document.querySelector(".el-main");let o=this;const a=new IntersectionObserver(r=>{let l=r[0];const s=l.target.getBoundingClientRect().top;if(s>=0&&s<=100&&o.scrollObserverEnabled){const d=l.target.getAttribute("data-index");o.affixIndex=d}},{root:n,rootMargin:"0px 0px 70% 0px"});t.forEach(r=>{a.observe(r)})}}},vy={class:"affix-body"},Py=["onClick"];function Ly(t,n,o,a,r,l){const i=e.resolveComponent("el-affix"),s=e.resolveComponent("el-skeleton"),d=e.resolveComponent("el-tag"),f=e.resolveComponent("FormItem"),p=e.resolveComponent("el-col"),m=e.resolveComponent("el-button"),_=e.resolveComponent("el-form-item"),C=e.resolveComponent("el-row"),k=e.resolveComponent("el-form"),S=e.resolveDirective("loading");return e.openBlock(),e.createElementBlock(e.Fragment,null,[o.showMenu?(e.openBlock(),e.createBlock(i,{key:0,offset:100,style:{width:"100%",height:"45px"}},{default:e.withCtx(()=>[e.createElementVNode("ul",vy,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.config.formItems,(B,q)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:q},[B.component==="divider"?(e.openBlock(),e.createElementBlock("a",{key:0,class:e.normalizeClass(["anchor-link",{active:r.affixIndex==q}]),onClick:F=>l.clickAffix(q)},e.toDisplayString(B.label),11,Py)):e.createCommentVNode("",!0)],64))),128))])]),_:1})):e.createCommentVNode("",!0),r.renderLoading||Object.keys(r.form).length==0?(e.openBlock(),e.createBlock(s,{key:1,animated:""})):e.withDirectives((e.openBlock(),e.createBlock(k,{key:2,ref:"form",model:r.form,"label-width":o.config.labelWidth,"label-position":t.$i18n.locale=="en-us"?"top":o.config.labelPosition,disabled:o.isView,"element-loading-text":"Loading..."},{default:e.withCtx(()=>[e.createVNode(C,{gutter:15},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.config.formItems,(B,q)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[l.hideHandle(B)?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(p,{key:0,span:B.span||24},{default:e.withCtx(()=>[e.createVNode(f,{item:B,form:r.form,index:q},e.createSlots({_:2},[["input","upload","checkbox","checkboxGroup","switch","select","treeSelect","cascader","date","number","radio","color","rate","slider","tags"].includes(B.component)?void 0:{name:B.component,fn:e.withCtx(()=>[e.renderSlot(t.$slots,B.component,{itemCur:B,formCur:r.form},()=>[e.createVNode(d,{type:"danger"},{default:e.withCtx(()=>[e.createTextVNode("["+e.toDisplayString(B.component)+"] 没有这个默认组件也未自定义插槽内容",1)]),_:2},1024)],!0)]),key:"0"}]),1032,["item","form","index"])]),_:2},1032,["span"]))],64))),256)),e.createVNode(p,{span:24},{default:e.withCtx(()=>[e.createVNode(_,null,{default:e.withCtx(()=>[e.renderSlot(t.$slots,"default",{},()=>[e.createVNode(m,{type:"primary",onClick:l.submit},{default:e.withCtx(()=>n[0]||(n[0]=[e.createTextVNode("提交")])),_:1},8,["onClick"])],!0)]),_:3})]),_:3})]),_:3})]),_:3},8,["model","label-width","label-position","disabled"])),[[S,o.loading]])],64)}const ns=le(Oy,[["render",Ly],["__scopeId","data-v-a28f7b39"]]),My={icons:[{name:"默认",key:"element",icons:["el-icon-aim","el-icon-add-location","el-icon-apple","el-icon-alarm-clock","el-icon-arrow-down","el-icon-arrow-down-bold","el-icon-arrow-left","el-icon-arrow-left-bold","el-icon-arrow-right-bold","el-icon-arrow-up","el-icon-back","el-icon-bell","el-icon-baseball","el-icon-bicycle","el-icon-bell-filled","el-icon-basketball","el-icon-bottom","el-icon-box","el-icon-briefcase","el-icon-brush-filled","el-icon-bowl","el-icon-avatar","el-icon-brush","el-icon-burger","el-icon-camera","el-icon-bottom-left","el-icon-calendar","el-icon-caret-bottom","el-icon-caret-left","el-icon-caret-right","el-icon-caret-top","el-icon-chat-dot-square","el-icon-cellphone","el-icon-chat-dot-round","el-icon-chat-line-square","el-icon-chat-line-round","el-icon-chat-round","el-icon-check","el-icon-chat-square","el-icon-cherry","el-icon-chicken","el-icon-circle-check-filled","el-icon-circle-check","el-icon-checked","el-icon-circle-close-filled","el-icon-circle-close","el-icon-arrow-right","el-icon-circle-plus","el-icon-clock","el-icon-close-bold","el-icon-close","el-icon-cloudy","el-icon-circle-plus-filled","el-icon-coffee-cup","el-icon-cold-drink","el-icon-coin","el-icon-arrow-up-bold","el-icon-collection-tag","el-icon-bottom-right","el-icon-coffee","el-icon-camera-filled","el-icon-collection","el-icon-cpu","el-icon-crop","el-icon-coordinate","el-icon-d-arrow-left","el-icon-compass","el-icon-connection","el-icon-credit-card","el-icon-data-board","el-icon-d-arrow-right","el-icon-dessert","el-icon-delete-location","el-icon-d-caret","el-icon-delete","el-icon-dish","el-icon-dish-dot","el-icon-document-copy","el-icon-discount","el-icon-document-checked","el-icon-document-add","el-icon-document-remove","el-icon-data-analysis","el-icon-delete-filled","el-icon-download","el-icon-drizzling","el-icon-eleme","el-icon-eleme-filled","el-icon-edit","el-icon-failed","el-icon-expand","el-icon-female","el-icon-document","el-icon-film","el-icon-finished","el-icon-data-line","el-icon-filter","el-icon-flag","el-icon-folder-checked","el-icon-first-aid-kit","el-icon-folder-add","el-icon-fold","el-icon-folder-delete","el-icon-document-delete","el-icon-folder","el-icon-food","el-icon-folder-opened","el-icon-football","el-icon-folder-remove","el-icon-fries","el-icon-full-screen","el-icon-fork-spoon","el-icon-goblet","el-icon-goblet-full","el-icon-goods","el-icon-goblet-square-full","el-icon-goods-filled","el-icon-grid","el-icon-grape","el-icon-goblet-square","el-icon-headset","el-icon-comment","el-icon-help-filled","el-icon-histogram","el-icon-home-filled","el-icon-help","el-icon-house","el-icon-ice-cream-round","el-icon-hot-water","el-icon-ice-cream","el-icon-files","el-icon-ice-cream-square","el-icon-key","el-icon-ice-tea","el-icon-knife-fork","el-icon-iphone","el-icon-info-filled","el-icon-link","el-icon-ice-drink","el-icon-lightning","el-icon-loading","el-icon-lollipop","el-icon-location-information","el-icon-lock","el-icon-location-filled","el-icon-magnet","el-icon-male","el-icon-location","el-icon-menu","el-icon-magic-stick","el-icon-message-box","el-icon-map-location","el-icon-mic","el-icon-message","el-icon-medal","el-icon-milk-tea","el-icon-microphone","el-icon-minus","el-icon-money","el-icon-moon-night","el-icon-monitor","el-icon-moon","el-icon-more","el-icon-mostly-cloudy","el-icon-more-filled","el-icon-mouse","el-icon-mug","el-icon-mute","el-icon-no-smoking","el-icon-mute-notification","el-icon-notification","el-icon-notebook","el-icon-odometer","el-icon-office-building","el-icon-operation","el-icon-opportunity","el-icon-orange","el-icon-open","el-icon-paperclip","el-icon-pear","el-icon-partly-cloudy","el-icon-phone","el-icon-picture-filled","el-icon-phone-filled","el-icon-picture-rounded","el-icon-guide","el-icon-place","el-icon-platform","el-icon-pie-chart","el-icon-pointer","el-icon-plus","el-icon-position","el-icon-postcard","el-icon-present","el-icon-price-tag","el-icon-promotion","el-icon-pouring","el-icon-reading-lamp","el-icon-question-filled","el-icon-printer","el-icon-picture","el-icon-refresh-right","el-icon-reading","el-icon-refresh-left","el-icon-refresh","el-icon-refrigerator","el-icon-remove-filled","el-icon-right","el-icon-scale-to-original","el-icon-school","el-icon-remove","el-icon-scissor","el-icon-select","el-icon-management","el-icon-search","el-icon-sell","el-icon-semi-select","el-icon-share","el-icon-setting","el-icon-service","el-icon-ship","el-icon-set-up","el-icon-shopping-bag","el-icon-shop","el-icon-shopping-cart","el-icon-shopping-cart-full","el-icon-soccer","el-icon-sold-out","el-icon-smoking","el-icon-sort-down","el-icon-sort","el-icon-sort-up","el-icon-star","el-icon-stamp","el-icon-star-filled","el-icon-stopwatch","el-icon-success-filled","el-icon-suitcase","el-icon-sugar","el-icon-sunny","el-icon-sunrise","el-icon-switch","el-icon-ticket","el-icon-sunset","el-icon-tickets","el-icon-switch-button","el-icon-takeaway-box","el-icon-toilet-paper","el-icon-timer","el-icon-tools","el-icon-top-left","el-icon-top","el-icon-top-right","el-icon-trend-charts","el-icon-turn-off","el-icon-unlock","el-icon-trophy","el-icon-umbrella","el-icon-upload-filled","el-icon-user-filled","el-icon-upload","el-icon-user","el-icon-van","el-icon-copy-document","el-icon-video-pause","el-icon-video-camera-filled","el-icon-view","el-icon-wallet","el-icon-warning-filled","el-icon-watch","el-icon-video-play","el-icon-watermelon","el-icon-video-camera","el-icon-wallet-filled","el-icon-warning","el-icon-list","el-icon-zoom-in","el-icon-zoom-out","el-icon-rank","el-icon-wind-power"]}]},Uy={props:{modelValue:{type:String,default:""},placeholder:{type:String,default:"请输入或者选择图标"},clearable:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},data(){return{defaultValue:"",activeName:"element",dialogVisible:!1,data:[]}},watch:{modelValue(t){this.defaultValue=t},defaultValue(t){this.$emit("update:modelValue",t)}},mounted(){this.defaultValue=this.modelValue,this.data.push(...My.icons)},methods:{open(){if(this.disabled)return!1;this.dialogVisible=!0},selectIcon(t){if(t.target.tagName!="SPAN")return!1;this.defaultValue=t.target.dataset.icon,this.dialogVisible=!1,this.$emit("update:modelValue",this.defaultValue)}}},jy={class:"lw-icon-select"},zy={class:"lw-icon-select__list"},Hy=["data-icon"];function Ky(t,n,o,a,r,l){const i=e.resolveComponent("el-button"),s=e.resolveComponent("el-input"),d=e.resolveComponent("el-tag"),f=e.resolveComponent("el-icon"),p=e.resolveComponent("el-scrollbar"),m=e.resolveComponent("el-tab-pane"),_=e.resolveComponent("el-tabs"),C=e.resolveComponent("el-dialog");return e.openBlock(),e.createElementBlock("div",jy,[e.createVNode(s,{modelValue:r.defaultValue,"onUpdate:modelValue":n[0]||(n[0]=k=>r.defaultValue=k),"prefix-icon":r.defaultValue||"none",placeholder:o.placeholder,clearable:o.clearable,disabled:o.disabled},{append:e.withCtx(()=>[e.createVNode(i,{icon:"el-icon-more-filled",onClick:l.open},null,8,["onClick"])]),_:1},8,["modelValue","prefix-icon","placeholder","clearable","disabled"]),e.createVNode(C,{title:"图标选择器",modelValue:r.dialogVisible,"onUpdate:modelValue":n[3]||(n[3]=k=>r.dialogVisible=k),width:780,"destroy-on-close":""},{default:e.withCtx(()=>[e.createVNode(_,{style:{"margin-top":"-30px"},modelValue:r.activeName,"onUpdate:modelValue":n[2]||(n[2]=k=>r.activeName=k)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.data,k=>(e.openBlock(),e.createBlock(m,{key:k.name,name:k.key,lazy:""},{label:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(k.name)+" ",1),e.createVNode(d,{size:"small",type:"info"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(k.icons.length),1)]),_:2},1024)]),default:e.withCtx(()=>[e.createElementVNode("div",zy,[e.createVNode(p,null,{default:e.withCtx(()=>[e.createElementVNode("ul",{onClick:n[1]||(n[1]=(...S)=>l.selectIcon&&l.selectIcon(...S))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k.icons,S=>(e.openBlock(),e.createElementBlock("li",{key:S},[e.createElementVNode("span",{"data-icon":S},null,8,Hy),e.createVNode(f,null,{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(S)))]),_:2},1024)]))),128))])]),_:2},1024)])]),_:2},1032,["name"]))),128))]),_:1},8,["modelValue"])]),_:1},8,["modelValue"])])}const os=le(Uy,[["render",Ky],["__scopeId","data-v-2ebe66a3"]]),_t={pageSize:20,parseData:function(t){return{data:t,rows:t.content,total:t.totalElements,msg:t.message,code:t.code}},request:{page:"page",pageSize:"size",keyword:"keyword"},props:{label:"label",value:"value"}},Gy={name:"lwTableSelect",props:{modelValue:null,apiObj:{type:[Object,Function],default:()=>{}},params:{type:Object,default:()=>{}},placeholder:{type:String,default:"请选择"},size:{type:String,default:"default"},clearable:{type:Boolean,default:!1},multiple:{type:Boolean,default:!1},filterable:{type:Boolean,default:!1},collapseTags:{type:Boolean,default:!1},collapseTagsTooltip:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},tableWidth:{type:Number,default:400},mode:{type:String,default:"popover"},props:{type:Object,default:()=>{}}},data(){return{loading:!1,keyword:null,defaultValue:[],tableData:[],pageSize:_t.pageSize,total:0,currentPage:1,defaultProps:{label:_t.props.label,value:_t.props.value,page:_t.request.page,pageSize:_t.request.pageSize,keyword:_t.request.keyword},formData:{}}},computed:{},watch:{modelValue:{handler(){this.defaultValue=this.modelValue},deep:!0}},mounted(){this.defaultProps=Object.assign(this.defaultProps,this.props),this.defaultValue=this.modelValue},methods:{visibleChange(t){t&&(this.currentPage=1,this.keyword=null,this.formData={},this.getData())},async getData(){var r,l,i;this.loading=!0;var t={[this.defaultProps.page]:this.currentPage-1,[this.defaultProps.pageSize]:this.pageSize,[this.defaultProps.keyword]:this.keyword};let n=this.$expression(this.formData);n&&((r=this.params)!=null&&r.expression)?this.formData.expression=`${this.params.expression} AND ${n}`:n?this.formData.expression=n:(l=this.params)!=null&&l.expression?this.formData.expression=(i=this.params)==null?void 0:i.expression:this.formData.expression="",Object.assign(t,this.params,this.formData);var o=await this.apiObj(t),a=_t.parseData(o);this.tableData=a.rows,this.total=a.total,this.loading=!1,this.$nextTick(()=>{if(this.multiple)this.defaultValue.forEach(d=>{var f=this.tableData.filter(p=>p[this.defaultProps.value]===d.value);f.length>0&&this.$refs.table.toggleRowSelection(f[0],!0)});else{var s=this.tableData.filter(d=>{var f;return d[this.defaultProps.value]===((f=this.defaultValue)==null?void 0:f.value)});this.$refs.table.setCurrentRow(s[0])}this.$refs.table.setScrollTop(0)})},formSubmit(){this.currentPage=1,this.keyword=null,this.getData()},reload(){this.getData()},getCurVlaue(t){const n={};return Object.entries(this.defaultProps).forEach(([o,a])=>{t[a]&&(n[o]=t[a])}),n},select(t,n){var o=t.length&&t.indexOf(n)!==-1;o?this.defaultValue.push(this.getCurVlaue(n)):this.defaultValue.splice(this.defaultValue.findIndex(a=>a.value==n[this.defaultProps.value]),1)},selectAll(t){var n=t.length>0;n?t.forEach(o=>{var a=this.defaultValue.find(r=>r.value==o[this.defaultProps.value]);a||this.defaultValue.push(this.getCurVlaue(o))}):this.defaultValue=[],this.$emit("update:modelValue",this.defaultValue),this.$emit("change",this.defaultValue)},click(t){this.multiple||(this.defaultValue=this.getCurVlaue(t),this.$refs.select.blur(),this.$emit("update:modelValue",this.defaultValue),this.$emit("change",this.defaultValue))},removeTag(t){var n=this.findRowByKey(t.value);this.$refs.table.toggleRowSelection(n,!1),this.$emit("update:modelValue",this.defaultValue)},clear(){this.$emit("update:modelValue",this.defaultValue)},findRowByKey(t){return this.tableData.find(n=>n[this.defaultProps.value]===t)},filterMethod(t){if(!t)return this.keyword=null,!1;this.keyword=t,this.getData()},blur(){this.$refs.select.blur()},focus(){this.$refs.select.focus()}}},Yy={class:"lw-table-select__table",style:{width:"100%"}},$y={class:"lw-table-select__header"},Wy={class:"lw-table-select__page"};function Jy(t,n,o,a,r,l){const i=e.resolveComponent("el-table-column"),s=e.resolveComponent("el-table"),d=e.resolveComponent("el-pagination"),f=e.resolveComponent("el-select"),p=e.resolveDirective("loading");return e.openBlock(),e.createBlock(f,{ref:"select",modelValue:r.defaultValue,"onUpdate:modelValue":n[1]||(n[1]=m=>r.defaultValue=m),size:o.size,clearable:o.clearable,multiple:o.multiple,"collapse-tags":o.collapseTags,"collapse-tags-tooltip":o.collapseTagsTooltip,filterable:o.filterable,placeholder:o.placeholder,disabled:o.disabled,"filter-method":l.filterMethod,onRemoveTag:l.removeTag,onVisibleChange:l.visibleChange,onClear:l.clear},{empty:e.withCtx(()=>[e.withDirectives((e.openBlock(),e.createElementBlock("div",Yy,[e.createElementVNode("div",$y,[e.renderSlot(t.$slots,"header",{form:r.formData,submit:l.formSubmit},void 0,!0)]),e.createVNode(s,{ref:"table",data:r.tableData,"max-height":245,"highlight-current-row":!o.multiple,"reserve-selection":!0,onRowClick:l.click,onSelect:l.select,onSelectAll:l.selectAll},{default:e.withCtx(()=>[o.multiple?(e.openBlock(),e.createBlock(i,{key:0,type:"selection",width:"45"})):(e.openBlock(),e.createBlock(i,{key:1,type:"index",width:"45"},{default:e.withCtx(m=>[e.createElementVNode("span",null,e.toDisplayString(m.$index+(r.currentPage-1)*r.pageSize+1),1)]),_:1})),e.renderSlot(t.$slots,"default",{},void 0,!0)]),_:3},8,["data","highlight-current-row","onRowClick","onSelect","onSelectAll"]),e.createElementVNode("div",Wy,[e.createVNode(d,{small:"",background:"",layout:"prev, pager, next",total:r.total,"page-size":r.pageSize,currentPage:r.currentPage,"onUpdate:currentPage":n[0]||(n[0]=m=>r.currentPage=m),onCurrentChange:l.reload},null,8,["total","page-size","currentPage","onCurrentChange"])])])),[[p,r.loading]])]),_:3},8,["modelValue","size","clearable","multiple","collapse-tags","collapse-tags-tooltip","filterable","placeholder","disabled","filter-method","onRemoveTag","onVisibleChange","onClear"])}const rs=le(Gy,[["render",Jy],["__scopeId","data-v-322204c0"]]),Zy={components:{lwUpload:St},props:{modelValue:{type:Object,default:()=>{}},config:{type:Object,default:()=>{}},maxHeight:{type:String,default:"calc(100vh - 280px)"},isView:{type:Boolean,default:!1},isPagination:{type:Boolean,default:!1}},data(){return{tableData:[],tagValue:"",currentPage:1,pageSize:8,ids:[],internalUpdate:!0,tagVisible:!1}},watch:{tableData:{handler(t){this.internalUpdate||this.$emit("update:modelValue",this.unflattenObject(t)),this.internalUpdate=!1},deep:!0},modelValue:{handler(t){this.internalUpdate||(this.internalUpdate=!0,this.tableData=this.flattenObject(t))},deep:!0}},computed:{hasConfig(){return Object.keys(this.config).length>0},hasValue(){return Object.keys(this.modelValue).length>0},dataList(){if(!this.isPagination)return this.tableData;const n=(this.currentPage-1)*this.pageSize;return this.tableData.slice(n,n+this.pageSize)}},mounted(){this.tableData=this.flattenObject(this.modelValue)},methods:{flattenObject(t){let n=[];function o(a,r=""){let l={};for(let i in a)if(a.hasOwnProperty(i)){const s=r?`${r}.${i}`:i;i!="errorMsg"&&typeof a[i]=="object"&&a[i]!==null&&!Array.isArray(a[i])?Object.assign(l,o(a[i],s)):l[s]=a[i]}return l}return t==null||t.forEach(a=>{n.push(o(a))}),n},unflattenObject(t){let n=[];return t==null||t.forEach(o=>{const a={};for(let r in o)if(o.hasOwnProperty(r)){const l=r.split(".");l.reduce((i,s,d)=>(d===l.length-1?i[s]=o[r]:i[s]=i[s]||{},i[s]),a)}n.push(a)}),n},isEmpty(t){return!!(t==null||typeof t=="string"&&t.trim()===""||Array.isArray(t)&&t.length===0||typeof t=="object"&&Object.keys(t).length===0)},isValue(t,n){const o=[];return t.forEach(a=>{n.forEach(r=>{r.rules&&r.rules.length>0&&r.rules.forEach(l=>{var i;r.component=="checkbox"||r.component=="upload"?r.options.items.forEach(s=>{this.isEmpty(a[s.name])&&(a!=null&&a.errorMsg||(a.errorMsg={}),a.errorMsg[s.name]=l.message)}):l.required&&this.isEmpty(a[r.name])?(a!=null&&a.errorMsg||(a.errorMsg={}),a.errorMsg[r.name]=l.message,o.push(`${r.label} ${l.message}`)):(a!=null&&a.errorMsg&&delete a.errorMsg[r.name],((i=a.errorMsg)==null?void 0:i.length)===0&&delete a.errorMsg)})})}),o.length>0?(this.$message.warning("校验失败,存在必填字段为空,请检查"),!0):!1},addItem(t=this.tableData){let n={},o=JSON.parse(JSON.stringify(this.config.formItems));if(this.isValue(t,o))return!1;o.forEach(l=>{var i;if(l.component=="checkbox"||l.component=="upload")if(l.name){const s=[];l.options.items.forEach(d=>{s.push(d.value)}),n[l.name]=s}else(i=l==null?void 0:l.options)!=null&&i.items&&l.options.items.forEach(s=>{n[s.name]=s.value});else n[l.name]=l.value});let r=this.$tool.getUUID(this.config.rowKey,"4");t.push({[this.config.rowKey]:r,...n}),this.ids.push(r)},clickFun(t,n,o){t=="delete"&&this.deleteItem(n),t=="add"&&(n!=null&&n.fields||(n.fields=[]),this.addItem(n.fields))},removeNode(t,n){for(let o=0;o<t.length;o++){if(JSON.stringify(t[o])===JSON.stringify(n)){t.splice(o,1);return}t[o][this.config.treeProps.children]&&this.removeNode(t[o][this.config.treeProps.children],n)}},deleteItem(t){this.removeNode(this.tableData,t)},isDisabled(t,n){var o;return!this.ids.includes(n[this.config.rowKey])&&((o=t.options)==null?void 0:o.disabled)},deepMerge(t,n){return n.forEach(o=>{if(n.hasOwnProperty(key)){const a=t[key]!==null&&t[key]!==void 0,r=n[key]!==null&&n[key]!==void 0;a&&typeof t[key]=="object"&&!Array.isArray(t[key])&&r&&typeof n[key]=="object"&&!Array.isArray(n[key])?t[key]=this.deepMerge(t[key],n[key]):r?t[key]=n[key]:r||delete t[key]}}),t},tagClose(t,n){n.splice(n.indexOf(t),1)},tagInputConfirm(t,n){this.tagValue&&(n[t.name]=n[t.name]||[],n[t.name].push(this.tagValue)),n.tagVisible=!1,this.tagValue=""},getPropName(t){return t.component=="checkbox"||t.component=="upload"?t.options.items[0].name:t.name},getFilters(t){let n=[];return this.tableData.forEach(o=>{n.includes(o[t])||n.push(o[t])}),n.map(o=>({text:o,value:o}))},filterHandler(t,n,o){const a=o.property;return n[a]===t}}},Xy={key:0},Qy={class:"error-tips"},e_={class:"error-tips"},t_={class:"error-tips"},n_={key:13,class:"tags-list"},o_={key:16,class:"el-row-item-msg"},r_={key:17,class:"error-tips"},a_={key:0,class:"pagination-body"},l_={key:1,class:"btn-list"};function i_(t,n,o,a,r,l){var T;const i=e.resolveComponent("el-input"),s=e.resolveComponent("lw-upload"),d=e.resolveComponent("el-col"),f=e.resolveComponent("el-checkbox"),p=e.resolveComponent("el-checkbox-group"),m=e.resolveComponent("el-switch"),_=e.resolveComponent("el-option"),C=e.resolveComponent("el-select"),k=e.resolveComponent("el-cascader"),S=e.resolveComponent("el-date-picker"),B=e.resolveComponent("el-input-number"),q=e.resolveComponent("el-radio"),F=e.resolveComponent("el-radio-group"),V=e.resolveComponent("el-color-picker"),j=e.resolveComponent("el-rate"),U=e.resolveComponent("el-slider"),L=e.resolveComponent("el-tag"),A=e.resolveComponent("el-button"),z=e.resolveComponent("el-tooltip"),Y=e.resolveComponent("el-icon-more-filled"),$=e.resolveComponent("el-icon"),H=e.resolveComponent("el-dropdown-item"),X=e.resolveComponent("el-dropdown-menu"),ie=e.resolveComponent("el-dropdown"),R=e.resolveComponent("el-table-column"),ne=e.resolveComponent("el-table"),h=e.resolveComponent("el-pagination");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(ne,{data:l.dataList,stripe:"",ref:"table",columns:o.config.formItems,"max-height":o.maxHeight,"row-key":o.config.rowKey||"id","tree-props":((T=o.config)==null?void 0:T.treeProps)||{children:"children",hasChildren:"hasChildren"},style:{width:"100%"}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.config.formItems,(x,Ce)=>(e.openBlock(),e.createBlock(R,{width:x.width,"min-width":x.minWidth,key:Ce,label:x.label,prop:l.getPropName(x),align:x.align??"left",fixed:x.fixed,sortable:x.sortable,"show-overflow-tooltip":x.tooltip,filters:x.filters?l.getFilters(x.name):null,"filter-method":x.filters?l.filterHandler:null},{header:e.withCtx(()=>[e.createElementVNode("div",{class:"table-name",style:e.normalizeStyle({justifyContent:x.align||"flex-start"})},[x!=null&&x.rules?(e.openBlock(),e.createElementBlock("span",Xy,"*")):e.createCommentVNode("",!0),e.createTextVNode(" "+e.toDisplayString(x.label),1)],4)]),default:e.withCtx(({row:G,$index:Te,column:Z})=>{var P,J,ee,ce,ye,we,xe,qe,Re,Ne,Ge,je,ae;return[x.component=="input"?(e.openBlock(),e.createBlock(i,{key:0,modelValue:G[x.name],"onUpdate:modelValue":v=>G[x.name]=v,placeholder:x.options.placeholder,clearable:"",size:o.config.size||"small",type:x.options.type,disabled:l.isDisabled(x,G),maxlength:x.options.maxlength,"show-word-limit":""},null,8,["modelValue","onUpdate:modelValue","placeholder","size","type","disabled","maxlength"])):x.component=="upload"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(x.options.items,(v,Q)=>(e.openBlock(),e.createBlock(d,{key:Q},{default:e.withCtx(()=>[e.createVNode(s,{modelValue:G[v.name],"onUpdate:modelValue":Be=>G[v.name]=Be,maxSize:v.maxSize,accept:v.accept,title:v.label,parseData:x.parseData,disabled:v==null?void 0:v.disabled,multiple:v==null?void 0:v.multiple,limit:v==null?void 0:v.limit,returnFile:v==null?void 0:v.returnFile,tip:v==null?void 0:v.tip,apiObj:x.apiObj},null,8,["modelValue","onUpdate:modelValue","maxSize","accept","title","parseData","disabled","multiple","limit","returnFile","tip","apiObj"]),e.createElementVNode("div",Qy,e.toDisplayString(G.errorMsg[v.name]),1)]),_:2},1024))),128)):x.component=="checkbox"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[x.name?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(x.options.items,(v,Q)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:Q},[e.createVNode(f,{modelValue:G[x.name],"onUpdate:modelValue":Be=>G[x.name]=Be,label:v.label,size:o.config.size||"small"},null,8,["modelValue","onUpdate:modelValue","label","size"]),e.createElementVNode("div",e_,e.toDisplayString(G.errorMsg[x.name]),1)],64))),128)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.options.items,(v,Q)=>(e.openBlock(),e.createBlock(f,{modelValue:G[v.name],"onUpdate:modelValue":Be=>G[v.name]=Be,label:v.label,key:Q},null,8,["modelValue","onUpdate:modelValue","label"]))),128)),e.createElementVNode("div",t_,e.toDisplayString(G.errorMsg[t._item.name]),1)],64))],64)):x.component=="checkboxGroup"?(e.openBlock(),e.createBlock(p,{key:3,modelValue:G[x.name],"onUpdate:modelValue":v=>G[x.name]=v,size:o.config.size||"small"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.options.items,v=>(e.openBlock(),e.createBlock(f,{key:v.value,label:v.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(v.label),1)]),_:2},1032,["label"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","size"])):x.component=="switch"?(e.openBlock(),e.createBlock(m,{key:4,size:o.config.size||"small",disabled:l.isDisabled(x,G),modelValue:G[x.name],"onUpdate:modelValue":v=>G[x.name]=v},null,8,["size","disabled","modelValue","onUpdate:modelValue"])):x.component=="select"?(e.openBlock(),e.createBlock(C,{key:5,modelValue:G[x.name],"onUpdate:modelValue":v=>G[x.name]=v,multiple:(P=x.options)==null?void 0:P.multiple,"allow-create":(J=x.options)==null?void 0:J.allowCreate,"default-first-option":"",placeholder:((ee=x.options)==null?void 0:ee.placeholder)||"",clearable:(ce=x.options)==null?void 0:ce.clearable,disabled:l.isDisabled(x,G),filterable:"",size:o.config.size||"small",style:{width:"100%"}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.options.items,v=>(e.openBlock(),e.createBlock(_,{key:v.value,label:v.label,value:v.value},null,8,["label","value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","multiple","allow-create","placeholder","clearable","disabled","size"])):x.component=="cascader"?(e.openBlock(),e.createBlock(k,{key:6,size:o.config.size||"small",modelValue:G[x.name],"onUpdate:modelValue":v=>G[x.name]=v,options:x.options.items,disabled:l.isDisabled(x,G),clearable:""},null,8,["size","modelValue","onUpdate:modelValue","options","disabled"])):x.component=="date"?(e.openBlock(),e.createBlock(S,{key:7,modelValue:G[x.name],"onUpdate:modelValue":v=>G[x.name]=v,style:{width:"100%"},size:o.config.size||"small",type:x.options.type,disabled:l.isDisabled(x,G),"start-placeholder":x.options.startPlaceholder,"end-placeholder":x.options.endPlaceholder,shortcuts:x.options.shortcuts,"default-time":x.options.defaultTime,"value-rowat":x.options.valuerowat,placeholder:x.options.placeholder||"请选择"},null,8,["modelValue","onUpdate:modelValue","size","type","disabled","start-placeholder","end-placeholder","shortcuts","default-time","value-rowat","placeholder"])):x.component=="number"?(e.openBlock(),e.createBlock(B,{key:8,modelValue:G[x.name],"onUpdate:modelValue":v=>G[x.name]=v,disabled:(ye=x.options)==null?void 0:ye.disabled,min:(we=x==null?void 0:x.options)==null?void 0:we.min,max:(xe=x==null?void 0:x.options)==null?void 0:xe.max,size:o.config.size||"small",step:((qe=x==null?void 0:x.options)==null?void 0:qe.step)||1,precision:(Re=x==null?void 0:x.options)==null?void 0:Re.precision,placeholder:((Ne=x==null?void 0:x.options)==null?void 0:Ne.placeholder)||"","controls-position":((Ge=x==null?void 0:x.options)==null?void 0:Ge.controlsPosition)||"right"},e.createSlots({_:2},[(je=x==null?void 0:x.options)!=null&&je.suffix?{name:"suffix",fn:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(x.options.suffix),1)]),key:"0"}:void 0]),1032,["modelValue","onUpdate:modelValue","disabled","min","max","size","step","precision","placeholder","controls-position"])):x.component=="radio"?(e.openBlock(),e.createBlock(F,{key:9,modelValue:G[x.name],"onUpdate:modelValue":v=>G[x.name]=v,disabled:l.isDisabled(x,G),size:o.config.size||"small"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.options.items,v=>(e.openBlock(),e.createBlock(q,{key:v.value,disabled:l.isDisabled(x,G),value:v.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(v.label),1)]),_:2},1032,["disabled","value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","disabled","size"])):x.component=="color"?(e.openBlock(),e.createBlock(V,{key:10,modelValue:G[x.name],"onUpdate:modelValue":v=>G[x.name]=v,disabled:l.isDisabled(x,G),size:o.config.size||"small"},null,8,["modelValue","onUpdate:modelValue","disabled","size"])):x.component=="rate"?(e.openBlock(),e.createBlock(j,{key:11,style:{"margin-top":"6px"},disabled:l.isDisabled(x,G),modelValue:G[x.name],"onUpdate:modelValue":v=>G[x.name]=v,size:o.config.size||"small"},null,8,["disabled","modelValue","onUpdate:modelValue","size"])):x.component=="slider"?(e.openBlock(),e.createBlock(U,{key:12,modelValue:G[x.name],"onUpdate:modelValue":v=>G[x.name]=v,marks:x.options.marks,disabled:l.isDisabled(x,G),size:o.config.size||"small"},null,8,["modelValue","onUpdate:modelValue","marks","disabled","size"])):x.component=="tags"?(e.openBlock(),e.createElementBlock("div",n_,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(G[x.name],v=>(e.openBlock(),e.createBlock(L,{key:v,closable:"","disable-transitions":!1,onClose:Q=>l.tagClose(v,G[x.name])},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(v),1)]),_:2},1032,["onClose"]))),128)),G!=null&&G.tagVisible?(e.openBlock(),e.createBlock(i,{key:0,modelValue:r.tagValue,"onUpdate:modelValue":n[0]||(n[0]=v=>r.tagValue=v),class:"w-20",size:o.config.size||"small",onKeyup:e.withKeys(v=>l.tagInputConfirm(x,G),["enter"]),onBlur:v=>l.tagInputConfirm(x,G)},null,8,["modelValue","size","onKeyup","onBlur"])):(e.openBlock(),e.createBlock(A,{key:1,class:"button-new-tag",size:o.config.size||"small",disabled:l.isDisabled(x,G),onClick:v=>G.tagVisible=!0},{default:e.withCtx(()=>n[3]||(n[3]=[e.createTextVNode(" + 添加 ")])),_:2},1032,["size","disabled","onClick"]))])):x.component=="operation"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:14},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.options.addDelete,v=>e.withDirectives((e.openBlock(),e.createElementBlock("span",{key:v},[v.icon?(e.openBlock(),e.createBlock(z,{key:0,content:v.label,placement:"top"},{default:e.withCtx(()=>[e.createVNode(A,{type:"primary",size:o.config.size||"small",onClick:Q=>v.clickFun?v.clickFun(G,Te,Z,r.tableData):l.clickFun(v.type,G,Te),disabled:v.disabled?v.disabled(G):!1,icon:v.icon,circle:""},null,8,["size","onClick","disabled","icon"])]),_:2},1032,["content"])):(e.openBlock(),e.createBlock(A,{key:1,type:"primary",text:"",size:o.config.size||"small",onClick:Q=>v.clickFun?v.clickFun(G,Te,Z,r.tableData):l.clickFun(v.type,G,Te),disabled:v.disabled?v.disabled(G):!1},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(v.label),1)]),_:2},1032,["size","onClick","disabled"]))])),[[e.vShow,v.isShow?v.isShow(G):!0]])),128)),(ae=x.options)!=null&&ae.items&&x.options.items.length>0?(e.openBlock(),e.createBlock(ie,{key:0},{dropdown:e.withCtx(()=>[e.createVNode(X,null,{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.options.items.filter(v=>!v.isShow||v.isShow(G)),v=>(e.openBlock(),e.createBlock(H,{key:v,onClick:Q=>v.clickFun(G,Te,Z,r.tableData)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(v.label),1)]),_:2},1032,["onClick"]))),128))]),_:2},1024)]),default:e.withCtx(()=>[e.createVNode(A,{size:o.config.size||"small",type:"primary",link:""},{default:e.withCtx(()=>[e.createVNode($,{class:"more-btn",size:"16"},{default:e.withCtx(()=>[e.createVNode(Y)]),_:1})]),_:1},8,["size"])]),_:2},1024)):e.createCommentVNode("",!0)],64)):e.renderSlot(t.$slots,x.component,{key:15,row:G},()=>[e.createVNode(L,{type:"danger"},{default:e.withCtx(()=>[e.createTextVNode("["+e.toDisplayString(x.component)+"] 没有这个默认组件也未自定义插槽内容",1)]),_:2},1024)],!0),x.message?(e.openBlock(),e.createElementBlock("div",o_,e.toDisplayString(x.message),1)):e.createCommentVNode("",!0),G.errorMsg?(e.openBlock(),e.createElementBlock("div",r_,e.toDisplayString(G.errorMsg[x==null?void 0:x.name]),1)):e.createCommentVNode("",!0)]}),_:2},1032,["width","min-width","label","prop","align","fixed","sortable","show-overflow-tooltip","filters","filter-method"]))),128))]),_:3},8,["data","columns","max-height","row-key","tree-props"]),o.isPagination&&r.tableData.length>r.pageSize?(e.openBlock(),e.createElementBlock("div",a_,[e.createVNode(h,{size:"small",background:"","page-size":r.pageSize,"current-page":r.currentPage,"onUpdate:currentPage":n[1]||(n[1]=x=>r.currentPage=x),layout:"prev, pager, next",total:r.tableData.length},null,8,["page-size","current-page","total"])])):e.createCommentVNode("",!0),o.isView?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",l_,[e.createVNode(A,{type:"primary",class:"add-btn",plain:"",icon:"el-icon-plus",onClick:n[2]||(n[2]=x=>l.addItem())},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("btn.add")),1)]),_:1}),e.renderSlot(t.$slots,"deleteBtn",{},void 0,!0)]))],64)}const as=le(Zy,[["render",i_],["__scopeId","data-v-e4f0fc23"]]),s_={name:"JsonItem",components:{FormItem:ts,draggable:Gt},props:{formItems:{type:Object,default:[]},form:{type:Object,default:()=>{}},hideBorder:{type:Boolean,default:!0},custom:{type:Array,default:()=>[]}},computed:{curIndex(){var t;return((t=this.$store.state)==null?void 0:t.curIndex)||""}},emits:["curClick"],methods:{hideHandle(t){return typeof(t==null?void 0:t.hideHandle)=="string"?new Function("form",`return ${t==null?void 0:t.hideHandle.replace(/\$/g,"form")}`)(this.form):typeof(t==null?void 0:t.hideHandle)=="boolean"?t.hideHandle:!1},changeClick(t){var n;this.$store.state.curIndex=t.name||((n=t==null?void 0:t.options.items[0])==null?void 0:n.name),this.$emit("curClick",t)},deleteListItem(t,n){t.splice(n,1)},addListItem(t){let n=t[0],o=JSON.parse(JSON.stringify(n));t.push(o)},deleteItem(t){this.formItems.splice(t,1)},copyItem(t,n){let o=JSON.parse(JSON.stringify(t));o.name=`${t.component}-${this.$tool.getUUID("",2)}`,this.formItems.splice(n+1,0,o)}}},c_={key:3,class:"tool-list"};function d_(t,n,o,a,r,l){var S,B,q;const i=e.resolveComponent("JsonItem",!0),s=e.resolveComponent("el-form-item"),d=e.resolveComponent("el-button"),f=e.resolveComponent("el-icon-delete"),p=e.resolveComponent("el-icon"),m=e.resolveComponent("el-col"),_=e.resolveComponent("FormItem"),C=e.resolveComponent("el-icon-copy-document"),k=e.resolveComponent("draggable");return e.openBlock(),e.createBlock(k,{list:o.formItems,"item-key":"name",group:"people",disabled:!o.hideBorder,class:e.normalizeClass(["draggable-item",{showBorder:o.hideBorder,cur:l.curIndex==(o.formItems.name||((q=(B=(S=o.formItems)==null?void 0:S.options)==null?void 0:B.items[0])==null?void 0:q.name))}]),"ghost-class":"draggable-ghost"},{item:e.withCtx(({element:F,index:V})=>{var j,U;return[l.hideHandle(F)?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(m,{key:0,span:["list"].includes(F.component)?24:F.span||24,class:e.normalizeClass({borderItem:o.hideBorder,cur:o.hideBorder&&l.curIndex==(F.name||((U=(j=F==null?void 0:F.options)==null?void 0:j.items[0])==null?void 0:U.name))}),onClickCapture:L=>l.changeClick(F)},{default:e.withCtx(()=>{var L,A;return[["object"].includes(F.component)?(e.openBlock(),e.createBlock(s,{key:0,label:F.label,onClickCapture:z=>l.changeClick(F)},{default:e.withCtx(()=>[e.createVNode(i,{formItems:F.value,form:o.form[F.name],class:"object-item",custom:o.custom,hideBorder:o.hideBorder,onCurClick:l.changeClick},e.createSlots({_:2},[e.renderList(o.custom,z=>({name:z.component,fn:e.withCtx(({itemCur:Y,formCur:$})=>[e.renderSlot(t.$slots,z.component,{itemCur:Y,formCur:$},void 0,!0)])}))]),1032,["formItems","form","custom","hideBorder","onCurClick"])]),_:2},1032,["label","onClickCapture"])):["list"].includes(F.component)?(e.openBlock(),e.createBlock(s,{key:1,onClickCapture:z=>l.changeClick(F)},{label:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(F.label)+" ",1),o.hideBorder?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(d,{key:0,type:"primary",class:"add-btn",plain:"",size:"small",icon:"el-icon-plus",onClick:z=>l.addListItem(F.value)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("btn.add")),1)]),_:2},1032,["onClick"]))]),default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(F.value,(z,Y)=>(e.openBlock(),e.createBlock(m,{span:F.span||24},{default:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass(["list-item",{borderItem:o.hideBorder}])},[o.form[F.name]?(e.openBlock(),e.createBlock(i,{key:0,formItems:z,custom:o.custom,form:o.form[F.name][Y],hideBorder:o.hideBorder,onCurClick:l.changeClick},e.createSlots({_:2},[e.renderList(o.custom,$=>({name:$.component,fn:e.withCtx(({itemCur:H,formCur:X})=>[e.renderSlot(t.$slots,$.component,{itemCur:H,formCur:X},void 0,!0)])}))]),1032,["formItems","custom","form","hideBorder","onCurClick"])):e.createCommentVNode("",!0),!o.hideBorder&&F.value.length>1?(e.openBlock(),e.createBlock(p,{key:1,class:"remove-btn",size:"14",onClick:$=>l.deleteListItem(F.value,Y)},{default:e.withCtx(()=>[e.createVNode(f)]),_:2},1032,["onClick"])):e.createCommentVNode("",!0)],2)]),_:2},1032,["span"]))),256))]),_:2},1032,["onClickCapture"])):(e.openBlock(),e.createBlock(_,{key:2,item:F,form:o.form},e.createSlots({_:2},[["input","upload","checkbox","checkboxGroup","switch","select","treeSelect","cascader","date","number","radio","color","rate","slider","tags"].includes(F.component)?void 0:{name:F.component,fn:e.withCtx(()=>[e.renderSlot(t.$slots,F.component,{itemCur:F,formCur:o.form},void 0,!0)]),key:"0"}]),1032,["item","form"])),o.hideBorder&&l.curIndex==(F.name||((A=(L=F==null?void 0:F.options)==null?void 0:L.items[0])==null?void 0:A.name))?(e.openBlock(),e.createElementBlock("div",c_,[e.createVNode(p,{class:"btn",size:"14",onClick:z=>l.copyItem(F,V),title:"复制"},{default:e.withCtx(()=>[e.createVNode(C)]),_:2},1032,["onClick"]),e.createVNode(p,{class:"btn",size:"14",onClick:z=>l.deleteItem(V),title:"删除"},{default:e.withCtx(()=>[e.createVNode(f)]),_:2},1032,["onClick"])])):e.createCommentVNode("",!0)]}),_:2},1032,["span","class","onClickCapture"]))]}),_:3},8,["list","disabled","class"])}const u_=le(s_,[["render",d_],["__scopeId","data-v-fc71052f"]]),h_={name:"TreeItem",components:{draggable:Gt},props:{formItems:{type:Object,default:[]}},computed:{curIndex(){var t;return((t=this.$store.state)==null?void 0:t.curIndex)||""}},emits:["curClick"],methods:{deleteItem(t){this.formItems.splice(t,1)},copyItem(t,n){let o=JSON.parse(JSON.stringify(t));o.name=`${t.component}-${this.$tool.getUUID("",2)}`,this.formItems.splice(n+1,0,o)}}},f_={class:"form-item"},p_={class:"tool-list"},m_={key:1,class:"list-item"},g_={class:"form-item"},b_={class:"tool-list"},y_={key:2,class:"form-item"},__={class:"tool-list"};function k_(t,n,o,a,r,l){const i=e.resolveComponent("el-icon-copy-document"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("el-icon-delete"),f=e.resolveComponent("TreeItem",!0),p=e.resolveComponent("draggable");return e.openBlock(),e.createBlock(p,{list:o.formItems,"item-key":"name",group:"people",class:"draggable-item","ghost-class":"draggable-ghost"},{item:e.withCtx(({element:m,index:_})=>{var C,k,S,B,q,F;return[e.createElementVNode("div",null,[["object"].includes(m.component)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("div",f_,[e.createTextVNode(e.toDisplayString(m.label),1),e.createElementVNode("span",null,"「"+e.toDisplayString(m.name||((k=(C=m.options)==null?void 0:C.items[0])==null?void 0:k.name))+"」",1),e.createElementVNode("div",p_,[e.createVNode(s,{class:"btn",size:"14",onClick:V=>l.copyItem(m,_),title:"复制"},{default:e.withCtx(()=>[e.createVNode(i)]),_:2},1032,["onClick"]),e.createVNode(s,{class:"btn",size:"14",onClick:V=>l.deleteItem(_),title:"删除"},{default:e.withCtx(()=>[e.createVNode(d)]),_:2},1032,["onClick"])])]),e.createVNode(f,{formItems:m.value},null,8,["formItems"])],64)):["list"].includes(m.component)?(e.openBlock(),e.createElementBlock("div",m_,[e.createElementVNode("div",g_,[e.createTextVNode(e.toDisplayString(m.label),1),e.createElementVNode("span",null,"「"+e.toDisplayString(m.name||((B=(S=m.options)==null?void 0:S.items[0])==null?void 0:B.name))+"」",1),e.createElementVNode("div",b_,[e.createVNode(s,{class:"btn",size:"14",onClick:V=>l.copyItem(m,_),title:"复制"},{default:e.withCtx(()=>[e.createVNode(i)]),_:2},1032,["onClick"]),e.createVNode(s,{class:"btn",size:"14",onClick:V=>l.deleteItem(_),title:"删除"},{default:e.withCtx(()=>[e.createVNode(d)]),_:2},1032,["onClick"])])]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,V=>(e.openBlock(),e.createBlock(f,{formItems:V},null,8,["formItems"]))),256))])):(e.openBlock(),e.createElementBlock("div",y_,[e.createTextVNode(e.toDisplayString(m.label),1),e.createElementVNode("span",null,"「"+e.toDisplayString(m.name||((F=(q=m.options)==null?void 0:q.items[0])==null?void 0:F.name))+"」",1),e.createElementVNode("div",__,[e.createVNode(s,{class:"btn",size:"14",onClick:V=>l.copyItem(m,_),title:"复制"},{default:e.withCtx(()=>[e.createVNode(i)]),_:2},1032,["onClick"]),e.createVNode(s,{class:"btn",size:"14",onClick:V=>l.deleteItem(_),title:"删除"},{default:e.withCtx(()=>[e.createVNode(d)]),_:2},1032,["onClick"])])]))])]}),_:1},8,["list"])}const w_={name:"StatsConfig",components:{TreeItem:le(h_,[["render",k_],["__scopeId","data-v-91979609"]])},data(){return{tagVisible:{},hideForm:{},tagValue:"",filter:[{label:"等于",value:"=="},{label:"大于",value:">"},{label:"大于等于",value:">="},{label:"小于",value:"<"},{label:"小于等于",value:"<="},{label:"不等于",value:"!="}],rules:[{label:"必填",required:!0,message:"请输入",trigger:"blur"},{label:"必选",required:!0,message:"请选择",trigger:"change"}]}},props:{item:{type:Object,default:()=>({})},config:{type:Object,default:()=>({})}},watch:{hideForm:{handler(t){if(!(t!=null&&t.label)||!t.filter||!t.value){this.item.hideHandle="";return}this.item.hideHandle=`$.${t.label} ${t.filter} ${t.value}`},deep:!0},item:{handler(t){if(t!=null&&t.hideHandle){const n=/^\$\.(\S+)\s+(\S+)\s+(\S+)$/,o=t==null?void 0:t.hideHandle.match(n);if(o){const a={label:o[1],filter:o[2],value:o[3]};this.hideForm=a}}},deep:!0}},computed:{strList(){function t(o){const a=r=>{var i;let l={label:r.label,value:r.name||r.label};return r.component==="object"||r.component==="list"?l.children=(r.value||[]).map(s=>Array.isArray(s)?s.map(a):a(s)).flat():(r.component==="checkbox"||r.component==="upload")&&(l.value=(i=r.options)==null?void 0:i.items[0].name),l};return o.formItems.map(a)}return t(this.config)}},methods:{tagClose(t,n){n.splice(n.indexOf(t),1)},tagInputConfirm(t,n){this.tagValue&&(n=n||[],n.push(this.tagValue)),this.tagVisible[t.name]=!1,this.tagValue=""}}},V_={class:"form-body"},C_={class:"form-body"},x_={class:"form-slider"},N_={key:1,class:"form-title"},B_={key:2,class:"form-body"},S_={class:"tags-list"},E_={class:"form-item"},T_={class:"form-body"},I_={class:"input-body"},D_={class:"form-body"};function F_(t,n,o,a,r,l){const i=e.resolveComponent("el-input"),s=e.resolveComponent("el-form-item"),d=e.resolveComponent("el-switch"),f=e.resolveComponent("el-slider"),p=e.resolveComponent("el-option"),m=e.resolveComponent("el-select"),_=e.resolveComponent("el-input-number"),C=e.resolveComponent("el-icon-delete"),k=e.resolveComponent("el-icon"),S=e.resolveComponent("el-button"),B=e.resolveComponent("el-tag"),q=e.resolveComponent("el-col"),F=e.resolveComponent("el-row"),V=e.resolveComponent("el-icon-question-filled"),j=e.resolveComponent("el-tooltip"),U=e.resolveComponent("el-cascader"),L=e.resolveComponent("TreeItem"),A=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(A,{model:o.item,class:"form-list","label-position":"top"},{default:e.withCtx(()=>{var z,Y,$,H,X,ie;return[o.item.component?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[n[38]||(n[38]=e.createElementVNode("div",{class:"form-title"},"基础配置",-1)),e.createElementVNode("div",V_,[o.item.component=="checkbox"||o.item.component=="upload"?(e.openBlock(),e.createBlock(s,{key:0,label:"属性名称"},{default:e.withCtx(()=>{var R;return[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((R=o.item)==null?void 0:R.options.items,(ne,h)=>(e.openBlock(),e.createBlock(i,{modelValue:ne.name,"onUpdate:modelValue":T=>ne.name=T,placeholder:"请输入",clearable:""},null,8,["modelValue","onUpdate:modelValue"]))),256))]}),_:1})):(e.openBlock(),e.createBlock(s,{key:1,label:"属性名称"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.name,"onUpdate:modelValue":n[0]||(n[0]=R=>o.item.name=R),placeholder:"请输入",clearable:""},null,8,["modelValue"])]),_:1})),e.createVNode(s,{label:"标题"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.label,"onUpdate:modelValue":n[1]||(n[1]=R=>o.item.label=R),placeholder:"请输入",clearable:""},null,8,["modelValue"])]),_:1}),(z=o.item)!=null&&z.options&&o.item.component!="checkbox"&&o.item.component!="upload"?(e.openBlock(),e.createBlock(s,{key:2,label:"输入提示"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.options.placeholder,"onUpdate:modelValue":n[2]||(n[2]=R=>o.item.options.placeholder=R),placeholder:"请输入",clearable:""},null,8,["modelValue"])]),_:1})):e.createCommentVNode("",!0),(Y=o.item)!=null&&Y.options&&o.item.component!="checkbox"&&o.item.component!="upload"?(e.openBlock(),e.createBlock(s,{key:3,label:"禁用"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:o.item.options.disabled,"onUpdate:modelValue":n[3]||(n[3]=R=>o.item.options.disabled=R),"active-text":"启用","inactive-text":"禁用"},null,8,["modelValue"])]),_:1})):e.createCommentVNode("",!0),e.createVNode(s,{label:"内容提示"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.tips,"onUpdate:modelValue":n[4]||(n[4]=R=>o.item.tips=R),type:"textarea",placeholder:"请输入",clearable:""},null,8,["modelValue"])]),_:1})]),($=o.item)!=null&&$.span?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[n[34]||(n[34]=e.createElementVNode("div",{class:"form-title"},"布局配置",-1)),e.createElementVNode("div",C_,[e.createVNode(s,{label:"栅格"},{default:e.withCtx(()=>[e.createElementVNode("div",x_,[e.createVNode(f,{modelValue:o.item.span,"onUpdate:modelValue":n[5]||(n[5]=R=>o.item.span=R),step:4,"show-stops":"",min:4,max:24},null,8,["modelValue"])])]),_:1})])],64)):e.createCommentVNode("",!0),(H=o.item)!=null&&H.options?(e.openBlock(),e.createElementBlock("div",N_,"组件属性配置")):e.createCommentVNode("",!0),(X=o.item)!=null&&X.options?(e.openBlock(),e.createElementBlock("div",B_,[o.item.component==="input"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[o.item.options.type!="textarea"?(e.openBlock(),e.createBlock(s,{key:0,label:"输入类型"},{default:e.withCtx(()=>[e.createVNode(m,{modelValue:o.item.options.type,"onUpdate:modelValue":n[6]||(n[6]=R=>o.item.options.type=R),placeholder:"请选择输入类型"},{default:e.withCtx(()=>[e.createVNode(p,{label:"文本",value:"text"}),e.createVNode(p,{label:"密码",value:"password"}),e.createVNode(p,{label:"邮箱",value:"email"})]),_:1},8,["modelValue"])]),_:1})):e.createCommentVNode("",!0),e.createVNode(s,{label:"最大长度"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:o.item.options.maxlength,"onUpdate:modelValue":n[7]||(n[7]=R=>o.item.options.maxlength=R),min:1,"controls-position":"right",placeholder:"请输入"},null,8,["modelValue"])]),_:1})],64)):e.createCommentVNode("",!0),["select","radio","checkbox","checkboxGroup"].includes(o.item.component)?(e.openBlock(),e.createBlock(s,{key:1,label:"选项"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.item.options.items,(R,ne)=>(e.openBlock(),e.createElementBlock("div",{key:ne,class:"form-item"},[["checkbox"].includes(o.item.component)?(e.openBlock(),e.createBlock(i,{key:0,modelValue:R.name,"onUpdate:modelValue":h=>R.name=h,placeholder:"属性名称",clearable:""},null,8,["modelValue","onUpdate:modelValue"])):e.createCommentVNode("",!0),e.createVNode(i,{modelValue:R.label,"onUpdate:modelValue":h=>R.label=h,placeholder:"选项名称",clearable:""},null,8,["modelValue","onUpdate:modelValue"]),e.createVNode(i,{modelValue:R.value,"onUpdate:modelValue":h=>R.value=h,placeholder:"选项值",clearable:""},null,8,["modelValue","onUpdate:modelValue"]),o.item.options.items.length>1?(e.openBlock(),e.createBlock(k,{key:1,class:"remove-btn",size:"14",onClick:h=>o.item.options.items.splice(ne,1)},{default:e.withCtx(()=>[e.createVNode(C)]),_:2},1032,["onClick"])):e.createCommentVNode("",!0)]))),128)),e.createVNode(S,{type:"primary",size:"small",style:{width:"100%"},onClick:n[8]||(n[8]=R=>o.item.options.items.push({label:"",value:""}))},{default:e.withCtx(()=>n[35]||(n[35]=[e.createTextVNode("新增选项")])),_:1})]),_:1})):e.createCommentVNode("",!0),["tags"].includes(o.item.component)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createVNode(s,{label:"按钮名称"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.options.addText,"onUpdate:modelValue":n[9]||(n[9]=R=>o.item.options.addText=R),placeholder:"请输入",clearable:""},null,8,["modelValue"])]),_:1}),e.createVNode(s,{label:"默认标签"},{default:e.withCtx(()=>[e.createElementVNode("div",S_,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.item.value,R=>(e.openBlock(),e.createBlock(B,{key:R,closable:"","disable-transitions":!1,onClose:ne=>l.tagClose(R,o.item.value)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(R),1)]),_:2},1032,["onClose"]))),128)),r.tagVisible[o.item.name]?(e.openBlock(),e.createBlock(i,{key:0,modelValue:r.tagValue,"onUpdate:modelValue":n[10]||(n[10]=R=>r.tagValue=R),class:"w-20",size:"small",onKeyup:n[11]||(n[11]=e.withKeys(R=>l.tagInputConfirm(o.item,o.item.value),["enter"])),onBlur:n[12]||(n[12]=R=>l.tagInputConfirm(o.item,o.item.value))},null,8,["modelValue"])):(e.openBlock(),e.createBlock(S,{key:1,class:"button-new-tag",size:"small",onClick:n[13]||(n[13]=R=>r.tagVisible[o.item.name]=!0)},{default:e.withCtx(()=>n[36]||(n[36]=[e.createTextVNode(" + 添加 ")])),_:1}))])]),_:1})],64)):e.createCommentVNode("",!0),o.item.component==="switch"?(e.openBlock(),e.createBlock(s,{key:3,label:"开关文字"},{default:e.withCtx(()=>[e.createElementVNode("div",E_,[e.createVNode(i,{modelValue:o.item.options.activeText,"onUpdate:modelValue":n[14]||(n[14]=R=>o.item.options.activeText=R),placeholder:"开文字",clearable:""},null,8,["modelValue"]),e.createVNode(i,{modelValue:o.item.options.inactiveText,"onUpdate:modelValue":n[15]||(n[15]=R=>o.item.options.inactiveText=R),placeholder:"关文字",clearable:""},null,8,["modelValue"])])]),_:1})):e.createCommentVNode("",!0),["rate","number"].includes(o.item.component)?(e.openBlock(),e.createBlock(F,{key:4,gutter:10},{default:e.withCtx(()=>[e.createVNode(q,{span:12},{default:e.withCtx(()=>[e.createVNode(s,{label:"最小值"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:o.item.options.min,"onUpdate:modelValue":n[16]||(n[16]=R=>o.item.options.min=R),"controls-position":"right",placeholder:"最小值"},null,8,["modelValue"])]),_:1})]),_:1}),e.createVNode(q,{span:12},{default:e.withCtx(()=>[e.createVNode(s,{label:"最大值"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:o.item.options.max,"onUpdate:modelValue":n[17]||(n[17]=R=>o.item.options.max=R),"controls-position":"right",placeholder:"最大值"},null,8,["modelValue"])]),_:1})]),_:1}),e.createVNode(q,{span:12},{default:e.withCtx(()=>[e.createVNode(s,{label:"步长"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:o.item.options.step,"onUpdate:modelValue":n[18]||(n[18]=R=>o.item.options.step=R),"controls-position":"right",placeholder:"步长"},null,8,["modelValue"])]),_:1})]),_:1}),e.createVNode(q,{span:12},{default:e.withCtx(()=>[o.item.component=="number"?(e.openBlock(),e.createBlock(s,{key:0,label:"后缀"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:o.item.options.suffix,"onUpdate:modelValue":n[19]||(n[19]=R=>o.item.options.suffix=R),"controls-position":"right",placeholder:"后缀"},null,8,["modelValue"])]),_:1})):e.createCommentVNode("",!0)]),_:1})]),_:1})):e.createCommentVNode("",!0),o.item.component==="upload"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:5},e.renderList((ie=o.item)==null?void 0:ie.options.items,(R,ne)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:ne},[e.createVNode(F,{gutter:10},{default:e.withCtx(()=>[e.createVNode(q,{span:12},{default:e.withCtx(()=>[e.createVNode(s,{label:"宽"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:o.item.width,"onUpdate:modelValue":n[20]||(n[20]=h=>o.item.width=h),min:1,"controls-position":"right",placeholder:"宽"},null,8,["modelValue"])]),_:1})]),_:1}),e.createVNode(q,{span:12},{default:e.withCtx(()=>[e.createVNode(s,{label:"高"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:o.item.height,"onUpdate:modelValue":n[21]||(n[21]=h=>o.item.height=h),min:1,"controls-position":"right",placeholder:"高"},null,8,["modelValue"])]),_:1})]),_:1}),e.createVNode(q,{span:12},{default:e.withCtx(()=>[e.createVNode(s,{label:"数量限制"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:R.limit,"onUpdate:modelValue":h=>R.limit=h,min:1,"controls-position":"right",placeholder:"文件数量"},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024)]),_:2},1024),e.createVNode(q,{span:12},{default:e.withCtx(()=>[e.createVNode(s,{label:"文件大小"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:R.maxSize,"onUpdate:modelValue":h=>R.maxSize=h,min:1,"controls-position":"right",placeholder:"文件大小"},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024)]),_:2},1024)]),_:2},1024),e.createVNode(s,null,{label:e.withCtx(()=>[n[37]||(n[37]=e.createTextVNode(" 文件类型 ")),e.createVNode(j,{content:"不填默认类型image/gif, image/jpeg, image/png"},{default:e.withCtx(()=>[e.createVNode(k,null,{default:e.withCtx(()=>[e.createVNode(V)]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(i,{modelValue:R.accept,"onUpdate:modelValue":h=>R.accept=h,placeholder:"请输入文件类型,如 .jpg,.png",clearable:""},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024),e.createVNode(s,{label:"上传文案"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:R.label,"onUpdate:modelValue":h=>R.label=h,placeholder:"请输入",clearable:""},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024),e.createVNode(s,{label:"提示文案"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:R.tip,"onUpdate:modelValue":h=>R.tip=h,placeholder:"请输入",clearable:""},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024),e.createVNode(s,{label:"禁用"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:R.disabled,"onUpdate:modelValue":h=>R.disabled=h,"active-text":"启用","inactive-text":"禁用"},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024)],64))),128)):e.createCommentVNode("",!0),o.item.component==="date"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:6},[e.createVNode(s,{label:"日期类型"},{default:e.withCtx(()=>[e.createVNode(m,{modelValue:o.item.options.type,"onUpdate:modelValue":n[22]||(n[22]=R=>o.item.options.type=R),placeholder:"请选择日期类型"},{default:e.withCtx(()=>[e.createVNode(p,{label:"日期",value:"date"}),e.createVNode(p,{label:"日期时间",value:"datetime"}),e.createVNode(p,{label:"周",value:"week"}),e.createVNode(p,{label:"月份",value:"month"}),e.createVNode(p,{label:"年",value:"year"}),e.createVNode(p,{label:"日期范围",value:"daterange"}),e.createVNode(p,{label:"日期时间范围",value:"datetimerange"})]),_:1},8,["modelValue"])]),_:1}),e.createVNode(s,{label:"开始占位符"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.options.startPlaceholder,"onUpdate:modelValue":n[23]||(n[23]=R=>o.item.options.startPlaceholder=R),placeholder:"请输入开始占位符",clearable:""},null,8,["modelValue"])]),_:1}),e.createVNode(s,{label:"结束占位符"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.options.endPlaceholder,"onUpdate:modelValue":n[24]||(n[24]=R=>o.item.options.endPlaceholder=R),placeholder:"请输入结束占位符",clearable:""},null,8,["modelValue"])]),_:1}),e.createVNode(s,{label:"日期格式"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.options.format,"onUpdate:modelValue":n[25]||(n[25]=R=>o.item.options.format=R),placeholder:"请输入日期格式",clearable:""},null,8,["modelValue"])]),_:1}),e.createVNode(s,{label:"值格式"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.options.valueFormat,"onUpdate:modelValue":n[26]||(n[26]=R=>o.item.options.valueFormat=R),placeholder:"请输入值格式",clearable:""},null,8,["modelValue"])]),_:1}),e.createVNode(s,{label:"快捷选项"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:o.item.options.shortcuts,"onUpdate:modelValue":n[27]||(n[27]=R=>o.item.options.shortcuts=R),"active-text":"启用","inactive-text":"禁用"},null,8,["modelValue"])]),_:1})],64)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),n[39]||(n[39]=e.createElementVNode("div",{class:"form-title"},"表单校验",-1)),e.createElementVNode("div",T_,[e.createVNode(s,{label:"提交校验"},{default:e.withCtx(()=>[e.createVNode(m,{modelValue:o.item.rules,"onUpdate:modelValue":n[28]||(n[28]=R=>o.item.rules=R),multiple:"","value-key":"label",clearable:"",placeholder:"请选择"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.rules,R=>(e.openBlock(),e.createBlock(p,{key:R.label,label:R.label,value:R},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),e.createVNode(s,{label:"隐藏校验(满足条件时将隐藏该项)"},{default:e.withCtx(()=>[e.createElementVNode("div",I_,[e.createVNode(U,{modelValue:r.hideForm.label,"onUpdate:modelValue":n[29]||(n[29]=R=>r.hideForm.label=R),"show-all-levels":!1,props:{emitPath:!1},style:{flex:"1.2"},options:l.strList},null,8,["modelValue","options"]),e.createVNode(m,{modelValue:r.hideForm.filter,"onUpdate:modelValue":n[30]||(n[30]=R=>r.hideForm.filter=R),clearable:"",style:{flex:"1"},placeholder:"条件"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.filter,R=>(e.openBlock(),e.createBlock(p,{key:R.label,label:R.label,value:R.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"]),e.createVNode(i,{modelValue:r.hideForm.value,"onUpdate:modelValue":n[31]||(n[31]=R=>r.hideForm.value=R),style:{flex:"1"},placeholder:"值",clearable:""},null,8,["modelValue"])])]),_:1})])],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[n[40]||(n[40]=e.createElementVNode("div",{class:"form-title"},"表单样式",-1)),e.createElementVNode("div",D_,[e.createVNode(s,{label:"标题宽度"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.labelWidth,"onUpdate:modelValue":n[32]||(n[32]=R=>o.item.labelWidth=R),placeholder:"请输入",clearable:""},null,8,["modelValue"])]),_:1}),e.createVNode(s,{label:"标题位置"},{default:e.withCtx(()=>[e.createVNode(m,{modelValue:o.item.labelPosition,"onUpdate:modelValue":n[33]||(n[33]=R=>o.item.labelPosition=R),placeholder:"请选择"},{default:e.withCtx(()=>[e.createVNode(p,{label:"顶部",value:"top"}),e.createVNode(p,{label:"左",value:"left"}),e.createVNode(p,{label:"右",value:"right"})]),_:1},8,["modelValue"])]),_:1})]),n[41]||(n[41]=e.createElementVNode("div",{class:"form-title"},"数据层级",-1)),e.createVNode(L,{formItems:o.config.formItems},null,8,["formItems"])],64))]}),_:1},8,["model"])}const q_=le(w_,[["render",F_],["__scopeId","data-v-21c6d3c4"]]),Wt=[{title:"布局组件",list:[{label:"组合",name:"object",value:[],component:"object",span:24},{label:"列表",name:"list",value:[[]],component:"list",span:24},{label:"标题",span:24,component:"divider"}]},{title:"基础组件",list:[{label:"单行输入",name:"input",value:"",component:"input",span:24,options:{placeholder:"请输入"}},{label:"多行输入",name:"textarea",value:"",component:"input",span:24,options:{type:"textarea",placeholder:"请输入"}},{label:"数值",name:"number",value:0,options:{},span:24,component:"number"},{label:"颜色",name:"color",value:"",span:24,component:"color"},{label:"标签",name:"tags",value:[],span:24,options:{addText:"添加"},component:"tags"}]},{title:"是否选项",list:[{label:"开关",name:"switch",span:24,options:{},value:!1,component:"switch"},{label:"下拉选择",name:"select",value:"",component:"select",span:24,options:{placeholder:"请选择",items:[{label:"选项1",value:"1"}]}}]},{title:"单选多选",list:[{label:"单选",name:"radio",value:"",component:"radio",span:24,options:{items:[{label:"选项1",value:"1"}]}},{label:"多选框",name:"checkboxGroup",component:"checkboxGroup",span:24,value:[],options:{items:[{label:"选项1",value:"1"}]}},{label:"下拉多选",name:"select",value:"",component:"select",span:24,options:{placeholder:"请选择",multiple:!0,items:[{label:"选项1",value:"1"}]}},{label:"下拉单选",name:"select",value:"",component:"select",span:24,options:{placeholder:"请选择",items:[{label:"选项1",value:"1"}]}}]},{title:"文件上传",list:[{label:"图片单张",component:"upload",span:24,width:148,height:148,options:{items:[{label:"请选择",name:"img1",value:""}]}},{label:"图片多张",component:"upload",span:24,width:148,height:148,options:{items:[{label:"请选择",multiple:!0,maxSize:100,limit:6,name:"img2",returnFile:"url",value:[]}]}},{label:"视屏单个",component:"upload",span:24,width:148,height:148,options:{items:[{label:"请选择",accept:"video/mp4",name:"videos",value:""}]}},{label:"视屏多个",component:"upload",span:24,width:148,height:148,options:{items:[{label:"请选择",accept:"video/mp4",multiple:!0,maxSize:100,limit:6,returnFile:"url",name:"videos3",value:[]}]}}]},{title:"时间日期",list:[{label:"日期范围",name:"date",value:"",component:"date",span:24,options:{type:"daterange",startPlaceholder:"开始时间",endPlaceholder:"结束时间",valueFormat:"YYYY-MM-DD HH:mm:ss"}},{label:"日期时间",name:"date1",value:"",component:"date",span:24,options:{type:"datetime",valueFormat:"YYYY-MM-DD HH:mm:ss"}},{label:"日期",name:"date2",value:"",component:"date",span:24,options:{type:"date",valueFormat:"YYYY-MM-DD"}},{label:"年",name:"date4",value:"",component:"date",span:24,options:{type:"year"}},{label:"月",name:"date5",value:"",component:"date",span:24,options:{type:"month"}},{label:"周",name:"date6",value:"",component:"date",span:24,options:{type:"week",format:"[Week] ww"}}]}],R_={components:{JsonItem:u_,StatsConfig:q_,draggable:Gt},props:{modelValue:{type:Object,default:()=>{}},config:{type:Object,default:()=>({})},maxHeight:{type:String,default:"calc(100vh - 137px)"},custom:{type:Array,default:()=>[]},loading:{type:Boolean,default:!1},hideTool:{type:Boolean,default:!0},isView:{type:Boolean,default:!1},hideBorder:{type:Boolean,default:!0}},data(){return{form:{},curItem:{},menuList:[],scrollObserverEnabled:!0,renderLoading:!1,activeNames:"布局组件"}},emits:["update:config","update:modelValue"],watch:{modelValue:{handler(t,n){this.hasConfig&&(this.form=t)},deep:!0},config:{handler(t){this.render(t),this.$emit("update:config",t)},immediate:!0,deep:!0},custom:{handler(t){if(this.menuList=[],t&&t.length>0){let n=Wt.findIndex(o=>o.title=="自定义组件");if(n>-1)Wt[n].list=t;else{let o={title:"自定义组件",list:t};Wt.push(o)}}this.menuList=Wt},immediate:!0,deep:!0}},computed:{hasConfig(){return Object.keys(this.config).length>0},hasValue(){return Object.keys(this.modelValue).length>0}},mounted(){this.hasConfig&&(this.render(),this.curItem=this.config)},methods:{render(t=this.config){function n(a,r){const l={};return a.forEach(i=>{var d,f,p,m;if((i.component==="checkbox"||i.component==="upload")&&((f=(d=i.options)==null?void 0:d.items)==null||f.forEach(_=>{if(!(_!=null&&_.name))return!1;l[_.name]=(r==null?void 0:r[_.name])??_.value})),!(i!=null&&i.name))return!1;let s=r==null?void 0:r[i.name];i.component==="list"?l[i.name]=((p=i.value)==null?void 0:p.map((_,C)=>(s?s=(r==null?void 0:r[i.name][C])||{}:s=[],n(_,s))))||[]:i.component==="object"?l[i.name]=n(i.value,s||{}):i.component==="number"?l[i.name]=s??(i.value!==void 0?Number(i.value):((m=i.options)==null?void 0:m.min)||0):l[i.name]=s??i.value}),l}let o=n(t.formItems,this.modelValue);this.form=this.parseNestedObject(o),this.$emit("update:modelValue",this.form)},parseNestedObject(t){const n={};for(const[o,a]of Object.entries(t)){const r=o.split(".");let l=n;r.forEach((i,s)=>{l[i]||(l[i]=s===r.length-1?a:{}),l=l[i]}),r.length>1&&delete t[o]}return n},validate(t,n){return this.$refs.form.validate(t,n)},clearValidate(t,n){return this.$refs.form.clearValidate()},scrollToField(t){return this.$refs.form.scrollToField(t)},resetFields(){return this.$refs.form.resetFields()},cloneItem(t){let n=JSON.parse(JSON.stringify(t));return t.component=="checkbox"||t.component=="upload"?n.options.items[0].name=`${t.component}-${this.$tool.getUUID("",2)}`:n.name=`${t.component}-${this.$tool.getUUID("",2)}`,{...n}},selectItem(t){this.curItem=t},back(){this.curItem=this.config,this.$store.state.curIndex=""}}},A_={class:"menu-list"},O_={class:"list-group-item"};function v_(t,n,o,a,r,l){const i=e.resolveComponent("draggable"),s=e.resolveComponent("el-collapse-item"),d=e.resolveComponent("el-collapse"),f=e.resolveComponent("el-aside"),p=e.resolveComponent("JsonItem"),m=e.resolveComponent("el-row"),_=e.resolveComponent("el-form"),C=e.resolveComponent("el-main"),k=e.resolveComponent("el-container"),S=e.resolveComponent("StatsConfig"),B=e.resolveDirective("loading");return e.openBlock(),e.createBlock(k,{style:e.normalizeStyle({maxHeight:o.maxHeight})},{default:e.withCtx(()=>[o.hideTool?(e.openBlock(),e.createBlock(f,{key:0,width:"200px",class:"form-json-body"},{default:e.withCtx(()=>[e.createElementVNode("div",A_,[e.createVNode(d,{modelValue:r.activeNames,"onUpdate:modelValue":n[0]||(n[0]=q=>r.activeNames=q)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.menuList,q=>(e.openBlock(),e.createBlock(s,{title:q.title,name:q.title,class:"menu-list-title"},{default:e.withCtx(()=>[e.createVNode(i,{class:"menu-list-group",list:q.list,group:{name:"people",pull:"clone",put:!1},clone:l.cloneItem,"item-key":"name"},{item:e.withCtx(({element:F})=>[e.createElementVNode("div",O_,e.toDisplayString(F.label),1)]),_:2},1032,["list","clone"])]),_:2},1032,["title","name"]))),256))]),_:1},8,["modelValue"])])]),_:1})):e.createCommentVNode("",!0),e.createVNode(k,null,{default:e.withCtx(()=>[e.createVNode(C,{class:"form-json-body"},{default:e.withCtx(()=>[e.withDirectives((e.openBlock(),e.createBlock(_,{ref:"form",onClickCapture:n[1]||(n[1]=q=>l.back(o.config)),model:r.form,"label-width":o.config.labelWidth,"label-position":t.$i18n.locale=="en-us"?"top":o.config.labelPosition,disabled:o.isView,"element-loading-text":"Loading..."},{default:e.withCtx(()=>[e.createVNode(m,{gutter:10},{default:e.withCtx(()=>[e.createVNode(p,{formItems:o.config.formItems,hideBorder:o.hideBorder,form:r.form,custom:o.custom,onCurClick:l.selectItem},e.createSlots({_:2},[e.renderList(o.custom,q=>({name:q.component,fn:e.withCtx(({itemCur:F,formCur:V})=>[e.renderSlot(t.$slots,q.component,{itemCur:F,formCur:V},void 0,!0)])}))]),1032,["formItems","hideBorder","form","custom","onCurClick"])]),_:3})]),_:3},8,["model","label-width","label-position","disabled"])),[[B,o.loading]])]),_:3})]),_:3}),o.hideTool?(e.openBlock(),e.createBlock(f,{key:1,width:"300px",class:"aside-right"},{default:e.withCtx(()=>[e.createVNode(S,{item:r.curItem,config:o.config},null,8,["item","config"])]),_:1})):e.createCommentVNode("",!0)]),_:3},8,["style"])}const ls=le(R_,[["render",v_],["__scopeId","data-v-65cb0380"]]),P_={props:{modelValue:{type:String,default:""},width:{type:String,default:""},password:{type:Boolean,default:!1}},data(){return{isEncrypted:this.password}},computed:{encryptedText(){return"*".repeat(this.modelValue.length)},textWidth(){return this!=null&&this.width?`calc(100% - ${this.width} - 10px)`:""}},methods:{toggleEncryption(){this.isEncrypted=!this.isEncrypted,this.isEncrypted||this.$emit("update:modelValue",this.modelValue)}}};function L_(t,n,o,a,r,l){const i=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("span",{class:"item-text",style:e.normalizeStyle({width:l.textWidth})},[e.createElementVNode("span",null,e.toDisplayString(r.isEncrypted?l.encryptedText:o.modelValue),1),o.password?(e.openBlock(),e.createBlock(i,{key:0,link:"",type:"primary",icon:"el-icon-view",onClick:l.toggleEncryption},null,8,["onClick"])):e.createCommentVNode("",!0)],4)}const M_={components:{lwUpload:St,textToPassword:le(P_,[["render",L_],["__scopeId","data-v-d22eb341"]])},props:{modelValue:{type:Object,default:()=>{}},config:{type:Object,default:()=>{}},loading:{type:Boolean,default:!1},isView:{type:Boolean,default:!1}},data(){return{form:{},tagValue:"",tagVisible:!1,renderLoading:!1}},watch:{modelValue(){this.hasConfig&&this.deepMerge(this.form,JSON.parse(JSON.stringify(this.modelValue)))},config(){this.render()},form:{handler(t){this.$emit("update:modelValue",t)},deep:!0}},computed:{hasConfig(){return Object.keys(this.config).length>0},hasValue(){return Object.keys(this.modelValue).length>0}},mounted(){this.hasConfig&&this.render()},methods:{render(){this.form={},this.config.formItems.forEach(t=>{var n,o,a;if(t.component=="checkbox"||t.component=="upload")if(t.name){const r={};t==null||t.options.items.forEach(l=>{r[l.name]=l.value}),this.form[t.name]=r}else(n=t==null?void 0:t.options)!=null&&n.items&&(t==null||t.options.items.forEach(r=>{this.form[r.name]=r.value}));else(o=t==null?void 0:t.options)!=null&&o.name?(this.form[t.name]||(this.form[t.name]={}),this.form[t.name][(a=t==null?void 0:t.options)==null?void 0:a.name]=t.value):t.name&&(this.form[t.name]=t.value)}),this.hasValue&&(this.form=this.deepMerge(this.form,this.modelValue))},deepMerge(t,n){for(let o in n)if(n.hasOwnProperty(o)){const a=t[o]!==null&&t[o]!==void 0,r=n[o]!==null&&n[o]!==void 0;a&&typeof t[o]=="object"&&!Array.isArray(t[o])&&r&&typeof n[o]=="object"&&!Array.isArray(n[o])?t[o]=this.deepMerge(t[o],n[o]):r?t[o]=n[o]:r||delete t[o]}return t},hideHandle(t){return typeof t.hideHandle=="string"?new Function("form",`return ${t==null?void 0:t.hideHandle.replace(/\$/g,"form")}`)(this.form):typeof t.hideHandle=="boolean"?t.hideHandle:!1},rulesHandle(t){if(t.requiredHandle)try{const o=new Function("form",`return ${t.requiredHandle.replace(/\$/g,"form")}`)(this.form),a=t.rules.find(r=>"required"in r);a&&(a.required=o)}catch(n){console.error("Error requiredHandle function:",n)}return t.rules},getKeyToLabel(t,n=[]){let o=n.find(a=>a.value==t);return(o==null?void 0:o.label)||"--"},dayjs:$e}},U_={class:"top-title-body"},j_={class:"lw-form-view-title-name"},z_={key:12,class:"tags-list"},H_={key:14,class:"el-form-item-msg"};function K_(t,n,o,a,r,l){const i=e.resolveComponent("el-skeleton"),s=e.resolveComponent("el-col"),d=e.resolveComponent("el-icon-question-filled"),f=e.resolveComponent("el-icon"),p=e.resolveComponent("el-tooltip"),m=e.resolveComponent("textToPassword"),_=e.resolveComponent("el-image"),C=e.resolveComponent("el-cascader"),k=e.resolveComponent("el-color-picker"),S=e.resolveComponent("el-rate"),B=e.resolveComponent("el-slider"),q=e.resolveComponent("el-tag"),F=e.resolveComponent("el-row");return r.renderLoading||Object.keys(r.form).length==0?(e.openBlock(),e.createBlock(i,{key:0,animated:""})):(e.openBlock(),e.createBlock(F,{key:1,gutter:0},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.config.formItems,(V,j)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[l.hideHandle(V)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[V.component=="divider"?(e.openBlock(),e.createBlock(s,{key:0,span:V.span||24,class:e.normalizeClass({topPadding:j!==0})},{default:e.withCtx(()=>{var U;return[e.createElementVNode("div",U_,[e.createElementVNode("span",j_,e.toDisplayString(V.label),1),e.renderSlot(t.$slots,(U=V==null?void 0:V.options)==null?void 0:U.component,{},void 0,!0)])]}),_:2},1032,["span","class"])):(e.openBlock(),e.createBlock(s,{key:1,span:V.span},{default:e.withCtx(()=>{var U,L,A,z,Y,$,H,X,ie,R,ne,h;return[e.createElementVNode("div",{class:e.normalizeClass(["span-item",[o.config.labelPosition]])},[V.label?(e.openBlock(),e.createElementBlock("span",{key:0,style:e.normalizeStyle({minWidth:o.config.labelWidth}),class:"title-item"},[e.createTextVNode(e.toDisplayString(V.label)+" ",1),V.tips?(e.openBlock(),e.createBlock(p,{key:0,content:V.tips},{default:e.withCtx(()=>[e.createVNode(f,null,{default:e.withCtx(()=>[e.createVNode(d)]),_:1})]),_:2},1032,["content"])):e.createCommentVNode("",!0),n[0]||(n[0]=e.createTextVNode(": "))],4)):e.createCommentVNode("",!0),V.component=="input"||V.component=="number"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[(U=V==null?void 0:V.options)!=null&&U.name?(e.openBlock(),e.createBlock(m,{key:0,modelValue:r.form[V.name][V==null?void 0:V.options.name],"onUpdate:modelValue":T=>r.form[V.name][V==null?void 0:V.options.name]=T,width:o.config.labelWidth,password:(L=V==null?void 0:V.options)==null?void 0:L.password},null,8,["modelValue","onUpdate:modelValue","width","password"])):(e.openBlock(),e.createBlock(m,{key:1,modelValue:r.form[V.name],"onUpdate:modelValue":T=>r.form[V.name]=T,password:(A=V==null?void 0:V.options)==null?void 0:A.password},null,8,["modelValue","onUpdate:modelValue","password"]))],64)):V.component=="upload"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList(V==null?void 0:V.options.items,(T,x)=>(e.openBlock(),e.createBlock(s,{key:x},{default:e.withCtx(()=>[V.name?(e.openBlock(),e.createBlock(_,{key:0,style:{width:"100px",height:"100px"},src:r.form[V.name][T.name],fit:t.contain},null,8,["src","fit"])):(e.openBlock(),e.createBlock(_,{key:1,style:{width:"100px",height:"100px"},src:r.form[T.name],fit:t.contain},null,8,["src","fit"]))]),_:2},1024))),128)):V.component=="checkbox"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[V.name?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(r.form[V.name][t._item.name]),1)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(r.form[t._item.name]),1)],64))],64)):V.component=="checkboxGroup"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[e.createTextVNode(e.toDisplayString(r.form[V.name]),1)],64)):V.component=="switch"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[(z=V==null?void 0:V.options)!=null&&z.name?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(r.form[V.name][V==null?void 0:V.options.name]?(V==null?void 0:V.options.true)||"是":(V==null?void 0:V.options.false)||"否"),1)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(r.form[V.name]?(V==null?void 0:V.options.true)||"是":(V==null?void 0:V.options.false)||"否"),1)],64))],64)):V.component=="select"||V.component=="radio"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:6},[(Y=V==null?void 0:V.options)!=null&&Y.name?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(l.getKeyToLabel(r.form[V.name][V==null?void 0:V.options.name],V==null?void 0:V.options.items)),1)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(l.getKeyToLabel(r.form[V.name],V==null?void 0:V.options.items)),1)],64))],64)):V.component=="cascader"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:7},[($=V==null?void 0:V.options)!=null&&$.name?(e.openBlock(),e.createBlock(C,{key:0,modelValue:r.form[V.name][V==null?void 0:V.options.name],"onUpdate:modelValue":T=>r.form[V.name][V==null?void 0:V.options.name]=T,options:V==null?void 0:V.options.items,clearable:""},null,8,["modelValue","onUpdate:modelValue","options"])):(e.openBlock(),e.createBlock(C,{key:1,modelValue:r.form[V.name],"onUpdate:modelValue":T=>r.form[V.name]=T,options:V==null?void 0:V.options.items,clearable:""},null,8,["modelValue","onUpdate:modelValue","options"]))],64)):V.component=="date"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:8},[(H=V==null?void 0:V.options)!=null&&H.name?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(l.dayjs(r.form[V.name][V==null?void 0:V.options.name]).format((V==null?void 0:V.options.valueFormat)||"YYYY-MM-DD HH:mm:ss")),1)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(l.dayjs(r.form[V.name]).format((V==null?void 0:V.options.valueFormat)||"YYYY-MM-DD HH:mm:ss")),1)],64))],64)):V.component=="color"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:9},[(X=V==null?void 0:V.options)!=null&&X.name?(e.openBlock(),e.createBlock(k,{key:0,disabled:"",modelValue:r.form[V.name][V==null?void 0:V.options.name],"onUpdate:modelValue":T=>r.form[V.name][V==null?void 0:V.options.name]=T},null,8,["modelValue","onUpdate:modelValue"])):(e.openBlock(),e.createBlock(k,{key:1,disabled:"",modelValue:r.form[V.name],"onUpdate:modelValue":T=>r.form[V.name]=T},null,8,["modelValue","onUpdate:modelValue"]))],64)):V.component=="rate"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:10},[(ie=V==null?void 0:V.options)!=null&&ie.name?(e.openBlock(),e.createBlock(S,{key:0,disabled:"",modelValue:r.form[V.name][V==null?void 0:V.options.name],"onUpdate:modelValue":T=>r.form[V.name][V==null?void 0:V.options.name]=T},null,8,["modelValue","onUpdate:modelValue"])):(e.openBlock(),e.createBlock(S,{key:1,disabled:"",modelValue:r.form[V.name],"onUpdate:modelValue":T=>r.form[V.name]=T},null,8,["modelValue","onUpdate:modelValue"]))],64)):V.component=="slider"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:11},[(R=V==null?void 0:V.options)!=null&&R.name?(e.openBlock(),e.createBlock(B,{key:0,disabled:"",modelValue:r.form[V.name][V==null?void 0:V.options.name],"onUpdate:modelValue":T=>r.form[V.name][V==null?void 0:V.options.name]=T,marks:V==null?void 0:V.options.marks},null,8,["modelValue","onUpdate:modelValue","marks"])):(e.openBlock(),e.createBlock(B,{key:1,disabled:"",modelValue:r.form[V.name],"onUpdate:modelValue":T=>r.form[V.name]=T,marks:V==null?void 0:V.options.marks},null,8,["modelValue","onUpdate:modelValue","marks"]))],64)):V.component=="tags"?(e.openBlock(),e.createElementBlock("div",z_,[(ne=V==null?void 0:V.options)!=null&&ne.name?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(r.form[V.name][(h=V==null?void 0:V.options)==null?void 0:h.name],T=>(e.openBlock(),e.createBlock(q,{key:T},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(T),1)]),_:2},1024))),128)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(r.form[V.name],T=>(e.openBlock(),e.createBlock(q,{key:T},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(T),1)]),_:2},1024))),128))])):e.renderSlot(t.$slots,V.component,{key:13},()=>[e.createVNode(q,{type:"danger"},{default:e.withCtx(()=>[e.createTextVNode(" ["+e.toDisplayString(V.component)+"] 没有这个默认组件也未自定义插槽内容",1)]),_:2},1024)],!0),V.message?(e.openBlock(),e.createElementBlock("div",H_,e.toDisplayString(V.message),1)):e.createCommentVNode("",!0)],2)]}),_:2},1032,["span"]))],64))],64))),256))]),_:3}))}const is=le(M_,[["render",K_],["__scopeId","data-v-a142ffc2"]]),G_={name:"lwCronSelect",props:{disabled:{type:Boolean,default:!1},modelValue:{type:String,default:""}},setup(t,{emit:n}){var m,_,C;const o=e.computed(()=>t.modelValue?t.modelValue.split(" "):["*","*","*","*","*","?"]),a=e.ref(t.modelValue),r=e.ref(!1),l=k=>{switch(k){case 3:o.value[3]="*",o.value[4]="*",o.value[5]="*";break;case 4:o.value[4]="*",o.value[5]="*";break;case 5:o.value[5]="?";break}i.value.day=[],i.value.weeks=[],i.value.month=[],i.value.timeData=""},i=e.ref({curType:o.value[4]!=="*"?4:o.value[5]==="?"?3:5,day:o.value[3]==="*"?[]:(m=o.value[3])==null?void 0:m.split(","),month:o.value[4]==="*"?[]:(_=o.value[4])==null?void 0:_.split(","),weeks:o.value[5]==="?"?[]:(C=o.value[5])==null?void 0:C.split(","),timeData:o.value[0]==="*"?"":`${o.value[2]}:${o.value[1]}:${o.value[0]}`});return{setData:i,showInput:a,visible:r,changeInt:l,changeOk:()=>{const k=i.value.timeData?i.value.timeData.split(":"):["*","*","*"];o.value[0]=k[2]==="*"?k[2]:parseInt(k[2],10).toString(),o.value[1]=k[1]==="*"?k[1]:parseInt(k[1],10).toString(),o.value[2]=k[0]==="*"?k[0]:parseInt(k[0],10).toString(),o.value[3]=i.value.day.length>0?i.value.day.toString():"*",o.value[4]=i.value.month.length>0?i.value.month.toString():"*",o.value[5]=i.value.weeks.length>0?i.value.weeks.toString():"?",o.value[3]==="*"&&o.value[5]!=="?"&&(o.value[3]="?"),a.value=`${o.value[0]} ${o.value[1]} ${o.value[2]} ${o.value[3]} ${o.value[4]} ${o.value[5]}`,n("update:modelValue",a.value),n("change"),r.value=!1},changeCron:()=>{n("update:modelValue",a.value),n("change")},changeDay:k=>{k.indexOf("L")!==-1&&(i.value.day=["L"])},changeWeeks:k=>{k.indexOf("?")!==-1&&(i.value.weeks=["?"])}}}},Y_={class:"select-model"},$_={style:{"margin-top":"10px","text-align":"right"}};function W_(t,n,o,a,r,l){const i=e.resolveComponent("el-button"),s=e.resolveComponent("el-option"),d=e.resolveComponent("el-select"),f=e.resolveComponent("el-time-picker"),p=e.resolveComponent("el-popover"),m=e.resolveComponent("el-input");return e.openBlock(),e.createBlock(m,{modelValue:a.showInput,"onUpdate:modelValue":n[6]||(n[6]=_=>a.showInput=_),placeholder:"CRON"},{append:e.withCtx(()=>[e.createVNode(p,{placement:"top",width:380,visible:a.visible,trigger:"click"},{reference:e.withCtx(()=>[e.createVNode(i,{onClick:n[0]||(n[0]=_=>a.visible=!0)},{default:e.withCtx(()=>n[7]||(n[7]=[e.createTextVNode("选择")])),_:1})]),default:e.withCtx(()=>[e.createElementVNode("div",Y_,[e.createVNode(d,{modelValue:a.setData.curType,"onUpdate:modelValue":n[1]||(n[1]=_=>a.setData.curType=_),placeholder:"选择类型",onChange:a.changeInt,style:{"margin-right":"5px","min-width":"80px",width:"80px"}},{default:e.withCtx(()=>[e.createVNode(s,{label:"每天",value:3}),e.createVNode(s,{label:"每月",value:4}),e.createVNode(s,{label:"每周",value:5})]),_:1},8,["modelValue","onChange"]),a.setData.curType===4?(e.openBlock(),e.createBlock(d,{key:0,modelValue:a.setData.day,"onUpdate:modelValue":n[2]||(n[2]=_=>a.setData.day=_),multiple:"","allow-clear":"",placeholder:"日期",onChange:a.changeDay,"max-tag-count":1,style:{"margin-right":"5px","min-width":"120px"}},{default:e.withCtx(()=>[e.createVNode(s,{label:"最后一天",value:"L"}),(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(31,_=>e.createVNode(s,{key:_,label:_,value:_,disabled:a.setData.day.indexOf("L")!==-1},null,8,["label","value","disabled"])),64))]),_:1},8,["modelValue","onChange"])):e.createCommentVNode("",!0),a.setData.curType===5?(e.openBlock(),e.createBlock(d,{key:1,modelValue:a.setData.weeks,"onUpdate:modelValue":n[3]||(n[3]=_=>a.setData.weeks=_),multiple:"","allow-clear":"",placeholder:"星期",onChange:a.changeWeeks,"max-tag-count":1,style:{"margin-right":"5px","min-width":"120px"}},{default:e.withCtx(()=>[e.createVNode(s,{label:"周日",value:"1",disabled:a.setData.weeks.indexOf("?")!==-1},null,8,["disabled"]),e.createVNode(s,{label:"周一",value:"2",disabled:a.setData.weeks.indexOf("?")!==-1},null,8,["disabled"]),e.createVNode(s,{label:"周二",value:"3",disabled:a.setData.weeks.indexOf("?")!==-1},null,8,["disabled"]),e.createVNode(s,{label:"周三",value:"4",disabled:a.setData.weeks.indexOf("?")!==-1},null,8,["disabled"]),e.createVNode(s,{label:"周四",value:"5",disabled:a.setData.weeks.indexOf("?")!==-1},null,8,["disabled"]),e.createVNode(s,{label:"周五",value:"6",disabled:a.setData.weeks.indexOf("?")!==-1},null,8,["disabled"]),e.createVNode(s,{label:"周六",value:"7",disabled:a.setData.weeks.indexOf("?")!==-1},null,8,["disabled"])]),_:1},8,["modelValue","onChange"])):e.createCommentVNode("",!0),e.createVNode(f,{modelValue:a.setData.timeData,"onUpdate:modelValue":n[4]||(n[4]=_=>a.setData.timeData=_),placeholder:"时分秒","value-format":"HH:mm:ss",style:{"min-width":"100px"}},null,8,["modelValue"])]),e.createElementVNode("div",$_,[e.createVNode(i,{onClick:n[5]||(n[5]=_=>a.visible=!1)},{default:e.withCtx(()=>n[8]||(n[8]=[e.createTextVNode("取消")])),_:1}),e.createVNode(i,{type:"primary",onClick:a.changeOk},{default:e.withCtx(()=>n[9]||(n[9]=[e.createTextVNode("确定")])),_:1},8,["onClick"])])]),_:1},8,["visible"])]),_:1},8,["modelValue"])}const ss=le(G_,[["render",W_],["__scopeId","data-v-5f87e552"]]);function xn(t){throw new Error('Could not dynamically require "'+t+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Nn,cs;function J_(){if(cs)return Nn;cs=1;function t(){this.__data__=[],this.size=0}return Nn=t,Nn}var Bn,ds;function Et(){if(ds)return Bn;ds=1;function t(n,o){return n===o||n!==n&&o!==o}return Bn=t,Bn}var Sn,us;function Jt(){if(us)return Sn;us=1;var t=Et();function n(o,a){for(var r=o.length;r--;)if(t(o[r][0],a))return r;return-1}return Sn=n,Sn}var En,hs;function Z_(){if(hs)return En;hs=1;var t=Jt(),n=Array.prototype,o=n.splice;function a(r){var l=this.__data__,i=t(l,r);if(i<0)return!1;var s=l.length-1;return i==s?l.pop():o.call(l,i,1),--this.size,!0}return En=a,En}var Tn,fs;function X_(){if(fs)return Tn;fs=1;var t=Jt();function n(o){var a=this.__data__,r=t(a,o);return r<0?void 0:a[r][1]}return Tn=n,Tn}var In,ps;function Q_(){if(ps)return In;ps=1;var t=Jt();function n(o){return t(this.__data__,o)>-1}return In=n,In}var Dn,ms;function e1(){if(ms)return Dn;ms=1;var t=Jt();function n(o,a){var r=this.__data__,l=t(r,o);return l<0?(++this.size,r.push([o,a])):r[l][1]=a,this}return Dn=n,Dn}var Fn,gs;function Zt(){if(gs)return Fn;gs=1;var t=J_(),n=Z_(),o=X_(),a=Q_(),r=e1();function l(i){var s=-1,d=i==null?0:i.length;for(this.clear();++s<d;){var f=i[s];this.set(f[0],f[1])}}return l.prototype.clear=t,l.prototype.delete=n,l.prototype.get=o,l.prototype.has=a,l.prototype.set=r,Fn=l,Fn}var qn,bs;function t1(){if(bs)return qn;bs=1;var t=Zt();function n(){this.__data__=new t,this.size=0}return qn=n,qn}var Rn,ys;function n1(){if(ys)return Rn;ys=1;function t(n){var o=this.__data__,a=o.delete(n);return this.size=o.size,a}return Rn=t,Rn}var An,_s;function o1(){if(_s)return An;_s=1;function t(n){return this.__data__.get(n)}return An=t,An}var On,ks;function r1(){if(ks)return On;ks=1;function t(n){return this.__data__.has(n)}return On=t,On}var vn,ws;function Vs(){if(ws)return vn;ws=1;var t=typeof $t=="object"&&$t&&$t.Object===Object&&$t;return vn=t,vn}var Pn,Cs;function We(){if(Cs)return Pn;Cs=1;var t=Vs(),n=typeof self=="object"&&self&&self.Object===Object&&self,o=t||n||Function("return this")();return Pn=o,Pn}var Ln,xs;function Tt(){if(xs)return Ln;xs=1;var t=We(),n=t.Symbol;return Ln=n,Ln}var Mn,Ns;function a1(){if(Ns)return Mn;Ns=1;var t=Tt(),n=Object.prototype,o=n.hasOwnProperty,a=n.toString,r=t?t.toStringTag:void 0;function l(i){var s=o.call(i,r),d=i[r];try{i[r]=void 0;var f=!0}catch{}var p=a.call(i);return f&&(s?i[r]=d:delete i[r]),p}return Mn=l,Mn}var Un,Bs;function l1(){if(Bs)return Un;Bs=1;var t=Object.prototype,n=t.toString;function o(a){return n.call(a)}return Un=o,Un}var jn,Ss;function kt(){if(Ss)return jn;Ss=1;var t=Tt(),n=a1(),o=l1(),a="[object Null]",r="[object Undefined]",l=t?t.toStringTag:void 0;function i(s){return s==null?s===void 0?r:a:l&&l in Object(s)?n(s):o(s)}return jn=i,jn}var zn,Es;function ze(){if(Es)return zn;Es=1;function t(n){var o=typeof n;return n!=null&&(o=="object"||o=="function")}return zn=t,zn}var Hn,Ts;function Rt(){if(Ts)return Hn;Ts=1;var t=kt(),n=ze(),o="[object AsyncFunction]",a="[object Function]",r="[object GeneratorFunction]",l="[object Proxy]";function i(s){if(!n(s))return!1;var d=t(s);return d==a||d==r||d==o||d==l}return Hn=i,Hn}var Kn,Is;function i1(){if(Is)return Kn;Is=1;var t=We(),n=t["__core-js_shared__"];return Kn=n,Kn}var Gn,Ds;function s1(){if(Ds)return Gn;Ds=1;var t=i1(),n=function(){var a=/[^.]+$/.exec(t&&t.keys&&t.keys.IE_PROTO||"");return a?"Symbol(src)_1."+a:""}();function o(a){return!!n&&n in a}return Gn=o,Gn}var Yn,Fs;function qs(){if(Fs)return Yn;Fs=1;var t=Function.prototype,n=t.toString;function o(a){if(a!=null){try{return n.call(a)}catch{}try{return a+""}catch{}}return""}return Yn=o,Yn}var $n,Rs;function c1(){if(Rs)return $n;Rs=1;var t=Rt(),n=s1(),o=ze(),a=qs(),r=/[\\^$.*+?()[\]{}|]/g,l=/^\[object .+?Constructor\]$/,i=Function.prototype,s=Object.prototype,d=i.toString,f=s.hasOwnProperty,p=RegExp("^"+d.call(f).replace(r,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function m(_){if(!o(_)||n(_))return!1;var C=t(_)?p:l;return C.test(a(_))}return $n=m,$n}var Wn,As;function d1(){if(As)return Wn;As=1;function t(n,o){return n==null?void 0:n[o]}return Wn=t,Wn}var Jn,Os;function wt(){if(Os)return Jn;Os=1;var t=c1(),n=d1();function o(a,r){var l=n(a,r);return t(l)?l:void 0}return Jn=o,Jn}var Zn,vs;function Xn(){if(vs)return Zn;vs=1;var t=wt(),n=We(),o=t(n,"Map");return Zn=o,Zn}var Qn,Ps;function Xt(){if(Ps)return Qn;Ps=1;var t=wt(),n=t(Object,"create");return Qn=n,Qn}var eo,Ls;function u1(){if(Ls)return eo;Ls=1;var t=Xt();function n(){this.__data__=t?t(null):{},this.size=0}return eo=n,eo}var to,Ms;function h1(){if(Ms)return to;Ms=1;function t(n){var o=this.has(n)&&delete this.__data__[n];return this.size-=o?1:0,o}return to=t,to}var no,Us;function f1(){if(Us)return no;Us=1;var t=Xt(),n="__lodash_hash_undefined__",o=Object.prototype,a=o.hasOwnProperty;function r(l){var i=this.__data__;if(t){var s=i[l];return s===n?void 0:s}return a.call(i,l)?i[l]:void 0}return no=r,no}var oo,js;function p1(){if(js)return oo;js=1;var t=Xt(),n=Object.prototype,o=n.hasOwnProperty;function a(r){var l=this.__data__;return t?l[r]!==void 0:o.call(l,r)}return oo=a,oo}var ro,zs;function m1(){if(zs)return ro;zs=1;var t=Xt(),n="__lodash_hash_undefined__";function o(a,r){var l=this.__data__;return this.size+=this.has(a)?0:1,l[a]=t&&r===void 0?n:r,this}return ro=o,ro}var ao,Hs;function g1(){if(Hs)return ao;Hs=1;var t=u1(),n=h1(),o=f1(),a=p1(),r=m1();function l(i){var s=-1,d=i==null?0:i.length;for(this.clear();++s<d;){var f=i[s];this.set(f[0],f[1])}}return l.prototype.clear=t,l.prototype.delete=n,l.prototype.get=o,l.prototype.has=a,l.prototype.set=r,ao=l,ao}var lo,Ks;function b1(){if(Ks)return lo;Ks=1;var t=g1(),n=Zt(),o=Xn();function a(){this.size=0,this.__data__={hash:new t,map:new(o||n),string:new t}}return lo=a,lo}var io,Gs;function y1(){if(Gs)return io;Gs=1;function t(n){var o=typeof n;return o=="string"||o=="number"||o=="symbol"||o=="boolean"?n!=="__proto__":n===null}return io=t,io}var so,Ys;function Qt(){if(Ys)return so;Ys=1;var t=y1();function n(o,a){var r=o.__data__;return t(a)?r[typeof a=="string"?"string":"hash"]:r.map}return so=n,so}var co,$s;function _1(){if($s)return co;$s=1;var t=Qt();function n(o){var a=t(this,o).delete(o);return this.size-=a?1:0,a}return co=n,co}var uo,Ws;function k1(){if(Ws)return uo;Ws=1;var t=Qt();function n(o){return t(this,o).get(o)}return uo=n,uo}var ho,Js;function w1(){if(Js)return ho;Js=1;var t=Qt();function n(o){return t(this,o).has(o)}return ho=n,ho}var fo,Zs;function V1(){if(Zs)return fo;Zs=1;var t=Qt();function n(o,a){var r=t(this,o),l=r.size;return r.set(o,a),this.size+=r.size==l?0:1,this}return fo=n,fo}var po,Xs;function mo(){if(Xs)return po;Xs=1;var t=b1(),n=_1(),o=k1(),a=w1(),r=V1();function l(i){var s=-1,d=i==null?0:i.length;for(this.clear();++s<d;){var f=i[s];this.set(f[0],f[1])}}return l.prototype.clear=t,l.prototype.delete=n,l.prototype.get=o,l.prototype.has=a,l.prototype.set=r,po=l,po}var go,Qs;function C1(){if(Qs)return go;Qs=1;var t=Zt(),n=Xn(),o=mo(),a=200;function r(l,i){var s=this.__data__;if(s instanceof t){var d=s.__data__;if(!n||d.length<a-1)return d.push([l,i]),this.size=++s.size,this;s=this.__data__=new o(d)}return s.set(l,i),this.size=s.size,this}return go=r,go}var bo,ec;function en(){if(ec)return bo;ec=1;var t=Zt(),n=t1(),o=n1(),a=o1(),r=r1(),l=C1();function i(s){var d=this.__data__=new t(s);this.size=d.size}return i.prototype.clear=n,i.prototype.delete=o,i.prototype.get=a,i.prototype.has=r,i.prototype.set=l,bo=i,bo}var yo,tc;function _o(){if(tc)return yo;tc=1;function t(n,o){for(var a=-1,r=n==null?0:n.length;++a<r&&o(n[a],a,n)!==!1;);return n}return yo=t,yo}var ko,nc;function oc(){if(nc)return ko;nc=1;var t=wt(),n=function(){try{var o=t(Object,"defineProperty");return o({},"",{}),o}catch{}}();return ko=n,ko}var wo,rc;function tn(){if(rc)return wo;rc=1;var t=oc();function n(o,a,r){a=="__proto__"&&t?t(o,a,{configurable:!0,enumerable:!0,value:r,writable:!0}):o[a]=r}return wo=n,wo}var Vo,ac;function nn(){if(ac)return Vo;ac=1;var t=tn(),n=Et(),o=Object.prototype,a=o.hasOwnProperty;function r(l,i,s){var d=l[i];(!(a.call(l,i)&&n(d,s))||s===void 0&&!(i in l))&&t(l,i,s)}return Vo=r,Vo}var Co,lc;function At(){if(lc)return Co;lc=1;var t=nn(),n=tn();function o(a,r,l,i){var s=!l;l||(l={});for(var d=-1,f=r.length;++d<f;){var p=r[d],m=i?i(l[p],a[p],p,l,a):void 0;m===void 0&&(m=a[p]),s?n(l,p,m):t(l,p,m)}return l}return Co=o,Co}var xo,ic;function x1(){if(ic)return xo;ic=1;function t(n,o){for(var a=-1,r=Array(n);++a<n;)r[a]=o(a);return r}return xo=t,xo}var No,sc;function et(){if(sc)return No;sc=1;function t(n){return n!=null&&typeof n=="object"}return No=t,No}var Bo,cc;function N1(){if(cc)return Bo;cc=1;var t=kt(),n=et(),o="[object Arguments]";function a(r){return n(r)&&t(r)==o}return Bo=a,Bo}var So,dc;function Ot(){if(dc)return So;dc=1;var t=N1(),n=et(),o=Object.prototype,a=o.hasOwnProperty,r=o.propertyIsEnumerable,l=t(function(){return arguments}())?t:function(i){return n(i)&&a.call(i,"callee")&&!r.call(i,"callee")};return So=l,So}var Eo,uc;function Se(){if(uc)return Eo;uc=1;var t=Array.isArray;return Eo=t,Eo}var vt={exports:{}},To,hc;function B1(){if(hc)return To;hc=1;function t(){return!1}return To=t,To}vt.exports;var fc;function It(){return fc||(fc=1,function(t,n){var o=We(),a=B1(),r=n&&!n.nodeType&&n,l=r&&!0&&t&&!t.nodeType&&t,i=l&&l.exports===r,s=i?o.Buffer:void 0,d=s?s.isBuffer:void 0,f=d||a;t.exports=f}(vt,vt.exports)),vt.exports}var Io,pc;function on(){if(pc)return Io;pc=1;var t=9007199254740991,n=/^(?:0|[1-9]\d*)$/;function o(a,r){var l=typeof a;return r=r??t,!!r&&(l=="number"||l!="symbol"&&n.test(a))&&a>-1&&a%1==0&&a<r}return Io=o,Io}var Do,mc;function Fo(){if(mc)return Do;mc=1;var t=9007199254740991;function n(o){return typeof o=="number"&&o>-1&&o%1==0&&o<=t}return Do=n,Do}var qo,gc;function S1(){if(gc)return qo;gc=1;var t=kt(),n=Fo(),o=et(),a="[object Arguments]",r="[object Array]",l="[object Boolean]",i="[object Date]",s="[object Error]",d="[object Function]",f="[object Map]",p="[object Number]",m="[object Object]",_="[object RegExp]",C="[object Set]",k="[object String]",S="[object WeakMap]",B="[object ArrayBuffer]",q="[object DataView]",F="[object Float32Array]",V="[object Float64Array]",j="[object Int8Array]",U="[object Int16Array]",L="[object Int32Array]",A="[object Uint8Array]",z="[object Uint8ClampedArray]",Y="[object Uint16Array]",$="[object Uint32Array]",H={};H[F]=H[V]=H[j]=H[U]=H[L]=H[A]=H[z]=H[Y]=H[$]=!0,H[a]=H[r]=H[B]=H[l]=H[q]=H[i]=H[s]=H[d]=H[f]=H[p]=H[m]=H[_]=H[C]=H[k]=H[S]=!1;function X(ie){return o(ie)&&n(ie.length)&&!!H[t(ie)]}return qo=X,qo}var Ro,bc;function rn(){if(bc)return Ro;bc=1;function t(n){return function(o){return n(o)}}return Ro=t,Ro}var Pt={exports:{}};Pt.exports;var yc;function Ao(){return yc||(yc=1,function(t,n){var o=Vs(),a=n&&!n.nodeType&&n,r=a&&!0&&t&&!t.nodeType&&t,l=r&&r.exports===a,i=l&&o.process,s=function(){try{var d=r&&r.require&&r.require("util").types;return d||i&&i.binding&&i.binding("util")}catch{}}();t.exports=s}(Pt,Pt.exports)),Pt.exports}var Oo,_c;function Lt(){if(_c)return Oo;_c=1;var t=S1(),n=rn(),o=Ao(),a=o&&o.isTypedArray,r=a?n(a):t;return Oo=r,Oo}var vo,kc;function wc(){if(kc)return vo;kc=1;var t=x1(),n=Ot(),o=Se(),a=It(),r=on(),l=Lt(),i=Object.prototype,s=i.hasOwnProperty;function d(f,p){var m=o(f),_=!m&&n(f),C=!m&&!_&&a(f),k=!m&&!_&&!C&&l(f),S=m||_||C||k,B=S?t(f.length,String):[],q=B.length;for(var F in f)(p||s.call(f,F))&&!(S&&(F=="length"||C&&(F=="offset"||F=="parent")||k&&(F=="buffer"||F=="byteLength"||F=="byteOffset")||r(F,q)))&&B.push(F);return B}return vo=d,vo}var Po,Vc;function an(){if(Vc)return Po;Vc=1;var t=Object.prototype;function n(o){var a=o&&o.constructor,r=typeof a=="function"&&a.prototype||t;return o===r}return Po=n,Po}var Lo,Cc;function xc(){if(Cc)return Lo;Cc=1;function t(n,o){return function(a){return n(o(a))}}return Lo=t,Lo}var Mo,Nc;function E1(){if(Nc)return Mo;Nc=1;var t=xc(),n=t(Object.keys,Object);return Mo=n,Mo}var Uo,Bc;function jo(){if(Bc)return Uo;Bc=1;var t=an(),n=E1(),o=Object.prototype,a=o.hasOwnProperty;function r(l){if(!t(l))return n(l);var i=[];for(var s in Object(l))a.call(l,s)&&s!="constructor"&&i.push(s);return i}return Uo=r,Uo}var zo,Sc;function rt(){if(Sc)return zo;Sc=1;var t=Rt(),n=Fo();function o(a){return a!=null&&n(a.length)&&!t(a)}return zo=o,zo}var Ho,Ec;function ht(){if(Ec)return Ho;Ec=1;var t=wc(),n=jo(),o=rt();function a(r){return o(r)?t(r):n(r)}return Ho=a,Ho}var Ko,Tc;function T1(){if(Tc)return Ko;Tc=1;var t=At(),n=ht();function o(a,r){return a&&t(r,n(r),a)}return Ko=o,Ko}var Go,Ic;function I1(){if(Ic)return Go;Ic=1;function t(n){var o=[];if(n!=null)for(var a in Object(n))o.push(a);return o}return Go=t,Go}var Yo,Dc;function D1(){if(Dc)return Yo;Dc=1;var t=ze(),n=an(),o=I1(),a=Object.prototype,r=a.hasOwnProperty;function l(i){if(!t(i))return o(i);var s=n(i),d=[];for(var f in i)f=="constructor"&&(s||!r.call(i,f))||d.push(f);return d}return Yo=l,Yo}var $o,Fc;function Vt(){if(Fc)return $o;Fc=1;var t=wc(),n=D1(),o=rt();function a(r){return o(r)?t(r,!0):n(r)}return $o=a,$o}var Wo,qc;function F1(){if(qc)return Wo;qc=1;var t=At(),n=Vt();function o(a,r){return a&&t(r,n(r),a)}return Wo=o,Wo}var Mt={exports:{}};Mt.exports;var Rc;function Ac(){return Rc||(Rc=1,function(t,n){var o=We(),a=n&&!n.nodeType&&n,r=a&&!0&&t&&!t.nodeType&&t,l=r&&r.exports===a,i=l?o.Buffer:void 0,s=i?i.allocUnsafe:void 0;function d(f,p){if(p)return f.slice();var m=f.length,_=s?s(m):new f.constructor(m);return f.copy(_),_}t.exports=d}(Mt,Mt.exports)),Mt.exports}var Jo,Oc;function vc(){if(Oc)return Jo;Oc=1;function t(n,o){var a=-1,r=n.length;for(o||(o=Array(r));++a<r;)o[a]=n[a];return o}return Jo=t,Jo}var Zo,Pc;function Lc(){if(Pc)return Zo;Pc=1;function t(n,o){for(var a=-1,r=n==null?0:n.length,l=0,i=[];++a<r;){var s=n[a];o(s,a,n)&&(i[l++]=s)}return i}return Zo=t,Zo}var Xo,Mc;function Uc(){if(Mc)return Xo;Mc=1;function t(){return[]}return Xo=t,Xo}var Qo,jc;function er(){if(jc)return Qo;jc=1;var t=Lc(),n=Uc(),o=Object.prototype,a=o.propertyIsEnumerable,r=Object.getOwnPropertySymbols,l=r?function(i){return i==null?[]:(i=Object(i),t(r(i),function(s){return a.call(i,s)}))}:n;return Qo=l,Qo}var tr,zc;function q1(){if(zc)return tr;zc=1;var t=At(),n=er();function o(a,r){return t(a,n(a),r)}return tr=o,tr}var nr,Hc;function or(){if(Hc)return nr;Hc=1;function t(n,o){for(var a=-1,r=o.length,l=n.length;++a<r;)n[l+a]=o[a];return n}return nr=t,nr}var rr,Kc;function ln(){if(Kc)return rr;Kc=1;var t=xc(),n=t(Object.getPrototypeOf,Object);return rr=n,rr}var ar,Gc;function Yc(){if(Gc)return ar;Gc=1;var t=or(),n=ln(),o=er(),a=Uc(),r=Object.getOwnPropertySymbols,l=r?function(i){for(var s=[];i;)t(s,o(i)),i=n(i);return s}:a;return ar=l,ar}var lr,$c;function R1(){if($c)return lr;$c=1;var t=At(),n=Yc();function o(a,r){return t(a,n(a),r)}return lr=o,lr}var ir,Wc;function Jc(){if(Wc)return ir;Wc=1;var t=or(),n=Se();function o(a,r,l){var i=r(a);return n(a)?i:t(i,l(a))}return ir=o,ir}var sr,Zc;function Xc(){if(Zc)return sr;Zc=1;var t=Jc(),n=er(),o=ht();function a(r){return t(r,o,n)}return sr=a,sr}var cr,Qc;function A1(){if(Qc)return cr;Qc=1;var t=Jc(),n=Yc(),o=Vt();function a(r){return t(r,o,n)}return cr=a,cr}var dr,ed;function O1(){if(ed)return dr;ed=1;var t=wt(),n=We(),o=t(n,"DataView");return dr=o,dr}var ur,td;function v1(){if(td)return ur;td=1;var t=wt(),n=We(),o=t(n,"Promise");return ur=o,ur}var hr,nd;function od(){if(nd)return hr;nd=1;var t=wt(),n=We(),o=t(n,"Set");return hr=o,hr}var fr,rd;function P1(){if(rd)return fr;rd=1;var t=wt(),n=We(),o=t(n,"WeakMap");return fr=o,fr}var pr,ad;function Dt(){if(ad)return pr;ad=1;var t=O1(),n=Xn(),o=v1(),a=od(),r=P1(),l=kt(),i=qs(),s="[object Map]",d="[object Object]",f="[object Promise]",p="[object Set]",m="[object WeakMap]",_="[object DataView]",C=i(t),k=i(n),S=i(o),B=i(a),q=i(r),F=l;return(t&&F(new t(new ArrayBuffer(1)))!=_||n&&F(new n)!=s||o&&F(o.resolve())!=f||a&&F(new a)!=p||r&&F(new r)!=m)&&(F=function(V){var j=l(V),U=j==d?V.constructor:void 0,L=U?i(U):"";if(L)switch(L){case C:return _;case k:return s;case S:return f;case B:return p;case q:return m}return j}),pr=F,pr}var mr,ld;function L1(){if(ld)return mr;ld=1;var t=Object.prototype,n=t.hasOwnProperty;function o(a){var r=a.length,l=new a.constructor(r);return r&&typeof a[0]=="string"&&n.call(a,"index")&&(l.index=a.index,l.input=a.input),l}return mr=o,mr}var gr,id;function sd(){if(id)return gr;id=1;var t=We(),n=t.Uint8Array;return gr=n,gr}var br,cd;function yr(){if(cd)return br;cd=1;var t=sd();function n(o){var a=new o.constructor(o.byteLength);return new t(a).set(new t(o)),a}return br=n,br}var _r,dd;function M1(){if(dd)return _r;dd=1;var t=yr();function n(o,a){var r=a?t(o.buffer):o.buffer;return new o.constructor(r,o.byteOffset,o.byteLength)}return _r=n,_r}var kr,ud;function U1(){if(ud)return kr;ud=1;var t=/\w*$/;function n(o){var a=new o.constructor(o.source,t.exec(o));return a.lastIndex=o.lastIndex,a}return kr=n,kr}var wr,hd;function j1(){if(hd)return wr;hd=1;var t=Tt(),n=t?t.prototype:void 0,o=n?n.valueOf:void 0;function a(r){return o?Object(o.call(r)):{}}return wr=a,wr}var Vr,fd;function pd(){if(fd)return Vr;fd=1;var t=yr();function n(o,a){var r=a?t(o.buffer):o.buffer;return new o.constructor(r,o.byteOffset,o.length)}return Vr=n,Vr}var Cr,md;function z1(){if(md)return Cr;md=1;var t=yr(),n=M1(),o=U1(),a=j1(),r=pd(),l="[object Boolean]",i="[object Date]",s="[object Map]",d="[object Number]",f="[object RegExp]",p="[object Set]",m="[object String]",_="[object Symbol]",C="[object ArrayBuffer]",k="[object DataView]",S="[object Float32Array]",B="[object Float64Array]",q="[object Int8Array]",F="[object Int16Array]",V="[object Int32Array]",j="[object Uint8Array]",U="[object Uint8ClampedArray]",L="[object Uint16Array]",A="[object Uint32Array]";function z(Y,$,H){var X=Y.constructor;switch($){case C:return t(Y);case l:case i:return new X(+Y);case k:return n(Y,H);case S:case B:case q:case F:case V:case j:case U:case L:case A:return r(Y,H);case s:return new X;case d:case m:return new X(Y);case f:return o(Y);case p:return new X;case _:return a(Y)}}return Cr=z,Cr}var xr,gd;function bd(){if(gd)return xr;gd=1;var t=ze(),n=Object.create,o=function(){function a(){}return function(r){if(!t(r))return{};if(n)return n(r);a.prototype=r;var l=new a;return a.prototype=void 0,l}}();return xr=o,xr}var Nr,yd;function _d(){if(yd)return Nr;yd=1;var t=bd(),n=ln(),o=an();function a(r){return typeof r.constructor=="function"&&!o(r)?t(n(r)):{}}return Nr=a,Nr}var Br,kd;function H1(){if(kd)return Br;kd=1;var t=Dt(),n=et(),o="[object Map]";function a(r){return n(r)&&t(r)==o}return Br=a,Br}var Sr,wd;function K1(){if(wd)return Sr;wd=1;var t=H1(),n=rn(),o=Ao(),a=o&&o.isMap,r=a?n(a):t;return Sr=r,Sr}var Er,Vd;function G1(){if(Vd)return Er;Vd=1;var t=Dt(),n=et(),o="[object Set]";function a(r){return n(r)&&t(r)==o}return Er=a,Er}var Tr,Cd;function Y1(){if(Cd)return Tr;Cd=1;var t=G1(),n=rn(),o=Ao(),a=o&&o.isSet,r=a?n(a):t;return Tr=r,Tr}var Ir,xd;function Nd(){if(xd)return Ir;xd=1;var t=en(),n=_o(),o=nn(),a=T1(),r=F1(),l=Ac(),i=vc(),s=q1(),d=R1(),f=Xc(),p=A1(),m=Dt(),_=L1(),C=z1(),k=_d(),S=Se(),B=It(),q=K1(),F=ze(),V=Y1(),j=ht(),U=Vt(),L=1,A=2,z=4,Y="[object Arguments]",$="[object Array]",H="[object Boolean]",X="[object Date]",ie="[object Error]",R="[object Function]",ne="[object GeneratorFunction]",h="[object Map]",T="[object Number]",x="[object Object]",Ce="[object RegExp]",G="[object Set]",Te="[object String]",Z="[object Symbol]",P="[object WeakMap]",J="[object ArrayBuffer]",ee="[object DataView]",ce="[object Float32Array]",ye="[object Float64Array]",we="[object Int8Array]",xe="[object Int16Array]",qe="[object Int32Array]",Re="[object Uint8Array]",Ne="[object Uint8ClampedArray]",Ge="[object Uint16Array]",je="[object Uint32Array]",ae={};ae[Y]=ae[$]=ae[J]=ae[ee]=ae[H]=ae[X]=ae[ce]=ae[ye]=ae[we]=ae[xe]=ae[qe]=ae[h]=ae[T]=ae[x]=ae[Ce]=ae[G]=ae[Te]=ae[Z]=ae[Re]=ae[Ne]=ae[Ge]=ae[je]=!0,ae[ie]=ae[R]=ae[P]=!1;function v(Q,Be,Ie,dt,ve,Fe){var _e,pe=Be&L,O=Be&A,Ye=Be&z;if(Ie&&(_e=ve?Ie(Q,dt,ve,Fe):Ie(Q)),_e!==void 0)return _e;if(!F(Q))return Q;var Ze=S(Q);if(Ze){if(_e=_(Q),!pe)return i(Q,_e)}else{var Pe=m(Q),Xe=Pe==R||Pe==ne;if(B(Q))return l(Q,pe);if(Pe==x||Pe==Y||Xe&&!ve){if(_e=O||Xe?{}:k(Q),!pe)return O?d(Q,r(_e,Q)):s(Q,a(_e,Q))}else{if(!ae[Pe])return ve?Q:{};_e=C(Q,Pe,pe)}}Fe||(Fe=new t);var Qe=Fe.get(Q);if(Qe)return Qe;Fe.set(Q,_e),V(Q)?Q.forEach(function(b){_e.add(v(b,Be,Ie,b,Q,Fe))}):q(Q)&&Q.forEach(function(b,c){_e.set(c,v(b,Be,Ie,c,Q,Fe))});var ut=Ye?O?p:f:O?U:j,nt=Ze?void 0:ut(Q);return n(nt||Q,function(b,c){nt&&(c=b,b=Q[c]),o(_e,c,v(b,Be,Ie,c,Q,Fe))}),_e}return Ir=v,Ir}var Dr,Bd;function $1(){if(Bd)return Dr;Bd=1;var t=Nd(),n=4;function o(a){return t(a,n)}return Dr=o,Dr}var Fr,Sd;function qr(){if(Sd)return Fr;Sd=1;function t(n){return function(){return n}}return Fr=t,Fr}var Rr,Ed;function W1(){if(Ed)return Rr;Ed=1;function t(n){return function(o,a,r){for(var l=-1,i=Object(o),s=r(o),d=s.length;d--;){var f=s[n?d:++l];if(a(i[f],f,i)===!1)break}return o}}return Rr=t,Rr}var Ar,Td;function Or(){if(Td)return Ar;Td=1;var t=W1(),n=t();return Ar=n,Ar}var vr,Id;function Pr(){if(Id)return vr;Id=1;var t=Or(),n=ht();function o(a,r){return a&&t(a,r,n)}return vr=o,vr}var Lr,Dd;function J1(){if(Dd)return Lr;Dd=1;var t=rt();function n(o,a){return function(r,l){if(r==null)return r;if(!t(r))return o(r,l);for(var i=r.length,s=a?i:-1,d=Object(r);(a?s--:++s<i)&&l(d[s],s,d)!==!1;);return r}}return Lr=n,Lr}var Mr,Fd;function sn(){if(Fd)return Mr;Fd=1;var t=Pr(),n=J1(),o=n(t);return Mr=o,Mr}var Ur,qd;function Ct(){if(qd)return Ur;qd=1;function t(n){return n}return Ur=t,Ur}var jr,Rd;function Ad(){if(Rd)return jr;Rd=1;var t=Ct();function n(o){return typeof o=="function"?o:t}return jr=n,jr}var zr,Od;function vd(){if(Od)return zr;Od=1;var t=_o(),n=sn(),o=Ad(),a=Se();function r(l,i){var s=a(l)?t:n;return s(l,o(i))}return zr=r,zr}var Hr,Pd;function Ld(){return Pd||(Pd=1,Hr=vd()),Hr}var Kr,Md;function Z1(){if(Md)return Kr;Md=1;var t=sn();function n(o,a){var r=[];return t(o,function(l,i,s){a(l,i,s)&&r.push(l)}),r}return Kr=n,Kr}var Gr,Ud;function X1(){if(Ud)return Gr;Ud=1;var t="__lodash_hash_undefined__";function n(o){return this.__data__.set(o,t),this}return Gr=n,Gr}var Yr,jd;function Q1(){if(jd)return Yr;jd=1;function t(n){return this.__data__.has(n)}return Yr=t,Yr}var $r,zd;function Hd(){if(zd)return $r;zd=1;var t=mo(),n=X1(),o=Q1();function a(r){var l=-1,i=r==null?0:r.length;for(this.__data__=new t;++l<i;)this.add(r[l])}return a.prototype.add=a.prototype.push=n,a.prototype.has=o,$r=a,$r}var Wr,Kd;function ek(){if(Kd)return Wr;Kd=1;function t(n,o){for(var a=-1,r=n==null?0:n.length;++a<r;)if(o(n[a],a,n))return!0;return!1}return Wr=t,Wr}var Jr,Gd;function Yd(){if(Gd)return Jr;Gd=1;function t(n,o){return n.has(o)}return Jr=t,Jr}var Zr,$d;function Wd(){if($d)return Zr;$d=1;var t=Hd(),n=ek(),o=Yd(),a=1,r=2;function l(i,s,d,f,p,m){var _=d&a,C=i.length,k=s.length;if(C!=k&&!(_&&k>C))return!1;var S=m.get(i),B=m.get(s);if(S&&B)return S==s&&B==i;var q=-1,F=!0,V=d&r?new t:void 0;for(m.set(i,s),m.set(s,i);++q<C;){var j=i[q],U=s[q];if(f)var L=_?f(U,j,q,s,i,m):f(j,U,q,i,s,m);if(L!==void 0){if(L)continue;F=!1;break}if(V){if(!n(s,function(A,z){if(!o(V,z)&&(j===A||p(j,A,d,f,m)))return V.push(z)})){F=!1;break}}else if(!(j===U||p(j,U,d,f,m))){F=!1;break}}return m.delete(i),m.delete(s),F}return Zr=l,Zr}var Xr,Jd;function tk(){if(Jd)return Xr;Jd=1;function t(n){var o=-1,a=Array(n.size);return n.forEach(function(r,l){a[++o]=[l,r]}),a}return Xr=t,Xr}var Qr,Zd;function ea(){if(Zd)return Qr;Zd=1;function t(n){var o=-1,a=Array(n.size);return n.forEach(function(r){a[++o]=r}),a}return Qr=t,Qr}var ta,Xd;function nk(){if(Xd)return ta;Xd=1;var t=Tt(),n=sd(),o=Et(),a=Wd(),r=tk(),l=ea(),i=1,s=2,d="[object Boolean]",f="[object Date]",p="[object Error]",m="[object Map]",_="[object Number]",C="[object RegExp]",k="[object Set]",S="[object String]",B="[object Symbol]",q="[object ArrayBuffer]",F="[object DataView]",V=t?t.prototype:void 0,j=V?V.valueOf:void 0;function U(L,A,z,Y,$,H,X){switch(z){case F:if(L.byteLength!=A.byteLength||L.byteOffset!=A.byteOffset)return!1;L=L.buffer,A=A.buffer;case q:return!(L.byteLength!=A.byteLength||!H(new n(L),new n(A)));case d:case f:case _:return o(+L,+A);case p:return L.name==A.name&&L.message==A.message;case C:case S:return L==A+"";case m:var ie=r;case k:var R=Y&i;if(ie||(ie=l),L.size!=A.size&&!R)return!1;var ne=X.get(L);if(ne)return ne==A;Y|=s,X.set(L,A);var h=a(ie(L),ie(A),Y,$,H,X);return X.delete(L),h;case B:if(j)return j.call(L)==j.call(A)}return!1}return ta=U,ta}var na,Qd;function ok(){if(Qd)return na;Qd=1;var t=Xc(),n=1,o=Object.prototype,a=o.hasOwnProperty;function r(l,i,s,d,f,p){var m=s&n,_=t(l),C=_.length,k=t(i),S=k.length;if(C!=S&&!m)return!1;for(var B=C;B--;){var q=_[B];if(!(m?q in i:a.call(i,q)))return!1}var F=p.get(l),V=p.get(i);if(F&&V)return F==i&&V==l;var j=!0;p.set(l,i),p.set(i,l);for(var U=m;++B<C;){q=_[B];var L=l[q],A=i[q];if(d)var z=m?d(A,L,q,i,l,p):d(L,A,q,l,i,p);if(!(z===void 0?L===A||f(L,A,s,d,p):z)){j=!1;break}U||(U=q=="constructor")}if(j&&!U){var Y=l.constructor,$=i.constructor;Y!=$&&"constructor"in l&&"constructor"in i&&!(typeof Y=="function"&&Y instanceof Y&&typeof $=="function"&&$ instanceof $)&&(j=!1)}return p.delete(l),p.delete(i),j}return na=r,na}var oa,eu;function rk(){if(eu)return oa;eu=1;var t=en(),n=Wd(),o=nk(),a=ok(),r=Dt(),l=Se(),i=It(),s=Lt(),d=1,f="[object Arguments]",p="[object Array]",m="[object Object]",_=Object.prototype,C=_.hasOwnProperty;function k(S,B,q,F,V,j){var U=l(S),L=l(B),A=U?p:r(S),z=L?p:r(B);A=A==f?m:A,z=z==f?m:z;var Y=A==m,$=z==m,H=A==z;if(H&&i(S)){if(!i(B))return!1;U=!0,Y=!1}if(H&&!Y)return j||(j=new t),U||s(S)?n(S,B,q,F,V,j):o(S,B,A,q,F,V,j);if(!(q&d)){var X=Y&&C.call(S,"__wrapped__"),ie=$&&C.call(B,"__wrapped__");if(X||ie){var R=X?S.value():S,ne=ie?B.value():B;return j||(j=new t),V(R,ne,q,F,j)}}return H?(j||(j=new t),a(S,B,q,F,V,j)):!1}return oa=k,oa}var ra,tu;function nu(){if(tu)return ra;tu=1;var t=rk(),n=et();function o(a,r,l,i,s){return a===r?!0:a==null||r==null||!n(a)&&!n(r)?a!==a&&r!==r:t(a,r,l,i,o,s)}return ra=o,ra}var aa,ou;function ak(){if(ou)return aa;ou=1;var t=en(),n=nu(),o=1,a=2;function r(l,i,s,d){var f=s.length,p=f,m=!d;if(l==null)return!p;for(l=Object(l);f--;){var _=s[f];if(m&&_[2]?_[1]!==l[_[0]]:!(_[0]in l))return!1}for(;++f<p;){_=s[f];var C=_[0],k=l[C],S=_[1];if(m&&_[2]){if(k===void 0&&!(C in l))return!1}else{var B=new t;if(d)var q=d(k,S,C,l,i,B);if(!(q===void 0?n(S,k,o|a,d,B):q))return!1}}return!0}return aa=r,aa}var la,ru;function au(){if(ru)return la;ru=1;var t=ze();function n(o){return o===o&&!t(o)}return la=n,la}var ia,lu;function lk(){if(lu)return ia;lu=1;var t=au(),n=ht();function o(a){for(var r=n(a),l=r.length;l--;){var i=r[l],s=a[i];r[l]=[i,s,t(s)]}return r}return ia=o,ia}var sa,iu;function su(){if(iu)return sa;iu=1;function t(n,o){return function(a){return a==null?!1:a[n]===o&&(o!==void 0||n in Object(a))}}return sa=t,sa}var ca,cu;function ik(){if(cu)return ca;cu=1;var t=ak(),n=lk(),o=su();function a(r){var l=n(r);return l.length==1&&l[0][2]?o(l[0][0],l[0][1]):function(i){return i===r||t(i,r,l)}}return ca=a,ca}var da,du;function Ft(){if(du)return da;du=1;var t=kt(),n=et(),o="[object Symbol]";function a(r){return typeof r=="symbol"||n(r)&&t(r)==o}return da=a,da}var ua,uu;function ha(){if(uu)return ua;uu=1;var t=Se(),n=Ft(),o=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;function r(l,i){if(t(l))return!1;var s=typeof l;return s=="number"||s=="symbol"||s=="boolean"||l==null||n(l)?!0:a.test(l)||!o.test(l)||i!=null&&l in Object(i)}return ua=r,ua}var fa,hu;function sk(){if(hu)return fa;hu=1;var t=mo(),n="Expected a function";function o(a,r){if(typeof a!="function"||r!=null&&typeof r!="function")throw new TypeError(n);var l=function(){var i=arguments,s=r?r.apply(this,i):i[0],d=l.cache;if(d.has(s))return d.get(s);var f=a.apply(this,i);return l.cache=d.set(s,f)||d,f};return l.cache=new(o.Cache||t),l}return o.Cache=t,fa=o,fa}var pa,fu;function ck(){if(fu)return pa;fu=1;var t=sk(),n=500;function o(a){var r=t(a,function(i){return l.size===n&&l.clear(),i}),l=r.cache;return r}return pa=o,pa}var ma,pu;function dk(){if(pu)return ma;pu=1;var t=ck(),n=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,o=/\\(\\)?/g,a=t(function(r){var l=[];return r.charCodeAt(0)===46&&l.push(""),r.replace(n,function(i,s,d,f){l.push(d?f.replace(o,"$1"):s||i)}),l});return ma=a,ma}var ga,mu;function cn(){if(mu)return ga;mu=1;function t(n,o){for(var a=-1,r=n==null?0:n.length,l=Array(r);++a<r;)l[a]=o(n[a],a,n);return l}return ga=t,ga}var ba,gu;function uk(){if(gu)return ba;gu=1;var t=Tt(),n=cn(),o=Se(),a=Ft(),r=1/0,l=t?t.prototype:void 0,i=l?l.toString:void 0;function s(d){if(typeof d=="string")return d;if(o(d))return n(d,s)+"";if(a(d))return i?i.call(d):"";var f=d+"";return f=="0"&&1/d==-r?"-0":f}return ba=s,ba}var ya,bu;function yu(){if(bu)return ya;bu=1;var t=uk();function n(o){return o==null?"":t(o)}return ya=n,ya}var _a,_u;function dn(){if(_u)return _a;_u=1;var t=Se(),n=ha(),o=dk(),a=yu();function r(l,i){return t(l)?l:n(l,i)?[l]:o(a(l))}return _a=r,_a}var ka,ku;function Ut(){if(ku)return ka;ku=1;var t=Ft(),n=1/0;function o(a){if(typeof a=="string"||t(a))return a;var r=a+"";return r=="0"&&1/a==-n?"-0":r}return ka=o,ka}var wa,wu;function un(){if(wu)return wa;wu=1;var t=dn(),n=Ut();function o(a,r){r=t(r,a);for(var l=0,i=r.length;a!=null&&l<i;)a=a[n(r[l++])];return l&&l==i?a:void 0}return wa=o,wa}var Va,Vu;function hk(){if(Vu)return Va;Vu=1;var t=un();function n(o,a,r){var l=o==null?void 0:t(o,a);return l===void 0?r:l}return Va=n,Va}var Ca,Cu;function fk(){if(Cu)return Ca;Cu=1;function t(n,o){return n!=null&&o in Object(n)}return Ca=t,Ca}var xa,xu;function Nu(){if(xu)return xa;xu=1;var t=dn(),n=Ot(),o=Se(),a=on(),r=Fo(),l=Ut();function i(s,d,f){d=t(d,s);for(var p=-1,m=d.length,_=!1;++p<m;){var C=l(d[p]);if(!(_=s!=null&&f(s,C)))break;s=s[C]}return _||++p!=m?_:(m=s==null?0:s.length,!!m&&r(m)&&a(C,m)&&(o(s)||n(s)))}return xa=i,xa}var Na,Bu;function Su(){if(Bu)return Na;Bu=1;var t=fk(),n=Nu();function o(a,r){return a!=null&&n(a,r,t)}return Na=o,Na}var Ba,Eu;function pk(){if(Eu)return Ba;Eu=1;var t=nu(),n=hk(),o=Su(),a=ha(),r=au(),l=su(),i=Ut(),s=1,d=2;function f(p,m){return a(p)&&r(m)?l(i(p),m):function(_){var C=n(_,p);return C===void 0&&C===m?o(_,p):t(m,C,s|d)}}return Ba=f,Ba}var Sa,Tu;function Iu(){if(Tu)return Sa;Tu=1;function t(n){return function(o){return o==null?void 0:o[n]}}return Sa=t,Sa}var Ea,Du;function mk(){if(Du)return Ea;Du=1;var t=un();function n(o){return function(a){return t(a,o)}}return Ea=n,Ea}var Ta,Fu;function gk(){if(Fu)return Ta;Fu=1;var t=Iu(),n=mk(),o=ha(),a=Ut();function r(l){return o(l)?t(a(l)):n(l)}return Ta=r,Ta}var Ia,qu;function at(){if(qu)return Ia;qu=1;var t=ik(),n=pk(),o=Ct(),a=Se(),r=gk();function l(i){return typeof i=="function"?i:i==null?o:typeof i=="object"?a(i)?n(i[0],i[1]):t(i):r(i)}return Ia=l,Ia}var Da,Ru;function Au(){if(Ru)return Da;Ru=1;var t=Lc(),n=Z1(),o=at(),a=Se();function r(l,i){var s=a(l)?t:n;return s(l,o(i,3))}return Da=r,Da}var Fa,Ou;function bk(){if(Ou)return Fa;Ou=1;var t=Object.prototype,n=t.hasOwnProperty;function o(a,r){return a!=null&&n.call(a,r)}return Fa=o,Fa}var qa,vu;function Pu(){if(vu)return qa;vu=1;var t=bk(),n=Nu();function o(a,r){return a!=null&&n(a,r,t)}return qa=o,qa}var Ra,Lu;function yk(){if(Lu)return Ra;Lu=1;var t=jo(),n=Dt(),o=Ot(),a=Se(),r=rt(),l=It(),i=an(),s=Lt(),d="[object Map]",f="[object Set]",p=Object.prototype,m=p.hasOwnProperty;function _(C){if(C==null)return!0;if(r(C)&&(a(C)||typeof C=="string"||typeof C.splice=="function"||l(C)||s(C)||o(C)))return!C.length;var k=n(C);if(k==d||k==f)return!C.size;if(i(C))return!t(C).length;for(var S in C)if(m.call(C,S))return!1;return!0}return Ra=_,Ra}var Aa,Mu;function Uu(){if(Mu)return Aa;Mu=1;function t(n){return n===void 0}return Aa=t,Aa}var Oa,ju;function zu(){if(ju)return Oa;ju=1;var t=sn(),n=rt();function o(a,r){var l=-1,i=n(a)?Array(a.length):[];return t(a,function(s,d,f){i[++l]=r(s,d,f)}),i}return Oa=o,Oa}var va,Hu;function Ku(){if(Hu)return va;Hu=1;var t=cn(),n=at(),o=zu(),a=Se();function r(l,i){var s=a(l)?t:o;return s(l,n(i,3))}return va=r,va}var Pa,Gu;function _k(){if(Gu)return Pa;Gu=1;function t(n,o,a,r){var l=-1,i=n==null?0:n.length;for(r&&i&&(a=n[++l]);++l<i;)a=o(a,n[l],l,n);return a}return Pa=t,Pa}var La,Yu;function kk(){if(Yu)return La;Yu=1;function t(n,o,a,r,l){return l(n,function(i,s,d){a=r?(r=!1,i):o(a,i,s,d)}),a}return La=t,La}var Ma,$u;function Wu(){if($u)return Ma;$u=1;var t=_k(),n=sn(),o=at(),a=kk(),r=Se();function l(i,s,d){var f=r(i)?t:a,p=arguments.length<3;return f(i,o(s,4),d,p,n)}return Ma=l,Ma}var Ua,Ju;function wk(){if(Ju)return Ua;Ju=1;var t=kt(),n=Se(),o=et(),a="[object String]";function r(l){return typeof l=="string"||!n(l)&&o(l)&&t(l)==a}return Ua=r,Ua}var ja,Zu;function Vk(){if(Zu)return ja;Zu=1;var t=Iu(),n=t("length");return ja=n,ja}var za,Xu;function Ck(){if(Xu)return za;Xu=1;var t="\\ud800-\\udfff",n="\\u0300-\\u036f",o="\\ufe20-\\ufe2f",a="\\u20d0-\\u20ff",r=n+o+a,l="\\ufe0e\\ufe0f",i="\\u200d",s=RegExp("["+i+t+r+l+"]");function d(f){return s.test(f)}return za=d,za}var Ha,Qu;function xk(){if(Qu)return Ha;Qu=1;var t="\\ud800-\\udfff",n="\\u0300-\\u036f",o="\\ufe20-\\ufe2f",a="\\u20d0-\\u20ff",r=n+o+a,l="\\ufe0e\\ufe0f",i="["+t+"]",s="["+r+"]",d="\\ud83c[\\udffb-\\udfff]",f="(?:"+s+"|"+d+")",p="[^"+t+"]",m="(?:\\ud83c[\\udde6-\\uddff]){2}",_="[\\ud800-\\udbff][\\udc00-\\udfff]",C="\\u200d",k=f+"?",S="["+l+"]?",B="(?:"+C+"(?:"+[p,m,_].join("|")+")"+S+k+")*",q=S+k+B,F="(?:"+[p+s+"?",s,m,_,i].join("|")+")",V=RegExp(d+"(?="+d+")|"+F+q,"g");function j(U){for(var L=V.lastIndex=0;V.test(U);)++L;return L}return Ha=j,Ha}var Ka,eh;function Nk(){if(eh)return Ka;eh=1;var t=Vk(),n=Ck(),o=xk();function a(r){return n(r)?o(r):t(r)}return Ka=a,Ka}var Ga,th;function Bk(){if(th)return Ga;th=1;var t=jo(),n=Dt(),o=rt(),a=wk(),r=Nk(),l="[object Map]",i="[object Set]";function s(d){if(d==null)return 0;if(o(d))return a(d)?r(d):d.length;var f=n(d);return f==l||f==i?d.size:t(d).length}return Ga=s,Ga}var Ya,nh;function Sk(){if(nh)return Ya;nh=1;var t=_o(),n=bd(),o=Pr(),a=at(),r=ln(),l=Se(),i=It(),s=Rt(),d=ze(),f=Lt();function p(m,_,C){var k=l(m),S=k||i(m)||f(m);if(_=a(_,4),C==null){var B=m&&m.constructor;S?C=k?new B:[]:d(m)?C=s(B)?n(r(m)):{}:C={}}return(S?t:o)(m,function(q,F,V){return _(C,q,F,V)}),C}return Ya=p,Ya}var $a,oh;function Ek(){if(oh)return $a;oh=1;var t=Tt(),n=Ot(),o=Se(),a=t?t.isConcatSpreadable:void 0;function r(l){return o(l)||n(l)||!!(a&&l&&l[a])}return $a=r,$a}var Wa,rh;function Ja(){if(rh)return Wa;rh=1;var t=or(),n=Ek();function o(a,r,l,i,s){var d=-1,f=a.length;for(l||(l=n),s||(s=[]);++d<f;){var p=a[d];r>0&&l(p)?r>1?o(p,r-1,l,i,s):t(s,p):i||(s[s.length]=p)}return s}return Wa=o,Wa}var Za,ah;function Tk(){if(ah)return Za;ah=1;function t(n,o,a){switch(a.length){case 0:return n.call(o);case 1:return n.call(o,a[0]);case 2:return n.call(o,a[0],a[1]);case 3:return n.call(o,a[0],a[1],a[2])}return n.apply(o,a)}return Za=t,Za}var Xa,lh;function ih(){if(lh)return Xa;lh=1;var t=Tk(),n=Math.max;function o(a,r,l){return r=n(r===void 0?a.length-1:r,0),function(){for(var i=arguments,s=-1,d=n(i.length-r,0),f=Array(d);++s<d;)f[s]=i[r+s];s=-1;for(var p=Array(r+1);++s<r;)p[s]=i[s];return p[r]=l(f),t(a,this,p)}}return Xa=o,Xa}var Qa,sh;function Ik(){if(sh)return Qa;sh=1;var t=qr(),n=oc(),o=Ct(),a=n?function(r,l){return n(r,"toString",{configurable:!0,enumerable:!1,value:t(l),writable:!0})}:o;return Qa=a,Qa}var el,ch;function Dk(){if(ch)return el;ch=1;var t=800,n=16,o=Date.now;function a(r){var l=0,i=0;return function(){var s=o(),d=n-(s-i);if(i=s,d>0){if(++l>=t)return arguments[0]}else l=0;return r.apply(void 0,arguments)}}return el=a,el}var tl,dh;function uh(){if(dh)return tl;dh=1;var t=Ik(),n=Dk(),o=n(t);return tl=o,tl}var nl,hh;function hn(){if(hh)return nl;hh=1;var t=Ct(),n=ih(),o=uh();function a(r,l){return o(n(r,l,t),r+"")}return nl=a,nl}var ol,fh;function ph(){if(fh)return ol;fh=1;function t(n,o,a,r){for(var l=n.length,i=a+(r?1:-1);r?i--:++i<l;)if(o(n[i],i,n))return i;return-1}return ol=t,ol}var rl,mh;function Fk(){if(mh)return rl;mh=1;function t(n){return n!==n}return rl=t,rl}var al,gh;function qk(){if(gh)return al;gh=1;function t(n,o,a){for(var r=a-1,l=n.length;++r<l;)if(n[r]===o)return r;return-1}return al=t,al}var ll,bh;function Rk(){if(bh)return ll;bh=1;var t=ph(),n=Fk(),o=qk();function a(r,l,i){return l===l?o(r,l,i):t(r,n,i)}return ll=a,ll}var il,yh;function Ak(){if(yh)return il;yh=1;var t=Rk();function n(o,a){var r=o==null?0:o.length;return!!r&&t(o,a,0)>-1}return il=n,il}var sl,_h;function Ok(){if(_h)return sl;_h=1;function t(n,o,a){for(var r=-1,l=n==null?0:n.length;++r<l;)if(a(o,n[r]))return!0;return!1}return sl=t,sl}var cl,kh;function vk(){if(kh)return cl;kh=1;function t(){}return cl=t,cl}var dl,wh;function Pk(){if(wh)return dl;wh=1;var t=od(),n=vk(),o=ea(),a=1/0,r=t&&1/o(new t([,-0]))[1]==a?function(l){return new t(l)}:n;return dl=r,dl}var ul,Vh;function Lk(){if(Vh)return ul;Vh=1;var t=Hd(),n=Ak(),o=Ok(),a=Yd(),r=Pk(),l=ea(),i=200;function s(d,f,p){var m=-1,_=n,C=d.length,k=!0,S=[],B=S;if(p)k=!1,_=o;else if(C>=i){var q=f?null:r(d);if(q)return l(q);k=!1,_=a,B=new t}else B=f?[]:S;e:for(;++m<C;){var F=d[m],V=f?f(F):F;if(F=p||F!==0?F:0,k&&V===V){for(var j=B.length;j--;)if(B[j]===V)continue e;f&&B.push(V),S.push(F)}else _(B,V,p)||(B!==S&&B.push(V),S.push(F))}return S}return ul=s,ul}var hl,Ch;function xh(){if(Ch)return hl;Ch=1;var t=rt(),n=et();function o(a){return n(a)&&t(a)}return hl=o,hl}var fl,Nh;function Mk(){if(Nh)return fl;Nh=1;var t=Ja(),n=hn(),o=Lk(),a=xh(),r=n(function(l){return o(t(l,1,a,!0))});return fl=r,fl}var pl,Bh;function Uk(){if(Bh)return pl;Bh=1;var t=cn();function n(o,a){return t(a,function(r){return o[r]})}return pl=n,pl}var ml,Sh;function Eh(){if(Sh)return ml;Sh=1;var t=Uk(),n=ht();function o(a){return a==null?[]:t(a,n(a))}return ml=o,ml}var gl,Th;function He(){if(Th)return gl;Th=1;var t;if(typeof xn=="function")try{t={clone:$1(),constant:qr(),each:Ld(),filter:Au(),has:Pu(),isArray:Se(),isEmpty:yk(),isFunction:Rt(),isUndefined:Uu(),keys:ht(),map:Ku(),reduce:Wu(),size:Bk(),transform:Sk(),union:Mk(),values:Eh()}}catch{}return t||(t=window._),gl=t,gl}var bl,Ih;function yl(){if(Ih)return bl;Ih=1;var t=He();bl=r;var n="\0",o="\0",a="";function r(p){this._isDirected=t.has(p,"directed")?p.directed:!0,this._isMultigraph=t.has(p,"multigraph")?p.multigraph:!1,this._isCompound=t.has(p,"compound")?p.compound:!1,this._label=void 0,this._defaultNodeLabelFn=t.constant(void 0),this._defaultEdgeLabelFn=t.constant(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[o]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}r.prototype._nodeCount=0,r.prototype._edgeCount=0,r.prototype.isDirected=function(){return this._isDirected},r.prototype.isMultigraph=function(){return this._isMultigraph},r.prototype.isCompound=function(){return this._isCompound},r.prototype.setGraph=function(p){return this._label=p,this},r.prototype.graph=function(){return this._label},r.prototype.setDefaultNodeLabel=function(p){return t.isFunction(p)||(p=t.constant(p)),this._defaultNodeLabelFn=p,this},r.prototype.nodeCount=function(){return this._nodeCount},r.prototype.nodes=function(){return t.keys(this._nodes)},r.prototype.sources=function(){var p=this;return t.filter(this.nodes(),function(m){return t.isEmpty(p._in[m])})},r.prototype.sinks=function(){var p=this;return t.filter(this.nodes(),function(m){return t.isEmpty(p._out[m])})},r.prototype.setNodes=function(p,m){var _=arguments,C=this;return t.each(p,function(k){_.length>1?C.setNode(k,m):C.setNode(k)}),this},r.prototype.setNode=function(p,m){return t.has(this._nodes,p)?(arguments.length>1&&(this._nodes[p]=m),this):(this._nodes[p]=arguments.length>1?m:this._defaultNodeLabelFn(p),this._isCompound&&(this._parent[p]=o,this._children[p]={},this._children[o][p]=!0),this._in[p]={},this._preds[p]={},this._out[p]={},this._sucs[p]={},++this._nodeCount,this)},r.prototype.node=function(p){return this._nodes[p]},r.prototype.hasNode=function(p){return t.has(this._nodes,p)},r.prototype.removeNode=function(p){var m=this;if(t.has(this._nodes,p)){var _=function(C){m.removeEdge(m._edgeObjs[C])};delete this._nodes[p],this._isCompound&&(this._removeFromParentsChildList(p),delete this._parent[p],t.each(this.children(p),function(C){m.setParent(C)}),delete this._children[p]),t.each(t.keys(this._in[p]),_),delete this._in[p],delete this._preds[p],t.each(t.keys(this._out[p]),_),delete this._out[p],delete this._sucs[p],--this._nodeCount}return this},r.prototype.setParent=function(p,m){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(t.isUndefined(m))m=o;else{m+="";for(var _=m;!t.isUndefined(_);_=this.parent(_))if(_===p)throw new Error("Setting "+m+" as parent of "+p+" would create a cycle");this.setNode(m)}return this.setNode(p),this._removeFromParentsChildList(p),this._parent[p]=m,this._children[m][p]=!0,this},r.prototype._removeFromParentsChildList=function(p){delete this._children[this._parent[p]][p]},r.prototype.parent=function(p){if(this._isCompound){var m=this._parent[p];if(m!==o)return m}},r.prototype.children=function(p){if(t.isUndefined(p)&&(p=o),this._isCompound){var m=this._children[p];if(m)return t.keys(m)}else{if(p===o)return this.nodes();if(this.hasNode(p))return[]}},r.prototype.predecessors=function(p){var m=this._preds[p];if(m)return t.keys(m)},r.prototype.successors=function(p){var m=this._sucs[p];if(m)return t.keys(m)},r.prototype.neighbors=function(p){var m=this.predecessors(p);if(m)return t.union(m,this.successors(p))},r.prototype.isLeaf=function(p){var m;return this.isDirected()?m=this.successors(p):m=this.neighbors(p),m.length===0},r.prototype.filterNodes=function(p){var m=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});m.setGraph(this.graph());var _=this;t.each(this._nodes,function(S,B){p(B)&&m.setNode(B,S)}),t.each(this._edgeObjs,function(S){m.hasNode(S.v)&&m.hasNode(S.w)&&m.setEdge(S,_.edge(S))});var C={};function k(S){var B=_.parent(S);return B===void 0||m.hasNode(B)?(C[S]=B,B):B in C?C[B]:k(B)}return this._isCompound&&t.each(m.nodes(),function(S){m.setParent(S,k(S))}),m},r.prototype.setDefaultEdgeLabel=function(p){return t.isFunction(p)||(p=t.constant(p)),this._defaultEdgeLabelFn=p,this},r.prototype.edgeCount=function(){return this._edgeCount},r.prototype.edges=function(){return t.values(this._edgeObjs)},r.prototype.setPath=function(p,m){var _=this,C=arguments;return t.reduce(p,function(k,S){return C.length>1?_.setEdge(k,S,m):_.setEdge(k,S),S}),this},r.prototype.setEdge=function(){var p,m,_,C,k=!1,S=arguments[0];typeof S=="object"&&S!==null&&"v"in S?(p=S.v,m=S.w,_=S.name,arguments.length===2&&(C=arguments[1],k=!0)):(p=S,m=arguments[1],_=arguments[3],arguments.length>2&&(C=arguments[2],k=!0)),p=""+p,m=""+m,t.isUndefined(_)||(_=""+_);var B=s(this._isDirected,p,m,_);if(t.has(this._edgeLabels,B))return k&&(this._edgeLabels[B]=C),this;if(!t.isUndefined(_)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(p),this.setNode(m),this._edgeLabels[B]=k?C:this._defaultEdgeLabelFn(p,m,_);var q=d(this._isDirected,p,m,_);return p=q.v,m=q.w,Object.freeze(q),this._edgeObjs[B]=q,l(this._preds[m],p),l(this._sucs[p],m),this._in[m][B]=q,this._out[p][B]=q,this._edgeCount++,this},r.prototype.edge=function(p,m,_){var C=arguments.length===1?f(this._isDirected,arguments[0]):s(this._isDirected,p,m,_);return this._edgeLabels[C]},r.prototype.hasEdge=function(p,m,_){var C=arguments.length===1?f(this._isDirected,arguments[0]):s(this._isDirected,p,m,_);return t.has(this._edgeLabels,C)},r.prototype.removeEdge=function(p,m,_){var C=arguments.length===1?f(this._isDirected,arguments[0]):s(this._isDirected,p,m,_),k=this._edgeObjs[C];return k&&(p=k.v,m=k.w,delete this._edgeLabels[C],delete this._edgeObjs[C],i(this._preds[m],p),i(this._sucs[p],m),delete this._in[m][C],delete this._out[p][C],this._edgeCount--),this},r.prototype.inEdges=function(p,m){var _=this._in[p];if(_){var C=t.values(_);return m?t.filter(C,function(k){return k.v===m}):C}},r.prototype.outEdges=function(p,m){var _=this._out[p];if(_){var C=t.values(_);return m?t.filter(C,function(k){return k.w===m}):C}},r.prototype.nodeEdges=function(p,m){var _=this.inEdges(p,m);if(_)return _.concat(this.outEdges(p,m))};function l(p,m){p[m]?p[m]++:p[m]=1}function i(p,m){--p[m]||delete p[m]}function s(p,m,_,C){var k=""+m,S=""+_;if(!p&&k>S){var B=k;k=S,S=B}return k+a+S+a+(t.isUndefined(C)?n:C)}function d(p,m,_,C){var k=""+m,S=""+_;if(!p&&k>S){var B=k;k=S,S=B}var q={v:k,w:S};return C&&(q.name=C),q}function f(p,m){return s(p,m.v,m.w,m.name)}return bl}var _l,Dh;function jk(){return Dh||(Dh=1,_l="2.1.8"),_l}var kl,Fh;function zk(){return Fh||(Fh=1,kl={Graph:yl(),version:jk()}),kl}var wl,qh;function Hk(){if(qh)return wl;qh=1;var t=He(),n=yl();wl={write:o,read:l};function o(i){var s={options:{directed:i.isDirected(),multigraph:i.isMultigraph(),compound:i.isCompound()},nodes:a(i),edges:r(i)};return t.isUndefined(i.graph())||(s.value=t.clone(i.graph())),s}function a(i){return t.map(i.nodes(),function(s){var d=i.node(s),f=i.parent(s),p={v:s};return t.isUndefined(d)||(p.value=d),t.isUndefined(f)||(p.parent=f),p})}function r(i){return t.map(i.edges(),function(s){var d=i.edge(s),f={v:s.v,w:s.w};return t.isUndefined(s.name)||(f.name=s.name),t.isUndefined(d)||(f.value=d),f})}function l(i){var s=new n(i.options).setGraph(i.value);return t.each(i.nodes,function(d){s.setNode(d.v,d.value),d.parent&&s.setParent(d.v,d.parent)}),t.each(i.edges,function(d){s.setEdge({v:d.v,w:d.w,name:d.name},d.value)}),s}return wl}var Vl,Rh;function Kk(){if(Rh)return Vl;Rh=1;var t=He();Vl=n;function n(o){var a={},r=[],l;function i(s){t.has(a,s)||(a[s]=!0,l.push(s),t.each(o.successors(s),i),t.each(o.predecessors(s),i))}return t.each(o.nodes(),function(s){l=[],i(s),l.length&&r.push(l)}),r}return Vl}var Cl,Ah;function Oh(){if(Ah)return Cl;Ah=1;var t=He();Cl=n;function n(){this._arr=[],this._keyIndices={}}return n.prototype.size=function(){return this._arr.length},n.prototype.keys=function(){return this._arr.map(function(o){return o.key})},n.prototype.has=function(o){return t.has(this._keyIndices,o)},n.prototype.priority=function(o){var a=this._keyIndices[o];if(a!==void 0)return this._arr[a].priority},n.prototype.min=function(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key},n.prototype.add=function(o,a){var r=this._keyIndices;if(o=String(o),!t.has(r,o)){var l=this._arr,i=l.length;return r[o]=i,l.push({key:o,priority:a}),this._decrease(i),!0}return!1},n.prototype.removeMin=function(){this._swap(0,this._arr.length-1);var o=this._arr.pop();return delete this._keyIndices[o.key],this._heapify(0),o.key},n.prototype.decrease=function(o,a){var r=this._keyIndices[o];if(a>this._arr[r].priority)throw new Error("New priority is greater than current priority. Key: "+o+" Old: "+this._arr[r].priority+" New: "+a);this._arr[r].priority=a,this._decrease(r)},n.prototype._heapify=function(o){var a=this._arr,r=2*o,l=r+1,i=o;r<a.length&&(i=a[r].priority<a[i].priority?r:i,l<a.length&&(i=a[l].priority<a[i].priority?l:i),i!==o&&(this._swap(o,i),this._heapify(i)))},n.prototype._decrease=function(o){for(var a=this._arr,r=a[o].priority,l;o!==0&&(l=o>>1,!(a[l].priority<r));)this._swap(o,l),o=l},n.prototype._swap=function(o,a){var r=this._arr,l=this._keyIndices,i=r[o],s=r[a];r[o]=s,r[a]=i,l[s.key]=o,l[i.key]=a},Cl}var xl,vh;function Ph(){if(vh)return xl;vh=1;var t=He(),n=Oh();xl=a;var o=t.constant(1);function a(l,i,s,d){return r(l,String(i),s||o,d||function(f){return l.outEdges(f)})}function r(l,i,s,d){var f={},p=new n,m,_,C=function(k){var S=k.v!==m?k.v:k.w,B=f[S],q=s(k),F=_.distance+q;if(q<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+k+" Weight: "+q);F<B.distance&&(B.distance=F,B.predecessor=m,p.decrease(S,F))};for(l.nodes().forEach(function(k){var S=k===i?0:Number.POSITIVE_INFINITY;f[k]={distance:S},p.add(k,S)});p.size()>0&&(m=p.removeMin(),_=f[m],_.distance!==Number.POSITIVE_INFINITY);)d(m).forEach(C);return f}return xl}var Nl,Lh;function Gk(){if(Lh)return Nl;Lh=1;var t=Ph(),n=He();Nl=o;function o(a,r,l){return n.transform(a.nodes(),function(i,s){i[s]=t(a,s,r,l)},{})}return Nl}var Bl,Mh;function Uh(){if(Mh)return Bl;Mh=1;var t=He();Bl=n;function n(o){var a=0,r=[],l={},i=[];function s(d){var f=l[d]={onStack:!0,lowlink:a,index:a++};if(r.push(d),o.successors(d).forEach(function(_){t.has(l,_)?l[_].onStack&&(f.lowlink=Math.min(f.lowlink,l[_].index)):(s(_),f.lowlink=Math.min(f.lowlink,l[_].lowlink))}),f.lowlink===f.index){var p=[],m;do m=r.pop(),l[m].onStack=!1,p.push(m);while(d!==m);i.push(p)}}return o.nodes().forEach(function(d){t.has(l,d)||s(d)}),i}return Bl}var Sl,jh;function Yk(){if(jh)return Sl;jh=1;var t=He(),n=Uh();Sl=o;function o(a){return t.filter(n(a),function(r){return r.length>1||r.length===1&&a.hasEdge(r[0],r[0])})}return Sl}var El,zh;function $k(){if(zh)return El;zh=1;var t=He();El=o;var n=t.constant(1);function o(r,l,i){return a(r,l||n,i||function(s){return r.outEdges(s)})}function a(r,l,i){var s={},d=r.nodes();return d.forEach(function(f){s[f]={},s[f][f]={distance:0},d.forEach(function(p){f!==p&&(s[f][p]={distance:Number.POSITIVE_INFINITY})}),i(f).forEach(function(p){var m=p.v===f?p.w:p.v,_=l(p);s[f][m]={distance:_,predecessor:f}})}),d.forEach(function(f){var p=s[f];d.forEach(function(m){var _=s[m];d.forEach(function(C){var k=_[f],S=p[C],B=_[C],q=k.distance+S.distance;q<B.distance&&(B.distance=q,B.predecessor=S.predecessor)})})}),s}return El}var Tl,Hh;function Kh(){if(Hh)return Tl;Hh=1;var t=He();Tl=n,n.CycleException=o;function n(a){var r={},l={},i=[];function s(d){if(t.has(l,d))throw new o;t.has(r,d)||(l[d]=!0,r[d]=!0,t.each(a.predecessors(d),s),delete l[d],i.push(d))}if(t.each(a.sinks(),s),t.size(r)!==a.nodeCount())throw new o;return i}function o(){}return o.prototype=new Error,Tl}var Il,Gh;function Wk(){if(Gh)return Il;Gh=1;var t=Kh();Il=n;function n(o){try{t(o)}catch(a){if(a instanceof t.CycleException)return!1;throw a}return!0}return Il}var Dl,Yh;function $h(){if(Yh)return Dl;Yh=1;var t=He();Dl=n;function n(a,r,l){t.isArray(r)||(r=[r]);var i=(a.isDirected()?a.successors:a.neighbors).bind(a),s=[],d={};return t.each(r,function(f){if(!a.hasNode(f))throw new Error("Graph does not have node: "+f);o(a,f,l==="post",d,i,s)}),s}function o(a,r,l,i,s,d){t.has(i,r)||(i[r]=!0,l||d.push(r),t.each(s(r),function(f){o(a,f,l,i,s,d)}),l&&d.push(r))}return Dl}var Fl,Wh;function Jk(){if(Wh)return Fl;Wh=1;var t=$h();Fl=n;function n(o,a){return t(o,a,"post")}return Fl}var ql,Jh;function Zk(){if(Jh)return ql;Jh=1;var t=$h();ql=n;function n(o,a){return t(o,a,"pre")}return ql}var Rl,Zh;function Xk(){if(Zh)return Rl;Zh=1;var t=He(),n=yl(),o=Oh();Rl=a;function a(r,l){var i=new n,s={},d=new o,f;function p(_){var C=_.v===f?_.w:_.v,k=d.priority(C);if(k!==void 0){var S=l(_);S<k&&(s[C]=f,d.decrease(C,S))}}if(r.nodeCount()===0)return i;t.each(r.nodes(),function(_){d.add(_,Number.POSITIVE_INFINITY),i.setNode(_)}),d.decrease(r.nodes()[0],0);for(var m=!1;d.size()>0;){if(f=d.removeMin(),t.has(s,f))i.setEdge(f,s[f]);else{if(m)throw new Error("Input graph is not connected: "+r);m=!0}r.nodeEdges(f).forEach(p)}return i}return Rl}var Al,Xh;function Qk(){return Xh||(Xh=1,Al={components:Kk(),dijkstra:Ph(),dijkstraAll:Gk(),findCycles:Yk(),floydWarshall:$k(),isAcyclic:Wk(),postorder:Jk(),preorder:Zk(),prim:Xk(),tarjan:Uh(),topsort:Kh()}),Al}var Ol,Qh;function ew(){if(Qh)return Ol;Qh=1;var t=zk();return Ol={Graph:t.Graph,json:Hk(),alg:Qk(),version:t.version},Ol}var fn;if(typeof xn=="function")try{fn=ew()}catch{}fn||(fn=window.graphlib);var Je=fn,vl,ef;function tw(){if(ef)return vl;ef=1;var t=Nd(),n=1,o=4;function a(r){return t(r,n|o)}return vl=a,vl}var Pl,tf;function pn(){if(tf)return Pl;tf=1;var t=Et(),n=rt(),o=on(),a=ze();function r(l,i,s){if(!a(s))return!1;var d=typeof i;return(d=="number"?n(s)&&o(i,s.length):d=="string"&&i in s)?t(s[i],l):!1}return Pl=r,Pl}var Ll,nf;function nw(){if(nf)return Ll;nf=1;var t=hn(),n=Et(),o=pn(),a=Vt(),r=Object.prototype,l=r.hasOwnProperty,i=t(function(s,d){s=Object(s);var f=-1,p=d.length,m=p>2?d[2]:void 0;for(m&&o(d[0],d[1],m)&&(p=1);++f<p;)for(var _=d[f],C=a(_),k=-1,S=C.length;++k<S;){var B=C[k],q=s[B];(q===void 0||n(q,r[B])&&!l.call(s,B))&&(s[B]=_[B])}return s});return Ll=i,Ll}var Ml,of;function ow(){if(of)return Ml;of=1;var t=at(),n=rt(),o=ht();function a(r){return function(l,i,s){var d=Object(l);if(!n(l)){var f=t(i,3);l=o(l),i=function(m){return f(d[m],m,d)}}var p=r(l,i,s);return p>-1?d[f?l[p]:p]:void 0}}return Ml=a,Ml}var Ul,rf;function rw(){if(rf)return Ul;rf=1;var t=/\s/;function n(o){for(var a=o.length;a--&&t.test(o.charAt(a)););return a}return Ul=n,Ul}var jl,af;function aw(){if(af)return jl;af=1;var t=rw(),n=/^\s+/;function o(a){return a&&a.slice(0,t(a)+1).replace(n,"")}return jl=o,jl}var zl,lf;function lw(){if(lf)return zl;lf=1;var t=aw(),n=ze(),o=Ft(),a=NaN,r=/^[-+]0x[0-9a-f]+$/i,l=/^0b[01]+$/i,i=/^0o[0-7]+$/i,s=parseInt;function d(f){if(typeof f=="number")return f;if(o(f))return a;if(n(f)){var p=typeof f.valueOf=="function"?f.valueOf():f;f=n(p)?p+"":p}if(typeof f!="string")return f===0?f:+f;f=t(f);var m=l.test(f);return m||i.test(f)?s(f.slice(2),m?2:8):r.test(f)?a:+f}return zl=d,zl}var Hl,sf;function cf(){if(sf)return Hl;sf=1;var t=lw(),n=1/0,o=17976931348623157e292;function a(r){if(!r)return r===0?r:0;if(r=t(r),r===n||r===-n){var l=r<0?-1:1;return l*o}return r===r?r:0}return Hl=a,Hl}var Kl,df;function iw(){if(df)return Kl;df=1;var t=cf();function n(o){var a=t(o),r=a%1;return a===a?r?a-r:a:0}return Kl=n,Kl}var Gl,uf;function sw(){if(uf)return Gl;uf=1;var t=ph(),n=at(),o=iw(),a=Math.max;function r(l,i,s){var d=l==null?0:l.length;if(!d)return-1;var f=s==null?0:o(s);return f<0&&(f=a(d+f,0)),t(l,n(i,3),f)}return Gl=r,Gl}var Yl,hf;function cw(){if(hf)return Yl;hf=1;var t=ow(),n=sw(),o=t(n);return Yl=o,Yl}var $l,ff;function pf(){if(ff)return $l;ff=1;var t=Ja();function n(o){var a=o==null?0:o.length;return a?t(o,1):[]}return $l=n,$l}var Wl,mf;function dw(){if(mf)return Wl;mf=1;var t=Or(),n=Ad(),o=Vt();function a(r,l){return r==null?r:t(r,n(l),o)}return Wl=a,Wl}var Jl,gf;function uw(){if(gf)return Jl;gf=1;function t(n){var o=n==null?0:n.length;return o?n[o-1]:void 0}return Jl=t,Jl}var Zl,bf;function hw(){if(bf)return Zl;bf=1;var t=tn(),n=Pr(),o=at();function a(r,l){var i={};return l=o(l,3),n(r,function(s,d,f){t(i,d,l(s,d,f))}),i}return Zl=a,Zl}var Xl,yf;function Ql(){if(yf)return Xl;yf=1;var t=Ft();function n(o,a,r){for(var l=-1,i=o.length;++l<i;){var s=o[l],d=a(s);if(d!=null&&(f===void 0?d===d&&!t(d):r(d,f)))var f=d,p=s}return p}return Xl=n,Xl}var ei,_f;function fw(){if(_f)return ei;_f=1;function t(n,o){return n>o}return ei=t,ei}var ti,kf;function pw(){if(kf)return ti;kf=1;var t=Ql(),n=fw(),o=Ct();function a(r){return r&&r.length?t(r,o,n):void 0}return ti=a,ti}var ni,wf;function Vf(){if(wf)return ni;wf=1;var t=tn(),n=Et();function o(a,r,l){(l!==void 0&&!n(a[r],l)||l===void 0&&!(r in a))&&t(a,r,l)}return ni=o,ni}var oi,Cf;function mw(){if(Cf)return oi;Cf=1;var t=kt(),n=ln(),o=et(),a="[object Object]",r=Function.prototype,l=Object.prototype,i=r.toString,s=l.hasOwnProperty,d=i.call(Object);function f(p){if(!o(p)||t(p)!=a)return!1;var m=n(p);if(m===null)return!0;var _=s.call(m,"constructor")&&m.constructor;return typeof _=="function"&&_ instanceof _&&i.call(_)==d}return oi=f,oi}var ri,xf;function Nf(){if(xf)return ri;xf=1;function t(n,o){if(!(o==="constructor"&&typeof n[o]=="function")&&o!="__proto__")return n[o]}return ri=t,ri}var ai,Bf;function gw(){if(Bf)return ai;Bf=1;var t=At(),n=Vt();function o(a){return t(a,n(a))}return ai=o,ai}var li,Sf;function bw(){if(Sf)return li;Sf=1;var t=Vf(),n=Ac(),o=pd(),a=vc(),r=_d(),l=Ot(),i=Se(),s=xh(),d=It(),f=Rt(),p=ze(),m=mw(),_=Lt(),C=Nf(),k=gw();function S(B,q,F,V,j,U,L){var A=C(B,F),z=C(q,F),Y=L.get(z);if(Y){t(B,F,Y);return}var $=U?U(A,z,F+"",B,q,L):void 0,H=$===void 0;if(H){var X=i(z),ie=!X&&d(z),R=!X&&!ie&&_(z);$=z,X||ie||R?i(A)?$=A:s(A)?$=a(A):ie?(H=!1,$=n(z,!0)):R?(H=!1,$=o(z,!0)):$=[]:m(z)||l(z)?($=A,l(A)?$=k(A):(!p(A)||f(A))&&($=r(z))):H=!1}H&&(L.set(z,$),j($,z,V,U,L),L.delete(z)),t(B,F,$)}return li=S,li}var ii,Ef;function yw(){if(Ef)return ii;Ef=1;var t=en(),n=Vf(),o=Or(),a=bw(),r=ze(),l=Vt(),i=Nf();function s(d,f,p,m,_){d!==f&&o(f,function(C,k){if(_||(_=new t),r(C))a(d,f,k,p,s,m,_);else{var S=m?m(i(d,k),C,k+"",d,f,_):void 0;S===void 0&&(S=C),n(d,k,S)}},l)}return ii=s,ii}var si,Tf;function _w(){if(Tf)return si;Tf=1;var t=hn(),n=pn();function o(a){return t(function(r,l){var i=-1,s=l.length,d=s>1?l[s-1]:void 0,f=s>2?l[2]:void 0;for(d=a.length>3&&typeof d=="function"?(s--,d):void 0,f&&n(l[0],l[1],f)&&(d=s<3?void 0:d,s=1),r=Object(r);++i<s;){var p=l[i];p&&a(r,p,i,d)}return r})}return si=o,si}var ci,If;function kw(){if(If)return ci;If=1;var t=yw(),n=_w(),o=n(function(a,r,l){t(a,r,l)});return ci=o,ci}var di,Df;function Ff(){if(Df)return di;Df=1;function t(n,o){return n<o}return di=t,di}var ui,qf;function ww(){if(qf)return ui;qf=1;var t=Ql(),n=Ff(),o=Ct();function a(r){return r&&r.length?t(r,o,n):void 0}return ui=a,ui}var hi,Rf;function Vw(){if(Rf)return hi;Rf=1;var t=Ql(),n=at(),o=Ff();function a(r,l){return r&&r.length?t(r,n(l,2),o):void 0}return hi=a,hi}var fi,Af;function Cw(){if(Af)return fi;Af=1;var t=We(),n=function(){return t.Date.now()};return fi=n,fi}var pi,Of;function xw(){if(Of)return pi;Of=1;var t=nn(),n=dn(),o=on(),a=ze(),r=Ut();function l(i,s,d,f){if(!a(i))return i;s=n(s,i);for(var p=-1,m=s.length,_=m-1,C=i;C!=null&&++p<m;){var k=r(s[p]),S=d;if(k==="__proto__"||k==="constructor"||k==="prototype")return i;if(p!=_){var B=C[k];S=f?f(B,k,C):void 0,S===void 0&&(S=a(B)?B:o(s[p+1])?[]:{})}t(C,k,S),C=C[k]}return i}return pi=l,pi}var mi,vf;function Nw(){if(vf)return mi;vf=1;var t=un(),n=xw(),o=dn();function a(r,l,i){for(var s=-1,d=l.length,f={};++s<d;){var p=l[s],m=t(r,p);i(m,p)&&n(f,o(p,r),m)}return f}return mi=a,mi}var gi,Pf;function Bw(){if(Pf)return gi;Pf=1;var t=Nw(),n=Su();function o(a,r){return t(a,r,function(l,i){return n(a,i)})}return gi=o,gi}var bi,Lf;function Sw(){if(Lf)return bi;Lf=1;var t=pf(),n=ih(),o=uh();function a(r){return o(n(r,void 0,t),r+"")}return bi=a,bi}var yi,Mf;function Ew(){if(Mf)return yi;Mf=1;var t=Bw(),n=Sw(),o=n(function(a,r){return a==null?{}:t(a,r)});return yi=o,yi}var _i,Uf;function Tw(){if(Uf)return _i;Uf=1;var t=Math.ceil,n=Math.max;function o(a,r,l,i){for(var s=-1,d=n(t((r-a)/(l||1)),0),f=Array(d);d--;)f[i?d:++s]=a,a+=l;return f}return _i=o,_i}var ki,jf;function Iw(){if(jf)return ki;jf=1;var t=Tw(),n=pn(),o=cf();function a(r){return function(l,i,s){return s&&typeof s!="number"&&n(l,i,s)&&(i=s=void 0),l=o(l),i===void 0?(i=l,l=0):i=o(i),s=s===void 0?l<i?1:-1:o(s),t(l,i,s,r)}}return ki=a,ki}var wi,zf;function Dw(){if(zf)return wi;zf=1;var t=Iw(),n=t();return wi=n,wi}var Vi,Hf;function Fw(){if(Hf)return Vi;Hf=1;function t(n,o){var a=n.length;for(n.sort(o);a--;)n[a]=n[a].value;return n}return Vi=t,Vi}var Ci,Kf;function qw(){if(Kf)return Ci;Kf=1;var t=Ft();function n(o,a){if(o!==a){var r=o!==void 0,l=o===null,i=o===o,s=t(o),d=a!==void 0,f=a===null,p=a===a,m=t(a);if(!f&&!m&&!s&&o>a||s&&d&&p&&!f&&!m||l&&d&&p||!r&&p||!i)return 1;if(!l&&!s&&!m&&o<a||m&&r&&i&&!l&&!s||f&&r&&i||!d&&i||!p)return-1}return 0}return Ci=n,Ci}var xi,Gf;function Rw(){if(Gf)return xi;Gf=1;var t=qw();function n(o,a,r){for(var l=-1,i=o.criteria,s=a.criteria,d=i.length,f=r.length;++l<d;){var p=t(i[l],s[l]);if(p){if(l>=f)return p;var m=r[l];return p*(m=="desc"?-1:1)}}return o.index-a.index}return xi=n,xi}var Ni,Yf;function Aw(){if(Yf)return Ni;Yf=1;var t=cn(),n=un(),o=at(),a=zu(),r=Fw(),l=rn(),i=Rw(),s=Ct(),d=Se();function f(p,m,_){m.length?m=t(m,function(S){return d(S)?function(B){return n(B,S.length===1?S[0]:S)}:S}):m=[s];var C=-1;m=t(m,l(o));var k=a(p,function(S,B,q){var F=t(m,function(V){return V(S)});return{criteria:F,index:++C,value:S}});return r(k,function(S,B){return i(S,B,_)})}return Ni=f,Ni}var Bi,$f;function Ow(){if($f)return Bi;$f=1;var t=Ja(),n=Aw(),o=hn(),a=pn(),r=o(function(l,i){if(l==null)return[];var s=i.length;return s>1&&a(l,i[0],i[1])?i=[]:s>2&&a(i[0],i[1],i[2])&&(i=[i[0]]),n(l,t(i,1),[])});return Bi=r,Bi}var Si,Wf;function vw(){if(Wf)return Si;Wf=1;var t=yu(),n=0;function o(a){var r=++n;return t(a)+r}return Si=o,Si}var Ei,Jf;function Pw(){if(Jf)return Ei;Jf=1;function t(n,o,a){for(var r=-1,l=n.length,i=o.length,s={};++r<l;){var d=r<i?o[r]:void 0;a(s,n[r],d)}return s}return Ei=t,Ei}var Ti,Zf;function Lw(){if(Zf)return Ti;Zf=1;var t=nn(),n=Pw();function o(a,r){return n(a||[],r||[],t)}return Ti=o,Ti}var mn;if(typeof xn=="function")try{mn={cloneDeep:tw(),constant:qr(),defaults:nw(),each:Ld(),filter:Au(),find:cw(),flatten:pf(),forEach:vd(),forIn:dw(),has:Pu(),isUndefined:Uu(),last:uw(),map:Ku(),mapValues:hw(),max:pw(),merge:kw(),min:ww(),minBy:Vw(),now:Cw(),pick:Ew(),range:Dw(),reduce:Wu(),sortBy:Ow(),uniqueId:vw(),values:Eh(),zipObject:Lw()}}catch{}mn||(mn=window._);var ke=mn,Mw=gn;function gn(){var t={};t._next=t._prev=t,this._sentinel=t}gn.prototype.dequeue=function(){var t=this._sentinel,n=t._prev;if(n!==t)return Xf(n),n},gn.prototype.enqueue=function(t){var n=this._sentinel;t._prev&&t._next&&Xf(t),t._next=n._next,n._next._prev=t,n._next=t,t._prev=n},gn.prototype.toString=function(){for(var t=[],n=this._sentinel,o=n._prev;o!==n;)t.push(JSON.stringify(o,Uw)),o=o._prev;return"["+t.join(", ")+"]"};function Xf(t){t._prev._next=t._next,t._next._prev=t._prev,delete t._next,delete t._prev}function Uw(t,n){if(t!=="_next"&&t!=="_prev")return n}var lt=ke,jw=Je.Graph,zw=Mw,Hw=Gw,Kw=lt.constant(1);function Gw(t,n){if(t.nodeCount()<=1)return[];var o=$w(t,n||Kw),a=Yw(o.graph,o.buckets,o.zeroIdx);return lt.flatten(lt.map(a,function(r){return t.outEdges(r.v,r.w)}),!0)}function Yw(t,n,o){for(var a=[],r=n[n.length-1],l=n[0],i;t.nodeCount();){for(;i=l.dequeue();)Ii(t,n,o,i);for(;i=r.dequeue();)Ii(t,n,o,i);if(t.nodeCount()){for(var s=n.length-2;s>0;--s)if(i=n[s].dequeue(),i){a=a.concat(Ii(t,n,o,i,!0));break}}}return a}function Ii(t,n,o,a,r){var l=r?[]:void 0;return lt.forEach(t.inEdges(a.v),function(i){var s=t.edge(i),d=t.node(i.v);r&&l.push({v:i.v,w:i.w}),d.out-=s,Di(n,o,d)}),lt.forEach(t.outEdges(a.v),function(i){var s=t.edge(i),d=i.w,f=t.node(d);f.in-=s,Di(n,o,f)}),t.removeNode(a.v),l}function $w(t,n){var o=new jw,a=0,r=0;lt.forEach(t.nodes(),function(s){o.setNode(s,{v:s,in:0,out:0})}),lt.forEach(t.edges(),function(s){var d=o.edge(s.v,s.w)||0,f=n(s),p=d+f;o.setEdge(s.v,s.w,p),r=Math.max(r,o.node(s.v).out+=f),a=Math.max(a,o.node(s.w).in+=f)});var l=lt.range(r+a+3).map(function(){return new zw}),i=a+1;return lt.forEach(o.nodes(),function(s){Di(l,i,o.node(s))}),{graph:o,buckets:l,zeroIdx:i}}function Di(t,n,o){o.out?o.in?t[o.out-o.in+n].enqueue(o):t[t.length-1].enqueue(o):t[0].enqueue(o)}var xt=ke,Ww=Hw,Jw={run:Zw,undo:Qw};function Zw(t){var n=t.graph().acyclicer==="greedy"?Ww(t,o(t)):Xw(t);xt.forEach(n,function(a){var r=t.edge(a);t.removeEdge(a),r.forwardName=a.name,r.reversed=!0,t.setEdge(a.w,a.v,r,xt.uniqueId("rev"))});function o(a){return function(r){return a.edge(r).weight}}}function Xw(t){var n=[],o={},a={};function r(l){xt.has(a,l)||(a[l]=!0,o[l]=!0,xt.forEach(t.outEdges(l),function(i){xt.has(o,i.w)?n.push(i):r(i.w)}),delete o[l])}return xt.forEach(t.nodes(),r),n}function Qw(t){xt.forEach(t.edges(),function(n){var o=t.edge(n);if(o.reversed){t.removeEdge(n);var a=o.forwardName;delete o.reversed,delete o.forwardName,t.setEdge(n.w,n.v,o,a)}})}var me=ke,Qf=Je.Graph,Oe={addDummyNode:ep,simplify:e0,asNonCompoundGraph:t0,successorWeights:n0,predecessorWeights:o0,intersectRect:r0,buildLayerMatrix:a0,normalizeRanks:l0,removeEmptyRanks:i0,addBorderNode:s0,maxRank:tp,partition:c0,time:d0,notime:u0};function ep(t,n,o,a){var r;do r=me.uniqueId(a);while(t.hasNode(r));return o.dummy=n,t.setNode(r,o),r}function e0(t){var n=new Qf().setGraph(t.graph());return me.forEach(t.nodes(),function(o){n.setNode(o,t.node(o))}),me.forEach(t.edges(),function(o){var a=n.edge(o.v,o.w)||{weight:0,minlen:1},r=t.edge(o);n.setEdge(o.v,o.w,{weight:a.weight+r.weight,minlen:Math.max(a.minlen,r.minlen)})}),n}function t0(t){var n=new Qf({multigraph:t.isMultigraph()}).setGraph(t.graph());return me.forEach(t.nodes(),function(o){t.children(o).length||n.setNode(o,t.node(o))}),me.forEach(t.edges(),function(o){n.setEdge(o,t.edge(o))}),n}function n0(t){var n=me.map(t.nodes(),function(o){var a={};return me.forEach(t.outEdges(o),function(r){a[r.w]=(a[r.w]||0)+t.edge(r).weight}),a});return me.zipObject(t.nodes(),n)}function o0(t){var n=me.map(t.nodes(),function(o){var a={};return me.forEach(t.inEdges(o),function(r){a[r.v]=(a[r.v]||0)+t.edge(r).weight}),a});return me.zipObject(t.nodes(),n)}function r0(t,n){var o=t.x,a=t.y,r=n.x-o,l=n.y-a,i=t.width/2,s=t.height/2;if(!r&&!l)throw new Error("Not possible to find intersection inside of the rectangle");var d,f;return Math.abs(l)*i>Math.abs(r)*s?(l<0&&(s=-s),d=s*r/l,f=s):(r<0&&(i=-i),d=i,f=i*l/r),{x:o+d,y:a+f}}function a0(t){var n=me.map(me.range(tp(t)+1),function(){return[]});return me.forEach(t.nodes(),function(o){var a=t.node(o),r=a.rank;me.isUndefined(r)||(n[r][a.order]=o)}),n}function l0(t){var n=me.min(me.map(t.nodes(),function(o){return t.node(o).rank}));me.forEach(t.nodes(),function(o){var a=t.node(o);me.has(a,"rank")&&(a.rank-=n)})}function i0(t){var n=me.min(me.map(t.nodes(),function(l){return t.node(l).rank})),o=[];me.forEach(t.nodes(),function(l){var i=t.node(l).rank-n;o[i]||(o[i]=[]),o[i].push(l)});var a=0,r=t.graph().nodeRankFactor;me.forEach(o,function(l,i){me.isUndefined(l)&&i%r!==0?--a:a&&me.forEach(l,function(s){t.node(s).rank+=a})})}function s0(t,n,o,a){var r={width:0,height:0};return arguments.length>=4&&(r.rank=o,r.order=a),ep(t,"border",r,n)}function tp(t){return me.max(me.map(t.nodes(),function(n){var o=t.node(n).rank;if(!me.isUndefined(o))return o}))}function c0(t,n){var o={lhs:[],rhs:[]};return me.forEach(t,function(a){n(a)?o.lhs.push(a):o.rhs.push(a)}),o}function d0(t,n){var o=me.now();try{return n()}finally{console.log(t+" time: "+(me.now()-o)+"ms")}}function u0(t,n){return n()}var np=ke,h0=Oe,f0={run:p0,undo:g0};function p0(t){t.graph().dummyChains=[],np.forEach(t.edges(),function(n){m0(t,n)})}function m0(t,n){var o=n.v,a=t.node(o).rank,r=n.w,l=t.node(r).rank,i=n.name,s=t.edge(n),d=s.labelRank;if(l!==a+1){t.removeEdge(n);var f,p,m;for(m=0,++a;a<l;++m,++a)s.points=[],p={width:0,height:0,edgeLabel:s,edgeObj:n,rank:a},f=h0.addDummyNode(t,"edge",p,"_d"),a===d&&(p.width=s.width,p.height=s.height,p.dummy="edge-label",p.labelpos=s.labelpos),t.setEdge(o,f,{weight:s.weight},i),m===0&&t.graph().dummyChains.push(f),o=f;t.setEdge(o,r,{weight:s.weight},i)}}function g0(t){np.forEach(t.graph().dummyChains,function(n){var o=t.node(n),a=o.edgeLabel,r;for(t.setEdge(o.edgeObj,a);o.dummy;)r=t.successors(n)[0],t.removeNode(n),a.points.push({x:o.x,y:o.y}),o.dummy==="edge-label"&&(a.x=o.x,a.y=o.y,a.width=o.width,a.height=o.height),n=r,o=t.node(n)})}var bn=ke,yn={longestPath:b0,slack:y0};function b0(t){var n={};function o(a){var r=t.node(a);if(bn.has(n,a))return r.rank;n[a]=!0;var l=bn.min(bn.map(t.outEdges(a),function(i){return o(i.w)-t.edge(i).minlen}));return(l===Number.POSITIVE_INFINITY||l===void 0||l===null)&&(l=0),r.rank=l}bn.forEach(t.sources(),o)}function y0(t,n){return t.node(n.w).rank-t.node(n.v).rank-t.edge(n).minlen}var _n=ke,_0=Je.Graph,kn=yn.slack,op=k0;function k0(t){var n=new _0({directed:!1}),o=t.nodes()[0],a=t.nodeCount();n.setNode(o,{});for(var r,l;w0(n,t)<a;)r=V0(n,t),l=n.hasNode(r.v)?kn(t,r):-kn(t,r),C0(n,t,l);return n}function w0(t,n){function o(a){_n.forEach(n.nodeEdges(a),function(r){var l=r.v,i=a===l?r.w:l;!t.hasNode(i)&&!kn(n,r)&&(t.setNode(i,{}),t.setEdge(a,i,{}),o(i))})}return _n.forEach(t.nodes(),o),t.nodeCount()}function V0(t,n){return _n.minBy(n.edges(),function(o){if(t.hasNode(o.v)!==t.hasNode(o.w))return kn(n,o)})}function C0(t,n,o){_n.forEach(t.nodes(),function(a){n.node(a).rank+=o})}var it=ke,x0=op,N0=yn.slack,B0=yn.longestPath,S0=Je.alg.preorder,E0=Je.alg.postorder,T0=Oe.simplify,I0=Nt;Nt.initLowLimValues=qi,Nt.initCutValues=Fi,Nt.calcCutValue=rp,Nt.leaveEdge=lp,Nt.enterEdge=ip,Nt.exchangeEdges=sp;function Nt(t){t=T0(t),B0(t);var n=x0(t);qi(n),Fi(n,t);for(var o,a;o=lp(n);)a=ip(n,t,o),sp(n,t,o,a)}function Fi(t,n){var o=E0(t,t.nodes());o=o.slice(0,o.length-1),it.forEach(o,function(a){D0(t,n,a)})}function D0(t,n,o){var a=t.node(o),r=a.parent;t.edge(o,r).cutvalue=rp(t,n,o)}function rp(t,n,o){var a=t.node(o),r=a.parent,l=!0,i=n.edge(o,r),s=0;return i||(l=!1,i=n.edge(r,o)),s=i.weight,it.forEach(n.nodeEdges(o),function(d){var f=d.v===o,p=f?d.w:d.v;if(p!==r){var m=f===l,_=n.edge(d).weight;if(s+=m?_:-_,q0(t,o,p)){var C=t.edge(o,p).cutvalue;s+=m?-C:C}}}),s}function qi(t,n){arguments.length<2&&(n=t.nodes()[0]),ap(t,{},1,n)}function ap(t,n,o,a,r){var l=o,i=t.node(a);return n[a]=!0,it.forEach(t.neighbors(a),function(s){it.has(n,s)||(o=ap(t,n,o,s,a))}),i.low=l,i.lim=o++,r?i.parent=r:delete i.parent,o}function lp(t){return it.find(t.edges(),function(n){return t.edge(n).cutvalue<0})}function ip(t,n,o){var a=o.v,r=o.w;n.hasEdge(a,r)||(a=o.w,r=o.v);var l=t.node(a),i=t.node(r),s=l,d=!1;l.lim>i.lim&&(s=i,d=!0);var f=it.filter(n.edges(),function(p){return d===cp(t,t.node(p.v),s)&&d!==cp(t,t.node(p.w),s)});return it.minBy(f,function(p){return N0(n,p)})}function sp(t,n,o,a){var r=o.v,l=o.w;t.removeEdge(r,l),t.setEdge(a.v,a.w,{}),qi(t),Fi(t,n),F0(t,n)}function F0(t,n){var o=it.find(t.nodes(),function(r){return!n.node(r).parent}),a=S0(t,o);a=a.slice(1),it.forEach(a,function(r){var l=t.node(r).parent,i=n.edge(r,l),s=!1;i||(i=n.edge(l,r),s=!0),n.node(r).rank=n.node(l).rank+(s?i.minlen:-i.minlen)})}function q0(t,n,o){return t.hasEdge(n,o)}function cp(t,n,o){return o.low<=n.lim&&n.lim<=o.lim}var R0=yn,dp=R0.longestPath,A0=op,O0=I0,v0=P0;function P0(t){switch(t.graph().ranker){case"network-simplex":up(t);break;case"tight-tree":M0(t);break;case"longest-path":L0(t);break;default:up(t)}}var L0=dp;function M0(t){dp(t),A0(t)}function up(t){O0(t)}var Ri=ke,U0=j0;function j0(t){var n=H0(t);Ri.forEach(t.graph().dummyChains,function(o){for(var a=t.node(o),r=a.edgeObj,l=z0(t,n,r.v,r.w),i=l.path,s=l.lca,d=0,f=i[d],p=!0;o!==r.w;){if(a=t.node(o),p){for(;(f=i[d])!==s&&t.node(f).maxRank<a.rank;)d++;f===s&&(p=!1)}if(!p){for(;d<i.length-1&&t.node(f=i[d+1]).minRank<=a.rank;)d++;f=i[d]}t.setParent(o,f),o=t.successors(o)[0]}})}function z0(t,n,o,a){var r=[],l=[],i=Math.min(n[o].low,n[a].low),s=Math.max(n[o].lim,n[a].lim),d,f;d=o;do d=t.parent(d),r.push(d);while(d&&(n[d].low>i||s>n[d].lim));for(f=d,d=a;(d=t.parent(d))!==f;)l.push(d);return{path:r.concat(l.reverse()),lca:f}}function H0(t){var n={},o=0;function a(r){var l=o;Ri.forEach(t.children(r),a),n[r]={low:l,lim:o++}}return Ri.forEach(t.children(),a),n}var st=ke,Ai=Oe,K0={run:G0,cleanup:W0};function G0(t){var n=Ai.addDummyNode(t,"root",{},"_root"),o=Y0(t),a=st.max(st.values(o))-1,r=2*a+1;t.graph().nestingRoot=n,st.forEach(t.edges(),function(i){t.edge(i).minlen*=r});var l=$0(t)+1;st.forEach(t.children(),function(i){hp(t,n,r,l,a,o,i)}),t.graph().nodeRankFactor=r}function hp(t,n,o,a,r,l,i){var s=t.children(i);if(!s.length){i!==n&&t.setEdge(n,i,{weight:0,minlen:o});return}var d=Ai.addBorderNode(t,"_bt"),f=Ai.addBorderNode(t,"_bb"),p=t.node(i);t.setParent(d,i),p.borderTop=d,t.setParent(f,i),p.borderBottom=f,st.forEach(s,function(m){hp(t,n,o,a,r,l,m);var _=t.node(m),C=_.borderTop?_.borderTop:m,k=_.borderBottom?_.borderBottom:m,S=_.borderTop?a:2*a,B=C!==k?1:r-l[i]+1;t.setEdge(d,C,{weight:S,minlen:B,nestingEdge:!0}),t.setEdge(k,f,{weight:S,minlen:B,nestingEdge:!0})}),t.parent(i)||t.setEdge(n,d,{weight:0,minlen:r+l[i]})}function Y0(t){var n={};function o(a,r){var l=t.children(a);l&&l.length&&st.forEach(l,function(i){o(i,r+1)}),n[a]=r}return st.forEach(t.children(),function(a){o(a,1)}),n}function $0(t){return st.reduce(t.edges(),function(n,o){return n+t.edge(o).weight},0)}function W0(t){var n=t.graph();t.removeNode(n.nestingRoot),delete n.nestingRoot,st.forEach(t.edges(),function(o){var a=t.edge(o);a.nestingEdge&&t.removeEdge(o)})}var Oi=ke,J0=Oe,Z0=X0;function X0(t){function n(o){var a=t.children(o),r=t.node(o);if(a.length&&Oi.forEach(a,n),Oi.has(r,"minRank")){r.borderLeft=[],r.borderRight=[];for(var l=r.minRank,i=r.maxRank+1;l<i;++l)fp(t,"borderLeft","_bl",o,r,l),fp(t,"borderRight","_br",o,r,l)}}Oi.forEach(t.children(),n)}function fp(t,n,o,a,r,l){var i={width:0,height:0,rank:l,borderType:n},s=r[n][l-1],d=J0.addDummyNode(t,"border",i,o);r[n][l]=d,t.setParent(d,a),s&&t.setEdge(s,d,{weight:1})}var tt=ke,Q0={adjust:eV,undo:tV};function eV(t){var n=t.graph().rankdir.toLowerCase();(n==="lr"||n==="rl")&&pp(t)}function tV(t){var n=t.graph().rankdir.toLowerCase();(n==="bt"||n==="rl")&&nV(t),(n==="lr"||n==="rl")&&(oV(t),pp(t))}function pp(t){tt.forEach(t.nodes(),function(n){mp(t.node(n))}),tt.forEach(t.edges(),function(n){mp(t.edge(n))})}function mp(t){var n=t.width;t.width=t.height,t.height=n}function nV(t){tt.forEach(t.nodes(),function(n){vi(t.node(n))}),tt.forEach(t.edges(),function(n){var o=t.edge(n);tt.forEach(o.points,vi),tt.has(o,"y")&&vi(o)})}function vi(t){t.y=-t.y}function oV(t){tt.forEach(t.nodes(),function(n){Pi(t.node(n))}),tt.forEach(t.edges(),function(n){var o=t.edge(n);tt.forEach(o.points,Pi),tt.has(o,"x")&&Pi(o)})}function Pi(t){var n=t.x;t.x=t.y,t.y=n}var ct=ke,rV=aV;function aV(t){var n={},o=ct.filter(t.nodes(),function(s){return!t.children(s).length}),a=ct.max(ct.map(o,function(s){return t.node(s).rank})),r=ct.map(ct.range(a+1),function(){return[]});function l(s){if(!ct.has(n,s)){n[s]=!0;var d=t.node(s);r[d.rank].push(s),ct.forEach(t.successors(s),l)}}var i=ct.sortBy(o,function(s){return t.node(s).rank});return ct.forEach(i,l),r}var ft=ke,lV=iV;function iV(t,n){for(var o=0,a=1;a<n.length;++a)o+=sV(t,n[a-1],n[a]);return o}function sV(t,n,o){for(var a=ft.zipObject(o,ft.map(o,function(f,p){return p})),r=ft.flatten(ft.map(n,function(f){return ft.sortBy(ft.map(t.outEdges(f),function(p){return{pos:a[p.w],weight:t.edge(p).weight}}),"pos")}),!0),l=1;l<o.length;)l<<=1;var i=2*l-1;l-=1;var s=ft.map(new Array(i),function(){return 0}),d=0;return ft.forEach(r.forEach(function(f){var p=f.pos+l;s[p]+=f.weight;for(var m=0;p>0;)p%2&&(m+=s[p+1]),p=p-1>>1,s[p]+=f.weight;d+=f.weight*m})),d}var gp=ke,cV=dV;function dV(t,n){return gp.map(n,function(o){var a=t.inEdges(o);if(a.length){var r=gp.reduce(a,function(l,i){var s=t.edge(i),d=t.node(i.v);return{sum:l.sum+s.weight*d.order,weight:l.weight+s.weight}},{sum:0,weight:0});return{v:o,barycenter:r.sum/r.weight,weight:r.weight}}else return{v:o}})}var Ue=ke,uV=hV;function hV(t,n){var o={};Ue.forEach(t,function(r,l){var i=o[r.v]={indegree:0,in:[],out:[],vs:[r.v],i:l};Ue.isUndefined(r.barycenter)||(i.barycenter=r.barycenter,i.weight=r.weight)}),Ue.forEach(n.edges(),function(r){var l=o[r.v],i=o[r.w];!Ue.isUndefined(l)&&!Ue.isUndefined(i)&&(i.indegree++,l.out.push(o[r.w]))});var a=Ue.filter(o,function(r){return!r.indegree});return fV(a)}function fV(t){var n=[];function o(l){return function(i){i.merged||(Ue.isUndefined(i.barycenter)||Ue.isUndefined(l.barycenter)||i.barycenter>=l.barycenter)&&pV(l,i)}}function a(l){return function(i){i.in.push(l),--i.indegree===0&&t.push(i)}}for(;t.length;){var r=t.pop();n.push(r),Ue.forEach(r.in.reverse(),o(r)),Ue.forEach(r.out,a(r))}return Ue.map(Ue.filter(n,function(l){return!l.merged}),function(l){return Ue.pick(l,["vs","i","barycenter","weight"])})}function pV(t,n){var o=0,a=0;t.weight&&(o+=t.barycenter*t.weight,a+=t.weight),n.weight&&(o+=n.barycenter*n.weight,a+=n.weight),t.vs=n.vs.concat(t.vs),t.barycenter=o/a,t.weight=a,t.i=Math.min(n.i,t.i),n.merged=!0}var jt=ke,mV=Oe,gV=bV;function bV(t,n){var o=mV.partition(t,function(p){return jt.has(p,"barycenter")}),a=o.lhs,r=jt.sortBy(o.rhs,function(p){return-p.i}),l=[],i=0,s=0,d=0;a.sort(yV(!!n)),d=bp(l,r,d),jt.forEach(a,function(p){d+=p.vs.length,l.push(p.vs),i+=p.barycenter*p.weight,s+=p.weight,d=bp(l,r,d)});var f={vs:jt.flatten(l,!0)};return s&&(f.barycenter=i/s,f.weight=s),f}function bp(t,n,o){for(var a;n.length&&(a=jt.last(n)).i<=o;)n.pop(),t.push(a.vs),o++;return o}function yV(t){return function(n,o){return n.barycenter<o.barycenter?-1:n.barycenter>o.barycenter?1:t?o.i-n.i:n.i-o.i}}var pt=ke,_V=cV,kV=uV,wV=gV,VV=yp;function yp(t,n,o,a){var r=t.children(n),l=t.node(n),i=l?l.borderLeft:void 0,s=l?l.borderRight:void 0,d={};i&&(r=pt.filter(r,function(k){return k!==i&&k!==s}));var f=_V(t,r);pt.forEach(f,function(k){if(t.children(k.v).length){var S=yp(t,k.v,o,a);d[k.v]=S,pt.has(S,"barycenter")&&xV(k,S)}});var p=kV(f,o);CV(p,d);var m=wV(p,a);if(i&&(m.vs=pt.flatten([i,m.vs,s],!0),t.predecessors(i).length)){var _=t.node(t.predecessors(i)[0]),C=t.node(t.predecessors(s)[0]);pt.has(m,"barycenter")||(m.barycenter=0,m.weight=0),m.barycenter=(m.barycenter*m.weight+_.order+C.order)/(m.weight+2),m.weight+=2}return m}function CV(t,n){pt.forEach(t,function(o){o.vs=pt.flatten(o.vs.map(function(a){return n[a]?n[a].vs:a}),!0)})}function xV(t,n){pt.isUndefined(t.barycenter)?(t.barycenter=n.barycenter,t.weight=n.weight):(t.barycenter=(t.barycenter*t.weight+n.barycenter*n.weight)/(t.weight+n.weight),t.weight+=n.weight)}var zt=ke,NV=Je.Graph,BV=SV;function SV(t,n,o){var a=EV(t),r=new NV({compound:!0}).setGraph({root:a}).setDefaultNodeLabel(function(l){return t.node(l)});return zt.forEach(t.nodes(),function(l){var i=t.node(l),s=t.parent(l);(i.rank===n||i.minRank<=n&&n<=i.maxRank)&&(r.setNode(l),r.setParent(l,s||a),zt.forEach(t[o](l),function(d){var f=d.v===l?d.w:d.v,p=r.edge(f,l),m=zt.isUndefined(p)?0:p.weight;r.setEdge(f,l,{weight:t.edge(d).weight+m})}),zt.has(i,"minRank")&&r.setNode(l,{borderLeft:i.borderLeft[n],borderRight:i.borderRight[n]}))}),r}function EV(t){for(var n;t.hasNode(n=zt.uniqueId("_root")););return n}var TV=ke,IV=DV;function DV(t,n,o){var a={},r;TV.forEach(o,function(l){for(var i=t.parent(l),s,d;i;){if(s=t.parent(i),s?(d=a[s],a[s]=i):(d=r,r=i),d&&d!==i){n.setEdge(d,i);return}i=s}})}var mt=ke,FV=rV,qV=lV,RV=VV,AV=BV,OV=IV,vV=Je.Graph,_p=Oe,PV=LV;function LV(t){var n=_p.maxRank(t),o=kp(t,mt.range(1,n+1),"inEdges"),a=kp(t,mt.range(n-1,-1,-1),"outEdges"),r=FV(t);wp(t,r);for(var l=Number.POSITIVE_INFINITY,i,s=0,d=0;d<4;++s,++d){MV(s%2?o:a,s%4>=2),r=_p.buildLayerMatrix(t);var f=qV(t,r);f<l&&(d=0,i=mt.cloneDeep(r),l=f)}wp(t,i)}function kp(t,n,o){return mt.map(n,function(a){return AV(t,a,o)})}function MV(t,n){var o=new vV;mt.forEach(t,function(a){var r=a.graph().root,l=RV(a,r,o,n);mt.forEach(l.vs,function(i,s){a.node(i).order=s}),OV(a,o,l.vs)})}function wp(t,n){mt.forEach(n,function(o){mt.forEach(o,function(a,r){t.node(a).order=r})})}var re=ke,UV=Je.Graph,jV=Oe,zV={positionX:GV,findType1Conflicts:Vp,findType2Conflicts:Cp,addConflict:Li,hasConflict:xp,verticalAlignment:Np,horizontalCompaction:Bp,alignCoordinates:Ep,findSmallestWidthAlignment:Sp,balance:Tp};function Vp(t,n){var o={};function a(r,l){var i=0,s=0,d=r.length,f=re.last(l);return re.forEach(l,function(p,m){var _=HV(t,p),C=_?t.node(_).order:d;(_||p===f)&&(re.forEach(l.slice(s,m+1),function(k){re.forEach(t.predecessors(k),function(S){var B=t.node(S),q=B.order;(q<i||C<q)&&!(B.dummy&&t.node(k).dummy)&&Li(o,S,k)})}),s=m+1,i=C)}),l}return re.reduce(n,a),o}function Cp(t,n){var o={};function a(l,i,s,d,f){var p;re.forEach(re.range(i,s),function(m){p=l[m],t.node(p).dummy&&re.forEach(t.predecessors(p),function(_){var C=t.node(_);C.dummy&&(C.order<d||C.order>f)&&Li(o,_,p)})})}function r(l,i){var s=-1,d,f=0;return re.forEach(i,function(p,m){if(t.node(p).dummy==="border"){var _=t.predecessors(p);_.length&&(d=t.node(_[0]).order,a(i,f,m,s,d),f=m,s=d)}a(i,f,i.length,d,l.length)}),i}return re.reduce(n,r),o}function HV(t,n){if(t.node(n).dummy)return re.find(t.predecessors(n),function(o){return t.node(o).dummy})}function Li(t,n,o){if(n>o){var a=n;n=o,o=a}var r=t[n];r||(t[n]=r={}),r[o]=!0}function xp(t,n,o){if(n>o){var a=n;n=o,o=a}return re.has(t[n],o)}function Np(t,n,o,a){var r={},l={},i={};return re.forEach(n,function(s){re.forEach(s,function(d,f){r[d]=d,l[d]=d,i[d]=f})}),re.forEach(n,function(s){var d=-1;re.forEach(s,function(f){var p=a(f);if(p.length){p=re.sortBy(p,function(S){return i[S]});for(var m=(p.length-1)/2,_=Math.floor(m),C=Math.ceil(m);_<=C;++_){var k=p[_];l[f]===f&&d<i[k]&&!xp(o,f,k)&&(l[k]=f,l[f]=r[f]=r[k],d=i[k])}}})}),{root:r,align:l}}function Bp(t,n,o,a,r){var l={},i=KV(t,n,o,r),s=r?"borderLeft":"borderRight";function d(m,_){for(var C=i.nodes(),k=C.pop(),S={};k;)S[k]?m(k):(S[k]=!0,C.push(k),C=C.concat(_(k))),k=C.pop()}function f(m){l[m]=i.inEdges(m).reduce(function(_,C){return Math.max(_,l[C.v]+i.edge(C))},0)}function p(m){var _=i.outEdges(m).reduce(function(k,S){return Math.min(k,l[S.w]-i.edge(S))},Number.POSITIVE_INFINITY),C=t.node(m);_!==Number.POSITIVE_INFINITY&&C.borderType!==s&&(l[m]=Math.max(l[m],_))}return d(f,i.predecessors.bind(i)),d(p,i.successors.bind(i)),re.forEach(a,function(m){l[m]=l[o[m]]}),l}function KV(t,n,o,a){var r=new UV,l=t.graph(),i=YV(l.nodesep,l.edgesep,a);return re.forEach(n,function(s){var d;re.forEach(s,function(f){var p=o[f];if(r.setNode(p),d){var m=o[d],_=r.edge(m,p);r.setEdge(m,p,Math.max(i(t,f,d),_||0))}d=f})}),r}function Sp(t,n){return re.minBy(re.values(n),function(o){var a=Number.NEGATIVE_INFINITY,r=Number.POSITIVE_INFINITY;return re.forIn(o,function(l,i){var s=$V(t,i)/2;a=Math.max(l+s,a),r=Math.min(l-s,r)}),a-r})}function Ep(t,n){var o=re.values(n),a=re.min(o),r=re.max(o);re.forEach(["u","d"],function(l){re.forEach(["l","r"],function(i){var s=l+i,d=t[s],f;if(d!==n){var p=re.values(d);f=i==="l"?a-re.min(p):r-re.max(p),f&&(t[s]=re.mapValues(d,function(m){return m+f}))}})})}function Tp(t,n){return re.mapValues(t.ul,function(o,a){if(n)return t[n.toLowerCase()][a];var r=re.sortBy(re.map(t,a));return(r[1]+r[2])/2})}function GV(t){var n=jV.buildLayerMatrix(t),o=re.merge(Vp(t,n),Cp(t,n)),a={},r;re.forEach(["u","d"],function(i){r=i==="u"?n:re.values(n).reverse(),re.forEach(["l","r"],function(s){s==="r"&&(r=re.map(r,function(m){return re.values(m).reverse()}));var d=(i==="u"?t.predecessors:t.successors).bind(t),f=Np(t,r,o,d),p=Bp(t,r,f.root,f.align,s==="r");s==="r"&&(p=re.mapValues(p,function(m){return-m})),a[i+s]=p})});var l=Sp(t,a);return Ep(a,l),Tp(a,t.graph().align)}function YV(t,n,o){return function(a,r,l){var i=a.node(r),s=a.node(l),d=0,f;if(d+=i.width/2,re.has(i,"labelpos"))switch(i.labelpos.toLowerCase()){case"l":f=-i.width/2;break;case"r":f=i.width/2;break}if(f&&(d+=o?f:-f),f=0,d+=(i.dummy?n:t)/2,d+=(s.dummy?n:t)/2,d+=s.width/2,re.has(s,"labelpos"))switch(s.labelpos.toLowerCase()){case"l":f=s.width/2;break;case"r":f=-s.width/2;break}return f&&(d+=o?f:-f),f=0,d}}function $V(t,n){return t.node(n).width}var Ht=ke,Ip=Oe,WV=zV.positionX,JV=ZV;function ZV(t){t=Ip.asNonCompoundGraph(t),XV(t),Ht.forEach(WV(t),function(n,o){t.node(o).x=n})}function XV(t){var n=Ip.buildLayerMatrix(t),o=t.graph().ranksep,a=0;Ht.forEach(n,function(r){var l=Ht.max(Ht.map(r,function(i){return t.node(i).height}));Ht.forEach(r,function(i){t.node(i).y=a+l/2}),a+=l+o})}var se=ke,Dp=Jw,Fp=f0,QV=v0,eC=Oe.normalizeRanks,tC=U0,nC=Oe.removeEmptyRanks,qp=K0,oC=Z0,Rp=Q0,rC=PV,aC=JV,gt=Oe,lC=Je.Graph,iC=sC;function sC(t,n){var o=n&&n.debugTiming?gt.time:gt.notime;o("layout",function(){var a=o(" buildLayoutGraph",function(){return _C(t)});o(" runLayout",function(){cC(a,o)}),o(" updateInputGraph",function(){dC(t,a)})})}function cC(t,n){n(" makeSpaceForEdgeLabels",function(){kC(t)}),n(" removeSelfEdges",function(){TC(t)}),n(" acyclic",function(){Dp.run(t)}),n(" nestingGraph.run",function(){qp.run(t)}),n(" rank",function(){QV(gt.asNonCompoundGraph(t))}),n(" injectEdgeLabelProxies",function(){wC(t)}),n(" removeEmptyRanks",function(){nC(t)}),n(" nestingGraph.cleanup",function(){qp.cleanup(t)}),n(" normalizeRanks",function(){eC(t)}),n(" assignRankMinMax",function(){VC(t)}),n(" removeEdgeLabelProxies",function(){CC(t)}),n(" normalize.run",function(){Fp.run(t)}),n(" parentDummyChains",function(){tC(t)}),n(" addBorderSegments",function(){oC(t)}),n(" order",function(){rC(t)}),n(" insertSelfEdges",function(){IC(t)}),n(" adjustCoordinateSystem",function(){Rp.adjust(t)}),n(" position",function(){aC(t)}),n(" positionSelfEdges",function(){DC(t)}),n(" removeBorderNodes",function(){EC(t)}),n(" normalize.undo",function(){Fp.undo(t)}),n(" fixupEdgeLabelCoords",function(){BC(t)}),n(" undoCoordinateSystem",function(){Rp.undo(t)}),n(" translateGraph",function(){xC(t)}),n(" assignNodeIntersects",function(){NC(t)}),n(" reversePoints",function(){SC(t)}),n(" acyclic.undo",function(){Dp.undo(t)})}function dC(t,n){se.forEach(t.nodes(),function(o){var a=t.node(o),r=n.node(o);a&&(a.x=r.x,a.y=r.y,n.children(o).length&&(a.width=r.width,a.height=r.height))}),se.forEach(t.edges(),function(o){var a=t.edge(o),r=n.edge(o);a.points=r.points,se.has(r,"x")&&(a.x=r.x,a.y=r.y)}),t.graph().width=n.graph().width,t.graph().height=n.graph().height}var uC=["nodesep","edgesep","ranksep","marginx","marginy"],hC={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},fC=["acyclicer","ranker","rankdir","align"],pC=["width","height"],mC={width:0,height:0},gC=["minlen","weight","width","height","labeloffset"],bC={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},yC=["labelpos"];function _C(t){var n=new lC({multigraph:!0,compound:!0}),o=Ui(t.graph());return n.setGraph(se.merge({},hC,Mi(o,uC),se.pick(o,fC))),se.forEach(t.nodes(),function(a){var r=Ui(t.node(a));n.setNode(a,se.defaults(Mi(r,pC),mC)),n.setParent(a,t.parent(a))}),se.forEach(t.edges(),function(a){var r=Ui(t.edge(a));n.setEdge(a,se.merge({},bC,Mi(r,gC),se.pick(r,yC)))}),n}function kC(t){var n=t.graph();n.ranksep/=2,se.forEach(t.edges(),function(o){var a=t.edge(o);a.minlen*=2,a.labelpos.toLowerCase()!=="c"&&(n.rankdir==="TB"||n.rankdir==="BT"?a.width+=a.labeloffset:a.height+=a.labeloffset)})}function wC(t){se.forEach(t.edges(),function(n){var o=t.edge(n);if(o.width&&o.height){var a=t.node(n.v),r=t.node(n.w),l={rank:(r.rank-a.rank)/2+a.rank,e:n};gt.addDummyNode(t,"edge-proxy",l,"_ep")}})}function VC(t){var n=0;se.forEach(t.nodes(),function(o){var a=t.node(o);a.borderTop&&(a.minRank=t.node(a.borderTop).rank,a.maxRank=t.node(a.borderBottom).rank,n=se.max(n,a.maxRank))}),t.graph().maxRank=n}function CC(t){se.forEach(t.nodes(),function(n){var o=t.node(n);o.dummy==="edge-proxy"&&(t.edge(o.e).labelRank=o.rank,t.removeNode(n))})}function xC(t){var n=Number.POSITIVE_INFINITY,o=0,a=Number.POSITIVE_INFINITY,r=0,l=t.graph(),i=l.marginx||0,s=l.marginy||0;function d(f){var p=f.x,m=f.y,_=f.width,C=f.height;n=Math.min(n,p-_/2),o=Math.max(o,p+_/2),a=Math.min(a,m-C/2),r=Math.max(r,m+C/2)}se.forEach(t.nodes(),function(f){d(t.node(f))}),se.forEach(t.edges(),function(f){var p=t.edge(f);se.has(p,"x")&&d(p)}),n-=i,a-=s,se.forEach(t.nodes(),function(f){var p=t.node(f);p.x-=n,p.y-=a}),se.forEach(t.edges(),function(f){var p=t.edge(f);se.forEach(p.points,function(m){m.x-=n,m.y-=a}),se.has(p,"x")&&(p.x-=n),se.has(p,"y")&&(p.y-=a)}),l.width=o-n+i,l.height=r-a+s}function NC(t){se.forEach(t.edges(),function(n){var o=t.edge(n),a=t.node(n.v),r=t.node(n.w),l,i;o.points?(l=o.points[0],i=o.points[o.points.length-1]):(o.points=[],l=r,i=a),o.points.unshift(gt.intersectRect(a,l)),o.points.push(gt.intersectRect(r,i))})}function BC(t){se.forEach(t.edges(),function(n){var o=t.edge(n);if(se.has(o,"x"))switch((o.labelpos==="l"||o.labelpos==="r")&&(o.width-=o.labeloffset),o.labelpos){case"l":o.x-=o.width/2+o.labeloffset;break;case"r":o.x+=o.width/2+o.labeloffset;break}})}function SC(t){se.forEach(t.edges(),function(n){var o=t.edge(n);o.reversed&&o.points.reverse()})}function EC(t){se.forEach(t.nodes(),function(n){if(t.children(n).length){var o=t.node(n),a=t.node(o.borderTop),r=t.node(o.borderBottom),l=t.node(se.last(o.borderLeft)),i=t.node(se.last(o.borderRight));o.width=Math.abs(i.x-l.x),o.height=Math.abs(r.y-a.y),o.x=l.x+o.width/2,o.y=a.y+o.height/2}}),se.forEach(t.nodes(),function(n){t.node(n).dummy==="border"&&t.removeNode(n)})}function TC(t){se.forEach(t.edges(),function(n){if(n.v===n.w){var o=t.node(n.v);o.selfEdges||(o.selfEdges=[]),o.selfEdges.push({e:n,label:t.edge(n)}),t.removeEdge(n)}})}function IC(t){var n=gt.buildLayerMatrix(t);se.forEach(n,function(o){var a=0;se.forEach(o,function(r,l){var i=t.node(r);i.order=l+a,se.forEach(i.selfEdges,function(s){gt.addDummyNode(t,"selfedge",{width:s.label.width,height:s.label.height,rank:i.rank,order:l+ ++a,e:s.e,label:s.label},"_se")}),delete i.selfEdges})})}function DC(t){se.forEach(t.nodes(),function(n){var o=t.node(n);if(o.dummy==="selfedge"){var a=t.node(o.e.v),r=a.x+a.width/2,l=a.y,i=o.x-r,s=a.height/2;t.setEdge(o.e,o.label),t.removeNode(n),o.label.points=[{x:r+2*i/3,y:l-s},{x:r+5*i/6,y:l-s},{x:r+i,y:l},{x:r+5*i/6,y:l+s},{x:r+2*i/3,y:l+s}],o.label.x=o.x,o.label.y=o.y}})}function Mi(t,n){return se.mapValues(se.pick(t,n),Number)}function Ui(t){var n={};return se.forEach(t,function(o,a){n[a.toLowerCase()]=o}),n}var wn=ke,FC=Oe,qC=Je.Graph,RC={debugOrdering:AC};function AC(t){var n=FC.buildLayerMatrix(t),o=new qC({compound:!0,multigraph:!0}).setGraph({});return wn.forEach(t.nodes(),function(a){o.setNode(a,{label:a}),o.setParent(a,"layer"+t.node(a).rank)}),wn.forEach(t.edges(),function(a){o.setEdge(a.v,a.w,{},a.name)}),wn.forEach(n,function(a,r){var l="layer"+r;o.setNode(l,{rank:"same"}),wn.reduce(a,function(i,s){return o.setEdge(i,s,{style:"invis"}),s})}),o}var OC="0.8.5",Ap={graphlib:Je,layout:iC,debug:RC,util:{time:Oe.time,notime:Oe.notime},version:OC};const Op=$i(Ap);window.graphlib=Ap.graphlib;class vp{constructor(){Cn(this,"lf");Cn(this,"option")}render(n){this.lf=n}getBytesLength(n){if(!n)return 0;let o=0;for(let a=0;a<n.length;a++){const r=n.charCodeAt(a);n.match(/[A-Z]/)?o+=1.5:r>=1&&r<=126||r>=65376&&r<=65439?o+=1:o+=2}return o}layout(n={}){const{nodes:o,edges:a,gridSize:r}=this.lf.graphModel;let l=40,i=40;r>20&&(l=r*2,i=r*2),this.option={type:"dagre",rankdir:"LR",align:"DR",nodesep:l,ranksep:i,begin:[120,120],...n};const d=new vC(this.option).layout({nodes:o.map(p=>({id:p.id,size:{width:p.width,height:p.height},model:p})),edges:a.map(p=>({source:p.sourceNodeId,target:p.targetNodeId,model:p}))}),f={nodes:[],edges:[]};d==null||d.nodes.forEach(p=>{const{model:m}=p,_=m.getData();_.x=p.x,_.y=p.y,f.nodes.push(_)}),d==null||d.edges.forEach(p=>{const{model:m}=p,_=m.getData();if(_.pointsList=this.calcPointsList(m,f.nodes),_.pointsList){const C=_.pointsList[0],k=_.pointsList[_.pointsList.length-1];_.startPoint={x:C.x,y:C.y},_.endPoint={x:k.x,y:k.y},_.text&&_.text.value&&(_.text={x:k.x-this.getBytesLength(_.text.value)*6-10,y:k.y,value:_.text.value})}else _.startPoint=void 0,_.endPoint=void 0,_.text&&_.text.value&&(_.text=_.text.value);f.edges.push(_)}),this.lf.render(f)}pointFilter(n){const o=n;let a=1;for(;a<o.length-1;){const r=o[a-1],l=o[a],i=o[a+1];r.x===l.x&&l.x===i.x||r.y===l.y&&l.y===i.y?o.splice(a,1):a++}return o}calcPointsList(n,o){const a=[];if(this.option.rankdir==="LR"&&n.modelType==="polyline-edge"){const r=this.lf.getNodeModelById(n.sourceNodeId),l=this.lf.getNodeModelById(n.targetNodeId),i=o.find(d=>d.id===n.sourceNodeId),s=o.find(d=>d.id===n.targetNodeId);if(i.x<s.x)return a.push({x:i.x+r.width/2+5,y:i.y+5}),a.push({x:i.x+r.width/2+(n.offset||50),y:i.y+5}),a.push({x:i.x+r.width/2+(n.offset||50),y:s.y+5}),a.push({x:s.x-l.width/2+5,y:s.y+5}),this.pointFilter(a);if(i.x>s.x)return i.y>=s.y?(a.push({x:i.x,y:i.y+r.height/2}),a.push({x:i.x,y:i.y+r.height/2+(n.offset||50)}),a.push({x:s.x,y:i.y+r.height/2+(n.offset||50)}),a.push({x:s.x,y:s.y+l.height/2})):(a.push({x:i.x,y:i.y-r.height/2}),a.push({x:i.x,y:i.y-r.height/2-(n.offset||50)}),a.push({x:s.x,y:i.y-r.height/2-(n.offset||50)}),a.push({x:s.x,y:s.y-l.height/2})),this.pointFilter(a)}}}Cn(vp,"pluginName","dagre");class vC{constructor(n){this.options={rankdir:"TB",align:null,nodesep:50,ranksep:50,controlPoints:!1,...n}}layout(n){const{nodes:o,edges:a}=n;if(!o||o.length===0)return;const r=new Op.graphlib.Graph({multigraph:!0});return r.setGraph({}),r.setDefaultEdgeLabel(()=>({})),r.graph().rankdir=this.options.rankdir,r.graph().align=this.options.align,r.graph().nodesep=this.options.nodesep,r.graph().ranksep=this.options.ranksep,o.forEach(l=>{r.setNode(l.id,{width:l.width||50,height:l.height||50})}),a.forEach(l=>{r.setEdge(l.source,l.target)}),Op.layout(r),o.forEach(l=>{const i=r.node(l.id);l.x=i.x,l.y=i.y}),this.options.controlPoints&&a.forEach(l=>{const i=r.edge(l.source,l.target);l.controlPoints=i.points}),{nodes:o,edges:a}}}const PC={name:"lfControl",props:{lf:{type:Object,default:()=>{}}},data(){return{undoDisable:!0,redoDisable:!0,graphData:null,dataVisible:!1}},mounted(){this.$props.lf.on("history:change",({data:{undoAble:t,redoAble:n}})=>{this.$data.undoDisable=!t,this.$data.redoDisable=!n})},methods:{zoomIn(){this.$props.lf.zoom(!0)},zoomOut(){this.$props.lf.zoom(!1)},zoomReset(){this.$props.lf.resetZoom()},translateRest(){this.$props.lf.resetTranslate()},reset(){this.$props.lf.resetZoom(),this.$props.lf.resetTranslate(),this.$props.lf.translateCenter()},undo(){this.$props.lf.undo()},redo(){this.$props.lf.redo()},download(){this.$props.lf.getSnapshot()},catData(){this.$emit("catData")},showMiniMap(){const{lf:t}=this.$props;t.extension.miniMap.isShow?t.extension.miniMap.hide():t.extension.miniMap.show(t.graphModel.width-178,50)}}};function LC(t,n,o,a,r,l){const i=e.resolveComponent("el-button"),s=e.resolveComponent("el-tooltip"),d=e.resolveComponent("el-button-group");return e.openBlock(),e.createElementBlock("div",null,[e.createVNode(d,null,{default:e.withCtx(()=>[e.createVNode(s,{class:"box-item",effect:"dark",content:"放大",placement:"bottom-end"},{default:e.withCtx(()=>[e.createVNode(i,{plain:"",onClick:l.zoomIn,icon:"el-icon-zoom-in"},null,8,["onClick"])]),_:1}),e.createVNode(s,{class:"box-item",effect:"dark",content:"缩小",placement:"bottom-end"},{default:e.withCtx(()=>[e.createVNode(i,{plain:"",onClick:l.zoomOut,icon:"el-icon-zoom-out"},null,8,["onClick"])]),_:1}),e.createVNode(s,{class:"box-item",effect:"dark",content:"还原(大小&定位)",placement:"bottom-end"},{default:e.withCtx(()=>[e.createVNode(i,{plain:"",onClick:l.reset,icon:"el-icon-location"},null,8,["onClick"])]),_:1}),e.createVNode(s,{class:"box-item",effect:"dark",content:"上一步(ctrl+z)",placement:"bottom-end"},{default:e.withCtx(()=>[e.createVNode(i,{plain:"",onClick:l.undo,icon:"el-icon-arrow-left",disabled:r.undoDisable},null,8,["onClick","disabled"])]),_:1}),e.createVNode(s,{class:"box-item",effect:"dark",content:"下一步(ctrl+y)",placement:"bottom-end"},{default:e.withCtx(()=>[e.createVNode(i,{plain:"",onClick:l.redo,icon:"el-icon-arrow-right",disabled:r.redoDisable},null,8,["onClick","disabled"])]),_:1}),e.createVNode(s,{class:"box-item",effect:"dark",content:"缩略图(点击展开,再次点击关闭)",placement:"bottom-end"},{default:e.withCtx(()=>[e.createVNode(i,{plain:"",onClick:l.showMiniMap,icon:"el-icon-position"},null,8,["onClick"])]),_:1})]),_:1})])}const MC=le(PC,[["render",LC]]),UC={name:"lfNodePanel",props:{lf:Object,nodeList:Array},data(){return{activeNames:""}},mounted(){this.activeNames=this.nodeList[0].title},methods:{dragNode(t){this.$props.lf.dnd.startDrag({type:t.type})}}},jC={class:"node-panel"},zC={class:"node-list"},HC=["onMousedown"],KC={class:"node-label"};function GC(t,n,o,a,r,l){const i=e.resolveComponent("el-collapse-item"),s=e.resolveComponent("el-collapse");return e.openBlock(),e.createElementBlock("div",jC,[e.createVNode(s,{modelValue:r.activeNames,"onUpdate:modelValue":n[0]||(n[0]=d=>r.activeNames=d),accordion:""},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.nodeList,d=>(e.openBlock(),e.createBlock(i,{title:d.title,name:d.title},{default:e.withCtx(()=>[e.createElementVNode("div",zC,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.list,f=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["node-item",[f.type]]),key:f.name,onMousedown:p=>l.dragNode(f)},[e.createElementVNode("i",{class:e.normalizeClass(["iconfont",[f.icon]]),style:e.normalizeStyle({color:f.themeColor})},null,6),e.createElementVNode("span",KC,e.toDisplayString(f.name),1)],42,HC))),128))])]),_:2},1032,["title","name"]))),256))]),_:1},8,["modelValue"])])}const YC=le(UC,[["render",GC],["__scopeId","data-v-663b3bb3"]]);function $C(t){t.register("start",({HtmlNode:n,HtmlNodeModel:o,h:a})=>{class r extends n{setHtml(s){var _,C,k,S,B,q,F,V,j,U,L,A,z;const{properties:d,text:f}=this.props.model,p=document.createElement("div");p.className="lw-flow-node-start",p.style.backgroundColor=((_=d==null?void 0:d.style)==null?void 0:_.backgroundColor)||"",p.style.borderStyle=((C=d==null?void 0:d.style)==null?void 0:C.borderStyle)||"",p.style.borderColor=((k=d==null?void 0:d.style)==null?void 0:k.borderColor)||"",p.style.borderWidth=`${((S=d==null?void 0:d.style)==null?void 0:S.borderWidth)||2}px`,p.style.color=((B=d==null?void 0:d.style)==null?void 0:B.fontColor)||"",p.style.fontSize=`${((q=d==null?void 0:d.style)==null?void 0:q.fontSize)||14}px`,p.style.fontFamily=((F=d==null?void 0:d.style)==null?void 0:F.fontFamily)||"Microsoft YaHei",p.style.lineHeight=((V=d==null?void 0:d.style)==null?void 0:V.lineHeight)||"1",p.style.fontWeight=((j=d==null?void 0:d.style)==null?void 0:j.fontWeight)||"",p.style.justifyContent=((U=d==null?void 0:d.style)==null?void 0:U.textAlign)||"",p.style.textDecoration=((L=d==null?void 0:d.style)==null?void 0:L.textDecoration)||"",p.style.fontStyle=((A=d==null?void 0:d.style)==null?void 0:A.fontStyle)||"";const m=`<span>${((z=d==null?void 0:d.data)==null?void 0:z.name)||"开始"}</span>`;p.innerHTML=m,s.innerHTML="",s.appendChild(p),window.stop=Y=>{Y.stopPropagation()},window.setData=()=>{const{graphModel:Y,model:$}=this.props;Y.eventCenter.emit("custom:button-click",$)}}}class l extends o{setAttributes(){this.width=100,this.height=40,this.text.editable=!1}getConnectedTargetRules(){const s=super.getConnectedTargetRules(),d={message:"起始节点不能作为连线的终点",validate:()=>!1};return s.push(d),s}}return{view:r,model:l}})}function WC(t){t.register("end",({HtmlNode:n,HtmlNodeModel:o,h:a})=>{class r extends n{setHtml(s){var _,C,k,S,B,q,F,V,j,U,L,A,z;const{properties:d,text:f}=this.props.model,p=document.createElement("div");p.className="lw-flow-node-end",p.style.backgroundColor=((_=d==null?void 0:d.style)==null?void 0:_.backgroundColor)||"",p.style.borderStyle=((C=d==null?void 0:d.style)==null?void 0:C.borderStyle)||"solid",p.style.borderColor=((k=d==null?void 0:d.style)==null?void 0:k.borderColor)||"",p.style.borderWidth=`${((S=d==null?void 0:d.style)==null?void 0:S.borderWidth)||2}px`,p.style.color=((B=d==null?void 0:d.style)==null?void 0:B.fontColor)||"",p.style.fontSize=`${((q=d==null?void 0:d.style)==null?void 0:q.fontSize)||14}px`,p.style.fontFamily=((F=d==null?void 0:d.style)==null?void 0:F.fontFamily)||"Microsoft YaHei",p.style.lineHeight=((V=d==null?void 0:d.style)==null?void 0:V.lineHeight)||"1",p.style.fontWeight=((j=d==null?void 0:d.style)==null?void 0:j.fontWeight)||"",p.style.justifyContent=((U=d==null?void 0:d.style)==null?void 0:U.textAlign)||"",p.style.textDecoration=((L=d==null?void 0:d.style)==null?void 0:L.textDecoration)||"",p.style.fontStyle=((A=d==null?void 0:d.style)==null?void 0:A.fontStyle)||"";const m=`<span>${((z=d==null?void 0:d.data)==null?void 0:z.name)||"结束"}</span>`;p.innerHTML=m,s.innerHTML="",s.appendChild(p),window.stop=Y=>{Y.stopPropagation()},window.setData=()=>{const{graphModel:Y,model:$}=this.props;Y.eventCenter.emit("custom:button-click",$)}}}class l extends o{setAttributes(){this.width=100,this.height=40,this.text.editable=!1}getConnectedSourceRules(){const s=super.getConnectedSourceRules(),d={message:"终止节点不能作为连线的起点",validate:()=>!1};return s.push(d),s}}return{view:r,model:l}})}const Ke={base:{configKeyableSource:{treeProps:{children:"fields"},rowKey:"id",formItems:[{label:"来源名称",name:"name",value:"",minWidth:"80",component:"input",options:{placeholder:"请输入"},rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"名称简写",name:"abbr",value:"",minWidth:"80",component:"input",options:{placeholder:"请输入"}},{label:"关联字段",name:"with",value:"",minWidth:"80",component:"input",options:{placeholder:"请输入"},rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"自动映射",name:"auto",value:!1,minWidth:"75",component:"switch"},{label:"操作",component:"operation",width:"60",fixed:"right",options:{addDelete:[{icon:"",type:"delete",label:"删除"}]}}]},configMapAction:{treeProps:{children:"fields"},rowKey:"id",formItems:[{label:"映射类型",name:"type",value:"",minWidth:"80",component:"select",options:{placeholder:"请选择",items:[{label:"任意映射",value:"any_of"},{label:"直接映射",value:"direct"}]},rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"来源字段",name:"from",value:"",minWidth:"80",component:"sourceField",options:{placeholder:"请输入"},rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"目标字段",name:"into",value:"",minWidth:"80",component:"input",options:{placeholder:"请输入"},rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"操作",component:"operation",width:"60",fixed:"right",options:{addDelete:[{icon:"",type:"delete",label:"删除"}]}}]}},collap:{nodeHtml:[],targetRules:[{message:"目标节点只允许一个上级连接",validate:(t,n,o,a)=>{let{edges:r}=n.graphModel,{id:l}=n;return[...r].filter(s=>{let{targetNodeId:d}={...s};return d==l}).length<1}}],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"来源名称",name:"from",value:"",component:"input",options:{placeholder:"请输入数据表名"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"折叠字段",name:"with",value:"",component:"input",options:{placeholder:"请输入折叠字段名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"折叠排序方式",name:"sort",value:"",component:"input",options:{placeholder:"请输入 例如:batchId, updateTime DESC"},span:24},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},expand:{nodeHtml:[],targetRules:[{message:"目标节点只允许一个上级连接",validate:(t,n,o,a)=>{let{edges:r}=n.graphModel,{id:l}=n;return[...r].filter(s=>{let{targetNodeId:d}={...s};return d==l}).length<1}}],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"来源名称",name:"from",value:"",component:"input",options:{placeholder:"请输入数据表名"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"展开字段名称",name:"with",value:"",component:"input",options:{placeholder:"请输入展开字段名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},filter:{nodeHtml:[],targetRules:[{message:"目标节点只允许一个上级连接",validate:(t,n,o,a)=>{let{edges:r}=n.graphModel,{id:l}=n;return[...r].filter(s=>{let{targetNodeId:d}={...s};return d==l}).length<1}}],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"来源名称",name:"from",value:"",component:"input",options:{placeholder:"请输入数据表名"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"过滤条件",name:"when",value:"",component:"input",options:{placeholder:"请输入 例如:time >= @date(-12M) && active = true"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},joiner:{nodeHtml:[],targetRules:[],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"连接模式",name:"mode",value:"",component:"input",span:24,options:{placeholder:"请输入连接模式"}},{label:"数据来源",name:"from",value:[],component:"KeyableSource",span:24,rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"映射动作",name:"with",value:[],component:"MapAction",options:{placeholder:"请选择映射动作"},span:24,rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},mapper:{nodeHtml:[],targetRules:[{message:"目标节点只允许一个上级连接",validate:(t,n,o,a)=>{let{edges:r}=n.graphModel,{id:l}=n;return[...r].filter(s=>{let{targetNodeId:d}={...s};return d==l}).length<1}}],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"来源名称",name:"from",value:"",component:"input",options:{placeholder:"请输入来源名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"自动映射",name:"auto",value:!1,component:"switch",options:{placeholder:"请输入来源名称"},tips:"自动映射来源/目标表中名称相同的字段",span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"映射动作",name:"with",value:[],component:"MapAction",options:{placeholder:"请选择映射动作"},tips:"启用自动映射时允许为空",span:24,hideHandle:"$.auto",rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"映射动作",name:"with",value:[],component:"MapAction",options:{placeholder:"请选择映射动作"},tips:"启用自动映射时允许为空",span:24,hideHandle:"!$.auto"},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},reduce:{nodeHtml:[],targetRules:[],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"数据来源",name:"from",value:[],component:"KeyableSource",span:24,rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"映射动作",name:"with",value:[],component:"MapAction",options:{placeholder:"请选择映射动作"},span:24,rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},source:{nodeHtml:[],targetRules:[{message:"目标节点只允许一个上级连接",validate:(t,n,o,a)=>{let{edges:r}=n.graphModel,{id:l}=n;return[...r].filter(s=>{let{targetNodeId:d}={...s};return d==l}).length<1}}],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"运行模式",name:"mode",value:"normal",component:"select",span:24,options:{items:[{label:"标准模式",value:"normal"},{label:"折叠模式",value:"collap"},{label:"展开模式",value:"expand"},{label:"SQL模式",value:"sql"}]}},{label:"数据表名",name:"from",value:"",component:"input",options:{placeholder:"请输入数据表名"},tips:"非SQL模式必须填写",span:24,hideHandle:'$.mode == "sql"',rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"数据表名",name:"from",value:"",component:"input",options:{placeholder:"请输入数据表名"},tips:"非SQL模式必须填写",span:24,hideHandle:'$.mode != "sql"'},{label:"所需字段",name:"cols",value:"",component:"input",options:{placeholder:"请输入所需字段"},tips:"多个字段采用逗号分隔,为空时选取所有字段,支持AS关键字。",span:24},{label:"关联字段",name:"with",value:"",component:"input",options:{placeholder:"请输入关联字段"},span:24,hideHandle:'$.mode != "expand" && $.mode != "collap"',rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"关联字段",name:"with",value:"",component:"input",options:{placeholder:"请输入关联字段"},span:24,hideHandle:'$.mode == "expand" || $.mode == "collap"'},{label:"折叠排序方式",name:"sort",value:"",component:"input",options:{placeholder:"请输入 例如:batchId, updateTime DESC"},span:24,hideHandle:'$.mode != "collap"',rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"折叠排序方式",name:"sort",value:"",component:"input",options:{placeholder:"请输入 例如:batchId, updateTime DESC"},span:24,hideHandle:'$.mode == "collap"'},{label:"过滤条件",name:"when",value:"",component:"input",options:{placeholder:"请输入 例如:time >= @date(-12M) && active = true"},span:24},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},target:{nodeHtml:[],targetRules:[{message:"目标节点只允许一个上级连接",validate:(t,n,o,a)=>{let{edges:r}=n.graphModel,{id:l}=n;return[...r].filter(s=>{let{targetNodeId:d}={...s};return d==l}).length<1}}],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"数据来源",name:"from",value:"",component:"input",options:{placeholder:"请输入来源名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},timer:{nodeHtml:[{label:"定时器类型",component:"radio",value:"schedule.type"},{label:"日期时间",value:"schedule.date",component:"date",hideHandle:'$.schedule.type != "DATE"'},{label:"日期范围",value:"timeRange",component:"date",hideHandle:'$.schedule.type != "CRON"'},{label:"cron",value:"cron",component:"dateCron",hideHandle:'$.schedule.type != "CRON"'},{label:"天",value:"delay.day",component:"number",hideHandle:'$.schedule.type != "DELAY"'},{label:"小时",value:"delay.hour",component:"number",hideHandle:'$.schedule.type != "DELAY"'},{label:"分钟",value:"delay.minute",component:"number",hideHandle:'$.schedule.type != "DELAY"'},{label:"秒",value:"delay.second",component:"number",hideHandle:'$.schedule.type != "DELAY"'}],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"定时器类型",name:"schedule",value:"DATE",component:"radio",span:24,options:{name:"type",items:[{label:"单次",value:"DATE"},{label:"多次",value:"CRON"},{label:"延时",value:"DELAY"}]}},{label:"日期时间",name:"schedule",value:"",component:"date",span:24,options:{name:"date",type:"datetime"},hideHandle:'$.schedule.type != "DATE"'},{label:"日期范围",name:"timeRange",value:"",component:"date",span:24,options:{type:"datetimerange",startPlaceholder:"开始时间",endPlaceholder:"结束时间"},hideHandle:'$.schedule.type != "CRON"'},{label:"cron",component:"dateCron",hideHandle:'$.schedule.type != "CRON"'},{label:"天",name:"delay",value:"",component:"number",span:12,options:{name:"day",min:0},hideHandle:'$.schedule.type != "DELAY"'},{label:"小时",name:"delay",value:"",component:"number",span:12,options:{name:"hour",min:0,max:24},hideHandle:'$.schedule.type != "DELAY"'},{label:"分钟",name:"delay",value:"",component:"number",span:12,options:{name:"minute",min:0,max:60},hideHandle:'$.schedule.type != "DELAY"'},{label:"秒",name:"delay",value:"",component:"number",span:12,options:{name:"second",min:0,max:60},hideHandle:'$.schedule.type != "DELAY"'}]}},audience_receive:{nodeHtml:[{label:"事件",component:"select",value:"audienceId"},{label:"人群快照",component:"select",value:"snapshotId"},{label:"营销频次",component:"select",value:"schedule.type"},{label:"触发时间",component:"date",value:"schedule.date",hideHandle:'$.schedule.type != "DATE"'},{label:"时间范围",component:"date",value:"startEndTime","value-format":"YYYY-MM-DD",hideHandle:'$.schedule.type != "CRON"'},{label:"Cron",component:"Cron",value:"schedule.cron",hideHandle:'$.schedule.type != "CRON"'}],targetRules:[],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"选择事件",name:"audienceId",value:"",component:"audienceIdSelect",span:24,options:{items:[],placeholder:"请选择"},rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"人群快照",name:"snapshotId",value:"",component:"snapshotIdSelect",span:24,options:{items:[],placeholder:"请选择"},rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"营销频次",name:"schedule",value:"DATE",component:"select",span:24,options:{name:"type",items:[{label:"单次定时",note:"活动周期内仅触发 1 次",value:"DATE"},{label:"多次定时",note:"活动周期内允许触发多次",value:"CRON"}],placeholder:"请选择"},rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"触发时间",name:"schedule",value:"",component:"scheduleTime",span:24,options:{name:"date",placeholder:"请选择"},hideHandle:'$.schedule.type != "DATE"',rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"触发时间",name:"schedule",value:"",component:"scheduleDate",span:24,options:{name:"startTime",placeholder:"请选择"},hideHandle:'$.schedule.type != "CRON"',rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"备注信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},event_receive:{nodeHtml:[{label:"事件",component:"select",value:"behaviorId"},{label:"时间范围",component:"date",value:"eventTimeRange"},{label:"关联客户",component:"switch",value:"mappingCustomer",activeText:"是",inactiveText:"否"},{label:"去重",component:"switch",value:"unique"},{label:"字段",component:"uniqueField",value:"uniqueField",key:"path",hideHandle:"!$.unique"}],targetRules:[],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"选择事件",name:"behaviorId",value:"",component:"behaviorIdSelect",span:24,options:{items:[],placeholder:"请选择"},rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"时间范围",name:"eventTimeRange",value:[],component:"date",span:24,options:{type:"datetimerange",startPlaceholder:"开始时间",endPlaceholder:"结束时间",format:"YYYY-MM-DD HH:mm:ss",valueFormat:"YYYY-MM-DD HH:mm:ss",placeholder:"请选择"},tips:"活动在运行期间接收指定的时间范围内的行为,超出时间范围的行为数据不处理。",rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"关联客户",name:"mappingCustomer",value:!1,component:"switch",span:24,options:{activeText:"是",inactiveText:"否"},tips:"活动接收到客户的行为数据时,主动根据行为中的客户信息查找完整的客户数据。注意: 当客户的行为数据无法找到对应的客户,则不需要关联客户",rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"去重",name:"unique",component:"uniqueField",span:24},{label:"备注信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},sms:{nodeHtml:[{label:"沟通模板",component:"select",value:"capabilityId"}],targetRules:[],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"短信沟通模板",name:"capabilityId",value:"",component:"capabilityIdSelect",span:24,options:{items:[],placeholder:"请选择"},rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"模板示例",name:"content",component:"content",span:24},{label:"沟通限制",name:"frequencyLimit",value:!0,component:"checkbox",span:24,options:{items:[{label:"限制沟通次数",value:!0}]},message:"超出客户的沟通频次限制时,沟通消息不会发送,并且该客户会停在当前节点不再继续执行",rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"备注信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}}};function JC(t,n){t.register(n.type,({HtmlNode:o,HtmlNodeModel:a,h:r})=>{class l extends o{setHtml(d){var C,k,S,B,q,F,V,j,U,L,A,z,Y,$;const{properties:f,text:p}=this.props.model,m=document.createElement("div");m.className="lw-flow-node-et2l",m.style.backgroundColor=((C=f==null?void 0:f.style)==null?void 0:C.backgroundColor)||n.themeColor||"",m.style.borderStyle=((k=f==null?void 0:f.style)==null?void 0:k.borderStyle)||"",m.style.borderColor=((S=f==null?void 0:f.style)==null?void 0:S.borderColor)||n.themeColor||"",m.style.borderWidth=`${((B=f==null?void 0:f.style)==null?void 0:B.borderWidth)||2}px`,m.style.color=((q=f==null?void 0:f.style)==null?void 0:q.fontColor)||"",m.style.fontSize=`${((F=f==null?void 0:f.style)==null?void 0:F.fontSize)||12}px`,m.style.fontFamily=((V=f==null?void 0:f.style)==null?void 0:V.fontFamily)||"Microsoft YaHei",m.style.lineHeight=((j=f==null?void 0:f.style)==null?void 0:j.lineHeight)||"1",m.style.fontWeight=((U=f==null?void 0:f.style)==null?void 0:U.fontWeight)||"",m.style.justifyContent=((L=f==null?void 0:f.style)==null?void 0:L.textAlign)||"",m.style.textDecoration=((A=f==null?void 0:f.style)==null?void 0:A.textDecoration)||"",m.style.fontStyle=((z=f==null?void 0:f.style)==null?void 0:z.fontStyle)||"",f.error?m.classList.add("lw-flow-node-error"):m.classList.remove("lw-flow-node-error");const _=`<i class="iconfont ${n.icon}"></i> <span class="text" title="${((Y=f==null?void 0:f.data)==null?void 0:Y.name)||n.name}">${(($=f==null?void 0:f.data)==null?void 0:$.name)||n.name}</span>`;m.innerHTML=_,d.innerHTML="",d.appendChild(m),window.stop=H=>{H.stopPropagation()},window.setData=()=>{const{graphModel:H,model:X}=this.props;H.eventCenter.emit("custom:button-click",X)}}}class i extends a{setAttributes(){this.width=120,this.height=40,this.text.editable=!1}initNodeData(d){var f,p;super.initNodeData(d),(p=(f=Ke[n.type])==null?void 0:f.targetRules)==null||p.forEach(m=>{this.targetRules.push(m)})}}return{view:l,model:i}})}function Pp(t,n,o){function a(l,i){if(Object.keys(i).length===0)return!1;if(typeof l.hideHandle=="string")try{return new Function("data",`return ${l.hideHandle.replace(/\$/g,"data")}`)(i)}catch(s){return console.error("遇到错误时返回默认值:",s),!1}else if(typeof l.hideHandle=="boolean")return l.hideHandle;return!1}function r(l){let i="";return Ke[n.type].nodeHtml.forEach(s=>{var f;let d=(f=s.value)==null?void 0:f.split(".").reduce((p,m)=>p&&p[m],l);if((s==null?void 0:s.component)=="date"&&(Array.isArray(d)?d=`${$e(d[0]).format(s["value-format"]||"YYYY-MM-DD HH:mm:ss")} 到 ${$e(d[1]).format(s["value-format"]||"YYYY-MM-DD HH:mm:ss")}`:d=$e(d).format(s["value-format"]||"YYYY-MM-DD HH:mm:ss")),(s==null?void 0:s.component)=="switch"&&(d=d?s.activeText||"是":s.inactiveText||"否"),o[`lwFlow_${n.type}`]&&o[`lwFlow_${n.type}`][s.value]){let m=o[`lwFlow_${n.type}`][s.value].find(_=>_[s.key||"value"]==d);d=m==null?void 0:m.label}s.hideHandle?a(s,l)||(i+=`<span>${s.label}: ${d||"--"}</span>`):i+=`<span>${s.label}: ${d||"--"}</span>`}),i}t.register(n.type,({HtmlNode:l,HtmlNodeModel:i,h:s})=>{class d extends l{setHtml(m){var B,q,F,V,j,U,L,A,z,Y,$,H,X;const{properties:_,text:C}=this.props.model,k=document.createElement("div");k.className="lw-flow-node-custom",k.style.backgroundColor=((B=_==null?void 0:_.style)==null?void 0:B.backgroundColor)||n.background||"",k.style.borderStyle=((q=_==null?void 0:_.style)==null?void 0:q.borderStyle)||"",k.style.borderColor=((F=_==null?void 0:_.style)==null?void 0:F.borderColor)||n.themeColor||"",k.style.borderWidth=`${((V=_==null?void 0:_.style)==null?void 0:V.borderWidth)||2}px`,k.style.color=((j=_==null?void 0:_.style)==null?void 0:j.fontColor)||"",k.style.fontSize=`${((U=_==null?void 0:_.style)==null?void 0:U.fontSize)||12}px`,k.style.fontFamily=((L=_==null?void 0:_.style)==null?void 0:L.fontFamily)||"Microsoft YaHei",k.style.lineHeight=((A=_==null?void 0:_.style)==null?void 0:A.lineHeight)||"1",k.style.fontWeight=((z=_==null?void 0:_.style)==null?void 0:z.fontWeight)||"",k.style.justifyContent=((Y=_==null?void 0:_.style)==null?void 0:Y.textAlign)||"",k.style.textDecoration=(($=_==null?void 0:_.style)==null?void 0:$.textDecoration)||"",k.style.fontStyle=((H=_==null?void 0:_.style)==null?void 0:H.fontStyle)||"",_.error?k.classList.add("lw-flow-node-error"):k.classList.remove("lw-flow-node-error");const S=`<div class="top-name" style="border-color: ${n.themeColor};">
15
- <i class="iconfont ${n.icon}"></i> ${((X=_==null?void 0:_.data)==null?void 0:X.name)||n.name}</div>
14
+ `)+"-----END PUBLIC KEY-----"},c.hasPublicKeyProperty=function(u){return(u=u||{}).hasOwnProperty("n")&&u.hasOwnProperty("e")},c.hasPrivateKeyProperty=function(u){return(u=u||{}).hasOwnProperty("n")&&u.hasOwnProperty("e")&&u.hasOwnProperty("d")&&u.hasOwnProperty("p")&&u.hasOwnProperty("q")&&u.hasOwnProperty("dmp1")&&u.hasOwnProperty("dmq1")&&u.hasOwnProperty("coeff")},c.prototype.parsePropertiesFrom=function(u){this.n=u.n,this.e=u.e,u.hasOwnProperty("d")&&(this.d=u.d,this.p=u.p,this.q=u.q,this.dmp1=u.dmp1,this.dmq1=u.dmq1,this.coeff=u.coeff)},c}(Fe),Qe=r(155),ut=Qe!==void 0?(Ze=Qe.env)===null||Ze===void 0?void 0:"3.3.2":void 0;const nt=function(){function b(c){c===void 0&&(c={}),c=c||{},this.default_key_size=c.default_key_size?parseInt(c.default_key_size,10):1024,this.default_public_exponent=c.default_public_exponent||"010001",this.log=c.log||!1,this.key=null}return b.prototype.setKey=function(c){this.log&&this.key&&console.warn("A key was already set, overriding existing."),this.key=new Xe(c)},b.prototype.setPrivateKey=function(c){this.setKey(c)},b.prototype.setPublicKey=function(c){this.setKey(c)},b.prototype.decrypt=function(c){try{return this.getKey().decrypt(F(c))}catch{return!1}},b.prototype.encrypt=function(c){try{return q(this.getKey().encrypt(c))}catch{return!1}},b.prototype.sign=function(c,u,g){try{return q(this.getKey().sign(c,u,g))}catch{return!1}},b.prototype.verify=function(c,u,g){try{return this.getKey().verify(c,F(u),g)}catch{return!1}},b.prototype.getKey=function(c){if(!this.key){if(this.key=new Xe,c&&{}.toString.call(c)==="[object Function]")return void this.key.generateAsync(this.default_key_size,this.default_public_exponent,c);this.key.generate(this.default_key_size,this.default_public_exponent)}return this.key},b.prototype.getPrivateKey=function(){return this.getKey().getPrivateKey()},b.prototype.getPrivateKeyB64=function(){return this.getKey().getPrivateBaseKeyB64()},b.prototype.getPublicKey=function(){return this.getKey().getPublicKey()},b.prototype.getPublicKeyB64=function(){return this.getKey().getPublicBaseKeyB64()},b.version=ut,b}()})(),l.default})())})(Wi);var Ug=Wi.exports;const jg=$i(Ug),zg="/static/images/logo1.svg",Hg="/static/images/register.svg",Kg="/static/images/login.svg",Gg={name:"lwLogin",props:{isInitialized:{type:Boolean,default:!0},isCombined:{type:Boolean,default:!0},isEncryption:{type:Boolean,default:!0}},components:{Lang:Gi},data(){return{isRegistered:!1,ruleForm:{user:"",password:"",role:0,autologin:!1},registForm:{},rules:{user:[{required:!0,message:this.t("loginPage.userError"),trigger:"blur"}],password:[{required:!0,message:this.t("loginPage.PWError"),trigger:"blur"}],name:[{required:!0,message:this.t("loginPage.enterTitle"),trigger:"blur"}],phone:[{required:!0,message:this.t("loginPage.enterPhone"),trigger:"blur"},{pattern:/^[1]([3-9])[0-9]{9}$/,message:this.t("loginPage.correctPhone"),trigger:"blur"}],company:[{required:!0,message:this.t("loginPage.enterCompany"),trigger:"blur"}],position:[{required:!0,message:this.t("loginPage.selectPosition"),trigger:"change"}],description:[{required:!0,message:this.t("loginPage.selectPurpose"),trigger:"change"}]},optionsDescription:[{name:this.t("purposes.findSolution"),id:"1"},{name:this.t("purposes.compareProducts"),id:"2"},{name:this.t("purposes.other"),id:"3"}],optionsCompany:[{name:this.t("positions.techStaff"),id:"1"},{name:this.t("positions.businessStaff"),id:"2"},{name:this.t("positions.researchStaff"),id:"3"},{name:this.t("positions.marketingStaff"),id:"4"},{name:this.t("positions.operationStaff"),id:"5"},{name:this.t("positions.otherStaff"),id:"6"}],islogin:!1}},created:function(){this.$store.commit("clearViewTags"),this.$store.commit("clearKeepLive"),this.$store.commit("clearIframeList")},methods:{encrypt(t,n){const o=new jg;return o.setPublicKey(t),o.encrypt(n)},async login(){if(!await this.$refs.loginForm.validate().catch(()=>{}))return!1;let n={username:this.ruleForm.user,password:this.ruleForm.password};if(this.isEncryption){const s=await this.$api.auth.key();n={username:this.encrypt(s,this.ruleForm.user),password:this.encrypt(s,this.ruleForm.password)}}let o=await this.$api.auth.token(n);this.$tool.data.set("TOKEN",o),this.islogin=!0;let a=await this.$api.auth.bu();this.$tool.data.set("buList",a);let r=this.$tool.data.get("buCode");a.find(s=>s.code==r)||this.$tool.data.set("buCode",a[0].code);let i=await this.$api.auth.user();if(this.$tool.data.set("tenantId",i.userAuthInfo.tenantId),this.$tool.data.set("userAuthInfo",i.userAuthInfo),this.$tool.data.set("MenuPath",i.userAuthInfo.grantedApplications),this.$store.state.user=i.userAuthInfo,sessionStorage.setItem("easyweb_session_passport_current_user",JSON.stringify({v:i})),sessionStorage.setItem("easyweb_session_passport_bu",JSON.stringify({v:a[0]})),sessionStorage.setItem("easyweb_session_passport_bu_list",JSON.stringify({v:a})),document.cookie=`Authorization=Bearer ${o}`,i.combined||this.isCombined){let s=await this.$api.auth.menu();this.$tool.data.set("MENUCOMBINED",s),this.$tool.data.set("MENUCOMBINEDNMAE",this.$config.APP_NAME)}else this.$tool.data.remove("MENUCOMBINED"),this.$tool.data.remove("MENUCOMBINEDNMAE");if(this.isInitialized){let s=await this.$api.auth.initialized();this.$tool.data.set("zoneInitialized",s),s?this.$router.push(this.$config.DASHBOARD_URL):this.$router.push(this.$config.INIT_URL)}else this.$router.push(this.$config.DASHBOARD_URL);this.$message.success(this.t("loginPage.loginSuccess")),this.islogin=!1},async apply(){if(!await this.$refs.registForm.validate().catch(()=>{}))return!1;await this.$api.auth.apply(this.registForm),this.$message.success(this.t("loginPage.applySuccess"))}}},Yg={class:"login_bg"},$g={class:"video-container"},Wg={class:"img",src:Hg},Jg={class:"img",src:Kg},Zg={class:"login_main"},Xg={class:"login_registered"},Qg={class:"login-form"},eb={class:"title-name"},tb={class:"login_config"},nb={class:"login-form"},ob={class:"title-name"};function rb(t,n,o,a,r,l){const i=e.resolveComponent("el-button"),s=e.resolveComponent("el-form-item"),d=e.resolveComponent("el-input"),h=e.resolveComponent("el-option"),f=e.resolveComponent("el-select"),p=e.resolveComponent("el-form"),_=e.resolveComponent("Lang"),C=e.resolveComponent("el-checkbox"),k=e.resolveComponent("el-col"),B=e.resolveComponent("el-row");return e.openBlock(),e.createElementBlock("div",Yg,[e.createElementVNode("div",$g,[e.renderSlot(t.$slots,"logo",{},()=>[n[10]||(n[10]=e.createElementVNode("img",{class:"logo",src:zg},null,-1))],!0),e.renderSlot(t.$slots,"registerBg",{},()=>[e.withDirectives(e.createElementVNode("img",Wg,null,512),[[e.vShow,r.isRegistered]])],!0),e.renderSlot(t.$slots,"loginBg",{},()=>[e.withDirectives(e.createElementVNode("img",Jg,null,512),[[e.vShow,!r.isRegistered]])],!0)]),e.createElementVNode("div",Zg,[r.isRegistered?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("div",Xg,[e.createVNode(i,{type:"primary",link:"",onClick:n[0]||(n[0]=N=>r.isRegistered=!1)},{default:e.withCtx(()=>n[11]||(n[11]=[e.createElementVNode("i",{class:"iconfont icon-quit"},null,-1)])),_:1})]),e.createElementVNode("div",Qg,[e.createVNode(p,{ref:"registForm",class:"form-body",model:r.registForm,rules:r.rules,"label-width":"0",size:"large"},{default:e.withCtx(()=>[e.createVNode(s,null,{default:e.withCtx(()=>[e.createElementVNode("div",eb,[e.renderSlot(t.$slots,"titleRegister",{},()=>[e.createTextVNode(e.toDisplayString(t.$t("loginPage.trialRequest")),1)],!0)])]),_:3}),e.createVNode(s,{prop:"name"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:r.registForm.name,"onUpdate:modelValue":n[1]||(n[1]=N=>r.registForm.name=N),"prefix-icon":"el-icon-user",clearable:"",placeholder:t.$t("loginPage.enterTitle")},null,8,["modelValue","placeholder"])]),_:1}),e.createVNode(s,{prop:"phone"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:r.registForm.phone,"onUpdate:modelValue":n[2]||(n[2]=N=>r.registForm.phone=N),"prefix-icon":"el-icon-iphone",clearable:"",maxlength:"11",placeholder:t.$t("loginPage.enterPhone")},null,8,["modelValue","placeholder"])]),_:1}),e.createVNode(s,{prop:"company"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:r.registForm.company,"onUpdate:modelValue":n[3]||(n[3]=N=>r.registForm.company=N),"prefix-icon":"el-icon-office-building",clearable:"",placeholder:t.$t("loginPage.enterCompany")},null,8,["modelValue","placeholder"])]),_:1}),e.createVNode(s,{prop:"position"},{default:e.withCtx(()=>[e.createVNode(f,{modelValue:r.registForm.position,"onUpdate:modelValue":n[4]||(n[4]=N=>r.registForm.position=N),placeholder:t.$t("loginPage.selectPosition")},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.optionsCompany,N=>(e.openBlock(),e.createBlock(h,{key:N.id,label:N.name,value:N.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue","placeholder"])]),_:1}),e.createVNode(s,{prop:"description"},{default:e.withCtx(()=>[e.createVNode(f,{modelValue:r.registForm.description,"onUpdate:modelValue":n[5]||(n[5]=N=>r.registForm.description=N),placeholder:t.$t("loginPage.selectPurpose")},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.optionsDescription,N=>(e.openBlock(),e.createBlock(h,{key:N.id,label:N.name,value:N.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue","placeholder"])]),_:1}),e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i,{type:"primary",style:{width:"100%"},loading:r.islogin,onClick:l.apply},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("loginPage.trialRequest")),1)]),_:1},8,["loading","onClick"])]),_:1})]),_:3},8,["model","rules"])])],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",tb,[e.createVNode(_)]),e.createElementVNode("div",nb,[e.createVNode(p,{ref:"loginForm",class:"form-body",model:r.ruleForm,rules:r.rules,"label-width":"0",size:"large"},{default:e.withCtx(()=>[e.createVNode(s,null,{default:e.withCtx(()=>[e.createElementVNode("div",ob,[e.renderSlot(t.$slots,"title",{},()=>[e.createTextVNode(e.toDisplayString(t.$t("loginPage.accountLogin")),1)],!0)])]),_:3}),e.createVNode(s,{prop:"user"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:r.ruleForm.user,"onUpdate:modelValue":n[6]||(n[6]=N=>r.ruleForm.user=N),"prefix-icon":"el-icon-user",clearable:"",placeholder:t.$t("loginPage.userPlaceholder")},null,8,["modelValue","placeholder"])]),_:1}),e.createVNode(s,{prop:"password"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:r.ruleForm.password,"onUpdate:modelValue":n[7]||(n[7]=N=>r.ruleForm.password=N),"prefix-icon":"el-icon-lock",clearable:"","show-password":"",placeholder:t.$t("loginPage.PWPlaceholder")},null,8,["modelValue","placeholder"])]),_:1}),e.createVNode(s,{style:{"margin-bottom":"10px"}},{default:e.withCtx(()=>[e.createVNode(B,null,{default:e.withCtx(()=>[e.createVNode(k,{span:12},{default:e.withCtx(()=>[e.createVNode(C,{label:t.$t("loginPage.rememberMe"),modelValue:r.ruleForm.autologin,"onUpdate:modelValue":n[8]||(n[8]=N=>r.ruleForm.autologin=N)},null,8,["label","modelValue"])]),_:1}),e.createVNode(k,{span:12,style:{"text-align":"right"}},{default:e.withCtx(()=>[e.createVNode(i,{type:"primary",text:""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("loginPage.forgetPassword"))+"? ",1)]),_:1})]),_:1})]),_:1})]),_:1}),e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i,{type:"primary",style:{width:"100%"},loading:r.islogin,onClick:l.login},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("loginPage.signIn")),1)]),_:1},8,["loading","onClick"])]),_:1}),e.createVNode(s,null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("loginPage.noAccount"))+" ",1),e.createVNode(i,{type:"primary",link:"",onClick:n[9]||(n[9]=N=>r.isRegistered=!0)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("loginPage.trialRequest")),1)]),_:1})]),_:1})]),_:3},8,["model","rules"])])],64))])])}const Ji=le(Gg,[["render",rb],["__scopeId","data-v-45056e2f"]]),ab={emits:["update:modelValue","change"],name:"Input",props:{disabled:{type:Boolean,default:!1},modelValue:{type:[String,Number],default:""},item:{type:Object,default:()=>({})}},data(){return{value:this.modelValue}},watch:{modelValue(t){this.value=t},value(t){(this.item.filter??!1)&&(t=t.replace(/ /g,",").replace(/\,/g,",").replace(/\,/g,",").replace(/\n/g,",")),this.$emit("update:modelValue",t),this.$emit("change",t)}}};function lb(t,n,o,a,r,l){const i=e.resolveComponent("el-input");return e.openBlock(),e.createElementBlock("div",null,[e.createVNode(i,{type:o.item.type||"text",disabled:o.item.disabled,placeholder:o.item.label||t.$t("lwSearch.please_input"),maxlength:o.item.maxlength,minlength:o.item.minlength,"show-word-limit":o.item.showWordLimit,autosize:o.item.autosize||{minRows:2},"allow-clear":"",clearable:"",modelValue:r.value,"onUpdate:modelValue":n[0]||(n[0]=s=>r.value=s)},null,8,["type","disabled","placeholder","maxlength","minlength","show-word-limit","autosize","modelValue"])])}const ib=le(ab,[["render",lb]]),sb={name:"Select",props:{disabled:{type:Boolean,default:!1},modelValue:{type:[String,Number,Boolean,Object],default:""},item:{type:Object,default:()=>({})}},data(){return{value:this.modelValue}},watch:{modelValue(t){this.value=t},value(t){this.$emit("update:modelValue",t),this.$emit("change",t),this.callback(t,this.item)}},methods:{callback(t,n){n.callback&&n.callback(t)}}};function cb(t,n,o,a,r,l){const i=e.resolveComponent("el-tooltip"),s=e.resolveComponent("el-option"),d=e.resolveComponent("el-select");return e.openBlock(),e.createElementBlock("div",null,[e.createVNode(d,{disabled:o.item.disabled,placeholder:o.item.label||"请选择","popper-append-to-body":o.item.appendToBody,modelValue:r.value,"onUpdate:modelValue":n[0]||(n[0]=h=>r.value=h),clearable:"",filterable:"",multiple:o.item.multiple,"collapse-tags":"","allow-search":"",size:"",style:{width:"100%"}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.item.options,(h,f)=>(e.openBlock(),e.createBlock(s,{disabled:h.disabled,key:o.item.key?o.item.key:o.item.valueKey?h[o.item.valueKey]+h[o.item.labelKey]+f:h.code+h.name+f,label:o.item.isCodeAndName?(o.item.valueKey?h[o.item.valueKey]:h.code)+" - "+(o.item.labelKey?h[o.item.labelKey]:h.name):o.item.labelKey?h[o.item.labelKey]:h.name,value:o.item.valueKey?h[o.item.valueKey]:h.code},{default:e.withCtx(()=>[e.createVNode(i,{content:o.item.isCodeAndName?(o.item.valueKey?h[o.item.valueKey]:h.code)+" - "+(o.item.labelKey?h[o.item.labelKey]:h.name):o.item.labelKey?h[o.item.labelKey]:h.name},{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(o.item.isCodeAndName?(o.item.valueKey?h[o.item.valueKey]:h.code)+" - "+(o.item.labelKey?h[o.item.labelKey]:h.name):o.item.labelKey?h[o.item.labelKey]:h.name),1)]),_:2},1032,["content"])]),_:2},1032,["disabled","label","value"]))),128))]),_:1},8,["disabled","placeholder","popper-append-to-body","modelValue","multiple"])])}const db=le(sb,[["render",cb]]),ub={emits:["update:modelValue","change"],name:"Date",props:{disabled:{type:Boolean,default(){return!1}},modelValue:{default(){return""}},item:{type:Object,default(){return{}}},disabledDate:{type:Function,default(){return null}},propValueFormat:{type:String,default(){return null}}},setup(t,n){const o=e.reactive({}),a=e.computed(()=>t.propValueFormat?t.propValueFormat:t.item.valueFormat?t.item.valueFormat:t.item.dateSection||t.item.withZero?"YYYY-MM-DD 00:00:00":t.item.withLast?"YYYY-MM-DD 23:59:59":"YYYY-MM-DD"),r=e.computed({get(){return t.modelValue},set(l){n.emit("update:modelValue",l),n.emit("change",l)}});return{...e.toRefs(o),valueFormat:a,value:r}}};function hb(t,n,o,a,r,l){const i=e.resolveComponent("el-date-picker");return e.openBlock(),e.createElementBlock("div",null,[e.createVNode(i,{type:o.item.type||"date",disabled:o.item.disabled,format:o.item.format||"YYYY-MM-DD","value-format":o.item.valueFormat,placeholder:o.item.placeholder||t.$t("lwSearch.please_select"),"range-separator":o.item.rangeSeparator||t.$t("lwSearch.monthRange.rangeSeparator"),"start-placeholder":o.item.startPlaceholder||t.$t("lwSearch.monthRange.startPlaceholder"),"end-placeholder":o.item.endPlaceholder||t.$t("lwSearch.monthRange.endPlaceholder"),clearable:"",modelValue:a.value,"onUpdate:modelValue":n[0]||(n[0]=s=>a.value=s),"disabled-date":o.disabledDate,style:{width:"100%"}},null,8,["type","disabled","format","value-format","placeholder","range-separator","start-placeholder","end-placeholder","modelValue","disabled-date"])])}const fb=le(ub,[["render",hb]]),pb={emits:["update:modelValue","change"],name:"Date",props:{disabled:{type:Boolean,default:!1},modelValue:{type:[String,Array],default:""},item:{type:Object,default:()=>({})}},setup(t,n){const o=e.reactive({isSidebarShow:!1,activeName:"single",isPanelShow:!1,value:[],shortcuts:[{text:"",value:""}]});e.watch(()=>t.modelValue,f=>{f?(o.activeName=Array.isArray(f)?"range":"single",o.value=Array.isArray(f)?f:f.split(",")):o.value=[]},{deep:!0}),e.watch(()=>o.value,f=>{const p=o.activeName==="single"?f.join(","):f;p!==t.modelValue&&(n.emit("update:modelValue",p),n.emit("change",p))},{deep:!0,immediate:!0});const a=e.computed(()=>o.value.join(",")),r=()=>{o.isPanelShow=!o.isPanelShow},l=()=>{e.nextTick(()=>{o.isSidebarShow=!0})},i=()=>{e.nextTick(()=>{o.isPanelShow=!1})},s=f=>{o.value.splice(f,1)},d=()=>{o.isSidebarShow=!1,e.nextTick(()=>{o.isPanelShow=!1})},h=()=>{o.value=[]};return{...e.toRefs(o),togglePanel:r,handleTabClick:l,pickerChange:i,deleteSingleDate:s,pickerBlur:d,handleClear:h,displayValue:a}}},mb={class:"dates-container"},gb={class:"dates-panel"},bb={class:"panel-label"},yb={class:"dates-side"},_b={class:"sidebar-list"},kb={class:"text"},wb=["onClick"],Vb={class:"panel-label"},Cb={class:"dates-side-top"},xb={class:"sidebar-list"},Nb={class:"item"},Bb={class:"text"};function Sb(t,n,o,a,r,l){const i=e.resolveComponent("el-icon-calendar"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("el-input"),h=e.resolveComponent("el-date-picker"),f=e.resolveComponent("Close"),p=e.resolveComponent("el-tab-pane"),_=e.resolveComponent("el-icon-close"),C=e.resolveComponent("el-tabs");return e.openBlock(),e.createElementBlock("div",mb,[e.createVNode(d,{class:"default-input",size:"small",type:"text",disabled:o.item.disabled,placeholder:o.item.placeholder||"请选择",clearable:"","model-value":a.displayValue,onClear:a.handleClear,onClick:a.togglePanel,style:{width:"100%"}},{suffix:e.withCtx(()=>[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i)]),_:1})]),_:1},8,["disabled","placeholder","model-value","onClear","onClick"]),e.withDirectives(e.createElementVNode("div",gb,[e.createVNode(C,{modelValue:t.activeName,"onUpdate:modelValue":n[3]||(n[3]=k=>t.activeName=k),class:"dates-panel-tabs",onTabClick:a.handleTabClick},{default:e.withCtx(()=>[e.createVNode(p,{label:"单日",name:"single"},{default:e.withCtx(()=>[e.createElementVNode("div",bb,[n[5]||(n[5]=e.createElementVNode("span",null,"单日",-1)),e.createVNode(h,{size:"small",type:o.item.singleType||"date",disabled:o.item.disabled,format:o.item.format||"yyyy-MM-dd","value-format":o.item.valueFormat||"yyyy-MM-dd",placeholder:o.item.placeholder||t.$t("lwSearch.please_select"),shortcuts:t.shortcuts,modelValue:t.value,"onUpdate:modelValue":n[0]||(n[0]=k=>t.value=k),clearable:!1,onBlur:a.pickerBlur,onChange:a.pickerChange,ref:"singlePicker","popper-class":"single-picker single-picker-"+o.item.prop},null,8,["type","disabled","format","value-format","placeholder","shortcuts","modelValue","onBlur","onChange","popper-class"]),t.isSidebarShow&&t.activeName==="single"?(e.openBlock(),e.createBlock(e.Teleport,{key:0,to:".single-picker-"+o.item.prop+" .el-picker-panel__sidebar"},[e.createElementVNode("div",yb,[n[4]||(n[4]=e.createElementVNode("div",{class:"sidebar-title"},"所选时间列表",-1)),e.createElementVNode("div",_b,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.value,(k,B)=>(e.openBlock(),e.createElementBlock("div",{class:"item",key:B},[e.createElementVNode("div",kb,e.toDisplayString(k),1),e.createElementVNode("div",{class:"button",onClick:N=>a.deleteSingleDate(B)},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(f)]),_:1})],8,wb)]))),128))])])],8,["to"])):e.createCommentVNode("",!0)])]),_:1}),e.createVNode(p,{label:"日期范围",name:"range"},{default:e.withCtx(()=>[e.createElementVNode("div",Vb,[n[6]||(n[6]=e.createElementVNode("span",null,"日期范围",-1)),e.createVNode(h,{size:"small",type:o.item.rangeType||"daterange",disabled:o.item.disabled,format:o.item.format||"yyyy-MM-dd","value-format":o.item.valueFormat||"yyyy-MM-dd",placeholder:o.item.placeholder||t.$t("lwSearch.please_select"),"unlink-panels":o.item.unlinkPanels??!1,shortcuts:t.shortcuts,modelValue:t.value,"onUpdate:modelValue":n[1]||(n[1]=k=>t.value=k),clearable:!1,onBlur:a.pickerBlur,onChange:a.pickerChange,ref:"rangePicker","popper-class":"range-picker range-picker-"+o.item.prop},null,8,["type","disabled","format","value-format","placeholder","unlink-panels","shortcuts","modelValue","onBlur","onChange","popper-class"]),t.isSidebarShow&&t.activeName==="range"?(e.openBlock(),e.createBlock(e.Teleport,{key:0,to:".range-picker-"+o.item.prop+" .el-picker-panel__sidebar"},[e.createElementVNode("div",Cb,[e.createElementVNode("div",xb,[e.withDirectives(e.createElementVNode("div",Nb,[e.createElementVNode("div",Bb,e.toDisplayString(t.value[0])+"~"+e.toDisplayString(t.value[1]),1),e.createElementVNode("div",{class:"button",onClick:n[2]||(n[2]=(...k)=>a.handleClear&&a.handleClear(...k))},[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(_)]),_:1})])],512),[[e.vShow,t.value.length===2]])])])],8,["to"])):e.createCommentVNode("",!0)])]),_:1})]),_:1},8,["modelValue","onTabClick"])],512),[[e.vShow,t.isPanelShow]])])}const Eb=le(pb,[["render",Sb]]),Tb={emits:["update:modelValue","change"],name:"dateRange",props:{disabled:{type:Boolean,default(){return!1}},modelValue:{default(){return[]}},item:{type:Object,default(){return{}}},disabledDate:{type:Function,default(){return null}},propValueFormat:{type:String,default(){return null}}},setup(t,n){const o=e.reactive({}),a=e.computed(()=>t.propValueFormat?t.propValueFormat:t.item.valueFormat?t.item.valueFormat:t.item.dateSection||t.item.withZero?"YYYY-MM-DD 00:00:00":t.item.withLast?"YYYY-MM-DD 23:59:59":"YYYY-MM-DD"),r=e.computed({get(){return t.modelValue},set(i){n.emit("update:modelValue",i),n.emit("change",i)}}),l=i=>{const s=new Date;return s.setHours(i),s.setMinutes(0),s.setSeconds(0),s};return{...e.toRefs(o),defaultTime:l,valueFormat:a,value:r}}};function Ib(t,n,o,a,r,l){const i=e.resolveComponent("el-date-picker");return e.openBlock(),e.createElementBlock("div",null,[e.createVNode(i,{showTime:o.item.showTime,format:o.item.format||"YYYY-MM-DD HH:mm:ss","value-format":o.item.valueFormat,clearable:"",modelValue:a.value,"onUpdate:modelValue":n[0]||(n[0]=s=>a.value=s),style:{width:"100%"},type:"datetimerange","start-placeholder":t.$t("lwSearch.dateRange.startPlaceholder"),"end-placeholder":t.$t("lwSearch.dateRange.endPlaceholder"),"default-time":o.item.defaultTime||a.defaultTime(0),size:""},null,8,["showTime","format","value-format","modelValue","start-placeholder","end-placeholder","default-time"])])}const Db={components:{SearchInput:ib,SearchSelect:db,SearchDate:fb,SearchDates:Eb,SearchDateRange:le(Tb,[["render",Ib]])},name:"lwSearch",props:{options:{type:Array,default:()=>[]},modelValue:{type:Object,default:()=>({})},labelWidth:{type:String,default:"70px"},labelPosition:{type:String,default:"left"},columnNumber:{type:Number,default:4},isSave:{type:Boolean,default:!1},isCloud:{type:Boolean,default:!1},saveKey:{type:String,default:""},isExpand:{type:Boolean,default:!1},expandNumber:{type:Number,default:4},hasExpandAll:{type:Boolean,default:!1},hideLabel:{type:Boolean,default:!1},labelAlign:{type:String,default:"right"}},data(){return{form:{},defaultForm:{},isExpandStatus:!1,isChange:!1,saveList:[],saveFormName:"",isSaveShow:!1,isSelectShow:!1,selectForm:"",currentExpandNumber:4,isExpandAll:!0,currentTemplate:{},variantList:[],varianId:[],systemName:"shopManagement"}},watch:{modelValue:{handler(t){JSON.stringify(t)!==JSON.stringify(this.form)&&(this.form=JSON.parse(JSON.stringify(t)))},deep:!0},form:{handler(t){JSON.stringify(t)!==JSON.stringify(this.modelValue)&&this.$emit("update:modelValue",t)},deep:!0}},mounted(){this.isExpandStatus=this.isExpand,this.currentExpandNumber=this.expandNumber||this.columnNumber,this.form=JSON.parse(JSON.stringify(this.modelValue)),this.defaultForm=JSON.stringify(this.defaultForm)==="{}"?JSON.parse(JSON.stringify(this.modelValue)):this.defaultForm},methods:{setComponent(t){return{input:"SearchInput",select:"SearchSelect",date:"SearchDate",dates:"SearchDates",dateRange:"SearchDateRange"}[t]||"SearchInput"},submitForm(t){this.$refs[t]&&this.$refs[t].validate(n=>{n&&this.$emit("search")})},resetForm(t){this.$refs[t]&&(this.$refs[t].resetFields(),this.form=JSON.parse(JSON.stringify(this.defaultForm)),this.form.size=this.modelValue.size,this.$emit("reset"))},handleChangeHide(t){t===!1&&(this.isChange=!1,this.isSaveShow=!1,this.isSelectShow=!1,this.saveFormName="",this.selectForm="")},handleSaveSearchForm(){if(this.saveKey&&this.isSave){if(Object.keys(this.form).length===0){this.$message.error("搜索条件为空!");return}let t=Object.assign({},this.form,{searchSaveName:this.saveFormName,id:$e().valueOf()+Math.random()+""}),n={route:this.$route.name,system:this.systemName,variant:[t]},o=this.variantList.find(a=>a.route===this.$route.name);o?o.variant.push(t):this.variantList.push(n),this.isCloud?(this.varianId,JSON.parse(sessionStorage.userAuthInfo).username,this.systemName,this.saveKey,JSON.stringify(this.variantList)):localStorage.setItem("variantList",JSON.stringify(this.variantList))}},handleSearchSelect(t){let n=this.saveList.find(o=>o.id===t);if(n){let o=JSON.parse(JSON.stringify(n));delete o.id,delete o.searchSaveName,this.$emit("update:modelValue",o)}},handleDeleteSearchList(t){JSON.parse(JSON.stringify(this.saveList)).splice(t,1),this.saveKey&&this.isSave},disabledDate(t,n,o=""){if(o){if(n==="prev")return $e(t.getTime()).isAfter($e(o),"day");if(n==="next")return $e(t.getTime()).isBefore($e(o),"day")}},expandAll(){this.isExpandAll=!this.isExpandAll}}},Fb={id:"search-wrap"},qb={class:"search-content"};function Ab(t,n,o,a,r,l){const i=e.resolveComponent("el-col"),s=e.resolveComponent("el-row"),d=e.resolveComponent("el-form-item"),h=e.resolveComponent("el-button"),f=e.resolveComponent("el-form");return e.openBlock(),e.createElementBlock("div",Fb,[e.createElementVNode("div",qb,[e.createVNode(f,{ref:"searchForm",model:r.form,onSubmit:n[3]||(n[3]=e.withModifiers(()=>{},["prevent"])),"label-align":o.labelAlign,style:{width:"100%"}},{default:e.withCtx(()=>[e.createVNode(s,{class:e.normalizeClass(o.options.length-o.expandNumber===0?"expand-row":o.options.length-o.expandNumber<o.columnNumber?"":r.isExpandStatus?o.options.length%o.columnNumber===0?"expand-row":"":o.options.length>=o.expandNumber?"expand-row":""),type:"flex",justify:"start",gutter:10},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.options,(p,_)=>(e.openBlock(),e.createBlock(i,{key:p.prop,class:e.normalizeClass(!r.isExpandStatus&&p.isExpand||o.options.length-o.expandNumber<o.columnNumber?"":!r.isExpandStatus&&_>o.expandNumber-1?"hide":""),span:o.columnNumber?24/o.columnNumber:p.span||8},{default:e.withCtx(()=>[e.createVNode(d,{"label-width":o.hideLabel?0:o.labelWidth,required:p.required,label:o.hideLabel?"":t.$t(p.label)},{default:e.withCtx(()=>[p.dateSection&&p.prop&&p.prop.length===2?(e.openBlock(),e.createBlock(s,{key:0,gutter:10,class:"date-section"},{default:e.withCtx(()=>[e.createVNode(i,{span:12,style:{width:"45%",flex:"0 0 45%"}},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(l.setComponent(p.renderType)),{disabled:p.disabled,item:p,modelValue:r.form[p.prop[0]],"onUpdate:modelValue":C=>r.form[p.prop[0]]=C,"disabled-date":C=>l.disabledDate(C,"prev",r.form[p.prop[1]]),propValueFormat:p.valueFormat||"YYYY-MM-DD 00:00:00"},null,8,["disabled","item","modelValue","onUpdate:modelValue","disabled-date","propValueFormat"]))]),_:2},1024),n[4]||(n[4]=e.createElementVNode("span",{class:"date-section-line"}," - ",-1)),e.createVNode(i,{span:12,style:{width:"45%",flex:"0 0 45%"}},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(l.setComponent(p.renderType)),{disabled:p.disabled,item:p,modelValue:r.form[p.prop[1]],"onUpdate:modelValue":C=>r.form[p.prop[1]]=C,"disabled-date":C=>l.disabledDate(C,"next",r.form[p.prop[0]]),propValueFormat:p.valueFormat||"YYYY-MM-DD 23:59:59"},null,8,["disabled","item","modelValue","onUpdate:modelValue","disabled-date","propValueFormat"]))]),_:2},1024)]),_:2},1024)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(l.setComponent(p.renderType)),{key:1,modelValue:r.form[p.prop],"onUpdate:modelValue":C=>r.form[p.prop]=C,disabled:p.disabled,item:p,style:{width:"100%"}},null,8,["modelValue","onUpdate:modelValue","disabled","item"]))]),_:2},1032,["label-width","required","label"])]),_:2},1032,["class","span"]))),128))]),_:1},8,["class"]),e.createElementVNode("div",{class:"control",style:e.normalizeStyle({bottom:o.options.length%o.columnNumber===0?"0px":"10px"})},[e.createVNode(h,{class:"reset",onClick:n[0]||(n[0]=p=>l.resetForm("searchForm"))},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("btn.reset")),1)]),_:1}),e.createVNode(h,{class:"submit",type:"primary",onClick:n[1]||(n[1]=p=>l.submitForm("searchForm"))},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("btn.query")),1)]),_:1}),e.createElementVNode("div",{class:e.normalizeClass(o.options.length-o.expandNumber>=o.columnNumber?"expand-button":"hidden"),onClick:n[2]||(n[2]=p=>r.isExpandStatus=!r.isExpandStatus)},[e.createElementVNode("span",null,e.toDisplayString(r.isExpandStatus?"收起":"展开"),1)],2)],4)]),_:1},8,["model","label-align"])])])}const Zi=le(Db,[["render",Ab],["__scopeId","data-v-153d358b"]]),Rb={class:"svg-icon"},Ob=["xlink:href"],Xi=le({__name:"index",props:{name:{type:String,required:!0}},setup(t){const n=t,o=e.computed(()=>`#${n.name}`);return(a,r)=>(e.openBlock(),e.createElementBlock("svg",Rb,[e.createElementVNode("use",{"xlink:href":o.value},null,8,Ob)]))}},[["__scopeId","data-v-d1f88c15"]]);function vb(){const t=e.ref(!1),n=l=>{l.requestFullscreen?l.requestFullscreen():l.mozRequestFullScreen?l.mozRequestFullScreen():l.webkitRequestFullscreen?l.webkitRequestFullscreen():l.msRequestFullscreen&&l.msRequestFullscreen()},o=()=>{document.exitFullscreen?document.exitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitExitFullscreen?document.webkitExitFullscreen():document.msExitFullscreen&&document.msExitFullscreen()},a=()=>{t.value?o():n(document.documentElement)},r=()=>{t.value=!!(document.fullscreenElement||document.mozFullScreenElement||document.webkitFullscreenElement||document.msFullscreenElement)};return e.onMounted(()=>{document.addEventListener("fullscreenchange",r),document.addEventListener("webkitfullscreenchange",r),document.addEventListener("mozfullscreenchange",r),document.addEventListener("MSFullscreenChange",r)}),e.onUnmounted(()=>{document.removeEventListener("fullscreenchange",r),document.removeEventListener("webkitfullscreenchange",r),document.removeEventListener("mozfullscreenchange",r),document.removeEventListener("MSFullscreenChange",r)}),{isFullscreen:t,toggle:a}}const Pb={name:"lwTable",props:{refName:{type:String,default:"multipleTableRef"},tableName:{type:String,default:""},isRadio:{type:Boolean,default:!1},bordered:{type:Boolean,default:!0},stripe:{type:Boolean,default:!1},summaryMethod:{type:Function,default:()=>[]},rowKey:{type:String,default:"id"},defaultSelectData:{type:Array,default:()=>[]},searchParams:{type:Object,default:()=>({page:1,size:20})},selectStatus:{type:Function,default:()=>!0},pageSizes:{type:Array,default:()=>[10,20,30,40,50]},isShowPagination:{type:Boolean,default:!0},tableData:{type:Array,default:[]},totalCount:{type:Number,default:0},tableColumns:{type:Array,default:[]},hoverable:{type:Boolean,default:!0},defaultExpandAll:{type:Boolean,default:!1},isSetting:{type:Boolean,default:!1},saveKey:{type:String,default:""},orderPage:{type:Boolean,default:!1},tableSize:{type:String,default:"large"},loading:{type:Boolean,default:!1},rowSelection:{type:Boolean,default:!1},selectedKeys:{type:Array},selectDatas:{type:Array},hideTool:{type:Boolean,default:!0},virtualListProps:{type:Object,default:void 0},draggable:{type:Object},maxHeight:{type:String,default:"calc(100vh - 270px)"}},setup(t,n){const o=e.ref(),{proxy:{$bus:a,$tool:r}}=e.getCurrentInstance(),{isFullscreen:l,toggle:i}=vb(),s=e.reactive({dialogVisible:!1,tableSettingTitle:"选择字段",tableHeaderListAll:[],checkedList:[],defaultProps:{children:"children",label:"label"},num:0,endFixed:!1,filterHeader:[],tableSize:t.tableSize,checkedKeys:[],treeData:[],allCheck:!0,lastColumsFixed:!0,tableHeaders:[],fixNum:0}),d=()=>{let z=t.tableColumns;s.checkedKeys=[];let $=[];z.forEach((X,_e)=>{X.key||(X.key=r.getUUID()),(X.checked||X.checked==null)&&(s.checkedKeys.push(X.key),$.push(X))}),s.treeData=z,s.tableHeaders=$};e.onBeforeMount(async()=>{window.addEventListener("resize",()=>{let z=document.mozFullScreen||document.fullScreen||document.webkitIsFullScreen||document.webkitRequestFullScreen||document.mozRequestFullScreen||document.msFullscreenEnabled;z===void 0&&(z=!1),z==!1&&a.$emit("tableFullScreen",!1)})}),e.watch(()=>t.tableColumns,z=>{d()},{deep:!0,immediate:!0});const h=e.ref([]),f=e.ref([]),p=e.ref([]);e.watch(()=>t.tableData,z=>{const $=[...z,...p.value],X={},_e=$.reduce((pe,ke)=>(X[ke[t.rowKey]]||(X[ke[t.rowKey]]=pe.push(ke)),pe),[]);p.value=_e||[]},{deep:!0,immediate:!0}),e.watch(()=>t.selectedKeys,z=>{if(h.value=z,f.value=[],p.value.length&&z){const X=[...p.value.filter(ke=>z.includes(ke[t.rowKey])),...f.value],_e={},pe=X.reduce((ke,Se)=>(_e[Se[t.rowKey]]||(_e[Se[t.rowKey]]=ke.push(Se)),ke),[]);f.value=pe||[],n.emit("update:selectDatas",pe)}},{deep:!0,immediate:!0});const _=z=>{n.emit("draggable",z)},C=z=>{n.emit("multipleSelection",z)},k=z=>{n.emit("currentChange",z)},B=z=>{t.searchParams.size=z,n.emit("getTableData")},N=z=>{t.searchParams.page=z-1,n.emit("getTableData",t.searchParams.page)},q=()=>{N(1)},F=(z,$)=>{o.value.toggleRowSelection(z,$)},V=(z,$)=>{o.value.clearSelection()},j=(z,$,X)=>X!=="inner",U=z=>z.data.label.indexOf("Level three 3-1-1")===-1,L=()=>{s.tableSettingTitle="选择字段",s.dialogVisible=!0},R=()=>{if(s.checkedList.length===0){Message.error("选择字段不可以为空!");return}s.tableSettingTitle="排序",s.treeData=[];let z=0;JSON.parse(JSON.stringify(s.checkedList)).forEach((X,_e)=>{t.tableHeader.forEach(pe=>{if(X===pe.label){let ke={label:X,children:[],index:_e,fixed:pe.fixed?pe.fixed:""};s.treeData.push(ke),pe.fixed==="left"?z++:pe.fixed==="right"&&(s.endFixed=!0)}}),s.num=z})},H=()=>{s.tableSettingTitle="选择字段"},W=()=>{if(s.num>2&&s.endFixed||s.num>3&&!s.endFixed){Message.error("固定列最多只能选择3列!");return}s.tableHeaderList=[],s.treeData.forEach(($,X)=>{s.num>0&&s.num>X?$.fixed="left":s.endFixed&&X===s.treeData.length-1?$.fixed="right":$.fixed="",s.tableHeaderList.push($)}),s.dialogVisible=!1;let z={userId:1,json:s.tableHeaderList};localStorage.setItem("userTable",JSON.stringify(z))},J=z=>{let $=(process.env.NODE_ENV==="development"||process.env.NODE_ENV==="test")&&location.hostname!=="localhost"?location.origin+z:"http://dev.yihai.lianwei.com.cn"+z;window.open($,"_blank")},K=({column:z,prop:$,order:X})=>{t.searchParams.sortField=$==null?void 0:$.split(",")[0],t.searchParams.sortType=X;const _e={...t.searchParams};n.emit("getTableData",_e)},ee=z=>{n.emit("getHeader",z)},ie=z=>{s.tableSize=z},O=z=>{z?(s.tableHeaders=JSON.parse(JSON.stringify(t.tableColumns)),s.tableHeaders.forEach(($,X)=>{$.key||($.key=r.getUUID()),s.checkedKeys.push($.key)})):(s.tableHeaders=[],s.checkedKeys=[]),s.treeData.forEach($=>{$.checked=z})},E=()=>{let z=s.treeData.filter($=>s.checkedKeys.includes($.key));s.tableHeaders=z},m=()=>{a.$emit("tableFullScreen",!l.value),i()},A=()=>{let z=s.fixNum;z>0?s.tableHeaders.forEach(($,X)=>{X<z&&($.fixed="left",$.width=$.width??"120")}):s.tableHeaders.forEach($=>{$.fixed==="left"&&delete $.fixed})},T=z=>{o.value.selectAll(z),n.emit("update:selectedKeys",z?t.tableData.map($=>$.id):[])},qe=(z,$)=>{o.value.select(z,$);const X=[...t.selectedKeys];n.emit("update:selectedKeys",$?X.push(z):X.filter(_e=>_e!==z))},Y=z=>{n.emit("update:selectedKeys",z?t.tableData.map($=>$[t.rowKey]):[])},Te=(z,$,X)=>{n.emit("update:selectedKeys",z)},Q=(z,$,{property:X})=>{},ce=z=>{const $=JSON.parse(localStorage.getItem("userAuthInfo")),{menus:X,authorities:_e}=$;return z?Array.isArray(z)?z.some(pe=>[...X,..._e].includes(pe)):typeof z=="string"?[...X,..._e].includes(z):!1:!0},Ae=(z,$)=>z.filter(X=>(!(X!=null&&X.isShow)||X.isShow($))&&ce(X.auth));return{...e.toRefs(s),checkAuth:ce,filterOperations:Ae,refresh:q,dayjs:$e,handleChange:_,handleSelectionChange:C,handleCurrentChange:k,sizeChange:B,currentChange:N,multipleTable:o,allowDrop:j,allowDrag:U,tableSetting:L,next:R,prev:H,tableHeaderConfirm:W,toggleRowChange:F,clearTableSelection:V,download:J,sortChange:K,getHeader:ee,handleSelect:ie,checkAll:O,tableToggleFullScreen:m,isFullscreen:l,treeCheck:E,fixNumChange:A,setSelectAll:T,setSelect:qe,selectedKeysForm:h,selectGoodsDatas:f,selectAll:Y,select:Te,changeColWidth:Q}}},Lb={class:"baseTablePage-wrap"},Mb={style:{"max-width":"300px",display:"inline-block"}},Ub={key:0},jb={key:1},zb={key:1},Hb=["innerHTML","onClick"],Kb=["innerHTML"],Gb={key:2},Yb={key:3},$b={key:0},Wb={key:4},Jb={style:{"margin-bottom":"5px"}},Zb={key:5},Xb={key:6},Qb={key:7},ey=["src"],ty={key:8},ny={key:9},oy={key:10},ry=["onClick"],ay={key:1},ly=["onClick"],iy={key:11},sy={key:0,class:"pagination-block"},cy={class:"tool-block"},dy={class:"dropdown-trigger"},uy={class:"fix-num"};function hy(t,n,o,a,r,l){const i=e.resolveComponent("el-table-column"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("el-tooltip"),h=e.resolveComponent("el-tag"),f=e.resolveComponent("el-button"),p=e.resolveComponent("el-icon-more-filled"),_=e.resolveComponent("el-dropdown-item"),C=e.resolveComponent("el-dropdown-menu"),k=e.resolveComponent("el-dropdown"),B=e.resolveComponent("el-image"),N=e.resolveComponent("el-option"),q=e.resolveComponent("el-select"),F=e.resolveComponent("el-switch"),V=e.resolveComponent("el-progress"),j=e.resolveComponent("el-table"),U=e.resolveComponent("el-icon-refresh"),L=e.resolveComponent("el-icon-set-up"),R=e.resolveComponent("el-icon-setting"),H=e.resolveComponent("el-checkbox"),W=e.resolveComponent("el-checkbox-group"),J=e.resolveComponent("el-input-number"),K=e.resolveComponent("el-popover"),ee=e.resolveComponent("el-icon-full-screen"),ie=e.resolveComponent("el-pagination"),O=e.resolveDirective("loading");return e.openBlock(),e.createElementBlock("div",Lb,[e.withDirectives((e.openBlock(),e.createBlock(j,{ref:"multipleTable","column-resizable":"",columns:t.tableHeaders,stripe:t.stripe,data:t.tableData,"row-key":t.rowKey,hoverable:t.hoverable,"default-expand-all-rows":t.defaultExpandAll,size:t.tableSize,"highlight-current-row":"","max-height":t.maxHeight,"scrollbar-always-on":"",scroll:{x:"100%",y:"100%"},"virtual-list-props":t.virtualListProps,onCurrentChange:t.handleCurrentChange,onSelectionChange:t.handleSelectionChange},{default:e.withCtx(()=>[t.rowSelection?(e.openBlock(),e.createBlock(i,{key:0,fixed:"left",type:"selection",width:"55"})):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.tableHeaders,E=>(e.openBlock(),e.createBlock(i,{label:E.title,prop:E.dataIndex,width:E.width,"min-width":E.minWidth,align:E.align??"center",fixed:E.fixed,sortable:E.sortable,"show-overflow-tooltip":E.tooltip,key:E},{header:e.withCtx(({column:m,$index:A})=>[E!=null&&E.header?e.renderSlot(t.$slots,E.header,{key:1,scope:{column:m,$index:A,t:E}},()=>[e.createVNode(h,{type:"danger"},{default:e.withCtx(()=>[e.createTextVNode(" ["+e.toDisplayString(t.item.header)+"]没有这个自定义表头 ",1)]),_:1})],!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(E.title)+" ",1),E.tips?(e.openBlock(),e.createBlock(d,{key:0},{content:e.withCtx(()=>[e.createElementVNode("span",Mb,e.toDisplayString(E.tips),1)]),default:e.withCtx(()=>[e.createVNode(s,null,{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(E.icon||"el-icon-question-filled")))]),_:2},1024)]),_:2},1024)):e.createCommentVNode("",!0)],64))]),default:e.withCtx(m=>[E!=null&&E.operation?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[t.filterOperations(E.operation,m.row).length<=3?(e.openBlock(),e.createElementBlock("div",Ub,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.filterOperations(E.operation,m.row),A=>(e.openBlock(),e.createElementBlock("span",{key:A},[A.icon?(e.openBlock(),e.createBlock(d,{key:0,content:A.label,placement:"top"},{default:e.withCtx(()=>[e.createVNode(f,{type:"primary",size:"small",onClick:T=>A.clickFun(m.row,m.$index,t.tableData),disabled:A.disabled?A.disabled(m.row):!1,icon:A.icon,circle:""},null,8,["onClick","disabled","icon"])]),_:2},1032,["content"])):(e.openBlock(),e.createBlock(f,{key:1,type:"primary",text:"",size:"small",onClick:T=>A.clickFun(m.row,m.$index,t.tableData),disabled:A.disabled?A.disabled(m.row):!1},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(A.label),1)]),_:2},1032,["onClick","disabled"]))]))),128))])):(e.openBlock(),e.createElementBlock("div",jb,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.filterOperations(E.operation,m.row).slice(0,2),A=>(e.openBlock(),e.createElementBlock("span",{key:A},[A.icon?(e.openBlock(),e.createBlock(d,{key:0,content:A.label,placement:"top"},{default:e.withCtx(()=>[e.createVNode(f,{type:"primary",size:"small",onClick:T=>A.clickFun(m.row,m.$index,t.tableData),disabled:A.disabled?A.disabled(m.row):!1,icon:A.icon,circle:""},null,8,["onClick","disabled","icon"])]),_:2},1032,["content"])):(e.openBlock(),e.createBlock(f,{key:1,type:"primary",text:"",size:"small",onClick:T=>A.clickFun(m.row,m.$index,t.tableData),disabled:A.disabled?A.disabled(m.row):!1},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(A.label),1)]),_:2},1032,["onClick","disabled"]))]))),128)),e.createVNode(k,null,{dropdown:e.withCtx(()=>[e.createVNode(C,null,{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.filterOperations(E.operation,m.row).slice(2),A=>(e.openBlock(),e.createBlock(_,{key:A,onClick:T=>A.clickFun(m.row,m.$index,t.tableData)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(A.label),1)]),_:2},1032,["onClick"]))),128))]),_:2},1024)]),default:e.withCtx(()=>[e.createVNode(f,{size:"small",type:"primary",link:""},{default:e.withCtx(()=>[e.createVNode(s,{class:"more-btn",size:"16"},{default:e.withCtx(()=>[e.createVNode(p)]),_:1})]),_:1})]),_:2},1024)]))],64)):E.eleRender?(e.openBlock(),e.createElementBlock("div",zb,[E!=null&&E.clickFun?(e.openBlock(),e.createElementBlock("span",{key:0,innerHTML:E.eleRender(m.row,m.$index),onClick:A=>E.clickFun(m.row,m.$index,t.tableData)},null,8,Hb)):(e.openBlock(),e.createElementBlock("span",{key:1,innerHTML:E.eleRender(m.row,m.$index)},null,8,Kb))])):E.type==="img"?(e.openBlock(),e.createElementBlock("div",Gb,[e.createVNode(B,{style:{height:"28px"},fit:"cover","max-scale":7,"min-scale":.2,"z-index":99,"preview-teleported":!0,previewSrcList:[m.row[E.dataIndex]],src:m.row[E.dataIndex]?m.row[E.dataIndex]:"/static/images/empty.jpg"},null,8,["previewSrcList","src"])])):!E.switch&&E.options&&E.options.length>0?(e.openBlock(),e.createElementBlock("div",Yb,[m.row.isEdit&&E.canEdit?(e.openBlock(),e.createBlock(q,{key:0,class:"select-select number","value-key":E.editValue||"code",modelValue:m.row[E.editSource],"onUpdate:modelValue":A=>m.row[E.editSource]=A,placeholder:"","allow-clear":"","allow-search":"","filter-option":"",onChange:A=>{E.callback(A,m.row)}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.options,A=>(e.openBlock(),e.createBlock(N,{value:A,key:A},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(E.editValue?A[E.editValue]:A.name),1)]),_:2},1032,["value"]))),128))]),_:2},1032,["value-key","modelValue","onUpdate:modelValue","onChange"])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(E.options,(A,T)=>(e.openBlock(),e.createElementBlock("span",{key:A+T},[m.row[E.dataIndex]==A[E.editValue||"code"]?(e.openBlock(),e.createElementBlock("span",$b,[A.statusColor?(e.openBlock(),e.createElementBlock("span",{key:0,style:e.normalizeStyle(`background-color: ${A.statusColor}; border-radius: 100%; padding: 4px; display: inline-block; margin-right: 5px;`)},null,4)):e.createCommentVNode("",!0),e.createTextVNode(e.toDisplayString(E.editValue?A[E.editValue]:A.name),1)])):e.createCommentVNode("",!0)]))),128))])):E.type==="startToEnd"?(e.openBlock(),e.createElementBlock("div",Wb,[e.createElementVNode("div",Jb,[n[3]||(n[3]=e.createElementVNode("span",{class:"start-span"},"起",-1)),e.createTextVNode(" "+e.toDisplayString(m.row[E.dataIndexList[0]]?t.dayjs(m.row[E.dataIndexList[0]]).format("YYYY-MM-DD HH:mm:ss"):"--"),1)]),e.createElementVNode("div",null,[n[4]||(n[4]=e.createElementVNode("span",{class:"end-span"},"止",-1)),e.createTextVNode(" "+e.toDisplayString(m.row[E.dataIndexList[1]]?t.dayjs(m.row[E.dataIndexList[1]]).format("YYYY-MM-DD HH:mm:ss"):"--"),1)])])):E.dataType?(e.openBlock(),e.createElementBlock("div",Zb,e.toDisplayString(t.$fermitTime(m.row[E.dataIndex])),1)):E.switch?(e.openBlock(),e.createElementBlock("div",Xb,[e.createVNode(F,{"inline-prompt":E.isShowMessage,"active-text":E.isShowMessage?E.activeText:"","inactive-text":E.isShowMessage?E.inactiveText:"",style:{"--el-switch-on-color":"var(--el-color-primary)","--el-switch-off-color":"#c6c6c6"},modelValue:m.row[E.dataIndex],"onUpdate:modelValue":A=>m.row[E.dataIndex]=A,"active-value":E.activeValue??!0,"inactive-value":E.inactiveValue??!1,disabled:E.disabled?E.disabled(m.row):!1,onChange:A=>{E.clickFun(A,m.row)}},null,8,["inline-prompt","active-text","inactive-text","modelValue","onUpdate:modelValue","active-value","inactive-value","disabled","onChange"])])):E.isVideo?(e.openBlock(),e.createElementBlock("div",Qb,[e.createElementVNode("video",{width:"40",src:m.row[E.dataIndex],style:{margin:"5px 0"}},null,8,ey)])):E.pictureCard?(e.openBlock(),e.createElementBlock("div",ty,[e.createVNode(B,{width:"40",src:m.row[E.dataIndex],style:{margin:"5px 0"}},null,8,["src"])])):E.arrayList?(e.openBlock(),e.createElementBlock("div",ny,[e.createElementVNode("span",null,e.toDisplayString(m.row[E.dataIndex]!==null&&m.row[E.dataIndex].length>0?m.row[E.dataIndex].toString():""),1)])):E.skip?(e.openBlock(),e.createElementBlock("span",oy,[m.row[E.dataIndex]&&m.row[E.dataIndex].toString().split(",").length>1?(e.openBlock(),e.createBlock(d,{key:0},{content:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.row[E.dataIndex].split(","),(A,T)=>(e.openBlock(),e.createElementBlock("div",{key:T,style:e.normalizeStyle(`color: ${t.theme}; cursor: pointer`),onClick:qe=>E.clickFun?E.clickFun(A,m.row,m.$index):()=>{}},e.toDisplayString(A),13,ry))),128))]),default:e.withCtx(()=>[e.createElementVNode("span",{style:e.normalizeStyle(`color: ${t.theme};cursor: pointer;width: 100%;display: inline-block;white-space: nowrap;overflow: hidden;text-overflow: ellipsis;`)},e.toDisplayString(m.row[E.dataIndex]?m.row[E.dataIndex]:""),5)]),_:2},1024)):(e.openBlock(),e.createElementBlock("span",ay,[e.createElementVNode("span",{style:{color:"var(--el-color-primary)",cursor:"pointer","text-decoration":"underline"},onClick:A=>E.clickFun?E.clickFun(m.row[E.dataIndex],m.row,m.$index):()=>{}},e.toDisplayString(m.row[E.dataIndex]||m.row[E.dataIndex]===0?m.row[E.dataIndex]:""),9,ly)]))])):E.isProgress?(e.openBlock(),e.createElementBlock("span",iy,[e.createVNode(V,{percentage:m.row[E.dataIndex],color:"var(--el-color-primary)"},null,8,["percentage"])])):E.slot?e.renderSlot(t.$slots,E.component,{key:12,row:m.row},()=>[e.createVNode(h,{type:"danger"},{default:e.withCtx(()=>[e.createTextVNode("["+e.toDisplayString(E.component)+"] 没有这个默认组件也未自定义插槽内容",1)]),_:2},1024)],!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:13},[e.createTextVNode(e.toDisplayString(m.row[E.dataIndex]?m.row[E.dataIndex]:m.row[E.dataIndex]===0?"0":""),1)],64))]),_:2},1032,["label","prop","width","min-width","align","fixed","sortable","show-overflow-tooltip"]))),128))]),_:3},8,["columns","stripe","data","row-key","hoverable","default-expand-all-rows","size","max-height","virtual-list-props","onCurrentChange","onSelectionChange"])),[[O,t.loading]]),t.isShowPagination?(e.openBlock(),e.createElementBlock("div",sy,[e.createElementVNode("div",cy,[t.hideTool?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(d,{content:t.$t("btn.refresh")},{default:e.withCtx(()=>[e.createVNode(s,{size:"20",onClick:t.refresh},{default:e.withCtx(()=>[e.createVNode(U)]),_:1},8,["onClick"])]),_:1},8,["content"]),e.createVNode(k,{onCommand:t.handleSelect},{dropdown:e.withCtx(()=>[e.createVNode(C,null,{default:e.withCtx(()=>[e.createVNode(_,{command:"small"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("lwTable.tools.lineHeight.mini")),1)]),_:1}),e.createVNode(_,{command:"medium"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("lwTable.tools.lineHeight.small")),1)]),_:1}),e.createVNode(_,{command:"large"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("lwTable.tools.lineHeight.medium")),1)]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createElementVNode("span",dy,[e.createVNode(d,{content:t.$t("lwTable.tools.lineHeightName")},{default:e.withCtx(()=>[e.createVNode(s,{size:"20"},{default:e.withCtx(()=>[e.createVNode(L)]),_:1})]),_:1},8,["content"])])]),_:1},8,["onCommand"]),e.createVNode(K,{placement:"top-start",title:t.$t("lwTable.tools.columnsSetting"),width:400,trigger:"hover"},{reference:e.withCtx(()=>[e.createVNode(s,{size:"20"},{default:e.withCtx(()=>[e.createVNode(R)]),_:1})]),default:e.withCtx(()=>[e.createVNode(H,{modelValue:t.allCheck,"onUpdate:modelValue":n[0]||(n[0]=E=>t.allCheck=E),onChange:t.checkAll},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("lwTable.tools.allCheck"))+","+e.toDisplayString(t.$t("lwTable.tools.hasChecked"))+e.toDisplayString(t.checkedKeys.length)+"/"+e.toDisplayString(t.treeData.length),1)]),_:1},8,["modelValue","onChange"]),e.createVNode(W,{modelValue:t.checkedKeys,"onUpdate:modelValue":n[1]||(n[1]=E=>t.checkedKeys=E),onChange:t.treeCheck},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.treeData,E=>(e.openBlock(),e.createBlock(H,{key:E.key,label:E.title,value:E.key},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(E.title),1)]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue","onChange"]),e.createElementVNode("div",uy,[e.createTextVNode(e.toDisplayString(t.$t("lwTable.tools.table_before"))+" ",1),e.createVNode(J,{modelValue:t.fixNum,"onUpdate:modelValue":n[2]||(n[2]=E=>t.fixNum=E),onChange:t.fixNumChange,min:0,max:10,size:"small"},null,8,["modelValue","onChange"]),e.createTextVNode(" "+e.toDisplayString(t.$t("lwTable.tools.column_fixed")),1)])]),_:1},8,["title"]),e.createVNode(d,{content:t.isFullscreen?t.$t("lwTable.tools.cancel"):t.$t("lwTable.tools.fullScreen")},{default:e.withCtx(()=>[t.isFullscreen?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(s,{key:0,class:"icon-fullscreen",onClick:t.tableToggleFullScreen},{default:e.withCtx(()=>[e.createVNode(ee)]),_:1},8,["onClick"])),t.isFullscreen?(e.openBlock(),e.createBlock(s,{key:1,class:"icon-fullscreen-exit",onClick:t.tableToggleFullScreen},{default:e.withCtx(()=>[e.createVNode(ee)]),_:1},8,["onClick"])):e.createCommentVNode("",!0)]),_:1},8,["content"])],64))]),e.createVNode(ie,{background:"",size:"small","current-page":parseFloat(t.searchParams.page).toString()=="NaN"?1:t.searchParams.page,"page-size":t.searchParams.size?t.searchParams.size:10,layout:"total, prev, pager, next, sizes, jumper",total:t.totalCount,"page-sizes":t.pageSizes,onSizeChange:t.sizeChange,onCurrentChange:t.currentChange},null,8,["current-page","page-size","total","page-sizes","onSizeChange","onCurrentChange"])])):e.createCommentVNode("",!0)])}const Qi=le(Pb,[["render",hy],["__scopeId","data-v-8fc2fdd6"]]),fy={name:"lwUpload",props:{modelValue:{type:[String,Array,Boolean,Object],default:""},height:{type:Number,default:148},width:{type:Number,default:148},title:{type:String,default:""},tip:{type:String,default:""},icon:{type:String,default:"el-icon-plus"},action:{type:String,default:()=>{}},apiObj:{type:[Object,Function],default:()=>{}},name:{type:String,default:"file"},data:{type:Object,default:()=>{}},accept:{type:String,default:"image/gif, image/jpeg, image/png"},maxSize:{type:Number,default:10},limit:{type:Number,default:1},autoUpload:{type:Boolean,default:!0},showFileList:{type:Boolean,default:!1},multiple:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},round:{type:Boolean,default:!1},onSuccess:{type:Function,default:()=>!0},returnFile:{type:[Object,String],default:{url:"url",code:"code",fileName:"fileName",src:"src",type:"type",name:"name",size:"size",tempCropperFile:"tempCropperFile"}},parseData:{type:Function,default:t=>({code:200,fileName:t.fileName,src:t.previewInfo.url,msg:t.message})}},data(){return{value:"",file:null,fileList:[],cropperDialogVisible:!1,cropperFile:null}},computed:{style(){return{width:this.width+"px",height:this.height+"px"}}},watch:{modelValue(t){this.value=t,this.newFile(t)},value(t){this.$emit("update:modelValue",t)}},mounted(){this.value=this.modelValue,this.newFile(this.modelValue)},methods:{newFile(t){this.multiple?this.fileList=t||[]:this.fileList=t?[t]:[],t?this.file={status:"success",url:t}:this.file=null},handleRemove(t){this.fileList.splice(t,1),this.clearFiles()},clearFiles(){var t;URL.revokeObjectURL((t=this.file)==null?void 0:t.tempFile),this.multiple?this.value=this.fileList:this.value="",this.file=null,this.$nextTick(()=>{var n;(n=this.$refs.uploader)==null||n.clearFiles()})},change(t,n){if(n.length>1&&n.splice(0,1),t.status=="ready")return this.accept.replace(/\s/g,"").split(",").includes(t.raw.type)?(this.cropperFile=t,this.cropperFile.tempCropperFile=URL.createObjectURL(t.raw),this.cropperDialogVisible=!0,!1):(this.$notify.warning({title:"上传文件警告",message:"选择的文件非图像类文件"}),!1);this.file=t,t.status=="ready"&&(t.tempFile=URL.createObjectURL(t.raw))},before(t){if(!this.accept.replace(/\s/g,"").split(",").includes(t.type))return this.$notify.warning({title:"上传文件错误",message:"选择的文件类型不对"}),this.clearFiles(),!1;if(!(t.size/1024/1024<this.maxSize))return this.$message.warning(`上传文件大小不能超过 ${this.maxSize}MB!`),this.clearFiles(),!1},handleExceed(t){const n=t[0];n.uid=this.$tool.getUUID("file, 16"),this.$refs.uploader.handleStart(n)},success(t,n){n.type=n.raw.type,URL.revokeObjectURL(n.tempFile),delete n.tempFile,delete n.percentage,delete n.raw,delete n.response,delete n.uid;var o=this.onSuccess(t,n);if(o!=null&&o==!1)return this.$nextTick(()=>{this.file=null,this.value=""}),!1;var a=this.parseData(t);n.url=a.src;let r={...a,...n};if(typeof this.returnFile=="object"){let l=Object.entries(this.returnFile).reduce((i,[s,d])=>(r[s]!==void 0&&(i[d]=r[s]),i),{});this.fileList.push(l)}else this.fileList.push(r[this.returnFile]);this.multiple?this.value=this.fileList:this.value=n.url},error(t){this.$nextTick(()=>{delete this.file.percentage}),this.$notify.error({title:"上传文件未成功",message:t})},request(t){let n=this.apiObj||this.$api.auth.upload;const o=new FormData;o.append(t.filename,t.file),o.append("fileName",t.file.name);for(const a in t.data)o.append(a,t.data[a]);n(o,{onUploadProgress:a=>{var r;(r=this.file)!=null&&r.percentage&&(this.file.percentage=parseInt(a.loaded/a.total*100|0,10))}}).then(a=>{var r=this.parseData(a);r.code==200?t.onSuccess(a):t.onError(r.msg||"未知错误")}).catch(a=>{t.onError(a)})},getShowValue(t){return this.multiple&&typeof this.returnFile=="object"?t[this.returnFile[Object.keys(this.returnFile)[0]]]:t}}},py={class:"view-img-list"},my=["src"],gy={key:2,class:"lw-upload__img-actions"},by=["onClick"],yy={class:"el-upload--picture-card"},_y={class:"file-empty"},ky={key:0},wy={key:0,class:"el-upload__tip"};function Vy(t,n,o,a,r,l){const i=e.resolveComponent("el-image"),s=e.resolveComponent("el-icon-delete"),d=e.resolveComponent("el-icon"),h=e.resolveComponent("el-progress"),f=e.resolveComponent("el-upload");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["lw-upload",{"lw-upload-round":o.round}])},[e.createElementVNode("div",py,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.fileList,(p,_)=>(e.openBlock(),e.createElementBlock("div",{class:"lw-upload__img",style:e.normalizeStyle(l.style)},[o.accept.indexOf("image")>-1?(e.openBlock(),e.createBlock(i,{key:0,class:"image",src:l.getShowValue(p),"preview-src-list":r.fileList,fit:"cover","hide-on-click-modal":"","append-to-body":"","z-index":9999},{placeholder:e.withCtx(()=>n[0]||(n[0]=[e.createElementVNode("div",{class:"lw-upload__img-slot"}," Loading... ",-1)])),_:2},1032,["src","preview-src-list"])):e.createCommentVNode("",!0),o.accept.indexOf("video")>-1?(e.openBlock(),e.createElementBlock("video",{key:1,src:l.getShowValue(p),controls:""},null,8,my)):e.createCommentVNode("",!0),o.disabled?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",gy,[e.createElementVNode("span",{class:"del",onClick:C=>l.handleRemove(_)},[e.createVNode(d,null,{default:e.withCtx(()=>[e.createVNode(s)]),_:1})],8,by)]))],4))),256)),r.fileList.length<o.limit?(e.openBlock(),e.createBlock(f,{key:0,class:"uploader",style:e.normalizeStyle(l.style),ref:"uploader","auto-upload":o.autoUpload,disabled:o.disabled,"show-file-list":o.showFileList,action:o.action,name:o.name,data:o.data,accept:o.accept,limit:o.limit,"http-request":l.request,"on-change":l.change,"before-upload":l.before,"on-success":l.success,"on-error":l.error,"on-exceed":l.handleExceed},{default:e.withCtx(()=>[e.renderSlot(t.$slots,"default",{},()=>{var p;return[e.createElementVNode("div",yy,[e.createElementVNode("div",_y,[e.createVNode(d,null,{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.icon)))]),_:1}),o.title?(e.openBlock(),e.createElementBlock("h4",ky,e.toDisplayString(o.title),1)):e.createCommentVNode("",!0)]),(p=r.file)!=null&&p.percentage?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(l.style),class:"lw-upload__progress"},[e.createVNode(h,{percentage:r.file.percentage,"text-inside":!0,"stroke-width":16},null,8,["percentage"])],4)):e.createCommentVNode("",!0)])]},!0)]),_:3},8,["style","auto-upload","disabled","show-file-list","action","name","data","accept","limit","http-request","on-change","before-upload","on-success","on-error","on-exceed"])):e.createCommentVNode("",!0)]),o.tip?(e.openBlock(),e.createElementBlock("div",wy,e.toDisplayString(o.tip),1)):e.createCommentVNode("",!0)],2)}const St=le(fy,[["render",Vy],["__scopeId","data-v-e6bbc2dd"]]),Cy={components:{lwUpload:St},props:{modelValue:{type:Object,default:()=>{}},config:{type:Object,default:()=>{}},loading:{type:Boolean,default:!1},isView:{type:Boolean,default:!1}},data(){return{form:{},tagValue:"",tagVisible:!1,renderLoading:!1}},watch:{modelValue(t,n){this.hasConfig&&this.hasValue&&this.deepMerge(this.form,JSON.parse(JSON.stringify(t)))},config(){this.render()},form:{handler(t){this.$emit("update:modelValue",t)},deep:!0}},computed:{hasConfig(){return Object.keys(this.config).length>0},hasValue(){return Object.keys(this.modelValue).length>0}},mounted(){this.hasConfig&&this.render()},methods:{render(){this.form={},this.config.formItems.forEach(t=>{var n,o,a;if(t.component=="checkbox"||t.component=="upload")if(t.name){const r={};t==null||t.options.items.forEach(l=>{r[l.name]=l.value}),this.form[t.name]=r}else(n=t==null?void 0:t.options)!=null&&n.items&&(t==null||t.options.items.forEach(r=>{this.form[r.name]=r.value}));else(o=t==null?void 0:t.options)!=null&&o.name?(this.form[t.name]||(this.form[t.name]={}),this.form[t.name][(a=t==null?void 0:t.options)==null?void 0:a.name]=t.value):t.name&&(this.form[t.name]=t.value)}),this.hasValue&&(this.form=this.deepMerge(this.form,this.modelValue))},deepMerge(t,n){for(let o in n)if(n.hasOwnProperty(o)){const a=t[o]!==null&&t[o]!==void 0,r=n[o]!==null&&n[o]!==void 0;a&&typeof t[o]=="object"&&!Array.isArray(t[o])&&r&&typeof n[o]=="object"&&!Array.isArray(n[o])?t[o]=this.deepMerge(t[o],n[o]):r?t[o]=n[o]:r||delete t[o]}return t},hideHandle(t){return typeof t.hideHandle=="string"?new Function("form",`return ${t==null?void 0:t.hideHandle.replace(/\$/g,"form")}`)(this.form):typeof t.hideHandle=="boolean"?t.hideHandle:!1},rulesHandle(t){if(t.requiredHandle)try{const o=new Function("form",`return ${t.requiredHandle.replace(/\$/g,"form")}`)(this.form),a=t.rules.find(r=>"required"in r);a&&(a.required=o)}catch(n){console.error("Error requiredHandle function:",n)}return t.rules},validate(t,n){return this.$refs.form.validate(t,n)},scrollToField(t){return this.$refs.form.scrollToField(t)},resetFields(){return this.$refs.form.resetFields()},submit(){this.$emit("submit",this.form)},tagClose(t,n){n.splice(n.indexOf(t),1)},tagInputConfirm(t,n){var o;this.tagValue&&((o=t==null?void 0:t.options)!=null&&o.name?(n[t.name]=n[t.name]||{},n[t.name][t==null?void 0:t.options.name]=n[t.name][t==null?void 0:t.options.name]||[],n[t.name][t==null?void 0:t.options.name].push(this.tagValue)):(n[t.name]=n[t.name]||[],n[t.name].push(this.tagValue))),this.tagVisible=!1,this.tagValue=""},getPropName(t){var n;return t.component=="checkbox"||t.component=="upload"?t.name?`${t.name}.${t==null?void 0:t.options.items[0].name}`:t==null?void 0:t.options.items[0].name:(n=t==null?void 0:t.options)!=null&&n.name?`${t.name}.${t==null?void 0:t.options.name}`:t.name}}},xy={key:0,class:"title-name"},Ny={key:0,style:{"margin-right":"5px"}},By={key:1,style:{"margin-right":"5px"}},Sy={key:13,class:"tags-list"},Ey={key:15,class:"el-form-item-msg"};function Ty(t,n,o,a,r,l){const i=e.resolveComponent("el-skeleton"),s=e.resolveComponent("el-icon-question-filled"),d=e.resolveComponent("el-icon"),h=e.resolveComponent("el-tooltip"),f=e.resolveComponent("el-input"),p=e.resolveComponent("lw-upload"),_=e.resolveComponent("el-checkbox"),C=e.resolveComponent("el-checkbox-group"),k=e.resolveComponent("el-switch"),B=e.resolveComponent("el-option"),N=e.resolveComponent("el-select"),q=e.resolveComponent("el-cascader"),F=e.resolveComponent("el-date-picker"),V=e.resolveComponent("el-input-number"),j=e.resolveComponent("el-radio"),U=e.resolveComponent("el-radio-group"),L=e.resolveComponent("el-color-picker"),R=e.resolveComponent("el-rate"),H=e.resolveComponent("el-slider"),W=e.resolveComponent("el-tag"),J=e.resolveComponent("el-button"),K=e.resolveComponent("el-form-item"),ee=e.resolveComponent("el-col"),ie=e.resolveComponent("el-row"),O=e.resolveComponent("el-form"),E=e.resolveDirective("loading");return r.renderLoading||Object.keys(r.form).length==0?(e.openBlock(),e.createBlock(i,{key:0,animated:""})):e.withDirectives((e.openBlock(),e.createBlock(O,{key:1,ref:"form",model:r.form,"label-width":o.config.labelWidth,"label-position":t.$i18n.locale=="en-us"?"top":o.config.labelPosition,disabled:o.isView,"element-loading-text":"Loading..."},{default:e.withCtx(()=>[e.createVNode(ie,{gutter:15},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.config.formItems,(m,A)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:A},[l.hideHandle(m)?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(ee,{key:0,span:m.span||24},{default:e.withCtx(()=>[m.component=="divider"?(e.openBlock(),e.createElementBlock("div",xy,[e.createTextVNode(e.toDisplayString(m.label)+" ",1),m.tips?(e.openBlock(),e.createBlock(h,{key:0,content:m.tips},{default:e.withCtx(()=>[e.createVNode(d,null,{default:e.withCtx(()=>[e.createVNode(s)]),_:1})]),_:2},1032,["content"])):e.createCommentVNode("",!0)])):(e.openBlock(),e.createBlock(K,{key:1,prop:l.getPropName(m),rules:l.rulesHandle(m)},{label:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(m.label)+" ",1),m.tips?(e.openBlock(),e.createBlock(h,{key:0,content:m.tips},{default:e.withCtx(()=>[e.createVNode(d,null,{default:e.withCtx(()=>[e.createVNode(s)]),_:1})]),_:2},1032,["content"])):e.createCommentVNode("",!0)]),default:e.withCtx(()=>{var T,qe,Y,Te,Q,ce,Ae,z,$,X,_e,pe,ke,Se,xe,Ge,je,ae,P,te,Ne,Ie,dt,ve,Fe,we,me,v,Ye,Ze,Pe,Xe,Qe,ut,nt,b,c,u,g,y,w,x,S,I,M,Z,de,ne,be,fe,ue,ye,Re;return[m.component=="input"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[(T=m==null?void 0:m.options)!=null&&T.name?(e.openBlock(),e.createBlock(f,{key:0,modelValue:r.form[m.name][m==null?void 0:m.options.name],"onUpdate:modelValue":D=>r.form[m.name][m==null?void 0:m.options.name]=D,placeholder:(qe=m==null?void 0:m.options)==null?void 0:qe.placeholder,clearable:"",type:m==null?void 0:m.options.type,disabled:(Y=m==null?void 0:m.options)==null?void 0:Y.disabled,autocomplete:((Te=m==null?void 0:m.options)==null?void 0:Te.autocomplete)||"off",maxlength:m==null?void 0:m.options.maxlength,"show-word-limit":""},e.createSlots({_:2},[m!=null&&m.options.prepend?{name:"prepend",fn:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(m==null?void 0:m.options.prepend),1)]),key:"0"}:void 0,m!=null&&m.options.append?{name:"append",fn:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(m==null?void 0:m.options.append),1)]),key:"1"}:void 0]),1032,["modelValue","onUpdate:modelValue","placeholder","type","disabled","autocomplete","maxlength"])):(e.openBlock(),e.createBlock(f,{key:1,modelValue:r.form[m.name],"onUpdate:modelValue":D=>r.form[m.name]=D,placeholder:(Q=m==null?void 0:m.options)==null?void 0:Q.placeholder,clearable:"",type:m==null?void 0:m.options.type,disabled:(ce=m==null?void 0:m.options)==null?void 0:ce.disabled,maxlength:m==null?void 0:m.options.maxlength,"show-word-limit":""},e.createSlots({_:2},[m!=null&&m.options.prepend?{name:"prepend",fn:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(m==null?void 0:m.options.prepend),1)]),key:"0"}:void 0,m!=null&&m.options.append?{name:"append",fn:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(m==null?void 0:m.options.append),1)]),key:"1"}:void 0]),1032,["modelValue","onUpdate:modelValue","placeholder","type","disabled","maxlength"]))],64)):m.component=="upload"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(m==null?void 0:m.options.items,(D,Ce)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:Ce},[m.name?(e.openBlock(),e.createElementBlock("div",Ny,[e.createVNode(p,{modelValue:r.form[m.name][D.name],"onUpdate:modelValue":De=>r.form[m.name][D.name]=De,maxSize:D.maxSize,accept:D.accept,title:D.label,parseData:m.parseData,disabled:D==null?void 0:D.disabled,multiple:D==null?void 0:D.multiple,limit:D==null?void 0:D.limit,returnFile:D==null?void 0:D.returnFile,tip:D==null?void 0:D.tip,apiObj:m.apiObj},null,8,["modelValue","onUpdate:modelValue","maxSize","accept","title","parseData","disabled","multiple","limit","returnFile","tip","apiObj"])])):(e.openBlock(),e.createElementBlock("div",By,[e.createVNode(p,{modelValue:r.form[D.name],"onUpdate:modelValue":De=>r.form[D.name]=De,maxSize:D.maxSize,accept:D.accept,title:D.label,parseData:m.parseData,disabled:D==null?void 0:D.disabled,multiple:D==null?void 0:D.multiple,limit:D==null?void 0:D.limit,returnFile:D==null?void 0:D.returnFile,tip:D==null?void 0:D.tip,apiObj:m.apiObj},null,8,["modelValue","onUpdate:modelValue","maxSize","accept","title","parseData","disabled","multiple","limit","returnFile","tip","apiObj"])]))],64))),128)):m.component=="checkbox"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[m.name?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(m==null?void 0:m.options.items,(D,Ce)=>(e.openBlock(),e.createBlock(_,{modelValue:r.form[m.name][D.name],"onUpdate:modelValue":De=>r.form[m.name][D.name]=De,label:D.label,key:Ce},null,8,["modelValue","onUpdate:modelValue","label"]))),128)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(m==null?void 0:m.options.items,(D,Ce)=>(e.openBlock(),e.createBlock(_,{modelValue:r.form[D.name],"onUpdate:modelValue":De=>r.form[D.name]=De,label:D.label,key:Ce},null,8,["modelValue","onUpdate:modelValue","label"]))),128))],64)):m.component=="checkboxGroup"?(e.openBlock(),e.createBlock(C,{key:3,modelValue:r.form[m.name],"onUpdate:modelValue":D=>r.form[m.name]=D},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m==null?void 0:m.options.items,D=>(e.openBlock(),e.createBlock(_,{key:D.value,label:D.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(D.label),1)]),_:2},1032,["label"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue"])):m.component=="switch"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[(Ae=m==null?void 0:m.options)!=null&&Ae.name?(e.openBlock(),e.createBlock(k,{key:0,modelValue:r.form[m.name][m==null?void 0:m.options.name],"onUpdate:modelValue":D=>r.form[m.name][m==null?void 0:m.options.name]=D,"inline-prompt":"","active-text":(z=m==null?void 0:m.options)==null?void 0:z.activeText,"inactive-text":($=m==null?void 0:m.options)==null?void 0:$.inactiveText},null,8,["modelValue","onUpdate:modelValue","active-text","inactive-text"])):(e.openBlock(),e.createBlock(k,{key:1,modelValue:r.form[m.name],"onUpdate:modelValue":D=>r.form[m.name]=D,"inline-prompt":"","active-text":(X=m==null?void 0:m.options)==null?void 0:X.activeText,"inactive-text":(_e=m==null?void 0:m.options)==null?void 0:_e.inactiveText},null,8,["modelValue","onUpdate:modelValue","active-text","inactive-text"]))],64)):m.component=="select"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[(pe=m==null?void 0:m.options)!=null&&pe.name?(e.openBlock(),e.createBlock(N,{key:0,modelValue:r.form[m.name][m==null?void 0:m.options.name],"onUpdate:modelValue":D=>r.form[m.name][m==null?void 0:m.options.name]=D,multiple:(ke=m==null?void 0:m.options)==null?void 0:ke.multiple,"allow-create":(Se=m==null?void 0:m.options)==null?void 0:Se.allowCreate,"default-first-option":"",placeholder:((xe=m==null?void 0:m.options)==null?void 0:xe.placeholder)||"",clearable:(Ge=m==null?void 0:m.options)==null?void 0:Ge.clearable,disabled:(je=m==null?void 0:m.options)==null?void 0:je.disabled,filterable:"",style:{width:"100%"}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m==null?void 0:m.options.items,D=>(e.openBlock(),e.createBlock(B,{key:D.value,label:D.label,value:D.value},null,8,["label","value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","multiple","allow-create","placeholder","clearable","disabled"])):(e.openBlock(),e.createBlock(N,{key:1,modelValue:r.form[m.name],"onUpdate:modelValue":D=>r.form[m.name]=D,multiple:(ae=m==null?void 0:m.options)==null?void 0:ae.multiple,"allow-create":(P=m==null?void 0:m.options)==null?void 0:P.allowCreate,"default-first-option":"",placeholder:((te=m==null?void 0:m.options)==null?void 0:te.placeholder)||"",clearable:(Ne=m==null?void 0:m.options)==null?void 0:Ne.clearable,disabled:(Ie=m==null?void 0:m.options)==null?void 0:Ie.disabled,filterable:"",style:{width:"100%"}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m==null?void 0:m.options.items,D=>(e.openBlock(),e.createBlock(B,{key:D.value,label:D.label,value:D.value},null,8,["label","value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","multiple","allow-create","placeholder","clearable","disabled"]))],64)):m.component=="cascader"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:6},[(dt=m==null?void 0:m.options)!=null&&dt.name?(e.openBlock(),e.createBlock(q,{key:0,modelValue:r.form[m.name][m==null?void 0:m.options.name],"onUpdate:modelValue":D=>r.form[m.name][m==null?void 0:m.options.name]=D,style:{width:"100%"},options:m==null?void 0:m.options.items,clearable:""},null,8,["modelValue","onUpdate:modelValue","options"])):(e.openBlock(),e.createBlock(q,{key:1,modelValue:r.form[m.name],"onUpdate:modelValue":D=>r.form[m.name]=D,style:{width:"100%"},options:m==null?void 0:m.options.items,clearable:""},null,8,["modelValue","onUpdate:modelValue","options"]))],64)):m.component=="date"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:7},[(ve=m==null?void 0:m.options)!=null&&ve.name?(e.openBlock(),e.createBlock(F,{key:0,modelValue:r.form[m.name][m==null?void 0:m.options.name],"onUpdate:modelValue":D=>r.form[m.name][m==null?void 0:m.options.name]=D,style:{width:"100%"},type:m==null?void 0:m.options.type,"start-placeholder":m==null?void 0:m.options.startPlaceholder,"end-placeholder":m==null?void 0:m.options.endPlaceholder,shortcuts:m==null?void 0:m.options.shortcuts,"disabled-date":(Fe=m==null?void 0:m.options)==null?void 0:Fe.disabledDate,"default-time":m==null?void 0:m.options.defaultTime,disabled:(we=m==null?void 0:m.options)==null?void 0:we.disabled,"value-format":m==null?void 0:m.options.valueFormat,format:m==null?void 0:m.options.format,placeholder:(m==null?void 0:m.options.placeholder)||"请选择"},null,8,["modelValue","onUpdate:modelValue","type","start-placeholder","end-placeholder","shortcuts","disabled-date","default-time","disabled","value-format","format","placeholder"])):(e.openBlock(),e.createBlock(F,{key:1,modelValue:r.form[m.name],"onUpdate:modelValue":D=>r.form[m.name]=D,style:{width:"100%"},type:m==null?void 0:m.options.type,"start-placeholder":m==null?void 0:m.options.startPlaceholder,"end-placeholder":m==null?void 0:m.options.endPlaceholder,shortcuts:m==null?void 0:m.options.shortcuts,"disabled-date":(me=m==null?void 0:m.options)==null?void 0:me.disabledDate,"default-time":m==null?void 0:m.options.defaultTime,disabled:(v=m==null?void 0:m.options)==null?void 0:v.disabled,"value-format":m==null?void 0:m.options.valueFormat,format:m==null?void 0:m.options.format,placeholder:(m==null?void 0:m.options.placeholder)||"请选择"},null,8,["modelValue","onUpdate:modelValue","type","start-placeholder","end-placeholder","shortcuts","disabled-date","default-time","disabled","value-format","format","placeholder"]))],64)):m.component=="number"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:8},[(Ye=m==null?void 0:m.options)!=null&&Ye.name?(e.openBlock(),e.createBlock(V,{key:0,modelValue:r.form[m.name][m==null?void 0:m.options.name],"onUpdate:modelValue":D=>r.form[m.name][m==null?void 0:m.options.name]=D,disabled:(Ze=m==null?void 0:m.options)==null?void 0:Ze.disabled,min:(Pe=m==null?void 0:m.options)==null?void 0:Pe.min,max:(Xe=m==null?void 0:m.options)==null?void 0:Xe.max,step:((Qe=m==null?void 0:m.options)==null?void 0:Qe.step)||1,precision:(ut=m==null?void 0:m.options)==null?void 0:ut.precision,placeholder:((nt=m==null?void 0:m.options)==null?void 0:nt.placeholder)||"","controls-position":((b=m==null?void 0:m.options)==null?void 0:b.controlsPosition)||"right"},e.createSlots({_:2},[(c=m==null?void 0:m.options)!=null&&c.suffix?{name:"suffix",fn:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(m==null?void 0:m.options.suffix),1)]),key:"0"}:void 0]),1032,["modelValue","onUpdate:modelValue","disabled","min","max","step","precision","placeholder","controls-position"])):(e.openBlock(),e.createBlock(V,{key:1,modelValue:r.form[m.name],"onUpdate:modelValue":D=>r.form[m.name]=D,disabled:(u=m==null?void 0:m.options)==null?void 0:u.disabled,min:(g=m==null?void 0:m.options)==null?void 0:g.min,max:(y=m==null?void 0:m.options)==null?void 0:y.max,step:((w=m==null?void 0:m.options)==null?void 0:w.step)||1,precision:(x=m==null?void 0:m.options)==null?void 0:x.precision,placeholder:((S=m==null?void 0:m.options)==null?void 0:S.placeholder)||"","controls-position":((I=m==null?void 0:m.options)==null?void 0:I.controlsPosition)||"right"},e.createSlots({_:2},[(M=m==null?void 0:m.options)!=null&&M.suffix?{name:"suffix",fn:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(m==null?void 0:m.options.suffix),1)]),key:"0"}:void 0]),1032,["modelValue","onUpdate:modelValue","disabled","min","max","step","precision","placeholder","controls-position"]))],64)):m.component=="radio"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:9},[(Z=m==null?void 0:m.options)!=null&&Z.name?(e.openBlock(),e.createBlock(U,{key:0,modelValue:r.form[m.name][m==null?void 0:m.options.name],"onUpdate:modelValue":D=>r.form[m.name][m==null?void 0:m.options.name]=D,disabled:(de=m==null?void 0:m.options)==null?void 0:de.disabled},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m==null?void 0:m.options.items,D=>(e.openBlock(),e.createBlock(j,{key:D.value,value:D.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(D.label),1)]),_:2},1032,["value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","disabled"])):(e.openBlock(),e.createBlock(U,{key:1,modelValue:r.form[m.name],"onUpdate:modelValue":D=>r.form[m.name]=D,disabled:(ne=m==null?void 0:m.options)==null?void 0:ne.disabled},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m==null?void 0:m.options.items,D=>(e.openBlock(),e.createBlock(j,{key:D.value,value:D.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(D.label),1)]),_:2},1032,["value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","disabled"]))],64)):m.component=="color"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:10},[(be=m==null?void 0:m.options)!=null&&be.name?(e.openBlock(),e.createBlock(L,{key:0,modelValue:r.form[m.name][m==null?void 0:m.options.name],"onUpdate:modelValue":D=>r.form[m.name][m==null?void 0:m.options.name]=D},null,8,["modelValue","onUpdate:modelValue"])):(e.openBlock(),e.createBlock(L,{key:1,modelValue:r.form[m.name],"onUpdate:modelValue":D=>r.form[m.name]=D},null,8,["modelValue","onUpdate:modelValue"]))],64)):m.component=="rate"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:11},[(fe=m==null?void 0:m.options)!=null&&fe.name?(e.openBlock(),e.createBlock(R,{key:0,style:{"margin-top":"6px"},modelValue:r.form[m.name][m==null?void 0:m.options.name],"onUpdate:modelValue":D=>r.form[m.name][m==null?void 0:m.options.name]=D},null,8,["modelValue","onUpdate:modelValue"])):(e.openBlock(),e.createBlock(R,{key:1,style:{"margin-top":"6px"},modelValue:r.form[m.name],"onUpdate:modelValue":D=>r.form[m.name]=D},null,8,["modelValue","onUpdate:modelValue"]))],64)):m.component=="slider"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:12},[(ue=m==null?void 0:m.options)!=null&&ue.name?(e.openBlock(),e.createBlock(H,{key:0,modelValue:r.form[m.name][m==null?void 0:m.options.name],"onUpdate:modelValue":D=>r.form[m.name][m==null?void 0:m.options.name]=D,marks:m==null?void 0:m.options.marks},null,8,["modelValue","onUpdate:modelValue","marks"])):(e.openBlock(),e.createBlock(H,{key:1,modelValue:r.form[m.name],"onUpdate:modelValue":D=>r.form[m.name]=D,marks:m==null?void 0:m.options.marks},null,8,["modelValue","onUpdate:modelValue","marks"]))],64)):m.component=="tags"?(e.openBlock(),e.createElementBlock("div",Sy,[(ye=m==null?void 0:m.options)!=null&&ye.name?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(r.form[m.name][(Re=m==null?void 0:m.options)==null?void 0:Re.name],D=>(e.openBlock(),e.createBlock(W,{key:D,closable:"","disable-transitions":!1,onClose:Ce=>l.tagClose(D,r.form[m.name][m==null?void 0:m.options.name])},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(D),1)]),_:2},1032,["onClose"]))),128)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(r.form[m.name],D=>(e.openBlock(),e.createBlock(W,{key:D,closable:"","disable-transitions":!1,onClose:Ce=>l.tagClose(D,r.form[m.name])},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(D),1)]),_:2},1032,["onClose"]))),128)),r.tagVisible?(e.openBlock(),e.createBlock(f,{key:2,modelValue:r.tagValue,"onUpdate:modelValue":n[0]||(n[0]=D=>r.tagValue=D),class:"w-20",size:"small",onKeyup:e.withKeys(D=>l.tagInputConfirm(m,r.form),["enter"]),onBlur:D=>l.tagInputConfirm(m,r.form)},null,8,["modelValue","onKeyup","onBlur"])):(e.openBlock(),e.createBlock(J,{key:3,class:"button-new-tag",size:"small",onClick:n[1]||(n[1]=D=>r.tagVisible=!0)},{default:e.withCtx(()=>n[2]||(n[2]=[e.createTextVNode(" + 添加 ")])),_:1}))])):e.renderSlot(t.$slots,m.component,{key:14,itemCur:m,formCur:r.form},()=>[e.createVNode(W,{type:"danger"},{default:e.withCtx(()=>[e.createTextVNode("["+e.toDisplayString(m.component)+"] 没有这个默认组件也未自定义插槽内容",1)]),_:2},1024)],!0),m.message?(e.openBlock(),e.createElementBlock("div",Ey,e.toDisplayString(m.message),1)):e.createCommentVNode("",!0)]}),_:2},1032,["prop","rules"]))]),_:2},1032,["span"]))],64))),128)),e.createVNode(ee,{span:24},{default:e.withCtx(()=>[e.createVNode(K,null,{default:e.withCtx(()=>[e.renderSlot(t.$slots,"default",{},()=>[e.createVNode(J,{type:"primary",onClick:l.submit},{default:e.withCtx(()=>n[3]||(n[3]=[e.createTextVNode("提交")])),_:1},8,["onClick"])],!0)]),_:3})]),_:3})]),_:3})]),_:3},8,["model","label-width","label-position","disabled"])),[[E,o.loading]])}const es=le(Cy,[["render",Ty],["__scopeId","data-v-8b6b742d"]]),Iy={name:"FormItem",data(){return{tagVisible:{},dataForm:{},objItem:{},tagValue:""}},components:{lwUpload:St},props:{item:{type:Object,default:()=>{}},index:{type:Number,default:0},form:{type:Object,default:()=>{}}},watch:{item:{handler(t){this.objItem=t},immediate:!0,deep:!0},form:{handler(t){var n,o;this.item.component==="checkbox"||this.item.component==="upload"?(o=(n=this.objItem.options)==null?void 0:n.items)==null||o.forEach(a=>{a.value=this.flattenObject(this.form,a.name,a.value)}):this.objItem.value=this.flattenObject(this.form,this.item.name,this.objItem.value)},immediate:!0,deep:!0},objItem:{handler(t){var n,o;t.component==="checkbox"||t.component==="upload"?(o=(n=t.options)==null?void 0:n.items)==null||o.forEach(a=>{this.unflattenObject(this.form,a.name,a.value)}):this.unflattenObject(this.form,t.name,t.value)},deep:!0}},methods:{flattenObject(t,n,o=""){if(!n||!t)return!1;const a=n.split(".");let r=t;for(let l=0;l<a.length;l++)r[a[l]]===void 0&&(r[a[l]]=l===a.length-1?o:{}),r=r[a[l]];return r},unflattenObject(t,n,o){if(!n||!t)return!1;const a=n.split(".");a.forEach((r,l)=>{l===a.length-1?t[r]=o:((!t[r]||typeof t[r]!="object")&&(t[r]={}),t=t[r])})},tagClose(t,n){n.splice(n.indexOf(t),1)},tagInputConfirm(t,n){this.tagValue&&(n=n||[],n.push(this.tagValue)),this.tagVisible[t.name]=!1,this.tagValue=""},getPropName(t){return t.component=="checkbox"||t.component=="upload"?t==null?void 0:t.options.items[0].name:t.name},rulesHandle(t){if(t.requiredHandle)try{const o=new Function("form",`return ${t.requiredHandle.replace(/\$/g,"form")}`)(this.form),a=t.rules.find(r=>"required"in r);a&&(a.required=o)}catch(n){console.error("Error requiredHandle function:",n)}return t.rules}}},Dy=["id","data-index"],Fy={style:{"max-width":"300px",display:"inline-block"}},qy={key:14,class:"tags-list"},Ay={key:16,class:"el-form-item-msg"};function Ry(t,n,o,a,r,l){var ee;const i=e.resolveComponent("el-icon-question-filled"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("el-tooltip"),h=e.resolveComponent("el-input"),f=e.resolveComponent("lw-upload"),p=e.resolveComponent("el-checkbox"),_=e.resolveComponent("el-checkbox-group"),C=e.resolveComponent("el-switch"),k=e.resolveComponent("el-option"),B=e.resolveComponent("el-select"),N=e.resolveComponent("el-tree-select"),q=e.resolveComponent("el-cascader"),F=e.resolveComponent("el-date-picker"),V=e.resolveComponent("el-input-number"),j=e.resolveComponent("el-radio"),U=e.resolveComponent("el-radio-group"),L=e.resolveComponent("el-color-picker"),R=e.resolveComponent("el-rate"),H=e.resolveComponent("el-slider"),W=e.resolveComponent("el-tag"),J=e.resolveComponent("el-button"),K=e.resolveComponent("el-form-item");return o.item.component=="divider"?(e.openBlock(),e.createElementBlock("div",{key:0,class:"title-name title-name-divider",id:"divider-"+o.index,"data-index":o.index},[e.createTextVNode(e.toDisplayString(o.item.label)+" ",1),o.item.tips?(e.openBlock(),e.createBlock(d,{key:0},{content:e.withCtx(()=>[e.createElementVNode("span",Fy,e.toDisplayString(o.item.tips),1)]),default:e.withCtx(()=>[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i)]),_:1})]),_:1})):e.createCommentVNode("",!0)],8,Dy)):(e.openBlock(),e.createBlock(K,{key:1,class:e.normalizeClass({"form-item-name-null":!((ee=o.item)!=null&&ee.label)}),prop:l.getPropName(o.item),rules:l.rulesHandle(o.item)},{label:e.withCtx(()=>{var ie;return[e.createTextVNode(e.toDisplayString(o.item.label)+" ",1),o.item.tips?(e.openBlock(),e.createBlock(d,{key:0,"raw-content":(ie=o.item)==null?void 0:ie.rawContent,content:o.item.tips},{default:e.withCtx(()=>[e.createVNode(s,null,{default:e.withCtx(()=>[e.createVNode(i)]),_:1})]),_:1},8,["raw-content","content"])):e.createCommentVNode("",!0)]}),default:e.withCtx(()=>{var ie,O,E,m,A,T,qe,Y,Te,Q,ce,Ae,z,$,X,_e,pe,ke,Se,xe,Ge,je,ae,P,te,Ne,Ie,dt,ve,Fe,we,me,v,Ye,Ze,Pe,Xe,Qe,ut,nt,b,c,u,g,y,w,x,S,I,M,Z,de,ne,be,fe,ue,ye,Re,D,Ce,De,oe,bt,yt,ot,qt,Le,Vn,Bt,Up,jp,zp,Hp,Kp,Gp,Yp,$p,Wp,Jp,Zp,Xp,Qp,em,tm,nm,om,rm,am;return[o.item.component=="input"?(e.openBlock(),e.createBlock(h,{key:0,modelValue:r.objItem.value,"onUpdate:modelValue":n[0]||(n[0]=G=>r.objItem.value=G),placeholder:(O=(ie=o.item)==null?void 0:ie.options)==null?void 0:O.placeholder,clearable:"",type:(m=(E=o.item)==null?void 0:E.options)==null?void 0:m.type,disabled:(T=(A=o.item)==null?void 0:A.options)==null?void 0:T.disabled,autocomplete:((Y=(qe=o.item)==null?void 0:qe.options)==null?void 0:Y.autocomplete)||"off",maxlength:(Q=(Te=o.item)==null?void 0:Te.options)==null?void 0:Q.maxlength,"show-word-limit":""},e.createSlots({_:2},[(Ae=(ce=o.item)==null?void 0:ce.options)!=null&&Ae.prepend?{name:"prepend",fn:e.withCtx(()=>{var G;return[e.createTextVNode(e.toDisplayString((G=o.item)==null?void 0:G.options.prepend),1)]}),key:"0"}:void 0,($=(z=o.item)==null?void 0:z.options)!=null&&$.append?{name:"append",fn:e.withCtx(()=>{var G;return[e.createTextVNode(e.toDisplayString((G=o.item)==null?void 0:G.options.append),1)]}),key:"1"}:void 0]),1032,["modelValue","placeholder","type","disabled","autocomplete","maxlength"])):o.item.component=="upload"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList((X=r.objItem)==null?void 0:X.options.items,(G,Ee)=>(e.openBlock(),e.createBlock(f,{key:Ee,modelValue:G.value,"onUpdate:modelValue":ji=>G.value=ji,height:o.item.height,width:o.item.width,maxSize:G.maxSize,accept:G.accept,title:G.label,parseData:o.item.parseData,disabled:G==null?void 0:G.disabled,multiple:G==null?void 0:G.multiple,limit:G==null?void 0:G.limit,returnFile:G==null?void 0:G.returnFile,tip:G==null?void 0:G.tip,apiObj:o.item.apiObj},null,8,["modelValue","onUpdate:modelValue","height","width","maxSize","accept","title","parseData","disabled","multiple","limit","returnFile","tip","apiObj"]))),128)):o.item.component=="checkbox"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList((_e=r.objItem)==null?void 0:_e.options.items,(G,Ee)=>(e.openBlock(),e.createBlock(p,{modelValue:G.value,"onUpdate:modelValue":ji=>G.value=ji,label:G.label,key:Ee},null,8,["modelValue","onUpdate:modelValue","label"]))),128)):o.item.component=="checkboxGroup"?(e.openBlock(),e.createBlock(_,{key:3,modelValue:r.objItem.value,"onUpdate:modelValue":n[1]||(n[1]=G=>r.objItem.value=G)},{default:e.withCtx(()=>{var G;return[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((G=o.item)==null?void 0:G.options.items,Ee=>(e.openBlock(),e.createBlock(p,{key:Ee.value,value:Ee.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(Ee.label),1)]),_:2},1032,["value"]))),128))]}),_:1},8,["modelValue"])):o.item.component=="switch"?(e.openBlock(),e.createBlock(C,{key:4,modelValue:r.objItem.value,"onUpdate:modelValue":n[2]||(n[2]=G=>r.objItem.value=G),"inline-prompt":"","active-text":(ke=(pe=o.item)==null?void 0:pe.options)==null?void 0:ke.activeText,"inactive-text":(xe=(Se=o.item)==null?void 0:Se.options)==null?void 0:xe.inactiveText},null,8,["modelValue","active-text","inactive-text"])):o.item.component=="select"?(e.openBlock(),e.createBlock(B,{key:5,modelValue:r.objItem.value,"onUpdate:modelValue":n[3]||(n[3]=G=>r.objItem.value=G),multiple:(je=(Ge=o.item)==null?void 0:Ge.options)==null?void 0:je.multiple,"allow-create":(P=(ae=o.item)==null?void 0:ae.options)==null?void 0:P.allowCreate,"default-first-option":"",placeholder:((Ne=(te=o.item)==null?void 0:te.options)==null?void 0:Ne.placeholder)||"",clearable:(dt=(Ie=o.item)==null?void 0:Ie.options)==null?void 0:dt.clearable,"collapse-tags":(Fe=(ve=o.item)==null?void 0:ve.options)==null?void 0:Fe.collapseTags,"collapse-tags-tooltip":(me=(we=o.item)==null?void 0:we.options)==null?void 0:me.collapseTagsTooltip,disabled:(v=o.item)==null?void 0:v.options.disabled,filterable:"",style:{width:"100%"}},{default:e.withCtx(()=>{var G;return[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((G=o.item)==null?void 0:G.options.items,Ee=>(e.openBlock(),e.createBlock(k,{key:Ee.value,label:Ee.label,value:Ee.value},null,8,["label","value"]))),128))]}),_:1},8,["modelValue","multiple","allow-create","placeholder","clearable","collapse-tags","collapse-tags-tooltip","disabled"])):o.item.component=="treeSelect"?(e.openBlock(),e.createBlock(N,{key:6,modelValue:r.objItem.value,"onUpdate:modelValue":n[4]||(n[4]=G=>r.objItem.value=G),props:(Ze=(Ye=o.item)==null?void 0:Ye.options)==null?void 0:Ze.props,"node-Key":(Xe=(Pe=o.item)==null?void 0:Pe.options)==null?void 0:Xe.nodeKey,multiple:(ut=(Qe=o.item)==null?void 0:Qe.options)==null?void 0:ut.multiple,"check-Strictly":(b=(nt=o.item)==null?void 0:nt.options)==null?void 0:b.checkStrictly,data:(u=(c=o.item)==null?void 0:c.options)==null?void 0:u.items},null,8,["modelValue","props","node-Key","multiple","check-Strictly","data"])):o.item.component=="cascader"?(e.openBlock(),e.createBlock(q,{key:7,modelValue:r.objItem.value,"onUpdate:modelValue":n[5]||(n[5]=G=>r.objItem.value=G),style:{width:"100%"},props:(y=(g=o.item)==null?void 0:g.options)==null?void 0:y.props,separator:(x=(w=o.item)==null?void 0:w.options)==null?void 0:x.separator,disabled:(I=(S=o.item)==null?void 0:S.options)==null?void 0:I.disabled,options:(M=o.item)==null?void 0:M.options.items,clearable:""},null,8,["modelValue","props","separator","disabled","options"])):o.item.component=="date"?(e.openBlock(),e.createBlock(F,{key:8,modelValue:r.objItem.value,"onUpdate:modelValue":n[6]||(n[6]=G=>r.objItem.value=G),style:{width:"100%"},type:(de=(Z=o.item)==null?void 0:Z.options)==null?void 0:de.type,"start-placeholder":(be=(ne=o.item)==null?void 0:ne.options)==null?void 0:be.startPlaceholder,"end-placeholder":(ue=(fe=o.item)==null?void 0:fe.options)==null?void 0:ue.endPlaceholder,shortcuts:(Re=(ye=o.item)==null?void 0:ye.options)==null?void 0:Re.shortcuts,"disabled-date":(Ce=(D=o.item)==null?void 0:D.options)==null?void 0:Ce.disabledDate,"default-time":(oe=(De=o.item)==null?void 0:De.options)==null?void 0:oe.defaultTime,disabled:(yt=(bt=o.item)==null?void 0:bt.options)==null?void 0:yt.disabled,"value-format":(qt=(ot=o.item)==null?void 0:ot.options)==null?void 0:qt.valueFormat,format:(Vn=(Le=o.item)==null?void 0:Le.options)==null?void 0:Vn.format,placeholder:((Up=(Bt=o.item)==null?void 0:Bt.options)==null?void 0:Up.placeholder)||"请选择"},null,8,["modelValue","type","start-placeholder","end-placeholder","shortcuts","disabled-date","default-time","disabled","value-format","format","placeholder"])):o.item.component=="number"?(e.openBlock(),e.createBlock(V,{key:9,modelValue:r.objItem.value,"onUpdate:modelValue":n[7]||(n[7]=G=>r.objItem.value=G),disabled:(zp=(jp=o.item)==null?void 0:jp.options)==null?void 0:zp.disabled,min:(Kp=(Hp=o.item)==null?void 0:Hp.options)==null?void 0:Kp.min,max:(Yp=(Gp=o.item)==null?void 0:Gp.options)==null?void 0:Yp.max,step:((Wp=($p=o.item)==null?void 0:$p.options)==null?void 0:Wp.step)||1,precision:(Zp=(Jp=o.item)==null?void 0:Jp.options)==null?void 0:Zp.precision,placeholder:((Qp=(Xp=o.item)==null?void 0:Xp.options)==null?void 0:Qp.placeholder)||"","controls-position":((tm=(em=o.item)==null?void 0:em.options)==null?void 0:tm.controlsPosition)||"right"},e.createSlots({_:2},[(om=(nm=o.item)==null?void 0:nm.options)!=null&&om.suffix?{name:"suffix",fn:e.withCtx(()=>{var G;return[e.createElementVNode("span",null,e.toDisplayString((G=o.item)==null?void 0:G.options.suffix),1)]}),key:"0"}:void 0]),1032,["modelValue","disabled","min","max","step","precision","placeholder","controls-position"])):o.item.component=="radio"?(e.openBlock(),e.createBlock(U,{key:10,modelValue:r.objItem.value,"onUpdate:modelValue":n[8]||(n[8]=G=>r.objItem.value=G),disabled:(rm=o.item)==null?void 0:rm.options.disabled},{default:e.withCtx(()=>{var G;return[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((G=o.item)==null?void 0:G.options.items,Ee=>(e.openBlock(),e.createBlock(j,{key:Ee.value,value:Ee.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(Ee.label),1)]),_:2},1032,["value"]))),128))]}),_:1},8,["modelValue","disabled"])):o.item.component=="color"?(e.openBlock(),e.createBlock(L,{key:11,modelValue:r.objItem.value,"onUpdate:modelValue":n[9]||(n[9]=G=>r.objItem.value=G)},null,8,["modelValue"])):o.item.component=="rate"?(e.openBlock(),e.createBlock(R,{key:12,style:{"margin-top":"6px"},modelValue:r.objItem.value,"onUpdate:modelValue":n[10]||(n[10]=G=>r.objItem.value=G)},null,8,["modelValue"])):o.item.component=="slider"?(e.openBlock(),e.createBlock(H,{key:13,modelValue:r.objItem.value,"onUpdate:modelValue":n[11]||(n[11]=G=>r.objItem.value=G),marks:(am=o.item)==null?void 0:am.options.marks},null,8,["modelValue","marks"])):o.item.component=="tags"?(e.openBlock(),e.createElementBlock("div",qy,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.objItem.value,G=>(e.openBlock(),e.createBlock(W,{key:G,closable:"","disable-transitions":!1,onClose:Ee=>l.tagClose(G,r.objItem.value)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(G),1)]),_:2},1032,["onClose"]))),128)),r.tagVisible[o.item.name]?(e.openBlock(),e.createBlock(h,{key:0,modelValue:r.tagValue,"onUpdate:modelValue":n[12]||(n[12]=G=>r.tagValue=G),class:"w-20",size:"small",onKeyup:n[13]||(n[13]=e.withKeys(G=>l.tagInputConfirm(o.item,r.objItem.value),["enter"])),onBlur:n[14]||(n[14]=G=>l.tagInputConfirm(o.item,r.objItem.value))},null,8,["modelValue"])):(e.openBlock(),e.createBlock(J,{key:1,class:"button-new-tag",size:"small",onClick:n[15]||(n[15]=G=>r.tagVisible[o.item.name]=!0)},{default:e.withCtx(()=>{var G,Ee;return[e.createTextVNode(" + "+e.toDisplayString(((Ee=(G=o.item)==null?void 0:G.options)==null?void 0:Ee.addText)||"添加"),1)]}),_:1}))])):e.renderSlot(t.$slots,o.item.component,{key:15,itemCur:o.item,formCur:o.form},()=>[e.createVNode(W,{type:"danger"},{default:e.withCtx(()=>[e.createTextVNode("["+e.toDisplayString(o.item.component)+"] 没有这个默认组件也未自定义插槽内容",1)]),_:1})],!0),o.item.message?(e.openBlock(),e.createElementBlock("div",Ay,e.toDisplayString(o.item.message),1)):e.createCommentVNode("",!0)]}),_:3},8,["class","prop","rules"]))}const ts=le(Iy,[["render",Ry],["__scopeId","data-v-9b3043e5"]]),Oy={components:{FormItem:ts},props:{modelValue:{type:Object,default:()=>{}},config:{type:Object,default:()=>{}},loading:{type:Boolean,default:!1},isView:{type:Boolean,default:!1},showMenu:{type:Boolean,default:!1}},data(){return{form:{},affixIndex:0,isChange:!0,scrollObserverEnabled:!0,renderLoading:!1}},watch:{modelValue:{handler(t,n){this.hasConfig&&this.isChange&&(this.form=t)},deep:!0},config:{handler(t){this.render(t),this.showMenu&&this.$nextTick(()=>{this.handleScroll()}),this.$emit("update:config",t)},immediate:!0,deep:!0}},computed:{hasConfig(){return Object.keys(this.config).length>0},hasValue(){return Object.keys(this.modelValue).length>0}},mounted(){this.hasConfig&&this.render()},beforeDestroy(){},methods:{render(t=this.config){function n(a,r){const l={};return a.forEach(i=>{var d,h,f,p;if((i.component==="checkbox"||i.component==="upload")&&((h=(d=i.options)==null?void 0:d.items)==null||h.forEach(_=>{if(!(_!=null&&_.name))return!1;l[_.name]=(r==null?void 0:r[_.name])??_.value})),!(i!=null&&i.name))return!1;let s=r==null?void 0:r[i.name];i.component==="list"?l[i.name]=((f=i.value)==null?void 0:f.map((_,C)=>(s?s=(r==null?void 0:r[i.name][C])||{}:s=[],n(_,s))))||[]:i.component==="object"?l[i.name]=n(i.value,s||{}):i.component==="number"?l[i.name]=s??(i.value!==void 0?Number(i.value):((p=i.options)==null?void 0:p.min)||0):l[i.name]=s??i.value}),l}let o=n(t.formItems,this.modelValue);o={...this.modelValue,...o},this.form=this.parseNestedObject(o),this.$emit("update:modelValue",this.form)},parseNestedObject(t){const n={};for(const[o,a]of Object.entries(t)){const r=o.split(".");let l=n;r.forEach((i,s)=>{l[i]||(l[i]=s===r.length-1?a:{}),l=l[i]}),delete t[o]}return n},hideHandle(t){return typeof(t==null?void 0:t.hideHandle)=="string"?new Function("form",`return ${t==null?void 0:t.hideHandle.replace(/\$/g,"form")}`)(this.form):typeof(t==null?void 0:t.hideHandle)=="boolean"?t.hideHandle:!1},validate(t,n){return this.$refs.form.validate(t,n)},clearValidate(t,n){return this.$refs.form.clearValidate()},scrollToField(t){return this.$refs.form.scrollToField(t)},resetFields(){return this.$refs.form.resetFields()},submit(){this.$emit("submit",this.form)},clickAffix(t){this.affixIndex=t;const n=document.getElementById("divider-"+t);n&&n.scrollIntoView({behavior:"smooth",block:"start"}),this.scrollObserverEnabled=!1,setTimeout(()=>{this.scrollObserverEnabled=!0},500)},handleScroll(){const t=document.querySelectorAll(".title-name-divider"),n=document.querySelector(".el-main");let o=this;const a=new IntersectionObserver(r=>{let l=r[0];const s=l.target.getBoundingClientRect().top;if(s>=0&&s<=100&&o.scrollObserverEnabled){const d=l.target.getAttribute("data-index");o.affixIndex=d}},{root:n,rootMargin:"0px 0px 70% 0px"});t.forEach(r=>{a.observe(r)})}}},vy={class:"affix-body"},Py=["onClick"];function Ly(t,n,o,a,r,l){const i=e.resolveComponent("el-affix"),s=e.resolveComponent("el-skeleton"),d=e.resolveComponent("el-tag"),h=e.resolveComponent("FormItem"),f=e.resolveComponent("el-col"),p=e.resolveComponent("el-button"),_=e.resolveComponent("el-form-item"),C=e.resolveComponent("el-row"),k=e.resolveComponent("el-form"),B=e.resolveDirective("loading");return e.openBlock(),e.createElementBlock(e.Fragment,null,[o.showMenu?(e.openBlock(),e.createBlock(i,{key:0,offset:100,style:{width:"100%",height:"45px"}},{default:e.withCtx(()=>[e.createElementVNode("ul",vy,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.config.formItems,(N,q)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:q},[N.component==="divider"?(e.openBlock(),e.createElementBlock("a",{key:0,class:e.normalizeClass(["anchor-link",{active:r.affixIndex==q}]),onClick:F=>l.clickAffix(q)},e.toDisplayString(N.label),11,Py)):e.createCommentVNode("",!0)],64))),128))])]),_:1})):e.createCommentVNode("",!0),r.renderLoading||Object.keys(r.form).length==0?(e.openBlock(),e.createBlock(s,{key:1,animated:""})):e.withDirectives((e.openBlock(),e.createBlock(k,{key:2,ref:"form",model:r.form,"label-width":o.config.labelWidth,"label-position":t.$i18n.locale=="en-us"?"top":o.config.labelPosition,disabled:o.isView,"element-loading-text":"Loading..."},{default:e.withCtx(()=>[e.createVNode(C,{gutter:15},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.config.formItems,(N,q)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[l.hideHandle(N)?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(f,{key:0,span:N.span||24},{default:e.withCtx(()=>[e.createVNode(h,{item:N,form:r.form,index:q},e.createSlots({_:2},[["input","upload","checkbox","checkboxGroup","switch","select","treeSelect","cascader","date","number","radio","color","rate","slider","tags"].includes(N.component)?void 0:{name:N.component,fn:e.withCtx(()=>[e.renderSlot(t.$slots,N.component,{itemCur:N,formCur:r.form},()=>[e.createVNode(d,{type:"danger"},{default:e.withCtx(()=>[e.createTextVNode("["+e.toDisplayString(N.component)+"] 没有这个默认组件也未自定义插槽内容",1)]),_:2},1024)],!0)]),key:"0"}]),1032,["item","form","index"])]),_:2},1032,["span"]))],64))),256)),e.createVNode(f,{span:24},{default:e.withCtx(()=>[e.createVNode(_,null,{default:e.withCtx(()=>[e.renderSlot(t.$slots,"default",{},()=>[e.createVNode(p,{type:"primary",onClick:l.submit},{default:e.withCtx(()=>n[0]||(n[0]=[e.createTextVNode("提交")])),_:1},8,["onClick"])],!0)]),_:3})]),_:3})]),_:3})]),_:3},8,["model","label-width","label-position","disabled"])),[[B,o.loading]])],64)}const ns=le(Oy,[["render",Ly],["__scopeId","data-v-a28f7b39"]]),My={icons:[{name:"默认",key:"element",icons:["el-icon-aim","el-icon-add-location","el-icon-apple","el-icon-alarm-clock","el-icon-arrow-down","el-icon-arrow-down-bold","el-icon-arrow-left","el-icon-arrow-left-bold","el-icon-arrow-right-bold","el-icon-arrow-up","el-icon-back","el-icon-bell","el-icon-baseball","el-icon-bicycle","el-icon-bell-filled","el-icon-basketball","el-icon-bottom","el-icon-box","el-icon-briefcase","el-icon-brush-filled","el-icon-bowl","el-icon-avatar","el-icon-brush","el-icon-burger","el-icon-camera","el-icon-bottom-left","el-icon-calendar","el-icon-caret-bottom","el-icon-caret-left","el-icon-caret-right","el-icon-caret-top","el-icon-chat-dot-square","el-icon-cellphone","el-icon-chat-dot-round","el-icon-chat-line-square","el-icon-chat-line-round","el-icon-chat-round","el-icon-check","el-icon-chat-square","el-icon-cherry","el-icon-chicken","el-icon-circle-check-filled","el-icon-circle-check","el-icon-checked","el-icon-circle-close-filled","el-icon-circle-close","el-icon-arrow-right","el-icon-circle-plus","el-icon-clock","el-icon-close-bold","el-icon-close","el-icon-cloudy","el-icon-circle-plus-filled","el-icon-coffee-cup","el-icon-cold-drink","el-icon-coin","el-icon-arrow-up-bold","el-icon-collection-tag","el-icon-bottom-right","el-icon-coffee","el-icon-camera-filled","el-icon-collection","el-icon-cpu","el-icon-crop","el-icon-coordinate","el-icon-d-arrow-left","el-icon-compass","el-icon-connection","el-icon-credit-card","el-icon-data-board","el-icon-d-arrow-right","el-icon-dessert","el-icon-delete-location","el-icon-d-caret","el-icon-delete","el-icon-dish","el-icon-dish-dot","el-icon-document-copy","el-icon-discount","el-icon-document-checked","el-icon-document-add","el-icon-document-remove","el-icon-data-analysis","el-icon-delete-filled","el-icon-download","el-icon-drizzling","el-icon-eleme","el-icon-eleme-filled","el-icon-edit","el-icon-failed","el-icon-expand","el-icon-female","el-icon-document","el-icon-film","el-icon-finished","el-icon-data-line","el-icon-filter","el-icon-flag","el-icon-folder-checked","el-icon-first-aid-kit","el-icon-folder-add","el-icon-fold","el-icon-folder-delete","el-icon-document-delete","el-icon-folder","el-icon-food","el-icon-folder-opened","el-icon-football","el-icon-folder-remove","el-icon-fries","el-icon-full-screen","el-icon-fork-spoon","el-icon-goblet","el-icon-goblet-full","el-icon-goods","el-icon-goblet-square-full","el-icon-goods-filled","el-icon-grid","el-icon-grape","el-icon-goblet-square","el-icon-headset","el-icon-comment","el-icon-help-filled","el-icon-histogram","el-icon-home-filled","el-icon-help","el-icon-house","el-icon-ice-cream-round","el-icon-hot-water","el-icon-ice-cream","el-icon-files","el-icon-ice-cream-square","el-icon-key","el-icon-ice-tea","el-icon-knife-fork","el-icon-iphone","el-icon-info-filled","el-icon-link","el-icon-ice-drink","el-icon-lightning","el-icon-loading","el-icon-lollipop","el-icon-location-information","el-icon-lock","el-icon-location-filled","el-icon-magnet","el-icon-male","el-icon-location","el-icon-menu","el-icon-magic-stick","el-icon-message-box","el-icon-map-location","el-icon-mic","el-icon-message","el-icon-medal","el-icon-milk-tea","el-icon-microphone","el-icon-minus","el-icon-money","el-icon-moon-night","el-icon-monitor","el-icon-moon","el-icon-more","el-icon-mostly-cloudy","el-icon-more-filled","el-icon-mouse","el-icon-mug","el-icon-mute","el-icon-no-smoking","el-icon-mute-notification","el-icon-notification","el-icon-notebook","el-icon-odometer","el-icon-office-building","el-icon-operation","el-icon-opportunity","el-icon-orange","el-icon-open","el-icon-paperclip","el-icon-pear","el-icon-partly-cloudy","el-icon-phone","el-icon-picture-filled","el-icon-phone-filled","el-icon-picture-rounded","el-icon-guide","el-icon-place","el-icon-platform","el-icon-pie-chart","el-icon-pointer","el-icon-plus","el-icon-position","el-icon-postcard","el-icon-present","el-icon-price-tag","el-icon-promotion","el-icon-pouring","el-icon-reading-lamp","el-icon-question-filled","el-icon-printer","el-icon-picture","el-icon-refresh-right","el-icon-reading","el-icon-refresh-left","el-icon-refresh","el-icon-refrigerator","el-icon-remove-filled","el-icon-right","el-icon-scale-to-original","el-icon-school","el-icon-remove","el-icon-scissor","el-icon-select","el-icon-management","el-icon-search","el-icon-sell","el-icon-semi-select","el-icon-share","el-icon-setting","el-icon-service","el-icon-ship","el-icon-set-up","el-icon-shopping-bag","el-icon-shop","el-icon-shopping-cart","el-icon-shopping-cart-full","el-icon-soccer","el-icon-sold-out","el-icon-smoking","el-icon-sort-down","el-icon-sort","el-icon-sort-up","el-icon-star","el-icon-stamp","el-icon-star-filled","el-icon-stopwatch","el-icon-success-filled","el-icon-suitcase","el-icon-sugar","el-icon-sunny","el-icon-sunrise","el-icon-switch","el-icon-ticket","el-icon-sunset","el-icon-tickets","el-icon-switch-button","el-icon-takeaway-box","el-icon-toilet-paper","el-icon-timer","el-icon-tools","el-icon-top-left","el-icon-top","el-icon-top-right","el-icon-trend-charts","el-icon-turn-off","el-icon-unlock","el-icon-trophy","el-icon-umbrella","el-icon-upload-filled","el-icon-user-filled","el-icon-upload","el-icon-user","el-icon-van","el-icon-copy-document","el-icon-video-pause","el-icon-video-camera-filled","el-icon-view","el-icon-wallet","el-icon-warning-filled","el-icon-watch","el-icon-video-play","el-icon-watermelon","el-icon-video-camera","el-icon-wallet-filled","el-icon-warning","el-icon-list","el-icon-zoom-in","el-icon-zoom-out","el-icon-rank","el-icon-wind-power"]}]},Uy={props:{modelValue:{type:String,default:""},placeholder:{type:String,default:"请输入或者选择图标"},clearable:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},data(){return{defaultValue:"",activeName:"element",dialogVisible:!1,data:[]}},watch:{modelValue(t){this.defaultValue=t},defaultValue(t){this.$emit("update:modelValue",t)}},mounted(){this.defaultValue=this.modelValue,this.data.push(...My.icons)},methods:{open(){if(this.disabled)return!1;this.dialogVisible=!0},selectIcon(t){if(t.target.tagName!="SPAN")return!1;this.defaultValue=t.target.dataset.icon,this.dialogVisible=!1,this.$emit("update:modelValue",this.defaultValue)}}},jy={class:"lw-icon-select"},zy={class:"lw-icon-select__list"},Hy=["data-icon"];function Ky(t,n,o,a,r,l){const i=e.resolveComponent("el-button"),s=e.resolveComponent("el-input"),d=e.resolveComponent("el-tag"),h=e.resolveComponent("el-icon"),f=e.resolveComponent("el-scrollbar"),p=e.resolveComponent("el-tab-pane"),_=e.resolveComponent("el-tabs"),C=e.resolveComponent("el-dialog");return e.openBlock(),e.createElementBlock("div",jy,[e.createVNode(s,{modelValue:r.defaultValue,"onUpdate:modelValue":n[0]||(n[0]=k=>r.defaultValue=k),"prefix-icon":r.defaultValue||"none",placeholder:o.placeholder,clearable:o.clearable,disabled:o.disabled},{append:e.withCtx(()=>[e.createVNode(i,{icon:"el-icon-more-filled",onClick:l.open},null,8,["onClick"])]),_:1},8,["modelValue","prefix-icon","placeholder","clearable","disabled"]),e.createVNode(C,{title:"图标选择器",modelValue:r.dialogVisible,"onUpdate:modelValue":n[3]||(n[3]=k=>r.dialogVisible=k),width:780,"destroy-on-close":""},{default:e.withCtx(()=>[e.createVNode(_,{style:{"margin-top":"-30px"},modelValue:r.activeName,"onUpdate:modelValue":n[2]||(n[2]=k=>r.activeName=k)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.data,k=>(e.openBlock(),e.createBlock(p,{key:k.name,name:k.key,lazy:""},{label:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(k.name)+" ",1),e.createVNode(d,{size:"small",type:"info"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(k.icons.length),1)]),_:2},1024)]),default:e.withCtx(()=>[e.createElementVNode("div",zy,[e.createVNode(f,null,{default:e.withCtx(()=>[e.createElementVNode("ul",{onClick:n[1]||(n[1]=(...B)=>l.selectIcon&&l.selectIcon(...B))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k.icons,B=>(e.openBlock(),e.createElementBlock("li",{key:B},[e.createElementVNode("span",{"data-icon":B},null,8,Hy),e.createVNode(h,null,{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(B)))]),_:2},1024)]))),128))])]),_:2},1024)])]),_:2},1032,["name"]))),128))]),_:1},8,["modelValue"])]),_:1},8,["modelValue"])])}const os=le(Uy,[["render",Ky],["__scopeId","data-v-2ebe66a3"]]),_t={pageSize:20,parseData:function(t){return{data:t,rows:t.content,total:t.totalElements,msg:t.message,code:t.code}},request:{page:"page",pageSize:"size",keyword:"keyword"},props:{label:"label",value:"value"}},Gy={name:"lwTableSelect",props:{modelValue:null,apiObj:{type:[Object,Function],default:()=>{}},params:{type:Object,default:()=>{}},placeholder:{type:String,default:"请选择"},size:{type:String,default:"default"},clearable:{type:Boolean,default:!1},multiple:{type:Boolean,default:!1},filterable:{type:Boolean,default:!1},collapseTags:{type:Boolean,default:!1},collapseTagsTooltip:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},tableWidth:{type:Number,default:400},mode:{type:String,default:"popover"},props:{type:Object,default:()=>{}}},data(){return{loading:!1,keyword:null,defaultValue:[],tableData:[],pageSize:_t.pageSize,total:0,currentPage:1,defaultProps:{label:_t.props.label,value:_t.props.value,page:_t.request.page,pageSize:_t.request.pageSize,keyword:_t.request.keyword},formData:{}}},computed:{},watch:{modelValue:{handler(){this.defaultValue=this.modelValue},deep:!0}},mounted(){this.defaultProps=Object.assign(this.defaultProps,this.props),this.defaultValue=this.modelValue},methods:{visibleChange(t){t&&(this.currentPage=1,this.keyword=null,this.formData={},this.getData())},async getData(){var r,l,i;this.loading=!0;var t={[this.defaultProps.page]:this.currentPage-1,[this.defaultProps.pageSize]:this.pageSize,[this.defaultProps.keyword]:this.keyword};let n=this.$expression(this.formData);n&&((r=this.params)!=null&&r.expression)?this.formData.expression=`${this.params.expression} AND ${n}`:n?this.formData.expression=n:(l=this.params)!=null&&l.expression?this.formData.expression=(i=this.params)==null?void 0:i.expression:this.formData.expression="",Object.assign(t,this.params,this.formData);var o=await this.apiObj(t),a=_t.parseData(o);this.tableData=a.rows,this.total=a.total,this.loading=!1,this.$nextTick(()=>{if(this.multiple)this.defaultValue.forEach(d=>{var h=this.tableData.filter(f=>f[this.defaultProps.value]===d.value);h.length>0&&this.$refs.table.toggleRowSelection(h[0],!0)});else{var s=this.tableData.filter(d=>{var h;return d[this.defaultProps.value]===((h=this.defaultValue)==null?void 0:h.value)});this.$refs.table.setCurrentRow(s[0])}this.$refs.table.setScrollTop(0)})},formSubmit(){this.currentPage=1,this.keyword=null,this.getData()},reload(){this.getData()},getCurVlaue(t){const n={};return Object.entries(this.defaultProps).forEach(([o,a])=>{t[a]&&(n[o]=t[a])}),n},select(t,n){var o=t.length&&t.indexOf(n)!==-1;o?this.defaultValue.push(this.getCurVlaue(n)):this.defaultValue.splice(this.defaultValue.findIndex(a=>a.value==n[this.defaultProps.value]),1)},selectAll(t){var n=t.length>0;n?t.forEach(o=>{var a=this.defaultValue.find(r=>r.value==o[this.defaultProps.value]);a||this.defaultValue.push(this.getCurVlaue(o))}):this.defaultValue=[],this.$emit("update:modelValue",this.defaultValue),this.$emit("change",this.defaultValue)},click(t){this.multiple||(this.defaultValue=this.getCurVlaue(t),this.$refs.select.blur(),this.$emit("update:modelValue",this.defaultValue),this.$emit("change",this.defaultValue))},removeTag(t){var n=this.findRowByKey(t.value);this.$refs.table.toggleRowSelection(n,!1),this.$emit("update:modelValue",this.defaultValue)},clear(){this.$emit("update:modelValue",this.defaultValue)},findRowByKey(t){return this.tableData.find(n=>n[this.defaultProps.value]===t)},filterMethod(t){if(!t)return this.keyword=null,!1;this.keyword=t,this.getData()},blur(){this.$refs.select.blur()},focus(){this.$refs.select.focus()}}},Yy={class:"lw-table-select__table",style:{width:"100%"}},$y={class:"lw-table-select__header"},Wy={class:"lw-table-select__page"};function Jy(t,n,o,a,r,l){const i=e.resolveComponent("el-table-column"),s=e.resolveComponent("el-table"),d=e.resolveComponent("el-pagination"),h=e.resolveComponent("el-select"),f=e.resolveDirective("loading");return e.openBlock(),e.createBlock(h,{ref:"select",modelValue:r.defaultValue,"onUpdate:modelValue":n[1]||(n[1]=p=>r.defaultValue=p),size:o.size,clearable:o.clearable,multiple:o.multiple,"collapse-tags":o.collapseTags,"collapse-tags-tooltip":o.collapseTagsTooltip,filterable:o.filterable,placeholder:o.placeholder,disabled:o.disabled,"filter-method":l.filterMethod,onRemoveTag:l.removeTag,onVisibleChange:l.visibleChange,onClear:l.clear},{empty:e.withCtx(()=>[e.withDirectives((e.openBlock(),e.createElementBlock("div",Yy,[e.createElementVNode("div",$y,[e.renderSlot(t.$slots,"header",{form:r.formData,submit:l.formSubmit},void 0,!0)]),e.createVNode(s,{ref:"table",data:r.tableData,"max-height":245,"highlight-current-row":!o.multiple,"reserve-selection":!0,onRowClick:l.click,onSelect:l.select,onSelectAll:l.selectAll},{default:e.withCtx(()=>[o.multiple?(e.openBlock(),e.createBlock(i,{key:0,type:"selection",width:"45"})):(e.openBlock(),e.createBlock(i,{key:1,type:"index",width:"45"},{default:e.withCtx(p=>[e.createElementVNode("span",null,e.toDisplayString(p.$index+(r.currentPage-1)*r.pageSize+1),1)]),_:1})),e.renderSlot(t.$slots,"default",{},void 0,!0)]),_:3},8,["data","highlight-current-row","onRowClick","onSelect","onSelectAll"]),e.createElementVNode("div",Wy,[e.createVNode(d,{small:"",background:"",layout:"prev, pager, next",total:r.total,"page-size":r.pageSize,currentPage:r.currentPage,"onUpdate:currentPage":n[0]||(n[0]=p=>r.currentPage=p),onCurrentChange:l.reload},null,8,["total","page-size","currentPage","onCurrentChange"])])])),[[f,r.loading]])]),_:3},8,["modelValue","size","clearable","multiple","collapse-tags","collapse-tags-tooltip","filterable","placeholder","disabled","filter-method","onRemoveTag","onVisibleChange","onClear"])}const rs=le(Gy,[["render",Jy],["__scopeId","data-v-322204c0"]]),Zy={components:{lwUpload:St},props:{modelValue:{type:Object,default:()=>{}},config:{type:Object,default:()=>{}},maxHeight:{type:String,default:"calc(100vh - 280px)"},isView:{type:Boolean,default:!1},isPagination:{type:Boolean,default:!1}},data(){return{tableData:[],tagValue:"",currentPage:1,pageSize:8,ids:[],internalUpdate:!0,tagVisible:!1}},watch:{tableData:{handler(t){this.internalUpdate||this.$emit("update:modelValue",this.unflattenObject(t)),this.internalUpdate=!1},deep:!0},modelValue:{handler(t){this.internalUpdate||(this.internalUpdate=!0,this.tableData=this.flattenObject(t))},deep:!0}},computed:{hasConfig(){return Object.keys(this.config).length>0},hasValue(){return Object.keys(this.modelValue).length>0},dataList(){if(!this.isPagination)return this.tableData;const n=(this.currentPage-1)*this.pageSize;return this.tableData.slice(n,n+this.pageSize)}},mounted(){this.tableData=this.flattenObject(this.modelValue)},methods:{flattenObject(t){let n=[];function o(a,r=""){let l={};for(let i in a)if(a.hasOwnProperty(i)){const s=r?`${r}.${i}`:i;i!="errorMsg"&&typeof a[i]=="object"&&a[i]!==null&&!Array.isArray(a[i])?Object.assign(l,o(a[i],s)):l[s]=a[i]}return l}return t==null||t.forEach(a=>{n.push(o(a))}),n},unflattenObject(t){let n=[];return t==null||t.forEach(o=>{const a={};for(let r in o)if(o.hasOwnProperty(r)){const l=r.split(".");l.reduce((i,s,d)=>(d===l.length-1?i[s]=o[r]:i[s]=i[s]||{},i[s]),a)}n.push(a)}),n},isEmpty(t){return!!(t==null||typeof t=="string"&&t.trim()===""||Array.isArray(t)&&t.length===0||typeof t=="object"&&Object.keys(t).length===0)},isValue(t,n){const o=[];return t.forEach(a=>{n.forEach(r=>{r.rules&&r.rules.length>0&&r.rules.forEach(l=>{var i;r.component=="checkbox"||r.component=="upload"?r.options.items.forEach(s=>{this.isEmpty(a[s.name])&&(a!=null&&a.errorMsg||(a.errorMsg={}),a.errorMsg[s.name]=l.message)}):l.required&&this.isEmpty(a[r.name])?(a!=null&&a.errorMsg||(a.errorMsg={}),a.errorMsg[r.name]=l.message,o.push(`${r.label} ${l.message}`)):(a!=null&&a.errorMsg&&delete a.errorMsg[r.name],((i=a.errorMsg)==null?void 0:i.length)===0&&delete a.errorMsg)})})}),o.length>0?(this.$message.warning("校验失败,存在必填字段为空,请检查"),!0):!1},addItem(t=this.tableData){let n={},o=JSON.parse(JSON.stringify(this.config.formItems));if(this.isValue(t,o))return!1;o.forEach(l=>{var i;if(l.component=="checkbox"||l.component=="upload")if(l.name){const s=[];l.options.items.forEach(d=>{s.push(d.value)}),n[l.name]=s}else(i=l==null?void 0:l.options)!=null&&i.items&&l.options.items.forEach(s=>{n[s.name]=s.value});else n[l.name]=l.value});let r=this.$tool.getUUID(this.config.rowKey,"4");t.push({[this.config.rowKey]:r,...n}),this.ids.push(r)},clickFun(t,n,o){t=="delete"&&this.deleteItem(n),t=="add"&&(n!=null&&n.fields||(n.fields=[]),this.addItem(n.fields))},removeNode(t,n){for(let o=0;o<t.length;o++){if(JSON.stringify(t[o])===JSON.stringify(n)){t.splice(o,1);return}t[o][this.config.treeProps.children]&&this.removeNode(t[o][this.config.treeProps.children],n)}},deleteItem(t){this.removeNode(this.tableData,t)},isDisabled(t,n){var o;return!this.ids.includes(n[this.config.rowKey])&&((o=t.options)==null?void 0:o.disabled)},deepMerge(t,n){return n.forEach(o=>{if(n.hasOwnProperty(key)){const a=t[key]!==null&&t[key]!==void 0,r=n[key]!==null&&n[key]!==void 0;a&&typeof t[key]=="object"&&!Array.isArray(t[key])&&r&&typeof n[key]=="object"&&!Array.isArray(n[key])?t[key]=this.deepMerge(t[key],n[key]):r?t[key]=n[key]:r||delete t[key]}}),t},tagClose(t,n){n.splice(n.indexOf(t),1)},tagInputConfirm(t,n){this.tagValue&&(n[t.name]=n[t.name]||[],n[t.name].push(this.tagValue)),n.tagVisible=!1,this.tagValue=""},getPropName(t){return t.component=="checkbox"||t.component=="upload"?t.options.items[0].name:t.name},getFilters(t){let n=[];return this.tableData.forEach(o=>{n.includes(o[t])||n.push(o[t])}),n.map(o=>({text:o,value:o}))},filterHandler(t,n,o){const a=o.property;return n[a]===t}}},Xy={key:0},Qy={class:"error-tips"},e_={class:"error-tips"},t_={class:"error-tips"},n_={key:13,class:"tags-list"},o_={key:16,class:"el-row-item-msg"},r_={key:17,class:"error-tips"},a_={key:0,class:"pagination-body"},l_={key:1,class:"btn-list"};function i_(t,n,o,a,r,l){var A;const i=e.resolveComponent("el-input"),s=e.resolveComponent("lw-upload"),d=e.resolveComponent("el-col"),h=e.resolveComponent("el-checkbox"),f=e.resolveComponent("el-checkbox-group"),p=e.resolveComponent("el-switch"),_=e.resolveComponent("el-option"),C=e.resolveComponent("el-select"),k=e.resolveComponent("el-cascader"),B=e.resolveComponent("el-date-picker"),N=e.resolveComponent("el-input-number"),q=e.resolveComponent("el-radio"),F=e.resolveComponent("el-radio-group"),V=e.resolveComponent("el-color-picker"),j=e.resolveComponent("el-rate"),U=e.resolveComponent("el-slider"),L=e.resolveComponent("el-tag"),R=e.resolveComponent("el-button"),H=e.resolveComponent("el-tooltip"),W=e.resolveComponent("el-icon-more-filled"),J=e.resolveComponent("el-icon"),K=e.resolveComponent("el-dropdown-item"),ee=e.resolveComponent("el-dropdown-menu"),ie=e.resolveComponent("el-dropdown"),O=e.resolveComponent("el-table-column"),E=e.resolveComponent("el-table"),m=e.resolveComponent("el-pagination");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(E,{data:l.dataList,stripe:"",ref:"table",columns:o.config.formItems,"max-height":o.maxHeight,"row-key":o.config.rowKey||"id","tree-props":((A=o.config)==null?void 0:A.treeProps)||{children:"children",hasChildren:"hasChildren"},style:{width:"100%"}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.config.formItems,(T,qe)=>(e.openBlock(),e.createBlock(O,{width:T.width,"min-width":T.minWidth,key:qe,label:T.label,prop:l.getPropName(T),align:T.align??"left",fixed:T.fixed,sortable:T.sortable,"show-overflow-tooltip":T.tooltip,filters:T.filters?l.getFilters(T.name):null,"filter-method":T.filters?l.filterHandler:null},{header:e.withCtx(()=>[e.createElementVNode("div",{class:"table-name",style:e.normalizeStyle({justifyContent:T.align||"flex-start"})},[T!=null&&T.rules?(e.openBlock(),e.createElementBlock("span",Xy,"*")):e.createCommentVNode("",!0),e.createTextVNode(" "+e.toDisplayString(T.label),1)],4)]),default:e.withCtx(({row:Y,$index:Te,column:Q})=>{var ce,Ae,z,$,X,_e,pe,ke,Se,xe,Ge,je,ae;return[T.component=="input"?(e.openBlock(),e.createBlock(i,{key:0,modelValue:Y[T.name],"onUpdate:modelValue":P=>Y[T.name]=P,placeholder:T.options.placeholder,clearable:"",size:o.config.size||"small",type:T.options.type,disabled:l.isDisabled(T,Y),maxlength:T.options.maxlength,"show-word-limit":""},null,8,["modelValue","onUpdate:modelValue","placeholder","size","type","disabled","maxlength"])):T.component=="upload"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(T.options.items,(P,te)=>(e.openBlock(),e.createBlock(d,{key:te},{default:e.withCtx(()=>[e.createVNode(s,{modelValue:Y[P.name],"onUpdate:modelValue":Ne=>Y[P.name]=Ne,maxSize:P.maxSize,accept:P.accept,title:P.label,parseData:T.parseData,disabled:P==null?void 0:P.disabled,multiple:P==null?void 0:P.multiple,limit:P==null?void 0:P.limit,returnFile:P==null?void 0:P.returnFile,tip:P==null?void 0:P.tip,apiObj:T.apiObj},null,8,["modelValue","onUpdate:modelValue","maxSize","accept","title","parseData","disabled","multiple","limit","returnFile","tip","apiObj"]),e.createElementVNode("div",Qy,e.toDisplayString(Y.errorMsg[P.name]),1)]),_:2},1024))),128)):T.component=="checkbox"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[T.name?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(T.options.items,(P,te)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:te},[e.createVNode(h,{modelValue:Y[T.name],"onUpdate:modelValue":Ne=>Y[T.name]=Ne,label:P.label,size:o.config.size||"small"},null,8,["modelValue","onUpdate:modelValue","label","size"]),e.createElementVNode("div",e_,e.toDisplayString(Y.errorMsg[T.name]),1)],64))),128)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(T.options.items,(P,te)=>(e.openBlock(),e.createBlock(h,{modelValue:Y[P.name],"onUpdate:modelValue":Ne=>Y[P.name]=Ne,label:P.label,key:te},null,8,["modelValue","onUpdate:modelValue","label"]))),128)),e.createElementVNode("div",t_,e.toDisplayString(Y.errorMsg[t._item.name]),1)],64))],64)):T.component=="checkboxGroup"?(e.openBlock(),e.createBlock(f,{key:3,modelValue:Y[T.name],"onUpdate:modelValue":P=>Y[T.name]=P,size:o.config.size||"small"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(T.options.items,P=>(e.openBlock(),e.createBlock(h,{key:P.value,label:P.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(P.label),1)]),_:2},1032,["label"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","size"])):T.component=="switch"?(e.openBlock(),e.createBlock(p,{key:4,size:o.config.size||"small",disabled:l.isDisabled(T,Y),modelValue:Y[T.name],"onUpdate:modelValue":P=>Y[T.name]=P},null,8,["size","disabled","modelValue","onUpdate:modelValue"])):T.component=="select"?(e.openBlock(),e.createBlock(C,{key:5,modelValue:Y[T.name],"onUpdate:modelValue":P=>Y[T.name]=P,multiple:(ce=T.options)==null?void 0:ce.multiple,"allow-create":(Ae=T.options)==null?void 0:Ae.allowCreate,"default-first-option":"",placeholder:((z=T.options)==null?void 0:z.placeholder)||"",clearable:($=T.options)==null?void 0:$.clearable,disabled:l.isDisabled(T,Y),filterable:"",size:o.config.size||"small",style:{width:"100%"}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(T.options.items,P=>(e.openBlock(),e.createBlock(_,{key:P.value,label:P.label,value:P.value},null,8,["label","value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","multiple","allow-create","placeholder","clearable","disabled","size"])):T.component=="cascader"?(e.openBlock(),e.createBlock(k,{key:6,size:o.config.size||"small",modelValue:Y[T.name],"onUpdate:modelValue":P=>Y[T.name]=P,options:T.options.items,disabled:l.isDisabled(T,Y),clearable:""},null,8,["size","modelValue","onUpdate:modelValue","options","disabled"])):T.component=="date"?(e.openBlock(),e.createBlock(B,{key:7,modelValue:Y[T.name],"onUpdate:modelValue":P=>Y[T.name]=P,style:{width:"100%"},size:o.config.size||"small",type:T.options.type,disabled:l.isDisabled(T,Y),"start-placeholder":T.options.startPlaceholder,"end-placeholder":T.options.endPlaceholder,shortcuts:T.options.shortcuts,"default-time":T.options.defaultTime,"value-rowat":T.options.valuerowat,placeholder:T.options.placeholder||"请选择"},null,8,["modelValue","onUpdate:modelValue","size","type","disabled","start-placeholder","end-placeholder","shortcuts","default-time","value-rowat","placeholder"])):T.component=="number"?(e.openBlock(),e.createBlock(N,{key:8,modelValue:Y[T.name],"onUpdate:modelValue":P=>Y[T.name]=P,disabled:(X=T.options)==null?void 0:X.disabled,min:(_e=T==null?void 0:T.options)==null?void 0:_e.min,max:(pe=T==null?void 0:T.options)==null?void 0:pe.max,size:o.config.size||"small",step:((ke=T==null?void 0:T.options)==null?void 0:ke.step)||1,precision:(Se=T==null?void 0:T.options)==null?void 0:Se.precision,placeholder:((xe=T==null?void 0:T.options)==null?void 0:xe.placeholder)||"","controls-position":((Ge=T==null?void 0:T.options)==null?void 0:Ge.controlsPosition)||"right"},e.createSlots({_:2},[(je=T==null?void 0:T.options)!=null&&je.suffix?{name:"suffix",fn:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(T.options.suffix),1)]),key:"0"}:void 0]),1032,["modelValue","onUpdate:modelValue","disabled","min","max","size","step","precision","placeholder","controls-position"])):T.component=="radio"?(e.openBlock(),e.createBlock(F,{key:9,modelValue:Y[T.name],"onUpdate:modelValue":P=>Y[T.name]=P,disabled:l.isDisabled(T,Y),size:o.config.size||"small"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(T.options.items,P=>(e.openBlock(),e.createBlock(q,{key:P.value,disabled:l.isDisabled(T,Y),value:P.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(P.label),1)]),_:2},1032,["disabled","value"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","disabled","size"])):T.component=="color"?(e.openBlock(),e.createBlock(V,{key:10,modelValue:Y[T.name],"onUpdate:modelValue":P=>Y[T.name]=P,disabled:l.isDisabled(T,Y),size:o.config.size||"small"},null,8,["modelValue","onUpdate:modelValue","disabled","size"])):T.component=="rate"?(e.openBlock(),e.createBlock(j,{key:11,style:{"margin-top":"6px"},disabled:l.isDisabled(T,Y),modelValue:Y[T.name],"onUpdate:modelValue":P=>Y[T.name]=P,size:o.config.size||"small"},null,8,["disabled","modelValue","onUpdate:modelValue","size"])):T.component=="slider"?(e.openBlock(),e.createBlock(U,{key:12,modelValue:Y[T.name],"onUpdate:modelValue":P=>Y[T.name]=P,marks:T.options.marks,disabled:l.isDisabled(T,Y),size:o.config.size||"small"},null,8,["modelValue","onUpdate:modelValue","marks","disabled","size"])):T.component=="tags"?(e.openBlock(),e.createElementBlock("div",n_,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Y[T.name],P=>(e.openBlock(),e.createBlock(L,{key:P,closable:"","disable-transitions":!1,onClose:te=>l.tagClose(P,Y[T.name])},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(P),1)]),_:2},1032,["onClose"]))),128)),Y!=null&&Y.tagVisible?(e.openBlock(),e.createBlock(i,{key:0,modelValue:r.tagValue,"onUpdate:modelValue":n[0]||(n[0]=P=>r.tagValue=P),class:"w-20",size:o.config.size||"small",onKeyup:e.withKeys(P=>l.tagInputConfirm(T,Y),["enter"]),onBlur:P=>l.tagInputConfirm(T,Y)},null,8,["modelValue","size","onKeyup","onBlur"])):(e.openBlock(),e.createBlock(R,{key:1,class:"button-new-tag",size:o.config.size||"small",disabled:l.isDisabled(T,Y),onClick:P=>Y.tagVisible=!0},{default:e.withCtx(()=>n[3]||(n[3]=[e.createTextVNode(" + 添加 ")])),_:2},1032,["size","disabled","onClick"]))])):T.component=="operation"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:14},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(T.options.addDelete,P=>e.withDirectives((e.openBlock(),e.createElementBlock("span",{key:P},[P.icon?(e.openBlock(),e.createBlock(H,{key:0,content:P.label,placement:"top"},{default:e.withCtx(()=>[e.createVNode(R,{type:"primary",size:o.config.size||"small",onClick:te=>P.clickFun?P.clickFun(Y,Te,Q,r.tableData):l.clickFun(P.type,Y,Te),disabled:P.disabled?P.disabled(Y):!1,icon:P.icon,circle:""},null,8,["size","onClick","disabled","icon"])]),_:2},1032,["content"])):(e.openBlock(),e.createBlock(R,{key:1,type:"primary",text:"",size:o.config.size||"small",onClick:te=>P.clickFun?P.clickFun(Y,Te,Q,r.tableData):l.clickFun(P.type,Y,Te),disabled:P.disabled?P.disabled(Y):!1},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(P.label),1)]),_:2},1032,["size","onClick","disabled"]))])),[[e.vShow,P.isShow?P.isShow(Y):!0]])),128)),(ae=T.options)!=null&&ae.items&&T.options.items.length>0?(e.openBlock(),e.createBlock(ie,{key:0},{dropdown:e.withCtx(()=>[e.createVNode(ee,null,{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(T.options.items.filter(P=>!P.isShow||P.isShow(Y)),P=>(e.openBlock(),e.createBlock(K,{key:P,onClick:te=>P.clickFun(Y,Te,Q,r.tableData)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(P.label),1)]),_:2},1032,["onClick"]))),128))]),_:2},1024)]),default:e.withCtx(()=>[e.createVNode(R,{size:o.config.size||"small",type:"primary",link:""},{default:e.withCtx(()=>[e.createVNode(J,{class:"more-btn",size:"16"},{default:e.withCtx(()=>[e.createVNode(W)]),_:1})]),_:1},8,["size"])]),_:2},1024)):e.createCommentVNode("",!0)],64)):e.renderSlot(t.$slots,T.component,{key:15,row:Y},()=>[e.createVNode(L,{type:"danger"},{default:e.withCtx(()=>[e.createTextVNode("["+e.toDisplayString(T.component)+"] 没有这个默认组件也未自定义插槽内容",1)]),_:2},1024)],!0),T.message?(e.openBlock(),e.createElementBlock("div",o_,e.toDisplayString(T.message),1)):e.createCommentVNode("",!0),Y.errorMsg?(e.openBlock(),e.createElementBlock("div",r_,e.toDisplayString(Y.errorMsg[T==null?void 0:T.name]),1)):e.createCommentVNode("",!0)]}),_:2},1032,["width","min-width","label","prop","align","fixed","sortable","show-overflow-tooltip","filters","filter-method"]))),128))]),_:3},8,["data","columns","max-height","row-key","tree-props"]),o.isPagination&&r.tableData.length>r.pageSize?(e.openBlock(),e.createElementBlock("div",a_,[e.createVNode(m,{size:"small",background:"","page-size":r.pageSize,"current-page":r.currentPage,"onUpdate:currentPage":n[1]||(n[1]=T=>r.currentPage=T),layout:"prev, pager, next",total:r.tableData.length},null,8,["page-size","current-page","total"])])):e.createCommentVNode("",!0),o.isView?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",l_,[e.createVNode(R,{type:"primary",class:"add-btn",plain:"",icon:"el-icon-plus",onClick:n[2]||(n[2]=T=>l.addItem())},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("btn.add")),1)]),_:1}),e.renderSlot(t.$slots,"deleteBtn",{},void 0,!0)]))],64)}const as=le(Zy,[["render",i_],["__scopeId","data-v-e4f0fc23"]]),s_={name:"JsonItem",components:{FormItem:ts,draggable:Gt},props:{formItems:{type:Object,default:[]},form:{type:Object,default:()=>{}},hideBorder:{type:Boolean,default:!0},custom:{type:Array,default:()=>[]}},computed:{curIndex(){var t;return((t=this.$store.state)==null?void 0:t.curIndex)||""}},emits:["curClick"],methods:{hideHandle(t){return typeof(t==null?void 0:t.hideHandle)=="string"?new Function("form",`return ${t==null?void 0:t.hideHandle.replace(/\$/g,"form")}`)(this.form):typeof(t==null?void 0:t.hideHandle)=="boolean"?t.hideHandle:!1},changeClick(t){var n;this.$store.state.curIndex=t.name||((n=t==null?void 0:t.options.items[0])==null?void 0:n.name),this.$emit("curClick",t)},deleteListItem(t,n){t.splice(n,1)},addListItem(t){let n=t[0],o=JSON.parse(JSON.stringify(n));t.push(o)},deleteItem(t){this.formItems.splice(t,1)},copyItem(t,n){let o=JSON.parse(JSON.stringify(t));o.name=`${t.component}-${this.$tool.getUUID("",2)}`,this.formItems.splice(n+1,0,o)}}},c_={key:3,class:"tool-list"};function d_(t,n,o,a,r,l){var B,N,q;const i=e.resolveComponent("JsonItem",!0),s=e.resolveComponent("el-form-item"),d=e.resolveComponent("el-button"),h=e.resolveComponent("el-icon-delete"),f=e.resolveComponent("el-icon"),p=e.resolveComponent("el-col"),_=e.resolveComponent("FormItem"),C=e.resolveComponent("el-icon-copy-document"),k=e.resolveComponent("draggable");return e.openBlock(),e.createBlock(k,{list:o.formItems,"item-key":"name",group:"people",disabled:!o.hideBorder,class:e.normalizeClass(["draggable-item",{showBorder:o.hideBorder,cur:l.curIndex==(o.formItems.name||((q=(N=(B=o.formItems)==null?void 0:B.options)==null?void 0:N.items[0])==null?void 0:q.name))}]),"ghost-class":"draggable-ghost"},{item:e.withCtx(({element:F,index:V})=>{var j,U;return[l.hideHandle(F)?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(p,{key:0,span:["list"].includes(F.component)?24:F.span||24,class:e.normalizeClass({borderItem:o.hideBorder,cur:o.hideBorder&&l.curIndex==(F.name||((U=(j=F==null?void 0:F.options)==null?void 0:j.items[0])==null?void 0:U.name))}),onClickCapture:L=>l.changeClick(F)},{default:e.withCtx(()=>{var L,R;return[["object"].includes(F.component)?(e.openBlock(),e.createBlock(s,{key:0,label:F.label,onClickCapture:H=>l.changeClick(F)},{default:e.withCtx(()=>[e.createVNode(i,{formItems:F.value,form:o.form[F.name],class:"object-item",custom:o.custom,hideBorder:o.hideBorder,onCurClick:l.changeClick},e.createSlots({_:2},[e.renderList(o.custom,H=>({name:H.component,fn:e.withCtx(({itemCur:W,formCur:J})=>[e.renderSlot(t.$slots,H.component,{itemCur:W,formCur:J},void 0,!0)])}))]),1032,["formItems","form","custom","hideBorder","onCurClick"])]),_:2},1032,["label","onClickCapture"])):["list"].includes(F.component)?(e.openBlock(),e.createBlock(s,{key:1,onClickCapture:H=>l.changeClick(F)},{label:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(F.label)+" ",1),o.hideBorder?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(d,{key:0,type:"primary",class:"add-btn",plain:"",size:"small",icon:"el-icon-plus",onClick:H=>l.addListItem(F.value)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.$t("btn.add")),1)]),_:2},1032,["onClick"]))]),default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(F.value,(H,W)=>(e.openBlock(),e.createBlock(p,{span:F.span||24},{default:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass(["list-item",{borderItem:o.hideBorder}])},[o.form[F.name]?(e.openBlock(),e.createBlock(i,{key:0,formItems:H,custom:o.custom,form:o.form[F.name][W],hideBorder:o.hideBorder,onCurClick:l.changeClick},e.createSlots({_:2},[e.renderList(o.custom,J=>({name:J.component,fn:e.withCtx(({itemCur:K,formCur:ee})=>[e.renderSlot(t.$slots,J.component,{itemCur:K,formCur:ee},void 0,!0)])}))]),1032,["formItems","custom","form","hideBorder","onCurClick"])):e.createCommentVNode("",!0),!o.hideBorder&&F.value.length>1?(e.openBlock(),e.createBlock(f,{key:1,class:"remove-btn",size:"14",onClick:J=>l.deleteListItem(F.value,W)},{default:e.withCtx(()=>[e.createVNode(h)]),_:2},1032,["onClick"])):e.createCommentVNode("",!0)],2)]),_:2},1032,["span"]))),256))]),_:2},1032,["onClickCapture"])):(e.openBlock(),e.createBlock(_,{key:2,item:F,form:o.form},e.createSlots({_:2},[["input","upload","checkbox","checkboxGroup","switch","select","treeSelect","cascader","date","number","radio","color","rate","slider","tags"].includes(F.component)?void 0:{name:F.component,fn:e.withCtx(()=>[e.renderSlot(t.$slots,F.component,{itemCur:F,formCur:o.form},void 0,!0)]),key:"0"}]),1032,["item","form"])),o.hideBorder&&l.curIndex==(F.name||((R=(L=F==null?void 0:F.options)==null?void 0:L.items[0])==null?void 0:R.name))?(e.openBlock(),e.createElementBlock("div",c_,[e.createVNode(f,{class:"btn",size:"14",onClick:H=>l.copyItem(F,V),title:"复制"},{default:e.withCtx(()=>[e.createVNode(C)]),_:2},1032,["onClick"]),e.createVNode(f,{class:"btn",size:"14",onClick:H=>l.deleteItem(V),title:"删除"},{default:e.withCtx(()=>[e.createVNode(h)]),_:2},1032,["onClick"])])):e.createCommentVNode("",!0)]}),_:2},1032,["span","class","onClickCapture"]))]}),_:3},8,["list","disabled","class"])}const u_=le(s_,[["render",d_],["__scopeId","data-v-fc71052f"]]),h_={name:"TreeItem",components:{draggable:Gt},props:{formItems:{type:Object,default:[]}},computed:{curIndex(){var t;return((t=this.$store.state)==null?void 0:t.curIndex)||""}},emits:["curClick"],methods:{deleteItem(t){this.formItems.splice(t,1)},copyItem(t,n){let o=JSON.parse(JSON.stringify(t));o.name=`${t.component}-${this.$tool.getUUID("",2)}`,this.formItems.splice(n+1,0,o)}}},f_={class:"form-item"},p_={class:"tool-list"},m_={key:1,class:"list-item"},g_={class:"form-item"},b_={class:"tool-list"},y_={key:2,class:"form-item"},__={class:"tool-list"};function k_(t,n,o,a,r,l){const i=e.resolveComponent("el-icon-copy-document"),s=e.resolveComponent("el-icon"),d=e.resolveComponent("el-icon-delete"),h=e.resolveComponent("TreeItem",!0),f=e.resolveComponent("draggable");return e.openBlock(),e.createBlock(f,{list:o.formItems,"item-key":"name",group:"people",class:"draggable-item","ghost-class":"draggable-ghost"},{item:e.withCtx(({element:p,index:_})=>{var C,k,B,N,q,F;return[e.createElementVNode("div",null,[["object"].includes(p.component)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("div",f_,[e.createTextVNode(e.toDisplayString(p.label),1),e.createElementVNode("span",null,"「"+e.toDisplayString(p.name||((k=(C=p.options)==null?void 0:C.items[0])==null?void 0:k.name))+"」",1),e.createElementVNode("div",p_,[e.createVNode(s,{class:"btn",size:"14",onClick:V=>l.copyItem(p,_),title:"复制"},{default:e.withCtx(()=>[e.createVNode(i)]),_:2},1032,["onClick"]),e.createVNode(s,{class:"btn",size:"14",onClick:V=>l.deleteItem(_),title:"删除"},{default:e.withCtx(()=>[e.createVNode(d)]),_:2},1032,["onClick"])])]),e.createVNode(h,{formItems:p.value},null,8,["formItems"])],64)):["list"].includes(p.component)?(e.openBlock(),e.createElementBlock("div",m_,[e.createElementVNode("div",g_,[e.createTextVNode(e.toDisplayString(p.label),1),e.createElementVNode("span",null,"「"+e.toDisplayString(p.name||((N=(B=p.options)==null?void 0:B.items[0])==null?void 0:N.name))+"」",1),e.createElementVNode("div",b_,[e.createVNode(s,{class:"btn",size:"14",onClick:V=>l.copyItem(p,_),title:"复制"},{default:e.withCtx(()=>[e.createVNode(i)]),_:2},1032,["onClick"]),e.createVNode(s,{class:"btn",size:"14",onClick:V=>l.deleteItem(_),title:"删除"},{default:e.withCtx(()=>[e.createVNode(d)]),_:2},1032,["onClick"])])]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p.value,V=>(e.openBlock(),e.createBlock(h,{formItems:V},null,8,["formItems"]))),256))])):(e.openBlock(),e.createElementBlock("div",y_,[e.createTextVNode(e.toDisplayString(p.label),1),e.createElementVNode("span",null,"「"+e.toDisplayString(p.name||((F=(q=p.options)==null?void 0:q.items[0])==null?void 0:F.name))+"」",1),e.createElementVNode("div",__,[e.createVNode(s,{class:"btn",size:"14",onClick:V=>l.copyItem(p,_),title:"复制"},{default:e.withCtx(()=>[e.createVNode(i)]),_:2},1032,["onClick"]),e.createVNode(s,{class:"btn",size:"14",onClick:V=>l.deleteItem(_),title:"删除"},{default:e.withCtx(()=>[e.createVNode(d)]),_:2},1032,["onClick"])])]))])]}),_:1},8,["list"])}const w_={name:"StatsConfig",components:{TreeItem:le(h_,[["render",k_],["__scopeId","data-v-91979609"]])},data(){return{tagVisible:{},hideForm:{},tagValue:"",filter:[{label:"等于",value:"=="},{label:"大于",value:">"},{label:"大于等于",value:">="},{label:"小于",value:"<"},{label:"小于等于",value:"<="},{label:"不等于",value:"!="}],rules:[{label:"必填",required:!0,message:"请输入",trigger:"blur"},{label:"必选",required:!0,message:"请选择",trigger:"change"}]}},props:{item:{type:Object,default:()=>({})},config:{type:Object,default:()=>({})}},watch:{hideForm:{handler(t){if(!(t!=null&&t.label)||!t.filter||!t.value){this.item.hideHandle="";return}this.item.hideHandle=`$.${t.label} ${t.filter} ${t.value}`},deep:!0},item:{handler(t){if(t!=null&&t.hideHandle){const n=/^\$\.(\S+)\s+(\S+)\s+(\S+)$/,o=t==null?void 0:t.hideHandle.match(n);if(o){const a={label:o[1],filter:o[2],value:o[3]};this.hideForm=a}}},deep:!0}},computed:{strList(){function t(o){const a=r=>{var i;let l={label:r.label,value:r.name||r.label};return r.component==="object"||r.component==="list"?l.children=(r.value||[]).map(s=>Array.isArray(s)?s.map(a):a(s)).flat():(r.component==="checkbox"||r.component==="upload")&&(l.value=(i=r.options)==null?void 0:i.items[0].name),l};return o.formItems.map(a)}return t(this.config)}},methods:{tagClose(t,n){n.splice(n.indexOf(t),1)},tagInputConfirm(t,n){this.tagValue&&(n=n||[],n.push(this.tagValue)),this.tagVisible[t.name]=!1,this.tagValue=""}}},V_={class:"form-body"},C_={class:"form-body"},x_={class:"form-slider"},N_={key:1,class:"form-title"},B_={key:2,class:"form-body"},S_={class:"tags-list"},E_={class:"form-item"},T_={class:"form-body"},I_={class:"input-body"},D_={class:"form-body"};function F_(t,n,o,a,r,l){const i=e.resolveComponent("el-input"),s=e.resolveComponent("el-form-item"),d=e.resolveComponent("el-switch"),h=e.resolveComponent("el-slider"),f=e.resolveComponent("el-option"),p=e.resolveComponent("el-select"),_=e.resolveComponent("el-input-number"),C=e.resolveComponent("el-icon-delete"),k=e.resolveComponent("el-icon"),B=e.resolveComponent("el-button"),N=e.resolveComponent("el-tag"),q=e.resolveComponent("el-col"),F=e.resolveComponent("el-row"),V=e.resolveComponent("el-icon-question-filled"),j=e.resolveComponent("el-tooltip"),U=e.resolveComponent("el-cascader"),L=e.resolveComponent("TreeItem"),R=e.resolveComponent("el-form");return e.openBlock(),e.createBlock(R,{model:o.item,class:"form-list","label-position":"top"},{default:e.withCtx(()=>{var H,W,J,K,ee,ie;return[o.item.component?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[n[38]||(n[38]=e.createElementVNode("div",{class:"form-title"},"基础配置",-1)),e.createElementVNode("div",V_,[o.item.component=="checkbox"||o.item.component=="upload"?(e.openBlock(),e.createBlock(s,{key:0,label:"属性名称"},{default:e.withCtx(()=>{var O;return[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((O=o.item)==null?void 0:O.options.items,(E,m)=>(e.openBlock(),e.createBlock(i,{modelValue:E.name,"onUpdate:modelValue":A=>E.name=A,placeholder:"请输入",clearable:""},null,8,["modelValue","onUpdate:modelValue"]))),256))]}),_:1})):(e.openBlock(),e.createBlock(s,{key:1,label:"属性名称"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.name,"onUpdate:modelValue":n[0]||(n[0]=O=>o.item.name=O),placeholder:"请输入",clearable:""},null,8,["modelValue"])]),_:1})),e.createVNode(s,{label:"标题"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.label,"onUpdate:modelValue":n[1]||(n[1]=O=>o.item.label=O),placeholder:"请输入",clearable:""},null,8,["modelValue"])]),_:1}),(H=o.item)!=null&&H.options&&o.item.component!="checkbox"&&o.item.component!="upload"?(e.openBlock(),e.createBlock(s,{key:2,label:"输入提示"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.options.placeholder,"onUpdate:modelValue":n[2]||(n[2]=O=>o.item.options.placeholder=O),placeholder:"请输入",clearable:""},null,8,["modelValue"])]),_:1})):e.createCommentVNode("",!0),(W=o.item)!=null&&W.options&&o.item.component!="checkbox"&&o.item.component!="upload"?(e.openBlock(),e.createBlock(s,{key:3,label:"禁用"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:o.item.options.disabled,"onUpdate:modelValue":n[3]||(n[3]=O=>o.item.options.disabled=O),"active-text":"启用","inactive-text":"禁用"},null,8,["modelValue"])]),_:1})):e.createCommentVNode("",!0),e.createVNode(s,{label:"内容提示"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.tips,"onUpdate:modelValue":n[4]||(n[4]=O=>o.item.tips=O),type:"textarea",placeholder:"请输入",clearable:""},null,8,["modelValue"])]),_:1})]),(J=o.item)!=null&&J.span?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[n[34]||(n[34]=e.createElementVNode("div",{class:"form-title"},"布局配置",-1)),e.createElementVNode("div",C_,[e.createVNode(s,{label:"栅格"},{default:e.withCtx(()=>[e.createElementVNode("div",x_,[e.createVNode(h,{modelValue:o.item.span,"onUpdate:modelValue":n[5]||(n[5]=O=>o.item.span=O),step:4,"show-stops":"",min:4,max:24},null,8,["modelValue"])])]),_:1})])],64)):e.createCommentVNode("",!0),(K=o.item)!=null&&K.options?(e.openBlock(),e.createElementBlock("div",N_,"组件属性配置")):e.createCommentVNode("",!0),(ee=o.item)!=null&&ee.options?(e.openBlock(),e.createElementBlock("div",B_,[o.item.component==="input"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[o.item.options.type!="textarea"?(e.openBlock(),e.createBlock(s,{key:0,label:"输入类型"},{default:e.withCtx(()=>[e.createVNode(p,{modelValue:o.item.options.type,"onUpdate:modelValue":n[6]||(n[6]=O=>o.item.options.type=O),placeholder:"请选择输入类型"},{default:e.withCtx(()=>[e.createVNode(f,{label:"文本",value:"text"}),e.createVNode(f,{label:"密码",value:"password"}),e.createVNode(f,{label:"邮箱",value:"email"})]),_:1},8,["modelValue"])]),_:1})):e.createCommentVNode("",!0),e.createVNode(s,{label:"最大长度"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:o.item.options.maxlength,"onUpdate:modelValue":n[7]||(n[7]=O=>o.item.options.maxlength=O),min:1,"controls-position":"right",placeholder:"请输入"},null,8,["modelValue"])]),_:1})],64)):e.createCommentVNode("",!0),["select","radio","checkbox","checkboxGroup"].includes(o.item.component)?(e.openBlock(),e.createBlock(s,{key:1,label:"选项"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.item.options.items,(O,E)=>(e.openBlock(),e.createElementBlock("div",{key:E,class:"form-item"},[["checkbox"].includes(o.item.component)?(e.openBlock(),e.createBlock(i,{key:0,modelValue:O.name,"onUpdate:modelValue":m=>O.name=m,placeholder:"属性名称",clearable:""},null,8,["modelValue","onUpdate:modelValue"])):e.createCommentVNode("",!0),e.createVNode(i,{modelValue:O.label,"onUpdate:modelValue":m=>O.label=m,placeholder:"选项名称",clearable:""},null,8,["modelValue","onUpdate:modelValue"]),e.createVNode(i,{modelValue:O.value,"onUpdate:modelValue":m=>O.value=m,placeholder:"选项值",clearable:""},null,8,["modelValue","onUpdate:modelValue"]),o.item.options.items.length>1?(e.openBlock(),e.createBlock(k,{key:1,class:"remove-btn",size:"14",onClick:m=>o.item.options.items.splice(E,1)},{default:e.withCtx(()=>[e.createVNode(C)]),_:2},1032,["onClick"])):e.createCommentVNode("",!0)]))),128)),e.createVNode(B,{type:"primary",size:"small",style:{width:"100%"},onClick:n[8]||(n[8]=O=>o.item.options.items.push({label:"",value:""}))},{default:e.withCtx(()=>n[35]||(n[35]=[e.createTextVNode("新增选项")])),_:1})]),_:1})):e.createCommentVNode("",!0),["tags"].includes(o.item.component)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createVNode(s,{label:"按钮名称"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.options.addText,"onUpdate:modelValue":n[9]||(n[9]=O=>o.item.options.addText=O),placeholder:"请输入",clearable:""},null,8,["modelValue"])]),_:1}),e.createVNode(s,{label:"默认标签"},{default:e.withCtx(()=>[e.createElementVNode("div",S_,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.item.value,O=>(e.openBlock(),e.createBlock(N,{key:O,closable:"","disable-transitions":!1,onClose:E=>l.tagClose(O,o.item.value)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(O),1)]),_:2},1032,["onClose"]))),128)),r.tagVisible[o.item.name]?(e.openBlock(),e.createBlock(i,{key:0,modelValue:r.tagValue,"onUpdate:modelValue":n[10]||(n[10]=O=>r.tagValue=O),class:"w-20",size:"small",onKeyup:n[11]||(n[11]=e.withKeys(O=>l.tagInputConfirm(o.item,o.item.value),["enter"])),onBlur:n[12]||(n[12]=O=>l.tagInputConfirm(o.item,o.item.value))},null,8,["modelValue"])):(e.openBlock(),e.createBlock(B,{key:1,class:"button-new-tag",size:"small",onClick:n[13]||(n[13]=O=>r.tagVisible[o.item.name]=!0)},{default:e.withCtx(()=>n[36]||(n[36]=[e.createTextVNode(" + 添加 ")])),_:1}))])]),_:1})],64)):e.createCommentVNode("",!0),o.item.component==="switch"?(e.openBlock(),e.createBlock(s,{key:3,label:"开关文字"},{default:e.withCtx(()=>[e.createElementVNode("div",E_,[e.createVNode(i,{modelValue:o.item.options.activeText,"onUpdate:modelValue":n[14]||(n[14]=O=>o.item.options.activeText=O),placeholder:"开文字",clearable:""},null,8,["modelValue"]),e.createVNode(i,{modelValue:o.item.options.inactiveText,"onUpdate:modelValue":n[15]||(n[15]=O=>o.item.options.inactiveText=O),placeholder:"关文字",clearable:""},null,8,["modelValue"])])]),_:1})):e.createCommentVNode("",!0),["rate","number"].includes(o.item.component)?(e.openBlock(),e.createBlock(F,{key:4,gutter:10},{default:e.withCtx(()=>[e.createVNode(q,{span:12},{default:e.withCtx(()=>[e.createVNode(s,{label:"最小值"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:o.item.options.min,"onUpdate:modelValue":n[16]||(n[16]=O=>o.item.options.min=O),"controls-position":"right",placeholder:"最小值"},null,8,["modelValue"])]),_:1})]),_:1}),e.createVNode(q,{span:12},{default:e.withCtx(()=>[e.createVNode(s,{label:"最大值"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:o.item.options.max,"onUpdate:modelValue":n[17]||(n[17]=O=>o.item.options.max=O),"controls-position":"right",placeholder:"最大值"},null,8,["modelValue"])]),_:1})]),_:1}),e.createVNode(q,{span:12},{default:e.withCtx(()=>[e.createVNode(s,{label:"步长"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:o.item.options.step,"onUpdate:modelValue":n[18]||(n[18]=O=>o.item.options.step=O),"controls-position":"right",placeholder:"步长"},null,8,["modelValue"])]),_:1})]),_:1}),e.createVNode(q,{span:12},{default:e.withCtx(()=>[o.item.component=="number"?(e.openBlock(),e.createBlock(s,{key:0,label:"后缀"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:o.item.options.suffix,"onUpdate:modelValue":n[19]||(n[19]=O=>o.item.options.suffix=O),"controls-position":"right",placeholder:"后缀"},null,8,["modelValue"])]),_:1})):e.createCommentVNode("",!0)]),_:1})]),_:1})):e.createCommentVNode("",!0),o.item.component==="upload"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:5},e.renderList((ie=o.item)==null?void 0:ie.options.items,(O,E)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:E},[e.createVNode(F,{gutter:10},{default:e.withCtx(()=>[e.createVNode(q,{span:12},{default:e.withCtx(()=>[e.createVNode(s,{label:"宽"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:o.item.width,"onUpdate:modelValue":n[20]||(n[20]=m=>o.item.width=m),min:1,"controls-position":"right",placeholder:"宽"},null,8,["modelValue"])]),_:1})]),_:1}),e.createVNode(q,{span:12},{default:e.withCtx(()=>[e.createVNode(s,{label:"高"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:o.item.height,"onUpdate:modelValue":n[21]||(n[21]=m=>o.item.height=m),min:1,"controls-position":"right",placeholder:"高"},null,8,["modelValue"])]),_:1})]),_:1}),e.createVNode(q,{span:12},{default:e.withCtx(()=>[e.createVNode(s,{label:"数量限制"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:O.limit,"onUpdate:modelValue":m=>O.limit=m,min:1,"controls-position":"right",placeholder:"文件数量"},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024)]),_:2},1024),e.createVNode(q,{span:12},{default:e.withCtx(()=>[e.createVNode(s,{label:"文件大小"},{default:e.withCtx(()=>[e.createVNode(_,{modelValue:O.maxSize,"onUpdate:modelValue":m=>O.maxSize=m,min:1,"controls-position":"right",placeholder:"文件大小"},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024)]),_:2},1024)]),_:2},1024),e.createVNode(s,null,{label:e.withCtx(()=>[n[37]||(n[37]=e.createTextVNode(" 文件类型 ")),e.createVNode(j,{content:"不填默认类型image/gif, image/jpeg, image/png"},{default:e.withCtx(()=>[e.createVNode(k,null,{default:e.withCtx(()=>[e.createVNode(V)]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(i,{modelValue:O.accept,"onUpdate:modelValue":m=>O.accept=m,placeholder:"请输入文件类型,如 .jpg,.png",clearable:""},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024),e.createVNode(s,{label:"上传文案"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:O.label,"onUpdate:modelValue":m=>O.label=m,placeholder:"请输入",clearable:""},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024),e.createVNode(s,{label:"提示文案"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:O.tip,"onUpdate:modelValue":m=>O.tip=m,placeholder:"请输入",clearable:""},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024),e.createVNode(s,{label:"禁用"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:O.disabled,"onUpdate:modelValue":m=>O.disabled=m,"active-text":"启用","inactive-text":"禁用"},null,8,["modelValue","onUpdate:modelValue"])]),_:2},1024)],64))),128)):e.createCommentVNode("",!0),o.item.component==="date"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:6},[e.createVNode(s,{label:"日期类型"},{default:e.withCtx(()=>[e.createVNode(p,{modelValue:o.item.options.type,"onUpdate:modelValue":n[22]||(n[22]=O=>o.item.options.type=O),placeholder:"请选择日期类型"},{default:e.withCtx(()=>[e.createVNode(f,{label:"日期",value:"date"}),e.createVNode(f,{label:"日期时间",value:"datetime"}),e.createVNode(f,{label:"周",value:"week"}),e.createVNode(f,{label:"月份",value:"month"}),e.createVNode(f,{label:"年",value:"year"}),e.createVNode(f,{label:"日期范围",value:"daterange"}),e.createVNode(f,{label:"日期时间范围",value:"datetimerange"})]),_:1},8,["modelValue"])]),_:1}),e.createVNode(s,{label:"开始占位符"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.options.startPlaceholder,"onUpdate:modelValue":n[23]||(n[23]=O=>o.item.options.startPlaceholder=O),placeholder:"请输入开始占位符",clearable:""},null,8,["modelValue"])]),_:1}),e.createVNode(s,{label:"结束占位符"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.options.endPlaceholder,"onUpdate:modelValue":n[24]||(n[24]=O=>o.item.options.endPlaceholder=O),placeholder:"请输入结束占位符",clearable:""},null,8,["modelValue"])]),_:1}),e.createVNode(s,{label:"日期格式"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.options.format,"onUpdate:modelValue":n[25]||(n[25]=O=>o.item.options.format=O),placeholder:"请输入日期格式",clearable:""},null,8,["modelValue"])]),_:1}),e.createVNode(s,{label:"值格式"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.options.valueFormat,"onUpdate:modelValue":n[26]||(n[26]=O=>o.item.options.valueFormat=O),placeholder:"请输入值格式",clearable:""},null,8,["modelValue"])]),_:1}),e.createVNode(s,{label:"快捷选项"},{default:e.withCtx(()=>[e.createVNode(d,{modelValue:o.item.options.shortcuts,"onUpdate:modelValue":n[27]||(n[27]=O=>o.item.options.shortcuts=O),"active-text":"启用","inactive-text":"禁用"},null,8,["modelValue"])]),_:1})],64)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),n[39]||(n[39]=e.createElementVNode("div",{class:"form-title"},"表单校验",-1)),e.createElementVNode("div",T_,[e.createVNode(s,{label:"提交校验"},{default:e.withCtx(()=>[e.createVNode(p,{modelValue:o.item.rules,"onUpdate:modelValue":n[28]||(n[28]=O=>o.item.rules=O),multiple:"","value-key":"label",clearable:"",placeholder:"请选择"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.rules,O=>(e.openBlock(),e.createBlock(f,{key:O.label,label:O.label,value:O},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),e.createVNode(s,{label:"隐藏校验(满足条件时将隐藏该项)"},{default:e.withCtx(()=>[e.createElementVNode("div",I_,[e.createVNode(U,{modelValue:r.hideForm.label,"onUpdate:modelValue":n[29]||(n[29]=O=>r.hideForm.label=O),"show-all-levels":!1,props:{emitPath:!1},style:{flex:"1.2"},options:l.strList},null,8,["modelValue","options"]),e.createVNode(p,{modelValue:r.hideForm.filter,"onUpdate:modelValue":n[30]||(n[30]=O=>r.hideForm.filter=O),clearable:"",style:{flex:"1"},placeholder:"条件"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.filter,O=>(e.openBlock(),e.createBlock(f,{key:O.label,label:O.label,value:O.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"]),e.createVNode(i,{modelValue:r.hideForm.value,"onUpdate:modelValue":n[31]||(n[31]=O=>r.hideForm.value=O),style:{flex:"1"},placeholder:"值",clearable:""},null,8,["modelValue"])])]),_:1})])],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[n[40]||(n[40]=e.createElementVNode("div",{class:"form-title"},"表单样式",-1)),e.createElementVNode("div",D_,[e.createVNode(s,{label:"标题宽度"},{default:e.withCtx(()=>[e.createVNode(i,{modelValue:o.item.labelWidth,"onUpdate:modelValue":n[32]||(n[32]=O=>o.item.labelWidth=O),placeholder:"请输入",clearable:""},null,8,["modelValue"])]),_:1}),e.createVNode(s,{label:"标题位置"},{default:e.withCtx(()=>[e.createVNode(p,{modelValue:o.item.labelPosition,"onUpdate:modelValue":n[33]||(n[33]=O=>o.item.labelPosition=O),placeholder:"请选择"},{default:e.withCtx(()=>[e.createVNode(f,{label:"顶部",value:"top"}),e.createVNode(f,{label:"左",value:"left"}),e.createVNode(f,{label:"右",value:"right"})]),_:1},8,["modelValue"])]),_:1})]),n[41]||(n[41]=e.createElementVNode("div",{class:"form-title"},"数据层级",-1)),e.createVNode(L,{formItems:o.config.formItems},null,8,["formItems"])],64))]}),_:1},8,["model"])}const q_=le(w_,[["render",F_],["__scopeId","data-v-21c6d3c4"]]),Wt=[{title:"布局组件",list:[{label:"组合",name:"object",value:[],component:"object",span:24},{label:"列表",name:"list",value:[[]],component:"list",span:24},{label:"标题",span:24,component:"divider"}]},{title:"基础组件",list:[{label:"单行输入",name:"input",value:"",component:"input",span:24,options:{placeholder:"请输入"}},{label:"多行输入",name:"textarea",value:"",component:"input",span:24,options:{type:"textarea",placeholder:"请输入"}},{label:"数值",name:"number",value:0,options:{},span:24,component:"number"},{label:"颜色",name:"color",value:"",span:24,component:"color"},{label:"标签",name:"tags",value:[],span:24,options:{addText:"添加"},component:"tags"}]},{title:"是否选项",list:[{label:"开关",name:"switch",span:24,options:{},value:!1,component:"switch"},{label:"下拉选择",name:"select",value:"",component:"select",span:24,options:{placeholder:"请选择",items:[{label:"选项1",value:"1"}]}}]},{title:"单选多选",list:[{label:"单选",name:"radio",value:"",component:"radio",span:24,options:{items:[{label:"选项1",value:"1"}]}},{label:"多选框",name:"checkboxGroup",component:"checkboxGroup",span:24,value:[],options:{items:[{label:"选项1",value:"1"}]}},{label:"下拉多选",name:"select",value:"",component:"select",span:24,options:{placeholder:"请选择",multiple:!0,items:[{label:"选项1",value:"1"}]}},{label:"下拉单选",name:"select",value:"",component:"select",span:24,options:{placeholder:"请选择",items:[{label:"选项1",value:"1"}]}}]},{title:"文件上传",list:[{label:"图片单张",component:"upload",span:24,width:148,height:148,options:{items:[{label:"请选择",name:"img1",value:""}]}},{label:"图片多张",component:"upload",span:24,width:148,height:148,options:{items:[{label:"请选择",multiple:!0,maxSize:100,limit:6,name:"img2",returnFile:"url",value:[]}]}},{label:"视屏单个",component:"upload",span:24,width:148,height:148,options:{items:[{label:"请选择",accept:"video/mp4",name:"videos",value:""}]}},{label:"视屏多个",component:"upload",span:24,width:148,height:148,options:{items:[{label:"请选择",accept:"video/mp4",multiple:!0,maxSize:100,limit:6,returnFile:"url",name:"videos3",value:[]}]}}]},{title:"时间日期",list:[{label:"日期范围",name:"date",value:"",component:"date",span:24,options:{type:"daterange",startPlaceholder:"开始时间",endPlaceholder:"结束时间",valueFormat:"YYYY-MM-DD HH:mm:ss"}},{label:"日期时间",name:"date1",value:"",component:"date",span:24,options:{type:"datetime",valueFormat:"YYYY-MM-DD HH:mm:ss"}},{label:"日期",name:"date2",value:"",component:"date",span:24,options:{type:"date",valueFormat:"YYYY-MM-DD"}},{label:"年",name:"date4",value:"",component:"date",span:24,options:{type:"year"}},{label:"月",name:"date5",value:"",component:"date",span:24,options:{type:"month"}},{label:"周",name:"date6",value:"",component:"date",span:24,options:{type:"week",format:"[Week] ww"}}]}],A_={components:{JsonItem:u_,StatsConfig:q_,draggable:Gt},props:{modelValue:{type:Object,default:()=>{}},config:{type:Object,default:()=>({})},maxHeight:{type:String,default:"calc(100vh - 137px)"},custom:{type:Array,default:()=>[]},loading:{type:Boolean,default:!1},hideTool:{type:Boolean,default:!0},isView:{type:Boolean,default:!1},hideBorder:{type:Boolean,default:!0}},data(){return{form:{},curItem:{},menuList:[],scrollObserverEnabled:!0,renderLoading:!1,activeNames:"布局组件"}},emits:["update:config","update:modelValue"],watch:{modelValue:{handler(t,n){this.hasConfig&&(this.form=t)},deep:!0},config:{handler(t){this.render(t),this.$emit("update:config",t)},immediate:!0,deep:!0},custom:{handler(t){if(this.menuList=[],t&&t.length>0){let n=Wt.findIndex(o=>o.title=="自定义组件");if(n>-1)Wt[n].list=t;else{let o={title:"自定义组件",list:t};Wt.push(o)}}this.menuList=Wt},immediate:!0,deep:!0}},computed:{hasConfig(){return Object.keys(this.config).length>0},hasValue(){return Object.keys(this.modelValue).length>0}},mounted(){this.hasConfig&&(this.render(),this.curItem=this.config)},methods:{render(t=this.config){function n(a,r){const l={};return a.forEach(i=>{var d,h,f,p;if((i.component==="checkbox"||i.component==="upload")&&((h=(d=i.options)==null?void 0:d.items)==null||h.forEach(_=>{if(!(_!=null&&_.name))return!1;l[_.name]=(r==null?void 0:r[_.name])??_.value})),!(i!=null&&i.name))return!1;let s=r==null?void 0:r[i.name];i.component==="list"?l[i.name]=((f=i.value)==null?void 0:f.map((_,C)=>(s?s=(r==null?void 0:r[i.name][C])||{}:s=[],n(_,s))))||[]:i.component==="object"?l[i.name]=n(i.value,s||{}):i.component==="number"?l[i.name]=s??(i.value!==void 0?Number(i.value):((p=i.options)==null?void 0:p.min)||0):l[i.name]=s??i.value}),l}let o=n(t.formItems,this.modelValue);this.form=this.parseNestedObject(o),this.$emit("update:modelValue",this.form)},parseNestedObject(t){const n={};for(const[o,a]of Object.entries(t)){const r=o.split(".");let l=n;r.forEach((i,s)=>{l[i]||(l[i]=s===r.length-1?a:{}),l=l[i]}),r.length>1&&delete t[o]}return n},validate(t,n){return this.$refs.form.validate(t,n)},clearValidate(t,n){return this.$refs.form.clearValidate()},scrollToField(t){return this.$refs.form.scrollToField(t)},resetFields(){return this.$refs.form.resetFields()},cloneItem(t){let n=JSON.parse(JSON.stringify(t));return t.component=="checkbox"||t.component=="upload"?n.options.items[0].name=`${t.component}-${this.$tool.getUUID("",2)}`:n.name=`${t.component}-${this.$tool.getUUID("",2)}`,{...n}},selectItem(t){this.curItem=t},back(){this.curItem=this.config,this.$store.state.curIndex=""}}},R_={class:"menu-list"},O_={class:"list-group-item"};function v_(t,n,o,a,r,l){const i=e.resolveComponent("draggable"),s=e.resolveComponent("el-collapse-item"),d=e.resolveComponent("el-collapse"),h=e.resolveComponent("el-aside"),f=e.resolveComponent("JsonItem"),p=e.resolveComponent("el-row"),_=e.resolveComponent("el-form"),C=e.resolveComponent("el-main"),k=e.resolveComponent("el-container"),B=e.resolveComponent("StatsConfig"),N=e.resolveDirective("loading");return e.openBlock(),e.createBlock(k,{style:e.normalizeStyle({maxHeight:o.maxHeight})},{default:e.withCtx(()=>[o.hideTool?(e.openBlock(),e.createBlock(h,{key:0,width:"200px",class:"form-json-body"},{default:e.withCtx(()=>[e.createElementVNode("div",R_,[e.createVNode(d,{modelValue:r.activeNames,"onUpdate:modelValue":n[0]||(n[0]=q=>r.activeNames=q)},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.menuList,q=>(e.openBlock(),e.createBlock(s,{title:q.title,name:q.title,class:"menu-list-title"},{default:e.withCtx(()=>[e.createVNode(i,{class:"menu-list-group",list:q.list,group:{name:"people",pull:"clone",put:!1},clone:l.cloneItem,"item-key":"name"},{item:e.withCtx(({element:F})=>[e.createElementVNode("div",O_,e.toDisplayString(F.label),1)]),_:2},1032,["list","clone"])]),_:2},1032,["title","name"]))),256))]),_:1},8,["modelValue"])])]),_:1})):e.createCommentVNode("",!0),e.createVNode(k,null,{default:e.withCtx(()=>[e.createVNode(C,{class:"form-json-body"},{default:e.withCtx(()=>[e.withDirectives((e.openBlock(),e.createBlock(_,{ref:"form",onClickCapture:n[1]||(n[1]=q=>l.back(o.config)),model:r.form,"label-width":o.config.labelWidth,"label-position":t.$i18n.locale=="en-us"?"top":o.config.labelPosition,disabled:o.isView,"element-loading-text":"Loading..."},{default:e.withCtx(()=>[e.createVNode(p,{gutter:10},{default:e.withCtx(()=>[e.createVNode(f,{formItems:o.config.formItems,hideBorder:o.hideBorder,form:r.form,custom:o.custom,onCurClick:l.selectItem},e.createSlots({_:2},[e.renderList(o.custom,q=>({name:q.component,fn:e.withCtx(({itemCur:F,formCur:V})=>[e.renderSlot(t.$slots,q.component,{itemCur:F,formCur:V},void 0,!0)])}))]),1032,["formItems","hideBorder","form","custom","onCurClick"])]),_:3})]),_:3},8,["model","label-width","label-position","disabled"])),[[N,o.loading]])]),_:3})]),_:3}),o.hideTool?(e.openBlock(),e.createBlock(h,{key:1,width:"300px",class:"aside-right"},{default:e.withCtx(()=>[e.createVNode(B,{item:r.curItem,config:o.config},null,8,["item","config"])]),_:1})):e.createCommentVNode("",!0)]),_:3},8,["style"])}const ls=le(A_,[["render",v_],["__scopeId","data-v-65cb0380"]]),P_={props:{modelValue:{type:String,default:""},width:{type:String,default:""},password:{type:Boolean,default:!1}},data(){return{isEncrypted:this.password}},computed:{encryptedText(){return"*".repeat(this.modelValue.length)},textWidth(){return this!=null&&this.width?`calc(100% - ${this.width} - 10px)`:""}},methods:{toggleEncryption(){this.isEncrypted=!this.isEncrypted,this.isEncrypted||this.$emit("update:modelValue",this.modelValue)}}};function L_(t,n,o,a,r,l){const i=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("span",{class:"item-text",style:e.normalizeStyle({width:l.textWidth})},[e.createElementVNode("span",null,e.toDisplayString(r.isEncrypted?l.encryptedText:o.modelValue),1),o.password?(e.openBlock(),e.createBlock(i,{key:0,link:"",type:"primary",icon:"el-icon-view",onClick:l.toggleEncryption},null,8,["onClick"])):e.createCommentVNode("",!0)],4)}const M_={components:{lwUpload:St,textToPassword:le(P_,[["render",L_],["__scopeId","data-v-d22eb341"]])},props:{modelValue:{type:Object,default:()=>{}},config:{type:Object,default:()=>{}},loading:{type:Boolean,default:!1},isView:{type:Boolean,default:!1}},data(){return{form:{},tagValue:"",tagVisible:!1,renderLoading:!1}},watch:{modelValue(){this.hasConfig&&this.deepMerge(this.form,JSON.parse(JSON.stringify(this.modelValue)))},config(){this.render()},form:{handler(t){this.$emit("update:modelValue",t)},deep:!0}},computed:{hasConfig(){return Object.keys(this.config).length>0},hasValue(){return Object.keys(this.modelValue).length>0}},mounted(){this.hasConfig&&this.render()},methods:{render(){this.form={},this.config.formItems.forEach(t=>{var n,o,a;if(t.component=="checkbox"||t.component=="upload")if(t.name){const r={};t==null||t.options.items.forEach(l=>{r[l.name]=l.value}),this.form[t.name]=r}else(n=t==null?void 0:t.options)!=null&&n.items&&(t==null||t.options.items.forEach(r=>{this.form[r.name]=r.value}));else(o=t==null?void 0:t.options)!=null&&o.name?(this.form[t.name]||(this.form[t.name]={}),this.form[t.name][(a=t==null?void 0:t.options)==null?void 0:a.name]=t.value):t.name&&(this.form[t.name]=t.value)}),this.hasValue&&(this.form=this.deepMerge(this.form,this.modelValue))},deepMerge(t,n){for(let o in n)if(n.hasOwnProperty(o)){const a=t[o]!==null&&t[o]!==void 0,r=n[o]!==null&&n[o]!==void 0;a&&typeof t[o]=="object"&&!Array.isArray(t[o])&&r&&typeof n[o]=="object"&&!Array.isArray(n[o])?t[o]=this.deepMerge(t[o],n[o]):r?t[o]=n[o]:r||delete t[o]}return t},hideHandle(t){return typeof t.hideHandle=="string"?new Function("form",`return ${t==null?void 0:t.hideHandle.replace(/\$/g,"form")}`)(this.form):typeof t.hideHandle=="boolean"?t.hideHandle:!1},rulesHandle(t){if(t.requiredHandle)try{const o=new Function("form",`return ${t.requiredHandle.replace(/\$/g,"form")}`)(this.form),a=t.rules.find(r=>"required"in r);a&&(a.required=o)}catch(n){console.error("Error requiredHandle function:",n)}return t.rules},getKeyToLabel(t,n=[]){let o=n.find(a=>a.value==t);return(o==null?void 0:o.label)||"--"},dayjs:$e}},U_={class:"top-title-body"},j_={class:"lw-form-view-title-name"},z_={key:12,class:"tags-list"},H_={key:14,class:"el-form-item-msg"};function K_(t,n,o,a,r,l){const i=e.resolveComponent("el-skeleton"),s=e.resolveComponent("el-col"),d=e.resolveComponent("el-icon-question-filled"),h=e.resolveComponent("el-icon"),f=e.resolveComponent("el-tooltip"),p=e.resolveComponent("textToPassword"),_=e.resolveComponent("el-image"),C=e.resolveComponent("el-cascader"),k=e.resolveComponent("el-color-picker"),B=e.resolveComponent("el-rate"),N=e.resolveComponent("el-slider"),q=e.resolveComponent("el-tag"),F=e.resolveComponent("el-row");return r.renderLoading||Object.keys(r.form).length==0?(e.openBlock(),e.createBlock(i,{key:0,animated:""})):(e.openBlock(),e.createBlock(F,{key:1,gutter:0},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.config.formItems,(V,j)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[l.hideHandle(V)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[V.component=="divider"?(e.openBlock(),e.createBlock(s,{key:0,span:V.span||24,class:e.normalizeClass({topPadding:j!==0})},{default:e.withCtx(()=>{var U;return[e.createElementVNode("div",U_,[e.createElementVNode("span",j_,e.toDisplayString(V.label),1),e.renderSlot(t.$slots,(U=V==null?void 0:V.options)==null?void 0:U.component,{},void 0,!0)])]}),_:2},1032,["span","class"])):(e.openBlock(),e.createBlock(s,{key:1,span:V.span},{default:e.withCtx(()=>{var U,L,R,H,W,J,K,ee,ie,O,E,m;return[e.createElementVNode("div",{class:e.normalizeClass(["span-item",[o.config.labelPosition]])},[V.label?(e.openBlock(),e.createElementBlock("span",{key:0,style:e.normalizeStyle({minWidth:o.config.labelWidth}),class:"title-item"},[e.createTextVNode(e.toDisplayString(V.label)+" ",1),V.tips?(e.openBlock(),e.createBlock(f,{key:0,content:V.tips},{default:e.withCtx(()=>[e.createVNode(h,null,{default:e.withCtx(()=>[e.createVNode(d)]),_:1})]),_:2},1032,["content"])):e.createCommentVNode("",!0),n[0]||(n[0]=e.createTextVNode(": "))],4)):e.createCommentVNode("",!0),V.component=="input"||V.component=="number"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[(U=V==null?void 0:V.options)!=null&&U.name?(e.openBlock(),e.createBlock(p,{key:0,modelValue:r.form[V.name][V==null?void 0:V.options.name],"onUpdate:modelValue":A=>r.form[V.name][V==null?void 0:V.options.name]=A,width:o.config.labelWidth,password:(L=V==null?void 0:V.options)==null?void 0:L.password},null,8,["modelValue","onUpdate:modelValue","width","password"])):(e.openBlock(),e.createBlock(p,{key:1,modelValue:r.form[V.name],"onUpdate:modelValue":A=>r.form[V.name]=A,password:(R=V==null?void 0:V.options)==null?void 0:R.password},null,8,["modelValue","onUpdate:modelValue","password"]))],64)):V.component=="upload"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList(V==null?void 0:V.options.items,(A,T)=>(e.openBlock(),e.createBlock(s,{key:T},{default:e.withCtx(()=>[V.name?(e.openBlock(),e.createBlock(_,{key:0,style:{width:"100px",height:"100px"},src:r.form[V.name][A.name],fit:t.contain},null,8,["src","fit"])):(e.openBlock(),e.createBlock(_,{key:1,style:{width:"100px",height:"100px"},src:r.form[A.name],fit:t.contain},null,8,["src","fit"]))]),_:2},1024))),128)):V.component=="checkbox"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[V.name?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(r.form[V.name][t._item.name]),1)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(r.form[t._item.name]),1)],64))],64)):V.component=="checkboxGroup"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[e.createTextVNode(e.toDisplayString(r.form[V.name]),1)],64)):V.component=="switch"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[(H=V==null?void 0:V.options)!=null&&H.name?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(r.form[V.name][V==null?void 0:V.options.name]?(V==null?void 0:V.options.true)||"是":(V==null?void 0:V.options.false)||"否"),1)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(r.form[V.name]?(V==null?void 0:V.options.true)||"是":(V==null?void 0:V.options.false)||"否"),1)],64))],64)):V.component=="select"||V.component=="radio"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:6},[(W=V==null?void 0:V.options)!=null&&W.name?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(l.getKeyToLabel(r.form[V.name][V==null?void 0:V.options.name],V==null?void 0:V.options.items)),1)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(l.getKeyToLabel(r.form[V.name],V==null?void 0:V.options.items)),1)],64))],64)):V.component=="cascader"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:7},[(J=V==null?void 0:V.options)!=null&&J.name?(e.openBlock(),e.createBlock(C,{key:0,modelValue:r.form[V.name][V==null?void 0:V.options.name],"onUpdate:modelValue":A=>r.form[V.name][V==null?void 0:V.options.name]=A,options:V==null?void 0:V.options.items,clearable:""},null,8,["modelValue","onUpdate:modelValue","options"])):(e.openBlock(),e.createBlock(C,{key:1,modelValue:r.form[V.name],"onUpdate:modelValue":A=>r.form[V.name]=A,options:V==null?void 0:V.options.items,clearable:""},null,8,["modelValue","onUpdate:modelValue","options"]))],64)):V.component=="date"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:8},[(K=V==null?void 0:V.options)!=null&&K.name?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(l.dayjs(r.form[V.name][V==null?void 0:V.options.name]).format((V==null?void 0:V.options.valueFormat)||"YYYY-MM-DD HH:mm:ss")),1)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(l.dayjs(r.form[V.name]).format((V==null?void 0:V.options.valueFormat)||"YYYY-MM-DD HH:mm:ss")),1)],64))],64)):V.component=="color"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:9},[(ee=V==null?void 0:V.options)!=null&&ee.name?(e.openBlock(),e.createBlock(k,{key:0,disabled:"",modelValue:r.form[V.name][V==null?void 0:V.options.name],"onUpdate:modelValue":A=>r.form[V.name][V==null?void 0:V.options.name]=A},null,8,["modelValue","onUpdate:modelValue"])):(e.openBlock(),e.createBlock(k,{key:1,disabled:"",modelValue:r.form[V.name],"onUpdate:modelValue":A=>r.form[V.name]=A},null,8,["modelValue","onUpdate:modelValue"]))],64)):V.component=="rate"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:10},[(ie=V==null?void 0:V.options)!=null&&ie.name?(e.openBlock(),e.createBlock(B,{key:0,disabled:"",modelValue:r.form[V.name][V==null?void 0:V.options.name],"onUpdate:modelValue":A=>r.form[V.name][V==null?void 0:V.options.name]=A},null,8,["modelValue","onUpdate:modelValue"])):(e.openBlock(),e.createBlock(B,{key:1,disabled:"",modelValue:r.form[V.name],"onUpdate:modelValue":A=>r.form[V.name]=A},null,8,["modelValue","onUpdate:modelValue"]))],64)):V.component=="slider"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:11},[(O=V==null?void 0:V.options)!=null&&O.name?(e.openBlock(),e.createBlock(N,{key:0,disabled:"",modelValue:r.form[V.name][V==null?void 0:V.options.name],"onUpdate:modelValue":A=>r.form[V.name][V==null?void 0:V.options.name]=A,marks:V==null?void 0:V.options.marks},null,8,["modelValue","onUpdate:modelValue","marks"])):(e.openBlock(),e.createBlock(N,{key:1,disabled:"",modelValue:r.form[V.name],"onUpdate:modelValue":A=>r.form[V.name]=A,marks:V==null?void 0:V.options.marks},null,8,["modelValue","onUpdate:modelValue","marks"]))],64)):V.component=="tags"?(e.openBlock(),e.createElementBlock("div",z_,[(E=V==null?void 0:V.options)!=null&&E.name?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(r.form[V.name][(m=V==null?void 0:V.options)==null?void 0:m.name],A=>(e.openBlock(),e.createBlock(q,{key:A},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(A),1)]),_:2},1024))),128)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(r.form[V.name],A=>(e.openBlock(),e.createBlock(q,{key:A},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(A),1)]),_:2},1024))),128))])):e.renderSlot(t.$slots,V.component,{key:13},()=>[e.createVNode(q,{type:"danger"},{default:e.withCtx(()=>[e.createTextVNode(" ["+e.toDisplayString(V.component)+"] 没有这个默认组件也未自定义插槽内容",1)]),_:2},1024)],!0),V.message?(e.openBlock(),e.createElementBlock("div",H_,e.toDisplayString(V.message),1)):e.createCommentVNode("",!0)],2)]}),_:2},1032,["span"]))],64))],64))),256))]),_:3}))}const is=le(M_,[["render",K_],["__scopeId","data-v-a142ffc2"]]),G_={name:"lwCronSelect",props:{disabled:{type:Boolean,default:!1},modelValue:{type:String,default:""}},setup(t,{emit:n}){var p,_,C;const o=e.computed(()=>t.modelValue?t.modelValue.split(" "):["*","*","*","*","*","?"]),a=e.ref(t.modelValue),r=e.ref(!1),l=k=>{switch(k){case 3:o.value[3]="*",o.value[4]="*",o.value[5]="*";break;case 4:o.value[4]="*",o.value[5]="*";break;case 5:o.value[5]="?";break}i.value.day=[],i.value.weeks=[],i.value.month=[],i.value.timeData=""},i=e.ref({curType:o.value[4]!=="*"?4:o.value[5]==="?"?3:5,day:o.value[3]==="*"?[]:(p=o.value[3])==null?void 0:p.split(","),month:o.value[4]==="*"?[]:(_=o.value[4])==null?void 0:_.split(","),weeks:o.value[5]==="?"?[]:(C=o.value[5])==null?void 0:C.split(","),timeData:o.value[0]==="*"?"":`${o.value[2]}:${o.value[1]}:${o.value[0]}`});return{setData:i,showInput:a,visible:r,changeInt:l,changeOk:()=>{const k=i.value.timeData?i.value.timeData.split(":"):["*","*","*"];o.value[0]=k[2]==="*"?k[2]:parseInt(k[2],10).toString(),o.value[1]=k[1]==="*"?k[1]:parseInt(k[1],10).toString(),o.value[2]=k[0]==="*"?k[0]:parseInt(k[0],10).toString(),o.value[3]=i.value.day.length>0?i.value.day.toString():"*",o.value[4]=i.value.month.length>0?i.value.month.toString():"*",o.value[5]=i.value.weeks.length>0?i.value.weeks.toString():"?",o.value[3]==="*"&&o.value[5]!=="?"&&(o.value[3]="?"),a.value=`${o.value[0]} ${o.value[1]} ${o.value[2]} ${o.value[3]} ${o.value[4]} ${o.value[5]}`,n("update:modelValue",a.value),n("change"),r.value=!1},changeCron:()=>{n("update:modelValue",a.value),n("change")},changeDay:k=>{k.indexOf("L")!==-1&&(i.value.day=["L"])},changeWeeks:k=>{k.indexOf("?")!==-1&&(i.value.weeks=["?"])}}}},Y_={class:"select-model"},$_={style:{"margin-top":"10px","text-align":"right"}};function W_(t,n,o,a,r,l){const i=e.resolveComponent("el-button"),s=e.resolveComponent("el-option"),d=e.resolveComponent("el-select"),h=e.resolveComponent("el-time-picker"),f=e.resolveComponent("el-popover"),p=e.resolveComponent("el-input");return e.openBlock(),e.createBlock(p,{modelValue:a.showInput,"onUpdate:modelValue":n[6]||(n[6]=_=>a.showInput=_),placeholder:"CRON"},{append:e.withCtx(()=>[e.createVNode(f,{placement:"top",width:380,visible:a.visible,trigger:"click"},{reference:e.withCtx(()=>[e.createVNode(i,{onClick:n[0]||(n[0]=_=>a.visible=!0)},{default:e.withCtx(()=>n[7]||(n[7]=[e.createTextVNode("选择")])),_:1})]),default:e.withCtx(()=>[e.createElementVNode("div",Y_,[e.createVNode(d,{modelValue:a.setData.curType,"onUpdate:modelValue":n[1]||(n[1]=_=>a.setData.curType=_),placeholder:"选择类型",onChange:a.changeInt,style:{"margin-right":"5px","min-width":"80px",width:"80px"}},{default:e.withCtx(()=>[e.createVNode(s,{label:"每天",value:3}),e.createVNode(s,{label:"每月",value:4}),e.createVNode(s,{label:"每周",value:5})]),_:1},8,["modelValue","onChange"]),a.setData.curType===4?(e.openBlock(),e.createBlock(d,{key:0,modelValue:a.setData.day,"onUpdate:modelValue":n[2]||(n[2]=_=>a.setData.day=_),multiple:"","allow-clear":"",placeholder:"日期",onChange:a.changeDay,"max-tag-count":1,style:{"margin-right":"5px","min-width":"120px"}},{default:e.withCtx(()=>[e.createVNode(s,{label:"最后一天",value:"L"}),(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(31,_=>e.createVNode(s,{key:_,label:_,value:_,disabled:a.setData.day.indexOf("L")!==-1},null,8,["label","value","disabled"])),64))]),_:1},8,["modelValue","onChange"])):e.createCommentVNode("",!0),a.setData.curType===5?(e.openBlock(),e.createBlock(d,{key:1,modelValue:a.setData.weeks,"onUpdate:modelValue":n[3]||(n[3]=_=>a.setData.weeks=_),multiple:"","allow-clear":"",placeholder:"星期",onChange:a.changeWeeks,"max-tag-count":1,style:{"margin-right":"5px","min-width":"120px"}},{default:e.withCtx(()=>[e.createVNode(s,{label:"周日",value:"1",disabled:a.setData.weeks.indexOf("?")!==-1},null,8,["disabled"]),e.createVNode(s,{label:"周一",value:"2",disabled:a.setData.weeks.indexOf("?")!==-1},null,8,["disabled"]),e.createVNode(s,{label:"周二",value:"3",disabled:a.setData.weeks.indexOf("?")!==-1},null,8,["disabled"]),e.createVNode(s,{label:"周三",value:"4",disabled:a.setData.weeks.indexOf("?")!==-1},null,8,["disabled"]),e.createVNode(s,{label:"周四",value:"5",disabled:a.setData.weeks.indexOf("?")!==-1},null,8,["disabled"]),e.createVNode(s,{label:"周五",value:"6",disabled:a.setData.weeks.indexOf("?")!==-1},null,8,["disabled"]),e.createVNode(s,{label:"周六",value:"7",disabled:a.setData.weeks.indexOf("?")!==-1},null,8,["disabled"])]),_:1},8,["modelValue","onChange"])):e.createCommentVNode("",!0),e.createVNode(h,{modelValue:a.setData.timeData,"onUpdate:modelValue":n[4]||(n[4]=_=>a.setData.timeData=_),placeholder:"时分秒","value-format":"HH:mm:ss",style:{"min-width":"100px"}},null,8,["modelValue"])]),e.createElementVNode("div",$_,[e.createVNode(i,{onClick:n[5]||(n[5]=_=>a.visible=!1)},{default:e.withCtx(()=>n[8]||(n[8]=[e.createTextVNode("取消")])),_:1}),e.createVNode(i,{type:"primary",onClick:a.changeOk},{default:e.withCtx(()=>n[9]||(n[9]=[e.createTextVNode("确定")])),_:1},8,["onClick"])])]),_:1},8,["visible"])]),_:1},8,["modelValue"])}const ss=le(G_,[["render",W_],["__scopeId","data-v-5f87e552"]]);function xn(t){throw new Error('Could not dynamically require "'+t+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Nn,cs;function J_(){if(cs)return Nn;cs=1;function t(){this.__data__=[],this.size=0}return Nn=t,Nn}var Bn,ds;function Et(){if(ds)return Bn;ds=1;function t(n,o){return n===o||n!==n&&o!==o}return Bn=t,Bn}var Sn,us;function Jt(){if(us)return Sn;us=1;var t=Et();function n(o,a){for(var r=o.length;r--;)if(t(o[r][0],a))return r;return-1}return Sn=n,Sn}var En,hs;function Z_(){if(hs)return En;hs=1;var t=Jt(),n=Array.prototype,o=n.splice;function a(r){var l=this.__data__,i=t(l,r);if(i<0)return!1;var s=l.length-1;return i==s?l.pop():o.call(l,i,1),--this.size,!0}return En=a,En}var Tn,fs;function X_(){if(fs)return Tn;fs=1;var t=Jt();function n(o){var a=this.__data__,r=t(a,o);return r<0?void 0:a[r][1]}return Tn=n,Tn}var In,ps;function Q_(){if(ps)return In;ps=1;var t=Jt();function n(o){return t(this.__data__,o)>-1}return In=n,In}var Dn,ms;function e1(){if(ms)return Dn;ms=1;var t=Jt();function n(o,a){var r=this.__data__,l=t(r,o);return l<0?(++this.size,r.push([o,a])):r[l][1]=a,this}return Dn=n,Dn}var Fn,gs;function Zt(){if(gs)return Fn;gs=1;var t=J_(),n=Z_(),o=X_(),a=Q_(),r=e1();function l(i){var s=-1,d=i==null?0:i.length;for(this.clear();++s<d;){var h=i[s];this.set(h[0],h[1])}}return l.prototype.clear=t,l.prototype.delete=n,l.prototype.get=o,l.prototype.has=a,l.prototype.set=r,Fn=l,Fn}var qn,bs;function t1(){if(bs)return qn;bs=1;var t=Zt();function n(){this.__data__=new t,this.size=0}return qn=n,qn}var An,ys;function n1(){if(ys)return An;ys=1;function t(n){var o=this.__data__,a=o.delete(n);return this.size=o.size,a}return An=t,An}var Rn,_s;function o1(){if(_s)return Rn;_s=1;function t(n){return this.__data__.get(n)}return Rn=t,Rn}var On,ks;function r1(){if(ks)return On;ks=1;function t(n){return this.__data__.has(n)}return On=t,On}var vn,ws;function Vs(){if(ws)return vn;ws=1;var t=typeof $t=="object"&&$t&&$t.Object===Object&&$t;return vn=t,vn}var Pn,Cs;function We(){if(Cs)return Pn;Cs=1;var t=Vs(),n=typeof self=="object"&&self&&self.Object===Object&&self,o=t||n||Function("return this")();return Pn=o,Pn}var Ln,xs;function Tt(){if(xs)return Ln;xs=1;var t=We(),n=t.Symbol;return Ln=n,Ln}var Mn,Ns;function a1(){if(Ns)return Mn;Ns=1;var t=Tt(),n=Object.prototype,o=n.hasOwnProperty,a=n.toString,r=t?t.toStringTag:void 0;function l(i){var s=o.call(i,r),d=i[r];try{i[r]=void 0;var h=!0}catch{}var f=a.call(i);return h&&(s?i[r]=d:delete i[r]),f}return Mn=l,Mn}var Un,Bs;function l1(){if(Bs)return Un;Bs=1;var t=Object.prototype,n=t.toString;function o(a){return n.call(a)}return Un=o,Un}var jn,Ss;function kt(){if(Ss)return jn;Ss=1;var t=Tt(),n=a1(),o=l1(),a="[object Null]",r="[object Undefined]",l=t?t.toStringTag:void 0;function i(s){return s==null?s===void 0?r:a:l&&l in Object(s)?n(s):o(s)}return jn=i,jn}var zn,Es;function ze(){if(Es)return zn;Es=1;function t(n){var o=typeof n;return n!=null&&(o=="object"||o=="function")}return zn=t,zn}var Hn,Ts;function At(){if(Ts)return Hn;Ts=1;var t=kt(),n=ze(),o="[object AsyncFunction]",a="[object Function]",r="[object GeneratorFunction]",l="[object Proxy]";function i(s){if(!n(s))return!1;var d=t(s);return d==a||d==r||d==o||d==l}return Hn=i,Hn}var Kn,Is;function i1(){if(Is)return Kn;Is=1;var t=We(),n=t["__core-js_shared__"];return Kn=n,Kn}var Gn,Ds;function s1(){if(Ds)return Gn;Ds=1;var t=i1(),n=function(){var a=/[^.]+$/.exec(t&&t.keys&&t.keys.IE_PROTO||"");return a?"Symbol(src)_1."+a:""}();function o(a){return!!n&&n in a}return Gn=o,Gn}var Yn,Fs;function qs(){if(Fs)return Yn;Fs=1;var t=Function.prototype,n=t.toString;function o(a){if(a!=null){try{return n.call(a)}catch{}try{return a+""}catch{}}return""}return Yn=o,Yn}var $n,As;function c1(){if(As)return $n;As=1;var t=At(),n=s1(),o=ze(),a=qs(),r=/[\\^$.*+?()[\]{}|]/g,l=/^\[object .+?Constructor\]$/,i=Function.prototype,s=Object.prototype,d=i.toString,h=s.hasOwnProperty,f=RegExp("^"+d.call(h).replace(r,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function p(_){if(!o(_)||n(_))return!1;var C=t(_)?f:l;return C.test(a(_))}return $n=p,$n}var Wn,Rs;function d1(){if(Rs)return Wn;Rs=1;function t(n,o){return n==null?void 0:n[o]}return Wn=t,Wn}var Jn,Os;function wt(){if(Os)return Jn;Os=1;var t=c1(),n=d1();function o(a,r){var l=n(a,r);return t(l)?l:void 0}return Jn=o,Jn}var Zn,vs;function Xn(){if(vs)return Zn;vs=1;var t=wt(),n=We(),o=t(n,"Map");return Zn=o,Zn}var Qn,Ps;function Xt(){if(Ps)return Qn;Ps=1;var t=wt(),n=t(Object,"create");return Qn=n,Qn}var eo,Ls;function u1(){if(Ls)return eo;Ls=1;var t=Xt();function n(){this.__data__=t?t(null):{},this.size=0}return eo=n,eo}var to,Ms;function h1(){if(Ms)return to;Ms=1;function t(n){var o=this.has(n)&&delete this.__data__[n];return this.size-=o?1:0,o}return to=t,to}var no,Us;function f1(){if(Us)return no;Us=1;var t=Xt(),n="__lodash_hash_undefined__",o=Object.prototype,a=o.hasOwnProperty;function r(l){var i=this.__data__;if(t){var s=i[l];return s===n?void 0:s}return a.call(i,l)?i[l]:void 0}return no=r,no}var oo,js;function p1(){if(js)return oo;js=1;var t=Xt(),n=Object.prototype,o=n.hasOwnProperty;function a(r){var l=this.__data__;return t?l[r]!==void 0:o.call(l,r)}return oo=a,oo}var ro,zs;function m1(){if(zs)return ro;zs=1;var t=Xt(),n="__lodash_hash_undefined__";function o(a,r){var l=this.__data__;return this.size+=this.has(a)?0:1,l[a]=t&&r===void 0?n:r,this}return ro=o,ro}var ao,Hs;function g1(){if(Hs)return ao;Hs=1;var t=u1(),n=h1(),o=f1(),a=p1(),r=m1();function l(i){var s=-1,d=i==null?0:i.length;for(this.clear();++s<d;){var h=i[s];this.set(h[0],h[1])}}return l.prototype.clear=t,l.prototype.delete=n,l.prototype.get=o,l.prototype.has=a,l.prototype.set=r,ao=l,ao}var lo,Ks;function b1(){if(Ks)return lo;Ks=1;var t=g1(),n=Zt(),o=Xn();function a(){this.size=0,this.__data__={hash:new t,map:new(o||n),string:new t}}return lo=a,lo}var io,Gs;function y1(){if(Gs)return io;Gs=1;function t(n){var o=typeof n;return o=="string"||o=="number"||o=="symbol"||o=="boolean"?n!=="__proto__":n===null}return io=t,io}var so,Ys;function Qt(){if(Ys)return so;Ys=1;var t=y1();function n(o,a){var r=o.__data__;return t(a)?r[typeof a=="string"?"string":"hash"]:r.map}return so=n,so}var co,$s;function _1(){if($s)return co;$s=1;var t=Qt();function n(o){var a=t(this,o).delete(o);return this.size-=a?1:0,a}return co=n,co}var uo,Ws;function k1(){if(Ws)return uo;Ws=1;var t=Qt();function n(o){return t(this,o).get(o)}return uo=n,uo}var ho,Js;function w1(){if(Js)return ho;Js=1;var t=Qt();function n(o){return t(this,o).has(o)}return ho=n,ho}var fo,Zs;function V1(){if(Zs)return fo;Zs=1;var t=Qt();function n(o,a){var r=t(this,o),l=r.size;return r.set(o,a),this.size+=r.size==l?0:1,this}return fo=n,fo}var po,Xs;function mo(){if(Xs)return po;Xs=1;var t=b1(),n=_1(),o=k1(),a=w1(),r=V1();function l(i){var s=-1,d=i==null?0:i.length;for(this.clear();++s<d;){var h=i[s];this.set(h[0],h[1])}}return l.prototype.clear=t,l.prototype.delete=n,l.prototype.get=o,l.prototype.has=a,l.prototype.set=r,po=l,po}var go,Qs;function C1(){if(Qs)return go;Qs=1;var t=Zt(),n=Xn(),o=mo(),a=200;function r(l,i){var s=this.__data__;if(s instanceof t){var d=s.__data__;if(!n||d.length<a-1)return d.push([l,i]),this.size=++s.size,this;s=this.__data__=new o(d)}return s.set(l,i),this.size=s.size,this}return go=r,go}var bo,ec;function en(){if(ec)return bo;ec=1;var t=Zt(),n=t1(),o=n1(),a=o1(),r=r1(),l=C1();function i(s){var d=this.__data__=new t(s);this.size=d.size}return i.prototype.clear=n,i.prototype.delete=o,i.prototype.get=a,i.prototype.has=r,i.prototype.set=l,bo=i,bo}var yo,tc;function _o(){if(tc)return yo;tc=1;function t(n,o){for(var a=-1,r=n==null?0:n.length;++a<r&&o(n[a],a,n)!==!1;);return n}return yo=t,yo}var ko,nc;function oc(){if(nc)return ko;nc=1;var t=wt(),n=function(){try{var o=t(Object,"defineProperty");return o({},"",{}),o}catch{}}();return ko=n,ko}var wo,rc;function tn(){if(rc)return wo;rc=1;var t=oc();function n(o,a,r){a=="__proto__"&&t?t(o,a,{configurable:!0,enumerable:!0,value:r,writable:!0}):o[a]=r}return wo=n,wo}var Vo,ac;function nn(){if(ac)return Vo;ac=1;var t=tn(),n=Et(),o=Object.prototype,a=o.hasOwnProperty;function r(l,i,s){var d=l[i];(!(a.call(l,i)&&n(d,s))||s===void 0&&!(i in l))&&t(l,i,s)}return Vo=r,Vo}var Co,lc;function Rt(){if(lc)return Co;lc=1;var t=nn(),n=tn();function o(a,r,l,i){var s=!l;l||(l={});for(var d=-1,h=r.length;++d<h;){var f=r[d],p=i?i(l[f],a[f],f,l,a):void 0;p===void 0&&(p=a[f]),s?n(l,f,p):t(l,f,p)}return l}return Co=o,Co}var xo,ic;function x1(){if(ic)return xo;ic=1;function t(n,o){for(var a=-1,r=Array(n);++a<n;)r[a]=o(a);return r}return xo=t,xo}var No,sc;function et(){if(sc)return No;sc=1;function t(n){return n!=null&&typeof n=="object"}return No=t,No}var Bo,cc;function N1(){if(cc)return Bo;cc=1;var t=kt(),n=et(),o="[object Arguments]";function a(r){return n(r)&&t(r)==o}return Bo=a,Bo}var So,dc;function Ot(){if(dc)return So;dc=1;var t=N1(),n=et(),o=Object.prototype,a=o.hasOwnProperty,r=o.propertyIsEnumerable,l=t(function(){return arguments}())?t:function(i){return n(i)&&a.call(i,"callee")&&!r.call(i,"callee")};return So=l,So}var Eo,uc;function Be(){if(uc)return Eo;uc=1;var t=Array.isArray;return Eo=t,Eo}var vt={exports:{}},To,hc;function B1(){if(hc)return To;hc=1;function t(){return!1}return To=t,To}vt.exports;var fc;function It(){return fc||(fc=1,function(t,n){var o=We(),a=B1(),r=n&&!n.nodeType&&n,l=r&&!0&&t&&!t.nodeType&&t,i=l&&l.exports===r,s=i?o.Buffer:void 0,d=s?s.isBuffer:void 0,h=d||a;t.exports=h}(vt,vt.exports)),vt.exports}var Io,pc;function on(){if(pc)return Io;pc=1;var t=9007199254740991,n=/^(?:0|[1-9]\d*)$/;function o(a,r){var l=typeof a;return r=r??t,!!r&&(l=="number"||l!="symbol"&&n.test(a))&&a>-1&&a%1==0&&a<r}return Io=o,Io}var Do,mc;function Fo(){if(mc)return Do;mc=1;var t=9007199254740991;function n(o){return typeof o=="number"&&o>-1&&o%1==0&&o<=t}return Do=n,Do}var qo,gc;function S1(){if(gc)return qo;gc=1;var t=kt(),n=Fo(),o=et(),a="[object Arguments]",r="[object Array]",l="[object Boolean]",i="[object Date]",s="[object Error]",d="[object Function]",h="[object Map]",f="[object Number]",p="[object Object]",_="[object RegExp]",C="[object Set]",k="[object String]",B="[object WeakMap]",N="[object ArrayBuffer]",q="[object DataView]",F="[object Float32Array]",V="[object Float64Array]",j="[object Int8Array]",U="[object Int16Array]",L="[object Int32Array]",R="[object Uint8Array]",H="[object Uint8ClampedArray]",W="[object Uint16Array]",J="[object Uint32Array]",K={};K[F]=K[V]=K[j]=K[U]=K[L]=K[R]=K[H]=K[W]=K[J]=!0,K[a]=K[r]=K[N]=K[l]=K[q]=K[i]=K[s]=K[d]=K[h]=K[f]=K[p]=K[_]=K[C]=K[k]=K[B]=!1;function ee(ie){return o(ie)&&n(ie.length)&&!!K[t(ie)]}return qo=ee,qo}var Ao,bc;function rn(){if(bc)return Ao;bc=1;function t(n){return function(o){return n(o)}}return Ao=t,Ao}var Pt={exports:{}};Pt.exports;var yc;function Ro(){return yc||(yc=1,function(t,n){var o=Vs(),a=n&&!n.nodeType&&n,r=a&&!0&&t&&!t.nodeType&&t,l=r&&r.exports===a,i=l&&o.process,s=function(){try{var d=r&&r.require&&r.require("util").types;return d||i&&i.binding&&i.binding("util")}catch{}}();t.exports=s}(Pt,Pt.exports)),Pt.exports}var Oo,_c;function Lt(){if(_c)return Oo;_c=1;var t=S1(),n=rn(),o=Ro(),a=o&&o.isTypedArray,r=a?n(a):t;return Oo=r,Oo}var vo,kc;function wc(){if(kc)return vo;kc=1;var t=x1(),n=Ot(),o=Be(),a=It(),r=on(),l=Lt(),i=Object.prototype,s=i.hasOwnProperty;function d(h,f){var p=o(h),_=!p&&n(h),C=!p&&!_&&a(h),k=!p&&!_&&!C&&l(h),B=p||_||C||k,N=B?t(h.length,String):[],q=N.length;for(var F in h)(f||s.call(h,F))&&!(B&&(F=="length"||C&&(F=="offset"||F=="parent")||k&&(F=="buffer"||F=="byteLength"||F=="byteOffset")||r(F,q)))&&N.push(F);return N}return vo=d,vo}var Po,Vc;function an(){if(Vc)return Po;Vc=1;var t=Object.prototype;function n(o){var a=o&&o.constructor,r=typeof a=="function"&&a.prototype||t;return o===r}return Po=n,Po}var Lo,Cc;function xc(){if(Cc)return Lo;Cc=1;function t(n,o){return function(a){return n(o(a))}}return Lo=t,Lo}var Mo,Nc;function E1(){if(Nc)return Mo;Nc=1;var t=xc(),n=t(Object.keys,Object);return Mo=n,Mo}var Uo,Bc;function jo(){if(Bc)return Uo;Bc=1;var t=an(),n=E1(),o=Object.prototype,a=o.hasOwnProperty;function r(l){if(!t(l))return n(l);var i=[];for(var s in Object(l))a.call(l,s)&&s!="constructor"&&i.push(s);return i}return Uo=r,Uo}var zo,Sc;function rt(){if(Sc)return zo;Sc=1;var t=At(),n=Fo();function o(a){return a!=null&&n(a.length)&&!t(a)}return zo=o,zo}var Ho,Ec;function ht(){if(Ec)return Ho;Ec=1;var t=wc(),n=jo(),o=rt();function a(r){return o(r)?t(r):n(r)}return Ho=a,Ho}var Ko,Tc;function T1(){if(Tc)return Ko;Tc=1;var t=Rt(),n=ht();function o(a,r){return a&&t(r,n(r),a)}return Ko=o,Ko}var Go,Ic;function I1(){if(Ic)return Go;Ic=1;function t(n){var o=[];if(n!=null)for(var a in Object(n))o.push(a);return o}return Go=t,Go}var Yo,Dc;function D1(){if(Dc)return Yo;Dc=1;var t=ze(),n=an(),o=I1(),a=Object.prototype,r=a.hasOwnProperty;function l(i){if(!t(i))return o(i);var s=n(i),d=[];for(var h in i)h=="constructor"&&(s||!r.call(i,h))||d.push(h);return d}return Yo=l,Yo}var $o,Fc;function Vt(){if(Fc)return $o;Fc=1;var t=wc(),n=D1(),o=rt();function a(r){return o(r)?t(r,!0):n(r)}return $o=a,$o}var Wo,qc;function F1(){if(qc)return Wo;qc=1;var t=Rt(),n=Vt();function o(a,r){return a&&t(r,n(r),a)}return Wo=o,Wo}var Mt={exports:{}};Mt.exports;var Ac;function Rc(){return Ac||(Ac=1,function(t,n){var o=We(),a=n&&!n.nodeType&&n,r=a&&!0&&t&&!t.nodeType&&t,l=r&&r.exports===a,i=l?o.Buffer:void 0,s=i?i.allocUnsafe:void 0;function d(h,f){if(f)return h.slice();var p=h.length,_=s?s(p):new h.constructor(p);return h.copy(_),_}t.exports=d}(Mt,Mt.exports)),Mt.exports}var Jo,Oc;function vc(){if(Oc)return Jo;Oc=1;function t(n,o){var a=-1,r=n.length;for(o||(o=Array(r));++a<r;)o[a]=n[a];return o}return Jo=t,Jo}var Zo,Pc;function Lc(){if(Pc)return Zo;Pc=1;function t(n,o){for(var a=-1,r=n==null?0:n.length,l=0,i=[];++a<r;){var s=n[a];o(s,a,n)&&(i[l++]=s)}return i}return Zo=t,Zo}var Xo,Mc;function Uc(){if(Mc)return Xo;Mc=1;function t(){return[]}return Xo=t,Xo}var Qo,jc;function er(){if(jc)return Qo;jc=1;var t=Lc(),n=Uc(),o=Object.prototype,a=o.propertyIsEnumerable,r=Object.getOwnPropertySymbols,l=r?function(i){return i==null?[]:(i=Object(i),t(r(i),function(s){return a.call(i,s)}))}:n;return Qo=l,Qo}var tr,zc;function q1(){if(zc)return tr;zc=1;var t=Rt(),n=er();function o(a,r){return t(a,n(a),r)}return tr=o,tr}var nr,Hc;function or(){if(Hc)return nr;Hc=1;function t(n,o){for(var a=-1,r=o.length,l=n.length;++a<r;)n[l+a]=o[a];return n}return nr=t,nr}var rr,Kc;function ln(){if(Kc)return rr;Kc=1;var t=xc(),n=t(Object.getPrototypeOf,Object);return rr=n,rr}var ar,Gc;function Yc(){if(Gc)return ar;Gc=1;var t=or(),n=ln(),o=er(),a=Uc(),r=Object.getOwnPropertySymbols,l=r?function(i){for(var s=[];i;)t(s,o(i)),i=n(i);return s}:a;return ar=l,ar}var lr,$c;function A1(){if($c)return lr;$c=1;var t=Rt(),n=Yc();function o(a,r){return t(a,n(a),r)}return lr=o,lr}var ir,Wc;function Jc(){if(Wc)return ir;Wc=1;var t=or(),n=Be();function o(a,r,l){var i=r(a);return n(a)?i:t(i,l(a))}return ir=o,ir}var sr,Zc;function Xc(){if(Zc)return sr;Zc=1;var t=Jc(),n=er(),o=ht();function a(r){return t(r,o,n)}return sr=a,sr}var cr,Qc;function R1(){if(Qc)return cr;Qc=1;var t=Jc(),n=Yc(),o=Vt();function a(r){return t(r,o,n)}return cr=a,cr}var dr,ed;function O1(){if(ed)return dr;ed=1;var t=wt(),n=We(),o=t(n,"DataView");return dr=o,dr}var ur,td;function v1(){if(td)return ur;td=1;var t=wt(),n=We(),o=t(n,"Promise");return ur=o,ur}var hr,nd;function od(){if(nd)return hr;nd=1;var t=wt(),n=We(),o=t(n,"Set");return hr=o,hr}var fr,rd;function P1(){if(rd)return fr;rd=1;var t=wt(),n=We(),o=t(n,"WeakMap");return fr=o,fr}var pr,ad;function Dt(){if(ad)return pr;ad=1;var t=O1(),n=Xn(),o=v1(),a=od(),r=P1(),l=kt(),i=qs(),s="[object Map]",d="[object Object]",h="[object Promise]",f="[object Set]",p="[object WeakMap]",_="[object DataView]",C=i(t),k=i(n),B=i(o),N=i(a),q=i(r),F=l;return(t&&F(new t(new ArrayBuffer(1)))!=_||n&&F(new n)!=s||o&&F(o.resolve())!=h||a&&F(new a)!=f||r&&F(new r)!=p)&&(F=function(V){var j=l(V),U=j==d?V.constructor:void 0,L=U?i(U):"";if(L)switch(L){case C:return _;case k:return s;case B:return h;case N:return f;case q:return p}return j}),pr=F,pr}var mr,ld;function L1(){if(ld)return mr;ld=1;var t=Object.prototype,n=t.hasOwnProperty;function o(a){var r=a.length,l=new a.constructor(r);return r&&typeof a[0]=="string"&&n.call(a,"index")&&(l.index=a.index,l.input=a.input),l}return mr=o,mr}var gr,id;function sd(){if(id)return gr;id=1;var t=We(),n=t.Uint8Array;return gr=n,gr}var br,cd;function yr(){if(cd)return br;cd=1;var t=sd();function n(o){var a=new o.constructor(o.byteLength);return new t(a).set(new t(o)),a}return br=n,br}var _r,dd;function M1(){if(dd)return _r;dd=1;var t=yr();function n(o,a){var r=a?t(o.buffer):o.buffer;return new o.constructor(r,o.byteOffset,o.byteLength)}return _r=n,_r}var kr,ud;function U1(){if(ud)return kr;ud=1;var t=/\w*$/;function n(o){var a=new o.constructor(o.source,t.exec(o));return a.lastIndex=o.lastIndex,a}return kr=n,kr}var wr,hd;function j1(){if(hd)return wr;hd=1;var t=Tt(),n=t?t.prototype:void 0,o=n?n.valueOf:void 0;function a(r){return o?Object(o.call(r)):{}}return wr=a,wr}var Vr,fd;function pd(){if(fd)return Vr;fd=1;var t=yr();function n(o,a){var r=a?t(o.buffer):o.buffer;return new o.constructor(r,o.byteOffset,o.length)}return Vr=n,Vr}var Cr,md;function z1(){if(md)return Cr;md=1;var t=yr(),n=M1(),o=U1(),a=j1(),r=pd(),l="[object Boolean]",i="[object Date]",s="[object Map]",d="[object Number]",h="[object RegExp]",f="[object Set]",p="[object String]",_="[object Symbol]",C="[object ArrayBuffer]",k="[object DataView]",B="[object Float32Array]",N="[object Float64Array]",q="[object Int8Array]",F="[object Int16Array]",V="[object Int32Array]",j="[object Uint8Array]",U="[object Uint8ClampedArray]",L="[object Uint16Array]",R="[object Uint32Array]";function H(W,J,K){var ee=W.constructor;switch(J){case C:return t(W);case l:case i:return new ee(+W);case k:return n(W,K);case B:case N:case q:case F:case V:case j:case U:case L:case R:return r(W,K);case s:return new ee;case d:case p:return new ee(W);case h:return o(W);case f:return new ee;case _:return a(W)}}return Cr=H,Cr}var xr,gd;function bd(){if(gd)return xr;gd=1;var t=ze(),n=Object.create,o=function(){function a(){}return function(r){if(!t(r))return{};if(n)return n(r);a.prototype=r;var l=new a;return a.prototype=void 0,l}}();return xr=o,xr}var Nr,yd;function _d(){if(yd)return Nr;yd=1;var t=bd(),n=ln(),o=an();function a(r){return typeof r.constructor=="function"&&!o(r)?t(n(r)):{}}return Nr=a,Nr}var Br,kd;function H1(){if(kd)return Br;kd=1;var t=Dt(),n=et(),o="[object Map]";function a(r){return n(r)&&t(r)==o}return Br=a,Br}var Sr,wd;function K1(){if(wd)return Sr;wd=1;var t=H1(),n=rn(),o=Ro(),a=o&&o.isMap,r=a?n(a):t;return Sr=r,Sr}var Er,Vd;function G1(){if(Vd)return Er;Vd=1;var t=Dt(),n=et(),o="[object Set]";function a(r){return n(r)&&t(r)==o}return Er=a,Er}var Tr,Cd;function Y1(){if(Cd)return Tr;Cd=1;var t=G1(),n=rn(),o=Ro(),a=o&&o.isSet,r=a?n(a):t;return Tr=r,Tr}var Ir,xd;function Nd(){if(xd)return Ir;xd=1;var t=en(),n=_o(),o=nn(),a=T1(),r=F1(),l=Rc(),i=vc(),s=q1(),d=A1(),h=Xc(),f=R1(),p=Dt(),_=L1(),C=z1(),k=_d(),B=Be(),N=It(),q=K1(),F=ze(),V=Y1(),j=ht(),U=Vt(),L=1,R=2,H=4,W="[object Arguments]",J="[object Array]",K="[object Boolean]",ee="[object Date]",ie="[object Error]",O="[object Function]",E="[object GeneratorFunction]",m="[object Map]",A="[object Number]",T="[object Object]",qe="[object RegExp]",Y="[object Set]",Te="[object String]",Q="[object Symbol]",ce="[object WeakMap]",Ae="[object ArrayBuffer]",z="[object DataView]",$="[object Float32Array]",X="[object Float64Array]",_e="[object Int8Array]",pe="[object Int16Array]",ke="[object Int32Array]",Se="[object Uint8Array]",xe="[object Uint8ClampedArray]",Ge="[object Uint16Array]",je="[object Uint32Array]",ae={};ae[W]=ae[J]=ae[Ae]=ae[z]=ae[K]=ae[ee]=ae[$]=ae[X]=ae[_e]=ae[pe]=ae[ke]=ae[m]=ae[A]=ae[T]=ae[qe]=ae[Y]=ae[Te]=ae[Q]=ae[Se]=ae[xe]=ae[Ge]=ae[je]=!0,ae[ie]=ae[O]=ae[ce]=!1;function P(te,Ne,Ie,dt,ve,Fe){var we,me=Ne&L,v=Ne&R,Ye=Ne&H;if(Ie&&(we=ve?Ie(te,dt,ve,Fe):Ie(te)),we!==void 0)return we;if(!F(te))return te;var Ze=B(te);if(Ze){if(we=_(te),!me)return i(te,we)}else{var Pe=p(te),Xe=Pe==O||Pe==E;if(N(te))return l(te,me);if(Pe==T||Pe==W||Xe&&!ve){if(we=v||Xe?{}:k(te),!me)return v?d(te,r(we,te)):s(te,a(we,te))}else{if(!ae[Pe])return ve?te:{};we=C(te,Pe,me)}}Fe||(Fe=new t);var Qe=Fe.get(te);if(Qe)return Qe;Fe.set(te,we),V(te)?te.forEach(function(b){we.add(P(b,Ne,Ie,b,te,Fe))}):q(te)&&te.forEach(function(b,c){we.set(c,P(b,Ne,Ie,c,te,Fe))});var ut=Ye?v?f:h:v?U:j,nt=Ze?void 0:ut(te);return n(nt||te,function(b,c){nt&&(c=b,b=te[c]),o(we,c,P(b,Ne,Ie,c,te,Fe))}),we}return Ir=P,Ir}var Dr,Bd;function $1(){if(Bd)return Dr;Bd=1;var t=Nd(),n=4;function o(a){return t(a,n)}return Dr=o,Dr}var Fr,Sd;function qr(){if(Sd)return Fr;Sd=1;function t(n){return function(){return n}}return Fr=t,Fr}var Ar,Ed;function W1(){if(Ed)return Ar;Ed=1;function t(n){return function(o,a,r){for(var l=-1,i=Object(o),s=r(o),d=s.length;d--;){var h=s[n?d:++l];if(a(i[h],h,i)===!1)break}return o}}return Ar=t,Ar}var Rr,Td;function Or(){if(Td)return Rr;Td=1;var t=W1(),n=t();return Rr=n,Rr}var vr,Id;function Pr(){if(Id)return vr;Id=1;var t=Or(),n=ht();function o(a,r){return a&&t(a,r,n)}return vr=o,vr}var Lr,Dd;function J1(){if(Dd)return Lr;Dd=1;var t=rt();function n(o,a){return function(r,l){if(r==null)return r;if(!t(r))return o(r,l);for(var i=r.length,s=a?i:-1,d=Object(r);(a?s--:++s<i)&&l(d[s],s,d)!==!1;);return r}}return Lr=n,Lr}var Mr,Fd;function sn(){if(Fd)return Mr;Fd=1;var t=Pr(),n=J1(),o=n(t);return Mr=o,Mr}var Ur,qd;function Ct(){if(qd)return Ur;qd=1;function t(n){return n}return Ur=t,Ur}var jr,Ad;function Rd(){if(Ad)return jr;Ad=1;var t=Ct();function n(o){return typeof o=="function"?o:t}return jr=n,jr}var zr,Od;function vd(){if(Od)return zr;Od=1;var t=_o(),n=sn(),o=Rd(),a=Be();function r(l,i){var s=a(l)?t:n;return s(l,o(i))}return zr=r,zr}var Hr,Pd;function Ld(){return Pd||(Pd=1,Hr=vd()),Hr}var Kr,Md;function Z1(){if(Md)return Kr;Md=1;var t=sn();function n(o,a){var r=[];return t(o,function(l,i,s){a(l,i,s)&&r.push(l)}),r}return Kr=n,Kr}var Gr,Ud;function X1(){if(Ud)return Gr;Ud=1;var t="__lodash_hash_undefined__";function n(o){return this.__data__.set(o,t),this}return Gr=n,Gr}var Yr,jd;function Q1(){if(jd)return Yr;jd=1;function t(n){return this.__data__.has(n)}return Yr=t,Yr}var $r,zd;function Hd(){if(zd)return $r;zd=1;var t=mo(),n=X1(),o=Q1();function a(r){var l=-1,i=r==null?0:r.length;for(this.__data__=new t;++l<i;)this.add(r[l])}return a.prototype.add=a.prototype.push=n,a.prototype.has=o,$r=a,$r}var Wr,Kd;function ek(){if(Kd)return Wr;Kd=1;function t(n,o){for(var a=-1,r=n==null?0:n.length;++a<r;)if(o(n[a],a,n))return!0;return!1}return Wr=t,Wr}var Jr,Gd;function Yd(){if(Gd)return Jr;Gd=1;function t(n,o){return n.has(o)}return Jr=t,Jr}var Zr,$d;function Wd(){if($d)return Zr;$d=1;var t=Hd(),n=ek(),o=Yd(),a=1,r=2;function l(i,s,d,h,f,p){var _=d&a,C=i.length,k=s.length;if(C!=k&&!(_&&k>C))return!1;var B=p.get(i),N=p.get(s);if(B&&N)return B==s&&N==i;var q=-1,F=!0,V=d&r?new t:void 0;for(p.set(i,s),p.set(s,i);++q<C;){var j=i[q],U=s[q];if(h)var L=_?h(U,j,q,s,i,p):h(j,U,q,i,s,p);if(L!==void 0){if(L)continue;F=!1;break}if(V){if(!n(s,function(R,H){if(!o(V,H)&&(j===R||f(j,R,d,h,p)))return V.push(H)})){F=!1;break}}else if(!(j===U||f(j,U,d,h,p))){F=!1;break}}return p.delete(i),p.delete(s),F}return Zr=l,Zr}var Xr,Jd;function tk(){if(Jd)return Xr;Jd=1;function t(n){var o=-1,a=Array(n.size);return n.forEach(function(r,l){a[++o]=[l,r]}),a}return Xr=t,Xr}var Qr,Zd;function ea(){if(Zd)return Qr;Zd=1;function t(n){var o=-1,a=Array(n.size);return n.forEach(function(r){a[++o]=r}),a}return Qr=t,Qr}var ta,Xd;function nk(){if(Xd)return ta;Xd=1;var t=Tt(),n=sd(),o=Et(),a=Wd(),r=tk(),l=ea(),i=1,s=2,d="[object Boolean]",h="[object Date]",f="[object Error]",p="[object Map]",_="[object Number]",C="[object RegExp]",k="[object Set]",B="[object String]",N="[object Symbol]",q="[object ArrayBuffer]",F="[object DataView]",V=t?t.prototype:void 0,j=V?V.valueOf:void 0;function U(L,R,H,W,J,K,ee){switch(H){case F:if(L.byteLength!=R.byteLength||L.byteOffset!=R.byteOffset)return!1;L=L.buffer,R=R.buffer;case q:return!(L.byteLength!=R.byteLength||!K(new n(L),new n(R)));case d:case h:case _:return o(+L,+R);case f:return L.name==R.name&&L.message==R.message;case C:case B:return L==R+"";case p:var ie=r;case k:var O=W&i;if(ie||(ie=l),L.size!=R.size&&!O)return!1;var E=ee.get(L);if(E)return E==R;W|=s,ee.set(L,R);var m=a(ie(L),ie(R),W,J,K,ee);return ee.delete(L),m;case N:if(j)return j.call(L)==j.call(R)}return!1}return ta=U,ta}var na,Qd;function ok(){if(Qd)return na;Qd=1;var t=Xc(),n=1,o=Object.prototype,a=o.hasOwnProperty;function r(l,i,s,d,h,f){var p=s&n,_=t(l),C=_.length,k=t(i),B=k.length;if(C!=B&&!p)return!1;for(var N=C;N--;){var q=_[N];if(!(p?q in i:a.call(i,q)))return!1}var F=f.get(l),V=f.get(i);if(F&&V)return F==i&&V==l;var j=!0;f.set(l,i),f.set(i,l);for(var U=p;++N<C;){q=_[N];var L=l[q],R=i[q];if(d)var H=p?d(R,L,q,i,l,f):d(L,R,q,l,i,f);if(!(H===void 0?L===R||h(L,R,s,d,f):H)){j=!1;break}U||(U=q=="constructor")}if(j&&!U){var W=l.constructor,J=i.constructor;W!=J&&"constructor"in l&&"constructor"in i&&!(typeof W=="function"&&W instanceof W&&typeof J=="function"&&J instanceof J)&&(j=!1)}return f.delete(l),f.delete(i),j}return na=r,na}var oa,eu;function rk(){if(eu)return oa;eu=1;var t=en(),n=Wd(),o=nk(),a=ok(),r=Dt(),l=Be(),i=It(),s=Lt(),d=1,h="[object Arguments]",f="[object Array]",p="[object Object]",_=Object.prototype,C=_.hasOwnProperty;function k(B,N,q,F,V,j){var U=l(B),L=l(N),R=U?f:r(B),H=L?f:r(N);R=R==h?p:R,H=H==h?p:H;var W=R==p,J=H==p,K=R==H;if(K&&i(B)){if(!i(N))return!1;U=!0,W=!1}if(K&&!W)return j||(j=new t),U||s(B)?n(B,N,q,F,V,j):o(B,N,R,q,F,V,j);if(!(q&d)){var ee=W&&C.call(B,"__wrapped__"),ie=J&&C.call(N,"__wrapped__");if(ee||ie){var O=ee?B.value():B,E=ie?N.value():N;return j||(j=new t),V(O,E,q,F,j)}}return K?(j||(j=new t),a(B,N,q,F,V,j)):!1}return oa=k,oa}var ra,tu;function nu(){if(tu)return ra;tu=1;var t=rk(),n=et();function o(a,r,l,i,s){return a===r?!0:a==null||r==null||!n(a)&&!n(r)?a!==a&&r!==r:t(a,r,l,i,o,s)}return ra=o,ra}var aa,ou;function ak(){if(ou)return aa;ou=1;var t=en(),n=nu(),o=1,a=2;function r(l,i,s,d){var h=s.length,f=h,p=!d;if(l==null)return!f;for(l=Object(l);h--;){var _=s[h];if(p&&_[2]?_[1]!==l[_[0]]:!(_[0]in l))return!1}for(;++h<f;){_=s[h];var C=_[0],k=l[C],B=_[1];if(p&&_[2]){if(k===void 0&&!(C in l))return!1}else{var N=new t;if(d)var q=d(k,B,C,l,i,N);if(!(q===void 0?n(B,k,o|a,d,N):q))return!1}}return!0}return aa=r,aa}var la,ru;function au(){if(ru)return la;ru=1;var t=ze();function n(o){return o===o&&!t(o)}return la=n,la}var ia,lu;function lk(){if(lu)return ia;lu=1;var t=au(),n=ht();function o(a){for(var r=n(a),l=r.length;l--;){var i=r[l],s=a[i];r[l]=[i,s,t(s)]}return r}return ia=o,ia}var sa,iu;function su(){if(iu)return sa;iu=1;function t(n,o){return function(a){return a==null?!1:a[n]===o&&(o!==void 0||n in Object(a))}}return sa=t,sa}var ca,cu;function ik(){if(cu)return ca;cu=1;var t=ak(),n=lk(),o=su();function a(r){var l=n(r);return l.length==1&&l[0][2]?o(l[0][0],l[0][1]):function(i){return i===r||t(i,r,l)}}return ca=a,ca}var da,du;function Ft(){if(du)return da;du=1;var t=kt(),n=et(),o="[object Symbol]";function a(r){return typeof r=="symbol"||n(r)&&t(r)==o}return da=a,da}var ua,uu;function ha(){if(uu)return ua;uu=1;var t=Be(),n=Ft(),o=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;function r(l,i){if(t(l))return!1;var s=typeof l;return s=="number"||s=="symbol"||s=="boolean"||l==null||n(l)?!0:a.test(l)||!o.test(l)||i!=null&&l in Object(i)}return ua=r,ua}var fa,hu;function sk(){if(hu)return fa;hu=1;var t=mo(),n="Expected a function";function o(a,r){if(typeof a!="function"||r!=null&&typeof r!="function")throw new TypeError(n);var l=function(){var i=arguments,s=r?r.apply(this,i):i[0],d=l.cache;if(d.has(s))return d.get(s);var h=a.apply(this,i);return l.cache=d.set(s,h)||d,h};return l.cache=new(o.Cache||t),l}return o.Cache=t,fa=o,fa}var pa,fu;function ck(){if(fu)return pa;fu=1;var t=sk(),n=500;function o(a){var r=t(a,function(i){return l.size===n&&l.clear(),i}),l=r.cache;return r}return pa=o,pa}var ma,pu;function dk(){if(pu)return ma;pu=1;var t=ck(),n=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,o=/\\(\\)?/g,a=t(function(r){var l=[];return r.charCodeAt(0)===46&&l.push(""),r.replace(n,function(i,s,d,h){l.push(d?h.replace(o,"$1"):s||i)}),l});return ma=a,ma}var ga,mu;function cn(){if(mu)return ga;mu=1;function t(n,o){for(var a=-1,r=n==null?0:n.length,l=Array(r);++a<r;)l[a]=o(n[a],a,n);return l}return ga=t,ga}var ba,gu;function uk(){if(gu)return ba;gu=1;var t=Tt(),n=cn(),o=Be(),a=Ft(),r=1/0,l=t?t.prototype:void 0,i=l?l.toString:void 0;function s(d){if(typeof d=="string")return d;if(o(d))return n(d,s)+"";if(a(d))return i?i.call(d):"";var h=d+"";return h=="0"&&1/d==-r?"-0":h}return ba=s,ba}var ya,bu;function yu(){if(bu)return ya;bu=1;var t=uk();function n(o){return o==null?"":t(o)}return ya=n,ya}var _a,_u;function dn(){if(_u)return _a;_u=1;var t=Be(),n=ha(),o=dk(),a=yu();function r(l,i){return t(l)?l:n(l,i)?[l]:o(a(l))}return _a=r,_a}var ka,ku;function Ut(){if(ku)return ka;ku=1;var t=Ft(),n=1/0;function o(a){if(typeof a=="string"||t(a))return a;var r=a+"";return r=="0"&&1/a==-n?"-0":r}return ka=o,ka}var wa,wu;function un(){if(wu)return wa;wu=1;var t=dn(),n=Ut();function o(a,r){r=t(r,a);for(var l=0,i=r.length;a!=null&&l<i;)a=a[n(r[l++])];return l&&l==i?a:void 0}return wa=o,wa}var Va,Vu;function hk(){if(Vu)return Va;Vu=1;var t=un();function n(o,a,r){var l=o==null?void 0:t(o,a);return l===void 0?r:l}return Va=n,Va}var Ca,Cu;function fk(){if(Cu)return Ca;Cu=1;function t(n,o){return n!=null&&o in Object(n)}return Ca=t,Ca}var xa,xu;function Nu(){if(xu)return xa;xu=1;var t=dn(),n=Ot(),o=Be(),a=on(),r=Fo(),l=Ut();function i(s,d,h){d=t(d,s);for(var f=-1,p=d.length,_=!1;++f<p;){var C=l(d[f]);if(!(_=s!=null&&h(s,C)))break;s=s[C]}return _||++f!=p?_:(p=s==null?0:s.length,!!p&&r(p)&&a(C,p)&&(o(s)||n(s)))}return xa=i,xa}var Na,Bu;function Su(){if(Bu)return Na;Bu=1;var t=fk(),n=Nu();function o(a,r){return a!=null&&n(a,r,t)}return Na=o,Na}var Ba,Eu;function pk(){if(Eu)return Ba;Eu=1;var t=nu(),n=hk(),o=Su(),a=ha(),r=au(),l=su(),i=Ut(),s=1,d=2;function h(f,p){return a(f)&&r(p)?l(i(f),p):function(_){var C=n(_,f);return C===void 0&&C===p?o(_,f):t(p,C,s|d)}}return Ba=h,Ba}var Sa,Tu;function Iu(){if(Tu)return Sa;Tu=1;function t(n){return function(o){return o==null?void 0:o[n]}}return Sa=t,Sa}var Ea,Du;function mk(){if(Du)return Ea;Du=1;var t=un();function n(o){return function(a){return t(a,o)}}return Ea=n,Ea}var Ta,Fu;function gk(){if(Fu)return Ta;Fu=1;var t=Iu(),n=mk(),o=ha(),a=Ut();function r(l){return o(l)?t(a(l)):n(l)}return Ta=r,Ta}var Ia,qu;function at(){if(qu)return Ia;qu=1;var t=ik(),n=pk(),o=Ct(),a=Be(),r=gk();function l(i){return typeof i=="function"?i:i==null?o:typeof i=="object"?a(i)?n(i[0],i[1]):t(i):r(i)}return Ia=l,Ia}var Da,Au;function Ru(){if(Au)return Da;Au=1;var t=Lc(),n=Z1(),o=at(),a=Be();function r(l,i){var s=a(l)?t:n;return s(l,o(i,3))}return Da=r,Da}var Fa,Ou;function bk(){if(Ou)return Fa;Ou=1;var t=Object.prototype,n=t.hasOwnProperty;function o(a,r){return a!=null&&n.call(a,r)}return Fa=o,Fa}var qa,vu;function Pu(){if(vu)return qa;vu=1;var t=bk(),n=Nu();function o(a,r){return a!=null&&n(a,r,t)}return qa=o,qa}var Aa,Lu;function yk(){if(Lu)return Aa;Lu=1;var t=jo(),n=Dt(),o=Ot(),a=Be(),r=rt(),l=It(),i=an(),s=Lt(),d="[object Map]",h="[object Set]",f=Object.prototype,p=f.hasOwnProperty;function _(C){if(C==null)return!0;if(r(C)&&(a(C)||typeof C=="string"||typeof C.splice=="function"||l(C)||s(C)||o(C)))return!C.length;var k=n(C);if(k==d||k==h)return!C.size;if(i(C))return!t(C).length;for(var B in C)if(p.call(C,B))return!1;return!0}return Aa=_,Aa}var Ra,Mu;function Uu(){if(Mu)return Ra;Mu=1;function t(n){return n===void 0}return Ra=t,Ra}var Oa,ju;function zu(){if(ju)return Oa;ju=1;var t=sn(),n=rt();function o(a,r){var l=-1,i=n(a)?Array(a.length):[];return t(a,function(s,d,h){i[++l]=r(s,d,h)}),i}return Oa=o,Oa}var va,Hu;function Ku(){if(Hu)return va;Hu=1;var t=cn(),n=at(),o=zu(),a=Be();function r(l,i){var s=a(l)?t:o;return s(l,n(i,3))}return va=r,va}var Pa,Gu;function _k(){if(Gu)return Pa;Gu=1;function t(n,o,a,r){var l=-1,i=n==null?0:n.length;for(r&&i&&(a=n[++l]);++l<i;)a=o(a,n[l],l,n);return a}return Pa=t,Pa}var La,Yu;function kk(){if(Yu)return La;Yu=1;function t(n,o,a,r,l){return l(n,function(i,s,d){a=r?(r=!1,i):o(a,i,s,d)}),a}return La=t,La}var Ma,$u;function Wu(){if($u)return Ma;$u=1;var t=_k(),n=sn(),o=at(),a=kk(),r=Be();function l(i,s,d){var h=r(i)?t:a,f=arguments.length<3;return h(i,o(s,4),d,f,n)}return Ma=l,Ma}var Ua,Ju;function wk(){if(Ju)return Ua;Ju=1;var t=kt(),n=Be(),o=et(),a="[object String]";function r(l){return typeof l=="string"||!n(l)&&o(l)&&t(l)==a}return Ua=r,Ua}var ja,Zu;function Vk(){if(Zu)return ja;Zu=1;var t=Iu(),n=t("length");return ja=n,ja}var za,Xu;function Ck(){if(Xu)return za;Xu=1;var t="\\ud800-\\udfff",n="\\u0300-\\u036f",o="\\ufe20-\\ufe2f",a="\\u20d0-\\u20ff",r=n+o+a,l="\\ufe0e\\ufe0f",i="\\u200d",s=RegExp("["+i+t+r+l+"]");function d(h){return s.test(h)}return za=d,za}var Ha,Qu;function xk(){if(Qu)return Ha;Qu=1;var t="\\ud800-\\udfff",n="\\u0300-\\u036f",o="\\ufe20-\\ufe2f",a="\\u20d0-\\u20ff",r=n+o+a,l="\\ufe0e\\ufe0f",i="["+t+"]",s="["+r+"]",d="\\ud83c[\\udffb-\\udfff]",h="(?:"+s+"|"+d+")",f="[^"+t+"]",p="(?:\\ud83c[\\udde6-\\uddff]){2}",_="[\\ud800-\\udbff][\\udc00-\\udfff]",C="\\u200d",k=h+"?",B="["+l+"]?",N="(?:"+C+"(?:"+[f,p,_].join("|")+")"+B+k+")*",q=B+k+N,F="(?:"+[f+s+"?",s,p,_,i].join("|")+")",V=RegExp(d+"(?="+d+")|"+F+q,"g");function j(U){for(var L=V.lastIndex=0;V.test(U);)++L;return L}return Ha=j,Ha}var Ka,eh;function Nk(){if(eh)return Ka;eh=1;var t=Vk(),n=Ck(),o=xk();function a(r){return n(r)?o(r):t(r)}return Ka=a,Ka}var Ga,th;function Bk(){if(th)return Ga;th=1;var t=jo(),n=Dt(),o=rt(),a=wk(),r=Nk(),l="[object Map]",i="[object Set]";function s(d){if(d==null)return 0;if(o(d))return a(d)?r(d):d.length;var h=n(d);return h==l||h==i?d.size:t(d).length}return Ga=s,Ga}var Ya,nh;function Sk(){if(nh)return Ya;nh=1;var t=_o(),n=bd(),o=Pr(),a=at(),r=ln(),l=Be(),i=It(),s=At(),d=ze(),h=Lt();function f(p,_,C){var k=l(p),B=k||i(p)||h(p);if(_=a(_,4),C==null){var N=p&&p.constructor;B?C=k?new N:[]:d(p)?C=s(N)?n(r(p)):{}:C={}}return(B?t:o)(p,function(q,F,V){return _(C,q,F,V)}),C}return Ya=f,Ya}var $a,oh;function Ek(){if(oh)return $a;oh=1;var t=Tt(),n=Ot(),o=Be(),a=t?t.isConcatSpreadable:void 0;function r(l){return o(l)||n(l)||!!(a&&l&&l[a])}return $a=r,$a}var Wa,rh;function Ja(){if(rh)return Wa;rh=1;var t=or(),n=Ek();function o(a,r,l,i,s){var d=-1,h=a.length;for(l||(l=n),s||(s=[]);++d<h;){var f=a[d];r>0&&l(f)?r>1?o(f,r-1,l,i,s):t(s,f):i||(s[s.length]=f)}return s}return Wa=o,Wa}var Za,ah;function Tk(){if(ah)return Za;ah=1;function t(n,o,a){switch(a.length){case 0:return n.call(o);case 1:return n.call(o,a[0]);case 2:return n.call(o,a[0],a[1]);case 3:return n.call(o,a[0],a[1],a[2])}return n.apply(o,a)}return Za=t,Za}var Xa,lh;function ih(){if(lh)return Xa;lh=1;var t=Tk(),n=Math.max;function o(a,r,l){return r=n(r===void 0?a.length-1:r,0),function(){for(var i=arguments,s=-1,d=n(i.length-r,0),h=Array(d);++s<d;)h[s]=i[r+s];s=-1;for(var f=Array(r+1);++s<r;)f[s]=i[s];return f[r]=l(h),t(a,this,f)}}return Xa=o,Xa}var Qa,sh;function Ik(){if(sh)return Qa;sh=1;var t=qr(),n=oc(),o=Ct(),a=n?function(r,l){return n(r,"toString",{configurable:!0,enumerable:!1,value:t(l),writable:!0})}:o;return Qa=a,Qa}var el,ch;function Dk(){if(ch)return el;ch=1;var t=800,n=16,o=Date.now;function a(r){var l=0,i=0;return function(){var s=o(),d=n-(s-i);if(i=s,d>0){if(++l>=t)return arguments[0]}else l=0;return r.apply(void 0,arguments)}}return el=a,el}var tl,dh;function uh(){if(dh)return tl;dh=1;var t=Ik(),n=Dk(),o=n(t);return tl=o,tl}var nl,hh;function hn(){if(hh)return nl;hh=1;var t=Ct(),n=ih(),o=uh();function a(r,l){return o(n(r,l,t),r+"")}return nl=a,nl}var ol,fh;function ph(){if(fh)return ol;fh=1;function t(n,o,a,r){for(var l=n.length,i=a+(r?1:-1);r?i--:++i<l;)if(o(n[i],i,n))return i;return-1}return ol=t,ol}var rl,mh;function Fk(){if(mh)return rl;mh=1;function t(n){return n!==n}return rl=t,rl}var al,gh;function qk(){if(gh)return al;gh=1;function t(n,o,a){for(var r=a-1,l=n.length;++r<l;)if(n[r]===o)return r;return-1}return al=t,al}var ll,bh;function Ak(){if(bh)return ll;bh=1;var t=ph(),n=Fk(),o=qk();function a(r,l,i){return l===l?o(r,l,i):t(r,n,i)}return ll=a,ll}var il,yh;function Rk(){if(yh)return il;yh=1;var t=Ak();function n(o,a){var r=o==null?0:o.length;return!!r&&t(o,a,0)>-1}return il=n,il}var sl,_h;function Ok(){if(_h)return sl;_h=1;function t(n,o,a){for(var r=-1,l=n==null?0:n.length;++r<l;)if(a(o,n[r]))return!0;return!1}return sl=t,sl}var cl,kh;function vk(){if(kh)return cl;kh=1;function t(){}return cl=t,cl}var dl,wh;function Pk(){if(wh)return dl;wh=1;var t=od(),n=vk(),o=ea(),a=1/0,r=t&&1/o(new t([,-0]))[1]==a?function(l){return new t(l)}:n;return dl=r,dl}var ul,Vh;function Lk(){if(Vh)return ul;Vh=1;var t=Hd(),n=Rk(),o=Ok(),a=Yd(),r=Pk(),l=ea(),i=200;function s(d,h,f){var p=-1,_=n,C=d.length,k=!0,B=[],N=B;if(f)k=!1,_=o;else if(C>=i){var q=h?null:r(d);if(q)return l(q);k=!1,_=a,N=new t}else N=h?[]:B;e:for(;++p<C;){var F=d[p],V=h?h(F):F;if(F=f||F!==0?F:0,k&&V===V){for(var j=N.length;j--;)if(N[j]===V)continue e;h&&N.push(V),B.push(F)}else _(N,V,f)||(N!==B&&N.push(V),B.push(F))}return B}return ul=s,ul}var hl,Ch;function xh(){if(Ch)return hl;Ch=1;var t=rt(),n=et();function o(a){return n(a)&&t(a)}return hl=o,hl}var fl,Nh;function Mk(){if(Nh)return fl;Nh=1;var t=Ja(),n=hn(),o=Lk(),a=xh(),r=n(function(l){return o(t(l,1,a,!0))});return fl=r,fl}var pl,Bh;function Uk(){if(Bh)return pl;Bh=1;var t=cn();function n(o,a){return t(a,function(r){return o[r]})}return pl=n,pl}var ml,Sh;function Eh(){if(Sh)return ml;Sh=1;var t=Uk(),n=ht();function o(a){return a==null?[]:t(a,n(a))}return ml=o,ml}var gl,Th;function He(){if(Th)return gl;Th=1;var t;if(typeof xn=="function")try{t={clone:$1(),constant:qr(),each:Ld(),filter:Ru(),has:Pu(),isArray:Be(),isEmpty:yk(),isFunction:At(),isUndefined:Uu(),keys:ht(),map:Ku(),reduce:Wu(),size:Bk(),transform:Sk(),union:Mk(),values:Eh()}}catch{}return t||(t=window._),gl=t,gl}var bl,Ih;function yl(){if(Ih)return bl;Ih=1;var t=He();bl=r;var n="\0",o="\0",a="";function r(f){this._isDirected=t.has(f,"directed")?f.directed:!0,this._isMultigraph=t.has(f,"multigraph")?f.multigraph:!1,this._isCompound=t.has(f,"compound")?f.compound:!1,this._label=void 0,this._defaultNodeLabelFn=t.constant(void 0),this._defaultEdgeLabelFn=t.constant(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[o]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}r.prototype._nodeCount=0,r.prototype._edgeCount=0,r.prototype.isDirected=function(){return this._isDirected},r.prototype.isMultigraph=function(){return this._isMultigraph},r.prototype.isCompound=function(){return this._isCompound},r.prototype.setGraph=function(f){return this._label=f,this},r.prototype.graph=function(){return this._label},r.prototype.setDefaultNodeLabel=function(f){return t.isFunction(f)||(f=t.constant(f)),this._defaultNodeLabelFn=f,this},r.prototype.nodeCount=function(){return this._nodeCount},r.prototype.nodes=function(){return t.keys(this._nodes)},r.prototype.sources=function(){var f=this;return t.filter(this.nodes(),function(p){return t.isEmpty(f._in[p])})},r.prototype.sinks=function(){var f=this;return t.filter(this.nodes(),function(p){return t.isEmpty(f._out[p])})},r.prototype.setNodes=function(f,p){var _=arguments,C=this;return t.each(f,function(k){_.length>1?C.setNode(k,p):C.setNode(k)}),this},r.prototype.setNode=function(f,p){return t.has(this._nodes,f)?(arguments.length>1&&(this._nodes[f]=p),this):(this._nodes[f]=arguments.length>1?p:this._defaultNodeLabelFn(f),this._isCompound&&(this._parent[f]=o,this._children[f]={},this._children[o][f]=!0),this._in[f]={},this._preds[f]={},this._out[f]={},this._sucs[f]={},++this._nodeCount,this)},r.prototype.node=function(f){return this._nodes[f]},r.prototype.hasNode=function(f){return t.has(this._nodes,f)},r.prototype.removeNode=function(f){var p=this;if(t.has(this._nodes,f)){var _=function(C){p.removeEdge(p._edgeObjs[C])};delete this._nodes[f],this._isCompound&&(this._removeFromParentsChildList(f),delete this._parent[f],t.each(this.children(f),function(C){p.setParent(C)}),delete this._children[f]),t.each(t.keys(this._in[f]),_),delete this._in[f],delete this._preds[f],t.each(t.keys(this._out[f]),_),delete this._out[f],delete this._sucs[f],--this._nodeCount}return this},r.prototype.setParent=function(f,p){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(t.isUndefined(p))p=o;else{p+="";for(var _=p;!t.isUndefined(_);_=this.parent(_))if(_===f)throw new Error("Setting "+p+" as parent of "+f+" would create a cycle");this.setNode(p)}return this.setNode(f),this._removeFromParentsChildList(f),this._parent[f]=p,this._children[p][f]=!0,this},r.prototype._removeFromParentsChildList=function(f){delete this._children[this._parent[f]][f]},r.prototype.parent=function(f){if(this._isCompound){var p=this._parent[f];if(p!==o)return p}},r.prototype.children=function(f){if(t.isUndefined(f)&&(f=o),this._isCompound){var p=this._children[f];if(p)return t.keys(p)}else{if(f===o)return this.nodes();if(this.hasNode(f))return[]}},r.prototype.predecessors=function(f){var p=this._preds[f];if(p)return t.keys(p)},r.prototype.successors=function(f){var p=this._sucs[f];if(p)return t.keys(p)},r.prototype.neighbors=function(f){var p=this.predecessors(f);if(p)return t.union(p,this.successors(f))},r.prototype.isLeaf=function(f){var p;return this.isDirected()?p=this.successors(f):p=this.neighbors(f),p.length===0},r.prototype.filterNodes=function(f){var p=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});p.setGraph(this.graph());var _=this;t.each(this._nodes,function(B,N){f(N)&&p.setNode(N,B)}),t.each(this._edgeObjs,function(B){p.hasNode(B.v)&&p.hasNode(B.w)&&p.setEdge(B,_.edge(B))});var C={};function k(B){var N=_.parent(B);return N===void 0||p.hasNode(N)?(C[B]=N,N):N in C?C[N]:k(N)}return this._isCompound&&t.each(p.nodes(),function(B){p.setParent(B,k(B))}),p},r.prototype.setDefaultEdgeLabel=function(f){return t.isFunction(f)||(f=t.constant(f)),this._defaultEdgeLabelFn=f,this},r.prototype.edgeCount=function(){return this._edgeCount},r.prototype.edges=function(){return t.values(this._edgeObjs)},r.prototype.setPath=function(f,p){var _=this,C=arguments;return t.reduce(f,function(k,B){return C.length>1?_.setEdge(k,B,p):_.setEdge(k,B),B}),this},r.prototype.setEdge=function(){var f,p,_,C,k=!1,B=arguments[0];typeof B=="object"&&B!==null&&"v"in B?(f=B.v,p=B.w,_=B.name,arguments.length===2&&(C=arguments[1],k=!0)):(f=B,p=arguments[1],_=arguments[3],arguments.length>2&&(C=arguments[2],k=!0)),f=""+f,p=""+p,t.isUndefined(_)||(_=""+_);var N=s(this._isDirected,f,p,_);if(t.has(this._edgeLabels,N))return k&&(this._edgeLabels[N]=C),this;if(!t.isUndefined(_)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(f),this.setNode(p),this._edgeLabels[N]=k?C:this._defaultEdgeLabelFn(f,p,_);var q=d(this._isDirected,f,p,_);return f=q.v,p=q.w,Object.freeze(q),this._edgeObjs[N]=q,l(this._preds[p],f),l(this._sucs[f],p),this._in[p][N]=q,this._out[f][N]=q,this._edgeCount++,this},r.prototype.edge=function(f,p,_){var C=arguments.length===1?h(this._isDirected,arguments[0]):s(this._isDirected,f,p,_);return this._edgeLabels[C]},r.prototype.hasEdge=function(f,p,_){var C=arguments.length===1?h(this._isDirected,arguments[0]):s(this._isDirected,f,p,_);return t.has(this._edgeLabels,C)},r.prototype.removeEdge=function(f,p,_){var C=arguments.length===1?h(this._isDirected,arguments[0]):s(this._isDirected,f,p,_),k=this._edgeObjs[C];return k&&(f=k.v,p=k.w,delete this._edgeLabels[C],delete this._edgeObjs[C],i(this._preds[p],f),i(this._sucs[f],p),delete this._in[p][C],delete this._out[f][C],this._edgeCount--),this},r.prototype.inEdges=function(f,p){var _=this._in[f];if(_){var C=t.values(_);return p?t.filter(C,function(k){return k.v===p}):C}},r.prototype.outEdges=function(f,p){var _=this._out[f];if(_){var C=t.values(_);return p?t.filter(C,function(k){return k.w===p}):C}},r.prototype.nodeEdges=function(f,p){var _=this.inEdges(f,p);if(_)return _.concat(this.outEdges(f,p))};function l(f,p){f[p]?f[p]++:f[p]=1}function i(f,p){--f[p]||delete f[p]}function s(f,p,_,C){var k=""+p,B=""+_;if(!f&&k>B){var N=k;k=B,B=N}return k+a+B+a+(t.isUndefined(C)?n:C)}function d(f,p,_,C){var k=""+p,B=""+_;if(!f&&k>B){var N=k;k=B,B=N}var q={v:k,w:B};return C&&(q.name=C),q}function h(f,p){return s(f,p.v,p.w,p.name)}return bl}var _l,Dh;function jk(){return Dh||(Dh=1,_l="2.1.8"),_l}var kl,Fh;function zk(){return Fh||(Fh=1,kl={Graph:yl(),version:jk()}),kl}var wl,qh;function Hk(){if(qh)return wl;qh=1;var t=He(),n=yl();wl={write:o,read:l};function o(i){var s={options:{directed:i.isDirected(),multigraph:i.isMultigraph(),compound:i.isCompound()},nodes:a(i),edges:r(i)};return t.isUndefined(i.graph())||(s.value=t.clone(i.graph())),s}function a(i){return t.map(i.nodes(),function(s){var d=i.node(s),h=i.parent(s),f={v:s};return t.isUndefined(d)||(f.value=d),t.isUndefined(h)||(f.parent=h),f})}function r(i){return t.map(i.edges(),function(s){var d=i.edge(s),h={v:s.v,w:s.w};return t.isUndefined(s.name)||(h.name=s.name),t.isUndefined(d)||(h.value=d),h})}function l(i){var s=new n(i.options).setGraph(i.value);return t.each(i.nodes,function(d){s.setNode(d.v,d.value),d.parent&&s.setParent(d.v,d.parent)}),t.each(i.edges,function(d){s.setEdge({v:d.v,w:d.w,name:d.name},d.value)}),s}return wl}var Vl,Ah;function Kk(){if(Ah)return Vl;Ah=1;var t=He();Vl=n;function n(o){var a={},r=[],l;function i(s){t.has(a,s)||(a[s]=!0,l.push(s),t.each(o.successors(s),i),t.each(o.predecessors(s),i))}return t.each(o.nodes(),function(s){l=[],i(s),l.length&&r.push(l)}),r}return Vl}var Cl,Rh;function Oh(){if(Rh)return Cl;Rh=1;var t=He();Cl=n;function n(){this._arr=[],this._keyIndices={}}return n.prototype.size=function(){return this._arr.length},n.prototype.keys=function(){return this._arr.map(function(o){return o.key})},n.prototype.has=function(o){return t.has(this._keyIndices,o)},n.prototype.priority=function(o){var a=this._keyIndices[o];if(a!==void 0)return this._arr[a].priority},n.prototype.min=function(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key},n.prototype.add=function(o,a){var r=this._keyIndices;if(o=String(o),!t.has(r,o)){var l=this._arr,i=l.length;return r[o]=i,l.push({key:o,priority:a}),this._decrease(i),!0}return!1},n.prototype.removeMin=function(){this._swap(0,this._arr.length-1);var o=this._arr.pop();return delete this._keyIndices[o.key],this._heapify(0),o.key},n.prototype.decrease=function(o,a){var r=this._keyIndices[o];if(a>this._arr[r].priority)throw new Error("New priority is greater than current priority. Key: "+o+" Old: "+this._arr[r].priority+" New: "+a);this._arr[r].priority=a,this._decrease(r)},n.prototype._heapify=function(o){var a=this._arr,r=2*o,l=r+1,i=o;r<a.length&&(i=a[r].priority<a[i].priority?r:i,l<a.length&&(i=a[l].priority<a[i].priority?l:i),i!==o&&(this._swap(o,i),this._heapify(i)))},n.prototype._decrease=function(o){for(var a=this._arr,r=a[o].priority,l;o!==0&&(l=o>>1,!(a[l].priority<r));)this._swap(o,l),o=l},n.prototype._swap=function(o,a){var r=this._arr,l=this._keyIndices,i=r[o],s=r[a];r[o]=s,r[a]=i,l[s.key]=o,l[i.key]=a},Cl}var xl,vh;function Ph(){if(vh)return xl;vh=1;var t=He(),n=Oh();xl=a;var o=t.constant(1);function a(l,i,s,d){return r(l,String(i),s||o,d||function(h){return l.outEdges(h)})}function r(l,i,s,d){var h={},f=new n,p,_,C=function(k){var B=k.v!==p?k.v:k.w,N=h[B],q=s(k),F=_.distance+q;if(q<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+k+" Weight: "+q);F<N.distance&&(N.distance=F,N.predecessor=p,f.decrease(B,F))};for(l.nodes().forEach(function(k){var B=k===i?0:Number.POSITIVE_INFINITY;h[k]={distance:B},f.add(k,B)});f.size()>0&&(p=f.removeMin(),_=h[p],_.distance!==Number.POSITIVE_INFINITY);)d(p).forEach(C);return h}return xl}var Nl,Lh;function Gk(){if(Lh)return Nl;Lh=1;var t=Ph(),n=He();Nl=o;function o(a,r,l){return n.transform(a.nodes(),function(i,s){i[s]=t(a,s,r,l)},{})}return Nl}var Bl,Mh;function Uh(){if(Mh)return Bl;Mh=1;var t=He();Bl=n;function n(o){var a=0,r=[],l={},i=[];function s(d){var h=l[d]={onStack:!0,lowlink:a,index:a++};if(r.push(d),o.successors(d).forEach(function(_){t.has(l,_)?l[_].onStack&&(h.lowlink=Math.min(h.lowlink,l[_].index)):(s(_),h.lowlink=Math.min(h.lowlink,l[_].lowlink))}),h.lowlink===h.index){var f=[],p;do p=r.pop(),l[p].onStack=!1,f.push(p);while(d!==p);i.push(f)}}return o.nodes().forEach(function(d){t.has(l,d)||s(d)}),i}return Bl}var Sl,jh;function Yk(){if(jh)return Sl;jh=1;var t=He(),n=Uh();Sl=o;function o(a){return t.filter(n(a),function(r){return r.length>1||r.length===1&&a.hasEdge(r[0],r[0])})}return Sl}var El,zh;function $k(){if(zh)return El;zh=1;var t=He();El=o;var n=t.constant(1);function o(r,l,i){return a(r,l||n,i||function(s){return r.outEdges(s)})}function a(r,l,i){var s={},d=r.nodes();return d.forEach(function(h){s[h]={},s[h][h]={distance:0},d.forEach(function(f){h!==f&&(s[h][f]={distance:Number.POSITIVE_INFINITY})}),i(h).forEach(function(f){var p=f.v===h?f.w:f.v,_=l(f);s[h][p]={distance:_,predecessor:h}})}),d.forEach(function(h){var f=s[h];d.forEach(function(p){var _=s[p];d.forEach(function(C){var k=_[h],B=f[C],N=_[C],q=k.distance+B.distance;q<N.distance&&(N.distance=q,N.predecessor=B.predecessor)})})}),s}return El}var Tl,Hh;function Kh(){if(Hh)return Tl;Hh=1;var t=He();Tl=n,n.CycleException=o;function n(a){var r={},l={},i=[];function s(d){if(t.has(l,d))throw new o;t.has(r,d)||(l[d]=!0,r[d]=!0,t.each(a.predecessors(d),s),delete l[d],i.push(d))}if(t.each(a.sinks(),s),t.size(r)!==a.nodeCount())throw new o;return i}function o(){}return o.prototype=new Error,Tl}var Il,Gh;function Wk(){if(Gh)return Il;Gh=1;var t=Kh();Il=n;function n(o){try{t(o)}catch(a){if(a instanceof t.CycleException)return!1;throw a}return!0}return Il}var Dl,Yh;function $h(){if(Yh)return Dl;Yh=1;var t=He();Dl=n;function n(a,r,l){t.isArray(r)||(r=[r]);var i=(a.isDirected()?a.successors:a.neighbors).bind(a),s=[],d={};return t.each(r,function(h){if(!a.hasNode(h))throw new Error("Graph does not have node: "+h);o(a,h,l==="post",d,i,s)}),s}function o(a,r,l,i,s,d){t.has(i,r)||(i[r]=!0,l||d.push(r),t.each(s(r),function(h){o(a,h,l,i,s,d)}),l&&d.push(r))}return Dl}var Fl,Wh;function Jk(){if(Wh)return Fl;Wh=1;var t=$h();Fl=n;function n(o,a){return t(o,a,"post")}return Fl}var ql,Jh;function Zk(){if(Jh)return ql;Jh=1;var t=$h();ql=n;function n(o,a){return t(o,a,"pre")}return ql}var Al,Zh;function Xk(){if(Zh)return Al;Zh=1;var t=He(),n=yl(),o=Oh();Al=a;function a(r,l){var i=new n,s={},d=new o,h;function f(_){var C=_.v===h?_.w:_.v,k=d.priority(C);if(k!==void 0){var B=l(_);B<k&&(s[C]=h,d.decrease(C,B))}}if(r.nodeCount()===0)return i;t.each(r.nodes(),function(_){d.add(_,Number.POSITIVE_INFINITY),i.setNode(_)}),d.decrease(r.nodes()[0],0);for(var p=!1;d.size()>0;){if(h=d.removeMin(),t.has(s,h))i.setEdge(h,s[h]);else{if(p)throw new Error("Input graph is not connected: "+r);p=!0}r.nodeEdges(h).forEach(f)}return i}return Al}var Rl,Xh;function Qk(){return Xh||(Xh=1,Rl={components:Kk(),dijkstra:Ph(),dijkstraAll:Gk(),findCycles:Yk(),floydWarshall:$k(),isAcyclic:Wk(),postorder:Jk(),preorder:Zk(),prim:Xk(),tarjan:Uh(),topsort:Kh()}),Rl}var Ol,Qh;function ew(){if(Qh)return Ol;Qh=1;var t=zk();return Ol={Graph:t.Graph,json:Hk(),alg:Qk(),version:t.version},Ol}var fn;if(typeof xn=="function")try{fn=ew()}catch{}fn||(fn=window.graphlib);var Je=fn,vl,ef;function tw(){if(ef)return vl;ef=1;var t=Nd(),n=1,o=4;function a(r){return t(r,n|o)}return vl=a,vl}var Pl,tf;function pn(){if(tf)return Pl;tf=1;var t=Et(),n=rt(),o=on(),a=ze();function r(l,i,s){if(!a(s))return!1;var d=typeof i;return(d=="number"?n(s)&&o(i,s.length):d=="string"&&i in s)?t(s[i],l):!1}return Pl=r,Pl}var Ll,nf;function nw(){if(nf)return Ll;nf=1;var t=hn(),n=Et(),o=pn(),a=Vt(),r=Object.prototype,l=r.hasOwnProperty,i=t(function(s,d){s=Object(s);var h=-1,f=d.length,p=f>2?d[2]:void 0;for(p&&o(d[0],d[1],p)&&(f=1);++h<f;)for(var _=d[h],C=a(_),k=-1,B=C.length;++k<B;){var N=C[k],q=s[N];(q===void 0||n(q,r[N])&&!l.call(s,N))&&(s[N]=_[N])}return s});return Ll=i,Ll}var Ml,of;function ow(){if(of)return Ml;of=1;var t=at(),n=rt(),o=ht();function a(r){return function(l,i,s){var d=Object(l);if(!n(l)){var h=t(i,3);l=o(l),i=function(p){return h(d[p],p,d)}}var f=r(l,i,s);return f>-1?d[h?l[f]:f]:void 0}}return Ml=a,Ml}var Ul,rf;function rw(){if(rf)return Ul;rf=1;var t=/\s/;function n(o){for(var a=o.length;a--&&t.test(o.charAt(a)););return a}return Ul=n,Ul}var jl,af;function aw(){if(af)return jl;af=1;var t=rw(),n=/^\s+/;function o(a){return a&&a.slice(0,t(a)+1).replace(n,"")}return jl=o,jl}var zl,lf;function lw(){if(lf)return zl;lf=1;var t=aw(),n=ze(),o=Ft(),a=NaN,r=/^[-+]0x[0-9a-f]+$/i,l=/^0b[01]+$/i,i=/^0o[0-7]+$/i,s=parseInt;function d(h){if(typeof h=="number")return h;if(o(h))return a;if(n(h)){var f=typeof h.valueOf=="function"?h.valueOf():h;h=n(f)?f+"":f}if(typeof h!="string")return h===0?h:+h;h=t(h);var p=l.test(h);return p||i.test(h)?s(h.slice(2),p?2:8):r.test(h)?a:+h}return zl=d,zl}var Hl,sf;function cf(){if(sf)return Hl;sf=1;var t=lw(),n=1/0,o=17976931348623157e292;function a(r){if(!r)return r===0?r:0;if(r=t(r),r===n||r===-n){var l=r<0?-1:1;return l*o}return r===r?r:0}return Hl=a,Hl}var Kl,df;function iw(){if(df)return Kl;df=1;var t=cf();function n(o){var a=t(o),r=a%1;return a===a?r?a-r:a:0}return Kl=n,Kl}var Gl,uf;function sw(){if(uf)return Gl;uf=1;var t=ph(),n=at(),o=iw(),a=Math.max;function r(l,i,s){var d=l==null?0:l.length;if(!d)return-1;var h=s==null?0:o(s);return h<0&&(h=a(d+h,0)),t(l,n(i,3),h)}return Gl=r,Gl}var Yl,hf;function cw(){if(hf)return Yl;hf=1;var t=ow(),n=sw(),o=t(n);return Yl=o,Yl}var $l,ff;function pf(){if(ff)return $l;ff=1;var t=Ja();function n(o){var a=o==null?0:o.length;return a?t(o,1):[]}return $l=n,$l}var Wl,mf;function dw(){if(mf)return Wl;mf=1;var t=Or(),n=Rd(),o=Vt();function a(r,l){return r==null?r:t(r,n(l),o)}return Wl=a,Wl}var Jl,gf;function uw(){if(gf)return Jl;gf=1;function t(n){var o=n==null?0:n.length;return o?n[o-1]:void 0}return Jl=t,Jl}var Zl,bf;function hw(){if(bf)return Zl;bf=1;var t=tn(),n=Pr(),o=at();function a(r,l){var i={};return l=o(l,3),n(r,function(s,d,h){t(i,d,l(s,d,h))}),i}return Zl=a,Zl}var Xl,yf;function Ql(){if(yf)return Xl;yf=1;var t=Ft();function n(o,a,r){for(var l=-1,i=o.length;++l<i;){var s=o[l],d=a(s);if(d!=null&&(h===void 0?d===d&&!t(d):r(d,h)))var h=d,f=s}return f}return Xl=n,Xl}var ei,_f;function fw(){if(_f)return ei;_f=1;function t(n,o){return n>o}return ei=t,ei}var ti,kf;function pw(){if(kf)return ti;kf=1;var t=Ql(),n=fw(),o=Ct();function a(r){return r&&r.length?t(r,o,n):void 0}return ti=a,ti}var ni,wf;function Vf(){if(wf)return ni;wf=1;var t=tn(),n=Et();function o(a,r,l){(l!==void 0&&!n(a[r],l)||l===void 0&&!(r in a))&&t(a,r,l)}return ni=o,ni}var oi,Cf;function mw(){if(Cf)return oi;Cf=1;var t=kt(),n=ln(),o=et(),a="[object Object]",r=Function.prototype,l=Object.prototype,i=r.toString,s=l.hasOwnProperty,d=i.call(Object);function h(f){if(!o(f)||t(f)!=a)return!1;var p=n(f);if(p===null)return!0;var _=s.call(p,"constructor")&&p.constructor;return typeof _=="function"&&_ instanceof _&&i.call(_)==d}return oi=h,oi}var ri,xf;function Nf(){if(xf)return ri;xf=1;function t(n,o){if(!(o==="constructor"&&typeof n[o]=="function")&&o!="__proto__")return n[o]}return ri=t,ri}var ai,Bf;function gw(){if(Bf)return ai;Bf=1;var t=Rt(),n=Vt();function o(a){return t(a,n(a))}return ai=o,ai}var li,Sf;function bw(){if(Sf)return li;Sf=1;var t=Vf(),n=Rc(),o=pd(),a=vc(),r=_d(),l=Ot(),i=Be(),s=xh(),d=It(),h=At(),f=ze(),p=mw(),_=Lt(),C=Nf(),k=gw();function B(N,q,F,V,j,U,L){var R=C(N,F),H=C(q,F),W=L.get(H);if(W){t(N,F,W);return}var J=U?U(R,H,F+"",N,q,L):void 0,K=J===void 0;if(K){var ee=i(H),ie=!ee&&d(H),O=!ee&&!ie&&_(H);J=H,ee||ie||O?i(R)?J=R:s(R)?J=a(R):ie?(K=!1,J=n(H,!0)):O?(K=!1,J=o(H,!0)):J=[]:p(H)||l(H)?(J=R,l(R)?J=k(R):(!f(R)||h(R))&&(J=r(H))):K=!1}K&&(L.set(H,J),j(J,H,V,U,L),L.delete(H)),t(N,F,J)}return li=B,li}var ii,Ef;function yw(){if(Ef)return ii;Ef=1;var t=en(),n=Vf(),o=Or(),a=bw(),r=ze(),l=Vt(),i=Nf();function s(d,h,f,p,_){d!==h&&o(h,function(C,k){if(_||(_=new t),r(C))a(d,h,k,f,s,p,_);else{var B=p?p(i(d,k),C,k+"",d,h,_):void 0;B===void 0&&(B=C),n(d,k,B)}},l)}return ii=s,ii}var si,Tf;function _w(){if(Tf)return si;Tf=1;var t=hn(),n=pn();function o(a){return t(function(r,l){var i=-1,s=l.length,d=s>1?l[s-1]:void 0,h=s>2?l[2]:void 0;for(d=a.length>3&&typeof d=="function"?(s--,d):void 0,h&&n(l[0],l[1],h)&&(d=s<3?void 0:d,s=1),r=Object(r);++i<s;){var f=l[i];f&&a(r,f,i,d)}return r})}return si=o,si}var ci,If;function kw(){if(If)return ci;If=1;var t=yw(),n=_w(),o=n(function(a,r,l){t(a,r,l)});return ci=o,ci}var di,Df;function Ff(){if(Df)return di;Df=1;function t(n,o){return n<o}return di=t,di}var ui,qf;function ww(){if(qf)return ui;qf=1;var t=Ql(),n=Ff(),o=Ct();function a(r){return r&&r.length?t(r,o,n):void 0}return ui=a,ui}var hi,Af;function Vw(){if(Af)return hi;Af=1;var t=Ql(),n=at(),o=Ff();function a(r,l){return r&&r.length?t(r,n(l,2),o):void 0}return hi=a,hi}var fi,Rf;function Cw(){if(Rf)return fi;Rf=1;var t=We(),n=function(){return t.Date.now()};return fi=n,fi}var pi,Of;function xw(){if(Of)return pi;Of=1;var t=nn(),n=dn(),o=on(),a=ze(),r=Ut();function l(i,s,d,h){if(!a(i))return i;s=n(s,i);for(var f=-1,p=s.length,_=p-1,C=i;C!=null&&++f<p;){var k=r(s[f]),B=d;if(k==="__proto__"||k==="constructor"||k==="prototype")return i;if(f!=_){var N=C[k];B=h?h(N,k,C):void 0,B===void 0&&(B=a(N)?N:o(s[f+1])?[]:{})}t(C,k,B),C=C[k]}return i}return pi=l,pi}var mi,vf;function Nw(){if(vf)return mi;vf=1;var t=un(),n=xw(),o=dn();function a(r,l,i){for(var s=-1,d=l.length,h={};++s<d;){var f=l[s],p=t(r,f);i(p,f)&&n(h,o(f,r),p)}return h}return mi=a,mi}var gi,Pf;function Bw(){if(Pf)return gi;Pf=1;var t=Nw(),n=Su();function o(a,r){return t(a,r,function(l,i){return n(a,i)})}return gi=o,gi}var bi,Lf;function Sw(){if(Lf)return bi;Lf=1;var t=pf(),n=ih(),o=uh();function a(r){return o(n(r,void 0,t),r+"")}return bi=a,bi}var yi,Mf;function Ew(){if(Mf)return yi;Mf=1;var t=Bw(),n=Sw(),o=n(function(a,r){return a==null?{}:t(a,r)});return yi=o,yi}var _i,Uf;function Tw(){if(Uf)return _i;Uf=1;var t=Math.ceil,n=Math.max;function o(a,r,l,i){for(var s=-1,d=n(t((r-a)/(l||1)),0),h=Array(d);d--;)h[i?d:++s]=a,a+=l;return h}return _i=o,_i}var ki,jf;function Iw(){if(jf)return ki;jf=1;var t=Tw(),n=pn(),o=cf();function a(r){return function(l,i,s){return s&&typeof s!="number"&&n(l,i,s)&&(i=s=void 0),l=o(l),i===void 0?(i=l,l=0):i=o(i),s=s===void 0?l<i?1:-1:o(s),t(l,i,s,r)}}return ki=a,ki}var wi,zf;function Dw(){if(zf)return wi;zf=1;var t=Iw(),n=t();return wi=n,wi}var Vi,Hf;function Fw(){if(Hf)return Vi;Hf=1;function t(n,o){var a=n.length;for(n.sort(o);a--;)n[a]=n[a].value;return n}return Vi=t,Vi}var Ci,Kf;function qw(){if(Kf)return Ci;Kf=1;var t=Ft();function n(o,a){if(o!==a){var r=o!==void 0,l=o===null,i=o===o,s=t(o),d=a!==void 0,h=a===null,f=a===a,p=t(a);if(!h&&!p&&!s&&o>a||s&&d&&f&&!h&&!p||l&&d&&f||!r&&f||!i)return 1;if(!l&&!s&&!p&&o<a||p&&r&&i&&!l&&!s||h&&r&&i||!d&&i||!f)return-1}return 0}return Ci=n,Ci}var xi,Gf;function Aw(){if(Gf)return xi;Gf=1;var t=qw();function n(o,a,r){for(var l=-1,i=o.criteria,s=a.criteria,d=i.length,h=r.length;++l<d;){var f=t(i[l],s[l]);if(f){if(l>=h)return f;var p=r[l];return f*(p=="desc"?-1:1)}}return o.index-a.index}return xi=n,xi}var Ni,Yf;function Rw(){if(Yf)return Ni;Yf=1;var t=cn(),n=un(),o=at(),a=zu(),r=Fw(),l=rn(),i=Aw(),s=Ct(),d=Be();function h(f,p,_){p.length?p=t(p,function(B){return d(B)?function(N){return n(N,B.length===1?B[0]:B)}:B}):p=[s];var C=-1;p=t(p,l(o));var k=a(f,function(B,N,q){var F=t(p,function(V){return V(B)});return{criteria:F,index:++C,value:B}});return r(k,function(B,N){return i(B,N,_)})}return Ni=h,Ni}var Bi,$f;function Ow(){if($f)return Bi;$f=1;var t=Ja(),n=Rw(),o=hn(),a=pn(),r=o(function(l,i){if(l==null)return[];var s=i.length;return s>1&&a(l,i[0],i[1])?i=[]:s>2&&a(i[0],i[1],i[2])&&(i=[i[0]]),n(l,t(i,1),[])});return Bi=r,Bi}var Si,Wf;function vw(){if(Wf)return Si;Wf=1;var t=yu(),n=0;function o(a){var r=++n;return t(a)+r}return Si=o,Si}var Ei,Jf;function Pw(){if(Jf)return Ei;Jf=1;function t(n,o,a){for(var r=-1,l=n.length,i=o.length,s={};++r<l;){var d=r<i?o[r]:void 0;a(s,n[r],d)}return s}return Ei=t,Ei}var Ti,Zf;function Lw(){if(Zf)return Ti;Zf=1;var t=nn(),n=Pw();function o(a,r){return n(a||[],r||[],t)}return Ti=o,Ti}var mn;if(typeof xn=="function")try{mn={cloneDeep:tw(),constant:qr(),defaults:nw(),each:Ld(),filter:Ru(),find:cw(),flatten:pf(),forEach:vd(),forIn:dw(),has:Pu(),isUndefined:Uu(),last:uw(),map:Ku(),mapValues:hw(),max:pw(),merge:kw(),min:ww(),minBy:Vw(),now:Cw(),pick:Ew(),range:Dw(),reduce:Wu(),sortBy:Ow(),uniqueId:vw(),values:Eh(),zipObject:Lw()}}catch{}mn||(mn=window._);var Ve=mn,Mw=gn;function gn(){var t={};t._next=t._prev=t,this._sentinel=t}gn.prototype.dequeue=function(){var t=this._sentinel,n=t._prev;if(n!==t)return Xf(n),n},gn.prototype.enqueue=function(t){var n=this._sentinel;t._prev&&t._next&&Xf(t),t._next=n._next,n._next._prev=t,n._next=t,t._prev=n},gn.prototype.toString=function(){for(var t=[],n=this._sentinel,o=n._prev;o!==n;)t.push(JSON.stringify(o,Uw)),o=o._prev;return"["+t.join(", ")+"]"};function Xf(t){t._prev._next=t._next,t._next._prev=t._prev,delete t._next,delete t._prev}function Uw(t,n){if(t!=="_next"&&t!=="_prev")return n}var lt=Ve,jw=Je.Graph,zw=Mw,Hw=Gw,Kw=lt.constant(1);function Gw(t,n){if(t.nodeCount()<=1)return[];var o=$w(t,n||Kw),a=Yw(o.graph,o.buckets,o.zeroIdx);return lt.flatten(lt.map(a,function(r){return t.outEdges(r.v,r.w)}),!0)}function Yw(t,n,o){for(var a=[],r=n[n.length-1],l=n[0],i;t.nodeCount();){for(;i=l.dequeue();)Ii(t,n,o,i);for(;i=r.dequeue();)Ii(t,n,o,i);if(t.nodeCount()){for(var s=n.length-2;s>0;--s)if(i=n[s].dequeue(),i){a=a.concat(Ii(t,n,o,i,!0));break}}}return a}function Ii(t,n,o,a,r){var l=r?[]:void 0;return lt.forEach(t.inEdges(a.v),function(i){var s=t.edge(i),d=t.node(i.v);r&&l.push({v:i.v,w:i.w}),d.out-=s,Di(n,o,d)}),lt.forEach(t.outEdges(a.v),function(i){var s=t.edge(i),d=i.w,h=t.node(d);h.in-=s,Di(n,o,h)}),t.removeNode(a.v),l}function $w(t,n){var o=new jw,a=0,r=0;lt.forEach(t.nodes(),function(s){o.setNode(s,{v:s,in:0,out:0})}),lt.forEach(t.edges(),function(s){var d=o.edge(s.v,s.w)||0,h=n(s),f=d+h;o.setEdge(s.v,s.w,f),r=Math.max(r,o.node(s.v).out+=h),a=Math.max(a,o.node(s.w).in+=h)});var l=lt.range(r+a+3).map(function(){return new zw}),i=a+1;return lt.forEach(o.nodes(),function(s){Di(l,i,o.node(s))}),{graph:o,buckets:l,zeroIdx:i}}function Di(t,n,o){o.out?o.in?t[o.out-o.in+n].enqueue(o):t[t.length-1].enqueue(o):t[0].enqueue(o)}var xt=Ve,Ww=Hw,Jw={run:Zw,undo:Qw};function Zw(t){var n=t.graph().acyclicer==="greedy"?Ww(t,o(t)):Xw(t);xt.forEach(n,function(a){var r=t.edge(a);t.removeEdge(a),r.forwardName=a.name,r.reversed=!0,t.setEdge(a.w,a.v,r,xt.uniqueId("rev"))});function o(a){return function(r){return a.edge(r).weight}}}function Xw(t){var n=[],o={},a={};function r(l){xt.has(a,l)||(a[l]=!0,o[l]=!0,xt.forEach(t.outEdges(l),function(i){xt.has(o,i.w)?n.push(i):r(i.w)}),delete o[l])}return xt.forEach(t.nodes(),r),n}function Qw(t){xt.forEach(t.edges(),function(n){var o=t.edge(n);if(o.reversed){t.removeEdge(n);var a=o.forwardName;delete o.reversed,delete o.forwardName,t.setEdge(n.w,n.v,o,a)}})}var ge=Ve,Qf=Je.Graph,Oe={addDummyNode:ep,simplify:e0,asNonCompoundGraph:t0,successorWeights:n0,predecessorWeights:o0,intersectRect:r0,buildLayerMatrix:a0,normalizeRanks:l0,removeEmptyRanks:i0,addBorderNode:s0,maxRank:tp,partition:c0,time:d0,notime:u0};function ep(t,n,o,a){var r;do r=ge.uniqueId(a);while(t.hasNode(r));return o.dummy=n,t.setNode(r,o),r}function e0(t){var n=new Qf().setGraph(t.graph());return ge.forEach(t.nodes(),function(o){n.setNode(o,t.node(o))}),ge.forEach(t.edges(),function(o){var a=n.edge(o.v,o.w)||{weight:0,minlen:1},r=t.edge(o);n.setEdge(o.v,o.w,{weight:a.weight+r.weight,minlen:Math.max(a.minlen,r.minlen)})}),n}function t0(t){var n=new Qf({multigraph:t.isMultigraph()}).setGraph(t.graph());return ge.forEach(t.nodes(),function(o){t.children(o).length||n.setNode(o,t.node(o))}),ge.forEach(t.edges(),function(o){n.setEdge(o,t.edge(o))}),n}function n0(t){var n=ge.map(t.nodes(),function(o){var a={};return ge.forEach(t.outEdges(o),function(r){a[r.w]=(a[r.w]||0)+t.edge(r).weight}),a});return ge.zipObject(t.nodes(),n)}function o0(t){var n=ge.map(t.nodes(),function(o){var a={};return ge.forEach(t.inEdges(o),function(r){a[r.v]=(a[r.v]||0)+t.edge(r).weight}),a});return ge.zipObject(t.nodes(),n)}function r0(t,n){var o=t.x,a=t.y,r=n.x-o,l=n.y-a,i=t.width/2,s=t.height/2;if(!r&&!l)throw new Error("Not possible to find intersection inside of the rectangle");var d,h;return Math.abs(l)*i>Math.abs(r)*s?(l<0&&(s=-s),d=s*r/l,h=s):(r<0&&(i=-i),d=i,h=i*l/r),{x:o+d,y:a+h}}function a0(t){var n=ge.map(ge.range(tp(t)+1),function(){return[]});return ge.forEach(t.nodes(),function(o){var a=t.node(o),r=a.rank;ge.isUndefined(r)||(n[r][a.order]=o)}),n}function l0(t){var n=ge.min(ge.map(t.nodes(),function(o){return t.node(o).rank}));ge.forEach(t.nodes(),function(o){var a=t.node(o);ge.has(a,"rank")&&(a.rank-=n)})}function i0(t){var n=ge.min(ge.map(t.nodes(),function(l){return t.node(l).rank})),o=[];ge.forEach(t.nodes(),function(l){var i=t.node(l).rank-n;o[i]||(o[i]=[]),o[i].push(l)});var a=0,r=t.graph().nodeRankFactor;ge.forEach(o,function(l,i){ge.isUndefined(l)&&i%r!==0?--a:a&&ge.forEach(l,function(s){t.node(s).rank+=a})})}function s0(t,n,o,a){var r={width:0,height:0};return arguments.length>=4&&(r.rank=o,r.order=a),ep(t,"border",r,n)}function tp(t){return ge.max(ge.map(t.nodes(),function(n){var o=t.node(n).rank;if(!ge.isUndefined(o))return o}))}function c0(t,n){var o={lhs:[],rhs:[]};return ge.forEach(t,function(a){n(a)?o.lhs.push(a):o.rhs.push(a)}),o}function d0(t,n){var o=ge.now();try{return n()}finally{console.log(t+" time: "+(ge.now()-o)+"ms")}}function u0(t,n){return n()}var np=Ve,h0=Oe,f0={run:p0,undo:g0};function p0(t){t.graph().dummyChains=[],np.forEach(t.edges(),function(n){m0(t,n)})}function m0(t,n){var o=n.v,a=t.node(o).rank,r=n.w,l=t.node(r).rank,i=n.name,s=t.edge(n),d=s.labelRank;if(l!==a+1){t.removeEdge(n);var h,f,p;for(p=0,++a;a<l;++p,++a)s.points=[],f={width:0,height:0,edgeLabel:s,edgeObj:n,rank:a},h=h0.addDummyNode(t,"edge",f,"_d"),a===d&&(f.width=s.width,f.height=s.height,f.dummy="edge-label",f.labelpos=s.labelpos),t.setEdge(o,h,{weight:s.weight},i),p===0&&t.graph().dummyChains.push(h),o=h;t.setEdge(o,r,{weight:s.weight},i)}}function g0(t){np.forEach(t.graph().dummyChains,function(n){var o=t.node(n),a=o.edgeLabel,r;for(t.setEdge(o.edgeObj,a);o.dummy;)r=t.successors(n)[0],t.removeNode(n),a.points.push({x:o.x,y:o.y}),o.dummy==="edge-label"&&(a.x=o.x,a.y=o.y,a.width=o.width,a.height=o.height),n=r,o=t.node(n)})}var bn=Ve,yn={longestPath:b0,slack:y0};function b0(t){var n={};function o(a){var r=t.node(a);if(bn.has(n,a))return r.rank;n[a]=!0;var l=bn.min(bn.map(t.outEdges(a),function(i){return o(i.w)-t.edge(i).minlen}));return(l===Number.POSITIVE_INFINITY||l===void 0||l===null)&&(l=0),r.rank=l}bn.forEach(t.sources(),o)}function y0(t,n){return t.node(n.w).rank-t.node(n.v).rank-t.edge(n).minlen}var _n=Ve,_0=Je.Graph,kn=yn.slack,op=k0;function k0(t){var n=new _0({directed:!1}),o=t.nodes()[0],a=t.nodeCount();n.setNode(o,{});for(var r,l;w0(n,t)<a;)r=V0(n,t),l=n.hasNode(r.v)?kn(t,r):-kn(t,r),C0(n,t,l);return n}function w0(t,n){function o(a){_n.forEach(n.nodeEdges(a),function(r){var l=r.v,i=a===l?r.w:l;!t.hasNode(i)&&!kn(n,r)&&(t.setNode(i,{}),t.setEdge(a,i,{}),o(i))})}return _n.forEach(t.nodes(),o),t.nodeCount()}function V0(t,n){return _n.minBy(n.edges(),function(o){if(t.hasNode(o.v)!==t.hasNode(o.w))return kn(n,o)})}function C0(t,n,o){_n.forEach(t.nodes(),function(a){n.node(a).rank+=o})}var it=Ve,x0=op,N0=yn.slack,B0=yn.longestPath,S0=Je.alg.preorder,E0=Je.alg.postorder,T0=Oe.simplify,I0=Nt;Nt.initLowLimValues=qi,Nt.initCutValues=Fi,Nt.calcCutValue=rp,Nt.leaveEdge=lp,Nt.enterEdge=ip,Nt.exchangeEdges=sp;function Nt(t){t=T0(t),B0(t);var n=x0(t);qi(n),Fi(n,t);for(var o,a;o=lp(n);)a=ip(n,t,o),sp(n,t,o,a)}function Fi(t,n){var o=E0(t,t.nodes());o=o.slice(0,o.length-1),it.forEach(o,function(a){D0(t,n,a)})}function D0(t,n,o){var a=t.node(o),r=a.parent;t.edge(o,r).cutvalue=rp(t,n,o)}function rp(t,n,o){var a=t.node(o),r=a.parent,l=!0,i=n.edge(o,r),s=0;return i||(l=!1,i=n.edge(r,o)),s=i.weight,it.forEach(n.nodeEdges(o),function(d){var h=d.v===o,f=h?d.w:d.v;if(f!==r){var p=h===l,_=n.edge(d).weight;if(s+=p?_:-_,q0(t,o,f)){var C=t.edge(o,f).cutvalue;s+=p?-C:C}}}),s}function qi(t,n){arguments.length<2&&(n=t.nodes()[0]),ap(t,{},1,n)}function ap(t,n,o,a,r){var l=o,i=t.node(a);return n[a]=!0,it.forEach(t.neighbors(a),function(s){it.has(n,s)||(o=ap(t,n,o,s,a))}),i.low=l,i.lim=o++,r?i.parent=r:delete i.parent,o}function lp(t){return it.find(t.edges(),function(n){return t.edge(n).cutvalue<0})}function ip(t,n,o){var a=o.v,r=o.w;n.hasEdge(a,r)||(a=o.w,r=o.v);var l=t.node(a),i=t.node(r),s=l,d=!1;l.lim>i.lim&&(s=i,d=!0);var h=it.filter(n.edges(),function(f){return d===cp(t,t.node(f.v),s)&&d!==cp(t,t.node(f.w),s)});return it.minBy(h,function(f){return N0(n,f)})}function sp(t,n,o,a){var r=o.v,l=o.w;t.removeEdge(r,l),t.setEdge(a.v,a.w,{}),qi(t),Fi(t,n),F0(t,n)}function F0(t,n){var o=it.find(t.nodes(),function(r){return!n.node(r).parent}),a=S0(t,o);a=a.slice(1),it.forEach(a,function(r){var l=t.node(r).parent,i=n.edge(r,l),s=!1;i||(i=n.edge(l,r),s=!0),n.node(r).rank=n.node(l).rank+(s?i.minlen:-i.minlen)})}function q0(t,n,o){return t.hasEdge(n,o)}function cp(t,n,o){return o.low<=n.lim&&n.lim<=o.lim}var A0=yn,dp=A0.longestPath,R0=op,O0=I0,v0=P0;function P0(t){switch(t.graph().ranker){case"network-simplex":up(t);break;case"tight-tree":M0(t);break;case"longest-path":L0(t);break;default:up(t)}}var L0=dp;function M0(t){dp(t),R0(t)}function up(t){O0(t)}var Ai=Ve,U0=j0;function j0(t){var n=H0(t);Ai.forEach(t.graph().dummyChains,function(o){for(var a=t.node(o),r=a.edgeObj,l=z0(t,n,r.v,r.w),i=l.path,s=l.lca,d=0,h=i[d],f=!0;o!==r.w;){if(a=t.node(o),f){for(;(h=i[d])!==s&&t.node(h).maxRank<a.rank;)d++;h===s&&(f=!1)}if(!f){for(;d<i.length-1&&t.node(h=i[d+1]).minRank<=a.rank;)d++;h=i[d]}t.setParent(o,h),o=t.successors(o)[0]}})}function z0(t,n,o,a){var r=[],l=[],i=Math.min(n[o].low,n[a].low),s=Math.max(n[o].lim,n[a].lim),d,h;d=o;do d=t.parent(d),r.push(d);while(d&&(n[d].low>i||s>n[d].lim));for(h=d,d=a;(d=t.parent(d))!==h;)l.push(d);return{path:r.concat(l.reverse()),lca:h}}function H0(t){var n={},o=0;function a(r){var l=o;Ai.forEach(t.children(r),a),n[r]={low:l,lim:o++}}return Ai.forEach(t.children(),a),n}var st=Ve,Ri=Oe,K0={run:G0,cleanup:W0};function G0(t){var n=Ri.addDummyNode(t,"root",{},"_root"),o=Y0(t),a=st.max(st.values(o))-1,r=2*a+1;t.graph().nestingRoot=n,st.forEach(t.edges(),function(i){t.edge(i).minlen*=r});var l=$0(t)+1;st.forEach(t.children(),function(i){hp(t,n,r,l,a,o,i)}),t.graph().nodeRankFactor=r}function hp(t,n,o,a,r,l,i){var s=t.children(i);if(!s.length){i!==n&&t.setEdge(n,i,{weight:0,minlen:o});return}var d=Ri.addBorderNode(t,"_bt"),h=Ri.addBorderNode(t,"_bb"),f=t.node(i);t.setParent(d,i),f.borderTop=d,t.setParent(h,i),f.borderBottom=h,st.forEach(s,function(p){hp(t,n,o,a,r,l,p);var _=t.node(p),C=_.borderTop?_.borderTop:p,k=_.borderBottom?_.borderBottom:p,B=_.borderTop?a:2*a,N=C!==k?1:r-l[i]+1;t.setEdge(d,C,{weight:B,minlen:N,nestingEdge:!0}),t.setEdge(k,h,{weight:B,minlen:N,nestingEdge:!0})}),t.parent(i)||t.setEdge(n,d,{weight:0,minlen:r+l[i]})}function Y0(t){var n={};function o(a,r){var l=t.children(a);l&&l.length&&st.forEach(l,function(i){o(i,r+1)}),n[a]=r}return st.forEach(t.children(),function(a){o(a,1)}),n}function $0(t){return st.reduce(t.edges(),function(n,o){return n+t.edge(o).weight},0)}function W0(t){var n=t.graph();t.removeNode(n.nestingRoot),delete n.nestingRoot,st.forEach(t.edges(),function(o){var a=t.edge(o);a.nestingEdge&&t.removeEdge(o)})}var Oi=Ve,J0=Oe,Z0=X0;function X0(t){function n(o){var a=t.children(o),r=t.node(o);if(a.length&&Oi.forEach(a,n),Oi.has(r,"minRank")){r.borderLeft=[],r.borderRight=[];for(var l=r.minRank,i=r.maxRank+1;l<i;++l)fp(t,"borderLeft","_bl",o,r,l),fp(t,"borderRight","_br",o,r,l)}}Oi.forEach(t.children(),n)}function fp(t,n,o,a,r,l){var i={width:0,height:0,rank:l,borderType:n},s=r[n][l-1],d=J0.addDummyNode(t,"border",i,o);r[n][l]=d,t.setParent(d,a),s&&t.setEdge(s,d,{weight:1})}var tt=Ve,Q0={adjust:eV,undo:tV};function eV(t){var n=t.graph().rankdir.toLowerCase();(n==="lr"||n==="rl")&&pp(t)}function tV(t){var n=t.graph().rankdir.toLowerCase();(n==="bt"||n==="rl")&&nV(t),(n==="lr"||n==="rl")&&(oV(t),pp(t))}function pp(t){tt.forEach(t.nodes(),function(n){mp(t.node(n))}),tt.forEach(t.edges(),function(n){mp(t.edge(n))})}function mp(t){var n=t.width;t.width=t.height,t.height=n}function nV(t){tt.forEach(t.nodes(),function(n){vi(t.node(n))}),tt.forEach(t.edges(),function(n){var o=t.edge(n);tt.forEach(o.points,vi),tt.has(o,"y")&&vi(o)})}function vi(t){t.y=-t.y}function oV(t){tt.forEach(t.nodes(),function(n){Pi(t.node(n))}),tt.forEach(t.edges(),function(n){var o=t.edge(n);tt.forEach(o.points,Pi),tt.has(o,"x")&&Pi(o)})}function Pi(t){var n=t.x;t.x=t.y,t.y=n}var ct=Ve,rV=aV;function aV(t){var n={},o=ct.filter(t.nodes(),function(s){return!t.children(s).length}),a=ct.max(ct.map(o,function(s){return t.node(s).rank})),r=ct.map(ct.range(a+1),function(){return[]});function l(s){if(!ct.has(n,s)){n[s]=!0;var d=t.node(s);r[d.rank].push(s),ct.forEach(t.successors(s),l)}}var i=ct.sortBy(o,function(s){return t.node(s).rank});return ct.forEach(i,l),r}var ft=Ve,lV=iV;function iV(t,n){for(var o=0,a=1;a<n.length;++a)o+=sV(t,n[a-1],n[a]);return o}function sV(t,n,o){for(var a=ft.zipObject(o,ft.map(o,function(h,f){return f})),r=ft.flatten(ft.map(n,function(h){return ft.sortBy(ft.map(t.outEdges(h),function(f){return{pos:a[f.w],weight:t.edge(f).weight}}),"pos")}),!0),l=1;l<o.length;)l<<=1;var i=2*l-1;l-=1;var s=ft.map(new Array(i),function(){return 0}),d=0;return ft.forEach(r.forEach(function(h){var f=h.pos+l;s[f]+=h.weight;for(var p=0;f>0;)f%2&&(p+=s[f+1]),f=f-1>>1,s[f]+=h.weight;d+=h.weight*p})),d}var gp=Ve,cV=dV;function dV(t,n){return gp.map(n,function(o){var a=t.inEdges(o);if(a.length){var r=gp.reduce(a,function(l,i){var s=t.edge(i),d=t.node(i.v);return{sum:l.sum+s.weight*d.order,weight:l.weight+s.weight}},{sum:0,weight:0});return{v:o,barycenter:r.sum/r.weight,weight:r.weight}}else return{v:o}})}var Ue=Ve,uV=hV;function hV(t,n){var o={};Ue.forEach(t,function(r,l){var i=o[r.v]={indegree:0,in:[],out:[],vs:[r.v],i:l};Ue.isUndefined(r.barycenter)||(i.barycenter=r.barycenter,i.weight=r.weight)}),Ue.forEach(n.edges(),function(r){var l=o[r.v],i=o[r.w];!Ue.isUndefined(l)&&!Ue.isUndefined(i)&&(i.indegree++,l.out.push(o[r.w]))});var a=Ue.filter(o,function(r){return!r.indegree});return fV(a)}function fV(t){var n=[];function o(l){return function(i){i.merged||(Ue.isUndefined(i.barycenter)||Ue.isUndefined(l.barycenter)||i.barycenter>=l.barycenter)&&pV(l,i)}}function a(l){return function(i){i.in.push(l),--i.indegree===0&&t.push(i)}}for(;t.length;){var r=t.pop();n.push(r),Ue.forEach(r.in.reverse(),o(r)),Ue.forEach(r.out,a(r))}return Ue.map(Ue.filter(n,function(l){return!l.merged}),function(l){return Ue.pick(l,["vs","i","barycenter","weight"])})}function pV(t,n){var o=0,a=0;t.weight&&(o+=t.barycenter*t.weight,a+=t.weight),n.weight&&(o+=n.barycenter*n.weight,a+=n.weight),t.vs=n.vs.concat(t.vs),t.barycenter=o/a,t.weight=a,t.i=Math.min(n.i,t.i),n.merged=!0}var jt=Ve,mV=Oe,gV=bV;function bV(t,n){var o=mV.partition(t,function(f){return jt.has(f,"barycenter")}),a=o.lhs,r=jt.sortBy(o.rhs,function(f){return-f.i}),l=[],i=0,s=0,d=0;a.sort(yV(!!n)),d=bp(l,r,d),jt.forEach(a,function(f){d+=f.vs.length,l.push(f.vs),i+=f.barycenter*f.weight,s+=f.weight,d=bp(l,r,d)});var h={vs:jt.flatten(l,!0)};return s&&(h.barycenter=i/s,h.weight=s),h}function bp(t,n,o){for(var a;n.length&&(a=jt.last(n)).i<=o;)n.pop(),t.push(a.vs),o++;return o}function yV(t){return function(n,o){return n.barycenter<o.barycenter?-1:n.barycenter>o.barycenter?1:t?o.i-n.i:n.i-o.i}}var pt=Ve,_V=cV,kV=uV,wV=gV,VV=yp;function yp(t,n,o,a){var r=t.children(n),l=t.node(n),i=l?l.borderLeft:void 0,s=l?l.borderRight:void 0,d={};i&&(r=pt.filter(r,function(k){return k!==i&&k!==s}));var h=_V(t,r);pt.forEach(h,function(k){if(t.children(k.v).length){var B=yp(t,k.v,o,a);d[k.v]=B,pt.has(B,"barycenter")&&xV(k,B)}});var f=kV(h,o);CV(f,d);var p=wV(f,a);if(i&&(p.vs=pt.flatten([i,p.vs,s],!0),t.predecessors(i).length)){var _=t.node(t.predecessors(i)[0]),C=t.node(t.predecessors(s)[0]);pt.has(p,"barycenter")||(p.barycenter=0,p.weight=0),p.barycenter=(p.barycenter*p.weight+_.order+C.order)/(p.weight+2),p.weight+=2}return p}function CV(t,n){pt.forEach(t,function(o){o.vs=pt.flatten(o.vs.map(function(a){return n[a]?n[a].vs:a}),!0)})}function xV(t,n){pt.isUndefined(t.barycenter)?(t.barycenter=n.barycenter,t.weight=n.weight):(t.barycenter=(t.barycenter*t.weight+n.barycenter*n.weight)/(t.weight+n.weight),t.weight+=n.weight)}var zt=Ve,NV=Je.Graph,BV=SV;function SV(t,n,o){var a=EV(t),r=new NV({compound:!0}).setGraph({root:a}).setDefaultNodeLabel(function(l){return t.node(l)});return zt.forEach(t.nodes(),function(l){var i=t.node(l),s=t.parent(l);(i.rank===n||i.minRank<=n&&n<=i.maxRank)&&(r.setNode(l),r.setParent(l,s||a),zt.forEach(t[o](l),function(d){var h=d.v===l?d.w:d.v,f=r.edge(h,l),p=zt.isUndefined(f)?0:f.weight;r.setEdge(h,l,{weight:t.edge(d).weight+p})}),zt.has(i,"minRank")&&r.setNode(l,{borderLeft:i.borderLeft[n],borderRight:i.borderRight[n]}))}),r}function EV(t){for(var n;t.hasNode(n=zt.uniqueId("_root")););return n}var TV=Ve,IV=DV;function DV(t,n,o){var a={},r;TV.forEach(o,function(l){for(var i=t.parent(l),s,d;i;){if(s=t.parent(i),s?(d=a[s],a[s]=i):(d=r,r=i),d&&d!==i){n.setEdge(d,i);return}i=s}})}var mt=Ve,FV=rV,qV=lV,AV=VV,RV=BV,OV=IV,vV=Je.Graph,_p=Oe,PV=LV;function LV(t){var n=_p.maxRank(t),o=kp(t,mt.range(1,n+1),"inEdges"),a=kp(t,mt.range(n-1,-1,-1),"outEdges"),r=FV(t);wp(t,r);for(var l=Number.POSITIVE_INFINITY,i,s=0,d=0;d<4;++s,++d){MV(s%2?o:a,s%4>=2),r=_p.buildLayerMatrix(t);var h=qV(t,r);h<l&&(d=0,i=mt.cloneDeep(r),l=h)}wp(t,i)}function kp(t,n,o){return mt.map(n,function(a){return RV(t,a,o)})}function MV(t,n){var o=new vV;mt.forEach(t,function(a){var r=a.graph().root,l=AV(a,r,o,n);mt.forEach(l.vs,function(i,s){a.node(i).order=s}),OV(a,o,l.vs)})}function wp(t,n){mt.forEach(n,function(o){mt.forEach(o,function(a,r){t.node(a).order=r})})}var re=Ve,UV=Je.Graph,jV=Oe,zV={positionX:GV,findType1Conflicts:Vp,findType2Conflicts:Cp,addConflict:Li,hasConflict:xp,verticalAlignment:Np,horizontalCompaction:Bp,alignCoordinates:Ep,findSmallestWidthAlignment:Sp,balance:Tp};function Vp(t,n){var o={};function a(r,l){var i=0,s=0,d=r.length,h=re.last(l);return re.forEach(l,function(f,p){var _=HV(t,f),C=_?t.node(_).order:d;(_||f===h)&&(re.forEach(l.slice(s,p+1),function(k){re.forEach(t.predecessors(k),function(B){var N=t.node(B),q=N.order;(q<i||C<q)&&!(N.dummy&&t.node(k).dummy)&&Li(o,B,k)})}),s=p+1,i=C)}),l}return re.reduce(n,a),o}function Cp(t,n){var o={};function a(l,i,s,d,h){var f;re.forEach(re.range(i,s),function(p){f=l[p],t.node(f).dummy&&re.forEach(t.predecessors(f),function(_){var C=t.node(_);C.dummy&&(C.order<d||C.order>h)&&Li(o,_,f)})})}function r(l,i){var s=-1,d,h=0;return re.forEach(i,function(f,p){if(t.node(f).dummy==="border"){var _=t.predecessors(f);_.length&&(d=t.node(_[0]).order,a(i,h,p,s,d),h=p,s=d)}a(i,h,i.length,d,l.length)}),i}return re.reduce(n,r),o}function HV(t,n){if(t.node(n).dummy)return re.find(t.predecessors(n),function(o){return t.node(o).dummy})}function Li(t,n,o){if(n>o){var a=n;n=o,o=a}var r=t[n];r||(t[n]=r={}),r[o]=!0}function xp(t,n,o){if(n>o){var a=n;n=o,o=a}return re.has(t[n],o)}function Np(t,n,o,a){var r={},l={},i={};return re.forEach(n,function(s){re.forEach(s,function(d,h){r[d]=d,l[d]=d,i[d]=h})}),re.forEach(n,function(s){var d=-1;re.forEach(s,function(h){var f=a(h);if(f.length){f=re.sortBy(f,function(B){return i[B]});for(var p=(f.length-1)/2,_=Math.floor(p),C=Math.ceil(p);_<=C;++_){var k=f[_];l[h]===h&&d<i[k]&&!xp(o,h,k)&&(l[k]=h,l[h]=r[h]=r[k],d=i[k])}}})}),{root:r,align:l}}function Bp(t,n,o,a,r){var l={},i=KV(t,n,o,r),s=r?"borderLeft":"borderRight";function d(p,_){for(var C=i.nodes(),k=C.pop(),B={};k;)B[k]?p(k):(B[k]=!0,C.push(k),C=C.concat(_(k))),k=C.pop()}function h(p){l[p]=i.inEdges(p).reduce(function(_,C){return Math.max(_,l[C.v]+i.edge(C))},0)}function f(p){var _=i.outEdges(p).reduce(function(k,B){return Math.min(k,l[B.w]-i.edge(B))},Number.POSITIVE_INFINITY),C=t.node(p);_!==Number.POSITIVE_INFINITY&&C.borderType!==s&&(l[p]=Math.max(l[p],_))}return d(h,i.predecessors.bind(i)),d(f,i.successors.bind(i)),re.forEach(a,function(p){l[p]=l[o[p]]}),l}function KV(t,n,o,a){var r=new UV,l=t.graph(),i=YV(l.nodesep,l.edgesep,a);return re.forEach(n,function(s){var d;re.forEach(s,function(h){var f=o[h];if(r.setNode(f),d){var p=o[d],_=r.edge(p,f);r.setEdge(p,f,Math.max(i(t,h,d),_||0))}d=h})}),r}function Sp(t,n){return re.minBy(re.values(n),function(o){var a=Number.NEGATIVE_INFINITY,r=Number.POSITIVE_INFINITY;return re.forIn(o,function(l,i){var s=$V(t,i)/2;a=Math.max(l+s,a),r=Math.min(l-s,r)}),a-r})}function Ep(t,n){var o=re.values(n),a=re.min(o),r=re.max(o);re.forEach(["u","d"],function(l){re.forEach(["l","r"],function(i){var s=l+i,d=t[s],h;if(d!==n){var f=re.values(d);h=i==="l"?a-re.min(f):r-re.max(f),h&&(t[s]=re.mapValues(d,function(p){return p+h}))}})})}function Tp(t,n){return re.mapValues(t.ul,function(o,a){if(n)return t[n.toLowerCase()][a];var r=re.sortBy(re.map(t,a));return(r[1]+r[2])/2})}function GV(t){var n=jV.buildLayerMatrix(t),o=re.merge(Vp(t,n),Cp(t,n)),a={},r;re.forEach(["u","d"],function(i){r=i==="u"?n:re.values(n).reverse(),re.forEach(["l","r"],function(s){s==="r"&&(r=re.map(r,function(p){return re.values(p).reverse()}));var d=(i==="u"?t.predecessors:t.successors).bind(t),h=Np(t,r,o,d),f=Bp(t,r,h.root,h.align,s==="r");s==="r"&&(f=re.mapValues(f,function(p){return-p})),a[i+s]=f})});var l=Sp(t,a);return Ep(a,l),Tp(a,t.graph().align)}function YV(t,n,o){return function(a,r,l){var i=a.node(r),s=a.node(l),d=0,h;if(d+=i.width/2,re.has(i,"labelpos"))switch(i.labelpos.toLowerCase()){case"l":h=-i.width/2;break;case"r":h=i.width/2;break}if(h&&(d+=o?h:-h),h=0,d+=(i.dummy?n:t)/2,d+=(s.dummy?n:t)/2,d+=s.width/2,re.has(s,"labelpos"))switch(s.labelpos.toLowerCase()){case"l":h=s.width/2;break;case"r":h=-s.width/2;break}return h&&(d+=o?h:-h),h=0,d}}function $V(t,n){return t.node(n).width}var Ht=Ve,Ip=Oe,WV=zV.positionX,JV=ZV;function ZV(t){t=Ip.asNonCompoundGraph(t),XV(t),Ht.forEach(WV(t),function(n,o){t.node(o).x=n})}function XV(t){var n=Ip.buildLayerMatrix(t),o=t.graph().ranksep,a=0;Ht.forEach(n,function(r){var l=Ht.max(Ht.map(r,function(i){return t.node(i).height}));Ht.forEach(r,function(i){t.node(i).y=a+l/2}),a+=l+o})}var se=Ve,Dp=Jw,Fp=f0,QV=v0,eC=Oe.normalizeRanks,tC=U0,nC=Oe.removeEmptyRanks,qp=K0,oC=Z0,Ap=Q0,rC=PV,aC=JV,gt=Oe,lC=Je.Graph,iC=sC;function sC(t,n){var o=n&&n.debugTiming?gt.time:gt.notime;o("layout",function(){var a=o(" buildLayoutGraph",function(){return _C(t)});o(" runLayout",function(){cC(a,o)}),o(" updateInputGraph",function(){dC(t,a)})})}function cC(t,n){n(" makeSpaceForEdgeLabels",function(){kC(t)}),n(" removeSelfEdges",function(){TC(t)}),n(" acyclic",function(){Dp.run(t)}),n(" nestingGraph.run",function(){qp.run(t)}),n(" rank",function(){QV(gt.asNonCompoundGraph(t))}),n(" injectEdgeLabelProxies",function(){wC(t)}),n(" removeEmptyRanks",function(){nC(t)}),n(" nestingGraph.cleanup",function(){qp.cleanup(t)}),n(" normalizeRanks",function(){eC(t)}),n(" assignRankMinMax",function(){VC(t)}),n(" removeEdgeLabelProxies",function(){CC(t)}),n(" normalize.run",function(){Fp.run(t)}),n(" parentDummyChains",function(){tC(t)}),n(" addBorderSegments",function(){oC(t)}),n(" order",function(){rC(t)}),n(" insertSelfEdges",function(){IC(t)}),n(" adjustCoordinateSystem",function(){Ap.adjust(t)}),n(" position",function(){aC(t)}),n(" positionSelfEdges",function(){DC(t)}),n(" removeBorderNodes",function(){EC(t)}),n(" normalize.undo",function(){Fp.undo(t)}),n(" fixupEdgeLabelCoords",function(){BC(t)}),n(" undoCoordinateSystem",function(){Ap.undo(t)}),n(" translateGraph",function(){xC(t)}),n(" assignNodeIntersects",function(){NC(t)}),n(" reversePoints",function(){SC(t)}),n(" acyclic.undo",function(){Dp.undo(t)})}function dC(t,n){se.forEach(t.nodes(),function(o){var a=t.node(o),r=n.node(o);a&&(a.x=r.x,a.y=r.y,n.children(o).length&&(a.width=r.width,a.height=r.height))}),se.forEach(t.edges(),function(o){var a=t.edge(o),r=n.edge(o);a.points=r.points,se.has(r,"x")&&(a.x=r.x,a.y=r.y)}),t.graph().width=n.graph().width,t.graph().height=n.graph().height}var uC=["nodesep","edgesep","ranksep","marginx","marginy"],hC={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},fC=["acyclicer","ranker","rankdir","align"],pC=["width","height"],mC={width:0,height:0},gC=["minlen","weight","width","height","labeloffset"],bC={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},yC=["labelpos"];function _C(t){var n=new lC({multigraph:!0,compound:!0}),o=Ui(t.graph());return n.setGraph(se.merge({},hC,Mi(o,uC),se.pick(o,fC))),se.forEach(t.nodes(),function(a){var r=Ui(t.node(a));n.setNode(a,se.defaults(Mi(r,pC),mC)),n.setParent(a,t.parent(a))}),se.forEach(t.edges(),function(a){var r=Ui(t.edge(a));n.setEdge(a,se.merge({},bC,Mi(r,gC),se.pick(r,yC)))}),n}function kC(t){var n=t.graph();n.ranksep/=2,se.forEach(t.edges(),function(o){var a=t.edge(o);a.minlen*=2,a.labelpos.toLowerCase()!=="c"&&(n.rankdir==="TB"||n.rankdir==="BT"?a.width+=a.labeloffset:a.height+=a.labeloffset)})}function wC(t){se.forEach(t.edges(),function(n){var o=t.edge(n);if(o.width&&o.height){var a=t.node(n.v),r=t.node(n.w),l={rank:(r.rank-a.rank)/2+a.rank,e:n};gt.addDummyNode(t,"edge-proxy",l,"_ep")}})}function VC(t){var n=0;se.forEach(t.nodes(),function(o){var a=t.node(o);a.borderTop&&(a.minRank=t.node(a.borderTop).rank,a.maxRank=t.node(a.borderBottom).rank,n=se.max(n,a.maxRank))}),t.graph().maxRank=n}function CC(t){se.forEach(t.nodes(),function(n){var o=t.node(n);o.dummy==="edge-proxy"&&(t.edge(o.e).labelRank=o.rank,t.removeNode(n))})}function xC(t){var n=Number.POSITIVE_INFINITY,o=0,a=Number.POSITIVE_INFINITY,r=0,l=t.graph(),i=l.marginx||0,s=l.marginy||0;function d(h){var f=h.x,p=h.y,_=h.width,C=h.height;n=Math.min(n,f-_/2),o=Math.max(o,f+_/2),a=Math.min(a,p-C/2),r=Math.max(r,p+C/2)}se.forEach(t.nodes(),function(h){d(t.node(h))}),se.forEach(t.edges(),function(h){var f=t.edge(h);se.has(f,"x")&&d(f)}),n-=i,a-=s,se.forEach(t.nodes(),function(h){var f=t.node(h);f.x-=n,f.y-=a}),se.forEach(t.edges(),function(h){var f=t.edge(h);se.forEach(f.points,function(p){p.x-=n,p.y-=a}),se.has(f,"x")&&(f.x-=n),se.has(f,"y")&&(f.y-=a)}),l.width=o-n+i,l.height=r-a+s}function NC(t){se.forEach(t.edges(),function(n){var o=t.edge(n),a=t.node(n.v),r=t.node(n.w),l,i;o.points?(l=o.points[0],i=o.points[o.points.length-1]):(o.points=[],l=r,i=a),o.points.unshift(gt.intersectRect(a,l)),o.points.push(gt.intersectRect(r,i))})}function BC(t){se.forEach(t.edges(),function(n){var o=t.edge(n);if(se.has(o,"x"))switch((o.labelpos==="l"||o.labelpos==="r")&&(o.width-=o.labeloffset),o.labelpos){case"l":o.x-=o.width/2+o.labeloffset;break;case"r":o.x+=o.width/2+o.labeloffset;break}})}function SC(t){se.forEach(t.edges(),function(n){var o=t.edge(n);o.reversed&&o.points.reverse()})}function EC(t){se.forEach(t.nodes(),function(n){if(t.children(n).length){var o=t.node(n),a=t.node(o.borderTop),r=t.node(o.borderBottom),l=t.node(se.last(o.borderLeft)),i=t.node(se.last(o.borderRight));o.width=Math.abs(i.x-l.x),o.height=Math.abs(r.y-a.y),o.x=l.x+o.width/2,o.y=a.y+o.height/2}}),se.forEach(t.nodes(),function(n){t.node(n).dummy==="border"&&t.removeNode(n)})}function TC(t){se.forEach(t.edges(),function(n){if(n.v===n.w){var o=t.node(n.v);o.selfEdges||(o.selfEdges=[]),o.selfEdges.push({e:n,label:t.edge(n)}),t.removeEdge(n)}})}function IC(t){var n=gt.buildLayerMatrix(t);se.forEach(n,function(o){var a=0;se.forEach(o,function(r,l){var i=t.node(r);i.order=l+a,se.forEach(i.selfEdges,function(s){gt.addDummyNode(t,"selfedge",{width:s.label.width,height:s.label.height,rank:i.rank,order:l+ ++a,e:s.e,label:s.label},"_se")}),delete i.selfEdges})})}function DC(t){se.forEach(t.nodes(),function(n){var o=t.node(n);if(o.dummy==="selfedge"){var a=t.node(o.e.v),r=a.x+a.width/2,l=a.y,i=o.x-r,s=a.height/2;t.setEdge(o.e,o.label),t.removeNode(n),o.label.points=[{x:r+2*i/3,y:l-s},{x:r+5*i/6,y:l-s},{x:r+i,y:l},{x:r+5*i/6,y:l+s},{x:r+2*i/3,y:l+s}],o.label.x=o.x,o.label.y=o.y}})}function Mi(t,n){return se.mapValues(se.pick(t,n),Number)}function Ui(t){var n={};return se.forEach(t,function(o,a){n[a.toLowerCase()]=o}),n}var wn=Ve,FC=Oe,qC=Je.Graph,AC={debugOrdering:RC};function RC(t){var n=FC.buildLayerMatrix(t),o=new qC({compound:!0,multigraph:!0}).setGraph({});return wn.forEach(t.nodes(),function(a){o.setNode(a,{label:a}),o.setParent(a,"layer"+t.node(a).rank)}),wn.forEach(t.edges(),function(a){o.setEdge(a.v,a.w,{},a.name)}),wn.forEach(n,function(a,r){var l="layer"+r;o.setNode(l,{rank:"same"}),wn.reduce(a,function(i,s){return o.setEdge(i,s,{style:"invis"}),s})}),o}var OC="0.8.5",Rp={graphlib:Je,layout:iC,debug:AC,util:{time:Oe.time,notime:Oe.notime},version:OC};const Op=$i(Rp);window.graphlib=Rp.graphlib;class vp{constructor(){Cn(this,"lf");Cn(this,"option")}render(n){this.lf=n}getBytesLength(n){if(!n)return 0;let o=0;for(let a=0;a<n.length;a++){const r=n.charCodeAt(a);n.match(/[A-Z]/)?o+=1.5:r>=1&&r<=126||r>=65376&&r<=65439?o+=1:o+=2}return o}layout(n={}){const{nodes:o,edges:a,gridSize:r}=this.lf.graphModel;let l=40,i=40;r>20&&(l=r*2,i=r*2),this.option={type:"dagre",rankdir:"LR",align:"DR",nodesep:l,ranksep:i,begin:[120,120],...n};const d=new vC(this.option).layout({nodes:o.map(f=>({id:f.id,size:{width:f.width,height:f.height},model:f})),edges:a.map(f=>({source:f.sourceNodeId,target:f.targetNodeId,model:f}))}),h={nodes:[],edges:[]};d==null||d.nodes.forEach(f=>{const{model:p}=f,_=p.getData();_.x=f.x,_.y=f.y,h.nodes.push(_)}),d==null||d.edges.forEach(f=>{const{model:p}=f,_=p.getData();if(_.pointsList=this.calcPointsList(p,h.nodes),_.pointsList){const C=_.pointsList[0],k=_.pointsList[_.pointsList.length-1];_.startPoint={x:C.x,y:C.y},_.endPoint={x:k.x,y:k.y},_.text&&_.text.value&&(_.text={x:k.x-this.getBytesLength(_.text.value)*6-10,y:k.y,value:_.text.value})}else _.startPoint=void 0,_.endPoint=void 0,_.text&&_.text.value&&(_.text=_.text.value);h.edges.push(_)}),this.lf.render(h)}pointFilter(n){const o=n;let a=1;for(;a<o.length-1;){const r=o[a-1],l=o[a],i=o[a+1];r.x===l.x&&l.x===i.x||r.y===l.y&&l.y===i.y?o.splice(a,1):a++}return o}calcPointsList(n,o){const a=[];if(this.option.rankdir==="LR"&&n.modelType==="polyline-edge"){const r=this.lf.getNodeModelById(n.sourceNodeId),l=this.lf.getNodeModelById(n.targetNodeId),i=o.find(d=>d.id===n.sourceNodeId),s=o.find(d=>d.id===n.targetNodeId);if(i.x<s.x)return a.push({x:i.x+r.width/2+5,y:i.y+5}),a.push({x:i.x+r.width/2+(n.offset||50),y:i.y+5}),a.push({x:i.x+r.width/2+(n.offset||50),y:s.y+5}),a.push({x:s.x-l.width/2+5,y:s.y+5}),this.pointFilter(a);if(i.x>s.x)return i.y>=s.y?(a.push({x:i.x,y:i.y+r.height/2}),a.push({x:i.x,y:i.y+r.height/2+(n.offset||50)}),a.push({x:s.x,y:i.y+r.height/2+(n.offset||50)}),a.push({x:s.x,y:s.y+l.height/2})):(a.push({x:i.x,y:i.y-r.height/2}),a.push({x:i.x,y:i.y-r.height/2-(n.offset||50)}),a.push({x:s.x,y:i.y-r.height/2-(n.offset||50)}),a.push({x:s.x,y:s.y-l.height/2})),this.pointFilter(a)}}}Cn(vp,"pluginName","dagre");class vC{constructor(n){this.options={rankdir:"TB",align:null,nodesep:50,ranksep:50,controlPoints:!1,...n}}layout(n){const{nodes:o,edges:a}=n;if(!o||o.length===0)return;const r=new Op.graphlib.Graph({multigraph:!0});return r.setGraph({}),r.setDefaultEdgeLabel(()=>({})),r.graph().rankdir=this.options.rankdir,r.graph().align=this.options.align,r.graph().nodesep=this.options.nodesep,r.graph().ranksep=this.options.ranksep,o.forEach(l=>{r.setNode(l.id,{width:l.width||50,height:l.height||50})}),a.forEach(l=>{r.setEdge(l.source,l.target)}),Op.layout(r),o.forEach(l=>{const i=r.node(l.id);l.x=i.x,l.y=i.y}),this.options.controlPoints&&a.forEach(l=>{const i=r.edge(l.source,l.target);l.controlPoints=i.points}),{nodes:o,edges:a}}}const PC={name:"lfControl",props:{lf:{type:Object,default:()=>{}}},data(){return{undoDisable:!0,redoDisable:!0,graphData:null,dataVisible:!1}},mounted(){this.$props.lf.on("history:change",({data:{undoAble:t,redoAble:n}})=>{this.$data.undoDisable=!t,this.$data.redoDisable=!n})},methods:{zoomIn(){this.$props.lf.zoom(!0)},zoomOut(){this.$props.lf.zoom(!1)},zoomReset(){this.$props.lf.resetZoom()},translateRest(){this.$props.lf.resetTranslate()},reset(){this.$props.lf.resetZoom(),this.$props.lf.resetTranslate(),this.$props.lf.translateCenter()},undo(){this.$props.lf.undo()},redo(){this.$props.lf.redo()},download(){this.$props.lf.getSnapshot()},catData(){this.$emit("catData")},showMiniMap(){const{lf:t}=this.$props;t.extension.miniMap.isShow?t.extension.miniMap.hide():t.extension.miniMap.show(t.graphModel.width-178,50)}}};function LC(t,n,o,a,r,l){const i=e.resolveComponent("el-button"),s=e.resolveComponent("el-tooltip"),d=e.resolveComponent("el-button-group");return e.openBlock(),e.createElementBlock("div",null,[e.createVNode(d,null,{default:e.withCtx(()=>[e.createVNode(s,{class:"box-item",effect:"dark",content:"放大",placement:"bottom-end"},{default:e.withCtx(()=>[e.createVNode(i,{plain:"",onClick:l.zoomIn,icon:"el-icon-zoom-in"},null,8,["onClick"])]),_:1}),e.createVNode(s,{class:"box-item",effect:"dark",content:"缩小",placement:"bottom-end"},{default:e.withCtx(()=>[e.createVNode(i,{plain:"",onClick:l.zoomOut,icon:"el-icon-zoom-out"},null,8,["onClick"])]),_:1}),e.createVNode(s,{class:"box-item",effect:"dark",content:"还原(大小&定位)",placement:"bottom-end"},{default:e.withCtx(()=>[e.createVNode(i,{plain:"",onClick:l.reset,icon:"el-icon-location"},null,8,["onClick"])]),_:1}),e.createVNode(s,{class:"box-item",effect:"dark",content:"上一步(ctrl+z)",placement:"bottom-end"},{default:e.withCtx(()=>[e.createVNode(i,{plain:"",onClick:l.undo,icon:"el-icon-arrow-left",disabled:r.undoDisable},null,8,["onClick","disabled"])]),_:1}),e.createVNode(s,{class:"box-item",effect:"dark",content:"下一步(ctrl+y)",placement:"bottom-end"},{default:e.withCtx(()=>[e.createVNode(i,{plain:"",onClick:l.redo,icon:"el-icon-arrow-right",disabled:r.redoDisable},null,8,["onClick","disabled"])]),_:1}),e.createVNode(s,{class:"box-item",effect:"dark",content:"缩略图(点击展开,再次点击关闭)",placement:"bottom-end"},{default:e.withCtx(()=>[e.createVNode(i,{plain:"",onClick:l.showMiniMap,icon:"el-icon-position"},null,8,["onClick"])]),_:1})]),_:1})])}const MC=le(PC,[["render",LC]]),UC={name:"lfNodePanel",props:{lf:Object,nodeList:Array},data(){return{activeNames:""}},mounted(){this.activeNames=this.nodeList[0].title},methods:{dragNode(t){this.$props.lf.dnd.startDrag({type:t.type})}}},jC={class:"node-panel"},zC={class:"node-list"},HC=["onMousedown"],KC={class:"node-label"};function GC(t,n,o,a,r,l){const i=e.resolveComponent("el-collapse-item"),s=e.resolveComponent("el-collapse");return e.openBlock(),e.createElementBlock("div",jC,[e.createVNode(s,{modelValue:r.activeNames,"onUpdate:modelValue":n[0]||(n[0]=d=>r.activeNames=d),accordion:""},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.nodeList,d=>(e.openBlock(),e.createBlock(i,{title:d.title,name:d.title},{default:e.withCtx(()=>[e.createElementVNode("div",zC,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.list,h=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["node-item",[h.type]]),key:h.name,onMousedown:f=>l.dragNode(h)},[e.createElementVNode("i",{class:e.normalizeClass(["iconfont",[h.icon]]),style:e.normalizeStyle({color:h.themeColor})},null,6),e.createElementVNode("span",KC,e.toDisplayString(h.name),1)],42,HC))),128))])]),_:2},1032,["title","name"]))),256))]),_:1},8,["modelValue"])])}const YC=le(UC,[["render",GC],["__scopeId","data-v-663b3bb3"]]);function $C(t){t.register("start",({HtmlNode:n,HtmlNodeModel:o,h:a})=>{class r extends n{setHtml(s){var _,C,k,B,N,q,F,V,j,U,L,R,H;const{properties:d,text:h}=this.props.model,f=document.createElement("div");f.className="lw-flow-node-start",f.style.backgroundColor=((_=d==null?void 0:d.style)==null?void 0:_.backgroundColor)||"",f.style.borderStyle=((C=d==null?void 0:d.style)==null?void 0:C.borderStyle)||"",f.style.borderColor=((k=d==null?void 0:d.style)==null?void 0:k.borderColor)||"",f.style.borderWidth=`${((B=d==null?void 0:d.style)==null?void 0:B.borderWidth)||2}px`,f.style.color=((N=d==null?void 0:d.style)==null?void 0:N.fontColor)||"",f.style.fontSize=`${((q=d==null?void 0:d.style)==null?void 0:q.fontSize)||14}px`,f.style.fontFamily=((F=d==null?void 0:d.style)==null?void 0:F.fontFamily)||"Microsoft YaHei",f.style.lineHeight=((V=d==null?void 0:d.style)==null?void 0:V.lineHeight)||"1",f.style.fontWeight=((j=d==null?void 0:d.style)==null?void 0:j.fontWeight)||"",f.style.justifyContent=((U=d==null?void 0:d.style)==null?void 0:U.textAlign)||"",f.style.textDecoration=((L=d==null?void 0:d.style)==null?void 0:L.textDecoration)||"",f.style.fontStyle=((R=d==null?void 0:d.style)==null?void 0:R.fontStyle)||"";const p=`<span>${((H=d==null?void 0:d.data)==null?void 0:H.name)||"开始"}</span>`;f.innerHTML=p,s.innerHTML="",s.appendChild(f),window.stop=W=>{W.stopPropagation()},window.setData=()=>{const{graphModel:W,model:J}=this.props;W.eventCenter.emit("custom:button-click",J)}}}class l extends o{setAttributes(){this.width=100,this.height=40,this.text.editable=!1}getConnectedTargetRules(){const s=super.getConnectedTargetRules(),d={message:"起始节点不能作为连线的终点",validate:()=>!1};return s.push(d),s}}return{view:r,model:l}})}function WC(t){t.register("end",({HtmlNode:n,HtmlNodeModel:o,h:a})=>{class r extends n{setHtml(s){var _,C,k,B,N,q,F,V,j,U,L,R,H;const{properties:d,text:h}=this.props.model,f=document.createElement("div");f.className="lw-flow-node-end",f.style.backgroundColor=((_=d==null?void 0:d.style)==null?void 0:_.backgroundColor)||"",f.style.borderStyle=((C=d==null?void 0:d.style)==null?void 0:C.borderStyle)||"solid",f.style.borderColor=((k=d==null?void 0:d.style)==null?void 0:k.borderColor)||"",f.style.borderWidth=`${((B=d==null?void 0:d.style)==null?void 0:B.borderWidth)||2}px`,f.style.color=((N=d==null?void 0:d.style)==null?void 0:N.fontColor)||"",f.style.fontSize=`${((q=d==null?void 0:d.style)==null?void 0:q.fontSize)||14}px`,f.style.fontFamily=((F=d==null?void 0:d.style)==null?void 0:F.fontFamily)||"Microsoft YaHei",f.style.lineHeight=((V=d==null?void 0:d.style)==null?void 0:V.lineHeight)||"1",f.style.fontWeight=((j=d==null?void 0:d.style)==null?void 0:j.fontWeight)||"",f.style.justifyContent=((U=d==null?void 0:d.style)==null?void 0:U.textAlign)||"",f.style.textDecoration=((L=d==null?void 0:d.style)==null?void 0:L.textDecoration)||"",f.style.fontStyle=((R=d==null?void 0:d.style)==null?void 0:R.fontStyle)||"";const p=`<span>${((H=d==null?void 0:d.data)==null?void 0:H.name)||"结束"}</span>`;f.innerHTML=p,s.innerHTML="",s.appendChild(f),window.stop=W=>{W.stopPropagation()},window.setData=()=>{const{graphModel:W,model:J}=this.props;W.eventCenter.emit("custom:button-click",J)}}}class l extends o{setAttributes(){this.width=100,this.height=40,this.text.editable=!1}getConnectedSourceRules(){const s=super.getConnectedSourceRules(),d={message:"终止节点不能作为连线的起点",validate:()=>!1};return s.push(d),s}}return{view:r,model:l}})}const Ke={base:{configKeyableSource:{treeProps:{children:"fields"},rowKey:"id",formItems:[{label:"来源名称",name:"name",value:"",minWidth:"80",component:"input",options:{placeholder:"请输入"},rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"名称简写",name:"abbr",value:"",minWidth:"80",component:"input",options:{placeholder:"请输入"}},{label:"关联字段",name:"with",value:"",minWidth:"80",component:"input",options:{placeholder:"请输入"},rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"自动映射",name:"auto",value:!1,minWidth:"75",component:"switch"},{label:"操作",component:"operation",width:"60",fixed:"right",options:{addDelete:[{icon:"",type:"delete",label:"删除"}]}}]},configMapAction:{treeProps:{children:"fields"},rowKey:"id",formItems:[{label:"映射类型",name:"type",value:"",minWidth:"80",component:"select",options:{placeholder:"请选择",items:[{label:"任意映射",value:"any_of"},{label:"直接映射",value:"direct"}]},rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"来源字段",name:"from",value:"",minWidth:"80",component:"sourceField",options:{placeholder:"请输入"},rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"目标字段",name:"into",value:"",minWidth:"80",component:"input",options:{placeholder:"请输入"},rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"操作",component:"operation",width:"60",fixed:"right",options:{addDelete:[{icon:"",type:"delete",label:"删除"}]}}]}},collap:{nodeHtml:[],targetRules:[{message:"目标节点只允许一个上级连接",validate:(t,n,o,a)=>{let{edges:r}=n.graphModel,{id:l}=n;return[...r].filter(s=>{let{targetNodeId:d}={...s};return d==l}).length<1}}],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"来源名称",name:"from",value:"",component:"input",options:{placeholder:"请输入数据表名"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"折叠字段",name:"with",value:"",component:"input",options:{placeholder:"请输入折叠字段名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"折叠排序方式",name:"sort",value:"",component:"input",options:{placeholder:"请输入 例如:batchId, updateTime DESC"},span:24},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},expand:{nodeHtml:[],targetRules:[{message:"目标节点只允许一个上级连接",validate:(t,n,o,a)=>{let{edges:r}=n.graphModel,{id:l}=n;return[...r].filter(s=>{let{targetNodeId:d}={...s};return d==l}).length<1}}],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"来源名称",name:"from",value:"",component:"input",options:{placeholder:"请输入数据表名"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"展开字段名称",name:"with",value:"",component:"input",options:{placeholder:"请输入展开字段名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},filter:{nodeHtml:[],targetRules:[{message:"目标节点只允许一个上级连接",validate:(t,n,o,a)=>{let{edges:r}=n.graphModel,{id:l}=n;return[...r].filter(s=>{let{targetNodeId:d}={...s};return d==l}).length<1}}],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"来源名称",name:"from",value:"",component:"input",options:{placeholder:"请输入数据表名"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"过滤条件",name:"when",value:"",component:"input",options:{placeholder:"请输入 例如:time >= @date(-12M) && active = true"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},joiner:{nodeHtml:[],targetRules:[],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"连接模式",name:"mode",value:"",component:"input",span:24,options:{placeholder:"请输入连接模式"}},{label:"数据来源",name:"from",value:[],component:"KeyableSource",span:24,rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"映射动作",name:"with",value:[],component:"MapAction",options:{placeholder:"请选择映射动作"},span:24,rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},mapper:{nodeHtml:[],targetRules:[{message:"目标节点只允许一个上级连接",validate:(t,n,o,a)=>{let{edges:r}=n.graphModel,{id:l}=n;return[...r].filter(s=>{let{targetNodeId:d}={...s};return d==l}).length<1}}],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"来源名称",name:"from",value:"",component:"input",options:{placeholder:"请输入来源名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"自动映射",name:"auto",value:!1,component:"switch",options:{placeholder:"请输入来源名称"},tips:"自动映射来源/目标表中名称相同的字段",span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"映射动作",name:"with",value:[],component:"MapAction",options:{placeholder:"请选择映射动作"},tips:"启用自动映射时允许为空",span:24,hideHandle:"$.auto",rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"映射动作",name:"with",value:[],component:"MapAction",options:{placeholder:"请选择映射动作"},tips:"启用自动映射时允许为空",span:24,hideHandle:"!$.auto"},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},reduce:{nodeHtml:[],targetRules:[],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"数据来源",name:"from",value:[],component:"KeyableSource",span:24,rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"映射动作",name:"with",value:[],component:"MapAction",options:{placeholder:"请选择映射动作"},span:24,rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},source:{nodeHtml:[],targetRules:[{message:"目标节点只允许一个上级连接",validate:(t,n,o,a)=>{let{edges:r}=n.graphModel,{id:l}=n;return[...r].filter(s=>{let{targetNodeId:d}={...s};return d==l}).length<1}}],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"运行模式",name:"mode",value:"normal",component:"select",span:24,options:{items:[{label:"标准模式",value:"normal"},{label:"折叠模式",value:"collap"},{label:"展开模式",value:"expand"},{label:"SQL模式",value:"sql"}]}},{label:"数据表名",name:"from",value:"",component:"input",options:{placeholder:"请输入数据表名"},tips:"非SQL模式必须填写",span:24,hideHandle:'$.mode == "sql"',rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"数据表名",name:"from",value:"",component:"input",options:{placeholder:"请输入数据表名"},tips:"非SQL模式必须填写",span:24,hideHandle:'$.mode != "sql"'},{label:"所需字段",name:"cols",value:"",component:"input",options:{placeholder:"请输入所需字段"},tips:"多个字段采用逗号分隔,为空时选取所有字段,支持AS关键字。",span:24},{label:"关联字段",name:"with",value:"",component:"input",options:{placeholder:"请输入关联字段"},span:24,hideHandle:'$.mode != "expand" && $.mode != "collap"',rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"关联字段",name:"with",value:"",component:"input",options:{placeholder:"请输入关联字段"},span:24,hideHandle:'$.mode == "expand" || $.mode == "collap"'},{label:"折叠排序方式",name:"sort",value:"",component:"input",options:{placeholder:"请输入 例如:batchId, updateTime DESC"},span:24,hideHandle:'$.mode != "collap"',rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"折叠排序方式",name:"sort",value:"",component:"input",options:{placeholder:"请输入 例如:batchId, updateTime DESC"},span:24,hideHandle:'$.mode == "collap"'},{label:"过滤条件",name:"when",value:"",component:"input",options:{placeholder:"请输入 例如:time >= @date(-12M) && active = true"},span:24},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},target:{nodeHtml:[],targetRules:[{message:"目标节点只允许一个上级连接",validate:(t,n,o,a)=>{let{edges:r}=n.graphModel,{id:l}=n;return[...r].filter(s=>{let{targetNodeId:d}={...s};return d==l}).length<1}}],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"数据来源",name:"from",value:"",component:"input",options:{placeholder:"请输入来源名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"输出名称",name:"into",value:"",component:"input",options:{placeholder:"请输入输出名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"描述信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},timer:{nodeHtml:[{label:"定时器类型",component:"radio",value:"schedule.type"},{label:"日期时间",value:"schedule.date",component:"date",hideHandle:'$.schedule.type != "DATE"'},{label:"日期范围",value:"timeRange",component:"date",hideHandle:'$.schedule.type != "CRON"'},{label:"cron",value:"cron",component:"dateCron",hideHandle:'$.schedule.type != "CRON"'},{label:"天",value:"delay.day",component:"number",hideHandle:'$.schedule.type != "DELAY"'},{label:"小时",value:"delay.hour",component:"number",hideHandle:'$.schedule.type != "DELAY"'},{label:"分钟",value:"delay.minute",component:"number",hideHandle:'$.schedule.type != "DELAY"'},{label:"秒",value:"delay.second",component:"number",hideHandle:'$.schedule.type != "DELAY"'}],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24,rules:[{required:!0,message:"不能为空",trigger:"blur"}]},{label:"定时器类型",name:"schedule",value:"DATE",component:"radio",span:24,options:{name:"type",items:[{label:"单次",value:"DATE"},{label:"多次",value:"CRON"},{label:"延时",value:"DELAY"}]}},{label:"日期时间",name:"schedule",value:"",component:"date",span:24,options:{name:"date",type:"datetime"},hideHandle:'$.schedule.type != "DATE"'},{label:"日期范围",name:"timeRange",value:"",component:"date",span:24,options:{type:"datetimerange",startPlaceholder:"开始时间",endPlaceholder:"结束时间"},hideHandle:'$.schedule.type != "CRON"'},{label:"cron",component:"dateCron",hideHandle:'$.schedule.type != "CRON"'},{label:"天",name:"delay",value:"",component:"number",span:12,options:{name:"day",min:0},hideHandle:'$.schedule.type != "DELAY"'},{label:"小时",name:"delay",value:"",component:"number",span:12,options:{name:"hour",min:0,max:24},hideHandle:'$.schedule.type != "DELAY"'},{label:"分钟",name:"delay",value:"",component:"number",span:12,options:{name:"minute",min:0,max:60},hideHandle:'$.schedule.type != "DELAY"'},{label:"秒",name:"delay",value:"",component:"number",span:12,options:{name:"second",min:0,max:60},hideHandle:'$.schedule.type != "DELAY"'}]}},audience_receive:{nodeHtml:[{label:"事件",component:"select",value:"audienceId"},{label:"人群快照",component:"select",value:"snapshotId"},{label:"营销频次",component:"select",value:"schedule.type"},{label:"触发时间",component:"date",value:"schedule.date",hideHandle:'$.schedule.type != "DATE"'},{label:"时间范围",component:"date",value:"startEndTime","value-format":"YYYY-MM-DD",hideHandle:'$.schedule.type != "CRON"'},{label:"Cron",component:"Cron",value:"schedule.cron",hideHandle:'$.schedule.type != "CRON"'}],targetRules:[],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"选择事件",name:"audienceId",value:"",component:"audienceIdSelect",span:24,options:{items:[],placeholder:"请选择"},rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"人群快照",name:"snapshotId",value:"",component:"snapshotIdSelect",span:24,options:{items:[],placeholder:"请选择"},rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"营销频次",name:"schedule",value:"DATE",component:"select",span:24,options:{name:"type",items:[{label:"单次定时",note:"活动周期内仅触发 1 次",value:"DATE"},{label:"多次定时",note:"活动周期内允许触发多次",value:"CRON"}],placeholder:"请选择"},rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"触发时间",name:"schedule",value:"",component:"scheduleTime",span:24,options:{name:"date",placeholder:"请选择"},hideHandle:'$.schedule.type != "DATE"',rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"触发时间",name:"schedule",value:"",component:"scheduleDate",span:24,options:{name:"startTime",placeholder:"请选择"},hideHandle:'$.schedule.type != "CRON"',rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"备注信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},event_receive:{nodeHtml:[{label:"事件",component:"select",value:"behaviorId"},{label:"时间范围",component:"date",value:"eventTimeRange"},{label:"关联客户",component:"switch",value:"mappingCustomer",activeText:"是",inactiveText:"否"},{label:"去重",component:"switch",value:"unique"},{label:"字段",component:"uniqueField",value:"uniqueField",key:"path",hideHandle:"!$.unique"}],targetRules:[],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"选择事件",name:"behaviorId",value:"",component:"behaviorIdSelect",span:24,options:{items:[],placeholder:"请选择"},rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"时间范围",name:"eventTimeRange",value:[],component:"date",span:24,options:{type:"datetimerange",startPlaceholder:"开始时间",endPlaceholder:"结束时间",format:"YYYY-MM-DD HH:mm:ss",valueFormat:"YYYY-MM-DD HH:mm:ss",placeholder:"请选择"},tips:"活动在运行期间接收指定的时间范围内的行为,超出时间范围的行为数据不处理。",rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"关联客户",name:"mappingCustomer",value:!1,component:"switch",span:24,options:{activeText:"是",inactiveText:"否"},tips:"活动接收到客户的行为数据时,主动根据行为中的客户信息查找完整的客户数据。注意: 当客户的行为数据无法找到对应的客户,则不需要关联客户",rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"去重",name:"unique",component:"uniqueField",span:24},{label:"备注信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}},sms:{nodeHtml:[{label:"沟通模板",component:"select",value:"capabilityId"}],targetRules:[],formConfig:{labelWidth:"70px",labelPosition:"top",formItems:[{label:"短信沟通模板",name:"capabilityId",value:"",component:"capabilityIdSelect",span:24,options:{items:[],placeholder:"请选择"},rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"模板示例",name:"content",component:"content",span:24},{label:"沟通限制",name:"frequencyLimit",value:!0,component:"checkbox",span:24,options:{items:[{label:"限制沟通次数",value:!0}]},message:"超出客户的沟通频次限制时,沟通消息不会发送,并且该客户会停在当前节点不再继续执行",rules:[{required:!0,message:"不能为空",trigger:"change"}]},{label:"备注信息",name:"desp",value:"",component:"input",options:{type:"textarea",placeholder:"请输入"},span:24}]}}};function JC(t,n){t.register(n.type,({HtmlNode:o,HtmlNodeModel:a,h:r})=>{class l extends o{setHtml(d){var C,k,B,N,q,F,V,j,U,L,R,H,W,J;const{properties:h,text:f}=this.props.model,p=document.createElement("div");p.className="lw-flow-node-et2l",p.style.backgroundColor=((C=h==null?void 0:h.style)==null?void 0:C.backgroundColor)||n.themeColor||"",p.style.borderStyle=((k=h==null?void 0:h.style)==null?void 0:k.borderStyle)||"",p.style.borderColor=((B=h==null?void 0:h.style)==null?void 0:B.borderColor)||n.themeColor||"",p.style.borderWidth=`${((N=h==null?void 0:h.style)==null?void 0:N.borderWidth)||2}px`,p.style.color=((q=h==null?void 0:h.style)==null?void 0:q.fontColor)||"",p.style.fontSize=`${((F=h==null?void 0:h.style)==null?void 0:F.fontSize)||12}px`,p.style.fontFamily=((V=h==null?void 0:h.style)==null?void 0:V.fontFamily)||"Microsoft YaHei",p.style.lineHeight=((j=h==null?void 0:h.style)==null?void 0:j.lineHeight)||"1",p.style.fontWeight=((U=h==null?void 0:h.style)==null?void 0:U.fontWeight)||"",p.style.justifyContent=((L=h==null?void 0:h.style)==null?void 0:L.textAlign)||"",p.style.textDecoration=((R=h==null?void 0:h.style)==null?void 0:R.textDecoration)||"",p.style.fontStyle=((H=h==null?void 0:h.style)==null?void 0:H.fontStyle)||"",h.error?p.classList.add("lw-flow-node-error"):p.classList.remove("lw-flow-node-error");const _=`<i class="iconfont ${n.icon}"></i> <span class="text" title="${((W=h==null?void 0:h.data)==null?void 0:W.name)||n.name}">${((J=h==null?void 0:h.data)==null?void 0:J.name)||n.name}</span>`;p.innerHTML=_,d.innerHTML="",d.appendChild(p),window.stop=K=>{K.stopPropagation()},window.setData=()=>{const{graphModel:K,model:ee}=this.props;K.eventCenter.emit("custom:button-click",ee)}}}class i extends a{setAttributes(){this.width=120,this.height=40,this.text.editable=!1}initNodeData(d){var h,f;super.initNodeData(d),(f=(h=Ke[n.type])==null?void 0:h.targetRules)==null||f.forEach(p=>{this.targetRules.push(p)})}}return{view:l,model:i}})}function Pp(t,n,o){function a(l,i){if(Object.keys(i).length===0)return!1;if(typeof l.hideHandle=="string")try{return new Function("data",`return ${l.hideHandle.replace(/\$/g,"data")}`)(i)}catch(s){return console.error("遇到错误时返回默认值:",s),!1}else if(typeof l.hideHandle=="boolean")return l.hideHandle;return!1}function r(l){let i="";return Ke[n.type].nodeHtml.forEach(s=>{var h;let d=(h=s.value)==null?void 0:h.split(".").reduce((f,p)=>f&&f[p],l);if((s==null?void 0:s.component)=="date"&&(Array.isArray(d)?d=`${$e(d[0]).format(s["value-format"]||"YYYY-MM-DD HH:mm:ss")} 到 ${$e(d[1]).format(s["value-format"]||"YYYY-MM-DD HH:mm:ss")}`:d=$e(d).format(s["value-format"]||"YYYY-MM-DD HH:mm:ss")),(s==null?void 0:s.component)=="switch"&&(d=d?s.activeText||"是":s.inactiveText||"否"),o[`lwFlow_${n.type}`]&&o[`lwFlow_${n.type}`][s.value]){let p=o[`lwFlow_${n.type}`][s.value].find(_=>_[s.key||"value"]==d);d=p==null?void 0:p.label}s.hideHandle?a(s,l)||(i+=`<span>${s.label}: ${d||"--"}</span>`):i+=`<span>${s.label}: ${d||"--"}</span>`}),i}t.register(n.type,({HtmlNode:l,HtmlNodeModel:i,h:s})=>{class d extends l{setHtml(p){var N,q,F,V,j,U,L,R,H,W,J,K,ee;const{properties:_,text:C}=this.props.model,k=document.createElement("div");k.className="lw-flow-node-custom",k.style.backgroundColor=((N=_==null?void 0:_.style)==null?void 0:N.backgroundColor)||n.background||"",k.style.borderStyle=((q=_==null?void 0:_.style)==null?void 0:q.borderStyle)||"",k.style.borderColor=((F=_==null?void 0:_.style)==null?void 0:F.borderColor)||n.themeColor||"",k.style.borderWidth=`${((V=_==null?void 0:_.style)==null?void 0:V.borderWidth)||2}px`,k.style.color=((j=_==null?void 0:_.style)==null?void 0:j.fontColor)||"",k.style.fontSize=`${((U=_==null?void 0:_.style)==null?void 0:U.fontSize)||12}px`,k.style.fontFamily=((L=_==null?void 0:_.style)==null?void 0:L.fontFamily)||"Microsoft YaHei",k.style.lineHeight=((R=_==null?void 0:_.style)==null?void 0:R.lineHeight)||"1",k.style.fontWeight=((H=_==null?void 0:_.style)==null?void 0:H.fontWeight)||"",k.style.justifyContent=((W=_==null?void 0:_.style)==null?void 0:W.textAlign)||"",k.style.textDecoration=((J=_==null?void 0:_.style)==null?void 0:J.textDecoration)||"",k.style.fontStyle=((K=_==null?void 0:_.style)==null?void 0:K.fontStyle)||"",_.error?k.classList.add("lw-flow-node-error"):k.classList.remove("lw-flow-node-error");const B=`<div class="top-name" style="border-color: ${n.themeColor};">
15
+ <i class="iconfont ${n.icon}"></i> ${((ee=_==null?void 0:_.data)==null?void 0:ee.name)||n.name}</div>
16
16
  <div class="bottom-content" style="border-color: ${n.themeColor};">
17
17
  ${r({..._.data})}
18
- `;k.innerHTML=S,m.innerHTML="",m.appendChild(k),window.stop=ie=>{ie.stopPropagation()},window.setData=()=>{const{graphModel:ie,model:R}=this.props;ie.eventCenter.emit("custom:button-click",R)}}}class f extends i{setAttributes(){this.width=230,this.height=105,this.text.editable=!1}}return{view:d,model:f}})}const ZC={name:"audienceReceive",data(){return{dataForm:{schedule:{}},...Ke,audienceIdOptions:[],snapshotIdOptions:[],audienceEstimate:"",snapshotEstimate:""}},props:{modelValue:{type:Object,default:()=>({})},lf:{type:Object,default:()=>{}},type:{type:String,default:""}},watch:{modelValue:{handler(t){t&&(this.dataForm=t)},immediate:!0,deep:!0},dataForm:{handler(t,n){Object.keys(n).length>0&&this.$emit("update:modelValue",t)},deep:!0}},computed:{config(){var o,a;let t={labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24}]},n=((o=Ke[this.type])==null?void 0:o.formConfig)||{};return n!=null&&n.labelWidth&&(t.labelWidth=n.labelWidth),n!=null&&n.labelPosition&&(t.labelPosition=n.labelPosition),this.$store.state[`lwFlow_${this.type}`]||(this.$store.state[`lwFlow_${this.type}`]={}),(a=n==null?void 0:n.formItems)==null||a.forEach(async r=>{var l,i,s,d;if((l=r==null?void 0:r.options)!=null&&l.items){if(r.api){let f=await r.api(this.$http);r.options.items=f||[]}(i=r==null?void 0:r.options)!=null&&i.name?this.$store.state[`lwFlow_${this.type}`][`${r.name}.${r.options.name}`]=((s=r==null?void 0:r.options)==null?void 0:s.items)||"":this.$store.state[`lwFlow_${this.type}`][r.name]=((d=r==null?void 0:r.options)==null?void 0:d.items)||""}}),n!=null&&n.formItems&&(t.formItems=n.formItems),t}},methods:{async getaudienceId(t){const n={fields:"name,usageType",expression:"usageType ne TEST"};t&&(n.expression=`AND name like ${t}`);let o=await this.$http.get("/api/ma-manage/{tenantId}/{buCode}/audience/list",n);o=o.map(a=>({value:a.id,label:`[${a.name}] ${a.id}`})),this.$store.state.lwFlow_audience_receive.audienceId=o,this.audienceIdOptions=o},async getSnapshotList(t){let n={};t&&(n={expression:`audienceId eq ${t}`});let{content:o}=await this.$http.get("/api/ma-manage/{tenantId}/{buCode}/audience/snapshot",n),a=o.map(r=>({value:r.id,num:r.num,label:$e(r.createDate).format("YYYY-MM-DD HH:mm:ss")}));this.$store.state.lwFlow_audience_receive.snapshotId=a,this.snapshotIdOptions=a},async onChangeAudience(t){this.getSnapshotList(t),this.dataForm.snapshotId="",this.audienceEstimate=await this.$http.get(`/api/ma-manage/{tenantId}/{buCode}/audience/${t}/count-customers`)},async onChangeSnapshot(t){this.snapshotEstimate=this.snapshotIdOptions.find(n=>n.value===t).num,this.dataForm.snapshotName=this.snapshotIdOptions.find(n=>n.value===t).label},changeDatetimerange(t){t?[this.dataForm.schedule.startTime,this.dataForm.schedule.endTime]=t:(this.dataForm.schedule.startTime="",this.dataForm.schedule.endTime="")}},mounted(){var t;this.getaudienceId(),(t=this.dataForm)!=null&&t.audienceId&&this.getSnapshotList(this.dataForm.audienceId)}},XC={class:"form-item"},QC={key:0,class:"span-top"},ex={class:"form-item"},tx={key:0,class:"span-top"},nx={class:"form-item"};function ox(t,n,o,a,r,l){const i=e.resolveComponent("el-option"),s=e.resolveComponent("el-select"),d=e.resolveComponent("el-date-picker"),f=e.resolveComponent("lwCronSelect"),p=e.resolveComponent("lw-form-mini");return e.openBlock(),e.createBlock(p,{ref:"dataFormRef",config:l.config,modelValue:r.dataForm,"onUpdate:modelValue":n[5]||(n[5]=m=>r.dataForm=m)},{audienceIdSelect:e.withCtx(()=>[e.createElementVNode("div",XC,[e.createVNode(s,{modelValue:r.dataForm.audienceId,"onUpdate:modelValue":n[0]||(n[0]=m=>r.dataForm.audienceId=m),filterable:"",onChange:l.onChangeAudience,placeholder:"请选择"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.audienceIdOptions,m=>(e.openBlock(),e.createBlock(i,{key:m.value,label:m.label,value:m.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue","onChange"]),r.dataForm.snapshotId?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("span",QC," 预估人数 "+e.toDisplayString(r.audienceEstimate!==""?r.audienceEstimate:"--")+" 人",1))])]),snapshotIdSelect:e.withCtx(()=>[e.createElementVNode("div",ex,[e.createVNode(s,{modelValue:r.dataForm.snapshotId,"onUpdate:modelValue":n[1]||(n[1]=m=>r.dataForm.snapshotId=m),filterable:"",onChange:l.onChangeSnapshot,placeholder:"请选择"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.snapshotIdOptions,m=>(e.openBlock(),e.createBlock(i,{key:m.value,label:m.label,value:m.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue","onChange"]),r.dataForm.snapshotId?(e.openBlock(),e.createElementBlock("span",tx,"预估人数 "+e.toDisplayString(r.snapshotEstimate!==""?r.snapshotEstimate:"--")+" 人",1)):e.createCommentVNode("",!0)])]),scheduleTime:e.withCtx(()=>[e.createElementVNode("div",nx,[e.createVNode(d,{modelValue:r.dataForm.schedule.date,"onUpdate:modelValue":n[2]||(n[2]=m=>r.dataForm.schedule.date=m),type:"datetime",format:"YYYY-MM-DD HH:mm:ss","value-format":"YYYY-MM-DDTHH:mm:ss.000ZZ",placeholder:"请选择"},null,8,["modelValue"]),n[6]||(n[6]=e.createElementVNode("span",{class:"text"},"开始活动",-1))])]),scheduleDate:e.withCtx(()=>[e.createVNode(d,{modelValue:r.dataForm.startEndTime,"onUpdate:modelValue":n[3]||(n[3]=m=>r.dataForm.startEndTime=m),type:"daterange",format:"YYYY-MM-DD","start-placeholder":"开始日期","end-placeholder":"结束日期","value-format":"YYYY-MM-DD",placeholder:"请选择",onChange:l.changeDatetimerange,style:{"margin-bottom":"5px"}},null,8,["modelValue","onChange"]),e.createVNode(f,{modelValue:r.dataForm.schedule.cron,"onUpdate:modelValue":n[4]||(n[4]=m=>r.dataForm.schedule.cron=m)},null,8,["modelValue"])]),default:e.withCtx(()=>[n[7]||(n[7]=e.createElementVNode("span",null,null,-1))]),_:1},8,["config","modelValue"])}const rx=le(ZC,[["render",ox],["__scopeId","data-v-8a5c3a46"]]),ax={name:"basicSettings",data(){return{dataForm:{},...Ke,behaviorIdOptions:[],dataModelFields:[]}},props:{modelValue:{type:Object,default:()=>({})},lf:{type:Object,default:()=>{}},type:{type:String,default:""}},watch:{modelValue:{handler(t){t&&(this.dataForm=t)},immediate:!0,deep:!0},dataForm:{handler(t,n){Object.keys(n).length>0&&this.$emit("update:modelValue",t)},deep:!0}},computed:{config(){var o,a;let t={labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24}]},n=((o=Ke[this.type])==null?void 0:o.formConfig)||{};return n!=null&&n.labelWidth&&(t.labelWidth=n.labelWidth),n!=null&&n.labelPosition&&(t.labelPosition=n.labelPosition),this.$store.state[`lwFlow_${this.type}`]||(this.$store.state[`lwFlow_${this.type}`]={}),(a=n==null?void 0:n.formItems)==null||a.forEach(async r=>{var l,i,s,d;if((l=r==null?void 0:r.options)!=null&&l.items){if(r.api){let f=await r.api(this.$http);r.options.items=f||[]}(i=r==null?void 0:r.options)!=null&&i.name?this.$store.state[`lwFlow_${this.type}`][`${r.name}.${r.options.name}`]=((s=r==null?void 0:r.options)==null?void 0:s.items)||"":this.$store.state[`lwFlow_${this.type}`][r.name]=((d=r==null?void 0:r.options)==null?void 0:d.items)||""}}),n!=null&&n.formItems&&(t.formItems=n.formItems),t}},methods:{async getBehaviorList(){const t={fields:"name,modelId,status"};t.expression="status in ENABLED";let n=await this.$http.get("/api/ma-manage/{tenantId}/{buCode}/behavior-event/list",t);n=n.map(o=>({value:o.id,label:o.name,...o})),this.$store.state.lwFlow_event_receive.behaviorId=n,this.behaviorIdOptions=n},onChangeBehavior(t){const n=this.behaviorIdOptions.find(o=>o.value===t);n&&(this.dataForm.behaviorModelId=n.modelId,this.dataForm.eventName=n.name,this.dataForm.uniqueField="",this.findBehaviorModel(n.modelId))},async findBehaviorModel(t){let n=await this.$http.get(`/api/ma-manage/{tenantId}/{buCode}/behavior-model/${t}`);this.$store.state.lwFlow_event_receive.uniqueField=[],this.dataModelFields=this.formatFields(n.fields)},formatFields(t,n){const o=[];return Array.isArray(t)&&t.forEach(a=>{const r=JSON.parse(JSON.stringify(a));n?r.path=`${n.path}.${a.name}`:r.path=a.name,a.aliasName?r.label=`「${a.aliasName}」${a.name}`:r.label=`${a.name}`,a.fields&&a.fields.length>0&&(r.fields=this.formatFields(a.fields,r)),this.$store.state.lwFlow_event_receive.uniqueField.push(r),o.push(r)}),o}},mounted(){var t;this.getBehaviorList(),(t=this.dataForm)!=null&&t.behaviorModelId&&this.findBehaviorModel(this.dataForm.behaviorModelId)}};function lx(t,n,o,a,r,l){const i=e.resolveComponent("el-option"),s=e.resolveComponent("el-select"),d=e.resolveComponent("el-switch"),f=e.resolveComponent("el-tree-select"),p=e.resolveComponent("lw-form-mini");return e.openBlock(),e.createBlock(p,{ref:"dataFormRef",config:l.config,modelValue:r.dataForm,"onUpdate:modelValue":n[3]||(n[3]=m=>r.dataForm=m)},{behaviorIdSelect:e.withCtx(()=>[e.createVNode(s,{modelValue:r.dataForm.behaviorId,"onUpdate:modelValue":n[0]||(n[0]=m=>r.dataForm.behaviorId=m),filterable:"",onChange:l.onChangeBehavior,placeholder:"请选择"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.behaviorIdOptions,m=>(e.openBlock(),e.createBlock(i,{key:m.value,label:m.label,value:m.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue","onChange"])]),uniqueField:e.withCtx(()=>[e.createVNode(d,{modelValue:r.dataForm.unique,"onUpdate:modelValue":n[1]||(n[1]=m=>r.dataForm.unique=m),type:"round"},null,8,["modelValue"]),r.dataForm.unique?(e.openBlock(),e.createBlock(f,{key:0,modelValue:r.dataForm.uniqueField,"onUpdate:modelValue":n[2]||(n[2]=m=>r.dataForm.uniqueField=m),filterable:"","default-expand-all":"",data:r.dataModelFields,"check-strictly":!0,props:{label:"label",value:"path",children:"fields"},placeholder:"请选择字段"},null,8,["modelValue","data"])):e.createCommentVNode("",!0)]),default:e.withCtx(()=>[n[4]||(n[4]=e.createElementVNode("span",null,null,-1))]),_:1},8,["config","modelValue"])}const ix=le(ax,[["render",lx]]),sx={name:"basicSettings",data(){return{dataForm:{},...Ke,communicates:[],content:""}},props:{modelValue:{type:Object,default:()=>({})},lf:{type:Object,default:()=>{}},type:{type:String,default:""}},watch:{modelValue:{handler(t){t&&(this.dataForm=t)},immediate:!0,deep:!0},dataForm:{handler(t,n){Object.keys(n).length>0&&this.$emit("update:modelValue",t)},deep:!0}},computed:{config(){var o,a;let t={labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24}]},n=((o=Ke[this.type])==null?void 0:o.formConfig)||{};return n!=null&&n.labelWidth&&(t.labelWidth=n.labelWidth),n!=null&&n.labelPosition&&(t.labelPosition=n.labelPosition),this.$store.state[`lwFlow_${this.type}`]||(this.$store.state[`lwFlow_${this.type}`]={}),(a=n==null?void 0:n.formItems)==null||a.forEach(async r=>{var l,i,s,d;if((l=r==null?void 0:r.options)!=null&&l.items){if(r.api){let f=await r.api(this.$http);r.options.items=f||[]}(i=r==null?void 0:r.options)!=null&&i.name?this.$store.state[`lwFlow_${this.type}`][`${r.name}.${r.options.name}`]=((s=r==null?void 0:r.options)==null?void 0:s.items)||"":this.$store.state[`lwFlow_${this.type}`][r.name]=((d=r==null?void 0:r.options)==null?void 0:d.items)||""}}),n!=null&&n.formItems&&(t.formItems=n.formItems),t}},methods:{async getCommunicate(){const t={fields:"name,budgetSetting",expression:""};t.expression="type eq sms AND status eq ENABLED";let n=await this.$http.get("/api/ma-manage/{tenantId}/{buCode}/communicate/list",t);n=n.map(o=>({value:o.id,label:o.name})),this.$store.state.lwFlow_sms.capabilityId=n,this.communicates=n},async showContent(t){if(t){const n=await this.$http.get(`/api/ma-manage/{tenantId}/{buCode}/communicate/${t}`);this.content=n.setting.template,this.dataForm.budgetSetting.budgetValue=n.budget}}},mounted(){this.getCommunicate(),this.dataForm.capabilityId&&this.showContent(this.dataForm.capabilityId)}},cx={class:"sms-content"};function dx(t,n,o,a,r,l){const i=e.resolveComponent("el-option"),s=e.resolveComponent("el-select"),d=e.resolveComponent("lw-form-mini");return e.openBlock(),e.createBlock(d,{ref:"dataFormRef",config:l.config,modelValue:r.dataForm,"onUpdate:modelValue":n[1]||(n[1]=f=>r.dataForm=f)},{capabilityIdSelect:e.withCtx(()=>[e.createVNode(s,{modelValue:r.dataForm.capabilityId,"onUpdate:modelValue":n[0]||(n[0]=f=>r.dataForm.capabilityId=f),filterable:"","allow-create":"",onChange:l.showContent,placeholder:"请选择"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.communicates,f=>(e.openBlock(),e.createBlock(i,{key:f.value,label:f.label,value:f.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue","onChange"])]),content:e.withCtx(()=>[e.createElementVNode("span",cx,e.toDisplayString(r.content),1)]),default:e.withCtx(()=>[n[2]||(n[2]=e.createElementVNode("span",null,null,-1))]),_:1},8,["config","modelValue"])}const ux=le(sx,[["render",dx],["__scopeId","data-v-e4c7ee6f"]]),hx={name:"basicSettings",data(){return{dataForm:{},...Ke}},props:{modelValue:{type:Object,default:()=>({})},lf:{type:Object,default:()=>{}},type:{type:String,default:""}},watch:{modelValue:{handler(t){t&&(this.dataForm=t)},immediate:!0,deep:!0},dataForm:{handler(t,n){Object.keys(n).length>0&&this.$emit("update:modelValue",t)},deep:!0}},computed:{config(){var o,a;let t={labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24}]},n=((o=Ke[this.type])==null?void 0:o.formConfig)||{};return n=JSON.parse(JSON.stringify(n)),n!=null&&n.labelWidth&&(t.labelWidth=n.labelWidth),n!=null&&n.labelPosition&&(t.labelPosition=n.labelPosition),this.$store.state[`lwFlow_${this.type}`]||(this.$store.state[`lwFlow_${this.type}`]={}),(a=n==null?void 0:n.formItems)==null||a.forEach(async r=>{var l,i,s,d;if((l=r==null?void 0:r.options)!=null&&l.items){if(r.api){let f=await r.api(this.$http);r.options.items=f||[]}(i=r==null?void 0:r.options)!=null&&i.name?this.$store.state[`lwFlow_${this.type}`][`${r.name}.${r.options.name}`]=((s=r==null?void 0:r.options)==null?void 0:s.items)||"":this.$store.state[`lwFlow_${this.type}`][r.name]=((d=r==null?void 0:r.options)==null?void 0:d.items)||""}}),n!=null&&n.formItems&&(t.formItems=n.formItems),t}},methods:{}};function fx(t,n,o,a,r,l){const i=e.resolveComponent("lwCronSelect"),s=e.resolveComponent("lwTableForm"),d=e.resolveComponent("el-input"),f=e.resolveComponent("el-select"),p=e.resolveComponent("lw-form-mini");return e.openBlock(),e.createBlock(p,{ref:"dataFormRef",config:l.config,modelValue:r.dataForm,"onUpdate:modelValue":n[3]||(n[3]=m=>r.dataForm=m)},{dateCron:e.withCtx(()=>[e.createVNode(i,{modelValue:r.dataForm.cron,"onUpdate:modelValue":n[0]||(n[0]=m=>r.dataForm.cron=m)},null,8,["modelValue"])]),KeyableSource:e.withCtx(()=>[e.createVNode(s,{config:t.base.configKeyableSource,modelValue:r.dataForm.from,"onUpdate:modelValue":n[1]||(n[1]=m=>r.dataForm.from=m)},null,8,["config","modelValue"])]),MapAction:e.withCtx(()=>[e.createVNode(s,{config:t.base.configMapAction,modelValue:r.dataForm.with,"onUpdate:modelValue":n[2]||(n[2]=m=>r.dataForm.with=m)},{sourceField:e.withCtx(({row:m})=>[m.type=="direct"?(e.openBlock(),e.createBlock(d,{key:0,size:"small",modelValue:m.from,"onUpdate:modelValue":_=>m.from=_,placeholder:"来源字段"},null,8,["modelValue","onUpdate:modelValue"])):(e.openBlock(),e.createBlock(f,{key:1,modelValue:m.from,"onUpdate:modelValue":_=>m.from=_,multiple:"",filterable:"","allow-create":"",size:"small","default-first-option":"","reserve-keyword":!1,placeholder:"来源字段",style:{width:"100%"}},null,8,["modelValue","onUpdate:modelValue"]))]),_:1},8,["config","modelValue"])]),default:e.withCtx(()=>[n[4]||(n[4]=e.createElementVNode("span",null,null,-1))]),_:1},8,["config","modelValue"])}const px=le(hx,[["render",fx]]),mx={name:"styleSettings",data(){return{dataForm:{}}},props:{modelValue:{type:Object,default:()=>({})},lf:{type:Object,default:()=>{}},id:{type:String,default:""}},watch:{modelValue:{handler(t){this.dataForm=t},deep:!0},dataForm:{handler(t){this.id&&this.lf.setProperties(this.id,{style:t}),this.$emit("update:modelValue",t)},deep:!0}},computed:{config(){return{labelWidth:"70px",labelPosition:"right",size:"medium",formItems:[{label:"背景色",name:"backgroundColor",value:"",component:"color",span:12},{label:"线条样式",name:"borderStyle",value:"",component:"select",options:{placeholder:"请选择",items:[{label:"实线 ─────────────",value:"solid"},{label:"虚线 ---------------------",value:"dashed"},{label:"点线 ·······································",value:"dotted"}]},span:24},{label:"线条颜色",name:"borderColor",value:"",component:"color",span:8},{label:"线条宽度",name:"borderWidth",value:2,component:"number",options:{placeholder:"请选择",min:1},span:16},{label:"文字颜色",name:"fontColor",value:"",component:"color",span:8},{label:"文本大小",name:"fontSize",value:"",component:"number",options:{placeholder:"请选择",min:12,suffix:"px"},span:16},{label:"字体",name:"fontFamily",value:"",component:"select",options:{placeholder:"请选择",items:[{label:"微软雅黑",value:"Microsoft YaHei"},{label:"宋体",value:"SimSun"},{label:"黑体",value:"SimHei"},{label:"楷体",value:"KaiTi"},{label:"隶书",value:"LiSu"},{label:"幼圆",value:"YouYuan"}]},span:24},{label:"行高",name:"lineHeight",value:1,component:"number",options:{placeholder:"请选择",min:1,step:.1},span:16},{label:"对齐",name:"textAlign",value:"",component:"select",options:{placeholder:"请选择",items:[{label:"左对齐",value:"left"},{label:"居中",value:"center"},{label:"右对齐",value:"right"}]},span:24},{label:"文本样式",component:"fontStyle",span:24}]}}},methods:{changeFontWeight(){this.dataForm.fontWeight=this.dataForm.fontWeight==="bold"?"normal":"bold"},changeTextDecoration(){this.dataForm.textDecoration=this.dataForm.textDecoration==="underline"?"none":"underline"},changeFontStyle(){this.dataForm.fontStyle=this.dataForm.fontStyle==="italic"?"normal":"italic"}}};function gx(t,n,o,a,r,l){const i=e.resolveComponent("el-button"),s=e.resolveComponent("lw-form-mini");return e.openBlock(),e.createBlock(s,{ref:"dataFormRef",config:l.config,modelValue:r.dataForm,"onUpdate:modelValue":n[0]||(n[0]=d=>r.dataForm=d)},{fontStyle:e.withCtx(()=>[e.createVNode(i,{size:"small",type:r.dataForm.fontWeight==="bold"?"primary":"",onClick:l.changeFontWeight},{default:e.withCtx(()=>n[1]||(n[1]=[e.createTextVNode("B")])),_:1},8,["type","onClick"]),e.createVNode(i,{size:"small",type:r.dataForm.textDecoration==="underline"?"primary":"",onClick:l.changeTextDecoration},{default:e.withCtx(()=>n[2]||(n[2]=[e.createTextVNode("U")])),_:1},8,["type","onClick"]),e.createVNode(i,{size:"small",type:r.dataForm.fontStyle==="italic"?"primary":"",onClick:l.changeFontStyle},{default:e.withCtx(()=>n[3]||(n[3]=[e.createTextVNode("I")])),_:1},8,["type","onClick"])]),default:e.withCtx(()=>[n[4]||(n[4]=e.createElementVNode("span",null,null,-1))]),_:1},8,["config","modelValue"])}const bx={name:"drawerForm",components:{audienceReceive:rx,eventReceive:ix,sms:ux,basicSettings:px,styleSettings:le(mx,[["render",gx]])},props:{nodeData:{type:Object,default:()=>{}},lf:{type:Object,default:()=>{}},drawerShow:{type:Boolean,default:!1}},watch:{drawerShow:{handler(t){t&&(this.dataForm={...this.dataForm,...this.nodeData}),this.isShow=t},immediate:!0}},data(){return{activeName:"basicInfo",dataForm:{text:{value:""},properties:{data:{},style:{}}},isShow:!1}},methods:{async onSubmit(){await this.$refs.dataFormRef.$refs.dataFormRef.validate();const{id:t}=this.dataForm;this.lf.setProperties(t,{...this.dataForm.properties}),this.close()},close(){this.isShow=!1,this.$nextTick(()=>{this.$emit("onClose")})}}},yx={key:0,class:"drawer-form"};function _x(t,n,o,a,r,l){const i=e.resolveComponent("audienceReceive"),s=e.resolveComponent("eventReceive"),d=e.resolveComponent("sms"),f=e.resolveComponent("basicSettings"),p=e.resolveComponent("el-collapse-item"),m=e.resolveComponent("el-alert"),_=e.resolveComponent("styleSettings"),C=e.resolveComponent("el-collapse"),k=e.resolveComponent("el-button"),S=e.resolveComponent("el-drawer");return e.openBlock(),e.createBlock(S,{modelValue:r.isShow,"onUpdate:modelValue":n[6]||(n[6]=B=>r.isShow=B),title:"节点编辑",direction:"rtl","append-to-body":!0,size:600,"before-close":l.close},{footer:e.withCtx(()=>[e.createVNode(k,{onClick:l.close},{default:e.withCtx(()=>n[7]||(n[7]=[e.createTextVNode("取 消")])),_:1},8,["onClick"]),e.createVNode(k,{type:"primary",onClick:l.onSubmit},{default:e.withCtx(()=>n[8]||(n[8]=[e.createTextVNode("保存")])),_:1},8,["onClick"])]),default:e.withCtx(()=>[r.isShow?(e.openBlock(),e.createElementBlock("div",yx,[e.createVNode(C,{modelValue:r.activeName,"onUpdate:modelValue":n[5]||(n[5]=B=>r.activeName=B),accordion:""},{default:e.withCtx(()=>[e.createVNode(p,{title:"基础信息",name:"basicInfo"},{default:e.withCtx(()=>[["audience_receive"].includes(o.nodeData.type)?(e.openBlock(),e.createBlock(i,{key:0,ref:"dataFormRef",modelValue:r.dataForm.properties.data,"onUpdate:modelValue":n[0]||(n[0]=B=>r.dataForm.properties.data=B),type:o.nodeData.type,lf:o.lf},null,8,["modelValue","type","lf"])):e.createCommentVNode("",!0),["event_receive"].includes(o.nodeData.type)?(e.openBlock(),e.createBlock(s,{key:1,ref:"dataFormRef",modelValue:r.dataForm.properties.data,"onUpdate:modelValue":n[1]||(n[1]=B=>r.dataForm.properties.data=B),type:o.nodeData.type,lf:o.lf},null,8,["modelValue","type","lf"])):e.createCommentVNode("",!0),["sms"].includes(o.nodeData.type)?(e.openBlock(),e.createBlock(d,{key:2,ref:"dataFormRef",modelValue:r.dataForm.properties.data,"onUpdate:modelValue":n[2]||(n[2]=B=>r.dataForm.properties.data=B),type:o.nodeData.type,lf:o.lf},null,8,["modelValue","type","lf"])):(e.openBlock(),e.createBlock(f,{key:3,ref:"dataFormRef",modelValue:r.dataForm.properties.data,"onUpdate:modelValue":n[3]||(n[3]=B=>r.dataForm.properties.data=B),type:o.nodeData.type,lf:o.lf},null,8,["modelValue","type","lf"]))]),_:1}),e.createVNode(p,{title:"样式设置",name:"styleSettings"},{default:e.withCtx(()=>[e.createVNode(m,{title:"基础属性修改就会同步显示,不需要点击保存",type:"success",style:{"margin-bottom":"10px"}}),e.createVNode(_,{modelValue:r.dataForm.properties.style,"onUpdate:modelValue":n[4]||(n[4]=B=>r.dataForm.properties.style=B),lf:o.lf,id:r.dataForm.id},null,8,["modelValue","lf","id"])]),_:1})]),_:1},8,["modelValue"])])):e.createCommentVNode("",!0)]),_:1},8,["modelValue","before-close"])}const kx=le(bx,[["render",_x],["__scopeId","data-v-8a4ae6c2"]]),Lp=[{title:"ET2L节点",list:[{name:"SOURCE",icon:"icon-table",type:"source",themeColor:"#00B050"},{name:"MAPPER",icon:"icon-change-type",type:"mapper",themeColor:"#56C4C3"},{name:"JOINER",icon:"icon-app-cdp",type:"joiner",themeColor:"#7030A0"},{name:"TARGET",icon:"icon-table",type:"target",themeColor:"#0070C0"},{name:"FILTER",icon:"icon-ma-filter",type:"filter",themeColor:"#C7161E"},{name:"COLAP",icon:"icon-ma-branch",type:"collap",themeColor:"#013E75"},{name:"EXPAND",icon:"icon-chaji",type:"expand",themeColor:"#156858"},{name:"REDUCE",icon:"icon-reload",type:"reduce",themeColor:"#EF5612"}]},{title:"营销目标",list:[{name:"事件",icon:"icon-event",type:"event_receive",themeColor:"#39bcc5",background:"#f2fcfa"},{name:"人群包",icon:"icon-user-info",type:"audience_receive",themeColor:"#39BCC5",background:"#f2fcfa"}]},{title:"营销触达",list:[{name:"短信",icon:"icon-auto-reply",type:"sms",themeColor:"#4594f3",background:"#f5faff"},{name:"微信",icon:"icon-scrm-l",type:"wechat",themeColor:"#4594f3",background:"#f5faff"},{name:"邮件",icon:"icon-mail-l",type:"email",themeColor:"#4594f3",background:"#f5faff"},{name:"权益",icon:"icon-license",type:"benefit",themeColor:"#4594f3",background:"#f5faff"},{name:"积分",icon:"icon-coin",type:"benefit",themeColor:"#4594f3",background:"#f5faff"},{name:"优惠券",icon:"icon--coupon-2",type:"coupon",themeColor:"#4594f3",background:"#f5faff"}]},{title:"营销功能",list:[{name:"客户标签",icon:"icon-tag",type:"tag",themeColor:"#39BCC5"},{name:"Flow",icon:"icon-event",type:"flow",themeColor:"#e8ffea"},{name:"扩展数据",icon:"icon-event",type:"extend_data",themeColor:"#ff6d69"},{name:"定制功能",icon:"icon-flow-stop",type:"customization",themeColor:"#ff6d69"}]},{title:"Flow",list:[{name:"flow测试",icon:"icon-event",type:"tag",themeColor:"#39BCC5"}]},{title:"逻辑操作",list:[{name:"交集",icon:"icon-cross",type:"intersect",themeColor:"#fba980"},{name:"并集",icon:"icon-merge",type:"union",themeColor:"#fba980"},{name:"差集",icon:"icon-chaji",type:"exclusion",themeColor:"#fba980"},{name:"过滤",icon:"icon-ma-filter",type:"filter",themeColor:"#fba980"},{name:"去重",icon:"icon-quzhong",type:"unique",themeColor:"#fba980"},{name:"A/B测试",icon:"icon-ABtestshezhi",type:"abtest",themeColor:"#fba980"},{name:"排序",icon:"icon-sort-fill",type:"sort",themeColor:"#fba980"}]},{title:"流程控制",list:[{name:"开始",icon:"icon-start",type:"start",themeColor:"#39BCC5"},{name:"定时",icon:"icon-timing",type:"timer",themeColor:"#105a63"},{name:"限流",icon:"icon-timing",type:"restrict",themeColor:"#105a63"},{name:"结束",icon:"icon-flow-stop",type:"end",themeColor:"#ff6d69"}]}],wx={components:{lfControl:MC,lfNodePanel:YC,nodeEdit:kx},props:{modelValue:{type:Object,default:()=>({})},nodes:{type:Array,default:()=>[]},nodeDatas:{type:Object,default:()=>Ke},configNodesList:{type:Object,default:()=>Lp},showDefaultNode:{type:Boolean,default:!0},isView:{type:Boolean,default:!1},showNodeGroup:{type:Array,default:[]},apiNodes:{type:Array,default:[]},options:{type:Object,default:()=>({grid:{size:10,visible:!0,type:"mesh",config:{color:"#f0f0f0",thickness:.5}}})}},watch:{modelValue:{handler(t,n){!n&&!this.logicFlow&&this.init()},deep:!0}},data(){return{logicFlow:null,drawerShow:!1,clickNode:null}},computed:{nodeList(){let t=Lp,n={};return this.apiNodes.forEach(o=>{n[o.groupName]||(n[o.groupName]={title:o.groupName,list:[]}),n[o.groupName].list.push(o)}),this.showDefaultNode?t=[...t,...Object.values(n)]:t=Object.values(n),this.showNodeGroup.length>0&&(t=t.filter(o=>this.showNodeGroup.includes(o.title))),t}},mounted(){this.init()},methods:{async init(){var t;this.logicFlow=new lm({container:this.$refs.container,plugins:[zi.Menu,zi.MiniMap,vp],isSilentMode:this.isView,hoverOutline:!this.isView,nodeSelectedOutline:!this.isView,edgeSelectedOutline:!this.isView,...this.options}),this.initMenu(),await this.initNode(),this.modelValue&&((t=this.modelValue)==null?void 0:t.nodes.length)>0?this.logicFlow.render(this.modelValue):this.initNodeData(),this.bindEvent(),this.logicFlow.translateCenter()},async initNodeData(){function t(){return"xxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(i){const s=Math.random()*16|0;return(i==="x"?s:s&3|8).toString(16)})}function n(i){return{id:t(),type:i.type||"",x:0,y:0,properties:{data:i}}}function o(i,s){return{id:t(),type:"polyline",sourceNodeId:i.id,targetNodeId:s.id}}const a=[],r=[],l={};this.nodes.forEach(i=>{const s=n(i);a.push(s),l[i.into]=s}),this.nodes.forEach(i=>{let s=Array.isArray(i.from)?i.from.map(f=>f.name):[i.from];const d=i.into;s.forEach(f=>{l[f]&&l[d]&&r.push(o(l[f],l[d]))})}),this.logicFlow.renderRawData({nodes:a,edges:r}),this.logicFlow.extension.dagre.layout({nodesep:60,ranksep:140})},initMenu(){let t=this;this.logicFlow.extension.menu.setMenuConfig({nodeMenu:[{text:"删除",callback(n){t.logicFlow.deleteNode(n.id)}},{text:"编辑",callback(n){t.nodeEditOpen(n),t.$emit("edit",n)}},{text:"复制",callback:n=>{this.logicFlow.cloneNode(n.id)}}],edgeMenu:[{text:"删除",callback(n){t.logicFlow.deleteEdge(n.id)}},{text:"编辑",callback(n){t.nodeEditOpen(n),t.$emit("edit",n)}},{text:"直线",callback(n){t.logicFlow.changeEdgeType(n.id,"line")}},{text:"曲线",callback(n){t.logicFlow.changeEdgeType(n.id,"bezier")}},{text:"折线",callback(n){t.logicFlow.changeEdgeType(n.id,"polyline")}},{text:"开启动画",callback(n){t.logicFlow.openEdgeAnimation(n.id)}},{text:"关闭动画",callback(n){t.logicFlow.closeEdgeAnimation(n.id)}}],graphMenu:[]})},async initNode(){for(const t of this.nodeList)for(const n of t.list)switch(n.type){case"start":await $C(this.logicFlow);break;case"end":await WC(this.logicFlow);break;case"source":case"mapper":case"joiner":case"target":case"filter":case"collap":case"expand":case"reduce":await JC(this.logicFlow,n);break;case"event_receive":await Pp(this.logicFlow,n,this.$store.state);break;default:await Pp(this.logicFlow,n,this.$store.state);break}},getNodes(t){let n=[];return t.forEach(o=>{n.push({...o.properties.data,type:o.type})}),n},bindEvent(){this.logicFlow.on("node:dbclick",({data:t})=>{this.nodeEditOpen(t)}),this.logicFlow.on("edge:dbclick",({data:t})=>{this.nodeEditOpen(t)}),this.logicFlow.on("blank:click",()=>{this.drawerShow=!1}),this.logicFlow.on("history:change",({data:t})=>{let{undos:n}=t;this.$emit("change",n),this.$emit("update:modelValue",n[n.length-1]),this.$emit("update:nodes",this.getNodes(n[n.length-1].nodes,n[n.length-1].edges))}),this.logicFlow.on("connection:not-allowed",t=>{this.$message({type:"error",message:t.msg})}),this.changeEdge()},changeEdge(){this.logicFlow.on("edge:add",({data:t})=>{}),this.logicFlow.on("edge:delete",({data:t})=>{})},nodeEditClose(){this.drawerShow=!1},nodeEditOpen(t){delete t.properties.error,this.logicFlow.setProperties(t.id,{error:!1}),this.clickNode=t,this.drawerShow=!0},async validate(){let{nodes:t}=this.logicFlow.getGraphData(),n={};for(const o of t){let{formConfig:a}=Ke[o.type],{formItems:r}=a,{data:l}=o.properties;if((r==null?void 0:r.length)>0)for(const i of r){let s=l&&l[i==null?void 0:i.name],d=!1;if(l&&typeof(i==null?void 0:i.hideHandle)=="string")try{d=new Function("data",`return ${i.hideHandle.replace(/\$/g,"data")}`)(l)}catch(f){console.error("遇到错误时返回默认值:",f),d=!1}else l&&typeof(i==null?void 0:i.hideHandle)=="boolean"&&(d=i.hideHandle);if(!d&&(i!=null&&i.rules)&&(s==null||s===""||Array.isArray(s)&&s.length===0)){this.logicFlow.setProperties(o.id,{data:l,error:!0}),n[o.id]=!0;break}}n[o.id]||this.logicFlow.setProperties(o.id,{data:l,error:!1})}return Object.keys(n).length===0}}},Vx={class:"logic-flow"},Cx={ref:"container",class:"logic-flow-body"};function xx(t,n,o,a,r,l){const i=e.resolveComponent("lfControl"),s=e.resolveComponent("lfNodePanel"),d=e.resolveComponent("nodeEdit");return e.openBlock(),e.createElementBlock("div",Vx,[e.createElementVNode("div",Cx,null,512),r.logicFlow?(e.openBlock(),e.createBlock(i,{key:0,class:"logic-flow-control",lf:r.logicFlow},null,8,["lf"])):e.createCommentVNode("",!0),o.isView?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[r.logicFlow?(e.openBlock(),e.createBlock(s,{key:0,class:"logic-flow-node",lf:r.logicFlow,nodeList:l.nodeList},null,8,["lf","nodeList"])):e.createCommentVNode("",!0),e.createVNode(d,{lf:r.logicFlow,drawerShow:r.drawerShow,nodeData:r.clickNode,onOnClose:l.nodeEditClose},null,8,["lf","drawerShow","nodeData","onOnClose"])],64))])}const Mp=le(wx,[["render",xx],["__scopeId","data-v-d788418a"]]),Nx={loginPage:{accountLoginNologo:"Marketing Cloud",accountLogin:"Lianwei Marketing Cloud",rememberMe:"Keep me logged in",forgetPassword:"Forgot password",signIn:"Account verification",userPlaceholder:"Username / Mobile / Email",userError:"Please enter your username",PWPlaceholder:"Please enter your password",PWError:"Please enter your password",mobileError:"Please enter your mobile number",trialRequest:"Request a trial",enterTitle:"Please enter your title",enterPhone:"Please enter your phone number",correctPhone:"Please enter a valid phone number format",enterCompany:"Please enter your company name",selectPosition:"Please select your position",selectPurpose:"Please select your purpose",noAccount:"Don’t have an account?",applySuccess:"You have applied for a trial, please check your SMS for a prompt.",loginSuccess:"Login successful"},positions:{techStaff:"Technical staff",businessStaff:"Business staff",researchStaff:"Research and development staff",marketingStaff:"Marketing staff",operationStaff:"Operations staff",otherStaff:"Other professional staff"},purposes:{findSolution:"Looking for suitable products to solve data, marketing, and other issues",compareProducts:"Comparing other products, want to learn more",other:"Other"}},Bx={loginPage:{accountLoginNologo:"营销云",accountLogin:"联蔚营销云",rememberMe:"保持登录状态",forgetPassword:"忘记密码",signIn:"账号验证",userPlaceholder:"用户名 / 手机 / 邮箱",userError:"请输入用户名",PWPlaceholder:"请输入密码",PWError:"请输入密码",mobileError:"请输入手机号码",trialRequest:"申请试用",enterTitle:"请输入您的称谓",enterPhone:"请输入手机号",correctPhone:"请输入正确的手机号格式",enterCompany:"请输入您的公司名称",selectPosition:"请选择您的职位",selectPurpose:"请选择您的用途",noAccount:"还没有账号 ?",applySuccess:"您已申请试用,请注意查收短信提示。",loginSuccess:"登录成功"},positions:{techStaff:"技术人员",businessStaff:"业务人员",researchStaff:"研发人员",marketingStaff:"市场人员",operationStaff:"运营人员",otherStaff:"其他专业人员"},purposes:{findSolution:"寻找合适的产品来解决数据,营销等问题",compareProducts:"正在对比其他产品,想了解",other:"其他"}},Sx={lwSearch:{please_select:"Please select",please_input:"Please input",dateRange:{startPlaceholder:"Start Time",endPlaceholder:"End Time"},monthRange:{rangeSeparator:"To",startPlaceholder:"Start Month",endPlaceholder:"End Month"}}},Ex={lwSearch:{please_select:"请选择",please_input:"请输入",dateRange:{startPlaceholder:"开始时间",endPlaceholder:"结束时间"},monthRange:{rangeSeparator:"至",startPlaceholder:"开始月",endPlaceholder:"结束月"}}},Tx={lwTable:{tools:{lineHeightName:"row height",lineHeight:{mini:"Compact",small:"Medium",medium:"High",large:"Extra High"},border:"Border",columnsSetting:"Column Settings",allCheck:"Select All",hasChecked:"Selected",cancel:"Cancel",fullScreen:"Full Screen",table_before:"Before the table",column_fixed:"Column fixed",last_column_fixed:"Last column fixed",please_select:"Please select...",total:"total",recordsPage:"records Page",pages:"pages"}}},Ix={lwTable:{tools:{lineHeightName:"行高",lineHeight:{mini:"紧凑",small:"中等",medium:"高",large:"较高"},border:"边框",columnsSetting:"列设置",allCheck:"全选",hasChecked:"已选",cancel:"取消",fullScreen:"全屏",table_before:"表格前",column_fixed:"列固定",last_column_fixed:"最后一列固定",please_select:"请选择...",total:"共",recordsPage:"条记录 第",pages:"页"}}};let Dx=localStorage.getItem("langMessageUi"),Kt={...JSON.parse(Dx)||{}};Kt["en-us"]={...Nx,...Sx,...Tx},Kt["zh-cn"]={...Bx,...Ex,...Ix},localStorage.setItem("langMessageUi",JSON.stringify(Kt));function Fx(t,n={}){if(n)for(const o in n)n.hasOwnProperty(o)&&(t.config.globalProperties[`$${o.toUpperCase()}`]=n[o]);t.directive("copy",im),t.directive("auth",sm),t.component("lwLayout",Yi),t.component("lwLogin",Ji),t.component("lwSearch",Zi),t.component("lwSvgIcon",Xi),t.component("lwTable",Qi),t.component("lwForm",es),t.component("lwFormMini",ns),t.component("lwUpload",St),t.component("lwIconSelect",os),t.component("lwTableSelect",rs),t.component("lwTableForm",as),t.component("lwFormView",is),t.component("lwFormJson",ls),t.component("lwCronSelect",ss),t.component("lwFlow",Mp)}const qx={install:Fx,uiI18n:Kt};he.default=qx,he.lwCronSelect=ss,he.lwFlow=Mp,he.lwForm=es,he.lwFormJson=ls,he.lwFormMini=ns,he.lwFormView=is,he.lwIconSelect=os,he.lwLayout=Yi,he.lwLogin=Ji,he.lwSearch=Zi,he.lwSvgIcon=Xi,he.lwTable=Qi,he.lwTableForm=as,he.lwTableSelect=rs,he.lwUpload=St,he.uiI18n=Kt,Object.defineProperties(he,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
18
+ `;k.innerHTML=B,p.innerHTML="",p.appendChild(k),window.stop=ie=>{ie.stopPropagation()},window.setData=()=>{const{graphModel:ie,model:O}=this.props;ie.eventCenter.emit("custom:button-click",O)}}}class h extends i{setAttributes(){this.width=230,this.height=105,this.text.editable=!1}}return{view:d,model:h}})}const ZC={name:"audienceReceive",data(){return{dataForm:{schedule:{}},...Ke,audienceIdOptions:[],snapshotIdOptions:[],audienceEstimate:"",snapshotEstimate:""}},props:{modelValue:{type:Object,default:()=>({})},lf:{type:Object,default:()=>{}},type:{type:String,default:""}},watch:{modelValue:{handler(t){t&&(this.dataForm=t)},immediate:!0,deep:!0},dataForm:{handler(t,n){Object.keys(n).length>0&&this.$emit("update:modelValue",t)},deep:!0}},computed:{config(){var o,a;let t={labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24}]},n=((o=Ke[this.type])==null?void 0:o.formConfig)||{};return n!=null&&n.labelWidth&&(t.labelWidth=n.labelWidth),n!=null&&n.labelPosition&&(t.labelPosition=n.labelPosition),this.$store.state[`lwFlow_${this.type}`]||(this.$store.state[`lwFlow_${this.type}`]={}),(a=n==null?void 0:n.formItems)==null||a.forEach(async r=>{var l,i,s,d;if((l=r==null?void 0:r.options)!=null&&l.items){if(r.api){let h=await r.api(this.$http);r.options.items=h||[]}(i=r==null?void 0:r.options)!=null&&i.name?this.$store.state[`lwFlow_${this.type}`][`${r.name}.${r.options.name}`]=((s=r==null?void 0:r.options)==null?void 0:s.items)||"":this.$store.state[`lwFlow_${this.type}`][r.name]=((d=r==null?void 0:r.options)==null?void 0:d.items)||""}}),n!=null&&n.formItems&&(t.formItems=n.formItems),t}},methods:{async getaudienceId(t){const n={fields:"name,usageType",expression:"usageType ne TEST"};t&&(n.expression=`AND name like ${t}`);let o=await this.$http.get("/api/ma-manage/{tenantId}/{buCode}/audience/list",n);o=o.map(a=>({value:a.id,label:`[${a.name}] ${a.id}`})),this.$store.state.lwFlow_audience_receive.audienceId=o,this.audienceIdOptions=o},async getSnapshotList(t){let n={};t&&(n={expression:`audienceId eq ${t}`});let{content:o}=await this.$http.get("/api/ma-manage/{tenantId}/{buCode}/audience/snapshot",n),a=o.map(r=>({value:r.id,num:r.num,label:$e(r.createDate).format("YYYY-MM-DD HH:mm:ss")}));this.$store.state.lwFlow_audience_receive.snapshotId=a,this.snapshotIdOptions=a},async onChangeAudience(t){this.getSnapshotList(t),this.dataForm.snapshotId="",this.audienceEstimate=await this.$http.get(`/api/ma-manage/{tenantId}/{buCode}/audience/${t}/count-customers`)},async onChangeSnapshot(t){this.snapshotEstimate=this.snapshotIdOptions.find(n=>n.value===t).num,this.dataForm.snapshotName=this.snapshotIdOptions.find(n=>n.value===t).label},changeDatetimerange(t){t?[this.dataForm.schedule.startTime,this.dataForm.schedule.endTime]=t:(this.dataForm.schedule.startTime="",this.dataForm.schedule.endTime="")}},mounted(){var t;this.getaudienceId(),(t=this.dataForm)!=null&&t.audienceId&&this.getSnapshotList(this.dataForm.audienceId)}},XC={class:"form-item"},QC={key:0,class:"span-top"},ex={class:"form-item"},tx={key:0,class:"span-top"},nx={class:"form-item"};function ox(t,n,o,a,r,l){const i=e.resolveComponent("el-option"),s=e.resolveComponent("el-select"),d=e.resolveComponent("el-date-picker"),h=e.resolveComponent("lwCronSelect"),f=e.resolveComponent("lw-form-mini");return e.openBlock(),e.createBlock(f,{ref:"dataFormRef",config:l.config,modelValue:r.dataForm,"onUpdate:modelValue":n[5]||(n[5]=p=>r.dataForm=p)},{audienceIdSelect:e.withCtx(()=>[e.createElementVNode("div",XC,[e.createVNode(s,{modelValue:r.dataForm.audienceId,"onUpdate:modelValue":n[0]||(n[0]=p=>r.dataForm.audienceId=p),filterable:"",onChange:l.onChangeAudience,placeholder:"请选择"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.audienceIdOptions,p=>(e.openBlock(),e.createBlock(i,{key:p.value,label:p.label,value:p.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue","onChange"]),r.dataForm.snapshotId?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("span",QC," 预估人数 "+e.toDisplayString(r.audienceEstimate!==""?r.audienceEstimate:"--")+" 人",1))])]),snapshotIdSelect:e.withCtx(()=>[e.createElementVNode("div",ex,[e.createVNode(s,{modelValue:r.dataForm.snapshotId,"onUpdate:modelValue":n[1]||(n[1]=p=>r.dataForm.snapshotId=p),filterable:"",onChange:l.onChangeSnapshot,placeholder:"请选择"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.snapshotIdOptions,p=>(e.openBlock(),e.createBlock(i,{key:p.value,label:p.label,value:p.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue","onChange"]),r.dataForm.snapshotId?(e.openBlock(),e.createElementBlock("span",tx,"预估人数 "+e.toDisplayString(r.snapshotEstimate!==""?r.snapshotEstimate:"--")+" 人",1)):e.createCommentVNode("",!0)])]),scheduleTime:e.withCtx(()=>[e.createElementVNode("div",nx,[e.createVNode(d,{modelValue:r.dataForm.schedule.date,"onUpdate:modelValue":n[2]||(n[2]=p=>r.dataForm.schedule.date=p),type:"datetime",format:"YYYY-MM-DD HH:mm:ss","value-format":"YYYY-MM-DDTHH:mm:ss.000ZZ",placeholder:"请选择"},null,8,["modelValue"]),n[6]||(n[6]=e.createElementVNode("span",{class:"text"},"开始活动",-1))])]),scheduleDate:e.withCtx(()=>[e.createVNode(d,{modelValue:r.dataForm.startEndTime,"onUpdate:modelValue":n[3]||(n[3]=p=>r.dataForm.startEndTime=p),type:"daterange",format:"YYYY-MM-DD","start-placeholder":"开始日期","end-placeholder":"结束日期","value-format":"YYYY-MM-DD",placeholder:"请选择",onChange:l.changeDatetimerange,style:{"margin-bottom":"5px"}},null,8,["modelValue","onChange"]),e.createVNode(h,{modelValue:r.dataForm.schedule.cron,"onUpdate:modelValue":n[4]||(n[4]=p=>r.dataForm.schedule.cron=p)},null,8,["modelValue"])]),default:e.withCtx(()=>[n[7]||(n[7]=e.createElementVNode("span",null,null,-1))]),_:1},8,["config","modelValue"])}const rx=le(ZC,[["render",ox],["__scopeId","data-v-8a5c3a46"]]),ax={name:"basicSettings",data(){return{dataForm:{},...Ke,behaviorIdOptions:[],dataModelFields:[]}},props:{modelValue:{type:Object,default:()=>({})},lf:{type:Object,default:()=>{}},type:{type:String,default:""}},watch:{modelValue:{handler(t){t&&(this.dataForm=t)},immediate:!0,deep:!0},dataForm:{handler(t,n){Object.keys(n).length>0&&this.$emit("update:modelValue",t)},deep:!0}},computed:{config(){var o,a;let t={labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24}]},n=((o=Ke[this.type])==null?void 0:o.formConfig)||{};return n!=null&&n.labelWidth&&(t.labelWidth=n.labelWidth),n!=null&&n.labelPosition&&(t.labelPosition=n.labelPosition),this.$store.state[`lwFlow_${this.type}`]||(this.$store.state[`lwFlow_${this.type}`]={}),(a=n==null?void 0:n.formItems)==null||a.forEach(async r=>{var l,i,s,d;if((l=r==null?void 0:r.options)!=null&&l.items){if(r.api){let h=await r.api(this.$http);r.options.items=h||[]}(i=r==null?void 0:r.options)!=null&&i.name?this.$store.state[`lwFlow_${this.type}`][`${r.name}.${r.options.name}`]=((s=r==null?void 0:r.options)==null?void 0:s.items)||"":this.$store.state[`lwFlow_${this.type}`][r.name]=((d=r==null?void 0:r.options)==null?void 0:d.items)||""}}),n!=null&&n.formItems&&(t.formItems=n.formItems),t}},methods:{async getBehaviorList(){const t={fields:"name,modelId,status"};t.expression="status in ENABLED";let n=await this.$http.get("/api/ma-manage/{tenantId}/{buCode}/behavior-event/list",t);n=n.map(o=>({value:o.id,label:o.name,...o})),this.$store.state.lwFlow_event_receive.behaviorId=n,this.behaviorIdOptions=n},onChangeBehavior(t){const n=this.behaviorIdOptions.find(o=>o.value===t);n&&(this.dataForm.behaviorModelId=n.modelId,this.dataForm.eventName=n.name,this.dataForm.uniqueField="",this.findBehaviorModel(n.modelId))},async findBehaviorModel(t){let n=await this.$http.get(`/api/ma-manage/{tenantId}/{buCode}/behavior-model/${t}`);this.$store.state.lwFlow_event_receive.uniqueField=[],this.dataModelFields=this.formatFields(n.fields)},formatFields(t,n){const o=[];return Array.isArray(t)&&t.forEach(a=>{const r=JSON.parse(JSON.stringify(a));n?r.path=`${n.path}.${a.name}`:r.path=a.name,a.aliasName?r.label=`「${a.aliasName}」${a.name}`:r.label=`${a.name}`,a.fields&&a.fields.length>0&&(r.fields=this.formatFields(a.fields,r)),this.$store.state.lwFlow_event_receive.uniqueField.push(r),o.push(r)}),o}},mounted(){var t;this.getBehaviorList(),(t=this.dataForm)!=null&&t.behaviorModelId&&this.findBehaviorModel(this.dataForm.behaviorModelId)}};function lx(t,n,o,a,r,l){const i=e.resolveComponent("el-option"),s=e.resolveComponent("el-select"),d=e.resolveComponent("el-switch"),h=e.resolveComponent("el-tree-select"),f=e.resolveComponent("lw-form-mini");return e.openBlock(),e.createBlock(f,{ref:"dataFormRef",config:l.config,modelValue:r.dataForm,"onUpdate:modelValue":n[3]||(n[3]=p=>r.dataForm=p)},{behaviorIdSelect:e.withCtx(()=>[e.createVNode(s,{modelValue:r.dataForm.behaviorId,"onUpdate:modelValue":n[0]||(n[0]=p=>r.dataForm.behaviorId=p),filterable:"",onChange:l.onChangeBehavior,placeholder:"请选择"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.behaviorIdOptions,p=>(e.openBlock(),e.createBlock(i,{key:p.value,label:p.label,value:p.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue","onChange"])]),uniqueField:e.withCtx(()=>[e.createVNode(d,{modelValue:r.dataForm.unique,"onUpdate:modelValue":n[1]||(n[1]=p=>r.dataForm.unique=p),type:"round"},null,8,["modelValue"]),r.dataForm.unique?(e.openBlock(),e.createBlock(h,{key:0,modelValue:r.dataForm.uniqueField,"onUpdate:modelValue":n[2]||(n[2]=p=>r.dataForm.uniqueField=p),filterable:"","default-expand-all":"",data:r.dataModelFields,"check-strictly":!0,props:{label:"label",value:"path",children:"fields"},placeholder:"请选择字段"},null,8,["modelValue","data"])):e.createCommentVNode("",!0)]),default:e.withCtx(()=>[n[4]||(n[4]=e.createElementVNode("span",null,null,-1))]),_:1},8,["config","modelValue"])}const ix=le(ax,[["render",lx]]),sx={name:"basicSettings",data(){return{dataForm:{},...Ke,communicates:[],content:""}},props:{modelValue:{type:Object,default:()=>({})},lf:{type:Object,default:()=>{}},type:{type:String,default:""}},watch:{modelValue:{handler(t){t&&(this.dataForm=t)},immediate:!0,deep:!0},dataForm:{handler(t,n){Object.keys(n).length>0&&this.$emit("update:modelValue",t)},deep:!0}},computed:{config(){var o,a;let t={labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24}]},n=((o=Ke[this.type])==null?void 0:o.formConfig)||{};return n!=null&&n.labelWidth&&(t.labelWidth=n.labelWidth),n!=null&&n.labelPosition&&(t.labelPosition=n.labelPosition),this.$store.state[`lwFlow_${this.type}`]||(this.$store.state[`lwFlow_${this.type}`]={}),(a=n==null?void 0:n.formItems)==null||a.forEach(async r=>{var l,i,s,d;if((l=r==null?void 0:r.options)!=null&&l.items){if(r.api){let h=await r.api(this.$http);r.options.items=h||[]}(i=r==null?void 0:r.options)!=null&&i.name?this.$store.state[`lwFlow_${this.type}`][`${r.name}.${r.options.name}`]=((s=r==null?void 0:r.options)==null?void 0:s.items)||"":this.$store.state[`lwFlow_${this.type}`][r.name]=((d=r==null?void 0:r.options)==null?void 0:d.items)||""}}),n!=null&&n.formItems&&(t.formItems=n.formItems),t}},methods:{async getCommunicate(){const t={fields:"name,budgetSetting",expression:""};t.expression="type eq sms AND status eq ENABLED";let n=await this.$http.get("/api/ma-manage/{tenantId}/{buCode}/communicate/list",t);n=n.map(o=>({value:o.id,label:o.name})),this.$store.state.lwFlow_sms.capabilityId=n,this.communicates=n},async showContent(t){if(t){const n=await this.$http.get(`/api/ma-manage/{tenantId}/{buCode}/communicate/${t}`);this.content=n.setting.template,this.dataForm.budgetSetting.budgetValue=n.budget}}},mounted(){this.getCommunicate(),this.dataForm.capabilityId&&this.showContent(this.dataForm.capabilityId)}},cx={class:"sms-content"};function dx(t,n,o,a,r,l){const i=e.resolveComponent("el-option"),s=e.resolveComponent("el-select"),d=e.resolveComponent("lw-form-mini");return e.openBlock(),e.createBlock(d,{ref:"dataFormRef",config:l.config,modelValue:r.dataForm,"onUpdate:modelValue":n[1]||(n[1]=h=>r.dataForm=h)},{capabilityIdSelect:e.withCtx(()=>[e.createVNode(s,{modelValue:r.dataForm.capabilityId,"onUpdate:modelValue":n[0]||(n[0]=h=>r.dataForm.capabilityId=h),filterable:"","allow-create":"",onChange:l.showContent,placeholder:"请选择"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.communicates,h=>(e.openBlock(),e.createBlock(i,{key:h.value,label:h.label,value:h.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue","onChange"])]),content:e.withCtx(()=>[e.createElementVNode("span",cx,e.toDisplayString(r.content),1)]),default:e.withCtx(()=>[n[2]||(n[2]=e.createElementVNode("span",null,null,-1))]),_:1},8,["config","modelValue"])}const ux=le(sx,[["render",dx],["__scopeId","data-v-e4c7ee6f"]]),hx={name:"basicSettings",data(){return{dataForm:{},...Ke}},props:{modelValue:{type:Object,default:()=>({})},lf:{type:Object,default:()=>{}},type:{type:String,default:""}},watch:{modelValue:{handler(t){t&&(this.dataForm=t)},immediate:!0,deep:!0},dataForm:{handler(t,n){Object.keys(n).length>0&&this.$emit("update:modelValue",t)},deep:!0}},computed:{config(){var o,a;let t={labelWidth:"70px",labelPosition:"top",formItems:[{label:"节点名称",name:"name",value:"",component:"input",options:{placeholder:"请输入节点名称"},span:24}]},n=((o=Ke[this.type])==null?void 0:o.formConfig)||{};return n=JSON.parse(JSON.stringify(n)),n!=null&&n.labelWidth&&(t.labelWidth=n.labelWidth),n!=null&&n.labelPosition&&(t.labelPosition=n.labelPosition),this.$store.state[`lwFlow_${this.type}`]||(this.$store.state[`lwFlow_${this.type}`]={}),(a=n==null?void 0:n.formItems)==null||a.forEach(async r=>{var l,i,s,d;if((l=r==null?void 0:r.options)!=null&&l.items){if(r.api){let h=await r.api(this.$http);r.options.items=h||[]}(i=r==null?void 0:r.options)!=null&&i.name?this.$store.state[`lwFlow_${this.type}`][`${r.name}.${r.options.name}`]=((s=r==null?void 0:r.options)==null?void 0:s.items)||"":this.$store.state[`lwFlow_${this.type}`][r.name]=((d=r==null?void 0:r.options)==null?void 0:d.items)||""}}),n!=null&&n.formItems&&(t.formItems=n.formItems),t}},methods:{}};function fx(t,n,o,a,r,l){const i=e.resolveComponent("lwCronSelect"),s=e.resolveComponent("lwTableForm"),d=e.resolveComponent("el-input"),h=e.resolveComponent("el-select"),f=e.resolveComponent("lw-form-mini");return e.openBlock(),e.createBlock(f,{ref:"dataFormRef",config:l.config,modelValue:r.dataForm,"onUpdate:modelValue":n[3]||(n[3]=p=>r.dataForm=p)},{dateCron:e.withCtx(()=>[e.createVNode(i,{modelValue:r.dataForm.cron,"onUpdate:modelValue":n[0]||(n[0]=p=>r.dataForm.cron=p)},null,8,["modelValue"])]),KeyableSource:e.withCtx(()=>[e.createVNode(s,{config:t.base.configKeyableSource,modelValue:r.dataForm.from,"onUpdate:modelValue":n[1]||(n[1]=p=>r.dataForm.from=p)},null,8,["config","modelValue"])]),MapAction:e.withCtx(()=>[e.createVNode(s,{config:t.base.configMapAction,modelValue:r.dataForm.with,"onUpdate:modelValue":n[2]||(n[2]=p=>r.dataForm.with=p)},{sourceField:e.withCtx(({row:p})=>[p.type=="direct"?(e.openBlock(),e.createBlock(d,{key:0,size:"small",modelValue:p.from,"onUpdate:modelValue":_=>p.from=_,placeholder:"来源字段"},null,8,["modelValue","onUpdate:modelValue"])):(e.openBlock(),e.createBlock(h,{key:1,modelValue:p.from,"onUpdate:modelValue":_=>p.from=_,multiple:"",filterable:"","allow-create":"",size:"small","default-first-option":"","reserve-keyword":!1,placeholder:"来源字段",style:{width:"100%"}},null,8,["modelValue","onUpdate:modelValue"]))]),_:1},8,["config","modelValue"])]),default:e.withCtx(()=>[n[4]||(n[4]=e.createElementVNode("span",null,null,-1))]),_:1},8,["config","modelValue"])}const px=le(hx,[["render",fx]]),mx={name:"styleSettings",data(){return{dataForm:{}}},props:{modelValue:{type:Object,default:()=>({})},lf:{type:Object,default:()=>{}},id:{type:String,default:""}},watch:{modelValue:{handler(t){this.dataForm=t},deep:!0},dataForm:{handler(t){this.id&&this.lf.setProperties(this.id,{style:t}),this.$emit("update:modelValue",t)},deep:!0}},computed:{config(){return{labelWidth:"70px",labelPosition:"right",size:"medium",formItems:[{label:"背景色",name:"backgroundColor",value:"",component:"color",span:12},{label:"线条样式",name:"borderStyle",value:"",component:"select",options:{placeholder:"请选择",items:[{label:"实线 ─────────────",value:"solid"},{label:"虚线 ---------------------",value:"dashed"},{label:"点线 ·······································",value:"dotted"}]},span:24},{label:"线条颜色",name:"borderColor",value:"",component:"color",span:8},{label:"线条宽度",name:"borderWidth",value:2,component:"number",options:{placeholder:"请选择",min:1},span:16},{label:"文字颜色",name:"fontColor",value:"",component:"color",span:8},{label:"文本大小",name:"fontSize",value:"",component:"number",options:{placeholder:"请选择",min:12,suffix:"px"},span:16},{label:"字体",name:"fontFamily",value:"",component:"select",options:{placeholder:"请选择",items:[{label:"微软雅黑",value:"Microsoft YaHei"},{label:"宋体",value:"SimSun"},{label:"黑体",value:"SimHei"},{label:"楷体",value:"KaiTi"},{label:"隶书",value:"LiSu"},{label:"幼圆",value:"YouYuan"}]},span:24},{label:"行高",name:"lineHeight",value:1,component:"number",options:{placeholder:"请选择",min:1,step:.1},span:16},{label:"对齐",name:"textAlign",value:"",component:"select",options:{placeholder:"请选择",items:[{label:"左对齐",value:"left"},{label:"居中",value:"center"},{label:"右对齐",value:"right"}]},span:24},{label:"文本样式",component:"fontStyle",span:24}]}}},methods:{changeFontWeight(){this.dataForm.fontWeight=this.dataForm.fontWeight==="bold"?"normal":"bold"},changeTextDecoration(){this.dataForm.textDecoration=this.dataForm.textDecoration==="underline"?"none":"underline"},changeFontStyle(){this.dataForm.fontStyle=this.dataForm.fontStyle==="italic"?"normal":"italic"}}};function gx(t,n,o,a,r,l){const i=e.resolveComponent("el-button"),s=e.resolveComponent("lw-form-mini");return e.openBlock(),e.createBlock(s,{ref:"dataFormRef",config:l.config,modelValue:r.dataForm,"onUpdate:modelValue":n[0]||(n[0]=d=>r.dataForm=d)},{fontStyle:e.withCtx(()=>[e.createVNode(i,{size:"small",type:r.dataForm.fontWeight==="bold"?"primary":"",onClick:l.changeFontWeight},{default:e.withCtx(()=>n[1]||(n[1]=[e.createTextVNode("B")])),_:1},8,["type","onClick"]),e.createVNode(i,{size:"small",type:r.dataForm.textDecoration==="underline"?"primary":"",onClick:l.changeTextDecoration},{default:e.withCtx(()=>n[2]||(n[2]=[e.createTextVNode("U")])),_:1},8,["type","onClick"]),e.createVNode(i,{size:"small",type:r.dataForm.fontStyle==="italic"?"primary":"",onClick:l.changeFontStyle},{default:e.withCtx(()=>n[3]||(n[3]=[e.createTextVNode("I")])),_:1},8,["type","onClick"])]),default:e.withCtx(()=>[n[4]||(n[4]=e.createElementVNode("span",null,null,-1))]),_:1},8,["config","modelValue"])}const bx={name:"drawerForm",components:{audienceReceive:rx,eventReceive:ix,sms:ux,basicSettings:px,styleSettings:le(mx,[["render",gx]])},props:{nodeData:{type:Object,default:()=>{}},lf:{type:Object,default:()=>{}},drawerShow:{type:Boolean,default:!1}},watch:{drawerShow:{handler(t){t&&(this.dataForm={...this.dataForm,...this.nodeData}),this.isShow=t},immediate:!0}},data(){return{activeName:"basicInfo",dataForm:{text:{value:""},properties:{data:{},style:{}}},isShow:!1}},methods:{async onSubmit(){await this.$refs.dataFormRef.$refs.dataFormRef.validate();const{id:t}=this.dataForm;this.lf.setProperties(t,{...this.dataForm.properties}),this.close()},close(){this.isShow=!1,this.$nextTick(()=>{this.$emit("onClose")})}}},yx={key:0,class:"drawer-form"};function _x(t,n,o,a,r,l){const i=e.resolveComponent("audienceReceive"),s=e.resolveComponent("eventReceive"),d=e.resolveComponent("sms"),h=e.resolveComponent("basicSettings"),f=e.resolveComponent("el-collapse-item"),p=e.resolveComponent("el-alert"),_=e.resolveComponent("styleSettings"),C=e.resolveComponent("el-collapse"),k=e.resolveComponent("el-button"),B=e.resolveComponent("el-drawer");return e.openBlock(),e.createBlock(B,{modelValue:r.isShow,"onUpdate:modelValue":n[6]||(n[6]=N=>r.isShow=N),title:"节点编辑",direction:"rtl","append-to-body":!0,size:600,"before-close":l.close},{footer:e.withCtx(()=>[e.createVNode(k,{onClick:l.close},{default:e.withCtx(()=>n[7]||(n[7]=[e.createTextVNode("取 消")])),_:1},8,["onClick"]),e.createVNode(k,{type:"primary",onClick:l.onSubmit},{default:e.withCtx(()=>n[8]||(n[8]=[e.createTextVNode("保存")])),_:1},8,["onClick"])]),default:e.withCtx(()=>[r.isShow?(e.openBlock(),e.createElementBlock("div",yx,[e.createVNode(C,{modelValue:r.activeName,"onUpdate:modelValue":n[5]||(n[5]=N=>r.activeName=N),accordion:""},{default:e.withCtx(()=>[e.createVNode(f,{title:"基础信息",name:"basicInfo"},{default:e.withCtx(()=>[["audience_receive"].includes(o.nodeData.type)?(e.openBlock(),e.createBlock(i,{key:0,ref:"dataFormRef",modelValue:r.dataForm.properties.data,"onUpdate:modelValue":n[0]||(n[0]=N=>r.dataForm.properties.data=N),type:o.nodeData.type,lf:o.lf},null,8,["modelValue","type","lf"])):e.createCommentVNode("",!0),["event_receive"].includes(o.nodeData.type)?(e.openBlock(),e.createBlock(s,{key:1,ref:"dataFormRef",modelValue:r.dataForm.properties.data,"onUpdate:modelValue":n[1]||(n[1]=N=>r.dataForm.properties.data=N),type:o.nodeData.type,lf:o.lf},null,8,["modelValue","type","lf"])):e.createCommentVNode("",!0),["sms"].includes(o.nodeData.type)?(e.openBlock(),e.createBlock(d,{key:2,ref:"dataFormRef",modelValue:r.dataForm.properties.data,"onUpdate:modelValue":n[2]||(n[2]=N=>r.dataForm.properties.data=N),type:o.nodeData.type,lf:o.lf},null,8,["modelValue","type","lf"])):(e.openBlock(),e.createBlock(h,{key:3,ref:"dataFormRef",modelValue:r.dataForm.properties.data,"onUpdate:modelValue":n[3]||(n[3]=N=>r.dataForm.properties.data=N),type:o.nodeData.type,lf:o.lf},null,8,["modelValue","type","lf"]))]),_:1}),e.createVNode(f,{title:"样式设置",name:"styleSettings"},{default:e.withCtx(()=>[e.createVNode(p,{title:"基础属性修改就会同步显示,不需要点击保存",type:"success",style:{"margin-bottom":"10px"}}),e.createVNode(_,{modelValue:r.dataForm.properties.style,"onUpdate:modelValue":n[4]||(n[4]=N=>r.dataForm.properties.style=N),lf:o.lf,id:r.dataForm.id},null,8,["modelValue","lf","id"])]),_:1})]),_:1},8,["modelValue"])])):e.createCommentVNode("",!0)]),_:1},8,["modelValue","before-close"])}const kx=le(bx,[["render",_x],["__scopeId","data-v-8a4ae6c2"]]),Lp=[{title:"ET2L节点",list:[{name:"SOURCE",icon:"icon-table",type:"source",themeColor:"#00B050"},{name:"MAPPER",icon:"icon-change-type",type:"mapper",themeColor:"#56C4C3"},{name:"JOINER",icon:"icon-app-cdp",type:"joiner",themeColor:"#7030A0"},{name:"TARGET",icon:"icon-table",type:"target",themeColor:"#0070C0"},{name:"FILTER",icon:"icon-ma-filter",type:"filter",themeColor:"#C7161E"},{name:"COLAP",icon:"icon-ma-branch",type:"collap",themeColor:"#013E75"},{name:"EXPAND",icon:"icon-chaji",type:"expand",themeColor:"#156858"},{name:"REDUCE",icon:"icon-reload",type:"reduce",themeColor:"#EF5612"}]},{title:"营销目标",list:[{name:"事件",icon:"icon-event",type:"event_receive",themeColor:"#39bcc5",background:"#f2fcfa"},{name:"人群包",icon:"icon-user-info",type:"audience_receive",themeColor:"#39BCC5",background:"#f2fcfa"}]},{title:"营销触达",list:[{name:"短信",icon:"icon-auto-reply",type:"sms",themeColor:"#4594f3",background:"#f5faff"},{name:"微信",icon:"icon-scrm-l",type:"wechat",themeColor:"#4594f3",background:"#f5faff"},{name:"邮件",icon:"icon-mail-l",type:"email",themeColor:"#4594f3",background:"#f5faff"},{name:"权益",icon:"icon-license",type:"benefit",themeColor:"#4594f3",background:"#f5faff"},{name:"积分",icon:"icon-coin",type:"benefit",themeColor:"#4594f3",background:"#f5faff"},{name:"优惠券",icon:"icon--coupon-2",type:"coupon",themeColor:"#4594f3",background:"#f5faff"}]},{title:"营销功能",list:[{name:"客户标签",icon:"icon-tag",type:"tag",themeColor:"#39BCC5"},{name:"Flow",icon:"icon-event",type:"flow",themeColor:"#e8ffea"},{name:"扩展数据",icon:"icon-event",type:"extend_data",themeColor:"#ff6d69"},{name:"定制功能",icon:"icon-flow-stop",type:"customization",themeColor:"#ff6d69"}]},{title:"Flow",list:[{name:"flow测试",icon:"icon-event",type:"tag",themeColor:"#39BCC5"}]},{title:"逻辑操作",list:[{name:"交集",icon:"icon-cross",type:"intersect",themeColor:"#fba980"},{name:"并集",icon:"icon-merge",type:"union",themeColor:"#fba980"},{name:"差集",icon:"icon-chaji",type:"exclusion",themeColor:"#fba980"},{name:"过滤",icon:"icon-ma-filter",type:"filter",themeColor:"#fba980"},{name:"去重",icon:"icon-quzhong",type:"unique",themeColor:"#fba980"},{name:"A/B测试",icon:"icon-ABtestshezhi",type:"abtest",themeColor:"#fba980"},{name:"排序",icon:"icon-sort-fill",type:"sort",themeColor:"#fba980"}]},{title:"流程控制",list:[{name:"开始",icon:"icon-start",type:"start",themeColor:"#39BCC5"},{name:"定时",icon:"icon-timing",type:"timer",themeColor:"#105a63"},{name:"限流",icon:"icon-timing",type:"restrict",themeColor:"#105a63"},{name:"结束",icon:"icon-flow-stop",type:"end",themeColor:"#ff6d69"}]}],wx={components:{lfControl:MC,lfNodePanel:YC,nodeEdit:kx},props:{modelValue:{type:Object,default:()=>({})},nodes:{type:Array,default:()=>[]},nodeDatas:{type:Object,default:()=>Ke},configNodesList:{type:Object,default:()=>Lp},showDefaultNode:{type:Boolean,default:!0},isView:{type:Boolean,default:!1},showNodeGroup:{type:Array,default:[]},apiNodes:{type:Array,default:[]},options:{type:Object,default:()=>({grid:{size:10,visible:!0,type:"mesh",config:{color:"#f0f0f0",thickness:.5}}})}},watch:{modelValue:{handler(t,n){!n&&!this.logicFlow&&this.init()},deep:!0}},data(){return{logicFlow:null,drawerShow:!1,clickNode:null}},computed:{nodeList(){let t=Lp,n={};return this.apiNodes.forEach(o=>{n[o.groupName]||(n[o.groupName]={title:o.groupName,list:[]}),n[o.groupName].list.push(o)}),this.showDefaultNode?t=[...t,...Object.values(n)]:t=Object.values(n),this.showNodeGroup.length>0&&(t=t.filter(o=>this.showNodeGroup.includes(o.title))),t}},mounted(){this.init()},methods:{async init(){var t;this.logicFlow=new lm({container:this.$refs.container,plugins:[zi.Menu,zi.MiniMap,vp],isSilentMode:this.isView,hoverOutline:!this.isView,nodeSelectedOutline:!this.isView,edgeSelectedOutline:!this.isView,...this.options}),this.initMenu(),await this.initNode(),this.modelValue&&((t=this.modelValue)==null?void 0:t.nodes.length)>0?this.logicFlow.render(this.modelValue):this.initNodeData(),this.bindEvent(),this.logicFlow.translateCenter()},async initNodeData(){function t(){return"xxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(i){const s=Math.random()*16|0;return(i==="x"?s:s&3|8).toString(16)})}function n(i){return{id:t(),type:i.type||"",x:0,y:0,properties:{data:i}}}function o(i,s){return{id:t(),type:"polyline",sourceNodeId:i.id,targetNodeId:s.id}}const a=[],r=[],l={};this.nodes.forEach(i=>{const s=n(i);a.push(s),l[i.into]=s}),this.nodes.forEach(i=>{let s=Array.isArray(i.from)?i.from.map(h=>h.name):[i.from];const d=i.into;s.forEach(h=>{l[h]&&l[d]&&r.push(o(l[h],l[d]))})}),this.logicFlow.renderRawData({nodes:a,edges:r}),this.logicFlow.extension.dagre.layout({nodesep:60,ranksep:140})},initMenu(){let t=this;this.logicFlow.extension.menu.setMenuConfig({nodeMenu:[{text:"删除",callback(n){t.logicFlow.deleteNode(n.id)}},{text:"编辑",callback(n){t.nodeEditOpen(n),t.$emit("edit",n)}},{text:"复制",callback:n=>{this.logicFlow.cloneNode(n.id)}}],edgeMenu:[{text:"删除",callback(n){t.logicFlow.deleteEdge(n.id)}},{text:"编辑",callback(n){t.nodeEditOpen(n),t.$emit("edit",n)}},{text:"直线",callback(n){t.logicFlow.changeEdgeType(n.id,"line")}},{text:"曲线",callback(n){t.logicFlow.changeEdgeType(n.id,"bezier")}},{text:"折线",callback(n){t.logicFlow.changeEdgeType(n.id,"polyline")}},{text:"开启动画",callback(n){t.logicFlow.openEdgeAnimation(n.id)}},{text:"关闭动画",callback(n){t.logicFlow.closeEdgeAnimation(n.id)}}],graphMenu:[]})},async initNode(){for(const t of this.nodeList)for(const n of t.list)switch(n.type){case"start":await $C(this.logicFlow);break;case"end":await WC(this.logicFlow);break;case"source":case"mapper":case"joiner":case"target":case"filter":case"collap":case"expand":case"reduce":await JC(this.logicFlow,n);break;case"event_receive":await Pp(this.logicFlow,n,this.$store.state);break;default:await Pp(this.logicFlow,n,this.$store.state);break}},getNodes(t){let n=[];return t.forEach(o=>{n.push({...o.properties.data,type:o.type})}),n},bindEvent(){this.logicFlow.on("node:dbclick",({data:t})=>{this.nodeEditOpen(t)}),this.logicFlow.on("edge:dbclick",({data:t})=>{this.nodeEditOpen(t)}),this.logicFlow.on("blank:click",()=>{this.drawerShow=!1}),this.logicFlow.on("history:change",({data:t})=>{let{undos:n}=t;this.$emit("change",n),this.$emit("update:modelValue",n[n.length-1]),this.$emit("update:nodes",this.getNodes(n[n.length-1].nodes,n[n.length-1].edges))}),this.logicFlow.on("connection:not-allowed",t=>{this.$message({type:"error",message:t.msg})}),this.changeEdge()},changeEdge(){this.logicFlow.on("edge:add",({data:t})=>{}),this.logicFlow.on("edge:delete",({data:t})=>{})},nodeEditClose(){this.drawerShow=!1},nodeEditOpen(t){delete t.properties.error,this.logicFlow.setProperties(t.id,{error:!1}),this.clickNode=t,this.drawerShow=!0},async validate(){let{nodes:t}=this.logicFlow.getGraphData(),n={};for(const o of t){let{formConfig:a}=Ke[o.type],{formItems:r}=a,{data:l}=o.properties;if((r==null?void 0:r.length)>0)for(const i of r){let s=l&&l[i==null?void 0:i.name],d=!1;if(l&&typeof(i==null?void 0:i.hideHandle)=="string")try{d=new Function("data",`return ${i.hideHandle.replace(/\$/g,"data")}`)(l)}catch(h){console.error("遇到错误时返回默认值:",h),d=!1}else l&&typeof(i==null?void 0:i.hideHandle)=="boolean"&&(d=i.hideHandle);if(!d&&(i!=null&&i.rules)&&(s==null||s===""||Array.isArray(s)&&s.length===0)){this.logicFlow.setProperties(o.id,{data:l,error:!0}),n[o.id]=!0;break}}n[o.id]||this.logicFlow.setProperties(o.id,{data:l,error:!1})}return Object.keys(n).length===0}}},Vx={class:"logic-flow"},Cx={ref:"container",class:"logic-flow-body"};function xx(t,n,o,a,r,l){const i=e.resolveComponent("lfControl"),s=e.resolveComponent("lfNodePanel"),d=e.resolveComponent("nodeEdit");return e.openBlock(),e.createElementBlock("div",Vx,[e.createElementVNode("div",Cx,null,512),r.logicFlow?(e.openBlock(),e.createBlock(i,{key:0,class:"logic-flow-control",lf:r.logicFlow},null,8,["lf"])):e.createCommentVNode("",!0),o.isView?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[r.logicFlow?(e.openBlock(),e.createBlock(s,{key:0,class:"logic-flow-node",lf:r.logicFlow,nodeList:l.nodeList},null,8,["lf","nodeList"])):e.createCommentVNode("",!0),e.createVNode(d,{lf:r.logicFlow,drawerShow:r.drawerShow,nodeData:r.clickNode,onOnClose:l.nodeEditClose},null,8,["lf","drawerShow","nodeData","onOnClose"])],64))])}const Mp=le(wx,[["render",xx],["__scopeId","data-v-d788418a"]]),Nx={loginPage:{accountLoginNologo:"Marketing Cloud",accountLogin:"Lianwei Marketing Cloud",rememberMe:"Keep me logged in",forgetPassword:"Forgot password",signIn:"Account verification",userPlaceholder:"Username / Mobile / Email",userError:"Please enter your username",PWPlaceholder:"Please enter your password",PWError:"Please enter your password",mobileError:"Please enter your mobile number",trialRequest:"Request a trial",enterTitle:"Please enter your title",enterPhone:"Please enter your phone number",correctPhone:"Please enter a valid phone number format",enterCompany:"Please enter your company name",selectPosition:"Please select your position",selectPurpose:"Please select your purpose",noAccount:"Don’t have an account?",applySuccess:"You have applied for a trial, please check your SMS for a prompt.",loginSuccess:"Login successful"},positions:{techStaff:"Technical staff",businessStaff:"Business staff",researchStaff:"Research and development staff",marketingStaff:"Marketing staff",operationStaff:"Operations staff",otherStaff:"Other professional staff"},purposes:{findSolution:"Looking for suitable products to solve data, marketing, and other issues",compareProducts:"Comparing other products, want to learn more",other:"Other"}},Bx={loginPage:{accountLoginNologo:"营销云",accountLogin:"联蔚营销云",rememberMe:"保持登录状态",forgetPassword:"忘记密码",signIn:"账号验证",userPlaceholder:"用户名 / 手机 / 邮箱",userError:"请输入用户名",PWPlaceholder:"请输入密码",PWError:"请输入密码",mobileError:"请输入手机号码",trialRequest:"申请试用",enterTitle:"请输入您的称谓",enterPhone:"请输入手机号",correctPhone:"请输入正确的手机号格式",enterCompany:"请输入您的公司名称",selectPosition:"请选择您的职位",selectPurpose:"请选择您的用途",noAccount:"还没有账号 ?",applySuccess:"您已申请试用,请注意查收短信提示。",loginSuccess:"登录成功"},positions:{techStaff:"技术人员",businessStaff:"业务人员",researchStaff:"研发人员",marketingStaff:"市场人员",operationStaff:"运营人员",otherStaff:"其他专业人员"},purposes:{findSolution:"寻找合适的产品来解决数据,营销等问题",compareProducts:"正在对比其他产品,想了解",other:"其他"}},Sx={lwSearch:{please_select:"Please select",please_input:"Please input",dateRange:{startPlaceholder:"Start Time",endPlaceholder:"End Time"},monthRange:{rangeSeparator:"To",startPlaceholder:"Start Month",endPlaceholder:"End Month"}}},Ex={lwSearch:{please_select:"请选择",please_input:"请输入",dateRange:{startPlaceholder:"开始时间",endPlaceholder:"结束时间"},monthRange:{rangeSeparator:"至",startPlaceholder:"开始月",endPlaceholder:"结束月"}}},Tx={lwTable:{tools:{lineHeightName:"row height",lineHeight:{mini:"Compact",small:"Medium",medium:"High",large:"Extra High"},border:"Border",columnsSetting:"Column Settings",allCheck:"Select All",hasChecked:"Selected",cancel:"Cancel",fullScreen:"Full Screen",table_before:"Before the table",column_fixed:"Column fixed",last_column_fixed:"Last column fixed",please_select:"Please select...",total:"total",recordsPage:"records Page",pages:"pages"}}},Ix={lwTable:{tools:{lineHeightName:"行高",lineHeight:{mini:"紧凑",small:"中等",medium:"高",large:"较高"},border:"边框",columnsSetting:"列设置",allCheck:"全选",hasChecked:"已选",cancel:"取消",fullScreen:"全屏",table_before:"表格前",column_fixed:"列固定",last_column_fixed:"最后一列固定",please_select:"请选择...",total:"共",recordsPage:"条记录 第",pages:"页"}}};let Dx=localStorage.getItem("langMessageUi"),Kt={...JSON.parse(Dx)||{}};Kt["en-us"]={...Nx,...Sx,...Tx},Kt["zh-cn"]={...Bx,...Ex,...Ix},localStorage.setItem("langMessageUi",JSON.stringify(Kt));function Fx(t,n={}){if(n)for(const o in n)n.hasOwnProperty(o)&&(t.config.globalProperties[`$${o.toUpperCase()}`]=n[o]);t.directive("copy",im),t.directive("auth",sm),t.component("lwLayout",Yi),t.component("lwLogin",Ji),t.component("lwSearch",Zi),t.component("lwSvgIcon",Xi),t.component("lwTable",Qi),t.component("lwForm",es),t.component("lwFormMini",ns),t.component("lwUpload",St),t.component("lwIconSelect",os),t.component("lwTableSelect",rs),t.component("lwTableForm",as),t.component("lwFormView",is),t.component("lwFormJson",ls),t.component("lwCronSelect",ss),t.component("lwFlow",Mp)}const qx={install:Fx,uiI18n:Kt};he.default=qx,he.lwCronSelect=ss,he.lwFlow=Mp,he.lwForm=es,he.lwFormJson=ls,he.lwFormMini=ns,he.lwFormView=is,he.lwIconSelect=os,he.lwLayout=Yi,he.lwLogin=Ji,he.lwSearch=Zi,he.lwSvgIcon=Xi,he.lwTable=Qi,he.lwTableForm=as,he.lwTableSelect=rs,he.lwUpload=St,he.uiI18n=Kt,Object.defineProperties(he,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});