qidian-shared 1.0.30 → 1.0.32

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -8053,6 +8053,9 @@ function isTypeByName(name, suffixs) {
8053
8053
  if (!name) return false;
8054
8054
  return suffixs.some((suffix) => `.${cutFileSuffix(name)}`.toLowerCase() === suffix.toLowerCase());
8055
8055
  }
8056
+ function b2mb(size = 0) {
8057
+ return size / 1024 / 1024;
8058
+ }
8056
8059
  var BI_RM = "0123456789abcdefghijklmnopqrstuvwxyz";
8057
8060
  function int2char(n) {
8058
8061
  return BI_RM.charAt(n);
@@ -12670,7 +12673,7 @@ function initialConversion(str, isLowerCase) {
12670
12673
  }
12671
12674
  }
12672
12675
  function camelize(str) {
12673
- return str.replace(/-(\w)/g, (_, c) => {
12676
+ return str.replace(/-|_(\w)/g, (_, c) => {
12674
12677
  return c ? c.toUpperCase() : "";
12675
12678
  });
12676
12679
  }
@@ -13129,6 +13132,7 @@ function useTimer(type = "timeout") {
13129
13132
  };
13130
13133
  }
13131
13134
  exports.MD5 = MD5;
13135
+ exports.b2mb = b2mb;
13132
13136
  exports.buildTree = buildTree;
13133
13137
  exports.camelize = camelize;
13134
13138
  exports.checkSameObject = checkSameObject;