import{_ as e,m as l,f as o,x as a,h as t,e as n,c as d,g as s,w as i,b as u,n as c,j as r,t as f,a1 as p,q as h,i as m,P as g}from"./index-vtcwYVzc.js";const v=l({props:{modelValue:!1,lazy:{type:Boolean,default:!1},icon:{type:String,default:"el-icon-warning-outline"},title:{type:String,default:"基本信息"},height:{type:Number,default:200},width:{type:Number,default:650},padding:{type:Number,default:16},modal:{type:Boolean,default:!0},draggable:{type:Boolean,default:!1},mask:{type:Boolean,default:!0},onModelClose:{type:Function,default:e=>!0},footer:{type:Boolean,default:!0}},setup(e,l){const t=.95*document.body.clientHeight-60,n=o(!0),d=o(!1),s=o(!1),i=o(100);d.value=e.modelValue,s.value=!!l.slots.footer;const u=o(200);u.value=e.height;const c=e=>(u.value=t-30,t/-2+"px");i.value=c(),a((()=>e.modelValue),((e,l)=>{d.value=e})),a((()=>e.height),((e,l)=>{i.value=c()}));const r=o(!1);return{handleClose:(o,a)=>{!1!==e.onModelClose(!!a)&&(d.value=!1,l.emit("update:modelValue",!1),o&&o())},inited:n,vmodel:d,footer:s,top:i,calcHeight:c,contentHeight:u,fullscreen:r,handleFullScreen:()=>{r.value=!r.value,l.emit("fullscreen",r.value)}}}}),y={class:"vol-dialog"},b={key:0,class:"dia-footer"};const x=e(v,[["render",function(e,l,o,a,v,x){const _=t("el-scrollbar"),k=t("el-button"),C=t("el-dialog");return n(),d("div",y,[s(C,{modelValue:e.vmodel,"onUpdate:modelValue":l[2]||(l[2]=l=>e.vmodel=l),"close-on-click-modal":!1,"close-on-press-escape":!1,width:e.width,fullscreen:e.fullscreen,draggable:e.draggable,modal:e.modal,"before-close":e.handleClose},{header:i((()=>[u("i",{class:c(e.icon)},null,2),r(" "+f(e.title)+" ",1),u("button",{class:"el-dialog__headerbtn",type:"button",style:{right:"35px",color:"var(--el-color-info)"},onClick:l[0]||(l[0]=(...l)=>e.handleFullScreen&&e.handleFullScreen(...l))},l[3]||(l[3]=[u("i",{class:"el-icon el-icon-full-screen"},null,-1)]))])),footer:i((()=>[e.footer?(n(),d("div",b,[p(e.$slots,"footer",{},void 0,!0),e.footer?m("",!0):(n(),h(k,{key:0,type:"primary",size:"mini",onClick:l[1]||(l[1]=l=>e.handleClose())},{default:i((()=>l[4]||(l[4]=[u("i",{class:"el-icon-close"},null,-1),r("关闭")]))),_:1}))])):m("",!0)])),default:i((()=>[s(_,{"max-height":e.contentHeight},{default:i((()=>[e.inited?(n(),d("div",{key:0,style:g([{"min-height":"50px"},{padding:e.padding+"px"}]),class:"srcoll-content"},[p(e.$slots,"content",{},void 0,!0),p(e.$slots,"default",{},void 0,!0)],4)):m("",!0)])),_:3},8,["max-height"])])),_:3},8,["modelValue","width","fullscreen","draggable","modal","before-close"])])}],["__scopeId","data-v-5ebdfe54"]]);export{x as default};
