sculp-js 1.8.4 → 1.9.0

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.
Files changed (63) hide show
  1. package/lib/cjs/array.js +1 -1
  2. package/lib/cjs/async.js +1 -1
  3. package/lib/cjs/base64.js +1 -1
  4. package/lib/cjs/clipboard.js +7 -11
  5. package/lib/cjs/cloneDeep.js +1 -1
  6. package/lib/cjs/cookie.js +1 -1
  7. package/lib/cjs/date.js +1 -1
  8. package/lib/cjs/dom.js +1 -1
  9. package/lib/cjs/download.js +1 -1
  10. package/lib/cjs/easing.js +1 -1
  11. package/lib/cjs/file.js +1 -1
  12. package/lib/cjs/func.js +1 -1
  13. package/lib/cjs/index.js +3 -1
  14. package/lib/cjs/isEqual.js +1 -1
  15. package/lib/cjs/math.js +1 -1
  16. package/lib/cjs/number.js +49 -12
  17. package/lib/cjs/object.js +1 -1
  18. package/lib/cjs/path.js +1 -1
  19. package/lib/cjs/qs.js +1 -1
  20. package/lib/cjs/random.js +1 -1
  21. package/lib/cjs/string.js +1 -1
  22. package/lib/cjs/tooltip.js +1 -1
  23. package/lib/cjs/tree.js +2 -2
  24. package/lib/cjs/type.js +1 -1
  25. package/lib/cjs/unique.js +1 -1
  26. package/lib/cjs/url.js +15 -5
  27. package/lib/cjs/validator.js +1 -1
  28. package/lib/cjs/variable.js +1 -1
  29. package/lib/cjs/watermark.js +1 -1
  30. package/lib/cjs/we-decode.js +1 -1
  31. package/lib/es/array.js +1 -1
  32. package/lib/es/async.js +1 -1
  33. package/lib/es/base64.js +1 -1
  34. package/lib/es/clipboard.js +7 -11
  35. package/lib/es/cloneDeep.js +1 -1
  36. package/lib/es/cookie.js +1 -1
  37. package/lib/es/date.js +1 -1
  38. package/lib/es/dom.js +1 -1
  39. package/lib/es/download.js +1 -1
  40. package/lib/es/easing.js +1 -1
  41. package/lib/es/file.js +1 -1
  42. package/lib/es/func.js +1 -1
  43. package/lib/es/index.js +2 -2
  44. package/lib/es/isEqual.js +1 -1
  45. package/lib/es/math.js +1 -1
  46. package/lib/es/number.js +48 -13
  47. package/lib/es/object.js +1 -1
  48. package/lib/es/path.js +1 -1
  49. package/lib/es/qs.js +1 -1
  50. package/lib/es/random.js +1 -1
  51. package/lib/es/string.js +1 -1
  52. package/lib/es/tooltip.js +1 -1
  53. package/lib/es/tree.js +2 -2
  54. package/lib/es/type.js +1 -1
  55. package/lib/es/unique.js +1 -1
  56. package/lib/es/url.js +15 -5
  57. package/lib/es/validator.js +1 -1
  58. package/lib/es/variable.js +1 -1
  59. package/lib/es/watermark.js +1 -1
  60. package/lib/es/we-decode.js +1 -1
  61. package/lib/index.d.ts +32 -9
  62. package/lib/umd/index.js +561 -518
  63. package/package.json +1 -1
package/lib/cjs/array.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/async.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/base64.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,32 +1,28 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
- var dom = require('./dom.js');
10
-
11
- const textEl = document.createElement('textarea');
12
- dom.setStyle(textEl, {
13
- position: 'absolute',
14
- top: '-9999px',
15
- left: '-9999px',
16
- opacity: 0
17
- });
18
- document.body.appendChild(textEl);
19
9
  /**
20
10
  * 复制文本
21
11
  * @param {string} text
22
12
  */
