import*as n from"react";import{styleSingleton as t}from"../../../react-style-singleton/dist/es2015/component.js";import{getGapWidth as i}from"./utils.js";import{noScrollbarsClassName as r,zeroRightClassName as o,fullWidthClassName as e,removedBarSizeVariable as a}from"./constants.js";var p=t(),g=function(n,t,i,p){var g=n.left,d=n.top,m=n.right,s=n.gap;return void 0===i&&(i="margin"),"\n  ."+r+" {\n   overflow: hidden "+p+";\n   padding-right: "+s+"px "+p+";\n  }\n  body {\n    overflow: hidden "+p+";\n    "+[t&&"position: relative "+p+";","margin"===i&&"\n    padding-left: "+g+"px;\n    padding-top: "+d+"px;\n    padding-right: "+m+"px;\n    margin-left:0;\n    margin-top:0;\n    margin-right: "+s+"px "+p+";\n    ","padding"===i&&"padding-right: "+s+"px "+p+";"].filter(Boolean).join("")+"\n  }\n  \n  ."+o+" {\n    right: "+s+"px "+p+";\n  }\n  \n  ."+e+" {\n    margin-right: "+s+"px "+p+";\n  }\n  \n  ."+o+" ."+o+" {\n    right: 0 "+p+";\n  }\n  \n  ."+e+" ."+e+" {\n    margin-right: 0 "+p+";\n  }\n  \n  body {\n    "+a+": "+s+"px;\n  }\n"},d=function(t){var r=n.useState(i(t.gapMode)),o=r[0],e=r[1];n.useEffect((function(){e(i(t.gapMode))}),[t.gapMode]);var a=t.noRelative,d=t.noImportant,m=t.gapMode,s=void 0===m?"margin":m;return n.createElement(p,{styles:g(o,!a,s,d?"":"!important")})};export{d as RemoveScrollBar};
//# sourceMappingURL=component.js.map
