import{defineComponent as p,ref as i,watch as c,onActivated as m,onBeforeUnmount as s,createVNode as d}from"vue";import r from"../_util/raf.mjs";import v from"../tooltip/index.mjs";import{tooltipProps as g}from"../tooltip/Tooltip.mjs";const w=p({compatConfig:{MODE:3},name:"SliderTooltip",inheritAttrs:!1,props:g(),setup(e,{attrs:a,slots:f}){const t=i(null),o=i(null);function n(){r.cancel(o.value),o.value=null}function u(){o.value=r(()=>{t.value?.forcePopupAlign(),o.value=null})}const l=()=>{n(),e.open&&u()};return c([()=>e.open,()=>e.title],()=>{l()},{flush:"post",immediate:!0}),m(()=>{l()}),s(()=>{n()}),()=>d(v,{ref:t,...e,...a},f)}});export{w as default};
