import{g as x}from"./vendor-ClLR6ncd.js";var n={exports:{}};/*!
 * bytes
 * Copyright(c) 2012-2014 TJ Holowaychuk
 * Copyright(c) 2015 Jed Watson
 * MIT Licensed
 */n.exports=B;n.exports.format=b;n.exports.parse=o;var g=/\B(?=(\d{3})+(?!\d))/g,v=/(?:\.0*|(\.[^0]+)0+)$/,s={b:1,kb:1024,mb:1<<20,gb:1<<30,tb:Math.pow(1024,4),pb:Math.pow(1024,5)},y=/^((-|\+)?(\d+(?:\.\d+)?)) *(kb|mb|gb|tb|pb)$/i;function B(r,e){return typeof r=="string"?o(r):typeof r=="number"?b(r,e):null}function b(r,e){if(!Number.isFinite(r))return null;var a=Math.abs(r),i=e&&e.thousandsSeparator||"",p=e&&e.unitSeparator||"",l=e&&e.decimalPlaces!==void 0?e.decimalPlaces:2,m=!!(e&&e.fixedDecimals),t=e&&e.unit||"";(!t||!s[t.toLowerCase()])&&(a>=s.pb?t="PB":a>=s.tb?t="TB":a>=s.gb?t="GB":a>=s.mb?t="MB":a>=s.kb?t="KB":t="B");var c=r/s[t.toLowerCase()],f=c.toFixed(l);return m||(f=f.replace(v,"$1")),i&&(f=f.split(".").map(function(u,d){return d===0?u.replace(g,i):u}).join(".")),f+p+t}function o(r){if(typeof r=="number"&&!isNaN(r))return r;if(typeof r!="string")return null;var e=y.exec(r),a,i="b";return e?(a=parseFloat(e[1]),i=e[4].toLowerCase()):(a=parseInt(r,10),i="b"),isNaN(a)?null:Math.floor(s[i]*a)}var h=n.exports;const E=x(h);export{E as b};
