"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const i=require("vue"),s=require("../canUseDom.js"),f=require("../getScrollBarSize.js"),t=require("../../vc-util/Dom/dynamicCSS.js"),a=`vc-util-locker-${Date.now()}`;let n=0;function r(){return document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight)&&window.innerWidth>document.body.offsetWidth}function S(o){const c=i.computed(()=>!!o&&!!o.value);n+=1;const e=`${a}_${n}`;i.watchEffect(u=>{if(s.default()){if(c.value){const l=f.default(),d=r();t.updateCSS(`
html body {
  overflow-y: hidden;
  ${d?`width: calc(100% - ${l}px);`:""}
}`,e)}else t.removeCSS(e);u(()=>{t.removeCSS(e)})}},{flush:"post"})}exports.default=S;exports.isBodyOverflowing=r;
