import{V as u,f as p,m as S}from"./forwardRefs-YZME3Z-4.js";import{s as h,x,J as O,W as T,c as e,r as k,q as d,e as w,a7 as A}from"./index-BrhME0Dw.js";import{u as C}from"./scopeId-Bb-xzR7W.js";import{u as I}from"./dimensions-g-Hg75km.js";const R=x({id:String,text:String,...A(S({closeOnBack:!1,location:"end",locationStrategy:"connected",eager:!0,minWidth:0,offset:10,openOnClick:!1,openOnHover:!0,origin:"auto",scrim:!1,scrollStrategy:"reposition",transition:!1}),["absolute","persistent"])},"VTooltip"),F=h()({name:"VTooltip",props:R(),emits:{"update:modelValue":t=>!0},setup(t,m){let{slots:o}=m;const r=O(t,"modelValue"),{scopeId:v}=C(),f=T(),n=e(()=>t.id||`v-tooltip-${f}`),l=k(),g=e(()=>t.location.split(" ").length>1?t.location:t.location+" center"),V=e(()=>t.origin==="auto"||t.origin==="overlap"||t.origin.split(" ").length>1||t.location.split(" ").length>1?t.origin:t.origin+" center"),P=e(()=>t.transition?t.transition:r.value?"scale-transition":"fade-transition"),y=e(()=>d({"aria-describedby":n.value},t.activatorProps));return I(()=>{const b=u.filterProps(t);return w(u,d({ref:l,class:["v-tooltip",t.class],style:t.style,id:n.value},b,{modelValue:r.value,"onUpdate:modelValue":a=>r.value=a,transition:P.value,absolute:!0,location:g.value,origin:V.value,persistent:!0,role:"tooltip",activatorProps:y.value,_disableGlobalStack:!0},v),{activator:o.activator,default:function(){var c;for(var a=arguments.length,s=new Array(a),i=0;i<a;i++)s[i]=arguments[i];return((c=o.default)==null?void 0:c.call(o,...s))??t.text}})}),p({},l)}});export{F as V};
