Files
workspace/code/sllog/Sllog-User-Ui/dist/assets/index-BM0JB0P6.js
T
2025-06-18 16:30:01 +08:00

2 lines
2.0 KiB
JavaScript

import{_ as y,d as m,e as V,h as v,o as P,A as g,u as a,f,n as r,D as d,G as C,ae as w,g as h,i as S,b as i,y as $,z as j}from"./index-C4UKuwCQ.js";const O=m({name:"Popover",components:{Trigger:w},props:{popupVisible:{type:Boolean,default:void 0},defaultPopupVisible:{type:Boolean,default:!1},title:String,content:String,trigger:{type:[String,Array],default:"hover"},position:{type:String,default:"top"},contentClass:{type:[String,Array,Object]},contentStyle:{type:Object},arrowClass:{type:[String,Array,Object]},arrowStyle:{type:Object},popupContainer:{type:[String,Object]}},emits:{"update:popupVisible":e=>!0,popupVisibleChange:e=>!0},setup(e,{emit:o}){const t=h("popover"),s=S(e.defaultPopupVisible),u=i(()=>{var n;return(n=e.popupVisible)!=null?n:s.value}),c=n=>{s.value=n,o("update:popupVisible",n),o("popupVisibleChange",n)},p=i(()=>[`${t}-popup-content`,e.contentClass]),b=i(()=>[`${t}-popup-arrow`,e.arrowClass]);return{prefixCls:t,computedPopupVisible:u,contentCls:p,arrowCls:b,handlePopupVisibleChange:c}}});function B(e,o,t,s,u,c){const p=V("trigger");return P(),v(p,{class:r(e.prefixCls),trigger:e.trigger,position:e.position,"popup-visible":e.computedPopupVisible,"popup-offset":10,"content-class":e.contentCls,"content-style":e.contentStyle,"arrow-class":e.arrowCls,"arrow-style":e.arrowStyle,"show-arrow":"","popup-container":e.popupContainer,"animation-name":"zoom-in-fade-out","auto-fit-transform-origin":"",onPopupVisibleChange:e.handlePopupVisibleChange},{content:g(()=>[f("div",{class:r(`${e.prefixCls}-title`)},[a(e.$slots,"title",{},()=>[d(C(e.title),1)])],2),f("div",{class:r(`${e.prefixCls}-content`)},[a(e.$slots,"content",{},()=>[d(C(e.content),1)])],2)]),default:g(()=>[a(e.$slots,"default")]),_:3},8,["class","trigger","position","popup-visible","content-class","content-style","arrow-class","arrow-style","popup-container","onPopupVisibleChange"])}var l=y(O,[["render",B]]);const z=Object.assign(l,{install:(e,o)=>{$(e,o);const t=j(o);e.component(t+l.name,l)}});export{z as P};