23
13
  function copyText(text) {
14
+ const textEl = document.createElement('textarea');
15
+ textEl.style.position = 'absolute';
16
+ textEl.style.top = '-9999px';
17
+ textEl.style.left = '-9999px';
24
18
  textEl.value = text;
19
+ document.body.appendChild(textEl);
25
20
  textEl.focus({ preventScroll: true });
26
21
  textEl.select();
27
22
  try {
28
23
  document.execCommand('copy');
29
24
  textEl.blur();
25
+ document.body.removeChild(textEl);
30
26
  }
31
27
  catch (err) {
32
28
  // ignore
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/cookie.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/date.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/dom.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/easing.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/file.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/func.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
@@ -131,7 +131,9 @@ exports.randomNumber = random.randomNumber;
131
131
  exports.randomString = random.randomString;
132
132
  exports.randomUuid = random.randomUuid;
133
133
  exports.HEX_POOL = number.HEX_POOL;
134
+ exports.formatMoney = number.formatNumber;
134
135
  exports.formatNumber = number.formatNumber;
136
+ exports.humanFileSize = number.humanFileSize;
135
137
  exports.numberAbbr = number.numberAbbr;
136
138
  exports.numberToHex = number.numberToHex;
137
139
  exports.UNIQUE_NUMBER_SAFE_LENGTH = unique.UNIQUE_NUMBER_SAFE_LENGTH;
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/math.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/number.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
@@ -8,6 +8,7 @@
8
8
 
9
9
  var func = require('./func.js');
10
10
  var string = require('./string.js');
11
+ var type = require('./type.js');
11
12
 
12
13
  const HEX_POOL = `${string.STRING_ARABIC_NUMERALS}${string.STRING_UPPERCASE_ALPHA}${string.STRING_LOWERCASE_ALPHA}`;
13
14
  const supportBigInt = typeof BigInt !== 'undefined';
@@ -45,38 +46,74 @@ function numberToHex(decimal, hexPool = HEX_POOL) {
45
46
  return ret.join('');
46
47
  }
47
48
  /**
48
- * 缩写
49
+ * 将数字转换为携带单位的字符串
49
50
  * @param {number | string} num
50
51
  * @param {Array<string>} units
51
- * @param {number} ratio
52
- * @param {number} exponent
52
+ * @param {INumberAbbr} options default: { ratio: 1000, decimals: 0, separator: ' ' }
53
53
  * @returns {string}
54
54
  */
55
- const numberAbbr = (num, units, ratio = 1000, exponent) => {
55
+ const numberAbbr = (num, units, options = { ratio: 1000, decimals: 0, separator: ' ' }) => {
56
+ const { ratio = 1000, decimals = 0, separator = ' ' } = options;
56
57
  const { length } = units;
57
58
  if (length === 0)
58
- throw new Error('至少需要一个单位');
59
+ throw new Error('At least one unit is required');
59
60
  let num2 = Number(num);
60
61
  let times = 0;
61
62
  while (num2 >= ratio && times < length - 1) {
62
63
  num2 = num2 / ratio;
63
64
  times++;
64
65
  }
65
- const value = num2.toFixed(exponent);
66
+ const value = num2.toFixed(decimals);
66
67
  const unit = units[times];
67
- return value.toString() + '' + unit;
68
+ return String(value) + separator + unit;
68
69
  };
70
+ /**
71
+ * Converting file size in bytes to human-readable string
72
+ * reference: https://zh.wikipedia.org/wiki/%E5%8D%83%E5%AD%97%E8%8A%82
73
+ * @param {number | string} num bytes Number in Bytes
74
+ * @param {IHumanFileSizeOptions} options default: { decimals = 0, si = false, separator = ' ' }
75
+ * si: True to use metric (SI) units, aka powers of 1000, the units is
76
+ * ['B', 'kB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'].
77
+ * False to use binary (IEC), aka powers of 1024, the units is
78
+ * ['Byte', 'KiB', 'MiB', 'GiB', 'TiB', 'PiB', 'EiB', 'ZiB', 'YiB']
79
+ * @returns
80
+ */
81
+ function humanFileSize(num, options) {
82
+ const { decimals = 0, si = false, separator = ' ', maxUnit } = options;
83
+ const units = si
84
+ ? ['B', 'kB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB']
85
+ : ['Byte', 'KiB', 'MiB', 'GiB', 'TiB', 'PiB', 'EiB', 'ZiB', 'YiB'];
86
+ if (!type.isNullOrUnDef(maxUnit)) {
87
+ const targetIndex = units.findIndex(el => el === maxUnit);
88
+ if (targetIndex !== -1) {
89
+ units.splice(targetIndex + 1);
90
+ }
91
+ }
92
+ return numberAbbr(num, units, { ratio: si ? 1000 : 1024, decimals, separator });
93
+ }
69
94
  /**
70
95
  * 将数字格式化成千位分隔符显示的字符串
71
- * @param {number} val 数字
72
- * @param {'int' | 'float'} type 展示分段显示的类型 int:整型 | float:浮点型
96
+ * @param {number|string} num 数字
97
+ * @param {number} decimals 格式化成指定小数位精度的参数
73
98
  * @returns {string}
74
99
  */
75
- function formatNumber(val, type = 'int') {
76
- return type === 'int' ? parseInt(String(val)).toLocaleString() : Number(val).toLocaleString('en-US');
100
+ function formatNumber(num, decimals) {
101
+ if (type.isNullOrUnDef(decimals)) {
102
+ return parseInt(String(num)).toLocaleString();
103
+ }
104
+ let prec = 0;
105
+ if (!type.isNumber(decimals)) {
106
+ throw new Error('Decimals must be a positive number not less than zero');
107
+ }
108
+ else if (decimals > 0) {
109
+ prec = decimals;
110
+ }
111
+ return Number(Number(num).toFixed(prec)).toLocaleString('en-US');
77
112
  }
78
113
 
79
114
  exports.HEX_POOL = HEX_POOL;
115
+ exports.formatMoney = formatNumber;
80
116
  exports.formatNumber = formatNumber;
117
+ exports.humanFileSize = humanFileSize;
81
118
  exports.numberAbbr = numberAbbr;
82
119
  exports.numberToHex = numberToHex;
package/lib/cjs/object.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/path.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/qs.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/random.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/string.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/tree.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
@@ -212,7 +212,7 @@ function flatTree(treeList, options = defaultFieldOptions) {
212
212
  ...node,
213
213
  [childField]: [] // 清空子级
214
214
  };
215
- item.hasOwnProperty([childField]) && delete item[childField];
215
+ type.objectHas(item, childField) && delete item[childField];
216
216
  res.push(item);
217
217
  if (node[childField]) {
218
218
  const children = node[childField].map(item => ({
package/lib/cjs/type.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/unique.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/cjs/url.js CHANGED
@@ -1,29 +1,39 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ var type = require('./type.js');
9
10
  var path = require('./path.js');
10
11
  var qs = require('./qs.js');
11
12
 
12
- const anchorEl = document.createElement('a');
13
13
  /**
14
14
  * url 解析
15
15
  * @param {string} url
16
+ * @param {boolean} isModernApi 使用现代API:URL, 默认true (对无效url解析会抛错), 否则使用a标签来解析(兼容性更强)
16
17
  * @returns {Url}
17
18
  */
18
- const urlParse = (url) => {
19
- anchorEl.href = url;
20
- const { protocol, username, password, host, port, hostname, hash, search, pathname: _pathname } = anchorEl;
19
+ const urlParse = (url, isModernApi = true) => {
20
+ // @ts-ignore
21
+ let urlObj = null;
22
+ if (type.isFunction(URL) && isModernApi) {
23
+ urlObj = new URL(url);
24
+ }
25
+ else {
26
+ urlObj = document.createElement('a');
27
+ urlObj.href = url;
28
+ }
29
+ const { protocol, username, password, host, port, hostname, hash, search, pathname: _pathname } = urlObj;
21
30
  // fix: ie 浏览器下,解析出来的 pathname 是没有 / 根的
22
31
  const pathname = path.pathJoin('/', _pathname);
23
32
  const auth = username && password ? `${username}:${password}` : '';
24
33
  const query = search.replace(/^\?/, '');
25
34
  const searchParams = qs.qsParse(query);
26
35
  const path$1 = `${pathname}${search}`;
36
+ urlObj = null;
27
37
  return {
28
38
  protocol,
29
39
  auth,
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/es/array.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/es/async.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/es/base64.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,30 +1,26 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
- import { setStyle } from './dom.js';
8
-
9
- const textEl = document.createElement('textarea');
10
- setStyle(textEl, {
11
- position: 'absolute',
12
- top: '-9999px',
13
- left: '-9999px',
14
- opacity: 0
15
- });
16
- document.body.appendChild(textEl);
17
7
  /**
18
8
  * 复制文本
19
9
  * @param {string} text
20
10
  */
21
11
  function copyText(text) {
12
+ const textEl = document.createElement('textarea');
13
+ textEl.style.position = 'absolute';
14
+ textEl.style.top = '-9999px';
15
+ textEl.style.left = '-9999px';
22
16
  textEl.value = text;
17
+ document.body.appendChild(textEl);
23
18
  textEl.focus({ preventScroll: true });
24
19
  textEl.select();
25
20
  try {
26
21
  document.execCommand('copy');
27
22
  textEl.blur();
23
+ document.body.removeChild(textEl);
28
24
  }
29
25
  catch (err) {
30
26
  // ignore
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/es/cookie.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/es/date.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/es/dom.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/es/easing.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/es/file.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/es/func.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/es/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
@@ -21,7 +21,7 @@ export { chooseLocalFile, compressImg, supportCanvas } from './file.js';
21
21
  export { genCanvasWM } from './watermark.js';
22
22
  export { debounce, getGlobal, once, setGlobal, throttle } from './func.js';
23
23
  export { STRING_POOL, randomNumber, randomString, randomUuid } from './random.js';
24
- export { HEX_POOL, formatNumber, numberAbbr, numberToHex } from './number.js';
24
+ export { HEX_POOL, formatNumber as formatMoney, formatNumber, humanFileSize, numberAbbr, numberToHex } from './number.js';
25
25
  export { UNIQUE_NUMBER_SAFE_LENGTH, uniqueNumber, uniqueString } from './unique.js';
26
26
  export { tooltipEvent } from './tooltip.js';
27
27
  export { flatTree, forEachDeep, formatTree, fuzzySearchTree, mapDeep, searchTreeById } from './tree.js';
package/lib/es/isEqual.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/lib/es/math.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.8.4
2
+ * sculp-js v1.9.0
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */