var e=e=>{let n=`data-block-touch-pan`,r=`scrollbar-visible`;t(e)?(e.removeAttribute(n),e.classList.add(r)):(e.setAttribute(n,`true`),e.classList.remove(r))},t=e=>e.scrollHeight>e.clientHeight&&getComputedStyle(e).overflowY!==`hidden`,n=t=>{e(t);let n=new ResizeObserver(()=>e(t));n.observe(t);let r,i=new MutationObserver(()=>{r===void 0&&(e(t),r=setTimeout(()=>{r=void 0,e(t)},500))});return i.observe(t,{childList:!0,subtree:!0}),{update(){e(t)},destroy(){clearTimeout(r),n.disconnect(),i.disconnect()}}};export{n as t};