index-d3a70a7f.js 1.2 KB

1
  1. import{d as s,x as i,w as g,a,b4 as c}from"./index-5e5e4ebc.js";const u="_dialogTitle_1fhba_1",f="_oDialog_1fhba_18",l={dialogTitle:u,oDialog:f},w=s({name:"o-dialog",props:{show:{type:Boolean,default:!1},message:{type:String,default:""},title:{type:String,default:"提示"},confirmButtonText:{type:String,default:"确认"},cancelButtonText:{type:String,default:"取消"},showConfirmButton:{type:Boolean,default:!0},showCancelButton:{type:Boolean,default:!1},messageAlign:{type:String,default:"center"},dialogMarginTop:{type:String,default:"0px"},allowHtml:{type:Boolean,default:!1}},emits:["cancel","confirm","update:show"],setup(t,{emit:e}){const o=i({show:t.show||!1});return g(()=>t.show,()=>{o.show=t.show}),()=>a(c,{class:l.oDialog,style:{marginTop:t.dialogMarginTop},show:o.show,"onUpdate:show":n=>o.show=n,message:t.message,messageAlign:t.messageAlign,allowHtml:t.allowHtml,confirmButtonText:t.confirmButtonText,cancelButtonText:t.cancelButtonText,showConfirmButton:t.showConfirmButton,showCancelButton:t.showCancelButton,onConfirm:()=>{e("update:show",!1),e("confirm")},onCancel:()=>{e("update:show",!1),e("cancel")}},{title:()=>a("div",{class:l.dialogTitle},[a("i",null,null),t.title])})}});export{w as O};